@import url('https://fonts.googleapis.com/css2?family=Fredoka:wght@600;700&family=Nunito:wght@600;700;800;900&display=swap');

:root {
  /* Ninja Legacy Night Village Sky (matched to winter-village-2026) */
  --sky-950: #0a1428;
  --sky-900: #102042;
  --sky-800: #18305e;
  --sky-700: #22417a;

  /* Authentic Ninja Saga In-Game Panel Chrome */
  --ink-black: #160c06;
  --steel-corner: #7c8d9e;
  --steel-dark: #495766;
  --wood-frame: #845026;
  --wood-deep: #5a3214;
  --wood-dark: #3d210d;
  --slot-brown: #4c2e19;
  --slot-border: #2c180b;

  /* Ninja Saga Tan Parchment */
  --tan-50: #fdf3e3;
  --tan-100: #f2dcb9;
  --tan-200: #e3c295;
  --tan-300: #cfa573;
  --tan-400: #b88855;

  /* Text on Parchment */
  --text-dark: #29160a;
  --text-mid: #5a351b;
  --text-muted: #7d4c24;

  /* Iconic Ninja Saga HUD Accents */
  --ns-green-top: #26c924;
  --ns-green-bot: #0a7a0c;
  --ns-green-rim: #ffeb3b;
  --ns-gold-top: #ffd63b;
  --ns-gold-bot: #e38607;
  --ns-gold-lip: #964900;
  --ns-crimson-top: #e84438;
  --ns-crimson-bot: #a11717;
  --ns-token-blue: #22a8f5;
  --ns-token-deep: #095999;
  --ns-gold-coin: #f9b918;
  --ns-online: #4ef536;
  --ns-pink-pts: #ff4fa3;

  --font-display: "Fredoka", "Nunito", system-ui, sans-serif;
  --font-body: "Nunito", system-ui, -apple-system, sans-serif;
  --shadow-panel: 0 10px 0 rgba(7, 12, 26, 0.55);
  --shadow-card: 0 4px 0 rgba(22, 12, 6, 0.35);
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; }

body {
  margin: 0;
  font-family: var(--font-body);
  font-weight: 700;
  font-size: 16px;
  line-height: 1.55;
  color: var(--tan-100);
  background-color: var(--sky-950);
  background-image:
    radial-gradient(2px 2px at 14% 18%, rgba(255,255,255,0.45), transparent),
    radial-gradient(2px 2px at 42% 9%, rgba(255,240,180,0.4), transparent),
    radial-gradient(1.5px 1.5px at 78% 22%, rgba(255,255,255,0.4), transparent),
    radial-gradient(2px 2px at 88% 44%, rgba(255,255,255,0.3), transparent),
    linear-gradient(180deg, var(--sky-950) 0%, var(--sky-900) 55%, var(--sky-950) 100%);
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  overflow-x: hidden;
}

main { flex: 1; }
a { color: inherit; text-decoration: none; }
img { max-width: 100%; display: block; }

::-webkit-scrollbar { width: 10px; }
::-webkit-scrollbar-track { background: var(--sky-950); }
::-webkit-scrollbar-thumb { background: var(--wood-frame); border: 2px solid var(--sky-950); border-radius: 6px; }
::-webkit-scrollbar-thumb:hover { background: var(--ns-gold-coin); }

.container { width: min(1180px, calc(100% - 32px)); margin: 0 auto; }

/* ================= NINJA SAGA HUD CURRENCY COINS ================= */
.ns-coin {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 24px;
  height: 24px;
  border-radius: 50%;
  font-family: var(--font-display);
  font-size: 14px;
  font-weight: 700;
  border: 2.5px solid var(--ink-black);
  box-shadow: inset 0 2px 0 rgba(255,255,255,0.55), 0 2px 0 rgba(0,0,0,0.45);
  flex-shrink: 0;
  line-height: 1;
}
.ns-coin.t {
  background: radial-gradient(circle at 35% 30%, #6ee0ff 0%, var(--ns-token-blue) 55%, var(--ns-token-deep) 100%);
  color: #ffffff;
  text-shadow: 0 1px 0 #052c4d;
}
.ns-coin.g {
  background: radial-gradient(circle at 35% 30%, #fff18f 0%, var(--ns-gold-coin) 55%, #b86a00 100%);
  color: #4a2200;
  text-shadow: 0 1px 0 rgba(255,255,255,0.55);
}
.ns-coin.e {
  background: radial-gradient(circle at 35% 30%, #ffe680 0%, #e5930b 65%, #753800 100%);
  color: #fff;
  border-color: #fff2a6;
}
.ns-coin.sm { width: 20px; height: 20px; font-size: 11px; border-width: 2px; }

/* ================= STICKY TOPBAR WITH REAL NINJA LEGACY LOGO ================= */
.ns-topbar {
  position: sticky;
  top: 0;
  z-index: 70;
  background: linear-gradient(180deg, rgba(10, 20, 42, 0.96) 0%, rgba(16, 32, 66, 0.94) 100%);
  backdrop-filter: blur(8px);
  border-bottom: 3px solid var(--ink-black);
  box-shadow: 0 3px 0 rgba(255, 198, 56, 0.72), 0 8px 24px rgba(0, 0, 0, 0.45);
}
.ns-topbar-inner {
  width: min(1240px, calc(100% - 28px));
  margin: 0 auto;
  height: 74px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}
.ns-brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  flex-shrink: 0;
}
.ns-brand img {
  height: 62px;
  width: auto;
  filter: drop-shadow(0 4px 8px rgba(0, 0, 0, 0.65));
  transition: transform 0.16s;
}
.ns-brand:hover img { transform: scale(1.04) rotate(-1deg); }

.ns-nav {
  display: flex;
  align-items: center;
  gap: 6px;
}
.ns-nav-link {
  position: relative;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 8px 14px;
  font-family: var(--font-display);
  font-size: 15px;
  font-weight: 700;
  letter-spacing: 0.03em;
  color: var(--tan-50);
  border-radius: 8px;
  border: 2px solid transparent;
  transition: all 0.14s;
}
.ns-nav-link:hover {
  color: var(--ns-gold-top);
  background: rgba(255, 214, 59, 0.1);
  border-color: rgba(255, 214, 59, 0.3);
}
.ns-nav-link.active {
  color: #fff;
  background: linear-gradient(180deg, rgba(132, 80, 38, 0.9), rgba(90, 50, 20, 0.95));
  border-color: var(--ns-gold-coin);
  box-shadow: inset 0 1px 0 rgba(255,255,255,0.28), 0 2px 0 var(--ink-black);
}

.ns-nav-right {
  display: flex;
  align-items: center;
  gap: 10px;
}
.ns-hud-wallet {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 5px 12px 5px 8px;
  background: linear-gradient(180deg, #5e381c 0%, #3d210d 100%);
  border: 2.5px solid var(--ink-black);
  border-radius: 999px;
  box-shadow: inset 0 1px 0 rgba(255,220,160,0.3), 0 2px 0 rgba(0,0,0,0.45);
  font-size: 14px;
  font-weight: 900;
  color: var(--tan-50);
}
.ns-hud-wallet .t-val { color: #7be0ff; }

/* ================= ICONIC NINJA SAGA BUTTONS ================= */
.ns-btn {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 11px 22px;
  font-family: var(--font-display);
  font-size: 15px;
  font-weight: 700;
  letter-spacing: 0.03em;
  border-radius: 9px;
  cursor: pointer;
  border: 3px solid var(--ink-black);
  transition: transform 0.1s, filter 0.12s;
  user-select: none;
  white-space: nowrap;
}
.ns-btn:hover { filter: brightness(1.08); }
.ns-btn:active { transform: translateY(3px); }
.ns-btn.sm { padding: 7px 14px; font-size: 13px; border-width: 2.5px; border-radius: 7px; }
.ns-btn.block { width: 100%; }

/* Classic Ninja Saga Glossy Emerald + Yellow Rim Button (Exact In-Game Look!) */
.ns-btn.emerald {
  background: linear-gradient(180deg, #35df30 0%, #15a817 48%, #0a780c 52%, #0d8e0f 100%);
  color: #ffffff;
  paint-order: stroke fill;
  -webkit-text-stroke: 3.5px var(--ink-black);
  text-shadow: 0 2px 0 var(--ink-black);
  box-shadow: inset 0 0 0 2px var(--ns-green-rim), inset 0 3px 6px rgba(255,255,255,0.45), 0 4px 0 var(--ink-black);
}
.ns-btn.emerald:active { box-shadow: inset 0 0 0 2px var(--ns-green-rim), 0 1px 0 var(--ink-black); }

/* Golden Scroll CTA Button */
.ns-btn.gold {
  background: linear-gradient(180deg, #ffe264 0%, #f9b71c 50%, #e08305 100%);
  color: #3a1700;
  text-shadow: 0 1px 0 rgba(255,255,255,0.5);
  box-shadow: inset 0 2px 0 rgba(255,255,255,0.65), inset 0 -4px 0 var(--ns-gold-lip), 0 4px 0 var(--ink-black);
}
.ns-btn.gold:active { box-shadow: inset 0 -2px 0 var(--ns-gold-lip), 0 1px 0 var(--ink-black); }

/* Kinjutsu Crimson Button */
.ns-btn.crimson {
  background: linear-gradient(180deg, #f25749 0%, #c92020 55%, #8f0f0f 100%);
  color: #ffffff;
  paint-order: stroke fill;
  -webkit-text-stroke: 3px var(--ink-black);
  text-shadow: 0 2px 0 var(--ink-black);
  box-shadow: inset 0 2px 0 rgba(255,255,255,0.35), inset 0 -4px 0 #590808, 0 4px 0 var(--ink-black);
}

/* Dark Indigo Ghost Button */
.ns-btn.ghost {
  background: rgba(16, 32, 66, 0.8);
  color: var(--tan-50);
  border-color: var(--tan-400);
  box-shadow: 0 3px 0 rgba(0, 0, 0, 0.45);
}
.ns-btn.ghost:hover { border-color: var(--ns-gold-top); color: var(--ns-gold-top); }

/* ================= STROKED NINJA SAGA HEADINGS ================= */
.ns-title {
  margin: 0;
  font-family: var(--font-display);
  font-weight: 700;
  font-size: clamp(30px, 4.4vw, 50px);
  line-height: 1.08;
  color: #ffffff;
  paint-order: stroke fill;
  -webkit-text-stroke: 7px var(--ink-black);
  text-shadow: 0 5px 0 var(--ink-black);
}
.ns-title.sm {
  font-size: clamp(24px, 3vw, 34px);
  -webkit-text-stroke: 5.5px var(--ink-black);
  text-shadow: 0 4px 0 var(--ink-black);
}
.ns-title em { font-style: normal; color: var(--ns-gold-top); }

.ns-eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 3px 12px;
  border-radius: 999px;
  background: rgba(16, 32, 66, 0.85);
  border: 2px solid var(--ns-gold-coin);
  font-family: var(--font-display);
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--ns-gold-top);
  margin-bottom: 10px;
}

/* ================= AUTHENTIC NINJA SAGA RIVETED PANEL ================= */
.ns-panel {
  position: relative;
  background: linear-gradient(180deg, #9c6232 0%, var(--wood-frame) 45%, var(--wood-deep) 100%);
  padding: 12px;
  border: 3.5px solid var(--ink-black);
  border-radius: 12px;
  box-shadow: inset 0 2px 0 rgba(255, 224, 175, 0.4), var(--shadow-panel);
}
/* Riveted steel corner brackets (exact Ninja Saga in-game panel detail!) */
.ns-panel::before, .ns-panel::after {
  content: "";
  position: absolute;
  left: 6px;
  right: 6px;
  height: 12px;
  pointer-events: none;
  z-index: 3;
  background:
    radial-gradient(circle at 6px 6px, var(--steel-corner) 0 4.5px, var(--ink-black) 5px 6.5px, transparent 7px),
    radial-gradient(circle at calc(100% - 6px) 6px, var(--steel-corner) 0 4.5px, var(--ink-black) 5px 6.5px, transparent 7px);
}
.ns-panel::before { top: 6px; }
.ns-panel::after { bottom: 6px; }

.ns-panel-ribbon {
  position: absolute;
  top: -22px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 6;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 6px 26px;
  font-family: var(--font-display);
  font-size: 16px;
  font-weight: 700;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  color: #ffffff;
  paint-order: stroke fill;
  -webkit-text-stroke: 3.5px var(--ink-black);
  text-shadow: 0 2px 0 var(--ink-black);
  background: linear-gradient(180deg, #b8783c 0%, #864d1f 100%);
  border: 3px solid var(--ink-black);
  border-radius: 8px;
  box-shadow: inset 0 2px 0 rgba(255, 228, 170, 0.45), 0 4px 0 rgba(0, 0, 0, 0.4);
  white-space: nowrap;
}
.ns-panel.has-ribbon { margin-top: 26px; }
.ns-panel-body {
  background: linear-gradient(180deg, var(--tan-100) 0%, var(--tan-200) 100%);
  border: 3px solid var(--wood-dark);
  border-radius: 7px;
  padding: 26px 22px 22px;
  color: var(--text-dark);
  box-shadow: inset 0 3px 0 rgba(61, 33, 13, 0.22);
}
.ns-panel.has-ribbon .ns-panel-body { padding-top: 32px; }

/* ================= FULL-BLEED VILLAGE HERO ================= */
.ns-hero {
  position: relative;
  padding: 46px 0 88px;
  background:
    linear-gradient(95deg, rgba(10, 20, 40, 0.94) 0%, rgba(16, 32, 66, 0.78) 48%, rgba(10, 20, 40, 0.42) 100%),
    url('/art/portal/hero-village.jpg') center center / cover no-repeat;
  border-bottom: 4px solid var(--ink-black);
  box-shadow: inset 0 -4px 0 rgba(255, 198, 56, 0.45);
  overflow: hidden;
}
.ns-hero-grid {
  display: grid;
  grid-template-columns: 1.08fr 0.92fr;
  gap: 28px;
  align-items: center;
  position: relative;
  z-index: 2;
}
.hero-logo {
  width: min(360px, 85%);
  height: auto;
  margin: 0 0 12px -8px;
  filter: drop-shadow(0 8px 16px rgba(0, 0, 0, 0.7));
}
.ns-hero-copy p {
  font-size: 17px;
  color: var(--tan-50);
  max-width: 530px;
  margin: 12px 0 22px;
  text-shadow: 0 2px 6px rgba(0, 0, 0, 0.75);
}
.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-bottom: 18px;
}
.hero-badges {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}
.hero-chip {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 5px 12px;
  background: rgba(10, 20, 40, 0.82);
  border: 2px solid var(--tan-400);
  border-radius: 8px;
  font-size: 12.5px;
  font-weight: 800;
  color: var(--tan-50);
}

/* Right Hero Visual: Classic Shinobi Duo + HUD Server Status Card */
.hero-showcase {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
}
.hero-duo {
  width: min(370px, 88%);
  height: auto;
  margin-bottom: -48px;
  position: relative;
  z-index: 2;
  filter: drop-shadow(0 10px 18px rgba(0, 0, 0, 0.65));
}
.hero-status-card {
  position: relative;
  z-index: 3;
  width: 100%;
  max-width: 430px;
}
.live-pill {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding: 3px 11px;
  background: var(--slot-brown);
  color: #ffffff;
  border: 2px solid var(--ink-black);
  border-radius: 999px;
  font-size: 11px;
  font-weight: 900;
  text-transform: uppercase;
  letter-spacing: 0.06em;
}
.live-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--ns-online);
  box-shadow: 0 0 8px var(--ns-online);
}
.hud-stats-row {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 8px;
  margin: 12px 0 14px;
}
.hud-stat {
  background: var(--slot-brown);
  border: 2.5px solid var(--ink-black);
  border-radius: 7px;
  padding: 8px 6px;
  text-align: center;
  box-shadow: inset 0 2px 0 rgba(0,0,0,0.35);
}
.hud-stat strong {
  display: block;
  font-family: var(--font-display);
  font-size: 21px;
  color: var(--ns-gold-top);
  line-height: 1.1;
}
.hud-stat span {
  font-size: 10.5px;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--tan-200);
}

/* ================= VILLAGE BUILDINGS DOCK ================= */
.village-dock-wrap {
  position: relative;
  margin-top: -52px;
  z-index: 12;
  padding-bottom: 18px;
}
.village-dock {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 12px;
}
.bldg-card {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  padding: 12px 10px 14px;
  background: linear-gradient(180deg, #1b3463 0%, #102042 100%);
  border: 3px solid var(--ink-black);
  border-radius: 10px;
  color: var(--tan-50);
  box-shadow: inset 0 1px 0 rgba(255,255,255,0.18), 0 5px 0 rgba(0,0,0,0.45);
  transition: transform 0.14s, border-color 0.14s;
}
.bldg-card:hover {
  transform: translateY(-4px);
  border-color: var(--ns-gold-top);
}
.bldg-card img {
  height: 76px;
  width: auto;
  object-fit: contain;
  margin-bottom: 8px;
  filter: drop-shadow(0 4px 5px rgba(0,0,0,0.55));
  transition: filter 0.16s, transform 0.16s;
}
.bldg-card:hover img {
  transform: scale(1.06);
  filter: drop-shadow(0 0 10px rgba(255, 224, 92, 0.9));
}
.bldg-card strong {
  font-family: var(--font-display);
  font-size: 15px;
  color: var(--ns-gold-top);
  text-shadow: 0 2px 0 var(--ink-black);
}
.bldg-card small {
  font-size: 11.5px;
  color: var(--tan-200);
  margin-top: 2px;
}

/* ================= SECTIONS ================= */
.band { padding: 56px 0; position: relative; }
.band.alt {
  background: linear-gradient(180deg, rgba(24, 48, 94, 0.52) 0%, rgba(16, 32, 66, 0.65) 100%);
  border-top: 2px solid rgba(255, 214, 59, 0.14);
  border-bottom: 2px solid rgba(255, 214, 59, 0.14);
}
.band.village-cta {
  background:
    linear-gradient(180deg, rgba(10, 20, 40, 0.84) 0%, rgba(16, 32, 66, 0.88) 100%),
    url('/art/portal/hero-village.jpg') center bottom / cover no-repeat;
  border-top: 3px solid var(--ink-black);
}
.section-head { text-align: center; margin-bottom: 30px; }
.section-head p { max-width: 640px; margin: 10px auto 0; color: var(--tan-100); opacity: 0.92; }

/* ================= NINJA SAGA TABS ================= */
.ns-tabs {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-bottom: -3px;
  padding-left: 16px;
  position: relative;
  z-index: 5;
}
.ns-tab {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 9px 18px;
  font-family: var(--font-display);
  font-size: 14px;
  font-weight: 700;
  color: var(--tan-50);
  background: linear-gradient(180deg, #744722 0%, #522f13 100%);
  border: 3px solid var(--ink-black);
  border-bottom: none;
  border-radius: 9px 9px 0 0;
  cursor: pointer;
  transition: background 0.12s;
}
.ns-tab:hover { background: linear-gradient(180deg, #985f2e 0%, #6d401b 100%); }
.ns-tab.active {
  background: linear-gradient(180deg, #ffd44c 0%, #e5930b 100%);
  color: #321500;
  box-shadow: inset 0 2px 0 rgba(255,255,255,0.55);
}

/* ================= STORE BALANCE BAR & PACK CARDS ================= */
.ns-wallet-bar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  padding: 13px 18px;
  margin-bottom: 22px;
  background: linear-gradient(180deg, #5e381c 0%, #3d210d 100%);
  border: 3px solid var(--ink-black);
  border-radius: 10px;
  box-shadow: inset 0 2px 0 rgba(255, 224, 168, 0.25), 0 5px 0 rgba(0, 0, 0, 0.4);
  color: var(--tan-50);
}
.wallet-pills { display: flex; flex-wrap: wrap; align-items: center; gap: 10px; }
.wallet-pill {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding: 5px 12px;
  background: rgba(16, 32, 66, 0.72);
  border: 2px solid var(--tan-400);
  border-radius: 999px;
  font-size: 14px;
  font-weight: 900;
}

.store-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(256px, 1fr));
  gap: 16px;
}
.ns-pack-card {
  position: relative;
  display: flex;
  flex-direction: column;
  background: linear-gradient(180deg, var(--tan-50) 0%, var(--tan-100) 100%);
  border: 3px solid var(--ink-black);
  border-radius: 10px;
  padding: 36px 15px 15px;
  color: var(--text-dark);
  box-shadow: inset 0 2px 0 rgba(255,255,255,0.65), var(--shadow-card);
  transition: transform 0.14s, box-shadow 0.14s;
}
.ns-pack-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 0 0 2px var(--ns-gold-top), 0 8px 0 rgba(22, 12, 6, 0.45);
}
.ns-pack-card.legendary {
  background: linear-gradient(180deg, #fff9e6 0%, #f5daa3 100%);
}
.pack-badge {
  position: absolute;
  top: 9px;
  right: 10px;
  padding: 3px 10px;
  font-family: var(--font-display);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  border-radius: 5px;
  border: 2px solid var(--ink-black);
  background: linear-gradient(180deg, #e84438, #b01818);
  color: #ffffff;
  box-shadow: 0 2px 0 rgba(0,0,0,0.3);
}
.ns-pack-card.legendary .pack-badge {
  background: linear-gradient(180deg, #ffe159, #e38a07);
  color: #381500;
}
.pack-head {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 10px;
}
.pack-icon-box {
  flex: 0 0 58px;
  width: 58px;
  height: 58px;
  border-radius: 9px;
  border: 3px solid var(--ink-black);
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: inset 0 0 12px rgba(0,0,0,0.35), 0 3px 0 rgba(0,0,0,0.3);
}
.pack-icon-box.rare { background: radial-gradient(circle, #6ee0ff 0%, #1976d2 70%, #0b2d5c 100%); }
.pack-icon-box.epic { background: radial-gradient(circle, #f395ff 0%, #8e24aa 70%, #370b4d 100%); }
.pack-icon-box.legendary { background: radial-gradient(circle, #fff08a 0%, #e5930b 68%, #6b3100 100%); }
.pack-icon-box svg { width: 34px; height: 34px; filter: drop-shadow(0 2px 2px rgba(0,0,0,0.5)); }

.ns-pack-card h3 {
  margin: 0;
  font-family: var(--font-display);
  font-size: 17px;
  font-weight: 700;
  line-height: 1.2;
  color: var(--text-dark);
}
.pack-sub { font-size: 12px; font-weight: 800; color: #a84208; margin-top: 2px; }
.pack-desc { font-size: 13px; color: var(--text-mid); margin: 0 0 12px; line-height: 1.45; }

/* In-game dark chocolate recessed contents box */
.pack-contents {
  list-style: none;
  margin: 0 0 14px;
  padding: 10px 11px;
  background: var(--slot-brown);
  border: 2.5px solid var(--slot-border);
  border-radius: 7px;
  font-size: 12.5px;
  font-weight: 800;
  color: var(--tan-50);
  display: flex;
  flex-direction: column;
  gap: 5px;
  box-shadow: inset 0 2px 6px rgba(0,0,0,0.38);
}
.pack-contents li { display: flex; align-items: center; gap: 7px; }
.pack-contents .c-tok { color: #7ae2ff; }
.pack-contents .c-gold { color: #ffd952; }
.pack-contents .c-emblem { color: #ffe875; }
.pack-contents .c-item { color: #ffeed9; }

.pack-foot {
  margin-top: auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding-top: 10px;
  border-top: 2px dashed var(--tan-400);
}
.pack-price {
  font-family: var(--font-display);
  font-size: 21px;
  font-weight: 700;
  color: var(--text-dark);
}
.pack-price small { display: block; font-size: 10px; font-weight: 800; color: var(--text-muted); text-transform: uppercase; }

/* ================= RANKINGS & TABLES ================= */
.kpi-strip { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; margin-bottom: 18px; }
.kpi-box {
  background: var(--slot-brown);
  border: 2.5px solid var(--ink-black);
  border-radius: 8px;
  padding: 12px;
  text-align: center;
  color: var(--tan-50);
}
.kpi-box strong { display: block; font-family: var(--font-display); font-size: 25px; color: var(--ns-gold-top); }
.kpi-box span { font-size: 11.5px; font-weight: 800; text-transform: uppercase; letter-spacing: 0.06em; color: var(--tan-200); }

.ns-table-wrap { overflow-x: auto; }
.ns-table { width: 100%; border-collapse: separate; border-spacing: 0 6px; }
.ns-table th {
  text-align: left;
  padding: 9px 12px;
  font-family: var(--font-display);
  font-size: 12px;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--tan-50);
  background: var(--slot-brown);
  border-top: 2px solid var(--ink-black);
  border-bottom: 2px solid var(--ink-black);
}
.ns-table th:first-child { border-left: 2px solid var(--ink-black); border-radius: 6px 0 0 6px; }
.ns-table th:last-child { border-right: 2px solid var(--ink-black); border-radius: 0 6px 6px 0; }
.ns-table td {
  padding: 10px 12px;
  background: var(--tan-50);
  border-top: 2px solid var(--tan-400);
  border-bottom: 2px solid var(--tan-400);
  font-size: 14px;
  font-weight: 800;
  color: var(--text-dark);
}
.ns-table td:first-child { border-left: 2px solid var(--tan-400); border-radius: 6px 0 0 6px; }
.ns-table td:last-child { border-right: 2px solid var(--tan-400); border-radius: 0 6px 6px 0; }
.ns-table tr.rank-1 td { background: #ffedb8; border-color: #d98606; }
.ns-table tr.rank-2 td { background: #e3edf5; border-color: #7c96ad; }
.ns-table tr.rank-3 td { background: #f0d7b8; border-color: #b07a3f; }

.rank-medal {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 28px;
  height: 28px;
  border-radius: 50%;
  background: var(--slot-brown);
  color: var(--tan-50);
  font-family: var(--font-display);
  font-size: 13px;
  border: 2px solid var(--ink-black);
}
.rank-1 .rank-medal { background: var(--ns-gold-top); color: #3a1700; }
.rank-2 .rank-medal { background: #cddbe6; color: #162436; }
.rank-3 .rank-medal { background: #d69c60; color: #331605; }

.tag-pill {
  display: inline-block;
  padding: 2px 8px;
  border-radius: 999px;
  font-size: 11px;
  font-weight: 900;
  text-transform: uppercase;
  border: 1.5px solid var(--ink-black);
}
.tag-pill.champ { background: #c92020; color: #fff; margin-left: 6px; }
.tag-pill.emblem { background: var(--ns-gold-top); color: #3a1700; margin-left: 6px; }
.tag-pill.ok { background: #c8f5c4; color: #0a4a0c; border-color: #0e7a10; }
.tag-pill.mail { background: #ccebff; color: #063d66; border-color: #167bc2; }

.stat-lvl { font-family: var(--font-display); color: #118213; font-size: 15px; }
.stat-pts { font-family: var(--font-display); color: #d61c78; font-size: 15px; }

/* ================= GUIDE & DOWNLOAD CARDS ================= */
.guide-grid { display: grid; grid-template-columns: 245px 1fr; gap: 22px; align-items: start; }
.guide-nav { display: flex; flex-direction: column; gap: 8px; }
.guide-step-btn {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 11px 14px;
  background: var(--slot-brown);
  border: 2.5px solid var(--ink-black);
  border-radius: 8px;
  color: var(--tan-50);
  font-family: var(--font-display);
  font-size: 14px;
  cursor: pointer;
  text-align: left;
  box-shadow: 0 3px 0 rgba(0,0,0,0.35);
  transition: transform 0.12s, background 0.12s;
}
.guide-step-btn:hover { transform: translateX(4px); }
.guide-step-btn.active {
  background: linear-gradient(180deg, #35df30, #0c820e);
  color: #fff;
  box-shadow: inset 0 0 0 2px var(--ns-green-rim), 0 3px 0 var(--ink-black);
  transform: translateX(5px);
}
.guide-stage {
  background: var(--tan-50);
  border: 3px solid var(--ink-black);
  border-radius: 9px;
  padding: 22px;
  box-shadow: var(--shadow-card);
}
.guide-stage h3 { margin: 8px 0 8px; font-family: var(--font-display); font-size: 24px; color: var(--text-dark); }
.guide-stage p { margin: 0 0 16px; color: var(--text-mid); }
.guide-points { display: grid; grid-template-columns: repeat(auto-fit, minmax(195px, 1fr)); gap: 10px; }
.guide-point {
  padding: 10px 12px;
  background: var(--tan-100);
  border: 2px solid var(--tan-400);
  border-radius: 7px;
  font-size: 13px;
  font-weight: 800;
}

.download-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; }
.dl-card {
  display: flex;
  flex-direction: column;
  background: linear-gradient(180deg, #1b3463 0%, #102042 100%);
  border: 3px solid var(--ink-black);
  border-radius: 10px;
  padding: 20px 18px;
  color: var(--tan-50);
  box-shadow: inset 0 1px 0 rgba(255,255,255,0.18), 0 6px 0 rgba(0,0,0,0.4);
}
.dl-card img { height: 74px; width: auto; object-fit: contain; margin: 0 auto 12px; filter: drop-shadow(0 4px 6px rgba(0,0,0,0.55)); }
.dl-card h3 { margin: 0 0 6px; font-family: var(--font-display); font-size: 19px; color: var(--ns-gold-top); text-align: center; }
.dl-card p { margin: 0 0 14px; font-size: 14px; color: var(--tan-100); flex: 1; text-align: center; }
.dl-meta {
  font-size: 12px;
  color: var(--tan-200);
  margin-bottom: 14px;
  padding: 9px 11px;
  background: rgba(10, 20, 40, 0.72);
  border-radius: 7px;
  border: 1.5px solid rgba(255, 214, 59, 0.25);
}

/* ================= AUTH & ACCOUNT ================= */
.auth-stage {
  position: relative;
  padding: 52px 0 76px;
  background:
    linear-gradient(180deg, rgba(10, 20, 40, 0.82) 0%, rgba(16, 32, 66, 0.88) 100%),
    url('/art/portal/hero-village.jpg') center center / cover no-repeat;
}
.auth-box { max-width: 460px; margin: 0 auto; }
.auth-logo { width: 220px; margin: 0 auto 16px; filter: drop-shadow(0 6px 12px rgba(0,0,0,0.65)); }

.ns-form { display: flex; flex-direction: column; gap: 14px; }
.ns-field label {
  display: block;
  font-family: var(--font-display);
  font-size: 13px;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--text-mid);
  margin-bottom: 5px;
}
.ns-field input, .ns-field select {
  width: 100%;
  padding: 11px 13px;
  font-family: var(--font-body);
  font-size: 15px;
  font-weight: 800;
  color: var(--text-dark);
  background: var(--tan-50);
  border: 2.5px solid var(--ink-black);
  border-radius: 7px;
  outline: none;
  box-shadow: inset 0 2px 0 rgba(0,0,0,0.12);
}
.ns-field input:focus, .ns-field select:focus {
  border-color: var(--ns-gold-bot);
  box-shadow: 0 0 0 3px rgba(255, 214, 59, 0.45);
}
.ns-field small { display: block; margin-top: 4px; font-size: 12px; color: var(--text-muted); }

.ns-alert {
  padding: 12px 16px;
  border-radius: 8px;
  border: 3px solid var(--ink-black);
  margin-bottom: 18px;
  font-size: 14px;
  font-weight: 800;
  box-shadow: 0 4px 0 rgba(0,0,0,0.3);
}
.ns-alert.ok { background: #d6f7d2; color: #0b4a0d; }
.ns-alert.err { background: #ffd8d4; color: #6e100a; }

.account-grid { display: grid; grid-template-columns: 1.2fr 0.8fr; gap: 22px; align-items: start; }
.char-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(230px, 1fr)); gap: 14px; }
.char-card {
  background: var(--tan-50);
  border: 2.5px solid var(--ink-black);
  border-radius: 9px;
  padding: 14px;
  color: var(--text-dark);
  box-shadow: var(--shadow-card);
}
.char-card.selected {
  background: #fff9e3;
  box-shadow: 0 0 0 3px var(--ns-gold-top), var(--shadow-card);
}
.char-head { display: flex; align-items: center; justify-content: space-between; margin-bottom: 8px; }
.char-head strong { font-family: var(--font-display); font-size: 18px; }
.char-stats { display: grid; grid-template-columns: 1fr 1fr; gap: 6px; font-size: 12.5px; color: var(--text-mid); margin-bottom: 10px; }
.char-stats b { color: var(--text-dark); }

/* ================= FAQ & MODAL ================= */
.faq-list { display: flex; flex-direction: column; gap: 10px; }
.faq-item {
  background: var(--tan-50);
  border: 2.5px solid var(--ink-black);
  border-radius: 8px;
  overflow: hidden;
}
.faq-item summary {
  list-style: none;
  cursor: pointer;
  padding: 13px 16px;
  font-family: var(--font-display);
  font-size: 16px;
  color: var(--text-dark);
  display: flex;
  align-items: center;
  gap: 10px;
}
.faq-item summary::-webkit-details-marker { display: none; }
.faq-shuriken { color: #c92020; transition: transform 0.2s; display: inline-block; }
.faq-item[open] .faq-shuriken { transform: rotate(90deg); }
.faq-body { padding: 0 16px 14px 36px; font-size: 14px; color: var(--text-mid); }

.modal-backdrop {
  position: fixed;
  inset: 0;
  z-index: 120;
  background: rgba(7, 13, 28, 0.8);
  backdrop-filter: blur(4px);
  display: none;
  align-items: center;
  justify-content: center;
  padding: 18px;
}
.modal-backdrop.open { display: flex; }
.modal-box { width: min(500px, 100%); animation: popIn 0.15s ease-out; }
@keyframes popIn { from { opacity: 0; transform: scale(0.95); } to { opacity: 1; transform: scale(1); } }
.modal-head { display: flex; align-items: center; justify-content: space-between; margin-bottom: 14px; }
.modal-close {
  width: 34px;
  height: 34px;
  border-radius: 50%;
  border: 2.5px solid var(--ink-black);
  background: linear-gradient(180deg, #f25749, #a11717);
  color: #fff;
  font-weight: 900;
  cursor: pointer;
}
.pay-methods { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; }
.pay-opt {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 9px 6px;
  background: var(--tan-200);
  border: 2.5px solid var(--ink-black);
  border-radius: 7px;
  cursor: pointer;
  font-size: 12px;
  font-weight: 900;
  text-align: center;
}
.pay-opt input { position: absolute; opacity: 0; }
.pay-opt:has(input:checked) { background: #ffedb8; box-shadow: inset 0 0 0 2px #d98606; }

/* ================= FOOTER ================= */
.ns-footer {
  background: linear-gradient(180deg, #4b2b13 0%, #2d1809 100%);
  color: var(--tan-100);
  border-top: 4px solid var(--ink-black);
  box-shadow: inset 0 3px 0 rgba(255, 200, 66, 0.5);
  padding: 42px 0 24px;
}
.footer-grid { display: grid; grid-template-columns: 1.5fr 1fr 1fr 1fr; gap: 28px; margin-bottom: 24px; }
.footer-brand img { width: 175px; margin-bottom: 10px; filter: drop-shadow(0 4px 8px rgba(0,0,0,0.55)); }
.footer-brand p { margin: 0; font-size: 13.5px; color: var(--tan-200); }
.footer-col h4 { margin: 0 0 10px; font-family: var(--font-display); font-size: 15px; color: var(--ns-gold-top); }
.footer-col ul { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 6px; }
.footer-col a { font-size: 14px; color: var(--tan-100); }
.footer-col a:hover { color: var(--ns-gold-top); }
.footer-bottom {
  padding-top: 16px;
  border-top: 2px solid rgba(255, 214, 59, 0.18);
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 10px;
  font-size: 12.5px;
  color: var(--tan-300);
}

/* ================= FEATURED EMBLEM BANNER + 2-COL TOKEN GRID + PROMO BAR ================= */
.emblem-banner {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  padding: 18px 20px;
  margin-bottom: 20px;
  background: linear-gradient(135deg, #fff9e3 0%, #f5d796 100%);
  border: 3px solid var(--ink-black);
  border-radius: 10px;
  box-shadow: inset 0 2px 0 rgba(255,255,255,0.75), var(--shadow-card);
  color: var(--text-dark);
}
.emblem-banner-left {
  display: flex;
  align-items: center;
  gap: 16px;
}
.emblem-banner-left h2 {
  margin: 0;
  font-family: var(--font-display);
  font-size: 22px;
  color: var(--text-dark);
}
.emblem-banner-left p {
  margin: 2px 0 6px;
  font-size: 13.5px;
  color: var(--text-mid);
}
.emblem-bonus-tok {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-family: var(--font-display);
  font-size: 19px;
  color: var(--ns-token-blue);
  paint-order: stroke fill;
  -webkit-text-stroke: 3.5px var(--ink-black);
  text-shadow: 0 2px 0 var(--ink-black);
}
.emblem-banner-right {
  display: flex;
  align-items: center;
  gap: 14px;
}

.token-recessed {
  background: var(--tan-300);
  border: 2.5px solid var(--wood-dark);
  border-radius: 9px;
  padding: 16px;
  margin-bottom: 20px;
  box-shadow: inset 0 3px 0 rgba(61, 33, 13, 0.2);
}
.token-recessed-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 12px;
}
.token-recessed-head h3 {
  margin: 0;
  font-family: var(--font-display);
  font-size: 19px;
  color: var(--text-dark);
}
.token-grid-2col {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 12px;
}
.token-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 12px 14px;
  background: linear-gradient(180deg, var(--tan-50) 0%, var(--tan-100) 100%);
  border: 2.5px solid var(--ink-black);
  border-radius: 9px;
  box-shadow: 0 3px 0 rgba(22, 12, 6, 0.28);
  transition: transform 0.12s, box-shadow 0.12s;
}
.token-row:hover {
  transform: translateY(-2px);
  box-shadow: 0 0 0 2px var(--ns-gold-top), 0 5px 0 rgba(22, 12, 6, 0.35);
}
.token-row-amt {
  display: flex;
  align-items: center;
  gap: 10px;
}
.token-amount-num {
  font-family: var(--font-display);
  font-size: 24px;
  font-weight: 700;
  color: var(--ns-token-blue);
  paint-order: stroke fill;
  -webkit-text-stroke: 4px var(--ink-black);
  text-shadow: 0 2px 0 var(--ink-black);
  line-height: 1;
}
.token-row-right {
  display: flex;
  align-items: center;
  gap: 12px;
}
.token-row-price {
  font-family: var(--font-display);
  font-size: 17px;
  color: var(--text-dark);
  white-space: nowrap;
}

.promo-bar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  margin-top: 22px;
  padding: 16px 18px;
  background: var(--slot-brown);
  border: 3px solid var(--ink-black);
  border-radius: 9px;
  color: var(--tan-50);
  box-shadow: inset 0 2px 6px rgba(0,0,0,0.35);
}
.promo-bar-form {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px;
  flex: 1;
  justify-content: flex-end;
}
.promo-bar-form input {
  min-width: 210px;
  padding: 9px 13px;
  font-family: var(--font-display);
  font-size: 15px;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  background: var(--tan-50);
  color: var(--text-dark);
  border: 2.5px solid var(--ink-black);
  border-radius: 7px;
}

/* ================= REWARDS / FOUNDER MILESTONES ================= */
.rewards-split {
  display: grid;
  grid-template-columns: 1.35fr 0.65fr;
  gap: 22px;
  align-items: start;
}
.milestone-list {
  display: flex;
  flex-direction: column;
  gap: 14px;
}
.milestone-card {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  padding: 16px;
  background: linear-gradient(180deg, var(--tan-50) 0%, var(--tan-100) 100%);
  border: 3px solid var(--ink-black);
  border-radius: 10px;
  box-shadow: var(--shadow-card);
  color: var(--text-dark);
}
.milestone-card.legendary { background: linear-gradient(180deg, #fff9e6 0%, #f5daa3 100%); }
.milestone-card.claimed { opacity: 0.78; }
.milestone-info h3 { margin: 0 0 3px; font-family: var(--font-display); font-size: 18px; }
.milestone-info p { margin: 0 0 8px; font-size: 13px; color: var(--text-mid); }
.milestone-loot { display: flex; flex-wrap: wrap; gap: 8px; font-size: 12.5px; font-weight: 900; }
.milestone-pill {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 3px 9px;
  background: var(--slot-brown);
  color: var(--tan-50);
  border: 2px solid var(--ink-black);
  border-radius: 6px;
}
.rewards-art-box {
  background: linear-gradient(180deg, #1b3463 0%, #102042 100%);
  border: 3px solid var(--ink-black);
  border-radius: 10px;
  padding: 20px 16px;
  text-align: center;
  color: var(--tan-50);
}
.rewards-art-box img { width: min(260px, 100%); margin: 0 auto 12px; filter: drop-shadow(0 8px 14px rgba(0,0,0,0.65)); }

/* ================= 2-COL ACCOUNT PROFILE RECESSED CARDS ================= */
.profile-id-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}
.readonly-box {
  padding: 10px 13px;
  background: var(--tan-300);
  border: 2px solid var(--wood-dark);
  border-radius: 7px;
  color: var(--text-dark);
  font-weight: 900;
  font-size: 15px;
}

/* ================= LANGUAGE SWITCHER ================= */
.lang-switch {
  display: inline-flex;
  align-items: center;
  background: rgba(10, 20, 40, 0.72);
  border: 2px solid var(--ink-black);
  border-radius: 999px;
  padding: 2px;
  gap: 2px;
  box-shadow: inset 0 1px 0 rgba(255,255,255,0.12);
}
.lang-pill-opt {
  padding: 3px 9px;
  border-radius: 999px;
  font-family: var(--font-display);
  font-size: 11.5px;
  font-weight: 700;
  color: var(--tan-200);
  letter-spacing: 0.04em;
  transition: background 0.12s, color 0.12s;
}
.lang-pill-opt:hover { color: #fff; }
.lang-pill-opt.active {
  background: linear-gradient(180deg, #ffe264, #e08605);
  color: #361500;
}

/* ================= RESPONSIVE ================= */
@media (max-width: 980px) {
  .ns-topbar-inner { flex-wrap: wrap; height: auto; padding: 10px 0; }
  .ns-hero-grid, .account-grid, .guide-grid, .rewards-split { grid-template-columns: 1fr; }
  .token-grid-2col { grid-template-columns: 1fr; }
  .village-dock { grid-template-columns: repeat(3, 1fr); }
  .download-grid { grid-template-columns: 1fr; }
  .footer-grid { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 600px) {
  .village-dock { grid-template-columns: repeat(2, 1fr); }
  .kpi-strip, .pay-methods, .profile-id-grid { grid-template-columns: 1fr; }
  .footer-grid { grid-template-columns: 1fr; }
}
