/* ===== SELECTION ===== */
::selection,
::-moz-selection {
    background: rgba(201, 184, 154, 0.35);
    color: #f4f4f5;
}

/* ===== SCROLLBAR ===== */
::-webkit-scrollbar { width: 6px; }
::-webkit-scrollbar-track { background: #000; }
::-webkit-scrollbar-thumb {
    background: #2a2a2a;
    border-radius: 3px;
    &:hover { background: #4a4a4a; }
}

/* ===== BASE ===== */
html {
    background-color: #000;
    scroll-behavior: smooth;
    overflow-x: hidden;
}

body {
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    overflow-x: hidden;
}

/* ===== COMPONENTS ===== */

#hero-video {
    will-change: transform, opacity;
    transform: translateZ(0);
}

[data-reveal] img {
    will-change: transform, filter;
}

.divider {
    width: 60px;
    height: 1px;
    background: linear-gradient(90deg, transparent, #a1a1aa, transparent);
}

.spec-card {
    border: 1px solid rgba(161, 161, 170, 0.12);
    transition: border-color 0.4s ease, box-shadow 0.4s ease, transform 0.6s ease;
    transform-style: preserve-3d;

    &:hover,
    &:active {
        border-color: rgba(161, 161, 170, 0.4);
        box-shadow: 0 0 30px rgba(161, 161, 170, 0.06);
        will-change: transform;
    }
}

.section-sep {
    width: 100%;
    height: 1px;
    background: linear-gradient(90deg, transparent 0%, rgba(161, 161, 170, 0.25) 50%, transparent 100%);
    margin: 0 auto;
}

.nav-link {
    position: relative;
    color: rgba(244, 244, 245, 0.5);
    transition: color 0.3s;

    &::after {
        content: '';
        position: absolute;
        bottom: -2px;
        left: 0;
        width: 0;
        height: 1px;
        background: #c9b89a;
        transition: width 0.35s ease;
    }

    &:hover,
    &.active {
        color: #f4f4f5;
        &::after { width: 100%; }
    }
}

.section-dot {
    &.active {
        & .dot-circle {
            background: #c9b89a;
            border-color: #c9b89a;
            box-shadow: 0 0 8px rgba(201, 184, 154, 0.6);
            transform: scale(1.4);
        }
        & .dot-label {
            color: rgba(201, 184, 154, 0.8) !important;
        }
    }
}

.word-mask {
    display: block;
    overflow: hidden;
    line-height: 1.15;
}

/* ===== PRELOADER ===== */
.preloader-logo {
    opacity: 0;
    animation: preloaderFadeIn 0.9s ease-out 0.25s forwards;
}

.preloader-line {
    width: 160px;
    height: 1px;
    background: linear-gradient(90deg, transparent, #c9b89a 50%, transparent);
    transform: scaleX(0);
    transform-origin: left;
    animation: preloaderLineExpand 0.55s ease-out 0.85s forwards;
}

.preloader-sub {
    opacity: 0;
    animation: preloaderFadeIn 0.5s ease-out 1.2s forwards;
}

@keyframes preloaderFadeIn {
    to { opacity: 1; }
}

@keyframes preloaderLineExpand {
    to { transform: scaleX(1); }
}

/* ===== WAVEFORM ===== */
.waveform-container {
    & .bar {
        will-change: transform;
        transform-origin: bottom;
    }

    &.playing {
        opacity: 1 !important;

        & .bar {
            height: 16px;
            animation: waveform 0.6s ease-in-out infinite alternate;

            &:nth-child(1) { animation-delay: 0.1s; }
            &:nth-child(2) { animation-delay: 0.3s; }
            &:nth-child(3) { animation-delay: 0s; }
            &:nth-child(4) { animation-delay: 0.4s; }
            &:nth-child(5) { animation-delay: 0.2s; }
        }
    }
}

@keyframes waveform {
    0%   { transform: scaleY(0.25); }
    100% { transform: scaleY(1); }
}

/* ===== DECORATIVE ===== */
.deco-question {
    &::before {
        content: "?";
        font-family: 'Playfair Display', serif;
        font-size: 30vw;
        color: rgba(255, 255, 255, 0.012);
        line-height: 1;
        letter-spacing: -0.05em;
        pointer-events: none;
        user-select: none;
    }
}

.deco-01 {
    &::before {
        content: "01";
        font-family: 'Playfair Display', serif;
        font-weight: 300;
        font-size: 20vw;
        color: rgba(255, 255, 255, 0.015);
        line-height: 1;
        letter-spacing: -0.05em;
        pointer-events: none;
        user-select: none;
    }
}

/* ===== TAILWIND CUSTOM UTILITIES ===== */

.bg-bugatti-black     { background-color: #000; }
.bg-bugatti-dark      { background-color: #0a0a0a; }
.bg-bugatti-light     { background-color: #f4f4f5; }
.bg-bugatti-accent    { background-color: #a1a1aa; }
.bg-bugatti-gold      { background-color: #c9b89a; }
.bg-bugatti-black\/85 { background-color: rgba(0, 0, 0, 0.85); }
.bg-bugatti-gold\/10  { background-color: rgba(201, 184, 154, 0.1); }

.text-bugatti-black  { color: #000; }
.text-bugatti-dark   { color: #0a0a0a; }
.text-bugatti-light  { color: #f4f4f5; }
.text-bugatti-accent { color: #a1a1aa; }
.text-bugatti-gold   { color: #c9b89a; }

.text-bugatti-accent\/0  { color: rgba(161, 161, 170, 0); }
.text-bugatti-accent\/50 { color: rgba(161, 161, 170, 0.5); }
.text-bugatti-accent\/60 { color: rgba(161, 161, 170, 0.6); }
.text-bugatti-accent\/70 { color: rgba(161, 161, 170, 0.7); }
.text-bugatti-accent\/80 { color: rgba(161, 161, 170, 0.8); }

.text-bugatti-gold\/50 { color: rgba(201, 184, 154, 0.5); }
.text-bugatti-gold\/60 { color: rgba(201, 184, 154, 0.6); }
.text-bugatti-gold\/75 { color: rgba(201, 184, 154, 0.75); }
.text-bugatti-gold\/80 { color: rgba(201, 184, 154, 0.8); }
.text-bugatti-gold\/85 { color: rgba(201, 184, 154, 0.85); }

.border-bugatti-black  { border-color: #000; }
.border-bugatti-dark   { border-color: #0a0a0a; }
.border-bugatti-light  { border-color: #f4f4f5; }
.border-bugatti-accent { border-color: #a1a1aa; }
.border-bugatti-gold   { border-color: #c9b89a; }

.border-bugatti-accent\/20 { border-color: rgba(161, 161, 170, 0.2); }
.border-bugatti-accent\/30 { border-color: rgba(161, 161, 170, 0.3); }
.border-bugatti-gold\/30   { border-color: rgba(201, 184, 154, 0.3); }
.border-bugatti-gold\/40   { border-color: rgba(201, 184, 154, 0.4); }

.font-sans { font-family: 'Inter', sans-serif; }
.font-serif { font-family: 'Playfair Display', serif; }

.tracking-widest   { letter-spacing: 0.25em; }
.tracking-widest-2 { letter-spacing: 0.35em; }

.shadow-bugatti-gold\/30 {
    --tw-shadow: 0 10px 15px -3px rgba(201, 184, 154, 0.3), 0 4px 6px -4px rgba(201, 184, 154, 0.3);
    --tw-shadow-colored: 0 10px 15px -3px var(--tw-shadow-color), 0 4px 6px -4px var(--tw-shadow-color);
    box-shadow: var(--tw-ring-offset-shadow, 0 0 #0000), var(--tw-ring-shadow, 0 0 #0000), var(--tw-shadow);
}

.group:hover {
    & .group-hover\:text-bugatti-accent   { color: #a1a1aa; }
    & .group-hover\:text-bugatti-gold     { color: #c9b89a; }
    & .group-hover\:text-bugatti-gold\/70 { color: rgba(201, 184, 154, 0.7); }
    & .group-hover\:bg-bugatti-gold       { background-color: #c9b89a; }
}

/* ===== LAYOUT ===== */

.video-section {
    height: 100vh !important;
    height: 100dvh !important;

    @media (min-width: 1024px) {
        height: 400vh !important;
    }
}

#compare-slider {
    height: 40vh;
    touch-action: pan-y;

    @media (min-width: 640px)  { height: 50vh; }
    @media (min-width: 768px)  { height: 60vh; }
    @media (min-width: 1024px) { height: 75vh; }

    @media (max-width: 425px) {
        height: 52vw !important;
        min-height: 200px;
    }
}

/* ===== SECTION-SPECIFIC RESPONSIVE ===== */

#heritage-timeline {
    @media (max-width: 1023px) {
        & .wrap { padding: 0.5rem; }

        & .timeline-track {
            left: 16px;
            transform: none;
            width: 28px;
        }

        & .right-timeline,
        & .left-timeline {
            flex-direction: row !important;
            justify-content: flex-start !important;
            padding-left: 44px;
        }

        & .right-timeline > div:first-child,
        & .left-timeline > div:first-child {
            display: none;
        }

        & .spec-card {
            width: 100% !important;
            text-align: left !important;
        }

        & .right-timeline > div:nth-child(2),
        & .left-timeline > div:nth-child(2) {
            width: 20px;
            flex-shrink: 0;
        }
    }
}

#heart img {
    @media (max-width: 425px) {
        min-height: 260px !important;
        max-height: 320px;
    }
}

#car-approach {
    @media (max-width: 425px) {
        height: 50vw !important;
        min-height: 200px;
    }
}

#perf-grid {
    @media (max-width: 767px) {
        & .spec-card { padding: 1.5rem; }
    }

    @media (max-width: 379px) {
        & .spec-card {
            padding: 1.1rem;
            & .font-serif { font-size: 1.65rem; line-height: 1; }
        }
    }
}

#icon,
#heart,
#artiste {
    @media (min-width: 1024px) and (max-width: 1199px) {
        & h2 {
            font-size: 3rem;
            line-height: 1.1;
        }
        & .max-w-7xl { gap: 3rem; }
    }
}

#section-dots {
    @media (min-width: 1024px) and (max-width: 1199px) {
        & .dot-label { display: none; }
    }
}

/* ===== MOBILE UTILITY OVERRIDES ===== */
@media (max-width: 767px) {
    .py-32 { padding-top: 4.5rem; padding-bottom: 4.5rem; }
    .py-24 { padding-top: 4rem;   padding-bottom: 4rem; }
    blockquote { padding-left: 1.25rem; }
}

/* ===== MISSING TAILWIND UTILITIES ===== */

@media (min-width: 1024px) {
    .lg\:flex          { display: flex; }
    .lg\:inline-block  { display: inline-block; }
    .lg\:hidden        { display: none; }
    .lg\:flex-row      { flex-direction: row; }
    .lg\:justify-between { justify-content: space-between; }
    .lg\:gap-4         { gap: 1rem; }
    .lg\:gap-24        { gap: 6rem; }
    .lg\:text-right    { text-align: right; }
    .lg\:grid-cols-12  { grid-template-columns: repeat(12, minmax(0, 1fr)); }
    .lg\:col-span-5    { grid-column: span 5 / span 5; }
    .lg\:col-span-6    { grid-column: span 6 / span 6; }
    .lg\:col-span-7    { grid-column: span 7 / span 7; }
    .lg\:py-48         { padding-top: 12rem; padding-bottom: 12rem; }
    .lg\:px-20         { padding-left: 5rem; padding-right: 5rem; }
    .lg\:order-1       { order: 1; }
    .lg\:order-2       { order: 2; }
    .lg\:p-6           { padding: 1.5rem; }
}

@media (min-width: 640px) {
    .sm\:w-auto        { width: auto; }
    .sm\:px-12         { padding-left: 3rem; padding-right: 3rem; }
    .sm\:py-10         { padding-top: 2.5rem; padding-bottom: 2.5rem; }
    .sm\:text-4xl      { font-size: 2.25rem; line-height: 2.5rem; }
    .sm\:text-\[10px\] { font-size: 10px; }
    .sm\:text-xs       { font-size: 0.75rem; line-height: 1rem; }
}
