:root {
  --bg: #eef3f8;
  --panel: #ffffff;
  --panel-soft: #f7fafe;
  --text: #17324d;
  --muted: #5f7386;
  --line: #cfdbe7;
  --shadow: 0 8px 22px rgba(23, 50, 77, 0.08);
  --radius-lg: 18px;
  --radius-md: 12px;
  --nav: #17324d;
  --nav-text: #ffffff;
  --practice-soft: #f7fbf2;
  --practice-line: #cfe3d0;
  --max-width: 420px;
  --nav-offset: 132px;
  --danger: #ce3a20;
  --danger-soft: #fff4f2;
  --danger-line: #efb1a8;
  --accent: #1f72bf;
  --accent-2: #24996c;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  background: linear-gradient(to bottom, #eaf1f7 0%, #f4f7fb 100%);
  font-family: Arial, Helvetica, sans-serif;
  color: var(--text);
}

button,
textarea,
input {
  font: inherit;
}

a {
  text-decoration: none;
}
.report-text p {
  margin: 0 0 10px;
}

.report-text p:last-child {
  margin-bottom: 0;
}

.report-text {
  font-weight: 400;
  color: #17324d;
}

.report-text * {
  font-weight: 400;
}

.report-text .report-section-header {
  margin-top: 6px;
  margin-bottom: 6px;
  font-weight: 700;
  color: #1f72bf;
}

.report-collapsible > .report-section-header:first-of-type {
  margin-top: 22px;
}
.report-text p {
  font-weight: 400 !important;
}
.app-shell {
  width: 100%;
  max-width: var(--max-width);
  margin: 0 auto;
  min-height: 100vh;
  padding: 12px 8px 28px;
}

/* ---------- Auth ---------- */

.auth-shell {
  max-width: 460px;
  margin: 40px auto 28px auto;
  padding: 24px 16px 40px;
}

.auth-brand {
  text-align: center;
  margin-bottom: 24px;
  padding-top: 8px;
}

.act-logo {
  display: inline-block;
  font-size: 42px;
  font-weight: 900;
  letter-spacing: 10px;
  line-height: 1;
  text-transform: uppercase;
  background: linear-gradient(180deg, #17324d 0%, #35526b 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  border-bottom: 2px solid rgba(23, 50, 77, 0.12);
  padding: 6px 14px 10px;
}

.auth-name {
  margin-top: 12px;
  font-size: 20px;
  font-weight: 600;
  color: #4b647a;
  letter-spacing: 0.5px;
}

.auth-tagline {
  margin: 14px auto 0;
  max-width: 340px;
  font-size: 15px;
  line-height: 1.6;
  color: #5f7386;
}

.auth-card {
  background: #ffffff;
  border: 1px solid #d7e3ee;
  border-radius: 18px;
  box-shadow: 0 8px 24px rgba(23, 50, 77, 0.08);
  padding: 24px 20px;
}

.auth-title {
  margin: 0 0 8px 0;
  font-size: 28px;
  color: #17324d;
  text-align: center;
}

.auth-subtitle {
  margin: 0 0 20px 0;
  text-align: center;
  color: #5f7386;
  font-size: 15px;
}

.auth-form {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.auth-form label {
  font-size: 14px;
  font-weight: 600;
  color: #35526b;
  margin-top: 4px;
}

.auth-form input {
  width: 100%;
  padding: 12px 14px;
  border: 1px solid #c9d8e6;
  border-radius: 12px;
  font-size: 15px;
  background: #f9fbfd;
  color: #17324d;
}

.auth-form input:focus {
  outline: none;
  border-color: #0f6cbd;
  background: #ffffff;
  box-shadow: 0 0 0 3px rgba(15, 108, 189, 0.12);
}

.auth-btn {
  margin-top: 14px;
  padding: 13px 16px;
  border: none;
  border-radius: 12px;
  background: #17324d;
  color: #ffffff;
  font-size: 15px;
  font-weight: 700;
  cursor: pointer;
}

.auth-note {
  text-align: center;
  font-size: 14px;
  color: #5f7386;
  margin: 16px 0 0 0;
}

.auth-switch {
  margin-top: 18px;
  text-align: center;
  font-size: 14px;
  color: #5f7386;
}

.auth-link-btn {
  background: none;
  border: none;
  color: #0f6cbd;
  font-size: 14px;
  font-weight: 700;
  cursor: pointer;
  margin-left: 6px;
  padding: 0;
}

.auth-link-btn:hover {
  text-decoration: underline;
}

/* ---------- Header / Nav ---------- */

.sticky-top-shell {
  position: fixed;
  top: 0;
  left: 8px;
  right: 8px;
  width: auto;
  max-width: calc(var(--max-width) - 16px);
  margin: 0 auto;
  z-index: 10000;
  isolation: isolate;
  background: linear-gradient(to bottom, #edf3f8 0%, #e9eff5 100%);
  padding: 4px 10px 6px;
  border-bottom: 1px solid #d8e1ea;
}

.app-header {
  padding: 0 0 4px;
  margin: 0;
  background: transparent;
}
.app-brand {
  background: #fff4c7;
  border: 1px solid #f1d98a;
  border-radius: 18px;
  box-shadow: none;
  padding: 8px 12px;
  transition: background 0.35s ease, border-color 0.35s ease, box-shadow 0.35s ease, color 0.35s ease;
}

.app-brand-compact {
  padding: 0;
}

.app-brand-row {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0;
  padding: 0;
  margin: 0;
}
.app-title {
  display: inline;
  margin: 0 8px 0 0;
  font-size: 16px;
  line-height: 1.2;
  font-weight: 700;
  vertical-align: middle;
  transition: color 0.35s ease;
}

.app-live-stats {
  display: block;
  width: 100%;
  min-width: 0;
  margin: 0;
  padding: 8px 8px 7px;
  background: #fff4cc;
  border: 1px solid rgba(0, 0, 0, 0.08);
  border-radius: 18px;
  box-shadow: inset 0 1px 0 rgba(255,255,255,0.35);
}

.top-stats-grid {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 4px;
  align-items: stretch;
}

.top-stat-block {
  min-width: 0;
  padding: 4px 3px 3px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 2px;
  text-align: center;
}

.top-stat-label {
  display: block;
  font-size: 10px;
  line-height: 1.05;
  font-weight: 700;
  letter-spacing: 0.01em;
  opacity: 0.95;
  white-space: nowrap;
  color: #6b5a00;
}

.top-stat-value {
  display: block;
  min-width: 0;
  font-size: 14px;
  line-height: 1.1;
  font-weight: 800;
  white-space: nowrap;
  color: #1f2937;
}
.top-stat-value-positive {
  color: #15803d;
}

.top-stat-value-debt {
  color: #b91c1c;
}

@media (max-width: 420px) {
  .top-stats-grid {
    gap: 3px;
  }

 .top-stat-block {
  padding: 4px 2px 3px;
  gap: 3px;
}

.top-stat-label {
  font-size: 9px;
  line-height: 1.05;
  color: #7a6500;
}

  .top-stat-value {
    font-size: 12px;
  }
}
}

.top-save-confirmation {
  display: inline-block;
  min-height: 18px;
  margin-left: 8px;
  font-size: 12px;
  font-weight: 700;
  color: #1b8c52;
  opacity: 0;
  transform: translateY(-2px);
  transition: opacity 0.2s ease, transform 0.2s ease, color 0.35s ease;
  white-space: nowrap;
  vertical-align: middle;
}

.top-save-confirmation.is-visible {
  opacity: 1;
  transform: translateY(0);
}

.top-nav {
  position: static;
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 6px;
  padding: 0;
  margin: 0;
  background: transparent;
  border-radius: 0;
}
.top-score-brand {
  font-size: 13px;
  font-weight: 800;
  color: #ffffff;
  letter-spacing: 0.4px;
  margin-right: 2px;
}

.top-score-chip {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 20px;
  padding: 2px 8px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.14);
  color: #ffffff;
  font-size: 11px;
  font-weight: 700;
  line-height: 1;
  white-space: nowrap;
  flex: 0 0 auto;
}
.top-score-chip.positive {
  background: rgba(47, 143, 91, 0.28);
}

.top-score-chip.debt {
  background: rgba(220, 38, 38, 0.22);
}

.top-score-chip.zone {
  background: rgba(255, 255, 255, 0.18);
  font-weight: 800;
}
.top-score-row {
  display: flex;
  align-items: center;
  justify-content: center;
  flex-wrap: nowrap;
  gap: 4px;
  overflow-x: auto;
  scrollbar-width: none;
  min-height: 26px;
}

.top-score-chip-inline {
  margin-left: 0;
}
.nav-tab {
  border: 1px solid #2f6fa3;
  background: #2f6fa3;
  color: #ffffff;
  border-radius: 10px;
  min-height: 42px;
  padding: 8px 4px;
  font-size: 12px;
  font-weight: 700;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.15);
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background 0.2s ease, transform 0.2s ease, box-shadow 0.2s ease, border-color 0.2s ease;
}

.nav-tab:hover {
  background: #3f82b8;
  border-color: #3f82b8;
  transform: translateY(-1px);
}

.nav-tab.is-active {
  background: #2f8f5b;
  border-color: #2f8f5b;
  box-shadow: 0 0 0 2px rgba(47, 143, 91, 0.18), 0 4px 10px rgba(0, 0, 0, 0.16);
  transform: translateY(-1px) scale(1.02);
}
:root {
  --card-gap: 6px;
}

.app-main {
  display: flex;
  flex-direction: column;
  gap: var(--card-gap);
  padding-top: 92px;
}
.app-section {
  display: flex;
  flex-direction: column;
  gap: var(--card-gap);
}

/* ---------- General cards ---------- */

.section-card,
.home-card,
.card {
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow);
  padding: 14px 14px 12px;
}

.section-card-tight {
  padding-bottom: 10px;
}

.section-label,
.card-label {
  margin: 0 0 10px;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: #5a7392;
}

.card-kicker{
  margin:0 0 8px;
  font-size:11px;
  font-weight:700;
  letter-spacing:0.12em;
  text-transform:uppercase;
  color:#5a7392;
  line-height:1.2;
}

.home-scene-kicker.card-kicker{
  color:#f4f8fb;
}
.scene-transition {
  transition: all 0.8s ease;
}
.section-title,
.card-title {
  margin: 0 0 6px;
  font-size: 18px;
  line-height: 1.18;
  font-weight: 700;
}

.card-title-small,
.inner-card-title,
.zone-title {
  margin: 0 0 8px;
  font-size: 15px;
  line-height: 1.3;
  font-weight: 700;
}

.section-text,
.card-text,
.section-sub,
.act-subtext,
.zone-text,
.rules-item,
.profile-line,
.profile-support {
  margin: 0;
  font-size: 14px;
  line-height: 1.5;
  color: var(--muted);
}

.card-value {
  margin: 0 0 8px;
  font-size: 16px;
  font-weight: 700;
}

.card-highlight {
  margin: 0;
  font-size: 17px;
  line-height: 1.25;
  font-weight: 700;
  color: #24496b;
}

/* ---------- Log section ---------- */

.log-group {
  margin-top: 16px;
}

.compact-group {
  margin-top: 10px;
}

.entry-type-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
}

.entry-type-card {
  min-height: 54px;
  border-radius: 14px;
  border: 1px solid var(--line);
  background: #ffffff;
  color: var(--text);
  font-size: 14px;
  font-weight: 700;
  cursor: pointer;
  transition: 0.18s ease;
}

.entry-type-card:hover {
  transform: translateY(-1px);
}

.entry-type-card.is-active {
  background: linear-gradient(to right, #1f8a5f 0%, #28a86f 100%);
  color: #ffffff;
  border-color: #28a86f;
}

.entry-type-card.debt.is-active {
  background: var(--danger);
  border-color: var(--danger);
}

.entry-type-card.practice {
  border-color: var(--practice-line);
}

.entry-type-card.practice.is-active {
  background: #f3fbef;
  color: #0e6e50;
  border-color: var(--practice-line);
}

.entry-type-card.note.is-active {
  background: #f8fbff;
  color: var(--text);
  border-color: var(--line);
}

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

.entry-title-columns {
  display: block;
}

.entry-columns-wrap {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr) minmax(0, 1.08fr);
  gap: 6px;
}

.entry-column {
  border-radius: 18px;
  padding: 9px;
  border: 1px solid rgba(255, 255, 255, 0.55);
  box-shadow: 0 6px 18px rgba(24, 39, 75, 0.06);
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.entry-column-label {
  margin: 0 0 2px;
  padding-left: 0;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: #5a7392;
  white-space: nowrap;
  text-align: center;
}

.entry-column-recovery {
  background: linear-gradient(180deg, #eef7ff 0%, #f7fbff 100%);
}

.entry-column-movement {
  background: linear-gradient(180deg, #eefbf3 0%, #f8fdf9 100%);
}

.entry-column-mind {
  background: linear-gradient(180deg, #fff8ea 0%, #fffdf7 100%);
}

.debt-column-recovery {
  background: linear-gradient(180deg, #fff1f1 0%, #fff8f8 100%);
}

.debt-column-movement {
  background: linear-gradient(180deg, #fff5ea 0%, #fffaf5 100%);
}

.debt-column-mind {
  background: linear-gradient(180deg, #f8f1f7 0%, #fcf8fc 100%);
}

.entry-category-btn {
  width: 100%;
  min-height: 50px;
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 6px 8px;
  text-align: center;
  font-size: 11px;
  line-height: 1.2;
  font-weight: 700;
  letter-spacing: 0;
  color: var(--text);
  background: rgba(255, 255, 255, 0.86);
  cursor: pointer;
  transition: transform 0.14s ease, box-shadow 0.14s ease, background 0.14s ease, border-color 0.14s ease;
  box-shadow: 0 2px 8px rgba(24, 39, 75, 0.06);

  white-space: nowrap;
  overflow: visible;
  text-overflow: unset;
  word-break: normal;
  overflow-wrap: normal;
  hyphens: none;
  display: flex;
  align-items: center;
  justify-content: center;
}
.entry-category-btn:hover {
  transform: translateY(-1px);
  box-shadow: 0 6px 14px rgba(24, 39, 75, 0.10);
}

.entry-category-btn.is-active {
  background: linear-gradient(to right, #1f8a5f 0%, #28a86f 100%);
  color: #ffffff;
  border-color: #28a86f;
}
.debt-btn {
  color: #6a2330;
}

.debt-btn.is-active {
  background: linear-gradient(to right, #c43d2a 0%, #de5a47 100%);
  color: #ffffff;
  border-color: #de5a47;
}

.selection-sub-chip {
  min-height: 44px;
}

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

.sub-grid-wrap {
  border: 1px solid #d9e5df;
  background: #f8fcf8;
  border-radius: 16px;
  padding: 10px;
}

.selection-chip {
  min-height: 48px;
  border-radius: 12px;
  border: 1px solid var(--line);
  background: #ffffff;
  color: var(--text);
  font-size: 13px;
  font-weight: 700;
  cursor: pointer;
  padding: 8px 10px;
  text-align: center;
  line-height: 1.2;
  white-space: normal;
  word-break: break-word;
  overflow-wrap: anywhere;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: 0.18s ease;
}

.selection-chip:hover {
  background: #f3f8fd;
}

.selection-chip.is-active {
  background: linear-gradient(to right, var(--accent) 0%, #2c88d8 100%);
  color: #ffffff;
  border-color: #2c88d8;
}

.meta-row {
  display: grid;
  grid-template-columns: 1fr 1.2fr;
  gap: 10px;
  margin-top: 12px;
}

.meta-box,
.meta-input {
  min-height: 48px;
  border-radius: 14px;
  border: 1px solid var(--line);
  background: var(--panel-soft);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 10px 12px;
  font-size: 14px;
}

.score-box {
  font-weight: 700;
  color: #74879a;
}

.meta-input {
  justify-content: flex-start;
  background: #ffffff;
  color: var(--text);
}

.log-info-box {
  margin-top: 10px;
  min-height: 48px;
  border: 1px solid var(--line);
  background: var(--panel-soft);
  border-radius: 14px;
  padding: 12px;
  font-size: 14px;
  line-height: 1.5;
  color: var(--muted);
}

.notes-wrap {
  margin-top: 10px;
}

.compact-notes {
  border: 1px solid var(--line);
  background: #fbfdff;
  border-radius: 14px;
  padding: 10px;
}

.notes-toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 8px;
}

.notes-toggle {
  border: 1px solid var(--line);
  background: #ffffff;
  color: var(--text);
  border-radius: 999px;
  min-height: 30px;
  padding: 4px 10px;
  font-size: 12px;
  font-weight: 700;
  cursor: pointer;
}

.note-counter {
  font-size: 12px;
  font-weight: 700;
  color: var(--muted);
}

.note-input {
  width: 100%;
  min-height: 110px;
  resize: vertical;
  border: 1px solid var(--line);
  border-radius: var(--radius-md);
  background: #ffffff;
  color: var(--text);
  padding: 12px;
  font-size: 14px;
  line-height: 1.5;
}

.note-input.compact {
  min-height: 68px;
  resize: none;
}

.note-input.expanded {
  min-height: 120px;
  resize: vertical;
}

.note-input:focus,
.meta-input:focus {
  border-color: #8aa7c4;
  box-shadow: 0 0 0 3px rgba(138, 167, 196, 0.16);
  outline: none;
}

.inline-button-row {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  margin-top: 10px;
}

.sticky-action-bar {
  position: static;
  bottom: auto;
  z-index: auto;
  background: transparent;
  backdrop-filter: none;
  padding-top: 8px;
}
.real-entry-actions-inline {
  flex-wrap: nowrap;
}

.action-inline {
  flex: 1 1 0;
  min-width: 0;
  white-space: nowrap;
}

.solid-button,
.soft-button,
.small-button,
.danger-btn {
  border-radius: 10px;
  min-height: 40px;
  padding: 8px 14px;
  font-size: 14px;
  font-weight: 700;
  cursor: pointer;
}

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

.gradient-button {
  width: 100%;
  min-height: 50px;
  border: none;
  border-radius: 16px;
  background: linear-gradient(to right, var(--accent) 0%, var(--accent-2) 100%);
  font-size: 15px;
  color: #ffffff;
  font-weight: 700;
}

.real-entry-actions-inline .gradient-button {
  width: auto;
}

.solid-button:disabled {
  opacity: 0.45;
  cursor: not-allowed;
}

.soft-button {
  border: 1px solid var(--line);
  background: #ffffff;
  color: var(--text);
}

.small-button {
  border: 1px solid #cfe0f2;
  background: #f7fbff;
  color: #17324d;
  min-height: 34px;
  padding: 6px 10px;
  font-size: 12px;
}

.danger-btn {
  background: #b42318;
  color: #fff;
  border: none;
}

.practice-score-wrap {
  margin-top: 12px;
  border: 1px solid var(--practice-line);
  background: var(--practice-soft);
  border-radius: 14px;
  padding: 12px;
}

.practice-label {
  margin: 0 0 4px;
  font-size: 12px;
  font-weight: 700;
  color: var(--muted);
  text-transform: uppercase;
  letter-spacing: 0.06em;
}

.practice-score {
  margin: 0;
  font-size: 30px;
  font-weight: 700;
  line-height: 1;
  color: #0e6e50;
}

.saved-note-box {
  margin-top: 12px;
}

.saved-note-box p,
.empty-note {
  margin: 0;
  padding: 12px;
  background: var(--panel-soft);
  border: 1px solid var(--line);
  border-radius: var(--radius-md);
  font-size: 14px;
  line-height: 1.6;
  color: var(--text);
}

.save-message {
  margin-top: 10px;
  min-height: 18px;
  font-size: 14px;
  font-weight: 700;
  color: #1b8c52;
}

.footer-log-actions {
  margin-top: 12px;
}
.diary-image-upload-wrap {
  margin-top: 10px;
  border: 1px solid var(--line);
  background: #fbfdff;
  border-radius: 14px;
  padding: 10px;
}

.diary-image-label {
  display: block;
  margin: 0 0 8px;
  font-size: 13px;
  font-weight: 700;
  color: var(--text);
}

#diary-image-input {
  width: 100%;
  font-size: 13px;
  color: var(--muted);
}

.diary-image-preview-wrap {
  margin-top: 10px;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.diary-image-preview {
  width: 100%;
  max-height: 260px;
  object-fit: cover;
  border-radius: 12px;
  border: 1px solid var(--line);
  background: #ffffff;
}
.diary-image-upload-wrap {
  margin-top: 10px;
  border: 1px solid var(--line);
  background: #fbfdff;
  border-radius: 14px;
  padding: 10px;
}

.diary-image-label {
  display: block;
  margin: 0 0 8px;
  font-size: 13px;
  font-weight: 700;
  color: var(--text);
}

#diary-image-input {
  width: 100%;
  font-size: 13px;
  color: var(--muted);
}

.diary-image-preview-wrap {
  margin-top: 10px;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.diary-image-preview {
  width: 100%;
  max-height: 260px;
  object-fit: cover;
  border-radius: 12px;
  border: 1px solid var(--line);
  background: #ffffff;
}

/* ---------- Score ---------- */

.score-panel {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.score-number-large {
  width: 100%;
  border: 1px solid var(--line);
  background: var(--panel-soft);
  border-radius: var(--radius-md);
  padding: 18px 14px;
  font-size: 42px;
  line-height: 1;
  font-weight: 700;
  text-align: center;
  color: var(--text);
}

.score-summary-grid,
.trend-summary-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
  margin-top: 10px;
}

.score-summary-grid-4 {
  grid-template-columns: 1fr 1fr;
}

.score-summary-grid-2 {
  grid-template-columns: 1fr 1fr;
}

.score-breakdown-shell,
.score-action-shell {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.score-breakdown-block,
.score-action-block {
  background: var(--panel-soft);
  border: 1px solid var(--line);
  border-radius: 14px;
  padding: 10px;
}
.score-action-block-highlight {
  background: linear-gradient(to right, #f8fbff 0%, #ffffff 100%);
}

.score-action-main {
  margin: 4px 0 6px 0;
  font-size: 18px;
  line-height: 1.25;
  font-weight: 700;
  color: var(--text);
}

.score-action-sub {
  margin: 0;
  font-size: 14px;
  line-height: 1.6;
  color: var(--muted);
}

.score-breakdown-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.score-breakdown-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding: 9px 10px;
  border-radius: 10px;
  background: #ffffff;
  border: 1px solid var(--line);
  transition: transform 0.14s ease, box-shadow 0.14s ease;
}

.score-breakdown-row:hover {
  transform: translateY(-1px);
  box-shadow: 0 4px 10px rgba(23, 50, 77, 0.08);
}

.score-breakdown-row-label,
.score-breakdown-row-value {
  margin: 0;
  font-size: 13px;
  line-height: 1.3;
}

.score-breakdown-row-value {
  font-weight: 700;
}

.score-breakdown-row-value.positive {
  color: #0e6e50;
}

.score-breakdown-row-value.debt {
  color: #b42318;
}

.score-breakdown-row-value.bonus {
  color: #1f72bf;
}

.score-insight-card .section-text {
  font-size: 15px;
  line-height: 1.6;
  color: #2b3e52;
}

.trend-summary-grid {
  grid-template-columns: 1fr 1fr 1fr;
}

.mini-stat-card {
  background: var(--panel-soft);
  border: 1px solid var(--line);
  border-radius: 14px;
  padding: 12px;

  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  text-align: center;
}

.mini-stat-label {
  margin: 0 0 6px;
  font-size: 12px;
  color: var(--muted);
  text-transform: uppercase;
  letter-spacing: 0.05em;
  font-weight: 700;
}

.mini-stat-value {
  margin: 0;
  font-size: 24px;
  line-height: 1.1;
  font-weight: 700;
  color: var(--text);
  text-align: center; /* 👈 add this */
}
#score-zone-label {
  font-size: 16px;
  line-height: 1.2;
  font-weight: 600;
}
.trend-list {
  margin-top: 12px;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.trend-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  padding: 9px 10px;
  border-radius: 12px;
  border: 1px solid var(--line);
  background: #ffffff;
}

.trend-day,
.trend-score,
.trend-meta {
  margin: 0;
  font-size: 14px;
}

.trend-score {
  font-weight: 700;
}

.score-visual-block {
  margin-top: 12px;
  padding: 14px;
  background: linear-gradient(to bottom, #f8fbff, #eef5fb);
  border: 1px solid #d8e4ee;
  border-radius: 16px;
  box-shadow: 0 4px 14px rgba(23, 50, 77, 0.06);
}

.score-visual-label-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 10px;
}

.score-visual-label-row .mini-stat-label {
  margin: 0;
}

.score-visual-value {
  margin: 0;
  font-size: 13px;
  font-weight: 800;
  color: var(--text);
}

.score-progress-track,
.score-balance-track,
.score-bonus-track {
  width: 100%;
  height: 16px;
  border-radius: 999px;
  overflow: hidden;
  background: #e6edf5;
  position: relative;
  box-shadow: inset 0 1px 2px rgba(23, 50, 77, 0.08);
}

.score-progress-fill {
  height: 100%;
  width: 0%;
  border-radius: 999px;
  background: linear-gradient(90deg,
    #dc2626 0%,
    #dc2626 16.66%,

    #f97316 16.66%,
    #f97316 33.33%,

    #eab308 33.33%,
    #eab308 50%,

    #22c55e 50%,
    #22c55e 66.66%,

    #3b82f6 66.66%,
    #3b82f6 83.33%,

    #8b5cf6 83.33%,
    #8b5cf6 100%
  );
  transition: width 0.35s ease;
  box-shadow: 0 0 8px rgba(59, 130, 246, 0.3);
}

.score-balance-track {
  display: flex;
  background: #eef2f7;
}

.score-balance-positive {
  height: 100%;
  width: 0%;
  background: linear-gradient(90deg, #86efac 0%, #22c55e 100%);
  transition: width 0.35s ease;
}

.score-balance-debt {
  height: 100%;
  width: 0%;
  background: linear-gradient(90deg, #fb7185 0%, #dc2626 100%);
  transition: width 0.35s ease;
}

.score-bonus-fill {
  height: 100%;
  width: 0%;
  border-radius: 999px;
  background: linear-gradient(90deg, #93c5fd 0%, #2563eb 100%);
  transition: width 0.35s ease;
  box-shadow: 0 0 6px rgba(37, 99, 235, 0.35);
}

.score-card .mini-stat-card,
.score-breakdown-card .score-breakdown-block,
.score-insight-card .card-body,
.score-action-card .score-action-block,
.mini-stat-card {
  background: var(--panel-soft);
  border: 1px solid var(--line);
  border-radius: 14px;
  padding: 10px;
}

.score-insight-card .card-body {
  background: linear-gradient(to right, #f8fbff 0%, #ffffff 100%);
  border: 1px solid #dbe7f0;
  border-radius: 14px;
  padding: 14px;
}

@media (max-width: 420px) {
  .score-summary-grid-4,
  .score-summary-grid-2,
  .trend-summary-grid {
    grid-template-columns: 1fr;
  }
}

/* ---------- Home Feed ---------- */

#section-home .section-card .section-title {
  font-size: 16px;
  line-height: 1.2;
}

#section-home .section-card .card-header,
#section-home .section-card .section-label {
  margin-bottom: 10px;
}

.home-screen {
  display: flex;
  flex-direction: row;
  gap: 8px;
  overflow-x: auto;
  overflow-y: hidden;
  padding-bottom: 4px;
  scroll-snap-type: x proximity;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: thin;
}

.home-screen::-webkit-scrollbar {
  height: 8px;
}

.home-screen::-webkit-scrollbar-thumb {
  background: #cbd5e1;
  border-radius: 999px;
}

.home-card {
  flex: 0 0 64%;
  min-width: 64%;
  min-height: 156px;
  padding: 9px 11px;
  scroll-snap-align: start;

  display: flex;
  flex-direction: column;
  justify-content: space-between;
}

.home-card .card-label {
  margin: 0 0 6px;
}

.home-card .card-title,
.home-card .card-title-small,
.home-card .card-value,
.home-card .card-highlight {
  margin: 0 0 6px;
}

.home-card .card-text {
  line-height: 1.35;
}

.home-card-greeting {
  background: linear-gradient(to right, #f2f8ff 0%, #f8fcff 100%);
  padding: 10px 12px 9px;
}
.home-card-greeting .card-label {
  display: none;
}

.home-card-greeting .card-title {
  margin: 0 0 4px 0;
  font-size: 15px;
  line-height: 1.25;
}

.home-card-greeting .card-text {
  font-size: 13px;
  line-height: 1.45;
}

.home-card-gold-line {
  background: linear-gradient(to right, #f7fbf2 0%, #fbfef8 100%);
}

.home-card-headline {
  padding-top: 18px;
  padding-bottom: 18px;
}

.home-card-headline .card-highlight {
  font-size: 17px;
  line-height: 1.25;
  color: #17324d;
}

.home-card-score {
  background: linear-gradient(to right, #f8fbff 0%, #ffffff 100%);
}

.home-card .card-title,
.home-card .card-title-small,
.home-card .card-value {
  font-size: 14px;
  line-height: 1.3;
  white-space: normal;
  overflow: visible;
  text-overflow: unset;
}

.home-card .card-highlight {
  font-size: 17px;
  line-height: 1.3;
  white-space: normal;
  overflow: visible;
  text-overflow: unset;
}

.home-card .card-text {
  font-size: 13px;
  line-height: 1.4;
  flex-grow: 1;
}
.home-card .card-title-small {
  margin-bottom: 4px;
}

.score-row {
  display: flex;
  align-items: center;
  gap: 14px;
}

.score-number {
  min-width: 80px;
  text-align: center;
  padding: 14px 8px;
  border-radius: 16px;
  background: #17324d;
  color: #ffffff;
  font-size: 28px;
  line-height: 1;
  font-weight: 700;
}

.score-title {
  margin: 0 0 6px;
  font-size: 15px;
  font-weight: 700;
}

/* ---------- Home recent activity rail ---------- */

.activity-list {
  display: flex;
  gap: 12px;
  overflow-x: auto;
  padding-bottom: 6px;
  scroll-snap-type: x mandatory;
  -webkit-overflow-scrolling: touch;
}

.activity-list::-webkit-scrollbar {
  display: none;
}

.activity-item,
.latest-entry-card,
.history-entry-card,
.diary-entry-card {
  border: 1px solid var(--line);
  background: #ffffff;
  border-radius: 14px;
  padding: 12px;
  box-shadow: 0 6px 18px rgba(23, 50, 77, 0.08);
}

.activity-item {
  flex: 0 0 85%;
  scroll-snap-align: start;
}

.latest-entry-card,
.history-entry-card,
.diary-entry-card {
  flex: 0 0 auto;
  height: auto;
  min-height: unset;
  align-self: stretch;
}
.activity-main,
.entry-main {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.activity-title,
.entry-title {
  margin: 0;
  font-size: 15px;
  font-weight: 700;
}

.activity-meta,
.entry-meta,
.entry-note,
.entry-weight {
  margin: 0;
  font-size: 13px;
  line-height: 1.5;
  color: var(--muted);
}

/* ---------- Latest / History / Diary ---------- */

.latest-list {
  display: flex;
  flex-direction: column;
  gap: 12px;
  max-height: none;
  overflow: visible;
  padding-right: 0;
  scrollbar-width: auto;
  scrollbar-color: auto;
}

.history-list {
  display: flex;
  flex-direction: column;
  gap: 12px;
  padding-right: 0;
  max-height: none;
  overflow: visible;
  scrollbar-width: auto;
  scrollbar-color: auto;
}

#diary-list {
  display: flex;
  flex-direction: column;
  gap: 12px;
  max-height: none;
  overflow-y: visible;
  padding-right: 0;
  scrollbar-width: auto;
  scrollbar-color: auto;
}

.latest-list::-webkit-scrollbar,
.history-list::-webkit-scrollbar {
  width: 10px;
}

.latest-list::-webkit-scrollbar-thumb,
.history-list::-webkit-scrollbar-thumb {
  background: #9fb5c9;
  border-radius: 999px;
  border: 2px solid transparent;
  background-clip: padding-box;
}

.latest-list::-webkit-scrollbar-thumb:hover,
.history-list::-webkit-scrollbar-thumb:hover {
  background: #87a2ba;
  background-clip: padding-box;
}

.latest-list::-webkit-scrollbar-track,
.history-list::-webkit-scrollbar-track {
  background: rgba(255, 255, 255, 0.18);
  border-radius: 999px;
}

#section-latest .section-card,
#section-diary .section-card,
#section-score .section-card,
#section-act .section-card,
#section-profile .section-card {
  overflow: visible;
}

#history-list .day-group,
#diary-list .day-group {
  flex: 0 0 auto;
}

.history-range-tabs {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  margin-bottom: 12px;
}

.history-range-btn.is-active {
  background: #17324d;
  color: #ffffff;
  border-color: #17324d;
}

.day-group {
  border: 1px solid var(--line);
  border-radius: 16px;
  overflow: hidden;
  background: #ffffff;
  margin-bottom: 8px;
}

.day-group-header {
  width: 100%;
  border: none;
  background: linear-gradient(to right, #f3f8ff, #f8fbff);
  padding: 12px 14px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  cursor: pointer;
  text-align: left;
  border-bottom: 1px solid #e2ecf5;
}

.day-group-title,
.day-group-total,
.day-group-meta {
  margin: 0;
}

.day-group-title {
  font-size: 15px;
  font-weight: 700;
}

.day-group-total,
.day-group-meta {
  font-size: 13px;
  color: var(--muted);
}

.day-group-body {
  display: flex;
  flex-direction: column;
  gap: 6px;
  padding: 10px;
}

.entry-type-pill {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 24px;
  padding: 2px 8px;
  border-radius: 999px;
  font-size: 11px;
  font-weight: 700;
}

.entry-type-pill.positive {
  background: #eef8f2;
  color: #0e6e50;
}

.entry-type-pill.debt {
  background: #fff4f2;
  color: #b42318;
}

.entry-type-pill.diary {
  background: #f4f8ff;
  color: #17324d;
}

.entry-top-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 6px;
}

.entry-points {
  font-size: 14px;
  font-weight: 700;
}

.entry-points.positive {
  color: #0e6e50;
}

.entry-points.debt {
  color: #b42318;
}

.entry-action-row {
  display: flex;
  gap: 8px;
  margin-top: 10px;
}

.entry-action-btn {
  border: 1px solid var(--line);
  background: #ffffff;
  color: var(--text);
  border-radius: 10px;
  min-height: 34px;
  padding: 6px 12px;
  font-size: 12px;
  font-weight: 700;
  cursor: pointer;
}

.entry-action-btn.danger {
  border-color: #efb1a8;
  background: #fff4f2;
  color: #b42318;
}

/* ---------- Act ---------- */

.rules-list {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

/* ---------- Utility ---------- */

.hidden {
  display: none !important;
}

.section-title-inline {
  display: flex;
  align-items: baseline;
  gap: 8px;
  flex-wrap: nowrap;
  margin-bottom: 10px;
  font-size: 18px;
  line-height: 1.25;
}
.log-header {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 4px;
}

.log-header .section-title {
  margin: 0;
  font-size: 22px;
  line-height: 1.1;
  font-weight: 800;
  letter-spacing: -0.01em;
}

.log-subtext {
  margin: 0;
  font-size: 13px;
  line-height: 1.35;
  color: var(--muted);
  white-space: normal;
  overflow-wrap: anywhere;
}

.section-title-helper {
  font-size: 13px;
  font-weight: 400;
  color: var(--muted);
  white-space: nowrap;
}

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

.entry-type-card-compact {
  min-height: 40px;
  padding: 6px 8px;
  border-radius: 12px;
  font-size: 13px;
  font-weight: 700;
}

.title-grid button {
  padding: 8px 6px;
  font-size: 13px;
  min-height: 40px;
}

/* ---------- Home Hero ---------- */

.home-hero-card {
  display: block;
  width: 100%;
  margin: 0 0 8px 0;
  flex: 0 0 auto;
  position: relative;
  scroll-margin-top: 120px;
}

.home-scene {
  position: relative;
  min-height: 52vh;
  border-radius: 26px;
  overflow: hidden;
  box-shadow: 0 14px 34px rgba(15, 23, 42, 0.18);
  padding: 14px;
  display: flex;
  align-items: stretch;
  transition: background 1.2s ease, transform 0.25s ease, opacity 0.6s ease, filter 1.2s ease, padding 0.35s ease;
  width: 100%;
}
.home-scene.phase-fresh,
.home-scene.phase-memory {
  padding: 16px;
}

.home-scene.phase-first-entry,
.home-scene.phase-live {
  padding: 14px;
}

.home-scene.phase-fresh {
  filter: brightness(0.99);
}

.home-scene.phase-memory {
  filter: brightness(1);
}

.home-scene.phase-first-entry {
  filter: brightness(1.06);
  transform: translateY(-2px);
  box-shadow: 0 18px 38px rgba(15, 23, 42, 0.22);
}

.home-scene.phase-live {
  filter: brightness(1.03);
}
/* Home day phases */
.phase-fresh {}
.phase-memory {}
.phase-first-entry {}
.phase-live {}

/* Memory intensity overlays */
.memory-strong-positive {
  filter: brightness(1.08) saturate(1.05);
}

.memory-mid-positive {
  filter: brightness(1.04);
}

.memory-light-positive {
  filter: brightness(1.02);
}

.memory-light-drift {
  filter: brightness(0.98);
}

.memory-mid-drift {
  filter: brightness(0.95) saturate(0.95);
}

.memory-strong-drift {
  filter: brightness(0.92) saturate(0.9);
}
.home-scene.replay-transition {
  opacity: 0.92;
  filter: blur(0.4px);
}
.home-scene::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  height: 80px;
  background: linear-gradient(to bottom, rgba(255,255,255,0) 0%, #f4f7fb 100%);
  pointer-events: none;
}

.home-scene-overlay {
  position: relative;
  z-index: 2;
  width: 100%;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}

.home-scene-kicker {
  margin: 0 0 8px 0;
  font-size: 0.82rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  font-weight: 700;
  opacity: 0.9;
}

.home-scene-title {
  margin: 0 0 10px 0;
  font-size: 1.35rem;
  line-height: 1.2;
  max-width: 340px;
}

.home-scene-state-line {
  display: inline-block;
  width: fit-content;
  max-width: 100%;
  margin: 0;
  padding: 9px 12px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.2);
  backdrop-filter: blur(4px);
  font-size: 0.92rem;
  font-weight: 600;
}

.home-scene-visual {
  position: relative;
  flex: 1;
  min-height: 240px;
  margin: 10px 0 12px 0;
  overflow: hidden;
  border-radius: 20px;
}

.scene-sun {
  position: absolute;
  top: 24px;
  right: 40px;
  width: 72px;
  height: 72px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(255,236,140,1) 0%, rgba(255,210,90,0.95) 65%, rgba(255,210,90,0.2) 100%);
  box-shadow: 0 0 26px rgba(255, 214, 102, 0.55);
  opacity: 0;
  transform: scale(0.8);
  transition: opacity 0.35s ease, transform 0.35s ease;
}

.scene-sun.is-visible {
  opacity: 1;
  transform: scale(1);
}

.scene-sky-glow {
  position: absolute;
  top: 26px;
  right: 34px;
  width: 110px;
  height: 110px;
  border-radius: 50%;
  background: rgba(255, 244, 180, 0.75);
  box-shadow: 0 0 60px rgba(255, 244, 180, 0.55);
  transition: all 0.35s ease;
  animation: skyPulse 7s ease-in-out infinite;
  opacity: 0.08;
}

.scene-sky-glow.sleep-active {
  opacity: 0.50;
}

.home-zone-clearing .scene-sky-glow.sleep-active {
  opacity: 0.72;
}

.home-zone-sunny .scene-sky-glow.sleep-active {
  opacity: 0.90;
}

.home-zone-radiant .scene-sky-glow.sleep-active {
  opacity: 1;
}

@keyframes skyPulse {
  0% { transform: scale(1); opacity: 0.72; }
  50% { transform: scale(1.06); opacity: 0.96; }
  100% { transform: scale(1); opacity: 0.72; }
}

.scene-mountains {
  position: absolute;
  bottom: 90px;
  left: -10%;
  width: 130%;
  height: 140px;
  background:
    radial-gradient(circle at 18% 100%, rgba(255,255,255,0.18) 0 24%, transparent 25%),
    radial-gradient(circle at 45% 100%, rgba(255,255,255,0.16) 0 27%, transparent 28%),
    radial-gradient(circle at 72% 100%, rgba(255,255,255,0.12) 0 26%, transparent 27%),
    linear-gradient(to top, rgba(26, 61, 44, 0.32), rgba(26, 61, 44, 0.04));
  opacity: 0.38;
}

.scene-ground {
  position: absolute;
  left: -10%;
  bottom: -18px;
  width: 130%;
  height: 120px;
  background: linear-gradient(to top, rgba(45, 100, 62, 0.95), rgba(80, 140, 92, 0.9));
  border-radius: 50% 50% 0 0;
  transition: background 0.4s ease, filter 0.4s ease, opacity 0.4s ease;
  overflow: hidden;
}
.scene-micro-motion {
  position: absolute;
  inset: 0;
  pointer-events: none;
}
.scene-ground::before {
  content: "";
  position: absolute;
  inset: 0;
  background:
    radial-gradient(ellipse at 18% 76%, rgba(62, 78, 46, 0.16), transparent 24%),
    radial-gradient(ellipse at 36% 58%, rgba(88, 98, 56, 0.14), transparent 20%),
    radial-gradient(ellipse at 58% 74%, rgba(54, 70, 40, 0.14), transparent 22%),
    radial-gradient(ellipse at 78% 62%, rgba(94, 104, 60, 0.12), transparent 18%);
  opacity: 0.22;
  transition: opacity 0.4s ease, filter 0.4s ease;
  pointer-events: none;
}

.scene-rain {
  position: absolute;
  inset: 0;
  pointer-events: none;
  opacity: 0;
  transition: opacity 0.35s ease, transform 0.35s ease;
}

.scene-rain::before {
  content: "";
  position: absolute;
  inset: 0;
  background-image: linear-gradient(to bottom, rgba(255,255,255,0.32), rgba(255,255,255,0.02));
  mask-image: repeating-linear-gradient(
    to right,
    transparent 0 10px,
    black 10px 12px,
    transparent 12px 20px
  );
  -webkit-mask-image: repeating-linear-gradient(
    to right,
    transparent 0 10px,
    black 10px 12px,
    transparent 12px 20px
  );
  transform: skewX(-18deg);
  animation: rainDrift 0.9s linear infinite;
}

@keyframes rainDrift {
  from { transform: translateY(-10px) skewX(-18deg); }
  to { transform: translateY(12px) skewX(-18deg); }
}

@keyframes rainDriftFast {
  from { transform: translateY(-14px) skewX(-18deg); }
  to { transform: translateY(16px) skewX(-18deg); }
}

.scene-rainbow,
.scene-tree,
.scene-flowers,
.scene-lounger,
.scene-picnic,
.scene-water-jug,
.scene-dog-secondary,
.scene-litter {
  opacity: 0;
  transform: translateY(10px) scale(0.88);
  transition: opacity 0.35s ease, transform 0.35s ease;
  pointer-events: none;
}

.scene-rainbow.is-visible,
.scene-tree.is-visible,
.scene-flowers.is-visible,
.scene-lounger.is-visible,
.scene-picnic.is-visible,
.scene-water-jug.is-visible,
.scene-dog-secondary.is-visible,
.scene-litter.is-visible {
  opacity: 1;
  transform: translateY(0) scale(1);
}
.scene-rainbow {
  position: absolute;
  left: -32px;
  top: -2px;
  width: 190px;
  height: 96px;
  z-index: 1;
  filter: drop-shadow(0 3px 10px rgba(255,255,255,0.14));
  opacity: 0;
  transform: translateY(10px) scale(0.88);
  transition: opacity 0.35s ease, transform 0.35s ease;
  pointer-events: none;
}

.scene-rainbow.is-visible {
  opacity: 0.72;
  transform: translateY(0) scale(1);
}



.scene-rainbow-secondary {
  left: -6px;
  top: 34px;
  width: 160px;
  height: 80px;
  opacity: 0;
  filter: blur(0.4px);
  transform: translateY(10px) scale(0.82);
}

.scene-rainbow-secondary.is-visible {
  opacity: 0.26;
  transform: translateY(0) scale(0.82);
}
.rainbow-arc {
  position: absolute;
  left: 50%;
  top: 50%;
  border-style: solid;
  border-color: transparent;
  border-radius: 50%;
  transform: translate(-50%, -50%);
}

.rainbow-arc-1 {
  width: 190px;
  height: 96px;
  border-width: 8px 8px 0 8px;
  border-top-color: rgba(239, 68, 68, 0.50);
}

.rainbow-arc-2 {
  width: 172px;
  height: 86px;
  border-width: 7px 7px 0 7px;
  border-top-color: rgba(249, 115, 22, 0.46);
}

.rainbow-arc-3 {
  width: 154px;
  height: 76px;
  border-width: 6px 6px 0 6px;
  border-top-color: rgba(250, 204, 21, 0.44);
}

.rainbow-arc-4 {
  width: 136px;
  height: 66px;
  border-width: 6px 6px 0 6px;
  border-top-color: rgba(34, 197, 94, 0.40);
}

.rainbow-arc-5 {
  width: 118px;
  height: 56px;
  border-width: 5px 5px 0 5px;
  border-top-color: rgba(59, 130, 246, 0.38);
}

.rainbow-arc-6 {
  width: 100px;
  height: 46px;
  border-width: 5px 5px 0 5px;
  border-top-color: rgba(168, 85, 247, 0.36);
}

.home-zone-storm .scene-rainbow,
.home-zone-overcast .scene-rainbow {
  filter: saturate(0.82) brightness(0.86);
}
.scene-litter.litter-light .litter-wrapper-2,
.scene-litter.litter-light .litter-bag,
.scene-litter.litter-light .litter-grease,
.scene-litter.litter-light .litter-crumbs {
  opacity: 0;
}

.scene-litter.litter-medium .litter-grease,
.scene-litter.litter-medium .litter-crumbs {
  opacity: 1;
}

.scene-litter.litter-heavy .litter-wrapper-1,
.scene-litter.litter-heavy .litter-wrapper-2,
.scene-litter.litter-heavy .litter-cup,
.scene-litter.litter-heavy .litter-bag,
.scene-litter.litter-heavy .litter-grease,
.scene-litter.litter-heavy .litter-crumbs {
  opacity: 1;
}

.scene-litter .litter-wrapper,
.scene-litter .litter-cup,
.scene-litter .litter-bag,
.scene-litter .litter-grease,
.scene-litter .litter-crumbs {
  transition: opacity 0.3s ease, transform 0.3s ease;
}

.home-zone-storm .scene-litter .litter-wrapper,
.home-zone-storm .scene-litter .litter-cup,
.home-zone-storm .scene-litter .litter-bag,
.home-zone-storm .scene-litter .litter-crumbs {
  animation: litterShift 2.8s ease-in-out infinite;
}

.scene-litter.litter-light .litter-wrapper-1 {
  transform: rotate(-18deg) scale(0.95);
}

.scene-litter.litter-medium .litter-wrapper-1,
.scene-litter.litter-medium .litter-wrapper-2,
.scene-litter.litter-medium .litter-cup,
.scene-litter.litter-medium .litter-bag {
  transform: scale(1);
}
.scene-litter.litter-medium .litter-wrapper-2 {
  transform: rotate(10deg) scale(1.05);
}

.scene-litter.litter-medium .litter-bag {
  transform: rotate(6deg) scale(1.05);
}
.scene-litter.litter-heavy .litter-wrapper-1 {
  transform: rotate(-24deg) scale(1.18) translateX(-6px);
}

.scene-litter.litter-heavy .litter-wrapper-2 {
  transform: rotate(18deg) scale(1.16) translateX(6px);
}

.scene-litter.litter-heavy .litter-cup {
  transform: scale(1.18) translateY(-2px);
}

.scene-litter.litter-heavy .litter-bag {
  transform: rotate(12deg) scale(1.2) translateX(4px);
}

.scene-litter.litter-heavy .litter-grease {
  transform: scale(1.35);
  opacity: 0.85;
}

.scene-litter.litter-heavy .litter-crumbs {
  transform: scale(1.3);
  opacity: 0.85;
}
.scene-flowers.is-visible {
  filter: drop-shadow(0 2px 4px rgba(255,255,255,0.35));
}

.scene-picnic.is-visible,
.scene-water-jug.is-visible,
.scene-lounger.is-visible,
.scene-tree.is-visible,
.scene-litter.is-visible {
  filter: drop-shadow(0 4px 8px rgba(0,0,0,0.12));
}

.scene-dog-secondary.is-visible {
  opacity: 0.95;
}

.scene-tree {
  position: absolute;
  left: 8%;
  bottom: 74px;
  width: 72px;
  height: 112px;
  z-index: 1;
}

.tree-canopy {
  position: absolute;
  top: 0;
  left: 0;
  width: 72px;
  height: 62px;
  border-radius: 50%;
  background: radial-gradient(circle at 35% 35%, #8bd16b 0%, #5ea54b 55%, #3f7c31 100%);
}

.tree-trunk {
  position: absolute;
  bottom: 0;
  left: 31px;
  width: 10px;
  height: 58px;
  border-radius: 6px;
  background: linear-gradient(to bottom, #7c5332, #5a381f);
}

.scene-flowers {
  position: absolute;
  left: 18%;
  bottom: 26px;
  width: 92px;
  height: 32px;
  z-index: 4;
}

.flower {
  position: absolute;
  bottom: 0;
  width: 12px;
  height: 12px;
  border-radius: 50%;
  background: #ffb3d1;
}

.flower::before {
  content: "";
  position: absolute;
  left: 5px;
  bottom: -10px;
  width: 2px;
  height: 12px;
  background: #4f8c3a;
}

.flower-1 { left: 0; background: #ffb3d1; }
.flower-2 { left: 18px; background: #ffd166; }
.flower-3 { left: 36px; background: #c084fc; }
.flower-4 { left: 56px; background: #7dd3fc; }
.flower-5 { left: 76px; background: #f9a8d4; }

.scene-lounger {
  position: absolute;
  left: 12%;
  bottom: 52px;
  width: 72px;
  height: 42px;
  z-index: 2;
}

.lounger-seat {
  position: absolute;
  bottom: 0;
  left: 8px;
  width: 54px;
  height: 12px;
  border-radius: 8px;
  background: linear-gradient(to right, #f2e5c8, #dbc196);
}

.lounger-back {
  position: absolute;
  left: 36px;
  bottom: 8px;
  width: 10px;
  height: 28px;
  border-radius: 8px;
  background: linear-gradient(to bottom, #e8d5b5, #c7a97a);
  transform: rotate(-35deg);
  transform-origin: bottom center;
}

.scene-picnic {
  position: absolute;
  left: 29%;
  bottom: 54px;
  width: 82px;
  height: 54px;
  z-index: 3;
}

.picnic-top {
  position: absolute;
  top: 8px;
  left: 8px;
  width: 66px;
  height: 10px;
  border-radius: 6px;
  background: linear-gradient(to right, #b97745, #8f5b31);
}

.picnic-leg {
  position: absolute;
  top: 18px;
  width: 6px;
  height: 30px;
  border-radius: 4px;
  background: #6f4526;
}

.picnic-leg-left { left: 20px; }
.picnic-leg-right { right: 20px; }

.scene-water-jug {
  position: absolute;
  left: 48%;
  bottom: 24px;
  width: 40px;
  height: 56px;
  z-index: 4;
}

.jug-body {
  position: absolute;
  bottom: 0;
  left: 6px;
  width: 28px;
  height: 38px;
  border-radius: 10px 10px 12px 12px;
  background: linear-gradient(to bottom, rgba(170,220,255,0.95), rgba(90,170,235,0.95));
  border: 2px solid rgba(255,255,255,0.55);
}

.jug-neck {
  position: absolute;
  top: 8px;
  left: 14px;
  width: 12px;
  height: 10px;
  border-radius: 4px;
  background: rgba(110,180,235,0.95);
}

.jug-cap {
  position: absolute;
  top: 2px;
  left: 15px;
  width: 10px;
  height: 8px;
  border-radius: 3px;
  background: #f3f8ff;
}

.scene-resistance {
  position: absolute;
  left: 66%;
  bottom: 28px;
  width: 92px;
  height: 54px;
  z-index: 2;
  opacity: 0;
  transform: translateY(10px) scale(0.88);
  transition: opacity 0.35s ease, transform 0.35s ease;
  pointer-events: none;
}

.scene-resistance.is-visible {
  opacity: 1;
  transform: translateY(0) scale(1);
}

.resistance-mat {
  position: absolute;
  left: -20px;
  bottom: -4px;
  width: 180px;
  height: 26px;
  border-radius: 8px;
  background: linear-gradient(to right, #7a8797, #a3adba);
  box-shadow: 0 4px 10px rgba(0,0,0,0.15);
  z-index: 1;
}

.resistance-dumbbell {
  position: absolute;
  bottom: 10px;
  width: 36px;
  height: 12px;
  z-index: 2;
}

.dumbbell-left {
  left: 5%;
}

.dumbbell-right {
  right: 5%;
}

.resistance-dumbbell .bar {
  position: absolute;
  left: 10px;
  right: 10px;
  top: 4px;
  height: 4px;
  border-radius: 2px;
  background: #9ca3af;
}

.resistance-dumbbell .plate {
  position: absolute;
  top: 0;
  width: 10px;
  height: 12px;
  border-radius: 2px;
  background: #374151;
}

.resistance-dumbbell .left-plate {
  left: 0;
}

.resistance-dumbbell .right-plate {
  right: 0;
}

.resistance-band {
  position: absolute;
  left: 6px;
  bottom: 24px;
  width: 34px;
  height: 14px;
  border: 3px solid rgba(220, 38, 38, 0.9);
  border-radius: 999px;
  opacity: 0.95;
}

.scene-litter {
  position: absolute;
  left: 58%;
  bottom: 30px;
  width: 110px;
  height: 42px;
  z-index: 4;
  opacity: 0;
  transform: translateY(8px) scale(0.9);
  transition: opacity 0.35s ease, transform 0.35s ease;
  pointer-events: none;
}

.scene-litter.is-visible {
  opacity: 1;
  transform: translateY(0) scale(1);
}
.scene-smoke {
  position: absolute;
  inset: 0;
  z-index: 3;
  pointer-events: none;
  background:
    radial-gradient(circle at 62% 36%, rgba(95, 95, 95, 0.22), transparent 58%),
    radial-gradient(circle at 34% 62%, rgba(80, 80, 80, 0.18), transparent 62%),
    linear-gradient(to bottom, rgba(70, 70, 70, 0.08), rgba(40, 40, 40, 0.12));
  opacity: 0;
  transition: opacity 0.5s ease;
}

.scene-smoke.is-visible {
  opacity: 1;
}
.litter-wrapper {
  position: absolute;
  width: 16px;
  height: 10px;
  border-radius: 3px;
  background: linear-gradient(to right, #f59e0b, #ef4444);
  transform: rotate(-18deg);
}

.litter-wrapper-1 {
  left: 4px;
  bottom: 6px;
}

.litter-wrapper-2 {
  left: 26px;
  bottom: 2px;
  transform: rotate(14deg);
}

.litter-cup {
  position: absolute;
  right: 8px;
  bottom: 4px;
  width: 12px;
  height: 18px;
  border-radius: 2px 2px 4px 4px;
  background: linear-gradient(to bottom, #f3f4f6, #d1d5db);
}

.litter-cup::after {
  content: "";
  position: absolute;
  top: -6px;
  right: 2px;
  width: 2px;
  height: 8px;
  background: #ef4444;
  transform: rotate(12deg);
}
.litter-bag {
  position: absolute;
  left: 42px;
  bottom: 10px;
  width: 18px;
  height: 16px;
  border-radius: 3px 3px 6px 6px;
  background: linear-gradient(to bottom, #c98a42, #9f6326);
  transform: rotate(8deg);
}

.litter-bag::before {
  content: "";
  position: absolute;
  top: -5px;
  left: 3px;
  width: 12px;
  height: 6px;
  border-radius: 2px;
  background: #f2d3a0;
}

.litter-grease {
  position: absolute;
  left: 60px;
  bottom: 4px;
  width: 24px;
  height: 10px;
  border-radius: 50%;
  background: radial-gradient(ellipse at center, rgba(70,40,18,0.45) 0%, rgba(70,40,18,0.18) 70%, rgba(70,40,18,0) 100%);
}

.litter-crumbs {
  position: absolute;
  left: 14px;
  bottom: 0;
  width: 32px;
  height: 12px;
}

.crumb {
  position: absolute;
  width: 4px;
  height: 4px;
  border-radius: 50%;
  background: #e2b45c;
  opacity: 0.95;
}

.crumb-1 { left: 0; bottom: 2px; }
.crumb-2 { left: 8px; bottom: 5px; }
.crumb-3 { left: 15px; bottom: 1px; }
.crumb-4 { left: 24px; bottom: 4px; }
.scene-cabin {
  position: absolute;
  left: 50%;
  bottom: 76px;
  transform: translateX(-50%);
  width: 138px;
  height: 112px;
}

.cabin-roof {
  position: absolute;
  top: 0;
  left: 9px;
  width: 120px;
  height: 48px;
  background: linear-gradient(to bottom, #5f3526, #472519);
  clip-path: polygon(50% 0%, 100% 100%, 0% 100%);
}

.cabin-body {
  position: absolute;
  left: 16px;
  bottom: 0;
  width: 106px;
  height: 74px;
  border-radius: 4px;
  background: linear-gradient(to bottom, #8f5f3f, #6e452d);
  box-shadow: 0 6px 16px rgba(0,0,0,0.18);
}

.cabin-door {
  position: absolute;
  left: 43px;
  bottom: 0;
  width: 20px;
  height: 38px;
  background: #52311f;
  border-radius: 3px 3px 0 0;
}

.cabin-window {
  position: absolute;
  top: 16px;
  width: 18px;
  height: 16px;
  border-radius: 3px;
  background: rgba(255, 230, 145, 0.45);
  box-shadow: inset 0 0 0 2px rgba(96, 64, 32, 0.2);
  transition: background 0.35s ease, box-shadow 0.35s ease;
}

.cabin-window-left { left: 16px; }
.cabin-window-right { right: 16px; }

.scene-plant {
  position: absolute;
  left: 22%;
  bottom: 58px;
  width: 48px;
  height: 86px;
  transform-origin: bottom center;
  transition: transform 0.35s ease, opacity 0.35s ease;
}

.plant-stem {
  position: absolute;
  left: 22px;
  bottom: 0;
  width: 4px;
  height: 56px;
  border-radius: 999px;
  background: linear-gradient(to top, #396b31, #67a545);
}

.plant-leaf {
  position: absolute;
  width: 18px;
  height: 12px;
  background: linear-gradient(to right, #5e9d48, #88c766);
  border-radius: 100% 0 100% 0;
}

.plant-leaf-left {
  left: 7px;
  bottom: 26px;
  transform: rotate(-35deg);
}

.plant-leaf-right {
  left: 22px;
  bottom: 40px;
  transform: rotate(145deg);
}

.plant-bloom {
  position: absolute;
  top: 4px;
  left: 14px;
  width: 20px;
  height: 20px;
  border-radius: 50%;
  background: rgba(255, 198, 86, 0);
  box-shadow: 0 0 0 rgba(255, 198, 86, 0);
  transition: all 0.35s ease;
}

.scene-dog-house {
  position: absolute;
  right: 10%;
  bottom: 88px;
  width: 76px;
  height: 64px;
  z-index: 1;
  opacity: 0.92;
}

.dog-house-roof {
  position: absolute;
  top: 0;
  left: 6px;
  width: 64px;
  height: 24px;
  background: linear-gradient(to bottom, #5f3526, #472519);
  clip-path: polygon(50% 0%, 100% 100%, 0% 100%);
}

.dog-house-body {
  position: absolute;
  left: 10px;
  bottom: 0;
  width: 56px;
  height: 40px;
  border-radius: 4px;
  background: linear-gradient(to bottom, #9a6a47, #74492f);
}

.dog-house-opening {
  position: absolute;
  left: 18px;
  bottom: 0;
  width: 20px;
  height: 24px;
  border-radius: 12px 12px 0 0;
  background: rgba(40, 22, 14, 0.9);
}

.dog-house-sign {
  position: absolute;
  top: 4px;
  left: 6px;
  right: 6px;
  min-height: 12px;
  padding: 1px 4px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.22);
  color: #f8fbff;
  font-size: 9px;
  line-height: 1.1;
  font-weight: 700;
  text-align: center;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  opacity: 0.95;
}

.home-zone-sunny .dog-house-sign,
.home-zone-radiant .dog-house-sign {
  color: #17324d;
  background: rgba(255, 255, 255, 0.42);
}

.dog-house-dog-face {
  position: absolute;
  left: 21px;
  bottom: 8px;
  width: 14px;
  height: 12px;
  border-radius: 50%;
  background: linear-gradient(to bottom, #d7a566, #be8446);
  opacity: 0;
  transform: scale(0.8);
  transition: opacity 0.35s ease, transform 0.35s ease;
}

.scene-dog-house.has-dog-inside .dog-house-dog-face {
  opacity: 1;
  transform: scale(1);
  animation: dogHouseGlowLow 3.6s ease-in-out infinite;
}

.scene-dog {
  position: absolute;
  right: 20%;
  bottom: 62px;
  width: 86px;
  height: 48px;
  transform-origin: bottom center;
  transition: transform 0.35s ease, opacity 0.35s ease, right 0.35s ease, bottom 0.35s ease;
}

.scene-dog-secondary {
  position: absolute;
  left: auto;
  right: 3%;
  bottom: 58px;
  width: 72px;
  height: 42px;
  z-index: 3;
}

.dog-body {
  position: absolute;
  left: 18px;
  bottom: 6px;
  width: 44px;
  height: 22px;
  border-radius: 16px 16px 12px 12px;
  background: linear-gradient(to bottom, #d49a56, #b97838);
}

.dog-head {
  position: absolute;
  left: 0;
  bottom: 18px;
  width: 24px;
  height: 20px;
  border-radius: 50%;
  background: linear-gradient(to bottom, #d7a566, #be8446);
}

.dog-ear {
  position: absolute;
  left: 3px;
  bottom: 31px;
  width: 10px;
  height: 12px;
  background: #8a5829;
  border-radius: 50% 50% 2px 2px;
  transform: rotate(-18deg);
}

.dog-tail {
  position: absolute;
  right: 14px;
  bottom: 24px;
  width: 20px;
  height: 4px;
  border-radius: 999px;
  background: #9e6531;
  transform-origin: left center;
  transform: rotate(20deg);
  transition: transform 0.35s ease;
}

.scene-dog-secondary .dog-body {
  width: 38px;
  height: 20px;
  left: 16px;
}

.scene-dog-secondary .dog-head {
  width: 22px;
  height: 18px;
}

.scene-dog-secondary .dog-ear {
  width: 9px;
  height: 10px;
}

.scene-dog-secondary .dog-tail {
  right: 10px;
  width: 18px;
}

.home-scene-message-wrap {
  max-width: 400px;
  padding: 12px 14px;
  border-radius: 18px;
  background: rgba(10, 20, 30, 0.18);
  backdrop-filter: blur(8px);
}

.home-scene-main-message {
  margin: 0 0 6px 0;
  font-size: 1.08rem;
  line-height: 1.28;
  font-weight: 800;
}

.home-scene-secondary-message {
  margin: 0;
  font-size: 0.95rem;
  line-height: 1.4;
  opacity: 0.94;
}

.home-scene-micro-message {
  margin: 6px 0 0;
  font-size: 13px;
  line-height: 1.35;
  color: rgba(44, 62, 80, 0.72);
  transition: opacity 0.35s ease, transform 0.35s ease;
}

.home-scene-micro-message.is-hidden {
  opacity: 0;
  transform: translateY(-4px);
}

/* ZONE BACKGROUNDS */

.home-zone-storm {
  color: #f4f7fb;
  background: linear-gradient(180deg, #3a4354 0%, #51627a 38%, #5f7483 62%, #61755d 100%);
}

.home-zone-overcast {
  color: #f7f9fc;
  background: linear-gradient(180deg, #728197 0%, #8fa0af 42%, #9fb4bc 65%, #7d9a73 100%);
}

.home-zone-calm {
  color: #f8fbff;
  background: linear-gradient(180deg, #7cb0d9 0%, #99c3df 42%, #b8d4dd 67%, #8cb37e 100%);
}

.home-zone-clearing {
  color: #f8fbff;
  background: linear-gradient(180deg, #5ea5da 0%, #80bfe5 38%, #b7dcf2 65%, #8fbd72 100%);
}

.home-zone-sunny {
  color: #173042;
  background: linear-gradient(180deg, #6bb8f2 0%, #97d3f7 40%, #d8eef8 66%, #9ccf73 100%);
}

.home-zone-radiant {
  color: #153042;
  background: linear-gradient(180deg, #62bcff 0%, #b5e3ff 40%, #fef4c5 68%, #a9d97e 100%);
}
/* GROUND / YARD DEBT STATES */

.home-zone-overcast .scene-ground {
  background: linear-gradient(to top, rgba(56, 104, 67, 0.92), rgba(92, 124, 88, 0.88));
  filter: saturate(0.82) brightness(0.92);
}

.home-zone-storm .scene-ground {
  background: linear-gradient(to top, rgba(52, 82, 52, 0.94), rgba(78, 98, 72, 0.9));
  filter: saturate(0.62) brightness(0.82);
}

.home-scene.cabin-debt-light .scene-ground {
  filter: saturate(0.9) brightness(0.95);
}

.home-scene.cabin-debt-medium .scene-ground {
  filter: saturate(0.78) brightness(0.88);
}

.home-scene.cabin-debt-heavy .scene-ground {
  background: linear-gradient(to top, rgba(48, 60, 44, 0.98), rgba(78, 82, 60, 0.94));
  filter: saturate(0.52) brightness(0.72);
}

.home-zone-overcast .scene-ground::before {
  opacity: 0.28;
}

.home-scene.cabin-debt-light .scene-ground::before {
  opacity: 0.26;
}

.home-scene.cabin-debt-medium .scene-ground::before {
  opacity: 0.38;
  filter: saturate(0.8);
}

.home-scene.cabin-debt-heavy .scene-ground::before {
  opacity: 0.72;
  filter: saturate(0.5) brightness(0.75);
}

/* CABIN WINDOW STATES */

.home-zone-storm .cabin-window,
.home-zone-overcast .cabin-window {
  background: rgba(255, 224, 150, 0.18);
  box-shadow: inset 0 0 0 2px rgba(96, 64, 32, 0.18);
}

.home-zone-calm .cabin-window {
  background: rgba(255, 224, 150, 0.38);
}

.home-zone-clearing .cabin-window {
  background: rgba(255, 224, 150, 0.55);
  box-shadow: 0 0 10px rgba(255, 225, 140, 0.24);
}

.home-zone-sunny .cabin-window {
  background: rgba(255, 226, 130, 0.7);
  box-shadow: 0 0 12px rgba(255, 220, 120, 0.34);
}

.home-zone-radiant .cabin-window {
  background: rgba(255, 231, 122, 0.88);
  box-shadow: 0 0 16px rgba(255, 220, 104, 0.46);
}
/* CABIN DEBT DIMMING */

.home-scene.cabin-debt-light .cabin-body {
  filter: brightness(0.9) saturate(0.92);
}

.home-scene.cabin-debt-light .cabin-window {
  background: rgba(255, 214, 130, 0.18);
  box-shadow: inset 0 0 0 2px rgba(96, 64, 32, 0.15);
}

.home-scene.cabin-debt-medium .cabin-body {
  filter: brightness(0.78) saturate(0.82);
}

.home-scene.cabin-debt-medium .cabin-window {
  background: rgba(255, 205, 120, 0.10);
  box-shadow: inset 0 0 0 2px rgba(96, 64, 32, 0.12);
}

.home-scene.cabin-debt-heavy .cabin-body {
  filter: brightness(0.62) saturate(0.7);
}

.home-scene.cabin-debt-heavy .cabin-window {
  background: rgba(255, 190, 110, 0.05);
  box-shadow: inset 0 0 0 2px rgba(96, 64, 32, 0.08);
}
/* SKY / SUN / RAIN BY ZONE */

.home-zone-overcast .scene-sky-glow {
  opacity: 0.25;
  filter: brightness(0.85);
}

.home-zone-calm .scene-sky-glow {
  opacity: 0.08;
}

.home-zone-clearing .scene-sky-glow {
  opacity: 0.08;
}

.home-zone-sunny .scene-sky-glow {
  opacity: 0.08;
}

.home-zone-radiant .scene-sky-glow {
  opacity: 0.08;
  transform: scale(1.08);
}

.home-zone-overcast .scene-sun {
  opacity: 0.28;
}

.home-zone-storm .scene-sun {
  display: none;
}

.home-zone-overcast .scene-rain {
  opacity: 0.28;
}

.home-zone-storm .scene-rain {
  opacity: 0.92;
  transform: rotate(12deg) scale(1.1);
}

.home-zone-storm .scene-rain::before {
  animation: rainDriftFast 0.48s linear infinite;
}

.home-zone-overcast .home-scene-visual {
  filter: brightness(0.9);
}

.home-zone-storm .home-scene-visual {
  filter: brightness(0.72);
}

/* DOG STATES */

.dog-curled {
  transform: scale(0.84) translateY(10px);
  opacity: 0.8;
}

.dog-withdrawn {
  transform: scale(0.86) translateY(8px);
  opacity: 0.72;
}

.dog-in-house {
  right: 12%;
  bottom: 74px;
  transform: scale(0.72);
  opacity: 0.18;
}

.dog-waiting {
  transform: scale(0.95) translateY(1px);
  opacity: 0.92;
}

.dog-resting {
  transform: scale(1);
  opacity: 0.96;
  animation: dogBreath 4.8s ease-in-out infinite;
}

.dog-alert {
  transform: scale(1.05) translateY(-3px);
  opacity: 0.98;
}

.dog-happy {
  transform: scale(1.08) translateY(-5px);
  opacity: 1;
}

.dog-playful {
  transform: scale(1.14) translateY(-8px);
  opacity: 1;
}

@keyframes dogBreath {
  0% { transform: scale(1) translateY(0); }
  50% { transform: scale(1.015) translateY(-1px); }
  100% { transform: scale(1) translateY(0); }
}

@keyframes dogBreathHeavy {
  0% { transform: scale(0.9) translateY(2px); }
  50% { transform: scale(0.92) translateY(1px); }
  100% { transform: scale(0.9) translateY(2px); }
}

@keyframes tailWagGentle {
  0% { transform: rotate(10deg); }
  50% { transform: rotate(22deg); }
  100% { transform: rotate(10deg); }
}

@keyframes tailWagMedium {
  0% { transform: rotate(20deg); }
  50% { transform: rotate(38deg); }
  100% { transform: rotate(20deg); }
}

@keyframes tailWagFast {
  0% { transform: rotate(34deg); }
  50% { transform: rotate(60deg); }
  100% { transform: rotate(34deg); }
}

.dog-curled .dog-tail {
  animation: none;
  transform: rotate(-4deg);
}

.dog-waiting .dog-tail {
  animation: none;
  transform: rotate(4deg);
}

.dog-resting .dog-tail {
  transform: rotate(18deg);
  animation: tailWagGentle 2.8s ease-in-out infinite;
}

.dog-alert .dog-tail {
  transform: rotate(28deg);
  animation: tailWagMedium 1.8s ease-in-out infinite;
}

.dog-happy .dog-tail {
  transform: rotate(42deg);
  animation: tailWagFast 1.1s ease-in-out infinite;
}

.dog-playful .dog-tail {
  transform: rotate(58deg);
  animation: tailWagFast 0.7s ease-in-out infinite;
}

.dog-withdrawn .dog-tail,
.dog-in-house .dog-tail,
.home-zone-overcast #scene-dog .dog-tail,
.home-zone-storm #scene-dog .dog-tail {
  animation: none;
  transform: rotate(-8deg);
}

.home-zone-storm #scene-dog {
  opacity: 0.06 !important;
  transform: scale(0.62) translateY(14px);
}

.home-zone-overcast #scene-dog {
  opacity: 0.82;
  transform: scale(0.9) translateY(5px);
  animation: dogBreathHeavy 4.8s ease-in-out infinite;
}

.home-zone-overcast #scene-dog .dog-head {
  transform: translateY(2px);
}

.home-zone-clearing #scene-dog {
  opacity: 0.96;
}

.home-zone-sunny #scene-dog {
  opacity: 1;
}

.home-zone-radiant #scene-dog {
  opacity: 1;
}

.home-zone-radiant #scene-dog .dog-head {
  transform: translateY(-2px);
}

/* PLANT STATES */

.plant-drooping {
  transform: rotate(-12deg) scale(0.92);
  opacity: 0.88;
}

.plant-strained {
  transform: rotate(-6deg) scale(0.96);
}

.plant-steady {
  transform: rotate(0deg) scale(1);
  animation: plantSwaySteady 6.5s ease-in-out infinite;
}

.plant-growing {
  transform: rotate(2deg) scale(1.05);
  animation: plantSwayGrowing 5.6s ease-in-out infinite;
}

.plant-healthy {
  transform: rotate(4deg) scale(1.1);
  animation: plantSwayHealthy 4.8s ease-in-out infinite;
}

.plant-blooming {
  transform: rotate(6deg) scale(1.15);
  animation: plantSwayBlooming 4.2s ease-in-out infinite;
}

@keyframes plantSwaySteady {
  0% { transform: rotate(0deg) scale(1); }
  50% { transform: rotate(2deg) scale(1.01); }
  100% { transform: rotate(0deg) scale(1); }
}

@keyframes plantSwayGrowing {
  0% { transform: rotate(2deg) scale(1.05); }
  50% { transform: rotate(4deg) scale(1.07); }
  100% { transform: rotate(2deg) scale(1.05); }
}

@keyframes plantSwayHealthy {
  0% { transform: rotate(4deg) scale(1.1); }
  50% { transform: rotate(7deg) scale(1.12); }
  100% { transform: rotate(4deg) scale(1.1); }
}

@keyframes plantSwayBlooming {
  0% { transform: rotate(6deg) scale(1.15); }
  50% { transform: rotate(9deg) scale(1.18); }
  100% { transform: rotate(6deg) scale(1.15); }
}

.plant-blooming .plant-bloom {
  background: rgba(255, 198, 86, 0.95);
  box-shadow: 0 0 16px rgba(255, 198, 86, 0.5);
  animation: bloomPulse 3s ease-in-out infinite;
}

@keyframes bloomPulse {
  0% { box-shadow: 0 0 10px rgba(255, 198, 86, 0.30); }
  50% { box-shadow: 0 0 18px rgba(255, 198, 86, 0.55); }
  100% { box-shadow: 0 0 10px rgba(255, 198, 86, 0.30); }
}


@keyframes litterShift {
  0% { transform: translateY(0); }
  50% { transform: translateY(1px); }
  100% { transform: translateY(0); }
}


@keyframes plantStressSway {
  0% { transform: rotate(-4deg) scale(0.96); }
  50% { transform: rotate(-7deg) scale(0.94); }
  100% { transform: rotate(-4deg) scale(0.96); }
}

@keyframes plantDroopPulse {
  0% { transform: rotate(-12deg) scale(0.88); }
  50% { transform: rotate(-15deg) scale(0.84); }
  100% { transform: rotate(-12deg) scale(0.88); }
}


@keyframes dogHouseGlowLow {
  0% { opacity: 0.82; }
  50% { opacity: 0.92; }
  100% { opacity: 0.82; }
}
.home-zone-clearing #scene-plant {
  animation: plantSwayGrowing 4.8s ease-in-out infinite;
}

.home-zone-sunny #scene-plant {
  animation: plantSwayHealthy 3.8s ease-in-out infinite;
}

.home-zone-radiant #scene-plant {
  animation: plantSwayBlooming 3.2s ease-in-out infinite;
}

.home-zone-overcast #scene-plant {
  animation: plantStressSway 7.2s ease-in-out infinite;
  opacity: 0.82;
}

.home-zone-storm #scene-plant {
  animation: plantDroopPulse 5.6s ease-in-out infinite;
  opacity: 0.58;
}

/* HIDE REWARD OBJECTS IN LOW ZONES */

.home-zone-overcast .scene-extra,
.home-zone-storm .scene-extra {
  opacity: 0 !important;
  pointer-events: none;
}
/* ---------- Home affordance ---------- */

.home-screen::after {
  content: "";
  display: none;
}

/* ---------- Top strip score-zone colors ---------- */

.app-brand.zone-thriving {
  background: linear-gradient(135deg, #34d399, #10b981);
  border-color: #10b981;
  color: #ffffff;
  box-shadow: 0 4px 14px rgba(16, 185, 129, 0.35);
}

.app-brand.zone-sunny {
  background: linear-gradient(135deg, #38bdf8, #0ea5e9);
  border-color: #0ea5e9;
  color: #ffffff;
}

.app-brand.zone-brightening {
  background: linear-gradient(135deg, #7dd3fc, #38bdf8);
  border-color: #38bdf8;
  color: #0f172a;
}

.app-brand.zone-calm {
  background: linear-gradient(135deg, #94a3b8, #64748b);
  border-color: #64748b;
  color: #ffffff;
}

.app-brand.zone-clouded {
  background: linear-gradient(135deg, #64748b, #475569);
  border-color: #475569;
  color: #ffffff;
}

.app-brand.zone-storm {
  background: linear-gradient(135deg, #334155, #1e293b);
  border-color: #1e293b;
  color: #ffffff;
}

.app-brand.zone-thriving .app-title,
.app-brand.zone-thriving .app-live-stats,
.app-brand.zone-thriving .top-save-confirmation,
.app-brand.zone-sunny .app-title,
.app-brand.zone-sunny .app-live-stats,
.app-brand.zone-sunny .top-save-confirmation,
.app-brand.zone-calm .app-title,
.app-brand.zone-calm .app-live-stats,
.app-brand.zone-calm .top-save-confirmation,
.app-brand.zone-clouded .app-title,
.app-brand.zone-clouded .app-live-stats,
.app-brand.zone-clouded .top-save-confirmation,
.app-brand.zone-storm .app-title,
.app-brand.zone-storm .app-live-stats,
.app-brand.zone-storm .top-save-confirmation {
  color: #ffffff;
}

.app-brand.zone-brightening .app-title,
.app-brand.zone-brightening .app-live-stats,
.app-brand.zone-brightening .top-save-confirmation {
  color: #0f172a;
}

/* ---------- Profile ---------- */

.profile-block {
  margin-top: 12px;
  padding: 12px;
  border: 1px solid var(--line);
  background: var(--panel-soft);
  border-radius: 16px;
}

.profile-field-label {
  display: block;
  margin: 10px 0 6px;
  font-size: 14px;
  font-weight: 700;
  color: var(--text);
}

.profile-input {
  width: 100%;
  justify-content: flex-start;
}

.profile-display-box {
  width: 100%;
  justify-content: flex-start;
  color: var(--text);
}

.profile-helper {
  margin: 6px 0 0 0;
  font-size: 13px;
  line-height: 1.5;
  color: var(--muted);
}

/* ---------- Section offsets ---------- */

#section-home,
#section-score,
#section-latest,
#section-diary,
#section-act,
#section-log {
  scroll-margin-top: 118px;
}

#section-home {
  gap: 8px;
}
/* ---------- Responsive ---------- */

@media (max-width: 640px) {
  .past-view-shell {
    height: auto;
    min-height: 0;
    max-height: none;
  }

  .past-view-tabs {
    padding: 10px 10px 8px;
    gap: 6px;
  }

  .past-view-tab {
    padding: 10px 10px;
    font-size: 13px;
  }

  .past-panel-inner {
    padding: 12px 12px 14px;
  }

  .section-title-small {
    font-size: 17px;
  }

  .past-panel-header {
    flex-direction: column;
    align-items: stretch;
  }

.entry-columns-wrap {
  display: grid;
  grid-template-columns: minmax(0, 1.06fr) minmax(0, 0.9fr) minmax(0, 1.06fr);
  gap: 6px;
}
  .section-title-inline {
    font-size: 16px;
    gap: 6px;
  }

  .section-title-helper {
    font-size: 12px;
  }

  .entry-type-grid-compact {
    gap: 6px;
  }

  .entry-type-card-compact {
    min-height: 36px;
    padding: 6px 4px;
    font-size: 12px;
  }

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

  .home-scene {
    min-height: 52vh;
    padding: 12px;
  }

  .home-scene-title {
    font-size: 1.2rem;
    max-width: 300px;
  }

  .home-scene-state-line {
    font-size: 0.86rem;
    line-height: 1.25;
  }

  .home-scene-visual {
    min-height: 260px;
  }

  .scene-cabin {
    width: 120px;
    height: 98px;
  }

  .cabin-roof {
    width: 104px;
  }

  .cabin-body {
    width: 92px;
    height: 66px;
  }

  .scene-dog {
    right: 14%;
    width: 74px;
  }

  .scene-plant {
    left: 14%;
  }

  .home-scene-message-wrap {
    max-width: none;
  }

  .scene-dog-house {
    right: 8%;
    bottom: 82px;
    width: 70px;
    height: 58px;
  }

  .dog-house-roof {
    width: 58px;
    height: 22px;
  }

  .dog-house-body {
    width: 50px;
    height: 36px;
  }

  .home-card {
    flex: 0 0 68%;
    min-width: 68%;
    min-height: 150px;
    padding: 9px 10px;
  }
}

@media (max-width: 420px) {
  .real-entry-actions-inline {
    flex-wrap: wrap;
  }

  .action-inline {
    flex: 1 1 100%;
  }

  .trend-summary-grid {
    grid-template-columns: 1fr;
  }

  .home-card {
    flex: 0 0 74%;
    min-width: 74%;
    min-height: 146px;
    padding: 8px 10px;
  }
}

/* ---------- Past View ---------- */

.past-view-card {
  overflow: visible;
}

.past-view-shell {
  height: auto;
  min-height: 0;
  max-height: none;
  display: flex;
  flex-direction: column;
  margin-top: 8px;
  border-radius: 18px;
  background: linear-gradient(to bottom, rgba(248, 251, 255, 0.9), rgba(240, 246, 252, 0.96));
  border: 1px solid rgba(210, 222, 235, 0.9);
  overflow: visible;
}
.past-view-tabs {
  position: sticky;
  top: 0;
  z-index: 5;
  display: flex;
  gap: 8px;
  padding: 12px 12px 10px;
  background: rgba(245, 249, 253, 0.95);
  backdrop-filter: blur(8px);
  border-bottom: 1px solid rgba(214, 224, 234, 0.9);
}

.past-view-tab {
  flex: 1 1 0;
  min-width: 0;
  border: none;
  border-radius: 999px;
  padding: 10px 14px;
  font-size: 14px;
  font-weight: 700;
  cursor: pointer;
  background: #eaf1f7;
  color: #4e6478;
  transition: all 0.2s ease;
}

.past-view-tab.is-active {
  background: linear-gradient(135deg, #d9ecff, #e7f6ea);
  color: #18354d;
  box-shadow: inset 0 0 0 1px rgba(116, 155, 196, 0.35);
}

.past-view-track {
  flex: 1;
  display: flex;
  overflow-x: auto;
  overflow-y: visible;
  scroll-snap-type: x mandatory;
  scroll-behavior: smooth;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none;
}

.past-view-track::-webkit-scrollbar {
  display: none;
}

.past-view-panel {
  flex: 0 0 100%;
  min-width: 100%;
  max-width: 100%;
  scroll-snap-align: start;
  display: flex;
  flex-direction: column;
  overflow: visible;
}

.past-panel-inner {
  height: auto;
  display: flex;
  flex-direction: column;
  padding: 14px 14px 16px;
  overflow: visible;
}

.past-panel-header {
  flex: 0 0 auto;
  display: flex;
  flex-direction: column;
  align-items: stretch;
  justify-content: flex-start;
  gap: 10px;
  margin-bottom: 12px;
}

.section-title-small {
  margin: 2px 0 0;
  font-size: 16px;
  line-height: 1.25;
  font-weight: 700;
  color: #2b465f;
}
.past-scroll-body {
  flex: 1 1 auto;
  min-height: 0;
  overflow: visible;
  padding-right: 0;
}
.recent-panel-scroll .latest-list,
.history-panel-scroll .history-list {
  flex: 1 1 auto;
  min-height: 0;
  overflow: visible;
  max-height: none;
}

.trend-panel-clean {
  justify-content: flex-start;
}

.trend-panel-clean .trend-summary-grid {
  margin-bottom: 14px;
}

.trend-panel-clean .trend-list {
  flex: 1 1 auto;
  min-height: 0;
  overflow: visible;
  padding-right: 0;
  max-height: none;
}
/* ---------- History sticky header ---------- */

.history-header {
  position: sticky;
  top: 0;
  z-index: 5;
  background: var(--panel);
  padding-bottom: 10px;
}

.history-header::after {
  content: "";
  display: block;
  height: 8px;
  background: linear-gradient(to bottom, rgba(0,0,0,0.05), transparent);
}

#section-history .section-card {
  overflow: visible;
}

/* ---------- Undo delete ---------- */

.undo-delete-bar {
  position: fixed;
  left: 50%;
  bottom: 18px;
  transform: translateX(-50%) translateY(20px);
  background: #17324d;
  color: #ffffff;
  border-radius: 14px;
  padding: 12px 14px;
  display: flex;
  align-items: center;
  gap: 12px;
  box-shadow: 0 10px 30px rgba(23, 50, 77, 0.22);
  z-index: 999;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.2s ease, transform 0.2s ease;
}

.undo-delete-bar.is-visible {
  opacity: 1;
  pointer-events: auto;
  transform: translateX(-50%) translateY(0);
}

.undo-delete-bar span {
  font-size: 14px;
  font-weight: 700;
}

.undo-delete-bar button {
  border: 1px solid rgba(255,255,255,0.28);
  background: #ffffff;
  color: #17324d;
  border-radius: 10px;
  min-height: 34px;
  padding: 6px 12px;
  font-size: 13px;
  font-weight: 700;
  cursor: pointer;
}
.undo-delete-bar button {
  border: 1px solid rgba(255,255,255,0.28);
  background: #ffffff;
  color: #17324d;
  border-radius: 10px;
  min-height: 34px;
  padding: 6px 12px;
  font-size: 13px;
  font-weight: 700;
  cursor: pointer;
}
/* ---------- Daily Awareness Stack ---------- */

#section-awareness {
  scroll-margin-top: 118px;
}

.awareness-stack-card {
  padding: 14px;
  background: #ffffff;
  border: 1px solid #d7e2ec;
  border-radius: 18px;
  box-shadow: 0 1px 2px rgba(0,0,0,0.04);
}

.awareness-stack-header {
  margin-bottom: 10px;
}

.awareness-stack-body {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.awareness-module,
.mirror-card,
.pulse-card,
.checkpoint-card,
#morning-light-section {
  margin: 0;
  padding: 12px;
  border: 1px solid #d7e2ec;
  border-radius: 12px;
  box-shadow: none;
  background: #ffffff;
}

.mirror-card {
  background: linear-gradient(to right, rgba(217, 200, 234, 0.32), #ffffff 48%, #fbfdff 100%);
}

#morning-light-section {
  background: linear-gradient(to right, rgba(240, 220, 150, 0.32), #ffffff 48%, #fbfdff 100%);
}

.pulse-card {
  background: linear-gradient(to right, rgba(183, 207, 231, 0.32), #ffffff 48%, #fbfdff 100%);
}

.checkpoint-card {
  background: linear-gradient(to right, rgba(189, 217, 195, 0.32), #ffffff 48%, #fbfdff 100%);
}

.mirror-card .card-header,
.pulse-card .card-header,
.checkpoint-card .card-header {
  margin-bottom: 6px;
}

.mirror-card .section-title,
.pulse-card .section-title,
.checkpoint-card .section-title,
#checkpoint-question-title {
  font-size: 16px;
  line-height: 1.25;
  margin-bottom: 6px;
}

.mirror-card .section-text,
.pulse-card .section-text,
.checkpoint-card .section-text {
  font-size: 13px;
  line-height: 1.45;
}

.mirror-answered,
.pulse-answered,
.checkpoint-answered {
  margin-top: 8px;
  padding: 10px 12px;
  background: rgba(255,255,255,0.82);
  border: 1px solid #d7e2ec;
  border-radius: 12px;
}
/* mirror */
#mirror-options,
.mirror-options {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
  margin-top: 10px;
}

.mirror-option-btn {
  appearance: none;
  -webkit-appearance: none;
  width: 100%;
  min-height: 40px;
  padding: 10px 12px;
  border: 1px solid #cbd5e1;
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.92);
  color: #17324d;
  font-size: 13px;
  line-height: 1.25;
  font-weight: 700;
  text-align: left;
  cursor: pointer;
  transition: background 0.15s ease, transform 0.12s ease, border-color 0.15s ease, box-shadow 0.15s ease;
}

.mirror-option-btn:hover {
  background: #ffffff;
  border-color: #b8c7d8;
  box-shadow: 0 6px 14px rgba(15, 23, 42, 0.06);
  transform: translateY(-1px);
}

.mirror-option-btn:active {
  transform: scale(0.98);
}

.mirror-option-btn.write-option {
  background: #f8fafc;
  border-style: dashed;
}

.mirror-write-wrap {
  margin-top: 10px;
  border: 1px solid var(--line);
  background: #fbfdff;
  border-radius: 14px;
  padding: 10px;
}

.mirror-write-input {
  width: 100%;
  min-height: 72px;
  resize: vertical;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: #ffffff;
  color: var(--text);
  padding: 12px;
  font-size: 14px;
  line-height: 1.5;
}

.mirror-write-input:focus {
  outline: none;
  border-color: #8aa7c4;
  box-shadow: 0 0 0 3px rgba(138, 167, 196, 0.16);
}

.mirror-write-actions {
  display: flex;
  gap: 8px;
  margin-top: 10px;
}

#mirror-save-write-btn,
#mirror-cancel-write-btn {
  border-radius: 10px;
  min-height: 38px;
  padding: 8px 12px;
  font-size: 13px;
  font-weight: 700;
  cursor: pointer;
}

#mirror-save-write-btn {
  border: none;
  background: linear-gradient(to right, var(--accent) 0%, var(--accent-2) 100%);
  color: #ffffff;
}

#mirror-cancel-write-btn {
  border: 1px solid var(--line);
  background: #ffffff;
  color: var(--text);
}

.mirror-answered {
  margin-top: 10px;
  padding: 12px;
  border: 1px solid #cfe0f2;
  background: rgba(255,255,255,0.72);
  border-radius: 14px;
}

.mirror-answered p {
  margin: 0 0 6px;
  font-size: 14px;
  line-height: 1.5;
}

.mirror-answered p:last-child {
  margin-bottom: 0;
}

/* pulse */
#pulse-options,
.pulse-options {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 10px;
}

.pulse-option-btn {
  appearance: none;
  -webkit-appearance: none;
  width: 100%;
  min-height: 44px;
  padding: 10px 14px;
  margin: 0;
  border: 1px solid #b9cbe0;
  border-radius: 14px;
  background: linear-gradient(to bottom, rgba(255,255,255,0.98), rgba(247,250,253,0.96));
  color: #17324d;
  font-size: 13px;
  line-height: 1.2;
  font-weight: 700;
  text-align: center;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow:
    0 1px 0 rgba(255,255,255,0.92) inset,
    0 4px 10px rgba(23, 50, 77, 0.06);
  transition: background 0.15s ease, transform 0.12s ease, border-color 0.15s ease, box-shadow 0.15s ease;
}

.pulse-option-btn:hover {
  background: linear-gradient(to bottom, #ffffff, #f4f8fc);
  border-color: #93b3d4;
  box-shadow:
    0 1px 0 rgba(255,255,255,0.95) inset,
    0 8px 18px rgba(31, 114, 191, 0.12);
  transform: translateY(-1px);
}

.pulse-option-btn:focus-visible {
  outline: none;
  border-color: #7aa7d9;
  box-shadow:
    0 0 0 3px rgba(122, 167, 217, 0.18),
    0 8px 18px rgba(31, 114, 191, 0.10);
}

.pulse-option-btn:active {
  transform: translateY(0);
  box-shadow:
    0 1px 0 rgba(255,255,255,0.8) inset,
    0 3px 8px rgba(23, 50, 77, 0.08);
}

.pulse-answered {
  margin-top: 10px;
  padding: 12px;
  border: 1px solid #cfe0f2;
  background: rgba(255,255,255,0.72);
  border-radius: 14px;
  font-size: 14px;
  line-height: 1.5;
  color: var(--text);
}

/* checkpoint */
#checkpoint-options,
.checkpoint-options {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
  margin-top: 10px;
}

.checkpoint-option-btn {
  appearance: none;
  -webkit-appearance: none;
  width: 100%;
  min-height: 48px;
  padding: 10px 12px;
  margin: 0;
  border: 1px solid #b8cade;
  border-radius: 14px;
  background: linear-gradient(to bottom, rgba(255,255,255,0.98), rgba(247,250,253,0.96));
  color: #17324d;
  font-size: 13px;
  line-height: 1.22;
  font-weight: 700;
  letter-spacing: 0;
  text-align: center;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow:
    0 1px 0 rgba(255,255,255,0.9) inset,
    0 4px 10px rgba(23, 50, 77, 0.06);
  transition: background 0.15s ease, transform 0.12s ease, border-color 0.15s ease, box-shadow 0.15s ease;
}

.checkpoint-option-btn:hover {
  background: linear-gradient(to bottom, #ffffff, #f4f8fc);
  border-color: #93b3d4;
  box-shadow:
    0 1px 0 rgba(255,255,255,0.95) inset,
    0 8px 18px rgba(31, 114, 191, 0.12);
  transform: translateY(-1px);
}

.checkpoint-option-btn:focus-visible {
  outline: none;
  border-color: #7aa7d9;
  box-shadow:
    0 0 0 3px rgba(122, 167, 217, 0.18),
    0 8px 18px rgba(31, 114, 191, 0.10);
}

.checkpoint-option-btn:active {
  transform: translateY(0);
  box-shadow:
    0 1px 0 rgba(255,255,255,0.8) inset,
    0 3px 8px rgba(23, 50, 77, 0.08);
}

.checkpoint-write-wrap {
  margin-top: 10px;
  border: 1px solid var(--line);
  background: #fbfdff;
  border-radius: 14px;
  padding: 10px;
}

.checkpoint-write-input {
  width: 100%;
  min-height: 72px;
  resize: vertical;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: #ffffff;
  color: var(--text);
  padding: 12px;
  font-size: 14px;
  line-height: 1.5;
}

.checkpoint-write-input:focus {
  outline: none;
  border-color: #8aa7c4;
  box-shadow: 0 0 0 3px rgba(138, 167, 196, 0.16);
}

.checkpoint-write-actions {
  display: flex;
  gap: 8px;
  margin-top: 10px;
}

.checkpoint-save-btn,
.checkpoint-cancel-btn {
  border-radius: 10px;
  min-height: 38px;
  padding: 8px 12px;
  font-size: 13px;
  font-weight: 700;
  cursor: pointer;
}

.checkpoint-save-btn {
  border: none;
  background: linear-gradient(to right, var(--accent) 0%, var(--accent-2) 100%);
  color: #ffffff;
}

.checkpoint-cancel-btn {
  border: 1px solid var(--line);
  background: #ffffff;
  color: var(--text);
}

.checkpoint-answered {
  margin-top: 10px;
  padding: 12px;
  border: 1px solid #cfe0f2;
  background: rgba(255,255,255,0.72);
  border-radius: 14px;
}

.checkpoint-answered p {
  margin: 0;
  font-size: 14px;
  line-height: 1.5;
}

@media (max-width: 420px) {
  #mirror-options,
  .mirror-options,
  #checkpoint-options,
  .checkpoint-options {
    grid-template-columns: 1fr;
  }
}/* ---------- Your Feed ---------- */

.zone-feed {
  margin-bottom: 8px;
}

.feed-container {
  display: block;
  padding: 0 0 12px 0;
  position: relative;
}

.feed-pinned-stack {
  display: flex;
  flex-direction: column;
  gap: 14px;
  margin-bottom: 14px;
}

.feed-scroll-stack {
  display: flex;
  flex-direction: column;
  gap: 14px;
  height: auto;
  overflow-y: visible;
  padding-right: 0;
  scrollbar-width: auto;
  scrollbar-color: auto;
}



.feed-card {
  position: relative;
  background: linear-gradient(to bottom, #f8fbff 0%, #ffffff 22%, #fbfdff 100%);
  border: 1px solid #d7e2ec;
  border-radius: 12px;
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.04);
  overflow: visible;
  min-height: 0;
  height: auto;
  flex: 0 0 auto;
  align-self: stretch;
  margin: 0;
}

.feed-card-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 10px;
  padding: 10px 10px 8px;
  background: rgba(244, 248, 252, 0.88);
  border-bottom: 1px solid #edf2f7;
}

.feed-card-identity {
  display: flex;
  flex-direction: column;
  gap: 2px;
  min-width: 0;
}

.feed-card-title {
  margin: 0;
  font-size: 15px;
  font-weight: 600;
  color: #17324d;
  line-height: 1.2;
}

.feed-card-meta {
  margin: 0;
  font-size: 12px;
  color: #7b8794;
  line-height: 1.3;
}

.feed-card-menu,
.feed-card-menu-btn {
  margin: 0;
  font-size: 18px;
  line-height: 1;
  color: #7b8794;
}

.feed-card-menu-btn {
  border: none;
  background: transparent;
  padding: 0;
  cursor: pointer;
}

.feed-card-menu-btn:hover {
  color: #17324d;
}

.feed-card-body {
  display: flex;
  flex-direction: column;
  gap: 10px;
  padding: 10px 0 0;
  height: auto;
  overflow: visible;
}

.feed-card-text {
  margin: 0 12px;
  font-size: 17px;
  line-height: 1.6;
  color: #243447;
}

.feed-card-text:not(.report-text) {
  white-space: pre-line;
}
.feed-card.reporter,
.feed-card.mirror,
.feed-card.morning-light,
.feed-card.diary,
.feed-card.momentum,
.feed-card.checkpoint,
.feed-card.pulse,
.feed-card.visual-prompt {
  border-top: 1px solid #d7e2ee !important;
}

.feed-scroll-stack {
  position: static;
}

.feed-scroll-stack::before {
  content: none;
}

.feed-scroll-stack .feed-card {
  margin-left: 0 !important;
}

.feed-scroll-stack .feed-card::before {
  content: none;
}
/* ---------- Remove feed card top color lines ---------- */


/* ---------- Feed cards ---------- */

.feed-card {
  width: 100%;
  max-width: none;
  border-radius: 12px;
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.04);
}
/* ---------- Your Feed timeline spine ---------- */

/* ---------- Your Feed timeline spine (aligned version) ---------- */

/* ---------- Your Feed timeline spine (far left version) ---------- */


.feed-card.visual-prompt {
  background: #fbfdff;
  border: 1px dashed #c9d8e8;
}

.feed-card.visual-prompt .feed-card-title {
  color: #1e3a5f;
}

.feed-card.visual-prompt .feed-card-text {
  color: #4b6075;
}
.feed-card-link-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: fit-content;
  margin-top: 2px;
  padding: 8px 12px;
  border-radius: 10px;
  border: 1px solid #cbd5e1;
  background: #ffffff;
  color: #17324d;
  font-size: 13px;
  font-weight: 700;
  text-decoration: none;
  box-shadow: 0 2px 6px rgba(23, 50, 77, 0.06);
}

.feed-card-link-btn:hover {
  background: #f8fbff;
  border-color: #b8c7d8;
}
.diary-spotlight {
  animation: diarySpotlightGlow 1.8s ease;
}

@keyframes diarySpotlightGlow {
  0% {
    background: #ffffff;
    border-color: #d7e2ec;
    box-shadow: 0 8px 22px rgba(23, 50, 77, 0.08);
  }
  20% {
    background: #f3fff8;
    border-color: #24996c;
    box-shadow: 0 0 0 4px rgba(36, 153, 108, 0.22), 0 10px 26px rgba(36, 153, 108, 0.14);
  }
  60% {
    background: #f7fff9;
    border-color: #24996c;
    box-shadow: 0 0 0 6px rgba(36, 153, 108, 0.14), 0 10px 26px rgba(36, 153, 108, 0.10);
  }
  100% {
    background: #ffffff;
    border-color: #d7e2ec;
    box-shadow: 0 8px 22px rgba(23, 50, 77, 0.08);
  }
}
.visual-prompt-complete {
  animation: visualPromptCompleteGlow 1.8s ease;
}

@keyframes visualPromptCompleteGlow {
  0% {
    background: #fbfdff;
    border-color: #c9d8e8;
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.04);
  }
  20% {
    background: #f3fff8;
    border-color: #24996c;
    box-shadow: 0 0 0 4px rgba(36, 153, 108, 0.22), 0 10px 26px rgba(36, 153, 108, 0.14);
  }
  60% {
    background: #f7fff9;
    border-color: #24996c;
    box-shadow: 0 0 0 6px rgba(36, 153, 108, 0.14), 0 10px 26px rgba(36, 153, 108, 0.10);
  }
  100% {
    background: #fbfdff;
    border-color: #c9d8e8;
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.04);
  }
}


.feed-today-header {
  margin: 0 0 14px 0;
  padding: 14px 14px 12px;
  border: 1px solid #c8d9e8;
  
  border-radius: 16px;
  background: linear-gradient(to right, #e8f2ff 0%, #f3f9ff 52%, #edf9f0 100%);
  box-shadow: 0 6px 16px rgba(23, 50, 77, 0.08);
}
.feed-today-kicker {
  margin: 0 0 8px;
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: #58718c;
  line-height: 1.2;
}
.feed-today-text {
  margin: 0;
  font-size: 18px;
  line-height: 1.25;
  color: #17324d;
  font-weight: 800;
  text-shadow: 0 1px 0 rgba(255, 255, 255, 0.35);
}
.tab-panel {
  display: none;
  height: auto;
  overflow: visible;
}

.tab-panel.is-active {
  display: block;
}
.feed-card-body img,
.feed-card-body .feed-image,
.feed-card img,
.feed-card .feed-image {
  display: block;
  width: 100%;
  max-width: 100%;
  height: auto;
  border-radius: 0;
}
.feed-post-image {
  display: block;
  width: 100%;
  max-width: 100%;
  height: auto;
  margin: 0;
  border-radius: 0 0 12px 12px;
  object-fit: cover;
}
#section-feed > .section-card:last-child {
  padding-top: 0;
  padding-left: 0;
  padding-right: 0;
  padding-bottom: 0;
}
.more-subnav {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 6px;
  margin: 6px 0 10px 0;
  position: relative;
  z-index: 1;
}
.more-subtab {
  border: 1px solid #2f6fa3;
  background: #2f6fa3;
  color: #ffffff;
  border-radius: 10px;
  min-height: 40px;
  padding: 8px 4px;
  font-size: 12px;
  font-weight: 700;
  cursor: pointer;
}

.more-subtab.is-active {
  background: #2f8f5b;
  border-color: #2f8f5b;
}

.more-panel {
  display: none;
  position: relative;
}

.more-panel.is-active {
  display: block;
}
.more-panel.is-active::after {
  content: "";
  position: sticky;
  display: block;
  bottom: 0;
  height: 28px;
  margin-top: -28px;
  pointer-events: none;
  background: linear-gradient(to bottom, rgba(244, 248, 252, 0), rgba(244, 248, 252, 0.96));
  border-radius: 0 0 14px 14px;
}
.feed-inline-composer {
  margin-top: 14px;
  padding: 14px;
  border: 1px solid #d7e3ee;
  border-radius: 16px;
  background: linear-gradient(to bottom, #f8fbff, #f4f8fc);
  box-shadow: inset 0 1px 0 rgba(255,255,255,0.55);
}

.feed-inline-textarea {
  width: 100%;
  min-height: 88px;
  resize: vertical;
  border: 1px solid #b9cbe0;
  border-radius: 14px;
  padding: 12px 13px;
  font: inherit;
  font-size: 15px;
  line-height: 1.45;
  color: #17324d;
  background: #ffffff;
  box-sizing: border-box;
}

.feed-inline-textarea:focus {
  outline: none;
  border-color: #7aa7d9;
  box-shadow: 0 0 0 3px rgba(122, 167, 217, 0.16);
}

.feed-inline-upload-row {
  margin-top: 12px;
  padding: 10px 12px;
  border: 1px solid #d8e4ee;
  border-radius: 12px;
  background: rgba(255,255,255,0.7);
}

.feed-inline-upload-label {
  display: block;
  margin-bottom: 6px;
  font-size: 13px;
  font-weight: 700;
  color: #17324d;
}

#feed-diary-image-input {
  display: block;
  width: 100%;
  font: inherit;
  font-size: 13px;
  color: #35506b;
}

.feed-inline-preview-wrap {
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin-top: 12px;
}

.feed-inline-preview-image {
  width: 100%;
  max-height: 320px;
  object-fit: cover;
  border-radius: 14px;
  border: 1px solid #d7e3ee;
}

.feed-inline-actions {
  display: flex;
  gap: 8px;
  margin-top: 14px;
}

.feed-inline-primary-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 46px;
  padding: 0 18px;
  border: none;
  border-radius: 14px;
  background: linear-gradient(to right, var(--accent) 0%, var(--accent-2) 100%);
  color: #ffffff;
  font-size: 14px;
  font-weight: 700;
  cursor: pointer;
  box-shadow: 0 6px 14px rgba(31, 114, 191, 0.18);
}

.feed-inline-primary-btn:hover {
  transform: translateY(-1px);
}

.feed-inline-secondary-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: fit-content;
  min-height: 38px;
  padding: 0 14px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: #ffffff;
  color: var(--text);
  font-size: 13px;
  font-weight: 700;
  cursor: pointer;
}
.feed-card.visual-prompt .feed-card-text {
  margin: 0 12px;
  font-size: 17px;
  line-height: 1.5;
  white-space: pre-line;
}
.feed-file-input-wrap input[type="file"] {
  width: 100%;
  font: inherit;
  font-size: 13px;
  color: #35506b;
}

.feed-file-input-wrap input[type="file"]::file-selector-button {
  margin-right: 10px;
  padding: 6px 12px;
  border-radius: 10px;
  border: 1px solid var(--line);
  background: #ffffff;
  color: var(--text);
  font-weight: 700;
  cursor: pointer;
  transition: all 0.15s ease;
}

.feed-file-input-wrap input[type="file"]::file-selector-button:hover {
  background: #f4f8fc;
  border-color: #c5d6e6;
}
.feed-inline-upload-row {
  margin-top: 10px;
}

.feed-inline-actions {
  margin-top: 12px;
}
/* ---------- NAV LOCKDOWN ---------- */

.tab-panel {
  display: none !important;
}

.tab-panel.is-active {
  display: block !important;
}

.more-panel {
  display: none !important;
}

.more-panel.is-active {
  display: block !important;
}
.home-text-fade {
  opacity: 0;
  transform: translateY(4px);
  transition: opacity 0.4s ease, transform 0.4s ease;
}

.home-text-visible {
  opacity: 1;
  transform: translateY(0);
}
.day-replay-bar {
  display: flex;
  align-items: center;
  gap: 8px;
  margin: 8px 0 2px;
  padding: 8px 10px;
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.58);
  backdrop-filter: blur(6px);
  width: 100%;
  box-sizing: border-box;
}

.replay-btn {
  border: 1px solid rgba(30, 41, 59, 0.12);
  padding: 7px 12px;
  border-radius: 10px;
  font-size: 13px;
  font-weight: 700;
  cursor: pointer;
  background: rgba(15, 23, 42, 0.06);
  color: #1e293b;
  white-space: nowrap;
}

.replay-btn.primary {
  background: #1e3a5f;
  color: #ffffff;
  border-color: #1e3a5f;
}

.replay-btn:disabled {
  opacity: 0.55;
  cursor: default;
}

.day-replay-status-inline {
  font-size: 12px;
  line-height: 1.35;
  color: #486581;
  min-width: 0;
}
.replay-btn:not(.primary) {
  background: rgba(15, 23, 42, 0.04);
  color: #64748b;
}
.practice-zone {
  display: inline-block;
  margin: 8px 0 0;
  padding: 4px 10px;
  font-size: 14px;
  font-weight: 900;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: #1f2937;
  background: rgba(255,255,255,0.55);
  border-radius: 999px;
}

.practice-subtext {
  margin: 6px 0 0;
  font-size: 13px;
  line-height: 1.35;
  color: #64748b;
}
/* 🔥 Phase 6 Step 1 — First Entry Impact */
.first-entry-impact {
  animation: firstEntryPulse 0.9s ease-out;
}

@keyframes firstEntryPulse {
  0% {
    transform: scale(1);
    filter: brightness(1);
  }
  30% {
    transform: scale(1.03);
    filter: brightness(1.25);
  }
  60% {
    transform: scale(0.995);
    filter: brightness(1.1);
  }
  100% {
    transform: scale(1);
    filter: brightness(1);
  }
}

.pulse-option-btn,
.checkpoint-option-btn,
.option-btn {
  line-height: 1.15;
}


.feed-card.mirror {
  background: linear-gradient(to right, rgba(217, 200, 234, 0.42), rgba(255, 255, 255, 0.96) 48%, #fbfdff 100%);
}

.feed-card.morning-light {
  background: linear-gradient(to right, rgba(240, 220, 150, 0.42), rgba(255, 255, 255, 0.96) 48%, #fbfdff 100%);
}

.feed-card.pulse {
  background: linear-gradient(to right, rgba(183, 207, 231, 0.42), rgba(255, 255, 255, 0.96) 48%, #fbfdff 100%);
}

.feed-card.checkpoint {
  background: linear-gradient(to right, rgba(189, 217, 195, 0.42), rgba(255, 255, 255, 0.96) 48%, #fbfdff 100%);
}

.feed-card.diary {
  background: linear-gradient(to right, rgba(207, 215, 223, 0.38), rgba(255, 255, 255, 0.96) 48%, #fbfdff 100%);
}
.feed-card.mirror .card-header {
  background: rgba(217, 200, 234, 0.25);
}

.feed-card.morning-light .card-header {
  background: rgba(240, 220, 150, 0.28);
}

.feed-card.pulse .card-header {
  background: rgba(183, 207, 231, 0.28);
}

.feed-card.checkpoint .card-header {
  background: rgba(189, 217, 195, 0.28);
}

.feed-card.diary .card-header {
  background: rgba(207, 215, 223, 0.25);
}

.feed-card-question {
  margin: 0 10px;
  font-size: 14px;
  line-height: 1.55;
  color: #243447;
}

.feed-card-answer {
  margin: 8px 10px 4px 10px;
  padding: 10px 12px;
  font-size: 17px;
  line-height: 1.6;
  font-weight: 700;
  color: #0f172a;
  background: #f1f5f9;
  border-radius: 8px;
}


.sticky-top-shell {
  transform: translateZ(0);
}

/* ---------- Home sticky fix ---------- */

#tab-home,
#section-home,
.home-hero-card,
#home-hero-card,
.home-scene,
#home-scene {
  position: relative;
  z-index: 0 !important;
}

.home-scene,
#home-scene {
  transform: none !important;
}html,
body,
#mainApp,
.app-shell,
.app-main,
#tab-home {
  overflow-x: hidden;
}
@media (max-width: 420px) {
  .app-brand-row {
    width: 100%;
  }

  .app-live-stats {
    padding: 7px 7px 6px;
  }

  .top-save-confirmation {
    display: none;
  }
}
@media (max-width: 420px) {
  .entry-category-btn {
    font-size: 8px;
    padding: 6px 6px;
  }
}
.action-meta-row {
  display: flex;
  align-items: stretch;
  gap: 8px;
  flex-wrap: wrap;
}

.action-meta-row .score-box {
  flex: 1 1 140px;
  min-width: 140px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.action-meta-row .action-inline {
  flex: 1 1 140px;
  min-width: 140px;
  display: flex;
  align-items: center;
  justify-content: center;
}
.entry-type-grid.entry-type-grid-compact {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
}

.entry-type-grid.entry-type-grid-compact .entry-type-card {
  width: 100%;
}
/* FINAL DAILY AWARENESS CLEANUP */

.awareness-stack-card {
  padding: 14px !important;
}

.awareness-stack-body {
  gap: 6px !important;
}

.awareness-module,
.mirror-card,
.pulse-card,
.checkpoint-card,
#morning-light-section {
  padding: 10px 12px !important;
  border-radius: 12px !important;
  box-shadow: none !important;
}

.mirror-answered,
.pulse-answered,
.checkpoint-answered {
  margin-top: 8px !important;
  padding: 10px 12px !important;
  border-radius: 12px !important;
  background: rgba(255,255,255,0.72) !important;
  border: 1px solid #d7e2ec !important;
}

.mirror-answered p,
.checkpoint-answered p {
  margin-bottom: 4px !important;
}

.mirror-card .section-label,
.pulse-card .section-label,
.checkpoint-card .section-label,
#morning-light-section .section-label {
  margin-bottom: 4px !important;
}

.mirror-card .section-title,
.pulse-card .section-title,
.checkpoint-card .section-title,
#checkpoint-question-title {
  font-size: 17px !important;
  line-height: 1.35 !important;
  font-weight: 700 !important;
  margin-bottom: 6px !important;
}

.mirror-card .section-text,
.pulse-card .section-text,
.checkpoint-card .section-text {
  font-size: 13px !important;
  line-height: 1.35 !important;
}
/* MATCH DAILY AWARENESS COLORS TO FEED INTENSITY */

.mirror-card {
  background: linear-gradient(to right, rgba(217, 200, 234, 0.18), rgba(255,255,255,0.96) 48%, #fbfdff 100%) !important;
}

#morning-light-section {
  background: linear-gradient(to right, rgba(240, 220, 150, 0.18), rgba(255,255,255,0.96) 48%, #fbfdff 100%) !important;
}

.pulse-card {
  background: linear-gradient(to right, rgba(183, 207, 231, 0.18), rgba(255,255,255,0.96) 48%, #fbfdff 100%) !important;
}

.checkpoint-card {
  background: linear-gradient(to right, rgba(189, 217, 195, 0.18), rgba(255,255,255,0.96) 48%, #fbfdff 100%) !important;
}
/* EXACT FEED COLORS FOR HOME DAILY AWARENESS STACK */

.mirror-card {
  background: linear-gradient(to right, rgba(217, 200, 234, 0.42), rgba(255, 255, 255, 0.96) 48%, #fbfdff 100%) !important;
}

#morning-light-section {
  background: linear-gradient(to right, rgba(240, 220, 150, 0.42), rgba(255, 255, 255, 0.96) 48%, #fbfdff 100%) !important;
}

.pulse-card {
  background: linear-gradient(to right, rgba(183, 207, 231, 0.42), rgba(255, 255, 255, 0.96) 48%, #fbfdff 100%) !important;
}

.checkpoint-card {
  background: linear-gradient(to right, rgba(189, 217, 195, 0.42), rgba(255, 255, 255, 0.96) 48%, #fbfdff 100%) !important;
}
/* Actscription Report button - match Post to Your Feed */

.report-collapsible {
  width: calc(100% - 20px);
  max-width: calc(100% - 20px);
  margin: 0 10px;
  box-sizing: border-box;
  overflow: hidden;
  border-radius: 14px;
}

.report-collapsible > summary.feed-inline-primary-btn {
  width: 100%;
  max-width: 100%;
  min-height: 46px;
  margin: 0;
  padding: 12px 16px;
  display: flex;
  align-items: center;
  justify-content: center;
  box-sizing: border-box;
  overflow: hidden;
  border-radius: 14px;
  list-style: none;
  color: #ffffff !important;
  font-size: 14px !important;
  font-weight: 700;
  text-align: center;
}

.report-collapsible > summary.feed-inline-primary-btn::-webkit-details-marker {
  display: none;
}

.report-collapsible > summary.feed-inline-primary-btn::before {
  content: none !important;
  display: none !important;
}
.feed-inline-primary-btn {
  width: 100% !important;
  max-width: 100% !important;
  margin: 0 !important;
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
  box-sizing: border-box !important;
}
.latest-entry {
  border: 1.5px solid #6bbf8f;
  box-shadow: 0 4px 12px rgba(0,0,0,0.06);
}
.feed-inline-primary-btn {
  width: 100%;
  text-align: center;
  border-radius: 14px;
  font-weight: 600;
  padding: 12px 16px;
  transition: transform 0.08s ease, box-shadow 0.08s ease;
}

.feed-inline-primary-btn:active {
  transform: scale(0.98);
  box-shadow: 0 2px 6px rgba(0,0,0,0.15);
}
.report-text .feed-inline-primary-btn {
  display: block;
  margin: 4px 0 !important;
}
.report-text,
.report-text p {
  font-weight: 400 !important;
}

.report-text .report-section-header,
.report-text .report-section-header strong {
  font-weight: 700 !important;
}

.report-text .feed-inline-primary-btn {
  font-weight: 700 !important;
}
.moments-collapsible {
  width: calc(100% - 20px);
  margin: 0 10px 10px;
  box-sizing: border-box;
}

.moments-collapsible > summary.feed-inline-primary-btn {
  width: 100%;
  list-style: none;
}

.moments-collapsible > summary.feed-inline-primary-btn::-webkit-details-marker {
  display: none;
}
/* ===== FULLSCREEN REPLAY MODE ===== */

body.replay-fullscreen {
  overflow: hidden !important;
}

body.replay-fullscreen .sticky-top-shell {
  display: none !important;
}

body.replay-fullscreen .app-shell,
body.replay-fullscreen #mainApp,
body.replay-fullscreen .app-main,
body.replay-fullscreen #tab-home {
  width: 100vw !important;
  max-width: 100vw !important;
  margin: 0 !important;
  padding: 0 !important;
  overflow: hidden !important;
}

/* Hide everything on Home except scene + replay bar */
body.replay-fullscreen #tab-home > * {
  display: none !important;
}

body.replay-fullscreen #section-home,
body.replay-fullscreen .day-replay-bar {
  display: flex !important;
}

/* Fullscreen scene */
body.replay-fullscreen #home-scene {
  position: fixed !important;
  inset: 0 !important;
  width: 100vw !important;
  max-width: 100vw !important;
  height: 100vh !important;
  min-height: 100vh !important;
  border-radius: 0 !important;
  z-index: 99999 !important;
  transform: none !important;
  opacity: 0;
  animation: replayFadeIn 0.3s ease forwards;
}

/* Replay controls stay at bottom */
body.replay-fullscreen .day-replay-bar {
  position: fixed !important;
  left: 10px !important;
  right: 10px !important;
  bottom: 10px !important;
  width: auto !important;
  margin: 0 !important;
  z-index: 100000 !important;
}

/* Exit button stays visible */
body.replay-fullscreen #exit-replay-btn {
  display: block !important;
  position: fixed !important;
  top: 14px !important;
  right: 14px !important;
  z-index: 100001 !important;
}
@keyframes replayFadeIn {
  from {
    opacity: 0;
  }
  to {
    opacity: 1;
  }
}
/* Replay bar mobile layout */

.day-replay-bar {
  flex-wrap: wrap;
}

.day-replay-status-inline {
  flex: 1 1 100%;
  width: 100%;
  text-align: center;
  margin-top: 4px;
}
.home-scene-kicker {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.home-scene-property-name {
  font-size: 13px;
  font-weight: 900;
  letter-spacing: 0.08em;
}

.home-scene-label {
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.12em;
  opacity: 0.9;
}
.home-scene-kicker {
  align-items: center !important;
  text-align: center !important;
}

.home-scene-property-name,
.home-scene-label {
  text-align: center !important;
  font-size: 13px !important;
  line-height: 1.15 !important;
  font-weight: 900 !important;
  letter-spacing: 0.08em !important;
}
/* Replay progress bar */

#replay-progress-bar {
  display: none;
}

body.replay-fullscreen #replay-progress-bar {
  display: block !important;
  position: fixed !important;
  left: 12px !important;
  right: 12px !important;
  bottom: 4px !important;
  width: auto !important;
  height: 6px !important;
  border-radius: 999px !important;
  background: rgba(0, 0, 0, 0.28) !important;
  z-index: 100002 !important;
  overflow: hidden !important;
}

body.replay-fullscreen #replay-progress-fill {
  height: 100% !important;
  width: 0%;
  border-radius: 999px !important;
  background: rgba(255, 255, 255, 0.95) !important;
  transition: width linear;
}
/* Recent News right-side gradients */

.feed-card.recent-news.morning {
  background: linear-gradient(to left, rgba(254,249,195,0.6), #ffffff 60%);
}

.feed-card.recent-news.midday {
  background: linear-gradient(to left, rgba(224,242,254,0.6), #ffffff 60%);
}

.feed-card.recent-news.afternoon {
  background: linear-gradient(to left, rgba(220,252,231,0.6), #ffffff 60%);
}

.feed-card.recent-news.evening {
  background: linear-gradient(to left, rgba(237,233,254,0.6), #ffffff 60%);
}

.feed-card.recent-news.late {
  background: linear-gradient(to left, rgba(229,231,235,0.6), #ffffff 60%);
}

.feed-card.recent-news.daily_wrap {
  background: linear-gradient(to left, rgba(243,244,246,0.6), #ffffff 60%);
}
.feed-diary-composer input[type="file"] {
  width: 100%;
  font-size: 13px;
  padding: 10px;
  border: 1px solid #cfe0ef;
  border-radius: 12px;
  background: #ffffff;
  box-sizing: border-box;
}

.feed-diary-composer .diary-image-label {
  display: block;
  margin-bottom: 6px;
  font-size: 13px;
  font-weight: 700;
  color: #17324d;
}

.feed-diary-composer .note-counter {
  display: block;
  text-align: right;
  font-size: 12px;
  color: #5f7386;
}
.feed-photo-button {
  display: inline-flex !important;
  align-items: center;
  justify-content: center;
  min-height: 42px;
  width: 100%;
  border-radius: 14px;
  background: linear-gradient(135deg, #eef6ff, #ffffff);
  border: 1px solid #cfe0ef;
  color: #17324d !important;
  font-weight: 800 !important;
  cursor: pointer;
  box-sizing: border-box;
}
.feed-photo-button:hover {
  background: linear-gradient(135deg, #e6f0ff, #ffffff);
  border-color: #bcd6ee;
}

.feed-photo-button:active {
  transform: scale(0.98);
}
.feed-card.has-image .feed-image {
  display: block;
  width: 100%;
  margin-top: 10px;
  border-radius: 0 0 14px 14px;
  object-fit: cover;
}
/* Home Today’s Article card text polish */

#section-home .article-card p,
#section-home .today-article-card p,
#section-home .constitution-article-card p {
  font-size: 17px !important;
  line-height: 1.6 !important;
  color: #243447 !important;
}

#section-home .article-card a,
#section-home .today-article-card a,
#section-home .constitution-article-card a {
  font-size: 16px !important;
  line-height: 1.45 !important;
}
/* Home awareness box text polish */

#section-home .mirror-answered,
#section-home .pulse-answered,
#section-home .checkpoint-answered {
  font-size: 16px !important;
  line-height: 1.55 !important;
}

#section-home .mirror-answered p,
#section-home .pulse-answered p,
#section-home .checkpoint-answered p {
  font-size: 16px !important;
  line-height: 1.55 !important;
}
/* Stronger Home Today's Article text size */

#section-home [class*="article"] p,
#section-home [class*="article"] .section-text,
#section-home [class*="article"] .card-text {
  font-size: 17px !important;
  line-height: 1.65 !important;
  color: #243447 !important;
}

#section-home [class*="article"] a {
  font-size: 16px !important;
  line-height: 1.5 !important;
}
.today-article-text {
  font-size: 16px;
  line-height: 1.6;
  color: #243447;
}
.today-article-text {
  font-size: 17px !important;
  line-height: 1.6 !important;
  color: #243447 !important;
}
/* Awareness question text polish */



.mirror-answered,
.pulse-answered,
.checkpoint-answered {
  font-size: 16px !important;
  line-height: 1.6 !important;
}

.mirror-answered p,
.pulse-answered p,
.checkpoint-answered p {
  font-size: 16px !important;
  line-height: 1.6 !important;
}

/* Awareness answer spacing polish */

.mirror-answered,
.pulse-answered,
.checkpoint-answered {
  padding: 12px 14px !important;
}

.mirror-answered p,
.pulse-answered p,
.checkpoint-answered p {
  margin: 0 0 8px !important;
}

.mirror-answered p:last-child,
.pulse-answered p:last-child,
.checkpoint-answered p:last-child {
  margin-bottom: 0 !important;
}
/* Awareness card spacing between modules */

.awareness-stack-body {
  gap: 8px !important;
}
/* Diary note readability polish */

.diary-entry-card .entry-note {
  font-size: 15px !important;
  line-height: 1.6 !important;
  color: #243447 !important;
}
#section-awareness .mirror-answered,
#section-awareness .mirror-answered *,
#section-awareness .pulse-answered,
#section-awareness .pulse-answered *,
#section-awareness .checkpoint-answered,
#section-awareness .checkpoint-answered *,
#section-awareness #morning-light-answered,
#section-awareness #morning-light-answered * {
  font-size: 16px !important;
  line-height: 1.6 !important;
  font-weight: 400 !important;
}
/* FIX: Keep second dog hidden unless Connection makes it visible */
#scene-dog-secondary:not(.is-visible) {
  opacity: 0 !important;
  visibility: hidden !important;
  pointer-events: none !important;
}

#scene-dog-secondary.is-visible {
  opacity: 1 !important;
  visibility: visible !important;
}
/* 30-Day Report text polish */
#thirty-day-content {
  font-size: 16px !important;
  line-height: 1.6 !important;
}

#thirty-day-content p {
  font-size: 16px !important;
  line-height: 1.6 !important;
}

#thirty-day-content h4 {
  font-size: 16px !important;
  line-height: 1.35 !important;
}
.first-action-hint {
  animation: pulseHint 1s ease-in-out infinite;
  outline: 3px solid #22c55e !important;
  box-shadow: 0 0 0 8px rgba(34,197,94,0.25) !important;
  border-radius: 14px !important;
}

@keyframes pulseHint {
  0% { box-shadow: 0 0 0 4px rgba(34,197,94,0.45); }
  70% { box-shadow: 0 0 0 16px rgba(34,197,94,0); }
  100% { box-shadow: 0 0 0 4px rgba(34,197,94,0); }
}
.day-replay-bar {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 8px;
}

.day-replay-bar .replay-btn {
  flex: 1 1 46%;
  max-width: 190px;
  text-align: center;
}

.day-replay-status-inline {
  flex: 1 1 100%;
  text-align: center;
}
/* ---------- Home Scene Feedback Sign ---------- */

.scene-feedback-sign {
  position: absolute;
  left: 4px;
  bottom: 22px;
  width: 92px;
  height: 48px;
  z-index: 8;
  display: block;
  text-decoration: none;
  cursor: pointer;
  filter: drop-shadow(0 3px 5px rgba(0,0,0,0.25));
}

.feedback-sign-post {
  position: absolute;
  left: 58px;
  bottom: 0;
  width: 7px;
  height: 40px;
  border-radius: 4px;
  background: linear-gradient(to right, #5b341f, #8a5530, #4a2a18);
}

.feedback-sign-board {
  position: absolute;
  left: 0;
  top: 0;
  width: 86px;
  height: 25px;
  padding: 5px 7px 5px 15px;
  box-sizing: border-box;
  background: linear-gradient(to bottom, #f7d28a, #c9893f);
  color: #2f1b0f;
  font-size: 11px;
  line-height: 1;
  font-weight: 900;
  text-align: center;
  border: 2px solid rgba(78,43,22,0.75);
  text-shadow: 0 1px rgba(255,255,255,0.35);
  clip-path: polygon(22% 0, 100% 0, 100% 100%, 22% 100%, 0 50%);
}

.scene-feedback-sign:hover {
  transform: translateY(-1px);
}

.scene-feedback-sign:active {
  transform: scale(0.96);
}