/* ── LANDING PAGE STYLES ── */

html { scroll-behavior: smooth; }
body {
  font-family: var(--font-body);
  font-size: 18px;
  line-height: 1.7;
  display: block;
  height: auto;
  overflow-x: hidden;
  overflow-y: auto;
  /* Force consistent dark bg matching the reference */
  background: #0F0D0A !important;
  color: #F0EBE0;
}

/* Subtle single glow, low opacity — reference doesn't have double glows */
body::before {
  content: '';
  position: fixed;
  inset: 0;
  background-image: radial-gradient(ellipse 800px 500px at 15% 25%, rgba(196,120,42,0.07), transparent);
  pointer-events: none;
  z-index: 0;
}

/* Landing: brighter text than default dark theme vars */
h1 { color: #F5F0E8 !important; }
h2 { color: #EDE5D8 !important; }
h2 .h2-gold { color: var(--accent) !important; }
.hero-subtitle { color: #A89880; }
.section-desc { color: #9A8878; }
p { color: #A89880; }

/* ── NAV ── */
nav {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 100;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 48px;
  height: 68px;
  background: var(--bg);
  border-bottom: 1px solid var(--border);
  backdrop-filter: blur(12px);
}

.nav-logo {
  font-family: var(--font-display);
  font-size: 20px;
  font-weight: 700;
  color: var(--accent);
  letter-spacing: 0.08em;
  text-decoration: none;
  display: flex;
  align-items: center;
  gap: 10px;
}

.logo-mark {
  width: 32px; height: 32px;
  border: 2px solid var(--accent);
  border-radius: 6px;
  display: flex; align-items: center; justify-content: center;
  font-size: 14px;
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 32px;
  list-style: none;
}
.nav-links a {
  font-family: var(--font-ui);
  font-size: 14px;
  color: var(--text2);
  text-decoration: none;
  letter-spacing: 0.03em;
  transition: color var(--transition);
}
.nav-links a:hover { color: var(--accent); }

.nav-right { display: flex; align-items: center; gap: 12px; }

/* ── BUTTONS ── */
.btn {
  font-family: var(--font-ui);
  font-size: 14px;
  font-weight: 500;
  border: none;
  border-radius: var(--radius);
  padding: 10px 22px;
  cursor: pointer;
  transition: all var(--transition);
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  letter-spacing: 0.02em;
}

.btn-ghost {
  background: transparent;
  color: var(--text2);
  border: 1px solid var(--border2);
}
.btn-ghost:hover { background: var(--bg2); color: var(--text); border-color: var(--accent); }

.btn-primary {
  background: var(--accent);
  color: #fff;
  box-shadow: 0 4px 16px var(--hero-glow);
}
.btn-primary:hover {
  background: var(--accent2);
  transform: translateY(-1px);
  box-shadow: 0 8px 24px var(--hero-glow);
}

.btn-outline {
  background: transparent;
  color: var(--accent);
  border: 1.5px solid var(--accent);
}
.btn-outline:hover { background: var(--accent-bg); }

.btn-dark {
  background: #0F0D0A;
  color: var(--accent);
  border: 1.5px solid rgba(196,120,42,0.3);
}
.btn-dark:hover { background: #1a1208; border-color: var(--accent); }

.btn-lg { font-size: 16px; padding: 14px 32px; border-radius: var(--radius-lg); }
.nav-btn-mobile { display: none; }

/* ── HAMBURGER BUTTON ── */
.nav-burger {
  display: none;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  gap: 5px;
  width: 40px; height: 40px;
  background: transparent;
  border: 1px solid var(--border2);
  border-radius: 8px;
  cursor: pointer;
  padding: 8px;
  flex-shrink: 0;
}
.nav-burger span {
  display: block;
  width: 20px; height: 2px;
  background: var(--text);
  border-radius: 2px;
  transition: all var(--transition);
  transform-origin: center;
}
.nav-burger.open span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.nav-burger.open span:nth-child(2) { opacity: 0; transform: scaleX(0); }
.nav-burger.open span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

/* ── MOBILE MENU ── */
.nav-mobile-menu {
  display: none;
  position: fixed;
  top: 60px; left: 0; right: 0;
  background: var(--bg);
  border-bottom: 1px solid var(--border);
  z-index: 99;
  flex-direction: column;
  padding: 20px;
  box-shadow: 0 8px 24px rgba(0,0,0,0.12);
  opacity: 0;
  pointer-events: none;
  transform: translateY(-6px);
  transition: opacity var(--transition), transform var(--transition);
}
.nav-mobile-menu.open {
  opacity: 1;
  pointer-events: all;
  transform: translateY(0);
}
.nav-mobile-menu ul { list-style: none; display: flex; flex-direction: column; }
.nav-mobile-menu ul li a {
  display: block;
  padding: 13px 0;
  font-family: var(--font-ui);
  font-size: 16px;
  color: var(--text);
  text-decoration: none;
  border-bottom: 1px solid var(--border);
  transition: color var(--transition);
}
.nav-mobile-menu ul li:last-child a { border-bottom: none; }
.nav-mobile-menu ul li a:hover { color: var(--accent); }
.nav-mobile-actions { display: flex; flex-direction: column; gap: 8px; margin-top: 16px; }
.nav-mobile-utils {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-top: 16px;
  padding-top: 16px;
  border-top: 1px solid var(--border);
}
.theme-switcher {
  display: flex;
  gap: 6px;
  background: var(--bg2);
  border: 1px solid var(--border);
  border-radius: 24px;
  padding: 4px;
}
.theme-btn {
  width: 28px; height: 28px;
  border-radius: 50%;
  border: 2px solid transparent;
  cursor: pointer;
  transition: all var(--transition);
  display: flex; align-items: center; justify-content: center;
  font-size: 13px;
}
.theme-btn[data-t="light"] { background: #F5F2ED; }
.theme-btn[data-t="dark"]  { background: #171310; }
.theme-btn[data-t="pink"]  { background: #F8EDF3; }
.theme-btn.active { border-color: var(--accent); }
.lang-switcher {
  display: flex;
  gap: 4px;
  background: var(--bg2);
  border: 1px solid var(--border);
  border-radius: 24px;
  padding: 4px;
}
.lang-nav-btn {
  width: 28px; height: 28px;
  border-radius: 50%;
  border: 2px solid transparent;
  background: transparent;
  cursor: pointer;
  font-size: 16px;
  display: flex; align-items: center; justify-content: center;
  transition: all var(--transition);
}
.lang-nav-btn:hover  { background: var(--bg3); }
.lang-nav-btn.active { border-color: var(--accent); }

/* ── EMOJI FONT FALLBACK ── */
.step-icon,
.card-icon,
.card-rating,
.card-players,
.world-thumb-img,
.world-thumb-players,
.world-lock-overlay span:first-child,
.world-card-ov-emoji {
  font-family: "Apple Color Emoji", "Segoe UI Emoji", "Noto Color Emoji", emoji;
}

/* ── SECTIONS ── */
section {
  position: relative;
  z-index: 1;
  padding: 80px 48px;
  background: #0F0D0A;
}
.section-alt {
  background: #141210;
  border-top: 1px solid rgba(200,170,120,0.08);
  border-bottom: 1px solid rgba(200,170,120,0.08);
}

/* ── HERO ── */
.hero {
  min-height: 100vh;
  display: flex;
  align-items: center;
  padding: 120px 48px 80px;
  position: relative;
}

.hero-content { max-width: 580px; position: relative; z-index: 1; }

.hero-badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: var(--tag-bg);
  color: var(--tag-text);
  border: 1px solid var(--border2);
  border-radius: 24px;
  padding: 6px 16px;
  font-family: var(--font-ui);
  font-size: 12px;
  font-weight: 500;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  margin-bottom: 28px;
}
.hero-badge::before {
  content: '';
  width: 6px; height: 6px;
  background: var(--accent);
  border-radius: 50%;
  animation: pulse 2s infinite;
}

@keyframes pulse {
  0%, 100% { opacity: 1; transform: scale(1); }
  50% { opacity: 0.5; transform: scale(0.8); }
}

h1 {
  font-family: var(--font-display);
  font-size: clamp(40px, 5vw, 68px);
  font-weight: 700;
  line-height: 1.1;
  letter-spacing: 0.02em;
  color: var(--text);
  margin-bottom: 24px;
}
h1 em { font-style: italic; }
h1 span { color: var(--accent); display: block; }

h2 {
  font-family: var(--font-display);
  font-size: clamp(28px, 3vw, 42px);
  font-weight: 600;
  color: var(--text);
  letter-spacing: 0.03em;
  line-height: 1.2;
  margin-bottom: 16px;
}
h2 .h2-gold { color: var(--accent); }

.hero-subtitle { font-size: 17px; color: var(--text2); font-weight: 300; font-style: italic; margin-bottom: 36px; line-height: 1.65; }
.hero-actions { display: flex; gap: 14px; flex-wrap: wrap; align-items: center; }

.section-label {
  font-family: var(--font-ui);
  font-size: 11px;
  font-weight: 500;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 12px;
}

.section-desc { font-size: 17px; color: var(--text2); max-width: 560px; font-style: italic; margin-bottom: 0; }

/* ── HERO VISUAL ── */
.hero-visual {
  position: absolute;
  right: 0; top: 0; bottom: 0;
  width: 52%;
  overflow: hidden;
  z-index: 0;
  pointer-events: none;
}
.hcm { pointer-events: auto; }

/* ── STATS BAR ── */
.stats-bar {
  display: flex; align-items: center; justify-content: center; gap: 0;
  padding: 20px 48px;
  background: var(--bg2);
  border-top: 1px solid var(--border); border-bottom: 1px solid var(--border);
  position: relative; z-index: 1;
}
.sb-stat { display: flex; flex-direction: column; align-items: center; gap: 4px; padding: 0 48px; }
.sb-num  { font-family: var(--font-display); font-size: 30px; font-weight: 700; color: var(--accent); line-height: 1; }
.sb-label { font-family: var(--font-ui); font-size: 12px; color: var(--text3); letter-spacing: 0.04em; }
.sb-sep  { width: 1px; height: 40px; background: var(--border2); flex-shrink: 0; }

/* ── HOW IT WORKS ── */
.steps {
  display: flex;
  align-items: stretch;
  gap: 0;
  margin-top: 56px;
}

.step {
  flex: 1;
  padding: 32px;
  background: #1A1612;
  border: 1px solid rgba(200,170,120,0.1);
  border-radius: var(--radius-lg);
  transition: all var(--transition);
}
.step:hover { border-color: var(--accent); background: #1E1A15; transform: translateY(-4px); }
.step h3 { color: #EDE5D8; }
.step p { color: #9A8878; }

.step-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  margin-bottom: 20px;
}
.step-num { font-family: var(--font-display); font-size: 48px; font-weight: 700; color: var(--accent); opacity: 0.2; line-height: 1; }
.step-icon { font-size: 22px; margin-top: 4px; }
.step h3 { font-family: var(--font-display); font-size: 18px; font-weight: 600; color: var(--text); margin-bottom: 10px; letter-spacing: 0.03em; }
.step p { font-size: 15px; color: var(--text2); line-height: 1.6; }

.step-arrow {
  display: flex;
  align-items: center;
  padding: 0 20px;
  color: var(--accent);
  opacity: 0.35;
  font-size: 22px;
  flex-shrink: 0;
  font-family: var(--font-ui);
  letter-spacing: -4px;
  margin-top: 0;
  align-self: center;
}

/* ── WORLDS ── */
.worlds-header {
  display: flex; align-items: flex-end; justify-content: space-between;
  margin-bottom: 36px;
}
.worlds-header h2 { margin-bottom: 0; }

.worlds-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 20px;
}

/* Landing overlay-style world cards */
#landingWorldsGrid {
  grid-template-columns: repeat(3, 1fr);
  gap: 16px;
}

.world-card-ov {
  position: relative;
  border-radius: 12px;
  overflow: hidden;
  cursor: pointer;
  aspect-ratio: 16 / 10;
  transition: transform 0.25s ease, box-shadow 0.25s ease;
}
.world-card-ov:hover {
  transform: translateY(-5px);
  box-shadow: 0 20px 56px rgba(0,0,0,0.35);
}
.world-card-ov-bg {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 52px;
  transition: transform 0.4s ease;
}
.world-card-ov:hover .world-card-ov-bg { transform: scale(1.06); }
.world-card-ov-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(to top, rgba(0,0,0,0.82) 0%, rgba(0,0,0,0.12) 55%, transparent 100%);
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  padding: 14px 16px;
}
.world-card-ov-tags { display: flex; gap: 5px; flex-wrap: wrap; margin-bottom: 6px; }
.world-card-ov-name {
  font-family: var(--font-display);
  font-size: 15px;
  font-weight: 700;
  color: #fff;
  letter-spacing: 0.02em;
  line-height: 1.25;
}
.world-card-ov .world-thumb-tag {
  background: rgba(0,0,0,0.45);
  color: rgba(255,255,255,0.82);
  backdrop-filter: blur(4px);
}

/* ── OLD WORLD THUMB (kept for /worlds page) ── */
.world-thumb {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  overflow: hidden;
  cursor: pointer;
  transition: all var(--transition);
}
.world-thumb:hover { border-color: var(--accent); transform: translateY(-4px); box-shadow: 0 16px 48px rgba(0,0,0,0.1); }
.world-thumb-img {
  height: 140px;
  display: flex; align-items: center; justify-content: center;
  font-size: 42px;
  position: relative;
  font-family: "Apple Color Emoji", "Segoe UI Emoji", "Noto Color Emoji", emoji;
}
.world-thumb-body { padding: 14px 16px 16px; }
.world-thumb-title { font-family: var(--font-display); font-size: 14px; font-weight: 600; color: var(--text); margin-bottom: 4px; letter-spacing: 0.03em; }
.world-thumb-meta { display: flex; align-items: center; justify-content: space-between; }
.world-thumb-tag { font-family: var(--font-ui); font-size: 10px; font-weight: 500; color: var(--tag-text); background: var(--tag-bg); padding: 2px 8px; border-radius: 10px; letter-spacing: 0.04em; text-transform: uppercase; }
.world-thumb-players { font-family: var(--font-ui); font-size: 11px; color: var(--text3); }
.world-thumb-desc { font-size: 11px; color: var(--text3); line-height: 1.45; margin-top: 5px; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.world-lock-overlay {
  position: absolute; inset: 0;
  background: rgba(0,0,0,0.55);
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  gap: 6px; backdrop-filter: blur(2px);
}
.world-lock-overlay span { font-family: var(--font-ui); font-size: 11px; color: rgba(255,255,255,0.7); }

/* gradient classes */
.w1 { background: linear-gradient(135deg, #1a0f08, #3d1c0c); }
.w2 { background: linear-gradient(135deg, #0a1520, #1a3040); }
.w3 { background: linear-gradient(135deg, #f0c8dc, #e0a0c0); }
.wg-dark   { background: linear-gradient(135deg,#1A0F08 0%,#3D1C0C 60%,#0E0C0A 100%); }
.wg-blue   { background: linear-gradient(135deg,#0A1520 0%,#1A3040 60%,#080E18 100%); }
.wg-pink   { background: linear-gradient(135deg,#3A1528 0%,#6A2848 60%,#2A0E1C 100%); }
.wg-purple { background: linear-gradient(135deg,#1A1A2E 0%,#2D2D4E 60%,#0E0E1C 100%); }
.wg-green  { background: linear-gradient(135deg,#0D2010 0%,#1A4020 60%,#081408 100%); }
.wg-gold   { background: linear-gradient(135deg,#1E1205 0%,#3C2410 60%,#120C02 100%); }
.wg-red    { background: linear-gradient(135deg,#200808 0%,#401010 60%,#140404 100%); }
.wg-teal   { background: linear-gradient(135deg,#081820 0%,#103040 60%,#041018 100%); }
.wg-rose   { background: linear-gradient(135deg,#F0C8DC 0%,#C880A8 60%,#E0A0C0 100%); }
.wg-blood  { background: linear-gradient(135deg,#1A0000 0%,#3D0808 60%,#0E0000 100%); }
.wg-gray   { background: linear-gradient(135deg,#141414 0%,#282828 60%,#0A0A0A 100%); }
.wg-cyan   { background: linear-gradient(135deg,#041818 0%,#083030 60%,#021010 100%); }
.wg-neon   { background: linear-gradient(135deg,#0A0020 0%,#1A0040 60%,#060010 100%); }
.wg-orange { background: linear-gradient(135deg,#1A0A00 0%,#3D2000 60%,#0E0800 100%); }
.wg-black  { background: linear-gradient(135deg,#080808 0%,#101010 60%,#040404 100%); }
.wg-warm   { background: linear-gradient(135deg,#1A1008 0%,#2D1E10 60%,#100C06 100%); }
.w4 { background: linear-gradient(135deg, #1a1a2e, #2d2d4e); }
.w5 { background: linear-gradient(135deg, #0d2010, #1a4020); }
.w6 { background: linear-gradient(135deg, #2a1520, #4a2535); }
.w7 { background: linear-gradient(135deg, #1e1205, #3c2410); }

/* ── PRICING ── */
.pricing-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
  margin-top: 56px;
}

.plan {
  background: #1A1612;
  border: 1px solid rgba(200,170,120,0.12);
  border-radius: var(--radius-lg);
  padding: 36px 32px;
  position: relative;
  transition: all var(--transition);
}
.plan .plan-name { color: #EDE5D8; }
.plan .plan-features li { color: #A89880; }
.plan:hover { transform: translateY(-4px); }

.plan-featured {
  background: var(--accent);
  border-color: var(--accent);
  box-shadow: 0 20px 60px var(--hero-glow);
}
.plan-featured .plan-name,
.plan-featured .plan-desc,
.plan-featured .plan-price { color: rgba(0,0,0,0.85); }
.plan-featured .plan-price span { color: rgba(0,0,0,0.6); }
.plan-featured .plan-features li { color: rgba(0,0,0,0.8); }
.plan-featured .plan-features li::before { color: rgba(0,0,0,0.7); }

.plan-badge {
  position: absolute;
  top: -14px; left: 50%;
  transform: translateX(-50%);
  background: #0F0D0A; color: var(--accent);
  font-family: var(--font-ui); font-size: 11px; font-weight: 600;
  padding: 5px 18px; border-radius: 20px;
  letter-spacing: 0.06em; text-transform: uppercase;
  white-space: nowrap;
  border: 1px solid rgba(196,120,42,0.3);
}

.plan-name { font-family: var(--font-display); font-size: 20px; font-weight: 600; color: var(--text); letter-spacing: 0.04em; margin-bottom: 8px; }
.plan-price { font-family: var(--font-display); font-size: 40px; font-weight: 700; color: var(--accent); line-height: 1; margin-bottom: 6px; display: flex; align-items: baseline; gap: 6px; }
.plan-price sup { font-size: 20px; }
.plan-price span { font-size: 14px; color: var(--text3); font-family: var(--font-ui); font-weight: 400; }
.plan-desc { font-size: 14px; color: var(--text2); margin-bottom: 16px; font-style: italic; min-height: 36px; margin-top: 6px; }
.plan-price { margin-bottom: 24px; }

.plan-features { list-style: none; display: flex; flex-direction: column; gap: 12px; margin-bottom: 32px; }
.plan-features li {
  font-family: var(--font-ui); font-size: 14px; color: var(--text2);
  display: flex; align-items: flex-start; gap: 10px; line-height: 1.4;
}
.plan-features li::before { content: '✓'; color: var(--accent); font-size: 13px; font-weight: 700; margin-top: 1px; flex-shrink: 0; }

/* ── COMMUNITY PLAYER LIST ── */
.community-layout {
  max-width: 1100px; margin: 0 auto;
  display: flex; align-items: flex-start; gap: 64px;
}
.community-text { flex: 0 0 380px; }
.community-text h2 { margin: 8px 0 0; }

.community-players {
  flex: 1; min-width: 0;
  background: var(--surface);
  border: 1px solid var(--border2);
  border-radius: 14px;
  overflow: hidden;
  box-shadow: 0 8px 32px rgba(0,0,0,0.06);
}

.cp2-row {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 14px 20px;
  border-bottom: 1px solid var(--border);
  transition: background 0.15s;
}
.cp2-row:last-child { border-bottom: none; }
.cp2-row:hover { background: var(--bg3); }

.cp2-avatar {
  width: 38px; height: 38px;
  border-radius: 50%;
  background: var(--accent-bg);
  color: var(--accent);
  font-family: var(--font-ui);
  font-size: 13px;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  border: 1px solid var(--border2);
}

.cp2-info { flex: 1; min-width: 0; }
.cp2-name {
  font-family: var(--font-ui);
  font-size: 14px;
  font-weight: 600;
  color: var(--text);
  line-height: 1.3;
}
.cp2-status {
  font-size: 12px;
  color: var(--text3);
  margin-top: 2px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  max-width: 260px;
}

.cp2-badge {
  font-family: var(--font-ui);
  font-size: 11px;
  font-weight: 600;
  color: var(--accent);
  white-space: nowrap;
  display: flex;
  align-items: center;
  gap: 4px;
}
.cp2-badge::before {
  content: '';
  width: 6px; height: 6px;
  border-radius: 50%;
  background: #5cb85c;
  flex-shrink: 0;
}

/* ── MODAL (landing version) ── */
.modal-overlay {
  position: fixed;
  inset: 0;
  background: var(--modal-bg);
  z-index: 200;
  display: flex;
  align-items: center;
  justify-content: center;
  backdrop-filter: blur(8px);
  opacity: 0;
  pointer-events: none;
  transition: opacity var(--transition);
}
.modal-overlay.open { opacity: 1; pointer-events: all; }

.modal {
  background: var(--surface);
  border: 1px solid var(--border2);
  border-radius: var(--radius-lg);
  position: relative;
  transform: translateY(16px);
  transition: transform var(--transition);
  padding: 48px 44px;
  width: 100%; max-width: 440px;
  box-shadow: 0 32px 80px rgba(0,0,0,0.2);
  max-height: 90vh;
  overflow-y: auto;
}
.modal-overlay.open .modal { transform: translateY(0); }

.modal-close {
  position: absolute; top: 20px; right: 20px;
  width: 32px; height: 32px;
  background: var(--bg2); border: 1px solid var(--border);
  border-radius: 50%; cursor: pointer;
  display: flex; align-items: center; justify-content: center;
  color: var(--text3); font-size: 16px;
  transition: all var(--transition);
}
.modal-close:hover { color: var(--text); background: var(--bg3); }

.modal-logo { font-family: var(--font-display); font-size: 22px; font-weight: 700; color: var(--accent); letter-spacing: 0.08em; text-align: center; margin-bottom: 8px; }
.modal h2 { font-size: 26px; text-align: center; margin-bottom: 6px; letter-spacing: 0.02em; }
.modal-subtitle { text-align: center; font-size: 15px; color: var(--text2); font-style: italic; margin-bottom: 32px; }

.tab-row { display: flex; background: var(--bg2); border: 1px solid var(--border); border-radius: var(--radius); padding: 4px; margin-bottom: 28px; gap: 4px; }
.tab-btn { flex: 1; padding: 9px; border: none; background: transparent; border-radius: 8px; font-family: var(--font-ui); font-size: 14px; font-weight: 500; color: var(--text2); cursor: pointer; transition: all var(--transition); }
.tab-btn.active { background: var(--surface); color: var(--accent); box-shadow: 0 2px 8px rgba(0,0,0,0.08); }
.tab-content { display: none; }
.tab-content.active { display: block; }

/* ── MODAL FORM ELEMENTS ── */
.form-group { margin-bottom: 16px; }
.form-label {
  display: block;
  font-size: 11px; font-weight: 500; letter-spacing: 0.06em; text-transform: uppercase;
  color: var(--text2); margin-bottom: 7px;
}
.form-input {
  width: 100%;
  background: var(--bg2); border: 1px solid var(--border2); border-radius: 8px;
  padding: 11px 14px; font-family: var(--font-ui); font-size: 14px; color: var(--text);
  outline: none; box-sizing: border-box; transition: border-color var(--transition);
}
.form-input:focus { border-color: var(--accent); box-shadow: 0 0 0 3px var(--accent-bg); }
.form-input::placeholder { color: var(--text3); }
.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.form-divider {
  display: flex; align-items: center; gap: 12px; margin: 20px 0;
  color: var(--text3); font-family: var(--font-ui); font-size: 12px;
}
.form-divider::before, .form-divider::after { content: ''; flex: 1; height: 1px; background: var(--border); }
.btn-google {
  width: 100%; background: var(--bg2); border: 1px solid var(--border2);
  border-radius: var(--radius); padding: 12px; font-family: var(--font-ui); font-size: 14px;
  font-weight: 500; color: var(--text2); cursor: pointer;
  display: flex; align-items: center; justify-content: center; gap: 10px; transition: all var(--transition);
}
.btn-google:hover { background: var(--bg3); color: var(--text); border-color: var(--accent); }
.form-terms { font-family: var(--font-ui); font-size: 11px; color: var(--text3); text-align: center; margin-top: 14px; line-height: 1.5; }
.form-terms a { color: var(--accent); text-decoration: none; }
.form-terms a:hover { text-decoration: underline; }

/* ── FOOTER ── */
footer {
  position: relative; z-index: 1;
  border-top: 1px solid var(--border);
  padding: 56px 48px 0;
  display: flex;
  flex-wrap: wrap;
  gap: 48px;
}

.footer-brand { flex: 0 0 220px; }
.footer-logo { font-family: var(--font-display); font-size: 17px; font-weight: 700; color: var(--accent); letter-spacing: 0.08em; margin-bottom: 12px; }
.footer-tagline { font-family: var(--font-ui); font-size: 13px; color: var(--text3); line-height: 1.6; margin: 0; }

.footer-cols { display: flex; gap: 40px; flex: 1; }
.footer-col { flex: 1; min-width: 100px; }
.footer-col-title {
  font-family: var(--font-ui); font-size: 11px; font-weight: 600;
  letter-spacing: 0.1em; text-transform: uppercase; color: var(--text);
  margin-bottom: 16px;
}
.footer-col ul { list-style: none; display: flex; flex-direction: column; gap: 10px; }
.footer-col ul a { font-family: var(--font-ui); font-size: 13px; color: var(--text3); text-decoration: none; transition: color var(--transition); }
.footer-col ul a:hover { color: var(--accent); }

.footer-bottom {
  width: 100%;
  display: flex; align-items: center; justify-content: center;
  padding: 20px 0 36px;
  border-top: 1px solid rgba(200,170,120,0.08);
  margin-top: 32px;
}
.footer-copy { font-family: var(--font-ui); font-size: 12px; color: var(--text3); text-align: center; }

/* ── CHARACTER CREATION MODAL ── */
.chm {
  background: var(--surface); border: 1px solid var(--border2);
  border-radius: 16px; overflow: hidden;
  width: 100%; max-width: 440px;
  box-shadow: 0 32px 80px rgba(0,0,0,0.35);
}
.chm-header {
  display: flex; align-items: center; gap: 10px;
  padding: 14px 18px; border-bottom: 1px solid var(--border); background: var(--bg2);
}
.chm-world { font-family: var(--font-ui); font-size: 14px; font-weight: 600; color: var(--text); flex: 1;
  font-family: "Apple Color Emoji","Segoe UI Emoji","Noto Color Emoji",emoji,var(--font-ui); }
.chm-body { padding: 20px 20px 16px; }
.chm-body h3 { font-family: var(--font-display); font-size: 18px; font-weight: 600; color: var(--text); margin-bottom: 4px; }
.chm-hint { font-size: 13px; color: var(--text3); margin-bottom: 18px; }
.chm-field { margin-bottom: 14px; }
.chm-field label { display: block; font-family: var(--font-ui); font-size: 12px; color: var(--text3); margin-bottom: 5px; }
.chm-footer { padding: 4px 20px 20px; }

/* ── Role combobox ── */
.chm-role-wrap { position: relative; }
.chm-role-row { display: flex; }
.chm-role-row .gcm-input {
  border-radius: 8px 0 0 8px !important;
  border-right: none !important;
  flex: 1;
}
.chm-role-row .gcm-input:focus { border-color: var(--accent); box-shadow: none; }
.chm-role-toggle {
  width: 36px; flex-shrink: 0;
  background: var(--bg); border: 1px solid var(--border2);
  border-radius: 0 8px 8px 0;
  color: var(--text3); cursor: pointer; font-size: 11px;
  display: flex; align-items: center; justify-content: center;
  transition: all 0.15s;
}
.chm-role-toggle:hover { background: var(--bg2); color: var(--text); border-color: var(--border2); }
.chm-role-toggle.open { color: var(--accent); border-color: var(--accent); background: var(--accent-bg); }
.chm-role-row:focus-within .chm-role-toggle { border-color: var(--accent); }

.chm-arch-dropdown {
  display: none;
  position: absolute; top: calc(100% + 4px); left: 0; right: 0;
  background: var(--surface); border: 1px solid var(--border2);
  border-radius: 10px; overflow: hidden;
  box-shadow: 0 12px 32px rgba(0,0,0,0.25);
  z-index: 200;
  animation: chm-dd-in 0.12s ease;
}
.chm-arch-dropdown.open { display: block; }
@keyframes chm-dd-in {
  from { opacity: 0; transform: translateY(-4px); }
  to   { opacity: 1; transform: translateY(0); }
}
.chm-arch-opt {
  padding: 9px 14px;
  font-family: var(--font-ui); font-size: 13px; color: var(--text2);
  cursor: pointer; transition: background 0.1s;
  display: flex; align-items: center; gap: 10px;
  border-bottom: 1px solid var(--border);
}
.chm-arch-opt:last-child { border-bottom: none; }
.chm-arch-opt:hover { background: var(--bg2); color: var(--accent); }
.chm-arch-opt-icon { font-size: 15px; width: 20px; text-align: center; flex-shrink: 0;
  font-family: "Apple Color Emoji","Segoe UI Emoji","Noto Color Emoji",emoji; }

/* ── SHARED LANDING MODAL OVERLAY ── */
.lm-overlay {
  display: none; position: fixed; inset: 0;
  background: rgba(0,0,0,0.6); z-index: 2000;
  align-items: center; justify-content: center;
  padding: 20px;
  backdrop-filter: blur(4px);
}
.lm-overlay.open, .lm-overlay[style*="flex"] { display: flex; }

/* ── WORLD DETAIL MODAL ── */
.wdm {
  background: var(--surface); border: 1px solid var(--border2);
  border-radius: 16px; overflow: hidden;
  width: 100%; max-width: 580px; max-height: 90vh; overflow-y: auto;
  box-shadow: 0 32px 80px rgba(0,0,0,0.35);
}
.wdm-img {
  height: 140px;
  display: flex; align-items: center; justify-content: center;
  font-size: 56px;
  font-family: "Apple Color Emoji","Segoe UI Emoji","Noto Color Emoji",emoji;
  position: relative;
}
.wdm-close { position: absolute; top: 12px; right: 12px; background: rgba(0,0,0,0.35); border: none; color: #fff; border-radius: 50%; width: 30px; height: 30px; cursor: pointer; font-size: 14px; display: flex; align-items: center; justify-content: center; }
.wdm-body { padding: 20px 24px 24px; }
.wdm-genres { display: flex; gap: 6px; flex-wrap: wrap; margin-bottom: 10px; }
.wdm-name { font-family: var(--font-display); font-size: 22px; font-weight: 700; color: var(--text); margin-bottom: 12px; line-height: 1.2; }
.wdm-desc { font-size: 15px; color: var(--text2); line-height: 1.65; margin-bottom: 14px; }
.wdm-features { list-style: none; display: flex; flex-wrap: wrap; gap: 6px; margin-bottom: 16px; }
.wdm-features li { background: var(--bg2); border: 1px solid var(--border); border-radius: 20px; padding: 3px 12px; font-family: var(--font-ui); font-size: 12px; color: var(--text2); }
.wdm-meta { display: flex; gap: 16px; font-family: var(--font-ui); font-size: 13px; color: var(--text3); margin-bottom: 20px; }
.wdm-btns { display: flex; gap: 10px; flex-wrap: wrap; }
.wdm-btns .btn { flex: 1; min-width: 140px; text-align: center; justify-content: center; }

/* ── GUEST CHAT MODAL ── */
.gcm {
  background: var(--surface); border: 1px solid var(--border2);
  border-radius: 16px; overflow: hidden;
  width: 100%; max-width: 560px; max-height: 90vh;
  display: flex; flex-direction: column;
  box-shadow: 0 32px 80px rgba(0,0,0,0.35);
}
.gcm-header {
  display: flex; align-items: center; gap: 10px;
  padding: 12px 16px; border-bottom: 1px solid var(--border);
  background: var(--bg2); flex-shrink: 0;
}
.gcm-world-name { font-family: var(--font-ui); font-size: 14px; font-weight: 600; color: var(--text); flex: 1; font-family: "Apple Color Emoji","Segoe UI Emoji","Noto Color Emoji",emoji,var(--font-ui); }
.gcm-turns-badge { background: var(--accent-bg); color: var(--accent); border: 1px solid var(--border2); border-radius: 20px; padding: 2px 10px; font-family: var(--font-ui); font-size: 11px; font-weight: 600; white-space: nowrap; }
.gcm-close-btn { background: none; border: none; color: var(--text3); cursor: pointer; font-size: 16px; padding: 4px; border-radius: 4px; transition: color 0.15s; }
.gcm-close-btn:hover { color: var(--text); }
.gcm-messages { flex: 1; overflow-y: auto; padding: 14px 16px; display: flex; flex-direction: column; gap: 10px; min-height: 280px; max-height: 380px; scrollbar-width: thin; }
.gcm-msg { max-width: 85%; padding: 9px 13px; border-radius: 12px; font-size: 14px; line-height: 1.55; }
.gcm-msg-gm { align-self: flex-start; background: var(--bg2); border: 1px solid var(--border); border-radius: 3px 12px 12px 12px; color: var(--text2); }
.gcm-msg-player { align-self: flex-end; background: var(--accent-bg); border: 1px solid var(--border2); border-radius: 12px 12px 3px 12px; color: var(--text); }
.gcm-gm-label { display: block; font-family: var(--font-ui); font-size: 10px; font-weight: 700; color: var(--accent); letter-spacing: 0.08em; text-transform: uppercase; margin-bottom: 3px; }
.gcm-typing span:last-child { opacity: 0.5; animation: gcm-dots 1.2s step-end infinite; }

/* ── GM TYPING INDICATOR ── */
.gcm-typing-indicator {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 6px;
  padding: 10px 14px !important;
}
.gcm-typing-indicator .gcm-gm-label {
  font-size: 10px; font-weight: 700; color: var(--accent);
  letter-spacing: 0.08em; text-transform: uppercase;
}
.gcm-dots {
  display: flex;
  align-items: center;
  gap: 5px;
  padding: 2px 0;
}
.gcm-dots span {
  width: 7px; height: 7px;
  background: rgba(200,170,120,0.5);
  border-radius: 50%;
  animation: gcm-bounce 1.3s ease-in-out infinite;
}
.gcm-dots span:nth-child(2) { animation-delay: 0.18s; }
.gcm-dots span:nth-child(3) { animation-delay: 0.36s; }
@keyframes gcm-bounce {
  0%, 60%, 100% { transform: translateY(0);    opacity: 0.4; }
  30%            { transform: translateY(-5px); opacity: 1;   background: var(--accent); }
}

.gcm-input-row {
  display: flex; gap: 8px;
  padding: 10px 12px;
  border-top: 1px solid var(--border);
  background: var(--bg2);
  flex-shrink: 0;
  align-items: center;
}
.gcm-input {
  width: 100%; box-sizing: border-box;
  background: var(--bg); border: 1px solid var(--border2); border-radius: 8px;
  padding: 10px 13px; font-size: 14px; font-family: var(--font-body);
  color: var(--text); outline: none; transition: border-color 0.15s;
}
.gcm-input-row .gcm-input { flex: 1; width: auto; height: 38px; padding: 0 13px; }
.gcm-input:focus { border-color: var(--accent); box-shadow: 0 0 0 3px var(--accent-bg); }
.gcm-input::placeholder { color: var(--text3); }
.gcm-send-btn {
  width: 38px; height: 38px; background: var(--accent); border: none;
  border-radius: 8px; color: #fff; font-size: 18px; cursor: pointer;
  display: flex; align-items: center; justify-content: center;
  transition: background 0.15s; flex-shrink: 0;
}
.gcm-send-btn:hover { background: var(--accent2); }
.gcm-send-btn:disabled { opacity: 0.4; cursor: default; }
.gcm-cta { display: flex; flex-direction: column; align-items: center; text-align: center; padding: 28px 24px; border-top: 1px solid var(--border); background: var(--bg2); flex-shrink: 0; }
.gcm-cta-icon { font-size: 32px; font-family: "Apple Color Emoji","Segoe UI Emoji","Noto Color Emoji",emoji; margin-bottom: 8px; }
.gcm-cta-title { font-family: var(--font-display); font-size: 18px; font-weight: 600; color: var(--text); margin-bottom: 6px; }
.gcm-cta-sub { font-size: 13px; color: var(--text3); max-width: 380px; line-height: 1.5; }

@keyframes gcm-dots { 0%,100% { content: '...'; } 33% { content: '.'; } 66% { content: '..'; } }

/* ── HERO MOBILE PREVIEW ── */
.hero-mobile-preview {
  display: none;
  flex-direction: column; gap: 8px;
  margin-top: 24px; padding: 14px;
  background: var(--surface); border: 1px solid var(--border2);
  border-radius: 12px;
}
.hmp-msg { padding: 8px 12px; border-radius: 10px; font-size: 13px; line-height: 1.5; max-width: 88%; }
.hmp-gm   { align-self: flex-start; background: var(--bg2); border: 1px solid var(--border); color: var(--text2); border-radius: 3px 10px 10px 10px; }
.hmp-player { align-self: flex-end; background: var(--accent-bg); border: 1px solid var(--border2); color: var(--text); border-radius: 10px 10px 3px 10px; }

/* ── RESPONSIVE ── */
@media (min-width: 769px) and (max-width: 1024px) {
  .nav-btn-mobile { display: inline-flex; padding: 9px 18px; font-size: 14px; }
}

@media (max-width: 1200px) {
  .sb-stat { padding: 0 28px; }
}

@media (max-width: 1024px) {
  #landingWorldsGrid { grid-template-columns: repeat(2, 1fr); }
  nav { padding: 0 24px; }
  .nav-links { gap: 20px; }
  .nav-links a { font-size: 13px; }
  .nav-btn-register { display: none; }
  .hero-visual { display: none; }
  .hero-content { max-width: 100%; }
  .worlds-grid { grid-template-columns: repeat(3, 1fr); }
  .pricing-grid { grid-template-columns: 1fr 1fr; gap: 16px; }
  .pricing-grid .plan:last-child { grid-column: 1 / -1; max-width: 480px; margin: 0 auto; width: 100%; }
  .community-layout { flex-direction: column; gap: 32px; }
  .community-text { flex: none; }
  .steps { flex-direction: column; }
  .step-arrow { display: none; }
  .footer-brand { flex: 0 0 100%; }
  .footer-cols { flex-wrap: wrap; }
}

@media (max-width: 768px) {
  nav { padding: 0 20px; height: 60px; }
  .nav-links { display: none; }
  .nav-right { gap: 8px; }
  .nav-btn-login, .nav-btn-register, .nav-btn-mobile { display: none; }
  .nav-burger { display: flex; }
  .nav-mobile-menu { display: flex; }

  .hero { padding: 90px 20px 60px; min-height: auto; }
  .hero-visual { display: none; }
  .hero-content { max-width: 100%; }
  section { padding: 56px 20px; }
  h1 { font-size: clamp(32px, 8vw, 48px); }

  .steps { flex-direction: column; gap: 12px; margin-top: 32px; }
  .step-arrow { display: none; }
  .step { padding: 22px 20px; }

  .worlds-header { flex-direction: column; align-items: flex-start; gap: 16px; margin-bottom: 24px; }

  .pricing-grid { grid-template-columns: 1fr; gap: 14px; margin-top: 32px; }
  .pricing-grid .plan:last-child { grid-column: auto; max-width: 100%; }
  .plan { padding: 24px 22px; }

  .worlds-grid, #landingWorldsGrid { grid-template-columns: repeat(2, 1fr); gap: 12px; }

  .stats-bar { padding: 16px 12px; gap: 0; flex-wrap: wrap; }
  .sb-stat { padding: 8px 16px; }
  .sb-num { font-size: 22px; }
  .sb-sep { display: none; }

  .hero-mobile-preview { display: flex; }

  footer { padding: 40px 20px 0; gap: 32px; }
  .footer-brand { flex: 0 0 100%; }
  .footer-cols { flex-direction: column; gap: 24px; }
  .footer-bottom { flex-direction: column; gap: 12px; align-items: flex-start; }
  .footer-legal { flex-wrap: wrap; gap: 12px; }

  .hero-actions { flex-direction: column; align-items: stretch; gap: 10px; }
  .hero-actions .btn { text-align: center; justify-content: center; }
  .btn-lg { font-size: 15px; padding: 13px 28px; }
}

@media (max-width: 480px) {
  .worlds-grid, #landingWorldsGrid { grid-template-columns: 1fr; }
  .hero-content { text-align: center; }
  .hero-mobile-preview { display: flex; }
  .stats-bar { justify-content: flex-start; }
  .sb-stat { padding: 8px 20px; }
}

/* ── HERO CHAT MOCK ── */
.hcm {
  position: absolute;
  right: 60px; top: 50%;
  transform: translateY(-50%);
  width: 360px; height: 420px;
  background: #0E0C0A;
  border: 1px solid rgba(255,255,255,0.09);
  border-radius: 16px;
  box-shadow: 0 32px 80px rgba(0,0,0,0.5), 0 0 0 1px rgba(255,255,255,0.03);
  display: flex; flex-direction: column; overflow: hidden;
}
.hcm-header {
  display: flex; align-items: center; justify-content: space-between;
  padding: 12px 16px;
  border-bottom: 1px solid rgba(255,255,255,0.07);
  flex-shrink: 0;
}
.hcm-world { display: flex; align-items: center; gap: 8px; }
.hcm-icon { font-family: "Apple Color Emoji","Segoe UI Emoji","Noto Color Emoji",emoji; font-size: 16px; }
.hcm-world span:last-child { font-family: var(--font-ui); font-size: 13px; font-weight: 600; color: rgba(255,255,255,0.85); letter-spacing: 0.02em; }
.hcm-live { display: flex; align-items: center; gap: 5px; font-family: var(--font-ui); font-size: 11px; color: #5cb85c; }
.hcm-live i { width: 6px; height: 6px; border-radius: 50%; display: inline-block; background: #5cb85c; animation: pulse-dot 2s ease-in-out infinite; }
.hcm-body {
  flex: 1; overflow-y: auto; padding: 12px;
  display: flex; flex-direction: column; gap: 8px;
  mask-image: linear-gradient(to bottom, transparent 0%, black 18%);
  -webkit-mask-image: linear-gradient(to bottom, transparent 0%, black 18%);
  scrollbar-width: none;
}
.hcm-body::-webkit-scrollbar { display: none; }
.hcm-msg {
  max-width: 84%; padding: 8px 12px; border-radius: 12px;
  font-size: 12.5px; line-height: 1.55;
  animation: hcm-pop 0.25s cubic-bezier(.34,1.56,.64,1) both;
}
.hcm-msg-player {
  align-self: flex-end;
  background: rgba(196,120,42,0.18); border: 1px solid rgba(196,120,42,0.28);
  border-radius: 12px 12px 3px 12px; color: rgba(255,255,255,0.88);
}
.hcm-msg-gm {
  align-self: flex-start;
  background: rgba(255,255,255,0.05); border: 1px solid rgba(255,255,255,0.08);
  border-radius: 3px 12px 12px 12px; color: rgba(255,255,255,0.72);
}
.hcm-gm-label {
  display: block; font-family: var(--font-ui); font-size: 10px; font-weight: 700;
  color: var(--accent); letter-spacing: 0.08em; margin-bottom: 3px; text-transform: uppercase;
}
.hcm-cursor::after { content: '▌'; opacity: 0.65; animation: blink-cur 0.7s step-end infinite; }
.hcm-footer {
  display: flex; align-items: center; gap: 8px;
  padding: 10px 12px; border-top: 1px solid rgba(255,255,255,0.07); flex-shrink: 0;
}
.hcm-input-mock {
  flex: 1; background: rgba(255,255,255,0.04); border: 1px solid rgba(255,255,255,0.08);
  border-radius: 8px; padding: 8px 12px; font-size: 12px;
  color: rgba(255,255,255,0.25); font-family: var(--font-ui); cursor: default;
}
.hcm-send {
  width: 32px; height: 32px; background: var(--accent); border: none; border-radius: 8px;
  color: #fff; font-size: 16px; cursor: pointer; display: flex;
  align-items: center; justify-content: center; transition: opacity 0.15s;
}
.hcm-send:hover { opacity: 0.85; }

/* ── ANIMATIONS ── */
@keyframes fadeUp {
  from { opacity: 0; transform: translateY(24px); }
  to   { opacity: 1; transform: translateY(0); }
}
.hero-content > * { animation: fadeUp 0.7s ease both; }
.hero-content > *:nth-child(1) { animation-delay: 0.1s; }
.hero-content > *:nth-child(2) { animation-delay: 0.2s; }
.hero-content > *:nth-child(3) { animation-delay: 0.3s; }
.hero-content > *:nth-child(4) { animation-delay: 0.4s; }
.hero-content > *:nth-child(5) { animation-delay: 0.5s; }
@keyframes hcm-pop {
  from { opacity: 0; transform: translateY(6px) scale(0.97); }
  to   { opacity: 1; transform: none; }
}
@keyframes blink-cur { 0%,100% { opacity: 0.65; } 50% { opacity: 0; } }
@keyframes pulse-dot { 0%,100% { opacity: 1; transform: scale(1); } 50% { opacity: 0.6; transform: scale(1.25); } }
