/* v1.1: more visible fine-paper texture for recorded-color cards */
:root {
  --page-bg: #ece9e2;
  --page-text: #292b2a;
  --page-muted: #6f726f;
  --page-panel: rgba(255, 255, 255, 0.72);

  --bg-top: #f7f1de;
  --bg-bottom: #f3e4c5;
  --text: #3e3a2f;
  --text-muted: #756d59;
  --accent: #9e7139;
  --surface: rgba(255, 252, 243, 0.92);
  --surface-solid: #f8edd5;
  --border: rgba(72, 64, 48, 0.16);
  --shadow-color: rgba(97, 76, 37, 0.14);

  --category-work-base: #71809a;
  --category-life-base: #718f7d;
  --category-people-base: #b47c63;
  --category-self-base: #8b7897;
  --intensity-accent: 94%;
  --intensity-ink: 72%;
  --intensity-wash: 22%;
  --intensity-marker: 66%;
  --row-surface: rgba(255, 252, 243, 0.70);
  --fine-paper-opacity: 0.18;
  --fine-paper-texture: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='96' height='96' viewBox='0 0 96 96'%3E%3Cfilter id='paper'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.78' numOctaves='3' seed='19' stitchTiles='stitch'/%3E%3CfeColorMatrix type='saturate' values='0'/%3E%3C/filter%3E%3Crect width='96' height='96' filter='url(%23paper)' opacity='.72'/%3E%3C/svg%3E");

  --card-radius: 18px;
  --card-padding: 13px;
  --section-gap: 11px;
  --date-size: 32px;
  --heading-size: 21px;
  --body-size: 15px;
  --time-size: 12px;
  --panel-height: 90%;
  --shadow: 0 12px 30px var(--shadow-color);
  --font-body: -apple-system, BlinkMacSystemFont, "Hiragino Sans", "Yu Gothic", sans-serif;
  --font-heading: var(--font-body);
}

* {
  box-sizing: border-box;
}

html {
  min-width: 320px;
  background: var(--page-bg);
  color: var(--page-text);
  font-family: var(--font-body);
}

body {
  margin: 0;
  min-height: 100vh;
  background:
    radial-gradient(circle at 12% 8%, rgba(255, 255, 255, 0.92), transparent 30rem),
    linear-gradient(145deg, #f4f1ea, #dedbd4);
}

button,
select,
input {
  font: inherit;
}

button,
select {
  -webkit-tap-highlight-color: transparent;
}

button:focus-visible,
select:focus-visible {
  outline: 3px solid color-mix(in srgb, var(--accent), white 30%);
  outline-offset: 2px;
}

.workbench {
  display: grid;
  grid-template-columns: minmax(390px, 480px) minmax(280px, 360px);
  justify-content: center;
  gap: 42px;
  width: min(100%, 1060px);
  margin: 0 auto;
  padding: 38px 24px 52px;
}

.preview-column {
  min-width: 0;
}

.preview-heading {
  width: min(100%, 430px);
  margin: 0 auto 20px;
}

.eyebrow {
  margin: 0 0 6px;
  color: #7a776f;
  font-size: 10px;
  font-weight: 750;
  letter-spacing: 0.16em;
}

.preview-heading h1,
.controls h2 {
  margin: 0;
  font-size: 20px;
  letter-spacing: 0.02em;
}

.preview-heading > p:last-child,
.controls-header > p:last-child {
  margin: 7px 0 0;
  color: var(--page-muted);
  font-size: 12px;
  line-height: 1.65;
}

.device {
  position: relative;
  width: min(100%, 430px);
  height: min(860px, calc(100vh - 70px));
  min-height: 720px;
  margin: 0 auto;
  padding: 9px;
  overflow: hidden;
  border: 1px solid rgba(32, 34, 33, 0.35);
  border-radius: 48px;
  background: #111311;
  box-shadow: 0 28px 70px rgba(22, 25, 23, 0.28);
}

.device-speaker {
  position: absolute;
  z-index: 40;
  top: 18px;
  left: 50%;
  width: 74px;
  height: 19px;
  transform: translateX(-50%);
  border-radius: 20px;
  background: #080908;
}

.app {
  --category-work-accent: color-mix(in srgb, var(--category-work-base) var(--intensity-accent), var(--text));
  --category-life-accent: color-mix(in srgb, var(--category-life-base) var(--intensity-accent), var(--text));
  --category-people-accent: color-mix(in srgb, var(--category-people-base) var(--intensity-accent), var(--text));
  --category-self-accent: color-mix(in srgb, var(--category-self-base) var(--intensity-accent), var(--text));
  --category-work-ink: color-mix(in srgb, var(--category-work-base) var(--intensity-ink), var(--text));
  --category-life-ink: color-mix(in srgb, var(--category-life-base) var(--intensity-ink), var(--text));
  --category-people-ink: color-mix(in srgb, var(--category-people-base) var(--intensity-ink), var(--text));
  --category-self-ink: color-mix(in srgb, var(--category-self-base) var(--intensity-ink), var(--text));
  --category-work-wash: color-mix(in srgb, var(--category-work-base) var(--intensity-wash), var(--surface-solid));
  --category-life-wash: color-mix(in srgb, var(--category-life-base) var(--intensity-wash), var(--surface-solid));
  --category-people-wash: color-mix(in srgb, var(--category-people-base) var(--intensity-wash), var(--surface-solid));
  --category-self-wash: color-mix(in srgb, var(--category-self-base) var(--intensity-wash), var(--surface-solid));
  --category-work-marker: color-mix(in srgb, var(--category-work-base) var(--intensity-marker), var(--surface-solid));
  --category-life-marker: color-mix(in srgb, var(--category-life-base) var(--intensity-marker), var(--surface-solid));
  --category-people-marker: color-mix(in srgb, var(--category-people-base) var(--intensity-marker), var(--surface-solid));
  --category-self-marker: color-mix(in srgb, var(--category-self-base) var(--intensity-marker), var(--surface-solid));
  --note-accent: color-mix(in srgb, #a890c8 54%, var(--text-muted));
  --note-ink: color-mix(in srgb, #88769f 38%, var(--text));
  --note-wash: color-mix(in srgb, #b9a8d7 12%, var(--surface-solid));
  --note-marker: color-mix(in srgb, #b9a8d7 58%, var(--surface-solid));
  position: relative;
  width: 100%;
  height: 100%;
  overflow: hidden;
  border-radius: 39px;
  background: linear-gradient(145deg, var(--bg-top), var(--bg-bottom));
  color: var(--text);
  font-family: var(--font-body);
  transition: background 220ms ease-out, color 220ms ease-out;
}

.app[data-time="night"] {
  --bg-top: #0c121a;
  --bg-bottom: #151e28;
  --text: #e3e4e1;
  --text-muted: #a5adb0;
  --accent: #aaa17f;
  --surface: rgba(18, 27, 36, 0.96);
  --surface-solid: #121c26;
  --row-surface: rgba(18, 27, 36, 0.76);
  --border: rgba(230, 232, 228, 0.14);
  --shadow-color: rgba(0, 0, 0, 0.42);
  --fine-paper-opacity: 0.12;
}

.app[data-palette="pop"],
.controls:has(#palette-control option[value="pop"]:checked) {
  --category-work-base: hsl(195 88% 62%);
  --category-life-base: hsl(156 67% 56%);
  --category-people-base: hsl(27 94% 62%);
  --category-self-base: hsl(334 88% 68%);
}

.app[data-palette="pop-charcoal"],
.controls:has(#palette-control option[value="pop-charcoal"]:checked) {
  --category-work-base: hsl(220 9% 34%);
  --category-life-base: hsl(156 67% 56%);
  --category-people-base: hsl(27 94% 62%);
  --category-self-base: hsl(334 88% 68%);
}

.app[data-intensity="soft"] {
  --intensity-accent: 78%;
  --intensity-ink: 58%;
  --intensity-wash: 10%;
  --intensity-marker: 48%;
}

.app[data-intensity="colorful"] {
  --intensity-accent: 94%;
  --intensity-ink: 72%;
  --intensity-wash: 22%;
  --intensity-marker: 66%;
}

.app[data-intensity="vivid"] {
  --intensity-accent: 100%;
  --intensity-ink: 82%;
  --intensity-wash: 32%;
  --intensity-marker: 82%;
}

.app[data-font="avenir"] {
  --font-body: "Avenir Next", "Hiragino Sans", "Yu Gothic", sans-serif;
  --font-heading: "Avenir Next", "Hiragino Sans", "Yu Gothic", sans-serif;
}

.app[data-font="helvetica"] {
  --font-body: "Helvetica Neue", "Hiragino Sans", "Yu Gothic", sans-serif;
  --font-heading: "Helvetica Neue", "Hiragino Sans", "Yu Gothic", sans-serif;
}

.app[data-font="futura"] {
  --font-body: -apple-system, BlinkMacSystemFont, "Hiragino Sans", "Yu Gothic", sans-serif;
  --font-heading: Futura, "Avenir Next", "Hiragino Sans", "Yu Gothic", sans-serif;
}

.app[data-title-style="handwritten"] .row-title {
  font-family: Klee, "HanziPen SC", YuKyokasho, "Hiragino Mincho ProN", serif;
  font-weight: 540;
  letter-spacing: 0.025em;
}

.app[data-title-style="category"] .category-work .row-title {
  font-family: "Avenir Next", "Hiragino Sans", "Yu Gothic", sans-serif;
  letter-spacing: 0.015em;
}

.app[data-title-style="category"] .category-life .row-title {
  font-family: "Hiragino Maru Gothic ProN", "Hiragino Sans", "Yu Gothic", sans-serif;
  letter-spacing: 0.02em;
}

.app[data-title-style="category"] .category-people .row-title {
  font-family: YuKyokasho, "Hiragino Mincho ProN", serif;
  letter-spacing: 0.025em;
}

.app[data-title-style="category"] .category-self .row-title,
.app[data-title-style="category"] .note-row .row-title {
  font-family: Klee, "HanziPen SC", YuKyokasho, serif;
  letter-spacing: 0.025em;
}

.atmosphere,
.atmosphere::before,
.atmosphere::after {
  position: absolute;
  inset: 0;
  pointer-events: none;
}

.atmosphere {
  overflow: hidden;
  opacity: 0.78;
}

.atmosphere::before {
  content: "";
  top: 23%;
  left: -16%;
  width: 132%;
  height: 13%;
  transform: rotate(-4deg);
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.15);
  filter: blur(30px);
}

.atmosphere::after {
  content: "";
  top: 49%;
  left: -10%;
  width: 124%;
  height: 10%;
  transform: rotate(3deg);
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.09);
  filter: blur(26px);
}

.haze {
  position: absolute;
  display: block;
  border-radius: 50%;
  filter: blur(55px);
}

.haze-one {
  top: -10%;
  left: -24%;
  width: 84%;
  aspect-ratio: 1;
  background: rgba(255, 255, 255, 0.52);
}

.haze-two {
  top: 21%;
  right: -28%;
  width: 92%;
  aspect-ratio: 1.4;
  background: rgba(231, 214, 171, 0.28);
}

.haze-three {
  right: -15%;
  bottom: -8%;
  width: 74%;
  aspect-ratio: 1;
  background: rgba(255, 255, 255, 0.18);
}

.app[data-time="night"] .atmosphere {
  opacity: 0.48;
}

.app[data-time="night"] .haze-one {
  background: rgba(97, 117, 133, 0.22);
}

.app[data-time="night"] .haze-two {
  background: rgba(54, 67, 84, 0.22);
}

.app-header {
  position: relative;
  z-index: 2;
  padding: max(28px, env(safe-area-inset-top)) 16px 0;
}

.settings-action {
  position: absolute;
  z-index: 4;
  top: max(28px, env(safe-area-inset-top));
  right: 12px;
}

.brand-line {
  display: grid;
  justify-items: center;
  gap: 3px;
  margin-top: 5px;
}

.brand-name {
  color: var(--text-muted);
  font-family: var(--font-heading);
  font-size: 9px;
  font-weight: 700;
  letter-spacing: 0.24em;
}

.brand-copy {
  margin: 0;
  font-family: var(--font-heading);
  font-size: 17px;
  font-weight: 660;
  letter-spacing: 0.04em;
}

.time-hub {
  display: grid;
  grid-template-columns: 1fr 138px 1fr;
  align-items: center;
  min-height: 160px;
  margin-top: 2px;
}

.selected-date {
  display: grid;
  align-self: stretch;
  justify-items: start;
  align-content: start;
  padding: 20px 0 0 1px;
}

.date-year {
  color: var(--text-muted);
  font-family: var(--font-heading);
  font-size: 16px;
  font-variant-numeric: tabular-nums;
  font-weight: 650;
  letter-spacing: 0.01em;
}

.date-weekday,
.today-return {
  color: var(--text-muted);
  font-size: 10px;
  font-weight: 620;
  letter-spacing: 0.04em;
}

.date-calendar {
  margin: 1px 0 2px;
  font-family: var(--font-heading);
  font-size: var(--date-size);
  font-variant-numeric: tabular-nums;
  font-weight: 600;
  line-height: 1;
  letter-spacing: -0.045em;
}

.today-return {
  min-height: 44px;
  margin: 5px 0 0 -6px;
  padding: 3px 6px;
  border: 0;
  background: transparent;
  color: var(--text-muted);
  cursor: pointer;
  text-decoration: underline;
  text-decoration-color: color-mix(in srgb, currentColor, transparent 58%);
  text-underline-offset: 3px;
}

.today-return:hover,
.today-return:active {
  color: var(--text);
}

.today-return[hidden] {
  display: none;
}

.celestial {
  position: relative;
  display: grid;
  width: 138px;
  height: 138px;
  place-items: center;
  border: 0;
  border-radius: 50%;
  background: transparent;
  color: inherit;
  cursor: pointer;
}

.celestial::before,
.celestial::after {
  position: absolute;
  content: "";
  border-radius: 50%;
  pointer-events: none;
}

.celestial::before {
  width: 128px;
  height: 128px;
  background: rgba(247, 216, 111, 0.22);
  filter: blur(17px);
}

.celestial::after {
  width: 112px;
  height: 112px;
  background: rgba(255, 246, 201, 0.34);
  filter: blur(9px);
}

.sun,
.moon {
  position: absolute;
  z-index: 1;
  width: 98px;
  height: 98px;
  border-radius: 50%;
}

.sun {
  background: radial-gradient(circle at 43% 38%, #fdf4c9 0, #f9e7a6 42%, #efd36c 100%);
  box-shadow: 0 0 24px rgba(240, 204, 95, 0.34);
}

.moon {
  display: none;
  background: radial-gradient(circle at 36% 30%, #ddd9cb 0, #c8c3b3 62%, #85857e 100%);
  box-shadow: 0 0 14px rgba(204, 201, 183, 0.14);
}

.moon::after {
  position: absolute;
  top: -4px;
  left: -25px;
  width: 98px;
  height: 98px;
  border-radius: 50%;
  background: #111923;
  content: "";
  opacity: 0.97;
}

.app[data-time="night"] .celestial::before {
  width: 115px;
  height: 115px;
  background: rgba(181, 181, 165, 0.10);
  filter: blur(14px);
}

.app[data-time="night"] .celestial::after {
  background: rgba(197, 196, 179, 0.08);
}

.app[data-time="night"] .sun {
  display: none;
}

.app[data-time="night"] .moon {
  display: block;
}

.clock-hands {
  position: absolute;
  z-index: 3;
  inset: 0;
  opacity: 1;
  transition: opacity 180ms ease-out;
}

.celestial[data-clock="0"] .clock-hands {
  opacity: 0;
}

.clock-hand {
  position: absolute;
  bottom: 50%;
  left: 50%;
  display: block;
  width: 3px;
  border-radius: 99px;
  background: #3d392f;
  opacity: 0.78;
  transform-origin: 50% 100%;
}

.clock-hand.hour {
  height: 27px;
  transform: translateX(-50%) rotate(53deg);
}

.clock-hand.minute {
  height: 39px;
  width: 2px;
  transform: translateX(-50%) rotate(28deg);
}

.clock-hand.second {
  display: none;
  height: 42px;
  width: 1px;
  background: #9c5f55;
  transform: translateX(-50%) rotate(178deg);
}

.celestial[data-clock="2"] .clock-hand.second {
  display: block;
}

.clock-pin {
  position: absolute;
  top: 50%;
  left: 50%;
  width: 7px;
  height: 7px;
  transform: translate(-50%, -50%);
  border-radius: 50%;
  background: #423c31;
}

.app[data-time="night"] .clock-hand,
.app[data-time="night"] .clock-pin {
  background: #58c9c3;
}

.top-actions {
  display: flex;
  align-items: center;
  justify-self: end;
  flex-direction: column;
  gap: 8px;
}

.close-button {
  display: grid;
  place-items: center;
  border: 1px solid var(--border);
  border-radius: 50%;
  background: color-mix(in srgb, var(--surface-solid), transparent 8%);
  color: var(--text);
  cursor: pointer;
}

.icon-button {
  display: grid;
  width: 44px;
  height: 44px;
  place-items: center;
  border: 1px solid transparent;
  border-radius: 50%;
  background: transparent;
  color: var(--text-muted);
  cursor: pointer;
  transition: background 140ms ease-out, color 140ms ease-out;
}

.icon-button:hover,
.icon-button:active {
  background: color-mix(in srgb, var(--surface-solid), transparent 78%);
  color: var(--text);
}

.icon-button svg {
  width: 18px;
  height: 18px;
  overflow: visible;
  fill: none;
  stroke: currentColor;
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-width: 1.7;
}

.week-navigation {
  display: grid;
  grid-template-columns: 44px minmax(0, 1fr) 44px;
  align-items: center;
  margin-top: -2px;
}

.week-strip {
  display: grid;
  min-width: 0;
  grid-template-columns: repeat(7, minmax(0, 1fr));
  gap: 1px;
}

.week-step {
  display: grid;
  width: 44px;
  height: 49px;
  place-items: center;
  padding: 0;
  border: 0;
  border-radius: 12px;
  background: transparent;
  color: color-mix(in srgb, var(--text-muted), transparent 18%);
  cursor: pointer;
}

.week-step:hover,
.week-step:active {
  background: color-mix(in srgb, var(--surface-solid), transparent 80%);
  color: var(--text);
}

.week-step svg {
  width: 18px;
  height: 18px;
  fill: none;
  stroke: currentColor;
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-width: 1.7;
}

.day {
  position: relative;
  display: grid;
  min-width: 0;
  min-height: 49px;
  place-content: center;
  gap: 2px;
  border: 1px solid transparent;
  border-radius: 13px;
  background: transparent;
  color: var(--text);
  cursor: pointer;
}

.day span {
  color: var(--text-muted);
  font-size: 9px;
  font-weight: 650;
}

.day strong {
  font-size: 15px;
  font-variant-numeric: tabular-nums;
  font-weight: 570;
}

.day i {
  position: absolute;
  right: 50%;
  bottom: 4px;
  width: 4px;
  height: 4px;
  transform: translateX(50%);
  border-radius: 50%;
  background: var(--accent);
}

.day.is-selected {
  border-color: color-mix(in srgb, var(--accent), transparent 18%);
  background: color-mix(in srgb, var(--accent), transparent 89%);
}

.day.saturday strong,
.day.saturday span {
  color: #557dae;
}

.day.holiday strong,
.day.holiday span {
  color: #b65f67;
}

.main-content {
  position: relative;
  z-index: 2;
  height: calc(100% - 310px);
  padding: 12px 16px 102px;
  overflow: auto;
  overscroll-behavior: contain;
  scrollbar-width: none;
}

.main-content::-webkit-scrollbar,
.sheet-body::-webkit-scrollbar,
.review-scroll::-webkit-scrollbar {
  display: none;
}

.section {
  display: flex;
  min-height: 100%;
  flex-direction: column;
  gap: var(--section-gap);
}

.section-header,
.review-section-heading {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 12px;
}

.section-title-wrap {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 7px;
}

.section h2,
.review-panel h2,
.placeholder-panel h2 {
  margin: 0;
  font-family: var(--font-heading);
  font-size: var(--heading-size);
  font-weight: 680;
  letter-spacing: 0.015em;
}

.count-label,
.section-date-note {
  color: var(--text-muted);
  font-size: 11px;
  font-weight: 620;
}

.input-actions {
  display: flex;
  gap: 5px;
}

.input-actions button {
  display: grid;
  width: 34px;
  height: 34px;
  place-items: center;
  border: 1px solid var(--border);
  border-radius: 50%;
  background: color-mix(in srgb, var(--surface-solid), transparent 5%);
  color: var(--text);
  cursor: pointer;
  font-size: 15px;
}

.entry-list {
  display: grid;
  gap: 2px;
}

.entry-row {
  --category-accent: var(--category-work-accent);
  --category-ink: var(--category-work-ink);
  --category-wash: var(--category-work-wash);
  --category-marker: var(--category-work-marker);
  --row-accent: var(--category-accent);
  --row-ink: var(--category-ink);
  --row-wash: var(--category-wash);
  --row-marker: color-mix(in srgb, var(--category-marker) 56%, transparent);
  --separator-inset: 58px;
  position: relative;
  display: grid;
  grid-template-columns: 58px minmax(0, 1fr) auto;
  align-items: center;
  min-height: 44px;
  overflow: hidden;
  border: 1px solid transparent;
  border-radius: 0;
  background: transparent;
  box-shadow: none;
  cursor: pointer;
}

.category-work {
  --category-accent: var(--category-work-accent);
  --category-ink: var(--category-work-ink);
  --category-wash: var(--category-work-wash);
  --category-marker: var(--category-work-marker);
}

.category-life {
  --category-accent: var(--category-life-accent);
  --category-ink: var(--category-life-ink);
  --category-wash: var(--category-life-wash);
  --category-marker: var(--category-life-marker);
}

.category-people {
  --category-accent: var(--category-people-accent);
  --category-ink: var(--category-people-ink);
  --category-wash: var(--category-people-wash);
  --category-marker: var(--category-people-marker);
}

.category-self {
  --category-accent: var(--category-self-accent);
  --category-ink: var(--category-self-ink);
  --category-wash: var(--category-self-wash);
  --category-marker: var(--category-self-marker);
}

.entry-row.plan-row {
  --row-accent: color-mix(in srgb, var(--category-accent) 76%, var(--surface-solid));
  --row-ink: color-mix(in srgb, var(--category-ink) 86%, var(--text));
  --row-wash: color-mix(in srgb, var(--category-wash) 72%, var(--surface-solid));
  --row-marker: color-mix(in srgb, var(--category-marker) 36%, transparent);
}

.entry-row.done-row {
  --row-marker: color-mix(in srgb, var(--category-marker) 56%, transparent);
  --separator-inset: 52px;
  grid-template-areas: "time emoji copy";
  grid-template-columns: 52px 30px minmax(0, 1fr);
  column-gap: 6px;
}

.entry-row.note-row {
  --row-accent: var(--note-accent);
  --row-ink: var(--note-ink);
  --row-wash: var(--note-wash);
  --row-marker: color-mix(in srgb, var(--note-marker) 50%, transparent);
  --separator-inset: 52px;
  grid-template-areas: "time emoji copy";
  grid-template-columns: 52px 30px minmax(0, 1fr);
  column-gap: 6px;
}

.app[data-timeline-time="right"] .done-row,
.app[data-timeline-time="right"] .note-row {
  --separator-inset: 40px;
  grid-template-areas: "emoji copy time";
  grid-template-columns: 34px minmax(0, 1fr) 48px;
  column-gap: 4px;
}

.app[data-treatment="band"] .entry-row:not(.note-row)::before {
  position: absolute;
  top: 50%;
  left: 8px;
  width: 3px;
  height: 22px;
  transform: translateY(-50%);
  border-radius: 99px;
  background: var(--row-accent);
  content: "";
}

.app[data-treatment="band"] .plan-row::before {
  opacity: 0.50;
}

.app[data-treatment="band"] .done-row::before {
  opacity: 0.95;
}

.app[data-treatment="dot"] .entry-row:not(.note-row)::before {
  position: absolute;
  top: 50%;
  left: 7px;
  width: 6px;
  height: 6px;
  transform: translateY(-50%);
  border-radius: 50%;
  background: var(--row-accent);
  content: "";
}

.app[data-treatment="dot"] .plan-row::before {
  opacity: 0.52;
}

.app[data-treatment="dot"] .done-row::before {
  opacity: 0.98;
}

.app[data-treatment="tint"] .entry-row:not(.note-row)::before {
  display: none;
}

.row-time {
  color: var(--text-muted);
  font-size: var(--time-size);
  font-variant-numeric: tabular-nums;
  letter-spacing: -0.01em;
}

.plan-row .row-time {
  padding-left: 16px;
  text-align: left;
}

.done-row .row-time,
.note-row .row-time {
  grid-area: time;
  padding-left: 10px;
  text-align: left;
}

.app[data-timeline-time="right"] .done-row .row-time,
.app[data-timeline-time="right"] .note-row .row-time {
  padding-right: 10px;
  padding-left: 0;
  text-align: right;
}

.row-copy {
  min-width: 0;
  padding: 6px 8px;
}

.done-row .row-copy,
.note-row .row-copy {
  grid-area: copy;
  padding-left: 2px;
}

.app[data-timeline-time="right"] .done-row .row-copy,
.app[data-timeline-time="right"] .note-row .row-copy {
  padding-right: 2px;
  padding-left: 0;
}

.row-title {
  display: block;
  overflow: hidden;
  color: var(--text);
  font-size: var(--body-size);
  font-weight: 590;
  line-height: 1.42;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.plan-row .row-title {
  color: var(--row-ink);
  font-weight: 570;
}

.done-row .row-title {
  color: var(--row-ink);
  font-weight: 640;
}

.note-row .row-title {
  color: var(--row-ink);
  font-weight: 470;
}

.app[data-title-weight="light"] .row-title {
  font-weight: 400;
  line-height: 1.36;
}

.app[data-title-weight="light"] .done-row .row-title {
  font-weight: 420;
}

.row-emoji {
  display: grid;
  grid-area: emoji;
  min-width: 34px;
  place-items: center;
  font-size: 18px;
}

.row-state {
  padding-right: 13px;
  color: var(--row-accent);
  font-size: 18px;
  font-weight: 700;
}

.app[data-emoji="off"] .row-emoji,
.app[data-emoji="off"] .review-records > p > span {
  display: none;
}

.app[data-emoji="off"] .done-row,
.app[data-emoji="off"] .note-row {
  --separator-inset: 52px;
  grid-template-areas: "time copy";
  grid-template-columns: 52px minmax(0, 1fr);
}

.app[data-emoji="off"][data-timeline-time="right"] .done-row,
.app[data-emoji="off"][data-timeline-time="right"] .note-row {
  --separator-inset: 8px;
  grid-template-areas: "copy time";
  grid-template-columns: minmax(0, 1fr) 48px;
}

.app[data-emoji="off"] .done-row .row-copy,
.app[data-emoji="off"] .note-row .row-copy {
  padding-left: 2px;
}

.app[data-emoji="off"] .review-records p {
  grid-template-columns: minmax(0, 1fr) auto;
}

.app[data-list-style="row"] .entry-list {
  gap: 0;
}

.app[data-list-style="row"] .entry-row {
  min-height: 44px;
  border-width: 0;
  border-radius: 0;
  box-shadow: none;
  background: transparent;
}

.app[data-list-style="light"] .entry-list,
.app[data-list-style="standard"] .entry-list,
.app[data-list-style="color-piece"] .entry-list {
  gap: 4px;
}

.app[data-list-style="light"] .entry-row,
.app[data-list-style="standard"] .entry-row,
.app[data-list-style="color-piece"] .entry-row {
  min-height: 45px;
  border-radius: 14px;
}

.app[data-list-style="light"] .entry-row {
  border-color: color-mix(in srgb, var(--border), transparent 38%);
  background: color-mix(in srgb, var(--surface-solid) 94%, var(--text) 6%);
}

.app[data-list-style="standard"] .entry-row {
  border-color: color-mix(in srgb, var(--row-accent), transparent 88%);
  background: var(--row-wash);
}

.app[data-list-style="color-piece"] .entry-row {
  margin: 0 3px 3px 0;
  overflow: visible;
  border-color: color-mix(in srgb, var(--row-accent), transparent 91%);
  background: var(--row-wash);
  box-shadow: 3px 3px 0 color-mix(in srgb, var(--row-accent), transparent 32%);
}

.app[data-list-style="color-piece"] .plan-row {
  box-shadow: 3px 3px 0 color-mix(in srgb, var(--row-accent), transparent 70%);
}

.app[data-list-style="color-piece"] .note-row {
  box-shadow: 3px 3px 0 color-mix(in srgb, var(--note-accent), transparent 62%);
}

.app[data-list-style="highlighter"] .entry-list {
  gap: 2px;
}

.app[data-list-style="highlighter"] .entry-row {
  min-height: 44px;
  overflow: visible;
  border: 0;
  border-radius: 8px;
  background: transparent;
  box-shadow: none;
}

.app[data-list-style="highlighter"] .entry-row::before {
  display: none;
}

.app[data-list-style="highlighter"] .entry-row:hover,
.app[data-list-style="highlighter"] .entry-row:active {
  background: color-mix(in srgb, var(--text), transparent 96%);
}

.app[data-list-style="highlighter"] .row-copy {
  padding-top: 7px;
  padding-bottom: 7px;
}

.app[data-list-style="highlighter"] .row-title {
  overflow: visible;
  color: color-mix(in srgb, var(--row-ink) 78%, var(--text));
  text-overflow: clip;
  white-space: normal;
}

.app[data-list-style="highlighter"] .entry-title-marker,
.app[data-list-style="todo-marker-today-card"] .plan-row .entry-title-marker {
  display: inline;
  margin-inline: var(--marker-margin-left, 0) var(--marker-margin-right, 0);
  padding-inline: var(--marker-pad-left, 0.12em) var(--marker-pad-right, 0.12em);
  background-image: linear-gradient(
    to top,
    var(--row-marker) 0,
    var(--row-marker) var(--marker-height, 56%),
    transparent var(--marker-height, 56%),
    transparent 100%
  );
  box-decoration-break: clone;
  -webkit-box-decoration-break: clone;
}

.app[data-list-style="highlighter"] .marker-variant-0,
.app[data-list-style="todo-marker-today-card"] .marker-variant-0 {
  --marker-height: 54%;
  --marker-pad-left: 0.08em;
  --marker-pad-right: 0.20em;
}

.app[data-list-style="highlighter"] .marker-variant-1,
.app[data-list-style="todo-marker-today-card"] .marker-variant-1 {
  --marker-height: 58%;
  --marker-pad-left: 0.18em;
  --marker-pad-right: 0.10em;
}

.app[data-list-style="highlighter"] .marker-variant-2,
.app[data-list-style="todo-marker-today-card"] .marker-variant-2 {
  --marker-height: 56%;
  --marker-pad-left: 0.12em;
  --marker-pad-right: 0.24em;
  --marker-margin-left: -1px;
}

.app[data-list-style="highlighter"] .marker-variant-3,
.app[data-list-style="todo-marker-today-card"] .marker-variant-3 {
  --marker-height: 52%;
  --marker-pad-left: 0.20em;
  --marker-pad-right: 0.14em;
  --marker-margin-right: -1px;
}

.app[data-list-style="todo-marker-today-card"] .entry-list {
  gap: 4px;
}

.app[data-list-style="todo-marker-today-card"] .plan-row {
  min-height: 44px;
  overflow: visible;
  border: 0;
  border-radius: 8px;
  background: transparent;
  box-shadow: none;
}

.app[data-list-style="todo-marker-today-card"] .plan-row::before {
  display: none;
}

.app[data-list-style="todo-marker-today-card"] .plan-row:hover,
.app[data-list-style="todo-marker-today-card"] .plan-row:active {
  background: color-mix(in srgb, var(--text), transparent 96%);
}

.app[data-list-style="todo-marker-today-card"] .plan-row .row-copy {
  padding-top: 7px;
  padding-bottom: 7px;
}

.app[data-list-style="todo-marker-today-card"] .plan-row .row-title {
  overflow: visible;
  color: color-mix(in srgb, var(--row-ink) 78%, var(--text));
  text-overflow: clip;
  white-space: normal;
}

.app[data-list-style="todo-marker-today-card"] .done-row,
.app[data-list-style="todo-marker-today-card"] .note-row {
  min-height: 44px;
  overflow: hidden;
  border: 1px solid color-mix(in srgb, var(--row-accent), transparent 90%);
  border-radius: 10px;
  background: var(--row-wash);
  box-shadow: none;
}

.app[data-list-style="todo-marker-today-card"] .note-row {
  border-color: color-mix(in srgb, var(--note-accent), transparent 91%);
  background: color-mix(in srgb, var(--note-wash) 94%, var(--surface-solid));
}

.app[data-list-style="todo-marker-today-card"] .done-row:hover,
.app[data-list-style="todo-marker-today-card"] .note-row:hover,
.app[data-list-style="todo-marker-today-card"] .done-row:active,
.app[data-list-style="todo-marker-today-card"] .note-row:active {
  background: color-mix(in srgb, var(--row-wash) 94%, var(--row-accent));
}

.app[data-list-style="todo-marker-today-card"] .done-row .row-copy,
.app[data-list-style="todo-marker-today-card"] .note-row .row-copy {
  padding-top: 5px;
  padding-bottom: 5px;
}

.app[data-list-style="todo-marker-today-card"] .done-row .row-title,
.app[data-list-style="todo-marker-today-card"] .note-row .row-title {
  display: -webkit-box;
  overflow: hidden;
  color: var(--row-ink);
  line-height: 1.32;
  text-overflow: clip;
  white-space: normal;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
}

.app[data-list-style="todo-marker-today-card"] .done-row .row-time,
.app[data-list-style="todo-marker-today-card"] .note-row .row-time {
  color: var(--text-muted);
}

.app[data-card-texture="fine-paper"][data-list-style="todo-marker-today-card"] .done-row::after,
.app[data-card-texture="fine-paper"][data-list-style="todo-marker-today-card"] .note-row::after,
.app[data-card-texture="fine-paper"] .mosaic-item::after {
  position: absolute;
  z-index: 0;
  inset: 0;
  border-radius: inherit;
  background-image: var(--fine-paper-texture);
  background-size: 96px 96px;
  content: "";
  mix-blend-mode: normal;
  opacity: var(--fine-paper-opacity);
  pointer-events: none;
}

.app[data-card-texture="fine-paper"][data-list-style="todo-marker-today-card"] .done-row::before,
.app[data-card-texture="fine-paper"] .mosaic-item::before {
  z-index: 2;
}

.app[data-card-texture="fine-paper"][data-list-style="todo-marker-today-card"] .done-row > *,
.app[data-card-texture="fine-paper"][data-list-style="todo-marker-today-card"] .note-row > *,
.app[data-card-texture="fine-paper"] .mosaic-item > * {
  position: relative;
  z-index: 1;
}

.app[data-list-style="paper-tape"] .entry-list {
  gap: 3px;
}

.app[data-list-style="paper-tape"] .entry-row {
  min-height: 47px;
  overflow: visible;
  border: 0;
  border-radius: 0;
  background: transparent;
  box-shadow: none;
}

.app[data-list-style="paper-tape"] .plan-row {
  --separator-inset: 0;
  grid-template-areas: "time copy state";
  grid-template-columns: 52px minmax(0, 1fr) 30px;
  column-gap: 4px;
}

.app[data-list-style="paper-tape"] .plan-row .row-copy {
  grid-area: copy;
}

.app[data-list-style="paper-tape"] .plan-row .row-time {
  grid-area: time;
}

.app[data-list-style="paper-tape"][data-timeline-time="right"] .done-row,
.app[data-list-style="paper-tape"][data-timeline-time="right"] .note-row {
  --separator-inset: 34px;
  grid-template-areas: "emoji copy time";
  grid-template-columns: 32px minmax(0, 1fr) 48px;
  column-gap: 4px;
}

.app[data-list-style="paper-tape"][data-timeline-time="left"] .done-row,
.app[data-list-style="paper-tape"][data-timeline-time="left"] .note-row {
  --separator-inset: 52px;
  grid-template-areas: "time emoji copy";
  grid-template-columns: 48px 32px minmax(0, 1fr);
  column-gap: 4px;
}

.app[data-list-style="paper-tape"] .row-copy {
  width: min(var(--tape-width), 100%);
  min-width: min(126px, 100%);
  max-width: 100%;
  justify-self: start;
  padding: 7px 14px;
  background:
    linear-gradient(93deg, color-mix(in srgb, var(--row-wash) 96%, var(--text) 4%), var(--row-wash));
  box-shadow: 0 1px 2px color-mix(in srgb, var(--shadow-color), transparent 76%);
  transform: translateX(var(--tape-shift)) rotate(var(--tape-tilt));
  transform-origin: center;
}

.app[data-list-style="paper-tape"] .row-title {
  font-size: 14px;
  letter-spacing: -0.025em;
}

.app[data-list-style="paper-tape"] .plan-row .row-copy {
  background: color-mix(in srgb, var(--row-wash) 78%, transparent);
  box-shadow: 0 1px 1px color-mix(in srgb, var(--shadow-color), transparent 84%);
}

.app[data-list-style="paper-tape"] .note-row .row-copy {
  background: color-mix(in srgb, var(--note-wash) 90%, transparent);
}

.app[data-list-style="paper-tape"] .plan-row .row-time,
.app[data-list-style="paper-tape"][data-timeline-time="left"] .done-row .row-time,
.app[data-list-style="paper-tape"][data-timeline-time="left"] .note-row .row-time {
  padding-right: 0;
  padding-left: 7px;
  text-align: left;
}

.app[data-list-style="paper-tape"][data-timeline-time="right"] .done-row .row-time,
.app[data-list-style="paper-tape"][data-timeline-time="right"] .note-row .row-time {
  padding-right: 7px;
  padding-left: 0;
  text-align: right;
}

.app[data-list-style="paper-tape"] .row-state {
  grid-area: state;
  padding-right: 2px;
  text-align: center;
}

.app[data-list-style="paper-tape"] .entry-row::before {
  display: none;
}

.app[data-list-style="paper-tape"] .tape-edge-0 .row-copy {
  clip-path: polygon(1% 0, 99% 0, 100% 13%, 99% 26%, 100% 41%, 99% 57%, 100% 74%, 99% 100%, 1% 100%, 0 86%, 1% 71%, 0 54%, 1% 37%, 0 20%);
}

.app[data-list-style="paper-tape"] .tape-edge-1 .row-copy {
  clip-path: polygon(2% 0, 98% 0, 100% 9%, 98.5% 22%, 100% 38%, 98.5% 55%, 100% 69%, 98% 84%, 99% 100%, 1% 100%, 0 80%, 1.5% 64%, 0 48%, 1.5% 31%, 0 14%);
}

.app[data-list-style="paper-tape"] .tape-edge-2 .row-copy {
  clip-path: polygon(1% 0, 99% 0, 98% 17%, 100% 31%, 98.5% 47%, 100% 63%, 98% 79%, 99% 100%, 2% 100%, 0 91%, 1.5% 75%, 0 59%, 1.5% 43%, 0 27%, 2% 12%);
}

.app[data-list-style="paper-tape"][data-emoji="off"][data-timeline-time="right"] .done-row,
.app[data-list-style="paper-tape"][data-emoji="off"][data-timeline-time="right"] .note-row {
  --separator-inset: 0;
  grid-template-areas: "copy time";
  grid-template-columns: minmax(0, 1fr) 48px;
}

.app[data-list-style="paper-tape"][data-emoji="off"][data-timeline-time="left"] .done-row,
.app[data-list-style="paper-tape"][data-emoji="off"][data-timeline-time="left"] .note-row {
  --separator-inset: 52px;
  grid-template-areas: "time copy";
  grid-template-columns: 48px minmax(0, 1fr);
}

.app[data-separator="on"] .entry-row + .entry-row::after {
  position: absolute;
  top: 0;
  right: 8px;
  left: var(--separator-inset, 48px);
  height: 1px;
  background: color-mix(in srgb, var(--text-muted), transparent 82%);
  content: "";
  pointer-events: none;
}

.bottom-sheet {
  position: absolute;
  z-index: 8;
  right: 10px;
  bottom: 9px;
  left: 10px;
  height: 88px;
  overflow: hidden;
  border: 1px solid var(--border);
  border-radius: 25px;
  background: var(--surface-solid);
  box-shadow: var(--shadow);
  transition: height 220ms ease-out, border-radius 220ms ease-out;
}

.app[data-sheet="expanded"] .bottom-sheet {
  height: min(64%, 545px);
  border-radius: 25px 25px 34px 34px;
}

.sheet-header {
  position: relative;
  display: flex;
  width: 100%;
  min-height: 87px;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding: 18px 19px 9px;
  border: 0;
  background: transparent;
  color: var(--text);
  cursor: pointer;
  text-align: left;
}

.sheet-handle {
  position: absolute;
  top: 8px;
  left: 50%;
  width: 44px;
  height: 4px;
  transform: translateX(-50%);
  border-radius: 99px;
  background: color-mix(in srgb, var(--text-muted), transparent 45%);
}

.sheet-heading {
  font-family: var(--font-heading);
  font-size: 16px;
  font-weight: 680;
}

.sheet-heading small {
  margin-left: 6px;
  color: var(--text-muted);
  font-family: var(--font-body);
  font-size: 10px;
  font-weight: 600;
}

.sheet-chevron {
  width: 20px;
  height: 20px;
  fill: none;
  stroke: currentColor;
  stroke-linecap: round;
  stroke-width: 1.8;
  transition: transform 220ms ease-out;
}

.app[data-sheet="expanded"] .sheet-chevron {
  transform: rotate(180deg);
}

.sheet-body {
  height: calc(100% - 82px);
  padding: 0 14px 22px;
  overflow: auto;
  opacity: 0;
  transition: opacity 150ms ease-out;
}

.app[data-sheet="expanded"] .sheet-body {
  opacity: 1;
}

.panel-backdrop {
  position: absolute;
  z-index: 18;
  inset: 0;
  background: rgba(4, 7, 9, 0.30);
  backdrop-filter: blur(1px);
}

.review-panel,
.placeholder-panel {
  position: absolute;
  z-index: 20;
  right: 8px;
  bottom: 8px;
  left: 8px;
  height: var(--panel-height);
  padding: 22px 18px 15px;
  overflow: hidden;
  border: 1px solid var(--border);
  border-radius: 30px;
  background: var(--surface-solid);
  color: var(--text);
  box-shadow: 0 -18px 50px rgba(0, 0, 0, 0.18);
  transform: translateY(calc(100% + 16px));
  transition: transform 220ms ease-out;
}

.review-panel.is-open,
.placeholder-panel.is-open {
  transform: translateY(0);
}

.placeholder-panel {
  top: 22%;
  bottom: auto;
  height: auto;
  min-height: 210px;
  padding-top: 30px;
  opacity: 0;
  pointer-events: none;
  transform: translateY(24px) scale(0.98);
}

.placeholder-panel.is-open {
  opacity: 1;
  pointer-events: auto;
  transform: translateY(0) scale(1);
}

.panel-topline {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
}

.panel-kicker {
  margin: 0 0 5px;
  color: var(--text-muted);
  font-size: 10px;
  font-weight: 650;
  letter-spacing: 0.05em;
}

.close-button {
  width: 38px;
  height: 38px;
  flex: 0 0 auto;
  font-size: 23px;
  font-weight: 330;
  line-height: 1;
}

.review-scroll {
  height: calc(100% - 56px);
  padding: 17px 1px 40px;
  overflow: auto;
}

.review-scroll section + section {
  margin-top: 20px;
}

.week-story {
  padding: 14px 15px;
  border: 1px solid var(--border);
  border-radius: 18px;
  background: color-mix(in srgb, var(--surface), var(--bg-top) 18%);
}

.week-story p {
  margin: 0;
  font-size: 13px;
  line-height: 1.8;
}

.review-scroll h3 {
  margin: 0 0 9px;
  font-family: var(--font-heading);
  font-size: 14px;
  letter-spacing: 0.03em;
}

.review-section-heading span {
  color: var(--text-muted);
  font-size: 10px;
}

.category-mosaic {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 7px;
}

.mosaic-item {
  position: relative;
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 2px 5px;
  min-width: 0;
  padding: 10px;
  border: 1px solid color-mix(in srgb, var(--category-accent), transparent 84%);
  border-radius: 15px;
  background: var(--category-wash);
  color: var(--category-ink);
}

.mosaic-item::before {
  position: absolute;
  top: 9px;
  left: 9px;
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: var(--category-accent);
  content: "";
}

.mosaic-item span,
.mosaic-item small {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.mosaic-item span {
  padding-left: 9px;
  font-size: 10px;
  font-weight: 650;
}

.mosaic-item strong {
  grid-row: span 2;
  font-size: 22px;
  font-weight: 500;
}

.mosaic-item small {
  color: var(--text-muted);
  font-size: 8px;
}

.review-records {
  display: grid;
  gap: 6px;
}

.review-records p {
  display: grid;
  grid-template-columns: 28px minmax(0, 1fr) auto;
  align-items: center;
  gap: 5px;
  margin: 0;
  padding: 8px 9px;
  border-bottom: 1px solid color-mix(in srgb, var(--category-accent), transparent 84%);
  background: color-mix(in srgb, var(--category-wash) 54%, transparent);
}

.review-records strong {
  overflow: hidden;
  color: var(--category-ink);
  font-size: 11px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.review-records small {
  color: var(--text-muted);
  font-size: 8px;
}

.weekly-notes blockquote {
  margin: 6px 0;
  padding: 9px 11px;
  border-left: 2px solid color-mix(in srgb, var(--accent), transparent 30%);
  background: color-mix(in srgb, var(--surface), transparent 18%);
  color: var(--text-muted);
  font-size: 11px;
  line-height: 1.55;
}

.review-footnote {
  margin: 22px 0 0;
  color: var(--text-muted);
  font-size: 9px;
  line-height: 1.6;
}

.placeholder-panel .close-button {
  position: absolute;
  top: 15px;
  right: 15px;
}

.placeholder-panel > p:last-child {
  max-width: 280px;
  color: var(--text-muted);
  font-size: 12px;
  line-height: 1.7;
}

.controls {
  position: sticky;
  top: 24px;
  align-self: start;
  max-height: calc(100vh - 48px);
  padding: 22px;
  overflow: auto;
  border: 1px solid rgba(60, 62, 60, 0.13);
  border-radius: 24px;
  background: var(--page-panel);
  box-shadow: 0 18px 48px rgba(44, 46, 44, 0.09);
  backdrop-filter: blur(18px);
}

.controls-header {
  padding-bottom: 15px;
  border-bottom: 1px solid rgba(54, 57, 55, 0.10);
}

.controls fieldset {
  min-width: 0;
  margin: 14px 0 0;
  padding: 0;
  border: 0;
}

.controls legend {
  margin-bottom: 7px;
  color: #6f706d;
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.05em;
}

.controls select {
  width: 100%;
  min-height: 40px;
  padding: 0 34px 0 12px;
  border: 1px solid rgba(54, 57, 55, 0.14);
  border-radius: 11px;
  background: rgba(255, 255, 255, 0.74);
  color: #2f312f;
  cursor: pointer;
  font-size: 12px;
}

.segmented,
.control-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 4px;
}

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

.control-grid.four {
  grid-template-columns: repeat(4, minmax(0, 1fr));
}

.segmented label {
  position: relative;
  cursor: pointer;
}

.segmented input {
  position: absolute;
  opacity: 0;
  pointer-events: none;
}

.segmented span,
.control-grid button {
  display: grid;
  min-height: 37px;
  place-items: center;
  padding: 5px;
  border: 1px solid rgba(54, 57, 55, 0.13);
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.64);
  color: #555853;
  font-size: 11px;
  font-weight: 600;
}

.segmented input:checked + span {
  border-color: rgba(49, 74, 66, 0.45);
  background: #2f3c37;
  color: white;
}

.control-grid button {
  cursor: pointer;
}

.control-grid button:hover {
  background: #2f3c37;
  color: white;
}

.palette-preview {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 5px 8px;
  margin-top: 9px;
}

.palette-preview i {
  display: inline-block;
  width: 8px;
  height: 8px;
  flex: 0 0 auto;
  border-radius: 99px;
}

.palette-preview span {
  display: flex;
  min-width: 0;
  align-items: center;
  gap: 5px;
  color: var(--page-muted);
  font-size: 9px;
  white-space: nowrap;
}

.palette-preview .category-work { background: var(--category-work-base); }
.palette-preview .category-life { background: var(--category-life-base); }
.palette-preview .category-people { background: var(--category-people-base); }
.palette-preview .category-self { background: var(--category-self-base); }

.token-note {
  margin-top: 17px;
  padding: 12px;
  border-radius: 13px;
  background: rgba(48, 58, 54, 0.06);
}

.token-note strong {
  font-size: 11px;
}

.token-note p {
  margin: 4px 0 0;
  color: var(--page-muted);
  font-size: 10px;
  line-height: 1.65;
}

@media (max-width: 880px) {
  .workbench {
    grid-template-columns: minmax(0, 1fr);
    gap: 28px;
    padding: 26px 18px 40px;
  }

  .controls {
    position: static;
    width: min(100%, 430px);
    max-height: none;
    margin: 0 auto;
  }

  .device {
    height: min(850px, calc(100svh - 48px));
  }
}

@media (max-width: 460px) {
  body {
    background: #111311;
  }

  .workbench {
    display: block;
    padding: 0;
  }

  .preview-heading,
  .controls {
    display: none;
  }

  .device {
    width: 100%;
    height: 100svh;
    min-height: 640px;
    padding: 0;
    border: 0;
    border-radius: 0;
    box-shadow: none;
  }

  .device-speaker {
    display: none;
  }

  .app {
    border-radius: 0;
  }
}

@media (max-height: 760px) and (min-width: 461px) {
  .device {
    min-height: 690px;
  }

  .time-hub {
    min-height: 142px;
  }

  .celestial {
    transform: scale(0.88);
  }

  .main-content {
    height: calc(100% - 288px);
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    scroll-behavior: auto !important;
    transition-duration: 0.01ms !important;
  }
}
