*,
*::before,
*::after
{
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

html
{
    scroll-behavior: smooth;
}

/* ===== MODO CLARO (predeterminado) ===== */
:root
{
    --bg: #f4f5f7;
    --surface: #ffffff;
    --card: #eef0f4;
    --border: #dde0e8;
    --accent: #e8a020;
    --accent2: #f5b93a;
    --text: #111318;
    --muted: #6b7080;
    --green: #25D366;
    --font-d: 'Bebas Neue', sans-serif;
    --font-b: 'Plus Jakarta Sans', sans-serif;
    --radius: 14px;
    --shadow: 0 8px 40px rgba(0, 0, 0, .1);
}

/* ===== MODO OSCURO ===== */
body.dark
{
    --bg: #0a0b0d;
    --surface: #111318;
    --card: #181b22;
    --border: #252830;
    --text: #eceef4;
    --muted: #6b7080;
    --shadow: 0 8px 40px rgba(0, 0, 0, .45);
}

body
{
    background: var(--bg);
    color: var(--text);
    font-family: var(--font-b);
    font-size: 15px;
    line-height: 1.65;
    overflow-x: hidden;
    transition: background .3s, color .3s;
}

a
{
    text-decoration: none;
    color: inherit;
}

img
{
    display: block;
    max-width: 100%;
}

/* ===== SCROLLBAR ===== */
::-webkit-scrollbar
{
    width: 6px;
}

::-webkit-scrollbar-track
{
    background: var(--bg);
}

::-webkit-scrollbar-thumb
{
    background: var(--border);
    border-radius: 3px;
}

/* ===== NAVBAR ===== */
#navbar
{
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 1000;
    height: 68px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 5%;
    background: transparent;
    transition: background .35s, box-shadow .35s;
}

/* CORRECCIÓN: usa var(--surface) para respetar el modo claro/oscuro */
#navbar.scrolled
{
    background: var(--surface);
    backdrop-filter: blur(16px);
    box-shadow: 0 1px 0 var(--border);
}

.nav-logo
{
    font-family: var(--font-d);
    font-size: 28px;
    letter-spacing: .06em;
    color: var(--accent);
    display: flex;
    align-items: center;
    gap: 8px;
}

.nav-logo span
{
    color: var(--text);
}

.nav-links
{
    display: flex;
    gap: 32px;
    list-style: none;
}

.nav-links a
{
    font-size: 13px;
    font-weight: 500;
    letter-spacing: .06em;
    text-transform: uppercase;
    color: var(--muted);
    transition: color .2s;
}

.nav-links a:hover
{
    color: var(--text);
}

.nav-wa
{
    display: flex;
    align-items: center;
    gap: 8px;
    background: var(--green);
    color: #fff;
    font-weight: 700;
    font-size: 13px;
    padding: 10px 20px;
    border-radius: 10px;
    transition: opacity .2s, transform .15s;
}

.nav-wa:hover
{
    opacity: .88;
    transform: translateY(-1px);
}

.nav-wa svg
{
    width: 17px;
    height: 17px;
    fill: #fff;
}

/* ===== BOTÓN DARK/LIGHT ===== */
.theme-btn
{
    background: var(--card);
    border: 1px solid var(--border);
    border-radius: 8px;
    padding: 8px 12px;
    font-size: 16px;
    cursor: pointer;
    color: var(--text);
    /* CORRECCIÓN: agregado para modo claro */
    transition: transform .2s, background .3s, border-color .3s;
}

.theme-btn:hover
{
    transform: scale(1.1);
}

/* ===== HAMBURGER ===== */
.hamburger
{
    display: none;
    flex-direction: column;
    gap: 5px;
    cursor: pointer;
    padding: 4px;
}

.hamburger span
{
    display: block;
    width: 24px;
    height: 2px;
    background: var(--text);
    border-radius: 2px;
    transition: transform .3s, opacity .3s;
}

.hamburger.open span:nth-child(1)
{
    transform: translateY(7px) rotate(45deg);
}

.hamburger.open span:nth-child(2)
{
    opacity: 0;
}

.hamburger.open span:nth-child(3)
{
    transform: translateY(-7px) rotate(-45deg);
}

/* ===== MOBILE MENU ===== */
.mobile-menu
{
    display: none;
    position: fixed;
    top: 68px;
    left: 0;
    right: 0;
    z-index: 999;
    background: var(--surface);
    backdrop-filter: blur(16px);
    padding: 28px 5% 36px;
    border-bottom: 1px solid var(--border);
    flex-direction: column;
    gap: 20px;
}

.mobile-menu.open
{
    display: flex;
}

.mobile-menu a
{
    font-size: 15px;
    font-weight: 600;
    letter-spacing: .04em;
    text-transform: uppercase;
    color: var(--muted);
    padding: 8px 0;
    border-bottom: 1px solid var(--border);
    transition: color .2s;
}

.mobile-menu a:hover
{
    color: var(--accent);
}

.mobile-menu .m-wa
{
    margin-top: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    background: var(--green);
    color: #fff;
    font-weight: 700;
    font-size: 14px;
    padding: 14px;
    border-radius: 12px;
    border: none;
}

/* ===== BANNER PRINCIPAL ===== */
#inicio
{
    min-height: 100vh;
    display: flex;
    align-items: center;
    padding: 120px 5% 80px;
    position: relative;
    overflow: hidden;
}

.hero-glow
{
    position: absolute;
    inset: 0;
    pointer-events: none;
    background:
        radial-gradient(ellipse 55% 65% at 75% 55%, rgba(232, 160, 32, .07) 0%, transparent 65%),
        radial-gradient(ellipse 35% 45% at 15% 75%, rgba(37, 211, 102, .04) 0%, transparent 55%);
}

.hero-grid
{
    position: absolute;
    inset: 0;
    pointer-events: none;
    background-image:
        linear-gradient(rgba(0, 0, 0, .06) 1px, transparent 1px),
        linear-gradient(90deg, rgba(0, 0, 0, .06) 1px, transparent 1px);
    background-size: 60px 60px;
    mask-image: radial-gradient(ellipse 80% 80% at 50% 50%, black 30%, transparent 100%);
}

.hero-content
{
    position: relative;
    z-index: 2;
    max-width: 620px;
}

.hero-pill
{
    display: inline-flex;
    align-items: center;
    gap: 9px;
    background: rgba(232, 160, 32, .1);
    border: 1px solid rgba(232, 160, 32, .22);
    color: var(--accent2);
    font-size: 11px;
    font-weight: 600;
    letter-spacing: .1em;
    text-transform: uppercase;
    padding: 7px 16px;
    border-radius: 30px;
    margin-bottom: 30px;
}

.pill-dot
{
    width: 7px;
    height: 7px;
    background: var(--accent);
    border-radius: 50%;
    animation: blink 2s ease-in-out infinite;
}

@keyframes blink
{

    0%,
    100%
    {
        opacity: 1;
    }

    50%
    {
        opacity: .2;
    }
}

.hero-title
{
    font-family: var(--font-d);
    font-size: clamp(72px, 10vw, 120px);
    line-height: .88;
    letter-spacing: .02em;
    margin-bottom: 26px;
}

.hero-title .gold
{
    color: var(--accent);
}

.hero-desc
{
    font-size: 16px;
    color: var(--muted);
    max-width: 460px;
    margin-bottom: 42px;
    line-height: 1.75;
}

.hero-btns
{
    display: flex;
    gap: 14px;
    flex-wrap: wrap;
    margin-bottom: 56px;
}

.btn-gold
{
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: var(--accent);
    color: #000;
    font-weight: 700;
    font-size: 14px;
    padding: 15px 30px;
    border-radius: 12px;
    border: none;
    cursor: pointer;
    transition: transform .15s, box-shadow .15s;
}

.btn-gold:hover
{
    transform: translateY(-2px);
    box-shadow: 0 8px 24px rgba(232, 160, 32, .3);
}

.btn-outline
{
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: transparent;
    color: var(--text);
    font-weight: 500;
    font-size: 14px;
    padding: 15px 30px;
    border-radius: 12px;
    border: 1px solid var(--border);
    cursor: pointer;
    transition: border-color .2s;
}

.btn-outline:hover
{
    border-color: var(--accent);
}

.hero-stats
{
    display: flex;
    gap: 36px;
    flex-wrap: wrap;
    padding-top: 36px;
    border-top: 1px solid var(--border);
}

.stat-val
{
    font-family: var(--font-d);
    font-size: 40px;
    color: var(--accent);
    line-height: 1;
}

.stat-lbl
{
    font-size: 11px;
    color: var(--muted);
    text-transform: uppercase;
    letter-spacing: .08em;
    margin-top: 4px;
}

/* Ilustración del carro */
.hero-car-wrap
{
    position: absolute;
    right: -2%;
    bottom: 0;
    width: 52%;
    max-width: 680px;
    pointer-events: none;
    z-index: 1;
    opacity: .22;
    animation: carFloat 5s ease-in-out infinite;
}

@keyframes carFloat
{

    0%,
    100%
    {
        transform: translateY(0);
    }

    50%
    {
        transform: translateY(-12px);
    }
}

/* ===== SECCIÓN BASE ===== */
section
{
    padding: 100px 5%;
}

.sec-tag
{
    font-size: 11px;
    font-weight: 700;
    letter-spacing: .14em;
    text-transform: uppercase;
    color: var(--accent);
    margin-bottom: 10px;
}

.sec-title
{
    font-family: var(--font-d);
    font-size: clamp(42px, 5.5vw, 68px);
    letter-spacing: .02em;
    line-height: .95;
    margin-bottom: 14px;
}

.sec-sub
{
    color: var(--muted);
    font-size: 15px;
    max-width: 460px;
    margin-bottom: 60px;
    line-height: 1.7;
}

/* ===== SERVICIOS ===== */
#servicios
{
    background: var(--surface);
}

.services-grid
{
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(230px, 1fr));
    gap: 18px;
}

.svc-card
{
    background: var(--card);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 32px 26px;
    position: relative;
    overflow: hidden;
    transition: border-color .25s, transform .25s;
    cursor: default;
}

.svc-card::after
{
    content: "";
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 2px;
    background: var(--accent);
    transform: scaleX(0);
    transform-origin: left;
    transition: transform .3s;
}

.svc-card:hover
{
    border-color: rgba(232, 160, 32, .35);
    transform: translateY(-5px);
}

.svc-card:hover::after
{
    transform: scaleX(1);
}

.svc-icon
{
    width: 50px;
    height: 50px;
    background: rgba(232, 160, 32, .1);
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 22px;
    margin-bottom: 22px;
}

.svc-name
{
    font-family: var(--font-d);
    font-size: 24px;
    letter-spacing: .03em;
    margin-bottom: 8px;
}

.svc-desc
{
    color: var(--muted);
    font-size: 14px;
    line-height: 1.65;
}

/* ===== GALERÍA ===== */
#galeria
{
    background: var(--bg);
}

.gallery-grid
{
    display: grid;
    grid-template-columns: 2fr 1fr 1fr;
    grid-template-rows: 210px 210px;
    gap: 12px;
}

.gal-item
{
    background: var(--card);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    overflow: hidden;
    position: relative;
    cursor: pointer;
    transition: border-color .2s, transform .2s;
}

.gal-item:hover
{
    border-color: var(--accent);
    transform: scale(1.01);
}

.gal-item:first-child
{
    grid-row: span 2;
}

/* Imagen ocupa todo el espacio del item */
.gal-item img
{
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

/* Overlay "Ver foto" al hacer hover */
.gal-item::before
{
    content: "Ver foto";
    position: absolute;
    inset: 0;
    background: rgba(232, 160, 32, .12);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 13px;
    font-weight: 700;
    color: var(--accent2);
    letter-spacing: .08em;
    text-transform: uppercase;
    opacity: 0;
    transition: opacity .25s;
    z-index: 1;
}

.gal-item:hover::before
{
    opacity: 1;
}

/* ===== CONTACTO ===== */
#contacto
{
    background: var(--surface);
}

.contact-wrap
{
    display: grid;
    grid-template-columns: 1fr 1.1fr;
    gap: 44px;
    align-items: start;
}

.contact-cards
{
    display: flex;
    flex-direction: column;
    gap: 14px;
}

.c-card
{
    display: flex;
    align-items: center;
    gap: 16px;
    background: var(--card);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 18px 20px;
    transition: border-color .2s;
}

.c-card:hover
{
    border-color: rgba(232, 160, 32, .3);
}

.c-icon
{
    width: 44px;
    height: 44px;
    flex-shrink: 0;
    border-radius: 11px;
    background: rgba(232, 160, 32, .1);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 18px;
}

.c-card.wa
{
    border-color: rgba(37, 211, 102, .2);
    background: rgba(37, 211, 102, .05);
}

.c-card.wa .c-icon
{
    background: rgba(37, 211, 102, .15);
}

.c-lbl
{
    font-size: 11px;
    color: var(--muted);
    text-transform: uppercase;
    letter-spacing: .07em;
}

.c-val
{
    font-weight: 600;
    font-size: 15px;
    margin-top: 2px;
}

/* Formulario */
.c-form
{
    background: var(--card);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 36px;
}

.c-form-title
{
    font-family: var(--font-d);
    font-size: 30px;
    letter-spacing: .03em;
    margin-bottom: 28px;
}

.f-group
{
    margin-bottom: 16px;
}

.f-group label
{
    display: block;
    font-size: 11px;
    font-weight: 600;
    color: var(--muted);
    text-transform: uppercase;
    letter-spacing: .08em;
    margin-bottom: 7px;
}

.f-group input,
.f-group textarea,
.f-group select
{
    width: 100%;
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: 9px;
    color: var(--text);
    font-family: var(--font-b);
    font-size: 14px;
    padding: 12px 14px;
    outline: none;
    transition: border-color .2s;
    appearance: none;
}

.f-group input:focus,
.f-group textarea:focus,
.f-group select:focus
{
    border-color: var(--accent);
}

.f-group textarea
{
    resize: none;
    height: 110px;
}

.f-row
{
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 12px;
}

.btn-send
{
    width: 100%;
    margin-top: 8px;
    background: var(--accent);
    color: #000;
    font-family: var(--font-b);
    font-weight: 700;
    font-size: 14px;
    padding: 15px;
    border-radius: 10px;
    border: none;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    transition: opacity .2s, transform .15s;
}

.btn-send:hover
{
    opacity: .88;
    transform: translateY(-1px);
}

/* ===== FOOTER ===== */
footer
{
    background: var(--surface);
    border-top: 1px solid var(--border);
    padding: 40px 5%;
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 20px;
}

.f-logo
{
    font-family: var(--font-d);
    font-size: 24px;
    color: var(--accent);
    letter-spacing: .06em;
}

.f-copy
{
    font-size: 12px;
    color: var(--muted);
}

.f-links
{
    display: flex;
    gap: 24px;
}

.f-links a
{
    font-size: 12px;
    color: var(--muted);
    transition: color .2s;
}

.f-links a:hover
{
    color: var(--text);
}

/* ===== WHATSAPP FLOTANTE ===== */
.wa-float
{
    position: fixed;
    bottom: 28px;
    right: 28px;
    z-index: 500;
    width: 60px;
    height: 60px;
    border-radius: 50%;
    background: var(--green);
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 6px 28px rgba(37, 211, 102, .45);
    cursor: pointer;
    animation: floatWa 3.5s ease-in-out infinite;
    transition: transform .2s, box-shadow .2s;
}

.wa-float:hover
{
    transform: scale(1.12);
    box-shadow: 0 10px 36px rgba(37, 211, 102, .6);
}

.wa-float svg
{
    width: 28px;
    height: 28px;
    fill: #fff;
}

@keyframes floatWa
{

    0%,
    100%
    {
        transform: translateY(0);
    }

    50%
    {
        transform: translateY(-7px);
    }
}

/* ===== TOAST ===== */
.toast
{
    position: fixed;
    bottom: 100px;
    right: 28px;
    z-index: 600;
    background: var(--card);
    border: 1px solid rgba(37, 211, 102, .3);
    color: var(--text);
    font-size: 14px;
    font-weight: 500;
    padding: 14px 20px;
    border-radius: 12px;
    box-shadow: var(--shadow);
    transform: translateY(20px);
    opacity: 0;
    transition: transform .3s, opacity .3s;
    pointer-events: none;
}

.toast.show
{
    transform: translateY(0);
    opacity: 1;
}

/* ===== LIGHTBOX ===== */
#lightbox
{
    display: none;
    position: fixed;
    inset: 0;
    z-index: 2000;
}

#lightbox.active
{
    display: flex;
    align-items: center;
    justify-content: center;
}

.lb-overlay
{
    position: absolute;
    inset: 0;
    background: rgba(0, 0, 0, 0.9);
    cursor: pointer;
}

.lb-content
{
    position: relative;
    z-index: 1;
    max-width: 90vw;
    max-height: 90vh;
}

.lb-content img
{
    max-width: 90vw;
    max-height: 85vh;
    border-radius: 12px;
    object-fit: contain;
}

.lb-close
{
    position: absolute;
    top: -16px;
    right: -16px;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background: var(--accent);
    color: #000;
    font-size: 14px;
    font-weight: 700;
    border: none;
    cursor: pointer;
}

/* ===== RESPONSIVE 900px ===== */
@media (max-width: 900px)
{

    .nav-links,
    .nav-wa
    {
        display: none;
    }

    .hamburger
    {
        display: flex;
    }

    .gallery-grid
    {
        grid-template-columns: 1fr 1fr;
        grid-template-rows: auto;
    }

    .gal-item:first-child
    {
        grid-row: span 1;
        grid-column: span 2;
        height: 220px;
    }

    .gal-item
    {
        height: 180px;
    }

    .contact-wrap
    {
        grid-template-columns: 1fr;
    }
}

/* ===== RESPONSIVE 600px ===== */
@media (max-width: 600px)
{
    section
    {
        padding: 72px 5%;
    }

    .hero-stats
    {
        gap: 24px;
    }

    .hero-car-wrap
    {
        display: none;
    }

    .gallery-grid
    {
        grid-template-columns: 1fr;
    }

    .gal-item:first-child
    {
        grid-column: span 1;
        height: 220px;
    }

    .gal-item
    {
        height: 180px;
    }

    .f-row
    {
        grid-template-columns: 1fr;
    }

    footer
    {
        flex-direction: column;
        align-items: flex-start;
        gap: 14px;
    }
}