:root {
    --bg: #050908;
    --panel: rgba(14, 24, 21, 0.78);
    --panel-strong: #0b1412;
    --line: rgba(255, 255, 255, 0.12);
    --line-strong: rgba(255, 255, 255, 0.2);
    --text: #f4fff7;
    --muted: #a8b7ae;
    --green: #59c13d;
    --green-2: #9af078;
    --cyan: #77d8d2;
    --orange: #f4b860;
    --shadow: 0 24px 80px rgba(0, 0, 0, 0.42);
    --body-gradient: radial-gradient(circle at 15% 8%, rgba(89, 193, 61, 0.2), transparent 30rem),
        radial-gradient(circle at 90% 20%, rgba(119, 216, 210, 0.12), transparent 28rem),
        linear-gradient(180deg, #050908 0%, #08110f 48%, #050908 100%);
    --header-bg: rgba(5, 9, 8, 0.76);
    --surface: linear-gradient(145deg, rgba(255,255,255,.1), rgba(255,255,255,.035));
    --surface-soft: rgba(255,255,255,.06);
    --surface-chip: rgba(255, 255, 255, 0.05);
    --tile-bg: rgba(8, 16, 14, 0.78);
    --input-bg: rgba(5, 9, 8, 0.8);
    --floating-bg: rgba(5, 9, 8, 0.82);
    --button-text: #061006;
    --icon-text: #071006;
}

body[data-theme="light"] {
    --bg: #f6faf3;
    --panel: rgba(255, 255, 255, 0.82);
    --panel-strong: #ffffff;
    --line: rgba(10, 30, 20, 0.13);
    --line-strong: rgba(10, 30, 20, 0.2);
    --text: #0a1410;
    --muted: #51635a;
    --green: #4fb236;
    --green-2: #2d8f20;
    --cyan: #1d9f99;
    --orange: #d88924;
    --shadow: 0 22px 70px rgba(18, 44, 30, 0.13);
    --body-gradient: radial-gradient(circle at 16% 8%, rgba(89, 193, 61, 0.18), transparent 28rem),
        radial-gradient(circle at 88% 18%, rgba(119, 216, 210, 0.18), transparent 26rem),
        linear-gradient(180deg, #f8fcf5 0%, #eef7eb 48%, #ffffff 100%);
    --header-bg: rgba(255, 255, 255, 0.78);
    --surface: linear-gradient(145deg, rgba(255,255,255,.92), rgba(246,252,243,.72));
    --surface-soft: rgba(12, 38, 22, 0.055);
    --surface-chip: rgba(14, 50, 28, 0.055);
    --tile-bg: rgba(255, 255, 255, 0.74);
    --input-bg: rgba(255, 255, 255, 0.88);
    --floating-bg: rgba(255, 255, 255, 0.84);
    --button-text: #061006;
    --icon-text: #071006;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
    margin: 0;
    font-family: Inter, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
    background: var(--body-gradient);
    color: var(--text);
    line-height: 1.6;
    min-height: 100vh;
    padding-bottom: 74px;
}

a { color: inherit; text-decoration: none; }
img { max-width: 100%; display: block; }

.site-header {
    position: sticky;
    top: 0;
    z-index: 20;
    display: grid;
    grid-template-columns: 180px 1fr auto auto;
    align-items: center;
    gap: 24px;
    width: min(1180px, calc(100% - 32px));
    margin: 16px auto 0;
    padding: 13px 16px;
    border: 1px solid var(--line);
    border-radius: 8px;
    background: var(--header-bg);
    backdrop-filter: blur(18px);
    box-shadow: var(--shadow);
}

.brand img { width: 156px; height: auto; }
.site-nav { display: flex; justify-content: center; gap: 6px; }
.site-nav a,
.header-cta {
    padding: 10px 13px;
    border-radius: 6px;
    color: var(--muted);
    font-size: 14px;
    font-weight: 700;
}
.site-nav a:hover,
.site-nav a.active {
    color: var(--text);
    background: var(--surface-soft);
}
.header-cta {
    color: var(--button-text);
    background: var(--green);
}
.nav-toggle { display: none; }
.theme-toggle {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    min-height: 38px;
    padding: 0 11px;
    border: 1px solid var(--line);
    border-radius: 7px;
    color: var(--text);
    background: var(--surface-soft);
    font: inherit;
    font-size: 13px;
    font-weight: 800;
    cursor: pointer;
}
.theme-toggle-icon {
    position: relative;
    display: grid;
    place-items: center;
    width: 17px;
    height: 17px;
    border-radius: 50%;
    color: transparent;
    font-size: 10px;
    line-height: 1;
    background: var(--green);
    box-shadow: inset -5px -3px 0 rgba(0,0,0,.22);
}
body[data-theme="light"] .theme-toggle-icon {
    box-shadow: 0 0 0 4px rgba(89,193,61,.16);
}

.hero,
.section,
.page-hero {
    width: min(1180px, calc(100% - 32px));
    margin: 0 auto;
}
.hero {
    display: grid;
    grid-template-columns: minmax(0, 1.05fr) minmax(360px, 0.95fr);
    align-items: center;
    gap: 48px;
    min-height: calc(100vh - 108px);
    padding: 56px 0 40px;
}
.hero h1,
.page-hero h1 {
    margin: 14px 0 18px;
    font-size: clamp(42px, 6vw, 78px);
    line-height: 0.96;
    letter-spacing: 0;
}
.hero p,
.page-hero p,
.section p {
    color: var(--muted);
    font-size: 17px;
}
.hero-content > p { max-width: 650px; }
.eyebrow {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    color: var(--green-2);
    font-size: 13px;
    font-weight: 800;
    text-transform: uppercase;
}
.eyebrow::before {
    content: "";
    width: 9px;
    height: 9px;
    border-radius: 50%;
    background: var(--green);
    box-shadow: 0 0 22px var(--green);
}
.hero-actions,
.wizard-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    margin-top: 28px;
}
.btn {
    display: inline-flex;
    justify-content: center;
    align-items: center;
    min-height: 48px;
    padding: 0 18px;
    border: 1px solid var(--line);
    border-radius: 7px;
    font-weight: 800;
    cursor: pointer;
    transition: transform .2s ease, border-color .2s ease, background .2s ease;
}
.btn:hover { transform: translateY(-2px); }
.btn.primary {
    color: var(--button-text);
    background: linear-gradient(135deg, var(--green), var(--green-2));
    border-color: rgba(154, 240, 120, 0.7);
    box-shadow: 0 14px 38px rgba(89, 193, 61, 0.25);
}
.btn.ghost { background: var(--surface-soft); color: var(--text); }
.proof-strip {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-top: 28px;
}
.proof-strip span,
.brand-row span,
.project-stats span {
    border: 1px solid var(--line);
    border-radius: 999px;
    padding: 8px 12px;
    color: var(--muted);
    background: var(--surface-chip);
    font-size: 13px;
}

.mock-window,
.glass-card,
.form-card,
.contact-panel,
.project-card,
.cta-panel,
.service-row,
.wizard-aside {
    border: 1px solid var(--line);
    border-radius: 8px;
    background: var(--surface);
    backdrop-filter: blur(18px);
    box-shadow: var(--shadow);
}
.mock-window {
    padding: 14px;
    transform: perspective(900px) rotateY(-7deg) rotateX(4deg);
}
.window-top {
    display: flex;
    align-items: center;
    gap: 8px;
    padding-bottom: 14px;
    color: var(--muted);
    font-size: 13px;
}
.window-top span {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background: var(--green);
}
.window-top span:nth-child(2) { background: var(--orange); }
.window-top span:nth-child(3) { background: var(--cyan); }
.window-top strong { margin-left: auto; }
.control-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 12px;
}
.control-tile {
    min-height: 124px;
    padding: 16px;
    border: 1px solid var(--line);
    border-radius: 7px;
    background: var(--tile-bg);
}
.control-tile.large,
.control-tile.wide { grid-column: span 2; }
.control-tile small,
.device-card span,
.project-card small { color: var(--muted); }
.control-tile strong {
    display: block;
    margin-top: 12px;
    font-size: 30px;
    line-height: 1;
}
.progress {
    display: block;
    height: 8px;
    margin-top: 24px;
    border-radius: 99px;
    background: var(--surface-chip);
    overflow: hidden;
}
.progress i {
    display: block;
    height: 100%;
    background: linear-gradient(90deg, var(--green), var(--cyan));
}
.bars {
    display: flex;
    align-items: end;
    gap: 6px;
    height: 44px;
    margin-top: 14px;
}
.bars i {
    flex: 1;
    border-radius: 6px 6px 0 0;
    background: var(--green);
}
.bars i:nth-child(1) { height: 32%; }
.bars i:nth-child(2) { height: 54%; background: var(--cyan); }
.bars i:nth-child(3) { height: 78%; }
.bars i:nth-child(4) { height: 44%; background: var(--orange); }
.bars i:nth-child(5) { height: 90%; }
.dimmer-tile {
    display: grid;
    gap: 14px;
}
.dimmer-list {
    display: grid;
    gap: 11px;
}
.dimmer-row {
    display: grid;
    grid-template-columns: 86px 1fr 44px;
    gap: 10px;
    align-items: center;
}
.dimmer-row span {
    color: var(--muted);
    font-size: 12px;
    font-weight: 800;
}
.dimmer-row i {
    position: relative;
    display: block;
    height: 8px;
    border-radius: 99px;
    background: var(--surface-chip);
    overflow: hidden;
}
.dimmer-row b {
    display: block;
    height: 100%;
    border-radius: inherit;
    background: linear-gradient(90deg, var(--green), var(--green-2));
}
.dimmer-row strong {
    margin: 0;
    font-size: 13px;
    text-align: right;
}

.section { padding: 74px 0; }
.page-hero { padding: 86px 0 34px; }
.page-hero p { max-width: 760px; }
.info-hero {
    display: grid;
    grid-template-columns: minmax(0, 1.05fr) minmax(320px, .72fr);
    gap: 36px;
    align-items: center;
}
.compact-info-hero h1 {
    max-width: 980px;
    font-size: clamp(48px, 5.1vw, 88px);
    line-height: 1.02;
}
.compact-info-hero .source-visual {
    margin-top: 64px;
}
.intro-grid,
.dashboard-band,
.contact-layout,
.wizard-layout {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 38px;
    align-items: center;
}
.section h2 {
    margin: 10px 0 14px;
    font-size: clamp(30px, 4vw, 52px);
    line-height: 1.04;
    letter-spacing: 0;
}
.section-head {
    display: flex;
    align-items: end;
    justify-content: space-between;
    gap: 24px;
    margin-bottom: 26px;
}
.section-head h2 { max-width: 700px; }
.section-head a { color: var(--green-2); font-weight: 800; }
.metrics {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 12px;
}
.metrics div,
.device-card {
    padding: 18px;
    border: 1px solid var(--line);
    border-radius: 8px;
    background: var(--surface-soft);
}
.metrics strong {
    display: block;
    color: var(--green-2);
    font-size: 34px;
    line-height: 1;
}
.metrics span { color: var(--muted); font-size: 13px; }
.service-grid,
.project-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 18px;
}
.service-card { padding: 22px; transition: transform .2s ease, border-color .2s ease; }
.service-card:hover,
.project-card:hover { transform: translateY(-5px); border-color: rgba(89,193,61,.55); }
.icon-3d {
    display: grid;
    place-items: center;
    width: 58px;
    height: 58px;
    border-radius: 8px;
    color: var(--icon-text);
    font-weight: 900;
    background: linear-gradient(145deg, #dcffd4, var(--green), #2c7a1f);
    box-shadow: inset -8px -8px 18px rgba(0,0,0,.24), 0 18px 34px rgba(89,193,61,.22);
}
.service-card a { color: var(--green-2); font-weight: 800; }
.device-stack { display: grid; gap: 12px; }
.device-card.active { border-color: rgba(89,193,61,.7); background: rgba(89,193,61,.13); }
.device-card strong { display: block; font-size: 34px; }
.device-card small { color: var(--muted); }
.brand-row { display: flex; flex-wrap: wrap; gap: 10px; justify-content: center; }
.cta-panel {
    padding: 34px;
    text-align: center;
}
.cta-panel p { max-width: 720px; margin: 0 auto 24px; }

.service-list { display: grid; gap: 18px; }
.service-row {
    display: grid;
    grid-template-columns: 80px 1fr minmax(220px, .8fr) auto;
    gap: 22px;
    align-items: center;
    padding: 22px;
}
.service-row ul { margin: 0; color: var(--muted); }
.api-flow {
    display: grid;
    grid-template-columns: 1fr 46px 1.2fr 46px 1fr;
    gap: 10px;
    align-items: center;
}
.api-flow span {
    min-height: 82px;
    display: grid;
    place-items: center;
    border: 1px solid var(--line);
    border-radius: 8px;
    background: var(--surface-soft);
    font-weight: 800;
}
.api-flow i { height: 2px; background: var(--green); }

.project-card { padding: 18px; transition: transform .2s ease, border-color .2s ease; }
.project-visual {
    display: grid;
    grid-template-columns: 1.3fr .8fr;
    gap: 10px;
    height: 180px;
    margin-bottom: 18px;
}
.project-visual span {
    border-radius: 8px;
    border: 1px solid var(--line);
    background:
        linear-gradient(135deg, rgba(89,193,61,.42), transparent),
        var(--surface);
}
.project-visual span:first-child { grid-row: span 2; }
.project-stats { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 18px; }

.source-visual {
    margin: 0;
    overflow: hidden;
    border: 1px solid var(--line);
    border-radius: 8px;
    background: var(--surface);
    box-shadow: var(--shadow);
}
.source-visual img {
    width: 100%;
    aspect-ratio: 16 / 11;
    object-fit: cover;
}
.source-visual.transparent-visual {
    display: grid;
    justify-items: center;
    align-self: center;
    overflow: visible;
    padding: 58px 18px 0;
    border: 0;
    background: transparent;
    box-shadow: none;
}
.source-visual.transparent-visual img {
    width: min(100%, 450px);
    height: auto;
    aspect-ratio: auto;
    object-fit: contain;
}
.source-visual figcaption {
    padding: 10px 14px 14px;
    color: var(--muted);
    font-size: 12px;
}
.feature-grid,
.product-grid,
.compare-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 18px;
}
.feature-card,
.product-info-card,
.compare-card {
    padding: 22px;
}
.feature-card h3,
.product-info-card h2,
.compare-card h3 {
    margin: 14px 0 10px;
}
.product-info-card {
    border: 1px solid var(--line);
    border-radius: 8px;
    background: var(--surface);
    box-shadow: var(--shadow);
}
.product-info-card img {
    width: 100%;
    aspect-ratio: 16 / 10;
    object-fit: contain;
    padding: 18px;
    border-radius: 8px;
    background: var(--tile-bg);
}
.compare-card {
    border: 1px solid var(--line);
    border-radius: 8px;
    background: var(--surface);
}
.compare-card.highlight {
    border-color: rgba(89,193,61,.55);
    background: linear-gradient(145deg, rgba(89,193,61,.16), rgba(255,255,255,.04));
}
.compare-card ul {
    margin: 18px 0 0;
    padding-left: 18px;
    color: var(--muted);
}
.mini-dashboard {
    display: grid;
    gap: 12px;
}
.mini-dashboard div {
    padding: 18px;
    border: 1px solid var(--line);
    border-radius: 8px;
    background: var(--surface-soft);
}
.mini-dashboard span {
    display: block;
    color: var(--muted);
    font-size: 13px;
    font-weight: 800;
}
.mini-dashboard strong {
    display: block;
    margin-top: 6px;
    font-size: 24px;
}
.source-note {
    padding-top: 20px;
}
.source-note a {
    color: var(--green-2);
    font-weight: 900;
}

.contact-panel { padding: 26px; }
.contact-panel a {
    display: block;
    padding: 14px 0;
    border-bottom: 1px solid var(--line);
    color: var(--green-2);
    font-weight: 800;
}
.form-card { padding: 22px; }
label {
    display: grid;
    gap: 8px;
    margin-bottom: 14px;
    color: var(--muted);
    font-weight: 700;
}
input, textarea, select {
    width: 100%;
    border: 1px solid var(--line);
    border-radius: 7px;
    background: var(--input-bg);
    color: var(--text);
    padding: 13px 14px;
    font: inherit;
}
textarea { resize: vertical; }
.alert {
    padding: 13px;
    border-radius: 7px;
    margin-bottom: 14px;
    font-weight: 800;
}
.alert.success { background: rgba(89,193,61,.16); border: 1px solid rgba(89,193,61,.45); }
.alert.error { background: rgba(244,93,72,.16); border: 1px solid rgba(244,93,72,.45); }

.wizard-layout { align-items: start; }
.wizard-progress {
    height: 9px;
    border-radius: 999px;
    background: var(--surface-chip);
    margin-bottom: 22px;
    overflow: hidden;
}
.wizard-progress i {
    display: block;
    height: 100%;
    background: linear-gradient(90deg, var(--green), var(--cyan));
    transition: width .25s ease;
}
fieldset {
    border: 0;
    padding: 0;
    margin: 0;
}
.wizard-step { display: none; }
.wizard-step.active { display: block; }
legend {
    font-size: 26px;
    font-weight: 900;
    margin-bottom: 18px;
}
.choice-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 12px;
}
.choice { margin: 0; }
.choice input { position: absolute; opacity: 0; pointer-events: none; }
.choice span {
    display: grid;
    min-height: 80px;
    place-items: center;
    border: 1px solid var(--line);
    border-radius: 8px;
    background: var(--surface-chip);
    color: var(--text);
    text-align: center;
    padding: 12px;
}
.choice input:checked + span {
    border-color: var(--green);
    background: rgba(89,193,61,.16);
}
.wizard-submit { display: none; }
.wizard-aside { padding: 14px; }
.wizard-aside .mock-window { transform: none; box-shadow: none; }
.mini-contact {
    display: flex;
    justify-content: space-between;
    gap: 16px;
    align-items: center;
    margin-top: 14px;
    padding: 14px;
}
.mini-contact a { color: var(--green-2); font-weight: 900; }

.sticky-contact {
    position: fixed;
    left: 50%;
    bottom: 14px;
    z-index: 30;
    display: flex;
    gap: 8px;
    width: min(560px, calc(100% - 24px));
    transform: translateX(-50%);
    padding: 8px;
    border: 1px solid var(--line);
    border-radius: 8px;
    background: var(--floating-bg);
    backdrop-filter: blur(18px);
    box-shadow: var(--shadow);
}
.sticky-contact a {
    flex: 1;
    text-align: center;
    padding: 11px 8px;
    border-radius: 6px;
    background: var(--surface-soft);
    color: var(--text);
    font-size: 13px;
    font-weight: 900;
}
.sticky-contact .whatsapp {
    color: var(--button-text);
    background: var(--green);
}
.site-footer {
    width: min(1180px, calc(100% - 32px));
    margin: 44px auto 120px;
    display: grid;
    grid-template-columns: 1.2fr .7fr .9fr;
    gap: 28px;
    padding-top: 34px;
    border-top: 1px solid var(--line);
    color: var(--muted);
}
.site-footer img { width: 160px; margin-bottom: 14px; }
.site-footer a,
.site-footer strong { display: block; margin-bottom: 8px; }
.site-footer strong { color: var(--text); }

[data-reveal] {
    opacity: 0;
    transform: translateY(18px);
    transition: opacity .65s ease, transform .65s ease;
}
[data-reveal].revealed {
    opacity: 1;
    transform: translateY(0);
}

@media (max-width: 920px) {
    .site-header {
        grid-template-columns: 150px auto;
    }
    .nav-toggle {
        display: inline-grid;
        gap: 4px;
        justify-self: end;
        width: 44px;
        height: 44px;
        place-content: center;
        border: 1px solid var(--line);
        border-radius: 7px;
        background: var(--surface-soft);
    }
    .nav-toggle span {
        display: block;
        width: 18px;
        height: 2px;
        background: var(--text);
    }
    .site-nav,
    .theme-toggle,
    .header-cta {
        display: none;
        grid-column: 1 / -1;
    }
    .theme-toggle {
        justify-content: center;
    }
    .site-header.nav-open .site-nav {
        display: grid;
        justify-content: stretch;
    }
    .site-header.nav-open .theme-toggle { display: inline-flex; }
    .site-header.nav-open .header-cta { display: inline-flex; justify-content: center; }
    .hero,
    .info-hero,
    .intro-grid,
    .dashboard-band,
    .contact-layout,
    .wizard-layout {
        grid-template-columns: 1fr;
    }
    .hero { min-height: 0; }
    .mock-window { transform: none; }
    .service-grid,
    .project-grid,
    .feature-grid,
    .product-grid,
    .compare-grid {
        grid-template-columns: 1fr;
    }
    .service-row {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 620px) {
    body { padding-bottom: 112px; }
    .hero h1,
    .page-hero h1 { font-size: 42px; }
    .section { padding: 52px 0; }
    .control-grid,
    .metrics,
    .choice-grid,
    .site-footer {
        grid-template-columns: 1fr;
    }
    .control-tile.large,
    .control-tile.wide { grid-column: span 1; }
    .section-head { display: block; }
    .api-flow { grid-template-columns: 1fr; }
    .api-flow i { height: 20px; width: 2px; justify-self: center; }
    .sticky-contact { bottom: 8px; }
    .sticky-contact a { font-size: 12px; }
}
