/*
 * Author: Yogabrata Mukhopadhyay
 * Organization: ManjuLab
 * Copyright (c) 2026 ManjuLab. All rights reserved.
 *
 * REACH — ManjuLAB cosmic/circular theme (UX redesign, Phase 1).
 */

:root {
  --bg-dark: #070d1b;
  --bg-deep: #0d1830;
  --bg-panel: #101d3a;
  --primary: #4f8cff;
  --primary-ink: #06122b;
  --accent: #35d3a7;
  --accent-2: #8f7bff;
  --brand-gold: #d8b75b;
  --ink: #eef3ff;
  --muted: #96a6cf;
  --muted-2: #6c7ba8;
  --danger: #ff6b81;
  --warn: #f0b94d;
  --ok: #35d3a7;
  --border: rgba(143, 165, 226, 0.22);
  --border-strong: rgba(143, 165, 226, 0.4);
  --focus: #8fc6ff;
  --panel-glass: rgba(16, 29, 58, 0.72);
  --shadow-soft: 0 18px 44px rgba(3, 7, 20, 0.55);
  --shadow-lift: 0 24px 60px rgba(3, 7, 20, 0.65);
  --radius-lg: 26px;
  --radius-md: 18px;
  --radius-sm: 12px;
  --font-display: "Trebuchet MS", "Segoe UI", "Verdana", sans-serif;
  --font-body: "Segoe UI", "Trebuchet MS", "Verdana", sans-serif;
}

* { box-sizing: border-box; }

[hidden] { display: none !important; }

html, body { margin: 0; padding: 0; }

body {
  min-height: 100vh;
  font-family: var(--font-body);
  color: var(--ink);
  background:
    radial-gradient(ellipse 60% 45% at 12% 4%, rgba(79, 140, 255, 0.24) 0%, transparent 62%),
    radial-gradient(ellipse 55% 50% at 92% 8%, rgba(143, 123, 255, 0.2) 0%, transparent 60%),
    radial-gradient(ellipse 70% 60% at 50% 100%, rgba(53, 211, 167, 0.14) 0%, transparent 65%),
    linear-gradient(180deg, var(--bg-dark) 0%, var(--bg-deep) 55%, var(--bg-dark) 100%);
  background-attachment: fixed;
  line-height: 1.5;
}

h1, h2, h3, .brand-word, .hero-title {
  font-family: var(--font-display);
  letter-spacing: 0.01em;
}

a { color: var(--focus); }

.skip-link {
  position: absolute;
  left: -999px;
  top: 0;
  background: var(--primary);
  color: #fff;
  padding: 0.5rem 1rem;
  z-index: 200;
  border-radius: 0 0 8px 0;
}
.skip-link:focus { left: 0; top: 0; }

.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;
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }
}

/* ---------- Forms & buttons ---------- */

label { display: block; font-size: 0.85rem; color: var(--muted); margin-bottom: 0.3rem; }

input, textarea, select {
  font: inherit;
  color: var(--ink);
  background: rgba(7, 13, 27, 0.65);
  border: 1px solid var(--border);
  padding: 0.6rem 0.8rem;
  border-radius: var(--radius-sm);
  width: 100%;
}
input::placeholder, textarea::placeholder { color: var(--muted-2); }
input:focus-visible, textarea:focus-visible, select:focus-visible,
button:focus-visible, a:focus-visible, [tabindex]:focus-visible {
  outline: 2px solid var(--focus);
  outline-offset: 2px;
}

button {
  font: inherit;
  cursor: pointer;
  color: var(--ink);
  background: rgba(143, 165, 226, 0.12);
  border: 1px solid var(--border);
  padding: 0.6rem 1rem;
  border-radius: 999px;
  transition: transform 0.12s ease, background 0.15s ease, border-color 0.15s ease;
}
button:hover { border-color: var(--border-strong); }
button:active { transform: translateY(1px); }
button:disabled { opacity: 0.5; cursor: not-allowed; transform: none; }

button.primary {
  background: linear-gradient(135deg, var(--primary), var(--accent-2));
  border-color: transparent;
  color: #fff;
  font-weight: 600;
  box-shadow: 0 10px 26px rgba(79, 140, 255, 0.35);
}
button.primary:hover { filter: brightness(1.06); }

button.ghost { background: transparent; border-color: var(--border); }
button.danger-ghost { background: transparent; border-color: rgba(255, 107, 129, 0.5); color: var(--danger); }
button.linkish {
  background: none; border: none; color: var(--focus);
  text-decoration: underline; padding: 0; border-radius: 0; font: inherit;
}
button.small { padding: 0.35rem 0.75rem; font-size: 0.82rem; }

.row { display: flex; flex-wrap: wrap; gap: 0.6rem; align-items: center; }
.stack { display: grid; gap: 0.5rem; }

.muted { color: var(--muted); font-size: 0.92rem; }
.error { color: var(--danger); margin: 0; font-size: 0.9rem; }

dialog {
  border: 1px solid var(--border-strong);
  background: linear-gradient(160deg, var(--bg-panel), var(--bg-deep));
  color: var(--ink);
  padding: 1.5rem;
  max-width: 460px;
  width: calc(100% - 2rem);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-lift);
}
dialog::backdrop { background: rgba(3, 6, 16, 0.72); backdrop-filter: blur(2px); }
dialog h2 { margin: 0 0 0.35rem; font-size: 1.25rem; }

details > summary { cursor: pointer; color: var(--muted); font-size: 0.9rem; }
details[open] > summary { color: var(--ink); margin-bottom: 0.6rem; }

.badge {
  display: inline-flex;
  align-items: center;
  gap: 0.3rem;
  font-size: 0.72rem;
  letter-spacing: 0.03em;
  text-transform: uppercase;
  padding: 0.2rem 0.55rem;
  border-radius: 999px;
  border: 1px solid var(--border);
  color: var(--muted);
}
.badge.ok, .badge.connected { color: var(--ok); border-color: rgba(53, 211, 167, 0.4); background: rgba(53, 211, 167, 0.1); }
.badge.warn, .badge.pending { color: var(--warn); border-color: rgba(240, 185, 77, 0.4); background: rgba(240, 185, 77, 0.1); }
.badge.bad, .badge.error { color: var(--danger); border-color: rgba(255, 107, 129, 0.4); background: rgba(255, 107, 129, 0.1); }
.badge.dot::before { content: ""; width: 0.4rem; height: 0.4rem; border-radius: 50%; background: currentColor; }

/* ---------- Login screen ---------- */

.login-screen {
  min-height: 100vh;
  display: grid;
  place-items: center;
  padding: 1.5rem;
  position: relative;
}
.login-orb {
  position: absolute;
  width: 40rem;
  height: 40rem;
  border-radius: 50%;
  border: 1px dashed rgba(143, 165, 226, 0.16);
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  pointer-events: none;
}
.login-orb.two { width: 56rem; height: 56rem; border-color: rgba(143, 123, 255, 0.1); }
.login-panel {
  position: relative;
  width: min(440px, 100%);
  background: var(--panel-glass);
  border: 1px solid var(--border-strong);
  border-radius: var(--radius-lg);
  padding: 2.1rem 2rem;
  box-shadow: var(--shadow-lift);
  backdrop-filter: blur(6px);
}
.login-mark {
  width: 3rem;
  height: 3rem;
  border-radius: 50%;
  background: conic-gradient(from 210deg, var(--primary), var(--accent-2), var(--accent), var(--primary));
  margin-bottom: 1rem;
  box-shadow: 0 0 0 6px rgba(79, 140, 255, 0.08);
}
.login-panel h1 {
  margin: 0 0 0.15rem;
  font-size: 2.1rem;
  background: linear-gradient(120deg, var(--ink), var(--focus));
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}
.login-panel > p.lede { margin: 0 0 1.4rem; color: var(--muted); }
.login-panel .stack { gap: 0.7rem; }
.login-advanced { margin-top: 0.5rem; }
.login-advanced summary { font-size: 0.85rem; }
.login-hint { margin-top: 1rem; text-align: center; }

/* ---------- App shell ---------- */

.app-shell {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

.app-header {
  position: sticky;
  top: 0;
  z-index: 40;
  display: flex;
  align-items: center;
  gap: 1rem;
  padding: 0.75rem clamp(1rem, 3vw, 2rem);
  background: rgba(7, 13, 27, 0.82);
  border-bottom: 1px solid var(--border);
  backdrop-filter: blur(10px);
}
.brand-word {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-weight: 700;
  font-size: 1.25rem;
  letter-spacing: 0.06em;
  color: var(--ink);
  white-space: nowrap;
}
.brand-mark {
  width: 1.7rem;
  height: 1.7rem;
  border-radius: 50%;
  background: conic-gradient(from 210deg, var(--primary), var(--accent-2), var(--accent), var(--primary));
  flex: none;
}
.org-switcher {
  display: flex;
  align-items: center;
  gap: 0.55rem;
  background: rgba(143, 165, 226, 0.1);
  border: 1px solid var(--border);
  border-radius: 999px;
  padding: 0.3rem 0.5rem 0.3rem 0.3rem;
  cursor: pointer;
  color: var(--ink);
}
.org-switcher:disabled { cursor: default; opacity: 0.85; }
.org-avatar {
  width: 1.9rem;
  height: 1.9rem;
  border-radius: 50%;
  display: grid;
  place-items: center;
  font-size: 0.72rem;
  font-weight: 700;
  color: #04102a;
  background: linear-gradient(135deg, var(--accent), var(--primary));
  flex: none;
}
.org-switcher .org-name { font-size: 0.9rem; font-weight: 600; max-width: 12rem; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.org-switcher .chev { color: var(--muted); font-size: 0.7rem; }
.header-spacer { flex: 1; }
.header-actions { display: flex; align-items: center; gap: 0.6rem; }
.icon-btn {
  width: 2.4rem;
  height: 2.4rem;
  border-radius: 50%;
  display: grid;
  place-items: center;
  padding: 0;
  font-size: 1.05rem;
  background: rgba(143, 165, 226, 0.1);
}
.user-menu-wrap { position: relative; }
.user-avatar {
  width: 2.4rem;
  height: 2.4rem;
  border-radius: 50%;
  display: grid;
  place-items: center;
  font-weight: 700;
  font-size: 0.85rem;
  color: var(--primary-ink);
  background: linear-gradient(135deg, var(--brand-gold), var(--accent));
  border: none;
  padding: 0;
}
.user-menu {
  position: absolute;
  right: 0;
  top: calc(100% + 0.6rem);
  min-width: 15rem;
  background: var(--bg-panel);
  border: 1px solid var(--border-strong);
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-lift);
  padding: 0.6rem;
  display: grid;
  gap: 0.15rem;
  z-index: 60;
}
.user-menu .who { padding: 0.5rem 0.65rem 0.7rem; border-bottom: 1px solid var(--border); margin-bottom: 0.3rem; }
.user-menu .who strong { display: block; font-size: 0.95rem; }
.user-menu button {
  display: block;
  width: 100%;
  text-align: left;
  border: none;
  background: none;
  border-radius: var(--radius-sm);
  padding: 0.55rem 0.65rem;
}
.user-menu button:hover { background: rgba(143, 165, 226, 0.12); }

/* Primary nav — desktop pill row */
.primary-nav {
  display: flex;
  gap: 0.35rem;
  padding: 0.6rem clamp(1rem, 3vw, 2rem) 0;
  overflow-x: auto;
}
.nav-btn {
  display: flex;
  align-items: center;
  gap: 0.45rem;
  border-radius: 999px;
  padding: 0.55rem 1.05rem;
  background: transparent;
  border: 1px solid transparent;
  color: var(--muted);
  white-space: nowrap;
}
.nav-btn .nav-icon { font-size: 1rem; }
.nav-btn.active {
  color: #fff;
  background: linear-gradient(135deg, rgba(79, 140, 255, 0.9), rgba(143, 123, 255, 0.9));
  border-color: transparent;
  box-shadow: 0 8px 20px rgba(79, 140, 255, 0.28);
}
.nav-btn:not(.active):hover { border-color: var(--border); color: var(--ink); }

/* Bottom nav — mobile */
.bottom-nav {
  position: fixed;
  left: 0; right: 0; bottom: 0;
  z-index: 50;
  display: none;
  justify-content: space-around;
  background: rgba(9, 15, 32, 0.94);
  border-top: 1px solid var(--border);
  backdrop-filter: blur(10px);
  padding: 0.35rem 0.25rem calc(0.35rem + env(safe-area-inset-bottom));
}
.bottom-nav .nav-btn {
  flex-direction: column;
  gap: 0.15rem;
  padding: 0.4rem 0.5rem;
  font-size: 0.68rem;
  border-radius: var(--radius-sm);
}
.bottom-nav .nav-btn .nav-icon { font-size: 1.15rem; }

.main {
  flex: 1;
  padding: 1.5rem clamp(1rem, 3vw, 2.25rem) 3rem;
  max-width: 1180px;
  width: 100%;
  margin: 0 auto;
}

.view-hero { max-width: 44rem; margin-bottom: 1.5rem; }
.view-hero h1 { margin: 0 0 0.4rem; font-size: clamp(1.6rem, 3vw, 2.15rem); }
.view-hero p { margin: 0; color: var(--muted); }

/* ---------- Generic cards / surfaces ---------- */

.surface {
  background: var(--panel-glass);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-soft);
}

.card-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
  gap: 1rem;
}

.empty-state {
  text-align: center;
  padding: 3rem 1.5rem;
  border: 1px dashed var(--border-strong);
  border-radius: var(--radius-lg);
  background: rgba(16, 29, 58, 0.4);
}
.empty-state .empty-icon {
  width: 3.4rem; height: 3.4rem; margin: 0 auto 1rem;
  border-radius: 50%;
  display: grid; place-items: center;
  font-size: 1.5rem;
  background: linear-gradient(135deg, rgba(79, 140, 255, 0.25), rgba(143, 123, 255, 0.25));
}
.empty-state h3 { margin: 0 0 0.4rem; }
.empty-state p { margin: 0 0 1rem; color: var(--muted); max-width: 30rem; margin-inline: auto; }

/* ---------- Organization picker ---------- */

.org-toolbar { display: flex; gap: 0.75rem; flex-wrap: wrap; margin-bottom: 1.25rem; align-items: center; }
.org-toolbar input[type="search"] { max-width: 22rem; }

.org-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
  gap: 1.1rem;
}
.org-card {
  padding: 1.3rem;
  display: grid;
  gap: 0.6rem;
  text-align: left;
  border-radius: var(--radius-lg);
  cursor: pointer;
}
.org-card:hover { border-color: var(--border-strong); transform: translateY(-2px); }
.org-card .org-logo {
  width: 3rem; height: 3rem; border-radius: 50%;
  display: grid; place-items: center;
  font-weight: 700; color: var(--primary-ink);
  background: linear-gradient(135deg, var(--accent), var(--primary));
  font-size: 1rem;
}
.org-card h3 { margin: 0; font-size: 1.08rem; }
.org-card .org-cat { color: var(--muted); font-size: 0.85rem; margin: -0.3rem 0 0; }
.org-card .org-meta { font-size: 0.85rem; color: var(--muted); display: flex; align-items: center; gap: 0.4rem; }
.org-card button { justify-self: start; margin-top: 0.2rem; }

.org-card.create-card {
  border: 2px dashed var(--border-strong);
  background: rgba(79, 140, 255, 0.06);
  display: grid;
  place-items: center;
  gap: 0.5rem;
  text-align: center;
  min-height: 168px;
}
.org-card.create-card .plus-orb {
  width: 3rem; height: 3rem; border-radius: 50%;
  display: grid; place-items: center; font-size: 1.5rem;
  background: linear-gradient(135deg, var(--primary), var(--accent-2));
  color: #fff;
}

/* ---------- Dashboard ---------- */

.dashboard-hero {
  position: relative;
  padding: 2.2rem clamp(1.2rem, 3vw, 2.4rem);
  border-radius: var(--radius-lg);
  overflow: hidden;
  background:
    radial-gradient(ellipse 70% 90% at 85% -10%, rgba(143, 123, 255, 0.35), transparent 60%),
    radial-gradient(ellipse 60% 80% at 0% 110%, rgba(53, 211, 167, 0.25), transparent 60%),
    linear-gradient(135deg, var(--bg-panel), var(--bg-deep));
  border: 1px solid var(--border-strong);
  margin-bottom: 1.5rem;
  display: flex;
  flex-wrap: wrap;
  gap: 1.5rem;
  align-items: center;
  justify-content: space-between;
}
.dashboard-hero .hero-org { display: flex; align-items: center; gap: 0.9rem; }
.dashboard-hero .org-logo-lg {
  width: 3.4rem; height: 3.4rem; border-radius: 50%;
  display: grid; place-items: center;
  font-weight: 700; font-size: 1.15rem; color: var(--primary-ink);
  background: linear-gradient(135deg, var(--accent), var(--primary));
}
.dashboard-hero .hero-title { font-size: clamp(1.5rem, 2.6vw, 2rem); margin: 0 0 0.25rem; }
.dashboard-hero .hero-sub { margin: 0; color: var(--muted); }
.dashboard-hero .hero-cta { flex: none; }

.section-title {
  font-size: 0.95rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--muted);
  margin: 1.8rem 0 0.85rem;
  font-weight: 600;
}
.section-title:first-child { margin-top: 0; }

.checklist-card {
  padding: 1.1rem 1.3rem;
  border-radius: var(--radius-lg);
  border-left: 3px solid var(--brand-gold);
  margin-bottom: 1.25rem;
}
.checklist-card h3 { margin: 0 0 0.6rem; font-size: 1rem; }
.checklist-items { list-style: none; margin: 0 0 0.85rem; padding: 0; display: grid; gap: 0.4rem; }
.checklist-items li { display: flex; align-items: center; gap: 0.55rem; font-size: 0.92rem; }
.checklist-items .tick {
  width: 1.15rem; height: 1.15rem; border-radius: 50%; flex: none;
  display: grid; place-items: center; font-size: 0.68rem;
  border: 1px solid var(--border-strong); color: transparent;
}
.checklist-items li.done .tick { background: var(--ok); border-color: var(--ok); color: #04150c; }
.checklist-items li.done { color: var(--ink); }

.quick-actions {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 1rem;
  margin-bottom: 1.75rem;
}
.quick-card {
  padding: 1.25rem;
  border-radius: var(--radius-lg);
  display: grid;
  gap: 0.5rem;
  cursor: pointer;
  text-align: left;
}
.quick-card:hover { border-color: var(--border-strong); transform: translateY(-2px); }
.quick-card .qi {
  width: 2.6rem; height: 2.6rem; border-radius: 50%;
  display: grid; place-items: center; font-size: 1.2rem;
  background: rgba(79, 140, 255, 0.14);
}
.quick-card.primary-action {
  background: linear-gradient(135deg, rgba(79, 140, 255, 0.22), rgba(143, 123, 255, 0.22));
  border-color: var(--border-strong);
}
.quick-card.primary-action .qi { background: linear-gradient(135deg, var(--primary), var(--accent-2)); color: #fff; }
.quick-card h3 { margin: 0; font-size: 1.02rem; }
.quick-card p { margin: 0; color: var(--muted); font-size: 0.85rem; }

/* Organization-centered channel orbit (ManjuLAB connected-node language) */
.reach-orbit-scene {
  position: relative;
  width: min(640px, 100%);
  margin: 0 auto 1.75rem;
  aspect-ratio: 1;
  max-height: min(72vw, 640px);
  /* Radius MUST be length units — % inside translate() is relative to the node, not the scene. */
  --ym-orbit-r: clamp(170px, 40vmin, 260px);
  container-type: size;
}
@supports (width: 1cqmin) {
  .reach-orbit-scene {
    --ym-orbit-r: min(38cqmin, 230px);
  }
}
.reach-orbit-scene__glow {
  position: absolute;
  inset: 8%;
  border-radius: 50%;
  background:
    radial-gradient(circle, rgba(79, 140, 255, 0.14), transparent 68%),
    radial-gradient(circle, rgba(53, 211, 167, 0.1), transparent 74%);
  pointer-events: none;
}
.reach-orbit-ring {
  position: absolute;
  inset: 18%;
  border-radius: 50%;
  border: 1px dashed rgba(143, 165, 226, 0.28);
  pointer-events: none;
}
.reach-orbit-hub {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  z-index: 3;
  width: min(200px, 42%);
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.55rem;
}
.reach-orbit-hub__disc {
  width: min(112px, 28vw);
  aspect-ratio: 1;
  border-radius: 50%;
  display: grid;
  place-items: center;
  font-weight: 700;
  font-size: clamp(1.1rem, 3vw, 1.6rem);
  color: var(--primary-ink);
  background:
    radial-gradient(circle at 30% 28%, rgba(255, 255, 255, 0.35), transparent 42%),
    linear-gradient(145deg, var(--accent), var(--primary));
  box-shadow:
    0 0 0 8px rgba(79, 140, 255, 0.12),
    0 18px 40px rgba(3, 7, 20, 0.45);
  border: 1px solid rgba(216, 183, 91, 0.35);
}
.reach-orbit-hub__name { margin: 0; font-size: 1.05rem; font-weight: 700; }
.reach-orbit-hub__sub { margin: 0.15rem 0 0; font-size: 0.78rem; max-width: 11rem; text-align: center; }
.reach-orbit-hub__cta { margin-top: 0.15rem; }
.reach-orbit-hub__disc--sample {
  background: radial-gradient(circle at 30% 25%, #7ec8ff, #4f8cff 45%, #1a3a7a);
  box-shadow: 0 0 0 3px rgba(216, 183, 91, 0.35), 0 12px 40px rgba(79, 140, 255, 0.35);
}
.section-lede { margin: -0.35rem 0 0.85rem; max-width: 36rem; }
.reach-orbit-scene--demos {
  --ym-orbit-r: clamp(160px, 38vmin, 240px);
  margin-bottom: 0.5rem;
}
@supports (width: 1cqmin) {
  .reach-orbit-scene--demos {
    --ym-orbit-r: min(40cqmin, 240px);
  }
}
.reach-orbit-nodes {
  position: absolute;
  inset: 0;
  pointer-events: none;
}
.reach-orbit-node.demo-org .reach-orbit-node__disc {
  font-size: 0.85rem;
  font-weight: 700;
  letter-spacing: 0.02em;
}
.reach-orbit-node.demo-org.active .reach-orbit-node__disc {
  box-shadow: 0 0 0 3px var(--accent), 0 8px 24px rgba(53, 211, 167, 0.35);
}
.reach-orbit-node.demo-org .reach-orbit-node__status { color: var(--muted); }
.reach-orbit-node {
  position: absolute;
  top: 50%;
  left: 50%;
  width: 5.6rem;
  margin: 0;
  /* Place on ring via angle + radius (length), then un-rotate label. */
  transform:
    translate(-50%, -50%)
    rotate(var(--ym-angle, 0deg))
    translateY(calc(-1 * var(--ym-orbit-r)))
    rotate(calc(var(--ym-angle, 0deg) * -1));
  z-index: 2;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.25rem;
  background: transparent;
  border: none;
  padding: 0;
  color: var(--ink);
  cursor: pointer;
  pointer-events: auto;
}
.reach-orbit-node__disc {
  width: 3rem;
  height: 3rem;
  border-radius: 50%;
  display: grid;
  place-items: center;
  font-size: 1.05rem;
  color: #fff;
  border: 2px solid rgba(255, 255, 255, 0.35);
  box-shadow: 0 8px 20px rgba(3, 7, 20, 0.4);
}
.reach-orbit-node.connected .reach-orbit-node__disc {
  box-shadow: 0 0 0 3px rgba(53, 211, 167, 0.45), 0 8px 20px rgba(3, 7, 20, 0.4);
}
.reach-orbit-node.warn .reach-orbit-node__disc {
  box-shadow: 0 0 0 3px rgba(240, 185, 77, 0.5), 0 8px 20px rgba(3, 7, 20, 0.4);
}
.reach-orbit-node.disconnected .reach-orbit-node__disc { opacity: 0.55; }
.reach-orbit-node__label {
  font-size: 0.68rem;
  font-weight: 600;
  text-align: center;
  line-height: 1.2;
  max-width: 5.5rem;
  color: var(--muted);
}
.reach-orbit-node__status {
  font-size: 0.62rem;
  color: var(--muted-2);
}
.reach-orbit-node.connected .reach-orbit-node__status { color: var(--ok); }
.reach-orbit-node.warn .reach-orbit-node__status { color: var(--warn); }
.reach-orbit-legend {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem 1.1rem;
  justify-content: center;
  margin: -0.5rem 0 1.5rem;
  font-size: 0.78rem;
  color: var(--muted);
}
.reach-orbit-legend span::before {
  content: "";
  display: inline-block;
  width: 0.55rem;
  height: 0.55rem;
  border-radius: 50%;
  margin-right: 0.35rem;
  vertical-align: middle;
  background: var(--muted-2);
}
.reach-orbit-legend .ok::before { background: var(--ok); }
.reach-orbit-legend .warn::before { background: var(--warn); }

@media (max-width: 720px) {
  .reach-orbit-scene {
    aspect-ratio: auto;
    max-height: none;
    height: auto;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1rem;
    padding: 0.5rem 0 1rem;
    container-type: normal;
  }
  .reach-orbit-scene__glow,
  .reach-orbit-ring { display: none; }
  .reach-orbit-hub {
    position: relative;
    top: auto;
    left: auto;
    transform: none;
    width: 100%;
  }
  .reach-orbit-nodes {
    position: relative;
    inset: auto;
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 0.65rem;
    width: 100%;
    pointer-events: auto;
  }
  .reach-orbit-node {
    position: relative;
    top: auto;
    left: auto;
    margin: 0;
    transform: none;
    width: auto;
    flex-direction: row;
    gap: 0.55rem;
    padding: 0.65rem 0.75rem;
    border-radius: var(--radius-md);
    border: 1px solid var(--border);
    background: rgba(16, 29, 58, 0.55);
    justify-content: flex-start;
  }
  .reach-orbit-node__label { text-align: left; max-width: none; font-size: 0.8rem; color: var(--ink); }
}

/* Publishing outward pulse */
.ym-publish-pulse {
  position: absolute;
  inset: 30%;
  border-radius: 50%;
  border: 2px solid rgba(53, 211, 167, 0.55);
  animation: ym-pulse-out 1.1s ease-out infinite;
  pointer-events: none;
  z-index: 1;
}
@keyframes ym-pulse-out {
  from { transform: scale(0.55); opacity: 0.85; }
  to { transform: scale(1.65); opacity: 0; }
}

.channel-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(230px, 1fr));
  gap: 0.9rem;
  margin-bottom: 1.5rem;
}
.channel-card {
  padding: 1rem 1.1rem;
  border-radius: var(--radius-lg);
  display: grid;
  gap: 0.55rem;
}
.channel-card .ch-head { display: flex; align-items: center; gap: 0.65rem; }
.channel-icon {
  width: 2.35rem; height: 2.35rem; border-radius: 50%;
  display: grid; place-items: center; font-size: 1.05rem; flex: none;
  color: #fff;
}
.channel-card h4 { margin: 0; font-size: 0.98rem; flex: 1; }
.channel-card .ch-account { color: var(--muted); font-size: 0.8rem; margin: 0; }
.channel-card button { width: 100%; }

/* ---------- Orbit stepper ---------- */

.orbit-stepper {
  position: relative;
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 0;
  margin: 0.5rem 0 2rem;
  padding: 1.5rem 0.5rem;
}
.orbit-track {
  position: absolute;
  left: 5%; right: 5%; top: 50%;
  height: 2px;
  background: linear-gradient(90deg, var(--border), var(--border));
  transform: translateY(-50%);
  z-index: 0;
  border-radius: 2px;
}
.orbit-track .orbit-fill {
  height: 100%;
  background: linear-gradient(90deg, var(--accent), var(--primary), var(--accent-2));
  border-radius: 2px;
  transition: width 0.4s ease;
}
.orbit-nodes {
  position: relative;
  z-index: 1;
  display: flex;
  justify-content: space-between;
  width: 100%;
}
.orbit-node {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.5rem;
  background: transparent;
  border: none;
  padding: 0;
  color: var(--muted);
  cursor: default;
  flex: 1;
}
.orbit-node.clickable { cursor: pointer; }
.orbit-node .orbit-dot {
  width: 2.9rem; height: 2.9rem;
  border-radius: 50%;
  display: grid; place-items: center;
  font-size: 1.05rem;
  border: 2px solid var(--border-strong);
  background: var(--bg-panel);
  box-shadow: var(--shadow-soft);
  transition: all 0.2s ease;
}
.orbit-node.done .orbit-dot { background: linear-gradient(135deg, var(--accent), var(--primary)); border-color: transparent; color: #04150c; }
.orbit-node.active .orbit-dot {
  background: linear-gradient(135deg, var(--primary), var(--accent-2));
  border-color: rgba(255,255,255,0.5);
  color: #fff;
  box-shadow: 0 0 0 6px rgba(79, 140, 255, 0.18), var(--shadow-lift);
}
.orbit-node .orbit-label { font-size: 0.82rem; font-weight: 600; }
.orbit-node.active .orbit-label, .orbit-node.done .orbit-label { color: var(--ink); }

@media (max-width: 640px) {
  .orbit-node .orbit-label { font-size: 0.68rem; max-width: 4.2rem; line-height: 1.15; }
}

/* ---------- Create: intent cards ---------- */

.intent-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
  gap: 0.75rem;
  margin-bottom: 0.75rem;
}
.ym-biz-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(140px, 1fr));
  gap: 0.65rem;
  margin-bottom: 1.35rem;
}
.ym-biz-card {
  padding: 0.9rem 0.85rem;
  border-radius: var(--radius-lg);
  text-align: left;
  cursor: pointer;
  border: 1px solid var(--border);
  background: rgba(255, 255, 255, 0.04);
}
.ym-biz-card strong { display: block; font-size: 0.95rem; }
.ym-biz-card span { display: block; margin-top: 0.25rem; color: var(--muted); font-size: 0.78rem; }
.ym-biz-card.selected {
  border-color: rgba(79, 140, 255, 0.75);
  box-shadow: 0 0 0 1px rgba(79, 140, 255, 0.35);
  background: rgba(79, 140, 255, 0.12);
}
.ym-intent-helper { margin: 0 0 1rem; min-height: 1.2em; }
.intent-card {
  padding: 1.1rem 1rem;
  border-radius: var(--radius-lg);
  display: grid;
  gap: 0.5rem;
  text-align: left;
  cursor: pointer;
}
.intent-card .ii { width: 2.5rem; height: 2.5rem; border-radius: 50%; display: grid; place-items: center; font-size: 1.2rem; background: rgba(79, 140, 255, 0.14); }
.intent-card h4 { margin: 0; font-size: 0.98rem; }
.intent-card p { margin: 0; color: var(--muted); font-size: 0.82rem; }
.intent-card.selected {
  border-color: var(--primary);
  background: linear-gradient(135deg, rgba(79, 140, 255, 0.16), rgba(143, 123, 255, 0.14));
  box-shadow: 0 0 0 2px rgba(79, 140, 255, 0.35);
}

.brief-panel { padding: 1.3rem; border-radius: var(--radius-lg); margin-bottom: 1.25rem; }
.brief-panel textarea { min-height: 7rem; resize: vertical; }
.upload-row { display: flex; align-items: center; gap: 0.75rem; flex-wrap: wrap; margin-top: 0.5rem; }
.upload-thumb { width: 3.4rem; height: 3.4rem; border-radius: var(--radius-sm); object-fit: cover; border: 1px solid var(--border); }

.generated-panel { padding: 1.3rem; border-radius: var(--radius-lg); margin-bottom: 1.25rem; display: grid; gap: 0.75rem; }
.ym-polish-workspace {
  display: grid;
  gap: 1.25rem;
  align-items: start;
}
@media (min-width: 900px) {
  .ym-polish-workspace {
    grid-template-columns: minmax(0, 1.05fr) minmax(0, 0.95fr);
    gap: 1.5rem;
  }
}
.ym-polish-copy { display: grid; gap: 0.65rem; }
.ym-polish-preview .ym-fb-post { max-width: none; }
.ym-fb-post__caption-preview {
  margin: 0;
  white-space: pre-wrap;
  color: var(--ink);
  font-size: 0.95rem;
  line-height: 1.45;
}
.ym-channel-crop-hint { font-size: 0.8rem; }
.generated-panel textarea { min-height: 6rem; }
.ym-caption-label {
  display: block;
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--text, #e8eefc);
  margin-top: 0.15rem;
}
.ym-caption-edit {
  width: 100%;
  min-height: 7rem;
  resize: vertical;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  background: rgba(255, 255, 255, 0.08);
  color: inherit;
  padding: 0.75rem 0.85rem;
  font: inherit;
  line-height: 1.45;
}
.ym-caption-edit:focus {
  outline: 2px solid rgba(79, 140, 255, 0.55);
  outline-offset: 1px;
  border-color: rgba(79, 140, 255, 0.7);
}
#generatedTuneRow { flex-wrap: wrap; gap: 0.45rem; }
#generatedTuneRow button:disabled { opacity: 0.55; cursor: wait; }
.ym-fb-post {
  display: grid;
  gap: 0.75rem;
  padding: 1rem;
  border-radius: var(--radius-md);
  border: 1px solid var(--border);
  background: rgba(255, 255, 255, 0.04);
  max-width: 36rem;
}
.ym-fb-post__head { display: flex; align-items: center; gap: 0.7rem; }
.ym-fb-post__avatar {
  width: 2.4rem; height: 2.4rem; border-radius: 50%;
  display: grid; place-items: center; font-weight: 700; font-size: 0.85rem;
  background: linear-gradient(145deg, var(--accent), var(--primary)); color: var(--primary-ink);
}
.ym-fb-post__org { font-weight: 700; }
.ym-fb-post__meta { font-size: 0.78rem; color: var(--muted); }
.ym-fb-post__media {
  position: relative;
  display: block;
  width: 100%;
  padding: 0;
  border: none;
  border-radius: var(--radius-md);
  overflow: hidden;
  cursor: zoom-in;
  background: #0a1224;
}
.ym-fb-post__media img {
  display: block;
  width: 100%;
  aspect-ratio: 16 / 9;
  object-fit: contain;
  background: #0a1224;
}
.ym-fb-post__zoom {
  position: absolute;
  right: 0.65rem;
  bottom: 0.65rem;
  padding: 0.3rem 0.6rem;
  border-radius: 999px;
  background: rgba(3, 7, 20, 0.72);
  color: #eef3ff;
  font-size: 0.75rem;
  font-weight: 600;
}
.ym-flyer-lightbox {
  border: none;
  border-radius: var(--radius-lg);
  padding: 0;
  max-width: min(960px, 96vw);
  width: 96vw;
  background: #070d1b;
  color: var(--ink);
}
.ym-flyer-lightbox::backdrop { background: rgba(3, 7, 20, 0.72); }
.ym-flyer-lightbox__bar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 1rem;
  padding: 0.75rem 1rem;
  border-bottom: 1px solid var(--border);
}
.ym-flyer-lightbox img {
  display: block;
  width: 100%;
  max-height: 80vh;
  object-fit: contain;
  background: #000;
}
.tune-row button { font-size: 0.8rem; }
.hashtag-pill-row { display: flex; gap: 0.4rem; flex-wrap: wrap; }
.hashtag-pill { background: rgba(53, 211, 167, 0.14); color: var(--accent); border-radius: 999px; padding: 0.15rem 0.6rem; font-size: 0.78rem; }

/* ---------- Create: channel selector ---------- */

.channel-select-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(210px, 1fr));
  gap: 0.85rem;
  margin-bottom: 1.25rem;
}
.channel-select-card {
  padding: 1rem;
  border-radius: var(--radius-lg);
  display: grid;
  gap: 0.5rem;
  text-align: left;
  cursor: pointer;
  position: relative;
}
.channel-select-card.picked {
  border-color: var(--accent);
  background: linear-gradient(135deg, rgba(53, 211, 167, 0.16), rgba(79, 140, 255, 0.1));
}
.channel-select-card.locked { cursor: default; opacity: 0.72; }
.channel-select-card .cs-check {
  position: absolute; top: 0.8rem; right: 0.8rem;
  width: 1.3rem; height: 1.3rem; border-radius: 50%;
  border: 2px solid var(--border-strong);
  display: grid; place-items: center; font-size: 0.7rem; color: transparent;
}
.channel-select-card.picked .cs-check { background: var(--accent); border-color: var(--accent); color: #04150c; }
.channel-select-card h4 { margin: 0.2rem 0 0; font-size: 0.95rem; }
.channel-select-card p { margin: 0; font-size: 0.78rem; color: var(--muted); }

/* ---------- Preview gallery ---------- */

.preview-tabs { display: flex; gap: 0.4rem; overflow-x: auto; margin-bottom: 1rem; padding-bottom: 0.2rem; }
.preview-tab {
  flex: none;
  border-radius: 999px;
  padding: 0.5rem 1rem;
  font-size: 0.85rem;
  color: var(--muted);
}
.preview-tab.active { color: #fff; background: linear-gradient(135deg, var(--primary), var(--accent-2)); border-color: transparent; }

.preview-card {
  padding: 1.3rem;
  border-radius: var(--radius-lg);
  display: grid;
  gap: 0.9rem;
  max-width: 34rem;
}
.preview-card .pc-head { display: flex; align-items: center; gap: 0.6rem; }
.preview-card .pc-org { font-weight: 700; font-size: 0.95rem; }
.preview-card .pc-flyer {
  width: 100%;
  aspect-ratio: 16 / 9;
  height: auto;
  border-radius: var(--radius-md);
  object-fit: contain;
  background: #0a1224;
  display: block;
}
.preview-card textarea { min-height: 8rem; }
.preview-warn { font-size: 0.78rem; color: var(--warn); }
.preview-card-actions { display: flex; gap: 0.5rem; flex-wrap: wrap; }

/* ---------- Publish summary & results ---------- */

.publish-summary { padding: 1.4rem; border-radius: var(--radius-lg); margin-bottom: 1.25rem; display: grid; gap: 0.6rem; }
.publish-summary .ps-row { display: flex; justify-content: space-between; gap: 1rem; font-size: 0.92rem; border-bottom: 1px solid var(--border); padding-bottom: 0.5rem; }
.publish-summary .ps-row:last-child { border-bottom: none; padding-bottom: 0; }
.publish-summary .ps-row span:first-child { color: var(--muted); }

.result-row-list { list-style: none; margin: 0 0 1rem; padding: 0; display: grid; gap: 0.5rem; }
.result-row {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  padding: 0.75rem 1rem;
  border-radius: var(--radius-md);
  border: 1px solid var(--border);
  background: rgba(16, 29, 58, 0.55);
}
.result-row .rr-icon {
  width: 2.1rem; height: 2.1rem; border-radius: 50%;
  display: grid; place-items: center; font-size: 1rem; flex: none; color: #fff;
}
.result-row.published .rr-icon { background: var(--ok); color: #04150c; }
.result-row.failed .rr-icon { background: var(--danger); }
.result-row.pending .rr-icon { background: var(--warn); color: #241a02; }
.result-row .rr-body { flex: 1; }
.result-row .rr-title { font-weight: 600; font-size: 0.92rem; }
.result-row .rr-msg { color: var(--muted); font-size: 0.82rem; }

.publish-outcome-banner {
  padding: 1rem 1.25rem;
  border-radius: var(--radius-lg);
  margin-bottom: 1.1rem;
  font-weight: 600;
  display: flex;
  align-items: center;
  gap: 0.7rem;
}
.publish-outcome-banner.success { background: rgba(53, 211, 167, 0.14); border: 1px solid rgba(53, 211, 167, 0.4); color: var(--ok); }
.publish-outcome-banner.partial { background: rgba(240, 185, 77, 0.14); border: 1px solid rgba(240, 185, 77, 0.4); color: var(--warn); }
.publish-outcome-banner.failed { background: rgba(255, 107, 129, 0.14); border: 1px solid rgba(255, 107, 129, 0.4); color: var(--danger); }

/* ---------- Sticky create-flow footer (mobile CTA) ---------- */

.flow-footer {
  display: flex;
  justify-content: space-between;
  gap: 0.75rem;
  margin-top: 1.5rem;
}
@media (max-width: 720px) {
  .flow-footer {
    position: sticky;
    bottom: calc(4.4rem + env(safe-area-inset-bottom));
    background: rgba(9, 15, 32, 0.92);
    backdrop-filter: blur(8px);
    padding: 0.75rem;
    border-radius: var(--radius-lg);
    border: 1px solid var(--border);
    z-index: 30;
  }
}

/* ---------- Published timeline ---------- */

.filter-row { display: flex; gap: 0.6rem; flex-wrap: wrap; margin-bottom: 1.25rem; }
.filter-row select, .filter-row input { width: auto; min-width: 9rem; }

.published-list { display: grid; gap: 0.9rem; }
.published-card {
  padding: 1.1rem 1.3rem;
  border-radius: var(--radius-lg);
  display: grid;
  grid-template-columns: 4.5rem 1fr;
  gap: 1rem;
  cursor: pointer;
}
.published-card .pub-thumb {
  width: 4.5rem; height: 4.5rem; border-radius: var(--radius-md);
  background: linear-gradient(135deg, rgba(79,140,255,0.22), rgba(143,123,255,0.22));
  display: grid; place-items: center; font-size: 1.4rem; color: var(--muted); object-fit: cover;
}
.published-card .pub-title { margin: 0 0 0.2rem; font-size: 1rem; }
.published-card .pub-excerpt { margin: 0 0 0.5rem; color: var(--muted); font-size: 0.88rem; }
.published-card .pub-meta { display: flex; gap: 0.5rem; flex-wrap: wrap; font-size: 0.78rem; color: var(--muted-2); align-items: center; }
.published-card .pub-channels { display: flex; gap: 0.3rem; flex-wrap: wrap; }
.published-detail { margin-top: 0.75rem; padding-top: 0.75rem; border-top: 1px solid var(--border); grid-column: 1 / -1; }

/* ---------- Analytics ---------- */

.metric-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
  gap: 1rem;
  margin-bottom: 1.5rem;
}
.metric-card { padding: 1.2rem; border-radius: var(--radius-lg); text-align: left; }
.metric-card .metric-value { font-size: 1.9rem; font-weight: 700; display: block; font-family: var(--font-display); }
.metric-card .metric-label { color: var(--muted); font-size: 0.85rem; }

/* ---------- Settings ---------- */

.settings-section { padding: 1.3rem 1.4rem; border-radius: var(--radius-lg); margin-bottom: 1.25rem; }
.settings-section h2 { margin: 0 0 0.3rem; font-size: 1.1rem; }
.settings-section > p.muted { margin: 0 0 1rem; }
.field-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 0.85rem; }
.field-grid .full { grid-column: 1 / -1; }
.color-row { display: flex; gap: 0.75rem; align-items: end; }
.color-row input[type="color"] { width: 3rem; height: 2.5rem; padding: 0.2rem; }
.tone-pills { display: flex; gap: 0.5rem; flex-wrap: wrap; }
.tone-pill { border-radius: 999px; padding: 0.4rem 0.9rem; font-size: 0.85rem; }
.tone-pill.selected { background: linear-gradient(135deg, var(--primary), var(--accent-2)); color: #fff; border-color: transparent; }

.settings-channel-row {
  display: flex; align-items: center; gap: 0.9rem;
  padding: 0.85rem 0; border-bottom: 1px solid var(--border);
}
.settings-channel-row:last-child { border-bottom: none; }
.settings-channel-row .sc-info { flex: 1; min-width: 0; }
.settings-channel-row .sc-info strong { display: block; font-size: 0.95rem; }
.settings-channel-row .sc-info span { color: var(--muted); font-size: 0.82rem; }
.settings-channel-row .sc-actions { display: flex; gap: 0.4rem; flex: none; }
.tech-details { margin-top: 0.5rem; font-size: 0.78rem; color: var(--muted-2); }
.tech-details code { background: rgba(0,0,0,0.25); padding: 0.05rem 0.35rem; border-radius: 4px; }

.connect-explainer { font-size: 0.88rem; color: var(--muted); margin: 0 0 0.9rem; line-height: 1.5; }
.connect-key-disclosure { border: 1px dashed var(--border); border-radius: var(--radius-md); padding: 0.7rem 0.9rem; margin-top: 0.4rem; }
.connect-key-disclosure summary { font-size: 0.85rem; }

.who-card { display: flex; align-items: center; gap: 0.85rem; }
.who-card .org-avatar { width: 2.6rem; height: 2.6rem; font-size: 0.85rem; }

/* ---------- Toast ---------- */

.toast-stack {
  position: fixed;
  right: 1.25rem;
  bottom: 1.25rem;
  z-index: 200;
  display: grid;
  gap: 0.5rem;
  max-width: 22rem;
}
.toast {
  padding: 0.8rem 1rem;
  border-radius: var(--radius-md);
  background: var(--bg-panel);
  border: 1px solid var(--border-strong);
  box-shadow: var(--shadow-soft);
  font-size: 0.88rem;
  animation: toast-in 0.2s ease;
}
.toast.error { border-color: rgba(255, 107, 129, 0.5); }
.toast.success { border-color: rgba(53, 211, 167, 0.5); }
@keyframes toast-in { from { opacity: 0; transform: translateY(6px); } to { opacity: 1; transform: translateY(0); } }

/* ---------- Loading ---------- */

.spinner {
  width: 1.1rem; height: 1.1rem; border-radius: 50%;
  border: 2px solid rgba(255,255,255,0.35);
  border-top-color: #fff;
  display: inline-block;
  animation: spin 0.7s linear infinite;
}
@keyframes spin { to { transform: rotate(360deg); } }

.ym-variation-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 0.55rem;
  margin: 0.85rem 0 0.5rem;
}
.ym-variation-card {
  appearance: none;
  border: 2px solid transparent;
  border-radius: 50%;
  padding: 0;
  overflow: hidden;
  aspect-ratio: 1;
  cursor: pointer;
  background: rgba(255,255,255,0.06);
  transition: border-color 0.2s ease, transform 0.2s ease;
}
.ym-variation-card img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}
.ym-variation-card:hover { transform: scale(1.03); }
.ym-variation-card.is-selected {
  border-color: #e8a838;
  box-shadow: 0 0 0 2px rgba(232, 168, 56, 0.35);
}
.ym-variation-card.is-loading {
  animation: ym-var-pulse 1.1s ease-in-out infinite;
}
@keyframes ym-var-pulse {
  0%, 100% { opacity: 0.45; }
  50% { opacity: 0.9; }
}
@media (max-width: 720px) {
  .ym-variation-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

/* ---------- Responsive ---------- */

@media (max-width: 900px) {
  .quick-actions { grid-template-columns: 1fr 1fr; }
}

@media (max-width: 720px) {
  .primary-nav { display: none; }
  .bottom-nav { display: flex; }
  .main { padding-bottom: 5.5rem; }
  .quick-actions { grid-template-columns: 1fr; }
  .dashboard-hero { flex-direction: column; align-items: flex-start; }
  .field-grid { grid-template-columns: 1fr; }
  .published-card { grid-template-columns: 3.6rem 1fr; }
}

@media (max-width: 480px) {
  .app-header { padding: 0.6rem 0.85rem; }
  .org-switcher .org-name { max-width: 6.5rem; }
  .login-panel { padding: 1.6rem 1.3rem; }
}
