/* ═══════════════════════════════════
   SHARED STYLES — btcbuyput
═══════════════════════════════════ */

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

:root {
  /* Base palette */
  --bg-deep: #0A0705;
  --bg-warm: #1A110A;
  --parchment: #D4B896;
  --parchment-mid: #C4A882;
  --parchment-dark: #A8895E;
  --parchment-light: #E8D5B5;
  --blood-red: #C62828;
  --crimson: #8B1A1A;
  --burnt-orange: #D4722A;
  --amber: #D4A020;
  --gold: #E8B830;
  --text-light: #E8D5B5;
  --text-muted: #A89478;
  --ink: #1A0E07;

  /* Theme-semantic (dark defaults) */
  --surface-card: rgba(26, 17, 10, 0.6);
  --surface-card-border: rgba(139, 115, 85, 0.15);
  --shadow: rgba(0, 0, 0, 0.4);
}

/* ── Light theme ── */
html[data-theme="light"] {
  --bg-deep: #F5EDE0;
  --bg-warm: #EBE0D0;
  --parchment-light: #2A1E12;
  --text-light: #3A2E22;
  --text-muted: #7A6B5A;
  --parchment: #4A3E32;
  --parchment-mid: #5A4E42;
  --parchment-dark: #6A5E52;
  --surface-card: rgba(255, 255, 255, 0.65);
  --surface-card-border: rgba(180, 160, 130, 0.3);
  --shadow: rgba(120, 100, 70, 0.12);
}

body {
  background: var(--bg-deep);
  color: var(--text-light);
  font-family: 'Noto Serif SC', 'Songti SC', serif;
  line-height: 1.6;
  overflow-x: hidden;
  transition: background-color 0.3s, color 0.3s;
}

.site-nav,
.nav-toggle,
.theme-toggle,
.section-title,
.footer { transition: background-color 0.3s, color 0.3s, border-color 0.3s; }

/* Grain overlay */
body::before {
  content: '';
  position: fixed;
  inset: 0;
  background: repeating-conic-gradient(#D4B896 0.0001%, #0A0705 0.0003%) 50% 50% / 600px 600px;
  opacity: 0.025;
  pointer-events: none;
  z-index: 9999;
}

html[data-theme="light"] body::before {
  background: repeating-conic-gradient(#A8895E 0.0001%, #F5EDE0 0.0003%) 50% 50% / 600px 600px;
  opacity: 0.018;
}

.container {
  max-width: 900px;
  margin: 0 auto;
  padding: 0 32px;
}

/* ── Divider ── */
.divider {
  border: none;
  height: 2px;
  max-width: 400px;
  margin: 0 auto;
  background: linear-gradient(to right, transparent, var(--burnt-orange) 30%, var(--blood-red) 50%, var(--burnt-orange) 70%, transparent);
  opacity: 0.6;
}

html[data-theme="light"] .divider { opacity: 0.4; }

/* ── Section base ── */
.panel {
  padding: 80px 0;
  position: relative;
}

.section-label {
  font-family: 'Noto Serif SC', serif;
  font-weight: 700;
  font-size: 14px;
  color: var(--burnt-orange);
  letter-spacing: 6px;
  text-transform: uppercase;
  margin-bottom: 12px;
  opacity: 0.7;
}

.section-title {
  font-family: 'Noto Serif SC', serif;
  font-weight: 900;
  font-size: 32px;
  color: var(--parchment-light);
  margin-bottom: 48px;
  position: relative;
  display: inline-block;
}

.section-title::after {
  content: '';
  position: absolute;
  bottom: -8px;
  left: 0;
  width: 60px;
  height: 3px;
  background: var(--blood-red);
}

/* ── English text ── */
.en {
  font-family: 'Inter', sans-serif;
  font-weight: 600;
  font-style: normal;
  letter-spacing: 0;
}

/* ── Footer ── */
.footer {
  text-align: center;
  padding: 40px 0 60px;
  font-size: 13px;
  color: rgba(168, 148, 120, 0.5);
  letter-spacing: 1px;
}

html[data-theme="light"] .footer { color: rgba(100, 85, 65, 0.5); }

.footer a {
  color: var(--text-muted);
  text-decoration: none;
}

/* ═══════════════════════════════════
   NAV TOGGLE
═══════════════════════════════════ */
.site-nav {
  position: sticky;
  top: 0;
  z-index: 1000;
  background: rgba(10, 7, 5, 0.85);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid rgba(139, 115, 85, 0.1);
  padding: 12px 0;
}

html[data-theme="light"] .site-nav {
  background: rgba(245, 237, 224, 0.9);
  border-bottom-color: rgba(180, 160, 130, 0.25);
}

.nav-inner {
  max-width: 900px;
  margin: 0 auto;
  padding: 0 32px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

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

.nav-brand {
  font-family: 'Noto Serif SC', serif;
  font-weight: 900;
  font-size: 18px;
  color: var(--parchment);
  text-decoration: none;
}

.nav-toggle {
  display: flex;
  background: rgba(26, 17, 10, 0.6);
  border: 1px solid rgba(139, 115, 85, 0.15);
  border-radius: 6px;
  padding: 3px;
  gap: 2px;
}

html[data-theme="light"] .nav-toggle {
  background: rgba(235, 224, 208, 0.8);
  border-color: rgba(180, 160, 130, 0.25);
}

.nav-toggle a {
  font-family: 'Noto Serif SC', serif;
  font-weight: 700;
  font-size: 14px;
  color: var(--text-muted);
  text-decoration: none;
  padding: 6px 16px;
  border-radius: 4px;
  transition: all 0.2s;
  letter-spacing: 2px;
}

.nav-toggle a:hover {
  color: var(--parchment-light);
}

.nav-toggle a.active {
  background: rgba(212, 114, 42, 0.2);
  color: var(--parchment-light);
  border: 1px solid rgba(212, 114, 42, 0.25);
}

html[data-theme="light"] .nav-toggle a.active {
  background: rgba(212, 114, 42, 0.12);
  border-color: rgba(212, 114, 42, 0.18);
}

/* ── Theme Toggle Button ── */
.theme-toggle {
  background: none;
  border: 1px solid rgba(139, 115, 85, 0.15);
  border-radius: 6px;
  padding: 6px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text-muted);
  transition: color 0.2s, border-color 0.2s;
}

.theme-toggle:hover {
  color: var(--parchment-light);
  border-color: rgba(139, 115, 85, 0.3);
}

html[data-theme="light"] .theme-toggle {
  border-color: rgba(180, 160, 130, 0.25);
}

html[data-theme="light"] .theme-toggle:hover {
  border-color: rgba(180, 160, 130, 0.5);
}

.theme-toggle .icon-sun { display: none; }
.theme-toggle .icon-moon { display: block; }
html[data-theme="light"] .theme-toggle .icon-sun { display: block; }
html[data-theme="light"] .theme-toggle .icon-moon { display: none; }

/* ═══════════════════════════════════
   MOBILE RESPONSIVE
═══════════════════════════════════ */
@media (max-width: 640px) {
  .container { padding: 0 20px; }
  .panel { padding: 56px 0; }
  .section-title { font-size: 26px; margin-bottom: 32px; }
  .nav-inner { padding: 0 16px; }
  .nav-brand { font-size: 16px; }
  .nav-toggle a { font-size: 13px; padding: 5px 12px; letter-spacing: 1px; }
  .nav-right { gap: 6px; }
  .theme-toggle { padding: 5px; }
  .theme-toggle svg { width: 16px; height: 16px; }
  .footer { font-size: 12px; padding: 32px 0 48px; }
}
