/* ==========================================================================
   CobbleWorld — shared stylesheet
   Palette derived from the in-game MOTD gradient (#0a6e7a -> #3ec5d4 -> #fff)
   ========================================================================== */

/* --- tokens --------------------------------------------------------------- */
:root {
  --bg:            #060e12;
  --bg-2:          #0a161c;
  --surface:       #0e1e26;
  --surface-2:     #122a34;
  --border:        #1d3a45;
  --border-bright: #2c5d6d;

  --accent:        #3ec5d4;
  --accent-deep:   #0a6e7a;
  --accent-soft:   rgba(62, 197, 212, .12);
  --accent-glow:   rgba(62, 197, 212, .30);

  --gold:          #f0b429;
  --violet:        #a78bfa;
  --rose:          #fb7185;
  --lime:          #a3e635;

  --text:          #e8f4f7;
  --muted:         #94aeb8;
  --muted-2:       #63808c;

  --radius:        14px;
  --radius-lg:     20px;
  --maxw:          1140px;

  --font-display: 'Outfit', 'Segoe UI', system-ui, sans-serif;
  --font-body:    'Inter', 'Segoe UI', system-ui, sans-serif;
  --font-mono:    'JetBrains Mono', ui-monospace, 'Cascadia Code', monospace;

  --shadow:    0 10px 30px -12px rgba(0,0,0,.7);
  --shadow-lg: 0 28px 60px -20px rgba(0,0,0,.85);
}

/* --- reset ---------------------------------------------------------------- */
*, *::before, *::after { box-sizing: border-box; }

html { scroll-behavior: smooth; scroll-padding-top: 90px; }

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: var(--font-body);
  font-size: 16px;
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

/* ambient background wash — pure CSS, no image assets */
body::before {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 0;
  background:
    radial-gradient(900px 520px at 12% -10%, rgba(62,197,212,.13), transparent 65%),
    radial-gradient(760px 460px at 92% 4%,  rgba(10,110,122,.20), transparent 62%),
    linear-gradient(180deg, transparent 0%, rgba(6,14,18,.9) 78%);
}

body > * { position: relative; z-index: 1; }

img { max-width: 100%; height: auto; display: block; }

a { color: var(--accent); text-decoration: none; }
a:hover { text-decoration: underline; }

h1, h2, h3, h4 {
  font-family: var(--font-display);
  font-weight: 700;
  line-height: 1.15;
  letter-spacing: -.02em;
  margin: 0 0 .5em;
}

h1 { font-size: clamp(2.2rem, 6vw, 3.6rem); }
h2 { font-size: clamp(1.7rem, 4vw, 2.5rem); }
h3 { font-size: 1.2rem; }

p { margin: 0 0 1rem; color: var(--muted); }

:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 3px;
  border-radius: 4px;
}

.container { width: 100%; max-width: var(--maxw); margin: 0 auto; padding: 0 24px; }

.skip-link {
  position: absolute; left: -9999px; top: 0;
  background: var(--accent); color: #04222a;
  padding: 10px 18px; border-radius: 0 0 8px 0; font-weight: 700; z-index: 999;
}
.skip-link:focus { left: 0; }

/* --- shared text bits ----------------------------------------------------- */
.grad-text {
  background: linear-gradient(100deg, var(--accent-deep), var(--accent) 35%, #ffffff 52%, var(--accent) 68%, var(--accent-deep));
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.eyebrow {
  display: inline-flex; align-items: center; gap: 8px;
  font-family: var(--font-display);
  font-size: .74rem; font-weight: 700;
  letter-spacing: .18em; text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 14px;
}
.eyebrow::before { content: ""; width: 22px; height: 2px; background: var(--accent); border-radius: 2px; }

.lede { font-size: 1.06rem; max-width: 62ch; }

.section { padding: 84px 0; }
.section-head { max-width: 640px; margin-bottom: 44px; }
.section-head.center { margin-inline: auto; text-align: center; }
.section-alt { background: linear-gradient(180deg, transparent, var(--bg-2) 18%, var(--bg-2) 82%, transparent); }

/* --- buttons -------------------------------------------------------------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 9px;
  font-family: var(--font-display);
  font-weight: 600; font-size: .95rem;
  padding: 13px 24px;
  border-radius: 10px;
  border: 1px solid transparent;
  cursor: pointer;
  transition: transform .18s ease, box-shadow .18s ease, background .18s ease, border-color .18s ease;
  white-space: nowrap;
  text-decoration: none !important;
}
.btn:hover { transform: translateY(-2px); }

.btn-primary {
  background: linear-gradient(135deg, var(--accent), var(--accent-deep));
  color: #04222a;
  box-shadow: 0 8px 24px -10px var(--accent-glow);
}
.btn-primary:hover { box-shadow: 0 14px 34px -10px var(--accent-glow); }

.btn-ghost {
  background: rgba(255,255,255,.03);
  border-color: var(--border-bright);
  color: var(--text);
}
.btn-ghost:hover { background: var(--accent-soft); border-color: var(--accent); }

.btn-sm { padding: 9px 16px; font-size: .87rem; }
.btn-lg { padding: 16px 32px; font-size: 1.02rem; }

/* --- header / nav --------------------------------------------------------- */
.site-header {
  position: sticky; top: 0; z-index: 100;
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  background: rgba(6,14,18,.78);
  border-bottom: 1px solid var(--border);
}

.header-inner { display: flex; align-items: center; gap: 20px; height: 72px; }

.brand {
  display: flex; align-items: center; gap: 10px;
  font-family: var(--font-display);
  font-weight: 800; font-size: 1.2rem;
  letter-spacing: -.02em;
  color: var(--text); text-decoration: none !important;
  margin-right: auto;
}
.brand-mark { color: var(--accent); font-size: 1rem; }
.brand-text span { color: var(--accent); }

.site-nav { display: flex; align-items: center; gap: 6px; }
.site-nav > a:not(.btn) {
  font-family: var(--font-display);
  font-weight: 500; font-size: .93rem;
  color: var(--muted);
  padding: 8px 13px; border-radius: 8px;
  text-decoration: none !important;
  transition: color .16s ease, background .16s ease;
}
.site-nav > a:not(.btn):hover { color: var(--text); background: rgba(255,255,255,.04); }
.site-nav > a.is-active { color: var(--accent); background: var(--accent-soft); }
.nav-sep { width: 1px; height: 22px; background: var(--border); margin: 0 8px; }

.nav-toggle {
  display: none;
  flex-direction: column; justify-content: center; gap: 5px;
  width: 42px; height: 42px; padding: 0 10px;
  background: rgba(255,255,255,.04);
  border: 1px solid var(--border-bright);
  border-radius: 9px; cursor: pointer;
}
.nav-toggle span { display: block; height: 2px; background: var(--text); border-radius: 2px; transition: transform .22s ease, opacity .22s ease; }
.nav-toggle[aria-expanded="true"] span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.nav-toggle[aria-expanded="true"] span:nth-child(2) { opacity: 0; }
.nav-toggle[aria-expanded="true"] span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

@media (max-width: 900px) {
  .nav-toggle { display: flex; }
  .site-nav {
    position: absolute; top: 72px; left: 0; right: 0;
    flex-direction: column; align-items: stretch; gap: 4px;
    padding: 16px 24px 24px;
    background: rgba(8,18,24,.98);
    border-bottom: 1px solid var(--border);
    box-shadow: var(--shadow-lg);
    display: none;
  }
  .site-nav.is-open { display: flex; }
  .site-nav > a:not(.btn) { padding: 12px 14px; font-size: 1rem; }
  .site-nav .btn { width: 100%; margin-top: 6px; }
  .nav-sep { display: none; }
}

/* --- notice banner -------------------------------------------------------- */
.notice {
  background: linear-gradient(90deg, var(--accent-deep), #0d4f58);
  color: #eaffff;
  font-size: .87rem;
  text-align: center;
  padding: 9px 24px;
  border-bottom: 1px solid var(--border-bright);
}
.notice strong { color: #fff; }

/* --- hero ----------------------------------------------------------------- */
.hero { padding: 96px 0 84px; text-align: center; position: relative; overflow: hidden; }
.hero::after {
  content: ""; position: absolute; inset: 0; pointer-events: none;
  background-image:
    linear-gradient(rgba(62,197,212,.045) 1px, transparent 1px),
    linear-gradient(90deg, rgba(62,197,212,.045) 1px, transparent 1px);
  background-size: 54px 54px;
  mask-image: radial-gradient(circle at 50% 38%, #000 0%, transparent 72%);
  -webkit-mask-image: radial-gradient(circle at 50% 38%, #000 0%, transparent 72%);
}
.hero > * { position: relative; z-index: 1; }

.hero-title {
  font-size: clamp(2.6rem, 9vw, 5.4rem);
  font-weight: 800;
  letter-spacing: -.035em;
  margin-bottom: .25em;
}
.hero-title .star { color: var(--accent); font-size: .42em; vertical-align: middle; margin: 0 .35em; }

.hero-tag {
  font-family: var(--font-display);
  font-size: clamp(.86rem, 2.4vw, 1.05rem);
  font-weight: 600;
  letter-spacing: .26em;
  text-transform: uppercase;
  color: var(--muted);
  margin-bottom: 1.6rem;
}

.hero-sub { max-width: 58ch; margin: 0 auto 2.4rem; font-size: 1.08rem; }

.hero-actions { display: flex; flex-wrap: wrap; gap: 12px; justify-content: center; margin-bottom: 2.6rem; }

/* --- IP copy box ---------------------------------------------------------- */
.ip-box {
  display: inline-flex; align-items: center; gap: 4px;
  background: var(--surface);
  border: 1px solid var(--border-bright);
  border-radius: 12px;
  padding: 6px 6px 6px 18px;
  box-shadow: var(--shadow);
  max-width: 100%;
}
.ip-label {
  font-family: var(--font-display);
  font-size: .7rem; font-weight: 700; letter-spacing: .16em; text-transform: uppercase;
  color: var(--muted-2); margin-right: 12px;
}
.ip-value {
  font-family: var(--font-mono);
  font-size: 1.02rem; font-weight: 700;
  color: var(--accent);
  letter-spacing: .01em;
  overflow-wrap: anywhere;
}
.ip-copy {
  margin-left: 12px;
  font-family: var(--font-display); font-weight: 600; font-size: .85rem;
  background: var(--accent-soft);
  color: var(--accent);
  border: 1px solid transparent;
  border-radius: 8px;
  padding: 9px 15px;
  cursor: pointer;
  transition: background .16s ease, color .16s ease;
}
.ip-copy:hover { background: var(--accent); color: #04222a; }
.ip-copy.copied { background: var(--lime); color: #10240a; }

@media (max-width: 520px) {
  .ip-box { flex-direction: column; align-items: stretch; padding: 14px; gap: 10px; text-align: center; }
  .ip-label { margin: 0; }
  .ip-copy { margin: 0; }
}

/* --- stat strip ----------------------------------------------------------- */
.stat-strip {
  display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
  gap: 1px;
  background: var(--border);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
  margin-top: 12px;
}
.stat { background: var(--surface); padding: 26px 20px; text-align: center; }
.stat-num {
  font-family: var(--font-display); font-size: 1.9rem; font-weight: 800;
  color: var(--accent); line-height: 1; margin-bottom: 6px;
}
.stat-label { font-size: .78rem; letter-spacing: .12em; text-transform: uppercase; color: var(--muted-2); }

/* --- cards / grids -------------------------------------------------------- */
.grid { display: grid; gap: 20px; }
.grid-2 { grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); }
.grid-3 { grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); }

.card {
  background: linear-gradient(160deg, var(--surface), var(--bg-2));
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 28px;
  transition: transform .2s ease, border-color .2s ease, box-shadow .2s ease;
}
.card:hover { transform: translateY(-4px); border-color: var(--border-bright); box-shadow: var(--shadow); }
.card h3 { margin-bottom: .4em; }
.card p { margin-bottom: 0; font-size: .95rem; }

.card-icon {
  width: 46px; height: 46px;
  display: grid; place-items: center;
  font-size: 1.4rem;
  background: var(--accent-soft);
  border: 1px solid var(--border-bright);
  border-radius: 11px;
  margin-bottom: 18px;
}

.tag {
  display: inline-block;
  font-family: var(--font-display);
  font-size: .68rem; font-weight: 700; letter-spacing: .12em; text-transform: uppercase;
  padding: 4px 10px; border-radius: 999px;
  background: var(--accent-soft); color: var(--accent);
  border: 1px solid var(--border-bright);
  vertical-align: middle;
}
.tag-soon { background: rgba(240,180,41,.12); color: var(--gold); border-color: rgba(240,180,41,.3); }

/* --- feature detail blocks ------------------------------------------------ */
.feature-block {
  display: grid; grid-template-columns: 1fr 1fr; gap: 44px; align-items: center;
  padding: 52px 0; border-top: 1px solid var(--border);
}
.feature-block:first-of-type { border-top: none; }
@media (max-width: 820px) { .feature-block { grid-template-columns: 1fr; gap: 26px; } }

.spec-list { list-style: none; padding: 0; margin: 20px 0 0; }
.spec-list li {
  display: flex; gap: 12px; padding: 9px 0;
  border-bottom: 1px dashed var(--border);
  font-size: .94rem; color: var(--muted);
}
.spec-list li:last-child { border-bottom: none; }
.spec-list li::before { content: "\25B8"; color: var(--accent); flex: none; }

.panel {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 26px;
  box-shadow: var(--shadow);
}
.panel-title {
  font-family: var(--font-display); font-weight: 700; font-size: .78rem;
  letter-spacing: .16em; text-transform: uppercase; color: var(--muted-2);
  padding-bottom: 14px; margin-bottom: 16px; border-bottom: 1px solid var(--border);
}

.kv { display: flex; justify-content: space-between; gap: 16px; padding: 8px 0; font-size: .92rem; }
.kv + .kv { border-top: 1px solid rgba(255,255,255,.04); }
.kv dt { color: var(--muted-2); margin: 0; }
.kv dd { margin: 0; font-family: var(--font-mono); font-size: .86rem; color: var(--accent); text-align: right; }

/* --- tables --------------------------------------------------------------- */
.table-wrap { overflow-x: auto; border: 1px solid var(--border); border-radius: var(--radius); background: var(--surface); }
table { width: 100%; border-collapse: collapse; min-width: 660px; font-size: .93rem; }
thead th {
  font-family: var(--font-display); font-size: .74rem; font-weight: 700;
  letter-spacing: .12em; text-transform: uppercase; color: var(--muted-2);
  text-align: left; padding: 16px 18px; background: var(--bg-2);
  border-bottom: 1px solid var(--border); white-space: nowrap;
}
tbody td { padding: 14px 18px; border-bottom: 1px solid rgba(255,255,255,.045); color: var(--muted); vertical-align: middle; }
tbody tr:last-child td { border-bottom: none; }
tbody tr:hover td { background: rgba(62,197,212,.035); }
td.yes { color: var(--lime); font-weight: 700; }
td.no  { color: var(--muted-2); }
th[scope="row"], td.row-head { color: var(--text); font-weight: 600; text-align: left; }

/* --- rank cards ----------------------------------------------------------- */
.rank-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(215px, 1fr)); gap: 18px; }
.rank-card {
  position: relative;
  background: linear-gradient(170deg, var(--surface), var(--bg-2));
  border: 1px solid var(--border);
  border-top: 3px solid var(--rank, var(--accent));
  border-radius: var(--radius);
  padding: 26px 24px;
  display: flex; flex-direction: column;
  transition: transform .2s ease, box-shadow .2s ease;
}
.rank-card:hover { transform: translateY(-5px); box-shadow: var(--shadow-lg); }
.rank-name {
  font-family: var(--font-display); font-size: 1.3rem; font-weight: 800;
  color: var(--rank, var(--accent)); margin-bottom: 2px;
}
.rank-price { font-family: var(--font-display); font-size: 1.9rem; font-weight: 800; color: var(--text); margin: 12px 0 4px; }
.rank-price small { font-size: .8rem; font-weight: 500; color: var(--muted-2); }
.rank-perks { list-style: none; padding: 0; margin: 18px 0 22px; flex: 1; }
.rank-perks li { font-size: .89rem; color: var(--muted); padding: 6px 0 6px 22px; position: relative; }
.rank-perks li::before { content: "\2713"; position: absolute; left: 0; color: var(--rank, var(--accent)); font-weight: 700; }
.rank-badge {
  position: absolute; top: -11px; right: 18px;
  font-family: var(--font-display); font-size: .66rem; font-weight: 800;
  letter-spacing: .12em; text-transform: uppercase;
  background: var(--rank, var(--accent)); color: #04222a;
  padding: 4px 11px; border-radius: 999px;
}

/* --- steps ---------------------------------------------------------------- */
.steps { list-style: none; counter-reset: step; padding: 0; margin: 0; display: grid; gap: 18px; }
.steps li {
  counter-increment: step;
  display: grid; grid-template-columns: 46px 1fr; gap: 18px; align-items: start;
  background: var(--surface); border: 1px solid var(--border);
  border-radius: var(--radius); padding: 22px 24px;
}
.steps li::before {
  content: counter(step);
  width: 46px; height: 46px; display: grid; place-items: center;
  font-family: var(--font-display); font-weight: 800; font-size: 1.15rem;
  color: var(--accent); background: var(--accent-soft);
  border: 1px solid var(--border-bright); border-radius: 11px;
}
.steps h3 { margin-bottom: .25em; font-size: 1.05rem; }
.steps p { margin: 0; font-size: .93rem; }

/* --- rules ---------------------------------------------------------------- */
.rule-group { margin-bottom: 40px; }
.rule-list { list-style: none; counter-reset: rule; padding: 0; margin: 0; }
.rule-list li {
  counter-increment: rule;
  position: relative; padding: 16px 0 16px 52px;
  border-bottom: 1px solid var(--border);
  color: var(--muted); font-size: .95rem;
}
.rule-list li:last-child { border-bottom: none; }
.rule-list li::before {
  content: counter(rule);
  position: absolute; left: 0; top: 15px;
  width: 32px; height: 32px; display: grid; place-items: center;
  font-family: var(--font-mono); font-size: .8rem; font-weight: 700;
  color: var(--accent); background: var(--accent-soft);
  border-radius: 8px;
}
.rule-list strong { color: var(--text); display: block; margin-bottom: 2px; font-weight: 600; }

/* --- vote ----------------------------------------------------------------- */
.vote-card {
  display: flex; align-items: center; gap: 18px;
  background: var(--surface); border: 1px solid var(--border);
  border-radius: var(--radius); padding: 20px 24px;
  transition: border-color .2s ease, transform .2s ease;
}
.vote-card:hover { border-color: var(--accent); transform: translateX(4px); }
.vote-num {
  font-family: var(--font-display); font-weight: 800; font-size: 1.1rem;
  color: var(--accent); background: var(--accent-soft);
  width: 42px; height: 42px; display: grid; place-items: center;
  border-radius: 10px; flex: none;
}
.vote-body { flex: 1; min-width: 0; }
.vote-body h3 { margin: 0 0 2px; font-size: 1rem; }
.vote-body p { margin: 0; font-size: .86rem; }
@media (max-width: 560px) { .vote-card { flex-wrap: wrap; } .vote-card .btn { width: 100%; } }

/* --- callout -------------------------------------------------------------- */
.callout {
  border-left: 3px solid var(--accent);
  background: var(--accent-soft);
  border-radius: 0 var(--radius) var(--radius) 0;
  padding: 18px 22px;
  margin: 26px 0;
}
.callout p { margin: 0; font-size: .93rem; }
.callout.warn { border-left-color: var(--gold); background: rgba(240,180,41,.09); }

/* --- CTA ------------------------------------------------------------------ */
.cta {
  text-align: center;
  background: linear-gradient(150deg, var(--surface-2), var(--bg-2));
  border: 1px solid var(--border-bright);
  border-radius: var(--radius-lg);
  padding: 60px 36px;
  box-shadow: var(--shadow-lg);
}
.cta h2 { margin-bottom: .3em; }
.cta p { max-width: 48ch; margin-inline: auto; }

/* --- footer --------------------------------------------------------------- */
.site-footer {
  border-top: 1px solid var(--border);
  background: var(--bg-2);
  padding: 56px 0 28px;
  margin-top: 40px;
}
.footer-grid { display: grid; grid-template-columns: 1.6fr 1fr 1fr 1fr; gap: 36px; margin-bottom: 40px; }
@media (max-width: 780px) { .footer-grid { grid-template-columns: 1fr 1fr; gap: 28px; } }
@media (max-width: 460px) { .footer-grid { grid-template-columns: 1fr; } }

.footer-grid h4 {
  font-size: .76rem; font-weight: 700; letter-spacing: .15em;
  text-transform: uppercase; color: var(--muted-2); margin-bottom: 14px;
}
.footer-links { list-style: none; padding: 0; margin: 0; }
.footer-links li { margin-bottom: 9px; }
.footer-links a { color: var(--muted); font-size: .92rem; text-decoration: none; transition: color .16s ease; }
.footer-links a:hover { color: var(--accent); }

.footer-bottom {
  border-top: 1px solid var(--border);
  padding-top: 22px;
  display: flex; flex-wrap: wrap; gap: 12px; justify-content: space-between;
  font-size: .82rem; color: var(--muted-2);
}
.footer-bottom p { margin: 0; font-size: .82rem; color: var(--muted-2); }
.disclaimer { max-width: 70ch; line-height: 1.6; }

/* --- reveal animation ----------------------------------------------------- */
.reveal { opacity: 0; transform: translateY(18px); transition: opacity .6s ease, transform .6s ease; }
.reveal.is-visible { opacity: 1; transform: none; }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation-duration: .01ms !important; transition-duration: .01ms !important; }
  .reveal { opacity: 1; transform: none; }
}

/* --- utilities ------------------------------------------------------------ */
.center { text-align: center; }
.mt-0 { margin-top: 0; }
.mt-3 { margin-top: 24px; }
.mt-4 { margin-top: 36px; }
.mb-0 { margin-bottom: 0; }
.muted { color: var(--muted-2); }
.small { font-size: .87rem; }
.mono { font-family: var(--font-mono); font-size: .9em; color: var(--accent); }
.stack-actions { display: flex; flex-wrap: wrap; gap: 12px; }
.stack-actions.center { justify-content: center; }
