/* Hermit design v2: underdog.ai-style structure, Hermit's own purple, crab and Monet coast */
:root {
  --bg: #FFFFFF;
  --bg-2: #F7F7F9;
  --surface: #FFFFFF;
  --ink: #1F1E24;
  --ink-2: #5E5C68;
  --ink-3: #9593A0;
  --line: #ECEBF0;
  --line-2: #DCDAE3;
  --purple: #4D1D95;
  --purple-hover: #3F1680;
  --purple-t: #4D1D95;
  --purple-wash: #F3EEFC;
  --on-purple: #FFFFFF;
  --ok: #2F8F5B;
  --glow-a: rgba(186, 160, 240, .35);
  --glow-b: rgba(160, 205, 235, .30);
  --glow-c: rgba(250, 205, 180, .30);
  --focus: 0 0 0 3px rgba(77, 29, 149, .25);
  --sans: 'Geist', system-ui, sans-serif;
  --serif: 'Newsreader', Georgia, serif;
  --mono: 'Geist Mono', ui-monospace, monospace;
  color-scheme: light;
}
:root[data-theme="dark"] {
  --bg: #0F0E12;
  --bg-2: #16141B;
  --surface: #1A1820;
  --ink: #F4F3F7;
  --ink-2: #ADAAB8;
  --ink-3: #75727F;
  --line: #25232C;
  --line-2: #34313D;
  --purple: #6B38C7;
  --purple-hover: #7A47D6;
  --purple-t: #C0A6F5;
  --purple-wash: #1F1830;
  --ok: #62C892;
  --glow-a: rgba(120, 80, 200, .22);
  --glow-b: rgba(60, 110, 160, .16);
  --glow-c: rgba(160, 90, 120, .12);
  --focus: 0 0 0 3px rgba(192, 166, 245, .35);
  color-scheme: dark;
}
* { box-sizing: border-box; }
html, body { margin: 0; }
html { scroll-behavior: smooth; }
body { background: var(--bg); color: var(--ink); font: 400 16.5px/1.55 var(--sans); -webkit-font-smoothing: antialiased; font-variant-numeric: tabular-nums; }
a { color: inherit; }
button, input { font: inherit; color: inherit; }
:focus-visible { outline: none; box-shadow: var(--focus); border-radius: 12px; }
em.s { font-family: var(--serif); font-style: italic; font-weight: 400; letter-spacing: -.01em; }
.mark { display: block; fill: none; stroke: currentColor; stroke-width: 9; stroke-linecap: round; stroke-linejoin: round; }

/* pills */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 10px; height: 52px; padding: 0 26px; border-radius: 99px; border: 0; cursor: pointer;
  background: var(--purple); color: #fff; font-weight: 500; font-size: 16.5px; text-decoration: none; white-space: nowrap;
  box-shadow: 0 10px 30px -10px rgba(77, 29, 149, .55); transition: background .2s, transform .2s cubic-bezier(.2, .8, .2, 1), box-shadow .2s; }
.btn:hover { background: var(--purple-hover); box-shadow: 0 14px 36px -10px rgba(77, 29, 149, .65); }
.btn:active { transform: scale(.98); }
.btn svg { width: 16px; height: 16px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; transition: transform .25s; }
.btn:hover svg { transform: translateX(2px); }
.btn.ghost { background: var(--surface); color: var(--ink); box-shadow: inset 0 0 0 1px var(--line-2); }
.btn.ghost:hover { background: var(--bg-2); }
.btn.sm { height: 40px; padding: 0 18px; font-size: 15px; gap: 8px; }
.btn.sm svg { width: 14px; height: 14px; }
.eyebrow { font: 500 12px/1 var(--mono); letter-spacing: .14em; text-transform: uppercase; color: var(--ink-3); }

/* theme switch: golden rectangle, the big arc fills in for dark */
.theme-sw { width: 40px; height: 40px; border-radius: 99px; border: 0; background: transparent; cursor: pointer; display: grid; place-items: center; color: var(--ink-2); }
.theme-sw:hover { background: var(--bg-2); color: var(--ink); }
.theme-sw svg { width: 24px; height: 16px; overflow: visible; }
.theme-sw .frame { fill: none; stroke: currentColor; stroke-width: 9; stroke-linejoin: round; stroke-linecap: round; }
.theme-sw .fill { fill: currentColor; transform-origin: 105px 105px; transform: scale(0); transition: transform .5s cubic-bezier(.3, .8, .2, 1); }
:root[data-theme="dark"] .theme-sw .fill { transform: scale(1); }
::view-transition-old(root), ::view-transition-new(root) { animation: none; mix-blend-mode: normal; }

/* toasts: a compact pill, bottom centre. black in light mode, white glass in dark (matches the navbar) */
.toasts { position: fixed; left: 50%; bottom: 22px; z-index: 60; display: grid; justify-items: center; gap: 8px; transform: translateX(-50%); width: max-content; max-width: calc(100vw - 24px); pointer-events: none; }
.toast { position: relative; overflow: hidden; display: flex; align-items: center; gap: 10px; min-width: 240px; max-width: 360px; padding: 8px 16px 8px 8px; border-radius: 16px;
  background: #0B0A0F; color: #fff; box-shadow: inset 0 1px 0 rgba(255, 255, 255, .14), 0 14px 34px -14px rgba(0, 0, 0, .55), 0 2px 6px rgba(0, 0, 0, .12);
  animation: toast-in .55s cubic-bezier(.2, 1.35, .35, 1) both; pointer-events: auto; }
.toast.out { animation: toast-out .3s ease forwards; }
.toast .ic { width: 34px; height: 34px; border-radius: 10px; flex: none; display: grid; place-items: center; background: rgba(255, 255, 255, .1); }
.toast .ic img { width: 24px; height: 24px; border-radius: 6px; }
.toast .ic svg { width: 18px; height: 12px; }
.toast .tx { min-width: 0; }
.toast b { display: block; font-weight: 600; font-size: 14px; line-height: 1.25; letter-spacing: -.01em; }
.toast span { display: block; font-size: 12.5px; line-height: 1.3; color: rgba(255, 255, 255, .62); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; max-width: 280px; }
.toast i.t { position: absolute; left: 0; bottom: 0; height: 2px; width: 100%; background: linear-gradient(90deg, #8B5CF6, #C0A6F5); transform-origin: left; animation: toast-time 3.6s linear forwards; }
:root[data-theme="dark"] .toast { color: #0B0A0F; background: linear-gradient(180deg, rgba(255, 255, 255, .94), rgba(255, 255, 255, .84));
  -webkit-backdrop-filter: blur(20px) saturate(180%); backdrop-filter: blur(20px) saturate(180%); box-shadow: inset 0 1px 0 #fff, 0 14px 34px -14px rgba(0, 0, 0, .7); }
:root[data-theme="dark"] .toast span { color: rgba(11, 10, 15, .58); }
:root[data-theme="dark"] .toast .ic { background: rgba(77, 29, 149, .08); }
@keyframes toast-in { from { opacity: 0; transform: translateY(16px) scale(.92); } }
@keyframes toast-out { to { opacity: 0; transform: translateY(10px) scale(.96); } }
@keyframes toast-time { to { transform: scaleX(0); } }
@media (max-width: 640px) { .toasts { bottom: calc(14px + env(safe-area-inset-bottom)); } .toast { min-width: 0; max-width: calc(100vw - 24px); } }
@media (prefers-reduced-motion: reduce) { .toast, .toast.out, .toast i.t { animation: none; } .theme-sw .fill { transition: none; } html { scroll-behavior: auto; } }
