/* camath.ai portal — light, on-brand (Camath purple -> AI pink). A dark-mode block below
   keeps it from glaring at night. Static, no build step. */
:root {
  --purple: #5b3fd6;
  --pink: #e63f9e;
  --brand: linear-gradient(135deg, #5b3fd6 0%, #e63f9e 100%);
  --ink: #2a2340;
  --ink-soft: #6a6480;
  --bg: #ffffff;
  --card: #ffffff;
  --border: #e7e1f5;
  --shadow: 0 10px 30px rgba(91, 63, 214, 0.12);
  --shadow-hover: 0 16px 44px rgba(230, 63, 158, 0.20);
}

* { box-sizing: border-box; }

/* Fit-to-screen landing view. On mobile PORTRAIT it must not scroll or rubber-band: 100vh is
   the URL-bar-HIDDEN viewport, so under a visible URL bar the body overshot the screen and
   became scrollable — svh (URL-bar-VISIBLE viewport, below) fits exactly so there's nothing to
   scroll, and overscroll-behavior:none kills the elastic bounce. We deliberately do NOT hard-
   hide overflow: when the content genuinely can't fit (e.g. a short LANDSCAPE viewport) the
   page must still scroll so the tile titles aren't cut off. min-height (not height) lets the
   body grow past svh in that case, restoring a normal scroll. */
html { overscroll-behavior: none; }

body {
  margin: 0;
  min-height: 100svh;
  overscroll-behavior: none;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 2rem;
  padding: 3rem 1.25rem;
  font: 16px/1.5 system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  color: var(--ink);
  background: var(--bg);
}

/* --- greeting bar (only shown to a recognized member) --- */
/* The bar defaults to display:flex, which would otherwise override the HTML `hidden`
   attribute (UA `[hidden]{display:none}` loses on specificity) — so honor `hidden` explicitly
   or a logged-out visitor sees an empty bar + stray Log out button. */
.greeting[hidden] { display: none; }
.greeting {
  position: fixed;
  top: 0; left: 0; right: 0;
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 1rem;
  padding: 0.8rem 1.2rem;
  font-size: 1.1rem;
  color: var(--ink-soft);
  background: rgba(255, 255, 255, 0.7);
  backdrop-filter: blur(8px);
}
.greeting b { color: var(--ink); }
.greeting button {
  font: inherit;
  color: var(--purple);
  background: none;
  border: 1px solid var(--border);
  border-radius: 999px;
  padding: 0.5rem 1.15rem;
  cursor: pointer;
}
.greeting button:hover { border-color: var(--purple); }

/* --- hero --- */
.portal { width: 100%; max-width: 720px; display: flex; flex-direction: column; gap: 2.5rem; }
.hero { text-align: center; display: flex; flex-direction: column; align-items: center; }
/* Logo PNG has a solid white background, so no drop-shadow (it would outline the square) and
   the page background is pure white to match — the square edges vanish into the page. */
.hero-logo { width: 200px; height: 200px; }

/* --- tiles --- */
/* Just two apps: no panels/descriptions, only a big icon + title. A centered flex row keeps
   them side by side (they're small enough to stay on one line even on a phone). */
.tiles {
  display: flex;
  justify-content: center;
  gap: 3rem;
}
.tile {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.85rem;
  text-decoration: none;
  color: var(--ink);
  transition: transform 0.16s ease;
}
.tile:hover { transform: translateY(-4px); }
/* No card behind the tile, so the icon itself carries the depth: a resting shadow that deepens
   on hover, plus a color shift on the name. */
.tile-icon {
  width: 66px; height: 66px;
  display: grid; place-items: center;
  border-radius: 17px;
  color: #fff;
  background: var(--brand);
  box-shadow: var(--shadow);
  transition: box-shadow 0.16s ease;
}
.tile-icon svg { width: 37px; height: 37px; }
.tile:hover .tile-icon { box-shadow: var(--shadow-hover); }
.tile-name { font-size: 1.25rem; font-weight: 650; }
.tile:hover .tile-name { color: var(--purple); }

@media (max-width: 520px) {
  .tiles { gap: 2rem; }
  .tile-icon { width: 58px; height: 58px; border-radius: 15px; }
  .tile-icon svg { width: 32px; height: 32px; }
  .tile-name { font-size: 1.12rem; }
  .hero-logo { width: 150px; height: 150px; }
}
