/* The public website (hub/site.py). Its own look, separate from the admin panel's hub.css. */

:root {
  --sky-top: #dff1ff; --sky-bottom: #fde9f4;
  --ink: #2b2d5a; --ink-2: #5b5e8c;
  --card: rgba(255, 255, 255, .78); --card-border: rgba(255, 255, 255, .9); --card-shadow: 0 10px 30px rgba(73, 86, 160, .12);
  --berry: #ff5f9e; --berry-soft: #ffe1ee; --sky: #3fa7f5; --sky-soft: #dcefff; --mint: #26b893; --mint-soft: #d8f6ec;
  --snow: #ffffff; --snow-shade: #cfe3f7; --ground-shadow: rgba(43, 45, 90, .1);
  --hat: #ff7fb2; --hat-band: #ff5f9e; --hat-light: #ffc2dc; --blush: rgba(255, 120, 170, .45);
  --flake: #ffffff; --flake-glow: rgba(120, 160, 220, .35);
  --round: ui-rounded, "SF Pro Rounded", "Arial Rounded MT Bold", "Varela Round", "Nunito", system-ui, sans-serif;
}
@media (prefers-color-scheme: dark) {
  :root {
    --sky-top: #151a3c; --sky-bottom: #2b1f4d;
    --ink: #f4f2ff; --ink-2: #b9b8e0;
    --card: rgba(255, 255, 255, .07); --card-border: rgba(255, 255, 255, .1); --card-shadow: 0 10px 30px rgba(0, 0, 0, .25);
    --berry: #ff8dbb; --berry-soft: rgba(255, 141, 187, .16); --sky: #7cc4ff; --sky-soft: rgba(124, 196, 255, .16);
    --mint: #6fe0c0; --mint-soft: rgba(111, 224, 192, .16);
    --snow-shade: #c3d6f2; --ground-shadow: rgba(0, 0, 0, .3);
    --flake-glow: rgba(255, 255, 255, .4);
  }
  /* The mascot keeps its daytime face colors at night. */
  .mascot { --ink: #2b2d5a; }
}

* { box-sizing: border-box; }
html { background: var(--sky-top); }
body {
  margin: 0; min-height: 100vh; display: flex; flex-direction: column; overflow-x: hidden;
  color: var(--ink); background: linear-gradient(180deg, var(--sky-top) 0%, var(--sky-bottom) 100%) fixed;
  font: 17px/1.55 system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  -webkit-font-smoothing: antialiased;
}
h1, h2, h3, .wordmark, .chip { font-family: var(--round); }

/* Falling snow */
.snow { position: fixed; inset: 0; pointer-events: none; overflow: hidden; z-index: 0; }
.snow span {
  position: absolute; top: -12px; left: var(--x); width: var(--s); height: var(--s); border-radius: 50%;
  background: var(--flake); box-shadow: 0 0 6px var(--flake-glow); opacity: .9;
  animation: fall var(--d) linear var(--delay) infinite;
}
@keyframes fall {
  to { transform: translate(var(--drift), 105vh); }
}

/* Header */
.top, main, .bottom { position: relative; z-index: 1; width: 100%; max-width: 1040px; margin: 0 auto; padding-left: 24px; padding-right: 24px; }
.top { padding-top: 22px; padding-bottom: 8px; }
.wordmark { display: inline-flex; align-items: center; gap: 10px; color: var(--ink); text-decoration: none; font-size: 21px; font-weight: 800; letter-spacing: -.2px; }
.wordmark .mascot { width: 40px; height: 40px; }

/* Hero */
.hero { display: grid; grid-template-columns: 1.1fr .9fr; align-items: center; gap: 32px; padding: 48px 0 56px; }
.hero-art { order: 2; display: grid; place-items: center; }
.hero-art .mascot { width: min(340px, 100%); height: auto; animation: bob 4.5s ease-in-out infinite; transform-origin: 50% 90%; }
@keyframes bob {
  0%, 100% { transform: translateY(0) rotate(-2deg); }
  50% { transform: translateY(-12px) rotate(2deg); }
}
.chip { display: inline-flex; align-items: center; gap: 8px; margin: 0 0 18px; padding: 7px 14px 7px 12px; border-radius: 999px;
  background: var(--card); border: 1px solid var(--card-border); box-shadow: var(--card-shadow); font-size: 15px; font-weight: 700; color: var(--ink); }
.chip .dot { width: 8px; height: 8px; border-radius: 50%; background: var(--berry); box-shadow: 0 0 0 4px var(--berry-soft); }
h1 { margin: 0 0 18px; font-size: clamp(40px, 6.2vw, 64px); line-height: 1.04; font-weight: 800; letter-spacing: -1px; }
h1 em { font-style: normal; color: var(--berry); }
.lead { margin: 0; max-width: 30em; font-size: 19px; color: var(--ink-2); }

/* Promise */
.promise { padding: 8px 0 64px; }
.promise h2 { margin: 0 0 20px; font-size: 28px; font-weight: 800; text-align: center; }
.cards { display: grid; grid-template-columns: repeat(3, 1fr); gap: 18px; }
.card { padding: 24px 22px 22px; border-radius: 24px; background: var(--card); border: 1px solid var(--card-border); box-shadow: var(--card-shadow);
  -webkit-backdrop-filter: blur(8px); backdrop-filter: blur(8px); }
.card h3 { margin: 16px 0 6px; font-size: 20px; font-weight: 800; }
.card p { margin: 0; color: var(--ink-2); font-size: 16px; }
.icon { width: 48px; height: 48px; border-radius: 16px; display: grid; place-items: center; }
.icon svg { width: 26px; height: 26px; }
.icon.berry { background: var(--berry-soft); fill: var(--berry); }
.icon.sky { background: var(--sky-soft); fill: var(--sky); }
.icon.mint { background: var(--mint-soft); fill: var(--mint); }

/* Footer */
.bottom { margin-top: auto; padding-top: 20px; padding-bottom: 28px; text-align: center; font-size: 14px; color: var(--ink-2); }

/* Tablet and phone */
@media (max-width: 860px) {
  .cards { grid-template-columns: 1fr; max-width: 520px; margin: 0 auto; }
}
@media (max-width: 720px) {
  .top, main, .bottom { padding-left: 16px; padding-right: 16px; }
  .hero { grid-template-columns: 1fr; gap: 8px; padding: 20px 0 40px; text-align: center; }
  .hero-art { order: 0; }
  .hero-art .mascot { width: 200px; }
  .lead { margin: 0 auto; font-size: 17px; }
}

@media (prefers-reduced-motion: reduce) {
  .snow span, .hero-art .mascot { animation: none; }
  .snow span { top: auto; bottom: calc(var(--x) * .6); }
}
