@import url('https://fonts.googleapis.com/css2?family=Heebo:wght@400;700;900&display=swap');

:root {
  /* Dynamic Typography & Accessibility Variables */
  --font-scale: 100%;
  --line-height: 1.35;
  --letter-space: 0px;

  /* Theme & Color Variables */
  --color-bg-base: #020202;
  --color-bg-surface: rgba(255, 255, 255, 0.05);
  --color-bg-surface-hover: rgba(255, 255, 255, 0.09);
  --color-border-subtle: rgba(255, 255, 255, 0.12);
  --color-border-focus: rgba(255, 255, 255, 0.28);
  --color-text-main: #ffffff;
  --color-text-muted: rgba(255, 255, 255, 0.65);
  --color-text-subtle: rgba(255, 255, 255, 0.40);
  --color-status-live: #53fc18;
  --color-status-offline: #ef4444;
  --color-brand-orange: #f97316;
  --color-brand-red: #dc2626;

  /* Layout & Transition Tokens */
  --radius-card: 20px;
  --radius-pill: 999px;
  --trans-default: 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
}

* { box-sizing: border-box; }

html {
  font-size: var(--font-scale);
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-height: 100vh;
  min-height: 100dvh;
  overflow-x: hidden;
  overflow-y: hidden;
  font-family: 'Heebo', sans-serif;
  color: var(--color-text-main, white);
  background: var(--color-bg-base, #020202);
  line-height: var(--line-height);
  letter-spacing: var(--letter-space);
  -webkit-tap-highlight-color: transparent;
}

body.ready {
  overflow-y: auto !important;
  overflow-x: hidden !important;
  -webkit-overflow-scrolling: touch;
}

body::before {
  content: "";
  position: fixed;
  inset: -40%;
  background:
    radial-gradient(circle at 20% 20%, rgba(255,255,255,.16), transparent 18%),
    radial-gradient(circle at 75% 30%, rgba(255,255,255,.10), transparent 20%),
    radial-gradient(circle at 50% 80%, rgba(255,255,255,.13), transparent 22%),
    linear-gradient(120deg, #000, #111, #050505, #222, #000);
  animation: bgMove 10s linear infinite;
  z-index: -3;
}

body::after {
  content: "";
  position: fixed;
  inset: 0;
  background:
    linear-gradient(90deg, rgba(255,255,255,.045) 1px, transparent 1px),
    linear-gradient(rgba(255,255,255,.045) 1px, transparent 1px);
  background-size: 38px 38px;
  opacity: .55;
  animation: gridMove 6s linear infinite;
  z-index: -2;
}

.bg-orbs {
  position: fixed;
  inset: 0;
  overflow: hidden;
  pointer-events: none;
  z-index: -1;
}

.orb {
  position: absolute;
  width: 180px;
  height: 180px;
  border-radius: 999px;
  background: rgba(255,255,255,.08);
  filter: blur(2px);
  animation: floatOrb 8s ease-in-out infinite alternate;
}

.orb:nth-child(1) { top: 12%; left: 12%; }
.orb:nth-child(2) { top: 58%; right: 8%; width: 240px; height: 240px; animation-delay: -2s; }
.orb:nth-child(3) { bottom: 8%; left: 32%; width: 130px; height: 130px; animation-delay: -4s; }

@keyframes bgMove {
  0% { transform: translate(0,0) rotate(0deg); }
  100% { transform: translate(7%,5%) rotate(360deg); }
}

@keyframes gridMove {
  from { background-position: 0 0; }
  to { background-position: 38px 38px; }
}

@keyframes floatOrb {
  from { transform: translate(0,0) scale(1); }
  to { transform: translate(45px,-32px) scale(1.12); }
}

#splash-screen {
  position: fixed;
  inset: 0;
  background: #000;
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 99999;
  transition: transform 0.85s cubic-bezier(0.77, 0, 0.175, 1), opacity 0.85s ease;
  overflow: hidden;
}

#splash-screen.dismissed {
  transform: translateY(-100%);
  opacity: 0;
  pointer-events: none;
}

#splash-screen::before {
  content: "";
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.65);
  z-index: 2;
  pointer-events: none;
}

/* Scroll Prompt Styling */
.scroll-prompt {
  position: absolute;
  bottom: 40px;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
  z-index: 4;
  cursor: pointer;
  animation: scrollPromptIn 1s ease 1.2s both;
}

.scroll-mouse {
  width: 22px;
  height: 36px;
  border: 2px solid rgba(255, 255, 255, 0.5);
  border-radius: 12px;
  position: relative;
  transition: border-color 0.3s;
}

.scroll-wheel {
  width: 4px;
  height: 8px;
  background-color: #53fc18;
  border-radius: 2px;
  position: absolute;
  top: 6px;
  left: 50%;
  transform: translateX(-50%);
  animation: scrollWheelScroll 1.6s ease-in-out infinite;
}

.scroll-text {
  font-size: 0.72rem;
  font-weight: 900;
  letter-spacing: 0.22em;
  color: rgba(255, 255, 255, 0.55);
  text-shadow: 0 0 10px rgba(0, 0, 0, 0.6);
  transition: color 0.3s, text-shadow 0.3s;
}

.scroll-prompt:hover .scroll-text {
  color: #53fc18;
  text-shadow: 0 0 12px rgba(83, 252, 24, 0.45);
}

.scroll-prompt:hover .scroll-mouse {
  border-color: #53fc18;
}

@keyframes scrollPromptIn {
  from { opacity: 0; transform: translate(-50%, 20px); }
  to { opacity: 1; transform: translate(-50%, 0); }
}

@keyframes scrollWheelScroll {
  0% { opacity: 0; transform: translate(-50%, 0); }
  20% { opacity: 1; }
  60% { opacity: 1; transform: translate(-50%, 10px); }
  100% { opacity: 0; transform: translate(-50%, 10px); }
}

.splash-logo {
  width: 116px;
  height: 116px;
  border-radius: 50%;
  object-fit: cover;
  border: 4px solid white;
  box-shadow: 0 0 42px rgba(255,255,255,.35);
  animation: logoPop 1.05s ease both;
}

.intro-card {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 14px;
  animation: introReveal .95s ease both;
  z-index: 3;
}

.intro-card::before {
  content: "";
  position: absolute;
  top: -18px;
  width: 178px;
  height: 178px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(255,255,255,.16), transparent 68%);
  filter: blur(2px);
  pointer-events: none;
}

.intro-ring {
  position: relative;
  width: 138px;
  height: 138px;
  border-radius: 50%;
  padding: 7px;
  background: radial-gradient(circle, rgba(255,255,255,.95), rgba(255,255,255,.20) 58%, transparent 72%);
  box-shadow: 0 0 42px rgba(255,255,255,.18);
  overflow: hidden;
  animation: logoPop 0.9s cubic-bezier(0.34, 1.56, 0.64, 1) both .06s;
}

.intro-ring::after {
  content: "";
  position: absolute;
  inset: -40%;
  border-radius: 50%;
  background: radial-gradient(circle at 30% 30%, rgba(255,255,255,.34), transparent 35%);
  animation: introSoftPulse 1.4s ease-in-out infinite alternate;
  pointer-events: none;
}

.intro-ring .splash-logo {
  position: relative;
  z-index: 2;
  width: 100%;
  height: 100%;
  display: block;
  animation: none;
  border-radius: 50%;
  border: 4px solid #000;
  box-shadow: 0 0 28px rgba(255,255,255,.14);
}

.intro-welcome {
  font-size: 1.4rem;
  font-weight: 900;
  letter-spacing: .25em;
  color: rgba(255,255,255,0.7);
  text-shadow: 0 0 10px rgba(255,255,255,.2);
  animation: introTextIn .8s ease both;
  margin-bottom: -4px;
}

.intro-name {
  font-size: 2.05rem;
  font-weight: 900;
  letter-spacing: .04em;
  text-shadow: 0 0 20px rgba(255,255,255,.32);
  animation: introTextIn .8s ease .12s both;
}

.intro-subtitle {
  font-size: 0.85rem;
  font-weight: 900;
  letter-spacing: .18em;
  color: #53fc18;
  text-shadow: 0 0 12px rgba(83,252,24,0.4);
  animation: introTextIn .8s ease .24s both;
  margin-top: -4px;
}

.intro-line {
  width: 120px;
  height: 4px;
  border-radius: 999px;
  background: linear-gradient(90deg, transparent, white, transparent);
  box-shadow: 0 0 18px rgba(255,255,255,.45);
  animation: introLineGrow .85s ease .3s both;
  transform-origin: center;
}

@keyframes introReveal {
  from { opacity: 0; transform: translateY(22px) scale(.88); filter: blur(8px); }
  to { opacity: 1; transform: translateY(0) scale(1); filter: blur(0); }
}

@keyframes introSoftPulse {
  from { opacity: .55; transform: scale(.96); }
  to { opacity: .9; transform: scale(1.06); }
}

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

@keyframes introLineGrow {
  from { transform: scaleX(.2); opacity: 0; }
  to { transform: scaleX(1); opacity: 1; }
}

@keyframes logoPop {
  0% { transform: scale(.65); opacity: 0; }
  60% { transform: scale(1.1); opacity: 1; }
  100% { transform: scale(1); }
}

.nav {
  position: fixed;
  top: 18px;
  right: 18px;
  z-index: 80;
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
  max-width: calc(100vw - 36px);
}

.nav button {
  border: 1px solid rgba(255,255,255,.18);
  background: rgba(255,255,255,.08);
  color: white;
  backdrop-filter: blur(14px);
  border-radius: 16px;
  padding: 9px 17px;
  font-weight: 900;
  cursor: pointer;
  transition: .22s;
}

.nav button.active,
.nav button:hover {
  background: white;
  color: #050505;
  transform: translateY(-2px) scale(1.04);
}

.page { display: none; }
.page.active { display: block; animation: pageIn .35s ease both; }

@keyframes pageIn {
  from { opacity: 0; transform: translateY(16px) scale(.985); }
  to { opacity: 1; transform: translateY(0) scale(1); }
}

.profile-container {
  position: relative;
  display: block;
  width: 118px;
  height: 118px;
  transition: transform .25s;
}

.profile-container:hover {
  transform: scale(1.06) rotate(-2deg);
}

.profile {
  width: 100%;
  height: 100%;
  border-radius: 50%;
  object-fit: cover;
  border: 5px solid #fff;
  box-shadow: 0 22px 48px rgba(0,0,0,.55), 0 0 30px rgba(255,255,255,.22);
  display: block;
  margin: 0 !important;
}

.status-dot {
  position: absolute;
  bottom: 2px;
  right: 2px;
  width: 26px;
  height: 26px;
  border-radius: 50%;
  background-color: #808080;
  border: 4px solid #141414;
  box-shadow: 0 4px 12px rgba(0,0,0,0.6);
  z-index: 5;
  transition: background-color 0.3s, box-shadow 0.3s;
}

.status-dot.live {
  background-color: var(--color-status-live, #53fc18);
  box-shadow: 0 0 16px rgba(83, 252, 24, 0.7), 0 4px 12px rgba(0,0,0,0.6);
}

.bubble {
  display: block;
  text-decoration: none;
  color: var(--color-text-main, white);
  border-radius: 30px;
  padding: 1px;
  background: linear-gradient(135deg, rgba(255,255,255,.75), rgba(255,255,255,.08), rgba(255,255,255,.35));
  box-shadow: 0 18px 42px rgba(0,0,0,.5);
  overflow: hidden;
  transition: .25s;
  border: 1px solid var(--color-border-subtle, rgba(255,255,255,.12));
}

.bubble:hover {
  transform: translateY(-7px) scale(1.015);
  box-shadow: 0 28px 65px rgba(0,0,0,.68), 0 0 28px rgba(255,255,255,.12);
}

.bubble-inner {
  min-height: 76px;
  border-radius: 28px;
  background:
    linear-gradient(145deg, rgba(255,255,255,.14), rgba(255,255,255,.035)),
    rgba(0,0,0,.5);
  backdrop-filter: blur(18px);
  display: flex;
  align-items: center;
  gap: 15px;
  padding: 14px 18px;
}

.icon {
  width: 44px;
  height: 44px;
  border-radius: 18px;
  background: rgba(255,255,255,.1);
  border: 1px solid rgba(255,255,255,.16);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.icon img, .icon svg {
  width: 27px;
  height: 27px;
  display: block;
}

.title {
  font-size: 1.12rem;
  font-weight: 900;
  line-height: 1;
}

.sub {
  margin-top: 7px;
  color: rgba(255,255,255,.68);
  font-weight: 800;
  font-size: .78rem;
}

.status {
  margin-top: 8px;
  display: flex;
  align-items: center;
  gap: 7px;
  font-weight: 900;
  font-size: .9rem;
  direction: ltr;
  justify-content: flex-end;
}

.dot {
  width: 9px;
  height: 9px;
  border-radius: 999px;
  background: #777;
}

.live { color: #53fc18; text-shadow: 0 0 12px rgba(83,252,24,.65); }
.live .dot { background: #53fc18; box-shadow: 0 0 12px rgba(83,252,24,.9); animation: pulse 1.15s infinite; }
.offline { color: #9ca3af; }

@keyframes pulse {
  0%,100% { transform: scale(1); opacity: 1; }
  50% { transform: scale(1.5); opacity: .55; }
}

.command-card, .contact-card {
  border-radius: 28px;
  padding: 1px;
  background: linear-gradient(135deg, rgba(255,255,255,.65), rgba(255,255,255,.07));
  box-shadow: 0 18px 42px rgba(0,0,0,.52);
  border: 1px solid rgba(255,255,255,.14);
  overflow: hidden;
}

.command-inner, .contact-inner {
  border-radius: 27px;
  background: rgba(0,0,0,.58);
  backdrop-filter: blur(18px);
  padding: 18px;
}

.command-inner {
  min-height: 86px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.command-name {
  direction: ltr;
  unicode-bidi: isolate;
  text-align: right;
  font-size: 1.28rem;
  font-weight: 900;
  color: #fff;
  text-shadow: 0 0 14px rgba(255,255,255,.28);
}

.command-desc {
  margin-top: 6px;
  color: rgba(255,255,255,.62);
  font-weight: 800;
  font-size: .78rem;
}

.copy-btn {
  width: 45px;
  height: 45px;
  border-radius: 16px;
  border: 1px solid rgba(255,255,255,.2);
  background: rgba(255,255,255,.11);
  color: white;
  cursor: pointer;
  transition: .2s;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.copy-btn:hover, .copy-btn.copied {
  background: white;
  color: black;
  transform: scale(1.07);
}

.copy-btn svg { width: 21px; height: 21px; }

footer {
  margin-top: 20px;
  margin-bottom: 26px;
  font-weight: 900;
  color: rgba(255,255,255,.58);
  text-align: center;
  font-size: .78rem;
}

footer button {
  transition: .2s;
}

footer button:hover {
  color: white !important;
  text-shadow: 0 0 12px rgba(255,255,255,.45);
}

#a11y-button {
  position: fixed;
  right: 18px;
  bottom: 18px;
  width: 54px;
  height: 54px;
  border-radius: 50%;
  border: 3px solid white;
  background: #111;
  color: white;
  z-index: 9999;
  cursor: pointer;
  box-shadow: 0 12px 28px rgba(0,0,0,.55);
  display: flex;
  align-items: center;
  justify-content: center;
  animation: a11yBounce 3.5s infinite;
}

#a11y-button svg { width: 28px; height: 28px; }

@keyframes a11yBounce {
  0%,72%,100% { transform: translateY(0); }
  78% { transform: translateY(-7px); }
  88% { transform: translateY(-4px); }
}

#a11y-panel {
  position: fixed;
  right: 18px;
  bottom: 84px;
  width: min(390px, calc(100vw - 44px));
  max-height: calc(100vh - 120px);
  overflow-y: auto;
  display: none;
  z-index: 9998;
  background: rgba(8,8,8,.96);
  border: 1px solid rgba(255,255,255,.28);
  border-radius: 24px;
  box-shadow: 0 25px 70px rgba(0,0,0,.78);
  backdrop-filter: blur(18px);
  padding: 18px;
}

#a11y-panel.open { display: block; animation: pageIn .22s ease both; }

.a11y-title {
  display: flex;
  justify-content: space-between;
  font-size: 20px;
  font-weight: 900;
  margin-bottom: 12px;
}

.a11y-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 9px;
}

.a11y-btn, .a11y-big {
  border: 1px solid rgba(255,255,255,.2);
  background: rgba(255,255,255,.08);
  color: white;
  border-radius: 14px;
  padding: 11px;
  font-weight: 900;
  cursor: pointer;
  transition: .2s;
}

.a11y-big {
  width: 100%;
  margin-bottom: 10px;
  background: rgba(255,255,255,.14);
}

.a11y-btn:hover, .a11y-big:hover, .a11y-active {
  background: white !important;
  color: black !important;
}

.a11y-section {
  margin-top: 14px;
  padding-top: 14px;
  border-top: 1px solid rgba(255,255,255,.12);
}

.a11y-label {
  display: flex;
  justify-content: space-between;
  font-weight: 900;
  margin-bottom: 8px;
  color: rgba(255,255,255,.88);
}

.a11y-range { width: 100%; accent-color: white; }

#reading-guide {
  position: fixed;
  left: 0;
  width: 100%;
  height: 4px;
  top: 50%;
  background: white;
  box-shadow: 0 0 18px rgba(255,255,255,.8);
  z-index: 9997;
  display: none;
  pointer-events: none;
}

body.reading-guide-on #reading-guide { display: block; }

body.contrast-light {
  background: white !important;
  color: black !important;
}

body.contrast-light::before, body.contrast-light::after, body.contrast-light .bg-orbs { display: none !important; }

body.contrast-light .bubble-inner,
body.contrast-light .command-inner,
body.contrast-light .contact-inner {
  background: white !important;
  color: black !important;
  border: 1px solid black;
}

body.contrast-light .sub,
body.contrast-light .command-desc,
body.contrast-light footer,
body.contrast-light .policy-box p,
body.contrast-light .policy-box li {
  color: #111 !important;
}

body.grayscale { filter: grayscale(1); }
body.underline-links a { text-decoration: underline !important; text-underline-offset: 5px; }

body.pause-motion *,
body.pause-motion *::before,
body.pause-motion *::after {
  animation: none !important;
  transition: none !important;
  scroll-behavior: auto !important;
}

#spotlight {
  position: fixed;
  top: 0;
  left: 0;
  width: 520px;
  height: 520px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(255,255,255,.16) 0%, rgba(255,255,255,.07) 26%, transparent 72%);
  transform: translate(-50%, -50%);
  pointer-events: none;
  z-index: 1;
  opacity: .95;
  mix-blend-mode: screen;
}

.live {
  color: #53fc18;
  text-shadow:
    0 0 8px rgba(83,252,24,.95),
    0 0 18px rgba(83,252,24,.85),
    0 0 34px rgba(83,252,24,.55);
  animation: kickGlow 1.35s ease-in-out infinite alternate;
}

@keyframes kickGlow {
  from { filter: drop-shadow(0 0 4px rgba(83,252,24,.55)); }
  to { filter: drop-shadow(0 0 16px rgba(83,252,24,.95)); }
}

body.a11y-scroll {
  overflow-y: auto !important;
}

body.a11y-scroll main {
  min-height: 100vh;
}

.back-btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  margin-bottom: 14px;
  padding: 8px 18px;
  border-radius: 999px;
  border: 1px solid rgba(255,255,255,.18);
  background: rgba(255,255,255,.07);
  color: rgba(255,255,255,.85);
  font-size: .85rem;
  font-weight: 800;
  cursor: pointer;
  transition: background .2s, color .2s, transform .15s;
  backdrop-filter: blur(8px);
}
.back-btn:hover {
  background: rgba(255,255,255,.15);
  color: #fff;
  transform: translateX(-3px);
}

.policy-card {
  border-radius: 28px;
  padding: 1px;
  background: linear-gradient(135deg, rgba(255,255,255,.65), rgba(255,255,255,.07));
  box-shadow: 0 18px 42px rgba(0,0,0,.52);
  border: 1px solid rgba(255,255,255,.14);
  overflow: hidden;
  max-height: calc(100vh - 245px);
}

.policy-inner {
  border-radius: 27px;
  background: rgba(0,0,0,.58);
  backdrop-filter: blur(18px);
  padding: 18px;
  overflow-y: auto;
  max-height: calc(100vh - 245px);
}

.policy-inner h2 {
  font-size: 1.6rem;
  font-weight: 900;
  margin-bottom: 8px;
  text-align: center;
}

.policy-box {
  margin-top: 10px;
  padding: 12px 14px;
  border-radius: 18px;
  background: rgba(255,255,255,.07);
  border: 1px solid rgba(255,255,255,.10);
}

.policy-box h3 {
  font-weight: 900;
  font-size: 1rem;
  margin-bottom: 4px;
}

.policy-box p, .policy-box li {
  color: rgba(255,255,255,.72);
  font-weight: 700;
  font-size: .78rem;
  line-height: 1.55;
}

.policy-box ul {
  margin: 0;
  padding-right: 18px;
}

#a11y-panel, #a11y-panel * {
  font-size: 16px !important;
  line-height: 1.35 !important;
  letter-spacing: 0 !important;
}

body.pause-motion::before,
body.pause-motion::after,
body.pause-motion .orb,
body.pause-motion #spotlight,
body.pause-motion .live,
body.pause-motion .dot,
body.pause-motion #a11y-button {
  animation: none !important;
  transition: none !important;
  transform: none !important;
}

body.pause-motion #spotlight {
  display: none !important;
}

/* Universal Responsive Design */
@media (max-width: 768px) {
  .lb-grid {
    grid-template-columns: 1fr;
    gap: 20px;
  }
}

@media (max-width: 520px) {
  .nav {
    top: max(10px, env(safe-area-inset-top));
    right: 50%;
    transform: translateX(50%);
    justify-content: center;
    width: calc(100% - 24px);
    max-width: 420px;
    gap: 6px;
  }
  .nav button {
    padding: 7px 12px;
    font-size: .80rem;
    border-radius: 12px;
  }
  main {
    padding-top: calc(80px + env(safe-area-inset-top)) !important;
    padding-bottom: calc(24px + env(safe-area-inset-bottom)) !important;
    padding-left: max(14px, env(safe-area-inset-left)) !important;
    padding-right: max(14px, env(safe-area-inset-right)) !important;
  }
  .profile-container { width: 108px; height: 108px; }
  .title, .command-name { font-size: 1.05rem; }
  .bubble-inner { min-height: 72px; padding: 13px 15px; gap: 12px; }
  .icon { width: 40px; height: 40px; border-radius: 14px; }
  .icon img, .icon svg { width: 23px; height: 23px; }
  .policy-card, .policy-inner {
    max-height: calc(100dvh - 190px);
  }
  #a11y-button {
    right: max(12px, env(safe-area-inset-right));
    bottom: max(12px, env(safe-area-inset-bottom));
    width: 48px;
    height: 48px;
  }
  #a11y-panel {
    right: max(12px, env(safe-area-inset-right));
    bottom: calc(68px + env(safe-area-inset-bottom));
    width: min(360px, calc(100vw - 24px));
  }
}

/* Small/Narrow devices (e.g. Galaxy Fold folded 280px-340px) */
@media (max-width: 340px) {
  .nav button {
    padding: 6px 8px;
    font-size: .70rem;
  }
  .profile-container { width: 92px; height: 92px; }
  .title { font-size: .95rem; }
  .sub { font-size: .70rem; }
  .bubble-inner { padding: 10px 12px; }
}

/* Landscape mode on smartphones */
@media (max-height: 520px) and (orientation: landscape) {
  .nav {
    top: 8px;
    position: fixed;
  }
  main {
    padding-top: 60px !important;
  }
  .intro-card {
    gap: 6px;
  }
  .intro-ring {
    width: 80px;
    height: 80px;
    padding: 4px;
  }
  .intro-welcome { font-size: .95rem; }
  .intro-name { font-size: 1.4rem; }
  .scroll-prompt { bottom: 12px; }
  .profile-container { width: 88px; height: 88px; }
  .policy-card, .policy-inner {
    max-height: calc(100dvh - 120px);
  }
}

/* Leaderboard Base Styling */
.lb-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 18px;
  width: 100%;
}
.lb-page-col {
  padding: 6px;
}
.lb-col-title {
  text-align: center;
  font-size: 1.1rem;
  font-weight: 900;
  color: #ff3b1f;
  margin-bottom: 15px;
  letter-spacing: .02em;
}
.lb-rows {
  display: grid;
  gap: 8px;
  min-height: 80px;
}
.rank-row {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 14px;
  border-radius: 18px;
  background: rgba(255,255,255,.03);
  border: 1px solid rgba(255,255,255,.06);
  opacity: 0;
  transform: translateY(8px);
  animation: rowIn .4s ease forwards;
  transition: transform .25s cubic-bezier(.25,.46,.45,.94), border-color .2s ease, background .2s ease;
}
.rank-row:hover {
  transform: translateX(-3px);
  border-color: rgba(255,118,90,.3);
  background: rgba(255,255,255,.05);
}
@keyframes rowIn {
  to { opacity: 1; transform: translateY(0); }
}
.rank-num {
  width: 26px;
  height: 26px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 900;
  font-size: 11px;
  background: rgba(255,255,255,.06);
  color: rgba(255,255,255,.5);
  flex: 0 0 auto;
}
.rank-row.top1 .rank-num {
  background: linear-gradient(135deg,#ffd966,#c9920b);
  color: #3a2800;
}
.rank-row.top2 .rank-num {
  background: linear-gradient(135deg,#e6e6e6,#9c9c9c);
  color: #222;
}
.rank-row.top3 .rank-num {
  background: linear-gradient(135deg,#e3a06a,#a85f2c);
  color: #2a1500;
}
.rank-name {
  flex: 1;
  min-width: 0;
  font-weight: 800;
  font-size: 14px;
  direction: ltr;
  text-align: left;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.rank-val {
  font-weight: 900;
  font-size: 13px;
  color: #ff6a3d;
  direction: ltr;
  flex: 0 0 auto;
}
.lb-empty {
  color: rgba(255,255,255,.32);
  font-size: 14px;
  text-align: center;
  padding: 18px;
}
@media (max-width: 640px) {
  .lb-grid {
    grid-template-columns: 1fr;
  }
}

/* Opening Entrance Animations */
body:not(.ready) .profile-container,
body:not(.ready) #main-header h1,
body:not(.ready) #page-subtitle,
body:not(.ready) .nav,
body:not(.ready) .bubble {
  opacity: 0 !important;
}

body.ready .profile-container {
  animation: mainProfileIn 0.85s cubic-bezier(0.16, 1, 0.3, 1) both 80ms;
}
body.ready #main-header h1 {
  animation: mainTitleIn 0.85s cubic-bezier(0.16, 1, 0.3, 1) both 160ms;
}
body.ready #page-subtitle {
  animation: mainTitleIn 0.85s cubic-bezier(0.16, 1, 0.3, 1) both 240ms;
}
body.ready .nav {
  animation: mainNavIn 0.85s cubic-bezier(0.16, 1, 0.3, 1) both 320ms;
}
body.ready .bubble {
  animation: mainBubbleIn 0.85s cubic-bezier(0.16, 1, 0.3, 1) both;
}

body.ready .bubble:nth-child(1) { animation-delay: 380ms; }
body.ready .bubble:nth-child(2) { animation-delay: 450ms; }
body.ready .bubble:nth-child(3) { animation-delay: 520ms; }
body.ready .bubble:nth-child(4) { animation-delay: 590ms; }
body.ready .bubble:nth-child(5) { animation-delay: 660ms; }
body.ready .bubble:nth-child(6) { animation-delay: 730ms; }
body.ready .bubble:nth-child(7) { animation-delay: 800ms; }
body.ready .bubble:nth-child(8) { animation-delay: 870ms; }
body.ready .bubble:nth-child(9) { animation-delay: 940ms; }

@keyframes mainProfileIn {
  from { opacity: 0; transform: translateY(18px) scale(0.92); }
  to { opacity: 1; transform: translateY(0) scale(1); }
}
@keyframes mainTitleIn {
  from { opacity: 0; transform: translateY(14px); }
  to { opacity: 1; transform: translateY(0); }
}
@keyframes mainNavIn {
  from { opacity: 0; transform: translateY(-14px); }
  to { opacity: 1; transform: translateY(0); }
}
@keyframes mainBubbleIn {
  from { opacity: 0; transform: translateY(18px); }
  to { opacity: 1; transform: translateY(0); }
}
