/* ─────────────────────────────────────────────
   보디야나 명상 — 홈페이지와 같은 색
   한지 빛 바탕 · 먹색 글씨 · 붉은 낙관 · 청사포 바다
   ───────────────────────────────────────────── */
:root {
  --paper: #fbf7f0;
  --paper-2: #f4ede2;
  --paper-3: #ebe2d3;
  --card: #fffdf9;
  --ink: #2b2420;
  --ink-2: #574c43;
  --ink-3: #6e6258;
  --line: #e6dccc;
  --line-2: #d6c9b5;
  --seal: #cd171c;
  --accent: #b3261e;
  --accent-soft: #f7e4dc;
  --sea: #2a5f6d;
  --sea-soft: #e0ecee;
  --night: #191512;
  --night-2: #241e1a;
  --night-3: #322a24;
  --night-ink: #f3ebe0;
  --night-ink-2: #c4b7a8;
  --radius: 22px;
  --radius-sm: 14px;
  --shadow: 0 1px 2px rgba(43, 36, 32, .05), 0 14px 32px -18px rgba(43, 36, 32, .30);
  --serif: "Noto Serif KR", "AppleMyungjo", serif;
  --sans: "Noto Sans KR", -apple-system, BlinkMacSystemFont, "Apple SD Gothic Neo", "Malgun Gothic", sans-serif;
  --fs: 1;
  --tabs-h: 64px;
  --safe-b: env(safe-area-inset-bottom, 0px);
  --safe-t: env(safe-area-inset-top, 0px);
  --grain: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='180' height='180'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.85' numOctaves='2' stitchTiles='stitch'/%3E%3CfeColorMatrix values='0 0 0 0 .32 0 0 0 0 .25 0 0 0 0 .18 0 0 0 .07 0'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
}

*, *::before, *::after { box-sizing: border-box; }
[hidden] { display: none !important; }
html { font-size: calc(16px * var(--fs)); -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--paper) var(--grain);
  color: var(--ink);
  font-family: var(--sans);
  font-size: 1.0625rem;
  line-height: 1.7;
  word-break: keep-all;
  overflow-wrap: break-word;
  -webkit-font-smoothing: antialiased;
  -webkit-tap-highlight-color: transparent;
}
button, input { font: inherit; color: inherit; }
button { cursor: pointer; }
a { color: inherit; }
img { display: block; max-width: 100%; }
svg { width: 24px; height: 24px; fill: none; stroke: currentColor; stroke-width: 1.7; stroke-linecap: round; stroke-linejoin: round; flex: none; }
svg .fill { fill: currentColor; stroke: none; }
svg .t { font: 600 8.5px var(--sans); fill: currentColor; stroke: none; letter-spacing: -.3px; }
svg.flip { transform: scaleX(-1); }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
:focus-visible { outline: 2.5px solid var(--sea); outline-offset: 2px; border-radius: 8px; }

/* ── 뼈대 ── */
.app { max-width: 560px; margin: 0 auto; min-height: 100vh; min-height: 100dvh; padding-bottom: calc(var(--tabs-h) + var(--safe-b) + 24px); }
.top {
  position: sticky; top: 0; z-index: 20;
  display: flex; align-items: center; justify-content: space-between;
  padding: calc(10px + var(--safe-t)) 16px 10px;
  background: rgba(251, 247, 240, .9);
  backdrop-filter: blur(12px); -webkit-backdrop-filter: blur(12px);
}
.brand { display: flex; align-items: center; gap: 10px; text-decoration: none; }
.brand img { width: 30px; height: auto; }
.brand-name { font-family: var(--serif); font-weight: 600; font-size: 1.12rem; letter-spacing: -.01em; }
.icon-btn {
  display: inline-grid; place-items: center; width: 44px; height: 44px; border-radius: 50%;
  background: transparent; border: 0; color: var(--ink-2);
}
.icon-btn:active { background: var(--paper-2); }
.icon-btn.lg svg { width: 34px; height: 34px; }
.icon-btn-space { width: 44px; }
main { padding: 4px 16px 0; }
.view { animation: fadein .35s ease; }
@keyframes fadein { from { opacity: 0; transform: translateY(6px); } to { opacity: 1; transform: none; } }

.view-title { font-family: var(--serif); font-weight: 600; font-size: 1.6rem; line-height: 1.35; margin: 10px 0 4px; letter-spacing: -.02em; }
.view-lead { color: var(--ink-3); margin: 0 0 22px; font-size: .98rem; }
.group-title { font-family: var(--serif); font-weight: 600; font-size: 1.18rem; margin: 30px 0 4px; display: flex; align-items: center; gap: 8px; }
.group-title svg { color: var(--seal); width: 22px; height: 22px; }
.group-lead { color: var(--ink-3); margin: 0 0 12px; font-size: .92rem; }
.eyebrow { margin: 0 0 6px; font-size: .82rem; font-weight: 700; letter-spacing: .08em; color: var(--seal); }
.label { margin: 0 0 8px; font-weight: 700; font-size: .98rem; display: flex; align-items: center; gap: 6px; flex-wrap: wrap; }
.label.sm { font-size: .9rem; margin-top: 14px; }
.label.center { justify-content: center; }
.label .ic { width: 20px; height: 20px; color: var(--seal); }
.hint { font-weight: 400; color: var(--ink-3); font-size: .85rem; }
.hint-block { margin: 2px 0 0; color: var(--ink-3); font-size: .9rem; line-height: 1.6; }
.warn { margin: 12px 0 0; padding: 10px 12px; border-radius: 12px; background: var(--paper-2); color: var(--ink-2); font-size: .88rem; line-height: 1.6; }
.row { display: flex; gap: 10px; align-items: center; }
.row.wrap { flex-wrap: wrap; }

/* ── 버튼 ── */
.btn-primary {
  display: flex; align-items: center; justify-content: center; gap: 8px;
  width: 100%; min-height: 54px; padding: 12px 20px;
  border: 0; border-radius: 999px;
  background: var(--ink); color: #fff; font-weight: 700; font-size: 1.05rem;
  box-shadow: 0 10px 24px -14px rgba(43, 36, 32, .7);
}
.btn-primary:active { transform: scale(.985); }
.btn-primary.big { min-height: 62px; font-size: 1.15rem; margin-top: 6px; }
.btn-ghost {
  display: inline-flex; align-items: center; justify-content: center; gap: 6px;
  min-height: 48px; padding: 10px 18px; border-radius: 999px;
  border: 1.5px solid var(--line-2); background: var(--card); color: var(--ink); font-weight: 500;
}
.btn-ghost svg { width: 20px; height: 20px; }
.btn-ghost.sm { min-height: 42px; padding: 8px 14px; font-size: .92rem; }
.btn-ghost.file { position: relative; overflow: hidden; }
.btn-ghost.file input { position: absolute; inset: 0; opacity: 0; cursor: pointer; }
#add-manual { width: 100%; margin-top: 18px; }
.text-btn {
  display: inline-flex; align-items: center; gap: 6px; min-height: 44px; padding: 8px 4px;
  border: 0; background: none; color: var(--sea); font-weight: 700; font-size: .95rem; text-decoration: none;
}
.text-btn svg { width: 19px; height: 19px; }
.text-btn.small { font-size: .88rem; min-height: 38px; }
.text-btn.muted { color: var(--ink-3); font-weight: 500; }

/* ── 고르기 칩 ── */
.chips { display: flex; flex-wrap: wrap; gap: 8px; }
.chip {
  min-height: 46px; min-width: 64px; padding: 8px 16px; border-radius: 999px;
  border: 1.5px solid var(--line-2); background: var(--card); color: var(--ink-2); font-weight: 500; font-size: .98rem;
}
.chip[aria-checked="true"] { background: var(--ink); border-color: var(--ink); color: #fff; font-weight: 700; }
.field { margin-bottom: 22px; }
.stepper { display: flex; align-items: center; gap: 12px; margin-top: 12px; }
.step { width: 52px; height: 52px; border-radius: 50%; border: 1.5px solid var(--line-2); background: var(--card); font-size: 1.5rem; line-height: 1; }
.stepper output { min-width: 84px; text-align: center; font-size: 1.3rem; font-weight: 700; }
.sit-note { color: var(--ink-3); font-size: .9rem; margin: 6px 0 14px; }

/* ── 오늘 ── */
.greet { margin: 6px 0 14px; color: var(--ink-3); font-size: .98rem; }
.quote-card {
  position: relative; padding: 26px 22px 12px; border-radius: var(--radius);
  background: var(--card); box-shadow: var(--shadow); border: 1px solid var(--line);
}
.quote-card::before {
  content: ""; position: absolute; left: 22px; top: 0; width: 34px; height: 3px; background: var(--seal); border-radius: 0 0 3px 3px;
}
.quote { margin: 0; font-family: var(--serif); font-weight: 500; font-size: 1.3rem; line-height: 1.75; letter-spacing: -.01em; color: var(--ink); min-height: 4.5em; }
.quote-by { margin: 14px 0 0; color: var(--ink-3); font-size: .92rem; }
.quote-by::before { content: "— "; }
.quote-actions { display: flex; justify-content: space-between; margin-top: 6px; border-top: 1px solid var(--line); padding-top: 2px; }
.today-stats { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; margin: 16px 0; }
.stat { padding: 12px 10px; border-radius: var(--radius-sm); background: var(--paper-2); text-align: center; }
.stat b { display: block; font-size: 1.3rem; line-height: 1.3; font-weight: 700; }
.stat span { font-size: .78rem; color: var(--ink-3); white-space: nowrap; }
.quick { display: grid; gap: 10px; }
.quick-main {
  display: flex; align-items: center; gap: 14px; width: 100%; padding: 12px 14px 12px 12px; text-align: left;
  border: 0; border-radius: var(--radius); background: var(--ink); color: #fff; box-shadow: var(--shadow);
}
.qm-img { width: 74px; height: 74px; border-radius: 16px; flex: none; background: url(../img/sea-window-800.jpg) 40% 60% / cover; }
.qm-body { flex: 1; display: grid; }
.qm-title { font-family: var(--serif); font-size: 1.35rem; font-weight: 600; }
.qm-sub { font-size: .9rem; color: #d9cfc3; }
.qm-go { width: 52px; height: 52px; border-radius: 50%; background: #fff; color: var(--ink); display: grid; place-items: center; flex: none; }
.qm-go svg { width: 26px; height: 26px; margin-left: 3px; }
.quick-row { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.quick-small {
  display: grid; align-content: start; gap: 2px; padding: 14px; min-height: 96px; text-align: left;
  border-radius: var(--radius); border: 1px solid var(--line); background: var(--card); box-shadow: var(--shadow);
}
.quick-small svg { width: 22px; height: 22px; margin-bottom: 4px; }
.quick-small.night { background: var(--night-2); color: var(--night-ink); border-color: var(--night-2); }
.qs-title { font-weight: 700; font-size: 1rem; }
.qs-sub { font-size: .84rem; color: var(--ink-3); }
.quick-small.night .qs-sub { color: var(--night-ink-2); }
.install-tip { margin-top: 16px; padding: 12px 16px; border-radius: var(--radius-sm); background: var(--sea-soft); }
.install-tip p { margin: 0; font-size: .95rem; }
.learn-teaser {
  display: flex; align-items: center; gap: 10px; margin-top: 16px; padding: 16px; border-radius: var(--radius);
  background: var(--paper-2); text-decoration: none;
}
.lt-k { font-size: .8rem; font-weight: 700; color: var(--seal); white-space: nowrap; }
.lt-t { flex: 1; font-weight: 700; }
.learn-teaser svg { color: var(--ink-3); }

/* ── 안내 명상 목록 ── */
.track {
  display: flex; align-items: center; gap: 14px; width: 100%; margin-bottom: 10px; padding: 14px; text-align: left;
  border-radius: var(--radius-sm); border: 1px solid var(--line); background: var(--card);
}
.track:active { background: var(--paper-2); }
.track-play { width: 46px; height: 46px; border-radius: 50%; background: var(--paper-2); color: var(--ink); display: grid; place-items: center; flex: none; }
.track-play svg { width: 22px; height: 22px; margin-left: 2px; }
.track.night .track-play { background: var(--night-2); color: var(--night-ink); }
.track-body { flex: 1; display: grid; gap: 1px; }
.track-title { font-weight: 700; font-size: 1.02rem; line-height: 1.45; }
.track-sub { font-size: .86rem; color: var(--ink-3); line-height: 1.5; }
.track-meta { display: flex; gap: 8px; align-items: center; font-size: .8rem; color: var(--ink-3); margin-top: 3px; }
.saved-mark { color: var(--sea); font-weight: 700; display: inline-flex; align-items: center; gap: 2px; }
.saved-mark svg { width: 15px; height: 15px; stroke-width: 2.4; }
.track.offline { opacity: .55; }
.need-net { color: var(--accent); font-weight: 700; }
.vid-group { margin-bottom: 14px; }
.vid-kind { font-weight: 700; font-size: .95rem; margin: 0 0 6px; }

/* ── 배우기 ── */
.course { padding: 20px; border-radius: var(--radius); background: var(--card); border: 1px solid var(--line); box-shadow: var(--shadow); }
.course h2 { margin: 0 0 12px; font-family: var(--serif); font-size: 1.25rem; font-weight: 600; }
.lesson { display: flex; align-items: center; gap: 12px; padding: 12px 0; border-top: 1px solid var(--line); text-decoration: none; }
.lesson-n { width: 40px; height: 40px; border-radius: 12px; display: grid; place-items: center; background: var(--seal); color: #fff; font-weight: 700; flex: none; }
.lesson-t { flex: 1; font-weight: 700; }
.lesson svg { color: var(--ink-3); width: 20px; height: 20px; }
.course-note { margin: 10px 0 0; font-size: .88rem; color: var(--ink-3); }
.before { display: grid; gap: 10px; }
.before-item { padding: 16px 18px; border-radius: var(--radius-sm); background: var(--paper-2); }
.before-item h3 { margin: 0 0 4px; font-size: .85rem; color: var(--seal); letter-spacing: .04em; }
.before-item p { margin: 0; font-family: var(--serif); font-size: 1.04rem; line-height: 1.75; }

/* ── 기록 ── */
.log-summary { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; margin: 8px 0 18px; }
.cal { padding: 14px 12px 10px; border-radius: var(--radius); background: var(--card); border: 1px solid var(--line); }
.cal-head { display: flex; align-items: center; justify-content: space-between; margin-bottom: 6px; }
.cal-title { margin: 0; font-weight: 700; font-size: 1.05rem; }
.cal-grid { display: grid; grid-template-columns: repeat(7, 1fr); gap: 2px; text-align: center; }
.cal-dow { font-size: .76rem; color: var(--ink-3); padding: 4px 0; }
.cal-dow:first-child { color: var(--accent); }
.cal-day {
  position: relative; aspect-ratio: 1; display: grid; place-items: center; border: 0; background: none; border-radius: 50%;
  font-size: .92rem; color: var(--ink-2); padding: 0;
}
.cal-day.empty { visibility: hidden; }
.cal-day.today { box-shadow: inset 0 0 0 1.5px var(--ink-3); }
.cal-day.sat { background: var(--seal); color: #fff; font-weight: 700; }
.cal-day.sat.long::after { content: ""; position: absolute; bottom: 4px; width: 4px; height: 4px; border-radius: 50%; background: #fff; }
.cal-day.sel { outline: 2.5px solid var(--sea); outline-offset: 1px; }
.cal-day.future { color: var(--line-2); }
.day-detail { margin-top: 14px; }
.day-detail h3 { font-size: 1rem; margin: 0 0 8px; }
.entry { display: flex; gap: 12px; align-items: center; padding: 12px 14px; border-radius: var(--radius-sm); background: var(--card); border: 1px solid var(--line); margin-bottom: 8px; }
.entry-w { width: 36px; height: 36px; flex: none; }
.entry-w svg { width: 36px; height: 36px; }
.entry-b { flex: 1; min-width: 0; }
.entry-t { font-weight: 700; font-size: .96rem; }
.entry-s { font-size: .84rem; color: var(--ink-3); }
.entry-n { font-size: .9rem; color: var(--ink-2); margin-top: 2px; }
.entry-del { color: var(--ink-3); }
.empty-note { color: var(--ink-3); font-size: .92rem; margin: 6px 2px; }
.log-note { color: var(--ink-3); font-size: .84rem; margin-top: 12px; }

/* 날씨 그림 */
.sun { color: #d9822b; stroke: #d9822b; }
.cloud { color: #9aa6ad; }
.drop { stroke: #4b83a0; stroke-width: 2; }
.wind { stroke: #6e8f8a; stroke-width: 2; }

/* ── 아래 메뉴 ── */
.tabs {
  position: fixed; left: 0; right: 0; bottom: 0; z-index: 30;
  display: grid; grid-template-columns: repeat(5, 1fr);
  max-width: 560px; margin: 0 auto;
  padding: 4px 4px calc(4px + var(--safe-b));
  background: rgba(251, 247, 240, .96); border-top: 1px solid var(--line);
  backdrop-filter: blur(12px); -webkit-backdrop-filter: blur(12px);
}
.tabs a { display: grid; justify-items: center; gap: 1px; padding: 7px 0 5px; text-decoration: none; color: var(--ink-3); font-size: .74rem; font-weight: 500; border-radius: 12px; }
.tabs a svg { width: 25px; height: 25px; }
.tabs a[aria-current="page"] { color: var(--ink); font-weight: 700; }
.tabs a[aria-current="page"] svg { color: var(--seal); stroke-width: 2; }

/* ── 덮는 화면 ── */
.overlay { position: fixed; inset: 0; z-index: 50; display: flex; flex-direction: column; overflow-y: auto; }
.night { background: var(--night); color: var(--night-ink); }

/* 앉는 중 */
#session { justify-content: space-between; align-items: center; padding: calc(40px + var(--safe-t)) 24px calc(28px + var(--safe-b)); text-align: center; }
.sess-inner { flex: 1; display: grid; place-content: center; justify-items: center; gap: 8px; width: 100%; }
.sess-phase { margin: 0 0 26px; font-family: var(--serif); font-size: 1.15rem; color: var(--night-ink-2); min-height: 1.7em; }
.ring { position: relative; width: min(62vw, 240px); aspect-ratio: 1; border-radius: 50%; border: 1px solid rgba(243, 235, 224, .14); display: grid; place-items: center; }
.ring-glow { width: 58%; aspect-ratio: 1; border-radius: 50%; background: radial-gradient(circle, rgba(232, 188, 140, .36), rgba(232, 188, 140, 0) 70%); animation: glow 11s ease-in-out infinite; }
@keyframes glow { 0%, 100% { transform: scale(.82); opacity: .55; } 50% { transform: scale(1.18); opacity: 1; } }
.sess-time { margin: 26px 0 0; font-size: 3rem; font-weight: 300; letter-spacing: .04em; font-variant-numeric: tabular-nums; }
.sess-sub { margin: 0; color: var(--night-ink-2); font-size: .92rem; min-height: 1.6em; }
#session.hide-time .sess-time, #session.hide-time .sess-sub { visibility: hidden; }
.sess-actions { display: flex; gap: 12px; width: 100%; max-width: 420px; }
.btn-night { flex: 1; min-height: 54px; border-radius: 999px; border: 1px solid rgba(243, 235, 224, .22); background: var(--night-2); color: var(--night-ink); font-weight: 500; }
.sess-hide { margin-top: 10px; min-height: 40px; border: 0; background: none; color: #8f8377; font-size: .88rem; }
#session.dim .sess-inner, #session.dim .sess-actions, #session.dim .sess-hide { opacity: .35; transition: opacity 1.2s; }

/* 재생 화면 */
.player { background: var(--paper) var(--grain); color: var(--ink); }
.player.night { background: var(--night); color: var(--night-ink); }
.pl-top { display: flex; align-items: center; justify-content: space-between; padding: calc(8px + var(--safe-t)) 10px 4px; }
.pl-kicker { margin: 0; font-size: .86rem; font-weight: 700; color: var(--ink-3); }
.player.night .pl-kicker, .player.night .icon-btn { color: var(--night-ink-2); }
.pl-body { flex: 1; display: flex; flex-direction: column; align-items: center; padding: 10px 24px calc(24px + var(--safe-b)); max-width: 520px; width: 100%; margin: 0 auto; text-align: center; }
.pl-art { width: min(58vw, 230px); aspect-ratio: 1; border-radius: 30px; display: grid; place-items: center; margin: 14px 0 24px; background: var(--card) url(../img/sea-window-800.jpg) 40% 60% / cover; box-shadow: var(--shadow); position: relative; overflow: hidden; }
.pl-moon { display: none; }
.player.night .pl-art { background: radial-gradient(circle at 30% 25%, #3a3029, var(--night-2)); }
.player.night .pl-moon { display: block; width: 34%; height: 34%; color: #e8bc8c; stroke-width: 1.2; }
.pl-title { margin: 0; font-family: var(--serif); font-weight: 600; font-size: 1.4rem; line-height: 1.45; }
.pl-sub { margin: 4px 0 0; color: var(--ink-3); font-size: .94rem; }
.player.night .pl-sub, .player.night .pl-part { color: var(--night-ink-2); }
.pl-part { margin: 14px 0 0; min-height: 1.6em; font-weight: 700; color: var(--seal); font-size: .95rem; }
.pl-bar { position: relative; width: 100%; margin-top: 16px; }
.pl-bar input[type=range] { width: 100%; margin: 0; }
.pl-marks { position: absolute; left: 0; right: 0; top: 0; height: 28px; pointer-events: none; }
.pl-marks i { position: absolute; top: 9px; width: 2px; height: 10px; background: var(--line-2); border-radius: 1px; }
.pl-times { display: flex; justify-content: space-between; font-size: .84rem; color: var(--ink-3); font-variant-numeric: tabular-nums; }
.pl-ctrl { display: flex; align-items: center; justify-content: center; gap: 18px; margin: 16px 0 10px; }
.skip-btn { display: inline-flex; align-items: center; gap: 3px; min-height: 48px; padding: 6px 8px; border: 0; background: none; color: var(--ink-2); font-size: .9rem; font-weight: 700; font-variant-numeric: tabular-nums; }
.skip-btn svg { width: 24px; height: 24px; stroke-width: 1.9; }
.player.night .skip-btn { color: var(--night-ink-2); }
.play-btn { width: 78px; height: 78px; border-radius: 50%; border: 0; display: grid; place-items: center; background: var(--ink); color: #fff; box-shadow: 0 14px 30px -14px rgba(43,36,32,.8); }
.play-btn svg { width: 34px; height: 34px; }
.play-btn.is-play svg { margin-left: 4px; }
.player.night .play-btn { background: var(--night-ink); color: var(--night); }
.pl-extra { display: flex; justify-content: center; gap: 18px; flex-wrap: wrap; }
.player.night .text-btn { color: #a9c7cf; }

input[type=range] { -webkit-appearance: none; appearance: none; height: 28px; background: transparent; accent-color: var(--ink); }
input[type=range]::-webkit-slider-runnable-track { height: 4px; border-radius: 4px; background: var(--line-2); }
input[type=range]::-webkit-slider-thumb { -webkit-appearance: none; width: 20px; height: 20px; margin-top: -8px; border-radius: 50%; background: var(--ink); border: 3px solid var(--card); box-shadow: 0 1px 4px rgba(0,0,0,.25); }
input[type=range]::-moz-range-track { height: 4px; border-radius: 4px; background: var(--line-2); }
input[type=range]::-moz-range-thumb { width: 16px; height: 16px; border-radius: 50%; background: var(--ink); border: 3px solid var(--card); }
.player.night input[type=range]::-webkit-slider-runnable-track { background: var(--night-3); }
.player.night input[type=range]::-webkit-slider-thumb { background: var(--night-ink); border-color: var(--night); }

/* 작은 재생 막대 */
.mini {
  position: fixed; left: 50%; transform: translateX(-50%); bottom: calc(var(--tabs-h) + var(--safe-b) + 8px); z-index: 35;
  width: calc(100% - 24px); max-width: 536px; display: flex; align-items: center; gap: 10px;
  padding: 8px 8px 8px 16px; border-radius: 18px; border: 0; text-align: left;
  background: var(--ink); color: #fff; box-shadow: 0 12px 30px -12px rgba(0,0,0,.5);
}
.mini-title { flex: 1; font-weight: 700; font-size: .92rem; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.mini-time { font-size: .82rem; color: #d9cfc3; font-variant-numeric: tabular-nums; }
.mini-play { width: 42px; height: 42px; border-radius: 50%; background: #fff; color: var(--ink); display: grid; place-items: center; }
.mini-play svg { width: 20px; height: 20px; }
body.has-mini .app { padding-bottom: calc(var(--tabs-h) + var(--safe-b) + 90px); }

/* 마치고 나서 */
.done { background: var(--paper) var(--grain); align-items: center; justify-content: center; padding: calc(30px + var(--safe-t)) 22px calc(30px + var(--safe-b)); }
.done-inner { width: 100%; max-width: 420px; display: grid; justify-items: center; gap: 10px; text-align: center; animation: fadein .8s ease; }
.done-seal { width: 54px; height: auto; margin-bottom: 6px; }
.done-ded { margin: 0; font-family: var(--serif); font-size: 1.5rem; font-weight: 600; line-height: 1.5; }
.done-sum { margin: 0 0 18px; color: var(--ink-3); }
.moods { display: grid; grid-template-columns: repeat(5, 1fr); gap: 6px; width: 100%; margin-bottom: 8px; }
.mood { display: grid; justify-items: center; gap: 2px; min-width: 0; padding: 8px 0 6px; white-space: nowrap; border-radius: 16px; border: 1.5px solid transparent; background: var(--card); font-size: .8rem; color: var(--ink-2); }
.mood svg { width: 36px; height: 36px; }
.mood[aria-checked="true"] { border-color: var(--ink); font-weight: 700; color: var(--ink); }
.note-field { width: 100%; }
.note-field input, .form-row input { width: 100%; min-height: 50px; padding: 10px 14px; border-radius: 14px; border: 1.5px solid var(--line-2); background: var(--card); font-size: 1rem; }
#done-save { margin-top: 8px; }

/* 영상 */
.video-ov { background: var(--paper) var(--grain); }
.vid-frame { width: 100%; max-width: 760px; margin: 0 auto; aspect-ratio: 16 / 9; background: #000; }
.vid-frame iframe { width: 100%; height: 100%; border: 0; display: block; }
.vid-body { padding: 18px 20px calc(24px + var(--safe-b)); max-width: 560px; width: 100%; margin: 0 auto; display: grid; gap: 8px; }

/* 시트 */
.sheet-back { position: fixed; inset: 0; z-index: 60; background: rgba(25, 21, 18, .45); }
.sheet {
  position: fixed; left: 0; right: 0; bottom: 0; z-index: 61; max-width: 560px; margin: 0 auto;
  max-height: 88vh; max-height: 88dvh; overflow-y: auto; overscroll-behavior: contain;
  padding: 8px 20px calc(24px + var(--safe-b)); border-radius: 26px 26px 0 0;
  background: var(--paper); box-shadow: 0 -20px 50px -20px rgba(0,0,0,.4);
  animation: up .28s ease;
}
@keyframes up { from { transform: translateY(40px); opacity: 0; } to { transform: none; opacity: 1; } }
.sheet-head { position: sticky; top: -8px; z-index: 1; display: flex; align-items: center; justify-content: space-between; padding: 12px 0 8px; background: var(--paper); }
.sheet-head h2 { margin: 0; font-family: var(--serif); font-size: 1.3rem; font-weight: 600; }
.set-group { padding: 16px 0; border-top: 1px solid var(--line); }
.switch-row { display: flex; gap: 14px; align-items: flex-start; justify-content: space-between; }
.switch { position: relative; width: 58px; height: 34px; flex: none; border-radius: 999px; border: 0; background: var(--line-2); margin-top: 2px; transition: background .2s; }
.switch span { position: absolute; top: 3px; left: 3px; width: 28px; height: 28px; border-radius: 50%; background: #fff; box-shadow: 0 1px 3px rgba(0,0,0,.25); transition: transform .2s; }
.switch[aria-checked="true"] { background: var(--sea); }
.switch[aria-checked="true"] span { transform: translateX(24px); }
.mb-next { margin: 12px 0 0; font-size: .9rem; color: var(--sea); font-weight: 700; }
.slider { display: grid; grid-template-columns: 84px 1fr; align-items: center; gap: 10px; font-size: .95rem; color: var(--ink-2); }
.about { display: flex; gap: 12px; align-items: center; padding: 18px 0 4px; border-top: 1px solid var(--line); color: var(--ink-2); font-size: .9rem; line-height: 1.6; }
.about p { margin: 0; }
.ins h3 { margin: 14px 0 6px; font-size: 1.02rem; }
.ins ol { margin: 0; padding-left: 1.3em; display: grid; gap: 4px; }
.form-row { display: grid; gap: 4px; margin-bottom: 12px; font-size: .92rem; font-weight: 700; }

/* 마음챙김 종 알림 */
.bell-toast {
  position: fixed; left: 50%; top: calc(14px + var(--safe-t)); transform: translateX(-50%); z-index: 80;
  width: calc(100% - 24px); max-width: 480px; display: flex; gap: 12px; align-items: center;
  padding: 14px 16px; border-radius: 18px; background: var(--night-2); color: var(--night-ink);
  box-shadow: 0 16px 40px -16px rgba(0,0,0,.6); animation: down .5s ease;
}
.bell-toast svg { color: #e8bc8c; width: 30px; height: 30px; }
.bt-t { margin: 0; font-weight: 700; }
.bt-s { margin: 0; font-size: .88rem; color: var(--night-ink-2); line-height: 1.5; }
@keyframes down { from { transform: translate(-50%, -20px); opacity: 0; } to { transform: translate(-50%, 0); opacity: 1; } }
.toast {
  position: fixed; left: 50%; bottom: calc(var(--tabs-h) + var(--safe-b) + 18px); transform: translateX(-50%); z-index: 90;
  max-width: calc(100% - 32px); padding: 10px 18px; border-radius: 999px; background: var(--ink); color: #fff; font-size: .92rem;
  opacity: 0; pointer-events: none; transition: opacity .25s;
}
.toast.show { opacity: 1; }

@media (min-width: 600px) {
  main { padding-top: 10px; }
  .quote { font-size: 1.4rem; }
}
@media (prefers-reduced-motion: reduce) {
  * { animation: none !important; transition: none !important; }
}
.icon-btn:disabled { opacity: .28; cursor: default; }
