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

:root {
    --primary-red: #ec0707;
    --bright-red: #ff1a1a;
    --dark-red: #c40606;
    --black: #0A0A0A;
    --dark-gray: #1A1A1A;
    --medium-gray: #333333;
    --light-gray: #F8F9FA;
    --white: #FFFFFF;
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    line-height: 1.6;
    color: var(--medium-gray);
    background: var(--white);
    padding-top: 200px;
}

header {
    background: var(--black);
    color: white;
    padding: 0;
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    width: 100%;
    overflow: hidden;
    border-bottom: 4px solid var(--primary-red);
    z-index: 999;
}

header::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(to right, rgba(10, 10, 10, 0.85) 0%, rgba(26, 26, 26, 0.5) 50%, rgba(26, 26, 26, 0.2) 100%), url('public/assets/copeaux.jpg');
    background-size: cover;
    background-position: center;
    z-index: 0;
}

header::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: url('public/assets/copeaux.jpg');
    background-size: cover;
    background-position: center;
    opacity: 0.3;
    z-index: 1;
}

.header-content {
    position: relative;
    z-index: 2;
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 25px 40px;
    max-width: 1400px;
    margin: 0 auto;
}

.header-left {
    display: flex;
    align-items: center;
    gap: 20px;
    position: relative;
    z-index: 3;
}

.logo-image {
    width: 100px;
    height: 100px;
    object-fit: contain;
}

.logo-section {
    display: flex;
    flex-direction: column;
}

.logo-section h1 {
    font-size: 2.2em;
    font-weight: 300;
    letter-spacing: 8px;
    margin: 0;
    line-height: 1;
}

.logo-section h2 {
    font-size: 1.1em;
    font-weight: 300;
    letter-spacing: 4px;
    color: var(--primary-red);
    margin: 5px 0 0 0;
}

.header-right {
    display: flex;
    align-items: center;
    gap: 30px;
    position: relative;
    z-index: 3;
}

.header-badges {
    display: flex;
    gap: 15px;
}

.lang-switcher {
    display: flex;
    gap: 8px;
}

.lang-link {
    display: inline-block;
    padding: 6px 12px;
    border: 1px solid var(--dark-gray);
    border-radius: 5px;
    color: inherit;
    text-decoration: none;
    font-size: 0.85em;
    font-weight: 600;
    letter-spacing: 1px;
    transition: all 0.2s ease;
}

.lang-link:hover {
    border-color: var(--primary-red);
    color: var(--primary-red);
}

.lang-link.active {
    background: var(--primary-red);
    border-color: var(--primary-red);
    color: #fff;
}

.badge {
    background: rgba(236, 7, 7, 0.15);
    border: 1px solid var(--primary-red);
    padding: 8px 16px;
    border-radius: 5px;
    font-size: 0.9em;
    font-weight: 500;
    white-space: nowrap;
}

nav {
    background: var(--black);
    border-bottom: 2px solid var(--dark-gray);
    position: fixed;
    top: 135px;
    left: 0;
    right: 0;
    width: 100%;
    z-index: 999;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.3);
}

.nav-container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 40px;
}

.hamburger {
    display: none;
    background: none;
    border: none;
    color: white;
    font-size: 1.8em;
    cursor: pointer;
    padding: 10px;
}

nav ul {
    list-style: none;
    display: flex;
    justify-content: center;
    align-items: center;
}

nav ul li {
    margin: 0;
}

nav ul li a {
    display: block;
    color: white;
    text-decoration: none;
    padding: 18px 22px;
    transition: all 0.3s;
    font-weight: 500;
    letter-spacing: 1px;
}

nav ul li a:hover {
    background: var(--primary-red);
    color: white;
}

nav ul li a.active {
    background: var(--primary-red);
    color: white;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

section {
    padding: 80px 0;
}

section h2 {
    font-size: 2.8em;
    margin-bottom: 30px;
    text-align: center;
    font-weight: 300;
    letter-spacing: 3px;
    text-transform: uppercase;
    color: var(--white);
    position: relative;
    padding: 40px 20px;
    background: linear-gradient(to right, rgba(10, 10, 10, 0.3) 0%, rgba(26, 26, 26, 0.6) 50%, rgba(10, 10, 10, 0.9) 100%), 
                url('public/assets/suisse.jpg');
    background-size: auto 100%;
    background-repeat: no-repeat;
    background-position: left center;
    border-radius: 10px;
    box-shadow: 0 5px 20px rgba(0,0,0,0.2);
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.8);
}

section h2::after {
    content: '';
    position: absolute;
    bottom: 10px;
    left: 50%;
    transform: translateX(-50%);
    width: 100px;
    height: 3px;
    background: var(--primary-red);
    border-radius: 2px;
}

section p.intro {
    text-align: center;
    font-size: 1.2em;
    color: #555;
    max-width: 900px;
    margin: 0 auto 50px;
    line-height: 1.8;
}

.hero {
    background: linear-gradient(135deg, var(--black) 0%, var(--dark-gray) 50%, var(--dark-red) 100%);
    color: white;
    text-align: center;
    padding: 60px 20px;
}

.hero h3 {
    font-size: 3em;
    margin-bottom: 25px;
    font-weight: 300;
    letter-spacing: 3px;
}

.hero p {
    font-size: 1.25em;
    max-width: 800px;
    margin: 0 auto 40px;
    line-height: 1.8;
}

.cta-button {
    display: inline-block;
    background: var(--primary-red);
    color: white;
    padding: 15px 40px;
    text-decoration: none;
    font-size: 1.1em;
    font-weight: 600;
    border-radius: 5px;
    transition: all 0.3s;
    border: 2px solid var(--primary-red);
}

.cta-button:hover {
    background: var(--dark-red);
    transform: translateY(-3px);
    box-shadow: 0 5px 15px rgba(236, 7, 7, 0.4);
}

.gray-bg {
    background: var(--light-gray);
}

.vision-highlights {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 30px;
    margin-top: 50px;
}

.highlight-item {
    background: white;
    padding: 35px 25px;
    border-radius: 10px;
    box-shadow: 0 5px 20px rgba(0,0,0,0.1);
    text-align: center;
    transition: all 0.3s;
    border-top: 4px solid var(--primary-red);
}

.highlight-item:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 30px rgba(236, 7, 7, 0.3);
}

.highlight-item h3 {
    font-size: 1.5em;
    margin-bottom: 15px;
    color: var(--black);
    font-weight: 600;
}

.highlight-item p {
    color: #666;
    line-height: 1.8;
    font-size: 1.05em;
}

.priority-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(400px, 1fr));
    gap: 40px;
    margin-top: 50px;
}

.priority-card {
    background: white;
    padding: 40px;
    border-radius: 10px;
    box-shadow: 0 5px 20px rgba(0,0,0,0.1);
    border-left: 5px solid var(--primary-red);
    transition: all 0.3s;
}

.priority-card:hover {
    transform: translateX(5px);
    box-shadow: 0 8px 30px rgba(236, 7, 7, 0.3);
}

.priority-card h3 {
    font-size: 1.8em;
    margin-bottom: 20px;
    color: var(--primary-red);
    font-weight: 600;
}

.priority-card p {
    color: #666;
    line-height: 1.8;
    font-size: 1.05em;
}

.machines-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(340px, 1fr));
    gap: 30px;
    margin-top: 50px;
}

.machine-card {
    background: white;
    padding: 30px 25px;
    border-radius: 10px;
    box-shadow: 0 5px 20px rgba(0,0,0,0.1);
    transition: all 0.3s;
    border-left: 4px solid var(--primary-red);
}

.machine-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 30px rgba(236, 7, 7, 0.3);
}

.machine-icon-header {
    width: 60px;
    height: 60px;
    background: var(--light-gray);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 20px;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

.machine-icon-header img {
    width: 35px;
    height: 35px;
    object-fit: contain;
}

.machine-card:hover .machine-icon-header {
    background: white;
    transform: scale(1.2) rotate(8deg);
    box-shadow: 0 8px 25px rgba(236, 7, 7, 0.3);
}

.machine-card h3 {
    text-align: center;
    font-size: 1.4em;
    margin-bottom: 20px;
    color: var(--black);
    font-weight: 600;
    letter-spacing: 1px;
}

.machine-card ul {
    list-style: none;
    padding: 0;
}

.machine-card ul li {
    padding: 10px 0;
    padding-left: 25px;
    position: relative;
    color: #555;
    line-height: 1.6;
}

.machine-card ul li::before {
    content: '▸';
    position: absolute;
    left: 0;
    color: var(--primary-red);
    font-weight: bold;
}

.materials-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 30px;
    margin-top: 50px;
}

.material-item {
    background: white;
    padding: 35px 25px;
    border-radius: 10px;
    box-shadow: 0 5px 20px rgba(0,0,0,0.1);
    text-align: center;
    transition: all 0.3s;
    border-top: 4px solid var(--primary-red);
}

.material-item:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 30px rgba(236, 7, 7, 0.3);
}

.material-item h4 {
    font-size: 1.3em;
    margin-bottom: 12px;
    color: var(--black);
    font-weight: 600;
    letter-spacing: 0.5px;
}

.material-item p {
    color: #666;
    font-size: 1em;
    line-height: 1.6;
}

.contact-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 30px;
    margin-top: 50px;
}

.contact-item {
    background: white;
    padding: 35px 25px;
    border-radius: 10px;
    box-shadow: 0 5px 20px rgba(0,0,0,0.1);
    text-align: center;
    transition: all 0.3s;
    border-top: 4px solid var(--primary-red);
}

.contact-item:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 30px rgba(236, 7, 7, 0.3);
}

.contact-item h3 {
    font-size: 1.3em;
    margin-bottom: 15px;
    color: var(--black);
    font-weight: 600;
    letter-spacing: 1px;
}

.contact-item p {
    color: #666;
    line-height: 1.8;
    font-size: 1.05em;
}

.contact-item a {
    color: var(--primary-red);
    text-decoration: none;
    font-weight: 600;
    transition: color 0.3s;
}

.contact-item a:hover {
    color: var(--dark-red);
}

.products-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: 35px;
    margin-top: 50px;
}

.product-card {
    background: white;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 5px 20px rgba(0,0,0,0.1);
    transition: all 0.3s;
    border: 2px solid transparent;
}

.product-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 12px 35px rgba(236, 7, 7, 0.3);
    border-color: var(--primary-red);
}

.product-image {
    position: relative;
    width: 100%;
    height: 280px;
    overflow: hidden;
    background: var(--light-gray);
}

.product-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s;
}

.product-card:hover .product-image img {
    transform: scale(1.1);
}

.product-badge {
    position: absolute;
    top: 15px;
    right: 15px;
    background: var(--primary-red);
    color: white;
    padding: 8px 16px;
    border-radius: 5px;
    font-size: 0.85em;
    font-weight: 600;
    z-index: 2;
}

.product-badge.promo {
    background: #ff9500;
}

.gallery-indicator {
    position: absolute;
    bottom: 15px;
    left: 15px;
    background: rgba(0, 0, 0, 0.7);
    color: white;
    padding: 6px 12px;
    border-radius: 5px;
    font-size: 0.85em;
    z-index: 2;
}

.gallery-image {
    cursor: pointer;
}

.product-info {
    padding: 25px;
}

.product-info h3 {
    font-size: 1.4em;
    margin-bottom: 12px;
    color: var(--black);
    font-weight: 600;
}

.product-description {
    color: #666;
    line-height: 1.7;
    margin-bottom: 15px;
    font-size: 0.95em;
}

.product-specs {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin: 15px 0;
}

.product-specs span {
    background: var(--light-gray);
    padding: 6px 12px;
    border-radius: 5px;
    font-size: 0.85em;
    color: #555;
}

.product-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: 20px;
    padding-top: 20px;
    border-top: 2px solid var(--light-gray);
}

.product-price {
    font-size: 1.5em;
    color: var(--primary-red);
    font-weight: 700;
}

.product-btn {
    background: var(--primary-red);
    color: white;
    padding: 12px 25px;
    text-decoration: none;
    border-radius: 5px;
    font-weight: 600;
    transition: all 0.3s;
    border: 2px solid var(--primary-red);
}

.product-btn:hover {
    background: var(--dark-red);
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(236, 7, 7, 0.4);
}

.product-download {
    margin-top: 15px;
    padding-top: 15px;
    border-top: 1px solid #eee;
}

.download-link {
    display: inline-block;
    color: var(--primary-red);
    text-decoration: none;
    font-size: 0.9em;
    font-weight: 600;
    transition: color 0.3s;
}

.download-link:hover {
    color: var(--dark-red);
}

.gallery-modal {
    display: none;
    position: fixed;
    z-index: 9999;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.95);
}

.gallery-modal.active {
    display: flex;
    align-items: center;
    justify-content: center;
}

.gallery-content {
    position: relative;
    max-width: 90%;
    max-height: 90%;
}

.gallery-content img {
    max-width: 100%;
    max-height: 85vh;
    object-fit: contain;
}

.gallery-close {
    position: absolute;
    top: 30px;
    right: 45px;
    color: white;
    font-size: 45px;
    font-weight: bold;
    cursor: pointer;
    z-index: 10000;
    transition: color 0.3s;
}

.gallery-close:hover {
    color: var(--primary-red);
}

.gallery-nav {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background: rgba(236, 7, 7, 0.8);
    color: white;
    border: none;
    font-size: 30px;
    padding: 15px 20px;
    cursor: pointer;
    transition: all 0.3s;
    z-index: 10000;
}

.gallery-nav:hover {
    background: var(--primary-red);
}

.gallery-nav.prev {
    left: 20px;
}

.gallery-nav.next {
    right: 20px;
}

.gallery-counter {
    text-align: center;
    color: white;
    margin-top: 15px;
    font-size: 1.1em;
}

.founder-content {
    max-width: 900px;
    margin: 40px auto;
    padding: 40px;
    background: white;
    border-radius: 12px;
    box-shadow: 0 5px 25px rgba(0,0,0,0.1);
    border-left: 5px solid var(--primary-red);
}

.founder-content h3 {
    font-size: 2.2em;
    margin-bottom: 10px;
    color: var(--black);
    font-weight: 600;
    letter-spacing: 2px;
}

.founder-content h4 {
    font-size: 1.3em;
    color: var(--primary-red);
    margin-bottom: 30px;
    font-weight: 400;
    letter-spacing: 1px;
}

.founder-content p {
    font-size: 1.1em;
    line-height: 1.9;
    color: #555;
    margin-bottom: 25px;
}

.download-card {
    min-height: 280px;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
}

.download-icon {
    font-size: 4em;
    margin-bottom: 20px;
}

.download-btn {
    display: inline-block;
    background: var(--primary-red);
    color: white;
    padding: 12px 25px;
    text-decoration: none;
    border-radius: 5px;
    font-weight: 600;
    transition: all 0.3s;
    margin-top: 15px;
}

.download-btn:hover {
    background: var(--dark-red);
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(236, 7, 7, 0.4);
}

.contact-form-wrapper {
    max-width: 800px;
    margin: 50px auto 0;
}

.contact-form {
    background: white;
    padding: 40px;
    border-radius: 10px;
    box-shadow: 0 5px 20px rgba(0,0,0,0.1);
}

.form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
    margin-bottom: 20px;
}

.form-group {
    margin-bottom: 20px;
}

.form-group label {
    display: block;
    margin-bottom: 8px;
    font-weight: 600;
    color: var(--black);
    font-size: 0.95em;
}

.form-group input,
.form-group select,
.form-group textarea {
    width: 100%;
    padding: 12px 15px;
    border: 2px solid #e0e0e0;
    border-radius: 5px;
    font-size: 1em;
    font-family: inherit;
    transition: border-color 0.3s;
}

.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
    outline: none;
    border-color: var(--primary-red);
}

.form-group textarea {
    resize: vertical;
    min-height: 120px;
}

.checkbox-label {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    cursor: pointer;
}

.checkbox-label input[type="checkbox"] {
    width: auto;
    margin-top: 3px;
    cursor: pointer;
}

.checkbox-label span {
    font-size: 0.9em;
    color: #666;
}

.submit-btn {
    background: var(--primary-red);
    color: white;
    border: none;
    padding: 15px 40px;
    font-size: 1.1em;
    font-weight: 600;
    border-radius: 5px;
    cursor: pointer;
    transition: all 0.3s;
    width: 100%;
    margin-top: 10px;
}

.submit-btn:hover {
    background: var(--dark-red);
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(236, 7, 7, 0.3);
}

.form-note {
    margin-top: 15px;
    font-size: 0.85em;
    color: #999;
    text-align: center;
}

.header-left a {
    transition: opacity 0.3s ease, transform 0.3s ease;
}

.header-left a:hover {
    opacity: 0.8;
    transform: scale(1.02);
}

.header-left a:hover .logo-image {
    filter: brightness(1.1);
}

footer {
    background: var(--black);
    color: white;
    text-align: center;
    padding: 40px 20px;
    border-top: 4px solid var(--primary-red);
}

footer p {
    font-size: 1em;
    font-weight: 300;
}

@media (max-width: 768px) {
    /* Le header défile normalement, la nav reste collée en haut :
       plus aucun chevauchement entre les deux. */
    header {
        /* relative (et non static) : les calques ::before/::after du header
           doivent rester ancrés sur le header, pas sur la page entière */
        position: relative;
        border-bottom-width: 2px;
    }

    nav {
        position: sticky;
        top: 0;
    }

    body {
        padding-top: 0;
    }

    /* Header compact sur une seule ligne */
    .header-content {
        flex-direction: row;
        justify-content: space-between;
        align-items: center;
        padding: 10px 15px;
        gap: 12px;
    }

    .header-left {
        flex-direction: row;
        align-items: center;
        text-align: left;
        gap: 10px;
        min-width: 0;
    }

    .logo-image {
        width: 44px;
        height: 44px;
        flex-shrink: 0;
    }

    .logo-section h1 {
        font-size: 1.05em;
        letter-spacing: 2px;
    }

    .logo-section h2 {
        font-size: 0.65em;
        letter-spacing: 1px;
        margin-top: 2px;
    }

    .header-right {
        flex-direction: column;
        align-items: flex-end;
        gap: 6px;
        flex-shrink: 0;
    }

    .lang-switcher {
        gap: 5px;
    }

    .lang-link {
        padding: 3px 8px;
        font-size: 0.72em;
    }

    .header-badges {
        flex-direction: row;
        gap: 6px;
    }

    .badge {
        padding: 3px 7px;
        font-size: 0.62em;
    }

    .hamburger {
        display: block;
        font-size: 1.5em;
        padding: 8px;
    }

    nav ul {
        display: none;
        flex-direction: column;
        width: 100%;
    }

    nav ul.active {
        display: flex;
    }

    nav ul li {
        width: 100%;
        text-align: center;
    }

    nav ul li a {
        padding: 15px;
    }

    .nav-container {
        padding: 0 20px;
    }

    section {
        padding: 50px 0;
    }

    section h2 {
        font-size: 2em;
        background-position: center center;
    }

    .hero h3 {
        font-size: 2em;
    }

    .machines-grid,
    .materials-grid,
    .vision-highlights,
    .contact-grid,
    .products-grid {
        grid-template-columns: 1fr;
        gap: 25px;
    }

    .priority-grid {
        grid-template-columns: 1fr;
    }

    .founder-content {
        padding: 25px;
    }

    .gallery-nav.prev {
        left: 10px;
    }

    .gallery-nav.next {
        right: 10px;
    }

    .gallery-close {
        right: 20px;
        top: 20px;
        font-size: 35px;
    }

    .form-row {
        grid-template-columns: 1fr;
        gap: 0;
    }

    .contact-form {
        padding: 25px;
    }
}

@media (max-width: 480px) {
    body {
        padding-top: 0;
    }

    .header-content {
        padding: 8px 12px;
        gap: 8px;
    }

    .logo-image {
        width: 38px;
        height: 38px;
    }

    .logo-section h1 {
        font-size: 0.85em;
        letter-spacing: 1px;
    }

    .logo-section h2 {
        font-size: 0.55em;
        letter-spacing: 0.5px;
    }

    .lang-link {
        padding: 2px 6px;
        font-size: 0.65em;
    }

    .badge {
        padding: 2px 5px;
        font-size: 0.55em;
    }

    section h2 {
        font-size: 1.6em;
        padding: 30px 15px;
    }

    .hero h3 {
        font-size: 1.6em;
    }

    .priority-card {
        padding: 25px;
    }
}

/* Animation smooth lors du scroll avec menu sticky */
html {
    scroll-behavior: smooth;
}

/* Style amélioré pour le menu sticky sur mobile */
@media (max-width: 768px) {
    .hamburger {
        position: relative;
        z-index: 1001;
    }
    
    nav ul.active {
        position: absolute;
        top: 100%;
        left: 0;
        right: 0;
        background: var(--black);
        box-shadow: 0 5px 15px rgba(0, 0, 0, 0.5);
    }
}
