/* ============================================================
   CVR Auto — Premium EV (India)
   Design tokens, layout, components.
   ============================================================ */

:root {
    --bg: #0a0a0c;
    --bg-elev: #111114;
    --bg-elev-2: #16161a;
    --line: rgba(255, 255, 255, 0.08);
    --line-strong: rgba(255, 255, 255, 0.16);
    --text: #f5f5f7;
    --text-dim: #a1a1aa;
    --text-mute: #6b6b73;
    --accent: #d6d6dc;
    --accent-2: #8a8a93;
    --silver-grad: linear-gradient(180deg, #ffffff 0%, #c7c7cf 45%, #6b6b73 100%);
    --max-w: 1320px;
    --pad-x: clamp(20px, 4vw, 56px);
    --nav-h: 72px;
    --r-sm: 6px;
    --r-md: 10px;
    --r-lg: 18px;
    --ease: cubic-bezier(0.22, 1, 0.36, 1);
    --t-fast: 200ms;
    --t-med: 380ms;
    --t-slow: 700ms;
}

* {
    box-sizing: border-box;
}

html, body {
    margin: 0;
    padding: 0;
    background: var(--bg);
    color: var(--text);
    font-family: "Helvetica Neue", "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
    font-weight: 400;
    line-height: 1.55;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    overflow-x: hidden;
}

img {
    max-width: 100%;
    height: auto;
    display: block;
}

a {
    color: inherit;
    text-decoration: none;
    transition: color var(--t-fast) var(--ease);
}

a:hover {
    color: #fff;
}

button {
    font-family: inherit;
    cursor: pointer;
    border: none;
    background: none;
    color: inherit;
}

/* ---------- Type ---------- */

h1, h2, h3, h4 {
    margin: 0 0 0.5em;
    font-weight: 300;
    letter-spacing: -0.02em;
    line-height: 1.1;
}

h1 {
    font-size: clamp(40px, 7vw, 92px);
    font-weight: 200;
}

h2 {
    font-size: clamp(28px, 4.2vw, 56px);
}

h3 {
    font-size: clamp(20px, 2.2vw, 28px);
    font-weight: 400;
}

p {
    color: var(--text-dim);
    font-size: clamp(15px, 1.1vw, 17px);
    max-width: 60ch;
}

.eyebrow {
    font-size: 12px;
    letter-spacing: 0.25em;
    text-transform: uppercase;
    color: var(--text-mute);
    margin-bottom: 16px;
    font-weight: 500;
}

.silver-text {
    background: var(--silver-grad);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    color: transparent;
}

/* ---------- Layout ---------- */

.container {
    max-width: var(--max-w);
    margin: 0 auto;
    padding-left: var(--pad-x);
    padding-right: var(--pad-x);
}

section {
    padding: clamp(64px, 10vw, 140px) 0;
}

.section-head {
    margin-bottom: 56px;
    max-width: 720px;
}

/* ---------- Navigation ---------- */

.nav {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    height: var(--nav-h);
    z-index: 100;
    display: flex;
    align-items: center;
    background: rgba(10, 10, 12, 0.6);
    backdrop-filter: saturate(160%) blur(16px);
    -webkit-backdrop-filter: saturate(160%) blur(16px);
    border-bottom: 1px solid var(--line);
    transition: background var(--t-med) var(--ease);
}

.nav.is-scrolled {
    background: rgba(10, 10, 12, 0.92);
}

.nav .container {
    width: 100%;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 32px;
}

.nav-brand {
    display: flex;
    align-items: center;
    gap: 10px;
    flex-shrink: 0;
}

.nav-brand img {
    height: 28px;
    width: auto;
}

.nav-brand-text {
    font-size: 13px;
    letter-spacing: 0.35em;
    font-weight: 500;
    color: var(--text);
    text-transform: uppercase;
}

.nav-links {
    display: flex;
    align-items: center;
    gap: 36px;
    list-style: none;
    margin: 0;
    padding: 0;
}

.nav-links a {
    font-size: 14px;
    letter-spacing: 0.04em;
    color: var(--text-dim);
    position: relative;
    padding: 8px 0;
}

.nav-links a.active,
.nav-links a:hover {
    color: var(--text);
}

.nav-links a.active::after {
    content: "";
    position: absolute;
    left: 0;
    right: 0;
    bottom: 0;
    height: 1px;
    background: var(--text);
}

.nav-cta {
    display: inline-flex;
    align-items: center;
    padding: 10px 22px;
    border: 1px solid var(--line-strong);
    border-radius: 999px;
    font-size: 13px;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    transition: all var(--t-fast) var(--ease);
}

.nav-cta:hover {
    background: var(--text);
    color: var(--bg);
    border-color: var(--text);
}

.nav-toggle {
    display: none;
    width: 32px;
    height: 32px;
    position: relative;
}

.nav-toggle span {
    position: absolute;
    left: 4px;
    right: 4px;
    height: 1.5px;
    background: var(--text);
    transition: transform var(--t-fast) var(--ease), opacity var(--t-fast) var(--ease);
}

.nav-toggle span:nth-child(1) { top: 11px; }
.nav-toggle span:nth-child(2) { top: 20px; }

.nav.is-open .nav-toggle span:nth-child(1) { transform: translateY(4px) rotate(45deg); }
.nav.is-open .nav-toggle span:nth-child(2) { transform: translateY(-5px) rotate(-45deg); }

@media (max-width: 880px) {
    .nav-toggle {
        display: block;
    }
    .nav-links {
        position: fixed;
        top: var(--nav-h);
        left: 0;
        right: 0;
        background: var(--bg);
        border-bottom: 1px solid var(--line);
        flex-direction: column;
        gap: 0;
        padding: 16px 0;
        transform: translateY(-150%);
        visibility: hidden;
        opacity: 0;
        transition: transform var(--t-med) var(--ease), opacity var(--t-fast) var(--ease), visibility 0s linear var(--t-med);
    }
    .nav.is-open .nav-links {
        transform: translateY(0);
        visibility: visible;
        opacity: 1;
        transition: transform var(--t-med) var(--ease), opacity var(--t-fast) var(--ease), visibility 0s linear 0s;
    }
    .nav-links li {
        width: 100%;
    }
    .nav-links a {
        display: block;
        padding: 16px var(--pad-x);
        font-size: 16px;
    }
    .nav-links a.active::after {
        display: none;
    }
    .nav-cta {
        display: none;
    }
    .nav-brand img {
        height: 32px;
    }
    .nav-brand-text {
        font-size: 12px;
        letter-spacing: 0.3em;
    }
}

/* Smaller phones: tighten hero copy and stack CTAs */
@media (max-width: 640px) {
    h1 { font-size: 38px; }
    .hero {
        padding-top: calc(var(--nav-h) + 32px);
        padding-bottom: 48px;
    }
    .hero h1 { font-size: 40px; line-height: 1.05; }
    .hero p.lede { font-size: 15px; }
    .btn-row { flex-direction: column; align-items: stretch; gap: 12px; }
    .btn-row .btn { width: 100%; }
    section { padding: 56px 0; }
    .section-head { margin-bottom: 32px; }
}

/* ---------- Buttons ---------- */

.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    padding: 14px 32px;
    border-radius: 999px;
    font-size: 14px;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    font-weight: 500;
    transition: all var(--t-fast) var(--ease);
    border: 1px solid transparent;
    cursor: pointer;
}

.btn-primary {
    background: var(--text);
    color: var(--bg);
}

.btn-primary:hover {
    background: #fff;
    color: var(--bg);
    transform: translateY(-1px);
}

.btn-ghost {
    background: transparent;
    color: var(--text);
    border-color: var(--line-strong);
}

.btn-ghost:hover {
    border-color: var(--text);
    background: rgba(255, 255, 255, 0.04);
}

.btn-row {
    display: flex;
    flex-wrap: wrap;
    gap: 14px;
    margin-top: 32px;
}

/* ---------- Hero ---------- */
/*
   Layout (desktop): car image sits in the right ~58% of the viewport.
   A gradient OVERLAY on the image's left edge fades it into the dark page
   background — the image visually "merges" into the dark text area on the
   left. The hero background is solid dark, so the text region is pure
   contrast (no car bleeding through).
*/

.hero {
    min-height: 100vh;
    min-height: 100svh;
    position: relative;
    display: flex;
    align-items: center;
    padding-top: var(--nav-h);
    overflow: hidden;
    background: var(--bg);
}

.hero-bg {
    position: absolute;
    top: 0;
    right: 0;
    bottom: 0;
    width: 58%;
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    z-index: 0;
}

/* The merge: dark gradient overlay on the LEFT of the image div,
   fading to transparent across ~45% of the image's width. */
.hero-bg::after {
    content: "";
    position: absolute;
    inset: 0;
    background:
        linear-gradient(90deg,
            var(--bg) 0%,
            var(--bg) 6%,
            rgba(10, 10, 12, 0.92) 14%,
            rgba(10, 10, 12, 0.55) 28%,
            rgba(10, 10, 12, 0.18) 42%,
            transparent 55%),
        linear-gradient(180deg,
            rgba(10, 10, 12, 0.45) 0%,
            transparent 22%,
            transparent 80%,
            rgba(10, 10, 12, 0.6) 100%);
    pointer-events: none;
}

.hero .container {
    position: relative;
    z-index: 1;
    width: 100%;
}

.hero-content {
    max-width: 520px;
}

.hero h1 {
    margin-bottom: 24px;
}

.hero p.lede {
    font-size: clamp(16px, 1.4vw, 20px);
    color: var(--text);
    opacity: 0.9;
    max-width: 56ch;
}

.hero-meta {
    position: absolute;
    right: var(--pad-x);
    bottom: 32px;
    text-align: right;
    font-size: 12px;
    letter-spacing: 0.2em;
    text-transform: uppercase;
    color: var(--text-mute);
    z-index: 1;
}

/* Tablets / small desktops: image keeps a clear right-anchor,
   merge zone slightly wider so text stays comfortably on dark. */
@media (max-width: 1100px) {
    .hero-bg { width: 62%; }
}

/* Mobile: stack vertically — image on top with bottom-fade, text below */
@media (max-width: 880px) {
    .hero {
        display: block;
        padding-top: 0;
        padding-bottom: 56px;
        min-height: auto;
    }
    .hero-bg {
        position: relative;
        top: auto;
        right: auto;
        bottom: auto;
        width: 100%;
        height: 48vh;
        min-height: 300px;
        margin-top: var(--nav-h);
        background-position: center;
    }
    .hero-bg::after {
        background: linear-gradient(180deg,
            rgba(10, 10, 12, 0.25) 0%,
            transparent 28%,
            transparent 60%,
            var(--bg) 100%);
    }
    .hero .container {
        padding-top: 32px;
    }
    .hero-meta { display: none; }
}

/* ---------- Page Hero (interior pages) ---------- */

.page-hero {
    padding-top: calc(var(--nav-h) + 80px);
    padding-bottom: 64px;
    border-bottom: 1px solid var(--line);
    background:
        radial-gradient(ellipse at 30% 0%, rgba(255, 255, 255, 0.05) 0%, transparent 55%),
        var(--bg);
}

.page-hero h1 {
    font-size: clamp(36px, 5.5vw, 72px);
    margin-bottom: 20px;
}

.page-hero p {
    font-size: clamp(16px, 1.3vw, 19px);
    color: var(--text-dim);
    max-width: 60ch;
}

/* ---------- Lineup Strip ---------- */

.lineup-strip {
    position: relative;
    padding: 0;
}

.lineup-strip img {
    width: 100%;
    height: auto;
    display: block;
}

.lineup-strip-wrap {
    position: relative;
}

.lineup-strip-wrap::after {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(180deg, rgba(10, 10, 12, 0.4) 0%, transparent 30%, transparent 70%, rgba(10, 10, 12, 0.6) 100%);
    pointer-events: none;
}

/* ---------- Feature Grid ---------- */

.feature-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
    gap: 1px;
    background: var(--line);
    border: 1px solid var(--line);
}

.feature-cell {
    background: var(--bg);
    padding: 40px 32px;
    min-height: 240px;
}

.feature-cell .num {
    font-size: 12px;
    color: var(--text-mute);
    letter-spacing: 0.2em;
    margin-bottom: 24px;
}

.feature-cell h3 {
    margin-bottom: 12px;
}

.feature-cell p {
    font-size: 14px;
    line-height: 1.6;
}

/* ---------- Spec Grid ---------- */

.spec-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
    gap: 1px;
    background: var(--line);
    border: 1px solid var(--line);
    margin: 48px 0;
}

.spec-cell {
    background: var(--bg);
    padding: 32px 24px;
    text-align: left;
}

.spec-cell .val {
    font-size: clamp(28px, 3.5vw, 44px);
    font-weight: 200;
    letter-spacing: -0.02em;
    margin-bottom: 8px;
    color: var(--text);
}

.spec-cell .lbl {
    font-size: 11px;
    color: var(--text-mute);
    letter-spacing: 0.18em;
    text-transform: uppercase;
}

/* ---------- Two-col content ---------- */

.split {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: clamp(40px, 6vw, 80px);
    align-items: center;
}

@media (max-width: 880px) {
    .split { grid-template-columns: 1fr; }
}

.split-media {
    border-radius: var(--r-lg);
    overflow: hidden;
    background: var(--bg-elev);
    border: 1px solid var(--line);
}

.split-media img {
    width: 100%;
    display: block;
}

/* ---------- Model Cards ---------- */

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

.model-card {
    background: var(--bg-elev);
    border: 1px solid var(--line);
    border-radius: var(--r-lg);
    padding: 32px 28px;
    display: flex;
    flex-direction: column;
    gap: 12px;
    transition: border-color var(--t-fast) var(--ease), transform var(--t-fast) var(--ease);
}

.model-card:hover {
    border-color: var(--line-strong);
    transform: translateY(-2px);
}

.model-card .badge {
    display: inline-block;
    font-size: 10px;
    letter-spacing: 0.22em;
    text-transform: uppercase;
    color: var(--text-mute);
    border: 1px solid var(--line-strong);
    padding: 4px 10px;
    border-radius: 999px;
    width: fit-content;
    margin-bottom: 8px;
}

.model-card h3 {
    font-size: 26px;
    margin: 0;
}

.model-card .price {
    font-size: 14px;
    color: var(--text-dim);
}

/* ---------- Form ---------- */

.form-wrap {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: clamp(40px, 6vw, 96px);
    align-items: start;
}

@media (max-width: 880px) {
    .form-wrap { grid-template-columns: 1fr; }
}

.form-aside h2 { margin-bottom: 20px; }
.form-aside ul {
    list-style: none;
    margin: 32px 0 0;
    padding: 0;
}
.form-aside li {
    padding: 14px 0;
    border-top: 1px solid var(--line);
    color: var(--text-dim);
    font-size: 14px;
    display: flex;
    gap: 14px;
}
.form-aside li::before {
    content: "—";
    color: var(--text-mute);
}

form.reserve {
    display: flex;
    flex-direction: column;
    gap: 18px;
}

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

.field label {
    font-size: 11px;
    letter-spacing: 0.18em;
    text-transform: uppercase;
    color: var(--text-mute);
}

.field input,
.field select,
.field textarea {
    background: var(--bg-elev);
    border: 1px solid var(--line);
    border-radius: var(--r-md);
    padding: 14px 16px;
    color: var(--text);
    font-family: inherit;
    font-size: 15px;
    transition: border-color var(--t-fast) var(--ease), background var(--t-fast) var(--ease);
}

.field input:focus,
.field select:focus,
.field textarea:focus {
    outline: none;
    border-color: var(--text);
    background: var(--bg-elev-2);
}

.field textarea {
    min-height: 110px;
    resize: vertical;
}

.field-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 18px;
}

@media (max-width: 600px) {
    .field-row { grid-template-columns: 1fr; }
}

.form-notice {
    font-size: 12px;
    color: var(--text-mute);
    line-height: 1.6;
}

.form-status {
    padding: 14px 18px;
    border-radius: var(--r-md);
    font-size: 14px;
    margin-top: 8px;
    display: none;
}

.form-status.ok {
    display: block;
    background: rgba(80, 200, 130, 0.08);
    border: 1px solid rgba(80, 200, 130, 0.3);
    color: #cdeed9;
}

.form-status.err {
    display: block;
    background: rgba(220, 80, 80, 0.08);
    border: 1px solid rgba(220, 80, 80, 0.3);
    color: #f0c7c7;
}

/* ---------- Footer ---------- */

.footer {
    border-top: 1px solid var(--line);
    padding: 64px 0 40px;
    background: #08080a;
}

.footer-grid {
    display: grid;
    grid-template-columns: 1.4fr 1fr 1fr 1fr;
    gap: 40px;
    margin-bottom: 48px;
}

@media (max-width: 720px) {
    .footer-grid { grid-template-columns: 1fr 1fr; }
}

.footer h4 {
    font-size: 11px;
    letter-spacing: 0.2em;
    text-transform: uppercase;
    color: var(--text-mute);
    margin-bottom: 18px;
    font-weight: 500;
}

.footer ul {
    list-style: none;
    margin: 0;
    padding: 0;
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.footer a {
    font-size: 14px;
    color: var(--text-dim);
}

.footer-brand img {
    height: 36px;
    width: auto;
    margin-bottom: 16px;
}

.footer-brand p {
    font-size: 13px;
    max-width: 30ch;
}

.footer-bottom {
    border-top: 1px solid var(--line);
    padding-top: 24px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 12px;
    font-size: 12px;
    color: var(--text-mute);
    letter-spacing: 0.05em;
}

/* ---------- Reveal on scroll ---------- */

.reveal {
    opacity: 0;
    transform: translateY(24px);
    transition: opacity var(--t-slow) var(--ease), transform var(--t-slow) var(--ease);
}

.reveal.is-visible {
    opacity: 1;
    transform: translateY(0);
}

@media (prefers-reduced-motion: reduce) {
    .reveal { opacity: 1; transform: none; transition: none; }
    * { animation: none !important; transition: none !important; }
}
