/* ============================================================
   PAUSE — design system (rebuilt from the actual app assets:
   light blue-grey theme, Azedo display font, Raleway body)
   ============================================================ */

:root {
  --bg: #e3eef4;
  --bg-deep: #cfdfe8;
  --surface: #f7fafc;
  --surface-2: #eef4f8;
  --ink: #0d3355;
  --ink-soft: #3a5a76;
  --ink-faint: #7d95a8;
  --teal: #4fb8a4;
  --blue: #4d9fd8;
  --pink: #e98cb0;
  --gold: #e0b46a;
  --line: rgba(13, 51, 85, 0.10);
  --line-strong: rgba(13, 51, 85, 0.18);
  --shadow: 0 14px 40px rgba(38, 70, 100, 0.14);
  --shadow-sm: 0 6px 18px rgba(38, 70, 100, 0.10);
  --radius: 22px;
  --display: 'Azedo Light', 'Cormorant Garamond', Georgia, serif;
  --body: 'Raleway', 'Helvetica Neue', -apple-system, 'Segoe UI', sans-serif;
}

@font-face {
  font-family: 'Azedo Light';
  src: url('../assets/fonts/Azedo-Light.otf') format('opentype');
  font-weight: 300;
}
@font-face {
  font-family: 'Raleway';
  src: url('../assets/fonts/Raleway-Regular.ttf') format('truetype');
  font-weight: 400;
}
@font-face {
  font-family: 'Raleway';
  src: url('../assets/fonts/Raleway-Medium.ttf') format('truetype');
  font-weight: 500;
}
@font-face {
  font-family: 'Raleway';
  src: url('../assets/fonts/Raleway-Bold.ttf') format('truetype');
  font-weight: 700;
}
@font-face {
  font-family: 'Raleway';
  src: url('../assets/fonts/Raleway-Light.ttf') format('truetype');
  font-weight: 300;
}

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

html, body {
  height: 100%;
  background: var(--bg);
  color: var(--ink);
  font-family: var(--body);
  -webkit-font-smoothing: antialiased;
  overscroll-behavior: none;
  -webkit-tap-highlight-color: transparent;
}
body { overflow: hidden; }

.app {
  position: fixed; inset: 0; overflow: hidden;
}
.screen {
  position: absolute; inset: 0;
  display: none; flex-direction: column;
  background: var(--bg);
  overflow: hidden;
}
.screen.active { display: flex; animation: screenIn 0.4s ease; }
@keyframes screenIn { from { opacity: 0; transform: translateY(8px); } to { opacity: 1; transform: translateY(0); } }

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

.btn {
  padding: 14px 30px; border-radius: 100px;
  font-size: 13px; letter-spacing: 0.16em; text-transform: uppercase;
  font-weight: 600;
  transition: transform 0.15s, box-shadow 0.2s;
  user-select: none;
}
.btn:active { transform: scale(0.97); }
.btn-primary {
  background: linear-gradient(135deg, var(--teal), #2e8f7b);
  color: #fff;
  box-shadow: 0 10px 26px rgba(79, 184, 164, 0.35);
}
.btn-ghost {
  border: 1px solid var(--line-strong);
  color: var(--ink-soft);
  background: var(--surface);
}
.btn-full { width: 100%; margin-top: 22px; }

.icon-btn {
  width: 40px; height: 40px; border-radius: 50%;
  display: inline-flex; align-items: center; justify-content: center;
  color: var(--ink-soft);
  border: 1px solid var(--line);
  background: var(--surface);
  box-shadow: var(--shadow-sm);
  transition: transform 0.15s;
}
.icon-btn:active { transform: scale(0.92); }
.icon-btn img { width: 20px; height: 20px; }
.icon-btn.ghost { background: transparent; box-shadow: none; border-color: rgba(255,255,255,0.3); color: #fff; }

.topbar {
  display: flex; align-items: center; justify-content: space-between;
  padding: 16px 16px 8px; min-height: 58px; position: relative; z-index: 5;
}
.topbar-title {
  font-size: 12px; font-weight: 700; letter-spacing: 0.24em; text-transform: uppercase;
  color: var(--ink-soft);
}
.topbar-spacer { width: 40px; }
.screen-scroll { flex: 1; overflow-y: auto; padding: 8px 20px 40px; -webkit-overflow-scrolling: touch; }
.screen-scroll::-webkit-scrollbar { display: none; }

/* ---------- wordmark ---------- */
.wordmark {
  font-family: var(--display);
  font-weight: 300;
  font-size: 34px;
  letter-spacing: 0.22em;
  color: var(--ink);
  line-height: 1;
}

/* ---------- splash ---------- */
.splash { padding: 0; }
.splash-img { width: 100%; height: 100%; object-fit: cover; animation: splashFade 0.9s ease; }
@keyframes splashFade { from { opacity: 0; } to { opacity: 1; } }

/* ---------- onboarding ---------- */
.onboarding { background: var(--bg); }
.ob-header { display: flex; justify-content: flex-end; padding: 16px 18px; }
.ob-close { font-size: 16px; color: var(--ink-faint); padding: 8px; }
.ob-body { flex: 1; overflow: hidden; position: relative; }
.ob-slides { height: 100%; display: flex; transition: transform 0.45s cubic-bezier(0.4,0,0.2,1); }
.ob-slide {
  flex: 0 0 100%;
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  text-align: center; padding: 24px 34px;
}
.ob-orb {
  width: 170px; height: 170px; border-radius: 50%;
  margin-bottom: 40px;
  background: radial-gradient(circle at 34% 32%, #fff, rgba(255,255,255,0.9));
  box-shadow: 0 0 60px rgba(255,255,255,0.6), inset 0 0 0 40px rgba(255,255,255,0.1);
  position: relative;
  display: flex; align-items: center; justify-content: center;
}
.ob-orb img { width: 110%; height: 110%; object-fit: contain; filter: drop-shadow(0 0 26px rgba(255,255,255,0.7)); }
.ob-title {
  font-family: var(--display); font-weight: 300; font-size: 32px; margin-bottom: 14px; color: var(--ink);
}
.ob-text { color: var(--ink-soft); font-size: 15px; line-height: 1.75; max-width: 330px; }
.ob-footer {
  display: flex; flex-direction: column; align-items: center; gap: 18px;
  padding: 12px 24px 36px;
}
.ob-dots { display: flex; gap: 8px; }
.ob-dot { width: 7px; height: 7px; border-radius: 50%; background: rgba(13,51,85,0.18); transition: background 0.3s, transform 0.3s; }
.ob-dot.active { background: var(--teal); transform: scale(1.35); }

/* ---------- home / start ---------- */
.home { background: var(--bg); }
.home-canvas-wrap { position: absolute; inset: 0; pointer-events: none; }
#home-canvas { width: 100%; height: 100%; }
.home-top {
  position: relative; z-index: 3;
  display: flex; align-items: center; justify-content: space-between;
  padding: 20px 20px 0;
}
.home-top-actions { display: flex; gap: 10px; }
.home-body {
  position: relative; z-index: 2;
  flex: 1; display: flex; flex-direction: column; align-items: center;
  padding: 10px 20px 26px;
  overflow: hidden;
}

.start-blob {
  position: relative;
  width: min(300px, 62vw);
  aspect-ratio: 1;
  margin-top: 4vh;
  display: flex; align-items: center; justify-content: center;
  cursor: pointer;
  animation: blobFloat 6s ease-in-out infinite;
}
.start-blob-img {
  width: 100%; height: 100%; object-fit: contain;
  filter: drop-shadow(0 12px 40px rgba(77,159,216,0.35));
  animation: blobPulse 4s ease-in-out infinite;
}
.start-blob-tip {
  position: absolute; bottom: 6%;
  font-size: 11px; letter-spacing: 0.3em; text-transform: uppercase;
  color: var(--ink-soft);
  background: rgba(247,250,252,0.85);
  padding: 8px 18px; border-radius: 100px;
  box-shadow: var(--shadow-sm);
  backdrop-filter: blur(4px);
}
@keyframes blobFloat { 0%,100% { transform: translateY(0); } 50% { transform: translateY(-8px); } }
@keyframes blobPulse { 0%,100% { transform: scale(1); } 50% { transform: scale(1.04); } }

.duration-select {
  margin-top: 20px;
  display: flex; gap: 10px; align-items: center;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 100px;
  padding: 6px 8px;
  box-shadow: var(--shadow-sm);
}
.dur-chip {
  padding: 9px 18px; border-radius: 100px;
  font-size: 14px; color: var(--ink-faint);
  transition: all 0.2s;
}
.dur-chip.on { background: var(--ink); color: #fff; box-shadow: 0 6px 16px rgba(13,51,85,0.25); }
.dur-chip.min { font-size: 11px; color: var(--ink-faint); }

.expressions {
  margin-top: 22px;
  display: flex; gap: 14px; justify-content: center; flex-wrap: wrap;
  max-width: 340px;
}
.expr {
  width: 52px; height: 52px; border-radius: 50%;
  background: var(--surface);
  border: 1px solid var(--line);
  box-shadow: var(--shadow-sm);
  display: flex; align-items: center; justify-content: center;
  transition: transform 0.15s;
}
.expr:active { transform: scale(0.9); }
.expr img { width: 70%; height: 70%; object-fit: contain; }

.home-links { margin-top: auto; padding-top: 16px; }
.link-btn {
  font-size: 12px; letter-spacing: 0.2em; text-transform: uppercase;
  color: var(--ink-soft); padding: 10px 20px;
}
.footer-actions { display: flex; justify-content: center; gap: 4px; padding: 6px 0 24px; }

/* ---------- gamemodes ---------- */
.gm-card {
  width: 100%;
  display: flex; align-items: center; gap: 16px;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 20px;
  padding: 16px 18px;
  margin-bottom: 14px;
  box-shadow: var(--shadow-sm);
  text-align: left;
  transition: transform 0.15s;
}
.gm-card:active { transform: scale(0.98); }
.gm-logo {
  width: 60px; height: 60px; border-radius: 50%;
  flex-shrink: 0;
  background: radial-gradient(circle at 32% 30%, #fff, rgba(255,255,255,0.85));
  box-shadow: 0 6px 18px rgba(13,51,85,0.15);
  display: flex; align-items: center; justify-content: center;
  overflow: hidden;
}
.gm-logo img { width: 110%; height: 110%; object-fit: contain; }
.gm-meta { flex: 1; }
.gm-name { font-family: var(--display); font-size: 21px; font-weight: 300; color: var(--ink); }
.gm-desc { font-size: 12px; color: var(--ink-faint); margin-top: 3px; }
.gm-soon {
  font-size: 10px; letter-spacing: 0.2em; text-transform: uppercase;
  color: var(--gold); border: 1px solid rgba(224,180,106,0.5);
  padding: 3px 9px; border-radius: 100px; white-space: nowrap;
}

/* ---------- mood ---------- */
.mood-q { font-family: var(--display); font-weight: 300; font-size: 30px; margin: 18px 0 6px; color: var(--ink); }
.mood-sub { color: var(--ink-faint); font-size: 13px; margin-bottom: 20px; }
.mood-chips { display: flex; flex-wrap: wrap; gap: 10px; }
.mood-chip {
  padding: 11px 18px; border-radius: 100px;
  border: 1px solid var(--line); background: var(--surface);
  color: var(--ink-soft); font-size: 14px;
  transition: all 0.2s;
}
.mood-chip.selected {
  background: linear-gradient(135deg, var(--teal), #2e8f7b);
  color: #fff; border-color: transparent; font-weight: 600;
}
.mood-extra { margin-top: 26px; }
.field-label { display: block; font-size: 12px; letter-spacing: 0.08em; color: var(--ink-soft); margin-bottom: 8px; }
.textarea, .input {
  width: 100%;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 14px;
  padding: 13px 15px;
  color: var(--ink);
  font-family: inherit; font-size: 14px;
  resize: none; outline: none;
  transition: border-color 0.2s;
}
.textarea:focus, .input:focus { border-color: var(--teal); }
.textarea { margin-bottom: 18px; }

/* ---------- setup ---------- */
.setup-body { display: flex; flex-direction: column; justify-content: center; }
.setup-sub { color: var(--ink-soft); font-size: 15px; line-height: 1.7; margin: 10px 0 18px; }
.setup-phrase { font-family: var(--display); font-style: italic; font-size: 20px; line-height: 1.5; color: var(--ink); margin-bottom: 30px; }
.duration-row, .sound-row { margin-bottom: 22px; }
.duration-title { display: block; font-size: 11px; letter-spacing: 0.26em; text-transform: uppercase; color: var(--ink-faint); margin-bottom: 12px; }
.duration-control { display: flex; align-items: center; justify-content: center; }
.duration-btn {
  width: 50px; height: 50px; border-radius: 50%;
  border: 1px solid var(--line-strong);
  font-size: 22px; color: var(--ink-soft); background: var(--surface);
}
.duration-val { width: 100px; text-align: center; font-family: var(--display); font-size: 38px; font-weight: 300; color: var(--ink); }
.duration-unit { font-size: 11px; color: var(--ink-faint); letter-spacing: 0.1em; display: block; }
.sound-picker { display: flex; gap: 10px; flex-wrap: wrap; justify-content: center; }
.sound-chip {
  padding: 10px 18px; border-radius: 100px;
  border: 1px solid var(--line); background: var(--surface);
  color: var(--ink-soft); font-size: 13px;
  transition: all 0.2s;
}
.sound-chip.selected { border-color: var(--teal); color: var(--teal); background: rgba(79,184,164,0.1); }

/* ---------- flow ---------- */
.flow-screen { background: #04101c; touch-action: none; }
#flow-canvas { position: absolute; inset: 0; width: 100%; height: 100%; display: block; touch-action: none; }
.flow-ui { position: absolute; inset: 0; display: flex; align-items: center; justify-content: center; pointer-events: none; }
.flow-timer-ring {
  width: 150px; height: 150px; border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  border: 1px solid rgba(255,255,255,0.14);
  backdrop-filter: blur(2px);
}
.flow-timer-label { font-family: var(--display); font-size: 26px; color: rgba(255,255,255,0.75); letter-spacing: 0.06em; }
.flow-message {
  position: absolute; top: 15%;
  font-family: var(--display); font-style: italic; font-size: 22px;
  color: rgba(255,255,255,0.9); text-align: center; padding: 0 30px;
  text-shadow: 0 2px 20px rgba(0,0,0,0.6);
  opacity: 0; transition: opacity 0.4s;
}
.flow-message.show { opacity: 1; }
.flow-controls {
  position: absolute; bottom: max(24px, env(safe-area-inset-bottom));
  left: 0; right: 0; display: flex; justify-content: space-between;
  padding: 0 20px; z-index: 5;
}
.flow-tutorial {
  position: absolute; inset: 0;
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  background: rgba(4,16,28,0.72); text-align: center; padding: 30px;
  z-index: 8; backdrop-filter: blur(6px);
}
.flow-tut-title { font-family: var(--display); font-weight: 300; font-size: 30px; margin-bottom: 12px; color: #fff; }
.flow-tut-sub { color: rgba(255,255,255,0.75); font-size: 15px; line-height: 1.7; max-width: 320px; margin-bottom: 30px; }

/* ---------- flow timer ---------- */
.flowtimer .ft-body { flex: 1; display: flex; flex-direction: column; align-items: center; justify-content: center; padding: 0 30px; position: relative; }
.ft-phrase { font-family: var(--display); font-style: italic; font-size: 20px; color: var(--ink-soft); text-align: center; margin-bottom: 40px; line-height: 1.6; }
.ft-orbit { position: relative; width: 300px; height: 300px; margin: 0 auto 30px; display: flex; align-items: center; justify-content: center; }
.ft-blob { width: 70%; height: 70%; object-fit: contain; opacity: 0.9; filter: drop-shadow(0 10px 40px rgba(77,159,216,0.35)); transition: transform 1s linear, opacity 1s linear; }
.ft-setup { text-align: center; width: 100%; }
.ft-setup-label { color: var(--ink-soft); font-size: 14px; margin-bottom: 18px; }
.ft-end { margin-top: 26px; }

/* ---------- resonance ---------- */
.resonance { background: #05070c; }
.res-modes { display: flex; gap: 8px; justify-content: center; padding: 12px 14px 4px; position: relative; z-index: 6; flex-wrap: wrap; }
.res-mode {
  padding: 9px 16px; border-radius: 100px;
  border: 1px solid rgba(255,255,255,0.14); color: rgba(255,255,255,0.6);
  font-size: 12px; letter-spacing: 0.06em;
}
.res-mode.active { border-color: #4fb8a4; color: #4fb8a4; background: rgba(79,184,164,0.12); }
.res-stage { flex: 1; position: relative; min-height: 0; }
.res-hud { position: absolute; top: 14px; left: 0; right: 0; text-align: center; pointer-events: none; color: rgba(255,255,255,0.6); font-size: 13px; }
.res-footer { display: flex; justify-content: space-between; align-items: center; padding: 12px 18px max(18px, env(safe-area-inset-bottom)); }
.res-footer .btn { color: rgba(255,255,255,0.75); border-color: rgba(255,255,255,0.2); background: rgba(255,255,255,0.05); }

/* ---------- sleep ---------- */
.sleep-screen { background: #02040c; touch-action: none; }
#sleep-canvas, #letgo-canvas { position: absolute; inset: 0; width: 100%; height: 100%; display: block; touch-action: none; }
.sleep-frames {
  position: absolute; inset: 0;
  display: flex; align-items: center; justify-content: center;
  pointer-events: none;
}
.sleep-frames img {
  width: min(60vw, 260px); height: auto;
  opacity: 0.5;
  filter: drop-shadow(0 8px 30px rgba(120,170,255,0.25));
}
.sleep-ui { position: absolute; inset: 0; display: flex; flex-direction: column; align-items: center; justify-content: center; text-align: center; pointer-events: none; padding: 0 30px; }
.sleep-title { font-family: var(--display); font-weight: 300; font-size: 32px; color: rgba(233,240,250,0.92); }
.sleep-taps { font-family: var(--display); font-size: 52px; font-weight: 300; color: rgba(233,240,250,0.55); margin: 16px 0; }
.sleep-sub { color: rgba(200,215,235,0.75); font-size: 15px; }
.sleep-tip { margin-top: 20px; font-size: 12px; color: rgba(200,215,235,0.45); letter-spacing: 0.08em; }
.sleep-controls { position: absolute; bottom: max(24px, env(safe-area-inset-bottom)); left: 0; right: 0; display: flex; justify-content: flex-end; padding: 0 20px; z-index: 6; }
.sleep-asleep { position: absolute; inset: 0; z-index: 9; display: flex; flex-direction: column; align-items: center; justify-content: center; background: rgba(2,4,12,0.82); text-align: center; padding: 30px; }

/* ---------- breathe ---------- */
.breathe-body { flex: 1; display: flex; flex-direction: column; align-items: center; justify-content: center; padding: 0 30px; position: relative; }
.breathe-orbit { position: relative; width: 260px; height: 260px; margin-bottom: 30px; display: flex; align-items: center; justify-content: center; }
.breathe-ring {
  width: 110px; height: 110px; border-radius: 50%;
  background: radial-gradient(circle at 35% 35%, rgba(79,184,164,0.95), rgba(46,143,123,0.5));
  box-shadow: 0 0 60px rgba(79,184,164,0.5);
  transition: transform 4s ease-in-out, background 4s ease-in-out;
}
.breathe-ring.hold { background: radial-gradient(circle at 35% 35%, rgba(224,180,106,0.95), rgba(180,130,60,0.5)); box-shadow: 0 0 60px rgba(224,180,106,0.5); }
.breathe-phrase { position: absolute; font-family: var(--display); font-size: 22px; font-style: italic; color: var(--ink); }

/* ---------- let go ---------- */
.letgo { background: #04101c; touch-action: none; }
.letgo-ui { position: absolute; top: 12%; left: 0; right: 0; text-align: center; pointer-events: none; }
.letgo-title { font-family: var(--display); font-weight: 300; font-size: 36px; color: #fff; }
.letgo-sub { color: rgba(255,255,255,0.7); font-size: 15px; margin-top: 8px; padding: 0 26px; }
.letgo-controls { position: absolute; bottom: max(24px, env(safe-area-inset-bottom)); left: 0; right: 0; display: flex; justify-content: space-between; padding: 0 20px; z-index: 6; }

/* ---------- session end ---------- */
.end { align-items: center; justify-content: center; }
.end-body { text-align: center; padding: 0 30px; width: 100%; max-width: 420px; position: relative; }
.end-glow {
  width: 150px; height: 150px; border-radius: 50%;
  margin: 0 auto 26px;
  background: radial-gradient(circle, rgba(79,184,164,0.4), transparent 70%);
  animation: pulse 3s ease-in-out infinite;
}
@keyframes pulse { 0%,100% { transform: scale(1); opacity: 0.9; } 50% { transform: scale(1.25); opacity: 0.5; } }
.end-title { font-family: var(--display); font-weight: 300; font-size: 34px; line-height: 1.2; color: var(--ink); }
.end-well { color: var(--teal); letter-spacing: 0.3em; text-transform: uppercase; font-size: 12px; margin-top: 10px; font-weight: 600; }
.end-stats { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; margin: 28px 0; }
.end-stat { background: var(--surface); border: 1px solid var(--line); border-radius: 16px; padding: 14px 6px; }
.end-stat-num { font-family: var(--display); font-size: 26px; font-weight: 300; color: var(--ink); display: block; }
.end-stat-lbl { font-size: 10px; letter-spacing: 0.16em; text-transform: uppercase; color: var(--ink-faint); margin-top: 4px; }
.end-notes { text-align: left; }
.end-mood { margin-top: 14px; text-align: center; }
.end-mood-label { font-size: 12px; color: var(--ink-soft); margin-bottom: 10px; letter-spacing: 0.08em; }
.star-row { display: flex; justify-content: center; gap: 10px; }
.star { font-size: 30px; color: var(--line-strong); cursor: pointer; transition: color 0.2s, transform 0.15s; }
.star.on { color: var(--gold); }
.star:active { transform: scale(1.2); }

/* ---------- stats ---------- */
.stats-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 10px; margin-bottom: 28px; }
.stat-cell { background: var(--surface); border: 1px solid var(--line); border-radius: 16px; padding: 16px 14px; }
.stat-cell-num { font-family: var(--display); font-size: 28px; font-weight: 300; color: var(--ink); display: block; }
.stat-cell-lbl { font-size: 10px; letter-spacing: 0.16em; text-transform: uppercase; color: var(--ink-faint); margin-top: 4px; }
.section-label { font-size: 11px; letter-spacing: 0.28em; text-transform: uppercase; color: var(--ink-faint); margin: 6px 0 14px; }
.bar-chart { display: flex; align-items: flex-end; gap: 8px; height: 130px; margin: 6px 0 30px; }
.bar { flex: 1; background: linear-gradient(180deg, var(--teal), rgba(79,184,164,0.2)); border-radius: 6px 6px 2px 2px; position: relative; min-height: 3px; }
.bar.empty { background: var(--line); }
.bar-label { position: absolute; bottom: -20px; left: 50%; transform: translateX(-50%); font-size: 10px; color: var(--ink-faint); }
.history-list { display: flex; flex-direction: column; gap: 10px; }
.history-item { display: flex; align-items: center; gap: 12px; padding: 13px 16px; background: var(--surface); border: 1px solid var(--line); border-radius: 16px; }
.history-orb { width: 34px; height: 34px; border-radius: 50%; flex-shrink: 0; background: radial-gradient(circle at 32% 30%, #fff, rgba(255,255,255,0.85)); }
.history-meta { flex: 1; }
.history-practice { font-size: 14px; color: var(--ink); }
.history-date { font-size: 11px; color: var(--ink-faint); margin-top: 2px; }
.history-dur { font-family: var(--display); font-size: 18px; color: var(--teal); }

/* ---------- settings ---------- */
.settings-group { margin-bottom: 28px; }
.settings-label { font-size: 11px; letter-spacing: 0.26em; text-transform: uppercase; color: var(--ink-faint); margin: 4px 0 12px; }
.setting-row { display: flex; align-items: center; justify-content: space-between; padding: 15px 2px; border-bottom: 1px solid var(--line); gap: 14px; }
.setting-name { font-size: 15px; color: var(--ink); }
.setting-desc { font-size: 12px; color: var(--ink-faint); margin-top: 3px; }
.switch { position: relative; width: 48px; height: 27px; flex-shrink: 0; }
.switch input { display: none; }
.switch-track { position: absolute; inset: 0; background: var(--bg-deep); border: 1px solid var(--line); border-radius: 100px; transition: background 0.25s; }
.switch-track::after { content: ''; position: absolute; top: 2.5px; left: 3px; width: 20px; height: 20px; border-radius: 50%; background: #fff; box-shadow: 0 2px 6px rgba(13,51,85,0.25); transition: transform 0.25s; }
.switch input:checked + .switch-track { background: var(--teal); }
.switch input:checked + .switch-track::after { transform: translateX(21px); }
.theme-row { display: flex; gap: 10px; flex-wrap: wrap; }
.theme-swatch { width: 44px; height: 44px; border-radius: 50%; border: 3px solid transparent; position: relative; }
.theme-swatch.active { border-color: var(--ink); }
.difficulty-row { display: flex; gap: 10px; flex-wrap: wrap; }
.list-btn { width: 100%; text-align: left; padding: 16px 4px; border-bottom: 1px solid var(--line); font-size: 15px; color: var(--ink-soft); display: flex; justify-content: space-between; align-items: center; }

/* ---------- account / news / about ---------- */
.account-hero { text-align: center; margin-top: 10px; background: linear-gradient(160deg, rgba(77,159,216,0.12), rgba(233,140,176,0.1)); border: 1px solid var(--line); border-radius: 22px; padding: 30px 22px; }
.account-title { font-family: var(--display); font-weight: 300; font-size: 28px; margin-bottom: 10px; color: var(--ink); }
.account-sub { color: var(--ink-soft); font-size: 14px; line-height: 1.6; margin-bottom: 24px; }
.account-links { margin-top: 20px; }
.news { text-align: center; }
.news-title { font-family: var(--display); font-weight: 300; font-size: 30px; margin: 26px 0 12px; color: var(--ink); }
.news-sub { color: var(--ink-soft); font-size: 14px; line-height: 1.7; margin-bottom: 30px; }
.news-form { max-width: 360px; margin: 0 auto; }
.news-thanks { margin-top: 20px; color: var(--teal); font-size: 14px; line-height: 1.6; }
.about { text-align: center; }
.about-logo { font-size: 54px; margin: 34px 0 26px; }
.about-text { color: var(--ink-soft); font-size: 15px; line-height: 1.9; max-width: 460px; margin: 0 auto; }
.about-credits { margin-top: 30px; font-size: 12px; color: var(--ink-faint); letter-spacing: 0.2em; text-transform: uppercase; }
.about-font { margin-top: 10px; font-size: 13px; color: var(--ink-faint); }
.about-foot { margin-top: 40px; font-size: 12px; color: var(--ink-faint); letter-spacing: 0.3em; text-transform: uppercase; }

/* ---------- install gate ---------- */
.install {
  background: radial-gradient(130% 100% at 50% 20%, #eef5f8 0%, var(--bg) 60%);
  align-items: center;
  justify-content: center;
}
.install-inner {
  text-align: center;
  padding: 30px;
  width: 100%;
  max-width: 380px;
}
.install-icon {
  width: 96px;
  height: 96px;
  border-radius: 24px;
  box-shadow: var(--shadow);
  margin-bottom: 18px;
}
.install-logo {
  font-size: 44px;
  margin-bottom: 18px;
}
.install-msg {
  color: var(--ink-soft);
  font-size: 16px;
  line-height: 1.8;
  margin-bottom: 30px;
}
.install-actions {
  margin-bottom: 22px;
}
.install-help {
  color: var(--ink-faint);
  font-size: 13px;
  line-height: 1.9;
  padding: 0 8px;
}
.install-help .step {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 12px;
  text-align: left;
}
.install-help .step-num {
  flex-shrink: 0;
  width: 26px;
  height: 26px;
  border-radius: 50%;
  background: var(--surface);
  border: 1px solid var(--line-strong);
  color: var(--ink);
  font-weight: 700;
  font-size: 13px;
  display: flex;
  align-items: center;
  justify-content: center;
}
.install-help .step-txt { color: var(--ink-soft); }
.install-help a { color: var(--teal); text-decoration: none; font-weight: 600; }

/* ---------- toast ---------- */
.toast {
  position: fixed; bottom: 30px; left: 50%;
  transform: translateX(-50%) translateY(80px);
  background: var(--ink); color: #fff;
  padding: 13px 24px; border-radius: 100px;
  font-size: 14px; z-index: 100;
  transition: transform 0.35s cubic-bezier(0.2,0.8,0.2,1);
  max-width: 86vw; text-align: center; pointer-events: none;
  box-shadow: var(--shadow);
}
.toast.show { transform: translateX(-50%) translateY(0); }

@media (min-width: 640px) {
  .app { max-width: 520px; margin: 0 auto; border-left: 1px solid var(--line); border-right: 1px solid var(--line); }
  body { background: var(--bg-deep); }
}
