:root {
  --ink: #141816;
  --paper: #ECEBE6;
  --surface: #fff;
  --accent: #243F35;
  --accent-hover: #1B3129;
  --accent-soft: #E6EEE9;
  --line: #C9CBC4;
  --muted: #5A5E5A;
  --danger: #8B1E1E;
  --gold: #C4A574;
  --gold-soft: #F4EEE4;
  --radius: 10px;
  --shadow: 0 1px 2px rgba(20, 24, 22, .06);
  --font: "IBM Plex Sans Arabic", "IBM Plex Sans", sans-serif;
  --tap: 44px;
}
* { box-sizing: border-box; }
body {
  margin: 0;
  font-family: var(--font);
  background: var(--paper);
  color: var(--ink);
  min-height: 100dvh;
  line-height: 1.55;
}
a { color: var(--accent); }
button, input, select, textarea { font: inherit; }
h1, h2, h3, h4 { color: var(--ink); }
.shell { max-width: 1120px; margin: 0 auto; padding: 20px 16px 64px; }
.brand-kicker {
  margin: 0 0 4px;
  font-size: .72rem;
  font-weight: 700;
  letter-spacing: .1em;
  color: var(--gold);
}
.page-title {
  margin: 0;
  font-size: 1.45rem;
  font-weight: 700;
  letter-spacing: -.02em;
  line-height: 1.25;
}
.page-sub { margin: 4px 0 0; font-size: .92rem; }
.top {
  display: flex; flex-wrap: wrap; gap: 12px 16px;
  justify-content: space-between; align-items: center;
  margin-bottom: 14px;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 14px 18px;
  box-shadow: var(--shadow);
}
.badge {
  display: inline-block; font-size: .72rem; font-weight: 650;
  color: var(--accent); background: var(--accent-soft);
  padding: 3px 8px; border-radius: 999px; margin-inline-start: 6px;
}
.badge.gold {
  color: #6F542E;
  background: var(--gold-soft);
}
.flash-ok {
  margin: 0 0 14px;
  padding: 10px 14px;
  border-radius: 8px;
  background: var(--accent-soft);
  border: 1px solid #C5D4CB;
  color: var(--accent);
  font-weight: 600;
}
.nav {
  display: flex; flex-wrap: nowrap; gap: 4px;
  margin: 0 0 22px;
  position: sticky; top: 0; z-index: 5;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 6px;
  box-shadow: var(--shadow);
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: thin;
}
.nav::-webkit-scrollbar { height: 4px; }
.nav::-webkit-scrollbar-thumb { background: #C9CBC4; border-radius: 999px; }
.nav .btn {
  flex: 0 0 auto;
  white-space: nowrap;
  background: transparent;
  border-color: transparent;
  min-height: 40px;
  padding: 8px 12px;
  font-weight: 600;
  gap: 6px;
}
.nav .btn:hover { background: var(--accent-soft); border-color: transparent; }
.nav .btn.primary {
  background: var(--accent);
  color: #fff;
  border-color: var(--accent);
}
.nav .btn.primary:hover { background: var(--accent-hover); color: #fff; }
.nav-count {
  display: inline-flex;
  min-width: 18px; height: 18px;
  padding: 0 5px;
  border-radius: 999px;
  align-items: center; justify-content: center;
  font-size: .68rem; font-weight: 700;
  background: var(--gold-soft); color: #6F542E;
}
.nav .btn.primary .nav-count {
  background: rgba(255,255,255,.18);
  color: #fff;
}
.card {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 18px 18px 16px;
  margin-bottom: 18px;
  box-shadow: var(--shadow);
}
.card > h2, .card > h3, .card-title {
  margin: 0 0 6px;
  font-size: 1.12rem;
  font-weight: 700;
  letter-spacing: -.01em;
}
.card > .muted:first-of-type { margin-top: 0; }
.grid { display: grid; gap: 14px; grid-template-columns: repeat(auto-fit, minmax(180px, 1fr)); margin-bottom: 18px; }
.grid > .card { margin-bottom: 0; }
.stat strong { display: block; font-size: 1.55rem; margin-top: 6px; font-weight: 700; }
.home-actions { display: flex; flex-wrap: wrap; gap: 8px; margin: 14px 0 18px; }
.kpi-grid {
  display: grid;
  gap: 12px;
  grid-template-columns: repeat(4, 1fr);
  margin: 0 0 18px;
}
.insight {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 16px;
  box-shadow: var(--shadow);
}
.insight .muted { font-size: .8rem; font-weight: 600; }
.insight strong { display: block; font-size: 1.7rem; margin-top: 8px; letter-spacing: -.03em; font-weight: 700; }
.insight.kpi-accent { border-color: #C5D4CB; background: #F7FAF8; }
.card .insight { background: #F7F6F2; }
.btn {
  border: 1px solid var(--line);
  background: var(--surface);
  border-radius: 8px;
  padding: 10px 14px;
  min-height: var(--tap);
  cursor: pointer;
  font-weight: 650;
  color: var(--ink);
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  transition: background .15s ease, border-color .15s ease, color .15s ease;
}
.btn:hover { background: #F3F4F1; border-color: #B7B9B2; }
.btn:active { background: #E8E9E4; }
.btn.primary { background: var(--accent); color: #fff; border-color: var(--accent); }
.btn.primary:hover { background: var(--accent-hover); border-color: var(--accent-hover); color: #fff; }
.btn.primary:active { background: #15261F; }
.btn.danger { color: var(--danger); border-color: #E2B6B6; background: #FDF6F6; }
.btn.danger:hover { background: #F8E8E8; }
.btn:disabled, .btn[disabled] {
  opacity: .55;
  cursor: not-allowed;
  pointer-events: none;
}
.btn:focus-visible, input:focus-visible, select:focus-visible, textarea:focus-visible {
  outline: 2px solid var(--accent); outline-offset: 2px;
}
.field { margin: 10px 0; }
label { display: block; font-size: .82rem; color: var(--muted); margin-bottom: 4px; font-weight: 550; }
input, select, textarea {
  width: 100%; padding: 11px 12px; border: 1px solid var(--line);
  border-radius: var(--radius); background: #fff; min-height: var(--tap);
}
table { width: 100%; border-collapse: collapse; font-size: .9rem; }
th, td { border-bottom: 1px solid var(--line); padding: 11px 6px; text-align: right; vertical-align: top; }
.muted { color: var(--muted); font-size: .88rem; }
.ok { color: var(--accent); font-weight: 600; }
.err { color: var(--danger); margin: 8px 0; }
.login { max-width: 420px; margin: 8vh auto; }
.login .card { padding: 22px 20px; }
.row-actions { display: flex; flex-wrap: wrap; gap: 8px; }
.howto {
  background: #F7F6F2;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 14px 16px;
  margin: 0 0 18px;
  font-size: .92rem;
  line-height: 1.65;
}
.howto ol { margin: 8px 0; padding-inline-start: 1.3rem; }
.howto li { margin: 4px 0; }
.howto p { margin: 0 0 8px; }
.howto p:last-child { margin: 8px 0 0; }
.vreq {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 16px;
  margin: 0 0 16px;
  background: var(--surface);
  box-shadow: var(--shadow);
}
.vreq-head {
  display: flex; flex-wrap: wrap; gap: 8px 12px;
  align-items: center; margin-bottom: 12px;
}
.vreq-head .vreq-title { flex: 1 1 180px; font-size: 1.08rem; margin-bottom: 0; font-weight: 700; }
.vreq-submitted { border-color: #E0C48A; }
.vreq-done, .vreq-canceled { opacity: .96; }
.vreq-filters { display: flex; flex-wrap: nowrap; gap: 8px; margin: 0 0 16px; overflow-x: auto; padding-bottom: 4px; }
.vreq-chip {
  border: 1px solid var(--line); background: #fff;
  border-radius: 999px; padding: 8px 12px; min-height: 40px;
  cursor: pointer; font-weight: 650; color: var(--ink);
  white-space: nowrap; flex: 0 0 auto;
}
.vreq-chip:hover { background: var(--accent-soft); }
.vreq-chip.on { background: var(--accent); color: #fff; border-color: var(--accent); }
.vreq-group { margin: 0 0 28px; }
.vreq-group h3 { margin: 0 0 8px; font-size: 1.08rem; font-weight: 700; }
.vreq-msg {
  background: #F7F6F2; border: 1px solid var(--line);
  border-radius: var(--radius); padding: 12px 14px;
  margin: 0 0 12px;
}
.vreq-msg h4 { margin: 0 0 6px; font-size: .78rem; color: var(--muted); font-weight: 700; letter-spacing: .02em; }
.vreq-note { margin: 0 0 6px; white-space: pre-wrap; line-height: 1.65; }
.vreq-grid {
  display: grid; gap: 12px;
  grid-template-columns: 1fr;
}
@media (min-width: 720px) {
  .vreq-grid { grid-template-columns: 1fr 1fr; }
}
.vreq-block {
  background: #F7F6F2;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 12px 14px;
  margin: 0 0 12px;
}
.vreq-block h4 {
  margin: 0 0 8px;
  font-size: .75rem;
  color: var(--muted);
  font-weight: 700;
  letter-spacing: .04em;
}
.vreq-title { display: block; font-size: 1.08rem; margin-bottom: 4px; font-weight: 700; }
.vreq-prop { display: block; margin: 0 0 6px; font-size: 1.02rem; }
.vreq-status { margin-top: 12px; }
.vreq-admin {
  margin-top: 4px;
  padding-top: 12px;
  border-top: 1px solid var(--line);
}
.vreq-reply {
  min-height: 148px;
  line-height: 1.7;
  white-space: pre-wrap;
}
.vreq-done .vreq-reply, .vreq-canceled .vreq-reply { min-height: 96px; }
.pill {
  display: inline-block; font-size: .75rem; padding: 4px 9px;
  border-radius: 999px; background: #F3F4F1; border: 1px solid var(--line);
  font-weight: 650;
}
.pill.open { background: #FFF6E8; border-color: #E8C48A; color: #7A4E12; }
.pill.progress { background: #EAF1FA; border-color: #B7C9E8; color: #2A4A73; }
.pill.done { background: #E7F5EC; border-color: #A9D4B5; color: #1E5A38; }
.pill.warn { background: #FDECEC; border-color: #E2B6B6; color: var(--danger); }
.empty { text-align: center; padding: 28px 12px; color: var(--muted); }
.chat {
  max-height: 420px; overflow: auto; background: var(--paper);
  border: 1px solid var(--line); border-radius: var(--radius); padding: 12px; margin: 12px 0;
}
.bubble { max-width: 88%; padding: 10px 12px; border-radius: var(--radius); margin-bottom: 8px; background: #fff; border: 1px solid var(--line); }
.bubble.me { background: var(--accent-soft); border-color: transparent; margin-right: auto; }
.bubble.system { background: #F7F3EA; border-color: #E8DCC4; font-size: .88rem; color: var(--muted); }
.media-list { list-style: none; padding: 0; margin: 0 0 12px; }
.media-list li {
  display: flex; flex-wrap: wrap; gap: 8px; align-items: center;
  padding: 8px 0; border-bottom: 1px solid var(--line);
}
.thumb {
  width: 64px; height: 48px; object-fit: cover; border-radius: 4px; border: 1px solid var(--line);
}
.edit-panel { border-top: 1px solid var(--line); margin-top: 12px; padding-top: 12px; }
.geo-map {
  height: 280px;
  margin: 12px 0;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  overflow: hidden;
  background: #e8ebe9;
}
.map-mgr-canvas { height: min(62vh, 520px); min-height: 320px; }
.map-mgr-filters { display: flex; flex-wrap: wrap; gap: 8px; margin: 10px 0 12px; }
.map-mgr-noloc { margin: 12px 0; }
.map-mgr-noloc table { width: 100%; }
.map-mgr-legend { display: flex; flex-wrap: wrap; gap: 14px; margin: 0 0 8px; font-size: .9rem; }
.map-mgr-legend .dot {
  display: inline-block; width: 10px; height: 10px; border-radius: 50%;
  margin-left: 6px; vertical-align: middle; border: 2px solid #fff;
  box-shadow: 0 0 0 1px rgba(0,0,0,.15);
}
.map-mgr-legend .dot.on { background: #243F35; }
.map-mgr-legend .dot.off { background: #9AA5A0; }
.map-mgr-panel {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 12px 14px;
  background: var(--paper);
  margin-bottom: 8px;
}
.map-mgr-panel h4 { margin: 0 0 6px; }
.geo-results {
  display: flex;
  flex-direction: column;
  gap: 6px;
  margin-top: 8px;
  max-height: 160px;
  overflow: auto;
}
.geo-results .btn { text-align: right; white-space: normal; height: auto; min-height: var(--tap); }
.social-list { display: grid; gap: 10px; margin: 12px 0; }
.social-row {
  display: grid;
  grid-template-columns: auto 110px 1fr;
  gap: 10px;
  align-items: center;
  padding: 10px 12px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--paper);
}
.social-toggle { font-size: .85rem; color: var(--muted); white-space: nowrap; }
.social-name { font-size: .92rem; }
.social-row .sh { width: 100%; min-height: var(--tap); padding: 8px 10px; border: 1px solid var(--line); border-radius: 6px; }
.avatar-editor {
  display: flex;
  gap: 14px;
  align-items: center;
  flex-wrap: wrap;
  margin: 0 0 14px;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--paper);
}
.avatar-preview {
  width: 88px;
  height: 88px;
  border-radius: 50%;
  overflow: hidden;
  display: flex;
  align-items: center;
  justify-content: center;
  background: linear-gradient(145deg, #2F5244, #243F35);
  color: #fff;
  font-weight: 700;
  font-size: 1.2rem;
  flex: 0 0 auto;
}
.avatar-preview img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}
.avatar-actions {
  display: flex;
  flex-direction: column;
  gap: 8px;
  align-items: flex-start;
}
.avatar-actions label.btn { cursor: pointer; }
.hero-pos-picker {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 12px 14px;
  margin: 0 0 14px;
  background: var(--paper);
}
.hero-pos-picker legend {
  font-weight: 650;
  font-size: .92rem;
  padding: 0 6px;
}
.hero-pos-opts {
  display: flex;
  flex-wrap: wrap;
  gap: 10px 16px;
  margin-top: 8px;
}
.hero-pos-select-label {
  display: block;
  margin: 10px 0 6px;
  font-size: .88rem;
  font-weight: 650;
}
#heroImagePosition {
  width: 100%;
  max-width: 360px;
  min-height: var(--tap);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: #fff;
  color: var(--ink);
  padding: 8px 10px;
}
.attn-board h3 { margin-bottom: 8px; }
.attn-chips {
  display: grid;
  gap: 8px;
  grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
  margin: 10px 0 6px;
}
.attn-chip {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 4px;
  text-align: right;
  border: 1px solid var(--line);
  background: var(--surface);
  border-radius: var(--radius);
  padding: 14px;
  min-height: var(--tap);
  cursor: pointer;
  font: inherit;
  color: var(--ink);
  box-shadow: var(--shadow);
}
.attn-chip:hover { border-color: var(--accent); background: #F7FAF8; }
.attn-chip.hot {
  background: #F7FAF8;
  border-color: #C5D4CB;
}
.attn-chip strong { font-size: 1.55rem; line-height: 1.1; font-weight: 700; }
.attn-note { margin: 4px 0 0; font-size: .8rem; }
.attn-head {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 8px;
}
.attn-head h3 { margin: 0; }
.attn-list { list-style: none; padding: 0; margin: 0; }
.attn-item, .attn-alert {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  justify-content: space-between;
  align-items: center;
  padding: 10px 0;
  border-bottom: 1px solid var(--line);
}
.attn-item:last-child, .attn-alert:last-child { border-bottom: 0; }
.attn-alert.warn { color: var(--danger); }
.btn.ai-busy { opacity: .65; cursor: wait; }
.ai-nudge { font-size: .82rem; }
.ai-hints { margin-top: 8px; }
.insights-grid {
  display: grid;
  gap: 10px;
  grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
  margin-top: 10px;
}
.setup-board .pill.done { background: #E7F5EC; border-color: #A9D4B5; }
.id-page { display: flex; flex-direction: column; gap: 0; }
.id-head {
  display: flex; flex-wrap: wrap; gap: 12px 16px;
  justify-content: space-between; align-items: flex-start;
  margin: 0 0 14px;
}
.id-head h2 { margin: 0 0 6px; font-size: 1.22rem; letter-spacing: -.02em; font-weight: 700; }
.id-kicker { color: var(--gold); }
.id-card { padding: 18px 18px 16px; }
.id-card-head { margin-bottom: 14px; }
.id-card-head h3 { margin: 0 0 4px; font-size: 1.02rem; }
.id-card-head .muted { margin: 0; }
.id-look {
  display: grid; gap: 14px;
  grid-template-columns: 1fr;
  margin-bottom: 16px;
}
@media (min-width: 820px) {
  .id-look { grid-template-columns: minmax(220px, .9fr) minmax(280px, 1.2fr); align-items: stretch; }
}
.id-photo {
  margin: 0; height: 100%;
  background: #F7F6F2;
}
.id-page .avatar-preview {
  width: 112px; height: 140px; border-radius: 12px;
  box-shadow: var(--shadow);
}
.id-hint { margin: 6px 0 0; font-size: .8rem; color: var(--muted); }
.id-live {
  display: flex; gap: 14px; align-items: center;
  padding: 16px 18px; border-radius: var(--radius);
  background: var(--accent); color: #F6F5F2;
  min-height: 168px; overflow: hidden;
  border: 1px solid var(--accent);
}
.id-live-eye {
  display: block; font-size: .68rem; font-weight: 700;
  letter-spacing: .12em; color: var(--gold); margin-bottom: 6px;
}
.id-live[data-pos="left"] { flex-direction: row-reverse; }
.id-live[data-pos="center"] {
  flex-direction: column; text-align: center;
  padding-top: 18px;
}
.id-live-copy { flex: 1; min-width: 0; }
.id-live-copy strong {
  display: block; font-size: 1.15rem; line-height: 1.25; margin-bottom: 4px;
}
.id-live-copy p { margin: 0 0 4px; font-size: .86rem; color: rgba(246,245,242,.82); }
.id-live-val { color: #F6F5F2 !important; font-weight: 550; }
.id-live-lic {
  display: inline-block; margin-top: 8px; font-size: .75rem;
  color: var(--gold); border: 1px solid rgba(196,165,116,.4);
  border-radius: 999px; padding: 3px 10px;
}
.id-live-photo {
  width: 88px; height: 110px; border-radius: 10px; overflow: hidden;
  flex: 0 0 auto; background: #1a2e27;
  display: flex; align-items: center; justify-content: center;
  font-weight: 700; color: #F6F5F2;
  border: 1px solid rgba(246,245,242,.16);
}
.id-live[data-pos="center"] .id-live-photo { width: 72px; height: 90px; }
.id-live-photo img { width: 100%; height: 100%; object-fit: cover; display: block; }
.id-pos-picker { position: relative; background: #F6F5F2; }
.id-pos-grid {
  display: grid; gap: 10px;
  grid-template-columns: 1fr;
  margin: 10px 0 0;
}
@media (min-width: 640px) {
  .id-pos-grid { grid-template-columns: repeat(3, 1fr); }
}
.id-pos-card {
  position: relative;
  display: flex; flex-direction: column; gap: 6px;
  margin: 0; padding: 12px; min-height: var(--tap);
  border: 1px solid var(--line); border-radius: 10px;
  background: #fff; cursor: pointer; color: var(--ink);
}
.id-pos-card input { position: absolute; opacity: 0; pointer-events: none; }
.id-pos-card strong { font-size: .9rem; }
.id-pos-card span:last-child { font-size: .78rem; color: var(--muted); font-weight: 400; }
.id-pos-card.is-on {
  border-color: var(--accent); background: var(--accent-soft);
  box-shadow: 0 0 0 1px var(--accent);
}
.id-pos-mock {
  display: flex; height: 44px; border-radius: 6px;
  background: #E8EBE8; overflow: hidden; gap: 4px; padding: 6px;
}
.id-pos-mock i, .id-pos-mock b { display: block; border-radius: 3px; }
.id-pos-mock i { flex: 1; background: #c9d4ce; }
.id-pos-mock b { width: 28%; background: #243F35; }
.id-pos-mock-left { flex-direction: row-reverse; }
.id-pos-mock-center { flex-direction: column; align-items: center; }
.id-pos-mock-center b { width: 22px; height: 14px; }
.id-pos-picker .hero-pos-select-label,
.id-pos-picker #heroImagePosition {
  position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0, 0, 0, 0); border: 0;
}
.id-fields {
  display: grid; gap: 4px 16px;
  grid-template-columns: 1fr;
}
@media (min-width: 720px) {
  .id-fields { grid-template-columns: 1fr 1fr; }
  .id-fields .id-span-2 { grid-column: 1 / -1; }
}
.id-ai-row { margin-top: 6px; }
.id-ai-row .btn { font-size: .82rem; min-height: 40px; font-weight: 550; }
.id-savebar {
  position: sticky; bottom: 8px; z-index: 4;
  display: flex; flex-wrap: wrap; gap: 10px 16px;
  justify-content: space-between; align-items: center;
  background: #fff; border: 1px solid var(--line);
  border-radius: var(--radius); padding: 12px 16px; margin: 0 0 12px;
  box-shadow: 0 4px 16px rgba(20, 24, 22, .08);
}
.id-savebar p { margin: 2px 0 0; }
.id-savebar-actions { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; }
.id-chan {
  display: grid; gap: 8px 12px;
  grid-template-columns: 1fr;
  padding: 12px; margin-bottom: 10px;
  border: 1px solid var(--line); border-radius: 8px;
  background: #F7F6F2;
}
@media (min-width: 720px) {
  .id-chan { grid-template-columns: 1fr 1.2fr; }
  .id-chan-flags { grid-column: 1 / -1; }
}
.id-chan .field { margin: 0; }
.id-chan-flags {
  display: flex; flex-wrap: wrap; gap: 10px 16px;
  font-size: .88rem; color: var(--muted);
}
.id-chan-flags label { display: flex; align-items: center; gap: 8px; margin: 0; color: var(--ink); }
.id-chan-flags input { width: auto; min-height: 20px; }
.id-page .social-row {
  background: #F7F6F2;
  border-radius: 8px;
}
.chat-contact {
  background: #F7F6F2;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 12px 14px;
  margin: 10px 0 14px;
}
.chat-contact h4 { margin: 0 0 8px; font-size: .92rem; }
.contact-sheet { display: grid; gap: 6px; }
.contact-sheet-name { margin: 0 0 4px; }
.contact-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  min-height: 44px;
}
.contact-row-val { font-size: .92rem; overflow-wrap: anywhere; }
.contact-ico {
  width: 40px; height: 40px; flex: 0 0 40px;
  border-radius: 50%;
  display: inline-flex; align-items: center; justify-content: center;
  text-decoration: none;
}
.contact-ico svg { width: 22px; height: 22px; display: block; }
.contact-ico.wa { background: #25D366; }
.contact-ico.mail {
  background: #fff;
  border: 1px solid #E2E2E2;
  box-shadow: 0 1px 2px rgba(0,0,0,.08);
}
.contact-ico:hover { transform: scale(1.05); }
.contact-ico:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }

.appt-box {
  border-color: #C5D4CB;
  background: #F7FAF8;
}
.appt-box h4 { color: var(--accent); font-weight: 700; }
.appt-slots, .appt-notify {
  margin: 6px 0 10px;
  padding-inline-start: 18px;
}
.appt-slot-row { margin: 8px 0; }
.appt-slot-fields {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
}
.appt-confirm-slots, .appt-outcomes {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin: 8px 0;
}
.appt-log { margin-top: 10px; font-size: .86rem; }
.appt-log summary { cursor: pointer; color: var(--muted); }
.appt-form { margin-top: 12px; padding-top: 10px; border-top: 1px dashed var(--line); }

@media (max-width: 900px) {
  .kpi-grid { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 760px) {
  .shell { padding: 12px 10px 56px; }
  .page-title { font-size: 1.28rem; }
  .top { padding: 12px 14px; }
  .home-actions .btn { flex: 1 1 calc(50% - 8px); }
  .home-actions .btn.primary { flex: 1 1 100%; }
  .social-row { grid-template-columns: 1fr; }
  .id-savebar { bottom: 4px; }
  .row-actions { gap: 8px; }
  .row-actions .btn, .row-actions a.btn { flex: 1 1 calc(50% - 8px); }
  .vreq .row-actions .btn.primary,
  .vreq .row-actions a.btn.primary { flex: 1 1 100%; }
  .kpi-grid { gap: 10px; }
  table.stack-table { width: 100%; border-collapse: separate; border-spacing: 0; }
  table.stack-table thead { display: none; }
  table.stack-table, table.stack-table tbody, table.stack-table tr, table.stack-table td {
    display: block; width: 100%;
  }
  table.stack-table tr {
    border: 1px solid var(--line);
    border-radius: var(--radius);
    padding: 12px 14px;
    margin: 0 0 12px;
    background: var(--surface);
    box-shadow: var(--shadow);
  }
  table.stack-table td {
    border: 0;
    padding: 8px 0;
    text-align: right;
  }
  table.stack-table td::before {
    content: attr(data-label);
    display: block;
    font-size: .72rem;
    font-weight: 700;
    color: var(--muted);
    margin-bottom: 4px;
    letter-spacing: .03em;
  }
  table.stack-table td.row-actions::before { display: none; }
  table.stack-table td.row-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    padding-top: 12px;
    margin-top: 4px;
    border-top: 1px solid var(--line);
  }
  table:not(.stack-table) { display: block; overflow-x: auto; }
}
