/* Shared public-home and signed-in-home identity. Session controls stay scoped to app.css. */
:root {
  --brand-bg: #071f1a;
  --brand-cream: #fff6e5;
  --brand-muted: rgba(255,246,229,.72);
  --brand-green: #37d59b;
  --brand-gold: #d9b86c;
  --brand-line: rgba(255,255,255,.13);
}
.brand-header .logo,
.brand-header.home-mode .brand-mark {
  width:44px; height:44px; flex:0 0 44px; border-radius:16px;
  display:grid; place-items:center; color:var(--brand-gold); font-size:27px; font-weight:800;
  background:linear-gradient(145deg,rgba(255,255,255,.14),rgba(255,255,255,.04));
  border:1px solid rgba(255,255,255,.18);
  box-shadow:inset 0 1px 0 rgba(255,255,255,.18),0 14px 36px rgba(0,0,0,.25);
}
.brand-header.home-mode .brand-mark::before { content:'÷'; position:static; background:none; color:var(--brand-gold); transform:none; }
.brand-header.home-mode .brand-mark::after { display:none; }
.brand-header.home-mode {
  position:sticky !important; flex-shrink:0;
  height:74px; padding:0 max(20px, calc((100% - 1180px) / 2));
  background:rgba(7,31,26,.94) !important;
  border-bottom:1px solid var(--brand-line); box-shadow:none;
}
.brand-header.home-mode::before,.brand-header.home-mode::after { display:none; }
.brand-header.home-mode .topbar-logo { justify-content:flex-start; flex:0 1 auto; gap:12px; min-width:0; }
.brand-header.home-mode .topbar-brand > span { font-size:20px; line-height:1; color:var(--brand-cream); letter-spacing:-.04em; }
.brand-header.home-mode .topbar-brand small#topbarSub { font-size:12px !important; color:var(--brand-muted) !important; text-transform:none; font-weight:500 !important; }
.brand-header.home-mode .topbar-brand-mark { color:var(--brand-gold); }
.brand-header.home-mode .auth-btn-wrap {
  width:44px; height:44px; min-height:44px; border-radius:14px;
  background:rgba(255,255,255,.07); border:1px solid var(--brand-line); color:var(--brand-cream);
}
.header-credits { min-height:44px; padding:0 15px; border:1px solid var(--brand-line); border-radius:999px; color:var(--brand-cream); font-size:13px; font-weight:600; background:rgba(255,255,255,.06); }
.header-credits[hidden] { display:none; }
.view[data-view="home"].on.dashboard-view {
  background:radial-gradient(circle at 10% 0,rgba(55,213,155,.13),transparent 40%),radial-gradient(circle at 100% 0,rgba(217,184,108,.1),transparent 35%),var(--brand-bg) !important;
  color:var(--brand-cream); min-height:calc(100dvh - 74px); padding:0;
}
.main-content.dashboard-main { padding-bottom:0 !important; }
.dashboard-shell { width:min(1180px, calc(100% - 40px)); margin:0 auto; padding:44px 0 max(28px, env(safe-area-inset-bottom)); }
.dashboard-welcome { margin-bottom:28px; }
.dashboard-kicker { color:var(--brand-gold); text-transform:uppercase; letter-spacing:.12em; font-size:11px; font-weight:700; margin-bottom:12px; }
.dashboard-welcome h1 { font-size:clamp(28px,4vw,44px); line-height:1.16; letter-spacing:-.045em; overflow-wrap:anywhere; }
.dashboard-welcome p { margin-top:12px; color:var(--brand-muted); font-size:14px; line-height:1.7; }
.dashboard-start { display:grid; grid-template-columns:minmax(0,1.8fr) minmax(0,1fr); grid-template-areas:'action credit' 'recents recents'; gap:22px; }
.dashboard-action-card { grid-area:action; }
.dashboard-credit-card { grid-area:credit; }
.dashboard-recents { grid-area:recents; min-width:0; }
.dashboard-action-card,.dashboard-credit-card { border:1px solid var(--brand-line); border-radius:26px; padding:30px; background:rgba(255,255,255,.05); }
.dashboard-action-card { background:linear-gradient(125deg,rgba(55,213,155,.13),rgba(255,255,255,.03)); }
.dashboard-icon { display:grid; place-items:center; width:46px; height:46px; border:1px solid rgba(55,213,155,.3); border-radius:15px; background:rgba(55,213,155,.12); color:var(--brand-green); margin-bottom:22px; }
.dashboard-action-card h2 { font-size:clamp(22px,2.5vw,28px); line-height:1.25; letter-spacing:-.035em; }
.dashboard-action-card p,.dashboard-credit-card p { font-size:13px; color:var(--brand-muted); line-height:1.7; margin:12px 0 22px; }
.dashboard-actions { display:flex; flex-wrap:wrap; gap:12px; }
.brand-button,.dashboard-shell .home-recents-link { display:inline-flex; align-items:center; justify-content:center; gap:10px; min-height:48px; padding:12px 20px; border:1px solid var(--brand-line); border-radius:999px; background:rgba(255,255,255,.07); color:var(--brand-cream); font:600 13px 'Sora',system-ui,sans-serif; cursor:pointer; text-decoration:none; }
.view[data-view="home"].on .dashboard-shell .brand-primary { width:auto; margin:0; min-height:48px; border:0; border-radius:999px; background:linear-gradient(135deg,var(--brand-green),#16aa77); color:#031711; box-shadow:0 12px 30px rgba(55,213,155,.12); }
.dashboard-shell .brand-primary span { color:inherit; }
.brand-button:hover,.dashboard-shell .home-recents-link:hover,.header-credits:hover { filter:brightness(1.12); }
.brand-button:focus-visible,.dashboard-shell button:focus-visible,.brand-header button:focus-visible,.dashboard-footer a:focus-visible { outline:3px solid var(--brand-gold); outline-offset:4px; }
.dashboard-credit-card { display:flex; flex-direction:column; align-items:flex-start; }
.dashboard-balance { font-size:52px; line-height:1.1; letter-spacing:-.05em; color:var(--brand-cream); }
.dashboard-credit-card > span { font-size:13px; color:var(--brand-muted); margin-top:5px; }
.dashboard-credit-card .brand-button { margin-top:auto; }
.dashboard-shell .home-recents { margin:14px 0 0; padding:0; max-width:none; }
.dashboard-shell .home-recents-head { margin-bottom:18px; align-items:center; }
.dashboard-shell .home-recents-kicker { color:var(--brand-muted); margin-bottom:7px; }
.dashboard-shell .home-recents h3 { font-size:22px; color:var(--brand-cream); letter-spacing:-.035em; }
.view[data-view="home"].on .dashboard-shell .home-recents-list { display:grid; grid-template-columns:repeat(2,minmax(0,1fr)); gap:12px; }
.dashboard-shell .home-recent-card { min-width:0; padding:20px; border-radius:20px; border-color:var(--brand-line); background:rgba(255,255,255,.045); backdrop-filter:none; }
.dashboard-shell .home-recent-card:hover { background:rgba(255,255,255,.08); border-color:rgba(55,213,155,.4); }
.dashboard-shell .home-recent-title,.dashboard-shell .home-recent-side strong { color:var(--brand-cream); }
.dashboard-shell .home-recent-side span { color:var(--brand-green); font-size:11px; }
.dashboard-shell .home-recent-meta { font-size:11px; }
.dashboard-shell .home-recent-code { font-size:11px; color:var(--brand-muted); }
.dashboard-empty { padding:28px; margin-top:18px; border:1px dashed var(--brand-line); border-radius:22px; font-size:14px; line-height:1.7; color:var(--brand-muted); }
.dashboard-empty > i { display:block; font-size:22px; color:var(--brand-gold); margin-bottom:12px; }
.dashboard-empty strong { display:block; color:var(--brand-cream); font-size:17px; margin-bottom:6px; }
.dashboard-footer { display:flex; justify-content:space-between; gap:20px; margin-top:42px; padding-top:20px; border-top:1px solid var(--brand-line); color:var(--brand-muted); font-size:12px; }
.dashboard-footer a { padding:10px 0; margin-top:-10px; color:var(--brand-muted); }
@media(max-width:680px) {
  .brand-header.home-mode { padding:0 16px; height:70px; gap:8px; }
  .brand-header.home-mode .topbar-logo { gap:9px; }
  .brand-header.home-mode .topbar-spacer { min-width:0; }
  .header-credits { padding:0 11px; font-size:12px; }
  .dashboard-shell { width:calc(100% - 32px); padding-top:28px; }
  .dashboard-welcome { margin-bottom:22px; }
  .dashboard-start { grid-template-columns:minmax(0,1fr); grid-template-areas:'action' 'recents' 'credit'; gap:20px; }
  .dashboard-action-card,.dashboard-credit-card { padding:22px; border-radius:22px; }
  .dashboard-icon { display:none; }
  .dashboard-actions { flex-direction:column; }
  .dashboard-actions .brand-button,.view[data-view="home"].on .dashboard-shell .brand-primary { width:100%; }
  .dashboard-credit-card { display:grid; grid-template-columns:auto minmax(0,1fr); column-gap:12px; align-items:center; }
  .dashboard-credit-card .dashboard-kicker { grid-column:1 / -1; margin-bottom:8px; }
  .dashboard-balance { font-size:36px; }
  .dashboard-credit-card > span { margin:0; }
  .dashboard-credit-card p { grid-column:1 / -1; margin:10px 0 14px; }
  .dashboard-credit-card .brand-button { grid-column:1 / -1; justify-self:start; }
  .view[data-view="home"].on .dashboard-shell .home-recents-list { grid-template-columns:minmax(0,1fr); }
  .dashboard-shell .home-recents { margin-top:8px; }
  .dashboard-shell .home-recents-head { gap:10px; }
  .dashboard-shell .home-recents h3 { font-size:20px; }
  .dashboard-shell .home-recents-link { padding:10px 14px; font-size:12px; white-space:nowrap; }
  .dashboard-shell .home-recent-card { padding:16px; gap:10px; }
}
@media(prefers-reduced-motion:reduce) {
  .dashboard-shell *, .brand-header.home-mode * { animation:none !important; transition:none !important; }
}
