:root {
  --ink: #30352f;
  --muted: #7c8078;
  --paper: #f7f4ed;
  --cream: #efebe1;
  --line: rgba(73, 76, 68, 0.13);
  --sage: #879b7a;
  --sage-pale: #dfe6d9;
  --clay: #b8795d;
  --clay-pale: #eee0d5;
  --gold: #c1a36e;
  --white: #fffdf8;
  --serif: "Iowan Old Style", "Palatino Linotype", Palatino, Georgia, serif;
  --sans: "Avenir Next", Avenir, "Segoe UI", sans-serif;
}

* {
  box-sizing: border-box;
}

[hidden] {
  display: none !important;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-width: 320px;
  overflow-x: hidden;
  color: var(--ink);
  background: var(--paper);
  font-family: var(--sans);
  -webkit-font-smoothing: antialiased;
}

button,
input,
textarea {
  font: inherit;
}

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

button {
  color: inherit;
}

.ambient {
  position: fixed;
  z-index: -1;
  width: 430px;
  height: 430px;
  border-radius: 50%;
  filter: blur(2px);
  pointer-events: none;
}

.ambient-one {
  top: -250px;
  right: 3%;
  background: radial-gradient(circle, rgba(218, 222, 199, 0.64), transparent 69%);
}

.ambient-two {
  bottom: -300px;
  left: 12%;
  background: radial-gradient(circle, rgba(232, 211, 194, 0.55), transparent 68%);
}

.app-shell {
  min-height: 100vh;
}

.sidebar {
  position: fixed;
  inset: 0 auto 0 0;
  z-index: 5;
  display: flex;
  width: 238px;
  flex-direction: column;
  padding: 34px 24px 28px;
  border-right: 1px solid var(--line);
  background: rgba(240, 236, 226, 0.72);
  backdrop-filter: blur(14px);
}

.brand {
  display: flex;
  align-items: center;
  gap: 11px;
  margin: 0 8px 18px;
  color: var(--ink);
  font-family: var(--serif);
  font-size: 19px;
  text-decoration: none;
}

.brand-mark {
  display: grid;
  width: 31px;
  height: 31px;
  place-items: center;
  border-radius: 50% 50% 48% 44%;
  color: white;
  background: var(--sage);
  font-size: 16px;
  font-style: italic;
}

.space-toggle {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 4px;
  margin: 0 0 30px;
  padding: 4px;
  border: 1px solid rgba(71, 76, 67, 0.08);
  border-radius: 999px;
  background: rgba(255, 253, 248, 0.55);
}

.space-toggle-button {
  min-height: 32px;
  border: 0;
  border-radius: 999px;
  color: #8b8e85;
  background: transparent;
  font-size: 9px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  cursor: pointer;
}

.space-toggle-button.active {
  color: var(--ink);
  background: rgba(239, 225, 215, 0.78);
  box-shadow: 0 6px 18px rgba(72, 69, 59, 0.055);
}

.nav {
  display: grid;
  gap: 6px;
}

.nav-link {
  display: flex;
  align-items: center;
  gap: 13px;
  padding: 11px 13px;
  border-radius: 9px;
  color: #767970;
  font-size: 13px;
  text-decoration: none;
  transition: 180ms ease;
}

.nav-link:hover,
.nav-link.active {
  color: var(--ink);
  background: rgba(255, 253, 248, 0.74);
}

.nav-icon {
  width: 18px;
  color: #8d9585;
  font-family: var(--serif);
  font-size: 17px;
  text-align: center;
}

.quiet-button {
  display: flex;
  align-items: center;
  gap: 9px;
  margin-top: 28px;
  padding: 11px 14px;
  border: 1px solid rgba(117, 130, 105, 0.22);
  border-radius: 9px;
  color: #65715e;
  background: rgba(223, 230, 217, 0.48);
  font-size: 12px;
  cursor: pointer;
  transition: 180ms ease;
}

.quiet-button:hover {
  background: var(--sage-pale);
  transform: translateY(-1px);
}

.sidebar-foot {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-top: auto;
}

.season-card {
  display: flex;
  flex: 1;
  align-items: center;
  gap: 10px;
  padding: 10px 12px;
  border-radius: 10px;
  background: rgba(255, 253, 248, 0.55);
}

.season-card small {
  color: #99998f;
  font-size: 9px;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.season-card p {
  margin: 2px 0 0;
  font-family: var(--serif);
  font-size: 13px;
}

.season-symbol {
  color: var(--gold);
  font-size: 21px;
}

.icon-button {
  display: grid;
  width: 32px;
  height: 32px;
  padding: 0;
  place-items: center;
  border: 0;
  border-radius: 50%;
  color: #85877e;
  background: transparent;
  cursor: pointer;
}

.icon-button:hover {
  background: rgba(100, 105, 95, 0.08);
}

main {
  min-height: 100vh;
  margin-left: 238px;
  padding: 0 5.5vw 80px;
}

.topbar {
  display: flex;
  height: 80px;
  align-items: center;
  justify-content: space-between;
  border-bottom: 1px solid var(--line);
}

.date {
  color: #888b82;
  font-family: var(--serif);
  font-size: 12px;
  font-style: italic;
}

.top-actions {
  display: flex;
  align-items: center;
  gap: 16px;
}

.search-button {
  display: flex;
  width: 195px;
  align-items: center;
  gap: 8px;
  padding: 8px 10px;
  border: 1px solid var(--line);
  border-radius: 8px;
  color: #999b93;
  background: rgba(255, 253, 248, 0.53);
  font-size: 11px;
  cursor: pointer;
}

.search-button kbd {
  margin-left: auto;
  padding: 2px 5px;
  border-radius: 4px;
  color: #aaa;
  background: rgba(80, 80, 75, 0.05);
  font-family: inherit;
  font-size: 9px;
}

.avatar {
  width: 34px;
  height: 34px;
  border: 0;
  border-radius: 50%;
  color: #fff;
  background: #7e8c74;
  font-family: var(--serif);
  cursor: pointer;
}

.hero {
  max-width: 690px;
  padding: 66px 0 48px;
}

.eyebrow {
  color: #686f66;
  font-size: 10px;
  font-weight: 600;
  letter-spacing: 0.18em;
  text-transform: uppercase;
}

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

h1 {
  margin: 9px 0 8px;
  font-family: var(--serif);
  font-size: clamp(36px, 4.2vw, 54px);
  font-weight: 400;
  letter-spacing: -0.035em;
  line-height: 1.08;
}

.hero-copy {
  color: #777b72;
  font-family: var(--serif);
  font-size: 16px;
  font-style: italic;
}

.check-in-card {
  margin-top: 35px;
  padding: 19px 21px;
  border: 1px solid rgba(116, 128, 108, 0.15);
  border-radius: 14px;
  background: rgba(229, 234, 223, 0.63);
}

.check-in-copy {
  display: flex;
  align-items: center;
  gap: 13px;
}

.soft-icon {
  display: grid;
  width: 35px;
  height: 35px;
  place-items: center;
  border-radius: 50%;
  color: #75826e;
  background: rgba(255, 255, 255, 0.56);
  font-family: var(--serif);
  font-size: 19px;
}

.check-in-card h2 {
  margin: 0 0 3px;
  font-family: var(--serif);
  font-size: 16px;
  font-weight: 400;
}

.check-in-card p {
  margin: 0;
  color: #8a8f84;
  font-size: 10px;
}

.check-in-card form {
  display: flex;
  margin-top: 15px;
}

.check-in-card input {
  flex: 1;
  padding: 10px 0;
  border: 0;
  border-bottom: 1px solid rgba(85, 96, 78, 0.18);
  outline: 0;
  color: var(--ink);
  background: transparent;
  font-family: var(--serif);
  font-size: 13px;
}

.check-in-card input::placeholder,
textarea::placeholder {
  color: #737970;
  font-style: italic;
}

.check-in-card form button {
  width: 34px;
  border: 0;
  border-radius: 50%;
  color: #fff;
  background: #7f8f76;
  cursor: pointer;
}

.check-in-saved {
  margin-top: 14px;
  color: #687361;
  font-family: var(--serif);
  font-size: 14px;
  font-style: italic;
}

.content-grid {
  display: grid;
  grid-template-columns: minmax(440px, 1.55fr) minmax(280px, 0.9fr);
  gap: clamp(36px, 5vw, 74px);
}

.section-block {
  margin-bottom: 57px;
}

.section-heading {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 20px;
  margin-bottom: 17px;
}

.section-heading h2,
.gentle-focus h2 {
  margin: 6px 0 0;
  font-family: var(--serif);
  font-size: 21px;
  font-weight: 400;
  letter-spacing: -0.015em;
}

.text-button,
.shuffle-button {
  padding: 4px;
  border: 0;
  color: #8b8e85;
  background: transparent;
  font-size: 10px;
  cursor: pointer;
}

.text-button span {
  margin-left: 3px;
}

.thread-list {
  display: grid;
  gap: 12px;
}

.thread-preview-empty {
  padding: 24px;
  border: 1px dashed rgba(102, 119, 93, 0.18);
  border-radius: 12px;
  background: rgba(224, 230, 216, 0.28);
  text-align: center;
}

.thread-preview-empty p {
  margin: 0 0 8px;
  color: #8b8f85;
  font-family: var(--serif);
  font-size: 11px;
  font-style: italic;
}

.thread-card {
  display: grid;
  width: 100%;
  grid-template-columns: 42px 1fr auto;
  align-items: center;
  gap: 15px;
  padding: 20px;
  border: 1px solid rgba(75, 75, 67, 0.08);
  border-radius: 12px;
  text-align: left;
  cursor: pointer;
  transition: 180ms ease;
}

.thread-card:hover {
  transform: translateY(-2px);
  box-shadow: 0 10px 30px rgba(65, 62, 54, 0.06);
}

.thread-card.clay {
  background: rgba(239, 225, 215, 0.62);
}

.thread-card.sage {
  background: rgba(224, 230, 216, 0.64);
}

.thread-symbol {
  display: grid;
  width: 38px;
  height: 38px;
  place-items: center;
  border-radius: 50%;
  font-family: var(--serif);
  font-size: 17px;
}

.clay .thread-symbol {
  color: #a9684d;
  background: rgba(255, 255, 255, 0.4);
}

.sage .thread-symbol {
  color: #6f8264;
  background: rgba(255, 255, 255, 0.4);
}

.thread-meta {
  color: #6f756c;
  font-size: 10px;
  letter-spacing: 0.07em;
  text-transform: uppercase;
}

.thread-card h3 {
  margin: 5px 0 5px;
  font-family: var(--serif);
  font-size: 16px;
  font-weight: 400;
}

.thread-card p {
  margin: 0;
  overflow: hidden;
  color: #85877e;
  font-family: var(--serif);
  font-size: 11px;
  font-style: italic;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.threads-view {
  max-width: 980px;
  padding: 51px 0 75px;
}

.threads-page-list {
  display: grid;
  gap: 13px;
  margin-top: 42px;
}

.thread-page-card {
  background: rgba(255, 253, 248, 0.72);
}

.thread-page-card:nth-child(even) {
  background: rgba(224, 230, 216, 0.5);
}

.arrow {
  color: #a1a299;
}

.reflection-card {
  position: relative;
  display: block;
  width: 100%;
  padding: 34px 36px 25px;
  overflow: hidden;
  border: 1px solid rgba(160, 136, 93, 0.16);
  border-radius: 13px;
  color: inherit;
  background: rgba(249, 245, 232, 0.87);
  text-align: left;
}

.resurfaced-card {
  cursor: pointer;
  transition: 180ms ease;
}

.resurfaced-card:hover {
  border-color: rgba(160, 136, 93, 0.26);
  box-shadow: 0 12px 35px rgba(99, 85, 60, 0.05);
  transform: translateY(-2px);
}

.reflection-card::after {
  position: absolute;
  right: -25px;
  bottom: -45px;
  width: 125px;
  height: 125px;
  border: 1px solid rgba(175, 153, 109, 0.13);
  border-radius: 50%;
  content: "";
}

.quote-mark {
  color: #c4aa78;
  font-family: Georgia, serif;
  font-size: 36px;
  line-height: 0.8;
}

blockquote {
  max-width: 530px;
  margin: 12px 0 26px;
  font-family: var(--serif);
  font-size: 20px;
  font-style: italic;
  line-height: 1.48;
}

.reflection-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-top: 1px solid rgba(150, 130, 95, 0.12);
  padding-top: 17px;
  color: #9a978d;
  font-size: 9px;
}

.reflection-arrow {
  position: relative;
  z-index: 1;
  color: #8d897f;
}

.resurfacing-reason {
  position: relative;
  z-index: 1;
  margin: 15px 0 0;
  color: #9d9a90;
  font-family: var(--serif);
  font-size: 9px;
  font-style: italic;
  line-height: 1.45;
}

.resurfacing-empty {
  display: flex;
  align-items: center;
  gap: 15px;
  padding: 23px 25px;
  border: 1px dashed rgba(126, 145, 117, 0.2);
  border-radius: 13px;
  background: rgba(230, 234, 223, 0.35);
}

.resurfacing-empty > span {
  display: grid;
  width: 38px;
  height: 38px;
  flex: 0 0 38px;
  place-items: center;
  border-radius: 50%;
  color: #83907b;
  background: rgba(255, 253, 248, 0.7);
  font-family: var(--serif);
  font-size: 18px;
}

.resurfacing-empty h3 {
  margin: 0 0 4px;
  font-family: var(--serif);
  font-size: 14px;
  font-weight: 400;
}

.resurfacing-empty p {
  margin: 0;
  color: #92968c;
  font-family: var(--serif);
  font-size: 10px;
  font-style: italic;
}

.heart {
  position: relative;
  z-index: 1;
  font-size: 17px;
}

.heart.loved {
  color: #ad765f;
}

.right-column {
  padding-top: 0;
}

.vibe-check {
  margin-bottom: 30px;
  padding: 23px;
  border: 1px solid rgba(137, 110, 94, 0.12);
  border-radius: 17px;
  background:
    radial-gradient(circle at top left, rgba(235, 207, 197, 0.34), transparent 42%),
    rgba(255, 253, 248, 0.72);
  box-shadow: 0 20px 54px rgba(72, 69, 59, 0.045);
}

.vibe-check .section-heading {
  margin-bottom: 14px;
}

.vibe-check h2 {
  max-width: 260px;
}

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

.vibe-card {
  display: grid;
  gap: 11px;
  align-content: start;
  min-height: 136px;
  padding: 14px;
  border: 1px solid rgba(71, 76, 67, 0.08);
  border-radius: 14px;
  background: rgba(255, 253, 248, 0.72);
}

.vibe-card.stack-card,
.vibe-card.stanley-card {
  min-height: auto;
}

.vibe-label {
  display: block;
  color: #7f665b;
  font-size: 10px;
  letter-spacing: 0.11em;
  text-transform: uppercase;
}

.vibe-card p {
  margin: 5px 0 0;
  color: #7d7f76;
  font-family: var(--serif);
  font-size: 12px;
  line-height: 1.42;
}

.vibe-card p strong {
  color: var(--ink);
  font-size: 18px;
  font-weight: 400;
}

.vibe-actions,
.stanley-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
  align-items: center;
}

.vibe-button,
.vibe-link-button {
  min-height: 36px;
  border: 0;
  border-radius: 999px;
  cursor: pointer;
}

.vibe-button {
  padding: 9px 13px;
  color: #f8f7f2;
  background: #7b8a72;
  font-size: 10px;
}

.vibe-link-button {
  padding: 8px 10px;
  color: #8b6758;
  background: rgba(239, 225, 215, 0.52);
  font-size: 9px;
}

.vibe-button:hover {
  background: #697961;
}

.vibe-button:disabled {
  opacity: 0.45;
  cursor: default;
}

.vibe-link-button:hover {
  color: var(--ink);
}

.stanley-actions .vibe-button {
  display: grid;
  width: 38px;
  padding: 0;
  place-items: center;
  font-size: 15px;
}

.vibe-note {
  display: grid;
  gap: 5px;
}

.vibe-note span {
  color: #8b8e85;
  font-size: 9px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.vibe-note small {
  color: #aaa79d;
  font-size: 8px;
  letter-spacing: 0.02em;
  text-transform: none;
}

.vibe-note input,
.vibe-note select {
  width: 100%;
  min-height: 38px;
  border: 1px solid rgba(71, 76, 67, 0.09);
  border-radius: 10px;
  color: var(--ink);
  background: rgba(255, 253, 248, 0.68);
  font-family: var(--sans);
  font-size: 11px;
}

.vibe-note input {
  padding: 0 10px;
}

.vibe-note select {
  padding: 0 9px;
}

.vibe-card.logged {
  border-color: rgba(123, 138, 114, 0.28);
  background: rgba(241, 246, 236, 0.58);
}

.gentle-nudges {
  margin-bottom: 30px;
  padding: 22px;
  border: 1px solid rgba(126, 111, 94, 0.11);
  border-radius: 16px;
  background:
    linear-gradient(135deg, rgba(255, 253, 248, 0.82), rgba(242, 229, 220, 0.44)),
    rgba(255, 253, 248, 0.68);
  box-shadow: 0 18px 48px rgba(72, 69, 59, 0.04);
}

.gentle-nudges .section-heading {
  margin-bottom: 13px;
}

.gentle-nudges h2 {
  max-width: 260px;
}

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

.gentle-nudge-card {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 14px;
  align-items: start;
  padding: 14px;
  border: 1px solid rgba(71, 76, 67, 0.08);
  border-radius: 13px;
  background: rgba(255, 253, 248, 0.72);
}

.gentle-nudge-card h3 {
  margin: 0 0 5px;
  font-family: var(--serif);
  font-size: 15px;
  font-weight: 400;
  letter-spacing: -0.01em;
}

.gentle-nudge-card p {
  margin: 0;
  color: #7d7f76;
  font-family: var(--serif);
  font-size: 11px;
  line-height: 1.45;
}

.nudge-action,
.nudge-note,
.nudge-dismiss {
  min-height: 34px;
}

.nudge-action {
  margin-top: 9px;
  padding: 0;
  border: 0;
  color: #8b6758;
  background: transparent;
  font-size: 10px;
  cursor: pointer;
}

.nudge-note {
  display: inline-flex;
  align-items: center;
  margin-top: 9px;
  color: #929087;
  font-size: 10px;
}

.nudge-dismiss {
  padding: 7px 9px;
  border: 1px solid rgba(71, 76, 67, 0.1);
  border-radius: 999px;
  color: #8b8e85;
  background: rgba(255, 253, 248, 0.7);
  font-size: 9px;
  cursor: pointer;
}

.nudge-action:hover,
.nudge-dismiss:hover {
  color: var(--ink);
}

.gentle-focus {
  margin-bottom: 52px;
  padding: 27px 25px;
  border: 1px solid rgba(71, 76, 67, 0.09);
  border-radius: 14px;
  background: rgba(255, 253, 248, 0.62);
  box-shadow: 0 18px 50px rgba(72, 69, 59, 0.035);
}

.gentle-focus h2 {
  max-width: 250px;
  margin-bottom: 17px;
  font-size: 20px;
  line-height: 1.32;
}

.gentle-focus textarea,
.dialog-card textarea {
  width: 100%;
  resize: none;
  border: 0;
  outline: 0;
  color: var(--ink);
  background: transparent;
  font-family: var(--serif);
  font-size: 13px;
  line-height: 1.5;
}

.gentle-focus form button {
  width: 100%;
  margin-top: 12px;
  padding: 10px;
  border: 0;
  border-radius: 8px;
  color: #f8f7f2;
  background: #7b8a72;
  font-size: 10px;
  cursor: pointer;
  transition: 180ms ease;
}

.gentle-focus form button:hover,
.primary-button:hover {
  background: #697961;
}

.daily-reflection-invite {
  display: flex;
  align-items: flex-start;
  gap: 14px;
  margin: -29px 0 43px;
  padding: 20px;
  border: 1px solid rgba(161, 119, 101, 0.11);
  border-radius: 13px;
  background: rgba(239, 225, 215, 0.42);
}

.daily-reflection-symbol {
  display: grid;
  width: 36px;
  height: 36px;
  flex: 0 0 36px;
  place-items: center;
  border-radius: 50%;
  color: #9b6f5c;
  background: rgba(255, 253, 248, 0.62);
  font-family: var(--serif);
  font-size: 18px;
}

.daily-reflection-invite h2 {
  margin: 5px 0 5px;
  font-family: var(--serif);
  font-size: 17px;
  font-weight: 400;
}

.daily-reflection-invite p {
  margin: 0 0 8px;
  color: #929087;
  font-family: var(--serif);
  font-size: 10px;
  font-style: italic;
  line-height: 1.4;
}

.daily-reflection-invite .text-button {
  margin-left: -4px;
  color: #886c5d;
}

.focus-display {
  display: flex;
  gap: 10px;
  margin: 21px 0 0;
  padding: 15px;
  border-radius: 10px;
  background: var(--sage-pale);
}

.focus-display span {
  color: #7a8a70;
}

.focus-display p {
  margin: 0;
  font-family: var(--serif);
  font-size: 14px;
  line-height: 1.4;
}

.compact {
  align-items: center;
  margin-bottom: 10px;
}

.compact h2 {
  font-size: 18px;
}

.section-mini-actions {
  display: flex;
  align-items: center;
  gap: 4px;
}

.gathered-list {
  display: grid;
}

.gathered-item {
  display: grid;
  width: 100%;
  grid-template-columns: 31px 1fr;
  gap: 10px;
  padding: 15px 0;
  border: 0;
  border-bottom: 1px solid var(--line);
  color: inherit;
  background: transparent;
  text-align: left;
  cursor: pointer;
  transition: 160ms ease;
}

.gathered-item:hover {
  padding-inline: 8px;
  border-radius: 9px;
  background: rgba(255, 253, 248, 0.65);
}

.item-icon {
  display: grid;
  width: 28px;
  height: 28px;
  place-items: center;
  border-radius: 8px;
  font-family: var(--serif);
}

.item-icon.paper {
  color: #95735f;
  background: var(--clay-pale);
}

.item-icon.leaf {
  color: #6c8063;
  background: var(--sage-pale);
}

.item-icon.sun {
  color: #9c824f;
  background: #eee5cc;
}

.gathered-item p {
  margin: 1px 0 5px;
  font-family: var(--serif);
  font-size: 12px;
  line-height: 1.4;
}

.gathered-item small {
  color: #6f756c;
  font-size: 10px;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.all-moments-view {
  max-width: 1060px;
  padding: 51px 0 70px;
}

.back-button {
  margin-bottom: 31px;
  padding: 0;
  border: 0;
  color: #8e9188;
  background: transparent;
  font-family: var(--serif);
  font-size: 11px;
  font-style: italic;
  cursor: pointer;
}

.moments-title-row {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 30px;
  margin-top: 3px;
}

.moments-title-row h1 {
  margin-bottom: 7px;
}

.moments-title-row p {
  margin: 0;
  color: #7e8279;
  font-family: var(--serif);
  font-size: 14px;
  font-style: italic;
}

.quiet-button.page-capture {
  width: auto;
  flex: 0 0 auto;
  margin: 0 0 5px;
  padding: 11px 15px;
}

.moments-controls {
  margin-top: 42px;
  padding: 18px;
  border: 1px solid rgba(75, 78, 69, 0.09);
  border-radius: 14px;
  background: rgba(255, 253, 248, 0.64);
  box-shadow: 0 13px 40px rgba(72, 69, 59, 0.035);
}

.moments-search {
  display: flex;
  align-items: center;
  gap: 11px;
  padding: 0 3px 13px;
  border-bottom: 1px solid var(--line);
  color: #979a91;
}

.moments-search > span {
  font-size: 18px;
}

.moments-search input {
  width: 100%;
  border: 0;
  outline: 0;
  color: var(--ink);
  background: transparent;
  font-family: var(--serif);
  font-size: 14px;
}

.moments-search input::placeholder {
  color: #a6a89f;
  font-style: italic;
}

.moment-filters {
  display: flex;
  align-items: end;
  gap: 10px;
  padding-top: 13px;
}

.moment-filters label {
  flex: 1;
}

.moment-filters label > span {
  display: block;
  margin: 0 0 5px 2px;
  color: #9c9f96;
  font-size: 7px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.moment-filters select {
  width: 100%;
  padding: 8px 26px 8px 9px;
  border: 1px solid var(--line);
  border-radius: 8px;
  outline: 0;
  color: #6f736b;
  background: #faf8f2;
  font-family: var(--serif);
  font-size: 10px;
}

.clear-filters {
  margin-bottom: 2px;
  padding: 8px 5px;
  border: 0;
  color: #9a7969;
  background: transparent;
  font-size: 8px;
  cursor: pointer;
}

.moments-results-heading {
  display: flex;
  justify-content: space-between;
  margin: 29px 2px 11px;
  color: #9b9e95;
  font-size: 8px;
  letter-spacing: 0.07em;
  text-transform: uppercase;
}

.all-moments-list {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}

.all-moment-card {
  min-height: 168px;
  padding: 20px;
  overflow: hidden;
  border: 1px solid rgba(75, 78, 69, 0.09);
  border-radius: 13px;
  color: var(--ink);
  background: rgba(255, 253, 248, 0.7);
  text-align: left;
  cursor: pointer;
  transition: 180ms ease;
}

.all-moment-card:nth-child(3n + 2) {
  background: rgba(239, 225, 215, 0.42);
}

.all-moment-card:nth-child(3n + 3) {
  background: rgba(224, 230, 216, 0.45);
}

.all-moment-card:hover {
  border-color: rgba(102, 119, 93, 0.18);
  box-shadow: 0 12px 34px rgba(65, 62, 54, 0.055);
  transform: translateY(-2px);
}

.all-moment-card-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 13px;
  color: #6f756c;
  font-size: 10px;
  letter-spacing: 0.05em;
  text-transform: uppercase;
}

.all-moment-card h2 {
  margin: -3px 0 7px;
  font-family: var(--serif);
  font-size: 15px;
  font-weight: 400;
}

.all-moment-card > p {
  display: -webkit-box;
  margin: 0;
  overflow: hidden;
  color: #62675f;
  font-family: var(--serif);
  font-size: 12px;
  line-height: 1.5;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 3;
}

.all-moment-labels {
  display: flex;
  flex-wrap: wrap;
  gap: 5px;
  margin-top: 16px;
}

.all-moment-labels span {
  padding: 4px 7px;
  border-radius: 20px;
  color: #7a8174;
  background: rgba(223, 230, 217, 0.72);
  font-size: 7px;
}

.moments-empty {
  padding: 72px 20px;
  text-align: center;
}

.empty-symbol {
  display: grid;
  width: 45px;
  height: 45px;
  margin: 0 auto 17px;
  place-items: center;
  border-radius: 50%;
  color: #829079;
  background: var(--sage-pale);
  font-family: var(--serif);
  font-size: 21px;
}

.moments-empty h2 {
  margin-bottom: 7px;
  font-family: var(--serif);
  font-size: 20px;
  font-weight: 400;
}

.moments-empty p {
  max-width: 390px;
  margin: 0 auto 17px;
  color: #92958c;
  font-family: var(--serif);
  font-size: 12px;
  font-style: italic;
  line-height: 1.5;
}

dialog {
  width: min(590px, calc(100vw - 32px));
  padding: 0;
  border: 0;
  border-radius: 18px;
  color: var(--ink);
  background: var(--white);
  box-shadow: 0 30px 100px rgba(45, 47, 41, 0.22);
}

dialog::backdrop {
  background: rgba(47, 51, 45, 0.3);
  backdrop-filter: blur(6px);
}

.dialog-card {
  padding: 30px;
}

.utility-dialog {
  width: min(500px, calc(100vw - 32px));
}

.daily-check-in-dialog {
  width: min(620px, calc(100vw - 32px));
  max-height: min(90vh, 850px);
}

.daily-check-in-card {
  max-height: min(90vh, 850px);
  padding: 31px;
  overflow-y: auto;
}

.daily-check-in-card .dialog-top h2 {
  margin-bottom: 4px;
}

.daily-check-in-card .dialog-top p {
  margin: 0;
  color: #92958c;
  font-family: var(--serif);
  font-size: 10px;
  font-style: italic;
}

.daily-prompt-list {
  display: grid;
  gap: 15px;
  margin-top: 25px;
}

.daily-prompt-list label > span {
  display: block;
  margin: 0 0 6px 2px;
  color: #62675f;
  font-family: var(--serif);
  font-size: 12px;
}

.daily-prompt-list input {
  width: 100%;
  padding: 11px 12px;
  border: 1px solid var(--line);
  border-radius: 9px;
  outline: 0;
  color: var(--ink);
  background: #faf8f2;
  font-family: var(--serif);
  font-size: 12px;
}

.daily-prompt-list input:focus {
  border-color: rgba(161, 119, 101, 0.28);
  box-shadow: 0 0 0 3px rgba(184, 121, 93, 0.06);
}

.daily-prompt-list input::placeholder {
  color: #aaaca4;
  font-style: italic;
}

.daily-check-in-card .dialog-actions {
  margin-top: 27px;
}

.utility-card {
  padding: 30px;
}

.moment-dialog {
  width: min(650px, calc(100vw - 32px));
  max-height: min(88vh, 820px);
}

.thread-detail-description {
  margin: 27px 0 8px;
  color: #555c53;
  font-family: var(--serif);
  font-size: 15px;
  font-style: italic;
  line-height: 1.55;
}

.thread-linked-heading {
  display: flex;
  align-items: end;
  justify-content: space-between;
  margin: 30px 0 11px;
  padding-top: 20px;
  border-top: 1px solid var(--line);
}

.thread-linked-heading h3 {
  margin: 5px 0 0;
  font-family: var(--serif);
  font-size: 17px;
  font-weight: 400;
}

.thread-linked-list {
  display: grid;
}

.thread-linked-row {
  display: grid;
  grid-template-columns: 1fr auto;
  align-items: center;
  gap: 10px;
  padding: 12px 0;
  border-bottom: 1px solid var(--line);
}

.thread-linked-open {
  padding: 0;
  overflow: hidden;
  border: 0;
  color: inherit;
  background: transparent;
  text-align: left;
  cursor: pointer;
}

.thread-linked-open strong,
.thread-linked-open small {
  display: block;
}

.thread-linked-open strong {
  overflow: hidden;
  font-family: var(--serif);
  font-size: 12px;
  font-weight: 400;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.thread-linked-open small {
  margin-top: 4px;
  color: #9a9d94;
  font-size: 8px;
}

.thread-unlink-button {
  padding: 6px;
  border: 0;
  color: #a07b6a;
  background: transparent;
  font-size: 8px;
  cursor: pointer;
}

.thread-linked-empty {
  margin: 0;
  padding: 20px;
  border-radius: 10px;
  color: #92958c;
  background: rgba(224, 230, 216, 0.35);
  font-family: var(--serif);
  font-size: 11px;
  font-style: italic;
  text-align: center;
}

.thread-editor-dialog {
  width: min(680px, calc(100vw - 32px));
  max-height: min(92vh, 900px);
}

.thread-editor-card {
  max-height: min(92vh, 900px);
  padding: 31px;
  overflow-y: auto;
}

.thread-editor-card .dialog-top {
  margin-bottom: 26px;
}

.thread-editor-card .dialog-top p {
  margin: 4px 0 0;
  color: #969990;
  font-family: var(--serif);
  font-size: 10px;
  font-style: italic;
}

.thread-editor-meta {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 11px;
}

.thread-moment-picker {
  margin-top: 5px;
  padding-top: 20px;
  border-top: 1px solid var(--line);
}

.thread-moment-picker > div:first-child p {
  margin: 5px 0 13px;
  color: #989b92;
  font-family: var(--serif);
  font-size: 10px;
  font-style: italic;
}

.compact-search {
  padding: 10px 12px;
  border: 1px solid var(--line);
  border-radius: 9px;
  background: #faf8f2;
}

.compact-search input {
  font-size: 12px;
}

.thread-moment-options {
  display: grid;
  max-height: 245px;
  margin-top: 10px;
  overflow-y: auto;
  border-block: 1px solid var(--line);
}

.thread-moment-option {
  position: relative;
  display: block;
  cursor: pointer;
}

.thread-moment-option input {
  position: absolute;
  width: 1px;
  height: 1px;
  opacity: 0;
}

.thread-moment-option > span {
  display: block;
  padding: 12px 34px 12px 10px;
  border-bottom: 1px solid var(--line);
  transition: 140ms ease;
}

.thread-moment-option > span::after {
  position: absolute;
  top: 50%;
  right: 11px;
  display: grid;
  width: 19px;
  height: 19px;
  place-items: center;
  border: 1px solid rgba(102, 119, 93, 0.22);
  border-radius: 50%;
  color: white;
  content: "";
  transform: translateY(-50%);
}

.thread-moment-option input:checked + span {
  background: rgba(223, 230, 217, 0.48);
}

.thread-moment-option input:checked + span::after {
  background: #7f8f76;
  content: "✓";
  font-size: 10px;
}

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

.thread-moment-option strong {
  overflow: hidden;
  font-family: var(--serif);
  font-size: 11px;
  font-weight: 400;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.thread-moment-option small {
  margin-top: 3px;
  color: #9b9e95;
  font-size: 8px;
}

.thread-picker-empty {
  padding: 18px;
  color: #969990;
  font-family: var(--serif);
  font-size: 10px;
  font-style: italic;
  text-align: center;
}

.moment-card {
  max-height: min(88vh, 820px);
  padding: 31px;
  overflow-y: auto;
}

.moment-full-text {
  margin: 30px 0;
  color: #3a3f38;
  font-family: var(--serif);
  font-size: 19px;
  line-height: 1.6;
  white-space: pre-wrap;
}

.moment-metadata {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 10px;
  padding: 15px 0;
  border-block: 1px solid var(--line);
}

.moment-metadata small,
.moment-label-group > small {
  display: block;
  margin-bottom: 5px;
  color: #a0a299;
  font-size: 8px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.moment-metadata span {
  color: #6f746b;
  font-family: var(--serif);
  font-size: 11px;
}

.moment-label-group {
  margin-top: 18px;
}

.moment-labels {
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
}

.moment-label {
  padding: 6px 10px;
  border-radius: 20px;
  color: #667360;
  background: var(--sage-pale);
  font-size: 9px;
}

.moment-labels.tags .moment-label {
  color: #886c5e;
  background: var(--clay-pale);
}

.moment-view-actions {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-top: 28px;
}

.delete-text-button {
  padding: 7px 0;
  border: 0;
  color: #a27d6c;
  background: transparent;
  font-size: 9px;
  cursor: pointer;
}

.delete-confirmation {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  margin-top: 22px;
  padding: 15px;
  border: 1px solid rgba(165, 105, 84, 0.14);
  border-radius: 11px;
  background: rgba(239, 225, 215, 0.55);
}

.delete-confirmation strong {
  font-family: var(--serif);
  font-size: 12px;
  font-weight: 400;
}

.delete-confirmation p {
  margin: 3px 0 0;
  color: #97877e;
  font-size: 9px;
}

.delete-confirmation > div:last-child {
  display: flex;
  align-items: center;
  gap: 8px;
  flex: 0 0 auto;
}

.delete-button {
  padding: 8px 11px;
  border: 0;
  border-radius: 7px;
  color: white;
  background: #ad765f;
  font-size: 9px;
  cursor: pointer;
}

#momentEditForm {
  margin-top: 26px;
}

.edit-field {
  display: block;
  margin-bottom: 19px;
}

.edit-field > span,
.context-picker legend {
  display: block;
  margin-bottom: 7px;
  color: #6f736b;
  font-family: var(--serif);
  font-size: 12px;
}

.edit-field > span small,
.context-picker legend small {
  color: #a3a59d;
  font-family: var(--sans);
  font-size: 8px;
  font-style: italic;
}

.edit-field input,
.edit-field textarea {
  width: 100%;
  padding: 12px 13px;
  resize: vertical;
  border: 1px solid var(--line);
  border-radius: 9px;
  outline: 0;
  color: var(--ink);
  background: #faf8f2;
  font-family: var(--serif);
  font-size: 13px;
  line-height: 1.5;
}

.edit-field input:focus,
.edit-field textarea:focus {
  border-color: rgba(105, 124, 96, 0.35);
  box-shadow: 0 0 0 3px rgba(126, 145, 117, 0.07);
}

.edit-field > small {
  display: block;
  margin-top: 5px;
  color: #a2a49c;
  font-size: 8px;
}

.context-picker {
  margin: 0 0 20px;
  padding: 0;
  border: 0;
}

.context-picker p {
  margin: -3px 0 10px;
  color: #a0a39a;
  font-size: 9px;
}

.context-options {
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
}

.context-options label {
  cursor: pointer;
}

.context-options input {
  position: absolute;
  width: 1px;
  height: 1px;
  opacity: 0;
}

.context-options span {
  display: block;
  padding: 7px 10px;
  border: 1px solid var(--line);
  border-radius: 20px;
  color: #888b82;
  background: transparent;
  font-size: 9px;
  transition: 150ms ease;
}

.context-options input:checked + span {
  color: #62705b;
  border-color: rgba(102, 119, 93, 0.21);
  background: var(--sage-pale);
}

.context-options input:focus-visible + span {
  outline: 2px solid rgba(102, 119, 93, 0.35);
  outline-offset: 2px;
}

.utility-card h2 {
  margin: 6px 0 0;
  font-family: var(--serif);
  font-size: 24px;
  font-weight: 400;
}

.storage-status {
  display: flex;
  align-items: center;
  gap: 13px;
  margin-top: 26px;
  padding: 16px;
  border: 1px solid rgba(102, 119, 93, 0.14);
  border-radius: 12px;
  background: rgba(223, 230, 217, 0.45);
}

.status-dot {
  width: 9px;
  height: 9px;
  flex: 0 0 9px;
  border-radius: 50%;
  background: #7e9175;
  box-shadow: 0 0 0 5px rgba(126, 145, 117, 0.1);
}

.status-dot.fallback {
  background: var(--gold);
  box-shadow: 0 0 0 5px rgba(193, 163, 110, 0.1);
}

.storage-status strong {
  display: block;
  font-family: var(--serif);
  font-size: 13px;
  font-weight: 400;
}

.storage-status p {
  margin: 3px 0 0;
  color: #92968c;
  font-size: 9px;
}

.backup-actions {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
  margin-top: 13px;
}

.backup-action {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 11px;
  color: var(--ink);
  background: rgba(250, 248, 242, 0.72);
  text-align: left;
  cursor: pointer;
  transition: 180ms ease;
}

.backup-action:hover {
  border-color: rgba(102, 119, 93, 0.22);
  background: var(--white);
  transform: translateY(-1px);
}

.backup-icon {
  display: grid;
  width: 29px;
  height: 29px;
  flex: 0 0 29px;
  place-items: center;
  border-radius: 50%;
  color: #718069;
  background: var(--sage-pale);
}

.backup-action strong,
.backup-action small {
  display: block;
}

.backup-action strong {
  font-family: var(--serif);
  font-size: 12px;
  font-weight: 400;
}

.backup-action small {
  margin-top: 2px;
  color: #999c93;
  font-size: 8px;
}

.storage-footnote {
  margin: 17px 0 0;
  color: #999b93;
  font-family: var(--serif);
  font-size: 10px;
  font-style: italic;
  text-align: center;
}

.backup-report {
  margin-top: 16px;
  padding: 14px 15px;
  border: 1px solid rgba(102, 119, 93, 0.15);
  border-radius: 10px;
  background: rgba(223, 230, 217, 0.42);
}

.backup-report.error {
  border-color: rgba(173, 118, 95, 0.16);
  background: rgba(239, 225, 215, 0.5);
}

.backup-report > strong {
  display: block;
  margin-bottom: 7px;
  font-family: var(--serif);
  font-size: 12px;
  font-weight: 400;
}

.backup-report p {
  margin: 3px 0;
  color: #858980;
  font-size: 8px;
  line-height: 1.45;
}

.storage-empty {
  color: #8d9187;
  font-family: var(--serif);
  font-size: 12px;
  font-style: italic;
}

.dialog-top {
  display: flex;
  justify-content: space-between;
}

.dialog-top h2 {
  margin: 6px 0 0;
  font-family: var(--serif);
  font-size: 24px;
  font-weight: 400;
}

.dialog-card textarea {
  margin: 24px 0 16px;
  padding: 18px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: #faf8f2;
  font-size: 15px;
}

.voice-capture {
  display: flex;
  width: 100%;
  align-items: center;
  gap: 12px;
  padding: 13px 15px;
  border: 1px solid rgba(102, 119, 93, 0.18);
  border-radius: 11px;
  color: #65715e;
  background: rgba(223, 230, 217, 0.46);
  text-align: left;
  cursor: pointer;
  transition: 180ms ease;
}

.voice-capture:hover {
  background: rgba(223, 230, 217, 0.78);
  transform: translateY(-1px);
}

.voice-orb {
  display: grid;
  width: 34px;
  height: 34px;
  flex: 0 0 34px;
  place-items: center;
  border-radius: 50%;
  color: #fff;
  background: #7b8a72;
  font-size: 17px;
  transition: 180ms ease;
}

.voice-capture strong,
.voice-capture small {
  display: block;
}

.voice-capture strong {
  font-family: var(--serif);
  font-size: 13px;
  font-weight: 400;
}

.voice-capture small {
  margin-top: 2px;
  color: #959b90;
  font-size: 9px;
}

.voice-capture.listening {
  border-color: rgba(169, 104, 77, 0.25);
  color: #90634f;
  background: var(--clay-pale);
}

.voice-capture.listening .voice-orb {
  background: var(--clay);
  box-shadow: 0 0 0 7px rgba(184, 121, 93, 0.11);
  animation: listen-pulse 1.6s ease-in-out infinite;
}

@keyframes listen-pulse {
  50% {
    box-shadow: 0 0 0 11px rgba(184, 121, 93, 0.04);
  }
}

.dialog-actions {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-top: 25px;
}

.dialog-actions span {
  color: #9b9e95;
  font-family: var(--serif);
  font-size: 11px;
  font-style: italic;
}

.primary-button {
  padding: 10px 19px;
  border: 0;
  border-radius: 8px;
  color: white;
  background: #7b8a72;
  font-size: 10px;
  cursor: pointer;
}

.toast {
  position: fixed;
  right: 28px;
  bottom: 28px;
  z-index: 20;
  padding: 12px 17px;
  border-radius: 9px;
  color: white;
  background: #4f5b49;
  font-size: 11px;
  opacity: 0;
  transform: translateY(10px);
  transition: 200ms ease;
  pointer-events: none;
}

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

@media (max-width: 1000px) {
  .sidebar {
    width: 190px;
    padding-inline: 18px;
  }

  main {
    margin-left: 190px;
    padding-inline: 4vw;
  }

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

  .right-column {
    display: grid;
    grid-template-columns: 0.8fr 1.2fr;
    gap: 35px;
  }

  .daily-reflection-invite {
    margin-top: 0;
  }

  .vibe-check,
  .gentle-nudges {
    grid-column: 1 / -1;
  }

  .recently-gathered {
    grid-column: 1 / -1;
  }
}

@media (max-width: 720px) {
  .sidebar {
    position: fixed;
    inset: auto 12px 12px;
    width: auto;
    height: 62px;
    flex-direction: row;
    align-items: center;
    justify-content: center;
    padding: 8px;
    border: 1px solid var(--line);
    border-radius: 16px;
    box-shadow: 0 12px 40px rgba(50, 52, 46, 0.13);
  }

  .brand,
  .space-toggle,
  .sidebar-foot,
  .nav-link span:last-child {
    display: none;
  }

  .nav {
    display: flex;
    width: 100%;
    justify-content: space-around;
  }

  .nav-link {
    padding: 10px 18px;
  }

  .quiet-button {
    display: grid;
    width: 46px;
    height: 46px;
    flex: 0 0 46px;
    margin: 0 4px 0 0;
    padding: 0;
    place-items: center;
    border-radius: 13px;
    font-size: 0;
  }

  .quiet-button span {
    font-size: 20px;
  }

  main {
    margin: 0;
    padding: 0 21px 110px;
  }

  .topbar {
    height: 65px;
  }

  .search-button {
    width: auto;
  }

  .search-button kbd,
  .search-button:not(:focus) {
    font-size: 0;
  }

  .search-button span {
    font-size: 18px;
  }

  .hero {
    padding: 48px 0 42px;
  }

  .content-grid,
  .right-column {
    display: block;
  }

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

  .thread-card {
    grid-template-columns: 35px 1fr;
    padding: 16px;
  }

  .thread-card .arrow {
    display: none;
  }

  .dialog-actions span {
    display: none;
  }

  .all-moments-view {
    padding-top: 38px;
  }

  .threads-view {
    padding-top: 38px;
  }

  .moments-title-row {
    align-items: flex-start;
    flex-direction: column;
  }

  .quiet-button.page-capture {
    display: flex;
    width: auto;
    height: auto;
    flex-basis: auto;
    padding: 10px 14px;
    font-size: 10px;
  }

  .quiet-button.page-capture span {
    font-size: 15px;
  }
  .moment-filters {
    display: grid;
    grid-template-columns: 1fr 1fr;
  }

  .all-moments-list {
    grid-template-columns: 1fr;
  }

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

  .moment-card {
    padding: 24px 20px;
  }

  .thread-editor-card {
    padding: 25px 20px;
  }

  .thread-editor-meta {
    grid-template-columns: 1fr;
  }

  .daily-check-in-card {
    padding: 25px 20px;
  }

  .moment-metadata {
    grid-template-columns: 1fr;
  }

  .delete-confirmation {
    align-items: flex-start;
    flex-direction: column;
  }
}

.visually-hidden {
  position: absolute !important;
  width: 1px !important;
  height: 1px !important;
  padding: 0 !important;
  overflow: hidden !important;
  clip: rect(0, 0, 0, 0) !important;
  white-space: nowrap !important;
  border: 0 !important;
}

:where(
  a,
  button,
  input,
  textarea,
  select,
  [tabindex]
):focus-visible {
  outline: 3px solid rgba(126, 84, 105, 0.58);
  outline-offset: 3px;
}

.visually-hidden:focus-visible + *,
.backup-action:focus-visible {
  outline: 3px solid rgba(126, 84, 105, 0.58);
  outline-offset: 3px;
}

.moment-full-text,
.all-moment-card > p,
.thread-detail-description,
.moment-label,
.all-moment-labels span,
.backup-report p,
.thread-linked-open strong {
  overflow-wrap: anywhere;
}

.moment-metadata small,
.moment-label-group > small,
.moment-filters label > span,
.moments-results-heading,
.storage-status p,
.backup-action small,
.backup-report p,
.thread-linked-open small,
.thread-moment-option small {
  color: #6f756c;
  font-size: 10px;
}

.text-button,
.shuffle-button,
.delete-text-button,
.clear-filters,
.thread-unlink-button {
  font-size: 11px;
}

.moment-card,
.thread-editor-card,
.daily-check-in-card,
.thread-moment-options {
  -webkit-overflow-scrolling: touch;
}

@media (pointer: coarse) {
  .nav-link,
  .quiet-button,
  .search-button,
  .primary-button,
  .text-button,
  .shuffle-button,
  .back-button,
  .delete-text-button,
  .delete-button,
  .clear-filters,
  .thread-unlink-button,
  .backup-action,
  .voice-capture {
    min-height: 44px;
  }

  .icon-button,
  .avatar {
    width: 44px;
    height: 44px;
    min-width: 44px;
  }

  input:not([type="checkbox"]):not([type="file"]),
  textarea,
  select {
    min-height: 44px;
  }

  .context-options span {
    display: flex;
    min-height: 44px;
    align-items: center;
  }

  .thread-moment-option > span {
    min-height: 58px;
  }
}

@media (max-width: 720px) {
  .sidebar {
    bottom: calc(12px + env(safe-area-inset-bottom, 0px));
  }

  main {
    padding-bottom: calc(110px + env(safe-area-inset-bottom, 0px));
  }

  dialog,
  .moment-dialog,
  .thread-editor-dialog,
  .daily-check-in-dialog {
    max-height: calc(100dvh - 24px);
  }

  input:not([type="checkbox"]):not([type="file"]),
  textarea,
  select {
    font-size: 16px;
  }

  .moment-filters {
    grid-template-columns: 1fr;
  }

  .moments-controls,
  .moment-card,
  .thread-editor-card,
  .daily-check-in-card,
  .utility-card {
    padding-inline: 18px;
  }
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  *,
  *::before,
  *::after {
    scroll-behavior: auto !important;
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
}

@media (prefers-contrast: more) {
  :root {
    --ink: #20251f;
    --muted: #555c53;
    --line: rgba(45, 50, 43, 0.28);
  }
}

::placeholder {
  color: #747a72;
  opacity: 1;
}

.date,
.checkin-banner p,
.thread-card p,
.storage-footnote,
.season-card small {
  color: #686f66;
}

.text-button,
.shuffle-button {
  color: #676d65;
}

.thread-moment-option input:focus-visible + span {
  outline: 3px solid var(--mauve);
  outline-offset: -3px;
}

@media (pointer: coarse) {
  .thread-linked-open {
    min-height: 44px;
  }
}
