:root {
    --bg: #f7f9fc;
    --surface: #ffffff;
    --text: #172033;
    --muted: #657083;
    --line: #dce3ee;
    --primary: #2364db;
    --primary-strong: #143f99;
    --accent: #10a37f;
    --warning: #f6b43b;
    --shadow: 0 18px 50px rgba(26, 42, 68, .12);
}

[data-theme="dark"] {
    --bg: #111827;
    --surface: #172033;
    --text: #f8fafc;
    --muted: #a8b3c7;
    --line: #2f3a4f;
    --primary: #6ea8fe;
    --primary-strong: #9ec5fe;
    --accent: #34d399;
    --shadow: 0 18px 50px rgba(0, 0, 0, .35);
}

body {
    background: var(--bg);
    color: var(--text);
    font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

a { color: var(--primary); text-decoration: none; }
h1, h2, h3 { letter-spacing: 0; font-weight: 800; }
.brand { color: var(--text); font-weight: 900; font-size: 1.35rem; }
.muted { color: var(--muted); }

.glass-nav {
    background: color-mix(in srgb, var(--surface) 88%, transparent);
    border-bottom: 1px solid var(--line);
    backdrop-filter: blur(16px);
}

.nav-link { color: var(--text); }
.theme-toggle {
    width: 38px;
    height: 38px;
    border-radius: 50%;
    border: 1px solid var(--line);
    background: var(--surface);
    color: var(--text);
}

.landing-hero {
    position: relative;
    min-height: calc(100vh - 72px);
    display: flex;
    align-items: center;
    overflow: hidden;
    color: white;
    background:
        linear-gradient(120deg, rgba(8, 21, 44, .94), rgba(17, 73, 101, .86) 48%, rgba(14, 116, 92, .82)),
        radial-gradient(circle at 76% 18%, rgba(246, 180, 59, .30), transparent 28%),
        linear-gradient(135deg, #0b1324, #12385c 58%, #0f766e);
}

.landing-hero::after {
    content: "";
    position: absolute;
    inset: auto 0 0;
    height: 120px;
    background: linear-gradient(180deg, transparent, var(--bg));
    pointer-events: none;
}

.landing-hero-grid {
    position: relative;
    z-index: 1;
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(360px, 560px);
    gap: 58px;
    align-items: center;
    padding-top: 64px;
    padding-bottom: 120px;
}

.landing-copy h1 {
    margin: 12px 0 22px;
    font-size: clamp(4rem, 12vw, 8.6rem);
    line-height: .82;
    color: white;
}

.landing-copy .lead {
    max-width: 720px;
    color: #dbeafe;
    font-size: clamp(1.12rem, 2vw, 1.45rem);
}

.hero-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 14px;
    margin-top: 30px;
}

.btn-ghost {
    color: white;
    border: 1px solid rgba(255,255,255,.45);
    background: rgba(255,255,255,.08);
}

.btn-ghost:hover {
    color: white;
    background: rgba(255,255,255,.16);
}

.trust-strip {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-top: 30px;
}

.trust-strip span {
    padding: 9px 12px;
    border: 1px solid rgba(255,255,255,.22);
    border-radius: 999px;
    background: rgba(255,255,255,.10);
    color: #e2e8f0;
    font-size: .92rem;
}

.market-preview {
    position: relative;
    min-height: 460px;
    border: 1px solid rgba(255,255,255,.25);
    border-radius: 8px;
    background: rgba(255,255,255,.10);
    box-shadow: 0 30px 80px rgba(0,0,0,.28);
    backdrop-filter: blur(18px);
    overflow: hidden;
}

.preview-toolbar {
    height: 58px;
    display: flex;
    align-items: center;
    gap: 9px;
    padding: 0 18px;
    border-bottom: 1px solid rgba(255,255,255,.18);
}

.preview-toolbar span {
    width: 11px;
    height: 11px;
    border-radius: 50%;
    background: #fb7185;
}

.preview-toolbar span:nth-child(2) { background: #facc15; }
.preview-toolbar span:nth-child(3) { background: #34d399; }
.preview-toolbar b { margin-left: 8px; color: #e0f2fe; font-size: .9rem; }

.preview-body {
    display: grid;
    grid-template-columns: 86px 1fr;
    min-height: 402px;
}

.preview-sidebar {
    display: grid;
    align-content: start;
    gap: 16px;
    padding: 24px;
    border-right: 1px solid rgba(255,255,255,.16);
}

.preview-sidebar i {
    display: block;
    height: 34px;
    border-radius: 8px;
    background: rgba(255,255,255,.18);
}

.preview-main {
    padding: 24px;
}

.preview-chart {
    height: 170px;
    border-radius: 8px;
    background:
        linear-gradient(180deg, rgba(255,255,255,.16), rgba(255,255,255,.05)),
        linear-gradient(135deg, transparent 35%, rgba(52,211,153,.55) 35% 47%, transparent 47%),
        linear-gradient(45deg, transparent 52%, rgba(110,168,254,.55) 52% 64%, transparent 64%);
    border: 1px solid rgba(255,255,255,.18);
}

.preview-products {
    display: grid;
    gap: 12px;
    margin-top: 18px;
}

.preview-products div {
    display: flex;
    justify-content: space-between;
    gap: 14px;
    padding: 16px;
    border: 1px solid rgba(255,255,255,.16);
    border-radius: 8px;
    background: rgba(255,255,255,.10);
}

.preview-products span { color: #bbf7d0; font-weight: 800; }

.preview-badge {
    position: absolute;
    right: 22px;
    bottom: 22px;
    display: grid;
    padding: 16px 18px;
    min-width: 160px;
    border-radius: 8px;
    background: white;
    color: #102a43;
    box-shadow: 0 20px 50px rgba(0,0,0,.22);
}

.preview-badge strong { font-size: 1.7rem; }
.preview-badge span { color: #64748b; font-weight: 700; }

.landing-stats {
    margin-top: -62px;
    position: relative;
    z-index: 2;
}

.landing-stats .stat-grid div {
    box-shadow: var(--shadow);
}

.split-head {
    display: flex;
    justify-content: space-between;
    align-items: end;
    gap: 22px;
    margin-bottom: 28px;
}

.split-head h2 {
    max-width: 720px;
    font-size: clamp(2rem, 5vw, 3.4rem);
    line-height: 1;
}

.split-head.centered {
    justify-content: center;
    text-align: center;
}

.category-showcase {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 14px;
}

.category-showcase a {
    display: grid;
    min-height: 116px;
    align-content: space-between;
    padding: 18px;
    border: 1px solid var(--line);
    border-radius: 8px;
    background:
        linear-gradient(135deg, color-mix(in srgb, var(--surface) 94%, var(--primary)), var(--surface));
    color: var(--text);
}

.category-showcase b { font-size: 1.08rem; }
.category-showcase span { color: var(--muted); }

.marketplace-band {
    background:
        linear-gradient(180deg, color-mix(in srgb, var(--surface) 80%, var(--bg)), var(--bg));
    border-top: 1px solid var(--line);
    border-bottom: 1px solid var(--line);
}

.workflow-grid {
    display: grid;
    grid-template-columns: minmax(0, .8fr) minmax(0, 1.2fr);
    gap: 38px;
    align-items: start;
}

.workflow-grid h2 {
    font-size: clamp(2rem, 5vw, 3.2rem);
    line-height: 1;
}

.workflow-steps {
    display: grid;
    gap: 14px;
}

.workflow-steps div {
    position: relative;
    padding: 24px 24px 24px 82px;
    border: 1px solid var(--line);
    border-radius: 8px;
    background: var(--surface);
}

.workflow-steps span {
    position: absolute;
    left: 22px;
    top: 24px;
    width: 38px;
    height: 38px;
    display: grid;
    place-items: center;
    border-radius: 50%;
    background: color-mix(in srgb, var(--primary) 16%, var(--surface));
    color: var(--primary);
    font-weight: 900;
}

.list-panel {
    height: 100%;
    padding: 24px;
    border: 1px solid var(--line);
    border-radius: 8px;
    background: var(--surface);
}

.dark-feature {
    color: white;
    background: linear-gradient(135deg, #0b1324, #143f64 54%, #0f766e);
}

.dark-feature .muted,
.dark-feature p {
    color: #dbeafe;
}

.dark-feature .landing-features div {
    background: rgba(255,255,255,.10);
    border-color: rgba(255,255,255,.18);
}

.dark-feature h2,
.dark-feature h3 {
    color: white;
}

.testimonial-grid blockquote p {
    min-height: 86px;
    color: var(--text);
    font-size: 1.05rem;
}

.testimonial-grid cite {
    display: block;
    margin-top: 18px;
    color: var(--muted);
    font-style: normal;
    font-weight: 800;
}

.pricing-section {
    background: color-mix(in srgb, var(--surface) 74%, var(--bg));
    border-top: 1px solid var(--line);
    border-bottom: 1px solid var(--line);
}

.pricing-grid div strong {
    display: block;
    margin: 10px 0 16px;
    color: var(--primary);
    font-size: 2rem;
}

.plan-label {
    display: inline-flex;
    margin-bottom: 12px;
    color: var(--muted);
    font-size: .82rem;
    font-weight: 900;
    text-transform: uppercase;
    letter-spacing: .08em;
}

.contact-panel {
    padding: 28px;
    border: 1px solid var(--line);
    border-radius: 8px;
    background: var(--surface);
    box-shadow: var(--shadow);
}

.admin-login-shell {
    min-height: calc(100vh - 72px);
    display: grid;
    place-items: center;
    padding: 48px 16px;
    background:
        linear-gradient(135deg, rgba(8,21,44,.92), rgba(15,63,100,.86)),
        radial-gradient(circle at 72% 18%, rgba(16,163,127,.28), transparent 30%),
        #0b1324;
}

.admin-login-card {
    width: min(100%, 520px);
    display: grid;
    gap: 22px;
    padding: 34px;
    border: 1px solid rgba(255,255,255,.16);
    border-radius: 8px;
    background: color-mix(in srgb, var(--surface) 94%, transparent);
    box-shadow: 0 28px 80px rgba(0,0,0,.28);
}

.admin-login-card h1 {
    margin-top: 8px;
    font-size: clamp(2.2rem, 7vw, 3.4rem);
}

.extension-grid {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(320px, .8fr);
    gap: 22px;
    align-items: stretch;
}

.extension-upload,
.extension-help,
.extension-card,
.empty-state {
    background: var(--surface);
    border: 1px solid var(--line);
    border-radius: 8px;
    padding: 24px;
}

.extension-upload {
    display: grid;
    gap: 16px;
}

.extension-help pre {
    margin: 0;
    padding: 16px;
    overflow: auto;
    border-radius: 8px;
    background: color-mix(in srgb, var(--bg) 86%, var(--surface));
    color: var(--text);
}

.extension-list {
    display: grid;
    gap: 14px;
}

.extension-card {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 18px;
}

.extension-card h3 {
    margin-bottom: 6px;
    font-size: 1.2rem;
}

.status-pill {
    display: inline-flex;
    align-items: center;
    padding: 7px 11px;
    border-radius: 999px;
    background: color-mix(in srgb, var(--accent) 18%, var(--surface));
    color: var(--accent);
    font-weight: 800;
}

.hero {
    background: linear-gradient(135deg, #102a43, #173f5f 48%, #0f766e);
    color: white;
    min-height: 680px;
    display: flex;
    align-items: center;
    overflow: hidden;
}

.hero-grid {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(320px, 520px);
    gap: 56px;
    align-items: center;
}

.hero h1 { font-size: clamp(3.2rem, 10vw, 7rem); line-height: .9; margin: 10px 0 20px; }
.eyebrow { color: var(--accent); text-transform: uppercase; font-size: .78rem; font-weight: 800; letter-spacing: .08em; }
.hero .lead { max-width: 650px; color: #dbeafe; font-size: 1.25rem; }

.hero-visual .window {
    min-height: 360px;
    border: 1px solid rgba(255,255,255,.24);
    border-radius: 8px;
    background: rgba(255,255,255,.10);
    box-shadow: var(--shadow);
    padding: 28px;
}
.hero-visual .window > span {
    display: inline-block;
    width: 12px;
    height: 12px;
    border-radius: 50%;
    background: #f87171;
    margin-right: 8px;
}
.hero-visual .window > span:nth-child(2) { background: #facc15; }
.hero-visual .window > span:nth-child(3) { background: #34d399; }
.code-line { height: 18px; background: rgba(255,255,255,.24); margin-top: 24px; border-radius: 4px; }
.mini-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 14px; margin-top: 36px; }
.mini-grid b { background: white; color: #102a43; padding: 20px; border-radius: 6px; text-align: center; }

.section { padding-top: 72px; padding-bottom: 72px; }
.section-head { display: flex; justify-content: space-between; align-items: end; gap: 16px; margin-bottom: 28px; }
.band { background: color-mix(in srgb, var(--surface) 72%, var(--bg)); border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }

.stat-band { background: var(--surface); border-bottom: 1px solid var(--line); }
.stat-grid, .metric-grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 18px;
}
.stat-grid div, .metric-grid div {
    padding: 24px;
    background: var(--surface);
    border: 1px solid var(--line);
    border-radius: 8px;
}
.stat-grid strong, .metric-grid strong { display: block; font-size: 2rem; color: var(--primary); }
.stat-grid span, .metric-grid span { color: var(--muted); }

.category-cloud, .admin-links {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}
.category-cloud a, .admin-links a {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    padding: 11px 14px;
    border: 1px solid var(--line);
    border-radius: 999px;
    background: var(--surface);
    color: var(--text);
}
.category-cloud span { color: var(--muted); }

.product-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 22px;
}
.product-card {
    overflow: hidden;
    background: var(--surface);
    border: 1px solid var(--line);
    border-radius: 8px;
    box-shadow: 0 10px 30px rgba(15, 23, 42, .05);
}
.product-art, .gallery-main {
    display: flex;
    align-items: end;
    min-height: 180px;
    padding: 18px;
    color: white;
    font-weight: 800;
    background:
        linear-gradient(135deg, rgba(35,100,219,.92), rgba(16,163,127,.82)),
        repeating-linear-gradient(45deg, rgba(255,255,255,.18) 0 8px, transparent 8px 18px);
}
.product-card h3 { font-size: 1.05rem; min-height: 48px; }
.product-card p { color: var(--muted); min-height: 48px; }
.product-meta { display: flex; gap: 12px; color: var(--muted); font-size: .88rem; flex-wrap: wrap; }

.feature-grid, .pricing-grid, .testimonial-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 20px;
}
.feature-grid { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.feature-grid div, .pricing-grid div, .testimonial-grid blockquote, .side-panel, .checkout-summary, .ticket {
    background: var(--surface);
    border: 1px solid var(--line);
    border-radius: 8px;
    padding: 24px;
}
.pricing-grid .highlight { border-color: var(--primary); box-shadow: var(--shadow); }

.list-product {
    display: flex;
    justify-content: space-between;
    gap: 12px;
    padding: 16px;
    margin-bottom: 10px;
    background: var(--surface);
    border: 1px solid var(--line);
    border-radius: 8px;
    color: var(--text);
}

.filters {
    position: relative;
    display: grid;
    grid-template-columns: 2fr 1.2fr 1fr 1fr 1fr 1fr auto;
    gap: 10px;
}
.live-results {
    position: absolute;
    top: 48px;
    left: 0;
    z-index: 10;
    width: min(420px, 100%);
    background: var(--surface);
    border: 1px solid var(--line);
    border-radius: 8px;
    display: none;
    box-shadow: var(--shadow);
}
.live-results a { display: flex; justify-content: space-between; padding: 12px 14px; border-bottom: 1px solid var(--line); color: var(--text); }

.pagination-wrap { display: flex; gap: 8px; margin-top: 32px; }
.pagination-wrap a { padding: 9px 14px; border: 1px solid var(--line); border-radius: 6px; color: var(--text); }
.pagination-wrap .active { background: var(--primary); color: white; }

.product-detail {
    display: grid;
    grid-template-columns: minmax(0, 1.25fr) 420px;
    gap: 32px;
    align-items: start;
}
.gallery-main { min-height: 460px; border-radius: 8px; font-size: 2rem; }
.thumb-row { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; margin-top: 12px; }
.thumb-row span { height: 92px; border-radius: 8px; background: color-mix(in srgb, var(--primary) 24%, var(--surface)); border: 1px solid var(--line); }
.buy-box {
    position: sticky;
    top: 96px;
    background: var(--surface);
    border: 1px solid var(--line);
    border-radius: 8px;
    padding: 28px;
    box-shadow: var(--shadow);
}
.price { font-size: 2rem; font-weight: 900; margin: 20px 0; }

.narrow { max-width: 760px; }
.stack-form { display: grid; gap: 14px; }
.wide-form { max-width: 1080px; }
.inline-form { display: flex; gap: 10px; }
.panel-table { color: var(--text); background: var(--surface); border: 1px solid var(--line); }
.panel-table th { color: var(--muted); }
.ticket { margin-bottom: 12px; }
.ticket span { float: right; color: var(--muted); }
details { border-bottom: 1px solid var(--line); padding: 16px 0; }
summary { cursor: pointer; font-weight: 800; }
.footer { background: var(--surface); border-top: 1px solid var(--line); }
.footer a { display: block; color: var(--muted); margin-bottom: 8px; }

@media (max-width: 992px) {
    .hero { min-height: auto; padding: 96px 0 48px; }
    .hero-grid, .product-detail, .landing-hero-grid, .workflow-grid, .extension-grid { grid-template-columns: 1fr; }
    .landing-hero { min-height: auto; }
    .landing-hero-grid { padding-bottom: 96px; }
    .filters, .product-grid, .feature-grid, .pricing-grid, .testimonial-grid, .stat-grid, .metric-grid, .category-showcase { grid-template-columns: 1fr 1fr; }
    .buy-box { position: static; }
}

@media (max-width: 640px) {
    .hero h1 { font-size: 3.4rem; }
    .landing-copy h1 { font-size: 4rem; }
    .filters, .product-grid, .feature-grid, .pricing-grid, .testimonial-grid, .stat-grid, .metric-grid, .category-showcase { grid-template-columns: 1fr; }
    .section-head, .inline-form, .split-head { display: grid; }
    .gallery-main { min-height: 300px; }
    .market-preview { min-height: 380px; }
    .preview-body { grid-template-columns: 64px 1fr; }
    .preview-main { padding: 16px; }
    .preview-sidebar { padding: 18px; }
    .preview-products div { display: grid; }
    .preview-badge { position: static; margin: 16px; }
    .workflow-steps div { padding: 22px; }
    .workflow-steps span { position: static; margin-bottom: 12px; }
    .extension-card { display: grid; }
}
