/* =========================================================
   EU Fortrydelsesfunktion — Frontend Styles
   ========================================================= */

/* --- Flydende knap (FAB) --- */
.eu-fort-fab {
    position: fixed;
    bottom: 24px;
    z-index: 99999;
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 12px 20px;
    border-radius: 50px;
    color: #fff !important;
    text-decoration: none !important;
    font-size: 14px;
    font-weight: 600;
    letter-spacing: .02em;
    box-shadow: 0 4px 20px rgba(0,0,0,.25);
    transition: transform .2s ease, box-shadow .2s ease;
    line-height: 1;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
}
.eu-fort-fab:hover {
    box-shadow: 0 8px 28px rgba(0,0,0,.3);
    color: #fff !important;
    text-decoration: none !important;
}
.eu-fort-fab svg {
    width: 18px;
    height: 18px;
    flex-shrink: 0;
}

/* Placering: højre (standard) */
.eu-fort-fab-right {
    right: 24px;
}
.eu-fort-fab-right:hover {
    transform: translateY(-3px);
}

/* Placering: venstre */
.eu-fort-fab-left {
    left: 24px;
}
.eu-fort-fab-left:hover {
    transform: translateY(-3px);
}

/* Placering: midt */
.eu-fort-fab-center {
    left: 50%;
    transform: translateX(-50%);
}
.eu-fort-fab-center:hover {
    transform: translateX(-50%) translateY(-3px);
}

/* --- Wrapper --- */
.eu-fort-wrap {
    max-width: 700px;
    margin: 0 auto;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    color: #1e293b;
}

/* --- Hero header --- */
.eu-fort-hero {
    text-align: center;
    padding: 40px 24px 32px;
    background: linear-gradient(135deg, #f8fafc 0%, #f1f5f9 100%);
    border-radius: 16px 16px 0 0;
    border: 1px solid #e2e8f0;
    border-bottom: none;
}
.eu-fort-hero-icon {
    font-size: 40px;
    margin-bottom: 12px;
    display: block;
}
.eu-fort-hero h2 {
    font-size: 26px;
    font-weight: 700;
    color: #0f172a;
    margin: 0 0 12px;
    padding: 0;
}
.eu-fort-hero p {
    font-size: 15px;
    color: #475569;
    margin: 0;
    line-height: 1.6;
}

/* --- Formular --- */
.eu-fort-form {
    background: #fff;
    border: 1px solid #e2e8f0;
    border-radius: 0 0 16px 16px;
    padding: 32px;
}

.eu-fort-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
}

.eu-fort-field {
    display: flex;
    flex-direction: column;
    gap: 6px;
}
.eu-fort-field.eu-fort-full {
    grid-column: 1 / -1;
}

.eu-fort-field label {
    font-size: 13px;
    font-weight: 600;
    color: #374151;
    letter-spacing: .03em;
    text-transform: uppercase;
}
.eu-fort-req {
    color: #ef4444;
    margin-left: 2px;
}
.eu-fort-optional {
    font-weight: 400;
    color: #94a3b8;
    text-transform: none;
    font-size: 12px;
    letter-spacing: 0;
}
.eu-fort-hint {
    font-size: 12px;
    color: #94a3b8;
    margin-top: 2px;
}

.eu-fort-form input[type="text"],
.eu-fort-form input[type="email"],
.eu-fort-form input[type="tel"],
.eu-fort-form input[type="url"],
.eu-fort-form textarea {
    width: 100%;
    padding: 11px 14px;
    border: 1.5px solid #e2e8f0;
    border-radius: 8px;
    font-size: 15px;
    color: #1e293b;
    background: #f8fafc;
    transition: border-color .15s, box-shadow .15s, background .15s;
    box-sizing: border-box;
    font-family: inherit;
    line-height: 1.5;
}
.eu-fort-form input:focus,
.eu-fort-form textarea:focus {
    outline: none;
    border-color: #6366f1;
    background: #fff;
    box-shadow: 0 0 0 3px rgba(99,102,241,.12);
}
.eu-fort-form input.invalid,
.eu-fort-form textarea.invalid {
    border-color: #ef4444;
    box-shadow: 0 0 0 3px rgba(239,68,68,.1);
}
.eu-fort-form textarea {
    resize: vertical;
    min-height: 80px;
}

/* --- Notice --- */
.eu-fort-notice {
    display: flex;
    gap: 12px;
    align-items: flex-start;
    background: #fffbeb;
    border: 1px solid #fcd34d;
    border-radius: 10px;
    padding: 14px 16px;
    margin: 24px 0;
}
.eu-fort-notice svg {
    width: 20px;
    height: 20px;
    flex-shrink: 0;
    color: #d97706;
    margin-top: 1px;
}
.eu-fort-notice p {
    margin: 0;
    font-size: 14px;
    color: #92400e;
    line-height: 1.5;
}

/* --- Alert --- */
.eu-fort-alert {
    padding: 12px 16px;
    border-radius: 8px;
    font-size: 14px;
    margin-bottom: 16px;
}
.eu-fort-alert-error {
    background: #fef2f2;
    border: 1px solid #fecaca;
    color: #991b1b;
}

/* --- Submit knap --- */
.eu-fort-btn-submit {
    width: 100%;
    padding: 15px 24px;
    background: #1e293b;
    color: #fff;
    border: none;
    border-radius: 10px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    transition: background .15s, transform .1s;
    font-family: inherit;
    letter-spacing: .01em;
}
.eu-fort-btn-submit:hover {
    background: #0f172a;
    transform: translateY(-1px);
}
.eu-fort-btn-submit:active {
    transform: none;
}
.eu-fort-btn-submit:disabled {
    background: #94a3b8;
    cursor: not-allowed;
    transform: none;
}

/* Spinner */
.eu-fort-spinner {
    width: 18px;
    height: 18px;
    border: 2px solid rgba(255,255,255,.3);
    border-top-color: #fff;
    border-radius: 50%;
    display: none;
    animation: eu-fort-spin .7s linear infinite;
    flex-shrink: 0;
}
.eu-fort-btn-submit.loading .eu-fort-spinner {
    display: block;
}
.eu-fort-btn-submit.loading .eu-fort-btn-text {
    opacity: .7;
}

@keyframes eu-fort-spin {
    to { transform: rotate(360deg); }
}

/* --- Legal --- */
.eu-fort-legal {
    font-size: 12px;
    color: #94a3b8;
    text-align: center;
    margin: 14px 0 0;
    line-height: 1.5;
}

/* --- Succes view --- */
.eu-fort-success-view {
    text-align: center;
    padding: 60px 32px;
    background: #fff;
    border: 1px solid #e2e8f0;
    border-radius: 16px;
}
.eu-fort-success-icon {
    width: 72px;
    height: 72px;
    background: linear-gradient(135deg, #10b981, #059669);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 32px;
    color: #fff;
    margin: 0 auto 24px;
    display: -webkit-flex;
    display: flex;
}
.eu-fort-success-view h2 {
    font-size: 26px;
    font-weight: 700;
    color: #0f172a;
    margin: 0 0 12px;
}
.eu-fort-success-ref {
    background: #f0fdf4;
    border: 1px solid #bbf7d0;
    color: #166534;
    padding: 12px 20px;
    border-radius: 8px;
    font-size: 15px;
    margin-bottom: 16px;
}
.eu-fort-success-view p {
    font-size: 15px;
    color: #475569;
    line-height: 1.6;
    margin: 0 0 12px;
}
.eu-fort-success-view a {
    color: #6366f1;
}

/* --- Responsiv --- */
@media (max-width: 600px) {
    .eu-fort-grid {
        grid-template-columns: 1fr;
    }
    .eu-fort-field.eu-fort-full {
        grid-column: 1;
    }
    .eu-fort-hero {
        padding: 28px 16px 24px;
        border-radius: 12px 12px 0 0;
    }
    .eu-fort-form {
        padding: 20px 16px;
        border-radius: 0 0 12px 12px;
    }
    .eu-fort-fab {
        bottom: 16px;
        padding: 10px 16px;
        font-size: 13px;
    }
    .eu-fort-fab-right {
        right: 16px;
    }
    .eu-fort-fab-left {
        left: 16px;
    }
}
