/* Uraio Business OS — core application styles */
@import url('https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700&family=Sora:wght@500;600;700;800&display=swap');

:root {
  --font-head: 'Sora', system-ui, -apple-system, 'Segoe UI', sans-serif;
  --font-body: 'Inter', system-ui, -apple-system, 'Segoe UI', sans-serif;
  --ink: #0b1220;
  --ink-soft: #31403d;
  --muted: #687873;
  --line: #e2eae7;
  --line-strong: #cddbd6;
  --surface: #ffffff;
  --surface-2: #f6f9f8;
  --surface-3: #edf3f1;
  --brand: #0f766e;
  --brand-dark: #0a5a54;
  --brand-soft: #d9f1ed;
  --accent: #f59e0b;
  --danger: #c2413b;
  --danger-soft: #fdecea;
  --success: #15803d;
  --success-soft: #e6f6eb;
  --warning: #b45309;
  --warning-soft: #fdf3e2;
  --info: #1d4ed8;
  --info-soft: #e8eefd;
  --shadow-sm: 0 1px 2px rgba(11, 18, 32, .05);
  --shadow: 0 8px 24px rgba(11, 18, 32, .07);
  --shadow-lg: 0 24px 60px rgba(11, 18, 32, .14);
  --radius-sm: 8px;
  --radius: 14px;
  --radius-lg: 22px;
  --sidebar-w: 258px;
  --topbar-h: 68px;
  --transition: .18s ease;
}

[data-theme="dark"] {
  --ink: #eaf2ef;
  --ink-soft: #c2d0cc;
  --muted: #91a39e;
  --line: #22302d;
  --line-strong: #2f423e;
  --surface: #0f1716;
  --surface-2: #131e1c;
  --surface-3: #1a2724;
  --brand: #2dd4bf;
  --brand-dark: #14b8a6;
  --brand-soft: #0d3833;
  --danger-soft: #3a1b1a;
  --success-soft: #12301f;
  --warning-soft: #33240f;
  --info-soft: #14213f;
  --shadow-sm: 0 1px 2px rgba(0, 0, 0, .3);
  --shadow: 0 10px 30px rgba(0, 0, 0, .28);
  --shadow-lg: 0 24px 60px rgba(0, 0, 0, .4);
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  font-family: var(--font-body);
  color: var(--ink);
  background: var(--surface-2);
  font-size: 15px;
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
}
img { max-width: 100%; display: block; }
a { color: var(--brand); text-decoration: none; }
a:hover { color: var(--brand-dark); }
h1, h2, h3, h4, h5 { font-family: var(--font-head); line-height: 1.15; margin: 0 0 .5em; letter-spacing: -.02em; }
h1 { font-size: clamp(1.8rem, 3vw, 2.5rem); }
h2 { font-size: clamp(1.35rem, 2.2vw, 1.8rem); }
h3 { font-size: 1.15rem; }
p { margin: 0 0 1em; }
hr { border: 0; border-top: 1px solid var(--line); margin: 24px 0; }
::selection { background: var(--brand-soft); color: var(--brand-dark); }

.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0,0,0,0); white-space: nowrap; border: 0; }
.muted { color: var(--muted); }
.small { font-size: .82rem; }
.strong { font-weight: 600; }
.text-right { text-align: right; }
.text-center { text-align: center; }
.nowrap { white-space: nowrap; }
.mt-0 { margin-top: 0; } .mt-1 { margin-top: 8px; } .mt-2 { margin-top: 16px; } .mt-3 { margin-top: 24px; } .mt-4 { margin-top: 32px; }
.mb-0 { margin-bottom: 0; } .mb-1 { margin-bottom: 8px; } .mb-2 { margin-bottom: 16px; } .mb-3 { margin-bottom: 24px; }
.flex { display: flex; gap: 12px; align-items: center; }
.flex-between { display: flex; gap: 16px; align-items: center; justify-content: space-between; }
.flex-wrap { flex-wrap: wrap; }
.grow { flex: 1; }
.hidden { display: none !important; }
.icon { width: 20px; height: 20px; flex: 0 0 auto; }
.icon-sm { width: 16px; height: 16px; }
.icon-lg { width: 28px; height: 28px; }

/* Brand */
.brand { display: inline-flex; align-items: center; gap: 10px; font-family: var(--font-head); font-weight: 800; color: var(--ink); font-size: 1.15rem; letter-spacing: -.03em; }
.brand:hover { color: var(--ink); }
.brand-mark { width: 34px; height: 34px; border-radius: 10px; background: linear-gradient(135deg, var(--brand) 0%, #0b4f49 100%); color: #fff; display: inline-grid; place-items: center; box-shadow: 0 5px 14px rgba(15, 118, 110, .28); flex: 0 0 auto; }
.brand-mark svg { width: 22px; height: 22px; }
.brand-mark-sm { width: 28px; height: 28px; border-radius: 8px; }
.brand-mark-sm svg { width: 18px; height: 18px; }
.brand-mark-lg { width: 44px; height: 44px; border-radius: 13px; }
.brand-mark-lg svg { width: 28px; height: 28px; }
.brand-center { justify-content: center; }

/* Buttons */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  border: 1px solid transparent; border-radius: 10px; padding: 10px 16px;
  font-family: var(--font-body); font-weight: 600; font-size: .9rem; line-height: 1.2;
  cursor: pointer; transition: var(--transition); text-decoration: none; white-space: nowrap;
  background: var(--surface); color: var(--ink);
}
.btn:hover { transform: translateY(-1px); }
.btn:active { transform: translateY(0); }
.btn-primary { background: var(--brand); color: #fff; box-shadow: 0 4px 14px rgba(15, 118, 110, .22); }
.btn-primary:hover { background: var(--brand-dark); color: #fff; }
.btn-dark { background: var(--ink); color: var(--surface); }
.btn-dark:hover { color: var(--surface); opacity: .9; }
.btn-ghost { background: transparent; border-color: var(--line-strong); color: var(--ink); }
.btn-ghost:hover { background: var(--surface-3); color: var(--ink); }
.btn-soft { background: var(--brand-soft); color: var(--brand-dark); }
.btn-soft:hover { color: var(--brand-dark); }
.btn-danger { background: var(--danger); color: #fff; }
.btn-danger:hover { color: #fff; opacity: .9; }
.btn-sm { padding: 7px 11px; font-size: .8rem; border-radius: 8px; }
.btn-lg { padding: 13px 22px; font-size: 1rem; border-radius: 12px; }
.btn-block { width: 100%; }
.btn[disabled] { opacity: .55; cursor: not-allowed; transform: none; }
.btn-icon { padding: 8px; width: 36px; height: 36px; }
.btn-group { display: inline-flex; gap: 6px; flex-wrap: wrap; }
.link { font-weight: 600; }

/* Forms */
label { display: block; font-size: .82rem; font-weight: 600; margin-bottom: 6px; color: var(--ink-soft); }
input[type="text"], input[type="email"], input[type="password"], input[type="tel"], input[type="number"],
input[type="url"], input[type="date"], input[type="time"], input[type="datetime-local"], input[type="search"],
select, textarea {
  width: 100%; border: 1px solid var(--line-strong); border-radius: 10px; background: var(--surface);
  color: var(--ink); padding: 10px 12px; font-family: var(--font-body); font-size: .92rem;
  transition: border-color var(--transition), box-shadow var(--transition); appearance: none;
}
select { background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' viewBox='0 0 24 24' fill='none' stroke='%23687873' stroke-width='2'%3E%3Cpath d='m6 9 6 6 6-6'/%3E%3C/svg%3E"); background-repeat: no-repeat; background-position: right 12px center; padding-right: 36px; }
textarea { min-height: 100px; resize: vertical; }
input:focus, select:focus, textarea:focus { outline: none; border-color: var(--brand); box-shadow: 0 0 0 3px color-mix(in srgb, var(--brand) 16%, transparent); }
input[type="file"] { font-size: .85rem; width: 100%; border: 1px dashed var(--line-strong); padding: 9px; border-radius: 10px; background: var(--surface-2); }
input[type="checkbox"], input[type="radio"] { accent-color: var(--brand); width: 17px; height: 17px; }
.field { margin-bottom: 16px; min-width: 0; }
.field-col-2 { grid-column: span 2; } .field-col-3 { grid-column: span 3; } .field-col-4 { grid-column: span 4; }
.field-col-6 { grid-column: span 6; } .field-col-8 { grid-column: span 8; } .field-col-12 { grid-column: span 12; }
.form-grid { display: grid; grid-template-columns: repeat(12, 1fr); gap: 0 16px; }
.form-grid > .field-col-4 { grid-column: span 4; }
.form-grid > .field-col-6 { grid-column: span 6; }
.form-grid > .field-col-8 { grid-column: span 8; }
.form-grid > .field-col-12 { grid-column: span 12; }
.field-help { display: block; color: var(--muted); font-size: .76rem; margin-top: 5px; }
.field-error { color: var(--danger); font-size: .78rem; margin-top: 5px; }
.req { color: var(--danger); }
.input-prefix { display: flex; border: 1px solid var(--line-strong); border-radius: 10px; overflow: hidden; background: var(--surface); }
.input-prefix span { padding: 10px 11px; background: var(--surface-3); font-size: .78rem; font-weight: 700; color: var(--muted); border-right: 1px solid var(--line); }
.input-prefix input { border: 0; border-radius: 0; box-shadow: none; }
.input-prefix:focus-within { border-color: var(--brand); box-shadow: 0 0 0 3px color-mix(in srgb, var(--brand) 16%, transparent); }
.field-check { display: flex; align-items: center; min-height: 42px; }
.switch-label { display: inline-flex; gap: 9px; align-items: center; cursor: pointer; margin: 0; font-size: .88rem; }
.switch-label input { accent-color: var(--brand); }
.form-actions { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; margin-top: 8px; padding-top: 18px; border-top: 1px solid var(--line); }
.image-field { display: flex; flex-direction: column; gap: 8px; }
.image-preview { width: 100%; max-width: 180px; height: 110px; object-fit: cover; border-radius: 10px; border: 1px solid var(--line); }
.help-box { background: var(--info-soft); color: var(--ink-soft); border-radius: 10px; padding: 12px 14px; font-size: .84rem; margin-bottom: 16px; }
.help-box strong { color: var(--ink); }
.check-list { list-style: none; padding: 0; margin: 0; display: grid; gap: 7px; }
.check-list li { display: flex; gap: 8px; align-items: flex-start; font-size: .86rem; color: var(--ink-soft); }
.check-list li::before { content: '✓'; color: var(--brand); font-weight: 700; }

/* App shell */
.app-shell { min-height: 100vh; display: grid; grid-template-columns: var(--sidebar-w) minmax(0, 1fr); }
.sidebar { background: var(--surface); border-right: 1px solid var(--line); display: flex; flex-direction: column; position: sticky; top: 0; height: 100vh; z-index: 40; }
.sidebar-head { padding: 20px 20px 14px; display: flex; align-items: center; justify-content: space-between; }
.sidebar-body { overflow-y: auto; padding: 0 12px 20px; flex: 1; scrollbar-width: thin; }
.sidebar-foot { padding: 14px; border-top: 1px solid var(--line); }
.sidebar-label { font-size: .67rem; text-transform: uppercase; letter-spacing: .1em; color: var(--muted); font-weight: 700; padding: 18px 10px 7px; }
.side-nav { display: grid; gap: 2px; }
.side-link { display: flex; align-items: center; gap: 10px; padding: 9px 10px; border-radius: 9px; color: var(--ink-soft); font-weight: 500; font-size: .87rem; transition: var(--transition); }
.side-link .icon { width: 18px; height: 18px; color: var(--muted); }
.side-link:hover { background: var(--surface-2); color: var(--ink); }
.side-link.is-active { background: var(--brand-soft); color: var(--brand-dark); font-weight: 600; }
.side-link.is-active .icon { color: var(--brand-dark); }
.side-link .count { margin-left: auto; background: var(--surface-3); color: var(--muted); border-radius: 20px; padding: 1px 7px; font-size: .68rem; font-weight: 700; }
.side-link.is-active .count { background: color-mix(in srgb, var(--brand) 18%, transparent); color: var(--brand-dark); }
.business-switcher { background: var(--surface-2); border: 1px solid var(--line); border-radius: 12px; padding: 10px; display: flex; gap: 10px; align-items: center; width: 100%; cursor: pointer; text-align: left; }
.business-switcher .avatar { background: var(--brand); color: #fff; }
.business-switcher-meta { min-width: 0; flex: 1; }
.business-switcher-meta strong { display: block; font-size: .82rem; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.business-switcher-meta span { font-size: .7rem; color: var(--muted); display: block; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.avatar { width: 34px; height: 34px; border-radius: 9px; display: inline-grid; place-items: center; font-weight: 700; font-size: .78rem; background: var(--surface-3); color: var(--ink-soft); flex: 0 0 auto; overflow: hidden; }
.avatar img { width: 100%; height: 100%; object-fit: cover; }
.avatar-lg { width: 52px; height: 52px; border-radius: 13px; font-size: 1rem; }
.main { min-width: 0; display: flex; flex-direction: column; min-height: 100vh; }
.topbar { height: var(--topbar-h); background: color-mix(in srgb, var(--surface) 88%, transparent); backdrop-filter: blur(10px); border-bottom: 1px solid var(--line); display: flex; align-items: center; gap: 14px; padding: 0 26px; position: sticky; top: 0; z-index: 30; }
.topbar-title { font-family: var(--font-head); font-weight: 700; font-size: 1.02rem; }
.topbar-title span { display: block; font-family: var(--font-body); font-weight: 400; font-size: .72rem; color: var(--muted); }
.topbar-actions { margin-left: auto; display: flex; align-items: center; gap: 8px; }
.icon-btn { width: 38px; height: 38px; border-radius: 10px; border: 1px solid var(--line); background: var(--surface); display: inline-grid; place-items: center; color: var(--ink-soft); cursor: pointer; position: relative; transition: var(--transition); }
.icon-btn:hover { background: var(--surface-2); color: var(--ink); }
.icon-btn .dot { position: absolute; top: 7px; right: 7px; width: 7px; height: 7px; border-radius: 50%; background: var(--danger); border: 2px solid var(--surface); }
.content { padding: 26px; max-width: 1480px; width: 100%; margin: 0 auto; flex: 1; }
.page-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 18px; margin-bottom: 24px; flex-wrap: wrap; }
.page-head h1 { margin: 0 0 5px; font-size: 1.7rem; }
.page-head p { margin: 0; color: var(--muted); font-size: .9rem; }
.page-actions { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; }
.breadcrumb { display: flex; gap: 6px; align-items: center; font-size: .76rem; color: var(--muted); margin-bottom: 8px; }
.breadcrumb a { color: var(--muted); }
.breadcrumb span { color: var(--line-strong); }

/* Cards and layout */
.card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow-sm); }
.card-pad { padding: 22px; }
.card-head { display: flex; align-items: center; justify-content: space-between; gap: 14px; padding: 18px 22px; border-bottom: 1px solid var(--line); flex-wrap: wrap; }
.card-head h2, .card-head h3 { margin: 0; font-size: 1.02rem; }
.card-body { padding: 22px; }
.card-foot { padding: 14px 22px; border-top: 1px solid var(--line); display: flex; justify-content: space-between; align-items: center; gap: 12px; flex-wrap: wrap; }
.grid { display: grid; gap: 18px; }
.grid-2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.grid-3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.grid-4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.grid-2-1 { grid-template-columns: minmax(0, 2fr) minmax(280px, 1fr); }
.stat-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 14px; margin-bottom: 22px; }
.stat-card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 17px 18px; position: relative; overflow: hidden; }
.stat-card .stat-icon { width: 36px; height: 36px; border-radius: 10px; background: var(--brand-soft); color: var(--brand-dark); display: grid; place-items: center; margin-bottom: 13px; }
.stat-card .stat-icon .icon { width: 19px; height: 19px; }
.stat-label { color: var(--muted); font-size: .76rem; font-weight: 600; text-transform: uppercase; letter-spacing: .05em; }
.stat-value { font-family: var(--font-head); font-size: 1.55rem; font-weight: 700; letter-spacing: -.03em; margin: 2px 0; }
.stat-note { color: var(--muted); font-size: .74rem; }
.section-title { display: flex; align-items: center; justify-content: space-between; gap: 14px; margin: 26px 0 14px; }
.section-title h2 { margin: 0; font-size: 1.12rem; }
.empty-state { padding: 46px 24px; text-align: center; }
.empty-state .empty-icon { width: 54px; height: 54px; margin: 0 auto 14px; border-radius: 15px; display: grid; place-items: center; background: var(--brand-soft); color: var(--brand-dark); }
.empty-state h3 { margin-bottom: 6px; }
.empty-state p { color: var(--muted); max-width: 420px; margin: 0 auto 18px; font-size: .88rem; }

/* Badges, chips, alerts */
.badge { display: inline-flex; align-items: center; gap: 4px; padding: 3px 9px; border-radius: 20px; font-size: .7rem; font-weight: 700; white-space: nowrap; letter-spacing: .01em; }
.badge-success { background: var(--success-soft); color: var(--success); }
.badge-warning { background: var(--warning-soft); color: var(--warning); }
.badge-danger { background: var(--danger-soft); color: var(--danger); }
.badge-info { background: var(--info-soft); color: var(--info); }
.badge-neutral { background: var(--surface-3); color: var(--muted); }
.chip { display: inline-flex; align-items: center; gap: 5px; padding: 5px 10px; background: var(--surface-2); border: 1px solid var(--line); border-radius: 20px; font-size: .76rem; color: var(--ink-soft); }
.alert { padding: 13px 15px; border-radius: 11px; border: 1px solid transparent; font-size: .86rem; margin-bottom: 16px; display: flex; gap: 10px; align-items: flex-start; }
.alert .icon { width: 18px; height: 18px; margin-top: 1px; }
.alert-success { background: var(--success-soft); border-color: color-mix(in srgb, var(--success) 25%, transparent); color: var(--success); }
.alert-danger { background: var(--danger-soft); border-color: color-mix(in srgb, var(--danger) 25%, transparent); color: var(--danger); }
.alert-warning { background: var(--warning-soft); border-color: color-mix(in srgb, var(--warning) 25%, transparent); color: var(--warning); }
.alert-info { background: var(--info-soft); border-color: color-mix(in srgb, var(--info) 25%, transparent); color: var(--info); }

/* Tables */
.table-wrap { overflow-x: auto; }
.table { width: 100%; border-collapse: collapse; font-size: .86rem; }
.table th { text-align: left; padding: 11px 16px; font-size: .7rem; text-transform: uppercase; letter-spacing: .06em; color: var(--muted); background: var(--surface-2); border-bottom: 1px solid var(--line); white-space: nowrap; }
.table td { padding: 12px 16px; border-bottom: 1px solid var(--line); vertical-align: middle; }
.table tr:last-child td { border-bottom: 0; }
.table tbody tr:hover { background: color-mix(in srgb, var(--surface-2) 70%, transparent); }
.table .cell-main { font-weight: 600; color: var(--ink); }
.table .cell-sub { display: block; font-size: .75rem; color: var(--muted); font-weight: 400; }
.table-actions { display: flex; gap: 5px; justify-content: flex-end; }
.table-thumb { width: 38px; height: 38px; border-radius: 8px; object-fit: cover; border: 1px solid var(--line); }
.table-toolbar { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; padding: 14px 18px; border-bottom: 1px solid var(--line); }
.search-input { position: relative; flex: 1; min-width: 200px; }
.search-input .icon { position: absolute; left: 11px; top: 50%; transform: translateY(-50%); width: 17px; height: 17px; color: var(--muted); }
.search-input input { padding-left: 36px; }
.pagination { display: flex; gap: 4px; align-items: center; flex-wrap: wrap; }
.pagination-link { min-width: 32px; height: 32px; display: inline-grid; place-items: center; border-radius: 8px; border: 1px solid var(--line); font-size: .8rem; color: var(--ink-soft); background: var(--surface); }
.pagination-link.is-active { background: var(--brand); border-color: var(--brand); color: #fff; font-weight: 700; }
.pagination-gap { color: var(--muted); padding: 0 4px; }

/* Tabs */
.tabs { display: flex; gap: 4px; border-bottom: 1px solid var(--line); overflow-x: auto; scrollbar-width: none; }
.tab { padding: 10px 14px; font-size: .84rem; font-weight: 600; color: var(--muted); border-bottom: 2px solid transparent; white-space: nowrap; }
.tab:hover { color: var(--ink); }
.tab.is-active { color: var(--brand-dark); border-bottom-color: var(--brand); }

/* Toast + modal */
.toast-stack { position: fixed; right: 20px; bottom: 20px; z-index: 200; display: grid; gap: 9px; width: min(380px, calc(100vw - 40px)); }
.toast { background: var(--ink); color: #fff; padding: 13px 15px; border-radius: 11px; box-shadow: var(--shadow-lg); display: flex; gap: 10px; align-items: flex-start; font-size: .86rem; animation: toastIn .25s ease; }
.toast .icon { width: 18px; height: 18px; margin-top: 1px; }
.toast-success .icon { color: #4ade80; } .toast-danger .icon { color: #fca5a5; } .toast-warning .icon { color: #fcd34d; }
@keyframes toastIn { from { opacity: 0; transform: translateY(12px); } to { opacity: 1; transform: none; } }
.modal-backdrop { position: fixed; inset: 0; background: rgba(7, 13, 20, .55); z-index: 150; display: none; align-items: center; justify-content: center; padding: 20px; }
.modal-backdrop.is-open { display: flex; }
.modal { background: var(--surface); border-radius: var(--radius-lg); box-shadow: var(--shadow-lg); width: min(560px, 100%); max-height: 90vh; overflow-y: auto; padding: 26px; animation: modalIn .2s ease; }
@keyframes modalIn { from { opacity: 0; transform: scale(.97); } to { opacity: 1; transform: none; } }
.modal h2 { font-size: 1.25rem; }
.modal-actions { display: flex; gap: 10px; justify-content: flex-end; margin-top: 20px; }

/* Sidebar mobile */
.mobile-menu-btn { display: none; }
.sidebar-backdrop { display: none; }

/* Auth pages */
.auth-body { min-height: 100vh; display: grid; place-items: center; padding: 30px 18px; background:
  radial-gradient(circle at 12% 15%, color-mix(in srgb, var(--brand) 14%, transparent), transparent 32%),
  radial-gradient(circle at 88% 82%, color-mix(in srgb, var(--accent) 10%, transparent), transparent 28%), var(--surface-2); }
.auth-card { width: min(460px, 100%); background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius-lg); box-shadow: var(--shadow-lg); padding: 32px; }
.auth-card h1 { font-size: 1.6rem; margin-bottom: 6px; }
.auth-sub { color: var(--muted); font-size: .9rem; margin-bottom: 24px; }
.auth-foot { text-align: center; margin-top: 22px; font-size: .84rem; color: var(--muted); }
.auth-split { width: min(1000px, 100%); display: grid; grid-template-columns: 1.05fr .95fr; background: var(--surface); border-radius: 26px; overflow: hidden; box-shadow: var(--shadow-lg); border: 1px solid var(--line); }
.auth-aside { background: linear-gradient(150deg, #0b3f3b 0%, #0f766e 55%, #115e59 100%); color: #fff; padding: 42px; display: flex; flex-direction: column; justify-content: space-between; }
.auth-aside .brand { color: #fff; }
.auth-aside .brand-mark { background: rgba(255,255,255,.14); box-shadow: none; }
.auth-aside h2 { font-size: 1.7rem; margin-top: 30px; }
.auth-aside p { color: rgba(255,255,255,.78); font-size: .92rem; }
.auth-aside .check-list li { color: rgba(255,255,255,.9); }
.auth-aside .check-list li::before { color: #5eead4; }
.auth-form-side { padding: 42px; }
.auth-form-side .brand { display: none; }
.error-body { min-height: 100vh; display: grid; place-items: center; padding: 24px; background: var(--surface-2); }
.error-card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius-lg); padding: 38px; max-width: 480px; text-align: center; box-shadow: var(--shadow); }
.error-code { font-family: var(--font-head); font-size: 3.4rem; font-weight: 800; color: var(--brand); margin: 14px 0 0; line-height: 1; }
.error-actions { display: flex; gap: 10px; justify-content: center; margin-top: 22px; flex-wrap: wrap; }

/* Onboarding */
.wizard-steps { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; margin-bottom: 26px; }
.wizard-step { display: flex; align-items: center; gap: 8px; font-size: .78rem; color: var(--muted); }
.wizard-step .step-num { width: 25px; height: 25px; border-radius: 50%; display: grid; place-items: center; background: var(--surface-3); font-weight: 700; font-size: .72rem; }
.wizard-step.is-active { color: var(--ink); font-weight: 600; }
.wizard-step.is-active .step-num { background: var(--brand); color: #fff; }
.wizard-step.is-done .step-num { background: var(--success-soft); color: var(--success); }
.wizard-divider { width: 22px; height: 1px; background: var(--line-strong); }
.category-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(170px, 1fr)); gap: 10px; max-height: 460px; overflow-y: auto; padding: 2px; }
.category-option { position: relative; border: 1px solid var(--line); border-radius: 12px; padding: 13px; cursor: pointer; background: var(--surface); transition: var(--transition); text-align: left; }
.category-option:hover { border-color: var(--brand); background: var(--surface-2); }
.category-option input { position: absolute; opacity: 0; pointer-events: none; }
.category-option.is-selected { border-color: var(--brand); background: var(--brand-soft); box-shadow: 0 0 0 1px var(--brand); }
.category-option .cat-icon { font-size: 1.35rem; display: block; margin-bottom: 6px; }
.category-option strong { display: block; font-size: .84rem; color: var(--ink); }
.category-option small { display: block; color: var(--muted); font-size: .7rem; margin-top: 2px; }
.category-option .cat-check { position: absolute; top: 9px; right: 9px; width: 18px; height: 18px; border-radius: 50%; background: var(--brand); color: #fff; display: none; place-items: center; font-size: .65rem; }
.category-option.is-selected .cat-check { display: grid; }
.template-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); gap: 16px; }
.template-card { border: 1px solid var(--line); border-radius: 14px; overflow: hidden; cursor: pointer; background: var(--surface); transition: var(--transition); position: relative; }
.template-card:hover { border-color: var(--brand); transform: translateY(-2px); box-shadow: var(--shadow); }
.template-card.is-selected { border-color: var(--brand); box-shadow: 0 0 0 2px var(--brand); }
.template-card input { position: absolute; opacity: 0; }
.template-preview { height: 150px; background: var(--surface-3); position: relative; overflow: hidden; padding: 16px; }
.template-preview .tp-bar { height: 8px; width: 38%; border-radius: 4px; background: var(--brand); margin-bottom: 10px; }
.template-preview .tp-line { height: 5px; border-radius: 3px; background: var(--line-strong); margin-bottom: 6px; }
.template-preview .tp-line.short { width: 55%; }
.template-preview .tp-block { display: flex; gap: 8px; margin-top: 12px; }
.template-preview .tp-block span { flex: 1; height: 42px; border-radius: 7px; background: var(--line); }
.template-preview.saffron { background: #fdf5e8; } .template-preview.saffron .tp-bar { background: #b45309; }
.template-preview.azure { background: #eef6fb; } .template-preview.azure .tp-bar { background: #0369a1; }
.template-preview.market { background: #f3f0ff; } .template-preview.market .tp-bar { background: #6d28d9; }
.template-preview.slate { background: #f1f3f4; } .template-preview.slate .tp-bar { background: #111827; }
.template-meta { padding: 13px 15px; }
.template-meta strong { display: block; font-size: .88rem; }
.template-meta small { color: var(--muted); font-size: .74rem; }
.template-badge { position: absolute; top: 10px; right: 10px; }

/* Website editor */
.editor-layout { display: grid; grid-template-columns: 380px minmax(0, 1fr); gap: 20px; align-items: start; }
.section-list { display: grid; gap: 8px; }
.section-item { border: 1px solid var(--line); border-radius: 11px; background: var(--surface); overflow: hidden; }
.section-item-head { display: flex; align-items: center; gap: 10px; padding: 11px 12px; }
.section-item-head .drag { color: var(--muted); cursor: default; }
.section-item-head strong { font-size: .82rem; flex: 1; }
.section-item-head small { color: var(--muted); font-size: .7rem; }
.section-item-body { padding: 0 12px 12px; border-top: 1px solid var(--line); }
.section-item-body .field:first-child { margin-top: 12px; }
.editor-preview { position: sticky; top: calc(var(--topbar-h) + 20px); }
.preview-frame { width: 100%; height: calc(100vh - 160px); border: 1px solid var(--line); border-radius: 14px; background: #fff; }
.repeater-row { border: 1px solid var(--line); border-radius: 10px; padding: 10px; margin-bottom: 8px; background: var(--surface-2); position: relative; }
.repeater-row .remove-row { position: absolute; top: 7px; right: 7px; }
.repeater-row .field { margin-bottom: 8px; }
.repeater-add { margin-top: 4px; }
.color-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; }
.color-input { display: flex; gap: 8px; align-items: center; }
.color-input input[type="color"] { width: 42px; height: 38px; padding: 3px; border: 1px solid var(--line-strong); border-radius: 8px; background: var(--surface); }

/* Billing */
.plan-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 16px; }
.plan-card { border: 1px solid var(--line); border-radius: var(--radius); padding: 22px; background: var(--surface); position: relative; display: flex; flex-direction: column; }
.plan-card.is-popular { border-color: var(--brand); box-shadow: 0 0 0 1px var(--brand); }
.plan-card .plan-price { font-family: var(--font-head); font-size: 1.8rem; font-weight: 800; margin: 10px 0 3px; letter-spacing: -.04em; }
.plan-card .plan-price small { font-size: .72rem; font-family: var(--font-body); font-weight: 500; color: var(--muted); }
.plan-features { list-style: none; padding: 0; margin: 18px 0; display: grid; gap: 9px; flex: 1; }
.plan-features li { display: flex; gap: 7px; font-size: .82rem; color: var(--ink-soft); }
.plan-features li::before { content: '✓'; color: var(--brand); font-weight: 700; }
.popular-tag { position: absolute; top: -10px; left: 22px; background: var(--brand); color: #fff; font-size: .65rem; font-weight: 700; text-transform: uppercase; letter-spacing: .08em; padding: 3px 9px; border-radius: 20px; }

/* Public landing (shared bits) */
.landing-body { background: var(--surface); }
.container { width: min(1180px, calc(100% - 40px)); margin: 0 auto; }
.landing-nav { height: 74px; display: flex; align-items: center; gap: 26px; }
.landing-nav .brand { flex: 0 1 auto; min-width: 0; }
.landing-nav .brand-text { white-space: nowrap; }
.landing-nav .nav-links { display: flex; gap: 22px; margin-left: auto; align-items: center; flex: 0 0 auto; }
.landing-nav .nav-links a { color: var(--ink-soft); font-size: .88rem; font-weight: 500; }
.landing-nav .nav-links a:hover { color: var(--brand); }
.landing-hero { padding: 60px 0 50px; position: relative; overflow: hidden; }
.landing-hero::before { content: ''; position: absolute; width: 520px; height: 520px; border-radius: 50%; background: radial-gradient(circle, color-mix(in srgb, var(--brand) 16%, transparent), transparent 68%); top: -160px; right: -100px; pointer-events: none; }
.hero-grid { display: grid; grid-template-columns: 1.05fr .95fr; gap: 50px; align-items: center; position: relative; }
.eyebrow { display: inline-flex; align-items: center; gap: 7px; background: var(--brand-soft); color: var(--brand-dark); border-radius: 20px; padding: 5px 12px; font-size: .74rem; font-weight: 700; margin-bottom: 16px; }
.hero-title { font-size: clamp(2.2rem, 4.4vw, 3.7rem); line-height: 1.03; letter-spacing: -.045em; margin-bottom: 18px; }
.hero-title em { font-style: normal; color: var(--brand); }
.hero-sub { font-size: 1.06rem; color: var(--muted); max-width: 560px; margin-bottom: 26px; }
.hero-actions { display: flex; gap: 11px; flex-wrap: wrap; margin-bottom: 26px; }
.hero-proof { display: flex; gap: 22px; flex-wrap: wrap; color: var(--muted); font-size: .78rem; }
.hero-proof span { display: flex; align-items: center; gap: 6px; }
.hero-proof .icon { width: 15px; height: 15px; color: var(--brand); }
.hero-visual { background: var(--surface); border: 1px solid var(--line); border-radius: 22px; box-shadow: var(--shadow-lg); overflow: hidden; transform: rotate(1.2deg); }
.hero-visual-top { height: 38px; background: var(--surface-2); border-bottom: 1px solid var(--line); display: flex; align-items: center; gap: 5px; padding: 0 13px; }
.hero-visual-top i { width: 8px; height: 8px; border-radius: 50%; background: var(--line-strong); display: block; }
.hero-visual-body { display: grid; grid-template-columns: 118px 1fr; min-height: 330px; }
.hero-mini-side { background: var(--surface-2); border-right: 1px solid var(--line); padding: 14px 10px; }
.hero-mini-side .m-line { height: 7px; background: var(--line); border-radius: 4px; margin-bottom: 9px; }
.hero-mini-side .m-line.active { background: var(--brand); width: 75%; }
.hero-mini-main { padding: 18px; }
.hero-mini-main .m-head { height: 11px; width: 46%; background: var(--ink); opacity: .8; border-radius: 5px; margin-bottom: 14px; }
.hero-mini-cards { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; margin-bottom: 14px; }
.hero-mini-cards span { height: 56px; border-radius: 8px; background: var(--surface-3); border: 1px solid var(--line); }
.hero-mini-chart { height: 94px; border-radius: 9px; border: 1px solid var(--line); background: linear-gradient(180deg, var(--brand-soft), transparent); position: relative; overflow: hidden; }
.hero-mini-chart::after { content: ''; position: absolute; inset: 22px 12px 14px; border-radius: 5px; background: linear-gradient(90deg, transparent 0 8%, var(--brand) 8% 12%, transparent 12% 22%, var(--brand) 22% 27%, transparent 27% 38%, var(--brand) 38% 44%, transparent 44% 56%, var(--brand) 56% 62%, transparent 62% 72%, var(--brand) 72% 79%, transparent 79% 88%, var(--brand) 88% 94%, transparent 94%); opacity: .35; }
.landing-section { padding: 72px 0; }
.landing-section.alt { background: var(--surface-2); }
.section-head { text-align: center; max-width: 660px; margin: 0 auto 42px; }
.section-head h2 { font-size: clamp(1.7rem, 3vw, 2.4rem); letter-spacing: -.035em; }
.section-head p { color: var(--muted); font-size: 1rem; }
.feature-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 18px; }
.feature-card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 24px; }
.feature-card .feature-icon { width: 42px; height: 42px; border-radius: 12px; background: var(--brand-soft); color: var(--brand-dark); display: grid; place-items: center; margin-bottom: 15px; }
.feature-card h3 { font-size: 1rem; margin-bottom: 7px; }
.feature-card p { color: var(--muted); font-size: .86rem; margin: 0; }
.steps-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 18px; counter-reset: step; }
.step-card { position: relative; padding-top: 12px; }
.step-card .step-no { width: 34px; height: 34px; border-radius: 10px; background: var(--ink); color: #fff; display: grid; place-items: center; font-family: var(--font-head); font-weight: 700; margin-bottom: 14px; }
.step-card h3 { font-size: .98rem; }
.step-card p { color: var(--muted); font-size: .84rem; margin: 0; }
.category-showcase { display: flex; flex-wrap: wrap; gap: 9px; justify-content: center; }
.category-pill { display: inline-flex; align-items: center; gap: 7px; background: var(--surface); border: 1px solid var(--line); border-radius: 30px; padding: 8px 14px; font-size: .82rem; color: var(--ink-soft); }
.category-pill:hover { border-color: var(--brand); color: var(--brand-dark); }
.cta-band { background: linear-gradient(130deg, #0b3f3b, #0f766e 60%, #115e59); border-radius: 24px; padding: 46px; color: #fff; display: flex; justify-content: space-between; align-items: center; gap: 24px; flex-wrap: wrap; }
.cta-band h2 { color: #fff; margin-bottom: 7px; }
.cta-band p { color: rgba(255,255,255,.76); margin: 0; }
.cta-band .btn-primary { background: #fff; color: var(--brand-dark); }
.cta-band .btn-primary:hover { background: #e9fffb; color: var(--brand-dark); }
.landing-footer { border-top: 1px solid var(--line); padding: 40px 0 28px; margin-top: 20px; }
.footer-grid { display: grid; grid-template-columns: 1.4fr repeat(3, 1fr); gap: 28px; }
.footer-grid h4 { font-size: .8rem; text-transform: uppercase; letter-spacing: .08em; color: var(--muted); margin-bottom: 12px; }
.footer-grid a { display: block; color: var(--ink-soft); font-size: .84rem; margin-bottom: 8px; }
.footer-grid a:hover { color: var(--brand); }
.footer-bottom { display: flex; justify-content: space-between; gap: 14px; flex-wrap: wrap; margin-top: 32px; padding-top: 20px; border-top: 1px solid var(--line); color: var(--muted); font-size: .76rem; }
.pricing-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 16px; }
.faq-list { max-width: 760px; margin: 0 auto; display: grid; gap: 9px; }
.faq-item { border: 1px solid var(--line); border-radius: 12px; background: var(--surface); overflow: hidden; }
.faq-item summary { padding: 15px 18px; cursor: pointer; font-weight: 600; font-size: .9rem; list-style: none; display: flex; justify-content: space-between; gap: 10px; }
.faq-item summary::-webkit-details-marker { display: none; }
.faq-item summary::after { content: '+'; color: var(--muted); font-weight: 400; }
.faq-item[open] summary::after { content: '−'; }
.faq-item p { padding: 0 18px 15px; color: var(--muted); font-size: .86rem; margin: 0; }
.testimonial-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 18px; }
.testimonial-card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 22px; }
.testimonial-card .stars { color: var(--accent); letter-spacing: 2px; font-size: .84rem; margin-bottom: 10px; }
.testimonial-card p { font-size: .88rem; color: var(--ink-soft); }
.testimonial-card .person { display: flex; gap: 10px; align-items: center; margin-top: 14px; }
.testimonial-card .person strong { display: block; font-size: .8rem; }
.testimonial-card .person small { color: var(--muted); font-size: .72rem; }

/* PWA install banner */
.install-banner { position: fixed; left: 20px; bottom: 20px; z-index: 120; width: min(400px, calc(100vw - 40px)); background: var(--surface); border: 1px solid var(--line); border-radius: 16px; box-shadow: var(--shadow-lg); padding: 15px; display: none; gap: 12px; align-items: flex-start; }
.install-banner.is-visible { display: flex; }
.install-banner .brand-mark { width: 40px; height: 40px; }
.install-banner h4 { margin: 0 0 2px; font-size: .88rem; }
.install-banner p { margin: 0; font-size: .76rem; color: var(--muted); }
.install-banner .close { margin-left: auto; background: none; border: 0; color: var(--muted); cursor: pointer; padding: 2px; }

/* Website templates */
.template-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px; }
.template-option { position: relative; display: flex; flex-direction: column; gap: 7px; border: 1px solid var(--line); border-radius: 12px; padding: 12px; cursor: pointer; background: var(--surface); transition: var(--transition); }
.template-option:hover { border-color: var(--line-strong); }
.template-option.is-selected { border-color: var(--brand); box-shadow: 0 0 0 3px color-mix(in srgb, var(--brand) 12%, transparent); }
.template-option.is-locked { opacity: .68; }
.template-option input { position: absolute; opacity: 0; pointer-events: none; }
.template-swatch { display: grid; grid-template-columns: 2fr 1fr; grid-template-rows: 26px 16px; gap: 4px; border-radius: 7px; overflow: hidden; background: var(--surface-2); padding: 6px; }
.template-swatch span { border-radius: 3px; background: var(--brand); }
.template-swatch span:first-child { grid-row: span 2; }
.template-swatch span:nth-child(2) { background: var(--ink); opacity: .82; }
.template-swatch span:nth-child(3) { background: var(--accent); }
.template-swatch-saffron span:first-child { background: #c2410c; }
.template-swatch-saffron span:nth-child(3) { background: #f59e0b; }
.template-swatch-azure span:first-child { background: #1d4ed8; }
.template-swatch-azure span:nth-child(3) { background: #38bdf8; }
.template-swatch-market span:first-child { background: #ea580c; }
.template-swatch-market span:nth-child(3) { background: #facc15; }
.template-swatch-slate span:first-child { background: #18181b; }
.template-swatch-slate span:nth-child(3) { background: #a1a1aa; }
.template-name { font-weight: 700; font-size: .86rem; display: flex; align-items: center; gap: 6px; }
.template-desc { color: var(--muted); font-size: .76rem; line-height: 1.45; }

/* Section editor */
.editor-shell { display: grid; grid-template-columns: minmax(0, 1fr) 420px; gap: 20px; align-items: start; }
.editor-main { min-width: 0; }
.editor-preview { position: sticky; top: calc(var(--topbar-h) + 20px); border: 1px solid var(--line); border-radius: var(--radius); background: var(--surface); overflow: hidden; box-shadow: var(--shadow-sm); }
.editor-preview-head { display: flex; justify-content: space-between; align-items: center; gap: 10px; padding: 10px 14px; border-bottom: 1px solid var(--line); font-size: .8rem; font-weight: 700; }
.editor-preview-head span { display: inline-flex; gap: 6px; align-items: center; }
.editor-preview iframe { width: 100%; height: min(680px, calc(100vh - 190px)); border: 0; background: #fff; opacity: .98; }
.section-type-icon { width: 38px; height: 38px; border-radius: 10px; display: grid; place-items: center; background: var(--brand-soft); color: var(--brand-dark); }
.section-type-icon .icon { width: 19px; height: 19px; }
.section-list { display: grid; }
.section-row { display: flex; align-items: center; gap: 12px; padding: 12px 18px; border-bottom: 1px solid var(--line); }
.section-row:last-child { border-bottom: 0; }
.section-row.is-hidden-section { background: var(--surface-2); opacity: .72; }
.section-row-meta { min-width: 0; flex: 1; }
.section-row-meta .cell-main { display: block; }
.section-row-actions { display: flex; gap: 4px; align-items: center; }
.drag-handle { width: 34px; height: 34px; border-radius: 8px; display: grid; place-items: center; color: var(--muted); background: var(--surface-2); flex: 0 0 auto; }
.drag-handle .icon { width: 17px; height: 17px; }
.section-picker { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; max-height: 380px; overflow-y: auto; margin-bottom: 16px; padding: 2px; }
.section-option { position: relative; display: flex; gap: 10px; align-items: center; border: 1px solid var(--line); border-radius: 10px; padding: 10px; cursor: pointer; }
.section-option:hover { border-color: var(--brand); }
.section-option input { accent-color: var(--brand); }
.section-option-icon { width: 30px; height: 30px; border-radius: 8px; background: var(--brand-soft); color: var(--brand-dark); display: grid; place-items: center; flex: 0 0 auto; }
.section-option-icon .icon { width: 16px; height: 16px; }
.section-option strong { display: block; font-size: .8rem; }
.section-option .small { display: block; font-size: .68rem; }
.repeater { display: grid; gap: 12px; }
.repeater-rows { display: grid; gap: 12px; }
.repeater-row { border: 1px dashed var(--line-strong); border-radius: 10px; padding: 14px; background: var(--surface-2); }
.repeater-row .form-grid { gap: 0 12px; }
.repeater-row .field { margin-bottom: 10px; }
.repeater-remove { margin-top: 2px; }
.repeater [data-repeater-add] { justify-self: start; }
.editor-shell .form-grid > .field-col-12 > .field { margin-bottom: 16px; }

/* Utility */
.divider { height: 1px; background: var(--line); margin: 20px 0; }
.kbd { background: var(--surface-3); border: 1px solid var(--line); border-radius: 5px; padding: 1px 5px; font-size: .72rem; font-family: monospace; }
.mono { font-family: ui-monospace, SFMono-Regular, Menlo, monospace; font-size: .82em; }
.truncate { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.scroll-x { overflow-x: auto; }
.scroll-y { overflow-y: auto; }
.sticky-top { position: sticky; top: calc(var(--topbar-h) + 20px); }

@media (max-width: 1100px) {
  .stat-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .plan-grid, .pricing-grid { grid-template-columns: repeat(2, 1fr); }
  .grid-4 { grid-template-columns: repeat(2, 1fr); }
  .grid-3 { grid-template-columns: repeat(2, 1fr); }
  .steps-grid { grid-template-columns: repeat(2, 1fr); }
  .feature-grid { grid-template-columns: repeat(2, 1fr); }
  .footer-grid { grid-template-columns: 1.4fr 1fr 1fr; }
  .editor-layout, .editor-shell { grid-template-columns: 1fr; }
  .editor-preview { position: static; }
  .editor-preview iframe { height: 540px; }
  .preview-frame { height: 520px; }
  .auth-split { grid-template-columns: 1fr; max-width: 500px; }
  .auth-aside { display: none; }
  .auth-form-side .brand { display: inline-flex; margin-bottom: 22px; }
  .auth-form-side { padding: 30px; }
}

/* The two-column hero needs less room than the grids above, so it stacks
   later — otherwise small laptops (~1024px) get a stacked hero with a large
   empty column. */
@media (max-width: 900px) {
  .hero-grid { grid-template-columns: 1fr; gap: 34px; }
  .hero-visual { transform: none; max-width: 620px; }
}

@media (max-width: 860px) {
  .app-shell { grid-template-columns: 1fr; }
  .sidebar { position: fixed; left: 0; top: 0; bottom: 0; width: 280px; transform: translateX(-100%); transition: transform .22s ease; box-shadow: var(--shadow-lg); }
  .sidebar.is-open { transform: none; }
  .sidebar-backdrop { position: fixed; inset: 0; background: rgba(7,13,20,.45); z-index: 35; }
  .sidebar-backdrop.is-open { display: block; }
  .mobile-menu-btn { display: inline-grid; }
  .topbar { padding: 0 16px; }
  .content { padding: 18px 16px 90px; }
  .grid-2, .grid-2-1, .grid-3, .grid-4 { grid-template-columns: 1fr; }
  .form-grid > .field-col-4, .form-grid > .field-col-6, .form-grid > .field-col-8 { grid-column: span 12; }
  .field-col-2, .field-col-3, .field-col-4, .field-col-6, .field-col-8 { grid-column: span 12; }
  .page-head h1 { font-size: 1.45rem; }
  .landing-nav .nav-links .hide-mobile { display: none; }
  .landing-nav { gap: 14px; }
  .landing-nav .nav-links { gap: 14px; }
  .landing-nav .brand-suffix { display: none; }
  .landing-nav .brand { font-size: 1.05rem; }
  .landing-hero { padding: 34px 0; }
  .landing-section { padding: 50px 0; }
  .feature-grid, .testimonial-grid, .plan-grid, .pricing-grid { grid-template-columns: 1fr; }
  .steps-grid { grid-template-columns: 1fr 1fr; }
  .cta-band { padding: 30px; }
  .footer-grid { grid-template-columns: 1fr 1fr; }
  .stat-grid { gap: 10px; }
  .stat-card { padding: 14px; }
  .stat-value { font-size: 1.3rem; }
  .table th, .table td { padding: 10px 12px; }
  .modal { padding: 20px; }
  .auth-card { padding: 24px; }
}

.btn.is-active { background: var(--brand-soft); color: var(--brand-ink, var(--brand)); border-color: var(--brand); }
.plan-card.is-current { background: linear-gradient(180deg, var(--brand-soft), var(--surface) 70%); }
.table tr.is-highlighted { background: var(--brand-soft); }
.table tr.is-unread { background: color-mix(in srgb, var(--brand-soft) 45%, var(--surface)); }
.table tr.is-unread .cell-main { font-weight: 700; }

/* ==========================================================================
   Admin panel
   ========================================================================== */
.admin-body { background: var(--surface-2); }
.admin-sidebar {
  position: fixed; top: 0; left: 0; bottom: 0; width: var(--sidebar-w);
  background: #0b1220; color: #dbe6e3; display: flex; flex-direction: column; z-index: 60; overflow-y: auto;
}
.admin-sidebar-head { display: flex; align-items: center; justify-content: space-between; padding: 18px 18px 14px; }
.admin-sidebar .brand { color: #fff; gap: 10px; }
.admin-side-nav { padding: 8px; display: grid; gap: 2px; flex: 1; }
.admin-side-link {
  display: flex; align-items: center; gap: 11px; padding: 10px 12px; border-radius: 10px;
  color: rgba(219, 230, 227, .78); font-size: .85rem; font-weight: 500; text-decoration: none; transition: background var(--transition), color var(--transition);
}
.admin-side-link:hover { background: rgba(255, 255, 255, .07); color: #fff; }
.admin-side-link.is-active { background: var(--brand); color: #fff; }
.admin-side-link .icon { width: 18px; height: 18px; flex-shrink: 0; }
.admin-sidebar-foot { padding: 12px 8px 18px; border-top: 1px solid rgba(255, 255, 255, .09); }
.admin-sidebar-backdrop { display: none; }
.admin-main { margin-left: var(--sidebar-w); min-height: 100vh; display: flex; flex-direction: column; }
.admin-topbar {
  height: var(--topbar-h); display: flex; align-items: center; gap: 14px; padding: 0 24px;
  background: var(--surface); border-bottom: 1px solid var(--line); position: sticky; top: 0; z-index: 30;
}
.admin-topbar-title { font-family: var(--font-head); font-weight: 700; font-size: 1.02rem; flex: 1; display: flex; flex-direction: column; line-height: 1.25; }
.admin-topbar-title span { font-family: var(--font-body); font-size: .74rem; font-weight: 500; color: var(--muted); }
.admin-topbar-actions { display: flex; align-items: center; gap: 10px; }
.admin-user-badge { display: inline-flex; align-items: center; gap: 8px; font-size: .82rem; font-weight: 600; background: var(--surface-3); padding: 6px 12px; border-radius: 999px; }
.admin-content { padding: 24px; max-width: 1400px; width: 100%; margin: 0 auto; flex: 1; }

.admin-auth-body { background: #0b1220; }
.admin-auth-split { display: grid; grid-template-columns: 1fr 1fr; min-height: 100vh; }
.admin-auth-aside { background: linear-gradient(160deg, #0b1220, #0f2e2b); color: #fff; padding: 44px; display: flex; flex-direction: column; justify-content: space-between; }
.admin-auth-aside h2 { font-size: 1.8rem; margin: 30px 0 12px; letter-spacing: -.03em; }
.admin-auth-aside p { color: rgba(255, 255, 255, .74); line-height: 1.7; max-width: 420px; }
.admin-auth-aside .check-list li { color: rgba(255, 255, 255, .86); }
.admin-auth-form-side { background: var(--surface); padding: 44px; display: flex; flex-direction: column; justify-content: center; max-width: 460px; width: 100%; }
.admin-auth-form-side h1 { font-size: 1.7rem; margin: 26px 0 6px; letter-spacing: -.03em; }
.admin-auth-form-side .auth-sub { color: var(--muted); margin-bottom: 24px; }

@media (max-width: 900px) {
  .admin-sidebar { transform: translateX(-100%); transition: transform var(--transition); }
  .admin-sidebar.is-open { transform: none; }
  .admin-sidebar.is-open + .admin-sidebar-backdrop { display: block; position: fixed; inset: 0; background: rgba(6, 12, 20, .5); z-index: 55; }
  .admin-main { margin-left: 0; }
  .admin-auth-split { grid-template-columns: 1fr; }
  .admin-auth-aside { display: none; }
  .admin-auth-form-side { max-width: none; padding: 28px; }
  .admin-content { padding: 16px; }
}

@media (min-width: 901px) { .admin-main .mobile-menu-btn { display: none; } }

@media (max-width: 520px) {
  .stat-grid { grid-template-columns: 1fr 1fr; }
  .steps-grid { grid-template-columns: 1fr; }
  .footer-grid { grid-template-columns: 1fr; }
  .hero-actions .btn { width: 100%; }
  .category-grid { grid-template-columns: repeat(2, 1fr); }
  .card-pad, .card-body { padding: 16px; }
  .card-head { padding: 14px 16px; }
  .page-actions { width: 100%; }
  .page-actions .btn { flex: 1; }
  .topbar-title span { display: none; }
}

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