:root {
    --ink: #111827;
    --muted: #64748b;
    --line: #e7eaf1;
    --surface: rgba(255, 255, 255, .88);
    --primary: #5b5ce2;
    --primary-dark: #4546c7;
    --cyan: #20b8c5;
    --danger: #dc2626;
    --success: #15803d;
    --shadow: 0 20px 55px rgba(30, 41, 59, .09);
    --radius: 24px;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
    margin: 0;
    color: var(--ink);
    font-family: -apple-system, BlinkMacSystemFont, "SF Pro Text", "PingFang SC", "Helvetica Neue", "Segoe UI", "Microsoft YaHei UI", sans-serif;
    background: #f7f8fc;
    -webkit-font-smoothing: antialiased;
}
button, input, textarea, select { font: inherit; }
button, a { -webkit-tap-highlight-color: transparent; }
a { color: inherit; text-decoration: none; }
img { display: block; max-width: 100%; }
svg { display: block; }
[hidden] { display: none !important; }

.public-page { min-height: 100vh; overflow-x: hidden; }
.ambient { position: fixed; z-index: -1; width: 560px; height: 560px; border-radius: 50%; filter: blur(90px); pointer-events: none; opacity: .32; }
.ambient-one { top: -320px; left: -180px; background: #c4b5fd; }
.ambient-two { top: 160px; right: -360px; background: #a5f3fc; }
.shell { width: min(1180px, calc(100% - 40px)); margin-inline: auto; }

.site-header { height: 88px; display: flex; align-items: center; justify-content: space-between; }
.brand { display: inline-flex; align-items: center; gap: 12px; min-width: 0; font-size: 16px; font-weight: 760; letter-spacing: -.01em; }
.brand-mark { display: grid; place-items: center; width: 38px; height: 38px; border-radius: 12px; color: #fff; background: linear-gradient(140deg, #6969ef, #3838a8); box-shadow: 0 9px 24px rgba(79, 70, 229, .26); }
.brand-mark svg { width: 22px; height: 22px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linejoin: round; }
.header-actions { display: flex; align-items: center; gap: 22px; }
.subtle-link { font-size: 14px; color: #475569; transition: color .2s ease; }
.subtle-link:hover { color: var(--primary); }
.button { min-height: 50px; display: inline-flex; align-items: center; justify-content: center; gap: 10px; padding: 0 22px; border: 0; border-radius: 14px; font-weight: 700; font-size: 14px; cursor: pointer; transition: transform .2s ease, box-shadow .2s ease, background .2s ease; }
.button:hover { transform: translateY(-2px); }
.button svg { width: 18px; height: 18px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.button-small { min-height: 42px; padding-inline: 18px; border-radius: 12px; }
.button-dark { color: #fff; background: #151927; box-shadow: 0 8px 22px rgba(15, 23, 42, .15); }
.button-primary { color: #fff; background: linear-gradient(135deg, #6263e6, #4c4dd2); box-shadow: 0 14px 30px rgba(79, 70, 229, .24); }
.button-ghost { color: #3730a3; background: rgba(255,255,255,.74); border: 1px solid rgba(99,102,241,.18); }

.hero { min-height: 610px; display: grid; grid-template-columns: 1.12fr .88fr; align-items: center; gap: 64px; padding-block: 72px 92px; }
.eyebrow { display: flex; align-items: center; gap: 10px; color: #5b5ce2; font-size: 12px; font-weight: 800; letter-spacing: .14em; text-transform: uppercase; }
.eyebrow span { width: 28px; height: 1px; background: currentColor; }
.hero h1 { margin: 24px 0 22px; font-size: clamp(48px, 6.5vw, 78px); line-height: 1.04; letter-spacing: -.055em; font-weight: 790; }
.hero h1 em { font-style: normal; background: linear-gradient(100deg, #5b5ce2 12%, #2879c8 55%, #12a6a8); -webkit-background-clip: text; color: transparent; }
.hero-copy > p { max-width: 620px; margin: 0; color: var(--muted); font-size: 18px; line-height: 1.8; }
.hero-actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 34px; }
.hero-panel { position: relative; min-height: 450px; border: 1px solid rgba(255,255,255,.85); border-radius: 42px; overflow: hidden; background: linear-gradient(150deg, rgba(255,255,255,.92), rgba(238,241,255,.82)); box-shadow: 0 35px 90px rgba(73, 82, 139, .14); }
.hero-panel::before { content: ""; position: absolute; inset: 18%; border-radius: 50%; background: radial-gradient(circle, rgba(99,102,241,.16), transparent 65%); }
.hero-orbit { position: absolute; left: 50%; top: 50%; border: 1px solid rgba(99,102,241,.14); border-radius: 50%; transform: translate(-50%,-50%) rotate(-18deg); }
.orbit-one { width: 420px; height: 260px; }
.orbit-two { width: 310px; height: 390px; }
.metric { position: absolute; z-index: 2; }
.metric-main { inset: 50% auto auto 50%; width: 190px; height: 190px; display: grid; place-content: center; text-align: center; border-radius: 50%; transform: translate(-50%,-50%); color: #fff; background: linear-gradient(145deg, #6667e9, #4647c4); box-shadow: 0 28px 55px rgba(79,70,229,.32), inset 0 1px rgba(255,255,255,.3); }
.metric-main strong { font-size: 64px; line-height: 1; letter-spacing: -.06em; }
.metric-main span { margin-top: 9px; font-size: 14px; opacity: .84; }
.metric-float { display: flex; align-items: center; gap: 12px; min-width: 156px; padding: 14px 17px; border-radius: 18px; background: rgba(255,255,255,.94); border: 1px solid rgba(226,232,240,.9); box-shadow: 0 18px 35px rgba(51,65,85,.12); animation: float 5s ease-in-out infinite; }
.metric-top { top: 60px; right: 28px; }
.metric-bottom { bottom: 64px; left: 24px; animation-delay: -2.5s; }
.metric-icon { display: grid; place-items: center; width: 38px; height: 38px; border-radius: 12px; color: #7c3aed; background: #f3e8ff; font-size: 18px; }
.metric-icon-blue { color: #0284c7; background: #e0f2fe; }
.metric-float strong, .metric-float small { display: block; }
.metric-float strong { font-size: 19px; }
.metric-float small { margin-top: 2px; color: #64748b; font-size: 11px; }
.hero-note { position: absolute; bottom: 22px; right: 28px; color: #9298ac; font-size: 9px; font-weight: 800; letter-spacing: .18em; }
@keyframes float { 0%,100% { transform: translateY(0) } 50% { transform: translateY(-8px) } }

.catalog { padding-block: 72px 110px; }
.section-heading { display: flex; align-items: flex-end; justify-content: space-between; gap: 32px; margin-bottom: 30px; }
.section-kicker { color: var(--primary); font-size: 11px; font-weight: 800; letter-spacing: .16em; text-transform: uppercase; }
.section-heading h2 { margin: 9px 0 8px; font-size: clamp(34px, 5vw, 48px); letter-spacing: -.04em; }
.section-heading p { margin: 0; color: var(--muted); font-size: 15px; }
.search-box { width: min(360px, 100%); height: 50px; flex: 0 1 360px; display: flex; align-items: center; gap: 10px; padding: 0 15px; border: 1px solid var(--line); border-radius: 15px; background: rgba(255,255,255,.84); box-shadow: 0 8px 24px rgba(30,41,59,.04); transition: border .2s, box-shadow .2s; }
.search-box:focus-within { border-color: rgba(91,92,226,.5); box-shadow: 0 0 0 4px rgba(91,92,226,.08); }
.search-box svg { width: 19px; height: 19px; flex: none; fill: none; stroke: #94a3b8; stroke-width: 2; stroke-linecap: round; }
.search-box input { width: 100%; border: 0; outline: 0; color: var(--ink); background: transparent; font-size: 14px; }
.search-box input::placeholder { color: #9aa5b5; }
.filter-row { display: flex; gap: 9px; overflow-x: auto; padding: 2px 2px 18px; scrollbar-width: none; }
.filter-row::-webkit-scrollbar { display: none; }
.filter-chip { flex: none; height: 42px; padding: 0 16px; border: 1px solid #e4e7ed; border-radius: 12px; color: #5f6b7c; background: rgba(255,255,255,.78); cursor: pointer; font-size: 13px; font-weight: 650; transition: all .2s ease; }
.filter-chip span { margin-left: 5px; color: #9ba5b5; font-size: 11px; }
.filter-chip:hover { color: var(--primary); border-color: #cdd0fb; }
.filter-chip.active { color: #fff; border-color: #1a1f2e; background: #1a1f2e; box-shadow: 0 8px 20px rgba(15,23,42,.14); }
.filter-chip.active span { color: #cbd5e1; }

.template-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 24px; }
.template-card { min-width: 0; overflow: hidden; border: 1px solid rgba(226,232,240,.92); border-radius: 26px; background: rgba(255,255,255,.9); box-shadow: 0 14px 40px rgba(30,41,59,.06); transition: transform .28s ease, box-shadow .28s ease, border-color .28s ease; }
.template-card:hover { transform: translateY(-6px); border-color: rgba(99,102,241,.24); box-shadow: 0 26px 60px rgba(30,41,59,.12); }
.preview-stage { position: relative; height: 340px; overflow: hidden; padding: 32px 34px; background: linear-gradient(145deg, #f0f1ff, #e5e9fa); }
.accent-1 .preview-stage { background: linear-gradient(145deg, #eefbfb, #e3f3f7); }
.accent-2 .preview-stage { background: linear-gradient(145deg, #f7efff, #eee7fa); }
.preview-stage::after { content: ""; position: absolute; width: 240px; height: 240px; right: -80px; bottom: -100px; border-radius: 50%; background: rgba(255,255,255,.36); }
.browser-frame { position: relative; z-index: 1; width: 90%; height: 258px; overflow: hidden; border: 5px solid #202535; border-radius: 15px; background: #202535; box-shadow: 0 24px 46px rgba(30,41,59,.22); transition: transform .35s ease; }
.template-card:hover .browser-frame { transform: translateY(-3px) rotate(-.3deg); }
.browser-bar { height: 23px; display: flex; align-items: center; gap: 5px; padding: 0 8px; background: #202535; }
.browser-bar i { width: 5px; height: 5px; border-radius: 50%; background: #70778b; }
.browser-bar span { width: 44%; height: 6px; margin-left: 7px; border-radius: 5px; background: #373d50; }
.browser-screen { height: calc(100% - 23px); overflow: hidden; border-radius: 7px; background: #eef2f7; }
.browser-screen img { width: 100%; height: 100%; object-fit: cover; object-position: top center; }
.phone-frame { position: absolute; z-index: 3; right: 27px; bottom: 22px; width: 92px; height: 190px; padding: 7px; border: 4px solid #202535; border-radius: 21px; background: #202535; box-shadow: 0 20px 40px rgba(30,41,59,.28); transition: transform .35s ease; }
.template-card:hover .phone-frame { transform: translateY(-4px) rotate(1deg); }
.phone-speaker { position: absolute; z-index: 2; left: 50%; top: 4px; width: 30px; height: 5px; border-radius: 0 0 6px 6px; background: #202535; transform: translateX(-50%); }
.phone-screen { width: 100%; height: 100%; overflow: hidden; border-radius: 13px; background: #edf1f7; }
.phone-screen img { width: 100%; height: 100%; object-fit: cover; object-position: top center; }
.recommend-badge { position: absolute; z-index: 4; top: 18px; right: 18px; display: inline-flex; align-items: center; gap: 5px; padding: 7px 10px; border: 1px solid rgba(255,255,255,.7); border-radius: 99px; color: #fff; background: rgba(26,31,46,.86); box-shadow: 0 8px 20px rgba(30,41,59,.12); backdrop-filter: blur(10px); font-size: 10px; font-weight: 750; }
.recommend-badge b { color: #facc15; }
.card-content { padding: 25px 26px 23px; }
.card-meta { display: flex; align-items: center; gap: 8px; margin-bottom: 13px; }
.card-meta span { padding: 5px 9px; border-radius: 7px; color: #5758c8; background: #f0f0ff; font-size: 10px; font-weight: 750; }
.card-meta span + span { color: #0f8892; background: #eafafa; }
.card-content h3 { margin: 0; font-size: 23px; letter-spacing: -.025em; }
.card-content > p { min-height: 46px; margin: 10px 0 20px; color: #687386; font-size: 13px; line-height: 1.75; }
.card-footer { display: flex; align-items: center; justify-content: space-between; gap: 16px; padding-top: 18px; border-top: 1px solid #edf0f4; }
.device-labels { display: flex; gap: 12px; color: #9aa4b2; font-size: 10px; font-weight: 650; }
.device-labels span::before { content: ""; display: inline-block; width: 5px; height: 5px; margin-right: 5px; border-radius: 50%; background: #a5b4fc; vertical-align: 1px; }
.demo-link { display: inline-flex; align-items: center; gap: 6px; color: #3435a4; font-size: 13px; font-weight: 750; }
.demo-link svg { width: 18px; height: 18px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; transition: transform .2s; }
.demo-link:hover svg { transform: translate(2px,-2px); }
.demo-link.disabled { color: #a0a8b5; }
.empty-state { padding: 90px 20px; text-align: center; border: 1px dashed #d8ddea; border-radius: 24px; color: var(--muted); background: rgba(255,255,255,.55); }
.empty-state > span { font-size: 42px; color: #a5b4fc; }
.empty-state h3 { margin: 10px 0 6px; color: var(--ink); }
.empty-state p { margin: 0; font-size: 14px; }
.site-footer { min-height: 130px; display: flex; align-items: center; justify-content: space-between; gap: 30px; border-top: 1px solid #e5e8ef; }
.site-footer div { display: flex; flex-direction: column; gap: 6px; }
.site-footer strong { font-size: 14px; }
.site-footer span, .site-footer p { margin: 0; color: #929cad; font-size: 12px; }
.back-top { position: fixed; z-index: 20; right: 24px; bottom: 24px; width: 46px; height: 46px; display: grid; place-items: center; border: 0; border-radius: 14px; color: #fff; background: #1a1f2e; box-shadow: 0 12px 28px rgba(15,23,42,.22); cursor: pointer; opacity: 0; pointer-events: none; transform: translateY(8px); transition: .2s ease; }
.back-top.show { opacity: 1; pointer-events: auto; transform: none; }
.back-top svg { width: 20px; height: 20px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }

/* Admin */
.admin-page { min-height: 100vh; background: #f3f5f9; }
.admin-shell { width: min(1440px, 100%); min-height: 100vh; display: grid; grid-template-columns: 240px 1fr; margin: auto; }
.admin-sidebar { position: sticky; top: 0; height: 100vh; display: flex; flex-direction: column; padding: 26px 20px; color: #dbe2ef; background: #151a27; }
.admin-sidebar .brand { color: #fff; padding-inline: 6px; }
.admin-nav { display: grid; gap: 6px; margin-top: 38px; }
.admin-nav a { display: flex; align-items: center; gap: 11px; min-height: 44px; padding: 0 13px; border-radius: 11px; color: #9fa9bb; font-size: 13px; font-weight: 650; }
.admin-nav a:hover, .admin-nav a.active { color: #fff; background: rgba(255,255,255,.08); }
.admin-nav svg { width: 18px; height: 18px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.sidebar-footer { margin-top: auto; padding: 17px 9px 0; border-top: 1px solid rgba(255,255,255,.08); }
.sidebar-footer a { display: block; color: #909bad; font-size: 12px; }
.sidebar-footer a + a { margin-top: 12px; }
.sidebar-footer form { margin: 12px 0 0; }
.sidebar-link { padding: 0; border: 0; color: #909bad; background: transparent; cursor: pointer; font-size: 12px; }
.sidebar-link:hover { color: #fff; }
.admin-main { min-width: 0; padding: 34px 38px 60px; }
.admin-topbar { display: flex; align-items: center; justify-content: space-between; gap: 24px; margin-bottom: 28px; }
.admin-title small { display: block; margin-bottom: 4px; color: #8a95a7; font-size: 12px; }
.admin-title h1 { margin: 0; font-size: 28px; letter-spacing: -.035em; }
.admin-top-actions { display: flex; gap: 10px; }
.admin-button { min-height: 42px; display: inline-flex; align-items: center; justify-content: center; gap: 8px; padding: 0 16px; border: 1px solid #dfe3eb; border-radius: 11px; color: #414b5c; background: #fff; cursor: pointer; font-weight: 700; font-size: 13px; }
.admin-button:hover { border-color: #bfc5d0; }
.admin-button.primary { color: #fff; border-color: var(--primary); background: var(--primary); }
.admin-button.danger { color: var(--danger); border-color: #fecaca; background: #fff7f7; }
.admin-button svg { width: 17px; height: 17px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.admin-grid { display: grid; grid-template-columns: minmax(0, 1.42fr) minmax(310px, .58fr); align-items: start; gap: 22px; }
.admin-panel { overflow: hidden; border: 1px solid #e2e6ed; border-radius: 18px; background: #fff; box-shadow: 0 8px 30px rgba(30,41,59,.04); }
.panel-head { min-height: 66px; display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: 0 20px; border-bottom: 1px solid #edf0f4; }
.panel-head h2 { margin: 0; font-size: 15px; }
.panel-head span { color: #8d97a6; font-size: 11px; }
.panel-body { padding: 20px; }
.admin-stats { display: grid; grid-template-columns: repeat(3, 1fr); gap: 14px; margin-bottom: 22px; }
.stat-card { padding: 19px; border: 1px solid #e4e8ef; border-radius: 16px; background: #fff; }
.stat-card span { color: #7c8798; font-size: 11px; }
.stat-card strong { display: block; margin-top: 7px; font-size: 28px; letter-spacing: -.04em; }
.template-list { display: grid; gap: 10px; padding: 14px; }
.template-row { display: grid; grid-template-columns: 94px minmax(160px,1fr) auto; align-items: center; gap: 14px; padding: 10px; border: 1px solid #e9ecf1; border-radius: 13px; }
.row-thumb { width: 94px; height: 60px; overflow: hidden; border-radius: 9px; background: #eef1f6; }
.row-thumb img { width: 100%; height: 100%; object-fit: cover; object-position: top; }
.row-copy { min-width: 0; }
.row-copy strong { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: 13px; }
.row-copy div { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 7px; }
.mini-tag { padding: 3px 7px; border-radius: 6px; color: #606b7d; background: #f0f2f6; font-size: 9px; font-weight: 700; }
.mini-tag.recommend { color: #7c3aed; background: #f3e8ff; }
.mini-tag.hidden { color: #b45309; background: #fff7ed; }
.row-actions { display: flex; gap: 6px; }
.icon-button { width: 36px; height: 36px; display: grid; place-items: center; padding: 0; border: 1px solid #e2e6ed; border-radius: 9px; color: #667085; background: #fff; cursor: pointer; }
.icon-button:hover { color: var(--primary); border-color: #c8c9fa; }
.icon-button.danger:hover { color: var(--danger); border-color: #fecaca; }
.icon-button svg { width: 16px; height: 16px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.form-grid { display: grid; grid-template-columns: repeat(2, minmax(0,1fr)); gap: 16px; }
.field { min-width: 0; }
.field.full { grid-column: 1 / -1; }
.field label { display: block; margin-bottom: 7px; color: #465164; font-size: 11px; font-weight: 750; }
.field input[type="text"], .field input[type="url"], .field input[type="number"], .field input[type="password"], .field textarea, .field select {
    width: 100%; min-height: 43px; padding: 10px 12px; border: 1px solid #dfe3ea; border-radius: 10px; outline: 0; color: #222b39; background: #fff; font-size: 13px; transition: border .2s, box-shadow .2s;
}
.field textarea { min-height: 92px; resize: vertical; line-height: 1.6; }
.field input:focus, .field textarea:focus, .field select:focus { border-color: rgba(91,92,226,.65); box-shadow: 0 0 0 3px rgba(91,92,226,.08); }
.field-help { margin: 6px 0 0; color: #929baa; font-size: 10px; line-height: 1.5; }
.check-row { display: flex; flex-wrap: wrap; gap: 18px; }
.check-label { display: inline-flex; align-items: center; gap: 8px; color: #4b5565; font-size: 12px; font-weight: 650; cursor: pointer; }
.check-label input { width: 17px; height: 17px; accent-color: var(--primary); }
.upload-box { min-height: 120px; display: grid; place-items: center; padding: 14px; border: 1px dashed #cfd5df; border-radius: 12px; color: #778294; background: #fafbfc; text-align: center; cursor: pointer; }
.upload-box:hover { border-color: #aeb3f4; background: #fafaff; }
.upload-box input { position: absolute; width: 1px; height: 1px; opacity: 0; pointer-events: none; }
.upload-box svg { width: 24px; height: 24px; margin: 0 auto 7px; fill: none; stroke: #7374df; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.upload-box strong { display: block; color: #505b6c; font-size: 11px; }
.upload-box span { display: block; margin-top: 4px; font-size: 9px; }
.current-image { width: 100%; max-height: 105px; margin-bottom: 10px; object-fit: cover; object-position: top; border-radius: 9px; }
.form-actions { display: flex; justify-content: flex-end; gap: 10px; margin-top: 20px; padding-top: 18px; border-top: 1px solid #edf0f4; }
.flash { display: flex; align-items: flex-start; gap: 10px; margin-bottom: 20px; padding: 13px 15px; border-radius: 12px; font-size: 12px; line-height: 1.5; }
.flash.success { color: #166534; background: #ecfdf3; border: 1px solid #bbf7d0; }
.flash.error { color: #991b1b; background: #fff1f2; border: 1px solid #fecdd3; }
.flash.warning { color: #92400e; background: #fffbeb; border: 1px solid #fde68a; }
.flash b { flex: none; }
.empty-list { padding: 50px 20px; text-align: center; color: #8a95a5; font-size: 12px; }
.settings-panel { margin-top: 22px; }

/* Login and setup */
.auth-page { min-height: 100vh; display: grid; grid-template-columns: minmax(0, .9fr) minmax(480px, 1.1fr); background: #f6f7fb; }
.auth-visual { position: relative; display: flex; flex-direction: column; justify-content: space-between; overflow: hidden; padding: 52px; color: #fff; background: linear-gradient(145deg, #17152e, #282663 56%, #244d63); }
.auth-visual::before, .auth-visual::after { content: ""; position: absolute; border-radius: 50%; filter: blur(2px); }
.auth-visual::before { width: 520px; height: 520px; right: -180px; top: 20%; background: radial-gradient(circle, rgba(129,140,248,.36), transparent 66%); }
.auth-visual::after { width: 330px; height: 330px; left: -140px; bottom: -90px; background: radial-gradient(circle, rgba(34,211,238,.2), transparent 68%); }
.auth-brand { position: relative; z-index: 1; display: flex; align-items: center; gap: 12px; font-weight: 750; }
.auth-message { position: relative; z-index: 1; max-width: 560px; }
.auth-message span { color: #a5b4fc; font-size: 11px; font-weight: 800; letter-spacing: .16em; text-transform: uppercase; }
.auth-message h1 { margin: 16px 0 18px; font-size: clamp(42px,5vw,68px); line-height: 1.08; letter-spacing: -.055em; }
.auth-message p { max-width: 480px; margin: 0; color: #aeb8cc; font-size: 15px; line-height: 1.8; }
.auth-foot { position: relative; z-index: 1; color: #8f9ab1; font-size: 10px; letter-spacing: .08em; }
.auth-form-wrap { display: grid; place-items: center; padding: 40px; }
.auth-card { width: min(440px, 100%); }
.auth-card h2 { margin: 0 0 8px; font-size: 30px; letter-spacing: -.04em; }
.auth-card > p { margin: 0 0 30px; color: #7b8697; font-size: 13px; line-height: 1.7; }
.auth-card .field { margin-bottom: 16px; }
.auth-submit { width: 100%; min-height: 50px; margin-top: 7px; border: 0; border-radius: 12px; color: #fff; background: var(--primary); cursor: pointer; font-weight: 750; box-shadow: 0 12px 26px rgba(91,92,226,.22); }
.auth-note { margin-top: 20px; color: #98a1af; font-size: 10px; text-align: center; }

@media (max-width: 1050px) {
    .hero { grid-template-columns: 1fr 420px; gap: 38px; }
    .hero h1 { font-size: 58px; }
    .preview-stage { height: 300px; }
    .browser-frame { height: 225px; }
    .phone-frame { width: 82px; height: 168px; }
    .admin-grid { grid-template-columns: 1fr; }
}

@media (max-width: 820px) {
    .shell { width: min(100% - 28px, 680px); }
    .site-header { height: 76px; }
    .subtle-link { display: none; }
    .hero { min-height: auto; grid-template-columns: 1fr; gap: 44px; padding-block: 56px 72px; }
    .hero-copy { text-align: center; }
    .eyebrow, .hero-actions { justify-content: center; }
    .hero-copy > p { margin-inline: auto; }
    .hero-panel { width: min(470px, 100%); min-height: 410px; margin-inline: auto; }
    .section-heading { align-items: stretch; flex-direction: column; }
    .search-box { flex-basis: 50px; width: 100%; }
    .template-grid { grid-template-columns: 1fr; }
    .preview-stage { height: 360px; }
    .browser-frame { height: 280px; }
    .phone-frame { width: 98px; height: 202px; }
    .admin-shell { display: block; }
    .admin-sidebar { position: static; width: 100%; height: auto; flex-direction: row; align-items: center; justify-content: space-between; padding: 14px 18px; }
    .admin-nav { display: none; }
    .sidebar-footer { display: flex; align-items: center; gap: 14px; margin: 0; padding: 0; border: 0; }
    .sidebar-footer a + a { margin: 0; }
    .sidebar-footer form { margin: 0; }
    .admin-main { padding: 25px 18px 50px; }
    .auth-page { grid-template-columns: 1fr; }
    .auth-visual { min-height: 320px; padding: 34px 28px; }
    .auth-message h1 { font-size: 42px; }
    .auth-message p { font-size: 13px; }
    .auth-foot { display: none; }
}

@media (max-width: 560px) {
    .shell { width: min(100% - 24px, 520px); }
    .brand { font-size: 14px; }
    .brand-mark { width: 35px; height: 35px; }
    .header-actions .button { min-height: 38px; padding-inline: 13px; font-size: 12px; }
    .hero { padding-block: 48px 62px; }
    .hero h1 { margin-top: 20px; font-size: 44px; }
    .hero-copy > p { font-size: 15px; line-height: 1.75; }
    .hero-actions { display: grid; grid-template-columns: 1fr; }
    .hero-panel { min-height: 330px; border-radius: 30px; }
    .metric-main { width: 150px; height: 150px; }
    .metric-main strong { font-size: 50px; }
    .metric-float { min-width: 125px; padding: 10px 12px; }
    .metric-icon { width: 32px; height: 32px; }
    .metric-top { top: 32px; right: 12px; }
    .metric-bottom { bottom: 44px; left: 12px; }
    .orbit-one { width: 340px; height: 205px; }
    .orbit-two { width: 240px; height: 310px; }
    .hero-note { display: none; }
    .catalog { padding-block: 58px 80px; }
    .section-heading h2 { font-size: 35px; }
    .filter-row { margin-inline: -12px; padding-inline: 12px; }
    .preview-stage { height: 260px; padding: 24px 20px; }
    .browser-frame { width: 91%; height: 200px; }
    .phone-frame { right: 17px; bottom: 16px; width: 72px; height: 148px; border-width: 3px; border-radius: 17px; padding: 5px; }
    .phone-screen { border-radius: 10px; }
    .recommend-badge { top: 12px; right: 12px; }
    .card-content { padding: 21px 20px 19px; }
    .card-content h3 { font-size: 21px; }
    .card-footer { align-items: flex-end; }
    .device-labels { flex-direction: column; gap: 4px; }
    .site-footer { align-items: flex-start; flex-direction: column; justify-content: center; }
    .back-top { right: 14px; bottom: 14px; }
    .admin-topbar { align-items: flex-start; flex-direction: column; }
    .admin-top-actions { width: 100%; }
    .admin-top-actions .admin-button { flex: 1; }
    .admin-stats { grid-template-columns: 1fr 1fr; }
    .stat-card:last-child { grid-column: 1 / -1; }
    .template-row { grid-template-columns: 76px minmax(0,1fr); }
    .row-thumb { width: 76px; height: 54px; }
    .row-actions { grid-column: 1 / -1; justify-content: flex-end; padding-top: 2px; }
    .form-grid { grid-template-columns: 1fr; }
    .field.full { grid-column: auto; }
    .form-actions { flex-direction: column-reverse; }
    .form-actions .admin-button { width: 100%; }
    .auth-visual { min-height: 280px; }
    .auth-message h1 { font-size: 36px; }
    .auth-form-wrap { padding: 38px 22px; }
}

@media (prefers-reduced-motion: reduce) {
    html { scroll-behavior: auto; }
    *, *::before, *::after { animation-duration: .01ms !important; animation-iteration-count: 1 !important; transition-duration: .01ms !important; }
}

/* Admin v1.1 — product-grade workspace */
.admin-page {
    --admin-bg: #f6f7fb;
    --admin-panel: #fff;
    --admin-text: #172033;
    --admin-muted: #758198;
    --admin-line: #e7eaf1;
    --admin-primary: #5b5ce2;
    --admin-primary-dark: #4849c8;
    min-height: 100vh;
    color: var(--admin-text);
    background: var(--admin-bg);
}
.admin-page button, .admin-page input, .admin-page textarea, .admin-page select { font: inherit; }
.admin-page svg { fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.admin-shell { width: 100%; min-height: 100vh; display: grid; grid-template-columns: 264px minmax(0, 1fr); margin: 0; }
.admin-sidebar {
    position: sticky; z-index: 60; top: 0; width: auto; height: 100vh; display: flex; flex-direction: column;
    padding: 28px 20px 22px; color: #c9d1df; background: #141927; border-right: 1px solid rgba(255,255,255,.04);
}
.sidebar-brand { display: flex; align-items: center; justify-content: space-between; min-height: 48px; padding: 0 8px; }
.admin-logo { min-width: 0; display: flex; align-items: center; gap: 12px; color: #fff; }
.admin-logo .brand-mark { width: 40px; height: 40px; flex: none; border-radius: 13px; background: linear-gradient(145deg, #7172f2, #5152d5); box-shadow: 0 10px 25px rgba(91,92,226,.32); }
.admin-logo > span:last-child { min-width: 0; }
.admin-logo strong, .admin-logo small { display: block; }
.admin-logo strong { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: 15px; letter-spacing: -.01em; }
.admin-logo small { margin-top: 3px; color: #788399; font-size: 10px; font-weight: 600; }
.sidebar-close { display: none; width: 34px; height: 34px; border: 0; border-radius: 10px; color: #98a3b7; background: rgba(255,255,255,.06); font-size: 21px; cursor: pointer; }
.nav-label { margin: 38px 12px 10px; color: #5f697e; font-size: 10px; font-weight: 800; letter-spacing: .14em; text-transform: uppercase; }
.admin-nav { display: grid; gap: 6px; margin: 0; }
.admin-nav a { position: relative; min-height: 48px; display: flex; align-items: center; gap: 12px; padding: 0 14px; border-radius: 12px; color: #919caf; font-size: 13px; font-weight: 680; transition: .2s ease; }
.admin-nav a::before { content: ""; position: absolute; left: -20px; width: 3px; height: 20px; border-radius: 0 4px 4px 0; background: transparent; }
.admin-nav a:hover { color: #e4e9f2; background: rgba(255,255,255,.045); }
.admin-nav a.active { color: #fff; background: rgba(112,113,242,.15); box-shadow: inset 0 0 0 1px rgba(129,140,248,.08); }
.admin-nav a.active::before { background: #7778f4; }
.admin-nav svg { width: 19px; height: 19px; flex: none; }
.admin-nav b { min-width: 24px; margin-left: auto; padding: 3px 7px; border-radius: 99px; color: #8994aa; background: rgba(255,255,255,.06); font-size: 9px; text-align: center; }
.admin-nav a.active b { color: #cfd0ff; background: rgba(123,124,244,.16); }
.sidebar-tip { margin-top: auto; padding: 16px; border: 1px solid rgba(255,255,255,.065); border-radius: 14px; background: rgba(255,255,255,.035); }
.sidebar-tip span, .sidebar-tip strong, .sidebar-tip small { display: block; }
.sidebar-tip span { color: #657086; font-size: 9px; font-weight: 800; letter-spacing: .1em; text-transform: uppercase; }
.sidebar-tip strong { margin-top: 10px; color: #dce3ee; font-size: 12px; }
.sidebar-tip strong i { display: inline-block; width: 7px; height: 7px; margin-right: 7px; border-radius: 50%; background: #34d399; box-shadow: 0 0 0 4px rgba(52,211,153,.09); }
.sidebar-tip small { margin-top: 6px; color: #727d92; font-size: 10px; line-height: 1.5; }
.sidebar-footer { display: grid; gap: 4px; margin: 18px 0 0; padding: 14px 0 0; border-top: 1px solid rgba(255,255,255,.06); }
.sidebar-footer a, .sidebar-footer button { width: 100%; min-height: 38px; display: flex; align-items: center; gap: 10px; padding: 0 10px; border: 0; border-radius: 9px; color: #7f899d; background: transparent; cursor: pointer; font-size: 11px; text-align: left; }
.sidebar-footer a:hover, .sidebar-footer button:hover { color: #e3e8f1; background: rgba(255,255,255,.04); }
.sidebar-footer svg { width: 16px; height: 16px; }
.sidebar-footer form { margin: 0; }
.sidebar-scrim { display: none; }

.admin-main { min-width: 0; padding: 0; background: var(--admin-bg); }
.admin-topbar { position: sticky; z-index: 30; top: 0; min-height: 88px; display: flex; align-items: center; justify-content: space-between; gap: 24px; margin: 0; padding: 18px clamp(24px, 3vw, 48px); border-bottom: 1px solid rgba(226,230,239,.88); background: rgba(246,247,251,.88); backdrop-filter: blur(18px); }
.topbar-left { display: flex; align-items: center; gap: 14px; min-width: 0; }
.mobile-menu { display: none; width: 42px; height: 42px; place-items: center; padding: 0; border: 1px solid var(--admin-line); border-radius: 11px; color: #4e596c; background: #fff; }
.mobile-menu svg { width: 20px; height: 20px; }
.admin-title small { display: block; margin: 0 0 4px; color: #98a1b2; font-size: 10px; font-weight: 650; }
.admin-title h1 { margin: 0; color: var(--admin-text); font-size: 24px; line-height: 1.2; letter-spacing: -.04em; }
.admin-top-actions { display: flex; align-items: center; gap: 10px; }
.admin-button { min-height: 42px; display: inline-flex; align-items: center; justify-content: center; gap: 8px; padding: 0 16px; border: 1px solid #dde2eb; border-radius: 11px; color: #4d586b; background: #fff; cursor: pointer; font-size: 12px; font-weight: 750; box-shadow: 0 2px 4px rgba(30,41,59,.025); transition: border-color .2s, background .2s, color .2s, transform .2s, box-shadow .2s; }
.admin-button:hover { transform: translateY(-1px); border-color: #cbd1dc; box-shadow: 0 6px 16px rgba(30,41,59,.07); }
.admin-button svg { width: 17px; height: 17px; }
.admin-button.primary { color: #fff; border-color: var(--admin-primary); background: var(--admin-primary); box-shadow: 0 8px 20px rgba(91,92,226,.2); }
.admin-button.primary:hover { border-color: var(--admin-primary-dark); background: var(--admin-primary-dark); }
.admin-button.ghost { color: #536075; background: #fff; }
.admin-button.light { color: #3435a7; border-color: #fff; background: #fff; }
.admin-avatar { width: 38px; height: 38px; display: grid; place-items: center; margin-left: 4px; border: 3px solid #fff; border-radius: 50%; color: #fff; background: #20283a; box-shadow: 0 0 0 1px #e0e4eb; font-size: 11px; font-weight: 800; }
.admin-content { width: min(1480px, 100%); margin: 0 auto; padding: 32px clamp(24px, 3vw, 48px) 60px; }
.admin-content > .flash { margin: 0 0 20px; }

.welcome-card { position: relative; min-height: 220px; display: flex; align-items: center; justify-content: space-between; gap: 40px; overflow: hidden; padding: 38px 44px; border-radius: 24px; color: #fff; background: linear-gradient(120deg, #242755, #5556d8 64%, #6869e7); box-shadow: 0 18px 45px rgba(63,65,161,.18); }
.welcome-card > div:first-child { position: relative; z-index: 2; }
.welcome-card span { color: #b9bcff; font-size: 10px; font-weight: 800; letter-spacing: .16em; }
.welcome-card h2 { margin: 11px 0 9px; font-size: clamp(27px, 3vw, 38px); letter-spacing: -.045em; }
.welcome-card p { margin: 0; color: #c9ccef; font-size: 13px; }
.welcome-actions { display: flex; align-items: center; gap: 18px; margin-top: 24px; }
.welcome-actions > a:last-child { color: #dfe1ff; font-size: 11px; font-weight: 700; }
.welcome-art { position: relative; z-index: 2; min-width: 180px; height: 140px; display: grid; place-content: center; text-align: center; border: 1px solid rgba(255,255,255,.12); border-radius: 22px; background: rgba(255,255,255,.08); box-shadow: inset 0 1px rgba(255,255,255,.08); backdrop-filter: blur(12px); }
.welcome-art i { display: none; }
.welcome-art strong { font-size: 64px; line-height: .9; letter-spacing: -.08em; }
.welcome-art > span { margin-top: 10px; color: #d4d6ff; letter-spacing: .12em; }

.admin-stats { display: grid; grid-template-columns: repeat(4, minmax(0,1fr)); gap: 16px; margin: 22px 0; }
.stat-card { min-height: 132px; display: flex; align-items: center; gap: 16px; padding: 22px; border: 1px solid var(--admin-line); border-radius: 18px; background: #fff; box-shadow: 0 7px 24px rgba(30,41,59,.035); }
.stat-icon { width: 44px; height: 44px; display: grid; place-items: center; flex: none; border-radius: 13px; }
.stat-icon svg { width: 21px; height: 21px; }
.stat-card.purple .stat-icon { color: #5b5ce2; background: #efefff; }
.stat-card.green .stat-icon { color: #079669; background: #e9fbf4; }
.stat-card.amber .stat-icon { color: #d97706; background: #fff7e8; }
.stat-card.blue .stat-icon { color: #2581d8; background: #edf7ff; }
.stat-card > div:last-child { min-width: 0; }
.stat-card span { color: #79859a; font-size: 11px; font-weight: 650; }
.stat-card strong { display: block; margin: 4px 0 2px; color: #192236; font-size: 30px; line-height: 1.1; letter-spacing: -.05em; }
.stat-card strong em { font-size: 15px; font-style: normal; }
.stat-card small { color: #9ca5b5; font-size: 9px; }

.dashboard-grid { display: grid; grid-template-columns: minmax(0,1.6fr) minmax(300px,.75fr); gap: 22px; }
.admin-panel { overflow: hidden; border: 1px solid var(--admin-line); border-radius: 20px; background: #fff; box-shadow: 0 8px 28px rgba(30,41,59,.035); }
.panel-head { min-height: 74px; display: flex; align-items: center; justify-content: space-between; gap: 20px; padding: 16px 22px; border-bottom: 1px solid #edf0f4; }
.panel-head > div { min-width: 0; }
.panel-head h2 { margin: 0; color: #1f293b; font-size: 14px; letter-spacing: -.01em; }
.panel-head span { display: block; margin-top: 4px; color: #939dae; font-size: 9px; }
.panel-head > a { color: #5556d8; font-size: 10px; font-weight: 750; }
.panel-body { padding: 24px; }
.recent-list { padding: 6px 12px 12px; }
.recent-row { min-height: 82px; display: grid; grid-template-columns: 86px minmax(0,1fr) auto 20px; align-items: center; gap: 14px; padding: 10px; border-radius: 13px; transition: background .2s; }
.recent-row:hover { background: #f7f8fb; }
.recent-row img { width: 86px; height: 56px; border-radius: 9px; object-fit: cover; object-position: top; background: #edf0f5; }
.recent-row > div { min-width: 0; }
.recent-row strong, .recent-row span { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.recent-row strong { color: #263044; font-size: 12px; }
.recent-row span { margin-top: 6px; color: #939cad; font-size: 9px; }
.recent-row > svg { width: 16px; height: 16px; color: #a8b0bf; }
.status-pill { display: inline-flex; align-items: center; gap: 5px; padding: 5px 9px; border-radius: 99px; font-size: 9px; font-style: normal; font-weight: 750; white-space: nowrap; }
.status-pill::before { content: ""; width: 5px; height: 5px; border-radius: 50%; }
.status-pill.online { color: #087a5a; background: #e9f9f3; }
.status-pill.online::before { background: #18b981; }
.status-pill.offline { color: #7d8797; background: #f0f2f5; }
.status-pill.offline::before { background: #9ca3af; }
.category-bars { display: grid; gap: 18px; padding: 22px; }
.category-bar > div { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.category-bar strong { color: #445066; font-size: 11px; }
.category-bar span { color: #9aa3b3; font-size: 9px; }
.category-bar > i { height: 6px; display: block; overflow: hidden; margin-top: 9px; border-radius: 99px; background: #f0f2f6; }
.category-bar > i b { height: 100%; display: block; border-radius: inherit; background: linear-gradient(90deg, #696aeb, #9394f4); }
.quick-card { min-height: 72px; display: flex; align-items: center; justify-content: space-between; gap: 16px; margin: 0 14px 14px; padding: 14px 16px; border-radius: 13px; background: #f7f7ff; }
.quick-card b, .quick-card small { display: block; }
.quick-card b { color: #4243a9; font-size: 11px; }
.quick-card small { margin-top: 4px; color: #9196bb; font-size: 9px; }
.quick-card svg { width: 16px; height: 16px; color: #6f70e7; }

.template-manager { border-radius: 20px; }
.manager-head { min-height: 104px; display: flex; align-items: center; justify-content: space-between; gap: 24px; padding: 24px 28px; border-bottom: 1px solid var(--admin-line); }
.manager-head h2 { margin: 0; font-size: 19px; letter-spacing: -.03em; }
.manager-head p { margin: 7px 0 0; color: #8a95a7; font-size: 11px; }
.admin-toolbar { min-height: 74px; display: flex; align-items: center; gap: 12px; padding: 14px 20px; border-bottom: 1px solid var(--admin-line); background: #fbfcfd; }
.admin-search { width: min(380px, 100%); min-height: 42px; display: flex; align-items: center; gap: 10px; padding: 0 13px; border: 1px solid #dfe4ec; border-radius: 11px; background: #fff; }
.admin-search:focus-within { border-color: #aeb0f5; box-shadow: 0 0 0 3px rgba(91,92,226,.08); }
.admin-search svg { width: 17px; height: 17px; flex: none; color: #9ba5b5; }
.admin-search input { width: 100%; border: 0; outline: 0; color: #263044; background: transparent; font-size: 11px; }
.admin-toolbar select { min-height: 42px; padding: 0 34px 0 13px; border: 1px solid #dfe4ec; border-radius: 11px; outline: 0; color: #536075; background: #fff; font-size: 11px; }
.toolbar-count { margin-left: auto; color: #97a0b0; font-size: 10px; }
.admin-table-wrap { overflow-x: auto; }
.admin-table { width: 100%; border-collapse: collapse; }
.admin-table th { height: 48px; padding: 0 18px; color: #8d97a8; background: #fafbfc; font-size: 9px; font-weight: 750; text-align: left; white-space: nowrap; }
.admin-table td { min-height: 78px; padding: 13px 18px; border-top: 1px solid #edf0f4; color: #586579; font-size: 10px; vertical-align: middle; }
.admin-table tbody tr { transition: background .15s; }
.admin-table tbody tr:hover { background: #fafbfe; }
.admin-table .align-right { text-align: right; }
.template-cell { min-width: 310px; display: flex; align-items: center; gap: 13px; }
.template-cell img { width: 84px; height: 53px; flex: none; border: 1px solid #e5e8ef; border-radius: 9px; object-fit: cover; object-position: top; background: #edf0f5; }
.template-cell > div { min-width: 0; }
.template-cell strong, .template-cell span { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.template-cell strong { max-width: 280px; color: #263044; font-size: 11px; }
.template-cell span { max-width: 310px; margin-top: 6px; color: #98a1b0; font-size: 9px; }
.category-chip { display: inline-flex; padding: 6px 9px; border-radius: 7px; color: #5556bd; background: #f0f0ff; font-weight: 700; white-space: nowrap; }
.status-stack { display: grid; justify-items: start; gap: 5px; }
.status-stack small { color: #a06a14; font-size: 8px; }
.sort-number { display: inline-grid; min-width: 28px; height: 28px; place-items: center; border-radius: 8px; color: #5f6b7e; background: #f3f5f8; font-weight: 750; }
.date-text { color: #8d97a8; white-space: nowrap; }
.table-actions { display: flex; align-items: center; justify-content: flex-end; gap: 6px; min-width: 116px; }
.table-actions form { margin: 0; }
.icon-button { width: 34px; height: 34px; display: grid; place-items: center; padding: 0; border: 1px solid #e0e4eb; border-radius: 9px; color: #7c8798; background: #fff; cursor: pointer; transition: .15s; }
.icon-button:hover { color: #5051c8; border-color: #c7c8f5; background: #f8f8ff; }
.icon-button.danger:hover { color: #dc4b4b; border-color: #fecaca; background: #fff6f6; }
.icon-button svg { width: 15px; height: 15px; }
.table-empty { padding: 60px 20px; color: #8f99aa; text-align: center; font-size: 11px; }
.empty-list { padding: 60px 22px; color: #98a1b1; text-align: center; }
.empty-list strong, .empty-list span { display: block; }
.empty-list strong { color: #4b5668; font-size: 13px; }
.empty-list span { margin-top: 8px; font-size: 10px; }
.empty-list.large { padding: 100px 22px; }

.editor-heading { min-height: 82px; display: flex; align-items: flex-end; justify-content: space-between; gap: 24px; margin-bottom: 22px; }
.editor-heading > div:first-child > a { color: #747f91; font-size: 10px; }
.editor-heading h2 { margin: 9px 0 5px; font-size: 24px; letter-spacing: -.04em; }
.editor-heading p { margin: 0; color: #8d97a8; font-size: 11px; }
.editor-heading > div:last-child { display: flex; gap: 10px; }
.editor-grid { display: grid; grid-template-columns: minmax(0,1fr) 360px; align-items: start; gap: 22px; }
.editor-main .panel-body { padding: 28px; }
.editor-side { display: grid; gap: 18px; }
.form-grid { display: grid; grid-template-columns: repeat(2,minmax(0,1fr)); gap: 20px; }
.field.full { grid-column: 1 / -1; }
.field label { display: block; margin-bottom: 8px; color: #47536a; font-size: 10px; font-weight: 750; }
.field label b { color: #e05252; }
.field input[type="text"], .field input[type="url"], .field input[type="number"], .field input[type="password"], .field textarea, .field select { width: 100%; min-height: 46px; padding: 11px 13px; border: 1px solid #dfe4ec; border-radius: 11px; outline: 0; color: #263044; background: #fff; font-size: 11px; transition: .2s; }
.field textarea { min-height: 116px; resize: vertical; line-height: 1.7; }
.field input:focus, .field textarea:focus, .field select:focus { border-color: #a7a9f0; box-shadow: 0 0 0 3px rgba(91,92,226,.08); }
.field input::placeholder, .field textarea::placeholder { color: #b0b7c3; }
.field-help { margin: 7px 0 0; color: #9aa4b3; font-size: 9px; line-height: 1.5; }
.publish-options { display: grid; gap: 2px; padding: 14px 20px; }
.publish-options label { min-height: 68px; display: flex; align-items: center; justify-content: space-between; gap: 18px; cursor: pointer; }
.publish-options label + label { border-top: 1px solid #edf0f4; }
.publish-options strong, .publish-options small { display: block; }
.publish-options strong { color: #404b5e; font-size: 11px; }
.publish-options small { margin-top: 4px; color: #939dad; font-size: 9px; }
.publish-options input { position: absolute; opacity: 0; pointer-events: none; }
.publish-options i { position: relative; width: 38px; height: 22px; flex: none; border-radius: 99px; background: #d7dce5; transition: .2s; }
.publish-options i::after { content: ""; position: absolute; left: 3px; top: 3px; width: 16px; height: 16px; border-radius: 50%; background: #fff; box-shadow: 0 2px 5px rgba(30,41,59,.18); transition: .2s; }
.publish-options input:checked + i { background: #6465e5; }
.publish-options input:checked + i::after { transform: translateX(16px); }
.upload-box { min-height: 116px; display: grid; place-items: center; padding: 15px; border: 1px dashed #cdd3df; border-radius: 12px; color: #798497; background: #fafbfc; text-align: center; cursor: pointer; }
.upload-box:hover { border-color: #a9abef; background: #f9f9ff; }
.upload-box input { position: absolute; width: 1px; height: 1px; opacity: 0; pointer-events: none; }
.upload-box svg { width: 22px; height: 22px; margin: 0 auto 8px; color: #6667df; }
.upload-box strong, .upload-box span { display: block; }
.upload-box strong { color: #505c70; font-size: 10px; }
.upload-box span { margin-top: 5px; font-size: 8px; }
.current-image { width: 100%; margin: 0 0 12px; border: 1px solid #e6e9ef; border-radius: 11px; object-fit: cover; object-position: top; background: #edf0f5; }
.current-image.desktop { height: 170px; max-height: none; }
.current-image.mobile { width: 112px; max-height: 200px; margin-inline: auto; }
.image-position-control { display: grid; gap: 11px; margin: -2px 0 13px; padding: 13px; border: 1px solid #e1e6ee; border-radius: 11px; background: #f8fafc; }
.position-title, .image-position-control label > span { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.position-title strong { color: #445066; font-size: 10px; }
.position-title button { padding: 0; border: 0; color: #6768dc; background: none; font-size: 9px; cursor: pointer; }
.image-position-control label { display: grid; gap: 6px; color: #6f7b8e; font-size: 9px; }
.image-position-control output { color: #5965d8; font-weight: 750; }
.image-position-control input[type="range"] { width: 100%; accent-color: #6465e5; cursor: pointer; }
.image-position-control > small { color: #929cac; font-size: 8px; line-height: 1.55; }
.remove-image { display: flex; align-items: center; gap: 7px; margin-top: 10px; color: #8b5360; font-size: 9px; cursor: pointer; }
.remove-image input { accent-color: #dc5a69; }
.mobile-save { display: none; }

.category-layout { display: grid; grid-template-columns: minmax(0,1fr) 330px; align-items: start; gap: 22px; }
.category-total { padding: 7px 10px; border-radius: 8px; color: #6869d9; background: #f0f0ff; font-size: 10px; font-weight: 750; }
.category-manage-list { display: grid; gap: 0; padding: 6px 22px 18px; }
.category-manage-row { min-height: 96px; display: grid; grid-template-columns: 44px minmax(180px,1fr) 110px auto; align-items: center; gap: 16px; padding: 14px 4px; border-bottom: 1px solid #edf0f4; }
.category-manage-row:last-child { border-bottom: 0; }
.category-symbol { width: 42px; height: 42px; display: grid; place-items: center; border-radius: 12px; color: #5c5dd4; background: #eeeeff; }
.category-symbol svg { width: 20px; height: 20px; }
.category-manage-row label > span, .category-usage span { display: block; margin-bottom: 6px; color: #929cac; font-size: 8px; font-weight: 700; }
.category-manage-row input[type="text"] { width: 100%; min-height: 40px; padding: 0 12px; border: 1px solid #dfe4ec; border-radius: 10px; outline: 0; color: #303a4d; font-size: 11px; font-weight: 650; }
.category-manage-row input[type="text"]:focus { border-color: #a7a9f0; box-shadow: 0 0 0 3px rgba(91,92,226,.08); }
.category-usage strong { color: #485469; font-size: 11px; }
.category-guide { display: grid; gap: 18px; }
.guide-card { padding: 24px; }
.guide-card > span { color: #6566df; font-size: 9px; font-weight: 800; letter-spacing: .12em; }
.guide-card h3 { margin: 12px 0 8px; font-size: 17px; letter-spacing: -.025em; }
.guide-card p { margin: 0; color: #7f8a9d; font-size: 10px; line-height: 1.8; }
.guide-link { min-height: 92px; display: flex; align-items: center; justify-content: space-between; gap: 18px; padding: 20px; }
.guide-link strong, .guide-link small { display: block; }
.guide-link strong { color: #3f4a5e; font-size: 11px; }
.guide-link small { margin-top: 5px; color: #929cac; font-size: 9px; }
.guide-link svg { width: 18px; height: 18px; color: #6b6ce2; }

.settings-layout { display: grid; grid-template-columns: 310px minmax(0,1fr); align-items: start; gap: 22px; }
.settings-intro { position: sticky; top: 120px; padding: 28px; color: #fff; background: linear-gradient(145deg, #22264f, #4f50c7); }
.settings-intro > span { color: #b7baff; font-size: 9px; font-weight: 800; letter-spacing: .14em; }
.settings-intro h2 { margin: 14px 0 10px; font-size: 24px; line-height: 1.2; letter-spacing: -.04em; }
.settings-intro p { margin: 0; color: #c4c8e7; font-size: 10px; line-height: 1.8; }
.settings-intro a { display: inline-flex; margin-top: 26px; color: #fff; font-size: 10px; font-weight: 750; }
.settings-stack { display: grid; gap: 18px; }
.settings-stack .panel-body { padding: 26px; }
.settings-actions { min-height: 70px; display: flex; align-items: center; justify-content: space-between; gap: 20px; padding: 0 4px; }
.settings-actions > span { color: #939dad; font-size: 9px; }

/* More confident sign-in and setup screen */
.auth-page { min-height: 100vh; grid-template-columns: minmax(420px,.9fr) minmax(520px,1.1fr); background: #f7f8fb; }
.auth-visual { min-height: 100vh; padding: clamp(38px,5vw,72px); background: linear-gradient(150deg, #171b2d, #292d63 58%, #3e4c79); }
.auth-message h1 { font-size: clamp(46px,5vw,72px); }
.auth-form-wrap { padding: 48px; }
.auth-card { width: min(460px,100%); padding: 40px; border: 1px solid #e5e8ef; border-radius: 22px; background: #fff; box-shadow: 0 20px 55px rgba(30,41,59,.08); }
.auth-card h2 { font-size: 28px; }
.auth-card > p { margin-bottom: 26px; }
.auth-submit { min-height: 52px; border-radius: 12px; background: #5b5ce2; }

@media (max-width: 1180px) {
    .admin-shell { grid-template-columns: 232px minmax(0,1fr); }
    .admin-sidebar { padding-inline: 16px; }
    .admin-nav a::before { left: -16px; }
    .admin-stats { grid-template-columns: repeat(2,minmax(0,1fr)); }
    .editor-grid { grid-template-columns: minmax(0,1fr) 330px; }
    .category-layout, .settings-layout { grid-template-columns: 280px minmax(0,1fr); }
    .category-layout { grid-template-columns: 1fr; }
    .category-guide { grid-template-columns: repeat(2,minmax(0,1fr)); }
}

@media (max-width: 920px) {
    .admin-shell { display: block; }
    .admin-sidebar { position: fixed; left: 0; top: 0; width: 276px; height: 100vh; transform: translateX(-105%); transition: transform .24s ease; box-shadow: 24px 0 60px rgba(15,23,42,.22); }
    .admin-page.sidebar-open .admin-sidebar { transform: none; }
    .sidebar-close { display: grid; place-items: center; }
    .sidebar-scrim { position: fixed; z-index: 50; inset: 0; display: block; pointer-events: none; opacity: 0; background: rgba(9,14,26,.44); transition: opacity .2s; }
    .admin-page.sidebar-open .sidebar-scrim { pointer-events: auto; opacity: 1; }
    .mobile-menu { display: grid; }
    .dashboard-grid, .editor-grid, .settings-layout { grid-template-columns: 1fr; }
    .settings-intro { position: static; }
    .editor-side { grid-template-columns: repeat(2,minmax(0,1fr)); }
    .editor-side > section:first-child { grid-column: 1 / -1; }
    .auth-page { grid-template-columns: 1fr; }
    .auth-visual { min-height: 300px; }
}

@media (max-width: 680px) {
    .admin-topbar { min-height: 76px; padding: 14px 16px; }
    .admin-title small { display: none; }
    .admin-title h1 { font-size: 20px; }
    .admin-top-actions .ghost, .admin-avatar { display: none; }
    .admin-top-actions .admin-button { min-height: 40px; padding-inline: 12px; }
    .admin-content { padding: 20px 14px 44px; }
    .welcome-card { min-height: 250px; align-items: flex-start; padding: 28px 24px; }
    .welcome-art { position: absolute; right: 20px; bottom: 20px; min-width: 104px; height: 88px; }
    .welcome-art strong { font-size: 42px; }
    .welcome-card h2 { font-size: 27px; }
    .welcome-card p { max-width: 240px; line-height: 1.7; }
    .welcome-actions { align-items: flex-start; flex-direction: column; gap: 12px; }
    .admin-stats { grid-template-columns: repeat(2,minmax(0,1fr)); gap: 10px; }
    .stat-card { min-height: 122px; align-items: flex-start; flex-direction: column; gap: 10px; padding: 16px; }
    .stat-icon { width: 36px; height: 36px; }
    .stat-card strong { font-size: 25px; }
    .recent-row { grid-template-columns: 68px minmax(0,1fr) auto; }
    .recent-row img { width: 68px; height: 48px; }
    .recent-row > svg { display: none; }
    .recent-row .status-pill { display: none; }
    .manager-head { align-items: flex-start; padding: 22px 18px; }
    .manager-head > .admin-button { display: none; }
    .admin-toolbar { align-items: stretch; flex-direction: column; padding: 14px; }
    .admin-search { width: 100%; }
    .admin-toolbar select { width: 100%; }
    .toolbar-count { margin: 0; padding-left: 2px; }
    .admin-table-wrap { padding: 10px; overflow: visible; background: #f7f8fb; }
    .admin-table, .admin-table tbody { display: block; }
    .admin-table thead { display: none; }
    .admin-table tr { display: grid; grid-template-columns: 1fr auto; gap: 12px; margin-bottom: 10px; padding: 14px; border: 1px solid var(--admin-line); border-radius: 14px; background: #fff; }
    .admin-table td { min-height: 0; display: block; padding: 0; border: 0; }
    .admin-table td:first-child { grid-column: 1 / -1; }
    .admin-table td:nth-child(4), .admin-table td:nth-child(5) { display: none; }
    .admin-table td:last-child { grid-column: 2; grid-row: 2; }
    .template-cell { min-width: 0; }
    .template-cell img { width: 72px; height: 48px; }
    .template-cell strong, .template-cell span { max-width: none; }
    .table-actions { min-width: 0; }
    .editor-heading { align-items: flex-start; margin-bottom: 18px; }
    .editor-heading > div:last-child { display: none; }
    .editor-heading h2 { font-size: 22px; }
    .editor-side { grid-template-columns: 1fr; }
    .editor-side > section:first-child { grid-column: auto; }
    .form-grid { grid-template-columns: 1fr; }
    .field.full { grid-column: auto; }
    .editor-main .panel-body, .settings-stack .panel-body { padding: 20px; }
    .mobile-save { position: sticky; z-index: 20; bottom: 0; display: block; margin: 18px -14px -44px; padding: 12px 14px calc(12px + env(safe-area-inset-bottom)); border-top: 1px solid var(--admin-line); background: rgba(255,255,255,.94); backdrop-filter: blur(14px); }
    .mobile-save .admin-button { width: 100%; min-height: 48px; }
    .category-guide { grid-template-columns: 1fr; }
    .category-manage-list { padding-inline: 14px; }
    .category-manage-row { grid-template-columns: 42px minmax(0,1fr); gap: 12px; }
    .category-manage-row label { grid-column: 2; }
    .category-usage { grid-column: 2; }
    .category-manage-row .admin-button { grid-column: 2; width: 100%; }
    .settings-actions { align-items: stretch; flex-direction: column; padding: 4px 0; }
    .settings-actions .admin-button { width: 100%; min-height: 48px; }
    .auth-visual { min-height: 260px; padding: 30px 24px; }
    .auth-message h1 { font-size: 34px; }
    .auth-form-wrap { padding: 24px 14px; }
    .auth-card { padding: 28px 22px; border-radius: 18px; }
}

/* Public v1.2 — compact client-facing demo directory */
.demo-directory {
    --ink: #162033;
    --muted: #6d788b;
    --line: #e3e8f0;
    --primary: #1769e8;
    --primary-dark: #0f55c9;
    min-height: 100vh;
    color: var(--ink);
    background: #f6f8fb;
}
.demo-directory .shell { width: min(1320px, calc(100% - 72px)); }
.demo-directory .site-header {
    position: sticky;
    z-index: 30;
    top: 0;
    height: 72px;
    border-bottom: 1px solid rgba(222,228,238,.92);
    background: rgba(255,255,255,.94);
    backdrop-filter: blur(16px);
}
.header-inner { height: 100%; display: flex; align-items: center; justify-content: space-between; gap: 32px; }
.demo-directory .brand { font-size: 16px; font-weight: 780; }
.demo-directory .brand-mark { width: 36px; height: 36px; border-radius: 10px; background: #1769e8; box-shadow: 0 8px 20px rgba(23,105,232,.2); }
.demo-directory .header-actions { gap: 28px; }
.nav-link { position: relative; padding-block: 25px 23px; color: #556176; font-size: 13px; font-weight: 650; }
.nav-link:hover, .nav-link.active { color: #1769e8; }
.nav-link.active::after { content: ""; position: absolute; left: 0; right: 0; bottom: -1px; height: 2px; border-radius: 2px; background: #1769e8; }
.demo-directory .button { min-height: 44px; padding-inline: 20px; border-radius: 10px; font-size: 13px; }
.demo-directory .button-small { min-height: 40px; padding-inline: 16px; }
.demo-directory .button-primary { background: #1769e8; box-shadow: 0 10px 24px rgba(23,105,232,.2); }
.demo-directory .button-primary:hover { background: #0f5dd9; }
.button-outline { color: #1769e8; border: 1px solid #98bdf6; background: #fff; }
.demo-directory .button-ghost { color: #1769e8; border: 1px solid #d9e6f8; background: #fff; }

.demo-hero { border-bottom: 1px solid #e5eaf2; background: #f8fbff; }
.demo-hero-grid { min-height: 276px; display: grid; grid-template-columns: minmax(0,1.12fr) minmax(500px,.88fr); align-items: center; gap: 64px; padding-block: 42px; }
.demo-hero-copy { min-width: 0; }
.demo-directory .eyebrow { display: block; color: #1769e8; font-size: 10px; font-weight: 850; letter-spacing: .14em; }
.demo-hero h1 { max-width: 760px; margin: 15px 0 12px; color: #162033; font-size: clamp(34px,2.8vw,40px); line-height: 1.2; letter-spacing: -.04em; }
.demo-hero-copy > p { max-width: 680px; margin: 0; color: #68758a; font-size: 14px; line-height: 1.75; }
.demo-directory .hero-actions { margin-top: 22px; }
.trust-panel { display: grid; grid-template-columns: repeat(3,minmax(0,1fr)); overflow: hidden; border: 1px solid #dfe6f0; border-radius: 16px; background: #fff; box-shadow: 0 10px 30px rgba(31,46,76,.045); }
.trust-panel > div { min-height: 112px; display: flex; align-items: center; flex-direction: column; justify-content: center; padding: 18px 14px; text-align: center; }
.trust-panel > div + div { border-left: 1px solid #e7ebf2; }
.trust-panel strong, .trust-panel span { display: block; }
.trust-panel strong { color: #243148; font-size: 13px; }
.trust-panel span { margin-top: 7px; color: #8993a3; font-size: 10px; line-height: 1.55; }

.demo-directory .catalog { padding-block: 30px 96px; }
.catalog-toolbar { margin-bottom: 18px; }
.demo-directory .section-heading { align-items: center; margin-bottom: 18px; }
.demo-directory .section-kicker { font-size: 9px; letter-spacing: .15em; }
.demo-directory .section-heading h2 { margin: 6px 0 4px; font-size: 27px; letter-spacing: -.035em; }
.demo-directory .section-heading p { font-size: 12px; }
.demo-directory .search-box { height: 42px; flex-basis: 290px; border-radius: 10px; background: #fff; box-shadow: none; }
.demo-directory .search-box input { font-size: 12px; }
.demo-directory .filter-row { gap: 8px; padding-bottom: 2px; }
.demo-directory .filter-chip { height: 34px; padding-inline: 13px; border-radius: 8px; color: #556176; background: #fff; font-size: 11px; }
.demo-directory .filter-chip.active { border-color: #1769e8; background: #1769e8; box-shadow: 0 7px 16px rgba(23,105,232,.16); }
.demo-directory .filter-chip.active span { color: #dceaff; }

.demo-directory .template-grid { grid-template-columns: repeat(2,minmax(0,1fr)); gap: 18px; }
.demo-directory .template-card { min-height: 260px; display: grid; grid-template-columns: minmax(0,1.56fr) minmax(210px,.74fr); border-radius: 16px; background: #fff; box-shadow: 0 6px 22px rgba(28,43,73,.045); }
.demo-directory .template-card:hover { transform: translateY(-3px); border-color: #b8cff2; box-shadow: 0 14px 34px rgba(28,43,73,.09); }
.demo-directory .preview-stage { height: 100%; min-height: 260px; padding: 20px 18px; background: #f3f6fa; }
.demo-directory .preview-stage::after { display: none; }
.demo-directory .browser-frame { width: 84%; height: 210px; border-width: 3px; border-radius: 11px; background: #242d3e; box-shadow: 0 13px 26px rgba(32,45,67,.18); }
.demo-directory .browser-bar { height: 19px; padding-inline: 7px; background: #242d3e; }
.demo-directory .browser-bar i { width: 4px; height: 4px; }
.demo-directory .browser-screen { height: calc(100% - 19px); border-radius: 6px; }
.demo-directory .phone-frame { right: 14px; bottom: 18px; width: 76px; height: 164px; padding: 5px; border-width: 3px; border-radius: 17px; background: #242d3e; box-shadow: 0 12px 25px rgba(32,45,67,.22); }
.demo-directory .phone-screen { border-radius: 10px; }
.demo-directory .phone-speaker { top: 3px; width: 24px; height: 4px; }
.demo-directory .card-content { display: flex; align-items: flex-start; flex-direction: column; justify-content: center; padding: 22px 20px; border-left: 1px solid #e8ecf2; }
.demo-directory .card-meta { flex-wrap: wrap; gap: 6px; margin-bottom: 12px; }
.demo-directory .card-meta span { padding: 4px 7px; border-radius: 5px; color: #5c687b; background: #f0f2f6; font-size: 9px; }
.demo-directory .card-meta .hot-tag { color: #1769e8; background: #eaf2ff; }
.demo-directory .card-content h3 { font-size: 18px; line-height: 1.35; }
.demo-directory .card-content > p { min-height: 0; margin: 9px 0 17px; color: #778295; font-size: 11px; line-height: 1.7; }
.demo-directory .demo-link { min-height: 38px; display: inline-flex; align-items: center; justify-content: center; gap: 6px; padding: 0 14px; border: 1px solid #dce3ed; border-radius: 9px; color: #26344c; background: #fff; font-size: 11px; }
.demo-directory .demo-link:hover { color: #1769e8; border-color: #a9c7f4; }
.demo-directory .demo-link.disabled { padding-inline: 0; border: 0; color: #9ba4b2; background: transparent; }
.demo-directory .empty-state { margin-top: 18px; border-radius: 16px; background: #fff; }
.demo-directory .site-footer { min-height: 112px; border-top: 1px solid #e2e7ef; background: #fff; }
.footer-inner { min-height: 112px; display: flex; align-items: center; justify-content: space-between; gap: 30px; }
.demo-directory .back-top { border-radius: 10px; background: #1769e8; }

@media (max-width: 1180px) {
    .demo-directory .shell { width: min(100% - 44px, 1040px); }
    .demo-hero-grid { grid-template-columns: minmax(0,1fr) 460px; gap: 38px; }
    .demo-directory .template-card { grid-template-columns: 1.45fr .8fr; }
}
@media (max-width: 980px) {
    .demo-directory .header-actions .nav-link { display: none; }
    .demo-hero-grid { grid-template-columns: 1fr; gap: 26px; padding-block: 36px; }
    .trust-panel { width: 100%; }
    .demo-directory .template-grid { grid-template-columns: 1fr; }
    .demo-directory .template-card { grid-template-columns: minmax(0,1.6fr) minmax(220px,.7fr); }
}
@media (max-width: 680px) {
    .demo-directory .shell { width: min(100% - 28px, 560px); }
    .demo-directory .site-header { height: 64px; }
    .demo-directory .brand { font-size: 13px; }
    .demo-directory .brand-mark { width: 34px; height: 34px; }
    .demo-directory .header-actions { gap: 0; }
    .demo-directory .header-actions .button { min-height: 36px; padding-inline: 12px; font-size: 11px; }
    .demo-hero-grid { padding-block: 30px; }
    .demo-hero h1 { margin-top: 12px; font-size: 31px; }
    .demo-hero-copy > p { font-size: 13px; }
    .demo-directory .hero-actions { display: flex; flex-direction: row; }
    .demo-directory .hero-actions .button { min-height: 40px; padding-inline: 14px; }
    .trust-panel { grid-template-columns: repeat(3,minmax(0,1fr)); }
    .trust-panel > div { min-height: 76px; padding: 12px 8px; }
    .trust-panel > div + div { border-left: 1px solid #e7ebf2; }
    .trust-panel strong { font-size: 10px; line-height: 1.45; }
    .trust-panel span { display: none; }
    .demo-directory .catalog { padding-block: 24px 70px; }
    .demo-directory .section-heading { align-items: stretch; }
    .demo-directory .section-heading h2 { font-size: 24px; }
    .demo-directory .search-box { flex: 0 0 42px; width: 100%; }
    .demo-directory .template-card { display: block; }
    .demo-directory .preview-stage { height: 236px; min-height: 236px; }
    .demo-directory .browser-frame { height: 188px; }
    .demo-directory .phone-frame { width: 68px; height: 143px; }
    .demo-directory .card-content { padding: 20px; border-top: 1px solid #e8ecf2; border-left: 0; }
    .demo-directory .card-content > p { margin-bottom: 14px; }
    .footer-inner { min-height: 120px; align-items: flex-start; flex-direction: column; justify-content: center; gap: 14px; }
}

/* Public v1.3 — quiet, product-led presentation */
.demo-directory {
    --ink: #1d1d1f;
    --muted: #6e6e73;
    --line: #d8d8dc;
    --primary: #0071e3;
    --primary-dark: #0068d1;
    color: var(--ink);
    background: #f5f5f7;
    font-family: -apple-system, BlinkMacSystemFont, "SF Pro Text", "PingFang SC", "Helvetica Neue", "Segoe UI", "Microsoft YaHei UI", sans-serif;
}
.demo-directory .shell { width: min(1180px, calc(100% - 48px)); }
.demo-directory .site-header {
    height: 54px;
    border-bottom: 0;
    background: rgba(250,250,252,.9);
    backdrop-filter: saturate(180%) blur(20px);
}
.demo-directory .header-inner { gap: 40px; }
.demo-directory .brand { color: #1d1d1f; font-size: 14px; font-weight: 650; letter-spacing: -.01em; }
.demo-directory .brand-mark { width: 30px; height: 30px; border-radius: 9px; color: #fff; background: #1d1d1f; box-shadow: none; }
.demo-directory .brand-mark svg { width: 17px; height: 17px; }
.demo-directory .header-actions { gap: 26px; }
.demo-directory .nav-link { padding: 19px 0 18px; color: #424245; font-size: 12px; font-weight: 450; }
.demo-directory .nav-link:hover, .demo-directory .nav-link.active { color: #000; }
.demo-directory .nav-link.active::after { display: none; }
.demo-directory .button { min-height: 46px; padding-inline: 22px; border-radius: 999px; font-size: 14px; font-weight: 550; box-shadow: none; }
.demo-directory .button-small { min-height: 32px; padding-inline: 14px; font-size: 12px; }
.demo-directory .button-primary { color: #fff; background: #0071e3; box-shadow: none; }
.demo-directory .button-primary:hover { background: #0077ed; }
.demo-directory .button-outline { color: #fff; border: 0; background: #1d1d1f; }
.demo-directory .button-ghost { color: #0066cc; border: 0; background: transparent; }

.demo-directory .demo-hero { border: 0; background: #fff; }
.demo-directory .demo-hero-grid {
    min-height: 500px;
    display: flex;
    align-items: center;
    flex-direction: column;
    justify-content: center;
    gap: 0;
    padding-block: 74px 48px;
}
.demo-directory .demo-hero-copy { max-width: 920px; text-align: center; }
.demo-directory .eyebrow { display: block; color: #6e6e73; font-size: 14px; font-weight: 600; letter-spacing: .02em; text-transform: none; }
.demo-directory .demo-hero h1 { max-width: 920px; margin: 17px auto 18px; color: #1d1d1f; font-size: clamp(44px,5.2vw,68px); font-weight: 700; line-height: 1.06; letter-spacing: -.055em; }
.demo-directory .demo-hero-copy > p { max-width: 720px; margin: 0 auto; color: #6e6e73; font-size: 19px; line-height: 1.55; letter-spacing: -.012em; }
.demo-directory .hero-actions { justify-content: center; margin-top: 28px; }
.demo-directory .trust-panel { width: min(760px,100%); grid-template-columns: repeat(3,minmax(0,1fr)); margin-top: 52px; overflow: hidden; border: 0; border-radius: 18px; background: #f5f5f7; box-shadow: none; }
.demo-directory .trust-panel > div { min-height: 94px; padding: 17px 14px; }
.demo-directory .trust-panel > div + div { border-left: 1px solid #dddde1; }
.demo-directory .trust-panel strong { color: #1d1d1f; font-size: 20px; font-weight: 650; letter-spacing: -.025em; }
.demo-directory .trust-panel span { margin-top: 5px; color: #86868b; font-size: 11px; }

.demo-directory .catalog { padding-block: 68px 110px; }
.demo-directory .catalog-toolbar { margin-bottom: 24px; }
.demo-directory .section-heading { align-items: flex-end; margin-bottom: 24px; }
.demo-directory .section-kicker { color: #86868b; font-size: 12px; font-weight: 600; letter-spacing: 0; text-transform: none; }
.demo-directory .section-heading h2 { margin: 7px 0 7px; color: #1d1d1f; font-size: clamp(34px,4vw,48px); font-weight: 700; line-height: 1.08; letter-spacing: -.045em; }
.demo-directory .section-heading p { color: #6e6e73; font-size: 14px; }
.demo-directory .search-box { height: 44px; flex-basis: 300px; border: 1px solid #d2d2d7; border-radius: 12px; background: #fff; box-shadow: none; }
.demo-directory .search-box:focus-within { border-color: #0071e3; box-shadow: 0 0 0 3px rgba(0,113,227,.12); }
.demo-directory .search-box input { font-size: 13px; }
.demo-directory .filter-row { gap: 8px; padding-bottom: 4px; }
.demo-directory .filter-chip { height: 36px; padding-inline: 15px; border: 1px solid #d2d2d7; border-radius: 999px; color: #424245; background: transparent; font-size: 12px; font-weight: 500; }
.demo-directory .filter-chip:hover { color: #0066cc; border-color: #8cbcec; }
.demo-directory .filter-chip.active { color: #fff; border-color: #1d1d1f; background: #1d1d1f; box-shadow: none; }
.demo-directory .filter-chip.active span { color: #d2d2d7; }

.demo-directory .template-grid { grid-template-columns: repeat(2,minmax(0,1fr)); gap: 24px; }
.demo-directory .template-card { min-height: 0; display: flex; overflow: hidden; flex-direction: column; border: 0; border-radius: 28px; background: #fff; box-shadow: none; }
.demo-directory .template-card:hover { transform: translateY(-3px); border-color: transparent; box-shadow: 0 14px 38px rgba(0,0,0,.08); }
.demo-directory .preview-stage { height: 390px; min-height: 390px; padding: 42px 36px; background: #eceef2; }
.demo-directory .accent-1 .preview-stage, .demo-directory .accent-2 .preview-stage { background: #eceef2; }
.demo-directory .preview-stage::after { display: none; }
.demo-directory .browser-frame { width: 88%; height: 294px; border: 5px solid #252527; border-radius: 14px; background: #252527; box-shadow: 0 24px 50px rgba(0,0,0,.2); }
.demo-directory .template-card:hover .browser-frame { transform: translateY(-3px); }
.demo-directory .browser-bar { height: 22px; background: #252527; }
.demo-directory .browser-screen { height: calc(100% - 22px); border-radius: 6px; }
.demo-directory .phone-frame { right: 28px; bottom: 25px; width: 92px; height: 198px; padding: 6px; border: 4px solid #252527; border-radius: 22px; background: #252527; box-shadow: 0 20px 42px rgba(0,0,0,.25); }
.demo-directory .template-card:hover .phone-frame { transform: translateY(-4px); }
.demo-directory .phone-screen { border-radius: 13px; }
.demo-directory .card-content { align-items: stretch; justify-content: flex-start; padding: 28px 30px 30px; border: 0; }
.demo-directory .card-meta { margin-bottom: 12px; }
.demo-directory .card-meta span { padding: 0; color: #86868b; background: transparent; font-size: 11px; font-weight: 550; }
.demo-directory .card-meta span + span { color: #86868b; background: transparent; }
.demo-directory .card-meta .hot-tag { color: #bf4800; background: transparent; }
.demo-directory .card-content h3 { color: #1d1d1f; font-size: 24px; font-weight: 650; line-height: 1.2; letter-spacing: -.035em; }
.demo-directory .card-content > p { min-height: 44px; margin: 10px 0 21px; color: #6e6e73; font-size: 13px; line-height: 1.65; }
.demo-directory .demo-link { min-height: 0; align-self: flex-start; padding: 0; border: 0; border-radius: 0; color: #0066cc; background: transparent; font-size: 13px; font-weight: 500; }
.demo-directory .demo-link:hover { color: #0066cc; border: 0; }
.demo-directory .demo-link.disabled { color: #86868b; }
.demo-directory .empty-state { border: 0; border-radius: 24px; background: #fff; }
.demo-directory .site-footer { min-height: 116px; border-color: #d2d2d7; background: #f5f5f7; }
.demo-directory .footer-inner { min-height: 116px; }
.demo-directory .back-top { width: 42px; height: 42px; border-radius: 50%; background: #1d1d1f; }

@media (max-width: 980px) {
    .demo-directory .demo-hero-grid { min-height: 470px; padding-block: 64px 42px; }
    .demo-directory .template-grid { grid-template-columns: 1fr; }
    .demo-directory .template-card { max-width: 720px; margin-inline: auto; }
}
@media (max-width: 680px) {
    .demo-directory .shell { width: min(100% - 30px, 560px); }
    .demo-directory .site-header { height: 50px; }
    .demo-directory .brand { font-size: 12px; }
    .demo-directory .brand-mark { width: 28px; height: 28px; }
    .demo-directory .header-actions .button { min-height: 30px; padding-inline: 12px; font-size: 11px; }
    .demo-directory .demo-hero-grid { min-height: 0; padding-block: 56px 34px; }
    .demo-directory .eyebrow { font-size: 12px; }
    .demo-directory .demo-hero h1 { margin-block: 14px; font-size: 38px; }
    .demo-directory .demo-hero-copy > p { font-size: 16px; line-height: 1.55; }
    .demo-directory .hero-actions { margin-top: 23px; }
    .demo-directory .trust-panel { margin-top: 38px; }
    .demo-directory .trust-panel > div { min-height: 76px; padding: 12px 7px; }
    .demo-directory .trust-panel strong { font-size: 15px; }
    .demo-directory .trust-panel span { display: block; font-size: 9px; }
    .demo-directory .catalog { padding-block: 46px 76px; }
    .demo-directory .section-heading { align-items: stretch; }
    .demo-directory .section-heading h2 { font-size: 31px; }
    .demo-directory .search-box { width: 100%; flex-basis: 44px; }
    .demo-directory .template-card { display: flex; border-radius: 22px; }
    .demo-directory .preview-stage { height: 260px; min-height: 260px; padding: 26px 20px; }
    .demo-directory .browser-frame { width: 88%; height: 204px; }
    .demo-directory .phone-frame { right: 17px; bottom: 17px; width: 69px; height: 148px; border-radius: 17px; }
    .demo-directory .card-content { padding: 23px 22px 25px; border: 0; }
    .demo-directory .card-content h3 { font-size: 21px; }
    .demo-directory .footer-inner { min-height: 126px; }
}

/* Public v1.3.1 — compact spacing aligned with the chosen industry reference */
.demo-directory .shell { width: min(1320px, calc(100% - 72px)); }
.demo-directory .site-header { height: 64px; border-bottom: 1px solid #e4e8ef; background: rgba(255,255,255,.94); }
.demo-directory .brand-mark { width: 34px; height: 34px; color: #fff; background: #0878ef; box-shadow: 0 8px 20px rgba(0,113,227,.16); }
.demo-directory .nav-link { padding-block: 23px 21px; }
.demo-directory .nav-link.active { color: #0066cc; }
.demo-directory .nav-link.active::after { display: block; height: 2px; background: #0878ef; }
.demo-directory .button { min-height: 42px; padding-inline: 19px; border-radius: 10px; font-size: 12px; }
.demo-directory .button-primary { border-radius: 10px; }

.demo-directory .demo-hero { background: #f7f9fc; border-bottom: 1px solid #e3e8f0; }
.demo-directory .demo-hero-grid {
    min-height: 278px;
    display: grid;
    grid-template-columns: minmax(0,1.15fr) minmax(470px,.85fr);
    align-items: center;
    gap: 70px;
    padding-block: 38px;
}
.demo-directory .demo-hero-copy { max-width: none; text-align: left; }
.demo-directory .eyebrow { color: #0878ef; font-size: 10px; font-weight: 750; letter-spacing: .12em; }
.demo-directory .demo-hero h1 { max-width: 760px; margin: 14px 0 12px; font-size: clamp(34px,3vw,42px); line-height: 1.16; letter-spacing: -.042em; }
.demo-directory .demo-hero-copy > p { max-width: 680px; margin: 0; color: #727d8f; font-size: 13px; line-height: 1.7; }
.demo-directory .hero-actions { justify-content: flex-start; margin-top: 22px; }
.demo-directory .trust-panel { width: 100%; margin-top: 0; border: 1px solid #dfe5ee; border-radius: 16px; background: #fff; box-shadow: 0 10px 28px rgba(29,45,76,.035); }
.demo-directory .trust-panel > div { min-height: 108px; padding: 17px 12px; }
.demo-directory .trust-panel > div + div { border-left-color: #e6eaf0; }
.demo-directory .trust-panel strong { color: #263248; font-size: 13px; font-weight: 650; letter-spacing: 0; }
.demo-directory .trust-panel span { margin-top: 7px; color: #919bab; font-size: 10px; }

.demo-directory .catalog { padding-block: 30px 92px; }
.demo-directory .catalog-toolbar { margin-bottom: 18px; }
.demo-directory .section-heading { align-items: center; margin-bottom: 18px; }
.demo-directory .section-kicker { color: #0878ef; font-size: 9px; font-weight: 750; letter-spacing: .12em; }
.demo-directory .section-heading h2 { margin: 6px 0 4px; font-size: 28px; line-height: 1.15; letter-spacing: -.035em; }
.demo-directory .section-heading p { font-size: 11px; }
.demo-directory .search-box { height: 42px; flex-basis: 290px; border-radius: 10px; }
.demo-directory .filter-row { gap: 8px; }
.demo-directory .filter-chip { height: 34px; padding-inline: 13px; border-radius: 8px; background: #fff; font-size: 11px; }
.demo-directory .filter-chip.active { border-color: #0878ef; background: #0878ef; }

.demo-directory .template-grid { grid-template-columns: repeat(2,minmax(0,1fr)); gap: 18px; }
.demo-directory .template-card { min-height: 260px; display: grid; grid-template-columns: minmax(0,1.55fr) minmax(205px,.72fr); border: 1px solid #e1e6ee; border-radius: 16px; box-shadow: 0 6px 22px rgba(28,43,73,.035); }
.demo-directory .template-card:hover { transform: translateY(-3px); border-color: #b8cff2; box-shadow: 0 14px 34px rgba(28,43,73,.08); }
.demo-directory .preview-stage { height: 100%; min-height: 260px; padding: 20px 18px; background: #f0f3f7; }
.demo-directory .accent-1 .preview-stage, .demo-directory .accent-2 .preview-stage { background: #f0f3f7; }
.demo-directory .browser-frame { width: 84%; height: 210px; border-width: 3px; border-radius: 11px; box-shadow: 0 13px 26px rgba(32,45,67,.17); }
.demo-directory .browser-bar { height: 19px; padding-inline: 7px; }
.demo-directory .browser-bar i { width: 4px; height: 4px; }
.demo-directory .browser-screen { height: calc(100% - 19px); }
.demo-directory .phone-frame { right: 14px; bottom: 18px; width: 76px; height: 164px; padding: 5px; border-width: 3px; border-radius: 17px; box-shadow: 0 12px 25px rgba(32,45,67,.22); }
.demo-directory .phone-screen { border-radius: 10px; }
.demo-directory .card-content { justify-content: center; padding: 22px 20px; border-left: 1px solid #e8ecf2; }
.demo-directory .card-meta { margin-bottom: 11px; }
.demo-directory .card-meta span { padding: 4px 7px; border-radius: 5px; color: #687386; background: #f0f2f6; font-size: 9px; }
.demo-directory .card-meta .hot-tag { color: #0066cc; background: #eaf2ff; }
.demo-directory .card-content h3 { font-size: 18px; line-height: 1.35; }
.demo-directory .card-content > p { min-height: 0; margin: 9px 0 17px; font-size: 11px; line-height: 1.7; }
.demo-directory .demo-link { min-height: 36px; padding: 0 13px; border: 1px solid #d9e0e9; border-radius: 9px; color: #26344c; background: #fff; font-size: 11px; }
.demo-directory .demo-link:hover { color: #0066cc; border: 1px solid #9fc2ef; }
.demo-directory .demo-link.disabled { padding: 0; border: 0; }

@media (max-width: 1080px) {
    .demo-directory .shell { width: min(100% - 44px, 1040px); }
    .demo-directory .demo-hero-grid { grid-template-columns: minmax(0,1fr) 440px; gap: 38px; }
    .demo-directory .template-card { grid-template-columns: 1.42fr .78fr; }
}
@media (max-width: 900px) {
    .demo-directory .demo-hero-grid { min-height: 0; grid-template-columns: 1fr; gap: 24px; padding-block: 34px; }
    .demo-directory .trust-panel { width: 100%; }
    .demo-directory .template-grid { grid-template-columns: 1fr; }
    .demo-directory .template-card { max-width: none; grid-template-columns: minmax(0,1.55fr) minmax(210px,.72fr); }
}
@media (max-width: 680px) {
    .demo-directory .shell { width: min(100% - 28px, 560px); }
    .demo-directory .site-header { height: 58px; }
    .demo-directory .demo-hero-grid { padding-block: 28px; }
    .demo-directory .eyebrow { font-size: 9px; }
    .demo-directory .demo-hero h1 { margin-block: 11px; font-size: 31px; }
    .demo-directory .demo-hero-copy > p { font-size: 12px; }
    .demo-directory .hero-actions { margin-top: 18px; }
    .demo-directory .trust-panel > div { min-height: 72px; padding: 10px 7px; }
    .demo-directory .trust-panel strong { font-size: 11px; }
    .demo-directory .trust-panel span { display: none; }
    .demo-directory .catalog { padding-block: 24px 70px; }
    .demo-directory .section-heading h2 { font-size: 24px; }
    .demo-directory .search-box { width: 100%; height: 42px; flex: 0 0 42px; }
    .demo-directory .template-card { display: block; border-radius: 16px; }
    .demo-directory .preview-stage { height: 236px; min-height: 236px; }
    .demo-directory .browser-frame { height: 188px; }
    .demo-directory .phone-frame { width: 68px; height: 143px; }
    .demo-directory .card-content { padding: 20px; border-top: 1px solid #e8ecf2; border-left: 0; }
}

/* v1.3.2 — non-blocking screenshot status and lighter phone bezel */
.capture-progress { display: flex; align-items: center; gap: 13px; margin: -4px 0 20px; padding: 14px 16px; border: 1px solid #cfe1f9; border-radius: 12px; color: #1f4f83; background: #f2f7fe; }
.capture-progress > i { width: 18px; height: 18px; flex: 0 0 auto; border: 2px solid #b7d3f5; border-top-color: #0878ef; border-radius: 50%; animation: capture-spin .8s linear infinite; }
.capture-progress > span { display: grid; gap: 3px; }
.capture-progress strong { font-size: 12px; }
.capture-progress small { color: #6f87a1; font-size: 10px; }
.capture-progress button { margin-left: auto; padding: 7px 11px; border: 1px solid #e0a8a8; border-radius: 8px; color: #a33a3a; background: #fff; cursor: pointer; }
.capture-progress.failed { color: #8e3131; border-color: #edcaca; background: #fff7f7; }
.capture-progress.failed > i { border-color: #d97878; animation: none; }
@keyframes capture-spin { to { transform: rotate(360deg); } }

.demo-directory .phone-frame { padding: 2px; border-width: 1px; border-radius: 14px; }
.demo-directory .phone-speaker { top: 1px; width: 18px; height: 2px; }
.demo-directory .phone-screen { border-radius: 10px; }
@media (max-width: 680px) {
    .capture-progress { align-items: flex-start; }
    .capture-progress button { flex: 0 0 auto; }
    .demo-directory .phone-frame { border-radius: 13px; }
}

/* Public v1.3.4 — compact stacked surfaces, brand lockup and refined footer */
.demo-directory { background: #eef2f7; }
.demo-directory .site-header { height: 60px; border: 0; background: rgba(255,255,255,.94); box-shadow: 0 1px 0 rgba(31,45,68,.07); }
.demo-directory .brand { gap: 10px; }
.demo-directory .brand-logo { position: relative; width: 36px; height: 36px; overflow: hidden; border-radius: 11px; color: #fff; background: linear-gradient(145deg,#1687f8,#0068d8); box-shadow: 0 9px 22px rgba(0,105,220,.2); }
.demo-directory .brand-logo::after { content: ""; position: absolute; inset: 1px; border: 1px solid rgba(255,255,255,.3); border-radius: 10px; pointer-events: none; }
.demo-directory .brand-logo svg { width: 21px; height: 21px; fill: currentColor; stroke: none; }
.demo-directory .brand-copy { min-width: 0; display: grid; gap: 1px; line-height: 1.15; }
.demo-directory .brand-copy strong { overflow: hidden; font-size: 13px; font-weight: 720; text-overflow: ellipsis; white-space: nowrap; }
.demo-directory .brand-copy small { color: #8a95a6; font-size: 8px; font-weight: 550; letter-spacing: .04em; }

.demo-directory main { display: grid; gap: 16px; padding-top: 16px; }
.demo-directory .demo-hero { width: min(1380px,calc(100% - 32px)); margin-inline: auto; overflow: hidden; border: 1px solid rgba(218,225,235,.9); border-radius: 20px; background: #f8fafc; box-shadow: 0 14px 38px rgba(31,45,68,.06),0 2px 8px rgba(31,45,68,.035); }
.demo-directory .demo-hero-grid { width: min(1280px,calc(100% - 64px)); min-height: 228px; gap: 58px; padding-block: 24px; }
.demo-directory .demo-hero h1 { margin: 10px 0 9px; font-size: clamp(32px,2.7vw,39px); }
.demo-directory .demo-hero-copy > p { font-size: 12px; line-height: 1.65; }
.demo-directory .hero-actions { margin-top: 16px; }
.demo-directory .hero-actions .button { min-height: 38px; }
.demo-directory .trust-panel { box-shadow: 0 10px 24px rgba(31,45,68,.045); }
.demo-directory .trust-panel > div { min-height: 88px; padding-block: 13px; }

.demo-directory .catalog { width: min(1380px,calc(100% - 32px)); margin-bottom: 0; padding: 25px 30px 64px; border: 1px solid rgba(218,225,235,.9); border-radius: 20px; background: #fff; box-shadow: 0 14px 38px rgba(31,45,68,.055),0 2px 8px rgba(31,45,68,.03); }
.demo-directory .template-card { box-shadow: 0 7px 22px rgba(31,45,68,.045); }

.demo-directory .site-footer { min-height: 0; padding: 16px 0 22px; border: 0; background: transparent; }
.demo-directory .footer-card { width: min(1380px,calc(100% - 32px)); min-height: 92px; display: grid; grid-template-columns: auto 1fr auto; align-items: center; gap: 28px; padding: 18px 24px; border: 1px solid rgba(255,255,255,.08); border-radius: 19px; color: #fff; background: linear-gradient(135deg,#151b26,#0e1420); box-shadow: 0 16px 38px rgba(15,23,42,.18); }
.demo-directory .footer-brand { display: flex; align-items: center; gap: 11px; }
.demo-directory .footer-brand .brand-logo { width: 38px; height: 38px; flex: none; }
.demo-directory .footer-brand > span:last-child { display: grid; gap: 4px; }
.demo-directory .footer-brand strong { color: #fff; font-size: 12px; }
.demo-directory .footer-brand small { color: #8f9bad; font-size: 9px; }
.demo-directory .footer-nav { display: flex; align-items: center; justify-content: center; gap: 24px; }
.demo-directory .footer-nav a { color: #aeb8c7; font-size: 10px; transition: color .2s ease; }
.demo-directory .footer-nav a:hover { color: #fff; }
.demo-directory .footer-card > p { color: #7e899a; font-size: 9px; white-space: nowrap; }

@media (max-width: 900px) {
    .demo-directory .demo-hero-grid { width: min(100% - 48px,1040px); min-height: 0; gap: 20px; padding-block: 28px; }
    .demo-directory .footer-card { grid-template-columns: auto 1fr; }
    .demo-directory .footer-card > p { display: none; }
    .demo-directory .footer-nav { justify-content: flex-end; }
}
@media (max-width: 680px) {
    .demo-directory .site-header { height: 56px; }
    .demo-directory .brand-logo { width: 34px; height: 34px; }
    .demo-directory .brand-copy small { display: none; }
    .demo-directory main { gap: 10px; padding-top: 8px; }
    .demo-directory .demo-hero { width: calc(100% - 12px); border-radius: 16px; }
    .demo-directory .demo-hero-grid { width: calc(100% - 32px); padding-block: 23px; }
    .demo-directory .demo-hero h1 { font-size: 29px; }
    .demo-directory .catalog { width: calc(100% - 12px); padding: 21px 16px 50px; border-radius: 16px; }
    .demo-directory .footer-card { width: calc(100% - 12px); min-height: 0; grid-template-columns: 1fr auto; gap: 14px; padding: 17px; border-radius: 16px; }
    .demo-directory .footer-nav { grid-column: 1 / -1; justify-content: flex-start; gap: 18px; }
    .demo-directory .footer-card > p { display: block; grid-column: 2; grid-row: 1; }
}

/* Public v1.3.5 — one-page filters without search or footer */
.demo-directory .filter-mode-switch { display: flex; align-items: center; gap: 8px; }
.demo-directory .filter-mode { min-height: 42px; display: inline-flex; align-items: center; justify-content: center; gap: 7px; padding: 0 15px; border: 1px solid #d7dee8; border-radius: 12px; color: #4c586b; background: #fff; cursor: pointer; font-size: 11px; font-weight: 650; white-space: nowrap; transition: color .2s ease,border-color .2s ease,background .2s ease,box-shadow .2s ease,transform .2s ease; }
.demo-directory .filter-mode svg { width: 16px; height: 16px; fill: currentColor; }
.demo-directory .filter-mode span { color: #8c97a8; font-size: 10px; font-weight: 600; }
.demo-directory .filter-mode:hover { color: #0878ef; border-color: #a9cdf5; transform: translateY(-1px); }
.demo-directory .filter-mode.active { color: #fff; border-color: #0878ef; background: #0878ef; box-shadow: 0 8px 18px rgba(8,120,239,.2); }
.demo-directory .filter-mode.active span { color: #dcecff; }

.demo-directory .category-filter { display: grid; grid-template-columns: auto minmax(0,1fr); align-items: center; gap: 24px; padding-top: 18px; border-top: 1px solid #edf0f4; }
.demo-directory .category-filter-title { display: flex; align-items: center; gap: 8px; color: #1f2b3e; white-space: nowrap; }
.demo-directory .category-filter-title > strong { font-size: 12px; }
.demo-directory .category-filter-title > span:last-child { color: #909aaa; font-size: 10px; }
.demo-directory .category-filter-icon { width: 28px; height: 28px; display: grid; place-items: center; border-radius: 9px; color: #0878ef; background: #eaf4ff; }
.demo-directory .category-filter-icon svg { width: 15px; height: 15px; fill: currentColor; }
.demo-directory .category-filter .filter-row { display: flex; flex-wrap: wrap; justify-content: flex-start; overflow: visible; padding: 0; }
.demo-directory .category-filter .filter-chip { min-height: 38px; padding-inline: 15px; border-radius: 999px; background: #f8fafc; }
.demo-directory .category-filter .filter-chip.active { color: #0878ef; border-color: #9fc9f7; background: #edf6ff; box-shadow: 0 5px 14px rgba(8,120,239,.08); }
.demo-directory .category-filter .filter-chip.active span { color: #5d9fe5; }
.demo-directory .catalog { padding-bottom: 42px; }

@media (max-width: 900px) {
    .demo-directory .category-filter { grid-template-columns: 1fr; gap: 12px; }
}

@media (max-width: 680px) {
    .demo-directory .section-heading { align-items: stretch; }
    .demo-directory .filter-mode-switch { width: 100%; }
    .demo-directory .filter-mode { min-width: 0; flex: 1; padding-inline: 10px; }
    .demo-directory .category-filter { padding-top: 16px; }
    .demo-directory .category-filter-title { flex-wrap: wrap; }
    .demo-directory .category-filter-title > span:last-child { width: calc(100% - 36px); margin-left: 36px; margin-top: -7px; }
    .demo-directory .category-filter .filter-row { margin-inline: 0; padding-inline: 0; }
    .demo-directory .category-filter .filter-chip { min-height: 40px; }
    .demo-directory .catalog { padding-bottom: 26px; }
}

/* Public v1.3.11 — keep desktop screenshots at their native 1600 × 900 ratio */
@media (min-width: 681px) {
    .demo-directory .template-card { min-height: 286px; }
    .demo-directory .preview-stage { min-height: 286px; }
    .demo-directory .browser-frame { height: auto; }
    .demo-directory .browser-screen { height: auto; aspect-ratio: 16 / 9; }
}

/* Brand v1.3.7 — compact W mark for header, admin and favicon */
.demo-directory .brand-logo svg { width: 21px; height: 21px; fill: none; stroke: currentColor; stroke-width: 3.2; stroke-linecap: round; stroke-linejoin: round; }
.admin-page .brand-mark { background: linear-gradient(145deg,#2494ff,#0068d8); box-shadow: 0 9px 22px rgba(0,105,220,.24); }
.admin-page .brand-mark svg { fill: none; stroke: currentColor; stroke-width: 2.8; stroke-linecap: round; stroke-linejoin: round; }

/* Typography v1.3.13 — Apple-like system typography without external font downloads */
html { text-rendering: optimizeLegibility; font-synthesis: none; }
body { line-height: 1.5; letter-spacing: -.006em; -moz-osx-font-smoothing: grayscale; }
.demo-directory h1, .demo-directory h2, .demo-directory h3,
.admin-page h1, .admin-page h2, .admin-page h3,
.auth-page h1, .auth-page h2 { font-family: -apple-system, BlinkMacSystemFont, "SF Pro Display", "PingFang SC", "Helvetica Neue", "Segoe UI", "Microsoft YaHei UI", sans-serif; font-weight: 600; }
.demo-directory .demo-hero h1 { font-weight: 600; letter-spacing: -.012em; }
.demo-directory .section-heading h2 { font-weight: 600; letter-spacing: -.01em; }
.demo-directory .card-content h3 { font-weight: 600; letter-spacing: -.014em; }
.auth-page .auth-message h1 { font-weight: 600; letter-spacing: -.018em; }
.auth-page .auth-card h2 { font-weight: 600; letter-spacing: -.012em; }
.demo-directory .brand, .demo-directory .eyebrow, .demo-directory .section-kicker,
.demo-directory .button, .demo-directory .filter-mode, .demo-directory .filter-chip,
.demo-directory .trust-panel strong, .admin-page .admin-nav a, .admin-page .admin-button,
.admin-page .field label, .admin-page .check-label { font-weight: 600; }
.demo-directory .nav-link, .demo-directory .card-meta span, .demo-directory .demo-link,
.admin-page input, .admin-page textarea, .admin-page select { font-weight: 400; }
.demo-directory .demo-hero-copy > p, .demo-directory .section-heading p,
.demo-directory .card-content > p, .admin-page .field-help { letter-spacing: 0; }
.admin-page .stat-card strong, .demo-directory .filter-mode span,
.demo-directory .filter-chip span { font-variant-numeric: tabular-nums; }

/* v1.4.0 — managed categories */
.admin-page .field-help.important { color: #c2414f; font-weight: 600; }
.admin-page .category-manage-row { grid-template-columns: 44px minmax(0,1fr) 90px 96px; }
.admin-page .category-rename-form { display: grid; grid-template-columns: minmax(0,1fr) auto; align-items: end; gap: 10px; }
.admin-page .category-rename-form .admin-button { min-height: 40px; }
.admin-page .category-order-actions { display: flex; justify-content: flex-end; gap: 8px; }
.admin-page .category-order-actions button { width: 44px; height: 44px; display: grid; place-items: center; padding: 0; border: 1px solid #dfe4ec; border-radius: 11px; color: #58657a; background: #fff; cursor: pointer; transition: color .2s ease,border-color .2s ease,background .2s ease,transform .2s ease; }
.admin-page .category-order-actions button:hover:not(:disabled) { color: #5556d8; border-color: #b7b9f2; background: #f7f7ff; transform: translateY(-1px); }
.admin-page .category-order-actions button:focus-visible { outline: 3px solid rgba(91,92,226,.16); outline-offset: 2px; }
.admin-page .category-order-actions button:disabled { color: #c5cbd5; background: #f7f8fa; cursor: not-allowed; }
.admin-page .category-order-actions svg { width: 17px; height: 17px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.admin-page .category-create { padding: 24px; }
.admin-page .category-create > span { color: #6566df; font-size: 9px; font-weight: 800; letter-spacing: .12em; }
.admin-page .category-create h3 { margin: 11px 0 18px; font-size: 18px; letter-spacing: -.02em; }
.admin-page .category-create label { display: block; margin-bottom: 7px; color: #687489; font-size: 9px; font-weight: 700; }
.admin-page .category-create input { width: 100%; min-height: 44px; padding: 0 13px; border: 1px solid #dfe4ec; border-radius: 11px; outline: 0; color: #303a4d; background: #fff; font-size: 11px; }
.admin-page .category-create input:focus { border-color: #a7a9f0; box-shadow: 0 0 0 3px rgba(91,92,226,.08); }
.admin-page .category-create .admin-button { width: 100%; margin-top: 12px; }

@media (max-width: 680px) {
    .admin-page .category-manage-row { grid-template-columns: 42px minmax(0,1fr); }
    .admin-page .category-rename-form { grid-column: 2; grid-template-columns: 1fr; }
    .admin-page .category-manage-row .category-rename-form label,
    .admin-page .category-manage-row .category-rename-form .admin-button { grid-column: auto; }
    .admin-page .category-order-actions { grid-column: 2; justify-content: flex-start; }
}

/* v1.4.3 — compact hero, animated gradient demo names and clear primary actions */
.demo-directory .demo-hero-grid { min-height: 218px; padding-block: 18px; }
.demo-directory .card-content h3 {
    color: #153b70;
    background: linear-gradient(100deg,#153b70 0%,#0878ef 32%,#665de7 50%,#0878ef 68%,#153b70 100%);
    background-size: 240% 100%;
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    animation: demo-title-gradient 8s ease-in-out infinite alternate;
}
.demo-directory .template-card:nth-child(2n) .card-content h3 { animation-delay: -3s; }
.demo-directory .template-card:nth-child(3n) .card-content h3 { animation-delay: -5s; }
.demo-directory .demo-link:not(.disabled) {
    min-height: 38px;
    padding: 0 14px;
    border: 1px solid #0878ef;
    border-radius: 9px;
    color: #fff;
    background: linear-gradient(135deg,#1687f8,#0878ef 55%,#0068d8);
    box-shadow: 0 7px 16px rgba(8,120,239,.18);
    transition: transform .2s ease,box-shadow .2s ease,background .2s ease;
}
.demo-directory .demo-link:not(.disabled):hover {
    color: #fff;
    border-color: #0068d8;
    background: linear-gradient(135deg,#0878ef,#0068d8);
    box-shadow: 0 10px 22px rgba(8,120,239,.24);
    transform: translateY(-1px);
}
.demo-directory .demo-link:not(.disabled):focus-visible { outline: 3px solid rgba(8,120,239,.2); outline-offset: 3px; }
@keyframes demo-title-gradient { from { background-position: 0% 50%; } to { background-position: 100% 50%; } }

@media (max-width: 900px) {
    .demo-directory .demo-hero-grid { gap: 18px; padding-block: 24px; }
}
@media (max-width: 680px) {
    .demo-directory .demo-hero-grid { padding-block: 20px; }
}
@media (prefers-reduced-motion: reduce) {
    .demo-directory .card-content h3 { animation: none; background-position: 50% 50%; }
}

/* v1.4.4 — single-line brand lockup and unified speed-link mark */
.demo-directory .brand-logo,
.admin-page .brand-mark,
.auth-page .brand-mark {
    color: #fff;
    background: #0878ef;
    box-shadow: 0 5px 14px rgba(8,120,239,.2);
}
.demo-directory .brand-logo svg,
.admin-page .brand-mark svg,
.auth-page .brand-mark svg {
    fill: none;
    stroke: currentColor;
    stroke-width: 2.7;
    stroke-linecap: round;
    stroke-linejoin: round;
}
.demo-directory .brand-copy { display: block; line-height: 1; }
.demo-directory .brand-copy strong { font-size: 14px; font-weight: 650; letter-spacing: -.012em; }
.admin-page .admin-logo > span:last-child { display: block; }
.admin-page .admin-logo strong { font-size: 14px; font-weight: 650; }

/* v1.4.5 — header WeChat contact entry and native accessible dialog */
.demo-directory .header-contact-button {
    min-height: 38px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 0 15px;
    border: 1px solid #0878ef;
    border-radius: 10px;
    color: #fff;
    background: #0878ef;
    box-shadow: 0 7px 18px rgba(8,120,239,.18);
    font-size: 12px;
    font-weight: 680;
    cursor: pointer;
    transition: background .2s ease,box-shadow .2s ease,transform .2s ease;
}
.demo-directory .header-contact-button:hover { background: #0068d8; box-shadow: 0 10px 22px rgba(8,120,239,.24); transform: translateY(-1px); }
.demo-directory .header-contact-button:focus-visible { outline: 3px solid rgba(8,120,239,.2); outline-offset: 3px; }
.demo-directory .header-contact-button svg { width: 17px; height: 17px; fill: none; stroke: currentColor; stroke-width: 1.65; stroke-linecap: round; stroke-linejoin: round; }
.contact-dialog { width: min(420px,calc(100% - 28px)); max-height: calc(100dvh - 28px); margin: auto; padding: 0; overflow: visible; border: 0; border-radius: 24px; color: #172033; background: transparent; }
.contact-dialog::backdrop { background: rgba(13,22,36,.54); backdrop-filter: blur(7px); }
.contact-dialog[open] { animation: contact-dialog-in .22s cubic-bezier(.2,.8,.2,1); }
.contact-dialog[open]::backdrop { animation: contact-backdrop-in .2s ease-out; }
.contact-dialog-card { position: relative; max-height: calc(100dvh - 28px); overflow-y: auto; padding: 30px; border: 1px solid rgba(255,255,255,.88); border-radius: 24px; background: rgba(255,255,255,.98); box-shadow: 0 28px 80px rgba(15,31,55,.24); text-align: center; }
.contact-dialog-close { position: absolute; top: 14px; right: 14px; width: 38px; height: 38px; display: grid; place-items: center; padding: 0; border: 0; border-radius: 50%; color: #718096; background: #f1f4f8; cursor: pointer; transition: color .2s ease,background .2s ease,transform .2s ease; }
.contact-dialog-close:hover { color: #172033; background: #e8edf3; transform: rotate(4deg); }
.contact-dialog-close:focus-visible { outline: 3px solid rgba(8,120,239,.2); outline-offset: 2px; }
.contact-dialog-close svg { width: 18px; height: 18px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; }
.contact-dialog-icon { width: 48px; height: 48px; display: grid; place-items: center; margin: 0 auto 14px; border-radius: 15px; color: #fff; background: linear-gradient(145deg,#22c979,#06a95f); box-shadow: 0 10px 24px rgba(6,169,95,.2); }
.contact-dialog-icon svg { width: 26px; height: 26px; fill: none; stroke: currentColor; stroke-width: 1.7; stroke-linecap: round; stroke-linejoin: round; }
.contact-dialog-icon circle { fill: currentColor; stroke: none; }
.contact-dialog-kicker { color: #0878ef; font-size: 10px; font-weight: 780; letter-spacing: .12em; }
.contact-dialog h2 { margin: 8px 0 7px; font-size: 24px; line-height: 1.25; letter-spacing: -.035em; }
.contact-dialog p { margin: 0; color: #7c8798; font-size: 13px; }
.contact-image-shell { width: min(270px,100%); min-height: 220px; display: grid; place-items: center; margin: 22px auto 16px; padding: 12px; overflow: hidden; border: 1px solid #e4e9f0; border-radius: 18px; background: #f7f9fc; }
.contact-image-shell img { width: 100%; max-height: 350px; object-fit: contain; border-radius: 11px; }
.contact-dialog small { display: block; color: #9aa4b3; font-size: 10px; line-height: 1.6; }
@keyframes contact-dialog-in { from { opacity: 0; transform: translateY(10px) scale(.98); } }
@keyframes contact-backdrop-in { from { opacity: 0; } }

.admin-page .contact-setting-grid { display: grid; grid-template-columns: minmax(0,1fr) 300px; align-items: start; gap: 24px; }
.admin-page .contact-setting-copy { display: grid; gap: 18px; }
.admin-page .contact-setting-note { min-height: 82px; display: flex; align-items: center; gap: 13px; padding: 15px; border: 1px solid #e2e8f0; border-radius: 13px; background: #f8fafc; }
.admin-page .contact-setting-note > svg { width: 24px; height: 24px; flex: none; color: #5556d8; fill: none; stroke: currentColor; stroke-width: 1.6; stroke-linecap: round; stroke-linejoin: round; }
.admin-page .contact-setting-note strong,.admin-page .contact-setting-note small { display: block; }
.admin-page .contact-setting-note strong { color: #455166; font-size: 10px; }
.admin-page .contact-setting-note small { margin-top: 5px; color: #8d98a9; font-size: 9px; line-height: 1.55; }
.admin-page .contact-image-preview { width: 100%; max-height: 260px; margin: 0 0 12px; object-fit: contain; border: 1px solid #e2e7ee; border-radius: 13px; background: #f7f9fc; }
.admin-page .contact-upload { min-height: 132px; }

@media (max-width: 760px) {
    .demo-directory .header-contact-button { min-height: 38px; padding-inline: 12px; font-size: 11px; }
    .demo-directory .header-contact-button svg { width: 16px; height: 16px; }
    .contact-dialog-card { padding: 26px 20px 22px; border-radius: 21px; }
    .contact-dialog h2 { padding-inline: 28px; font-size: 21px; }
    .contact-image-shell { margin-top: 18px; }
    .admin-page .contact-setting-grid { grid-template-columns: 1fr; }
}
@media (max-width: 420px) {
    .demo-directory .brand { gap: 8px; }
    .demo-directory .brand-copy strong { max-width: 120px; }
    .demo-directory .header-contact-button { gap: 6px; padding-inline: 10px; }
}
@media (prefers-reduced-motion: reduce) {
    .contact-dialog[open],.contact-dialog[open]::backdrop { animation: none; }
}

/* v1.4.6 — graphite browser-and-spark brand mark */
.demo-directory .brand-logo,
.admin-page .brand-mark,
.auth-page .brand-mark {
    overflow: visible;
    border-radius: 0;
    background: transparent;
    box-shadow: none;
}
.demo-directory .brand-logo::after { display: none; }
.demo-directory .brand-logo img,
.admin-page .brand-mark img,
.auth-page .brand-mark img {
    width: 32px;
    height: 32px;
    object-fit: contain;
}
.admin-page .brand-mark img,
.auth-page .brand-mark img { filter: brightness(0) invert(1); }
.demo-directory .brand-logo img { filter: none; }
@media (max-width: 680px) {
    .demo-directory .brand-logo img { width: 30px; height: 30px; }
}
