@import url('https://fonts.googleapis.com/css2?family=Cormorant+Garamond:ital,wght@0,300;0,400;0,500;0,600;1,300;1,400&family=Syne:wght@400;500;600;700;800&family=DM+Sans:ital,opsz,wght@0,9..40,300;0,9..40,400;0,9..40,500;1,9..40,300&display=swap');

/* ═══════════════════════════════════════
   VOID — Token System
   Light: White / Pearl / Silver Luxury
   Dark:  Deep Navy / Slate / Midnight
═══════════════════════════════════════ */

:root {
  /* ── Light Mode (default) ── */
  --bg:           #F5F4F2;
  --bg-2:         #EDECEA;
  --bg-3:         #E4E2DF;
  --surface:      #FFFFFF;
  --surface-2:    #FAFAF9;
  --surface-3:    #F0EFED;
  --border:       rgba(0,0,0,0.07);
  --border-2:     rgba(0,0,0,0.12);

  --text:         #0E0E0E;
  --text-sec:     #5A5A5A;
  --text-muted:   #9A9896;
  --text-faint:   #C4C2BF;

  --accent:       #1A1A2E;
  --accent-2:     #16213E;
  --accent-soft:  rgba(26,26,46,0.08);
  --accent-glow:  rgba(26,26,46,0.15);

  --gold:         #C9A84C;
  --gold-soft:    rgba(201,168,76,0.12);

  --success:      #2D6A4F;
  --error:        #9B2226;
  --warning:      #CA6702;

  --shadow-sm:    0 1px 3px rgba(0,0,0,0.06), 0 1px 2px rgba(0,0,0,0.04);
  --shadow-md:    0 4px 16px rgba(0,0,0,0.08), 0 2px 6px rgba(0,0,0,0.05);
  --shadow-lg:    0 12px 40px rgba(0,0,0,0.12), 0 4px 12px rgba(0,0,0,0.06);
  --shadow-card:  0 2px 8px rgba(0,0,0,0.06), 0 8px 32px rgba(0,0,0,0.08), inset 0 1px 0 rgba(255,255,255,0.9);

  --noise-opacity: 0.025;
  --sheen-opacity: 0.6;

  /* Shared */
  --font-display: 'Cormorant Garamond', Georgia, serif;
  --font-ui:      'Syne', system-ui, sans-serif;
  --font-body:    'DM Sans', system-ui, sans-serif;

  --radius:       18px;
  --radius-sm:    10px;
  --radius-xs:    6px;
  --radius-pill:  999px;
  --pad-h:        16px;
  --nav-h:        72px;
  --ease-out:     cubic-bezier(0.16, 1, 0.3, 1);
  --ease-spring:  cubic-bezier(0.34, 1.56, 0.64, 1);
}

/* ── Dark Mode ── */
[data-theme="dark"] {
  --bg:           #0B0F1A;
  --bg-2:         #0F1422;
  --bg-3:         #141928;
  --surface:      #141928;
  --surface-2:    #1A2035;
  --surface-3:    #202840;
  --border:       rgba(255,255,255,0.06);
  --border-2:     rgba(255,255,255,0.1);

  --text:         #EEF0F4;
  --text-sec:     #8A9BB8;
  --text-muted:   #4A5A78;
  --text-faint:   #2A3550;

  --accent:       #7EB8F7;
  --accent-2:     #5A9FE8;
  --accent-soft:  rgba(126,184,247,0.1);
  --accent-glow:  rgba(126,184,247,0.2);

  --gold:         #D4AF60;
  --gold-soft:    rgba(212,175,96,0.1);

  --success:      #52B788;
  --error:        #E07070;
  --warning:      #E9A84B;

  --shadow-sm:    0 1px 3px rgba(0,0,0,0.3), 0 1px 2px rgba(0,0,0,0.2);
  --shadow-md:    0 4px 16px rgba(0,0,0,0.4), 0 2px 6px rgba(0,0,0,0.2);
  --shadow-lg:    0 12px 40px rgba(0,0,0,0.5), 0 4px 12px rgba(0,0,0,0.3);
  --shadow-card:  0 2px 8px rgba(0,0,0,0.3), 0 8px 32px rgba(0,0,0,0.4), inset 0 1px 0 rgba(255,255,255,0.05);

  --noise-opacity: 0.04;
  --sheen-opacity: 0.08;
}

/* ══════ RESET ══════ */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html {
  font-size: 16px;
  -webkit-text-size-adjust: 100%;
  height: 100%;
  overflow: hidden;
}
body {
  font-family: var(--font-body);
  background: var(--bg);
  color: var(--text);
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow: hidden;
  height: 100vh;
  transition: background 400ms ease, color 300ms ease;
}
button { font-family: var(--font-body); cursor: pointer; border: none; outline: none; background: none; color: inherit; -webkit-tap-highlight-color: transparent; }
input, textarea { font-family: var(--font-body); outline: none; border: none; background: none; color: var(--text); resize: none; }
a { text-decoration: none; color: inherit; }

/* ══════ LAYOUT ══════ */
.phone-shell {
  width: 390px;
  height: 844px;
  position: relative;
  overflow: hidden;
  background: var(--bg);
  transition: background 400ms ease;
}

.screen {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  opacity: 0;
  pointer-events: none;
  transition: opacity 220ms ease;
  background: var(--bg);
}

.screen.active { opacity: 1; pointer-events: all; }

.safe-top    { height: 52px; flex-shrink: 0; }
.safe-bottom { height: 16px; flex-shrink: 0; }

.scroll-area {
  flex: 1;
  overflow-y: auto;
  overflow-x: hidden;
  -webkit-overflow-scrolling: touch;
}
.scroll-area::-webkit-scrollbar { display: none; }

/* ══════ NOISE TEXTURE OVERLAY ══════ */
.noise-layer {
  position: absolute;
  inset: 0;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 256 256' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)' opacity='1'/%3E%3C/svg%3E");
  opacity: var(--noise-opacity);
  pointer-events: none;
  z-index: 999;
  mix-blend-mode: multiply;
}
[data-theme="dark"] .noise-layer { mix-blend-mode: screen; }

/* ══════ LUXURY CARD ══════ */
.card {
  background: var(--surface);
  border-radius: var(--radius);
  box-shadow: var(--shadow-card);
  border: 1px solid var(--border);
  position: relative;
  overflow: hidden;
  transition: transform 250ms var(--ease-out), box-shadow 250ms ease;
}

.card::before {
  content: '';
  position: absolute;
  top: 0; left: 0; right: 0;
  height: 1px;
  background: linear-gradient(90deg, transparent, rgba(255,255,255,var(--sheen-opacity)), transparent);
  pointer-events: none;
}

.card:active {
  transform: scale(0.985);
  box-shadow: var(--shadow-sm);
}

/* Shiny shimmer card variant */
.card-shiny {
  background: linear-gradient(145deg, var(--surface) 0%, var(--surface-2) 50%, var(--surface) 100%);
}

.card-shiny::after {
  content: '';
  position: absolute;
  top: -50%; left: -50%;
  width: 200%; height: 200%;
  background: linear-gradient(
    105deg,
    transparent 40%,
    rgba(255,255,255,0.12) 50%,
    transparent 60%
  );
  transform: translateX(-100%);
  transition: transform 600ms var(--ease-out);
  pointer-events: none;
}

.card-shiny:hover::after {
  transform: translateX(100%);
}

/* ══════ BOTTOM NAV ══════ */
.bottom-nav {
  height: var(--nav-h);
  background: var(--surface);
  border-top: 1px solid var(--border);
  display: flex;
  align-items: center;
  justify-content: space-around;
  padding: 0 8px 12px;
  flex-shrink: 0;
  position: relative;
}

.bottom-nav::before {
  content: '';
  position: absolute;
  top: 0; left: 16px; right: 16px;
  height: 1px;
  background: linear-gradient(90deg, transparent, var(--border-2), transparent);
}

.nav-tab {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 4px;
  padding: 8px 20px;
  border-radius: 12px;
  color: var(--text-muted);
  transition: all 200ms ease;
  position: relative;
}

.nav-tab svg { width: 22px; height: 22px; stroke-width: 1.5; }
.nav-tab .nav-label { font-family: var(--font-ui); font-size: 9px; font-weight: 600; letter-spacing: 0.08em; text-transform: uppercase; }

.nav-tab.active { color: var(--accent); }

.nav-tab.active::after {
  content: '';
  position: absolute;
  top: 0;
  left: 50%; transform: translateX(-50%);
  width: 20px; height: 2px;
  background: var(--accent);
  border-radius: 0 0 2px 2px;
}

.nav-tab:active { transform: scale(0.9); }

/* ══════ BUTTONS ══════ */
.btn-primary {
  width: 100%;
  padding: 15px 20px;
  background: var(--accent);
  color: var(--surface);
  font-family: var(--font-ui);
  font-size: 13px;
  font-weight: 600;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  border-radius: var(--radius-sm);
  transition: transform 150ms, opacity 150ms, box-shadow 200ms;
  position: relative;
  overflow: hidden;
  box-shadow: 0 4px 20px var(--accent-glow);
}

[data-theme="dark"] .btn-primary {
  color: var(--bg);
}

.btn-primary::before {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(to bottom, rgba(255,255,255,0.12), transparent);
  pointer-events: none;
}

.btn-primary:active { transform: scale(0.97); opacity: 0.9; }
.btn-primary:disabled { opacity: 0.35; cursor: not-allowed; box-shadow: none; }

.btn-ghost {
  padding: 10px 16px;
  border-radius: var(--radius-xs);
  color: var(--text-sec);
  font-size: 14px;
  font-weight: 500;
  transition: background 150ms, color 150ms;
}
.btn-ghost:hover { background: var(--surface-3); color: var(--text); }

.btn-outline {
  padding: 12px 20px;
  border-radius: var(--radius-sm);
  border: 1px solid var(--border-2);
  color: var(--text);
  font-family: var(--font-ui);
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  background: var(--surface);
  transition: all 200ms;
}
.btn-outline:hover { border-color: var(--accent); color: var(--accent); }

/* ══════ INPUTS ══════ */
.field {
  background: var(--surface-3);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 14px 16px;
  font-size: 15px;
  color: var(--text);
  width: 100%;
  transition: border-color 200ms, box-shadow 200ms;
}
.field:focus {
  border-color: var(--accent);
  box-shadow: 0 0 0 3px var(--accent-soft);
}
.field::placeholder { color: var(--text-faint); }

/* ══════ PILLS ══════ */
.pill {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 5px 12px;
  border-radius: var(--radius-pill);
  font-size: 11px;
  font-weight: 600;
  font-family: var(--font-ui);
  letter-spacing: 0.06em;
  text-transform: uppercase;
  background: var(--surface-3);
  color: var(--text-muted);
  border: 1px solid var(--border);
}

.pill.accent {
  background: var(--accent-soft);
  color: var(--accent);
  border-color: var(--accent-soft);
}

/* ══════ MOOD SCROLL ══════ */
.mood-scroll {
  display: flex;
  gap: 8px;
  overflow-x: auto;
  padding: 4px 2px;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none;
}
.mood-scroll::-webkit-scrollbar { display: none; }

.mood-chip {
  flex-shrink: 0;
  padding: 8px 16px;
  border-radius: var(--radius-pill);
  background: var(--surface);
  color: var(--text-sec);
  font-size: 12px;
  font-weight: 500;
  border: 1px solid var(--border-2);
  transition: all 180ms ease;
  white-space: nowrap;
  box-shadow: var(--shadow-sm);
}

.mood-chip.active {
  background: var(--accent);
  color: var(--surface);
  border-color: var(--accent);
  box-shadow: 0 2px 12px var(--accent-glow);
}
[data-theme="dark"] .mood-chip.active { color: var(--bg); }

/* ══════ TOGGLE SWITCH ══════ */
.toggle {
  width: 48px; height: 26px;
  border-radius: var(--radius-pill);
  background: var(--bg-3);
  border: 1px solid var(--border-2);
  padding: 3px;
  display: flex;
  align-items: center;
  transition: background 220ms, border-color 220ms;
  cursor: pointer;
  flex-shrink: 0;
}
.toggle.on { background: var(--accent); border-color: var(--accent); }
.toggle-knob {
  width: 18px; height: 18px;
  border-radius: 50%;
  background: var(--surface);
  box-shadow: 0 1px 4px rgba(0,0,0,0.15);
  transition: transform 220ms var(--ease-spring);
}
.toggle.on .toggle-knob { transform: translateX(22px); }

/* ══════ THEME TOGGLE (top bar) ══════ */
.theme-toggle-btn {
  width: 36px; height: 36px;
  border-radius: 50%;
  background: var(--surface-3);
  border: 1px solid var(--border-2);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text-sec);
  transition: all 200ms;
  box-shadow: var(--shadow-sm);
}
.theme-toggle-btn svg { width: 16px; height: 16px; }
.theme-toggle-btn:active { transform: scale(0.9); }

/* ══════ DIVIDER ══════ */
.divider {
  height: 1px;
  background: var(--border);
  flex-shrink: 0;
  margin: 0;
}

/* ══════ REACTION BUTTONS ══════ */
.reaction-btn {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 3px;
  padding: 8px 4px;
  border-radius: 10px;
  min-width: 48px;
  transition: all 150ms;
}
.reaction-btn .rxn-icon { font-size: 22px; line-height: 1; }
.reaction-btn .rxn-count {
  font-size: 10px;
  font-weight: 600;
  color: var(--text-muted);
  font-family: var(--font-ui);
  letter-spacing: 0.04em;
}
.reaction-btn.active { background: var(--accent-soft); }
.reaction-btn.active .rxn-count { color: var(--accent); }

@keyframes rxnPop {
  0%   { transform: scale(1); }
  35%  { transform: scale(0.88); }
  65%  { transform: scale(1.18); }
  100% { transform: scale(1); }
}

/* ══════ VOTE BUTTONS ══════ */
.vote-btn {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  padding: 10px;
  border-radius: var(--radius-sm);
  background: var(--surface-3);
  border: 1px solid var(--border);
  font-size: 12px;
  font-weight: 600;
  font-family: var(--font-ui);
  letter-spacing: 0.04em;
  color: var(--text-sec);
  transition: all 180ms;
}
.vote-btn.real.active { background: rgba(45,106,79,0.12); border-color: rgba(45,106,79,0.3); color: var(--success); }
.vote-btn.fake.active { background: rgba(155,34,38,0.1); border-color: rgba(155,34,38,0.25); color: var(--error); }
[data-theme="dark"] .vote-btn.real.active { background: rgba(82,183,136,0.12); border-color: rgba(82,183,136,0.3); color: var(--success); }
[data-theme="dark"] .vote-btn.fake.active { background: rgba(224,112,112,0.12); border-color: rgba(224,112,112,0.3); color: var(--error); }

/* ══════ BELIEVE BAR ══════ */
.believe-bar {
  height: 3px;
  border-radius: var(--radius-pill);
  background: var(--bg-3);
  overflow: hidden;
}
.believe-fill {
  height: 100%;
  border-radius: var(--radius-pill);
  background: linear-gradient(90deg, var(--success), #40916C);
  transition: width 600ms var(--ease-out);
}

/* ══════ MODAL OVERLAY ══════ */
.overlay {
  position: absolute;
  inset: 0;
  background: rgba(0,0,0,0.35);
  backdrop-filter: blur(8px);
  z-index: 500;
  opacity: 0;
  pointer-events: none;
  transition: opacity 220ms ease;
}
[data-theme="dark"] .overlay { background: rgba(0,0,0,0.6); }
.overlay.open { opacity: 1; pointer-events: all; }

.sheet {
  position: absolute;
  bottom: 0; left: 0; right: 0;
  background: var(--surface);
  border-radius: 24px 24px 0 0;
  border-top: 1px solid var(--border);
  transform: translateY(100%);
  transition: transform 320ms var(--ease-out);
  box-shadow: 0 -8px 40px rgba(0,0,0,0.12);
}
.overlay.open .sheet { transform: translateY(0); }

.sheet-handle {
  width: 32px; height: 3px;
  border-radius: var(--radius-pill);
  background: var(--bg-3);
  margin: 12px auto 0;
}

/* ══════ COMMENT ITEM ══════ */
.comment-item { padding: 12px var(--pad-h); border-bottom: 1px solid var(--border); }
.comment-author { font-size: 10px; font-weight: 700; font-family: var(--font-ui); letter-spacing: 0.08em; text-transform: uppercase; color: var(--accent); margin-bottom: 4px; }
.comment-text { font-size: 14px; color: var(--text); line-height: 1.55; }
.comment-meta { display: flex; gap: 12px; margin-top: 5px; }
.comment-time { font-size: 10px; color: var(--text-muted); }
.comment-reply-lnk { font-size: 10px; font-weight: 600; color: var(--text-sec); font-family: var(--font-ui); letter-spacing: 0.04em; }
.comment-indent { margin-left: 20px; padding-left: 12px; border-left: 2px solid var(--border-2); }

/* ══════ ANIMATIONS ══════ */
@keyframes fadeUp {
  from { opacity: 0; transform: translateY(14px); }
  to   { opacity: 1; transform: translateY(0); }
}

@keyframes scaleIn {
  from { opacity: 0; transform: scale(0.94); }
  to   { opacity: 1; transform: scale(1); }
}

@keyframes shimmer {
  0%   { background-position: -300% 0; }
  100% { background-position: 300% 0; }
}

.fade-up { animation: fadeUp 400ms var(--ease-out) both; }
.scale-in { animation: scaleIn 300ms var(--ease-spring) both; }

/* ══════ TYPOGRAPHY ══════ */
.display { font-family: var(--font-display); font-weight: 300; letter-spacing: -0.01em; }
.ui-label { font-family: var(--font-ui); font-weight: 600; font-size: 11px; letter-spacing: 0.1em; text-transform: uppercase; color: var(--text-muted); }

/* ══════ CONFESSION TEXT ══════ */
.confession-text {
  font-family: var(--font-display);
  font-size: 22px;
  font-weight: 300;
  line-height: 1.6;
  color: var(--text);
  text-align: center;
  font-style: italic;
  letter-spacing: 0.01em;
}

/* ══════ FEED CARD ══════ */
.feed-card {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  padding: 0 var(--pad-h);
  opacity: 0;
  pointer-events: none;
  transform: translateY(30px);
  transition: opacity 300ms ease, transform 300ms var(--ease-out);
}
.feed-card.visible {
  opacity: 1;
  pointer-events: all;
  transform: translateY(0);
}
.feed-card.above {
  opacity: 0;
  transform: translateY(-30px);
}

/* ══════ DESKTOP WRAPPER ══════ */
.app-root {
  min-height: 100vh;
  width: 100vw;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 80px;
  padding: 40px;
  background: var(--bg);
  transition: background 400ms ease;
}

/* Sidebar hidden by default, shown only on very wide screens */
.app-aside {
  max-width: 280px;
  display: none;
  flex-direction: column;
  gap: 24px;
}

@media (min-width: 1100px) {
  .app-aside { display: flex; }
}

.app-wordmark {
  font-family: var(--font-display);
  font-size: 72px;
  font-weight: 300;
  letter-spacing: 0.2em;
  color: var(--text);
  line-height: 1;
  font-style: italic;
}

.app-sub {
  font-family: var(--font-body);
  font-size: 14px;
  color: var(--text-muted);
  line-height: 1.7;
  font-style: italic;
}

.aside-feat {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 12px;
  color: var(--text-muted);
}

.aside-feat-dot {
  width: 5px; height: 5px;
  border-radius: 50%;
  background: var(--gold);
  flex-shrink: 0;
}

.phone-wrap {
  flex-shrink: 0;
  border-radius: 52px;
  padding: 14px;
  background: var(--bg-2);
  box-shadow:
    0 0 0 1px var(--border-2),
    0 40px 80px rgba(0,0,0,0.15),
    inset 0 1px 0 rgba(255,255,255,0.5);
  transition: background 400ms ease;
}
[data-theme="dark"] .phone-wrap {
  box-shadow:
    0 0 0 1px var(--border-2),
    0 40px 80px rgba(0,0,0,0.5),
    inset 0 1px 0 rgba(255,255,255,0.04);
}

.di { /* dynamic island */
  position: absolute;
  top: 14px; left: 50%;
  transform: translateX(-50%);
  width: 110px; height: 30px;
  background: #000;
  border-radius: 18px;
  z-index: 9999;
  pointer-events: none;
}

/* ── Responsive: phone fills the screen on anything that isn't a big desktop ── */
@media (max-width: 1099px) {
  .app-root {
    padding: 0;
    gap: 0;
    align-items: stretch;
    justify-content: stretch;
  }

  .app-aside { display: none !important; }

  .phone-wrap {
    border-radius: 0;
    padding: 0;
    box-shadow: none;
    background: var(--bg);
    flex: 1;
    display: flex;
  }

  .phone-shell {
    width: 100vw;
    height: 100vh;
    min-height: 100svh;
    border-radius: 0;
    flex: 1;
  }
}

/* ── Tiny screens (< 380px): just make sure nothing overflows ── */
@media (max-width: 380px) {
  .phone-shell { width: 100%; }
}
