/* ===== RESET & TOKENS ===== */
*, *::before, *::after { margin: 0; padding: 0; box-sizing: border-box; }

:root {
    --bg: #0c0c0d;
    --bg-soft: #141416;
    --fg: #f2f0ec;
    --muted: #8a8782;
    --accent: #ff5a1f;
    --accent-2: #ffb347;
    --line: rgba(255,255,255,0.08);
    --font-display: 'Archivo', sans-serif;
    --font-body: 'Inter', sans-serif;
}

html { scroll-behavior: auto; }
body {
    background: var(--bg);
    color: var(--fg);
    font-family: var(--font-body);
    font-weight: 300;
    line-height: 1.5;
    overflow-x: hidden;
    -webkit-font-smoothing: antialiased;
}
a { color: inherit; text-decoration: none; }
img { display: block; max-width: 100%; }
.eyebrow {
    font-family: var(--font-body);
    font-size: 0.78rem;
    letter-spacing: 0.25em;
    text-transform: uppercase;
    color: var(--accent);
    margin-bottom: 1.2rem;
}

/* ===== LOADER ===== */
.loader {
    position: fixed;
    inset: 0;
    z-index: 1000;
    background: var(--bg);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 1.5rem;
}
.loader-logo {
    font-family: var(--font-display);
    font-weight: 900;
    font-size: clamp(3rem, 12vw, 7rem);
    letter-spacing: -0.04em;
    color: var(--fg);
}
.loader-bar {
    width: 180px;
    height: 2px;
    background: var(--line);
    overflow: hidden;
}
.loader-bar span {
    display: block;
    height: 100%;
    width: 0%;
    background: var(--accent);
}

/* ===== SCROLL PROGRESS ===== */
.scroll-progress {
    position: fixed;
    top: 0; left: 0;
    height: 3px;
    width: 0%;
    background: linear-gradient(90deg, var(--accent), var(--accent-2));
    z-index: 200;
}

/* ===== NAV ===== */
.nav {
    position: fixed;
    top: 0; left: 0; right: 0;
    z-index: 150;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 1.4rem clamp(1.2rem, 4vw, 3.5rem);
    mix-blend-mode: difference;
}
.nav-brand img { height: 34px; width: auto; }
.nav-brand { font-family: var(--font-display); font-weight: 900; letter-spacing: -0.02em; }
.nav-links { display: flex; gap: 2rem; }
.nav-links a {
    font-size: 0.85rem;
    letter-spacing: 0.02em;
    position: relative;
    padding: 4px 0;
}
.nav-links a::after {
    content: '';
    position: absolute;
    left: 0; bottom: 0;
    width: 0; height: 1px;
    background: var(--fg);
    transition: width 0.35s ease;
}
.nav-links a:hover::after { width: 100%; }
.nav-cta {
    font-size: 0.85rem;
    border: 1px solid var(--fg);
    padding: 0.5rem 1.2rem;
    border-radius: 100px;
    transition: background 0.3s, color 0.3s;
}
.nav-cta:hover { background: var(--fg); color: var(--bg); }

/* ===== BUTTONS ===== */
.btn {
    display: inline-flex;
    align-items: center;
    gap: 0.6rem;
    font-family: var(--font-body);
    font-weight: 500;
    font-size: 0.95rem;
    padding: 0.95rem 1.8rem;
    border-radius: 100px;
    cursor: pointer;
    transition: transform 0.3s ease, background 0.3s ease, color 0.3s ease;
}
.btn-primary { background: var(--accent); color: #fff; }
.btn-primary:hover { background: var(--accent-2); color: #1a1a1a; transform: translateY(-2px); }
.btn-ghost { border: 1px solid var(--line); color: var(--fg); }
.btn-ghost:hover { border-color: var(--fg); transform: translateY(-2px); }
.btn-lg { padding: 1.2rem 2.6rem; font-size: 1.05rem; }

/* ===== HERO ===== */
.hero {
    position: relative;
    height: 100vh;
    min-height: 640px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    padding: 0 clamp(1.2rem, 4vw, 3.5rem);
    overflow: hidden;
}
.hero-bg {
    position: absolute;
    inset: -10% 0 -10% 0;
    background: url('assets/images/hero-offroad-new.jpg') center/cover no-repeat;
    z-index: -2;
    will-change: transform;
}
.hero::before {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(180deg, rgba(12,12,13,0.55) 0%, rgba(12,12,13,0.35) 40%, rgba(12,12,13,0.95) 100%);
    z-index: -1;
}
.hero-grain {
    position: absolute;
    inset: 0;
    opacity: 0.05;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='100' height='100'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
    z-index: -1;
    pointer-events: none;
}
.hero-kicker {
    font-size: 0.8rem;
    letter-spacing: 0.25em;
    text-transform: uppercase;
    color: var(--accent-2);
    margin-bottom: 1.5rem;
}
.hero-title {
    font-family: var(--font-display);
    font-weight: 900;
    font-size: clamp(3rem, 13vw, 11rem);
    line-height: 0.92;
    letter-spacing: -0.04em;
    text-transform: uppercase;
}
.hero-title .line { display: block; overflow: hidden; }
.hero-title .line span { display: block; }
.hero-sub {
    max-width: 460px;
    margin-top: 2rem;
    color: var(--muted);
    font-size: 1.05rem;
}
.hero-actions { display: flex; gap: 1rem; margin-top: 2rem; flex-wrap: wrap; }
.hero-scroll {
    position: absolute;
    bottom: 2rem;
    right: clamp(1.2rem, 4vw, 3.5rem);
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.8rem;
    font-size: 0.72rem;
    letter-spacing: 0.2em;
    text-transform: uppercase;
    color: var(--muted);
}
.hero-scroll-line {
    width: 1px;
    height: 60px;
    background: linear-gradient(var(--accent), transparent);
}

/* ===== MARQUEE ===== */
.marquee {
    border-top: 1px solid var(--line);
    border-bottom: 1px solid var(--line);
    overflow: hidden;
    padding: 1.4rem 0;
    background: var(--bg-soft);
}
.marquee-track {
    display: flex;
    align-items: center;
    gap: 2.5rem;
    white-space: nowrap;
    width: max-content;
    will-change: transform;
}
.marquee-track span {
    font-family: var(--font-display);
    font-weight: 800;
    font-size: clamp(1.2rem, 3vw, 2rem);
    letter-spacing: -0.01em;
}
.marquee-track i { color: var(--accent); font-style: normal; }

/* ===== INTRO ===== */
.intro {
    padding: clamp(6rem, 14vw, 12rem) clamp(1.2rem, 6vw, 6rem);
    max-width: 1400px;
    margin: 0 auto;
}
.intro-text {
    font-family: var(--font-display);
    font-weight: 600;
    font-size: clamp(1.6rem, 4.5vw, 3.4rem);
    line-height: 1.18;
    letter-spacing: -0.02em;
    max-width: 16ch;
}
.intro-text .word { display: inline-block; }
.stats {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 2rem;
    margin-top: clamp(3rem, 8vw, 6rem);
    border-top: 1px solid var(--line);
    padding-top: 3rem;
}
.stat { display: flex; flex-direction: column; gap: 0.4rem; }
.stat-num {
    font-family: var(--font-display);
    font-weight: 900;
    font-size: clamp(2rem, 6vw, 4rem);
    letter-spacing: -0.03em;
    color: var(--accent);
}
.stat-label { font-size: 0.8rem; letter-spacing: 0.1em; text-transform: uppercase; color: var(--muted); }

/* ===== CATEGORIAS (carrusel horizontal con flechas) ===== */
.cats {
    background: var(--bg-soft);
    padding: clamp(5rem, 12vw, 10rem) 0;
    overflow: hidden;
}
.cats-head {
    max-width: 1600px;
    margin: 0 auto clamp(2rem, 4vw, 3rem);
    padding: 0 clamp(1.2rem, 5vw, 5rem);
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    gap: 2rem;
    flex-wrap: wrap;
}
.cats-head h2 {
    font-family: var(--font-display);
    font-weight: 900;
    font-size: clamp(2.2rem, 6vw, 4.5rem);
    line-height: 0.95;
    letter-spacing: -0.03em;
    text-transform: uppercase;
}
.cats-controls { display: flex; flex-direction: column; align-items: flex-end; gap: 1rem; }
.cats-hint { color: var(--muted); font-size: 0.85rem; letter-spacing: 0.08em; text-transform: uppercase; }
.cats-arrows { display: flex; gap: 0.8rem; }
.cats-arrow {
    width: 52px;
    height: 52px;
    border-radius: 50%;
    border: 1px solid var(--line);
    background: transparent;
    color: var(--fg);
    font-size: 1.3rem;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background 0.3s, color 0.3s, border-color 0.3s, transform 0.3s, opacity 0.3s;
}
.cats-arrow:hover:not(:disabled) { background: var(--accent); border-color: var(--accent); color: #fff; transform: scale(1.06); }
.cats-arrow:disabled { opacity: 0.3; cursor: default; }

.cats-viewport {
    max-width: 1600px;
    margin: 0 auto;
    padding: 0 clamp(1.2rem, 5vw, 5rem);
    overflow-x: auto;
    overflow-y: hidden;
    scrollbar-width: none;
    -ms-overflow-style: none;
    scroll-behavior: smooth;
    cursor: grab;
}
.cats-viewport::-webkit-scrollbar { display: none; }
.cats-viewport.dragging { cursor: grabbing; scroll-behavior: auto; }
.cats-viewport.dragging .cat-card { pointer-events: none; }
.cats-track {
    display: flex;
    gap: 1.5rem;
    width: max-content;
    padding-bottom: 4px;
}
.cat-card {
    position: relative;
    flex: 0 0 clamp(260px, 26vw, 360px);
    height: clamp(380px, 56vh, 520px);
    border-radius: 14px;
    overflow: hidden;
    background: #1c1c1f;
    cursor: pointer;
}
.cat-card-img {
    position: absolute;
    inset: 0;
    background-size: cover;
    background-position: center;
    transition: transform 0.8s cubic-bezier(0.16,1,0.3,1);
}
.cat-card:hover .cat-card-img { transform: scale(1.08); }
.cat-card::after {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(180deg, transparent 35%, rgba(10,10,11,0.92) 100%);
}
.cat-card-body {
    position: absolute;
    inset: auto 0 0 0;
    padding: 1.6rem;
    z-index: 2;
}
.cat-card-index {
    font-family: var(--font-display);
    font-weight: 800;
    font-size: 0.8rem;
    color: var(--accent-2);
    margin-bottom: 0.5rem;
}
.cat-card-body h3 {
    font-family: var(--font-display);
    font-weight: 800;
    font-size: 1.3rem;
    line-height: 1.05;
    letter-spacing: -0.01em;
    margin-bottom: 0.5rem;
}
.cat-card-body p {
    font-size: 0.85rem;
    color: var(--muted);
    max-height: 0;
    opacity: 0;
    overflow: hidden;
    transition: max-height 0.5s ease, opacity 0.4s ease, margin 0.4s ease;
}
.cat-card:hover .cat-card-body p { max-height: 120px; opacity: 1; margin-top: 0.3rem; }

.cats-progress {
    max-width: 1600px;
    margin: clamp(1.5rem, 3vw, 2.5rem) auto 0;
    padding: 0 clamp(1.2rem, 5vw, 5rem);
    height: 3px;
}
.cats-progress span {
    display: block;
    height: 100%;
    width: 20%;
    background: var(--accent);
    border-radius: 2px;
    transition: width 0.2s linear, transform 0.2s linear;
    transform-origin: left;
}
.cats-progress {
    position: relative;
}
.cats-progress::before {
    content: '';
    position: absolute;
    left: clamp(1.2rem, 5vw, 5rem);
    right: clamp(1.2rem, 5vw, 5rem);
    top: 0;
    height: 100%;
    background: var(--line);
    border-radius: 2px;
}
.cats-progress span { position: relative; z-index: 1; }

/* ===== MANIFIESTO ===== */
.manifesto {
    display: grid;
    grid-template-columns: 1fr 1fr;
    min-height: 100vh;
    align-items: center;
}
.manifesto-media { height: 100%; overflow: hidden; position: relative; }
.manifesto-img {
    position: absolute;
    inset: -12% 0;
    background: url('assets/images/category-offroad.webp') center/cover no-repeat;
    will-change: transform;
}
.manifesto-body { padding: clamp(3rem, 8vw, 7rem) clamp(1.5rem, 5vw, 5rem); }
.manifesto-body h2 {
    font-family: var(--font-display);
    font-weight: 900;
    font-size: clamp(1.8rem, 4vw, 3.4rem);
    line-height: 1.02;
    letter-spacing: -0.03em;
    margin-bottom: 3rem;
}
.manifesto-list { display: flex; flex-direction: column; gap: 2rem; }
.m-item { display: flex; gap: 1.5rem; align-items: flex-start; }
.m-num { font-family: var(--font-display); font-weight: 800; color: var(--accent); font-size: 0.9rem; padding-top: 4px; }
.m-item h3 { font-family: var(--font-display); font-weight: 700; font-size: 1.2rem; margin-bottom: 0.3rem; }
.m-item p { color: var(--muted); font-size: 0.95rem; }

/* ===== CTA ===== */
.cta {
    text-align: center;
    padding: clamp(6rem, 16vw, 14rem) 1.5rem;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 2.5rem;
}
.cta-title {
    font-family: var(--font-display);
    font-weight: 900;
    font-size: clamp(2.4rem, 9vw, 7rem);
    line-height: 0.95;
    letter-spacing: -0.04em;
    text-transform: uppercase;
}
.cta-meta { display: flex; gap: 2rem; flex-wrap: wrap; justify-content: center; color: var(--muted); font-size: 0.85rem; letter-spacing: 0.05em; }

/* ===== FOOTER ===== */
.footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 1rem;
    padding: 2rem clamp(1.2rem, 4vw, 3.5rem);
    border-top: 1px solid var(--line);
    font-size: 0.8rem;
    color: var(--muted);
}
.footer a:hover { color: var(--accent); }

/* ===== RESPONSIVE ===== */
@media (max-width: 860px) {
    .nav-links { display: none; }
    .stats { grid-template-columns: repeat(2, 1fr); gap: 2rem 1rem; }
    .manifesto { grid-template-columns: 1fr; }
    .manifesto-media { height: 60vh; }
    .cats-head { align-items: flex-start; }
    .cats-controls { align-items: flex-start; }
    .cats-arrows { display: none; } /* en m\u00f3vil se desliza con el dedo */
    /* En pantallas peque\u00f1as: mostrar siempre la descripci\u00f3n (sin depender de hover) */
    .cat-card-body p { max-height: 120px; opacity: 1; margin-top: 0.3rem; }
}

@media (prefers-reduced-motion: reduce) {
    *, *::before, *::after { animation-duration: 0.01ms !important; transition-duration: 0.01ms !important; }
}
