:root { --accent: #2155f5; --accent-hover: #1a46d1; --bg: #f9f9fa; --alt: #eef1fb; --line: #e1e2e9; --text: #0f1013; --muted: #494c52; --muted2: #6b6e76; }
* { box-sizing: border-box; }
/* the [hidden] attribute must always win — several elements below (e.g.
   .editor-body) set their own `display`, which would otherwise silently
   out-specificity the browser's default [hidden]{display:none} rule. */
[hidden] { display: none !important; }
body { margin: 0; background: var(--bg); color: var(--text); font-family: "Geist", ui-sans-serif, system-ui, sans-serif; -webkit-font-smoothing: antialiased; }
a { color: inherit; text-decoration: none; }
a:hover { text-decoration: underline; }
input, textarea, select, button { font: inherit; color: inherit; }
.serif { font-family: "Host Grotesk", ui-sans-serif, system-ui, sans-serif; font-weight: 600; letter-spacing: -0.02em; }
.wrap { max-width: 1180px; margin: 0 auto; padding: 0 40px; }
.topbar { position: sticky; top: 0; z-index: 50; background: #fff; border-bottom: 1px solid var(--line); }
.topbar-inner { display: flex; align-items: center; justify-content: space-between; gap: 24px; height: 64px; }
.brandmark { width: 28px; height: 28px; border-radius: 8px; display: flex; align-items: center; justify-content: center; font-weight: 800; font-size: 12px; color: #fff; background: var(--accent); }
.brand-logo-full { height: 28px; width: auto; max-width: 220px; display: block; object-fit: contain; } /* height is normally set inline per Theme.LogoHeight */
.brand { font-weight: 750; font-size: 16px; }
.crumb { font-size: 13px; color: var(--muted2); }
.nav a { font-size: 14px; color: #3f3f46; margin-left: 22px; }
.btn { border: 1px solid #d8d8dc; border-radius: 999px; background: #fff; padding: 8px 16px; font-size: 13.5px; font-weight: 600; cursor: pointer; }
.btn-primary { border: 0; border-radius: 999px; padding: 11px 22px; font-family: "Host Grotesk", sans-serif; font-size: 14px; font-weight: 500; color: #fff; background: var(--accent); cursor: pointer; }
.hero { padding: 64px 0 40px; }
.hero h1 { font-weight: 600; font-size: 52px; line-height: 1.1; letter-spacing: -0.03em; margin: 0 0 14px; }
.hero p { font-size: 17px; line-height: 1.55; color: var(--muted); margin: 0 0 28px; }
.searchbox { display: flex; align-items: center; gap: 10px; background: #fff; border: 1px solid var(--line); border-radius: 999px; box-shadow: 0 24px 64px rgba(193,193,214,.16); padding: 8px 8px 8px 22px; }
.searchbox input { flex: 1; min-width: 0; border: 0; outline: none; font-size: 16px; background: transparent; }
.grid-cards { display: grid; grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); gap: 18px; margin: 36px 0; }
.card { background: #fff; border: 1px solid var(--line); border-radius: 20px; padding: 22px; }
.card h3 { margin: 0 0 6px; font-size: 16px; }
.card p { margin: 0 0 14px; font-size: 13.5px; color: var(--muted); }
.card ul { list-style: none; margin: 0; padding: 12px 0 0; border-top: 1px solid #eee; display: flex; flex-direction: column; gap: 8px; }
.card a { font-size: 13.5px; color: #3f3f46; }
.article-body { font-size: 16px; line-height: 1.7; }
.article-body::after { content: ""; display: table; clear: both; }
.article-body h2 { font-size: 20px; margin-top: 28px; }
.article-body blockquote.callout { background: #eef2ff; border-left: 3px solid var(--accent); border-radius: 8px; padding: 4px 18px; margin: 20px 0; }
.article-body blockquote.callout p { margin: 10px 0; }
.article-body code { background: #f4f4f5; border-radius: 4px; padding: 2px 6px; font-size: 0.9em; font-family: ui-monospace, monospace; }
.article-body pre { background: #131316; color: #e4e4e7; border-radius: 10px; padding: 16px 18px; overflow-x: auto; margin: 20px 0; }
.article-body pre code { background: transparent; padding: 0; color: inherit; }
.article-body img, .article-body video { max-width: 100%; border-radius: 10px; margin: 16px 0; display: block; }
.footer { border-top: 1px solid var(--line); padding: 30px 0; color: var(--muted2); font-size: 13px; }
form.stack { display: flex; flex-direction: column; gap: 12px; max-width: 380px; }
form.stack input, form.stack textarea { border: 1px solid #d8d8dc; border-radius: 8px; padding: 10px 12px; }
.error { color: #c0392b; font-size: 13.5px; }
/* ---- admin shell ---- */
.admin-shell { display: grid; grid-template-columns: 240px 1fr; min-height: 100vh; background: #f7f7f8; }
.admin-sidebar { background: #101014; color: #d4d4d8; padding: 20px 14px; display: flex; flex-direction: column; }
.admin-sidebar-brand { display: flex; align-items: center; gap: 10px; margin-bottom: 26px; padding: 0 6px; }
.admin-sidebar-brand .brand { color: #fff; font-size: 15px; }
.admin-nav-group { margin-bottom: 20px; }
.admin-nav-label { font-size: 10.5px; font-weight: 700; text-transform: uppercase; letter-spacing: 0.08em; color: #6b6b74; padding: 0 10px; margin-bottom: 6px; }
.admin-sidebar a.nav-link { display: flex; align-items: center; justify-content: space-between; gap: 8px; padding: 8px 10px; border-radius: 8px; font-size: 14px; margin-bottom: 1px; color: #d4d4d8; }
.admin-sidebar a.nav-link.active { background: #26262e; color: #fff; font-weight: 600; }
.admin-sidebar a.nav-link:hover { background: #1f1f26; color: #fff; text-decoration: none; }
.admin-sidebar a.nav-link.disabled { color: #55555c; cursor: default; pointer-events: none; }
.admin-sidebar-foot { margin-top: auto; border-top: 1px solid #232329; padding-top: 14px; display: flex; align-items: center; gap: 10px; }
.admin-avatar { width: 30px; height: 30px; border-radius: 999px; background: #2c2c34; color: #fff; display: flex; align-items: center; justify-content: center; font-size: 12px; font-weight: 700; flex-shrink: 0; }
.admin-sidebar-foot .who { flex: 1; min-width: 0; }
.admin-sidebar-foot .who .name { font-size: 13.5px; color: #fff; font-weight: 600; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.admin-sidebar-foot .who .role { font-size: 11.5px; color: #8a8a92; }
.admin-sidebar-foot a.signout { font-size: 12.5px; color: #9a9aa2; flex-shrink: 0; }

/* On a narrow/mobile viewport the fixed 240px sidebar column left almost no
   room for .admin-main, and the sidebar (a flex column stretched to the
   grid row's full 100vh height) pinned "Sign out" off the bottom of the
   screen behind a wall of empty space. Stack sidebar above content instead,
   sized to its own content so nothing is pushed out of view. */
@media (max-width: 760px) {
  .admin-shell { grid-template-columns: 1fr; grid-template-rows: auto 1fr; min-height: 0; }
  .admin-sidebar { padding: 14px; }
  .admin-sidebar-brand { margin-bottom: 14px; }
  .admin-nav-group { margin-bottom: 10px; }
  .admin-sidebar-foot { margin-top: 14px; }
  .admin-main { padding: 20px 16px 40px; }
}

.admin-main { padding: 26px 36px 60px; max-width: 1360px; }
.admin-topbar { display: flex; justify-content: space-between; align-items: flex-start; margin-bottom: 22px; gap: 20px; }
.admin-topbar h1 { margin: 0; font-size: 24px; font-weight: 700; letter-spacing: -0.01em; }
.admin-topbar .sub { margin: 4px 0 0; font-size: 13.5px; color: var(--muted); }
.admin-topbar .actions { display: flex; gap: 10px; flex-shrink: 0; }

table.admin-table { width: 100%; border-collapse: collapse; background: #fff; border: 1px solid var(--line); border-radius: 10px; overflow: hidden; }
table.admin-table th, table.admin-table td { text-align: left; padding: 10px 14px; border-bottom: 1px solid #f0f0f2; font-size: 14px; }
table.admin-table tr:last-child td { border-bottom: 0; }
table.admin-table th { background: #fafafa; font-weight: 650; color: var(--muted); font-size: 12px; text-transform: uppercase; letter-spacing: 0.04em; }
.badge { font-size: 11px; padding: 2px 8px; border-radius: 999px; background: #eef2ff; color: var(--accent); font-weight: 650; white-space: nowrap; }
.badge.draft { background: #f4f4f5; color: var(--muted); }
.badge.in_review { background: #fef3c7; color: #92620a; }
.badge.translating { background: #dbeafe; color: #1d4ed8; }
.badge.blocked { background: #fee2e2; color: #b91c1c; }
.toolbar { display: flex; justify-content: space-between; align-items: center; margin-bottom: 18px; }

/* ---- dashboard ---- */
.stat-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 16px; margin-bottom: 18px; }
.stat-card { background: #fff; border: 1px solid var(--line); border-radius: 14px; padding: 18px 20px; }
.stat-card .label { font-size: 12.5px; color: var(--muted); margin-bottom: 10px; }
.stat-card .value { font-size: 30px; font-weight: 700; letter-spacing: -0.01em; line-height: 1; }
.stat-card .delta { font-size: 12.5px; margin-top: 8px; color: var(--muted2); }
.stat-card .delta.up { color: #0a7a3d; }
.stat-card .delta.down { color: #c0392b; }
.panel-grid { display: grid; grid-template-columns: 1.15fr 1fr; gap: 16px; align-items: start; }
@media (max-width: 900px) { .panel-grid { grid-template-columns: 1fr; } }
.panel { background: #fff; border: 1px solid var(--line); border-radius: 14px; padding: 18px 20px 8px; }
.panel-head { font-size: 11px; font-weight: 700; text-transform: uppercase; letter-spacing: 0.07em; color: var(--muted2); margin-bottom: 6px; }
.panel-row { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 12px 0; border-top: 1px solid #f0f0f2; }
.panel-row:first-of-type { border-top: 0; }
.panel-row .title { font-size: 14.5px; font-weight: 600; margin: 0 0 2px; }
.panel-row .meta { font-size: 12.5px; color: var(--muted2); }
.panel-row .q { font-size: 14px; }
.panel-row .count { font-size: 12.5px; color: var(--muted2); margin-right: 14px; }
.panel-empty { padding: 22px 0; color: var(--muted2); font-size: 13.5px; }

/* ---- theme & branding ---- */
.theme-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; align-items: start; }
@media (max-width: 1000px) { .theme-grid { grid-template-columns: 1fr; } }
.theme-col { display: flex; flex-direction: column; gap: 16px; }
.theme-card { background: #fff; border: 1px solid var(--line); border-radius: 14px; padding: 18px 20px; }
.theme-card-head { font-size: 11px; font-weight: 700; text-transform: uppercase; letter-spacing: 0.07em; color: var(--muted2); margin-bottom: 14px; }
.theme-field { margin-bottom: 14px; }
.theme-field:last-child { margin-bottom: 0; }
.theme-field label.fl { display: block; font-size: 13px; font-weight: 600; margin-bottom: 6px; }
.theme-field .hint { font-size: 12px; color: var(--muted2); margin-top: 4px; }
.theme-field input[type=text], .theme-field input[type=email], .theme-field textarea, .theme-field select {
  width: 100%; border: 1px solid #d8d8dc; border-radius: 8px; padding: 9px 12px; font-size: 14px; background: #fff;
}
.swatch-row { display: flex; gap: 10px; margin-bottom: 14px; }
.swatch { width: 30px; height: 30px; border-radius: 999px; border: 2px solid transparent; cursor: pointer; padding: 0; }
.swatch.selected { border-color: #131316; box-shadow: 0 0 0 2px #fff inset; }
.hex-row { display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 7px 0; }
.hex-row .fl { font-size: 13.5px; font-weight: 600; }
.hex-row .hex-inputs { display: flex; align-items: center; gap: 8px; }
.hex-row input[type=text] { width: 92px; border: 1px solid #d8d8dc; border-radius: 8px; padding: 7px 10px; font-size: 13px; font-family: monospace; }
.hex-row input[type=color] { width: 32px; height: 32px; border-radius: 8px; border: 1px solid #d8d8dc; padding: 2px; background: #fff; cursor: pointer; }
.logo-uploader { display: flex; align-items: center; gap: 12px; }
.logo-uploader .box { width: 52px; height: 52px; border: 1px dashed #d8d8dc; border-radius: 10px; display: flex; align-items: center; justify-content: center; font-size: 10px; color: var(--muted2); overflow: hidden; flex-shrink: 0; background: #fafafa; }
.logo-uploader .box img { width: 100%; height: 100%; object-fit: cover; }
.logo-uploader .info { font-size: 13px; }
.logo-uploader .info .fl { font-weight: 600; margin-bottom: 2px; }
.logo-uploader label.upload-link { color: var(--accent); font-size: 12.5px; cursor: pointer; font-weight: 600; }
.toggle-row { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 4px 0; }
.toggle-row .fl { font-size: 13.5px; font-weight: 600; }
.toggle-row .hint { font-size: 12px; color: var(--muted2); margin-top: 2px; }
.switch { position: relative; width: 40px; height: 22px; flex-shrink: 0; }
.switch input { opacity: 0; width: 0; height: 0; }
.switch .track { position: absolute; inset: 0; background: #d8d8dc; border-radius: 999px; transition: background .15s; cursor: pointer; }
.switch .track::before { content: ""; position: absolute; width: 18px; height: 18px; left: 2px; top: 2px; background: #fff; border-radius: 999px; transition: transform .15s; box-shadow: 0 1px 2px rgba(0,0,0,.25); }
.switch input:checked + .track { background: var(--accent); }
.switch input:checked + .track::before { transform: translateX(18px); }
.seg-row { display: flex; gap: 8px; flex-wrap: wrap; }
.seg-btn { border: 1px solid #d8d8dc; background: #fff; border-radius: 999px; padding: 7px 16px; font-size: 13px; font-weight: 600; cursor: pointer; }
.seg-btn.selected { background: #131316; color: #fff; border-color: #131316; }

.preview-card { background: #fff; border: 1px solid var(--line); border-radius: 14px; padding: 14px; position: sticky; top: 20px; }
.preview-mock { border-radius: 12px; overflow: hidden; }
.preview-mock .p-header { display: flex; align-items: center; gap: 10px; padding: 16px 20px; }
.preview-mock .p-header .pm-brandmark { width: 24px; height: 24px; border-radius: 7px; background: var(--accent); color: #fff; font-size: 11px; font-weight: 800; display: flex; align-items: center; justify-content: center; overflow: hidden; }
.preview-mock .p-header .pm-brandmark img { width: 100%; height: 100%; object-fit: cover; }
.preview-mock .p-header .pm-brandmark.full-logo { width: auto; height: auto; border-radius: 0; background: transparent; }
.preview-mock .p-header .pm-brandmark.full-logo img { width: auto; max-height: 40px; object-fit: contain; }
.preview-mock .p-header .pm-brand { font-weight: 700; font-size: 14px; }
.preview-mock .p-hero { padding: 22px 20px 30px; }
.preview-mock .p-hero h2 { margin: 0 0 8px; font-size: 24px; font-weight: 400; }
.preview-mock .p-hero p { margin: 0 0 16px; font-size: 13.5px; opacity: .78; max-width: 380px; }
.preview-mock .p-search { display: flex; align-items: center; background: rgba(255,255,255,.08); border: 1px solid rgba(255,255,255,.18); border-radius: 10px; padding: 10px 14px; font-size: 13px; opacity: .85; margin-bottom: 16px; }
.preview-mock .p-search.on-light { background: #f4f4f5; border-color: #e4e4e7; color: #6b6b73; }
.preview-mock .p-links { display: flex; gap: 8px; flex-wrap: wrap; }
.preview-mock .p-links span { border-radius: 999px; padding: 8px 14px; font-size: 12.5px; font-weight: 600; }
.preview-mock .p-links span.pri { background: var(--accent); color: #fff; }
.preview-mock .p-links span.sec { background: rgba(127,127,127,.18); }

/* ---- generic form controls reused across new admin pages ---- */
.form-inline { display: flex; gap: 10px; align-items: flex-end; flex-wrap: wrap; }
.form-inline .fld input, .form-inline .fld select { border: 1px solid #d8d8dc; border-radius: 8px; padding: 8px 10px; font-size: 14px; }
.form-inline .fld .fl { display: block; font-size: 12px; color: var(--muted); margin-bottom: 4px; }
.role-pill { font-size: 11px; padding: 2px 8px; border-radius: 999px; background: #f4f4f5; color: var(--muted); font-weight: 650; white-space: nowrap; }
.role-pill.super_admin { background: #f3e8ff; color: #7c3aed; }
.role-pill.admin { background: #fef3c7; color: #92620a; }
.role-pill.editor { background: #dbeafe; color: #1d4ed8; }
.role-pill.author { background: #f4f4f5; color: var(--muted); }
.role-pill.translator { background: #cffafe; color: #0e7490; }
.empty-state { padding: 40px 20px; text-align: center; color: var(--muted2); font-size: 14px; background: #fff; border: 1px solid var(--line); border-radius: 12px; }

/* ---- users & roles ---- */
.role-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(190px, 1fr)); gap: 14px; margin-bottom: 18px; }
.role-card { background: #fff; border: 1px solid var(--line); border-radius: 14px; padding: 16px 18px; }
.role-card .row { display: flex; align-items: baseline; justify-content: space-between; gap: 8px; margin-bottom: 6px; }
.role-card .label { font-size: 14.5px; font-weight: 700; }
.role-card .count { font-size: 20px; font-weight: 700; color: var(--muted2); }
.role-card .desc { font-size: 12.5px; color: var(--muted); line-height: 1.45; }
.member-cell { display: flex; align-items: center; gap: 10px; }
.member-avatar { width: 34px; height: 34px; border-radius: 999px; background: #eef2ff; color: var(--accent); display: flex; align-items: center; justify-content: center; font-size: 12px; font-weight: 700; flex-shrink: 0; }
.member-cell .name { font-weight: 650; }
.member-cell .email { font-size: 12.5px; color: var(--muted2); }
.scope-text { font-size: 13.5px; color: var(--muted); }
.check-list { display: grid; grid-template-columns: repeat(auto-fill, minmax(140px, 1fr)); gap: 8px 12px; margin: 4px 0 2px; max-height: 190px; overflow-y: auto; }
.check-list label { display: flex; align-items: center; gap: 7px; font-size: 13.5px; cursor: pointer; }
.check-list input { margin: 0; }
.scope-hint { font-size: 12px; color: var(--muted2); margin: 2px 0 12px; }
details.invites-panel { background: #fff; border: 1px solid var(--line); border-radius: 14px; padding: 4px 18px; margin-top: 16px; }
details.invites-panel summary { padding: 12px 0; font-size: 13.5px; font-weight: 650; cursor: pointer; list-style: none; }
details.invites-panel summary::-webkit-details-marker { display: none; }
details.invites-panel summary::before { content: "▸ "; color: var(--muted2); }
details.invites-panel[open] summary::before { content: "▾ "; }
details.invites-panel table.admin-table { margin-bottom: 16px; border: 0; }

.modal-overlay { position: fixed; inset: 0; background: rgba(15,15,18,.45); display: flex; align-items: flex-start; justify-content: center; padding: 8vh 20px; z-index: 300; }
.modal-overlay[hidden] { display: none; }
.modal-card { background: #fff; border-radius: 16px; padding: 24px 26px 26px; width: 100%; max-width: 420px; box-shadow: 0 20px 60px rgba(0,0,0,.25); }
.modal-card h2 { margin: 0 0 4px; font-size: 18px; }
.modal-card .sub { margin: 0 0 18px; font-size: 13px; color: var(--muted); }
.modal-actions { display: flex; justify-content: flex-end; gap: 10px; margin-top: 18px; }

/* ---- categories: list + edit panel ---- */
.cat-grid { display: grid; grid-template-columns: 1fr 340px; gap: 18px; align-items: start; }
@media (max-width: 900px) { .cat-grid { grid-template-columns: 1fr; } }
tr.selected-row { background: #eef2ff; }
.cat-icon-link { display: inline-flex; }
.cat-name-link { color: inherit; }
.row-actions { text-align: right; }
.row-actions a { font-size: 13px; font-weight: 600; color: var(--accent); }
.badge.visibility-public { background: #f4f4f5; color: var(--muted); }
.badge.visibility-partners { background: #eef2ff; color: var(--accent); }
.side-stack { display: flex; flex-direction: column; gap: 16px; position: sticky; top: 20px; }
.theme-card-head-row { display: flex; align-items: center; justify-content: space-between; margin-bottom: 14px; }
.theme-card-head-row .theme-card-head { margin-bottom: 0; }
.link-danger { border: 0; background: none; padding: 0; font-size: 12.5px; font-weight: 650; color: #c0392b; cursor: pointer; }
.link-danger:hover { text-decoration: underline; }
.panel-hr { border: 0; border-top: 1px solid #f0f0f2; margin: 18px 0; }

/* ---- toast notification ---- */
.toast {
  position: fixed; bottom: 24px; left: 50%; z-index: 200;
  transform: translate(-50%, 12px); opacity: 0;
  background: #131316; color: #fff; font-size: 13.5px; font-weight: 600;
  padding: 11px 20px; border-radius: 999px; box-shadow: 0 8px 24px rgba(0,0,0,.18);
  transition: opacity .2s ease, transform .2s ease;
  pointer-events: none;
}
.toast.in { opacity: 1; transform: translate(-50%, 0); }
.toast::before { content: "✓ "; color: #4ade80; }
.cat-icon { width: 32px; height: 32px; border-radius: 999px; background: #eef2ff; display: flex; align-items: center; justify-content: center; overflow: hidden; flex-shrink: 0; }
.cat-icon img { width: 100%; height: 100%; object-fit: cover; border-radius: 999px; }
.cat-icon.lg { width: 44px; height: 44px; }
.cat-icon.lg::before { transform: scale(1.5); }
.cat-icon.lg.diamond::before { transform: rotate(45deg) scale(1.5); }
.cat-icon.circle::before { content: ""; width: 13px; height: 13px; border-radius: 50%; background: var(--accent); }
.cat-icon.rounded-square::before { content: ""; width: 13px; height: 13px; border-radius: 4px; background: var(--accent); }
.cat-icon.diamond::before { content: ""; width: 10px; height: 10px; background: var(--accent); transform: rotate(45deg); }
.cat-icon.ring::before { content: ""; width: 13px; height: 13px; border-radius: 50%; border: 2.5px solid var(--accent); }
.cat-icon.square-outline::before { content: ""; width: 13px; height: 13px; border-radius: 4px; border: 2.5px solid var(--accent); }
.cat-icon.pill::before { content: ""; width: 19px; height: 8px; border-radius: 999px; background: var(--accent); }
.cat-icon.bar::before { content: ""; width: 5px; height: 15px; border-radius: 3px; background: var(--accent); }
.cat-icon.triangle::before { content: ""; width: 0; height: 0; border-left: 6.5px solid transparent; border-right: 6.5px solid transparent; border-bottom: 11px solid var(--accent); }
.icon-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 8px; margin-bottom: 14px; }
.icon-opt { border: 1px solid #d8d8dc; background: #fff; border-radius: 10px; height: 52px; display: flex; align-items: center; justify-content: center; cursor: pointer; }
.icon-opt .cat-icon { background: transparent; width: 24px; height: 24px; transform: scale(1.4); }
.icon-opt.selected { border-color: var(--accent); border-width: 2px; box-shadow: 0 0 0 1px var(--accent) inset; }
.icon-drop { display: block; border: 1px dashed #d8d8dc; border-radius: 10px; padding: 20px; text-align: center; font-size: 12.5px; color: var(--muted2); font-family: ui-monospace, monospace; cursor: pointer; }
.icon-drop:hover { border-color: var(--accent); }

/* ---- article editor ---- */
.editor-shell { display: grid; grid-template-columns: 1fr 300px; gap: 18px; align-items: start; }
@media (max-width: 1050px) { .editor-shell { grid-template-columns: 1fr; } }
.editor-card { background: #fff; border: 1px solid var(--line); border-radius: 14px; padding: 22px 26px 26px; }
.editor-title-input { display: block; width: 100%; border: 0; outline: none; font-family: var(--heading-font); font-size: 28px; font-weight: 400; padding: 0; margin-bottom: 8px; background: transparent; }
.editor-subtitle-input { display: block; width: 100%; border: 0; outline: none; font-size: 15px; color: var(--muted); padding: 0; margin-bottom: 16px; background: transparent; }

.side-card { background: #fff; border: 1px solid var(--line); border-radius: 14px; padding: 18px 20px; margin-bottom: 16px; }
.side-card:last-child { margin-bottom: 0; }
.side-head { font-size: 11px; font-weight: 700; text-transform: uppercase; letter-spacing: 0.07em; color: var(--muted2); margin-bottom: 14px; }

.wf-step { display: flex; gap: 10px; padding-bottom: 16px; position: relative; }
.wf-step:not(:last-child)::before { content: ""; position: absolute; left: 5px; top: 16px; bottom: -2px; width: 1px; background: #e4e4e7; }
.wf-dot { width: 11px; height: 11px; border-radius: 50%; margin-top: 3px; flex-shrink: 0; }
.wf-dot.done { background: var(--accent); }
.wf-dot.current { background: #fff; border: 2px solid var(--accent); }
.wf-dot.future { background: #fff; border: 2px solid #d8d8dc; }
.wf-dot.blocked { background: #c0392b; }
.wf-label { font-size: 14px; font-weight: 650; }
.wf-meta { font-size: 12.5px; color: var(--muted2); margin-top: 1px; }
.wf-meta.pending { color: #92620a; }
.wf-meta.blocked-text { color: #c0392b; }
.wf-actions { margin-top: 6px; }
.wf-actions select { width: 100%; border: 1px solid #d8d8dc; border-radius: 8px; padding: 7px 10px; font-size: 13px; margin-bottom: 8px; }
.wf-actions .btn-row { display: flex; gap: 8px; }

.prop-row { display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 8px 0; border-top: 1px solid #f4f4f5; font-size: 13px; }
.prop-row:first-child { border-top: 0; padding-top: 0; }
.prop-row .fl { color: var(--muted); flex-shrink: 0; }
.prop-row select, .prop-row input[type=text] { border: 0; background: transparent; text-align: right; font-size: 13px; font-weight: 650; color: var(--text); cursor: pointer; max-width: 60%; }
.prop-row .val { font-weight: 650; text-align: right; }

.version-row { padding: 8px 0; border-top: 1px solid #f4f4f5; font-size: 12.5px; }
.version-row:first-child { border-top: 0; padding-top: 0; }
.version-row .v { font-weight: 700; color: var(--text); }
.version-row .who { color: var(--muted2); }

/* ---- ZEDSMS design system ---- */
.btn-primary:hover { background: var(--accent-hover); }
.btn-primary, .btn { transition: transform 220ms cubic-bezier(.34,1.56,.64,1), background-color 220ms ease; }
.btn-primary:hover, .btn:hover { transform: translateY(-2px); }
.brand-mark-img { width: 28px; height: 28px; display: block; }
.brand-wordmark-img { height: 16px; width: auto; display: block; }
h1, h2, h3, .brand, .nav a, .btn, .btn-primary { font-family: "Host Grotesk", ui-sans-serif, system-ui, sans-serif; }
.nav a { font-weight: 500; color: var(--text); }
.nav a:hover { color: var(--accent); text-decoration: none; }
.topbar { border-bottom-color: var(--line); }
.card { transition: transform 220ms cubic-bezier(.34,1.56,.64,1), box-shadow 220ms ease; }
a.card:hover, .grid-cards .card:hover { transform: translateY(-4px); box-shadow: 0 18px 40px -10px rgba(15,16,19,.16); text-decoration: none; }
.footer { background: #fff; }
@media (prefers-reduced-motion: reduce) { .card, .btn, .btn-primary { transition: none; } a.card:hover, .grid-cards .card:hover, .btn:hover, .btn-primary:hover { transform: none; } }

/* search-as-you-type dropdown (static/js/search-suggest.js) */
.searchbox { position: relative; }
.suggest { position: absolute; z-index: 20; top: calc(100% + 8px); left: 0; right: 0; background: #fff; color: #18181b; border: 1px solid var(--line); border-radius: 16px; box-shadow: 0 18px 48px rgba(24,24,27,.12); padding: 6px; text-align: left; }
.suggest-row { display: flex; justify-content: space-between; align-items: baseline; gap: 12px; padding: 10px 14px; border-radius: 10px; font-size: 14.5px; color: inherit; text-decoration: none; }
.suggest-row:hover, .suggest-row.active { background: #f4f4f5; }
.suggest-dym { color: var(--accent); }
.suggest-cat { flex-shrink: 0; font-size: 12px; color: var(--muted); }
.search-correction { margin-bottom: 18px; font-size: 16px; }
.search-correction a { color: var(--accent); }
.search-correction .crumb { margin-top: 4px; }
