@font-face {
  font-family: "jf-jinxuanlatte-2.0";
  src: url("assets/fonts/jf-jinxuan-latte-book.otf") format("opentype");
  font-weight: 300;
  font-display: swap;
}

@font-face {
  font-family: "jf-jinxuanlatte-2.0";
  src: url("assets/fonts/jf-jinxuan-latte-medium.otf") format("opentype");
  font-weight: 500;
  font-display: swap;
}

@font-face {
  font-family: "jf-jinxuanlatte-2.0";
  src: url("assets/fonts/jf-jinxuan-latte-bold.otf") format("opentype");
  font-weight: 700 900;
  font-display: swap;
}

:root {
  color-scheme: light;
  --font: "jf-jinxuanlatte-2.0", "PingFang TC", "Microsoft JhengHei", sans-serif;
  --ink: #4f4a42;
  --muted: #7f776d;
  --paper: #fffbf2;
  --panel: #fffefa;
  --line: #e5dcd1;
  --teal: #43929e;
  --teal-dark: #367f8a;
  --teal-light: #d0eaed;
  --yellow: #ebc15a;
  --yellow-light: #faf0d0;
  --latte: #d1bba5;
  --danger: #b96758;
  --shadow: 0 18px 50px rgba(79, 74, 66, 0.09);
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-width: 320px;
  color: var(--ink);
  background:
    radial-gradient(circle at 80% 0%, rgba(208, 234, 237, 0.85), transparent 25rem),
    var(--paper);
  font-family: var(--font);
  font-weight: 500;
}

button,
input,
select,
textarea {
  font: inherit;
}

button {
  cursor: pointer;
}

.app-shell {
  width: min(1240px, calc(100% - 40px));
  margin: 0 auto;
}

.topbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 82px;
  border-bottom: 1px solid rgba(79, 74, 66, 0.14);
}

.brand {
  display: flex;
  align-items: center;
  gap: 12px;
  color: inherit;
  text-decoration: none;
}

.brand-logo {
  width: 62px;
  height: 44px;
  object-fit: contain;
}

.brand strong,
.brand small {
  display: block;
}

.brand small {
  margin-top: 6px;
  color: var(--muted);
  font-size: 11px;
  font-weight: 300;
  letter-spacing: 0.12em;
}

.top-actions,
.heading-actions,
.focus-actions,
.dialog-actions {
  display: flex;
  align-items: center;
  gap: 10px;
}

.account-button {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  min-height: 42px;
  padding: 0 15px;
  color: var(--ink);
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: 999px;
  font-weight: 700;
}

.account-dot {
  width: 9px;
  height: 9px;
  background: var(--latte);
  border-radius: 50%;
}

.account-button.is-signed-in .account-dot {
  background: #68a95d;
  box-shadow: 0 0 0 4px rgba(104, 169, 93, 0.14);
}

.primary-button,
.secondary-button,
.quiet-button,
.danger-button {
  min-height: 44px;
  padding: 0 18px;
  border-radius: 999px;
  font-weight: 700;
  transition: 150ms ease;
}

.primary-button {
  color: #fff;
  background: var(--teal);
  border: 1px solid var(--teal);
}

.secondary-button {
  color: var(--ink);
  background: var(--yellow);
  border: 1px solid var(--yellow);
}

.quiet-button {
  color: var(--ink);
  background: transparent;
  border: 1px solid var(--line);
}

.danger-button {
  color: #fff;
  background: var(--danger);
  border: 1px solid var(--danger);
}

.primary-button:hover,
.secondary-button:hover,
.quiet-button:hover {
  transform: translateY(-1px);
}

.small {
  min-height: 36px;
  padding: 0 13px;
  font-size: 12px;
}

.compact {
  min-height: 42px;
}

.text-action {
  padding: 6px;
  color: var(--muted);
  background: transparent;
  border: 0;
  font-size: 12px;
}

.hero {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 40px;
  align-items: end;
  padding: 64px 0 40px;
}

.eyebrow {
  margin: 0 0 10px;
  color: var(--teal-dark);
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 0.17em;
}

h1,
h2,
h3,
p {
  margin-top: 0;
}

h1 {
  max-width: 800px;
  margin-bottom: 18px;
  font-size: clamp(42px, 6vw, 72px);
  line-height: 1.06;
  letter-spacing: -0.04em;
}

h2 {
  margin-bottom: 0;
  font-size: 28px;
}

.hero-description,
.section-description {
  margin-bottom: 0;
  color: var(--muted);
  font-weight: 300;
  line-height: 1.7;
}

.date-switcher {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 12px;
  background: var(--yellow);
  border-radius: 22px;
  box-shadow: var(--shadow);
}

.date-switcher button {
  width: 38px;
  height: 38px;
  color: var(--ink);
  background: rgba(255, 255, 255, 0.42);
  border: 0;
  border-radius: 50%;
}

.date-switcher label {
  display: grid;
  gap: 4px;
  text-align: center;
}

.date-switcher label span {
  font-size: 11px;
  font-weight: 800;
}

.date-switcher input {
  min-height: auto;
  padding: 0;
  background: transparent;
  border: 0;
  font-weight: 700;
}

.focus-panel {
  display: grid;
  grid-template-columns: minmax(0, 1.5fr) auto auto;
  gap: 28px;
  align-items: center;
  min-height: 190px;
  margin-bottom: 18px;
  padding: 30px;
  color: #fff;
  background: var(--teal);
  border-radius: 28px;
  box-shadow: var(--shadow);
}

.focus-panel.idle {
  color: var(--ink);
  background: var(--teal-light);
}

.focus-panel.paused {
  color: var(--ink);
  background: var(--yellow-light);
}

.focus-panel .eyebrow,
.focus-panel .focus-copy > span,
.focus-panel .focus-copy p,
.focus-panel .focus-clock span,
.focus-panel .focus-clock small {
  color: rgba(255, 255, 255, 0.74);
}

.focus-panel.idle .eyebrow,
.focus-panel.idle .focus-copy > span,
.focus-panel.idle .focus-copy p,
.focus-panel.idle .focus-clock span,
.focus-panel.idle .focus-clock small,
.focus-panel.paused .eyebrow,
.focus-panel.paused .focus-copy > span,
.focus-panel.paused .focus-copy p,
.focus-panel.paused .focus-clock span,
.focus-panel.paused .focus-clock small {
  color: var(--muted);
}

.focus-copy > span {
  display: block;
  margin-bottom: 8px;
  font-size: 12px;
}

.focus-copy h2 {
  margin-bottom: 10px;
  font-size: 30px;
}

.focus-copy p {
  max-width: 650px;
  margin-bottom: 0;
  font-weight: 300;
  line-height: 1.6;
}

.focus-clock {
  min-width: 220px;
  text-align: center;
}

.focus-clock span,
.focus-clock small {
  display: block;
  font-size: 11px;
}

.focus-clock strong {
  display: block;
  margin: 8px 0;
  font-size: 38px;
  font-variant-numeric: tabular-nums;
}

.stats-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 12px;
  margin-bottom: 20px;
}

.stat-card {
  min-height: 145px;
  padding: 22px;
  background: rgba(255, 254, 250, 0.9);
  border: 1px solid rgba(79, 74, 66, 0.1);
  border-radius: 20px;
}

.stat-card.featured {
  background: var(--yellow);
  border-color: var(--yellow);
}

.stat-card > span {
  display: block;
  margin-bottom: 22px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 700;
}

.stat-card strong {
  display: block;
  margin-bottom: 10px;
  font-size: 24px;
}

.stat-card p {
  margin-bottom: 0;
  color: var(--muted);
  font-size: 11px;
  font-weight: 300;
}

.panel {
  padding: 30px;
  background: var(--panel);
  border: 1px solid rgba(79, 74, 66, 0.1);
  border-radius: 26px;
  box-shadow: var(--shadow);
}

.panel-heading {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 20px;
  margin-bottom: 26px;
}

.schedule-heading {
  align-items: end;
}

.schedule-table-head,
.schedule-row {
  display: grid;
  grid-template-columns: 120px 1.05fr 1.8fr 140px 150px;
  gap: 18px;
  align-items: center;
}

.schedule-table-head {
  padding: 0 18px 10px;
  color: var(--muted);
  font-size: 11px;
  font-weight: 800;
}

.schedule-list {
  display: grid;
  gap: 10px;
}

.schedule-row {
  padding: 17px 18px;
  background: var(--paper);
  border: 1px solid transparent;
  border-radius: 17px;
}

.schedule-row.is-active {
  border-color: var(--teal);
  box-shadow: inset 5px 0 var(--teal);
}

.schedule-time strong,
.schedule-time span,
.schedule-time small,
.schedule-project strong,
.schedule-project span,
.schedule-project small,
.schedule-status strong,
.schedule-status small {
  display: block;
}

.schedule-time strong {
  font-size: 21px;
}

.schedule-time {
  padding: 12px 10px;
  background: var(--teal-light);
  border-radius: 14px;
  text-align: center;
}

.schedule-time span {
  color: var(--muted);
  font-size: 13px;
}

.schedule-time span::before {
  content: "↓";
  display: block;
  margin: 3px 0;
  color: var(--teal);
  font-size: 12px;
  line-height: 1;
}

.schedule-time small,
.schedule-project span,
.schedule-project small,
.schedule-status small {
  margin-top: 4px;
  color: var(--muted);
  font-size: 10px;
}

.schedule-time small {
  margin-top: 7px;
  padding-top: 7px;
  border-top: 1px solid rgba(30, 95, 91, 0.14);
}

.schedule-project strong,
.schedule-work strong {
  font-size: 14px;
}

.schedule-work p {
  margin: 5px 0;
  color: var(--muted);
  font-size: 12px;
  font-weight: 300;
  line-height: 1.5;
}

.schedule-work span {
  font-size: 11px;
  font-weight: 700;
}

.schedule-status {
  display: grid;
  justify-items: start;
  gap: 5px;
}

.schedule-status strong {
  font-size: 14px;
}

.status-pill,
.outcome {
  display: inline-flex;
  padding: 5px 9px;
  border-radius: 999px;
  font-size: 10px;
  font-weight: 800;
}

.status-planned {
  color: var(--teal-dark);
  background: var(--teal-light);
}

.status-running {
  color: #fff;
  background: var(--teal);
}

.status-paused {
  background: var(--yellow);
}

.status-completed {
  background: #dcebd7;
}

.status-incomplete {
  color: var(--danger);
  background: #f4ddd8;
}

.schedule-actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 5px;
}

.schedule-project {
  position: relative;
  padding-right: 46px;
}

.schedule-copy-button {
  position: absolute;
  top: -4px;
  right: 0;
  padding: 4px 7px;
  color: var(--teal-dark);
  background: transparent;
  border: 1px solid rgba(67, 146, 158, 0.28);
  border-radius: 999px;
  font-size: 9px;
  font-weight: 800;
}

.schedule-copy-button:hover {
  background: var(--teal-light);
}

.empty-state {
  display: grid;
  gap: 10px;
  justify-items: center;
  padding: 50px 20px;
  color: var(--muted);
  border: 1px dashed var(--latte);
  border-radius: 16px;
  text-align: center;
}

.empty-state.compact {
  padding: 32px 15px;
}

.review-grid {
  display: grid;
  grid-template-columns: 1.2fr 0.8fr;
  gap: 20px;
  margin-top: 20px;
}

.strategy-review-grid {
  grid-template-columns: minmax(0, 1.05fr) minmax(360px, 0.95fr);
  align-items: start;
}

.quadrant-chart {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
}

.quadrant-cell {
  min-height: 126px;
  padding: 16px;
  border: 1px solid rgba(79, 74, 66, 0.09);
  border-radius: 16px;
}

.quadrant-cell span,
.quadrant-cell strong,
.quadrant-cell small {
  display: block;
}

.quadrant-cell span {
  color: var(--muted);
  font-size: 10px;
  font-weight: 800;
}

.quadrant-cell strong {
  margin: 8px 0 2px;
  font-size: 27px;
}

.quadrant-cell small {
  color: var(--muted);
  font-size: 10px;
}

.quadrant-cell p {
  margin: 11px 0 0;
  font-size: 11px;
  font-weight: 700;
}

.quadrant-cell.core {
  background: #e2f1e2;
}

.quadrant-cell.cash {
  background: var(--yellow-light);
}

.quadrant-cell.growth {
  background: var(--teal-light);
}

.quadrant-cell.drain {
  background: #f4e3df;
}

.operation-alert {
  display: grid;
  gap: 5px;
  margin-top: 12px;
  padding: 13px 15px;
  border-left: 5px solid var(--teal);
  border-radius: 12px;
}

.operation-alert strong {
  font-size: 12px;
}

.operation-alert span {
  color: var(--muted);
  font-size: 11px;
  line-height: 1.55;
}

.operation-alert.neutral,
.operation-alert.healthy {
  background: var(--teal-light);
}

.operation-alert.notice {
  background: #fff0bd;
  border-color: #d6a82c;
}

.operation-alert.warning {
  background: #f9dfc3;
  border-color: #d9863b;
}

.operation-alert.danger {
  background: #f4d6d0;
  border-color: var(--danger);
}

.time-block-heading {
  align-items: flex-start;
}

.time-block-legend {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-bottom: 14px;
  color: var(--muted);
  font-size: 10px;
}

.time-block-legend span {
  display: inline-flex;
  align-items: center;
  gap: 5px;
}

.time-block-legend i {
  width: 10px;
  height: 10px;
  border-radius: 3px;
}

.time-block-legend .output {
  background: var(--yellow);
}

.time-block-legend .input {
  background: var(--teal);
}

.time-block-legend .rest {
  background: var(--latte);
}

.time-block-timeline {
  display: grid;
  gap: 18px;
}

.timeline-half {
  min-width: 0;
}

.timeline-labels {
  position: relative;
  height: 18px;
  margin: 0 6px;
  color: var(--muted);
  font-size: 8px;
}

.timeline-labels span {
  position: absolute;
  transform: translateX(-50%);
}

.timeline-labels span:first-child {
  transform: none;
}

.timeline-labels span:last-child {
  transform: translateX(-100%);
}

.time-track {
  position: relative;
  height: 116px;
  overflow: hidden;
  background: #f8f4ec;
  border: 1px solid var(--line);
  border-radius: 14px;
  cursor: crosshair;
  touch-action: pan-y;
  user-select: none;
}

.timeline-grid {
  position: absolute;
  inset: 0;
  background-image: repeating-linear-gradient(
    to right,
    transparent 0,
    transparent calc(8.333% - 1px),
    rgba(79, 74, 66, 0.09) calc(8.333% - 1px),
    rgba(79, 74, 66, 0.09) 8.333%
  );
  pointer-events: none;
}

.time-block {
  position: absolute;
  z-index: 2;
  top: calc(9px + var(--lane) * 34px);
  display: grid;
  min-width: 14px;
  height: 28px;
  align-content: center;
  overflow: hidden;
  padding: 3px 7px;
  color: var(--ink);
  border: 0;
  border-radius: 8px;
  text-align: left;
}

.time-block.output {
  background: var(--yellow);
}

.time-block.input {
  color: #fff;
  background: var(--teal);
}

.time-block.unclassified {
  background: var(--yellow-light);
  outline: 1px dashed var(--latte);
}

.time-block.rest {
  background: var(--latte);
}

.time-block.drag-preview {
  z-index: 4;
  opacity: 0.7;
  pointer-events: none;
}

.time-block strong,
.time-block small {
  overflow: hidden;
  font-size: 8px;
  line-height: 1.15;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.time-block small {
  opacity: 0.75;
}

.result-list {
  display: grid;
  gap: 10px;
}

.result-item {
  display: grid;
  gap: 12px;
  padding: 18px;
  background: var(--yellow-light);
  border-radius: 14px;
}

.result-heading {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr) auto;
  align-items: center;
  gap: 14px;
}

.result-heading div span,
.result-heading div strong {
  display: block;
}

.result-heading div span,
.result-detail span {
  margin-bottom: 5px;
  color: var(--muted);
  font-size: 10px;
}

.result-heading div strong {
  font-size: 13px;
}

.result-detail {
  padding: 12px 14px;
  background: rgba(255, 255, 255, 0.72);
  border-radius: 11px;
}

.result-detail.featured-result {
  border-left: 4px solid var(--teal);
}

.result-detail p {
  margin: 0;
  color: var(--ink);
  font-size: 13px;
  line-height: 1.65;
  white-space: pre-wrap;
}

.result-review-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}

.outcome {
  background: var(--latte);
}

.outcome.achieved {
  background: #dcebd7;
}

.strategy-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 5px;
  margin: 8px 0;
}

.strategy-tags span {
  padding: 3px 7px;
  color: var(--muted);
  background: #f5efe5;
  border-radius: 999px;
  font-size: 9px;
  font-weight: 700;
}

.strategy-tags span.output {
  color: var(--ink);
  background: var(--yellow-light);
}

.strategy-tags span.input {
  color: var(--teal-dark);
  background: var(--teal-light);
}

#dailyReviewForm {
  display: grid;
  gap: 16px;
}

.saved-review {
  display: grid;
  gap: 10px;
  margin-top: 20px;
  padding-top: 20px;
  border-top: 1px solid var(--line);
}

.saved-review > span {
  color: var(--teal-dark);
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 0.08em;
}

.saved-review section {
  padding: 14px;
  background: var(--yellow-light);
  border-radius: 13px;
}

.saved-review small {
  display: block;
  margin-bottom: 6px;
  color: var(--muted);
  font-size: 10px;
  font-weight: 800;
}

.saved-review p {
  margin-bottom: 0;
  font-size: 13px;
  font-weight: 300;
  line-height: 1.65;
  white-space: pre-wrap;
}

.export-panel {
  display: grid;
  grid-template-columns: minmax(260px, 0.8fr) minmax(520px, 1.2fr);
  align-items: center;
  gap: 24px;
  margin-top: 20px;
  padding: 28px 30px;
  color: #fff;
  background: var(--teal);
  border-radius: 24px;
  box-shadow: var(--shadow);
}

.export-panel .eyebrow {
  margin-bottom: 16px;
}

.export-panel .eyebrow,
.export-panel p {
  color: rgba(255, 255, 255, 0.76);
}

.export-panel h2 {
  margin-bottom: 10px;
}

.export-panel p {
  margin-bottom: 0;
  font-weight: 300;
}

.export-panel .primary-button {
  color: var(--ink);
  background: var(--yellow);
  border-color: var(--yellow);
  white-space: nowrap;
}

.export-actions {
  display: grid;
  grid-template-columns: auto minmax(320px, 1fr) auto;
  align-items: end;
  gap: 10px;
}

.export-presets {
  display: flex;
  gap: 6px;
}

.export-presets button {
  min-height: 42px;
  padding: 0 13px;
  color: #fff;
  background: rgba(255, 255, 255, 0.12);
  border: 1px solid rgba(255, 255, 255, 0.28);
  border-radius: 999px;
  font-weight: 700;
}

.export-date-range {
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: end;
  gap: 8px;
}

.export-date-range label {
  gap: 5px;
  color: rgba(255, 255, 255, 0.76);
  font-size: 11px;
}

.export-date-range input {
  min-height: 42px;
  color: var(--ink);
  background: #fff;
}

.export-date-range > span {
  padding-bottom: 13px;
  color: rgba(255, 255, 255, 0.7);
  font-size: 12px;
}

.export-actions small {
  grid-column: 1 / -1;
  justify-self: end;
  max-width: 280px;
  color: rgba(255, 255, 255, 0.72);
  font-size: 12px;
  line-height: 1.5;
  text-align: right;
}

.print-report {
  display: none;
}

label {
  display: grid;
  gap: 8px;
  font-size: 13px;
  font-weight: 700;
}

input,
select,
textarea {
  width: 100%;
  color: var(--ink);
  background: var(--paper);
  border: 1px solid #ddd1c4;
  border-radius: 12px;
  outline: none;
}

input,
select {
  min-height: 48px;
  padding: 0 13px;
}

textarea {
  min-height: 92px;
  padding: 13px;
  resize: vertical;
  line-height: 1.6;
}

input:focus,
select:focus,
textarea:focus {
  border-color: var(--teal);
  box-shadow: 0 0 0 3px rgba(67, 146, 158, 0.14);
}

input[readonly] {
  color: var(--muted);
  background: #f4efe6;
}

.app-dialog {
  width: min(760px, calc(100% - 32px));
  max-height: calc(100vh - 32px);
  padding: 0;
  color: var(--ink);
  background: var(--panel);
  border: 0;
  border-radius: 26px;
  box-shadow: 0 24px 90px rgba(79, 74, 66, 0.3);
}

.app-dialog::backdrop {
  background: rgba(79, 74, 66, 0.58);
  backdrop-filter: blur(5px);
}

.dialog-header,
.dialog-actions {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 23px 27px;
}

.dialog-header {
  border-bottom: 1px solid var(--line);
}

.dialog-actions {
  justify-content: flex-end;
  border-top: 1px solid var(--line);
}

.dialog-close {
  display: grid;
  width: 42px;
  height: 42px;
  place-items: center;
  color: var(--ink);
  background: var(--yellow-light);
  border: 0;
  border-radius: 50%;
  font-size: 25px;
}

.dialog-body {
  display: grid;
  gap: 20px;
  max-height: calc(100vh - 190px);
  padding: 25px 27px;
  overflow-y: auto;
}

.field-grid {
  display: grid;
  gap: 16px;
}

.field-grid.two {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.field-grid.three {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.planned-duration {
  display: grid;
  grid-template-columns: minmax(160px, 1fr) auto auto;
  align-items: center;
  gap: 16px;
  padding: 13px 15px;
  background: var(--teal-light);
  border-radius: 12px;
  font-size: 12px;
}

.planned-duration > div:first-child span,
.planned-duration > div:first-child small {
  display: block;
}

.planned-duration > div:first-child small {
  margin-top: 4px;
  color: var(--muted);
  font-weight: 300;
}

.duration-inputs {
  display: flex;
  gap: 8px;
}

.duration-inputs label {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 11px;
}

.duration-inputs input {
  width: 72px;
  min-height: 40px;
  background: #fff;
}

.planned-duration > strong {
  white-space: nowrap;
}

.recurrence-panel {
  display: grid;
  grid-template-columns: minmax(220px, 1fr) minmax(180px, 0.7fr);
  align-items: end;
  gap: 12px 16px;
  padding: 16px;
  background: var(--yellow-light);
  border-radius: 14px;
}

.recurrence-panel p {
  grid-column: 1 / -1;
  margin: 0;
  color: var(--muted);
  font-size: 11px;
  font-weight: 300;
  line-height: 1.5;
}

.strategy-fields {
  display: grid;
  grid-template-columns: minmax(180px, 1.2fr) repeat(3, minmax(120px, 0.8fr));
  align-items: end;
  gap: 12px;
  padding: 16px;
  background: #f7f2e9;
  border-radius: 14px;
}

.strategy-fields > div span,
.strategy-fields > div small {
  display: block;
}

.strategy-fields > div small {
  margin-top: 5px;
  color: var(--muted);
  font-size: 10px;
  font-weight: 300;
  line-height: 1.5;
}

.recurrence-label {
  display: block;
  margin-bottom: 4px;
  color: var(--teal-dark);
}

.completion-summary {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 10px;
}

.completion-summary div {
  padding: 14px;
  background: var(--yellow-light);
  border-radius: 12px;
}

.completion-summary span,
.completion-summary strong {
  display: block;
}

.completion-summary span {
  margin-bottom: 6px;
  color: var(--muted);
  font-size: 10px;
}

.completion-summary strong {
  font-size: 12px;
  line-height: 1.5;
}

.completion-summary small {
  display: block;
  margin-top: 5px;
  color: var(--muted);
  font-size: 10px;
}

.actual-metrics-summary button,
.actual-clock-summary button {
  margin-top: 8px;
  padding: 0;
  font-size: 11px;
}

.actual-metrics-editor {
  display: grid;
  gap: 14px;
  padding: 16px;
  background: var(--teal-light);
  border-radius: 14px;
}

.actual-metrics-heading {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
}

.actual-metrics-heading strong,
.actual-metrics-heading small {
  display: block;
}

.actual-metrics-heading small {
  margin-top: 5px;
  color: var(--muted);
  font-size: 11px;
  font-weight: 300;
  line-height: 1.5;
}

.actual-time-inputs {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
}

.actual-clock-inputs {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}

.rest-optional-details {
  background: var(--paper);
  border: 1px solid var(--line);
}

.review-details {
  padding: 16px;
  background: var(--yellow-light);
  border-radius: 14px;
}

.review-details summary {
  cursor: pointer;
  font-weight: 800;
}

.review-details label {
  margin-top: 16px;
}

.settings-dialog {
  width: min(1120px, calc(100% - 32px));
}

.life-planning-dialog {
  width: min(1080px, calc(100% - 32px));
}

.nested-dialog {
  width: min(680px, calc(100% - 32px));
}

.planning-tabs {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 6px;
  padding: 5px;
  background: var(--yellow-light);
  border-radius: 14px;
}

.planning-tabs button {
  min-height: 42px;
  color: var(--muted);
  background: transparent;
  border: 0;
  border-radius: 10px;
  font-weight: 800;
}

.planning-tabs button.active {
  color: #fff;
  background: var(--teal);
}

.life-budget-grid,
.business-finance-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
}

.life-budget-card,
.finance-ledger-card,
.revenue-target-card {
  padding: 20px;
  background: #f7f2e9;
  border: 1px solid var(--line);
  border-radius: 18px;
}

.life-budget-card.ideal {
  background: var(--yellow-light);
}

.life-budget-card > div:first-child span,
.life-budget-card > div:first-child strong,
.life-budget-card > div:first-child small {
  display: block;
}

.life-budget-card > div:first-child span {
  color: var(--muted);
  font-size: 11px;
  font-weight: 800;
}

.life-budget-card > div:first-child strong {
  margin: 7px 0 3px;
  font-size: 22px;
}

.life-budget-card > div:first-child small {
  color: var(--muted);
}

.budget-fields {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
  margin: 18px 0;
}

.money-input,
.percent-input {
  display: flex;
  align-items: center;
  gap: 7px;
}

.money-input span,
.percent-input span {
  color: var(--muted);
  font-weight: 800;
}

.finance-ledger-card {
  display: grid;
  gap: 10px;
}

.finance-ledger-card > span,
.finance-ledger-card > strong {
  display: block;
}

.finance-ledger-card > span {
  color: var(--muted);
  font-size: 11px;
  font-weight: 800;
}

.finance-ledger-card > strong {
  font-size: 22px;
}

.finance-ledger-card > button {
  min-height: 40px;
  color: var(--teal-dark);
  background: var(--teal-light);
  border: 0;
  border-radius: 10px;
  font-weight: 800;
}

.finance-ledger-card small {
  line-height: 1.5;
}

.coverage-ok {
  color: #52704d;
}

.coverage-short {
  color: var(--danger);
}

.revenue-target-card {
  display: grid;
  grid-template-columns: 1fr minmax(160px, 0.7fr) 1fr;
  align-items: center;
  gap: 18px;
  margin-top: 14px;
  background: var(--teal-light);
}

.revenue-target-card span,
.revenue-target-card strong {
  display: block;
}

.revenue-target-card span {
  color: var(--muted);
  font-size: 11px;
}

.revenue-target-card strong {
  margin-top: 5px;
  font-size: 20px;
}

.revenue-target-result {
  padding: 15px;
  background: #fff;
  border-radius: 13px;
}

.freedom-target {
  padding: 18px;
  text-align: center;
  background: var(--yellow-light);
  border-radius: 15px;
}

.freedom-target span,
.freedom-target strong {
  display: block;
}

.freedom-target strong {
  margin-top: 6px;
  font-size: 24px;
}

.freedom-projection-list {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
}

.freedom-projection-list article {
  padding: 15px;
  background: #f7f2e9;
  border-radius: 13px;
}

.freedom-projection-list span,
.freedom-projection-list strong {
  display: block;
}

.freedom-projection-list span {
  color: var(--muted);
  font-size: 10px;
}

.freedom-projection-list strong {
  margin-top: 5px;
  font-size: 13px;
}

.freedom-projection-list p {
  margin: 9px 0 0;
  color: var(--teal-dark);
  font-size: 11px;
  line-height: 1.5;
}

.finance-ledger-list {
  display: grid;
  gap: 8px;
}

.finance-ledger-list article {
  position: relative;
  padding: 14px;
  background: var(--yellow-light);
  border-radius: 12px;
}

.finance-ledger-list article > div {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  padding-right: 52px;
}

.finance-ledger-list article > button {
  position: absolute;
  top: 14px;
  right: 14px;
}

.finance-ledger-list details {
  margin-top: 10px;
  font-size: 11px;
}

.finance-ledger-list p {
  line-height: 1.6;
  white-space: pre-wrap;
}

.finance-ledger-entry {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 14px;
  padding-top: 18px;
  border-top: 1px solid var(--line);
}

.finance-ledger-entry label:last-child {
  grid-column: 1 / -1;
}

.rest-ratings {
  margin: 0;
  padding: 16px;
  border: 1px solid var(--line);
  border-radius: 14px;
}

.rest-ratings legend {
  padding: 0 7px;
  font-weight: 800;
}

#restRatingFields {
  display: grid;
  gap: 13px;
}

.star-rating-row {
  display: grid;
  grid-template-columns: 90px 1fr;
  align-items: center;
  gap: 12px;
}

.star-rating-row > span {
  font-size: 12px;
  font-weight: 800;
}

.star-rating {
  display: flex;
  gap: 4px;
}

.star-rating label {
  position: relative;
  display: grid;
  gap: 1px;
  place-items: center;
  cursor: pointer;
}

.star-rating input {
  position: absolute;
  width: 1px;
  height: 1px;
  opacity: 0;
}

.star-rating label span {
  color: #d8cec0;
  font-size: 24px;
}

.star-rating label small {
  color: var(--muted);
  font-size: 8px;
}

.star-rating label:has(input:checked) span,
.star-rating label:has(input:checked) ~ label span {
  color: #d8cec0;
}

.star-rating:has(input[value="1"]:checked) label:nth-child(-n + 1) span,
.star-rating:has(input[value="2"]:checked) label:nth-child(-n + 2) span,
.star-rating:has(input[value="3"]:checked) label:nth-child(-n + 3) span,
.star-rating:has(input[value="4"]:checked) label:nth-child(-n + 4) span,
.star-rating:has(input[value="5"]:checked) label:nth-child(-n + 5) span {
  color: var(--yellow);
}

.privacy-option {
  display: grid;
  grid-template-columns: auto 1fr;
  align-items: start;
  gap: 13px;
  padding: 17px;
  border: 1px solid var(--line);
  border-radius: 14px;
  cursor: pointer;
}

.privacy-option:has(input:checked) {
  background: var(--yellow-light);
  border-color: var(--yellow);
}

.privacy-option input {
  width: 19px;
  min-height: 19px;
  margin-top: 2px;
}

.privacy-option strong,
.privacy-option small {
  display: block;
}

.privacy-option small {
  margin-top: 5px;
  color: var(--muted);
  font-weight: 300;
}

.auth-dialog {
  width: min(520px, calc(100% - 30px));
}

.auth-intro {
  margin-top: 0;
  color: var(--muted);
  font-weight: 300;
  line-height: 1.7;
}

.auth-tabs {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 6px;
  margin-bottom: 20px;
  padding: 5px;
  background: var(--yellow-light);
  border-radius: 14px;
}

.auth-tabs button {
  min-height: 40px;
  color: var(--muted);
  background: transparent;
  border: 0;
  border-radius: 10px;
  font-weight: 700;
}

.auth-tabs button.active {
  color: #fff;
  background: var(--teal);
}

#authForm,
#passwordRecoveryForm,
.signed-in-panel {
  display: grid;
  gap: 16px;
}

#authForm .primary-button,
#passwordRecoveryForm .primary-button,
.signed-in-panel .quiet-button {
  width: 100%;
}

.auth-hint {
  margin: -4px 0 0;
  color: var(--muted);
  font-size: 12px;
  font-weight: 300;
  line-height: 1.6;
}

.auth-reset,
.danger-action {
  justify-self: center;
}

.danger-action {
  color: var(--danger);
}

.cloud-account-card {
  display: grid;
  gap: 6px;
  padding: 20px;
  background: var(--teal-light);
  border-radius: 16px;
}

.cloud-account-card span,
.cloud-account-card small {
  color: var(--muted);
  font-size: 11px;
}

.cloud-account-card strong {
  font-size: 18px;
  overflow-wrap: anywhere;
}

#cloudSyncStatus[data-state="success"] {
  color: #477c40;
}

#cloudSyncStatus[data-state="error"] {
  color: var(--danger);
}

.signed-in-panel > p,
.cloud-unavailable p {
  margin: 0;
  color: var(--muted);
  font-weight: 300;
  line-height: 1.7;
}

.cloud-unavailable {
  padding: 18px;
  background: var(--yellow-light);
  border-radius: 14px;
}

.cloud-unavailable strong {
  display: block;
  margin-bottom: 7px;
}

.settings-intro {
  margin-bottom: 0;
  color: var(--muted);
  font-weight: 300;
}

.settings-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 18px;
}

.settings-grid section {
  min-width: 0;
  padding: 18px;
  background: var(--paper);
  border-radius: 16px;
}

.settings-grid h3 {
  margin-bottom: 14px;
}

.inline-form {
  display: grid;
  gap: 8px;
}

.inline-form + .inline-form {
  margin-top: 12px;
  padding-top: 12px;
  border-top: 1px solid var(--line);
}

.inline-form button {
  min-height: 40px;
  color: #fff;
  background: var(--teal);
  border: 0;
  border-radius: 10px;
  font-weight: 800;
}

.settings-list {
  display: grid;
  gap: 9px;
  margin-top: 15px;
}

.settings-folder {
  overflow: hidden;
  background: rgba(255, 255, 255, 0.72);
  border: 1px solid rgba(79, 74, 66, 0.08);
  border-radius: 12px;
}

.settings-folder summary {
  display: flex;
  align-items: center;
  gap: 9px;
  padding: 12px;
  cursor: pointer;
  list-style: none;
}

.settings-folder summary::-webkit-details-marker {
  display: none;
}

.settings-folder summary::after {
  content: "⌄";
  flex: 0 0 auto;
  color: var(--muted);
  transition: transform 150ms ease;
}

.settings-folder[open] summary::after {
  transform: rotate(180deg);
}

.settings-folder summary strong {
  flex: 1 1 auto;
  overflow: hidden;
  font-size: 12px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.settings-folder summary small {
  flex: 0 0 auto;
  color: var(--muted);
  font-size: 9px;
}

.folder-icon {
  position: relative;
  width: 18px;
  height: 13px;
  background: var(--yellow);
  border-radius: 3px;
}

.folder-icon::before {
  position: absolute;
  top: -4px;
  left: 2px;
  width: 8px;
  height: 5px;
  background: var(--yellow);
  border-radius: 3px 3px 0 0;
  content: "";
}

.settings-folder-content {
  display: grid;
  gap: 7px;
  padding: 0 9px 9px;
}

.drag-handle {
  color: #aaa095;
  cursor: grab;
  font-size: 12px;
  letter-spacing: -0.2em;
  user-select: none;
}

.is-dragging {
  opacity: 0.45;
}

.is-drag-over {
  outline: 2px dashed var(--teal);
  outline-offset: -3px;
}

.setting-actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 3px;
}

.settings-folder-content > .setting-actions {
  padding: 0 3px 3px;
  border-bottom: 1px solid rgba(79, 74, 66, 0.08);
}

.setting-actions button {
  padding: 5px 6px;
  color: var(--teal-dark);
  background: transparent;
  border: 0;
  font-size: 9px;
}

.setting-actions .danger-text {
  color: var(--danger);
}

.folder-remove {
  justify-self: end;
  padding: 5px;
  color: var(--danger);
  background: transparent;
  border: 0;
  font-size: 10px;
}

.setting-item {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  align-items: center;
  gap: 10px;
  padding: 9px 10px;
  background: #fff;
  border-radius: 10px;
}

.setting-item-copy strong,
.setting-item-copy small {
  display: block;
}

.setting-title-row {
  display: flex;
  align-items: center;
  gap: 6px;
  min-width: 0;
}

.setting-title-row strong {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.setting-item-copy strong {
  font-size: 12px;
}

.setting-item-copy small {
  margin-top: 2px;
  color: var(--muted);
  font-size: 9px;
}

.settings-empty {
  color: var(--muted);
  font-size: 11px;
}

.responsibility-category {
  overflow: hidden;
  border: 1px solid rgba(52, 126, 138, 0.18);
  border-radius: 13px;
}

.responsibility-category > summary {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto auto;
  align-items: center;
  gap: 9px;
  padding: 13px 14px;
  color: var(--teal-dark);
  background: rgba(52, 126, 138, 0.08);
  cursor: pointer;
  list-style: none;
}

.responsibility-category > summary::-webkit-details-marker {
  display: none;
}

.responsibility-category > summary::after {
  content: "⌄";
  color: var(--teal-dark);
  transition: transform 150ms ease;
}

.responsibility-category[open] > summary::after {
  transform: rotate(180deg);
}

.responsibility-category > summary strong {
  overflow: hidden;
  font-size: 12px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.responsibility-category > summary small {
  color: var(--muted);
  font-size: 9px;
}

.responsibility-category-content {
  display: grid;
  gap: 8px;
  padding: 9px;
  background: rgba(255, 255, 255, 0.5);
}

.note-eye {
  display: inline-grid;
  place-items: center;
  flex: 0 0 25px;
  width: 25px;
  height: 25px;
  padding: 5px;
  color: var(--muted);
  background: transparent;
  border: 1px solid transparent;
  border-radius: 50%;
}

.note-eye:hover,
.note-eye:focus-visible {
  color: var(--teal-dark);
  background: rgba(52, 126, 138, 0.1);
}

.note-eye.has-note {
  color: var(--teal-dark);
  background: rgba(52, 126, 138, 0.12);
  border-color: rgba(52, 126, 138, 0.16);
}

.note-eye svg {
  width: 100%;
  height: 100%;
  fill: none;
  stroke: currentColor;
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-width: 1.8;
}

.data-editor-dialog,
.note-dialog,
.recurrence-delete-dialog {
  width: min(560px, calc(100% - 30px));
}

.note-context {
  margin: 0;
  padding: 10px 12px;
  color: var(--teal-dark);
  background: rgba(52, 126, 138, 0.08);
  border-radius: 10px;
  font-size: 12px;
  font-weight: 700;
}

.note-writing-guide {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
}

.note-writing-guide article {
  padding: 13px;
  background: var(--paper);
  border-radius: 12px;
}

.note-writing-guide strong,
.note-writing-guide span {
  display: block;
}

.note-writing-guide strong {
  margin-bottom: 5px;
  color: var(--teal-dark);
  font-size: 12px;
}

.note-writing-guide span {
  color: var(--muted);
  font-size: 11px;
  font-weight: 300;
  line-height: 1.6;
}

.form-hint,
.delete-description {
  margin: 0;
  color: var(--muted);
  font-size: 12px;
  font-weight: 300;
  line-height: 1.65;
}

.delete-scope-options {
  display: grid;
  gap: 10px;
}

.delete-scope-option {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  align-items: start;
  gap: 12px;
  padding: 15px;
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: 14px;
  cursor: pointer;
}

.delete-scope-option:has(input:checked) {
  background: var(--yellow-light);
  border-color: var(--yellow);
}

.delete-scope-option input {
  width: 18px;
  min-height: 18px;
  margin: 2px 0 0;
}

.delete-scope-option strong,
.delete-scope-option small {
  display: block;
}

.delete-scope-option small {
  margin-top: 5px;
  color: var(--muted);
  font-size: 11px;
  font-weight: 300;
  line-height: 1.5;
}

footer {
  padding: 28px 0 90px;
  color: var(--muted);
  font-size: 11px;
  font-weight: 300;
  text-align: center;
}

.toast {
  position: fixed;
  z-index: 30;
  right: 24px;
  bottom: 24px;
  padding: 13px 18px;
  color: #fff;
  background: var(--teal);
  border-radius: 999px;
  opacity: 0;
  pointer-events: none;
  transform: translateY(12px);
  transition: 200ms ease;
}

.toast.show {
  opacity: 1;
  transform: translateY(0);
}

.mobile-nav {
  display: none;
}

.hidden {
  display: none !important;
}

@media (max-width: 980px) {
  .focus-panel {
    grid-template-columns: 1fr auto;
  }

  .focus-actions {
    grid-column: 1 / -1;
  }

  .stats-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .schedule-table-head {
    display: none;
  }

  .schedule-row {
    grid-template-columns: 90px 1fr 1.5fr;
  }

  .schedule-status {
    grid-column: 2;
  }

  .schedule-actions {
    grid-column: 3;
  }

  .settings-grid {
    grid-template-columns: 1fr;
  }

  .strategy-fields,
  .revenue-target-card {
    grid-template-columns: 1fr 1fr;
  }

  .strategy-fields > div,
  .revenue-target-result {
    grid-column: 1 / -1;
  }

  .export-panel {
    align-items: stretch;
    grid-template-columns: 1fr;
  }

  .export-actions {
    width: 100%;
    grid-template-columns: auto minmax(0, 1fr) auto;
  }

  .export-date-range {
    min-width: 0;
  }

  .export-date-range label,
  .export-date-range input {
    min-width: 0;
    width: 100%;
  }
}

@media (max-width: 820px) {
  .export-actions {
    grid-template-columns: 1fr;
    align-items: stretch;
  }

  .export-presets {
    display: grid;
    grid-template-columns: 1fr 1fr;
  }

  .export-actions .primary-button {
    width: 100%;
  }

  .export-actions small {
    grid-column: auto;
    max-width: none;
    justify-self: stretch;
    text-align: left;
  }
}

@media (max-width: 680px) {
  .app-shell {
    width: calc(100% - 24px);
  }

  .topbar {
    min-height: 70px;
  }

  .top-actions {
    display: none;
  }

  .brand-logo {
    width: 54px;
  }

  .hero {
    grid-template-columns: 1fr;
    gap: 22px;
    padding: 40px 0 28px;
  }

  h1 {
    font-size: 40px;
  }

  .date-switcher {
    justify-self: stretch;
    justify-content: space-between;
  }

  .focus-panel {
    grid-template-columns: 1fr;
    gap: 22px;
    padding: 22px;
  }

  .focus-clock {
    min-width: auto;
    text-align: left;
  }

  .focus-clock strong {
    font-size: 34px;
  }

  .focus-actions {
    display: grid;
    grid-template-columns: 1fr;
  }

  .focus-actions button {
    width: 100%;
  }

  .stats-grid {
    gap: 8px;
  }

  .stat-card {
    min-height: 140px;
    padding: 17px;
  }

  .stat-card > span {
    margin-bottom: 18px;
  }

  .stat-card strong {
    font-size: 20px;
  }

  .panel {
    padding: 20px;
    border-radius: 20px;
  }

  .schedule-heading {
    align-items: stretch;
    flex-direction: column;
  }

  .heading-actions {
    display: grid;
    grid-template-columns: 1fr 1fr;
  }

  .schedule-row {
    grid-template-columns: 92px 1fr;
    gap: 12px;
    padding: 15px;
  }

  .schedule-work,
  .schedule-status,
  .schedule-actions {
    grid-column: 2;
  }

  .schedule-actions {
    justify-content: flex-start;
  }

  .review-grid {
    grid-template-columns: 1fr;
  }

  .quadrant-chart {
    grid-template-columns: 1fr 1fr;
  }

  .quadrant-cell {
    min-height: 112px;
    padding: 13px;
  }

  .quadrant-cell strong {
    font-size: 23px;
  }

  .time-block-heading {
    display: grid;
  }

  .time-block-heading button {
    width: 100%;
  }

  .time-track {
    height: 126px;
  }

  .strategy-fields,
  .life-budget-grid,
  .business-finance-grid,
  .revenue-target-card,
  .freedom-projection-list,
  .finance-ledger-entry {
    grid-template-columns: 1fr;
  }

  .strategy-fields > div,
  .revenue-target-result,
  .finance-ledger-entry label:last-child {
    grid-column: auto;
  }

  .budget-fields {
    grid-template-columns: 1fr;
  }

  .star-rating-row {
    grid-template-columns: 1fr;
  }

  .star-rating {
    justify-content: space-between;
  }

  .result-item {
    padding: 15px;
  }

  .result-heading,
  .result-review-grid {
    grid-template-columns: 1fr;
  }

  .result-heading {
    gap: 9px;
  }

  .result-heading .outcome {
    justify-self: start;
  }

  .export-panel {
    align-items: stretch;
    grid-template-columns: 1fr;
    padding: 22px;
  }

  .export-actions {
    width: 100%;
    grid-template-columns: 1fr;
    align-items: stretch;
  }

  .export-presets {
    display: grid;
    grid-template-columns: 1fr 1fr;
  }

  .export-date-range {
    grid-template-columns: 1fr;
    min-width: 0;
  }

  .export-date-range > span {
    display: none;
  }

  .export-actions small {
    grid-column: auto;
    max-width: none;
    justify-self: stretch;
    text-align: left;
  }

  .export-panel button {
    width: 100%;
  }

  .app-dialog {
    width: calc(100% - 18px);
    max-height: calc(100vh - 18px);
    border-radius: 20px;
  }

  .dialog-header,
  .dialog-actions,
  .dialog-body {
    padding: 19px;
  }

  .dialog-actions {
    display: grid;
    grid-template-columns: 1fr;
  }

  .dialog-actions button {
    width: 100%;
  }

  .field-grid.two,
  .field-grid.three,
  .completion-summary,
  .actual-clock-inputs {
    grid-template-columns: 1fr;
  }

  .planned-duration {
    grid-template-columns: 1fr;
  }

  .recurrence-panel {
    grid-template-columns: 1fr;
  }

  .recurrence-panel p {
    grid-column: auto;
  }

  .setting-item {
    grid-template-columns: auto minmax(0, 1fr);
  }

  .setting-item .setting-actions {
    grid-column: 2;
    justify-content: flex-start;
  }

  .duration-inputs {
    display: grid;
    grid-template-columns: 1fr 1fr;
  }

  .duration-inputs input {
    width: 100%;
  }

  .actual-time-inputs {
    grid-template-columns: 1fr 1fr;
  }

  .note-writing-guide {
    grid-template-columns: 1fr;
  }

  input,
  select {
    min-height: 52px;
    font-size: 16px;
  }

  textarea {
    font-size: 16px;
  }

  .mobile-nav {
    position: fixed;
    z-index: 20;
    right: 12px;
    bottom: calc(10px + env(safe-area-inset-bottom, 0px));
    left: 12px;
    display: flex;
    gap: 4px;
    overflow-x: auto;
    overscroll-behavior-x: contain;
    padding: 7px;
    background: rgba(79, 74, 66, 0.97);
    border-radius: 18px;
    box-shadow: 0 16px 40px rgba(79, 74, 66, 0.28);
    scrollbar-width: none;
    scroll-snap-type: x proximity;
    touch-action: pan-x;
  }

  .mobile-nav::-webkit-scrollbar {
    display: none;
  }

  .mobile-nav a,
  .mobile-nav button {
    display: grid;
    gap: 3px;
    place-items: center;
    flex: 0 0 72px;
    min-height: 48px;
    color: rgba(255, 255, 255, 0.76);
    background: transparent;
    border: 0;
    border-radius: 12px;
    font-size: 10px;
    text-decoration: none;
    scroll-snap-align: start;
  }

  .mobile-nav .mobile-account,
  .mobile-nav [data-open-settings] {
    color: rgba(255, 255, 255, 0.76);
    background: transparent;
  }

  .mobile-nav [data-open-schedule] {
    color: var(--ink);
    background: var(--yellow);
    font-weight: 800;
  }

  .mobile-nav span {
    font-size: 18px;
  }

  .toast {
    right: 18px;
    bottom: 82px;
  }
}

@media print {
  @page {
    size: A4;
    margin: 13mm;
  }

  body {
    color: #332f2a;
    background: #fff;
    print-color-adjust: exact;
    -webkit-print-color-adjust: exact;
  }

  body > .app-shell,
  body > .toast,
  body > dialog,
  body > .mobile-nav {
    display: none !important;
  }

  .print-report {
    display: block;
    font-family: var(--font);
  }

  .print-overview-page,
  .print-day-page {
    min-height: 265mm;
  }

  .print-day-page {
    break-before: page;
    page-break-before: always;
  }

  .print-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
    padding-bottom: 16px;
    border-bottom: 3px solid var(--teal);
  }

  .print-brand {
    display: flex;
    align-items: center;
    gap: 10px;
  }

  .print-brand img {
    width: 54px;
    height: 38px;
    object-fit: contain;
  }

  .print-brand strong,
  .print-brand span,
  .print-date span,
  .print-date strong {
    display: block;
  }

  .print-brand strong {
    font-size: 15px;
  }

  .print-brand span,
  .print-date span {
    color: #746d64;
    font-size: 9px;
  }

  .print-date {
    text-align: right;
  }

  .print-date strong {
    margin-top: 4px;
    font-size: 13px;
  }

  .print-summary {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 8px;
    margin: 16px 0;
  }

  .print-summary div {
    padding: 11px;
    background: var(--yellow-light);
    border-radius: 8px;
  }

  .print-summary span,
  .print-summary strong {
    display: block;
  }

  .print-summary span {
    margin-bottom: 5px;
    color: #746d64;
    font-size: 8px;
  }

  .print-summary strong {
    font-size: 11px;
  }

  .print-quadrant-section {
    margin: 16px 0;
    break-inside: avoid;
  }

  .print-quadrant-section h2 {
    margin-bottom: 8px;
    color: var(--teal-dark);
    font-size: 14px;
  }

  .print-quadrant-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 7px;
  }

  .print-quadrant-grid article {
    display: grid;
    grid-template-columns: 1fr auto auto;
    align-items: center;
    gap: 8px;
    padding: 9px 11px;
    border-radius: 7px;
  }

  .print-quadrant-grid article.core {
    background: #e2f1e2;
  }

  .print-quadrant-grid article.cash {
    background: var(--yellow-light);
  }

  .print-quadrant-grid article.growth {
    background: var(--teal-light);
  }

  .print-quadrant-grid article.drain {
    background: #f4e3df;
  }

  .print-quadrant-grid span,
  .print-quadrant-grid strong,
  .print-quadrant-grid small {
    font-size: 8px;
  }

  .print-quadrant-grid strong {
    font-size: 10px;
  }

  .print-report-title {
    padding: 36px 0 24px;
    text-align: center;
  }

  .print-report-title span {
    color: var(--teal-dark);
    font-size: 8px;
    font-weight: 800;
    letter-spacing: 0.18em;
  }

  .print-report-title h1 {
    margin: 8px 0;
    font-size: 25px;
  }

  .print-report-title p {
    margin: 0;
    color: #746d64;
    font-size: 10px;
  }

  .print-insights,
  .print-project-summary {
    margin-top: 22px;
  }

  .print-insights h2,
  .print-project-summary h2 {
    margin-bottom: 9px;
    color: var(--teal-dark);
    font-size: 15px;
  }

  .print-insight-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 8px;
  }

  .print-insight-grid article {
    padding: 13px;
    background: #f7f2e9;
    border-left: 4px solid var(--yellow);
  }

  .print-insight-grid span,
  .print-insight-grid strong {
    display: block;
  }

  .print-insight-grid span {
    color: #746d64;
    font-size: 8px;
  }

  .print-insight-grid strong {
    margin: 5px 0;
    font-size: 12px;
  }

  .print-insight-grid p {
    margin: 0;
    color: #746d64;
    font-size: 8px;
  }

  .print-project-summary {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 7px;
  }

  .print-project-summary h2 {
    grid-column: 1 / -1;
  }

  .print-project-summary div {
    display: flex;
    justify-content: space-between;
    gap: 12px;
    padding: 9px 11px;
    background: var(--teal-light);
    border-radius: 7px;
    font-size: 9px;
  }

  .print-section {
    margin-top: 18px;
    break-inside: avoid;
  }

  .print-section h2 {
    margin-bottom: 9px;
    color: var(--teal-dark);
    font-size: 15px;
  }

  .print-section table {
    width: 100%;
    border-collapse: collapse;
    font-size: 8px;
  }

  .print-section th,
  .print-section td {
    padding: 7px;
    border: 1px solid #ddd4c8;
    text-align: left;
    vertical-align: top;
    line-height: 1.5;
  }

  .print-section th {
    background: var(--teal-light);
  }

  .print-results {
    display: grid;
    gap: 7px;
  }

  .print-results article {
    padding: 10px;
    background: var(--yellow-light);
    border-radius: 8px;
    break-inside: avoid;
  }

  .print-results span,
  .print-results strong,
  .print-results small {
    display: block;
  }

  .print-results span,
  .print-results small {
    color: #746d64;
    font-size: 8px;
  }

  .print-results strong {
    margin: 4px 0;
    font-size: 10px;
  }

  .print-results p,
  .print-review p {
    margin: 4px 0 0;
    font-size: 9px;
    line-height: 1.6;
    white-space: pre-wrap;
  }

  .print-results dl {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 6px;
    margin: 8px 0 0;
  }

  .print-results dl div {
    padding: 6px;
    background: #fff;
    border-radius: 5px;
  }

  .print-results dt {
    color: #746d64;
    font-size: 7px;
    font-weight: 800;
  }

  .print-results dd {
    margin: 3px 0 0;
    font-size: 8px;
    line-height: 1.5;
    white-space: pre-wrap;
  }

  .print-review {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 8px;
  }

  .print-review h2 {
    grid-column: 1 / -1;
  }

  .print-review div {
    padding: 11px;
    background: #f7f2e9;
    border-left: 4px solid var(--yellow);
  }

  .print-review span {
    color: #746d64;
    font-size: 8px;
    font-weight: 800;
  }

  .print-rest-list {
    display: grid;
    gap: 7px;
  }

  .print-rest-list article {
    padding: 10px;
    background: #eee3d7;
    border-left: 4px solid var(--latte);
    break-inside: avoid;
  }

  .print-rest-list span,
  .print-rest-list strong {
    display: block;
  }

  .print-rest-list span {
    color: #746d64;
    font-size: 8px;
  }

  .print-rest-list strong {
    margin-top: 4px;
    font-size: 10px;
  }

  .print-rest-list dl {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 6px;
    margin: 8px 0;
  }

  .print-rest-list dl div {
    padding: 6px;
    background: rgba(255, 255, 255, 0.7);
  }

  .print-rest-list dt {
    color: #746d64;
    font-size: 7px;
  }

  .print-rest-list dd,
  .print-rest-list p {
    margin: 3px 0 0;
    font-size: 8px;
    line-height: 1.5;
  }

  .print-empty {
    padding: 10px;
    color: #746d64;
    background: #f7f2e9;
    font-size: 9px;
  }

  .print-footer {
    margin-top: 22px;
    padding-top: 9px;
    color: #746d64;
    border-top: 1px solid #ddd4c8;
    font-size: 8px;
    text-align: center;
  }
}
