@import url('https://fonts.googleapis.com/css2?family=Manrope:wght@400;500;600;650;700;750;800&display=swap');

:root {
  color-scheme: light;
  --ink: #073c5a;
  --deep: #043553;
  --muted: #366178;
  --sans: 'Manrope', 'Avenir Next', 'Segoe UI', sans-serif;
  --glass: linear-gradient(155deg, #f4ffffda, #e0f9ff9c 46%, #a9e3f4a8);
  --glass-shadow: inset 0 2px 1px #fff, inset 0 -1px 1px #04628e40, 0 12px 32px #004b7d24, 0 2px 4px #004b7d1a;
  --gloss-blue: linear-gradient(#9ae9ff 0%, #49bde9 47%, #088dca 49%, #0871b1 100%);
  --gloss-green: linear-gradient(#eeffd2 0%, #c2ed89 47%, #a2d75c 49%, #8bc343 100%);
}
* { box-sizing: border-box; }
[hidden] { display: none !important; }
body { margin: 0; min-height: 100vh; color: var(--ink); background: #128fd1; font-family: var(--sans); -webkit-font-smoothing: antialiased; }
body::before { content: ''; position: fixed; inset: 0; z-index: -3; background: radial-gradient(ellipse at 10% 0%, #f3ffe9 0%, transparent 55%), linear-gradient(155deg, #b3f2ed, #30b6e4 55%, #0962b6); }
button, input, select { font: inherit; color: inherit; }
button { cursor: pointer; -webkit-tap-highlight-color: transparent; transition: background .18s, box-shadow .18s, transform .18s; }
button:hover { filter: brightness(1.035); box-shadow: inset 0 1px 2px #fff, 0 3px 10px #005c922b; }
button:active { transform: translateY(1px); }
:where(button, select, input, a):focus-visible { outline: 3px solid #034d87; outline-offset: 4px; }
#water { position: fixed; inset: 0; width: 100%; height: 100%; z-index: -2; pointer-events: none; }
.atmosphere { position: fixed; inset: 0; z-index: -1; pointer-events: none; overflow: hidden; }
.atmosphere::after { content: ''; position: absolute; width: 150vw; height: 50vh; left: -22vw; bottom: -40vh; border-radius: 50%; background: linear-gradient(175deg, #c5f0799c, #04adb600); border-top: 2px solid #f4ffda80; transform: rotate(-9deg); box-shadow: 0 -12px 55px #c5ffe03b; }
.sunlight { position: absolute; width: 100vw; height: 100vh; top: -60vh; left: -35vw; border-radius: 50%; background: radial-gradient(ellipse, #fffff5ab, #f6ffe329 45%, transparent 67%); }
.bubble { position: absolute; border-radius: 50%; border: 1px solid #eaffffc7; background: radial-gradient(circle at 30% 22%, #ffffffbf, #e8ffff05 27%, #9efbfc1a 63%, #f1ffff73 92%, #80dcfa30); box-shadow: inset -8px -10px 20px #0056a32b, inset 3px 5px 8px #ffffffb0, 0 16px 28px #005e8c12; animation: float 12s ease-in-out infinite; }
.bubble::before { content: ''; position: absolute; top: 12%; left: 22%; width: 24%; height: 10%; border-radius: 50%; background: #fff9; transform: rotate(-35deg); }
.bubble-one { width: 180px; height: 180px; top: 16%; right: -100px; animation-delay: -3s; }
.bubble-two { width: 75px; height: 75px; bottom: 8%; left: -25px; animation-delay: -6s; }
.bubble-three { width: 32px; height: 32px; top: 6%; left: 58%; animation-duration: 9s; }
.page { width: min(1160px, calc(100% - 56px)); min-height: 100vh; min-height: 100dvh; margin: 0 auto; display: flex; flex-direction: column; }
.topbar { flex-shrink: 0; display: grid; grid-template-columns: auto minmax(0,1fr) auto auto; grid-template-areas: 'brand views time controls'; align-items: center; gap: 16px; padding: 8px 12px; margin: 12px 0 16px; border: 1px solid #efffffda; border-radius: 23px; background: linear-gradient(#f3ffffb8, #d0f2fc80 48%, #b5e7f475 50%, #def6ff80); box-shadow: var(--glass-shadow); backdrop-filter: blur(18px) saturate(135%); -webkit-backdrop-filter: blur(18px) saturate(135%); }
.brand { grid-area: brand; display: flex; align-items: center; gap: 10px; min-width: 0; }
.seal { display: grid; place-items: center; width: 38px; height: 38px; flex-shrink: 0; border-radius: 50%; background: linear-gradient(#fff, #e4f5ff); border: 1px solid #fff; box-shadow: 0 2px 4px #00467830, inset 0 -2px 4px #005b8b1f; }
.seal img { width: 90%; height: 90%; object-fit: contain; }
.brand-name { display: block; font-size: 16px; line-height: 1.2; font-weight: 800; letter-spacing: -.04em; }
.brand-caption { display: block; margin-top: 3px; color: var(--muted); font-size: 9px; font-weight: 650; }
.view-switch { grid-area: views; display: none; justify-self: center; }
.toolbar-time { grid-area: time; display: flex; flex-direction: column; align-items: flex-end; gap: 3px; white-space: nowrap; }
.clock { font-size: 18px; line-height: 1.1; font-weight: 800; letter-spacing: -.04em; font-variant-numeric: tabular-nums; }
.toolbar-date { display: flex; gap: 5px; color: var(--muted); font-size: 9px; line-height: 1.2; }
.toolbar-date strong { font-weight: 700; }
.header-actions { grid-area: controls; display: flex; align-items: center; gap: 7px; }
.motion-button { width: 34px; height: 34px; display: grid; place-items: center; padding: 0; border: 1px solid #ffffffda; border-radius: 50%; background: linear-gradient(#fcffffb3, #b8e4f27a); box-shadow: inset 0 1px 2px #fff, 0 2px 3px #005b7c1a; }
.motion-button svg { width: 18px; height: 18px; }
#motionLabel { display: none; }
.schedule-tools, .override-banner, .override-banner > div { display: flex; align-items: center; gap: 5px; }
.override-button, .apply-button, #usePreview { min-height: 34px; padding: 0 15px; border: 1px solid #117db2; border-top-color: #e0fbff; border-radius: 20px; background: var(--gloss-blue); color: #fff; font-size: 11px; font-weight: 800; white-space: nowrap; text-shadow: 0 1px 2px #004b8c; box-shadow: inset 0 0 0 1px #cefbff70, inset 0 2px 2px #fff8, 0 3px 5px #00537b33; }
.override-button.is-manual { box-shadow: inset 0 0 0 1px #cefbff70, 0 0 0 2px #d9ffb8, 0 3px 5px #00537b33; }
#clearOverride, .close { width: 30px; height: 30px; display: grid; place-items: center; padding: 0; border: 1px solid #fffd; border-radius: 50%; background: linear-gradient(#f8ffffb8, #b1dbeb7a); font-size: 21px; line-height: 1; }
#usePreview { min-height: 30px; padding: 0 10px; font-size: 10px; }
main { flex: 1; display: flex; flex-direction: column; justify-content: center; gap: 14px; padding-bottom: 18px; }
.dashboard { display: grid; grid-template-columns: minmax(0,1.08fr) minmax(0,1fr); gap: 18px; min-height: clamp(420px, calc(100dvh - 212px), 640px); align-items: stretch; }
.glass { border: 1px solid #efffffdf; border-radius: 29px; background: var(--glass); box-shadow: var(--glass-shadow); backdrop-filter: blur(22px) saturate(130%); -webkit-backdrop-filter: blur(22px) saturate(130%); }
.hero { display: flex; flex-direction: column; min-width: 0; padding: 25px; position: relative; overflow: hidden; }
.hero::before { content: ''; position: absolute; width: 160%; height: 60%; left: -30%; top: -38%; border-radius: 50%; background: linear-gradient(#fff0, #ffffff6b); border-bottom: 1px solid #ffffff80; pointer-events: none; }
.hero-main { flex: 1; position: relative; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 24px; padding: 24px 0; min-height: 0; }
.hero-orb { position: relative; flex-shrink: 0; display: grid; place-items: center; width: clamp(86px, 12svh, 124px); height: clamp(86px, 12svh, 124px); border-radius: 50%; color: #f3ffff; border: 1px solid #f0ffff; background: radial-gradient(ellipse at 50% 100%, #b8ed70a1, transparent 62%), radial-gradient(circle at 29% 19%, #ffffffb3, transparent 32%), linear-gradient(#64d8f0 0%, #15b0d9 48%, #0089c2 51%, #0076b3); box-shadow: inset 0 2px 4px #fff, inset 0 -6px 10px #0059a385, 0 10px 18px -8px #005e9866, 0 0 0 7px #f6ffff27; animation: float 9s ease-in-out infinite; }
.hero-orb::before { content: ''; position: absolute; inset: 6% 13% 51%; border-radius: 50% 50% 45% 45%; background: linear-gradient(#ffffffe6, #fff2); }
.hero-orb svg { width: 60%; height: 60%; position: relative; filter: drop-shadow(0 2px 1px #00629c5c); }
.hero-copy { position: relative; width: 100%; text-align: center; }
h1 { margin: 0; width: 100%; font-size: clamp(52px, 5.6vw, 80px); font-weight: 800; line-height: 1.04; letter-spacing: -.065em; text-wrap: balance; overflow-wrap: anywhere; text-shadow: 0 2px 1px #fff9; }
h1.long { font-size: clamp(42px, 4.5vw, 65px); }
.hero-subtitle { margin: 15px 0 0; font-size: 15px; font-weight: 600; line-height: 1.5; color: var(--muted); }
.hero-subtitle:empty { display: none; }
.pass-status { display: inline-flex; align-items: center; justify-content: center; gap: 7px; margin-top: 20px; padding: 8px 13px; border-radius: 20px; border: 1px solid #fff; background: linear-gradient(#fff9df, #f5dfae); color: #72510d; font-size: 11px; font-weight: 750; line-height: 1.45; box-shadow: inset 0 1px 1px #fff, 0 2px 5px #005e7a15; }
.pass-status[data-ok='true'] { background: var(--gloss-green); color: #294f16; }
#passIcon { font-size: 17px; }
.hero-bottom { position: relative; display: flex; justify-content: space-between; align-items: center; gap: 16px; padding: 17px 19px; border: 1px solid #fff; border-radius: 18px; background: linear-gradient(#f8ffffb3, #d4edf77d); box-shadow: inset 0 1px 0 #fff, 0 4px 9px #00598812; overflow: hidden; isolation: isolate; }
.hero-bottom > .next-info, .hero-bottom > .countdown, .hero-bottom > .timer-group { position: relative; z-index: 1; }
.next-info { min-width: 0; }
.next-label, .section-kicker { display: block; color: var(--muted); font-size: 8px; font-weight: 800; letter-spacing: .13em; text-transform: uppercase; line-height: 1.3; }
.next-name { margin-top: 6px; font-size: 13px; line-height: 1.4; font-weight: 750; letter-spacing: -.025em; }
.countdown { color: #075e92; font-size: clamp(30px, 3vw, 42px); font-weight: 800; letter-spacing: -.06em; line-height: 1; font-variant-numeric: tabular-nums; white-space: nowrap; }
.countdown:empty { display: none; }
#blockProgress { position: absolute; inset: 0 auto 0 0; width: 0; height: 100%; background: linear-gradient(90deg, #52c4cf70, #9aeee470); pointer-events: none; transition: width 1s linear; }
.schedule-panel { min-width: 0; display: flex; flex-direction: column; padding: 21px 22px 15px; }
.schedule-meta { display: flex; align-items: center; justify-content: center; gap: 12px; min-height: 27px; padding-bottom: 13px; margin-bottom: 8px; border-bottom: 1px solid #ffffffbd; }
h2 { margin: 0; font-size: 30px; font-weight: 800; letter-spacing: -.05em; line-height: 1.2; }
.schedule-name { font-size: 18px; text-align: center; letter-spacing: -.035em; line-height: 1.3; }
.grade { display: none; align-items: center; gap: 6px; font-size: 10px; font-weight: 700; }
.grade.show { display: flex; }
.grade select { min-height: 34px; padding: 0 8px; border: 1px solid #fff; border-radius: 9px; background: #f6ffffab; }
.schedule-note { margin: 0 0 8px; padding: 8px 10px; border-radius: 11px; background: #ffffffe0; border: 1px solid #fff; font-size: 10px; line-height: 1.5; color: var(--muted); }
.timeline { flex: 1; display: flex; flex-direction: column; gap: 2px; }
.row { flex: 1; min-height: 37px; display: grid; grid-template-columns: 77px minmax(0,1fr) 34px; align-items: center; gap: 10px; padding: 5px 10px; border: 1px solid transparent; border-bottom-color: #ffffff70; border-radius: 10px; position: relative; overflow: hidden; isolation: isolate; }
.row:last-child { border-bottom-color: transparent; }
.row::before { content: ''; position: absolute; inset: 0; width: var(--fill, 0%); z-index: -1; background: #b4dee940; transition: width 1s linear; }
.row.current { border-color: #fff; background: linear-gradient(#f5ffffc9, #bde8f6b0); box-shadow: inset 0 1px 2px #fff, 0 3px 7px #007ab01a; }
.row.current::before { background: linear-gradient(90deg, #61d3e775, #c7ed987d); }
.row-time { display: flex; flex-direction: column; gap: 2px; font-size: 11px; font-weight: 750; font-variant-numeric: tabular-nums; line-height: 1.2; white-space: nowrap; }
.row-time span:last-child { color: var(--muted); font-size: 9px; font-weight: 500; }
.row-name { font-size: 16px; font-weight: 750; letter-spacing: -.035em; line-height: 1.25; overflow-wrap: anywhere; }
.row-state { font-size: 7px; font-weight: 800; text-transform: uppercase; text-align: center; }
.row.current .row-state { color: #2d5117; padding: 5px 4px; border: 1px solid #fff; border-radius: 12px; background: var(--gloss-green); box-shadow: inset 0 1px 1px #fff; }
.row.past { opacity: .75; }
.row.past::before { background: #b4dee940; transition: none; }
.row[data-type='meal'] { flex: .65; min-height: 28px; }
.row[data-type='meal'] .row-name { color: var(--muted); font-size: 12px; font-weight: 650; }
.row[data-type='meal'] .row-time { font-size: 10px; }
.row[data-type='meal'] .row-time span:last-child { font-size: 9px; }
.row[data-type='activity'] .row-name, .row[data-type='test'] .row-name { font-size: 14px; }
.day-glance { display: none; }
.empty { display: none; align-items: center; justify-content: center; padding: 24px; }
.empty.show { display: flex; }
.preview-button { padding: 12px 17px; background: linear-gradient(#fff, #d3eef9); border: 1px solid #fff; border-radius: 20px; font-size: 11px; font-weight: 750; }
.year-strip { flex-shrink: 0; display: grid; grid-template-columns: 1fr 1fr; width: min(680px, 100%); align-self: center; padding: 13px 20px; border-radius: 23px; }
.year-stat { min-width: 0; text-align: center; padding: 0 10px; }
.year-stat + .year-stat { border-left: 1px solid #ffffffde; box-shadow: -1px 0 #00588912; }
.year-stat > div { display: flex; justify-content: center; align-items: baseline; flex-wrap: wrap; gap: 8px; margin: 4px 0 2px; }
.year-stat strong { font-size: 30px; font-weight: 800; letter-spacing: -.06em; line-height: 1.1; }
.year-stat > div > span { font-size: 10px; font-weight: 650; }
.year-stat small { display: block; font-size: 9px; line-height: 1.3; color: var(--muted); }
.waterline-fill { position: absolute; inset: 0; width: 100%; height: 100%; pointer-events: none; display: block; }
.row > .waterline-fill { z-index: -1; }
.row.has-waterline::before { display: none; }
.hero-bottom > .waterline-fill { z-index: 0; opacity: .5; }
.hero-bottom.has-waterline > #blockProgress { opacity: 0; }
.hero-bottom.is-complete > #blockProgress { background: #b4dedf80; }
body[data-state='off'] .schedule-panel { display: none; }
body[data-state='off'] .hero { grid-column: 1 / -1; }
body[data-state='off'] .hero-bottom { width: min(540px,100%); align-self: center; justify-content: center; text-align: center; }

dialog { width: min(700px, calc(100% - 28px)); max-height: calc(100dvh - 40px); padding: 25px; border: 1px solid #fff; border-radius: 28px; color: var(--ink); background: linear-gradient(150deg, #f4fffff5, #c4e9f8f5); box-shadow: inset 0 2px 1px #fff, 0 24px 70px #003d6b66; backdrop-filter: blur(28px); }
dialog::backdrop { background: #003b5966; backdrop-filter: blur(8px); }
.dialog-head { display: flex; align-items: center; justify-content: space-between; gap: 10px; padding-bottom: 10px; }
.close { width: 36px; height: 36px; font-size: 24px; }
.dialog-intro, .editor-intro, .dialog-foot { font-size: 12px; line-height: 1.65; color: var(--muted); }
.dialog-intro { margin: 0 0 17px; }
.dialog-foot { margin: 20px 0 0; padding-top: 15px; border-top: 1px solid #fff; font-size: 10px; }
.selection-scope { display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: 10px; padding: 11px 13px; background: #fff8; border: 1px solid #fff; border-radius: 13px; font-size: 11px; font-weight: 700; }
.selection-scope select { padding: 8px; border: 1px solid #9ac3d5; border-radius: 9px; background: #f3ffff; font-size: 12px; }
.dialog-tabs { display: flex; gap: 25px; margin: 19px 0; border-bottom: 1px solid #fff; }
.dialog-tabs button { background: transparent; border: 0; border-bottom: 3px solid transparent; padding: 10px 0; font-size: 13px; font-weight: 800; }
.dialog-tabs button[aria-selected='true'] { border-color: #0785b9; }
.choices { display: grid; grid-template-columns: 1fr 1fr; gap: 9px; }
.choice { display: flex; flex-direction: column; justify-content: center; gap: 5px; min-height: 55px; padding: 13px 14px; border: 1px solid #fff; border-radius: 13px; background: linear-gradient(#ffffffe0, #e0f3fcab); box-shadow: inset 0 1px 1px #fff, 0 2px 3px #00698c0d; font-size: 12px; font-weight: 700; text-align: left; }
.choice strong { font-size: 13px; }
.choice small { font-size: 10px; font-weight: 500; line-height: 1.4; color: var(--muted); }
.choice[aria-pressed='true'] { border-color: #168db7; box-shadow: inset 0 0 0 1px #168db7; }
.choice.auto { grid-column: 1 / -1; color: #fff; background: var(--gloss-blue); border-color: #167fb1; text-shadow: 0 1px 1px #005184; }
.schedule-label { display: flex; flex-direction: column; gap: 7px; font-size: 12px; font-weight: 750; margin: 15px 0; }
.schedule-label input, .draft-row input, .draft-row select { width: 100%; min-width: 0; padding: 10px; border: 1px solid #8ab8d0; border-radius: 9px; background: #f8ffff; font-size: 14px; }
.custom-rows { display: grid; gap: 12px; }
.draft-row { display: grid; grid-template-columns: minmax(100px,1.5fr) 110px 110px 105px 30px; align-items: end; gap: 8px; min-width: 0; margin: 0; padding: 11px; border: 1px solid #fff; border-radius: 14px; background: #ffffff59; }
.draft-row legend { font-size: 10px; font-weight: 800; padding: 0 5px; color: var(--muted); }
.draft-row label { display: flex; flex-direction: column; gap: 5px; min-width: 0; font-size: 10px; font-weight: 700; }
.draft-row input, .draft-row select { height: 38px; padding: 9px 6px; font-size: 12px; }
.remove-row { width: 30px; height: 38px; border: 0; background: transparent; font-size: 24px; }
.text-button { margin-top: 8px; padding: 8px 2px; border: 0; background: transparent; text-decoration: underline; text-underline-offset: 3px; font-size: 12px; font-weight: 750; }
.text-button:disabled { opacity: .5; cursor: default; }
.apply-button { width: 100%; min-height: 46px; margin-top: 20px; font-size: 13px; }
.form-error { color: #8a3222; padding: 12px; background: #fff1e5; border-radius: 12px; border: 1px solid #d2a485; font-size: 12px; line-height: 1.6; }
@keyframes float { 0%,100% { translate: 0 0; } 50% { translate: 0 -8px; } }
body.water-paused *, body.water-paused *::before, body.water-paused *::after { animation-play-state: paused !important; }

@media screen and (min-width:781px) and (max-height:740px) {
  .hero-main { gap: 18px; padding: 16px 0; }
  .hero-orb { width: 80px; height: 80px; }
  .pass-status { margin-top: 14px; }
}
@media screen and (max-width:1000px) and (min-width:781px) {
  .page { width: calc(100% - 40px); }
  .dashboard { gap: 14px; grid-template-columns: minmax(0,1fr) minmax(0,1fr); }
  .hero { padding: 20px; }
  .schedule-panel { padding: 20px 15px 12px; }
  .hero-bottom { padding: 14px; flex-wrap: wrap; justify-content: center; text-align: center; }
  .row { grid-template-columns: 66px minmax(0,1fr) 30px; gap: 7px; padding-left: 6px; padding-right: 6px; }
  .row-name { font-size: 15px; }
  .row-time { font-size: 10px; }
}
@media screen and (max-width:780px) {
  .page { width: calc(100% - 28px); }
  .topbar { gap: 10px; margin: 8px 0 12px; }
  .brand-text { display: none; }
  .view-switch { display: grid; grid-template-columns: 1fr 1fr; gap: 2px; width: 112px; padding: 3px; border: 1px solid #fff; border-radius: 20px; background: #7ab4cf30; box-shadow: inset 0 1px 3px #00537c1a; }
  .view-switch button { min-height: 30px; padding: 0 9px; border: 1px solid transparent; border-radius: 20px; background: transparent; font-size: 11px; font-weight: 800; }
  .view-switch button[aria-pressed='true'] { color: #284e15; background: var(--gloss-green); border-color: #fff; box-shadow: inset 0 1px 1px #fff, 0 2px 4px #356e3521; }
  main { justify-content: flex-start; gap: 12px; padding-bottom: 12px; }
  .dashboard { flex: 1; display: flex; flex-direction: column; min-height: 0; gap: 0; }
  .hero { flex: 1; min-height: 260px; padding: 22px; }
  .hero-main { gap: 22px; padding: 28px 0; }
  .hero-orb { width: 104px; height: 104px; }
  h1 { font-size: clamp(52px, 13vw, 80px); }
  h1.long { font-size: clamp(40px, 10.5vw, 62px); }
  .hero-subtitle { font-size: 13px; }
  .pass-status { margin-top: 16px; font-size: 11px; }
  .hero-bottom { padding: 15px; }
  .next-name { font-size: 12px; }
  .countdown { font-size: 34px; }
  .schedule-panel { flex: 1; padding: 15px 16px 10px; }
  body[data-mobile-view='now'] .schedule-panel { display: none; }
  body[data-mobile-view='day'] .hero { display: none; }
  .day-glance { display: flex; justify-content: space-between; align-items: baseline; gap: 10px; margin-bottom: 12px; padding-bottom: 9px; border-bottom: 1px solid #fff; font-size: 11px; line-height: 1.5; }
  .day-glance > span { text-align: right; font-size: 10px; font-variant-numeric: tabular-nums; }
  .schedule-meta { min-height: 22px; padding-bottom: 10px; margin-bottom: 6px; }
  .schedule-name { font-size: 16px; }
  .row { grid-template-columns: 70px minmax(0,1fr) 30px; gap: 8px; min-height: 35px; padding: 4px 7px; }
  .row-name { font-size: 15px; }
  .row-time { font-size: 10px; }
  .row[data-type='meal'] { min-height: 27px; }
  .row[data-type='meal'] .row-name { font-size: 11px; }
  .year-strip { width: 100%; padding: 12px 8px; border-radius: 22px; }
  .year-stat { padding: 0 5px; }
  .year-stat .section-kicker { font-size: 7px; letter-spacing: .1em; }
  .year-stat > div { gap: 5px; }
  .year-stat strong { font-size: 27px; }
  .year-stat > div > span { font-size: 9px; }
  .year-stat small { font-size: 8px; }
  .draft-row { position: relative; grid-template-columns: minmax(0,1fr) minmax(0,1fr); }
  .draft-row label:first-of-type { grid-column: 1 / 3; padding-right: 32px; }
  .draft-row label:nth-of-type(2) { grid-column: 1; grid-row: 2; }
  .draft-row label:nth-of-type(3) { grid-column: 2; grid-row: 2; }
  .draft-row label:nth-of-type(4) { grid-column: 1 / 3; grid-row: 3; }
  .remove-row { position: absolute; top: 14px; right: 8px; }
  .draft-row input, .draft-row select { font-size: 16px; }
  .draft-row input[type='time'] { font-size: 14px; }
  body[data-state='off'][data-mobile-view='day'] .hero { display: flex; }
}
@media screen and (max-width:600px) {
  .topbar { grid-template-columns: 30px minmax(0,1fr) auto; grid-template-areas: 'brand clock controls' 'views views date'; gap: 4px 8px; padding: 7px 9px; margin: 7px 0 11px; border-radius: 22px; }
  .seal { width: 30px; height: 30px; }
  .toolbar-time { display: contents; }
  .clock { grid-area: clock; justify-self: start; font-size: 16px; }
  .toolbar-date { grid-area: date; justify-self: end; align-self: center; }
  .header-actions { gap: 5px; }
  .motion-button { width: 30px; height: 30px; }
  .override-button { min-height: 30px; padding: 0 10px; font-size: 10px; }
  .schedule-tools, .override-banner, .override-banner > div { gap: 4px; }
  #clearOverride { width: 26px; height: 28px; }
  #usePreview { min-height: 28px; padding: 0 7px; }
  .view-switch { justify-self: start; width: 108px; padding: 2px; }
  .view-switch button { min-height: 27px; font-size: 10px; }
}
@media screen and (max-width:780px) and (max-height:740px) {
  main { gap: 10px; }
  .hero { padding: 17px 19px; }
  .hero-main { gap: 18px; padding: 18px 0; }
  .hero-orb { width: 78px; height: 78px; }
  .hero-bottom { padding: 12px; }
  .pass-status { margin-top: 13px; padding: 6px 10px; font-size: 10px; }
  .schedule-panel { padding: 11px 14px 8px; }
  .day-glance { padding-bottom: 6px; margin-bottom: 8px; }
  .schedule-meta { padding-bottom: 7px; margin-bottom: 4px; }
  .row { min-height: 30px; padding: 3px 6px; }
  .row-name { font-size: 14px; }
  .row[data-type='meal'] { min-height: 25px; }
  .year-strip { padding-top: 10px; padding-bottom: 10px; }
  .year-stat strong { font-size: 25px; }
}
@media screen and (max-width:360px) {
  .page { width: calc(100% - 20px); }
  .topbar { gap: 4px 6px; padding-left: 7px; padding-right: 7px; }
  .header-actions { gap: 4px; }
  .override-button { padding: 0 8px; }
  h1 { font-size: 46px; }
  h1.long { font-size: 36px; }
  .countdown { font-size: 30px; }
  .next-name { font-size: 11px; }
  .choices { grid-template-columns: 1fr; }
}
@media (prefers-reduced-motion:reduce) { *, *::before, *::after { animation: none !important; transition: none !important; } }
@media print {
  body { background: #fff; }
  #water, .atmosphere, .header-actions, .hero-orb, .view-switch, .preview-button, dialog { display: none; }
  .page { width: 100%; min-height: 0; }
  .topbar, .glass { box-shadow: none; background: #fff; border: 1px solid #aaa; backdrop-filter: none; }
  .dashboard { min-height: 400px; }
  h1 { font-size: 46px; }
  .pass-status, .waterline-fill, #blockProgress { display: none; }
  .row::before { display: none; }
  .year-strip { break-inside: avoid; }
}
