/* ==== design-tokens.css ==== */
/* ==========================================================================
   CyoriaSMP — Design Tokens & Core System
   ใช้ร่วมกันทุกหน้า (public + admin + dashboard)
   ========================================================================== */

/* ─── Fonts ──────────────────────────────────────────────────────────────── */


/* ─── Tokens ─────────────────────────────────────────────────────────────── */

:root {
  /* Backgrounds */
  --bg: #050506;
  --bg-surface: #101114;
  --bg-elevated: #17181c;
  --bg-card: #0e0f12;

  /* Foregrounds */
  --fg: #ffffff;
  --muted: #9aa0ab;
  --subtle: color-mix(in srgb, var(--fg) 40%, transparent);

  /* Borders */
  --border: color-mix(in srgb, var(--fg) 15%, transparent);
  --border-hover: color-mix(in srgb, var(--fg) 30%, transparent);

  /* Accent */
  --accent: #5e6ad2;
  --accent-hover: #7b85e0;
  --accent-muted: color-mix(in srgb, var(--accent) 15%, transparent);
  --accent-border: color-mix(in srgb, var(--accent) 35%, transparent);

  /* Status */
  --success: #22c55e;
  --warning: #eab308;
  --danger: #ef4444;
  --info: #3b82f6;

  /* Typography */
  --font-display: "Inter", "Roboto", system-ui, -apple-system, "Segoe UI", "Helvetica Neue", Arial, sans-serif;
  --font-body: "Roboto", "Inter", system-ui, -apple-system, "Segoe UI", "Helvetica Neue", Arial, sans-serif;
  --font-mono: "Roboto Mono", "SFMono-Regular", Consolas, "Liberation Mono", monospace;

  /* Spacing (8px grid) */
  --space-1: 4px;
  --space-2: 8px;
  --space-3: 12px;
  --space-4: 16px;
  --space-5: 20px;
  --space-6: 24px;
  --space-8: 32px;
  --space-10: 40px;
  --space-12: 48px;

  /* Radii */
  --radius: 8px;
  --radius-sm: 6px;
  --radius-lg: 16px;
  --radius-pill: 999px;

  /* Shadows */
  --shadow: 0 20px 60px color-mix(in srgb, var(--bg) 75%, transparent);
  --shadow-sm: 0 4px 12px color-mix(in srgb, var(--bg) 80%, transparent);

  /* Layout */
  --shell-width: 1180px;
  --header-height: 72px;
}

/* ─── prefers-reduced-motion ────────────────────────────────────────────── */

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }
  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }
}

/* ─── Reset ───────────────────────────────────────────────────────────────── */

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

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  color: var(--fg);
  background: var(--bg);
  font-family: var(--font-body);
  font-size: 15px;
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-x: hidden;
}

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

a {
  color: inherit;
  text-decoration: none;
}

button {
  color: inherit;
  font: inherit;
  cursor: pointer;
}

input,
textarea,
select {
  font: inherit;
  color: var(--fg);
  background: var(--bg-surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 0.5rem 0.75rem;
  outline: none;
  transition: border-color 0.2s ease;
}

input:focus,
textarea:focus,
select:focus {
  border-color: var(--accent-border);
  box-shadow: 0 0 0 3px var(--accent-muted);
}

::placeholder {
  color: var(--muted);
}

/* ─── Utilities ───────────────────────────────────────────────────────────── */

.shell {
  width: min(var(--shell-width), calc(100% - 40px));
  margin: 0 auto;
}

.shell-sm {
  width: min(900px, calc(100% - 40px));
  margin: 0 auto;
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

/* ─── Typography ──────────────────────────────────────────────────────────── */

h1, h2, h3, h4, h5, h6, p {
  margin-top: 0;
}

h1 {
  font-family: var(--font-display);
  font-size: clamp(44px, 8vw, 86px);
  line-height: 1.03;
  letter-spacing: -0.04em;
  font-weight: 600;
  margin-bottom: 26px;
}

h2 {
  font-family: var(--font-display);
  font-size: clamp(28px, 4vw, 44px);
  line-height: 1.1;
  letter-spacing: -0.03em;
  font-weight: 600;
}

h3 {
  font-family: var(--font-display);
  font-size: 18px;
  letter-spacing: -0.01em;
  font-weight: 600;
}

.eyebrow {
  margin: 0 0 18px;
  color: var(--accent);
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.text-mono {
  font-family: var(--font-mono);
}

.text-muted {
  color: var(--muted);
}

.text-sm {
  font-size: 13px;
}

/* ─── Buttons ─────────────────────────────────────────────────────────────── */

.button {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  min-height: 48px;
  padding: 0 24px;
  border-radius: var(--radius);
  font-size: 14px;
  font-weight: 600;
  transition: transform 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
  white-space: nowrap;
}

.button:hover {
  transform: translateY(-2px);
}

.button-primary {
  background: var(--accent);
  color: var(--fg);
  border: 1px solid var(--accent);
}

.button-primary:hover {
  background: var(--accent-hover);
  box-shadow: 0 8px 24px color-mix(in srgb, var(--accent) 25%, transparent);
}

.button-secondary {
  background: transparent;
  color: var(--fg);
  border: 1px solid var(--border);
}

.button-secondary:hover {
  border-color: var(--accent-border);
  background: var(--accent-muted);
}

/* ─── Status Dot ──────────────────────────────────────────────────────────── */

.status-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--muted);
  display: inline-block;
  flex-shrink: 0;
}

.status-dot.status-online {
  background: var(--success);
  box-shadow: 0 0 8px color-mix(in srgb, var(--success) 50%, transparent);
}

.status-dot.status-offline {
  background: var(--danger);
}

/* ==== cyoria.css ==== */
/* ==========================================================================
   CYORIA SMP — Dojo-Inspired Design System
   Clean · Glass · Premium
   ========================================================================== */


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

/* ── Compatibility aliases ────────────────────────────────────────────────
   หน้านี้มี component รุ่นเก่าที่ใช้ชื่อ var คนละชุดกับ global tokens
   จึงแปลงชื่อให้ชี้กลับไปที่ design-tokens.css เท่านั้น ห้ามประกาศสี/รัศมี
   ชุดใหม่ที่นี่ เพราะไฟล์นี้ถูกรวมเข้า site.css ของทุกหน้าแล้ว */
:root {
    --primary: var(--accent);
    --primary-hover: var(--accent-hover);
    --primary-muted: var(--accent-muted);
    --primary-border: var(--accent-border);
    --text: var(--fg);
    --text-secondary: color-mix(in srgb, var(--fg) 78%, var(--bg));
    --text-muted: var(--muted);
    --text-color: var(--fg);
    --font-th: var(--font-display);
    --font-en: var(--font-body);
    --transition: 0.2s ease;
}

html { scroll-behavior: smooth; }

body {
    font-family: var(--font-en);
    color: var(--text);
    min-height: 100vh;
    -webkit-font-smoothing: antialiased;
    line-height: 1.6;
}

a { color: inherit; text-decoration: none; }
button { font-family: inherit; cursor: pointer; border: none; background: none; color: inherit; }

input, textarea, select {
    font-family: inherit;
    font-size: inherit;
    color: var(--text);
    background: rgba(255,255,255,0.04);
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    padding: 0.75rem 1rem;
    outline: none;
    transition: border var(--transition);
    width: 100%;
}
input:focus, textarea:focus, select:focus {
    border-color: var(--primary-border);
    box-shadow: 0 0 0 3px var(--primary-muted);
}
::placeholder { color: var(--text-muted); }

/* ===================== BACKGROUND ===================== */

.background-effect {
    position: fixed;
    top: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 100vw;
    height: 70vh;
    background: radial-gradient(circle at 50% 0%, color-mix(in srgb, var(--primary) 14%, transparent), transparent 62%);
    z-index: 1;
    pointer-events: none;
}
.bg-mesh { display: none; } /* replaced by background-effect */

/* ===================== CONTAINER ===================== */

.container {
    width: 100%;
    max-width: 1280px;
    margin: 0 auto;
    padding: 0 1.5rem;
}
.container-sm { max-width: 900px; }
.container-lg { max-width: 1400px; }
.w-full { width: 100%; }

/* ===================== UTILITY ===================== */

.flex { display: flex; }
.flex-col { flex-direction: column; }
.items-center { align-items: center; }
.items-start { align-items: flex-start; }
.justify-center { justify-content: center; }
.justify-between { justify-content: space-between; }
.gap-1 { gap: 0.25rem; }
.gap-2 { gap: 0.5rem; }
.gap-3 { gap: 0.75rem; }
.gap-4 { gap: 1rem; }
.gap-6 { gap: 1.5rem; }
.gap-8 { gap: 2rem; }
.mb-2 { margin-bottom: 0.5rem; }
.mb-4 { margin-bottom: 1rem; }
.mb-6 { margin-bottom: 1.5rem; }
.mb-8 { margin-bottom: 2rem; }
.mb-12 { margin-bottom: 3rem; }
.mt-2 { margin-top: 0.5rem; }
.mt-4 { margin-top: 1rem; }
.mt-6 { margin-top: 1.5rem; }
.mt-8 { margin-top: 2rem; }
.mt-auto { margin-top: auto; }
.text-center { text-align: center; }
.text-muted { color: var(--muted); }
.text-sm { font-size: 0.875rem; }
.text-xs { font-size: 0.75rem; }
.font-mono { font-family: var(--font-mono); }
.font-bold { font-weight: 700; }
.font-semibold { font-weight: 600; }
.hide-mobile { display: flex; }
.show-mobile { display: none; }
.grid { display: grid; }
.grid-2 { grid-template-columns: repeat(2, 1fr); }
.grid-3 { grid-template-columns: repeat(3, 1fr); }

.gradient-text {
    background: linear-gradient(135deg, var(--primary), var(--primary-hover));
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
}
.text-primary { color: var(--primary); }

/* ===================== BADGE ===================== */

.badge {
    display: inline-flex;
    align-items: center;
    gap: 0.375rem;
    padding: 0.25rem 0.75rem;
    border-radius: var(--radius-pill);
    font-size: 0.75rem;
    font-weight: 600;
    border: 1px solid var(--border);
    background: var(--bg-card);
    color: var(--text-secondary);
}
.badge-primary {
    background: var(--primary-muted);
    border-color: var(--primary-border);
    color: var(--primary-hover);
}
.badge-success {
    background: rgba(16, 185, 129, 0.12);
    border-color: rgba(16, 185, 129, 0.25);
    color: var(--success);
}

/* ===================== BUTTONS ===================== */

.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    padding: 0.625rem 1.5rem;
    border-radius: var(--radius-pill);
    font-size: 0.875rem;
    font-weight: 600;
    transition: all var(--transition);
    white-space: nowrap;
    line-height: 1.4;
    cursor: pointer;
}
.btn-primary {
    background: var(--primary);
    color: #fff;
    border: 1px solid var(--primary);
}
.btn-primary:hover {
    background: var(--primary-hover);
    border-color: var(--primary-hover);
    transform: translateY(-1px);
    box-shadow: 0 4px 20px rgba(59, 130, 246, 0.3);
}
.btn-secondary {
    background: transparent;
    color: var(--text-secondary);
    border: 1px solid var(--border);
}
.btn-secondary:hover {
    background: rgba(255,255,255,0.04);
    border-color: var(--border-hover);
    color: var(--text);
}
.btn-ghost {
    background: transparent;
    color: var(--text-secondary);
    border: 1px solid transparent;
}
.btn-ghost:hover {
    background: rgba(255,255,255,0.04);
    color: var(--text);
}
.btn-sm { padding: 0.4rem 1rem; font-size: 0.8125rem; }
.btn-lg { padding: 0.875rem 2rem; font-size: 0.9375rem; }
.btn-icon {
    width: 2.25rem;
    height: 2.25rem;
    padding: 0;
    border-radius: var(--radius-sm);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border: 1px solid var(--border);
    color: var(--text-secondary);
    transition: all var(--transition);
}
.btn-icon:hover {
    background: rgba(255,255,255,0.04);
    border-color: var(--border-hover);
    color: var(--text);
}
.btn-block { width: 100%; }
.btn:disabled { opacity: 0.5; cursor: not-allowed; }

/* ===================== NAVBAR ===================== */

/* .navbar / .nav-left / .nav-right ที่เคยอยู่ตรงนี้ถูกลบออก
   มันเขียนไว้สำหรับ markup อีกชุด (.nav-inner / .nav-center / .nav-brand-text)
   ซึ่ง "ไม่มีหน้าไหนใช้แล้ว" แต่ตัว .navbar ดันไปทับ navbar ทรงแคปซูลใน style.css
   ทำให้หน้า terms/voice/profile/dashboard/panel ได้ navbar สี่เหลี่ยมเต็มจอคนละแบบกับหน้าอื่น
   ถ้าจะเพิ่ม navbar style ให้แก้ที่ style.css ที่เดียว */
.nav-inner {
    max-width: 1280px;
    margin: 0 auto;
    display: flex;
    justify-content: space-between;
    align-items: center;
    height: 64px;
    padding: 0 1.5rem;
}
.nav-logo-img {
    width: 2rem;
    height: 2rem;
    border-radius: 0.5rem;
    object-fit: contain;
}
.nav-brand-text {
    display: flex;
    flex-direction: column;
    padding-right: 1rem;
    border-right: 1px solid var(--border);
}
.nav-brand-name {
    font-family: var(--font-th);
    font-weight: 800;
    font-size: 1rem;
    color: var(--text);
    line-height: 1.2;
}
.nav-brand-sub {
    font-size: 0.625rem;
    color: var(--text-muted);
    font-weight: 500;
    line-height: 1.2;
}
.nav-center {
    display: flex;
    align-items: center;
    gap: 0.375rem;
}
.nav-link {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.5rem 1rem;
    border-radius: var(--radius-pill);
    font-size: 0.875rem;
    font-weight: 600;
    color: var(--text-secondary);
    text-decoration: none;
    transition: all var(--transition);
    border: 1px solid transparent;
}
.nav-link:hover {
    color: var(--text);
    background: rgba(255,255,255,0.04);
    border-color: var(--border);
}
.nav-link.active {
    background: var(--primary);
    color: #fff;
    border-color: var(--primary);
    box-shadow: 0 4px 14px rgba(59, 130, 246, 0.3);
}
.nav-status {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.375rem 0.875rem;
    border-radius: var(--radius-pill);
    border: 1px solid var(--border);
    font-size: 0.75rem;
    color: var(--text-muted);
}
.status-dot {
    width: 0.5rem;
    height: 0.5rem;
    border-radius: 50%;
    flex-shrink: 0;
}
.status-dot.online { background: var(--success); box-shadow: 0 0 6px rgba(16, 185, 129, 0.4); }
.status-dot.offline { background: var(--danger); box-shadow: 0 0 6px rgba(239, 68, 68, 0.4); }
.status-dot.loading { background: var(--text-muted); }

.lang-toggle {
    display: flex;
    align-items: center;
    gap: 2px;
    padding: 2px;
    background: rgba(255,255,255,0.04);
    border-radius: var(--radius-pill);
    border: 1px solid var(--border);
}
.lang-btn {
    padding: 0.25rem 0.5rem;
    border-radius: var(--radius-pill);
    font-size: 0.6875rem;
    font-weight: 700;
    color: var(--text-muted);
    cursor: pointer;
    transition: all var(--transition);
}
.lang-btn.active {
    background: var(--primary);
    color: #fff;
}
.lang-btn:hover:not(.active) { color: var(--text); }

.btn-hamburger {
    display: none;
    width: 2.25rem;
    height: 2.25rem;
    align-items: center;
    justify-content: center;
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    color: var(--text-secondary);
    font-size: 1.125rem;
    transition: all var(--transition);
}
.btn-hamburger:hover {
    background: rgba(255,255,255,0.04);
    color: var(--text);
}

/* ===================== SECTION ===================== */

.section {
    padding: 4rem 0;
}
.section-header {
    text-align: center;
    margin-bottom: 2.5rem;
}
.section-tag {
    display: inline-flex;
    align-items: center;
    gap: 0.375rem;
    padding: 0.25rem 0.875rem;
    border-radius: var(--radius-pill);
    font-size: 0.75rem;
    font-weight: 600;
    letter-spacing: 0.02em;
    background: var(--primary-muted);
    border: 1px solid var(--primary-border);
    color: var(--primary-hover);
    margin-bottom: 0.75rem;
    text-transform: uppercase;
}
.section-title {
    font-family: var(--font-th);
    font-size: 2.25rem;
    font-weight: 800;
    line-height: 1.15;
    color: var(--text);
    margin-bottom: 0.75rem;
}
.section-title em { font-style: normal; color: var(--primary); }
.section-desc {
    color: var(--text-secondary);
    font-size: 1rem;
    max-width: 560px;
    margin: 0 auto;
    line-height: 1.6;
}

/* ===================== HERO ===================== */

.hero {
    padding: 6rem 0 3rem;
}
.hero-card {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    padding: 2.5rem;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 3rem;
    align-items: center;
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    box-shadow: var(--shadow-lg);
    position: relative;
    overflow: hidden;
}
.hero-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 4px;
    height: 100%;
    background: var(--primary);
}
.hero-tag {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    margin-bottom: 1.25rem;
}
.hero-live-dot {
    width: 0.5rem;
    height: 0.5rem;
    border-radius: 50%;
    background: var(--success);
    box-shadow: 0 0 6px rgba(16, 185, 129, 0.5);
    animation: pulse-dot 2s ease-in-out infinite;
}
@keyframes pulse-dot {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.5; }
}
.hero-title {
    font-family: var(--font-th);
    font-size: 3.5rem;
    font-weight: 900;
    line-height: 1.05;
    margin-bottom: 0.75rem;
}
.hero-sub {
    font-size: 1.125rem;
    color: var(--text-secondary);
    margin-bottom: 1rem;
    max-width: 480px;
}
.hero-desc {
    color: var(--text-secondary);
    font-size: 0.95rem;
    margin-bottom: 1.5rem;
    max-width: 480px;
}
.hero-btns {
    display: flex;
    gap: 0.75rem;
    flex-wrap: wrap;
    margin-bottom: 2rem;
}
.hero-stats {
    display: flex;
    gap: 2rem;
    opacity: 0.6;
}
.hero-stat-val {
    font-family: var(--font-mono);
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--text);
}
.hero-stat-lbl {
    font-size: 0.6875rem;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.05em;
    font-weight: 500;
}
.hero-stat-div {
    width: 1px;
    background: var(--border);
}

/* Hero Visual */
.hero-visual {
    display: flex;
    justify-content: center;
    align-items: center;
    position: relative;
}
.hero-logo-ring {
    position: relative;
    width: 260px;
    height: 260px;
    display: flex;
    align-items: center;
    justify-content: center;
}
.hero-logo-ring-inner, .hero-logo-ring-outer {
    position: absolute;
    border-radius: 50%;
    border: 1px solid var(--border);
    animation: ring-spin 30s linear infinite;
}
.hero-logo-ring-inner { inset: 0; }
.hero-logo-ring-outer {
    inset: -20px;
    border-color: rgba(59, 130, 246, 0.08);
    animation: ring-spin 20s linear infinite reverse;
}
@keyframes ring-spin {
    from { transform: rotate(0deg); }
    to { transform: rotate(360deg); }
}
.hero-logo-box {
    width: 180px;
    height: 180px;
    border-radius: var(--radius-lg);
    background: var(--bg-card);
    border: 1px solid var(--border);
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    position: relative;
    z-index: 2;
}
.hero-logo-box img {
    width: 75%;
    height: 75%;
    object-fit: contain;
}
.hero-tps-badge {
    position: absolute;
    bottom: -8px;
    right: -8px;
    padding: 0.5rem 1rem;
    border-radius: var(--radius-sm);
    background: var(--bg-card);
    border: 1px solid var(--border);
    font-size: 0.75rem;
    font-weight: 600;
    color: var(--primary);
    font-family: var(--font-mono);
    display: flex;
    align-items: center;
    gap: 0.375rem;
    z-index: 10;
}
.hero-tps-dot {
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: var(--success);
}

/* ===================== CARD ===================== */

.card {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    transition: all var(--transition);
}
.card:hover {
    border-color: var(--border-hover);
}

/* ===================== IP BOX ===================== */

.ip-box {
    display: inline-flex;
    align-items: center;
    background: rgba(255,255,255,0.03);
    border: 1px solid var(--border);
    border-radius: var(--radius-pill);
    padding: 0.375rem;
    padding-left: 1.25rem;
    margin-bottom: 2rem;
}
.ip-box-inner {
    display: flex;
    align-items: center;
    gap: 0.75rem;
}
.ip-label {
    font-size: 0.675rem;
    color: var(--text-muted);
}
.ip-address {
    font-family: var(--font-mono);
    font-weight: 600;
    font-size: 0.9375rem;
}
.btn-copy {
    padding: 0.5rem 1.25rem;
    border-radius: var(--radius-pill);
    background: var(--primary);
    color: #fff;
    font-size: 0.75rem;
    font-weight: 700;
    border: none;
    cursor: pointer;
    transition: all var(--transition);
}
.btn-copy:hover {
    background: var(--primary-hover);
}

/* ===================== EMPERORS ===================== */

.emperors-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1rem;
}
.emperor-card {
    display: flex;
    flex-direction: column;
    gap: 1rem;
    padding: 1.5rem;
}
.emperor-card:first-child {
    grid-column: 1 / -1;
    flex-direction: row;
    align-items: center;
}
.emperor-icon {
    width: 3rem;
    height: 3rem;
    border-radius: var(--radius-sm);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    flex-shrink: 0;
}
.emperor-icon.blue { background: rgba(59, 130, 246, 0.12); }
.emperor-icon.red { background: rgba(239, 68, 68, 0.12); }
.emperor-icon.amber { background: rgba(245, 158, 11, 0.12); }
.emperor-icon.green { background: rgba(16, 185, 129, 0.12); }
.emperor-icon.purple { background: rgba(139, 92, 246, 0.12); }
.emperor-header {
    display: flex;
    align-items: center;
    gap: 1rem;
}
.emperor-meta {
    display: flex;
    flex-direction: column;
}
.emperor-rank {
    font-size: 0.625rem;
    font-weight: 600;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.08em;
}
.emperor-name {
    font-family: var(--font-th);
    font-size: 1.125rem;
    font-weight: 700;
    color: var(--text);
}
.emperor-desc {
    font-size: 0.875rem;
    color: var(--text-secondary);
    line-height: 1.5;
    flex: 1;
}
.emperor-tags {
    display: flex;
    gap: 0.375rem;
    flex-wrap: wrap;
}
.emperor-tag {
    padding: 0.25rem 0.625rem;
    border-radius: var(--radius-pill);
    font-size: 0.6875rem;
    font-weight: 500;
    background: rgba(255,255,255,0.04);
    border: 1px solid var(--border);
    color: var(--text-secondary);
}
.emperor-card:first-child .emperor-icon {
    width: 4rem;
    height: 4rem;
    font-size: 2rem;
}
.emperor-card:first-child .emperor-name {
    font-size: 1.5rem;
}

/* ===================== FEATURES ===================== */

.features-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1rem;
}
.feature-card {
    display: flex;
    flex-direction: column;
    padding: 1.5rem;
}
.feature-icon {
    width: 2.5rem;
    height: 2.5rem;
    border-radius: var(--radius-sm);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.25rem;
    background: var(--primary-muted);
    border: 1px solid var(--primary-border);
    margin-bottom: 1rem;
    flex-shrink: 0;
}
.feature-title {
    font-family: var(--font-th);
    font-size: 1.125rem;
    font-weight: 700;
    color: var(--text);
    margin-bottom: 0.5rem;
}
.feature-desc {
    font-size: 0.875rem;
    color: var(--text-secondary);
    line-height: 1.6;
    flex: 1;
}
.feature-footer {
    display: flex;
    align-items: center;
    gap: 0.375rem;
    font-size: 0.75rem;
    font-weight: 500;
    color: var(--primary);
    margin-top: 1rem;
    padding-top: 1rem;
    border-top: 1px solid var(--border);
    opacity: 0;
    transition: all var(--transition);
}
.feature-card:hover .feature-footer {
    opacity: 1;
}

/* ===================== COMMUNITY ===================== */

.discord-wrap {
    display: flex;
    justify-content: center;
}
.discord-card {
    padding: 1rem;
}
.discord-card iframe {
    border-radius: var(--radius-sm);
    border: none;
}

/* ===================== CTA ===================== */

.cta-card {
    padding: 3rem 2rem;
    text-align: center;
    position: relative;
    overflow: hidden;
}
.cta-card::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: radial-gradient(circle at 30% 20%, rgba(59, 130, 246, 0.04) 0%, transparent 50%);
    pointer-events: none;
}
.cta-title {
    font-family: var(--font-th);
    font-size: 2.25rem;
    font-weight: 900;
    line-height: 1.1;
    margin-bottom: 1rem;
    position: relative;
}
.cta-desc {
    color: var(--text-secondary);
    font-size: 1rem;
    max-width: 480px;
    margin: 0 auto 1.5rem;
    line-height: 1.6;
    position: relative;
}
.cta-btns {
    display: flex;
    justify-content: center;
    gap: 0.75rem;
    flex-wrap: wrap;
    position: relative;
}

/* ===================== FOOTER ===================== */

.footer {
    margin-top: 60px;
    padding: 2rem 0;
}
.footer-card {
    padding: 2rem;
}
.footer-grid {
    display: grid;
    grid-template-columns: 2fr 1fr 1fr;
    gap: 3rem;
    margin-bottom: 2rem;
}
.footer-brand {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}
.footer-logo-row {
    display: flex;
    align-items: center;
    gap: 0.75rem;
}
.footer-logo-icon {
    width: 2.5rem;
    height: 2.5rem;
    border-radius: 0.5rem;
    background: linear-gradient(135deg, var(--primary), #2563eb);
    display: flex;
    align-items: center;
    justify-content: center;
    font-family: var(--font-th);
    font-weight: 900;
    font-size: 1.125rem;
    color: #fff;
    flex-shrink: 0;
}
.footer-brand-name {
    font-family: var(--font-th);
    font-weight: 800;
    font-size: 1rem;
    color: var(--text);
}
.footer-desc {
    font-size: 0.8125rem;
    color: var(--text-muted);
    line-height: 1.6;
    max-width: 320px;
}
.footer-desc a { color: var(--primary); }
.footer-col-title {
    font-size: 0.75rem;
    font-weight: 700;
    color: var(--text);
    text-transform: uppercase;
    letter-spacing: 0.05em;
    margin-bottom: 1.25rem;
}
.footer-links {
    list-style: none;
    display: flex;
    flex-direction: column;
    gap: 0.625rem;
}
.footer-links a {
    font-size: 0.8125rem;
    color: var(--text-muted);
    transition: color var(--transition);
}
.footer-links a:hover { color: var(--text); }
.footer-bottom {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding-top: 1.5rem;
    border-top: 1px solid var(--border);
    font-size: 0.75rem;
    color: var(--text-muted);
}
.footer-bottom a { color: var(--primary); font-weight: 600; }
.footer-socials {
    display: flex;
    gap: 1rem;
}
.footer-socials a {
    color: var(--text-muted);
    font-size: 1rem;
    transition: color var(--transition);
}
.footer-socials a:hover { color: var(--text); }

/* ===================== MOBILE DRAWER ===================== */

.mobile-drawer {
    position: fixed;
    inset: 0;
    z-index: 200;
    background: rgba(5, 5, 5, 0.98);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    transform: translateX(100%);
    transition: transform 0.35s cubic-bezier(0.4, 0, 0.2, 1);
    display: flex;
    flex-direction: column;
    padding: 1.5rem;
}
.mobile-drawer.open { transform: translateX(0); }
.mobile-drawer-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 3rem;
}
.mobile-drawer-header img {
    width: 2.5rem;
    height: 2.5rem;
    border-radius: 0.5rem;
    object-fit: contain;
}
.mobile-drawer-close {
    width: 2.25rem;
    height: 2.25rem;
    display: flex;
    align-items: center;
    justify-content: center;
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    color: var(--text-secondary);
    font-size: 1.125rem;
    transition: all var(--transition);
}
.mobile-drawer-close:hover {
    background: rgba(255,255,255,0.04);
    color: var(--text);
}
.mobile-drawer-links {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
    flex: 1;
}
.mobile-drawer-link {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 0.875rem 1rem;
    border-radius: var(--radius-sm);
    font-family: var(--font-th);
    font-size: 1.125rem;
    font-weight: 600;
    color: var(--text-secondary);
    transition: all var(--transition);
}
.mobile-drawer-link:hover {
    background: rgba(255,255,255,0.04);
    color: var(--text);
}
.mobile-drawer-footer {
    padding-top: 1.5rem;
    border-top: 1px solid var(--border);
    display: flex;
    flex-direction: column;
    gap: 1rem;
}
.mobile-lang-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
}
.mobile-lang-row span {
    font-size: 0.75rem;
    font-weight: 600;
    color: var(--text-muted);
}
.mobile-discord-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    padding: 0.875rem;
    border-radius: var(--radius-sm);
    background: rgba(88, 101, 242, 0.10);
    border: 1px solid rgba(88, 101, 242, 0.20);
    color: #8b9cf7;
    font-weight: 600;
    font-size: 0.875rem;
    transition: all var(--transition);
}
.mobile-discord-btn:hover {
    background: rgba(88, 101, 242, 0.18);
}

/* ===================== PAGE WRAPPER ===================== */

.page-section {
    padding-top: 100px;
    padding-bottom: 3rem;
    min-height: 80vh;
}
.page-header {
    text-align: center;
    padding: 1.5rem 0 2rem;
}
.page-header h1 {
    font-family: var(--font-th);
    font-size: clamp(2rem, 6vw, 3rem);
    font-weight: 900;
    line-height: 1.1;
    margin-bottom: 0.5rem;
}
.page-header p {
    font-size: 1rem;
    max-width: 560px;
    margin: 0 auto;
    color: var(--text-muted);
}

/* ===================== AUTH ===================== */

.cyauth-group { position: relative; }
.cyauth-btn {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.375rem 0.75rem 0.375rem 0.375rem;
    border-radius: var(--radius-pill);
    background: rgba(255,255,255,0.04);
    border: 1px solid var(--border);
    color: var(--text);
    cursor: pointer;
    transition: all var(--transition);
    font-size: 0.8125rem;
}
.cyauth-btn:hover {
    border-color: var(--border-hover);
    background: rgba(255,255,255,0.08);
}
.cyauth-btn img {
    width: 1.5rem;
    height: 1.5rem;
    border-radius: 4px;
}
.cyauth-dropdown {
    position: absolute;
    right: 0;
    top: 100%;
    margin-top: 0.375rem;
    width: 12rem;
    background: var(--bg-elevated);
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    box-shadow: var(--shadow-lg);
    opacity: 0;
    visibility: hidden;
    transition: all 0.2s;
    z-index: 50;
    overflow: hidden;
}
.cyauth-group:hover .cyauth-dropdown {
    opacity: 1;
    visibility: visible;
}
.cyauth-item {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.625rem 1rem;
    color: var(--text-secondary);
    font-size: 0.8125rem;
    transition: all 0.15s;
    cursor: pointer;
    background: transparent;
    border: none;
    width: 100%;
    text-align: left;
}
.cyauth-item:hover {
    background: rgba(255,255,255,0.04);
    color: var(--text);
}
.cyauth-item.danger { color: var(--danger); }
.cyauth-item.danger:hover { color: #f87171; }

/* ===================== MODAL ===================== */

.modal-overlay {
    position: fixed;
    inset: 0;
    z-index: 3000;
    background: rgba(5, 5, 5, 0.85);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    display: none;
    align-items: center;
    justify-content: center;
    padding: 1rem;
}
.modal-overlay.active { display: flex; }
.modal-content {
    max-width: 400px;
    width: 100%;
    background: var(--bg-elevated);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 2rem;
}
.modal-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 1.5rem;
}
.modal-close {
    color: var(--text-muted);
    font-size: 1.125rem;
    transition: color var(--transition);
}
.modal-close:hover { color: var(--text); }

/* ===================== COOKIE ===================== */

.cookie-popup {
    position: fixed;
    bottom: 1.5rem;
    left: 50%;
    transform: translateX(-50%) translateY(100%);
    z-index: 300;
    max-width: 520px;
    width: calc(100% - 2rem);
    padding: 1rem 1.25rem;
    background: var(--bg-elevated);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    box-shadow: var(--shadow-lg);
    opacity: 0;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    display: flex;
    align-items: center;
    gap: 1rem;
}
.cookie-popup.show {
    opacity: 1;
    transform: translateX(-50%) translateY(0);
}
.cookie-popup p {
    font-size: 0.8125rem;
    color: var(--text-secondary);
    line-height: 1.5;
    flex: 1;
}
.cookie-popup a { color: var(--primary); text-decoration: underline; }

/* ===================== PORTAL ===================== */

.portal-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1rem;
}
.portal-stat-card {
    text-align: center;
    padding: 1.5rem;
}
.portal-stat-val {
    font-family: var(--font-mono);
    font-size: 2rem;
    font-weight: 700;
    color: var(--text);
}
.portal-stat-lbl {
    font-size: 0.75rem;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.05em;
    margin-top: 0.25rem;
}
.player-list {
    max-height: 300px;
    overflow-y: auto;
}
.player-item {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 0.5rem 0;
    border-bottom: 1px solid rgba(255,255,255,0.04);
}
.player-item:last-child { border-bottom: none; }
.player-item img {
    width: 24px;
    height: 24px;
    border-radius: 4px;
}
.progress-bar {
    width: 100%;
    height: 6px;
    background: rgba(255,255,255,0.08);
    border-radius: 3px;
    overflow: hidden;
}
.progress-fill {
    height: 100%;
    border-radius: 3px;
    transition: width 0.5s ease;
}

/* ===================== STORE ===================== */

.product-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 1rem;
}
.product-card {
    display: flex;
    flex-direction: column;
    gap: 1rem;
    padding: 1.5rem;
    position: relative;
}
.product-card .hot-badge {
    position: absolute;
    top: 0.75rem;
    right: 0.75rem;
    background: rgba(239, 68, 68, 0.2);
    color: #ef4444;
    padding: 0.25rem 0.5rem;
    border-radius: 4px;
    font-size: 0.7rem;
    font-weight: 700;
}
.product-icon-box {
    width: 3rem;
    height: 3rem;
    border-radius: var(--radius-sm);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.25rem;
    flex-shrink: 0;
}
.product-title {
    font-family: var(--font-th);
    font-weight: 700;
    font-size: 1.125rem;
}
.product-desc {
    font-size: 0.8125rem;
    color: var(--text-secondary);
}
.product-price {
    font-family: var(--font-mono);
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--primary);
}
.product-features {
    list-style: none;
    display: flex;
    flex-direction: column;
    gap: 0.375rem;
}
.product-features li {
    font-size: 0.8125rem;
    color: var(--text-secondary);
}
.category-tabs {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    justify-content: center;
    margin-bottom: 1.5rem;
}
.category-tab {
    padding: 0.5rem 1.25rem;
    border-radius: var(--radius-pill);
    background: transparent;
    border: 1px solid var(--border);
    color: var(--text-secondary);
    font-size: 0.8125rem;
    font-weight: 600;
    cursor: pointer;
    transition: all var(--transition);
}
.category-tab:hover {
    border-color: var(--border-hover);
    color: var(--text);
}
.category-tab.active {
    background: var(--primary);
    color: #fff;
    border-color: var(--primary);
    box-shadow: 0 4px 14px rgba(59, 130, 246, 0.3);
}

/* ===================== DASHBOARD ===================== */

.dash-layout {
    display: grid;
    grid-template-columns: 250px 1fr;
    gap: 1.5rem;
    min-height: 60vh;
}
.dash-sidebar {
    display: flex;
    flex-direction: column;
    gap: 0.375rem;
    padding: 1rem;
    height: fit-content;
}
.dash-sidebar-item {
    padding: 0.75rem 1rem;
    color: var(--text-muted);
    border-radius: var(--radius-sm);
    cursor: pointer;
    transition: all var(--transition);
    display: flex;
    align-items: center;
    gap: 0.625rem;
    font-weight: 500;
    font-size: 0.875rem;
}
.dash-sidebar-item:hover {
    background: rgba(255,255,255,0.04);
    color: var(--text);
}
.dash-sidebar-item.active {
    background: var(--primary-muted);
    color: var(--primary-hover);
}
.dash-panel { display: none; }
.dash-panel.active { display: block; }
.dash-panel-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1.5rem;
    padding-bottom: 1rem;
    border-bottom: 1px solid var(--border);
}
.dash-panel-title {
    font-family: var(--font-th);
    font-size: 1.25rem;
    font-weight: 700;
}
.data-table {
    width: 100%;
    border-collapse: collapse;
}
.data-table th, .data-table td {
    padding: 0.75rem 0.5rem;
    text-align: left;
    border-bottom: 1px solid rgba(255,255,255,0.05);
    font-size: 0.875rem;
}
.data-table th {
    color: var(--text-muted);
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    font-weight: 700;
}
.data-table tr:hover td { background: rgba(255,255,255,0.02); }

/* ===================== SCROLLBAR ===================== */

::-webkit-scrollbar { width: 6px; }
::-webkit-scrollbar-track { background: transparent; }
::-webkit-scrollbar-thumb {
    background: rgba(255,255,255,0.08);
    border-radius: 3px;
}
::-webkit-scrollbar-thumb:hover { background: rgba(255,255,255,0.15); }

/* ===================== ANIMATION ===================== */

.section-enter {
    opacity: 0;
    transform: translateY(24px);
}

/* ===================== RESPONSIVE ===================== */

@media (max-width: 1023px) {
    .hide-mobile { display: none !important; }
    .show-mobile { display: flex; }

    .nav-center { display: none; }
    .nav-status { display: none; }
    .btn-hamburger { display: flex; }
    .lang-toggle.hide-mobile { display: none !important; }

    .hero-card {
        grid-template-columns: 1fr;
        gap: 2rem;
        text-align: center;
    }
    .hero-sub, .hero-desc { margin: 0 auto; }
    .hero-btns { justify-content: center; }
    .hero-stats { justify-content: center; }
    .hero-visual { display: none; }

    .emperors-grid { grid-template-columns: 1fr; }
    .emperor-card:first-child { flex-direction: column; text-align: center; }

    .features-grid { grid-template-columns: 1fr; }

    .footer-grid {
        grid-template-columns: 1fr;
        gap: 2rem;
        text-align: center;
    }
    .footer-brand { align-items: center; }
    .footer-desc { margin: 0 auto; }
    .footer-bottom {
        flex-direction: column;
        gap: 1rem;
        text-align: center;
    }

    .section-title { font-size: 1.75rem; }
    .hero-title { font-size: 2.5rem; }

    .portal-grid { grid-template-columns: 1fr; }
    .dash-layout { grid-template-columns: 1fr; }
    .grid-2 { grid-template-columns: 1fr; }
    .grid-3 { grid-template-columns: 1fr; }
}

@media (max-width: 640px) {
    .nav-brand-sub { display: none; }
    .container { padding: 0 1rem; }
    .hero { padding: 5rem 0 2rem; }
    .hero-title { font-size: 2rem; }
    .section { padding: 2.5rem 0; }
    .section-title { font-size: 1.5rem; }
    .cta-card { padding: 2rem 1.25rem; }
    .cta-title { font-size: 1.5rem; }
    .page-section { padding-top: 80px; }
}

@media (prefers-reduced-motion: reduce) {
    html { scroll-behavior: auto; }
    *, *::before, *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        animation-delay: 0s !important;
        transition-duration: 0.01ms !important;
        transition-delay: 0s !important;
        scroll-behavior: auto !important;
    }
}

html[data-reduced-motion="true"] { scroll-behavior: auto; }
html[data-reduced-motion="true"] *,
html[data-reduced-motion="true"] *::before,
html[data-reduced-motion="true"] *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    animation-delay: 0s !important;
    transition-duration: 0.01ms !important;
    transition-delay: 0s !important;
    scroll-behavior: auto !important;
}

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(12px); }
    to { opacity: 1; transform: translateY(0); }
}

/* ===================== PAGE-SPECIFIC ===================== */

/* Index status strip */
.server-strip {
    padding: 0;
}

/* Voice Page */
.voice-page { padding-top: 96px; padding-bottom: 2rem; min-height: 100vh; display: flex; flex-direction: column; }
.voice-card { max-width: 800px; margin: 0 auto; width: 100%; }
.v-status-bar { display: flex; align-items: center; gap: 0.75rem; padding: 1rem; border-radius: var(--radius-sm); background: rgba(255,255,255,0.03); border: 1px solid var(--border); margin-bottom: 1.25rem; }
.v-status-dot { width: 10px; height: 10px; border-radius: 50%; flex-shrink: 0; }
.v-status-dot.offline { background: var(--danger); }
.v-status-dot.connecting { background: var(--warning); animation: pulse-dot 1s infinite; }
.v-status-dot.online { background: var(--success); }
.v-status-text { font-size: 0.8125rem; font-weight: 500; }
.v-status-sub { font-size: 0.75rem; color: var(--text-muted); }
.v-controls { display: flex; gap: 0.75rem; justify-content: center; margin: 1rem 0; flex-wrap: wrap; }
.v-btn { width: 3.5rem; height: 3.5rem; border-radius: 14px; border: 1px solid var(--border); background: rgba(255,255,255,0.04); color: var(--text); font-size: 1.125rem; cursor: pointer; transition: all var(--transition); display: flex; align-items: center; justify-content: center; }
.v-btn:hover { background: rgba(255,255,255,0.08); border-color: var(--border-hover); }
.v-btn.active { background: var(--primary); border-color: var(--primary); color: #fff; }
.v-btn.danger.active { background: var(--danger); border-color: var(--danger); }
.v-btn:disabled { opacity: 0.35; cursor: not-allowed; }
.v-sld-row { display: flex; align-items: center; gap: 0.75rem; padding: 0.625rem 0; }
.v-sld-row label { font-size: 0.8125rem; color: var(--text-muted); min-width: 6rem; }
.v-sld { flex: 1; -webkit-appearance: none; height: 4px; border-radius: 2px; background: var(--border); outline: none; }
.v-sld::-webkit-slider-thumb { -webkit-appearance: none; width: 16px; height: 16px; border-radius: 50%; background: var(--primary); cursor: pointer; }
.v-sld-val { font-size: 0.75rem; font-family: var(--font-mono); color: var(--text-secondary); min-width: 2.5rem; text-align: right; }
.v-select { width: 100%; padding: 0.625rem 0.75rem; background: rgba(255,255,255,0.04); border: 1px solid var(--border); border-radius: var(--radius-sm); color: var(--text); font-size: 0.875rem; outline: none; cursor: pointer; }
.v-select option { background: #1a1a1a; color: #ffffff; }
.v-select:focus { border-color: var(--primary-border); }
.v-activity { display: flex; align-items: center; gap: 0.75rem; padding: 0.75rem; border-radius: var(--radius-sm); background: rgba(255,255,255,0.03); border: 1px solid var(--border); margin: 1rem 0; }
.v-activity-bars { display: flex; align-items: center; gap: 2px; height: 24px; }
.v-activity-bars span { width: 3px; background: var(--primary); border-radius: 2px; transition: height 0.1s; }
.v-activity-label { font-size: 0.8125rem; color: var(--text-muted); }
.v-players { display: flex; flex-direction: column; gap: 0.375rem; }
.v-player { display: flex; align-items: center; justify-content: space-between; padding: 0.5rem 0.75rem; border-radius: var(--radius-sm); background: rgba(255,255,255,0.03); border: 1px solid var(--border); }
.v-player-info { display: flex; align-items: center; gap: 0.625rem; }
.v-player-head { width: 1.5rem; height: 1.5rem; border-radius: 4px; background: var(--bg-elevated); }
.v-player-name { font-size: 0.8125rem; font-weight: 500; }
.v-player-tag { font-size: 0.6875rem; color: var(--text-muted); padding: 0.125rem 0.375rem; border-radius: 4px; background: var(--border); }
.v-player-speaking { width: 8px; height: 8px; border-radius: 50%; background: rgba(255,255,255,0.1); flex-shrink: 0; }
.v-player-speaking.on { background: var(--success); animation: pulse-dot 1s infinite; }
.v-player-vol { width: 0; display: flex; align-items: center; gap: 0.5rem; }
.v-player-vol input { width: 64px; -webkit-appearance: none; height: 3px; background: var(--border); border-radius: 2px; outline: none; }
.v-player-vol input::-webkit-slider-thumb { -webkit-appearance: none; width: 12px; height: 12px; border-radius: 50%; background: var(--text-muted); cursor: pointer; }
.v-login-card { max-width: 420px; margin: 0 auto; width: 100%; }
.v-field { width: 100%; padding: 0.75rem 1rem; background: rgba(255,255,255,0.04); border: 1px solid var(--border); border-radius: var(--radius-sm); color: var(--text); font-size: 0.9375rem; outline: none; transition: border var(--transition); }
.v-field:focus { border-color: var(--primary-border); }
.v-field::placeholder { color: var(--text-muted); }
.v-login-hint { font-size: 0.75rem; color: var(--text-muted); text-align: center; padding: 0.75rem; background: rgba(255,255,255,0.03); border-radius: var(--radius-sm); border: 1px solid var(--border); }
.v-login-hint i { color: var(--primary); margin-right: 0.375rem; }
.v-info-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 0.75rem; margin: 1rem 0; }
.v-info-item { padding: 0.75rem; background: rgba(255,255,255,0.03); border-radius: var(--radius-sm); border: 1px solid var(--border); text-align: center; }
.v-info-item .num { font-family: var(--font-mono); font-size: 1.375rem; font-weight: 700; }
.v-info-item .lbl { font-size: 0.6875rem; color: var(--text-muted); text-transform: uppercase; letter-spacing: 0.05em; margin-top: 0.25rem; }
.v-section { display: none; }
.v-section.active { display: block; }
.v-keyhint { font-size: 0.6875rem; color: var(--text-muted); background: rgba(255,255,255,0.04); padding: 0.125rem 0.375rem; border-radius: 4px; border: 1px solid var(--border); }

/* AI Page */
.ai-page { padding-top: 96px; padding-bottom: 2rem; min-height: 100vh; display: flex; flex-direction: column; }
.chat-card { display: flex; flex-direction: column; height: calc(100vh - 140px); max-height: 800px; padding: 1.5rem; }
.chat-header { display: flex; align-items: center; gap: 1rem; padding-bottom: 1rem; border-bottom: 1px solid var(--border); margin-bottom: 1rem; }
.ai-avatar { width: 2.75rem; height: 2.75rem; border-radius: 50%; background: linear-gradient(135deg, var(--accent), var(--accent-hover)); display: flex; align-items: center; justify-content: center; font-size: 1.25rem; color: #fff; flex-shrink: 0; }
.chat-header-info h2 { font-family: var(--font-th); font-size: 1.125rem; font-weight: 700; }
.chat-header-info p { font-size: 0.75rem; color: var(--success); display: flex; align-items: center; gap: 0.375rem; }
.chat-messages { flex: 1; overflow-y: auto; display: flex; flex-direction: column; gap: 0.75rem; padding-right: 0.5rem; }
.msg { max-width: 80%; padding: 0.875rem 1.125rem; border-radius: 12px; line-height: 1.6; font-size: 0.9375rem; animation: fadeIn 0.3s ease; }
.msg.user { align-self: flex-end; background: linear-gradient(135deg, var(--accent), var(--accent-hover)); color: #fff; border-bottom-right-radius: 4px; }
.msg.ai { align-self: flex-start; background: rgba(255,255,255,0.04); border: 1px solid var(--border); color: var(--text); border-bottom-left-radius: 4px; }
.typing-indicator { display: none; align-self: flex-start; padding: 0.75rem 0; color: var(--text-muted); font-size: 0.8125rem; }
.chat-input-area { display: flex; gap: 0.75rem; padding-top: 1rem; border-top: 1px solid var(--border); margin-top: 1rem; }
.chat-input { flex: 1; background: rgba(255,255,255,0.04); border: 1px solid var(--border); border-radius: 24px; padding: 0.75rem 1.25rem; color: var(--text); font-size: 0.9375rem; outline: none; transition: border var(--transition); }
.chat-input:focus { border-color: var(--primary-border); }
.send-btn { width: 3rem; height: 3rem; border-radius: 50%; background: linear-gradient(135deg, var(--accent), var(--accent-hover)); color: #fff; font-size: 1.125rem; display: flex; align-items: center; justify-content: center; transition: all var(--transition); flex-shrink: 0; }
.send-btn:hover { transform: scale(1.05); }
.support-ticket-btn { display: flex; align-items: center; justify-content: center; gap: .45rem; width: fit-content; max-width: 100%; min-height: 36px; margin-top: 12px; padding: 0 12px; border: 1px solid var(--accent-border); border-radius: 10px; color: var(--accent); background: var(--accent-muted); font: 600 .78rem 'Roboto', sans-serif; line-height: 1.25; white-space: normal; text-align: left; cursor: pointer; transition: background .2s ease, border-color .2s ease, transform .2s ease; }
.support-ticket-btn:hover { border-color: var(--accent-hover); background: color-mix(in srgb, var(--accent) 24%, transparent); transform: translateY(-1px); }
.support-ticket-btn:focus-visible { outline: 2px solid var(--accent-hover); outline-offset: 2px; }
@media (max-width: 520px) { .support-ticket-btn { max-width: 100%; white-space: normal; line-height: 1.25; text-align: left; } }

/* Monitor Page */
.monitor-page { padding-top: 96px; min-height: 100vh; padding-bottom: 2rem; }
.stats-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); gap: 1rem; margin-bottom: 1.5rem; }
.stat-card { padding: 1.25rem; display: flex; flex-direction: column; gap: 0.5rem; }
.stat-card-header { display: flex; align-items: center; justify-content: space-between; }
.stat-card-icon { width: 2.25rem; height: 2.25rem; border-radius: var(--radius-sm); display: flex; align-items: center; justify-content: center; font-size: 1rem; }
.stat-card-label { font-size: 0.75rem; color: var(--text-muted); text-transform: uppercase; letter-spacing: 0.04em; font-weight: 600; }
.stat-card-value { font-family: var(--font-mono); font-size: 1.75rem; font-weight: 700; color: var(--text); line-height: 1.1; }
.stat-card-change { font-size: 0.6875rem; font-weight: 600; display: flex; align-items: center; gap: 0.25rem; }
.stat-card-change.up { color: var(--success); }
.stat-card-change.down { color: var(--danger); }
.charts-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 1rem; margin-bottom: 1.5rem; }
.chart-card { padding: 1.25rem; }
.chart-card h3 { font-family: var(--font-th); font-size: 1rem; font-weight: 700; margin-bottom: 1rem; }
.chart-card canvas { max-height: 200px; }
.info-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 1rem; }
.info-card { padding: 1.25rem; }
.info-card h3 { font-family: var(--font-th); font-size: 1rem; font-weight: 700; margin-bottom: 0.75rem; }
.info-row { display: flex; justify-content: space-between; padding: 0.5rem 0; border-bottom: 1px solid rgba(255,255,255,0.04); font-size: 0.875rem; }
.info-row:last-child { border-bottom: none; }
.info-row-label { color: var(--text-muted); }
.info-row-value { color: var(--text); font-weight: 500; }

/* Dashboard Page */
.dash-page { padding-top: 96px; min-height: 100vh; padding-bottom: 2rem; }
.unauthorized { text-align:center; padding:6rem 2rem; margin-top:100px; display:none; }
.unauthorized h1 { font-family:var(--font-th); font-size:3rem; font-weight:900; color:var(--danger); margin-bottom:1rem; }
.unauthorized p { color:var(--text-secondary); font-size:1.1rem; margin-bottom:1.5rem; }

/* Patch Page */
.patch-card { border-left: 4px solid var(--primary); padding: 1.5rem; }
.tag-add { background:rgba(16,185,129,0.15);color:#34d399;padding:2px 8px;border-radius:4px;font-size:0.7rem;font-weight:700;margin-right:6px; }
.tag-fix { background:rgba(96,165,250,0.15);color:#60a5fa;padding:2px 8px;border-radius:4px;font-size:0.7rem;font-weight:700;margin-right:6px; }
.tag-change { background:rgba(245,158,11,0.15);color:#fbbf24;padding:2px 8px;border-radius:4px;font-size:0.7rem;font-weight:700;margin-right:6px; }

/* Payment modal */
#stripe-payment-mount { background: rgba(255,255,255,0.04); border-radius: var(--radius-sm); padding: 1.25rem; border: 1px solid var(--border); min-height: 200px; }
.payment-option-btn { display:flex; align-items:center; justify-content:space-between; padding:0.75rem 1rem; border-radius:var(--radius-sm); background:rgba(255,255,255,0.03); border:1px solid var(--border); cursor:pointer; transition:all var(--transition); }
.payment-option-btn:hover { border-color:var(--border-hover); background:rgba(255,255,255,0.08); }
.payment-option-btn.disabled { opacity:0.4; cursor:not-allowed; }
.payment-option-info { display:flex; align-items:center; gap:0.75rem; }
.payment-option-icon { width:2rem; height:2rem; border-radius:6px; background:rgba(255,255,255,0.04); display:flex; align-items:center; justify-content:center; font-size:0.875rem; }
.payment-option-text { font-size:0.8125rem; font-weight:600; color:var(--text); }
.payment-option-balance { font-size:0.6875rem; color:var(--text-muted); }
.payment-option-price { font-size:0.875rem; font-weight:700; font-family:var(--font-mono); }
.modal-product-summary { display:flex; align-items:center; gap:1rem; margin-bottom:1.5rem; padding-bottom:1rem; border-bottom:1px solid var(--border); }
.modal-product-icon { width:2.5rem; height:2.5rem; border-radius:var(--radius-sm); background:linear-gradient(135deg,var(--primary),#0088ff); display:flex; align-items:center; justify-content:center; font-size:1rem; color:#000; flex-shrink:0; }

/* Profile Page */
.profile-stats { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1rem; }
.profile-stat-card { padding: 1.5rem; text-align: center; }

/* Responsive fixes for page-specific */
@media (max-width: 1023px) {
    .stats-grid { grid-template-columns: repeat(2, 1fr); }
    .charts-grid { grid-template-columns: 1fr; }
    .info-grid { grid-template-columns: 1fr; }
    .profile-stats { grid-template-columns: 1fr; }
}

@media (max-width: 640px) {
    .voice-page { padding-top: 80px; }
    .v-info-grid { grid-template-columns: 1fr 1fr; }
    .v-btn { width: 3rem; height: 3rem; font-size: 1rem; }
    .ai-page { padding-top: 80px; }
    .chat-card { height: calc(100vh - 120px); max-height: none; }
    .msg { max-width: 90%; font-size: 0.875rem; }
    .monitor-page { padding-top: 80px; }
    .dash-page { padding-top: 80px; }
}

/* Auth bridge */
.auth-bridge-body {
    background: var(--bg);
    color: var(--text);
    display: flex;
    align-items: center;
    justify-content: center;
    height: 100vh;
    margin: 0;
    font-family: var(--font-en);
    text-align: center;
}

/* ===================== MODAL ===================== */
.modal-overlay {
    position: fixed;
    inset: 0;
    z-index: 3000;
    background: rgba(5, 5, 5, 0.85);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    display: none;
    align-items: center;
    justify-content: center;
    padding: 1rem;
}
.modal-overlay.active { display: flex; }
.modal-content {
    max-width: 400px;
    width: 100%;
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: 16px;
    padding: 2rem;
}
.modal-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 1.5rem;
}
.modal-close {
    color: var(--text-muted);
    font-size: 1.125rem;
    transition: color 0.2s;
    background: none;
    border: none;
    cursor: pointer;
}
.modal-close:hover { color: var(--text-color); }

/* Payment modal */
.payment-option-btn { display:flex; align-items:center; justify-content:space-between; padding:0.75rem 1rem; border-radius:8px; background:rgba(255,255,255,0.03); border:1px solid var(--border-color); cursor:pointer; transition:all 0.2s; }
.payment-option-btn:hover { border-color:var(--primary); background:rgba(255,255,255,0.08); }
.payment-option-btn.disabled { opacity:0.4; cursor:not-allowed; }
.payment-option-info { display:flex; align-items:center; gap:0.75rem; }
.payment-option-icon { width:2rem; height:2rem; border-radius:6px; background:rgba(255,255,255,0.05); display:flex; align-items:center; justify-content:center; }
.payment-option-text { font-size:0.875rem; font-weight:600; }
.payment-option-balance { font-size:0.6875rem; color:var(--text-muted); }
.payment-option-price { font-size:0.875rem; font-weight:700; font-family:monospace; }
.modal-product-summary { display:flex; align-items:center; gap:1rem; margin-bottom:1.5rem; padding-bottom:1rem; border-bottom:1px solid var(--border-color); }
.modal-product-icon { width:2.5rem; height:2.5rem; border-radius:8px; background:linear-gradient(135deg,var(--primary),#0088ff); display:flex; align-items:center; justify-content:center; font-size:1rem; color:#000; flex-shrink:0; }

/* ===================== PRODUCT CARDS ===================== */
.product-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 1rem;
}
.product-card {
    display: flex;
    flex-direction: column;
    gap: 1rem;
    padding: 1.5rem;
    position: relative;
    background: var(--bg-card, rgba(255,255,255,0.02));
    border: 1px solid var(--border-color, rgba(255,255,255,0.05));
    border-radius: 16px;
}
.product-card .hot-badge {
    position: absolute;
    top: 0.75rem;
    right: 0.75rem;
    background: rgba(239, 68, 68, 0.2);
    color: #ef4444;
    padding: 0.25rem 0.5rem;
    border-radius: 4px;
    font-size: 0.7rem;
    font-weight: 700;
}
.product-icon-box {
    width: 3rem;
    height: 3rem;
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.25rem;
    flex-shrink: 0;
}
.product-title {
    font-weight: 700;
    font-size: 1.125rem;
}
.product-desc {
    font-size: 0.8125rem;
    color: var(--text-muted);
}
.product-price {
    font-family: monospace;
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--primary);
}
.product-features {
    list-style: none;
    display: flex;
    flex-direction: column;
    gap: 0.375rem;
}
.product-features li {
    font-size: 0.8125rem;
    color: var(--text-muted);
}

/* Profile utility panels */
.session-list,.purchase-list{display:flex;flex-direction:column;gap:8px}
.session-row,.purchase-row{display:flex;align-items:center;justify-content:space-between;gap:12px;padding:12px 14px;border:1px solid var(--border);border-radius:var(--radius-sm);background:rgba(255,255,255,.025)}
.session-device{display:flex;align-items:center;gap:12px;min-width:0}.session-device>i{width:32px;height:32px;display:grid;place-items:center;border-radius:9px;background:var(--primary-muted);color:var(--primary-hover)}
.session-device b,.purchase-row b{font-size:.85rem}.session-device small,.purchase-row small{display:block;color:var(--text-muted);font-size:.72rem;margin-top:2px}.session-kick{color:#fca5a5!important;background:rgba(239,68,68,.12)!important;border:1px solid rgba(239,68,68,.25)!important}
.purchase-meta{display:flex;align-items:center;gap:10px;white-space:nowrap;font-family:var(--font-mono)}.empty-state{text-align:center;padding:2.5rem 0;color:var(--text-muted)}.empty-state i{font-size:2rem;display:block;margin-bottom:.75rem;opacity:.45}.empty-state p{margin-bottom:1rem;font-family:var(--font-th)}
.redeem-hero{display:flex;align-items:center;gap:14px;padding:14px;border:1px solid var(--primary-border);background:linear-gradient(135deg,var(--primary-muted),transparent);border-radius:var(--radius-sm)}.redeem-icon{width:42px;height:42px;border-radius:12px;display:grid;place-items:center;background:var(--primary);color:#fff;font-size:1.1rem}.redeem-form{margin-top:20px}.redeem-form label{display:block;margin-bottom:6px}.redeem-notes{display:grid;grid-template-columns:1fr 1fr;gap:10px;margin-top:18px}.redeem-notes>div{display:flex;gap:10px;padding:12px;border:1px solid var(--border);border-radius:var(--radius-sm);background:rgba(255,255,255,.02)}.redeem-notes i{color:var(--primary);margin-top:3px}.redeem-notes b,.redeem-notes small{display:block}.redeem-notes small{color:var(--text-muted);font-size:.72rem;margin-top:3px}
@media(max-width:700px){.redeem-notes{grid-template-columns:1fr}.purchase-row{align-items:flex-start;flex-direction:column}.purchase-meta{width:100%;justify-content:space-between}.session-row{align-items:flex-start}.session-row .btn{flex-shrink:0}}

/* ==== components.css ==== */
/* ==========================================================================
   CyoriaSMP — Shared Component Styles
   ใช้ร่วมกับ design-tokens.css ในทุกหน้า
   ========================================================================== */

/* ─── Component: Site Header ─────────────────────────────────────────────── */

.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  border-bottom: 1px solid var(--border);
  background: var(--bg);
}

.site-header .nav {
  min-height: var(--header-height);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-weight: 600;
  letter-spacing: -0.02em;
  white-space: nowrap;
}

.brand-mark {
  width: 30px;
  height: 30px;
  display: grid;
  place-items: center;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  color: var(--accent);
}

.brand-mark svg {
  width: 18px;
  height: 18px;
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 4px;
}

.nav-link {
  min-height: 44px;
  display: inline-flex;
  align-items: center;
  padding: 0 12px;
  color: var(--muted);
  font-size: 13px;
  letter-spacing: 0.02em;
  transition: color 0.2s ease, background 0.2s ease;
  white-space: nowrap;
}

.nav-link:hover,
.nav-link[aria-current="page"],
.nav-link.active-page {
  color: var(--fg);
  background: var(--bg-surface);
  border-radius: var(--radius);
}

.nav-actions {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-shrink: 0;
}

.status-link {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: var(--muted);
  font-size: 12px;
  white-space: nowrap;
}

.header-cta {
  min-height: 44px;
  display: inline-flex;
  align-items: center;
  padding: 0 15px;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  color: var(--fg);
  font-size: 13px;
  font-weight: 600;
  transition: transform 0.2s ease, border-color 0.2s ease;
  white-space: nowrap;
}

.header-cta:hover {
  transform: translateY(-2px);
  border-color: var(--accent);
}

.menu-toggle {
  display: none;
  min-width: 44px;
  min-height: 44px;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: transparent;
  font-size: 18px;
  align-items: center;
  justify-content: center;
  cursor: pointer;
}

/* Mobile nav panel — ย้ายไป style.css (checkbox hack .nav-toggle-chk:checked)
   block เดิมใช้ .is-open/.menu-toggle ซึ่งหน้าเว็บจริงไม่ได้ใช้และชนกับ checkbox */

@media (max-width: 680px) {
  .nav-actions .header-cta.hide-mobile {
    display: none !important;
  }
}

/* ─── Component: Site Footer ─────────────────────────────────────────────── */

.site-footer {
  border-top: 1px solid var(--border);
  padding: 32px 0;
}

.footer-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
  color: var(--muted);
  font-size: 13px;
}

.footer-links {
  display: flex;
  gap: 20px;
}

.footer-links a {
  color: var(--muted);
  transition: color 0.2s ease;
}

.footer-links a:hover {
  color: var(--fg);
}

@media (max-width: 680px) {
  .footer-row {
    flex-direction: column;
    text-align: center;
  }
}

/* ─── Component: Section ─────────────────────────────────────────────────── */

.section {
  padding: 88px 0;
  border-bottom: 1px solid var(--border);
}

.section-head {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 24px;
  margin-bottom: 34px;
}

.section-head h2 {
  max-width: 560px;
  margin-bottom: 0;
  font-size: clamp(28px, 4vw, 44px);
  line-height: 1.1;
  letter-spacing: -0.03em;
  font-weight: 600;
}

.section-head p {
  max-width: 390px;
  margin-bottom: 2px;
  color: var(--muted);
  font-size: 15px;
}

@media (max-width: 680px) {
  .section {
    padding: 64px 0;
  }
  .section-head {
    display: block;
  }
  .section-head h2 {
    margin-bottom: 14px;
  }
}

/* ─── Component: Hero ────────────────────────────────────────────────────── */

.hero {
  padding: 112px 0 84px;
  border-bottom: 1px solid var(--border);
}

.hero-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.15fr) minmax(320px, 0.85fr);
  gap: 72px;
  align-items: end;
}

.hero-copy {
  max-width: 590px;
  margin-bottom: 34px;
  color: var(--muted);
  font-size: 17px;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  align-items: center;
}

@media (max-width: 920px) {
  .hero {
    padding: 76px 0 60px;
  }
  .hero-grid {
    grid-template-columns: 1fr;
    gap: 42px;
  }
}

/* ─── Component: Shared Public Page Hero ────────────────────────────────── */

/* Home, Store, Portal and Staff all use this same shell. Page-specific
   content belongs inside .hero-info; visual differences belong in the copy,
   not in the card geometry. */
.hero-card.page-hero {
  position: relative;
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(280px, 0.52fr);
  align-items: center;
  gap: clamp(28px, 5vw, 64px);
  min-height: 360px;
  margin: 0 0 40px;
  padding: clamp(32px, 4vw, 48px);
  overflow: hidden;
  background: linear-gradient(135deg, var(--bg-surface), var(--bg-card));
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
}

.hero-card.page-hero::before {
  content: "";
  position: absolute;
  inset: auto 0 0;
  width: 100%;
  height: 3px;
  background: linear-gradient(90deg, var(--accent), transparent 75%);
  pointer-events: none;
}

.hero-card.page-hero .hero-info,
.hero-card.page-hero .hero-character {
  position: relative;
  z-index: 1;
}

.hero-card.page-hero .hero-info {
  min-width: 0;
  max-width: 680px;
}

.hero-card.page-hero .hero-info > .badge {
  display: inline-flex;
  align-items: center;
  min-height: 30px;
  margin: 0 0 14px;
  padding: 0 12px;
  color: var(--accent-hover);
  background: var(--accent-muted);
  border: 1px solid var(--accent-border);
  border-radius: var(--radius);
  font-family: var(--font-mono);
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.16em;
  text-transform: uppercase;
}

.hero-card.page-hero .hero-info h1 {
  max-width: 760px;
  margin: 0 0 16px;
  color: var(--fg);
  font-family: var(--font-display);
  font-size: clamp(2.25rem, 4vw, 4rem);
  font-weight: 800;
  line-height: 1;
  letter-spacing: -0.045em;
  text-shadow: 4px 4px 0 color-mix(in srgb, var(--accent) 22%, transparent);
}

.hero-card.page-hero .hero-info h1 em {
  color: var(--accent-hover);
  font-style: normal;
}

.hero-card.page-hero .hero-info p {
  max-width: 600px;
  margin: 0;
  color: var(--muted);
  font-size: 1rem;
  line-height: 1.7;
}

.hero-card.page-hero .hero-actions {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 22px;
}

.hero-card.page-hero .hero-character {
  width: 100%;
  max-width: 310px;
  min-height: 280px;
  justify-self: end;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
  background: color-mix(in srgb, var(--bg-surface) 88%, transparent);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: none;
  cursor: default;
  transition: none;
}

.hero-card.page-hero .hero-character:hover {
  transform: none;
  border-color: var(--border);
}

.hero-card.page-hero .hero-logo {
  display: block;
  width: min(100%, 260px);
  height: auto;
  max-height: 240px;
  object-fit: contain;
  filter: drop-shadow(0 10px 20px rgba(0, 0, 0, 0.5));
}

.hero-card.page-hero .hero-ip {
  display: flex;
  align-items: center;
  gap: 12px;
  min-height: 64px;
  padding: 10px 20px;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  cursor: pointer;
}

.hero-card.page-hero .hero-ip > i {
  color: var(--accent);
}

.hero-card.page-hero .hero-ip-copy {
  min-width: 0;
}

.hero-card.page-hero .hero-ip-copy strong,
.hero-card.page-hero .hero-metric-value {
  display: block;
  font-family: var(--font-mono);
  font-weight: 700;
}

.hero-card.page-hero .hero-ip-copy span,
.hero-card.page-hero .hero-metric-label {
  display: block;
  color: var(--muted);
  font-size: 0.65rem;
  letter-spacing: 0.05em;
  text-transform: uppercase;
}

.hero-card.page-hero .hero-metrics {
  display: flex;
  align-items: center;
  gap: 20px;
}

.hero-card.page-hero .hero-metric {
  text-align: center;
}

.hero-card.page-hero .hero-metric-value {
  color: var(--fg);
  font-size: 1.25rem;
}

.hero-card.page-hero .hero-metric:last-child .hero-metric-value {
  color: var(--accent-hover);
}

.hero-card.page-hero .btn-hero {
  min-height: 44px;
  padding: 0 20px;
  color: #fff;
  background: var(--accent);
  border: 1px solid var(--accent);
  border-radius: var(--radius);
  font-weight: 700;
}

@media (max-width: 860px) {
  .hero-card.page-hero {
    grid-template-columns: 1fr;
    min-height: 0;
  }

  .hero-card.page-hero .hero-character {
    justify-self: start;
    max-width: 100%;
    min-height: 220px;
  }
}

@media (max-width: 560px) {
  .hero-card.page-hero {
    gap: 28px;
    padding: 28px 20px;
  }

  .hero-card.page-hero .hero-info h1 {
    font-size: clamp(2.1rem, 12vw, 3rem);
  }

  .hero-card.page-hero .hero-character {
    min-height: 190px;
  }

  .hero-card.page-hero .hero-ip {
    padding-inline: 14px;
  }
}

/* ─── Component: Server Card ─────────────────────────────────────────────── */

.server-card {
  position: relative;
  overflow: hidden;
  padding: 24px;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--bg-surface);
  box-shadow: var(--shadow);
}

.server-card::before {
  content: "";
  position: absolute;
  inset: 0;
  opacity: 0.35;
  background-image:
    linear-gradient(color-mix(in srgb, var(--fg) 10%, transparent) 1px, transparent 1px),
    linear-gradient(90deg, color-mix(in srgb, var(--fg) 10%, transparent) 1px, transparent 1px);
  background-size: 28px 28px;
  mask-image: linear-gradient(135deg, var(--fg), transparent 70%);
  pointer-events: none;
}

.server-card > * {
  position: relative;
}

.server-kicker {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 30px;
  color: var(--muted);
  font-size: 11px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.server-state {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  color: var(--muted);
}

.server-state .status-dot {
  background: var(--accent);
}

.server-ip {
  margin-bottom: 20px;
  font-family: var(--font-mono);
  font-size: clamp(20px, 3vw, 30px);
  letter-spacing: -0.04em;
  word-break: break-word;
}

.copy-ip {
  width: 100%;
  min-height: 46px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 0 14px;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: color-mix(in srgb, var(--bg) 40%, transparent);
  cursor: pointer;
  text-align: left;
  font-size: 14px;
  transition: border-color 0.2s ease;
}

.copy-ip span:last-child {
  color: var(--muted);
  font-size: 12px;
}

.copy-ip:hover {
  border-color: var(--accent);
}

.server-meta {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1px;
  margin-top: 20px;
  border-top: 1px solid var(--border);
}

.meta-item {
  padding-top: 16px;
}

.meta-value {
  display: block;
  font-family: var(--font-mono);
  font-size: 18px;
}

.meta-label {
  display: block;
  margin-top: 3px;
  color: var(--muted);
  font-size: 11px;
}

/* ─── Component: Features Grid ───────────────────────────────────────────── */

.feature-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  border-top: 1px solid var(--border);
  border-left: 1px solid var(--border);
}

.feature {
  min-height: 220px;
  padding: 24px;
  border-right: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
  transition: background 0.2s ease;
}

.feature:hover {
  background: var(--bg-surface);
}

.feature-index {
  display: block;
  margin-bottom: 48px;
  color: var(--muted);
  font-family: var(--font-mono);
  font-size: 12px;
}

.feature h3 {
  margin-bottom: 8px;
  font-size: 18px;
  letter-spacing: -0.01em;
  font-weight: 600;
}

.feature p {
  max-width: 34ch;
  margin-bottom: 0;
  color: var(--muted);
  font-size: 14px;
}

@media (max-width: 920px) {
  .feature-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

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

/* ─── Component: Status Bar (loading state) ──────────────────────────────── */

.st {
  padding: 16px;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  text-align: center;
}

.st-v {
  font-family: var(--font-mono);
  font-size: 24px;
  font-weight: 700;
}

.st-l {
  margin-top: 4px;
  color: var(--muted);
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

/* ─── Helpers ────────────────────────────────────────────────────────────── */

.fade-in {
  animation: fadeIn 0.3s ease;
}

@keyframes fadeIn {
  from { opacity: 0; transform: translateY(8px); }
  to { opacity: 1; transform: translateY(0); }
}

/* ==== style.css ==== */

:root {
    /* ── Alias → design-tokens.css (แหล่งเดียว) ────────────────────────────
       style.css ยังใช้ชื่อ var เก่า (--primary, --card-bg, ฯลฯ) อยู่ทุกหน้า
       ให้ alias เหล่านี้ชี้ไปค่าเดียวกับ design-tokens เพื่อให้ทั้งเว็บเป็นทิศทางเดียว */
    --bg-color: var(--bg, #050506);
    --card-bg: var(--bg-surface, color-mix(in srgb, var(--fg, #ffffff) 6%, transparent));
    --border-color: var(--border, color-mix(in srgb, var(--fg, #ffffff) 15%, transparent));
    --primary: var(--accent, #5e6ad2);
    --primary-hover: var(--accent-hover, #7b85e0);
    --text-main: var(--fg, #ffffff);
    --text-muted: var(--muted, #8a8f98);
    --radius-sm: 6px;
}

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

/* ── Typography ────────────────────────────────────────────────────────────
   Inter = หัวข้อเท่านั้น (display) / Roboto = เนื้อหาทั้งหมด (body)
   เดิม `*` บังคับ Inter ทั้งเว็บ ทำให้ข้อความไทยอ่านยาก */
body {
    font-family: var(--font-body, 'Roboto', system-ui, sans-serif);
    font-size: 15px;
    line-height: 1.65;
    background-color: var(--bg-color);
    color: var(--text-main);
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    overflow-x: hidden;
    position: relative;
    -webkit-font-smoothing: antialiased;
    text-rendering: optimizeLegibility;
}

h1, h2, h3, h4, h5, h6,
.logo, .section-title, .btn-hero, .hero-card h1 {
    font-family: var(--font-display, 'Inter', serif);
    font-weight: 700;
    line-height: 1.25;
    letter-spacing: -0.01em;
}

button, input, select, textarea {
    font-family: inherit;
    font-size: inherit;
}

code, kbd, samp, pre, .mono {
    font-family: var(--font-mono, 'Roboto Mono', monospace);
}

body::before {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    /* ชั้นบน = scrim ไล่สีทับภาพ ให้เนื้อหาอ่านออกตลอดหน้า
       (เดิมภาพเบลอสว่างเต็มจอ ทำให้ข้อความลอยอ่านยาก)
       รวมไว้ใน pseudo-element เดียวกัน ไม่เพิ่มเลเยอร์ทับหน้าเว็บ */
    background-image:
        linear-gradient(180deg,
            rgba(5, 5, 6, 0.62) 0%,
            rgba(5, 5, 6, 0.88) 45%,
            rgba(5, 5, 6, 0.97) 100%),
        url('assets/hero-bg-v2.webp'),
        url('assets/hero-bg-v2.jpg');
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    filter: blur(24px) saturate(0.8);
    z-index: 0;
    transform: scale(1.12); /* Prevent blurred edges */
    pointer-events: none;
}

.background-effect {
    position: fixed;
    top: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 100vw;
    height: 70vh;
    background: radial-gradient(circle at 50% 0%, color-mix(in srgb, var(--accent) 14%, transparent), transparent 62%);
    z-index: 1;
    pointer-events: none;
}

/* เนื้อหาต้องอยู่เหนือ body::before (ภาพพื้นหลัง, z-index 0)
   และ .background-effect (แสงเรือง, z-index 1)

   เดิมระบุแค่ `.main-content` / `.footer` → หน้าที่ใช้ <main> เฉยๆ
   (terms, profile, dashboard, panel, voice) โดนภาพพื้นหลังทับจนตัวหนังสือจาง
   ครอบด้วย element ระดับหน้าทั้งหมดแทน เพื่อไม่ต้องพึ่งคลาสเฉพาะ */
body > main,
body > .main-content,
body > footer,
body > .footer {
    position: relative;
    z-index: 2;
}

body > .navbar {
    position: fixed;
    z-index: 50;
}

/* Navbar */
.navbar {
    position: fixed;
    top: 14px;
    left: 50%;
    width: min(calc(100% - 24px), 1280px);
    transform: translateX(-50%);
    z-index: 50;
    background: #0a0c11;
    border: 1px solid rgba(255,255,255,0.08);
    border-radius: 999px;
    box-shadow: 0 12px 30px rgba(0, 0, 0, 0.25);
}

.nav-container {
    max-width: none;
    margin: 0 auto;
    display: flex;
    justify-content: space-between;
    align-items: center;
    height: 62px;
    padding: 0 18px;
}

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

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

.logo {
    font-size: 1.05rem;
    font-weight: 800;
    color: var(--text-main);
    text-decoration: none;
    display: flex;
    align-items: center;
    gap: 8px;
    padding-right: 14px;
    border-right: 1px solid rgba(255,255,255,0.08);
}

.nav-links {
    display: flex;
    gap: 4px;
    flex: 1;
    align-items: center;
}

.nav-actions-group {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-left: auto;
}

.nav-links a {
    color: var(--text-muted);
    text-decoration: none;
    font-size: 0.82rem;
    font-weight: 600;
    padding: 7px 10px;
    border-radius: 999px;
    transition: all 0.2s ease;
    display: flex;
    align-items: center;
    gap: 6px;
    border: 1px solid transparent;
    white-space: nowrap;
}

.nav-links a:hover {
    color: var(--text-main);
    background: rgba(255, 255, 255, 0.05);
    border-color: var(--border-color);
}

.nav-links a.active {
    background: var(--primary);
    color: white;
    border-color: var(--primary);
    box-shadow: 0 4px 14px rgba(59, 130, 246, 0.3);
}

.online-status {
    font-size: 0.875rem;
    color: var(--text-muted);
    display: flex;
    align-items: center;
    gap: 8px;
    background: rgba(255, 255, 255, 0.05);
    padding: 8px 16px;
    border-radius: 99px;
    text-decoration: none;
    transition: all 0.3s ease;
    border: 1px solid transparent;
}

.online-status:hover {
    background: rgba(255, 255, 255, 0.1);
    color: var(--text-main);
    border-color: rgba(255, 255, 255, 0.1);
}

.pulse {
    display: inline-block;
    width: 8px;
    height: 8px;
    background-color: #10b981;
    border-radius: 50%;
    box-shadow: 0 0 0 rgba(16, 185, 129, 0.4);
    animation: pulse 2s infinite;
}

@keyframes pulse {
    0% { box-shadow: 0 0 0 0 rgba(16, 185, 129, 0.4); }
    70% { box-shadow: 0 0 0 6px rgba(16, 185, 129, 0); }
    100% { box-shadow: 0 0 0 0 rgba(16, 185, 129, 0); }
}

.discord-btn, .login-btn {
    text-decoration: none;
    font-size: 0.875rem;
    font-weight: 600;
    padding: 8px 16px;
    border-radius: 99px;
    transition: all 0.2s;
    display: flex;
    align-items: center;
    gap: 8px;
}

.discord-btn {
    color: var(--text-muted);
}

.discord-btn:hover {
    color: #5865F2;
    background: rgba(88, 101, 242, 0.1);
}

.nav-actions-group #authContainer {
    display: flex;
    align-items: center;
}

.login-btn {
    color: var(--text-muted);
    border: 1px solid transparent;
}

.login-btn:hover {
    color: var(--text-main);
    background: rgba(255, 255, 255, 0.05);
    border-color: var(--border-color);
}

/* Main Content */
.main-content {
    flex: 1;
    max-width: 1280px;
    margin: 100px auto 40px;
    padding: 0 24px;
    width: 100%;
}

.hero-card {
    background: var(--bg-surface);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: clamp(24px, 3vw, 40px);
    display: flex;
    justify-content: space-between;
    align-items: center;
    box-shadow: 0 18px 40px rgba(0, 0, 0, 0.2);
    position: relative;
    overflow: hidden;
}

.hero-card::before {
    content: '';
    position: absolute;
    inset: auto auto 0 0;
    width: 100%;
    height: 3px;
    background: linear-gradient(90deg, var(--accent), transparent);
}

.page-shell {
    width: 100%;
    max-width: 1280px;
    margin: 100px auto 40px;
    padding: 0 24px 40px;
}

.page-header {
    margin-bottom: 24px;
}

.page-header .eyebrow {
    color: var(--primary);
    text-transform: uppercase;
    font-size: 0.72rem;
    font-weight: 800;
    letter-spacing: 0.2em;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    margin-bottom: 8px;
}

.page-panel,
.info-card {
    background: var(--bg-surface);
    border-radius: var(--radius);
    box-shadow: 0 18px 40px rgba(0, 0, 0, 0.16);
}

.info-card {
    padding: 24px;
    transition: transform 0.2s ease, border-color 0.2s ease;
}

.info-card:hover {
    transform: translateY(-3px);
    border-color: rgba(255, 255, 255, 0.18);
}

.stat-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 20px;
}

.hero-info .badge {
    color: var(--primary);
    text-transform: uppercase;
    font-size: 0.72rem;
    font-weight: 800;
    letter-spacing: 0.2em;
    display: inline-flex;
    align-items: center;
    gap: 6px;
}

.hero-info h1 {
    font-size: clamp(2rem, 3.4vw, 3.1rem);
    font-weight: 800;
    margin: 10px 0 12px;
    line-height: 1.06;
}

.hero-info p {
    color: var(--text-muted);
    font-size: 0.95rem;
    max-width: 560px;
    line-height: 1.7;
    margin-bottom: 0;
}

.hero-character {
    background: var(--bg-surface);
    border: 1px solid var(--border);
    padding: 18px 24px;
    border-radius: var(--radius);
    display: flex;
    align-items: center;
    justify-content: center;
    transition: transform 0.3s ease, border-color 0.3s ease;
    cursor: pointer;
}

.hero-character:hover {
    transform: translateY(-5px);
    border-color: var(--primary);
}

.box-icon {
    font-size: 4rem;
    color: var(--primary);
}

/* Categories Grid */
.categories-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 24px;
    margin-top: 40px;
}

.category-card {
    background: linear-gradient(135deg, rgba(255,255,255,0.05), rgba(255,255,255,0.025));
    border: 1px solid rgba(255,255,255,0.08);
    border-radius: var(--radius-lg);
    overflow: hidden;
    text-decoration: none;
    color: var(--text-main);
    transition: all 0.25s ease;
}

.category-card:hover {
    transform: translateY(-4px);
    border-color: rgba(255, 255, 255, 0.18);
    box-shadow: 0 12px 28px rgba(0, 0, 0, 0.24);
}

.card-image {
    aspect-ratio: 16/9;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 4rem;
    color: rgba(255, 255, 255, 0.8);
    position: relative;
}

.bg-survival { background: linear-gradient(135deg, #166534, #14532d); }
.bg-skyblock { background: linear-gradient(135deg, #0ea5e9, #0284c7); }
.bg-lifesteal { background: linear-gradient(135deg, #dc2626, #991b1b); }
.bg-pvp { background: linear-gradient(135deg, #f59e0b, #d97706); }
.bg-cosmetics { background: linear-gradient(135deg, #8b5cf6, #6d28d9); }
.bg-unban { background: linear-gradient(135deg, #475569, #334155); }

.card-content {
    padding: 24px;
    text-align: center;
}

.card-content h3 {
    font-size: 1.25rem;
    font-weight: 700;
    margin-bottom: 8px;
}

.card-content p {
    color: var(--text-muted);
    font-size: 0.875rem;
}

/* Footer */
.footer {
    margin-top: 40px;
    padding: 40px 24px max(40px, env(safe-area-inset-bottom));
    border-top: 1px solid var(--border);
    background: transparent;
    color: var(--muted);
    font-size: 13px;
}

.footer-container {
    max-width: 1232px;
    margin: 0 auto;
    background: var(--bg-surface);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    padding: 40px;
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
}

.footer-info h2 {
    font-size: 1.5rem;
    font-weight: 800;
    margin-bottom: 12px;
}

.footer-info p {
    color: var(--text-muted);
    max-width: 400px;
    font-size: 0.9rem;
    line-height: 1.6;
    margin-bottom: 24px;
}

.social-links {
    display: flex;
    gap: 16px;
}

.social-links a {
    color: var(--text-muted);
    font-size: 1.25rem;
    transition: all 0.2s;
}

.social-links a:hover {
    color: var(--text-main);
    transform: translateY(-2px);
}

.server-ip {
    display: flex;
    flex-direction: column;
    align-items: flex-end;
}

.ip-box {
    display: flex;
    align-items: center;
    gap: 16px;
    background: var(--bg-surface);
    border: 1px solid var(--border);
    padding: 12px 20px;
    border-radius: var(--radius);
    margin-bottom: 20px;
    transition: border-color 0.2s;
    cursor: pointer;
}

.ip-box:hover {
    border-color: var(--primary);
}

.ip-box i {
    color: var(--primary);
    font-size: 1.5rem;
}

.ip-text {
    display: block;
    font-family: monospace;
    font-size: 1rem;
    font-weight: 700;
}

.version {
    display: block;
    font-size: 0.65rem;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.copyright {
    font-size: 0.8rem;
    margin-bottom: 4px;
}

.disclaimer {
    font-size: 0.65rem;
    color: var(--text-muted);
    opacity: 0.9;
}

.mobile-menu-btn {
    display: none;
    background: none;
    border: none;
    color: var(--text-main);
    font-size: 2rem;
    cursor: pointer;
    margin-left: 12px;
    z-index: 100;
}

.nav-toggle-chk:checked ~ .navbar .nav-links {
    top: 0 !important;
    opacity: 1 !important;
    pointer-events: auto !important;
}

/* Change icon when checked */
.nav-toggle-chk:checked ~ .navbar .nav-right .mobile-menu-btn {
    content: "\2715"; /* Cross symbol */
}

@media (max-width: 1024px) {
    .navbar {
        top: 10px;
        width: calc(100% - 20px);
        border-radius: 18px;
    }

    .nav-container {
        height: 62px;
        padding: 0 10px;
        gap: 6px;
    }

    .nav-left {
        min-width: 0;
        gap: 8px;
    }

    .logo {
        min-width: 0;
        gap: 6px;
        padding-right: 8px;
        font-size: 0.95rem;
        white-space: nowrap;
    }

    .logo img {
        width: 32px !important;
        height: 32px !important;
    }

    .nav-actions-group {
        min-width: 0;
        flex-shrink: 1;
        gap: 6px;
    }

    .online-status {
        min-width: 0;
        flex-shrink: 1;
        gap: 5px;
        padding: 7px 10px;
        font-size: 0.75rem;
        line-height: 1.1;
        white-space: nowrap;
    }

    .mobile-menu-btn {
        flex: 0 0 40px;
        width: 40px;
        height: 40px;
        margin-left: 0;
        padding: 0;
        display: grid !important;
        place-items: center;
        font-size: 1.75rem;
    }

    .nav-actions-group {
        margin-left: auto;
    }
    .nav-actions-group #authContainer {
        display: none !important;
    }
    .mobile-menu-btn {
        display: block !important;
    }
    .nav-links {
        display: flex;
        position: fixed;
        top: -100vh;
        left: 0;
        width: 100%;
        height: 100vh;
        background: #0a0a0a;
        flex-direction: column;
        padding: 80px 24px 24px;
        transition: all 0.3s ease;
        z-index: 40;
        opacity: 0;
        pointer-events: none;
    }
    .nav-links.active {
        top: 0;
        opacity: 1;
        pointer-events: auto;
    }
    .nav-links a {
        font-size: 1.2rem;
        padding: 16px;
        justify-content: center;
        width: 100%;
    }
    .nav-links #authContainer {
        margin-top: 24px;
        display: flex;
        justify-content: center;
        width: 100%;
    }
    .nav-links #authContainer .cyauth-btn {
        font-size: 1rem;
        padding: 12px 24px;
    }
    .discord-btn {
        display: none;
    }
    .hero-card, .footer-container {
        flex-direction: column;
        text-align: left;
        gap: 20px;
    }
    .hero-info p, .footer-info p {
        margin: 10px 0;
    }
    .server-ip {
        align-items: flex-start;
        width: 100%;
    }
}

@media (max-width: 680px) {
    .main-content {
        margin-top: 86px;
        padding: 0 14px;
    }

    .hero-card {
        padding: 20px;
        border-radius: var(--radius-lg);
    }

    .hero-info h1 {
        font-size: 1.9rem;
    }

    .hero-info p {
        font-size: 0.9rem;
    }

    .hero-character {
        width: 100%;
        padding: 18px;
    }

    .categories-grid {
        grid-template-columns: 1fr;
        gap: 14px;
    }

    .card-content {
        padding: 18px;
    }

    .footer-container {
        padding: 24px;
    }
}

/* Store System Styles */
.category-tabs {
    display: flex;
    gap: 12px;
    margin-bottom: 32px;
    overflow-x: auto;
    padding-bottom: 8px;
    scrollbar-width: thin;
    scrollbar-color: var(--primary) transparent;
}

.category-tab {
    background: var(--bg-card, #1a1a1f);
    border: 1px solid var(--border-color);
    color: var(--text-muted);
    padding: 10px 24px;
    border-radius: 12px;
    font-weight: 600;
    cursor: pointer;
    white-space: nowrap;
    transition: all 0.3s ease;
}

.category-tab:hover {
    background: rgba(35, 35, 40, 0.95);
    color: var(--text-main);
}

.category-tab.active {
    background: var(--primary);
    color: #fff;
    border-color: var(--primary);
}

.product-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 24px;
}

.product-card {
    background: #0f0f12;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    padding: 24px;
    position: relative;
    display: flex;
    flex-direction: column;
    transition: all 0.3s ease;
    overflow: hidden;
}

.product-card:hover {
    transform: translateY(-5px);
    border-color: var(--primary);
    background: rgba(35, 35, 40, 0.95);
}

.hot-badge {
    position: absolute;
    top: 16px;
    right: 16px;
    background: linear-gradient(45deg, #ef4444, #f97316);
    color: white;
    font-size: 0.75rem;
    font-weight: 800;
    padding: 4px 12px;
    border-radius: 99px;
    box-shadow: 0 4px 12px rgba(239, 68, 68, 0.3);
}

.product-icon-box {
    width: 64px;
    height: 64px;
    background: rgba(var(--primary-rgb), 0.1);
    border: 1px solid rgba(var(--primary-rgb), 0.3);
    border-radius: 16px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 2rem;
    color: var(--primary);
    margin-bottom: 20px;
}

.product-card .product-icon-box.product-art {
    width: 100%;
    height: 108px;
    overflow: hidden;
    padding: 0;
    margin-bottom: 16px;
    background: transparent !important;
    border: 0 !important;
}

.product-card .product-icon-box.product-art img {
    width: 100%;
    height: 100%;
    display: block;
    object-fit: contain;
    mix-blend-mode: normal;
    transform: scale(1.25);
}

.product-card--unban {
    border-color: rgba(239, 68, 68, 0.3);
    background: linear-gradient(145deg, rgba(50, 15, 20, 0.92), rgba(15, 15, 18, 0.92));
}

.product-card--unban:hover {
    border-color: rgba(239, 68, 68, 0.75);
    background: linear-gradient(145deg, rgba(70, 18, 25, 0.96), rgba(25, 15, 18, 0.96));
}

.product-card .product-art--unban img {
    filter: hue-rotate(125deg) saturate(1.35);
}

.product-card .product-icon-box.product-art.product-art--party-key img {
    transform: scale(0.95);
}

.product-title {
    font-size: 1.25rem;
    font-weight: 800;
    margin-bottom: 8px;
    color: var(--text-main);
}

.product-price {
    font-family: monospace;
    font-size: 1.1rem;
    font-weight: 700;
    color: var(--primary);
    margin-bottom: 16px;
}

.product-features {
    list-style: none;
    padding: 0;
    margin: 0 0 24px 0;
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.product-features li {
    font-size: 0.875rem;
    color: var(--text-muted);
    display: flex;
    align-items: center;
    gap: 8px;
}

.btn-buy {
    background: var(--primary);
    color: #fff;
    border: none;
    padding: 12px;
    border-radius: 12px;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.3s ease;
    width: 100%;
    margin-top: auto;
}

.btn-buy:hover {
    opacity: 0.9;
    transform: translateY(-2px);
}
/* ===================== MODAL ===================== */

.modal-overlay {
    position: fixed;
    inset: 0;
    z-index: 3000;
    background: #0b0b0e;
    display: none;
    align-items: center;
    justify-content: center;
    padding: 1rem;
}
.modal-overlay.active { display: flex; }
.modal-content {
    max-width: 400px;
    width: 100%;
    background: var(--bg-elevated);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 2rem;
}
.modal-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 1.5rem;
}
.modal-close {
    color: var(--text-muted);
    font-size: 1.125rem;
    transition: color var(--transition);
}
.modal-close:hover { color: var(--text); }

/* ===================== COOKIE ===================== */

.cookie-popup {
    position: fixed;
    bottom: 1.5rem;
    left: 50%;
    transform: translateX(-50%) translateY(100%);
    z-index: 300;
    max-width: 520px;
    width: calc(100% - 2rem);
    padding: 1rem 1.25rem;
    background: var(--bg-elevated);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    box-shadow: var(--shadow-lg);
    opacity: 0;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    display: flex;
    align-items: center;
    gap: 1rem;
}
.cookie-popup.show {
    opacity: 1;
    transform: translateX(-50%) translateY(0);
}
.cookie-popup p {
    font-size: 0.8125rem;
    color: var(--text-secondary);
    line-height: 1.5;
    flex: 1;
}
.cookie-popup a { color: var(--primary); text-decoration: underline; }

/* ===================== PORTAL ===================== */

.portal-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1rem;
}
.portal-stat-card {
    text-align: center;
    padding: 1.5rem;
}
.portal-stat-val {
    font-family: var(--font-mono);
    font-size: 2rem;
    font-weight: 700;
    color: var(--text);
}
.portal-stat-lbl {
    font-size: 0.75rem;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.05em;
    margin-top: 0.25rem;
}
.player-list {
    max-height: 300px;
    overflow-y: auto;
}
.player-item {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 0.5rem 0;
    border-bottom: 1px solid rgba(255,255,255,0.04);
}
.player-item:last-child { border-bottom: none; }
.player-item img {
    width: 24px;
    height: 24px;
    border-radius: 4px;
}
.progress-bar {
    width: 100%;
    height: 6px;
    background: rgba(255,255,255,0.08);
    border-radius: 3px;
    overflow: hidden;
}
.progress-fill {
    height: 100%;
    border-radius: 3px;
    transition: width 0.5s ease;
}

/* ===================== STORE ===================== */

.product-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 1rem;
}
.product-card {
    display: flex;
    flex-direction: column;
    gap: 1rem;
    padding: 1.5rem;
    position: relative;
}
.product-card .hot-badge {
    position: absolute;
    top: 0.75rem;
    right: 0.75rem;
    background: rgba(239, 68, 68, 0.2);
    color: #ef4444;
    padding: 0.25rem 0.5rem;
    border-radius: 4px;
    font-size: 0.7rem;
    font-weight: 700;
}
.product-icon-box {
    width: 3rem;
    height: 3rem;
    border-radius: var(--radius-sm);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.25rem;
    flex-shrink: 0;
}
.product-title {
    font-family: var(--font-th);
    font-weight: 700;
    font-size: 1.125rem;
}
.product-desc {
    font-size: 0.8125rem;
    color: var(--text-secondary);
}
.product-price {
    font-family: var(--font-mono);
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--primary);
}
.product-features {
    list-style: none;
    display: flex;
    flex-direction: column;
    gap: 0.375rem;
}
.product-features li {
    font-size: 0.8125rem;
    color: var(--text-secondary);
}
.category-tabs {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    justify-content: center;
    margin-bottom: 1.5rem;
}
.category-tab {
    padding: 0.5rem 1.25rem;
    border-radius: 12px;
    background: var(--bg-card, #1a1a1f);
    border: 1px solid var(--border);
    color: var(--text-secondary);
    font-size: 0.8125rem;
    font-weight: 600;
    cursor: pointer;
    transition: all var(--transition);
}
.category-tab:hover {
    border-color: var(--border-hover);
    color: var(--text);
}
.category-tab.active {
    background: var(--primary);
    color: #fff;
    border-color: var(--primary);
    box-shadow: 0 4px 14px rgba(59, 130, 246, 0.3);
}

/* ===================== DASHBOARD ===================== */

.dash-layout {
    display: grid;
    grid-template-columns: 250px 1fr;
    gap: 1.5rem;
    min-height: 60vh;
}
.dash-sidebar {
    display: flex;
    flex-direction: column;
    gap: 0.375rem;
    padding: 1rem;
    height: fit-content;
}
.dash-sidebar-item {
    padding: 0.75rem 1rem;
    color: var(--text-muted);
    border-radius: var(--radius-sm);
    cursor: pointer;
    transition: all var(--transition);
    display: flex;
    align-items: center;
    gap: 0.625rem;
    font-weight: 500;
    font-size: 0.875rem;
}
.dash-sidebar-item:hover {
    background: rgba(255,255,255,0.04);
    color: var(--text);
}
.dash-sidebar-item.active {
    background: var(--primary-muted);
    color: var(--primary-hover);
}
.dash-panel { display: none; }
.dash-panel.active { display: block; }
.dash-panel-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1.5rem;
    padding-bottom: 1rem;
    border-bottom: 1px solid var(--border);
}
.dash-panel-title {
    font-family: var(--font-th);
    font-size: 1.25rem;
    font-weight: 700;
}
.data-table {
    width: 100%;
    border-collapse: collapse;
}
.data-table th, .data-table td {
    padding: 0.75rem 0.5rem;
    text-align: left;
    border-bottom: 1px solid rgba(255,255,255,0.05);
    font-size: 0.875rem;
}
.data-table th {
    color: var(--text-muted);
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    font-weight: 700;
}
.data-table tr:hover td { background: rgba(255,255,255,0.02); }

/* ===================== SCROLLBAR ===================== */

::-webkit-scrollbar { width: 6px; }
::-webkit-scrollbar-track { background: transparent; }
::-webkit-scrollbar-thumb {
    background: rgba(255,255,255,0.08);
    border-radius: 3px;
}
::-webkit-scrollbar-thumb:hover { background: rgba(255,255,255,0.15); }

/* ===================== ANIMATION ===================== */

.section-enter {
    opacity: 0;
    transform: translateY(24px);
}

/* ===================== RESPONSIVE ===================== */

@media (max-width: 1023px) {
    .hide-mobile { display: none !important; }
    .show-mobile { display: flex; }

    .nav-center { display: none; }
    .nav-status { display: none; }
    .btn-hamburger { display: flex; }
    .lang-toggle.hide-mobile { display: none !important; }

    .hero-card {
        grid-template-columns: 1fr;
        gap: 2rem;
        text-align: center;
    }
    .hero-sub, .hero-desc { margin: 0 auto; }
    .hero-btns { justify-content: center; }
    .hero-stats { justify-content: center; }
    .hero-visual { display: none; }

    .emperors-grid { grid-template-columns: 1fr; }
    .emperor-card:first-child { flex-direction: column; text-align: center; }

    .features-grid { grid-template-columns: 1fr; }

    .footer-grid {
        grid-template-columns: 1fr;
        gap: 2rem;
        text-align: center;
    }
    .footer-brand { align-items: center; }
    .footer-desc { margin: 0 auto; }
    .footer-bottom {
        flex-direction: column;
        gap: 1rem;
        text-align: center;
    }

    .section-title { font-size: 1.75rem; }
    .hero-title { font-size: 2.5rem; }

    .portal-grid { grid-template-columns: 1fr; }
    .dash-layout { grid-template-columns: 1fr; }
    .grid-2 { grid-template-columns: 1fr; }
    .grid-3 { grid-template-columns: 1fr; }
}

@media (max-width: 640px) {
    .nav-brand-sub { display: none; }
    .container { padding: 0 1rem; }
    .hero { padding: 5rem 0 2rem; }
    .hero-title { font-size: 2rem; }
    .section { padding: 2.5rem 0; }
    .section-title { font-size: 1.5rem; }
    .cta-card { padding: 2rem 1.25rem; }
    .cta-title { font-size: 1.5rem; }
    .page-section { padding-top: 80px; }
}

@media (prefers-reduced-motion: reduce) {
    html { scroll-behavior: auto; }
    *, *::before, *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        animation-delay: 0s !important;
        transition-duration: 0.01ms !important;
        transition-delay: 0s !important;
        scroll-behavior: auto !important;
    }
}

html[data-reduced-motion="true"] { scroll-behavior: auto; }
html[data-reduced-motion="true"] *,
html[data-reduced-motion="true"] *::before,
html[data-reduced-motion="true"] *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    animation-delay: 0s !important;
    transition-duration: 0.01ms !important;
    transition-delay: 0s !important;
    scroll-behavior: auto !important;
}

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(12px); }
    to { opacity: 1; transform: translateY(0); }
}

/* ===================== PAGE-SPECIFIC ===================== */

/* Index status strip */
.server-strip {
    padding: 0;
}

/* Voice Page */
.voice-page { padding-top: 96px; padding-bottom: 2rem; min-height: 100vh; display: flex; flex-direction: column; }
.voice-card { max-width: 800px; margin: 0 auto; width: 100%; }
.v-status-bar { display: flex; align-items: center; gap: 0.75rem; padding: 1rem; border-radius: var(--radius-sm); background: rgba(255,255,255,0.03); border: 1px solid var(--border); margin-bottom: 1.25rem; }
.v-status-dot { width: 10px; height: 10px; border-radius: 50%; flex-shrink: 0; }
.v-status-dot.offline { background: var(--danger); }
.v-status-dot.connecting { background: var(--warning); animation: pulse-dot 1s infinite; }
.v-status-dot.online { background: var(--success); }
.v-status-text { font-size: 0.8125rem; font-weight: 500; }
.v-status-sub { font-size: 0.75rem; color: var(--text-muted); }
.v-controls { display: flex; gap: 0.75rem; justify-content: center; margin: 1rem 0; flex-wrap: wrap; }
.v-btn { width: 3.5rem; height: 3.5rem; border-radius: 14px; border: 1px solid var(--border); background: rgba(255,255,255,0.04); color: var(--text); font-size: 1.125rem; cursor: pointer; transition: all var(--transition); display: flex; align-items: center; justify-content: center; }
.v-btn:hover { background: rgba(255,255,255,0.08); border-color: var(--border-hover); }
.v-btn.active { background: var(--primary); border-color: var(--primary); color: #fff; }
.v-btn.danger.active { background: var(--danger); border-color: var(--danger); }
.v-btn:disabled { opacity: 0.35; cursor: not-allowed; }
.v-sld-row { display: flex; align-items: center; gap: 0.75rem; padding: 0.625rem 0; }
.v-sld-row label { font-size: 0.8125rem; color: var(--text-muted); min-width: 6rem; }
.v-sld { flex: 1; -webkit-appearance: none; height: 4px; border-radius: 2px; background: var(--border); outline: none; }
.v-sld::-webkit-slider-thumb { -webkit-appearance: none; width: 16px; height: 16px; border-radius: 50%; background: var(--primary); cursor: pointer; }
.v-sld-val { font-size: 0.75rem; font-family: var(--font-mono); color: var(--text-secondary); min-width: 2.5rem; text-align: right; }
.v-select { width: 100%; padding: 0.625rem 0.75rem; background: rgba(255,255,255,0.04); border: 1px solid var(--border); border-radius: var(--radius-sm); color: var(--text); font-size: 0.875rem; outline: none; cursor: pointer; }
.v-select option { background: #1a1a1a; color: #ffffff; }
.v-select:focus { border-color: var(--primary-border); }
.v-activity { display: flex; align-items: center; gap: 0.75rem; padding: 0.75rem; border-radius: var(--radius-sm); background: rgba(255,255,255,0.03); border: 1px solid var(--border); margin: 1rem 0; }
.v-activity-bars { display: flex; align-items: center; gap: 2px; height: 24px; }
.v-activity-bars span { width: 3px; background: var(--primary); border-radius: 2px; transition: height 0.1s; }
.v-activity-label { font-size: 0.8125rem; color: var(--text-muted); }
.v-players { display: flex; flex-direction: column; gap: 0.375rem; }
.v-player { display: flex; align-items: center; justify-content: space-between; padding: 0.5rem 0.75rem; border-radius: var(--radius-sm); background: rgba(255,255,255,0.03); border: 1px solid var(--border); }
.v-player-info { display: flex; align-items: center; gap: 0.625rem; }
.v-player-head { width: 1.5rem; height: 1.5rem; border-radius: 4px; background: var(--bg-elevated); }
.v-player-name { font-size: 0.8125rem; font-weight: 500; }
.v-player-tag { font-size: 0.6875rem; color: var(--text-muted); padding: 0.125rem 0.375rem; border-radius: 4px; background: var(--border); }
.v-player-speaking { width: 8px; height: 8px; border-radius: 50%; background: rgba(255,255,255,0.1); flex-shrink: 0; }
.v-player-speaking.on { background: var(--success); animation: pulse-dot 1s infinite; }
.v-player-vol { width: 0; display: flex; align-items: center; gap: 0.5rem; }
.v-player-vol input { width: 64px; -webkit-appearance: none; height: 3px; background: var(--border); border-radius: 2px; outline: none; }
.v-player-vol input::-webkit-slider-thumb { -webkit-appearance: none; width: 12px; height: 12px; border-radius: 50%; background: var(--text-muted); cursor: pointer; }
.v-login-card { max-width: 420px; margin: 0 auto; width: 100%; }
.v-field { width: 100%; padding: 0.75rem 1rem; background: rgba(255,255,255,0.04); border: 1px solid var(--border); border-radius: var(--radius-sm); color: var(--text); font-size: 0.9375rem; outline: none; transition: border var(--transition); }
.v-field:focus { border-color: var(--primary-border); }
.v-field::placeholder { color: var(--text-muted); }
.v-login-hint { font-size: 0.75rem; color: var(--text-muted); text-align: center; padding: 0.75rem; background: rgba(255,255,255,0.03); border-radius: var(--radius-sm); border: 1px solid var(--border); }
.v-login-hint i { color: var(--primary); margin-right: 0.375rem; }
.v-info-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 0.75rem; margin: 1rem 0; }
.v-info-item { padding: 0.75rem; background: rgba(255,255,255,0.03); border-radius: var(--radius-sm); border: 1px solid var(--border); text-align: center; }
.v-info-item .num { font-family: var(--font-mono); font-size: 1.375rem; font-weight: 700; }
.v-info-item .lbl { font-size: 0.6875rem; color: var(--text-muted); text-transform: uppercase; letter-spacing: 0.05em; margin-top: 0.25rem; }
.v-section { display: none; }
.v-section.active { display: block; }
.v-keyhint { font-size: 0.6875rem; color: var(--text-muted); background: rgba(255,255,255,0.04); padding: 0.125rem 0.375rem; border-radius: 4px; border: 1px solid var(--border); }

/* AI Page */
.ai-page { padding-top: 96px; padding-bottom: 2rem; min-height: 100vh; display: flex; flex-direction: column; }
.chat-card { display: flex; flex-direction: column; height: calc(100vh - 140px); max-height: 800px; padding: 1.5rem; }
.chat-header { display: flex; align-items: center; gap: 1rem; padding-bottom: 1rem; border-bottom: 1px solid var(--border); margin-bottom: 1rem; }
.ai-avatar { width: 2.75rem; height: 2.75rem; border-radius: 50%; background: linear-gradient(135deg, var(--primary), #8b5cf6); display: flex; align-items: center; justify-content: center; font-size: 1.25rem; color: #fff; flex-shrink: 0; }
.chat-header-info h2 { font-family: var(--font-th); font-size: 1.125rem; font-weight: 700; }
.chat-header-info p { font-size: 0.75rem; color: var(--success); display: flex; align-items: center; gap: 0.375rem; }
.chat-messages { flex: 1; overflow-y: auto; display: flex; flex-direction: column; gap: 0.75rem; padding-right: 0.5rem; }
.msg { max-width: 80%; padding: 0.875rem 1.125rem; border-radius: 12px; line-height: 1.6; font-size: 0.9375rem; animation: fadeIn 0.3s ease; }
.msg.user { align-self: flex-end; background: linear-gradient(135deg, var(--primary), #2563eb); color: #fff; border-bottom-right-radius: 4px; }
.msg.ai { align-self: flex-start; background: rgba(255,255,255,0.04); border: 1px solid var(--border); color: var(--text); border-bottom-left-radius: 4px; }
.typing-indicator { display: none; align-self: flex-start; padding: 0.75rem 0; color: var(--text-muted); font-size: 0.8125rem; }
.chat-input-area { display: flex; gap: 0.75rem; padding-top: 1rem; border-top: 1px solid var(--border); margin-top: 1rem; }
.chat-input { flex: 1; background: rgba(255,255,255,0.04); border: 1px solid var(--border); border-radius: 24px; padding: 0.75rem 1.25rem; color: var(--text); font-size: 0.9375rem; outline: none; transition: border var(--transition); }
.chat-input:focus { border-color: var(--primary-border); }
.send-btn { width: 3rem; height: 3rem; border-radius: 50%; background: linear-gradient(135deg, var(--primary), #8b5cf6); color: #fff; font-size: 1.125rem; display: flex; align-items: center; justify-content: center; transition: all var(--transition); flex-shrink: 0; }
.send-btn:hover { transform: scale(1.05); }

/* Monitor Page */
.monitor-page { padding-top: 96px; min-height: 100vh; padding-bottom: 2rem; }
.stats-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); gap: 1rem; margin-bottom: 1.5rem; }
.stat-card { padding: 1.25rem; display: flex; flex-direction: column; gap: 0.5rem; }
.stat-card-header { display: flex; align-items: center; justify-content: space-between; }
.stat-card-icon { width: 2.25rem; height: 2.25rem; border-radius: var(--radius-sm); display: flex; align-items: center; justify-content: center; font-size: 1rem; }
.stat-card-label { font-size: 0.75rem; color: var(--text-muted); text-transform: uppercase; letter-spacing: 0.04em; font-weight: 600; }
.stat-card-value { font-family: var(--font-mono); font-size: 1.75rem; font-weight: 700; color: var(--text); line-height: 1.1; }
.stat-card-change { font-size: 0.6875rem; font-weight: 600; display: flex; align-items: center; gap: 0.25rem; }
.stat-card-change.up { color: var(--success); }
.stat-card-change.down { color: var(--danger); }
.charts-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 1rem; margin-bottom: 1.5rem; }
.chart-card { padding: 1.25rem; }
.chart-card h3 { font-family: var(--font-th); font-size: 1rem; font-weight: 700; margin-bottom: 1rem; }
.chart-card canvas { max-height: 200px; }
.info-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 1rem; }
.info-card { padding: 1.25rem; }
.info-card h3 { font-family: var(--font-th); font-size: 1rem; font-weight: 700; margin-bottom: 0.75rem; }
.info-row { display: flex; justify-content: space-between; padding: 0.5rem 0; border-bottom: 1px solid rgba(255,255,255,0.04); font-size: 0.875rem; }
.info-row:last-child { border-bottom: none; }
.info-row-label { color: var(--text-muted); }
.info-row-value { color: var(--text); font-weight: 500; }

/* Dashboard Page */
.dash-page { padding-top: 96px; min-height: 100vh; padding-bottom: 2rem; }
.unauthorized { text-align:center; padding:6rem 2rem; margin-top:100px; display:none; }
.unauthorized h1 { font-family:var(--font-th); font-size:3rem; font-weight:900; color:var(--danger); margin-bottom:1rem; }
.unauthorized p { color:var(--text-secondary); font-size:1.1rem; margin-bottom:1.5rem; }

/* Patch Page */
.patch-card { border-left: 4px solid var(--primary); padding: 1.5rem; }
.tag-add { background:rgba(16,185,129,0.15);color:#34d399;padding:2px 8px;border-radius:4px;font-size:0.7rem;font-weight:700;margin-right:6px; }
.tag-fix { background:rgba(96,165,250,0.15);color:#60a5fa;padding:2px 8px;border-radius:4px;font-size:0.7rem;font-weight:700;margin-right:6px; }
.tag-change { background:rgba(245,158,11,0.15);color:#fbbf24;padding:2px 8px;border-radius:4px;font-size:0.7rem;font-weight:700;margin-right:6px; }

/* Payment modal */
#stripe-payment-mount { background: rgba(255,255,255,0.04); border-radius: var(--radius-sm); padding: 1.25rem; border: 1px solid var(--border); min-height: 200px; }
.payment-option-btn { display:flex; align-items:center; justify-content:space-between; padding:0.75rem 1rem; border-radius:var(--radius-sm); background:rgba(255,255,255,0.03); border:1px solid var(--border); cursor:pointer; transition:all var(--transition); }
.payment-option-btn:hover { border-color:var(--border-hover); background:rgba(255,255,255,0.08); }
.payment-option-btn.disabled { opacity:0.4; cursor:not-allowed; }
.payment-option-info { display:flex; align-items:center; gap:0.75rem; }
.payment-option-icon { width:2rem; height:2rem; border-radius:6px; background:rgba(255,255,255,0.04); display:flex; align-items:center; justify-content:center; font-size:0.875rem; }
.payment-option-text { font-size:0.8125rem; font-weight:600; color:var(--text); }
.payment-option-balance { font-size:0.6875rem; color:var(--text-muted); }
.payment-option-price { font-size:0.875rem; font-weight:700; font-family:var(--font-mono); }
.modal-product-summary { display:flex; align-items:center; gap:1rem; margin-bottom:1.5rem; padding-bottom:1rem; border-bottom:1px solid var(--border); }
.modal-product-icon { width:2.5rem; height:2.5rem; border-radius:var(--radius-sm); background:linear-gradient(135deg,var(--primary),#0088ff); display:flex; align-items:center; justify-content:center; font-size:1rem; color:#000; flex-shrink:0; }

/* Profile Page */
.profile-stats { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1rem; }
.profile-stat-card { padding: 1.5rem; text-align: center; }

/* Responsive fixes for page-specific */
@media (max-width: 1023px) {
    .stats-grid { grid-template-columns: repeat(2, 1fr); }
    .charts-grid { grid-template-columns: 1fr; }
    .info-grid { grid-template-columns: 1fr; }
    .profile-stats { grid-template-columns: 1fr; }
}

@media (max-width: 640px) {
    .voice-page { padding-top: 80px; }
    .v-info-grid { grid-template-columns: 1fr 1fr; }
    .v-btn { width: 3rem; height: 3rem; font-size: 1rem; }
    .ai-page { padding-top: 80px; }
    .chat-card { height: calc(100vh - 120px); max-height: none; }
    .msg { max-width: 90%; font-size: 0.875rem; }
    .monitor-page { padding-top: 80px; }
    .dash-page { padding-top: 80px; }
}

/* Auth bridge */
.auth-bridge-body {
    background: var(--bg);
    color: var(--text);
    display: flex;
    align-items: center;
    justify-content: center;
    height: 100vh;
    margin: 0;
    font-family: var(--font-en);
    text-align: center;
}

/* ===================== MODAL ===================== */
/* กติกา: overlay = ฉากหลังหรี่ + เบลอ, content = กล่องที่ "เลื่อนในตัวเอง"
   (เดิม overlay ทึบเต็มจอ และ content ไม่มี max-height → เนื้อหายาวล้นจอ กดปุ่มไม่ถึง) */
.modal-overlay {
    position: fixed;
    inset: 0;
    z-index: 3000;
    background: color-mix(in srgb, #05060a 78%, transparent);
    backdrop-filter: blur(6px);
    -webkit-backdrop-filter: blur(6px);
    display: none;
    align-items: center;
    justify-content: center;
    padding: 20px 16px;
    overscroll-behavior: contain;
}
.modal-overlay.active {
    display: flex;
    animation: modalFade 0.18s ease-out;
}
@keyframes modalFade { from { opacity: 0; } to { opacity: 1; } }

.modal-content {
    max-width: 400px;
    width: 100%;
    max-height: calc(100dvh - 40px);
    overflow-y: auto;
    overscroll-behavior: contain;
    background: var(--bg-elevated, #17181c);
    border: 1px solid var(--border-color);
    border-radius: 14px;
    padding: 22px;
    box-shadow: 0 24px 70px rgba(0,0,0,0.55);
    animation: modalRise 0.2s cubic-bezier(0.2, 0.9, 0.3, 1);
}
@keyframes modalRise { from { transform: translateY(12px); } to { transform: none; } }

.modal-content::-webkit-scrollbar { width: 8px; }
.modal-content::-webkit-scrollbar-thumb {
    background: var(--border-color);
    border-radius: 99px;
}

.modal-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    margin-bottom: 18px;
    padding-bottom: 14px;
    border-bottom: 1px solid var(--border-color);
}
.modal-close {
    width: 32px;
    height: 32px;
    flex-shrink: 0;
    display: grid;
    place-items: center;
    border-radius: 8px;
    color: var(--text-muted);
    font-size: 0.95rem;
    transition: color 0.2s, background 0.2s;
    background: none;
    border: none;
    cursor: pointer;
}
.modal-close:hover { color: var(--text-main); background: rgba(255,255,255,0.07); }

/* Payment modal */
.payment-option-btn {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    padding: 12px 14px;
    border-radius: 10px;
    background: rgba(255,255,255,0.03);
    border: 1px solid var(--border-color);
    cursor: pointer;
    transition: border-color 0.2s, background 0.2s;
}
.payment-option-btn:hover { border-color: var(--primary); background: rgba(255,255,255,0.06); }
.payment-option-btn.is-selected {
    border-color: var(--primary);
    background: color-mix(in srgb, var(--primary) 12%, transparent);
}
.payment-option-btn.disabled { opacity: 0.4; cursor: not-allowed; }
.payment-option-info { display: flex; align-items: center; gap: 12px; min-width: 0; }
.payment-option-icon {
    width: 38px;
    height: 38px;
    flex-shrink: 0;
    border-radius: 10px;
    background: rgba(255,255,255,0.05);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1rem;
}
.payment-option-text { font-size: 0.875rem; font-weight: 700; }
.payment-option-balance { font-size: 0.7rem; color: var(--text-muted); margin-top: 1px; }
.payment-option-price { font-size: 0.875rem; font-weight: 700; font-family: var(--font-mono, monospace); }

/* ── ฟอร์มในโมดัล (ใช้ร่วมกันทุกช่องทางเติมเงิน) ───────────────────────── */
.modal-field { display: block; margin-bottom: 12px; }
.modal-field > span,
.modal-label {
    display: block;
    font-size: 0.78rem;
    font-weight: 700;
    color: var(--text-muted);
    margin-bottom: 6px;
    letter-spacing: 0.02em;
}
.modal-input {
    width: 100%;
    padding: 11px 13px;
    background: rgba(0,0,0,0.28);
    border: 1px solid var(--border-color);
    border-radius: 9px;
    color: var(--text-main);
    outline: none;
    transition: border-color 0.2s, box-shadow 0.2s;
}
.modal-input:focus {
    border-color: var(--primary);
    box-shadow: 0 0 0 3px color-mix(in srgb, var(--primary) 22%, transparent);
}
.modal-input::placeholder { color: color-mix(in srgb, var(--text-muted) 75%, transparent); }
.modal-hint { font-size: 0.72rem; color: var(--text-muted); margin-top: 6px; line-height: 1.5; }
.modal-hint.is-warning { color: var(--warning, #eab308); }

/* file input ที่ไม่ใช่ปุ่มระบบเปลือยๆ */
.modal-filedrop {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 14px;
    border: 1px dashed var(--border-color);
    border-radius: 10px;
    background: rgba(0,0,0,0.2);
    cursor: pointer;
    transition: border-color 0.2s, background 0.2s;
}
.modal-filedrop:hover { border-color: var(--primary); background: rgba(255,255,255,0.03); }
.modal-filedrop input[type="file"] { display: none; }
.modal-filedrop i { font-size: 1.15rem; color: var(--primary); }
.modal-filedrop .filedrop-text { font-size: 0.82rem; font-weight: 600; }
.modal-filedrop .filedrop-sub { font-size: 0.7rem; color: var(--text-muted); }

.modal-submit {
    width: 100%;
    margin-top: 14px;
    padding: 12px;
    background: var(--primary);
    color: #fff;
    border: none;
    border-radius: 9px;
    font-weight: 700;
    cursor: pointer;
    transition: background 0.2s, opacity 0.2s;
}
.modal-submit:hover:not(:disabled) { background: var(--primary-hover); }
.modal-submit:disabled { opacity: 0.55; cursor: progress; }

/* บล็อก QR พร้อมเพย์ */
.qr-card {
    text-align: center;
    padding: 16px;
    border-radius: 12px;
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    margin-bottom: 14px;
}
.qr-card__title {
    font-family: var(--font-mono, monospace);
    font-weight: 700;
    font-size: 0.68rem;
    letter-spacing: 0.12em;
    color: var(--primary);
    margin-bottom: 10px;
}
.qr-card__meta {
    display: grid;
    grid-template-columns: auto 1fr;
    gap: 3px 10px;
    text-align: left;
    font-size: 0.72rem;
    margin-bottom: 12px;
}
.qr-card__meta dt { color: var(--text-muted); }
.qr-card__meta dd { margin: 0; font-weight: 600; font-family: var(--font-mono, monospace); }
.qr-card__img {
    width: 168px;
    max-width: 100%;
    border-radius: 10px;
    background: #fff;
    padding: 8px;
}
.qr-card__warn {
    font-size: 0.68rem;
    color: var(--danger, #ef4444);
    margin-top: 10px;
    line-height: 1.5;
}

@media (max-width: 480px) {
    .modal-content { padding: 18px 16px; border-radius: 12px; }
    .modal-overlay { padding: 12px 10px; }
}
.modal-product-summary { display:flex; align-items:center; gap:1rem; margin-bottom:1.5rem; padding-bottom:1rem; border-bottom:1px solid var(--border-color); }
.modal-product-icon { width:2.5rem; height:2.5rem; border-radius:8px; background:linear-gradient(135deg,var(--primary),#0088ff); display:flex; align-items:center; justify-content:center; font-size:1rem; color:#000; flex-shrink:0; }


/* ===================== GLOBAL LIGHT THEME ===================== */
html[data-theme="light"] {
    --bg: #eef2f7;
    --bg-color: #eef2f7;
    --bg-surface: rgba(255,255,255,0.72);
    --bg-card: rgba(255,255,255,0.88);
    --card-bg: rgba(255,255,255,0.9);
    --bg-elevated: #ffffff;
    --fg: #172033;
    --text: #172033;
    --text-main: #172033;
    --text-secondary: #526176;
    --text-muted: #718096;
    --muted: #526176;
    --subtle: rgba(15,23,42,0.42);
    --border: rgba(15,23,42,0.14);
    --border-color: rgba(15,23,42,0.14);
    --border-hover: rgba(15,23,42,0.26);
    --primary: #2563eb;
    --primary-hover: #1d4ed8;
    --primary-muted: rgba(37,99,235,0.12);
    --primary-border: rgba(37,99,235,0.3);
    --accent: #2563eb;
    --accent-hover: #1d4ed8;
    --accent-muted: rgba(37,99,235,0.12);
    --accent-border: rgba(37,99,235,0.3);
    --shadow: 0 4px 12px rgba(15,23,42,0.12);
    --shadow-lg: 0 8px 30px rgba(15,23,42,0.16);
}

html[data-theme="light"] body { background-color: var(--bg-color); color: var(--text-main); }
html[data-theme="light"] body::before { filter: blur(15px) brightness(1.12) saturate(0.7); opacity: 0.14; }
html[data-theme="light"] .background-effect { opacity: 0.08; background: radial-gradient(circle at 50% 0%, rgba(37,99,235,0.1), transparent 60%); }
html[data-theme="light"] .navbar { background: rgba(255,255,255,0.9); border-color: rgba(15,23,42,0.12); box-shadow: 0 14px 34px rgba(15,23,42,0.12); }
html[data-theme="light"] .hero-card, html[data-theme="light"] .category-card, html[data-theme="light"] .card, html[data-theme="light"] .product-card, html[data-theme="light"] .footer-container, html[data-theme="light"] .server-card, html[data-theme="light"] .ip-box, html[data-theme="light"] .glass, html[data-theme="light"] .modal-content, html[data-theme="light"] .cyauth-dropdown { background: rgba(255,255,255,0.86); border-color: rgba(15,23,42,0.12); color: var(--text); box-shadow: 0 18px 50px rgba(15,23,42,0.1); }
html[data-theme="light"] .home-page .hero-card { background: linear-gradient(115deg, rgba(255,255,255,0.96), rgba(241,245,249,0.9)); border-color: rgba(37,99,235,0.18); }
html[data-theme="light"] .home-page .hero-info>p, html[data-theme="light"] .home-page .hero-info h1 em { color: var(--text-secondary); }
html[data-theme="light"] .nav-links a, html[data-theme="light"] .discord-btn, html[data-theme="light"] .login-btn, html[data-theme="light"] .online-status { color: var(--text-secondary); }
html[data-theme="light"] .nav-links a:hover, html[data-theme="light"] .login-btn:hover, html[data-theme="light"] .online-status:hover { color: var(--text); background: rgba(15,23,42,0.05); border-color: rgba(15,23,42,0.12); }
html[data-theme="light"] input, html[data-theme="light"] textarea, html[data-theme="light"] select { background: rgba(255,255,255,0.78); color: var(--text); border-color: rgba(15,23,42,0.16); }
html[data-theme="light"] .mobile-drawer { background: rgba(248,250,252,0.98); color: var(--text); }
html[data-theme="light"] .mobile-drawer-link, html[data-theme="light"] .mobile-lang-row span { color: var(--text-secondary); }
html[data-theme="light"] .mobile-drawer-link:hover, html[data-theme="light"] .mobile-drawer-close:hover { background: rgba(15,23,42,0.05); color: var(--text); }
html[data-theme="light"] .modal-overlay { background: rgba(15,23,42,0.42); }
html[data-theme="light"] [style*="background:rgba(255,255,255"], html[data-theme="light"] [style*="background: rgba(255, 255, 255"] { background: rgba(15,23,42,0.04) !important; }
html[data-theme="light"] [style*="border:1px solid rgba(255,255,255"], html[data-theme="light"] [style*="border: 1px solid rgba(255, 255, 255"] { border-color: rgba(15,23,42,0.12) !important; }
html[data-theme="light"] .footer-info p, html[data-theme="light"] .copyright, html[data-theme="light"] .disclaimer, html[data-theme="light"] .card-content p, html[data-theme="light"] .product-desc { color: var(--text-muted); }

/* ==== home.css ==== */
/* CyoriaSMP — Home page overrides (ย้ายจาก inline <style> ใน index.html)
   โหลดต่อจาก style.css; ใช้ .home-page prefix ให้ specificity ชนะโดยไม่ต้องใช้ !important */

.home-page .hero-card {
            background: linear-gradient(135deg, #14161c, #0e0f13);
            border: 1px solid var(--border);
            border-radius: var(--radius);
            box-shadow: 0 18px 40px rgba(0,0,0,0.2);
        }.home-page .hero-card .badge {
            background: var(--accent-muted);
            color: var(--accent-hover);
            border: 1px solid var(--accent-border);
            border-radius: var(--radius-sm);
            font-family: var(--font-mono);
            font-size: 11px;
            font-weight: 600;
            padding: 4px 12px;
        }
        .hero-card h1 {
            font-family: var(--font-display);
            letter-spacing: -0.03em;
        }.home-page .hero-card p {
            color: var(--muted);
            font-size: 16px;
            line-height: 1.6;
        }.home-page .hero-character img {
            opacity: 0.85;
        }.home-page .ip-box {
            background: var(--bg-surface);
            border: 1px solid var(--border);
            border-radius: var(--radius);
            box-shadow: none;
        }
        .ip-box div div:first-child {
            font-family: var(--font-mono);
        }.home-page .ip-box div div:last-child {
            color: var(--muted);
        }


        .categories-grid {
            display: grid;
            grid-template-columns: repeat(3, minmax(0, 1fr));
            gap: 16px;
            padding: 0;
            max-width: 100%;
        }.home-page .category-card {
            display: flex;
            flex-direction: column;
            border: 1px solid var(--border);
            border-radius: var(--radius);
            background: var(--bg-surface);
            overflow: hidden;
            transition: border-color 0.2s ease, background 0.2s ease;
            text-decoration: none;
            box-shadow: none;
            min-height: 0;
            padding: 0;
        }.home-page .category-card:hover {
            border-color: var(--border-hover);
            background: var(--bg-elevated);
        }.home-page .category-card .card-image {
            height: 72px;
            display: flex;
            align-items: center;
            justify-content: center;
            background: transparent;
            border-radius: 0;
            position: relative;
            overflow: hidden;
        }
        .category-card .card-image img {
            position: absolute;
            inset: 0;
            width: 100%;
            height: 100%;
            object-fit: cover;
            opacity: 0.92;
            transition: transform 0.35s ease, opacity 0.35s ease;
        }
        .category-card:hover .card-image img {
            transform: scale(1.06);
            opacity: 1;
        }
        .category-card .card-image::before {
            content: '';
            position: absolute;
            inset: 0;
            z-index: 1;
            background: linear-gradient(180deg, rgba(5, 5, 6, 0.08), rgba(5, 5, 6, 0.52));
        }.home-page .category-card .card-image i {
            position: relative;
            z-index: 2;
            font-size: 28px;
            color: var(--accent);
            color: #fff;
            opacity: 0.9;
            filter: none;
            text-shadow: 0 2px 12px rgba(0,0,0,.65);
        }
        .category-card .card-image::after {
            content: '';
            position: absolute;
            bottom: 0;
            left: 16px;
            right: 16px;
            height: 1px;
            background: var(--border);
        }
        .category-card .card-content {
            padding: 16px 20px 20px;
        }.home-page .category-card .card-content h3 {
            font-family: var(--font-display);
            font-size: 16px;
            font-weight: 600;
            margin-bottom: 6px;
            color: var(--fg);
            letter-spacing: -0.01em;
        }.home-page .category-card .card-content p {
            color: var(--muted);
            font-size: 13px;
            line-height: 1.55;
            margin-bottom: 0;
        }
        .category-card .bg-survival,
        .category-card .bg-skyblock,
        .category-card .bg-cosmetics,
        .category-card .bg-lifesteal,
        .category-card .bg-pvp,
        .category-card .bg-unban {
            background: transparent;
        }
        @media (max-width: 900px) {
            .categories-grid {
                grid-template-columns: repeat(2, minmax(0, 1fr));
            }
        }
        @media (max-width: 640px) {
            .categories-grid {
                grid-template-columns: 1fr;
            }
        }.home-page .online-status .pulse {
            background: var(--success);
            box-shadow: 0 0 10px color-mix(in srgb, var(--success) 60%, transparent);
        }
        
        .portal-btn, .discord-btn {
            font-family: var(--font-body);
            border-radius: var(--radius);
        }
        .portal-btn {
            border: 1px solid var(--border);
            background: transparent;
        }
        .portal-btn:hover {
            border-color: var(--accent-border);
            background: var(--accent-muted);
        }
        .discord-btn:hover {
            opacity: 0.9;
        }

/* NOTE: บล็อกนี้เคยประกาศ token ซ้ำกับ design-tokens.css และตั้ง
   `body { font-family: var(--font-display) }` — เนื่องจาก home.css ถูกต่อท้ายสุดใน
   site.css ที่ "ทุกหน้า" โหลด มันจึงบังคับ Inter ให้ทั้งเว็บ ทับกฎใน style.css
   เหลือไว้เฉพาะตัวแปรที่ style.css ไม่มี — ห้ามประกาศ token หรือกฎ body ซ้ำที่นี่ */
:root {
      --line: color-mix(in srgb, var(--fg) 14%, transparent);
      --surface: var(--bg-surface);
      --surface-strong: #1b1c20;
      --page: min(1180px, calc(100% - 40px));
    }
    html { scroll-behavior: smooth; background: var(--bg); }
    body { min-width: 320px; padding-right: env(safe-area-inset-right); padding-left: env(safe-area-inset-left); }
    a { color: inherit; text-decoration: none; }
    button { font: inherit; }
    .shell { width: var(--page); margin: 0 auto; }
    .skip-link { position: fixed; z-index: 100; top: 10px; left: 10px; transform: translateY(-150%); padding: 10px 14px; border-radius: var(--radius); background: var(--fg); color: var(--bg); font-weight: 700; transition: transform .18s ease; }
    .skip-link:focus { transform: translateY(0); }
    .site-header { position: sticky; z-index: 50; top: 0; border-bottom: 1px solid var(--line); background: var(--bg); }
    .nav { min-height: 72px; display: flex; align-items: center; justify-content: space-between; gap: 20px; }
    .brand { display: inline-flex; align-items: center; gap: 10px; font-size: 15px; font-weight: 800; letter-spacing: -.03em; }
    .brand-mark { width: 31px; height: 31px; display: grid; place-items: center; border: 1px solid var(--line); border-radius: var(--radius); background: var(--surface); color: var(--accent); }
    .brand-mark i { font-size: 14px; }
    .nav-links { display: flex; align-items: center; gap: 3px; }
    .nav-links a { min-height: 42px; display: inline-flex; align-items: center; padding: 0 10px; border: 1px solid transparent; border-radius: var(--radius); color: var(--muted); font-size: 13px; font-weight: 600; transition: color .18s ease, background .18s ease, border-color .18s ease; }
    .nav-links a:hover, .nav-links a:focus-visible { border-color: var(--line); background: var(--surface); color: var(--fg); outline: none; }
    .nav-actions { display: flex; align-items: center; gap: 11px; }
    .server-status { display: inline-flex; align-items: center; gap: 8px; color: var(--muted); font-family: var(--font-mono); font-size: 11px; white-space: nowrap; }
    [data-status-dot] { width: 8px; height: 8px; flex: 0 0 auto; border-radius: 50%; background: var(--accent); box-shadow: 0 0 0 4px color-mix(in srgb, var(--accent) 16%, transparent); }
    [data-status-dot="offline"] { background: var(--muted); box-shadow: none; }
    .button { min-height: 44px; display: inline-flex; align-items: center; justify-content: center; gap: 8px; padding: 0 15px; border: 1px solid var(--line); border-radius: var(--radius); color: var(--fg); font-size: 13px; font-weight: 700; transition: transform .18s ease, background .18s ease, border-color .18s ease; }
    .button:hover, .button:focus-visible { transform: translateY(-2px); border-color: var(--accent); outline: none; }
    .button-primary { border-color: var(--accent); background: var(--accent); box-shadow: 0 10px 24px color-mix(in srgb, var(--accent) 28%, transparent); }
    .button-primary:hover, .button-primary:focus-visible { border-color: var(--accent-hover); background: var(--accent-hover); }
    .button-secondary { background: var(--bg-surface); }
    .menu-toggle { display: none; width: 44px; height: 44px; border: 1px solid var(--line); border-radius: var(--radius); background: var(--surface); color: var(--fg); cursor: pointer; }
    .hero { position: relative; overflow: hidden; padding: clamp(62px, 10vw, 132px) 0 clamp(62px, 8vw, 108px); }
    .hero::after { position: absolute; right: max(0px, calc((100vw - 1180px) / 2)); bottom: 0; width: min(44vw, 540px); height: min(44vw, 540px); border: 1px solid var(--line); background: linear-gradient(90deg, color-mix(in srgb, var(--accent) 15%, transparent) 1px, transparent 1px), linear-gradient(color-mix(in srgb, var(--accent) 15%, transparent) 1px, transparent 1px); background-size: 34px 34px; content: ""; mask-image: linear-gradient(135deg, transparent 18%, var(--fg)); pointer-events: none; }
    .hero-grid { position: relative; z-index: 1; display: grid; grid-template-columns: minmax(0, 1.1fr) minmax(310px, .9fr); gap: clamp(38px, 7vw, 90px); align-items: end; }
    .overline { margin: 0 0 18px; color: var(--accent); font-family: var(--font-mono); font-size: 11px; font-weight: 600; letter-spacing: .12em; text-transform: uppercase; }
    h1, h2, h3, p { margin-top: 0; }
    h1 { max-width: 760px; margin-bottom: 23px; font-size: clamp(48px, 7vw, 86px); font-weight: 800; line-height: .98; letter-spacing: -.065em; text-shadow: 5px 5px 0 color-mix(in srgb, var(--accent) 22%, transparent); }
    h1 span { color: var(--muted); }
    .hero-copy { max-width: 56ch; margin-bottom: 30px; color: var(--muted); font-size: 17px; }
    .hero-actions { display: flex; flex-wrap: wrap; gap: 10px; }
    .server-card { position: relative; overflow: hidden; padding: 28px; border: 1px solid var(--border); border-radius: var(--radius); background: var(--bg-surface); box-shadow: 8px 8px 0 color-mix(in srgb, var(--accent) 25%, transparent); }
    .server-card::before { position: absolute; inset: 0; background-image: linear-gradient(90deg, color-mix(in srgb, var(--fg) 7%, transparent) 1px, transparent 1px), linear-gradient(color-mix(in srgb, var(--fg) 7%, transparent) 1px, transparent 1px); background-size: 24px 24px; content: ""; opacity: .7; pointer-events: none; }
    .server-card > * { position: relative; }
    .card-kicker { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 34px; color: var(--muted); font-family: var(--font-mono); font-size: 11px; letter-spacing: .07em; text-transform: uppercase; }
    .card-kicker .server-status { font-size: 10px; }
    .ip-box { width: 100%; display: flex; align-items: center; justify-content: space-between; gap: 14px; padding: 19px; border: 1px solid color-mix(in srgb, var(--accent) 58%, var(--border)); border-radius: var(--radius); background: color-mix(in srgb, var(--accent) 13%, var(--bg)); box-shadow: inset 0 0 24px color-mix(in srgb, var(--accent) 14%, transparent), 0 10px 26px color-mix(in srgb, var(--accent) 12%, transparent); color: var(--fg); cursor: pointer; text-align: left; transition: border-color .18s ease, transform .18s ease, box-shadow .18s ease; }
    .ip-box:hover, .ip-box:focus-visible { border-color: var(--accent-hover); box-shadow: inset 0 0 28px color-mix(in srgb, var(--accent) 19%, transparent), 0 13px 30px color-mix(in srgb, var(--accent) 20%, transparent); transform: translateY(-2px); outline: none; }
    .ip-copy { display: grid; gap: 3px; }
    .ip-copy strong { font-family: var(--font-mono); font-size: clamp(18px, 2.5vw, 25px); font-weight: 600; letter-spacing: -.055em; }
    .ip-copy span { color: var(--muted); font-size: 11px; }
    .ip-box i { color: var(--accent); font-size: 17px; }
    .platforms { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 14px; }
    .badge { display: inline-flex; align-items: center; min-height: 29px; padding: 0 9px; border: 1px solid var(--line); border-radius: var(--radius); background: var(--surface); color: var(--muted); font-family: var(--font-mono); font-size: 10px; }
    .server-metrics { display: grid; grid-template-columns: repeat(2, 1fr); gap: 1px; margin-top: 24px; border-top: 1px solid var(--line); }
    .metric { padding-top: 15px; }
    .metric strong { display: block; font-family: var(--font-mono); font-size: 20px; font-weight: 500; letter-spacing: -.05em; }
    .metric span { display: block; margin-top: 2px; color: var(--muted); font-size: 11px; }
    .stats { border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); background: color-mix(in srgb, var(--fg) 3%, transparent); }
    .stats-grid { display: grid; grid-template-columns: repeat(4, 1fr); }
    .stat { min-height: 142px; display: flex; flex-direction: column; justify-content: center; padding: 22px; border-right: 1px solid var(--line); }
    .stat:first-child { border-left: 1px solid var(--line); }
    .stat::before { margin-bottom: 10px; color: var(--accent); font-family: "Font Awesome 6 Free"; font-size: 14px; font-weight: 900; }
    .stat:nth-child(1)::before { content: "\f017"; }
    .stat:nth-child(2)::before { content: "\f00c"; }
    .stat:nth-child(3)::before { content: "\f0c0"; }
    .stat:nth-child(4)::before { content: "\f017"; }
    .stat strong { font-family: var(--font-mono); font-size: 32px; font-weight: 500; letter-spacing: -.07em; }
    .stat span { margin-top: 4px; color: var(--muted); font-size: 12px; }
    .section { padding: clamp(65px, 9vw, 112px) 0; }
    .section-heading { display: grid; grid-template-columns: minmax(0, 1fr) minmax(240px, .62fr); gap: 28px; align-items: end; margin-bottom: 34px; }
    .section-heading h2, .faq-intro h2 { margin-bottom: 0; font-size: clamp(32px, 4.3vw, 54px); font-weight: 800; line-height: 1.02; letter-spacing: -.05em; }
    .section-heading p { max-width: 42ch; margin: 0 0 3px; color: var(--muted); font-size: 15px; }
    .feature-grid { display: grid; grid-template-columns: repeat(3, 1fr); border-top: 1px solid var(--line); border-left: 1px solid var(--line); }
    .feature { min-height: 240px; display: flex; flex-direction: column; padding: 23px; border-right: 1px solid var(--line); border-bottom: 1px solid var(--line); background: color-mix(in srgb, var(--bg) 62%, transparent); transition: background .18s ease; }
    .feature:hover { background: var(--surface); }
    .feature-top { display: flex; align-items: center; justify-content: space-between; margin-bottom: auto; }
    .feature i { color: var(--accent); font-size: 18px; }
    .feature-index { color: var(--muted); font-family: var(--font-mono); font-size: 11px; }
    .feature h3 { margin: 34px 0 8px; font-size: 17px; font-weight: 750; letter-spacing: -.025em; }
    .feature p { margin: 0; color: var(--muted); font-size: 13px; line-height: 1.6; }
    .faq-section { border-top: 1px solid var(--line); background: color-mix(in srgb, var(--fg) 3%, transparent); }
    .faq-layout { display: grid; grid-template-columns: .76fr 1.24fr; gap: clamp(42px, 9vw, 110px); }
    .faq-intro p { max-width: 32ch; margin: 16px 0 0; color: var(--muted); font-size: 15px; }
    .faq-list { border-top: 1px solid var(--line); }
    details { display: grid; grid-template-rows: 68px 0fr; border-bottom: 1px solid var(--line); transition: grid-template-rows .24s cubic-bezier(.23, 1, .32, 1); }
    details[open] { grid-template-rows: 68px 1fr; }
    summary { min-height: 68px; display: flex; align-items: center; justify-content: space-between; gap: 22px; cursor: pointer; list-style: none; font-size: 15px; font-weight: 650; }
    summary::-webkit-details-marker { display: none; }
    summary::after { content: "+"; color: var(--muted); font-family: var(--font-mono); font-size: 21px; font-weight: 400; transition: color .2s ease, transform .24s cubic-bezier(.23, 1, .32, 1); }
    details[open] summary::after { color: var(--accent); transform: rotate(45deg); }
    details p { min-height: 0; max-width: 62ch; margin: -1px 44px 20px 0; overflow: hidden; color: var(--muted); font-size: 14px; opacity: 0; transform: translateY(-6px); transition: opacity .18s ease, transform .24s cubic-bezier(.23, 1, .32, 1); }
    details[open] p { opacity: 1; transform: translateY(0); }
    .final-section { padding-top: 0; }
    .final-cta { position: relative; overflow: hidden; display: grid; grid-template-columns: 1fr auto; gap: 30px; align-items: center; padding: clamp(28px, 4vw, 48px); border: 1px solid var(--line); border-radius: var(--radius); background: var(--surface); box-shadow: 8px 8px 0 color-mix(in srgb, var(--accent) 22%, transparent); }
    .final-cta::after { position: absolute; right: -32px; bottom: -32px; width: 150px; height: 150px; border: 1px solid color-mix(in srgb, var(--accent) 45%, transparent); content: ""; transform: rotate(45deg); }
    .final-cta > * { position: relative; z-index: 1; }
    .final-cta h2 { margin-bottom: 8px; font-size: clamp(30px, 4vw, 48px); font-weight: 800; line-height: 1.02; letter-spacing: -.05em; }
    .final-cta p { max-width: 54ch; margin: 0; color: var(--muted); font-size: 15px; }
    .cta-actions { display: flex; flex-wrap: wrap; justify-content: flex-end; gap: 10px; }
    .footer-row { display: flex; align-items: flex-start; justify-content: space-between; gap: 28px; }
    .footer-brand { color: var(--fg); font-weight: 700; }
    .footer-brand span { color: var(--muted); font-family: var(--font-mono); font-size: 10px; font-weight: 400; }
    .footer-links { display: flex; flex-wrap: wrap; justify-content: flex-end; gap: 14px; }
    .footer-links a:hover, .footer-links a:focus-visible { color: var(--fg); outline: none; }
    @media (max-width: 980px) {
      .nav-actions .button { display: none; }
      .hero-grid, .faq-layout { grid-template-columns: 1fr; }
      .hero-grid { gap: 42px; }
      .server-card { max-width: 620px; }
      .section-heading { grid-template-columns: 1fr; }
      .section-heading p { margin: 0; }
    }
    @media (max-width: 680px) {
      :root { --page: min(100% - 28px, 1180px); }
      .nav { min-height: 64px; }
      .server-status { display: none; }
      .hero { padding-top: 58px; }
      h1 { font-size: clamp(43px, 13.5vw, 66px); }
      .hero-copy { font-size: 16px; }
      .server-card { padding: 18px; }
      .stats-grid { grid-template-columns: repeat(2, 1fr); }
      .stat:nth-child(3) { border-left: 1px solid var(--line); }
      .stat { min-height: 104px; padding: 17px; border-bottom: 1px solid var(--line); }
      .feature-grid { grid-template-columns: 1fr; }
      .feature { min-height: 190px; }
      .feature h3 { margin-top: 25px; }
      .final-cta { grid-template-columns: 1fr; }
      .cta-actions { justify-content: flex-start; }
      .cta-actions .button { width: 100%; }
      .footer-row { flex-direction: column; }
      .footer-links { justify-content: flex-start; }
    }
    @media (prefers-reduced-motion: reduce) { *, *::before, *::after { scroll-behavior: auto; transition: none; } }

     html[data-reduced-motion="true"] .category-card,
     html[data-reduced-motion="true"] .category-card .card-image img { transition: none; }

/* ═══ Classes กลาง (มาตรฐานหน้าแรก — ใช้แทน inline style) ══════════════ */

/* Section header: eyebrow + h2 + sub */
.sec-head { text-align: center; margin-bottom: 32px; }
.sec-eyebrow { display: inline-block; color: var(--accent-hover); text-transform: uppercase; font-size: 0.75rem; font-weight: 800; letter-spacing: 0.2em; }
.sec-head h2 { font-size: 2rem; font-weight: 800; margin: 8px 0; }
.sec-head p { color: var(--muted); max-width: 560px; margin: 0 auto; }

/* Server stats bar */
.stats-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 1px; border: 1px solid var(--border); border-radius: var(--radius); overflow: hidden; background: var(--border); }
.stat-cell { background: var(--bg); text-align: center; padding: 28px 16px; }
.stat-value { font-family: var(--font-mono); font-size: 28px; font-weight: 700; color: var(--accent); }
.stat-label { color: var(--muted); font-size: 11px; text-transform: uppercase; margin-top: 4px; }
@media (max-width: 640px) { .stats-grid { grid-template-columns: repeat(2, 1fr); } }

/* FAQ */
.faq-item { border: 1px solid var(--border); border-radius: var(--radius); background: var(--bg-surface); overflow: hidden; }
.faq-summary { padding: 16px 20px; font-weight: 600; cursor: pointer; display: flex; align-items: center; gap: 12px; list-style: none; }
.faq-summary::-webkit-details-marker { display: none; }
.faq-summary i { color: var(--accent); font-size: 10px; }
.faq-body { padding: 0 20px 16px; color: var(--muted); font-size: 14px; line-height: 1.7; border-top: 1px solid var(--border); padding-top: 12px; }

/* Code chip */
.code-chip { background: var(--bg); padding: 2px 8px; border-radius: 4px; font-family: var(--font-mono); font-size: 0.9em; }

/* Utility spacing */
.mt-40 { margin-top: 40px; }
.mt-60 { margin-top: 60px; }

/* Hero card (หน้าเว็บสาธารณะ) */
.hero-card { display: flex; align-items: center; justify-content: space-between; gap: 32px; }
.hero-card .hero-info { flex: 1; min-width: 0; }
.hero-card .hero-character { flex: 0 0 auto; }
.hero-card .hero-character img { width: 260px; height: auto; object-fit: contain; filter: drop-shadow(0 10px 20px rgba(0,0,0,0.5)); }
.btn-hero {
  display: inline-flex; align-items: center; gap: 8px;
  background: var(--accent); color: #fff;
  border: none; cursor: pointer;
  border-radius: var(--radius);
  padding: 12px 24px; font-weight: 700; font-size: 1rem;
  transition: opacity 0.2s ease;
}
.btn-hero:hover { opacity: 0.9; }
