/* =============================================
   WHITEOUT SURVIVAL — STRATEGY GUIDE
   ============================================= */

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

:root {
  --bg-darkest:   #040b14;
  --bg-dark:      #071525;
  --bg-card:      #0d1f33;
  --bg-card-2:    #112540;
  --border:       #1e3a5a;
  --border-glow:  #2a5f8f;
  --ice-blue:     #4fc3f7;
  --ice-light:    #81d4fa;
  --ice-pale:     #b3e5fc;
  --ice-white:    #e1f5fe;
  --frost:        #cce7ff;
  --gold:         #ffd54f;
  --gold-light:   #ffe082;
  --red:          #ef5350;
  --red-light:    #ff7043;
  --green:        #66bb6a;
  --green-light:  #a5d6a7;
  --purple:       #ab47bc;
  --purple-light: #ce93d8;
  --orange:       #ffa726;
  --text-primary: #e8f4fd;
  --text-secondary: #94b8d4;
  --text-muted:   #4a7a9b;
  --sidebar-w:    280px;
  --radius:       12px;
  --radius-sm:    8px;
  --shadow:       0 4px 20px rgba(0,0,0,0.6);
  --glow:         0 0 20px rgba(79,195,247,0.2);
  --transition:   0.25s ease;
}

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

html { scroll-behavior: smooth; }

body {
  font-family: 'Inter', sans-serif;
  background: var(--bg-darkest);
  color: var(--text-primary);
  min-height: 100vh;
  overflow-x: hidden;
}

/* ── SCROLLBAR ── */
::-webkit-scrollbar { width: 6px; height: 6px; }
::-webkit-scrollbar-track { background: var(--bg-dark); }
::-webkit-scrollbar-thumb { background: var(--border-glow); border-radius: 3px; }

/* ── LAYOUT ── */
.app-shell {
  display: flex;
  min-height: 100vh;
}

/* ── SIDEBAR ── */
.sidebar {
  width: var(--sidebar-w);
  background: linear-gradient(180deg, #020a14 0%, #050f1c 100%);
  border-right: 1px solid var(--border);
  display: flex;
  flex-direction: column;
  position: fixed;
  top: 0; left: 0; bottom: 0;
  z-index: 100;
  overflow-y: auto;
  transition: transform var(--transition);
}

.sidebar-logo {
  padding: 28px 20px 18px;
  border-bottom: 1px solid var(--border);
  text-align: center;
  background: linear-gradient(180deg, rgba(79,195,247,0.06) 0%, transparent 100%);
  position: relative;
}
.sidebar-logo::after {
  content: '';
  position: absolute;
  bottom: 0; left: 20%; right: 20%;
  height: 1px;
  background: linear-gradient(90deg, transparent, rgba(79,195,247,0.5), transparent);
}

.sidebar-logo .game-icon {
  font-size: 2.6rem;
  display: block;
  margin-bottom: 8px;
  filter: drop-shadow(0 0 12px rgba(79,195,247,0.7));
  animation: iconPulse 4s ease-in-out infinite;
}
@keyframes iconPulse {
  0%, 100% { filter: drop-shadow(0 0 10px rgba(79,195,247,0.6)); }
  50%       { filter: drop-shadow(0 0 20px rgba(79,195,247,0.9)); }
}

.sidebar-logo h1 {
  font-family: 'Cinzel', serif;
  font-size: 0.92rem;
  font-weight: 700;
  color: var(--ice-light);
  letter-spacing: 0.06em;
  line-height: 1.35;
  text-shadow: 0 0 16px rgba(79,195,247,0.5);
}

.sidebar-logo .subtitle {
  font-size: 0.6rem;
  color: var(--text-muted);
  letter-spacing: 0.15em;
  text-transform: uppercase;
  margin-top: 4px;
}

.sidebar-search {
  padding: 12px 16px;
  border-bottom: 1px solid var(--border);
}

.sidebar-search input {
  width: 100%;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  color: var(--text-primary);
  padding: 8px 12px;
  font-size: 0.8rem;
  outline: none;
  transition: border-color var(--transition);
}
.sidebar-search input::placeholder { color: var(--text-muted); }
.sidebar-search input:focus { border-color: var(--ice-blue); box-shadow: 0 0 0 2px rgba(79,195,247,0.15); }

/* Nav section labels — ice-blue tinted, Cinzel, separator line */
.nav-section-label {
  padding: 16px 16px 4px;
  font-size: 0.62rem;
  font-family: 'Cinzel', serif;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.14em;
  color: rgba(79,195,247,0.7);
  border-top: 1px solid rgba(79,195,247,0.1);
  margin-top: 4px;
}
.nav-section-label:first-of-type {
  border-top: none;
  margin-top: 0;
}

/* Nav items — full pill style, no left border */
.nav-item {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 9px 16px;
  cursor: pointer;
  border-radius: 8px;
  margin: 2px 8px;
  transition: background var(--transition), color var(--transition), box-shadow var(--transition), text-shadow var(--transition);
  font-size: 0.82rem;
  color: var(--text-secondary);
  border-left: none;
}
.nav-item:hover {
  background: rgba(79,195,247,0.1);
  color: var(--text-primary);
  box-shadow: inset 0 0 0 1px rgba(79,195,247,0.2);
}
.nav-item.active {
  background: rgba(79,195,247,0.18);
  color: var(--ice-blue);
  box-shadow: inset 0 0 0 1px rgba(79,195,247,0.4);
  font-weight: 600;
  text-shadow: 0 0 12px rgba(79,195,247,0.5);
}
.nav-item .nav-icon {
  font-size: 0.95rem;
  width: 26px;
  height: 26px;
  background: rgba(79,195,247,0.08);
  border-radius: 6px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}
.nav-item.active .nav-icon { background: rgba(79,195,247,0.22); }
.nav-item .nav-badge {
  margin-left: auto;
  background: var(--ice-blue);
  color: var(--bg-darkest);
  font-size: 0.6rem;
  font-weight: 700;
  padding: 1px 5px;
  border-radius: 10px;
}
.nav-item .nav-badge.new { background: var(--green); }
.nav-item .nav-badge.hot { background: var(--red); }

.sidebar-footer {
  margin-top: auto;
  padding: 16px;
  border-top: 1px solid var(--border);
  font-size: 0.7rem;
  color: var(--text-muted);
  text-align: center;
  line-height: 1.6;
}

/* ── MAIN CONTENT ── */
.main-content {
  margin-left: var(--sidebar-w);
  flex: 1;
  min-height: 100vh;
  background: radial-gradient(ellipse at 20% 10%, rgba(79,195,247,0.06) 0%, transparent 50%),
              radial-gradient(ellipse at 80% 90%, rgba(79,195,247,0.04) 0%, transparent 40%);
}

/* ── TOP BAR ── */
.top-bar {
  position: sticky;
  top: 0;
  background: rgba(2, 8, 16, 0.97);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid rgba(79,195,247,0.15);
  box-shadow: 0 1px 20px rgba(79,195,247,0.08);
  padding: 14px 32px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  z-index: 50;
}

.top-bar h2 {
  font-family: 'Cinzel', serif;
  font-size: 1.15rem;
  font-weight: 600;
  color: var(--ice-light);
  letter-spacing: 0.03em;
}

.top-bar .breadcrumb {
  font-size: 0.75rem;
  color: var(--text-muted);
}
.top-bar .breadcrumb span { color: var(--text-secondary); }

.hamburger {
  display: none;
  background: rgba(79,195,247,0.08);
  border: 1px solid rgba(79,195,247,0.2);
  border-radius: 8px;
  color: var(--ice-light);
  font-size: 1.1rem;
  cursor: pointer;
  padding: 0;
  width: 40px;
  height: 40px;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  touch-action: manipulation;
}

.content-area {
  padding: 32px;
  max-width: 1100px;
}

/* ── SECTIONS ── */
.section { display: none; }
.section.active {
  display: block;
  contain: layout style;
}

/* ── HERO BANNER ── */
.hero-banner {
  background:
    repeating-linear-gradient(60deg,  rgba(79,195,247,0.035) 0px, rgba(79,195,247,0.035) 1px, transparent 1px, transparent 30px),
    repeating-linear-gradient(-60deg, rgba(79,195,247,0.035) 0px, rgba(79,195,247,0.035) 1px, transparent 1px, transparent 30px),
    linear-gradient(160deg, #010a15 0%, #0b2540 28%, #071a30 60%, #010a15 100%);
  border: 1px solid rgba(79,195,247,0.3);
  border-radius: var(--radius);
  padding: 60px 48px;
  margin-bottom: 40px;
  position: relative;
  overflow: hidden;
  min-height: 380px;
  display: flex;
  flex-direction: column;
  justify-content: center;
  box-shadow: 0 0 80px rgba(79,195,247,0.12), 0 8px 40px rgba(0,0,0,0.8), inset 0 0 120px rgba(0,0,0,0.3);
}
.hero-banner::before {
  content: '';
  position: absolute;
  top: -30%; right: -15%;
  width: 65%; height: 130%;
  background: radial-gradient(ellipse, rgba(79,195,247,0.2) 0%, rgba(79,195,247,0.07) 40%, transparent 70%);
  pointer-events: none;
}
.hero-banner::after {
  content: '';
  position: absolute;
  bottom: 0; left: 0; right: 0;
  height: 2px;
  background: linear-gradient(90deg, transparent 0%, rgba(79,195,247,0.6) 35%, rgba(179,229,252,0.95) 50%, rgba(79,195,247,0.6) 65%, transparent 100%);
}
.hero-banner h2 {
  font-family: 'Cinzel', serif;
  font-size: 2.6rem;
  color: var(--ice-white);
  text-shadow: 0 0 30px rgba(79,195,247,0.7), 0 0 70px rgba(79,195,247,0.3), 0 2px 6px rgba(0,0,0,0.9);
  margin-bottom: 16px;
  line-height: 1.2;
  letter-spacing: 0.02em;
}
.hero-banner .tagline {
  font-size: 1rem;
  color: var(--ice-pale);
  max-width: 620px;
  line-height: 1.75;
  margin-bottom: 32px;
  opacity: 0.85;
}
.hero-stats {
  display: flex;
  gap: 24px;
  flex-wrap: wrap;
}
.hero-stat {
  background: rgba(79,195,247,0.1);
  border: 1px solid rgba(79,195,247,0.3);
  border-top: 2px solid rgba(255,213,79,0.6);
  border-radius: var(--radius-sm);
  padding: 12px 24px;
  text-align: center;
  min-width: 88px;
}
.hero-stat .stat-value {
  font-family: 'Cinzel', serif;
  font-size: 1.6rem;
  color: var(--gold);
  font-weight: 700;
  text-shadow: 0 0 20px rgba(255,213,79,0.5);
}
.hero-stat .stat-label {
  font-size: 0.68rem;
  color: var(--ice-pale);
  text-transform: uppercase;
  letter-spacing: 0.12em;
  margin-top: 2px;
}

/* ── CARDS GRID ── */
.cards-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
  gap: 20px;
  margin-bottom: 28px;
}

.cards-grid-3 {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
  gap: 16px;
  margin-bottom: 28px;
}

/* ── CARDS ── */
.card {
  background: linear-gradient(145deg, #152e50 0%, #070e1c 100%);
  border: 1px solid rgba(79,195,247,0.2);
  border-top: 3px solid rgba(79,195,247,0.6);
  border-radius: var(--radius);
  padding: 22px;
  position: relative;
  transition: border-color var(--transition), border-top-color var(--transition), box-shadow var(--transition), transform var(--transition);
}
/* Corner brackets — always visible at 0.35 opacity */
.card::before, .card::after {
  content: '';
  position: absolute;
  width: 14px; height: 14px;
  opacity: 0.35;
  transition: opacity var(--transition);
  pointer-events: none;
}
.card::before {
  top: -1px; left: -1px;
  border-top: 2px solid var(--ice-blue);
  border-left: 2px solid var(--ice-blue);
  border-radius: var(--radius) 0 0 0;
}
.card::after {
  bottom: -1px; right: -1px;
  border-bottom: 2px solid var(--ice-blue);
  border-right: 2px solid var(--ice-blue);
  border-radius: 0 0 var(--radius) 0;
}
.card:hover {
  border-color: rgba(79,195,247,0.35);
  border-top-color: var(--ice-blue);
  box-shadow: 0 0 28px rgba(79,195,247,0.18), 0 4px 24px rgba(0,0,0,0.5);
  transform: translateY(-2px);
}
.card:hover::before, .card:hover::after { opacity: 1; }

.card-header {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 14px;
}
.card-icon {
  font-size: 1.5rem;
  width: 46px;
  height: 46px;
  background: rgba(79,195,247,0.12);
  border: 1px solid rgba(79,195,247,0.25);
  border-radius: 10px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}
.card-title {
  font-family: 'Cinzel', serif;
  font-size: 0.95rem;
  font-weight: 600;
  color: var(--ice-light);
}
.card-subtitle {
  font-size: 0.72rem;
  color: var(--text-muted);
  margin-top: 2px;
}
.card p {
  font-size: 0.83rem;
  color: var(--text-secondary);
  line-height: 1.65;
}

/* ── PRIORITY CARD ── */
.priority-card {
  background: linear-gradient(145deg, #0f2542 0%, #091829 100%);
  border: 1px solid rgba(79,195,247,0.3);
  border-radius: var(--radius);
  overflow: hidden;
  margin-bottom: 20px;
  position: relative;
  box-shadow: 0 0 60px rgba(79,195,247,0.1), 0 8px 32px rgba(0,0,0,0.6);
}
.priority-card::before {
  content: '';
  position: absolute;
  top: 0; left: 0; right: 0;
  height: 4px;
  background: linear-gradient(90deg, var(--ice-blue) 0%, rgba(79,195,247,0.6) 50%, rgba(79,195,247,0.1) 100%);
  z-index: 1;
}
.priority-card-header {
  background: linear-gradient(90deg, rgba(79,195,247,0.16) 0%, rgba(79,195,247,0.04) 100%);
  border-bottom: 1px solid rgba(79,195,247,0.2);
  padding: 16px 24px;
  display: flex;
  align-items: center;
  gap: 10px;
  font-family: 'Cinzel', serif;
  font-size: 0.95rem;
  color: var(--ice-light);
  font-weight: 600;
  letter-spacing: 0.04em;
}
.priority-card-body { padding: 24px; }

/* ── TIER LIST ── */
.tier-row {
  display: flex;
  align-items: stretch;
  gap: 0;
  margin-bottom: 5px;
  border-radius: var(--radius-sm);
  overflow: hidden;
  border: 1px solid rgba(255,255,255,0.05);
}
.tier-label {
  flex-shrink: 0;
  width: 54px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: 'Cinzel', serif;
  font-size: 1rem;
  font-weight: 700;
  align-self: stretch;
  letter-spacing: 0.02em;
}
.tier-s { background: linear-gradient(160deg, #ffe57f, #ff8f00); color: #1a0800; box-shadow: inset -3px 0 12px rgba(0,0,0,0.3); }
.tier-a { background: linear-gradient(160deg, #ce93d8, #7b1fa2); color: #fff; box-shadow: inset -3px 0 12px rgba(0,0,0,0.3); }
.tier-b { background: linear-gradient(160deg, #64b5f6, #1565c0); color: #fff; box-shadow: inset -3px 0 12px rgba(0,0,0,0.3); }
.tier-c { background: linear-gradient(160deg, #81c784, #2e7d32); color: #fff; box-shadow: inset -3px 0 12px rgba(0,0,0,0.3); }
.tier-d { background: linear-gradient(160deg, #90a4ae, #37474f); color: #fff; box-shadow: inset -3px 0 12px rgba(0,0,0,0.3); }
.tier-content {
  flex: 1;
  padding: 12px 16px;
  background: rgba(255,255,255,0.02);
}
.tier-content .tier-title { font-size: 0.72rem; font-weight: 600; color: var(--text-muted); margin-bottom: 8px; text-transform: uppercase; letter-spacing: 0.07em; }
.tier-tags { display: flex; flex-wrap: wrap; gap: 6px; align-items: center; }
.tier-tag {
  background: rgba(255,255,255,0.06);
  border: 1px solid rgba(255,255,255,0.11);
  border-radius: 6px;
  padding: 6px 14px;
  font-size: 0.78rem;
  font-weight: 500;
  color: var(--text-primary);
  white-space: nowrap;
  display: inline-flex;
  align-items: center;
  min-height: 32px;
}
.tier-row:has(.tier-s) .tier-content { background: rgba(255,213,79,0.04); }
.tier-row:has(.tier-a) .tier-content { background: rgba(171,71,188,0.04); }
.tier-row:has(.tier-b) .tier-content { background: rgba(66,165,245,0.04); }
.tier-row:has(.tier-c) .tier-content { background: rgba(102,187,106,0.04); }

/* ── TABLES ── */
.table-wrap {
  overflow-x: auto;
  margin-bottom: 24px;
  border-radius: var(--radius);
  border: 1px solid var(--border);
}
table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.82rem;
}
thead {
  background: linear-gradient(90deg, rgba(79,195,247,0.18) 0%, rgba(79,195,247,0.06) 100%);
}
th {
  padding: 12px 16px;
  text-align: left;
  font-family: 'Cinzel', serif;
  font-size: 0.72rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--ice-blue);
  white-space: nowrap;
  border-bottom: 2px solid rgba(79,195,247,0.25);
}
td {
  padding: 11px 16px;
  border-bottom: 1px solid rgba(30,58,90,0.5);
  color: var(--text-secondary);
  vertical-align: middle;
}
tr:last-child td { border-bottom: none; }
tbody tr:nth-child(even) td { background: rgba(255,255,255,0.025); }
tr:hover td { background: rgba(79,195,247,0.06); }
.td-name { color: var(--text-primary); font-weight: 500; }
.td-gold { color: var(--gold); font-weight: 600; }
.td-green { color: var(--green); }
.td-red { color: var(--red); }
.td-blue { color: var(--ice-blue); }
.td-purple { color: var(--purple-light); }
.table-gen-row td {
  background: rgba(79,195,247,0.08) !important;
  color: var(--ice-blue);
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  padding: 5px 12px;
  border-bottom: 1px solid rgba(79,195,247,0.15);
}
.table-gen-row:hover td { background: rgba(79,195,247,0.08) !important; }

/* ── STEP LIST ── */
.step-list { list-style: none; }
.step-list li {
  display: flex;
  gap: 14px;
  padding: 12px 0;
  border-bottom: 1px solid rgba(30,58,90,0.4);
  font-size: 0.83rem;
  color: var(--text-secondary);
  line-height: 1.6;
}
.step-list li:last-child { border-bottom: none; }
.step-num {
  flex-shrink: 0;
  width: 26px;
  height: 26px;
  background: rgba(79,195,247,0.12);
  border: 1px solid rgba(79,195,247,0.3);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.72rem;
  font-weight: 700;
  color: var(--ice-blue);
  margin-top: 1px;
}
.step-list li strong { color: var(--text-primary); }

/* ── TIP BOXES ── */
.tip-box {
  border-radius: var(--radius-sm);
  padding: 14px 16px;
  margin-bottom: 16px;
  font-size: 0.82rem;
  line-height: 1.6;
  display: flex;
  gap: 10px;
  align-items: flex-start;
  overflow-wrap: break-word;
  word-break: break-word;
}
.tip-box .tip-icon { font-size: 1.1rem; flex-shrink: 0; margin-top: 1px; }
.tip-box.tip-info    { background: rgba(79,195,247,0.1);  border: 1px solid rgba(79,195,247,0.35);  color: var(--ice-pale); }
.tip-box.tip-warn    { background: rgba(255,167,38,0.1);  border: 1px solid rgba(255,167,38,0.35);  color: #ffe0b2; }
.tip-box.tip-danger  { background: rgba(239,83,80,0.1);   border: 1px solid rgba(239,83,80,0.35);   color: #ffcdd2; }
.tip-box.tip-success { background: rgba(102,187,106,0.1); border: 1px solid rgba(102,187,106,0.35); color: #c8e6c9; }

/* ── SECTION HEADING ── */
.section-heading {
  font-family: 'Cinzel', serif;
  font-size: 1.05rem;
  color: var(--ice-blue);
  text-shadow: 0 0 20px rgba(79,195,247,0.4);
  margin-bottom: 22px;
  margin-top: 44px;
  display: flex;
  align-items: center;
  gap: 14px;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  white-space: nowrap;
}
.section-heading::before,
.section-heading::after {
  content: '';
  flex: 1;
  height: 1px;
  min-width: 20px;
  flex-shrink: 1;
}
.section-heading::before {
  background: linear-gradient(90deg, transparent, rgba(79,195,247,0.5));
}
.section-heading::after {
  background: linear-gradient(270deg, transparent, rgba(79,195,247,0.5));
}
.section-heading:first-child { margin-top: 0; }
.section-heading .sh-icon { font-size: 1.1rem; flex-shrink: 0; }
.section-desc {
  font-size: 0.85rem;
  color: var(--text-secondary);
  margin-bottom: 24px;
  line-height: 1.7;
  max-width: 720px;
  overflow-wrap: break-word;
  word-break: break-word;
}

/* ── TROOP TRIANGLE ── */
.triangle-wrap {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 28px;
  margin-bottom: 24px;
  text-align: center;
}
.triangle-visual {
  display: flex;
  justify-content: center;
  margin-bottom: 20px;
}
.triangle-svg { max-width: 320px; width: 100%; }
.troop-nodes {
  display: flex;
  justify-content: center;
  gap: 24px;
  flex-wrap: wrap;
}
/* Troop nodes — gradient background */
.troop-node {
  background: linear-gradient(135deg, #0f2440 0%, #091829 100%);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 16px 20px;
  min-width: 160px;
  transition: border-color var(--transition);
}
.troop-node:hover { border-color: var(--border-glow); }
.troop-node .tn-icon { font-size: 1.8rem; margin-bottom: 6px; }
.troop-node .tn-name { font-weight: 600; font-size: 0.9rem; color: var(--text-primary); margin-bottom: 4px; }
.troop-node .tn-beats { font-size: 0.75rem; color: var(--green); }
.troop-node .tn-loses { font-size: 0.75rem; color: var(--red); }

/* ── PROGRESS BAR ── */
.progress-bar-wrap { margin-bottom: 12px; }
.progress-bar-label {
  display: flex;
  justify-content: space-between;
  font-size: 0.78rem;
  color: var(--text-secondary);
  margin-bottom: 5px;
}
.progress-bar-track {
  background: var(--bg-card-2);
  border-radius: 4px;
  height: 8px;
  overflow: hidden;
}
.progress-bar-fill {
  height: 100%;
  border-radius: 4px;
  background: linear-gradient(90deg, var(--ice-blue), var(--ice-light));
}

/* ── DAILY CHECKLIST ── */
.checklist { list-style: none; }
.checklist li {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  padding: 8px 0;
  font-size: 0.83rem;
  color: var(--text-secondary);
  border-bottom: 1px solid rgba(30,58,90,0.3);
  cursor: pointer;
  user-select: none;
  transition: color var(--transition);
}
.checklist li:last-child { border-bottom: none; }
.checklist li:hover { color: var(--text-primary); }
.check-box {
  flex-shrink: 0;
  width: 18px;
  height: 18px;
  border: 2px solid var(--border-glow);
  border-radius: 4px;
  margin-top: 1px;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background var(--transition), border-color var(--transition);
}
.checklist li.checked .check-box {
  background: var(--green);
  border-color: var(--green);
}
.checklist li.checked .check-box::after { content: '✓'; font-size: 0.65rem; color: white; font-weight: 700; }
.checklist li.checked .check-text { text-decoration: line-through; color: var(--text-muted); }
.check-priority {
  margin-left: auto;
  font-size: 0.65rem;
  font-weight: 600;
  padding: 1px 6px;
  border-radius: 10px;
  flex-shrink: 0;
}
.cp-high { background: rgba(239,83,80,0.2); color: var(--red-light); border: 1px solid rgba(239,83,80,0.3); }
.cp-med  { background: rgba(255,167,38,0.2); color: var(--orange); border: 1px solid rgba(255,167,38,0.3); }
.cp-low  { background: rgba(102,187,106,0.2); color: var(--green); border: 1px solid rgba(102,187,106,0.3); }

/* ── TIMELINE ── */
.timeline { position: relative; padding-left: 28px; margin-bottom: 24px; }
.timeline::before {
  content: '';
  position: absolute;
  left: 9px; top: 0; bottom: 0;
  width: 2px;
  background: linear-gradient(to bottom, var(--ice-blue), transparent);
}
.tl-item {
  position: relative;
  margin-bottom: 24px;
}
.tl-dot {
  position: absolute;
  left: -24px; top: 4px;
  width: 12px; height: 12px;
  border-radius: 50%;
  background: var(--ice-blue);
  border: 2px solid var(--bg-darkest);
  box-shadow: 0 0 8px rgba(79,195,247,0.6);
}
.tl-label {
  font-family: 'Cinzel', serif;
  font-size: 0.8rem;
  color: var(--ice-blue);
  font-weight: 600;
  margin-bottom: 6px;
  letter-spacing: 0.03em;
}
/* Timeline content — gradient card */
.tl-content {
  background: linear-gradient(145deg, #0f2542 0%, #091829 100%);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 14px 16px;
  font-size: 0.82rem;
  color: var(--text-secondary);
  line-height: 1.65;
}
.tl-content ul { padding-left: 16px; margin-top: 6px; }
.tl-content ul li { margin-bottom: 4px; }

/* ── HERO CARDS ── */
.hero-cards {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
  gap: 16px;
  margin-bottom: 24px;
}
.hero-card {
  background: linear-gradient(145deg, #0f2542 0%, #091829 100%);
  border: 1px solid var(--border);
  border-top: 3px solid var(--border);
  border-radius: var(--radius);
  padding: 18px;
  position: relative;
  transition: border-color var(--transition), border-top-color var(--transition), box-shadow var(--transition);
}
/* Role-colored top borders — always visible at 0.85 opacity */
.hero-card:has(.role-combat)  { border-top-color: rgba(239,83,80,0.85); }
.hero-card:has(.role-dev), .hero-card:has(.role-develop) { border-top-color: rgba(79,195,247,0.85); }
.hero-card:has(.role-gather)  { border-top-color: rgba(102,187,106,0.85); }
.hero-card:has(.role-special) { border-top-color: rgba(171,71,188,0.85); }
/* Corner brackets — always visible at 0.35 opacity */
.hero-card::before, .hero-card::after {
  content: '';
  position: absolute;
  width: 12px; height: 12px;
  opacity: 0.35;
  transition: opacity var(--transition);
  pointer-events: none;
}
.hero-card::before {
  top: -1px; left: -1px;
  border-top: 2px solid var(--ice-blue);
  border-left: 2px solid var(--ice-blue);
  border-radius: var(--radius) 0 0 0;
}
.hero-card::after {
  bottom: -1px; right: -1px;
  border-bottom: 2px solid var(--ice-blue);
  border-right: 2px solid var(--ice-blue);
  border-radius: 0 0 var(--radius) 0;
}
.hero-card:hover {
  border-color: rgba(79,195,247,0.4);
  box-shadow: 0 0 24px rgba(79,195,247,0.18), 0 4px 20px rgba(0,0,0,0.5);
}
.hero-card:hover::before, .hero-card:hover::after { opacity: 1; }
.hc-top {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 12px;
}
.hc-avatar {
  width: 50px; height: 50px;
  border-radius: 50%;
  background: var(--bg-card-2);
  border: 2px solid var(--border-glow);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.6rem;
  flex-shrink: 0;
  box-shadow: 0 0 10px rgba(79,195,247,0.12);
}
.hc-name { font-weight: 700; font-size: 0.95rem; color: var(--text-primary); letter-spacing: 0.01em; }
.hc-role {
  display: inline-block;
  font-size: 0.65rem;
  font-weight: 600;
  padding: 2px 7px;
  border-radius: 10px;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  margin-top: 3px;
}
.role-combat   { background: rgba(239,83,80,0.18); color: var(--red-light); border: 1px solid rgba(239,83,80,0.3); }
.role-dev,
.role-develop  { background: rgba(79,195,247,0.18); color: var(--ice-blue); border: 1px solid rgba(79,195,247,0.3); }
.role-gather   { background: rgba(102,187,106,0.18); color: var(--green); border: 1px solid rgba(102,187,106,0.3); }
.role-special  { background: rgba(171,71,188,0.18); color: var(--purple-light); border: 1px solid rgba(171,71,188,0.3); }
.hc-desc { font-size: 0.78rem; color: var(--text-secondary); line-height: 1.55; margin-bottom: 10px; }
.hc-stars { color: var(--gold); font-size: 0.85rem; margin-bottom: 8px; }
.hc-skills { display: flex; flex-wrap: wrap; gap: 5px; }
.hc-skill-tag {
  background: var(--bg-card-2);
  border: 1px solid var(--border);
  border-radius: 4px;
  padding: 2px 7px;
  font-size: 0.68rem;
  color: var(--text-muted);
}

/* ── GEAR GRID ── */
.gear-set {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 20px;
  margin-bottom: 16px;
}
.gear-set-title {
  font-family: 'Cinzel', serif;
  font-size: 0.95rem;
  color: var(--gold);
  margin-bottom: 14px;
  display: flex;
  align-items: center;
  gap: 8px;
}
.gear-pieces {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
  gap: 10px;
}
/* Gear pieces — gradient background */
.gear-piece {
  background: linear-gradient(135deg, #0f2440 0%, #091829 100%);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 10px 12px;
  font-size: 0.78rem;
}
.gear-piece-name { color: var(--text-primary); font-weight: 500; margin-bottom: 3px; }
.gear-piece-bonus { color: var(--text-muted); font-size: 0.72rem; }

/* ── RESOURCE BAR ── */
.resource-list {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
  gap: 14px;
  margin-bottom: 24px;
}
/* Resource items — gradient background */
.resource-item {
  background: linear-gradient(135deg, #0f2440 0%, #091829 100%);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 14px 16px;
  display: flex;
  align-items: center;
  gap: 12px;
}
.resource-icon { font-size: 1.6rem; }
.resource-name { font-size: 0.82rem; font-weight: 600; color: var(--text-primary); }
.resource-desc { font-size: 0.72rem; color: var(--text-muted); margin-top: 2px; }

/* ── TAGS ── */
.tag {
  display: inline-block;
  background: rgba(79,195,247,0.1);
  border: 1px solid rgba(79,195,247,0.25);
  color: var(--ice-blue);
  border-radius: 4px;
  padding: 2px 8px;
  font-size: 0.72rem;
  font-weight: 500;
  margin: 2px;
}
.tag.gold { background: rgba(255,213,79,0.1); border-color: rgba(255,213,79,0.3); color: var(--gold-light); }
.tag.red  { background: rgba(239,83,80,0.1); border-color: rgba(239,83,80,0.3); color: #ff8a80; }
.tag.green{ background: rgba(102,187,106,0.1); border-color: rgba(102,187,106,0.3); color: var(--green-light); }
.tag.purple{ background: rgba(171,71,188,0.1); border-color: rgba(171,71,188,0.3); color: var(--purple-light); }

/* ── SNOWFLAKE PARTICLES (decorative) ── */
.snowflakes {
  position: fixed;
  top: 0; left: 0;
  width: 100%; height: 100%;
  pointer-events: none;
  z-index: -1;
  overflow: hidden;
}
.snowflake {
  position: absolute;
  top: -20px;
  color: rgba(255,255,255,0.15);
  font-size: 12px;
  animation: fall linear infinite;
  user-select: none;
}
@keyframes fall {
  0%   { transform: translateY(-20px) rotate(0deg); opacity: 0; }
  10%  { opacity: 1; }
  90%  { opacity: 0.3; }
  100% { transform: translateY(100vh) rotate(360deg); opacity: 0; }
}

/* ── OVERVIEW QUICKNAV ── */
.quick-nav {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
  gap: 12px;
  margin-bottom: 28px;
}
/* Quick nav cards — gradient + always-visible corner brackets */
.qn-card {
  background: linear-gradient(145deg, #0f2542 0%, #091829 100%);
  border: 1px solid var(--border);
  border-top: 2px solid rgba(79,195,247,0.5);
  border-radius: var(--radius);
  padding: 20px 16px;
  cursor: pointer;
  position: relative;
  transition: border-color var(--transition), border-top-color var(--transition), transform var(--transition), box-shadow var(--transition);
  text-align: center;
}
.qn-card::before, .qn-card::after {
  content: '';
  position: absolute;
  width: 12px; height: 12px;
  opacity: 0.35;
  transition: opacity var(--transition);
  pointer-events: none;
}
.qn-card::before {
  top: -1px; left: -1px;
  border-top: 2px solid var(--ice-blue);
  border-left: 2px solid var(--ice-blue);
  border-radius: var(--radius) 0 0 0;
}
.qn-card::after {
  bottom: -1px; right: -1px;
  border-bottom: 2px solid var(--ice-blue);
  border-right: 2px solid var(--ice-blue);
  border-radius: 0 0 var(--radius) 0;
}
.qn-card:hover {
  border-color: rgba(79,195,247,0.4);
  border-top-color: var(--ice-blue);
  transform: translateY(-4px);
  box-shadow: 0 0 24px rgba(79,195,247,0.2), 0 6px 20px rgba(0,0,0,0.5);
}
.qn-card:hover::before, .qn-card:hover::after { opacity: 1; }
.qn-card:hover .qn-icon { background: rgba(79,195,247,0.2); border-color: rgba(79,195,247,0.45); }
.qn-icon {
  font-size: 2rem;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 62px;
  height: 62px;
  background: rgba(79,195,247,0.1);
  border: 1px solid rgba(79,195,247,0.22);
  border-radius: 50%;
  margin: 0 auto 14px;
  transition: background var(--transition), border-color var(--transition);
}
.qn-title { font-size: 0.88rem; font-weight: 700; color: var(--ice-light); margin-bottom: 4px; }
.qn-desc { font-size: 0.7rem; color: var(--text-muted); line-height: 1.5; }

/* ── TABS ── */
.tabs {
  display: flex;
  gap: 0;
  border-bottom: 1px solid var(--border);
  margin-bottom: 20px;
  overflow-x: auto;
}
.tab-btn {
  background: none;
  border: none;
  padding: 10px 18px;
  font-size: 0.82rem;
  font-weight: 500;
  color: var(--text-muted);
  cursor: pointer;
  border-bottom: 2px solid transparent;
  white-space: nowrap;
  transition: color var(--transition), border-color var(--transition);
}
.tab-btn:hover { color: var(--text-primary); }
.tab-btn.active { color: var(--ice-blue); border-bottom-color: var(--ice-blue); }
.tab-panel { display: none; }
.tab-panel.active { display: block; }

/* ── ACCORDION ── */
.accordion { border: 1px solid var(--border); border-radius: var(--radius); overflow: hidden; margin-bottom: 20px; }
.acc-item {
  border-bottom: 1px solid var(--border);
  border-left: 3px solid transparent;
  transition: border-left-color var(--transition);
}
.acc-item:last-child { border-bottom: none; }
.acc-item.open { border-left-color: var(--ice-blue); }
.acc-header {
  width: 100%;
  background: var(--bg-card);
  border: none;
  padding: 14px 18px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  cursor: pointer;
  font-size: 0.85rem;
  font-weight: 500;
  color: var(--text-primary);
  transition: background var(--transition), color var(--transition);
  text-align: left;
  gap: 10px;
}
.acc-header:hover { background: var(--bg-card-2); color: var(--ice-light); }
.acc-item.open .acc-header { color: var(--ice-blue); }
.acc-arrow { color: var(--text-muted); transition: transform var(--transition); font-size: 0.75rem; flex-shrink: 0; }
.acc-item.open .acc-arrow { transform: rotate(180deg); }
.acc-body {
  max-height: 0;
  overflow: hidden;
  opacity: 0;
  transition: max-height 0.4s cubic-bezier(0.4, 0, 0.2, 1), opacity 0.3s ease;
  background: rgba(4, 14, 26, 0.8);
}
.acc-item.open .acc-body { opacity: 1; }
.acc-body-inner {
  padding: 18px 20px;
  font-size: 0.82rem;
  color: var(--text-secondary);
  line-height: 1.7;
  border-left: none;
}
.acc-body-inner ul { padding-left: 18px; }
.acc-body-inner ul li { margin-bottom: 6px; }
.acc-body-inner strong { color: var(--text-primary); }

/* ── NAV RAIL ── */
.nav-rail { display: none; }

/* ── MOBILE ── */
.mobile-overlay {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.6);
  z-index: 90;
}

body.sidebar-open { overflow: hidden; }

@media (max-width: 900px) {
  /* ── sidebar drawer ── */
  .sidebar {
    transform: translateX(-100%);
    -webkit-overflow-scrolling: touch;
    overscroll-behavior: contain;
  }
  .sidebar.open {
    transform: translateX(0);
    box-shadow: 4px 0 30px rgba(0,0,0,0.8);
  }

  /* ── nav rail ── */
  .nav-rail {
    display: flex;
    flex-direction: column;
    align-items: center;
    position: fixed;
    left: 0; top: 0; bottom: 0;
    width: 52px;
    background: linear-gradient(180deg, #020a14 0%, #050f1c 100%);
    border-right: 1px solid var(--border);
    z-index: 95;
    overflow-y: auto;
    overflow-x: hidden;
    padding: 8px 0 16px;
    scrollbar-width: none;
  }
  .nav-rail::-webkit-scrollbar { display: none; }

  .rail-btn {
    width: 44px;
    height: 44px;
    border: none;
    background: transparent;
    border-radius: 10px;
    font-size: 1.25rem;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 1px 0;
    flex-shrink: 0;
    touch-action: manipulation;
    transition: background var(--transition), transform 0.1s ease;
    position: relative;
  }
  .rail-btn:active { transform: scale(0.88); }
  .rail-btn.active {
    background: rgba(79,195,247,0.15);
    box-shadow: inset 3px 0 0 var(--ice-blue);
  }
  .rail-btn.active::after {
    content: '';
    position: absolute;
    right: 0; top: 8px; bottom: 8px;
    width: 3px;
    background: var(--ice-blue);
    border-radius: 2px 0 0 2px;
    display: none; /* left-side indicator via box-shadow instead */
  }

  .rail-divider {
    width: 28px;
    height: 1px;
    background: var(--border);
    margin: 4px 0;
    flex-shrink: 0;
  }

  /* ── layout shift for rail ── */
  .main-content { margin-left: 52px; }
  .hamburger { display: flex; width: 44px; height: 44px; }
  .content-area { padding: 20px 16px; width: 100%; box-sizing: border-box; overflow-x: hidden; }
  .mobile-overlay.show { display: block; }
  .hero-banner { padding: 28px 20px; min-height: auto; }
  .hero-banner h2 { font-size: 1.5rem; }
  .top-bar { padding: 10px 16px; }
  .nav-item { padding: 12px 16px; touch-action: manipulation; min-height: 44px; display: flex; align-items: center; }
  .section { overflow-x: hidden; }
}

@media (max-width: 600px) {
  /* section headings: drop decorative lines, tighten font so they fit on one line */
  .section-heading {
    font-size: 0.8rem;
    letter-spacing: 0.05em;
    gap: 8px;
    margin-top: 28px;
    margin-bottom: 14px;
    overflow: hidden;
  }
  .section-heading::before,
  .section-heading::after { display: none; }

  /* cards & layout */
  .cards-grid { grid-template-columns: 1fr; }
  .cards-grid-3 { grid-template-columns: 1fr; }
  .hero-stats { gap: 10px; flex-wrap: wrap; justify-content: center; }
  .hero-stat { min-width: 72px; }
  .quick-nav { grid-template-columns: repeat(2, 1fr); }

  /* troop triangle */
  .triangle-wrap { padding: 16px 12px; }
  .troop-nodes { gap: 10px; }
  .troop-node { min-width: 0; flex: 1 1 120px; padding: 12px 14px; }

  /* hero banner */
  .hero-banner h2 { font-size: 1.3rem; }
  .hero-banner .tagline { font-size: 0.8rem; }

  /* tip boxes & description text */
  .tip-box { padding: 12px 14px; font-size: 0.8rem; }
  .section-desc { font-size: 0.82rem; }
  p, li { overflow-wrap: break-word; word-break: break-word; }

  /* tabs — scroll if too many */
  .tabs { overflow-x: auto; -webkit-overflow-scrolling: touch; }
  .tab-btn { padding: 10px 14px; font-size: 0.78rem; }

  /* accordion */
  .acc-header { padding: 14px 16px; font-size: 0.82rem; }

  /* hero cards */
  .hc-top { flex-wrap: wrap; }
}

@media (max-width: 400px) {
  .section-heading { font-size: 0.72rem; letter-spacing: 0.03em; }
  .hero-stats { gap: 8px; }
  .hero-stat { min-width: 60px; padding: 10px 12px; }
  .hero-stat .stat-value { font-size: 1.2rem; }
  .content-area { padding: 14px 10px; }
  .troop-node { padding: 10px 10px; }
}

/* ── UTILITIES ── */
.mt-0 { margin-top: 0 !important; }
.mb-0 { margin-bottom: 0 !important; }
.mt-8 { margin-top: 8px; }
.mt-16 { margin-top: 16px; }
.mt-24 { margin-top: 24px; }
.mb-8 { margin-bottom: 8px; }
.mb-16 { margin-bottom: 16px; }
.mb-24 { margin-bottom: 24px; }
.text-gold { color: var(--gold) !important; }
.text-ice { color: var(--ice-blue) !important; }
.text-red { color: var(--red) !important; }
.text-green { color: var(--green) !important; }
.text-muted { color: var(--text-muted) !important; }
.font-cinzel { font-family: 'Cinzel', serif; }
.bold { font-weight: 700; }
ul.guide-list { list-style: none; padding: 0; }
ul.guide-list li {
  padding: 6px 0;
  padding-left: 16px;
  position: relative;
  font-size: 0.83rem;
  color: var(--text-secondary);
  line-height: 1.6;
}
ul.guide-list li::before {
  content: '▸';
  position: absolute;
  left: 0;
  color: var(--ice-blue);
  font-size: 0.75rem;
}
ul.guide-list li strong { color: var(--text-primary); }

/* ── SECTION PANEL ── */
.section-panel {
  background: rgba(13,31,51,0.5);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 24px 28px;
  margin-bottom: 28px;
  position: relative;
  overflow: hidden;
}
.section-panel::before {
  content: '';
  position: absolute;
  top: 0; left: 0; right: 0;
  height: 3px;
  background: linear-gradient(90deg, var(--ice-blue) 0%, rgba(79,195,247,0.15) 60%, transparent 100%);
}
.section-panel.sp-red::before    { background: linear-gradient(90deg, var(--red)    0%, rgba(239,83,80,0.15)  60%, transparent 100%); }
.section-panel.sp-gold::before   { background: linear-gradient(90deg, var(--gold)   0%, rgba(255,213,79,0.15) 60%, transparent 100%); }
.section-panel.sp-green::before  { background: linear-gradient(90deg, var(--green)  0%, rgba(102,187,106,0.15) 60%, transparent 100%); }
.section-panel.sp-purple::before { background: linear-gradient(90deg, var(--purple) 0%, rgba(171,71,188,0.15) 60%, transparent 100%); }

/* Divider */
.divider {
  border: none;
  border-top: 1px solid var(--border);
  margin: 24px 0;
}

/* =============================================
   GEAR ADVISOR
   ============================================= */
.ga-dropzone {
  border: 2px dashed var(--border-glow);
  border-radius: var(--radius);
  background: rgba(13,31,51,0.4);
  padding: 32px 20px;
  text-align: center;
  cursor: pointer;
  transition: var(--transition);
  margin-bottom: 20px;
}
.ga-dropzone:hover, .ga-dropzone.ga-dragover {
  border-color: var(--ice-blue);
  background: rgba(79,195,247,0.06);
}
.ga-dropzone-icon { display: block; font-size: 2rem; margin-bottom: 10px; }
.ga-dropzone-inner { color: var(--text-secondary); }
.ga-dropzone-inner strong { color: var(--text-primary); }
.ga-dropzone-sub { font-size: 0.85rem; margin-top: 4px; color: var(--text-muted); }

.ga-entries {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(340px, 1fr));
  gap: 16px;
  margin-bottom: 20px;
}
.ga-entry-card {
  position: relative;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 14px;
  display: flex;
  gap: 12px;
}
.ga-entry-thumb {
  flex-shrink: 0;
  width: 72px;
  height: 72px;
  border-radius: var(--radius-sm);
  overflow: hidden;
  background: var(--bg-dark);
}
.ga-entry-thumb img { width: 100%; height: 100%; object-fit: cover; }
.ga-entry-body { flex: 1; min-width: 0; }
.ga-entry-remove {
  position: absolute;
  top: 6px; right: 6px;
  width: 22px; height: 22px;
  border-radius: 50%;
  border: none;
  background: rgba(255,255,255,0.06);
  color: var(--text-secondary);
  cursor: pointer;
  font-size: 0.75rem;
  line-height: 1;
}
.ga-entry-remove:hover { background: var(--red); color: #fff; }
.ga-entry-loading, .ga-entry-error { font-size: 0.85rem; color: var(--text-secondary); padding-top: 6px; }
.ga-entry-error { color: var(--red-light); }
.ga-entry-notes { font-size: 0.8rem; color: var(--gold-light); margin: 6px 0; }

.ga-entry-header { display: flex; gap: 8px; flex-wrap: wrap; margin-bottom: 6px; }
.ga-badge {
  font-size: 0.7rem;
  font-weight: 600;
  padding: 2px 8px;
  border-radius: 20px;
  background: rgba(79,195,247,0.12);
  color: var(--ice-blue);
  border: 1px solid rgba(79,195,247,0.3);
  white-space: nowrap;
}
.ga-badge-conf-low { background: rgba(239,83,80,0.12); color: var(--red-light); border-color: rgba(239,83,80,0.3); }
.ga-badge-conf-medium { background: rgba(255,167,38,0.12); color: var(--orange); border-color: rgba(255,167,38,0.3); }
.ga-badge-conf-high { background: rgba(102,187,106,0.12); color: var(--green-light); border-color: rgba(102,187,106,0.3); }
.ga-badge-unknown { background: rgba(239,83,80,0.12); color: var(--red-light); border-color: rgba(239,83,80,0.3); }

.ga-form { display: flex; flex-direction: column; gap: 6px; }
.ga-table { display: flex; flex-direction: column; gap: 6px; }
.ga-row { display: flex; flex-wrap: wrap; gap: 6px; }
.ga-materials { margin-top: 4px; padding-top: 6px; border-top: 1px dashed var(--border); }

.ga-field {
  display: flex;
  flex-direction: column;
  gap: 2px;
  flex: 1;
  min-width: 70px;
}
.ga-field-label { font-size: 0.65rem; text-transform: uppercase; letter-spacing: 0.03em; color: var(--text-muted); }
.ga-field input, .ga-field select {
  background: var(--bg-dark);
  border: 1px solid var(--border);
  border-radius: 6px;
  color: var(--text-primary);
  font-size: 0.82rem;
  padding: 5px 7px;
  font-family: inherit;
}
.ga-field input:focus, .ga-field select:focus { outline: none; border-color: var(--ice-blue); }

.ga-actions { display: none; gap: 12px; margin-bottom: 24px; }
.ga-btn {
  font-family: 'Cinzel', serif;
  font-size: 0.85rem;
  padding: 10px 22px;
  border-radius: var(--radius-sm);
  border: 1px solid var(--border-glow);
  cursor: pointer;
  transition: var(--transition);
}
.ga-btn-primary { background: linear-gradient(90deg, var(--ice-blue), var(--ice-light)); color: var(--bg-darkest); border: none; font-weight: 600; }
.ga-btn-primary:hover { filter: brightness(1.1); }
.ga-btn-ghost { background: transparent; color: var(--text-secondary); }
.ga-btn-ghost:hover { color: var(--text-primary); border-color: var(--ice-blue); }

.ga-results { display: flex; flex-direction: column; gap: 20px; }
.ga-result-group {
  background: rgba(13,31,51,0.5);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 18px 20px;
}
.ga-result-group-title { font-family: 'Cinzel', serif; color: var(--ice-blue); font-size: 1rem; margin-bottom: 4px; }
.ga-result-group-sub { font-size: 0.8rem; color: var(--text-muted); margin-bottom: 12px; }
.ga-result-item {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 12px 14px;
  margin-bottom: 10px;
}
.ga-result-item:last-child { margin-bottom: 0; }
.ga-result-item-head { display: flex; align-items: center; gap: 10px; margin-bottom: 6px; }
.ga-result-rank { font-family: 'Cinzel', serif; color: var(--gold); font-weight: 700; }
.ga-result-label { color: var(--text-primary); font-weight: 600; }
.ga-result-stat { font-size: 0.82rem; color: var(--text-secondary); margin-bottom: 6px; }

.ga-progress-list { display: flex; flex-direction: column; gap: 6px; }
.ga-progress-row { display: grid; grid-template-columns: 110px 1fr 90px; align-items: center; gap: 8px; font-size: 0.78rem; }
.ga-progress-name { color: var(--text-secondary); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.ga-progress-bar { height: 6px; border-radius: 4px; background: var(--bg-dark); overflow: hidden; }
.ga-progress-fill { height: 100%; background: var(--orange); }
.ga-progress-fill-ready { background: var(--green); }
.ga-progress-fill-empty { background: var(--border); }
.ga-progress-count { color: var(--text-muted); text-align: right; white-space: nowrap; }

.ga-overview-table { display: flex; flex-direction: column; gap: 4px; }
.ga-overview-row { display: grid; grid-template-columns: 100px 1fr 90px; gap: 8px; font-size: 0.85rem; padding: 4px 0; border-bottom: 1px solid var(--border); }
.ga-overview-slot { color: var(--text-primary); text-transform: capitalize; }
.ga-overview-tier { color: var(--text-secondary); }
.ga-overview-stars { color: var(--gold); text-align: right; }

.ga-overview-block {
  background: rgba(13,31,51,0.4);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 16px 18px;
  margin-bottom: 20px;
}
.ga-subheading { font-family: 'Cinzel', serif; color: var(--ice-blue); font-size: 0.95rem; margin-bottom: 10px; }
.ga-subheading-note { font-family: 'Inter', sans-serif; font-size: 0.75rem; color: var(--text-muted); font-weight: 400; text-transform: none; }
.ga-overview-edit-row { align-items: flex-end; margin-bottom: 8px; }

.ga-manual-add { display: flex; gap: 10px; margin: 4px 0 20px; flex-wrap: wrap; }

.ga-btn-small { padding: 6px 14px; font-size: 0.78rem; }

.ga-row-remove {
  align-self: flex-end;
  width: 30px; height: 30px;
  border-radius: 6px;
  border: 1px solid var(--border);
  background: transparent;
  color: var(--text-muted);
  cursor: pointer;
  font-size: 0.75rem;
}
.ga-row-remove:hover { background: var(--red); border-color: var(--red); color: #fff; }

.ga-raw-ocr { margin-top: 8px; font-size: 0.75rem; color: var(--text-muted); }
.ga-raw-ocr summary { cursor: pointer; color: var(--text-secondary); }
.ga-raw-ocr-text {
  white-space: pre-wrap;
  background: var(--bg-dark);
  border: 1px solid var(--border);
  border-radius: 6px;
  padding: 8px;
  margin-top: 6px;
  font-family: monospace;
  font-size: 0.7rem;
  color: var(--text-secondary);
}
