/* ============================================
   RESET & BASE STYLES
   ============================================ */

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    font-size: 16px;
    scroll-behavior: smooth;
}

body {
    font-family: 'Montserrat', sans-serif;
    line-height: 1.6;
    color: #333;
    background-color: #f5f5f5;
}

/* ============================================
   HERO HEADER
   ============================================ */

.hero-header {
    position: relative;
    width: 100%;
    min-height: 400px;
    background-image: url('../images/header-image.jpg');
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    display: flex;
    align-items: flex-start;
    justify-content: flex-start;
}

.hero-header::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.4);
}

.hero-content {
    position: relative;
    z-index: 1;
    padding: 40px 60px;
    color: #ffffff;
}

.hero-logo {
    font-size: 56px;
    font-weight: 700;
    margin-bottom: 10px;
    text-shadow: 2px 2px 8px rgba(0, 0, 0, 0.8);
}

.hero-title {
    font-size: 28px;
    font-weight: 400;
    text-shadow: 2px 2px 8px rgba(0, 0, 0, 0.8);
}

/* ============================================
   BUTTONS SECTION - 4 boutons sur une ligne
   ============================================ */

.buttons-section {
    padding: 60px 20px;
    background-color: #ffffff;
}

.buttons-container {
    max-width: 1400px;
    margin: 0 auto;
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 20px;
}

.nav-button {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    background-color: #E51E23;
    color: #ffffff;
    padding: 30px 20px;
    text-decoration: none;
    border-radius: 8px;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
    transition: all 0.3s ease;
    min-height: 120px;
}

.nav-button:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 15px rgba(0, 0, 0, 0.2);
    opacity: 0.9;
}

.nav-button-icon {
    font-size: 32px;
    margin-bottom: 10px;
}

.nav-button-text {
    font-size: 16px;
    font-weight: 700;
    text-align: center;
}

/* ============================================
   UPLOAD SECTION - Zone grise
   ============================================ */

.upload-section {
    background-color: #e8e8e8;
    padding: 60px 20px;
    margin: 0;
}

.upload-container {
    max-width: 600px;
    margin: 0 auto;
    display: flex;
    justify-content: center;
    align-items: center;
}

.upload-form-wrapper {
    width: 100%;
    background-color: #ffffff;
    border-radius: 12px;
    padding: 40px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
}

.upload-title {
    font-size: 24px;
    font-weight: 700;
    color: #333;
    text-align: center;
    margin-bottom: 30px;
}

.upload-form {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

/* Champs d'identification */
.upload-fields {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 15px;
}

.field-group {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.field-label {
    font-size: 14px;
    font-weight: 600;
    color: #333;
}

.field-label .required {
    color: #E51E23;
}

.field-input {
    padding: 12px 15px;
    border: 1px solid #ddd;
    border-radius: 6px;
    font-size: 14px;
    font-family: inherit;
    transition: border-color 0.3s ease, box-shadow 0.3s ease;
}

.field-input:focus {
    outline: none;
    border-color: #E51E23;
    box-shadow: 0 0 0 3px rgba(229, 30, 35, 0.1);
}

.field-input::placeholder {
    color: #aaa;
}

.upload-dropzone {
    border: 2px dashed #ccc;
    border-radius: 8px;
    padding: 40px 20px;
    text-align: center;
    cursor: pointer;
    transition: all 0.3s ease;
    background-color: #fafafa;
}

.upload-dropzone:hover,
.upload-dropzone.dragover {
    border-color: #E51E23;
    background-color: #fff5f5;
}

.upload-dropzone.has-file {
    border-color: #28a745;
    background-color: #f0fff4;
}

.upload-icon {
    font-size: 48px;
    color: #999;
    margin-bottom: 15px;
}

.upload-dropzone:hover .upload-icon,
.upload-dropzone.dragover .upload-icon {
    color: #E51E23;
}

.upload-text {
    font-size: 16px;
    color: #666;
    margin-bottom: 10px;
}

.upload-browse-btn {
    display: inline-block;
    background-color: #E51E23;
    color: #ffffff;
    padding: 10px 25px;
    font-size: 14px;
    font-weight: 600;
    border-radius: 4px;
    cursor: pointer;
    transition: all 0.3s ease;
}

.upload-browse-btn:hover {
    background-color: #c9191d;
}

.upload-hint {
    font-size: 12px;
    color: #999;
    margin-top: 15px;
}

/* Liste des fichiers sélectionnés */
.files-list {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.file-item {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 12px 15px;
    background-color: #f8f8f8;
    border-radius: 6px;
    border: 1px solid #e0e0e0;
}

.file-info {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 15px;
    background-color: #f0f0f0;
    border-radius: 6px;
}

.file-icon {
    font-size: 20px;
    color: #E51E23;
    flex-shrink: 0;
}

.file-name {
    flex: 1;
    font-size: 14px;
    font-weight: 500;
    color: #333;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.file-size {
    font-size: 12px;
    color: #888;
    flex-shrink: 0;
}

.remove-file-btn {
    background: none;
    border: none;
    color: #999;
    font-size: 16px;
    cursor: pointer;
    padding: 5px;
    transition: color 0.3s ease;
    flex-shrink: 0;
}

.remove-file-btn:hover {
    color: #E51E23;
}

/* Progression upload */
.upload-progress {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.progress-info {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 13px;
}

.progress-file {
    color: #333;
    font-weight: 500;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    max-width: 80%;
}

.progress-count {
    color: #666;
    flex-shrink: 0;
}

.progress-bar {
    flex: 1;
    height: 8px;
    background-color: #e0e0e0;
    border-radius: 4px;
    overflow: hidden;
}

.progress-fill {
    height: 100%;
    background-color: #E51E23;
    border-radius: 4px;
    transition: width 0.3s ease;
    width: 0%;
}

.progress-text {
    font-size: 14px;
    font-weight: 600;
    color: #333;
    min-width: 40px;
}

.upload-message {
    padding: 12px 15px;
    border-radius: 6px;
    font-size: 14px;
    text-align: center;
}

.upload-message.success {
    background-color: #d4edda;
    color: #155724;
    border: 1px solid #c3e6cb;
}

.upload-message.error {
    background-color: #f8d7da;
    color: #721c24;
    border: 1px solid #f5c6cb;
}

.upload-submit-btn {
    background-color: #E51E23;
    color: #ffffff;
    border: none;
    padding: 15px 30px;
    font-size: 16px;
    font-weight: 700;
    border-radius: 6px;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
}

.upload-submit-btn:hover:not(:disabled) {
    background-color: #c9191d;
    transform: translateY(-2px);
    box-shadow: 0 4px 10px rgba(229, 30, 35, 0.3);
}

.upload-submit-btn:disabled {
    background-color: #ccc;
    cursor: not-allowed;
}

.upload-submit-btn i {
    font-size: 14px;
}

/* Ancien style du bouton (conservé pour compatibilité) */
.upload-button {
    display: inline-block;
    background-color: #666;
    color: #ffffff;
    padding: 15px 40px;
    font-size: 18px;
    font-weight: 700;
    text-decoration: none;
    border-radius: 4px;
    text-transform: uppercase;
    transition: all 0.3s ease;
}

.upload-button:hover {
    background-color: #555;
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
}

/* ============================================
   INFO SECTION - 3 colonnes avec listes
   ============================================ */

.info-section {
    background-color: #f5f5f5;
    padding: 60px 20px;
}

.info-container {
    max-width: 1400px;
    margin: 0 auto;
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 40px;
}

.info-column {
    background-color: #ffffff;
    padding: 30px;
    border-radius: 8px;
}

.info-title {
    font-size: 22px;
    font-weight: 700;
    color: #333;
    margin-bottom: 20px;
    padding-bottom: 10px;
    border-bottom: 2px solid #E51E23;
}

.info-list {
    list-style: disc;
    padding-left: 20px;
}

.info-list li {
    margin-bottom: 12px;
    color: #555;
    line-height: 1.5;
}

/* ============================================
   CONTACTS SECTION
   ============================================ */

.contacts-section {
    background-color: #ffffff;
    padding: 60px 20px;
}

.contacts-container {
    max-width: 1400px;
    margin: 0 auto;
}

.contacts-title {
    font-size: 28px;
    font-weight: 700;
    color: #333;
    margin-bottom: 30px;
}

.contacts-list {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.contact-item {
    font-size: 16px;
    color: #555;
}

.contact-label {
    color: #555;
    margin-right: 5px;
}

.contact-email {
    color: #E51E23;
    text-decoration: underline;
    transition: color 0.3s ease;
}

.contact-email:hover {
    color: #a31030;
}

/* ============================================
   FOOTER
   ============================================ */

.footer {
    background-color: #333;
    color: #ffffff;
    text-align: center;
    padding: 30px 20px;
}

.footer p {
    margin: 0;
    font-size: 14px;
}

/* ============================================
   RESPONSIVE DESIGN - TABLET
   ============================================ */

@media (max-width: 992px) {
    .buttons-container {
        grid-template-columns: repeat(2, 1fr);
    }

    .info-container {
        grid-template-columns: 1fr;
        gap: 30px;
    }

    .hero-logo {
        font-size: 42px;
    }

    .hero-title {
        font-size: 22px;
    }
}

@media (max-width: 768px) {
    .hero-header {
        min-height: 300px;
    }

    .hero-content {
        padding: 30px;
    }

    .hero-logo {
        font-size: 36px;
    }

    .hero-title {
        font-size: 20px;
    }

    .nav-button {
        padding: 25px 15px;
        min-height: 100px;
    }

    .nav-button-icon {
        font-size: 28px;
    }

    .nav-button-text {
        font-size: 14px;
    }

    .info-column {
        padding: 25px;
    }

    .info-title {
        font-size: 20px;
    }

    .contacts-title {
        font-size: 24px;
    }
}

/* ============================================
   RESPONSIVE DESIGN - MOBILE
   ============================================ */

@media (max-width: 480px) {
    .hero-header {
        min-height: 250px;
    }

    .hero-content {
        padding: 20px;
    }

    .hero-logo {
        font-size: 28px;
    }

    .hero-title {
        font-size: 16px;
    }

    .buttons-section {
        padding: 30px 15px;
    }

    .buttons-container {
        grid-template-columns: 1fr;
        gap: 15px;
    }

    .nav-button {
        flex-direction: row;
        justify-content: flex-start;
        gap: 15px;
        padding: 20px;
        min-height: auto;
    }

    .nav-button-icon {
        margin-bottom: 0;
        font-size: 24px;
    }

    .upload-section {
        padding: 40px 15px;
    }

    .upload-form-wrapper {
        padding: 25px 20px;
    }

    .upload-title {
        font-size: 20px;
        margin-bottom: 20px;
    }

    .upload-fields {
        grid-template-columns: 1fr;
        gap: 12px;
    }

    .field-input {
        padding: 10px 12px;
    }

    .upload-dropzone {
        padding: 30px 15px;
    }

    .upload-icon {
        font-size: 36px;
    }

    .upload-text {
        font-size: 14px;
    }

    .upload-browse-btn {
        padding: 8px 20px;
        font-size: 13px;
    }

    .file-item {
        padding: 10px 12px;
    }

    .file-name {
        font-size: 13px;
    }

    .file-size {
        font-size: 11px;
    }

    .upload-submit-btn {
        padding: 12px 25px;
        font-size: 14px;
    }

    .upload-button {
        padding: 12px 30px;
        font-size: 16px;
    }

    .info-section {
        padding: 40px 15px;
    }

    .info-column {
        padding: 20px;
    }

    .info-title {
        font-size: 18px;
    }

    .info-list li {
        font-size: 14px;
    }

    .contacts-section {
        padding: 40px 15px;
    }

    .contacts-title {
        font-size: 20px;
    }

    .contact-item {
        font-size: 14px;
    }

    .footer {
        padding: 20px 15px;
    }

    .footer p {
        font-size: 12px;
    }
}

/* ============================================
   ACCESSIBILITY
   ============================================ */

@media (prefers-reduced-motion: reduce) {
    * {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
}

/* Focus styles for keyboard navigation */
a:focus,
button:focus {
    outline: 3px solid #E51E23;
    outline-offset: 2px;
}

/* ============================================
   PRINT STYLES
   ============================================ */

@media print {
    .hero-header {
        min-height: 200px;
    }

    .hero-logo {
        font-size: 32px;
    }

    .hero-title {
        font-size: 18px;
    }

    .nav-button {
        break-inside: avoid;
        page-break-inside: avoid;
    }

    .upload-section {
        background-color: #f0f0f0 !important;
        -webkit-print-color-adjust: exact;
        print-color-adjust: exact;
    }

    .info-column {
        break-inside: avoid;
        page-break-inside: avoid;
    }

    .footer {
        display: none;
    }
}
