@import url('https://fonts.googleapis.com/css2?family=Sora:wght@600;700;800&family=Inter:wght@400;500;600;700&display=swap');

:root {
  --bg: #08070c;
  --bg-elevated: #100d17;
  --bg-panel: #16121f;
  --bg-panel-2: #1c1729;
  --border: #2c2640;
  --border-bright: #453a63;

  --ember: #ff7a3d;
  --ember-bright: #ffab6b;
  --purple: #a78bfa;
  --purple-bright: #c4b1ff;
  --cyan: #4dd8e6;

  --text: #f3efe7;
  --text-dim: #a79fc0;
  --text-faint: #756e8c;

  --confirmed: #34d399;
  --provisional: #fbbf24;

  --tier-s: #ffd54f;
  --tier-a: #c4b1ff;
  --tier-b: #6fb7ff;
  --tier-c: #9aa3b8;
  --tier-d: #6b7280;

  --radius: 14px;
  --radius-sm: 9px;
  --shadow-glow: 0 8px 30px -8px rgba(255, 122, 61, 0.25);
  --shadow-card: 0 2px 10px rgba(0, 0, 0, 0.35);
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  background:
    radial-gradient(ellipse 900px 500px at 15% -10%, rgba(255, 122, 61, 0.10), transparent 60%),
    radial-gradient(ellipse 700px 500px at 100% 0%, rgba(167, 139, 250, 0.08), transparent 60%),
    var(--bg);
  background-attachment: fixed;
  color: var(--text);
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

.wrap {
  max-width: 900px;
  margin: 0 auto;
  padding: 0 1.5rem 5rem;
}

/* ---------- Nav ---------- */

header.site {
  position: sticky;
  top: 0;
  z-index: 20;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1.1rem 0;
  margin-bottom: 3rem;
  background: rgba(8, 7, 12, 0.72);
  backdrop-filter: blur(14px) saturate(140%);
  -webkit-backdrop-filter: blur(14px) saturate(140%);
  border-bottom: 1px solid var(--border);
}

header.site a.brand {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-family: 'Sora', sans-serif;
  font-weight: 800;
  font-size: 1.35rem;
  letter-spacing: 0.01em;
  background: linear-gradient(135deg, var(--ember-bright), var(--purple-bright));
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  text-decoration: none;
}

header.site a.brand::before {
  content: '';
  width: 22px;
  height: 22px;
  border-radius: 6px;
  background: linear-gradient(135deg, var(--ember), var(--purple));
  box-shadow: 0 0 16px rgba(255, 122, 61, 0.55);
  flex-shrink: 0;
}

header.site nav { display: flex; align-items: center; gap: 0.3rem; }

header.site nav a {
  color: var(--text-dim);
  text-decoration: none;
  padding: 0.45rem 0.8rem;
  border-radius: var(--radius-sm);
  font-size: 0.92rem;
  font-weight: 500;
  transition: color 0.15s ease, background 0.15s ease;
}

header.site nav a:hover { color: var(--text); background: rgba(255, 255, 255, 0.05); }
header.site nav a.active { color: var(--ember-bright); background: rgba(255, 122, 61, 0.1); }

@media (max-width: 640px) {
  header.site nav { gap: 0; overflow-x: auto; }
  header.site nav a { padding: 0.4rem 0.5rem; font-size: 0.82rem; white-space: nowrap; }
}

/* ---------- Type ---------- */

h1 {
  font-family: 'Sora', sans-serif;
  font-weight: 700;
  color: var(--text);
  font-size: 2rem;
  letter-spacing: -0.01em;
  margin-bottom: 0.5rem;
}

h2 {
  font-family: 'Sora', sans-serif;
  font-weight: 700;
  color: var(--text);
  font-size: 1.3rem;
  margin-top: 2.4rem;
}

.tagline { color: var(--text-dim); margin-top: 0; margin-bottom: 2.2rem; max-width: 60ch; }

a { color: var(--purple-bright); }
a:hover { color: var(--ember-bright); }

/* ---------- Ask box / forms ---------- */

.ask-box {
  background: linear-gradient(160deg, var(--bg-panel), var(--bg-panel-2));
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1.6rem;
  margin-bottom: 2.5rem;
  box-shadow: var(--shadow-card);
}

.ask-box textarea {
  width: 100%;
  min-height: 90px;
  background: rgba(0, 0, 0, 0.25);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  color: var(--text);
  padding: 0.9rem 1rem;
  font-family: inherit;
  font-size: 1rem;
  resize: vertical;
  transition: border-color 0.15s ease;
}

.ask-box textarea:focus { outline: none; border-color: var(--ember); }

.ask-box button {
  margin-top: 0.9rem;
  background: linear-gradient(135deg, var(--ember), #ff5f7a);
  color: #17100a;
  border: none;
  border-radius: var(--radius-sm);
  padding: 0.7rem 1.5rem;
  font-size: 1rem;
  font-weight: 700;
  font-family: 'Sora', sans-serif;
  cursor: pointer;
  box-shadow: 0 4px 18px -4px rgba(255, 122, 61, 0.45);
  transition: transform 0.12s ease, box-shadow 0.12s ease;
}

.ask-box button:hover { transform: translateY(-1px); box-shadow: 0 6px 22px -4px rgba(255, 122, 61, 0.6); }
.ask-box button:disabled { opacity: 0.5; cursor: default; transform: none; box-shadow: none; }

.ask-box .hint { color: var(--text-faint); font-size: 0.85rem; margin-top: 0.7rem; }

/* ---------- Reveal / build cards ---------- */

.reveal-card {
  background: linear-gradient(160deg, var(--bg-panel), var(--bg-panel-2));
  border: 1px solid var(--border);
  border-left: 3px solid var(--ember);
  border-radius: var(--radius);
  padding: 1.6rem 1.8rem;
  margin-top: 1.2rem;
  box-shadow: var(--shadow-card);
}

.reveal-card .narrator { font-style: italic; font-size: 1.05rem; color: var(--text); margin: 0 0 1rem; }
.reveal-card .core { color: var(--text-dim); margin: 0 0 1rem; }
.reveal-card a.permalink {
  display: inline-block;
  margin-top: 0.4rem;
  font-size: 0.85rem;
  color: var(--text-faint);
}

.error-card { border-left-color: #e2545a; }
.error-card .narrator { color: #f5a3a3; }

/* ---------- Freshness badges ---------- */

.freshness-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  font-size: 0.8rem;
  font-weight: 600;
  padding: 0.25rem 0.65rem;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.04);
}

.freshness-badge .dot { width: 7px; height: 7px; border-radius: 50%; }
.freshness-badge.Confirmed { color: var(--confirmed); }
.freshness-badge.Confirmed .dot { background: var(--confirmed); box-shadow: 0 0 8px var(--confirmed); }
.freshness-badge.Provisional { color: var(--provisional); }
.freshness-badge.Provisional .dot { background: var(--provisional); box-shadow: 0 0 8px var(--provisional); }

p.freshness { font-size: 0.85rem; }
p.freshness.Confirmed { color: var(--confirmed); }
p.freshness.Provisional { color: var(--provisional); }

/* ---------- Tier badges ---------- */

.tier-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 30px;
  height: 30px;
  border-radius: 8px;
  font-family: 'Sora', sans-serif;
  font-weight: 800;
  font-size: 0.95rem;
  color: #0c0a10;
}

.tier-badge.tier-S { background: linear-gradient(135deg, var(--tier-s), #ffb84d); box-shadow: 0 0 14px rgba(255, 213, 79, 0.45); }
.tier-badge.tier-A { background: linear-gradient(135deg, var(--tier-a), var(--purple)); }
.tier-badge.tier-B { background: linear-gradient(135deg, var(--tier-b), #4a8fd6); }
.tier-badge.tier-C { background: var(--tier-c); }
.tier-badge.tier-D { background: var(--tier-d); }

/* ---------- Grids / cards ---------- */

.class-grid, .build-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(210px, 1fr));
  gap: 1rem;
  list-style: none;
  padding: 0;
}

.class-grid li a, .build-grid li a {
  display: flex;
  align-items: center;
  gap: 0.8rem;
  background: linear-gradient(160deg, var(--bg-panel), var(--bg-panel-2));
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1rem 1.1rem;
  color: var(--text);
  text-decoration: none;
  box-shadow: var(--shadow-card);
  transition: transform 0.15s ease, border-color 0.15s ease, box-shadow 0.15s ease;
}

.class-grid li a:hover, .build-grid li a:hover {
  transform: translateY(-3px);
  border-color: var(--border-bright);
  box-shadow: 0 10px 28px -10px rgba(167, 139, 250, 0.35);
}

.class-icon-badge {
  flex-shrink: 0;
  width: 38px;
  height: 38px;
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: linear-gradient(135deg, rgba(255, 122, 61, 0.18), rgba(167, 139, 250, 0.18));
  color: var(--ember-bright);
}

.class-grid li a .label-block, .build-grid li a .label-block { display: flex; flex-direction: column; gap: 0.15rem; min-width: 0; }
.class-grid li a .name, .build-grid li a .name { font-weight: 600; }

.class-grid li a .meta, .build-grid li a .meta {
  display: block;
  color: var(--text-faint);
  font-size: 0.78rem;
}

/* ---------- Homepage path cards ---------- */

.path-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1.2rem;
  margin: 2rem 0 2.5rem;
}

.path-card {
  position: relative;
  display: block;
  overflow: hidden;
  background: linear-gradient(160deg, var(--bg-panel), var(--bg-panel-2));
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 2rem 1.7rem;
  text-decoration: none;
  color: var(--text);
  box-shadow: var(--shadow-card);
  transition: transform 0.18s ease, border-color 0.18s ease, box-shadow 0.18s ease;
}

.path-card::before {
  content: '';
  position: absolute;
  inset: 0;
  background: radial-gradient(circle at 20% 0%, rgba(255, 122, 61, 0.14), transparent 55%);
  opacity: 0;
  transition: opacity 0.25s ease;
}

.path-card:hover { transform: translateY(-4px); border-color: var(--border-bright); box-shadow: 0 14px 34px -10px rgba(255, 122, 61, 0.3); }
.path-card:hover::before { opacity: 1; }

.path-card .path-eyebrow {
  color: var(--ember-bright);
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  margin: 0 0 0.7rem;
}

.path-card h2 { margin: 0 0 0.6rem; font-size: 1.4rem; }
.path-card p.desc { color: var(--text-dim); font-size: 0.95rem; margin: 0; position: relative; }

@media (max-width: 560px) {
  .path-grid { grid-template-columns: 1fr; }
}

/* ---------- Tables ---------- */

.freshness-table {
  width: 100%;
  border-collapse: separate;
  border-spacing: 0;
  font-size: 0.9rem;
  margin-top: 1.5rem;
  background: var(--bg-panel);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
}

.freshness-table th, .freshness-table td {
  text-align: left;
  padding: 0.75rem 0.9rem;
  border-bottom: 1px solid var(--border);
}

.freshness-table th {
  color: var(--text-faint);
  font-weight: 600;
  font-size: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  background: rgba(255, 255, 255, 0.03);
}

.freshness-table tbody tr:hover { background: rgba(255, 255, 255, 0.025); }
.freshness-table tbody tr:last-child td { border-bottom: none; }

.freshness-cell.Confirmed { color: var(--confirmed); font-weight: 600; }
.freshness-cell.Provisional { color: var(--provisional); font-weight: 600; }
.freshness-table td.meta { color: var(--text-faint); font-size: 0.8rem; }
.freshness-table td.tier-cell { padding-left: 0.7rem; }

/* ---------- Footer ---------- */

footer.site {
  margin-top: 4rem;
  color: var(--text-faint);
  font-size: 0.82rem;
  border-top: 1px solid var(--border);
  padding-top: 1.4rem;
}

footer.site p { margin: 0.3rem 0; }
footer.site a { color: var(--text-faint); }
footer.site a:hover { color: var(--ember-bright); }
