/* ==================== STYLES GLOBAUX ==================== */
.contact-page {
    padding: 80px 20px;
    max-width: 100vw;
    overflow-x: clip;
}

/* ==================== TITRES ==================== */
.section-title {
    font-family: 'Abril Fatface', serif;
    font-size: 72px;
    color: var(--text-primary);
    margin-bottom: 20px;
    line-height: 1.1;
}

.section-title .highlight {
    color: #DD9933;
}

.section-intro {
    font-size: 18px;
    color: var(--text-secondary);
    max-width: 600px;
    margin-bottom: 50px;
    line-height: 1.8;
}

/* ==================== LAYOUT PRINCIPAL ==================== */
.contact-layout {
    display: grid;
    grid-template-columns: 1fr 350px;
    gap: 50px;
    align-items: start;
}

/* ==================== CARTE FORMULAIRE ==================== */
.form-card {
    background: var(--bg-card);
    border-radius: 24px;
    padding: 50px;
    box-shadow: var(--shadow-card);
}

.form-title {
    font-family: var(--font-ui);
    font-size: 28px;
    font-weight: 700;
    color: var(--text-primary);
    margin-bottom: 30px;
}

.form-required-note {
    margin: -14px 0 24px;
    font-size: 13px;
    color: var(--text-secondary);
}

.form-required-note .required {
    color: #DD9933;
    font-weight: 700;
}

/* Champs du formulaire */
.form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
    margin-bottom: 25px;
}

.form-group {
    margin-bottom: 25px;
}

.form-group.full-width {
    grid-column: 1 / -1;
}

.form-label {
    display: block;
    font-size: 14px;
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 10px;
}

.form-label .required {
    color: #DD9933;
    margin-left: 3px;
}

.form-input,
.form-textarea {
    width: 100%;
    padding: 16px 20px;
    border: 2px solid var(--border-color);
    border-radius: 12px;
    font-family: 'Open Sans', sans-serif;
    font-size: 16px;
    color: var(--text-primary);
    background: var(--bg-input);
    transition: all 0.3s ease;
}

.form-input:focus,
.form-textarea:focus {
    outline: none;
    border-color: #DD9933;
    background: var(--bg-card);
    box-shadow: 0 0 0 4px rgba(221, 153, 51, 0.1);
}

.form-input::placeholder,
.form-textarea::placeholder {
    color: var(--text-muted);
}

.form-textarea {
    min-height: 150px;
    resize: vertical;
}

/* Checkbox RGPD */
.form-checkbox {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    margin-bottom: 30px;
}

.form-checkbox input[type="checkbox"] {
    width: 20px;
    height: 20px;
    margin-top: 2px;
    accent-color: #DD9933;
    cursor: pointer;
    flex-shrink: 0;
}

.form-checkbox label {
    font-size: 14px;
    color: var(--text-secondary);
    line-height: 1.5;
    cursor: pointer;
}

.form-checkbox label .required {
    color: #DD9933;
}

/* reCAPTCHA */
.recaptcha-container {
    margin-bottom: 30px;
    display: flex;
    justify-content: flex-start;
}

/* Responsive reCAPTCHA */
.g-recaptcha {
    transform: scale(1);
    transform-origin: 0 0;
}

/* Bouton envoyer */
.form-submit {
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    gap: 10px;
    width: 100%;
    padding: 18px 40px;
    background: linear-gradient(135deg, #DD9933 0%, #c4872d 100%);
    color: white;
    border: none;
    border-radius: 30px;
    font-family: 'Open Sans', sans-serif;
    font-size: 16px;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 4px 15px rgba(221, 153, 51, 0.3);
    text-align: center;
    letter-spacing: 1px;
    text-transform: uppercase;
}

.form-submit:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 25px rgba(221, 153, 51, 0.4);
}

.form-submit svg {
    width: 18px;
    height: 18px;
    fill: currentColor;
    display: inline-block;
    vertical-align: middle;
    flex-shrink: 0;
}

/* ==================== SIDEBAR ==================== */
.contact-sidebar {
    position: sticky;
    top: 100px;
}

.sidebar-card {
    background: var(--bg-card);
    border-radius: 24px;
    padding: 40px;
    box-shadow: var(--shadow-card);
    text-align: center;
}

.sidebar-title {
    font-family: var(--font-ui);
    font-size: 24px;
    font-weight: 700;
    color: var(--text-primary);
    margin-bottom: 10px;
}

.sidebar-title .highlight {
    color: #DD9933;
}

.sidebar-subtitle {
    font-size: 14px;
    color: var(--text-secondary);
    margin-bottom: 30px;
}

/* Icônes de contact */
.contact-icons {
    display: flex;
    justify-content: center;
    gap: 20px;
}

.contact-icon {
    width: 70px;
    height: 70px;
    background: var(--bg-card-alt);
    border-radius: 16px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
    text-decoration: none;
}

.contact-icon:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.1);
}

.contact-icon.linkedin {
    background: #0A66C2;
}

.contact-icon.linkedin:hover {
    background: #004182;
}

.contact-icon.email {
    background: linear-gradient(135deg, #DD9933 0%, #c4872d 100%);
}

.contact-icon.email:hover {
    background: linear-gradient(135deg, #c4872d 0%, #a86f1f 100%);
}

.contact-icon.github {
    background: #24292e;
}

.contact-icon.github:hover {
    background: #000000;
}

.contact-icon svg {
    width: 32px;
    height: 32px;
    fill: white;
}

/* Info délai de réponse */
.response-info {
    margin-top: 30px;
    padding: 20px;
    background: var(--bg-card-alt);
    border-radius: 12px;
    display: flex;
    align-items: center;
    gap: 12px;
}

.response-info svg {
    width: 24px;
    height: 24px;
    fill: #DD9933;
    flex-shrink: 0;
}

.response-info span {
    font-size: 14px;
    color: var(--text-secondary);
}

.response-info strong {
    color: #DD9933;
}

/* ==================== RESPONSIVE ==================== */

/* Tablette (601px à 900px) */
@media (min-width: 601px) and (max-width: 900px) {
    .section-title {
        font-size: 48px;
        text-align: center;
    }

    .section-intro {
        text-align: center;
        max-width: 100%;
    }

    .contact-layout {
        display: flex;
        flex-direction: column;
        gap: 40px;
    }

    /* Formulaire en premier */
    .form-card {
        order: 1;
        padding: 40px;
    }

    /* Sidebar en second */
    .contact-sidebar {
        position: static;
        order: 2;
        align-self: center;
        width: 100%;
        max-width: 500px;
    }

    .sidebar-card {
        padding: 35px;
    }
}

/* Max 900px - Layout 1 colonne */
@media (max-width: 900px) {
    .contact-layout {
        grid-template-columns: 1fr;
    }

    .contact-sidebar {
        position: static;
    }

    .section-title {
        font-size: 56px;
    }
}

/* Mobile (max 600px) */
@media (max-width: 600px) {
    .contact-page {
        padding: 60px 15px;
    }

    .section-title {
        font-size: 36px;
        text-align: center;
        word-wrap: break-word;
        overflow-wrap: break-word;
    }

    .section-intro {
        font-size: 16px;
        text-align: center;
        padding: 0 10px;
    }

    .form-card {
        padding: 30px 20px;
    }

    .form-title {
        font-size: 24px;
        text-align: center;
    }

    .form-row {
        grid-template-columns: 1fr;
        gap: 0;
    }

    .form-input,
    .form-textarea {
        padding: 14px 16px;
        font-size: 16px;
    }

    .form-checkbox {
        gap: 10px;
    }

    .form-checkbox label {
        font-size: 13px;
    }

    .form-submit {
        padding: 16px 30px;
        font-size: 15px;
    }

    .sidebar-card {
        padding: 30px 20px;
    }

    .sidebar-title {
        font-size: 22px;
    }

    .contact-icons {
        gap: 15px;
    }

    .contact-icon {
        width: 60px;
        height: 60px;
        border-radius: 14px;
    }

    .contact-icon svg {
        width: 28px;
        height: 28px;
    }

    .response-info {
        padding: 15px;
        gap: 10px;
    }

    .response-info span {
        font-size: 13px;
    }

    /* reCAPTCHA responsive sur mobile */
    .recaptcha-container {
        margin-bottom: 25px;
        overflow: hidden;
    }

    .g-recaptcha {
        transform: scale(0.85);
        transform-origin: 0 0;
    }
}

/* Très petit mobile (max 400px) */
@media (max-width: 400px) {
    .g-recaptcha {
        transform: scale(0.75);
        transform-origin: 0 0;
    }
}

/* ==================== FORM TOAST ==================== */
.form-toast {
    position: fixed;
    bottom: 30px;
    left: 50%;
    transform: translateX(-50%) translateY(100px);
    padding: 16px 28px;
    border-radius: 14px;
    font-size: 15px;
    font-weight: 600;
    font-family: 'Open Sans', sans-serif;
    color: white;
    z-index: 10000;
    opacity: 0;
    transition: all 0.4s cubic-bezier(0.16, 1, 0.3, 1);
    display: flex;
    align-items: center;
    gap: 10px;
    box-shadow: 0 8px 30px rgba(0, 0, 0, 0.2);
}

.form-toast.visible {
    opacity: 1;
    transform: translateX(-50%) translateY(0);
}

.form-toast.success {
    background: linear-gradient(135deg, #28a745 0%, #218838 100%);
}

.form-toast.error {
    background: linear-gradient(135deg, #dc3545 0%, #c82333 100%);
}

.form-toast.warning {
    background: linear-gradient(135deg, #DD9933 0%, #c4872d 100%);
}

.form-toast svg {
    width: 20px;
    height: 20px;
    fill: white;
    flex-shrink: 0;
}

.form-submit.sending {
    pointer-events: none;
    opacity: 0.7;
}

.form-submit.sending span {
    display: none;
}

.form-submit.sending::after {
    content: attr(data-sending-label);
    color: white;
}

.form-submit span {
    color: white !important;
}
