@font-face {
  font-family: "Inter";
  src: url("assets/fonts/InterVariable.woff2") format("woff2");
  font-style: normal;
  font-weight: 100 900;
  font-display: swap;
}

:root {
  color-scheme: light;
  --blue: #008cff;
  --blue-text: #3e7ae4;
  --ink: #000b42;
  --ink-80: #333c68;
  --muted: #8085a0;
  --surface-soft: #ebf3ff;
  --surface-soft-2: #f5f8ff;
  --line: rgba(0, 11, 66, .15);
  --green-bg: #dbe6dd;
  --green-text: #2a533c;
  --dot-bg: #cadaef;
  --dot-text: #264a72;
  --change-bg: #f3ddd0;
  --change-text: #6b4222;
  --nav-height: 54px;
  --safe-top: env(safe-area-inset-top, 0px);
  --viewport-height: 100svh;
  --screen-height: var(--viewport-height);
}

@supports (height: 100dvh) {
  :root { --viewport-height: 100dvh; }
}

/* Installed iOS apps can exclude the status area from dynamic viewport units. */
@media (display-mode: standalone) {
  :root { --viewport-height: 100vh; }
}
:root.is-apple-standalone { --viewport-height: 100vh; }

.browser-top-tint { display: none; }
@media (max-width: 430px) and (display-mode: browser) {
  /* Safari extends the solid background of a fixed element into its top UI. */
  :root:not(.is-apple-standalone) .browser-top-tint {
    display: block;
    position: fixed;
    z-index: 46;
    top: 0;
    left: 0;
    right: 0;
    height: 1px;
    background-color: var(--blue);
    pointer-events: none;
  }
}

* { box-sizing: border-box; }

html {
  min-width: 280px;
  min-height: 100%;
  background: #e8eef7;
  scrollbar-width: none;
}

body {
  margin: 0;
  min-width: 280px;
  min-height: 100%;
  color: var(--ink-80);
  background: #e8eef7;
  font-family: "Inter", ui-sans-serif, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  -webkit-font-smoothing: antialiased;
  text-rendering: geometricPrecision;
  scrollbar-width: none;
}

html::-webkit-scrollbar,
body::-webkit-scrollbar { display: none; }

button, input, select, textarea { font: inherit; }
button { color: inherit; }
button, select { cursor: pointer; }
button:focus-visible, input:focus-visible, select:focus-visible, textarea:focus-visible, summary:focus-visible {
  outline: 3px solid rgba(0, 140, 255, .3);
  outline-offset: 2px;
}

.app-shell {
  position: relative;
  width: min(100%, 430px);
  min-height: var(--screen-height);
  margin: 0 auto;
  overflow: hidden;
  border-radius: 0;
  background: #fff;
  box-shadow: 0 24px 80px rgba(0, 11, 66, .12);
}

.screen-stage {
  min-height: var(--screen-height);
  background: #fff;
  touch-action: pan-y;
  overscroll-behavior-x: none;
}

.app-screen { min-height: var(--screen-height); }
.app-screen[hidden] { display: none !important; }

.schedule-screen { display: flex; flex-direction: column; }

.schedule-screen,
.standard-screen {
  background: var(--blue);
}

.hero {
  display: flex;
  min-height: calc(155px + var(--safe-top));
  flex-direction: column;
  gap: 32px;
  padding: calc(20px + var(--safe-top)) 20px 12px;
  color: #fff;
}

.hero-main {
  display: flex;
  min-height: 74px;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
}

.day-heading { min-width: 0; }
.day-heading h1 {
  margin: 0;
  color: #fff;
  font-size: 48px;
  font-weight: 700;
  line-height: 48px;
  letter-spacing: -2.88px;
  white-space: nowrap;
}
.day-heading p {
  margin: 2px 0 0;
  color: rgba(255, 255, 255, .65);
  font-size: 20px;
  font-weight: 500;
  line-height: 24px;
  letter-spacing: -1.2px;
  white-space: nowrap;
}

.bell-button {
  position: relative;
  display: grid;
  width: 44px;
  height: 44px;
  flex: 0 0 44px;
  place-items: center;
  padding: 12px;
  border: 0;
  border-radius: 16px;
  background: #fff;
  transition: transform .16s ease;
}
.bell-button:active { transform: scale(.94); }
.bell-button img { display: block; width: 20px; height: 20px; }


.hero-meta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  color: #fff;
  font-size: 14px;
  font-weight: 500;
  line-height: 17px;
  letter-spacing: -.84px;
  white-space: nowrap;
}

.content-panel {
  display: flex;
  min-height: calc(var(--screen-height) - 155px - var(--safe-top));
  flex: 1;
  flex-direction: column;
  gap: 12px;
  padding: 20px 20px 90px;
  overflow: hidden;
  border-radius: 48px 48px 0 0;
  background: #fff;
}

.status-row {
  display: flex;
  min-height: 27px;
  flex-wrap: wrap;
  align-items: flex-start;
  gap: 8px 12px;
}
.status-chip {
  display: inline-flex;
  min-height: 27px;
  align-items: center;
  justify-content: center;
  gap: 4px;
  padding: 5px 7px;
  border: 0;
  border-radius: 999px;
  background: var(--green-bg);
  color: var(--green-text);
  font-size: 14px;
  font-weight: 500;
  line-height: 17px;
  letter-spacing: -.84px;
}
button.status-chip { transition: transform .16s ease; }
button.status-chip:active { transform: scale(.96); }
.status-chip img { display: block; width: 10px; height: 10px; }
.status-chip.info { background: var(--dot-bg); color: var(--dot-text); }
.status-chip.warning { background: #fff0d9; color: #7b4a12; }
.status-chip.error { background: #ffe0e0; color: #7f2929; }
.status-chip.neutral { background: #eef0f5; color: #555e78; }

.day-switcher {
  display: grid;
  width: 100%;
  min-height: 41px;
  grid-template-columns: minmax(0, 1fr) 140px minmax(0, 1fr);
  align-items: center;
  padding: 4px;
  overflow: hidden;
  border-radius: 999px;
  background: var(--surface-soft);
}
.day-switcher button {
  min-width: 0;
  min-height: 33px;
  padding: 4px 8px;
  border: 0;
  border-radius: 16px;
  background: transparent;
  color: rgba(0, 11, 68, .5);
  font-size: 14px;
  font-weight: 500;
  line-height: 17px;
  letter-spacing: -.84px;
  transition: background .2s ease, color .2s ease, transform .2s ease;
}
.day-switcher button.active {
  border-radius: 999px;
  background: var(--blue);
  color: #fff;
  font-weight: 700;
}

.schedule-list { display: flex; min-width: 0; flex-direction: column; gap: 4px; }
.lesson-card {
  display: grid;
  width: 100%;
  min-width: 0;
  grid-template-columns: 45px 1.5px minmax(0, 1fr);
  gap: 10px;
  padding: 14px 14px 14px 4px;
  border-radius: 24px;
}
.lesson-divider { width: 1.5px; align-self: stretch; border-radius: 999px; background: var(--line); }
.lesson-time {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  justify-content: center;
  gap: 10px;
  white-space: nowrap;
}
.lesson-number { color: #125cdf; font-size: 12px; font-weight: 700; line-height: 15px; letter-spacing: -.72px; opacity: .8; text-transform: uppercase; }
.lesson-clock { display: flex; flex-direction: column; gap: 4px; }
.lesson-start { color: var(--ink); font-size: 18px; font-weight: 700; line-height: 22px; letter-spacing: -1.08px; opacity: .8; }
.lesson-end { color: var(--ink); font-size: 12px; font-weight: 500; line-height: 15px; letter-spacing: -.72px; opacity: .5; }
.lesson-main { display: flex; min-width: 0; flex-direction: column; align-items: flex-start; gap: 8px; }
.lesson-title { margin: 0; color: var(--ink); font-size: 18px; font-weight: 700; line-height: 22px; letter-spacing: -1.08px; opacity: .8; overflow-wrap: anywhere; }
.lesson-teacher { margin: 0; color: var(--ink); font-size: 14px; font-weight: 500; line-height: 17px; letter-spacing: -.84px; opacity: .5; overflow-wrap: anywhere; }
.lesson-details { display: flex; width: 100%; flex-wrap: wrap; align-items: center; gap: 6px 10px; }
.room { display: inline-flex; align-items: center; gap: 4px; color: var(--blue-text); font-size: 14px; font-weight: 500; line-height: 17px; letter-spacing: -.84px; }
.room img { display: block; width: 16px; height: 16px; object-fit: contain; }
.change-badge { display: inline-flex; min-height: 17px; align-items: center; justify-content: center; gap: 4px; padding: 3px 6px; border-radius: 999px; background: var(--change-bg); color: rgba(107, 66, 34, .85); font-size: 10px; font-weight: 600; line-height: 11px; letter-spacing: -.4px; }
.change-badge img { display: block; width: 6px; height: 6px; }
.cancelled-badge { background: #fdebec !important; color: #b4232c !important; }
.lesson-card.cancelled .lesson-title { color: var(--muted); text-decoration: line-through; }
.student-note { width: 100%; padding: 8px 10px; border-radius: 10px; background: var(--surface-soft); color: rgba(0, 11, 66, .65); font-size: 12px; line-height: 16px; }
.schedule-separator { width: 100%; height: 1.5px; border-radius: 999px; background: var(--line); }

.state-card { padding: 24px 20px; border-radius: 24px; background: var(--surface-soft); text-align: center; }
.state-card strong { display: block; color: var(--ink-80); font-size: 17px; line-height: 22px; }
.state-card span { display: block; margin-top: 6px; color: var(--muted); font-size: 13px; line-height: 18px; }
.special-card { padding: 16px; border-radius: 20px; background: #fff0d9; color: #6b4222; }
.special-card strong { display: block; font-size: 16px; line-height: 21px; }
.special-card span { display: block; margin-top: 5px; font-size: 13px; line-height: 18px; opacity: .78; }
.day-notices { display: grid; gap: 8px; margin-bottom: 8px; }
.day-notice { padding: 14px 16px; border-radius: 18px; background: #fff0d9; color: #6b4222; }
.day-notice strong { display: block; font-size: 15px; line-height: 20px; }
.day-notice span { display: block; margin-top: 4px; font-size: 12px; line-height: 17px; opacity: .78; }

.quick-actions { display: flex; flex-direction: column; gap: 12px; margin-top: auto; }
.quick-actions h2, .menu-section h2 { margin: 0; color: var(--ink-80); font-size: 18px; font-weight: 700; line-height: 22px; letter-spacing: -1.08px; }
.action-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
.action-card, .report-card { border: 0; text-align: left; transition: transform .16s ease, filter .16s ease; }
.action-card:active, .report-card:active { transform: scale(.985); }
.action-card:hover, .report-card:hover { filter: brightness(.985); }
.action-card { display: flex; min-width: 0; min-height: 93px; flex-direction: column; align-items: flex-start; gap: 10px; padding: 12px; border-radius: 16px; background: var(--surface-soft); color: var(--ink-80); font-size: 14px; font-weight: 600; line-height: 17px; letter-spacing: -.84px; }
.action-icon, .report-icon { display: grid; width: 28px; height: 28px; flex: 0 0 28px; place-items: center; padding: 5.25px; border-radius: 8.75px; }
.action-icon { background: var(--blue); }
.report-icon { background: var(--blue); }
.report-icon img { filter: brightness(0) invert(1); }
.action-icon img, .report-icon img { display: block; width: 17.5px; height: 17.5px; }
.report-card { display: flex; min-height: 77px; flex-direction: column; align-items: flex-start; gap: 10px; padding: 12px; border-radius: 16px; background: var(--blue); color: #fff; font-size: 14px; font-weight: 600; line-height: 17px; letter-spacing: -.84px; }

/* Full-screen root pages */
.detail-screen {
  background: var(--blue);
}
.page-hero {
  display: flex;
  min-height: calc(155px + var(--safe-top));
  flex-direction: column;
  justify-content: space-between;
  gap: 28px;
  padding: calc(20px + var(--safe-top)) 20px 12px;
  color: #fff;
}
.page-heading { min-width: 0; }
.page-heading h1 { margin: 0; color: #fff; font-size: 48px; font-weight: 700; line-height: 48px; letter-spacing: -2.88px; }
.page-heading p { margin: 2px 0 0; color: rgba(255,255,255,.65); font-size: 20px; font-weight: 500; line-height: 24px; letter-spacing: -1.2px; }
.page-content { padding: 20px 20px 92px; }
.content-panel-style { min-height: calc(var(--screen-height) - 155px - var(--safe-top)); border-radius: 48px 48px 0 0; background: #fff; }
.week-content { display: flex; flex-direction: column; gap: 16px; }
.week-switcher { display: grid; grid-template-columns: 44px minmax(0, 1fr) 44px; gap: 6px; padding: 4px; border-radius: 999px; background: var(--surface-soft); }
.week-switcher button { min-height: 40px; padding: 6px; border: 0; border-radius: 999px; background: transparent; color: rgba(0, 11, 68, .5); font-size: 20px; font-weight: 600; }
.week-switcher .current-week-button { padding-inline: 12px; background: var(--blue); color: #fff; font-size: 14px; font-weight: 700; }
.week-switcher .current-week-button:disabled { opacity: 1; }
.week-list { display: grid; gap: 18px; }
.week-day { overflow: hidden; border: 0; border-radius: 22px; background: var(--surface-soft-2); }
.week-day:last-child { border-bottom: 0; }
.week-day.today { border-radius: 22px; background: var(--surface-soft-2); }
.week-day-head { display: flex; width: 100%; align-items: flex-start; justify-content: space-between; gap: 12px; padding: 14px 10px 10px; border: 0; background: transparent; text-align: left; }
.week-date { display: flex; min-width: 0; flex-direction: column; gap: 2px; }
.week-date-line { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 8px; }
.week-day-head strong { color: var(--ink-80); font-size: 18px; line-height: 22px; }
.week-day-head small { color: var(--muted); font-size: 12px; line-height: 16px; }
.week-day-statuses { display: flex; flex-wrap: wrap; gap: 5px; margin-top: 6px; }
.week-status { display: inline-flex; align-items: center; gap: 4px; min-height: 22px; padding: 4px 7px; border-radius: 999px; background: var(--green-bg); color: var(--green-text); font-size: 11px; font-weight: 600; line-height: 14px; }
.week-status img { display: block; width: 8px; height: 8px; }
.week-status.info { background: var(--dot-bg); color: var(--dot-text); }
.week-status.warning { background: #fff0d9; color: #7b4a12; }
.week-status.replacement { background: var(--change-bg); color: var(--change-text); }
.week-status.replacement img { width: 12px; height: 12px; }
.week-status.neutral { background: #eef0f5; color: #555e78; }
.week-count { flex: 0 0 auto; padding: 5px 8px; border-radius: 999px; background: var(--surface-soft); color: var(--blue-text); font-size: 11px; font-style: normal; font-weight: 700; }
.week-lessons { display: flex; flex-direction: column; gap: 4px; padding: 0 6px 14px; }
.week-lessons .lesson-card { padding-inline: 4px 8px; }
.week-empty { margin: 0; padding: 4px 10px 18px; color: var(--muted); font-size: 13px; }

.more-content { display: grid; gap: 14px; }
.settings-card, .menu-card { border: 0; border-radius: 22px; background: var(--surface-soft); box-shadow: none; }
.settings-card { padding: 17px; }
.section-heading p { margin: 0; color: var(--blue-text); font-size: 11px; font-weight: 700; text-transform: uppercase; }
.section-heading h2, .settings-card h2 { margin: 3px 0 0; color: var(--ink-80); font-size: 18px; line-height: 22px; }
.menu-card { overflow: hidden; }
.menu-row { display: flex; width: 100%; min-height: 66px; align-items: center; justify-content: space-between; gap: 12px; padding: 13px 16px; border: 0; border-bottom: 1px solid rgba(0, 11, 66, .08); background: transparent; text-align: left; }
.menu-row:last-child { border-bottom: 0; }
.menu-row > span { display: flex; min-width: 0; flex-direction: column; gap: 2px; }
.menu-row b { color: var(--ink-80); font-size: 14px; line-height: 18px; }
.menu-row small { color: var(--muted); font-size: 11px; line-height: 15px; }
.menu-row i { color: var(--blue-text); font-size: 23px; font-style: normal; }
.about-copy { margin: 2px 0; color: var(--muted); font-size: 12px; line-height: 17px; text-align: center; }

/* Detail pages */
.back-button { display: grid; width: 42px; height: 42px; flex: 0 0 42px; place-items: center; padding: 0; border: 0; border-radius: 15px; background: #fff; color: var(--ink-80); font-size: 22px; font-weight: 600; }
.detail-header { display: grid; min-height: calc(155px + var(--safe-top)); grid-template-columns: 42px minmax(0, 1fr) 44px; align-items: flex-start; gap: 14px; padding: calc(20px + var(--safe-top)) 20px 12px; background: transparent; color: #fff; }
.detail-header > div { min-width: 0; padding-top: 2px; }
.detail-header p { margin: 0; color: rgba(255,255,255,.7); font-size: 12px; font-weight: 700; text-transform: uppercase; }
.detail-header h1 { margin: 3px 0 0; color: #fff; font-size: 25px; line-height: 30px; letter-spacing: -1.3px; overflow-wrap: anywhere; }
.detail-content { min-height: calc(var(--screen-height) - 155px - var(--safe-top)); padding: 20px 20px 34px; border-radius: 48px 48px 0 0; background: #fff; }
.intro-copy, .helper-copy { margin: 0; color: var(--muted); font-size: 13px; line-height: 19px; }
.notice-list { display: grid; gap: 10px; }
.notice-item { padding: 14px; border-radius: 16px; background: var(--surface-soft); }
.notice-item strong { display: block; color: var(--ink-80); font-size: 14px; line-height: 18px; }
.notice-item span { display: block; margin-top: 4px; color: rgba(0, 11, 66, .56); font-size: 12px; line-height: 16px; }
.notice-item .notice-badge { display: inline-block; margin-top: 8px; padding: 4px 7px; border-radius: 999px; background: var(--change-bg); color: var(--change-text); font-size: 10px; font-weight: 700; }
.notification-settings { margin-top: 16px; box-shadow: none; background: var(--surface-soft-2); }
.switch-row { display: flex; align-items: center; justify-content: space-between; gap: 18px; margin-top: 15px; }
.switch-row > span { display: flex; min-width: 0; flex-direction: column; gap: 2px; }
.switch-row b { font-size: 14px; line-height: 18px; }
.switch-row small { color: var(--muted); font-size: 11px; line-height: 15px; }
.switch-row input { appearance: none; -webkit-appearance: none; width: 28px; height: 28px; flex: 0 0 28px; margin: 0; border: 1px solid rgba(0,55,68,.15); border-radius: 8.75px; background: #e3f6fa center / 18px 18px no-repeat; cursor: pointer; transition: background-color 240ms ease, border-color 240ms ease; }
.switch-row input:checked { border-color: var(--blue); background-color: var(--blue); background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20' fill='none'%3E%3Cpath d='M4.5 10l3.5 3.5 7.5-7.5' stroke='white' stroke-width='2.5' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E"); }
.helper-copy { margin-top: 14px; }
.detail-form { display: block; }

.field { display: grid; gap: 7px; margin-top: 16px; }
.owner-field { margin-top: 14px; }
.field > span { color: rgba(0, 11, 66, .62); font-size: 13px; font-weight: 600; }
.field input, .field select, .field textarea { width: 100%; min-height: 48px; padding: 12px 13px; border: 1px solid rgba(0, 11, 66, .14); border-radius: 14px; background: #f8faff; color: var(--ink-80); }
.primary-button:disabled { opacity: .5; cursor: default; }
.field textarea { min-height: 126px; resize: vertical; }
.primary-button, .secondary-button { width: 100%; min-height: 50px; margin-top: 16px; padding: 12px 16px; border: 0; border-radius: 15px; font-size: 14px; font-weight: 700; }
.primary-button { background: var(--blue); color: #fff; }
.secondary-button { background: var(--surface-soft); color: var(--ink-80); }
.context-box { margin: 0 0 2px; padding: 13px 14px; border-radius: 14px; background: var(--surface-soft); color: rgba(0, 11, 66, .64); font-size: 13px; line-height: 18px; }

.materials-list { display: grid; gap: 10px; }
.materials-list details { overflow: hidden; border: 1px solid rgba(0, 11, 66, .08); border-radius: 16px; background: var(--surface-soft-2); }
.materials-list summary { padding: 15px 42px 15px 15px; color: var(--ink-80); font-size: 14px; font-weight: 700; line-height: 18px; cursor: pointer; }
.materials-list p { margin: 0; padding: 0 15px 16px; color: var(--muted); font-size: 13px; line-height: 19px; }

.bottom-nav {
  position: fixed;
  z-index: 20;
  left: 50%;
  bottom: 10px;
  display: grid;
  width: min(calc(100% - 20px), 410px);
  height: var(--nav-height);
  grid-template-columns: repeat(3, minmax(0, 1fr));
  align-items: center;
  justify-content: center;
  padding: 2px;
  overflow: hidden;
  border-radius: 999px;
  background: var(--surface-soft);
  box-shadow: 0 8px 28px rgba(0, 11, 66, .08);
  transform: translateX(-50%);
}
.bottom-nav.hidden-nav { opacity: 0; pointer-events: none; transform: translate(-50%, 16px); }
.nav-indicator { position: absolute; z-index: 0; top: 2px; bottom: 2px; left: 2px; width: calc((100% - 4px) / 3); border-radius: 999px; background: var(--blue); transform: translateX(100%); }
.bottom-nav[data-active="week"] .nav-indicator { transform: translateX(0); }
.bottom-nav[data-active="schedule"] .nav-indicator { transform: translateX(100%); }
.bottom-nav[data-active="more"] .nav-indicator { transform: translateX(200%); }
.nav-item { position: relative; z-index: 1; display: flex; min-width: 0; min-height: 49px; flex-direction: column; align-items: center; justify-content: center; gap: 0; padding: 6px 5px; border: 0; border-radius: 16px; background: transparent; color: rgba(0, 11, 68, .5); font-size: 12px; font-weight: 500; line-height: 15px; letter-spacing: -.72px; white-space: nowrap; }
.nav-item img { display: block; width: 20px; height: 20px; object-fit: contain; filter: brightness(0) saturate(100%); opacity: .5; }
.nav-item.active { color: #fff; font-weight: 600; }
.nav-item.active img { filter: brightness(0) invert(1); opacity: 1; }

.toast { position: fixed; z-index: 50; left: 50%; bottom: 74px; width: min(calc(100% - 40px), 350px); padding: 12px 15px; border-radius: 14px; background: #18213f; color: #fff; font-size: 13px; font-weight: 600; line-height: 17px; text-align: center; opacity: 0; pointer-events: none; transform: translate(-50%, 14px); transition: opacity .18s ease, transform .18s ease; }
.toast.show { opacity: 1; transform: translate(-50%, 0); }
.hidden { display: none !important; }

@media (max-width: 359px) {
  .day-heading h1 { font-size: 42px; line-height: 44px; }
  .day-heading p { font-size: 17px; }
  .day-switcher { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .lesson-card { grid-template-columns: 42px 1.5px minmax(0, 1fr); gap: 8px; }
  .lesson-title { font-size: 16px; line-height: 20px; }
  .lesson-teacher, .room { font-size: 12px; line-height: 15px; }
  .nav-item { font-size: 10px; letter-spacing: -.5px; }
}

@media (max-width: 430px) {
  html, body {
    /* Keep the status area blue and the exposed bottom canvas white on iOS. */
    background: linear-gradient(to bottom, var(--blue) 0 50%, #fff 50% 100%) fixed;
    overscroll-behavior-y: none;
  }
  .app-shell { width: 100%; box-shadow: none; }
}

@media (min-width: 431px) {
  :root { --screen-height: calc(var(--viewport-height) - 40px); }
  body { padding: 20px; }
  .bottom-nav { width: 410px; }
}

@media (prefers-reduced-motion: reduce) {
  * { scroll-behavior: auto !important; transition: none !important; animation: none !important; }
}
/* Beta: mobile screens from Figma, 27 September 2026. */
:root {
  --blue: #10c6f0;
  --blue-text: #008dae;
  --ink: #003744;
  --ink-80: #305e69;
  --muted: #7f9da5;
  --surface-soft: #e3f6fa;
  --surface-soft-2: #f4f7f7;
  --line: rgba(0, 55, 68, .15);
  --change-bg: rgba(241, 114, 2, .15);
  --change-text: #f17202;
  --nav-height: 67px;
  --nav-gap: 10px;
  --nav-active-width: 160px;
  --page-edge: 0px;
  --page-panel-radius: 64px;
  --floating-surface: linear-gradient(rgba(0,55,68,.1),rgba(0,55,68,.1)), rgba(16,198,240,.1);
  --page-hero-height: calc(clamp(230px, calc(var(--screen-height) * .33056872), 310px) + var(--safe-top));
  --panel-top: calc(clamp(175px, calc(var(--screen-height) * .33056872), 310px) + var(--safe-top));
  --motion-ease: cubic-bezier(.22, 1, .36, 1);
}
.app-shell[data-panel-position="high"] { --panel-top: calc(clamp(150px, calc(var(--screen-height) * .17772512), 180px) + var(--safe-top)); }
.app-shell[data-panel-position="low"] { --panel-top: calc(clamp(235px, calc(var(--screen-height) * .48815166), 455px) + var(--safe-top)); }
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0, 0, 0, 0); white-space: nowrap; border: 0; }
.schedule-screen, .standard-screen { background: radial-gradient(ellipse 320.49px 281.54px at calc(50% + 1.83px) 281.5px, #0283f1 0%, #09a5f1 50%, #10c6f0 100%); }
.standard-screen { position: relative; }
.schedule-screen { position: relative; height: var(--screen-height); min-height: 0; overflow: hidden; background: radial-gradient(ellipse 320.49px 281.54px at calc(50% + 1.83px) 281.5px, #0283f1 0%, #09a5f1 50%, #10c6f0 100%); }
.hero-art { position: absolute; inset: 0; overflow: hidden; pointer-events: none; }
.hero-art img { position: absolute; max-width: none; transition: opacity 480ms var(--motion-ease); }
.hero-star { top: calc(-110px + var(--safe-top)); left: calc(50% - 294px); }
.hero-mascot { top: calc(94px + var(--safe-top)); left: calc(50% - 198px); }
.hero-star-high { top: calc(-134px + var(--safe-top)); left: calc(87.5% - 264.248px); opacity: 0; }
.hero-mascot-high { top: calc(18.46px + var(--safe-top)); left: calc(25% + 51.24px); opacity: 0; }
[data-panel-position="high"] .hero-star, [data-panel-position="high"] .hero-mascot { opacity: 0; }
[data-panel-position="high"] .hero-star-high, [data-panel-position="high"] .hero-mascot-high { opacity: 1; }
.hero { position: absolute; z-index: 1; inset: 0 0 auto; height: var(--panel-top); min-height: 0; justify-content: space-between; gap: 12px; padding: calc(20px + var(--safe-top)) 20px 12px; transition: height 480ms var(--motion-ease); }
.hero-main { min-height: 82px; gap: 8px; }
.day-heading h1 { font-size: clamp(32px, 10.77vw, 42px); line-height: 51px; letter-spacing: -.06em; }
.day-heading p { margin: 0; color: rgba(255, 255, 255, .75); font-size: 26px; line-height: 31px; letter-spacing: -1.56px; font-weight: 500; }
.hero-meta { font-size: 14px; line-height: 17px; }
.content-panel { position: absolute; z-index: 2; top: var(--panel-top); bottom: 0; left: 0; right: 0; min-height: 0; gap: 12px; padding: 14px 14px 0 28px; border-radius: 64px 64px 0 0; transition: top 480ms var(--motion-ease); }
.panel-handle, .sheet-handle { display: flex; flex: 0 0 13px; width: 84px; height: 13px; flex-direction: column; align-items: center; justify-content: center; gap: 5px; align-self: center; margin: 0 14px 0 0; padding: 2px 7px; border: 0; background: transparent; touch-action: none; cursor: ns-resize; position: relative; }
.panel-handle::before, .sheet-handle::before { content: ""; position: absolute; inset: -10px -22px; }
.panel-handle span, .sheet-handle span { width: 70px; height: 2px; flex: 0 0 2px; border-radius: 100px; background: rgba(0, 55, 68, .3); pointer-events: none; }
.panel-handle span + span, .sheet-handle span + span { width: 50px; }
.app-shell.is-dragging .hero, .app-shell.is-dragging .content-panel { transition: none; }
.day-switcher { display: flex; width: calc(100% - 14px); height: 41px; min-height: 41px; flex: 0 0 41px; padding: 4px; position: relative; touch-action: pan-y; }
.day-indicator { position: absolute; top: 4px; bottom: 4px; left: calc(50% - 70px); width: 140px; background: var(--blue); border-radius: 100px; pointer-events: none; }
.day-switcher button { position: relative; z-index: 1; flex: 1 1 auto; min-width: max-content; min-height: 33px; padding: 4px clamp(8px, 2.5vw, 12px); background: transparent; color: rgba(0,55,68,.6); font-size: 14px; line-height: 17px; letter-spacing: -.84px; white-space: nowrap; transition: color 240ms ease; }
.day-switcher button.active { flex: 1.3 1 auto; background: transparent; color: #fff; }
.panel-scroll { flex: 1 1 0; min-height: 0; overflow-y: auto; overflow-x: hidden; overscroll-behavior-y: contain; scrollbar-width: thin; scrollbar-color: #10c6f0 #bff1fc; padding: 0 14px 92px 0; margin-right: 0; touch-action: pan-y; }
.panel-scroll::-webkit-scrollbar, .sheet-scroll::-webkit-scrollbar { width: 4px; }
.panel-scroll::-webkit-scrollbar-track, .sheet-scroll::-webkit-scrollbar-track { background: #bff1fc; border-radius: 100px; }
.panel-scroll::-webkit-scrollbar-thumb, .sheet-scroll::-webkit-scrollbar-thumb { background: #10c6f0; border-radius: 100px; }
.status-row { min-height: 0; }
.status-row:empty, .status-row.is-quiet { display: none; }
.status-row:not(.is-quiet):not(:empty) { margin-bottom: 8px; }
.schedule-list { gap: 4px; }
.lesson-card { min-height: 0; grid-template-columns: 45px 1.5px minmax(0, 1fr); padding: 12px 0 12px 4px; gap: 10px; }
/* Card height follows the taller column, including replacement controls and notes. */
.lesson-time { justify-content: flex-start; }
.lesson-number { color: #0283f1; }
.lesson-start, .lesson-end { color: #004682; }
.lesson-main { gap: 8px; }
.room { color: #008dae; }
.room img { width: auto; height: auto; object-fit: initial; }
.replacement-button { display: flex; width: 45px; height: 22px; align-items: center; justify-content: center; padding: 4px; border: 0; border-radius: 100px; background: rgba(241,114,2,.15); }
.replacement-button img { display: block; }
.official-link { display: flex; min-height: 49px; align-items: center; gap: 10px; margin-top: 16px; padding: 12px; border-radius: 16px; background: linear-gradient(rgba(0,141,174,.1),rgba(0,141,174,.1)), #f4f7f7; color: #305e69; text-decoration: none; font-size: 14px; font-weight: 600; line-height: 17px; letter-spacing: -.84px; }
.official-icon, .notice-icon { display: grid; width: 24.5px; height: 24.5px; flex: 0 0 24.5px; place-items: center; border-radius: 8.75px; background: #008dae; }
.official-icon img, .notice-icon img { display: block; }
.bottom-nav { z-index: 45; top: calc(var(--viewport-height) - var(--page-edge) - var(--nav-gap) - var(--nav-height)); bottom: auto; width: min(calc(100% - 2 * var(--nav-gap)), 410px); height: 67px; padding: 4px; grid-template-columns: minmax(0,1fr) var(--nav-active-width) minmax(0,1fr); background: var(--floating-surface); backdrop-filter: blur(12px); -webkit-backdrop-filter: blur(12px); box-shadow: none; transition: opacity 320ms var(--motion-ease), transform 480ms var(--motion-ease); }
.nav-indicator { top: 4px; bottom: 4px; left: calc(50% - var(--nav-active-width) / 2); width: var(--nav-active-width); transform: none; transition: left 480ms var(--motion-ease), width 480ms var(--motion-ease); }
.bottom-nav[data-active="schedule"] .nav-indicator { transform: none; }
.bottom-nav[data-active="week"] { grid-template-columns: var(--nav-active-width) minmax(0,1fr) minmax(0,1fr); }
.bottom-nav[data-active="week"] .nav-indicator { transform: none; left: 4px; }
.bottom-nav[data-active="more"] { grid-template-columns: minmax(0,1fr) minmax(0,1fr) var(--nav-active-width); }
.bottom-nav[data-active="more"] .nav-indicator { transform: none; left: calc(100% - var(--nav-active-width) - 4px); }
.nav-item { height: 59px; min-height: 59px; padding: 6px 0; color: rgba(0,55,68,.6); font-size: 12px; }
.nav-icon { display: grid; width: 32px; height: 32px; place-items: center; }
.nav-item .nav-icon img { width: auto; height: auto; object-fit: initial; filter: none; opacity: 1; }
.nav-item.active .nav-icon img { filter: brightness(0) invert(1); }
.nav-item:not(.active)[data-tab="schedule"] .nav-icon img { filter: brightness(0) saturate(100%) invert(34%) sepia(18%) saturate(889%) hue-rotate(145deg); }
.bell-button, .replacement-button, .official-link { transition: transform 320ms var(--motion-ease), background 240ms ease; }
.bell-button:active, .replacement-button:active, .official-link:active { transform: scale(.97); }
.notification-scroll { padding-left: 0; padding-right: 14px; }
.notification-screen .content-panel { padding-left: 20px; padding-right: 6px; }
.notification-screen .panel-handle { margin-right: 14px; }
.notice-list { gap: 8px; }
.notice-section-title { margin: 0 0 4px; font-size: 18px; font-weight: 700; line-height: 22px; letter-spacing: -1.08px; color: #305e69; }
.notice-section-title:not(:first-child) { margin-top: 8px; }
.notification-card { display: flex; width: 100%; gap: 10px; padding: 12px; border: 0; border-radius: 16px; background: rgba(48,94,105,.05); text-align: left; color: #305e69; }
.notification-card.is-read { opacity: .5; background: rgba(48,94,105,.1); }
.notice-icon { background: #f17202; }
.notice-icon.info { background: #10c6f0; opacity: .7; }
.notice-body { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 4px; }
.notice-line { display: flex; align-items: start; justify-content: space-between; gap: 8px; }
.notice-line strong { font-size: 14px; line-height: 17px; letter-spacing: -.84px; }
.notice-line small, .notice-body > span { color: #7f9da5; font-size: 12px; line-height: 15px; letter-spacing: -.72px; }
.notice-line small { flex-shrink: 0; }
.sheet-layer { position: fixed; z-index: 35; inset: 0 0 auto; height: var(--viewport-height); width: min(100%,430px); margin: auto; pointer-events: none; }
.sheet-layer[hidden], .bottom-sheet[hidden] { display: none; }
.sheet-dimmer { position: absolute; inset: var(--sheet-dim-top, 279px) 0 0; border-radius: 64px 64px 0 0; background: rgba(0,55,68,.15); pointer-events: auto; }
.bottom-sheet { position: absolute; z-index: 1; display: flex; flex-direction: column; bottom: var(--page-edge); width: 100%; max-height: none; min-height: 0; padding: 14px 28px 87px; border-radius: 64px 64px 0 0; background: #fff; pointer-events: auto; overflow: hidden; }
.changes-sheet { top: var(--sheet-top, 279px); }
.original-sheet { z-index: 2; top: max(calc(var(--sheet-top, 279px) + 72px), calc(var(--viewport-height) - var(--page-edge) - 380px)); }
.sheet-handle { margin: 0 auto 12px; cursor: grab; }
.bottom-sheet h2 { margin: 0 0 12px; color: #305e69; font-size: 18px; line-height: 22px; letter-spacing: -1.08px; }
.bottom-sheet.is-dragging { transform: translate3d(0, var(--sheet-drag-y, 0px), 0); will-change: transform; }
.bottom-sheet.is-dragging .sheet-handle { cursor: grabbing; }
.bottom-sheet > h2 { touch-action: none; }
.sheet-scroll { flex: 1 1 0; overflow-y: auto; min-height: 0; padding-right: 14px; scrollbar-width: thin; scrollbar-color: #10c6f0 #bff1fc; overscroll-behavior-y: contain; }
.sheet-card { padding: 8px; border-radius: 24px; background: rgba(48,94,105,.05); margin-bottom: 12px; }
.sheet-card .lesson-card { min-height: 0; padding: 14px 4px; }
.changes-sheet.is-underneath::after { content: ""; position: absolute; inset: 0; background: rgba(0,55,68,.15); opacity: var(--sheet-underneath-opacity, 1); pointer-events: auto; }
.toast { bottom: calc(var(--page-edge) + 90px); background: var(--floating-surface); color: #335f69; backdrop-filter: blur(12px); -webkit-backdrop-filter: blur(12px); transition: opacity 320ms ease, transform 480ms var(--motion-ease); }
@media (max-width: 359px) {
  .content-panel { padding-left: 20px; padding-right: 10px; border-radius: 52px 52px 0 0; }
  .day-heading h1 { font-size: 34px; letter-spacing: -2px; }
  .day-heading p { font-size: 23px; }
  .day-switcher button { font-size: 12px; }
  .day-indicator { width: 120px; left: calc(50% - 60px); }
  .hero-meta { font-size: 12px; }
  .lesson-card { grid-template-columns: 42px 1.5px minmax(0,1fr); gap: 8px; }
  .replacement-button { width: 42px; }
  .bottom-sheet { padding-inline: 20px; }
  .official-link { font-size: 12px; }
  :root { --nav-active-width: 140px; }
}
@media (min-width: 431px) {
  :root { --page-edge: 20px; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { scroll-behavior: auto !important; transition: none !important; animation: none !important; }
}

.nav-item:not(.active) .nav-icon { opacity: .6; }
#scheduleList > .schedule-separator { width: calc(100% - 14px); }
.notification-card { font-weight: 500; }
.panel-scroll, .sheet-scroll { scrollbar-width: none; }
.panel-scroll::-webkit-scrollbar, .sheet-scroll::-webkit-scrollbar { display: none; }
.scroll-track { position: absolute; width: 4px; right: 14px; top: 100px; bottom: 87px; border-radius: 100px; background: #bff1fc; pointer-events: none; overflow: hidden; }
.notification-screen .scroll-track { right: 6px; top: 68px; }
.bottom-sheet .scroll-track { right: 28px; top: 74px; }
.scroll-thumb { display: block; width: 4px; min-height: 24px; border-radius: 100px; background: #10c6f0; }
.scroll-track[hidden] { display: none; }




/* Beta refinements from the screen comments. */
.day-switcher button.is-today { font-weight: 650; }
.day-switcher button.is-today:not(.active) { color: var(--blue); background: transparent; }
.nav-item { transition: color 240ms ease; }
.page-art { height: calc(var(--page-hero-height) + var(--page-panel-radius)); }
.page-art .hero-star, .page-art .hero-mascot { opacity: 1; }
.page-hero { position: relative; z-index: 1; height: var(--page-hero-height); gap: 12px; }
.page-heading h1 { font-size: 42px; line-height: 51px; letter-spacing: -.06em; }
.page-heading p { font-size: 20px; line-height: 25px; letter-spacing: -1px; }
.page-content { position: relative; z-index: 2; }
.content-panel-style { min-height: calc(var(--screen-height) - var(--page-hero-height)); border-radius: var(--page-panel-radius) var(--page-panel-radius) 0 0; }
.more-content .settings-card, .more-content .menu-card, .more-content .action-card, .more-content .report-card { background: #f4f7f7; }
.more-content .owner-settings { background: var(--surface-soft-2); border-radius: calc(var(--page-panel-radius) - 20px) calc(var(--page-panel-radius) - 20px) 22px 22px; }
.more-content .report-card { color: #305e69; }
.more-content .quick-actions { margin-top: 0; }
.menu-section { display: grid; gap: 12px; }
.owner-field input, .owner-field select { border: 0; background: #fff; box-shadow: none; }
.owner-field input { appearance: none; -webkit-appearance: none; }
.notification-heading { display: flex; align-items: center; gap: 8px; min-width: 0; }
.notification-heading .back-button { width: 44px; height: 44px; flex-basis: 44px; border-radius: 16px; }
@media (max-width: 359px) {
  :root { --page-panel-radius: 52px; }
  .bottom-sheet .scroll-track { right: 20px; }
}

/* Draggable root panels and separate notification preferences. */
.app-shell:is([data-screen="week"], [data-screen="more"])[data-panel-position="medium"] { --panel-top: var(--page-hero-height); }
.root-panel-content { padding: 14px 6px 0 20px; }
.root-panel-content .week-switcher { width: calc(100% - 14px); flex-shrink: 0; }
.week-screen .scroll-track { top: 99px; right: 6px; }
.more-screen .scroll-track, .notification-settings-screen .scroll-track { top: 39px; right: 6px; }
.notification-settings-screen .notification-settings { margin-top: 0; }
.owner-field > span { color: var(--ink-80); }
.owner-field input::placeholder { color: var(--muted); opacity: 1; }

/* Shared spacing, typography and surfaces across Beta screens. */
:root {
  --page-inset: 20px;
  --card-inset: 16px;
  --row-inset: 12px;
  --space-small: 8px;
  --section-gap: 24px;
  --scroll-gutter: 14px;
  --scroll-edge: 6px;
  --content-clearance: calc(var(--nav-height) + var(--nav-gap) + 16px);
  --card-radius: 22px;
  --control-radius: 16px;
  --font-section: 18px;
  --font-body: 14px;
  --font-meta: 12px;
  --muted: #58737c;
}
.content-panel,
.root-panel-content,
.notification-screen .content-panel {
  padding-inline: var(--page-inset) var(--scroll-edge);
  border-radius: var(--page-panel-radius) var(--page-panel-radius) 0 0;
}
.panel-scroll { padding-right: var(--scroll-gutter); padding-bottom: var(--content-clearance); }
.panel-handle { margin-right: var(--scroll-gutter); }
.hero-meta, .hero-main h1 { text-shadow: 0 1px 3px rgba(0, 55, 68, .35); }
.scroll-track,
.week-screen .scroll-track,
.more-screen .scroll-track,
.notification-screen .scroll-track { right: var(--scroll-edge); bottom: calc(var(--nav-height) + var(--nav-gap) + 10px); }
.day-switcher,
.root-panel-content .week-switcher { width: calc(100% - var(--scroll-gutter)); }
.week-switcher { gap: 4px; min-height: 41px; }
.week-switcher button { min-height: 33px; }
.week-switcher .current-week-button { font-size: var(--font-body); line-height: 17px; }
.schedule-list .lesson-card { padding-inline: 0; }
#scheduleList > .schedule-separator { width: 100%; }
.lesson-title { color: var(--ink-80); opacity: 1; }
.lesson-teacher, .lesson-end { color: var(--muted); opacity: 1; }
.lesson-teacher, .room { line-height: 20px; }
.lesson-end { line-height: 18px; }
.lesson-start { color: #336897; opacity: 1; }
.student-note { color: var(--ink-80); }

.week-list { gap: var(--card-inset); }
.week-day-head { padding: var(--card-inset) var(--card-inset) var(--space-small); }
.week-lessons { padding: 0 var(--card-inset) var(--card-inset); }
.week-lessons .lesson-card { padding-inline: 0; }
.week-empty { padding: var(--space-small) var(--card-inset) var(--card-inset); font-size: var(--font-meta); line-height: 18px; }
.week-day-head small, .week-count { font-size: var(--font-meta); line-height: 16px; }
.week-status { padding: 4px 8px; font-size: var(--font-meta); line-height: 16px; }
.week-status.neutral, .status-chip.neutral { background: var(--surface-soft-2); color: var(--muted); }

.more-content { gap: var(--section-gap); }
.settings-card { padding: var(--card-inset); }
.settings-card, .menu-card { background: var(--surface-soft-2); }
.more-content .owner-settings {
  padding: var(--section-gap);
  border-radius: calc(var(--page-panel-radius) - var(--page-inset)) calc(var(--page-panel-radius) - var(--page-inset)) var(--card-radius) var(--card-radius);
}
.quick-actions, .menu-section { gap: var(--row-inset); }
.action-grid { gap: var(--row-inset); }
.action-card, .report-card { padding: var(--card-inset); gap: var(--row-inset); border-radius: var(--card-radius); }
.menu-row { padding: var(--card-inset); border-color: var(--line); }
.menu-row > span, .switch-row > span { gap: 4px; }
.menu-row small, .switch-row small { font-size: var(--font-meta); line-height: 18px; }
.section-heading h2, .settings-card h2, .quick-actions h2, .menu-section h2,
.notice-section-title, .bottom-sheet h2, .week-day-head strong {
  margin-top: 0; font-size: var(--font-section); font-weight: 700; line-height: 22px; letter-spacing: -.06em;
}
.field { gap: var(--space-small); margin-top: var(--card-inset); }
.field > span { color: var(--ink-80); font-size: var(--font-body); line-height: 20px; }
.field input, .field select, .field textarea {
  padding: var(--row-inset) var(--card-inset); border: 0; border-radius: var(--control-radius);
  /* iOS zooms focused form controls when their text is smaller than 16px. */
  background: var(--surface-soft-2); color: var(--ink-80); font-size: 16px; line-height: 20px;
}
.owner-field input, .owner-field select { background: #fff; }
.field input::placeholder, .field textarea::placeholder { color: var(--muted); opacity: 1; }
.primary-button, .secondary-button { border-radius: var(--control-radius); font-size: var(--font-body); line-height: 20px; }
.helper-copy, .about-copy { font-size: var(--font-meta); line-height: 18px; }
.helper-copy { margin-top: var(--card-inset); }
.intro-copy { color: var(--muted); font-size: var(--font-body); line-height: 20px; }

.back-button { width: 44px; height: 44px; flex-basis: 44px; border-radius: var(--control-radius); }
.detail-header { grid-template-columns: 44px minmax(0, 1fr) 44px; gap: var(--row-inset); padding-inline: var(--page-inset); }
.detail-header h1 { font-size: 26px; font-weight: 700; line-height: 31px; letter-spacing: -.06em; }
.detail-content { padding-top: 32px; padding-inline: var(--page-inset); border-radius: var(--page-panel-radius) var(--page-panel-radius) 0 0; }
.context-box { padding: var(--row-inset) var(--card-inset); border-radius: var(--control-radius); background: var(--surface-soft-2); color: var(--ink-80); font-size: var(--font-meta); line-height: 18px; }
.materials-list { gap: var(--row-inset); }
.materials-list details { border: 0; border-radius: var(--card-radius); }
.materials-list summary { padding: var(--card-inset); font-size: var(--font-body); line-height: 20px; }
.materials-list p { padding: 0 var(--card-inset) var(--card-inset); font-size: var(--font-body); line-height: 20px; }
.notice-list { gap: var(--row-inset); }
.notice-item, .notification-card { padding: var(--card-inset); border-radius: var(--card-radius); background: var(--surface-soft-2); }
.notification-card.is-read { opacity: 1; background: var(--surface-soft-2); }
.notification-card.is-read .notice-icon { opacity: .7; }
.notice-line { flex-wrap: wrap; gap: 4px var(--space-small); }
.notice-line strong { font-weight: 700; }
.notification-card.is-read .notice-line strong { font-weight: 600; }
.notice-line small, .notice-body > span, .notice-item span { color: var(--muted); font-size: var(--font-meta); line-height: 18px; }
.state-card { padding: var(--section-gap) var(--card-inset); border-radius: var(--card-radius); background: var(--surface-soft-2); }
.state-card strong { font-size: var(--font-section); line-height: 22px; }
.state-card span { font-size: var(--font-meta); line-height: 18px; }
.bottom-sheet { padding-inline: var(--page-inset) var(--scroll-edge); border-radius: var(--page-panel-radius) var(--page-panel-radius) 0 0; }
.sheet-dimmer { border-radius: var(--page-panel-radius) var(--page-panel-radius) 0 0; }
.bottom-sheet h2 { margin-right: var(--scroll-gutter); }
.sheet-handle { margin: 0 var(--scroll-gutter) var(--row-inset) 0; }
.sheet-scroll { padding-right: var(--scroll-gutter); }
.bottom-sheet .scroll-track { right: var(--scroll-edge); }
.sheet-card { padding: var(--card-inset); border-radius: var(--card-radius); background: var(--surface-soft-2); }
.sheet-card .lesson-card { padding: 0; }
.toast { border-radius: var(--control-radius); }
.app-tools { display: flex; flex-wrap: wrap; justify-content: center; gap: 8px 16px; }
.app-tools button { padding: 8px 0; border: 0; background: transparent; color: var(--blue-text); font-size: var(--font-meta); line-height: 18px; }
.viewport-check { width: min(calc(100% - 40px), 390px); max-height: calc(100dvh - 40px); margin: auto; padding: 24px; border: 0; border-radius: 24px; background: #fff; color: var(--ink-80); }
.viewport-check::backdrop { background: rgba(0, 55, 68, .3); }
.viewport-check h2 { margin: 0; font-size: 18px; line-height: 22px; letter-spacing: -.06em; }
.viewport-check p { font-size: 14px; line-height: 20px; color: var(--muted); }
.viewport-check textarea { display: block; width: 100%; height: 240px; padding: 12px; border: 0; border-radius: 16px; background: var(--surface-soft-2); color: var(--ink-80); font: 16px/22px ui-monospace, monospace; resize: none; }
@media (max-width: 359px) {
  .lesson-teacher, .room { line-height: 18px; }
}

/* Scrollable dates with a moving active indicator. */
.screen-stage { touch-action: auto; }
.hero, .detail-header { touch-action: pan-y; }
.day-switcher { gap: 4px; touch-action: auto; }
.day-viewport { flex: 1 1 0; min-width: 0; height: 33px; overflow-x: auto; overflow-y: hidden; scrollbar-width: none; overscroll-behavior-x: contain; touch-action: pan-x; border-radius: 999px; mask-image: linear-gradient(to right, transparent, #000 8px, #000 calc(100% - 8px), transparent); -webkit-mask-image: linear-gradient(to right, transparent, #000 8px, #000 calc(100% - 8px), transparent); }
.day-viewport::-webkit-scrollbar { display: none; }
.day-track { display: flex; position: relative; width: max-content; min-width: 100%; height: 33px; gap: 4px; }
.day-track button { flex: 0 0 auto; min-width: 76px; padding-inline: 12px; font-size: 14px; }
.day-track button.active { flex: 0 0 auto; }
.day-track .day-indicator { top: 0; bottom: 0; left: 0; }
.day-track button:focus-visible { outline-offset: -3px; }

/* Status hues share the saturation and 15% tint of the change badge. */
:root {
  --green-text: #179b64;
  --green-bg: rgba(23, 155, 100, .15);
  --dot-text: #2883de;
  --dot-bg: rgba(40, 131, 222, .15);
  --error-text: #d83a4a;
  --error-bg: rgba(216, 58, 74, .15);
}
.status-chip { font-weight: 600; }
.status-chip.info, .week-status.info, .status-chip.neutral, .week-status.neutral { color: var(--dot-text); background: var(--dot-bg); }
.status-chip.warning, .week-status.warning { color: var(--change-text); background: var(--change-bg); }
.status-chip.error, .week-status.error { color: var(--error-text); background: var(--error-bg); }
.status-dot { display: block; flex: 0 0 10px; width: 10px; height: 10px; border-radius: 50%; background: currentColor; }
.week-status .status-dot { flex-basis: 8px; width: 8px; height: 8px; }

.push-heading { margin-top: 24px; margin-bottom: 16px; }
#pushButton { width: 100%; }

.telegram-card { text-decoration: none; }
.site-update-card { text-decoration: none; }
.calendar-dialog { box-sizing: border-box; width: min(430px, calc(100% - 32px)); max-height: calc(100dvh - 32px); padding: 24px; border: 0; border-radius: 28px; background: #fff; color: var(--ink-80); overflow-y: auto; overscroll-behavior: contain; }
.calendar-dialog::backdrop { background: rgba(0,55,68,.25); }
.calendar-dialog-heading { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.calendar-dialog h2 { margin: 0; font-size: 24px; line-height: 1.2; }
.calendar-dialog h3 { margin: 0 0 10px; font-size: 18px; line-height: 1.3; }
.calendar-dialog p { font-size: 14px; line-height: 1.5; margin: 12px 0; }
.calendar-owner { font-weight: 600; overflow-wrap: anywhere; }
.calendar-choice { margin-top: 20px; padding: 20px; border-radius: 22px; background: var(--surface-soft); }
.calendar-choice .field { margin-block: 16px; }
.calendar-choice input { min-width: 0; width: 100%; font-size: 16px; }
.calendar-choice .primary-button, .calendar-choice .secondary-button { width: 100%; }
.calendar-subscribe { display: flex; align-items: center; justify-content: center; padding: 14px 12px; text-decoration: none; text-align: center; }
.calendar-note, #calendarCopyStatus { color: var(--ink-60, #607d85); }
#calendarCopyStatus:empty { display: none; }
@media (max-width: 360px) { .calendar-dialog { padding: 20px; } .calendar-choice { padding: 16px; } }

/* Appearance families share the same layout and semantic status colors. */
.appearance-settings { border-radius: var(--card-radius); }
.appearance-options { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; padding: 0; margin: 16px 0; border: 0; }
.appearance-option { position: relative; display: flex; flex-direction: column; gap: 10px; min-width: 0; padding: 10px; border: 2px solid transparent; border-radius: 20px; background: #fff; cursor: pointer; }
.appearance-option:has(input:checked), .variant-option:has(input:checked) { border-color: var(--blue-text); }
.appearance-option:has(input:focus-visible), .variant-option:has(input:focus-visible) { outline: 3px solid var(--ink); outline-offset: 3px; }
.appearance-option input, .variant-option input { position: absolute; width: 1px; height: 1px; opacity: 0; }
.appearance-preview { position: relative; display: block; height: 104px; overflow: hidden; border-radius: 12px; }
.azure-preview { background: #e8f5fa; }
.kitty-preview { background: linear-gradient(140deg, #f8c6d9, #ef93b7); }
.appearance-preview img { position: absolute; height: 100px; width: 100px; object-fit: contain; inset: 4px auto auto calc(50% - 50px); }
.appearance-option b, .variant-option b { display: block; color: var(--ink); font-size: 16px; line-height: 20px; }
.appearance-option small, .variant-option small { display: block; margin-top: 4px; color: var(--ink-80); font-size: 12px; line-height: 16px; }
.kitty-options { display: grid; gap: 8px; margin: 0; padding: 0; border: 0; }
.kitty-options[hidden] { display: none; }
.kitty-options legend { margin-bottom: 8px; color: var(--ink); font-size: 16px; font-weight: 600; }
.kitty-options .helper-copy { margin: 0 0 4px; }
.variant-option { position: relative; display: flex; align-items: center; gap: 12px; padding: 12px; border: 2px solid transparent; border-radius: 16px; background: #fff; cursor: pointer; }
.variant-swatch { width: 36px; height: 36px; flex: 0 0 36px; border-radius: 10px; }
.marshmallow-swatch { background: linear-gradient(135deg, #ffdfeb, #ed91b6); }
.bow-swatch { background: linear-gradient(135deg, #fa98c0, #da3281); }
.pixel-swatch { border-radius: 0; background: conic-gradient(#6c2048 25%, #f993c5 0 50%, #c8f4ff 0 75%, #fff6e9 0); }
:root[data-theme="kitty"] {
  --blue: #b6577d; --blue-text: #a44670; --ink: #35333b; --ink-80: #48434d; --muted: #77727e; --ink-60: #77727e;
  --surface-soft: #fceef4; --surface-soft-2: #fffafc; --line: #ece8ed;
  --floating-surface: rgba(252,238,244,.94);
  --theme-hero: radial-gradient(ellipse at 50% 80%, #f3d9e5, #f9e8f0 70%, #fff7fb);
  --theme-scroll: #f8eaf0; --lesson-accent: #527b8a; --lesson-accent-soft: #edf7fa;
}
:root[data-theme="kitty"][data-theme-variant="bow"] {
  --blue: #b6537e; --blue-text: #a2446b; --theme-hero: radial-gradient(ellipse at 50% 80%, #edcddd, #f7e3ec 70%, #fff6fa);
}
:root[data-theme="kitty"][data-theme-variant="pixel"] {
  --blue: #b6577d; --blue-text: #9e4468;
  --theme-hero: repeating-conic-gradient(rgba(255,255,255,.12) 0 25%, transparent 0 50%) 0 0 / 32px 32px, #f6e1eb;
}
:root[data-theme="kitty"] :is(.schedule-screen, .standard-screen, .detail-screen) { background: var(--theme-hero); }
:root[data-theme="kitty"] :is(.hero-star, .hero-star-high) { filter: hue-rotate(125deg) saturate(.3); opacity: .22; }
:root[data-theme="kitty"] [data-panel-position="high"] .hero-star { opacity: 0; }
:root[data-theme="kitty"] .hero-star-high { opacity: 0; }
:root[data-theme="kitty"] [data-panel-position="high"] .hero-star-high { opacity: .22; }
:root[data-theme="kitty"] .hero-mascot { width: 300px; height: 300px; object-fit: contain; left: calc(50% - 135px); top: calc(28px + var(--safe-top)); transform: rotate(6deg); }
:root[data-theme="kitty"] .hero-mascot-high { width: 215px; height: 215px; object-fit: contain; left: calc(50% - 25px); top: calc(14px + var(--safe-top)); transform: rotate(6deg); }
:root[data-theme="kitty"][data-theme-variant="pixel"] :is(.hero-mascot, .hero-mascot-high) { image-rendering: pixelated; transform: none; }
:root[data-theme="kitty"] :is(.hero, .page-hero, .detail-header),
:root[data-theme="kitty"] :is(.hero h1, .hero-main h1, .detail-header h1) { color: var(--ink); text-shadow: none; }
:root[data-theme="kitty"] :is(.day-heading p, .page-heading p, .detail-header p, .hero-meta, .back-button) { color: var(--ink-80); text-shadow: none; }
:root[data-theme="kitty"] :is(.content-panel, .detail-content, .bottom-sheet, .calendar-dialog, .viewport-check) { background: #fff; }
:root[data-theme="kitty"] :is(.lesson-start, .lesson-number, .room) { color: var(--lesson-accent); }
:root[data-theme="kitty"] .lesson-end { color: var(--muted); }
:root[data-theme="kitty"] .lesson-title { color: var(--ink); }
:root[data-theme="kitty"] :is(.lesson-teacher, .notice-line small, .notice-body > span, .notice-item span) { color: var(--muted); }
:root[data-theme="kitty"] .room img { filter: none; }
:root[data-theme="kitty"] .official-link { color: var(--lesson-accent); background: var(--lesson-accent-soft); }
:root[data-theme="kitty"] :is(.official-icon, .notice-icon.info) { background: var(--lesson-accent); opacity: 1; }
:root[data-theme="kitty"] .more-content :is(.settings-card, .menu-card, .action-card, .report-card) { background: var(--surface-soft-2); color: var(--ink-80); }
:root[data-theme="kitty"] :is(.notification-card, .notice-item, .sheet-card, .context-box, .materials-list details, .calendar-choice) { background: var(--surface-soft-2); color: var(--ink-80); }
:root[data-theme="kitty"] :is(.notice-section-title, .bottom-sheet h2) { color: var(--ink); }
:root[data-theme="kitty"] :is(.field input, .field select, .field textarea) { background: #fff; color: var(--ink); border-color: var(--line); }
:root[data-theme="kitty"] :is(.panel-scroll, .sheet-scroll) { scrollbar-color: var(--blue) var(--theme-scroll); }
:root[data-theme="kitty"] :is(.scroll-track, .panel-scroll::-webkit-scrollbar-track, .sheet-scroll::-webkit-scrollbar-track) { background: var(--theme-scroll); }
:root[data-theme="kitty"] :is(.scroll-thumb, .panel-scroll::-webkit-scrollbar-thumb, .sheet-scroll::-webkit-scrollbar-thumb) { background: #d99bb6; }
:root[data-theme="kitty"] .day-switcher button { color: var(--ink-80); }
:root[data-theme="kitty"] .day-switcher button.active { color: #fff; }
:root[data-theme="kitty"] .toast { color: var(--ink); }
:root[data-theme="kitty"] :is(.action-icon, .report-icon) { background: var(--lesson-accent); }
:root[data-theme="kitty"] :is(.action-icon img, .report-icon img) { filter: brightness(0) invert(1); }
:root[data-theme="kitty"] .bell-button img { filter: none; }
:root[data-theme="kitty"] .switch-row input { background-color: var(--lesson-accent-soft); border-color: var(--line); }
:root[data-theme="kitty"] .switch-row input:checked { background-color: var(--blue); }
:root[data-theme="kitty"] .kitty-preview { background: #f9e8f0; }
:root[data-theme="kitty"] .marshmallow-swatch { background: linear-gradient(135deg, #fff7fb, #f3d9e5); }
:root[data-theme="kitty"] .bow-swatch { background: linear-gradient(135deg, #f7e3ec, #edcddd); }
:root[data-theme="kitty"] .pixel-swatch { background: conic-gradient(#527b8a 25%, #f3d9e5 0 50%, #edf7fa 0 75%, #fffafc 0); }
/* Inactive navigation stays dark; white is reserved for the active item. */
:root[data-theme="kitty"] .nav-item:not(.active) .nav-icon { opacity: 1; }
:root[data-theme="kitty"] .nav-item:not(.active)[data-tab] .nav-icon img { filter: brightness(0) saturate(100%); opacity: 1; }
:root[data-theme="kitty"] .nav-item:not(.active) { color: var(--ink); }
:root[data-theme="kitty"] .nav-item.active { color: #fff; }

:root[data-theme="kitty"] .browser-top-tint { background-color: #f9e8f0; }

/* Approved YGK-Schedule Figma palette, shared by all Hello Kitty screens. */
:root[data-theme="kitty"] {
  --blue: #ff5691; --blue-text: #ff5691;
  --ink: #945767; --ink-80: #945767; --ink-60: #bc96a0; --muted: #bc96a0;
  --surface-soft: #ffe7f0; --surface-soft-2: #fffafc;
  --line: rgba(0,55,68,.15); --floating-surface: #fceef4;
  --theme-hero: radial-gradient(ellipse 320.49px 281.54px at calc(50% + 1.83px) 281.5px, #ffbbbc 0%, #ff829c 50%, #ff668d 75%, #ff497d 100%);
  --theme-scroll: rgba(255,86,145,.25);
  --lesson-accent: #ffad42; --lesson-accent-soft: #fff3e4;
}
:root[data-theme="kitty"][data-theme-variant="bow"],
:root[data-theme="kitty"][data-theme-variant="pixel"] { --blue: #ff5691; --blue-text: #ff5691; --theme-hero: radial-gradient(ellipse 320.49px 281.54px at calc(50% + 1.83px) 281.5px, #ffbbbc 0%, #ff829c 50%, #ff668d 75%, #ff497d 100%); }
:root[data-theme="kitty"] :is(.hero-star, .hero-star-high) { filter: none; }
:root[data-theme="kitty"][data-theme-variant="marshmallow"] .hero-mascot { width: 458.65px; height: 380.582px; left: calc(50% - 190.391px); top: calc(var(--panel-top) - 271.608px); transform: rotate(9.25deg); transition: top 480ms var(--motion-ease), opacity 480ms var(--motion-ease); }
:root[data-theme="kitty"] .app-shell.is-dragging .hero-mascot { transition: none; }
:root[data-theme="kitty"][data-theme-variant="marshmallow"] .hero-mascot-high { width: 300px; height: 249px; left: calc(50% - 70px); top: calc(-14px + var(--safe-top)); transform: rotate(9.25deg); }
:root[data-theme="kitty"] :is(.day-heading h1, .page-heading h1, .day-heading p, .page-heading p, .hero-meta, .detail-header h1, .detail-header p, .back-button) { color: #682135; text-shadow: none; }
:root[data-theme="kitty"] .lesson-number { color: #ff5691; }
:root[data-theme="kitty"] :is(.lesson-start, .lesson-end) { color: #640e26; }
:root[data-theme="kitty"] :is(.lesson-title, .lesson-teacher) { color: #792d42; }
:root[data-theme="kitty"] :is(.lesson-start, .lesson-title) { opacity: .8; }
:root[data-theme="kitty"] :is(.lesson-end, .lesson-teacher) { opacity: .5; }
:root[data-theme="kitty"] .lesson-divider { background: rgba(121,45,66,.15); }
:root[data-theme="kitty"] .room { color: #ffad42; }
:root[data-theme="kitty"] .room img { width: 12px; height: 16px; object-fit: contain; }
:root[data-theme="kitty"] .more-content .owner-settings { background: #f9eff4; }
:root[data-theme="kitty"] :is(.field input, .field select, .field textarea, .field input::placeholder, .field textarea::placeholder) { color: #945767; }
:root[data-theme="kitty"] :is(.scroll-thumb, .panel-scroll::-webkit-scrollbar-thumb, .sheet-scroll::-webkit-scrollbar-thumb) { background: #ff5691; }
:root[data-theme="kitty"] .day-switcher button { color: #99465c; }
:root[data-theme="kitty"] .day-switcher button.is-today:not(.active) { color: #ff5691; }
:root[data-theme="kitty"] .day-switcher button.active { color: #fff; }
:root[data-theme="kitty"] .nav-item:not(.active) { color: #945767; }
:root[data-theme="kitty"] .nav-item:not(.active)[data-tab] .nav-icon img { filter: none; }
:root[data-theme="kitty"] .nav-item:not(.active)[data-tab="schedule"] .nav-icon img { filter: brightness(0) saturate(100%) invert(39%) sepia(19%) saturate(969%) hue-rotate(293deg) brightness(90%) contrast(85%); }
:root[data-theme="kitty"] .browser-top-tint { background-color: #ff497d; }

/* Center theme thumbnails independently of the large header mascot. */
.appearance-preview { display: grid; place-items: center; }
.appearance-preview img { position: static; inset: auto; margin: 0; width: 100px; max-width: 100%; height: 100px; object-fit: contain; transform: none; }

/* The floating navigation uses the same translucency in both appearances. */
:root[data-theme="kitty"] { --floating-surface: linear-gradient(rgba(104,33,53,.1), rgba(104,33,53,.1)), rgba(255,86,145,.1); }
.nav-item:not(.active) .nav-icon { opacity: .6; }
.nav-item:not(.active)[data-tab] .nav-icon img { filter: brightness(0) saturate(100%) invert(34%) sepia(18%) saturate(889%) hue-rotate(145deg); opacity: 1; }
:root[data-theme="kitty"] .nav-item:not(.active) .nav-icon { opacity: .6; }
:root[data-theme="kitty"] .nav-item:not(.active) { color: rgba(148,87,103,.6); }
:root[data-theme="kitty"] .nav-item:not(.active)[data-tab] .nav-icon img { filter: brightness(0) saturate(100%) invert(39%) sepia(19%) saturate(969%) hue-rotate(293deg) brightness(90%) contrast(85%); opacity: 1; }

/* Hide decorative art across all screens without changing the header layout. */
:root[data-mascot="hidden"] :is(.hero-star, .hero-star-high, .hero-mascot, .hero-mascot-high) { visibility: hidden; }
.mascot-options { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; border: 0; padding: 0; margin: 16px 0; }
.mascot-options legend { color: var(--ink); font-weight: 600; margin-bottom: 8px; }
