:root {
  color-scheme: light;
  --bg: #f8f6f1;
  --surface: #ffffff;
  --surface-soft: #f1ebe2;
  --ink: #251c18;
  --muted: #766b64;
  --line: #e5ddd2;
  --coral: #cc6b5a;
  --coral-dark: #a84d40;
  --teal: #237782;
  --sage: #6e8a65;
  --violet: #6d5aa8;
  --amber: #a36a22;
  --danger: #b8464f;
  --shadow: 0 18px 50px rgba(67, 48, 38, 0.12);
  font-family: "Plus Jakarta Sans", sans-serif;
}

* {
  box-sizing: border-box;
}

html {
  width: 100%;
  min-height: 100%;
  overflow-x: hidden;
  overflow-y: auto;
  background: var(--bg);
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
}

body {
  width: 100%;
  min-height: 100vh;
  margin: 0;
  overflow-x: hidden;
  overflow-y: auto;
  background:
    linear-gradient(180deg, rgba(255, 236, 225, 0.62), rgba(248, 246, 241, 0) 420px),
    var(--bg);
  color: var(--ink);
}

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

button {
  cursor: pointer;
}

.sidebar {
  position: fixed;
  inset: 0 auto 0 0;
  width: 292px;
  display: flex;
  flex-direction: column;
  gap: 28px;
  padding: 24px;
  background:
    linear-gradient(180deg, rgba(204, 107, 90, 0.18), rgba(204, 107, 90, 0)),
    #2f2420;
  color: #fffaf2;
}

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

.brand-mark {
  width: 46px;
  height: 46px;
  display: grid;
  place-items: center;
  border-radius: 8px;
  background: #ffd7c8;
  color: #2f2420;
  font-weight: 900;
}

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

.brand small,
.notice p {
  color: rgba(255, 250, 242, 0.68);
}

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

.nav-item {
  min-height: 44px;
  display: flex;
  align-items: center;
  gap: 10px;
  border: 1px solid transparent;
  border-radius: 8px;
  padding: 0 12px;
  background: transparent;
  color: rgba(255, 250, 242, 0.78);
  text-align: left;
  font-weight: 700;
}

.nav-item.active,
.nav-item:hover {
  background: rgba(255, 255, 255, 0.1);
  color: #ffffff;
  border-color: rgba(255, 255, 255, 0.13);
}

.notice {
  margin-top: auto;
  padding: 16px;
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.13);
}

.notice p {
  margin: 8px 0 0;
  line-height: 1.45;
  font-size: 0.9rem;
}

.app-shell {
  margin-left: 292px;
  padding: 30px;
  display: grid;
  gap: 22px;
  max-width: 1520px;
}

.topbar {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 20px;
}

.topbar-actions {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 10px;
  flex-wrap: wrap;
  padding: 10px;
  border: 1px solid rgba(229, 221, 210, 0.9);
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.72);
  box-shadow: 0 12px 30px rgba(67, 48, 38, 0.08);
  backdrop-filter: blur(12px);
}

.sync-status,
.user-badge {
  min-height: 36px;
  padding: 0 13px;
  border-radius: 999px;
  font-size: 0.78rem;
  font-weight: 900;
}

.sync-status::before {
  content: "●";
  margin-right: 7px;
  font-size: 0.68rem;
}

.sync-status.online::before {
  color: var(--teal);
}

.user-badge {
  background: #fff0df;
  color: var(--amber);
  border: 1px solid rgba(163, 106, 34, 0.18);
}

#logoutBtn.ghost-button {
  min-height: 36px;
  padding: 0 14px;
  border-radius: 999px;
  background: var(--ink);
  color: #fff;
  font-size: 0.78rem;
}

#logoutBtn.ghost-button:hover {
  background: #3b2d27;
}

.topbar-actions .primary-action {
  min-height: 36px;
  padding: 0 16px;
  border-radius: 999px;
  font-size: 0.78rem;
  box-shadow: 0 10px 22px rgba(204, 107, 90, 0.18);
}

@media (max-width: 720px) {
  .topbar-actions {
    justify-content: stretch;
  }

  .sync-status,
  .user-badge,
  #logoutBtn.ghost-button,
  .topbar-actions .primary-action {
    width: 100%;
    justify-content: center;
  }
}

.eyebrow {
  margin: 0 0 8px;
  color: var(--teal);
  font-weight: 900;
  text-transform: uppercase;
  font-size: 0.76rem;
}

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

h1 {
  max-width: 900px;
  margin-bottom: 0;
  font-size: clamp(2.1rem, 4vw, 4.5rem);
  line-height: 0.96;
  letter-spacing: 0;
}

h2 {
  margin-bottom: 0;
  font-size: 1.05rem;
}

.primary-action,
.ghost-button {
  min-height: 42px;
  border: 0;
  border-radius: 8px;
  padding: 0 16px;
  font-weight: 900;
}

.primary-action {
  background: var(--coral);
  color: #fff;
  box-shadow: 0 12px 26px rgba(204, 107, 90, 0.22);
  white-space: nowrap;
}

.primary-action:hover {
  background: var(--coral-dark);
}

.ghost-button {
  background: var(--surface-soft);
  color: var(--ink);
}

.full {
  width: 100%;
}

.hero {
  position: relative;
  min-height: 220px;
  overflow: hidden;
  border-radius: 8px;
  background: #3f302b;
  box-shadow: var(--shadow);
}

.hero img {
  width: 100%;
  height: 100%;
  min-height: 220px;
  object-fit: cover;
  display: block;
}

.hero::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(90deg, rgba(47, 36, 32, 0.9), rgba(47, 36, 32, 0.52) 44%, rgba(47, 36, 32, 0.06));
}

.hero-copy {
  position: absolute;
  z-index: 1;
  left: clamp(18px, 4vw, 44px);
  bottom: clamp(18px, 4vw, 42px);
  max-width: 580px;
  color: #ffffff;
}

.hero-copy span {
  display: inline-flex;
  margin-bottom: 12px;
  color: #ffd7c8;
  font-weight: 900;
}

.hero-copy strong {
  display: block;
  font-size: clamp(1.35rem, 2.2vw, 2.25rem);
  line-height: 1;
}

.hero-copy p {
  margin: 12px 0 0;
  color: rgba(255, 255, 255, 0.78);
}

.stage-switch {
  display: grid;
  grid-template-columns: repeat(2, minmax(190px, 1fr));
  width: min(520px, 100%);
  gap: 8px;
  padding: 6px;
  border-radius: 8px;
  background: var(--surface);
  border: 1px solid var(--line);
}

.stage-tab {
  min-height: 58px;
  border: 0;
  border-radius: 7px;
  padding: 8px 14px;
  background: transparent;
  color: var(--muted);
  font-weight: 900;
  text-align: left;
}

.stage-tab.active {
  background: var(--ink);
  color: #fff;
}

.stage-tab span,
.stage-tab small {
  display: block;
}

.stage-tab small {
  margin-top: 3px;
  opacity: 0.72;
  font-size: 0.76rem;
}

.product-strip {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 14px;
}

.product-strip article {
  min-height: 116px;
  display: grid;
  align-content: start;
  gap: 8px;
  padding: 16px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.82);
  box-shadow: 0 10px 26px rgba(67, 48, 38, 0.06);
}

.product-strip span {
  color: var(--coral);
  font-size: 0.78rem;
  font-weight: 900;
}

.product-strip strong {
  font-size: 1rem;
}

.product-strip small {
  color: var(--muted);
  line-height: 1.45;
}

.hero.is-hidden,
.product-strip.is-hidden {
  display: none;
}

.section-intro {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 18px;
  padding: 16px 18px;
  border: 1px solid var(--line);
  border-left: 5px solid var(--coral);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.86);
  box-shadow: 0 10px 26px rgba(67, 48, 38, 0.05);
}

.section-intro.stage-born {
  border-left-color: var(--teal);
  background: linear-gradient(90deg, rgba(232, 244, 245, 0.9), rgba(255, 255, 255, 0.88));
}

.section-intro.stage-pregnancy {
  border-left-color: var(--coral);
  background: linear-gradient(90deg, rgba(255, 236, 225, 0.95), rgba(255, 255, 255, 0.88));
}

.section-intro span:first-child {
  display: inline-flex;
  margin-bottom: 6px;
  color: var(--coral);
  font-size: 0.76rem;
  font-weight: 900;
  text-transform: uppercase;
}

.section-intro h2 {
  margin: 0;
  font-size: 1.35rem;
}

.section-intro p {
  max-width: 760px;
  margin: 6px 0 0;
  color: var(--muted);
  line-height: 1.45;
}

.section-badge {
  min-height: 34px;
  display: inline-flex;
  align-items: center;
  border-radius: 999px;
  padding: 0 12px;
  background: var(--surface-soft);
  color: var(--ink);
  font-weight: 900;
  white-space: nowrap;
}

.view {
  display: none;
}

.view.active {
  display: grid;
  gap: 18px;
}

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

.metric,
.panel,
.library-card {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 8px;
  box-shadow: 0 10px 28px rgba(67, 48, 38, 0.06);
}

.metric:nth-child(2) {
  border-top: 3px solid var(--teal);
}

.metric:nth-child(3) {
  border-top: 3px solid var(--sage);
}

.metric:nth-child(4) {
  border-top: 3px solid var(--violet);
}

.metric {
  padding: 18px;
  display: grid;
  gap: 8px;
  min-height: 132px;
}

.metric span,
.muted,
.meta {
  color: var(--muted);
  font-size: 0.9rem;
}

.metric strong {
  font-size: 1.8rem;
  line-height: 1.05;
}

.metric small {
  color: var(--teal);
  font-weight: 800;
}

.content-grid,
.workbench {
  display: grid;
  grid-template-columns: minmax(0, 1.38fr) minmax(330px, 0.62fr);
  gap: 18px;
}

.child-workbench {
  align-items: start;
}

.child-main-column {
  display: grid;
  gap: 18px;
  min-width: 0;
}

.panel {
  min-width: 0;
  padding: 18px;
}

.panel-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 14px;
  margin-bottom: 16px;
}

.profile-form {
  display: grid;
  gap: 14px;
}

.child-birth-form {
  align-self: start;
  gap: 12px;
}

.child-birth-form .panel-header {
  margin-bottom: 8px;
}

.child-birth-form label {
  gap: 6px;
  font-size: 0.84rem;
}

.child-birth-form input,
.child-birth-form select {
  min-height: 38px;
  padding: 8px 10px;
  font-weight: 800;
}

.child-birth-form .split {
  gap: 10px;
}

.child-birth-form .primary-action {
  min-height: 40px;
  margin-top: 2px;
  box-shadow: 0 10px 20px rgba(204, 107, 90, 0.18);
}

.hidden {
  display: none !important;
}

label {
  min-width: 0;
  display: grid;
  gap: 7px;
  color: var(--muted);
  font-size: 0.9rem;
  font-weight: 800;
}

.field-hint {
  color: var(--muted);
  font-size: 0.78rem;
  font-weight: 700;
  line-height: 1.35;
}

input,
select,
textarea {
  width: 100%;
  max-width: 100%;
  min-width: 0;
  min-height: 44px;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 10px 12px;
  background: #fff;
  color: var(--ink);
}

textarea {
  resize: vertical;
  line-height: 1.45;
}

input[type="date"] {
  display: block;
  min-width: 0;
  max-width: 100%;
  line-height: 1.2;
  appearance: none;
  -webkit-appearance: none;
}

input[type="date"]::-webkit-date-and-time-value {
  min-height: 1.2em;
  text-align: left;
}

input[type="date"]::-webkit-calendar-picker-indicator {
  flex: 0 0 auto;
  margin-left: 4px;
}

input[readonly] {
  background: var(--surface-soft);
  color: var(--ink);
}

.split {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}

.timeline,
.checklist-grid,
.vaccine-list,
.alert-list {
  display: grid;
  gap: 10px;
}

.timeline-item,
.checklist-card,
.vaccine-item,
.alert-item,
.pregnancy-card,
.development-card {
  padding: 14px;
  border-radius: 8px;
  border: 1px solid var(--line);
  background: linear-gradient(180deg, #fffdfa, #ffffff);
}

.timeline-item {
  display: grid;
  grid-template-columns: auto 1fr auto;
  gap: 12px;
  align-items: center;
}

.timeline-item.checked {
  border-color: rgba(110, 138, 101, 0.36);
  background: linear-gradient(180deg, #eef8eb, #ffffff);
}

.timeline-item.past:not(.checked) {
  border-color: rgba(35, 119, 130, 0.2);
}

.timeline-check {
  display: grid;
  place-items: center;
  width: 30px;
  height: 30px;
}

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

.timeline-dot {
  width: 13px;
  height: 13px;
  border-radius: 999px;
  background: var(--coral);
  box-shadow: 0 0 0 5px rgba(204, 107, 90, 0.15);
}

.timeline-item.past .timeline-dot {
  background: var(--teal);
  box-shadow: 0 0 0 5px rgba(35, 119, 130, 0.12);
}

.timeline-item.checked .timeline-dot {
  width: 22px;
  height: 22px;
  display: grid;
  place-items: center;
  background: var(--sage);
  box-shadow: 0 0 0 5px rgba(110, 138, 101, 0.16);
}

.timeline-item.checked .timeline-dot::after {
  content: "✓";
  color: #fff;
  font-size: 0.8rem;
  font-weight: 900;
}

.timeline-item:hover,
.vaccine-item:hover,
.checklist-card:hover,
.library-card:hover {
  transform: translateY(-1px);
  box-shadow: 0 12px 28px rgba(67, 48, 38, 0.08);
}

.item-title {
  display: block;
  margin-bottom: 4px;
  font-weight: 900;
}

.pill {
  display: inline-flex;
  align-items: center;
  min-height: 28px;
  border-radius: 999px;
  padding: 0 10px;
  background: #e8f4f5;
  color: var(--teal);
  font-size: 0.78rem;
  font-weight: 900;
  white-space: nowrap;
}

.pill.warn {
  background: #fff0df;
  color: var(--amber);
}

.pill.danger {
  background: #ffe8ea;
  color: var(--danger);
}

.pill.done {
  background: #eef5ea;
  color: var(--sage);
}

.checklist-grid,
.library-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 14px;
}

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

.check-row {
  display: flex;
  align-items: center;
  gap: 9px;
  color: var(--ink);
  font-weight: 700;
}

.check-row input {
  width: 18px;
  min-height: 18px;
}

.pregnancy-card,
.development-card {
  display: grid;
  gap: 14px;
}

.development-summary {
  display: grid;
  gap: 4px;
  padding: 12px;
  border: 1px solid rgba(28, 126, 139, 0.2);
  border-radius: 8px;
  background: #edf8f8;
}

.development-summary span,
.development-summary small {
  color: var(--muted);
  font-weight: 800;
}

.development-summary strong {
  font-size: 1.2rem;
}

.tip-grid {
  display: grid;
  gap: 8px;
  margin-top: 8px;
}

.tip-card {
  display: block;
  padding: 10px 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface-soft);
  color: var(--muted);
  font-weight: 800;
}

.pregnancy-size-visual {
  display: grid;
  grid-template-columns: minmax(180px, 0.7fr) minmax(0, 1fr);
  gap: 14px;
  align-items: center;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fffdfa;
}

.pregnancy-size-visual img {
  width: 100%;
  aspect-ratio: 4 / 3;
  object-fit: cover;
  border-radius: 8px;
}

.pregnancy-size-visual span,
.pregnancy-size-visual p {
  margin: 0;
  color: var(--muted);
  font-weight: 800;
}

.pregnancy-size-visual strong {
  display: block;
  margin: 5px 0 7px;
  font-size: 1.4rem;
}

.pregnancy-highlight {
  display: grid;
  gap: 6px;
  padding: 14px;
  border: 1px solid rgba(35, 119, 130, 0.18);
  border-radius: 8px;
  background: #edf8f8;
}

.pregnancy-highlight span,
.pregnancy-highlight p {
  margin: 0;
  color: var(--muted);
  font-weight: 800;
}

.pregnancy-highlight strong {
  font-size: 1.2rem;
  line-height: 1.18;
}

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

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

.pregnancy-detail-card,
.question-card,
.admin-row {
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: linear-gradient(180deg, #fffdfa, #ffffff);
}

.question-card {
  color: var(--ink);
  font-weight: 900;
}

.reviewed-badge {
  width: fit-content;
  padding: 6px 9px;
  border-radius: 999px;
  background: #eef8eb;
  color: var(--sage);
  font-weight: 900;
}

.admin-workbench {
  align-items: start;
}

.admin-form,
.admin-list {
  display: grid;
  gap: 12px;
}

.admin-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.admin-row {
  display: grid;
  grid-template-columns: 86px minmax(0, 1fr) auto;
  gap: 12px;
  align-items: center;
}

.admin-thumb {
  width: 86px;
  height: 70px;
  object-fit: cover;
  border-radius: 8px;
  border: 1px solid var(--line);
}

.admin-row strong,
.admin-row p {
  display: block;
  margin: 8px 0 0;
}

.admin-row p {
  color: var(--muted);
  line-height: 1.45;
}

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

.fact {
  padding: 12px;
  border-radius: 8px;
  background: var(--surface-soft);
}

.fact span {
  display: block;
  color: var(--muted);
  font-size: 0.82rem;
  margin-bottom: 5px;
}

.fact strong {
  font-size: 1.1rem;
}

.copy-list {
  margin: 0;
  padding-left: 18px;
  color: var(--muted);
  line-height: 1.55;
}

.vaccine-item {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 12px;
  align-items: center;
}

.chart-wrap {
  min-height: 330px;
  overflow: hidden;
}

.growth-chart {
  width: 100%;
  height: 330px;
}

.chart-axis {
  stroke: #cfc5b8;
  stroke-width: 1;
}

.chart-line-weight {
  fill: none;
  stroke: var(--coral);
  stroke-width: 4;
}

.chart-line-length {
  fill: none;
  stroke: var(--teal);
  stroke-width: 4;
}

.chart-dot {
  fill: #fff;
  stroke-width: 3;
}

.library-tools {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(180px, 0.28fr);
  gap: 12px;
  margin-bottom: 14px;
}

.search-field {
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fffdfa;
}

.search-field span {
  color: var(--muted);
  font-size: 0.82rem;
  font-weight: 900;
}

.pagination {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  margin-top: 16px;
}

.pagination span {
  color: var(--muted);
  font-weight: 900;
}

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

#article.view.active {
  justify-items: center;
}

.article-view {
  width: min(920px, 100%);
  justify-self: center;
  display: grid;
  gap: 18px;
  padding: 18px;
}

.article-view > .ghost-button {
  width: fit-content;
  justify-self: start;
}

.article-hero {
  width: 100%;
  height: clamp(220px, 34vw, 340px);
  object-fit: cover;
  border-radius: 8px;
  border: 1px solid var(--line);
}

.article-meta-row {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
}

.article-view h2 {
  font-size: clamp(1.7rem, 3vw, 2.7rem);
  line-height: 1.05;
}

.article-lead {
  color: var(--muted);
  font-size: 1.05rem;
  line-height: 1.55;
  font-weight: 800;
}

.article-body {
  display: grid;
  gap: 12px;
  max-width: 760px;
}

.article-body p,
.article-empty {
  margin: 0;
  color: var(--ink);
  line-height: 1.7;
}

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

.library-card {
  padding: 16px;
  display: grid;
  align-content: start;
  gap: 10px;
  overflow: hidden;
}

.library-image {
  width: calc(100% + 32px);
  max-width: none;
  height: 168px;
  margin: -16px -16px 4px;
  object-fit: cover;
  border-bottom: 1px solid var(--line);
}

.library-card h3 {
  margin: 0;
  font-size: 1rem;
}

.library-card p {
  margin: 0;
  color: var(--muted);
  line-height: 1.48;
}

@media (max-width: 1120px) {
  .sidebar {
    position: static;
    width: auto;
    flex-direction: row;
    align-items: center;
    padding: 16px;
    overflow-x: auto;
  }

  .brand {
    min-width: 245px;
  }

  .nav {
    display: flex;
    min-width: max-content;
  }

  .notice {
    display: none;
  }

  .app-shell {
    margin-left: 0;
    padding: 18px;
  }

  .metrics-grid,
  .checklist-grid,
  .library-grid,
  .product-strip {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

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

@media (max-width: 720px) {
  html,
  body {
    max-width: 100%;
    overflow-x: hidden;
    }

  body {
    padding-bottom: calc(76px + env(safe-area-inset-bottom));
  }

  .app-shell,
  .view.active,
  .content-grid,
  .workbench,
  .panel,
  .topbar,
  .topbar > div,
  .section-intro,
  .hero,
  .stage-switch,
  .product-strip,
  .metrics-grid {
    width: 100%;
    max-width: 100%;
    min-width: 0;
  }

  h1,
  h2,
  p,
  .muted,
  .meta,
  .section-intro,
  .hero-copy,
  .user-badge,
  .nav-item span {
    overflow-wrap: anywhere;
  }

  .sidebar {
    position: fixed;
    inset: auto 0 0 0;
    z-index: 18;
    width: auto;
    display: block;
    padding: 8px 8px calc(8px + env(safe-area-inset-bottom));
    border-top: 1px solid rgba(255, 255, 255, 0.14);
    background: #2f2420;
    box-shadow: 0 -14px 38px rgba(47, 36, 32, 0.22);
    overflow: hidden;
    transform: translateZ(0);
    backface-visibility: hidden;
    contain: layout paint;
  }

  body::after {
    content: "";
    position: fixed;
    inset: auto 0 0 0;
    z-index: 17;
    height: calc(86px + env(safe-area-inset-bottom));
    background: #2f2420;
    pointer-events: none;
    transform: translateZ(0);
  }

  .sidebar .brand,
  .sidebar .notice {
    display: none;
  }

  .nav {
    width: 100%;
    min-width: 0;
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(44px, 1fr));
    gap: 4px;
  }

  .nav-item {
    min-height: 56px;
    justify-content: center;
    align-items: center;
    gap: 2px;
    padding: 5px 3px;
    border-radius: 8px;
    flex-direction: column;
    text-align: center;
    font-size: 1rem;
    line-height: 1;
  }

  .nav-item span {
    display: block;
    max-width: 100%;
    overflow: hidden;
    text-overflow: ellipsis;
    font-size: 0.68rem;
    line-height: 1.05;
  }

  .primary-action,
  .ghost-button,
  .section-badge,
  .stage-tab {
    max-width: 100%;
    white-space: normal;
  }

  .stage-tab {
    min-height: 48px;
    padding: 8px 10px;
  }

  .stage-tab small {
    font-size: 0.72rem;
  }

  .app-shell {
    padding: 14px 12px;
    gap: 16px;
  }

  .topbar,
  .timeline-item,
  .vaccine-item,
  .panel-header,
  .section-intro {
    display: grid;
  }

  .topbar-actions {
    width: 100%;
    justify-items: stretch;
  }

  h1 {
    font-size: clamp(1.75rem, 9vw, 2.15rem);
    line-height: 1.02;
  }

  .hero,
  .hero img {
    min-height: 260px;
  }

  .hero::after {
    background: linear-gradient(180deg, rgba(47, 36, 32, 0.12), rgba(47, 36, 32, 0.88));
  }

  .metrics-grid,
  .checklist-grid,
  .library-grid,
  .library-tools,
  .product-strip,
  .stage-switch,
  .split,
  .fact-grid,
  .pregnancy-size-visual,
  .pregnancy-list-grid,
  .pregnancy-detail-grid,
  .question-grid,
  .admin-row {
    grid-template-columns: 1fr;
  }

  .panel {
    padding: 14px;
  }

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

  .article-view {
    padding: 14px;
  }

  .article-hero {
    height: 220px;
  }

  #pregnancy,
  #pregnancy .workbench,
  #pregnancy .panel,
  #pregnancy .pregnancy-card,
  #pregnancy .timeline,
  #pregnancy .timeline-item {
    width: 100%;
    min-width: 0;
  }

  #pregnancy .timeline-item {
    grid-template-columns: auto minmax(0, 1fr);
    align-items: start;
  }

  #pregnancy .timeline-item .pill {
    grid-column: 2;
    justify-self: start;
  }

  .auth-screen {
    padding: 12px;
    place-items: stretch;
    overflow: hidden;
  }

  .auth-card {
    align-self: center;
    max-height: calc(100dvh - 24px);
    overflow-y: auto;
    overscroll-behavior: contain;
    padding: 16px;
  }

  .auth-forms {
    grid-template-columns: 1fr;
  }
}

.auth-screen {
  position: fixed;
  inset: 0;
  z-index: 20;
  overscroll-behavior: contain;
  display: grid;
  place-items: center;
  padding: 24px;
  background:
    linear-gradient(120deg, rgba(47, 36, 32, 0.9), rgba(47, 36, 32, 0.68)),
    url("assets/babyjourney-hero.png") center/cover no-repeat;
}

.auth-screen.hidden {
  display: none;
}

.auth-card {
  width: min(980px, 100%);
  display: grid;
  grid-template-columns: 0.9fr 1.1fr;
  gap: 24px;
  padding: 24px;
  border: 1px solid rgba(255, 255, 255, 0.24);
  border-radius: 8px;
  background: rgba(255, 250, 242, 0.96);
  box-shadow: var(--shadow);
}

.auth-card h1 {
  font-size: clamp(2rem, 4vw, 3.6rem);
}

.auth-copy {
  color: var(--muted);
  line-height: 1.55;
}

.auth-forms {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 14px;
}

.auth-form {
  display: grid;
  align-content: start;
  gap: 14px;
  padding: 16px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
}

.auth-message {
  grid-column: 1 / -1;
  min-height: 44px;
  margin: 0;
  display: flex;
  align-items: center;
  padding: 10px 12px;
  border: 1px solid transparent;
  border-radius: 8px;
  color: var(--muted);
  background: rgba(255, 255, 255, 0.68);
  font-weight: 800;
}

.auth-message:empty {
  min-height: 0;
  padding: 0;
  border: 0;
  background: transparent;
}

.auth-message.success {
  border-color: rgba(110, 138, 101, 0.32);
  color: var(--sage);
  background: #eef8eb;
}

.auth-message.error {
  border-color: rgba(181, 78, 63, 0.28);
  color: var(--danger);
  background: #fff0ed;
}

.auth-message.loading {
  border-color: rgba(28, 126, 139, 0.28);
  color: var(--teal);
  background: #edf8f8;
}

.user-badge {
  min-height: 30px;
  display: inline-flex;
  align-items: center;
  border-radius: 999px;
  padding: 0 10px;
  background: #e8f4f5;
  color: var(--teal);
  font-size: 0.78rem;
  font-weight: 900;
}

@media (max-width: 820px) {
  .auth-card,
  .auth-forms {
    grid-template-columns: 1fr;
  }
}

.save-dialog {
  width: min(420px, calc(100vw - 32px));
  border: 0;
  border-radius: 8px;
  padding: 26px;
  color: var(--ink);
  background: #fffdfa;
  box-shadow: 0 24px 70px rgba(47, 36, 32, 0.22);
  text-align: center;
}

.save-dialog::backdrop {
  background: rgba(47, 36, 32, 0.34);
}

.save-dialog-icon {
  width: 58px;
  height: 58px;
  display: grid;
  place-items: center;
  margin: 0 auto 16px;
  border-radius: 999px;
  background: #eef8eb;
  color: var(--sage);
  font-size: 1.9rem;
  font-weight: 900;
  box-shadow: 0 0 0 8px rgba(110, 138, 101, 0.12);
}

.save-dialog h2 {
  margin: 0 0 8px;
  font-size: 1.45rem;
}

.save-dialog p {
  margin: 0 0 20px;
  color: var(--muted);
  line-height: 1.5;
}

.save-toast {
  position: fixed;
  right: 22px;
  bottom: 22px;
  z-index: 30;
  display: flex;
  align-items: center;
  gap: 10px;
  max-width: min(360px, calc(100vw - 44px));
  padding: 12px 14px;
  border: 1px solid rgba(110, 138, 101, 0.28);
  border-radius: 8px;
  background: #eef8eb;
  color: var(--ink);
  box-shadow: 0 18px 45px rgba(47, 36, 32, 0.14);
  transform: translateY(120%);
  opacity: 0;
  transition: transform 180ms ease, opacity 180ms ease;
}

.save-toast.visible {
  transform: translateY(0);
  opacity: 1;
}

.save-toast span {
  width: 26px;
  height: 26px;
  display: grid;
  place-items: center;
  border-radius: 999px;
  background: var(--sage);
  color: #fff;
  font-weight: 900;
}

.save-dialog[open] {
  animation: saveDialogIn 180ms ease-out both;
}

.save-dialog[open]::backdrop {
  animation: saveBackdropIn 180ms ease-out both;
}

.save-dialog.closing {
  animation: saveDialogOut 140ms ease-in both;
}

.save-dialog.closing::backdrop {
  animation: saveBackdropOut 140ms ease-in both;
}

@keyframes saveDialogIn {
  from {
    opacity: 0;
    transform: translateY(14px) scale(0.96);
  }
  to {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

@keyframes saveDialogOut {
  from {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
  to {
    opacity: 0;
    transform: translateY(10px) scale(0.97);
  }
}

@keyframes saveBackdropIn {
  from { opacity: 0; }
  to { opacity: 1; }
}

@keyframes saveBackdropOut {
  from { opacity: 1; }
  to { opacity: 0; }
}

@media (prefers-reduced-motion: reduce) {
  .save-dialog[open],
  .save-dialog[open]::backdrop,
  .save-dialog.closing,
  .save-dialog.closing::backdrop,
  .save-toast {
    animation: none;
    transition: none;
  }
}

.chart-line-head {
  fill: none;
  stroke: var(--violet);
  stroke-width: 3;
  stroke-dasharray: 7 5;
}

.growth-summary {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
  margin-bottom: 14px;
}

.growth-stat {
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fffdfa;
}

.growth-stat.active {
  border-color: rgba(204, 107, 90, 0.38);
  background: #fff0ea;
}

.growth-stat span,
.growth-stat small {
  display: block;
  color: var(--muted);
  font-size: 0.82rem;
  font-weight: 800;
}

.growth-stat strong {
  display: block;
  margin: 5px 0;
  font-size: 1.35rem;
}

.growth-modes {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 12px;
}

.growth-mode {
  min-height: 38px;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 0 13px;
  background: #fff;
  color: var(--muted);
  font-weight: 900;
}

.growth-mode.active {
  background: var(--ink);
  color: #fff;
  border-color: var(--ink);
}

.chart-grid {
  stroke: #eadfd3;
  stroke-width: 1;
}

.chart-label,
.chart-date,
.chart-title,
.chart-delta {
  fill: #766b64;
  font-size: 12px;
  font-weight: 800;
}

.chart-title {
  fill: var(--ink);
  font-size: 15px;
}

.chart-line-active {
  fill: none;
  stroke-width: 5;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.chart-point {
  fill: #fff;
  stroke-width: 4;
}

.growth-history {
  display: grid;
  gap: 8px;
  margin-top: 12px;
}

.history-row {
  display: grid;
  grid-template-columns: 1.2fr repeat(3, 1fr);
  gap: 10px;
  padding: 10px 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fffdfa;
  color: var(--muted);
  font-size: 0.9rem;
}

.history-row strong {
  color: var(--ink);
}

@media (max-width: 720px) {
  .growth-summary,
  .history-row {
    grid-template-columns: 1fr;
  }
}

.history-row {
  grid-template-columns: 1.1fr repeat(3, 0.8fr) auto;
  align-items: center;
}

.history-actions {
  display: flex;
  gap: 6px;
  justify-content: flex-end;
}

.small-action {
  min-height: 32px;
  padding: 0 10px;
  font-size: 0.82rem;
}

.danger-button {
  min-height: 42px;
  border: 0;
  border-radius: 8px;
  padding: 0 14px;
  background: #ffe8ea;
  color: var(--danger);
  font-weight: 900;
}

.danger-button:hover {
  background: #ffd8dc;
}

@media (max-width: 720px) {
  .history-actions {
    justify-content: stretch;
  }

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

.growth-insights {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
  margin: 0 0 12px;
}

.insight-card {
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fffdfa;
}

.insight-card.primary {
  border-color: rgba(35, 119, 130, 0.28);
  background: #e8f4f5;
}

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

.insight-card strong {
  margin-bottom: 6px;
  color: var(--ink);
}

.insight-card span {
  color: var(--muted);
  line-height: 1.45;
  font-size: 0.9rem;
}

.history-row {
  grid-template-columns: 1.2fr repeat(2, 0.9fr) auto;
}

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

@media (max-width: 920px) {
  .growth-insights {
    grid-template-columns: 1fr;
  }
}

.panel-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  justify-content: flex-end;
}

@media (max-width: 720px) {
  .panel-actions {
    justify-content: stretch;
  }

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

.growth-entry-form {
  align-self: start;
  display: grid;
  gap: 14px;
  padding: 18px;
}

.growth-form-head {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 12px;
  align-items: start;
  padding-bottom: 12px;
  border-bottom: 1px solid var(--line);
}

.growth-form-head h2 {
  margin: 0 0 5px;
  font-size: 1.1rem;
}

.growth-form-head p {
  margin: 0;
  color: var(--muted);
  line-height: 1.45;
  font-size: 0.9rem;
}

.growth-form-icon {
  width: 38px;
  height: 38px;
  display: grid;
  place-items: center;
  border-radius: 8px;
  background: #e8f4f5;
  color: var(--teal);
  font-size: 1.35rem;
  font-weight: 900;
}

.field-card {
  gap: 9px;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fffdfa;
}

.field-card > span {
  color: var(--ink);
  font-size: 0.88rem;
  font-weight: 900;
}

.field-card input {
  width: 100%;
  min-width: 0;
  min-height: 42px;
  border-color: transparent;
  background: #fff;
  box-shadow: inset 0 0 0 1px var(--line);
}

.date-field input {
  font-weight: 800;
}

.measurement-fields {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
}

.unit-input {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
  gap: 8px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  padding-right: 10px;
}

.unit-input input {
  border: 0;
  box-shadow: none;
  font-size: 1.1rem;
  font-weight: 900;
}

.unit-input strong {
  color: var(--muted);
  font-size: 0.9rem;
}

.form-help {
  padding: 10px 12px;
  border-radius: 8px;
  background: #f6f1ea;
  color: var(--muted);
  font-size: 0.86rem;
  line-height: 1.4;
}

.compact-submit {
  min-height: 48px;
}

@media (max-width: 720px) {
  .measurement-fields,
  .growth-form-head {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 720px) {
  .auth-screen {
    padding: 12px;
    place-items: stretch;
    overflow: hidden;
  }

  .auth-card {
    align-self: center;
    max-height: calc(100dvh - 24px);
    overflow-y: auto;
    overscroll-behavior: contain;
    padding: 16px;
  }

  .auth-forms {
    grid-template-columns: 1fr;
  }
}




.community-hero {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  border-left: 5px solid var(--teal);
  background: linear-gradient(90deg, #effafa, #fffdfa 72%);
}

.community-hero h2 {
  margin: 6px 0;
  font-size: clamp(1.4rem, 2vw, 2.1rem);
}

.community-hero p {
  max-width: 820px;
  margin: 0;
  color: var(--muted);
  line-height: 1.5;
}

.community-layout {
  display: grid;
  grid-template-columns: minmax(320px, 0.9fr) minmax(420px, 1.25fr) minmax(280px, 0.72fr);
  gap: 16px;
  align-items: start;
}

.community-board,
.community-side,
.community-thread {
  align-self: start;
}

.community-toolbar {
  margin-bottom: 12px;
}

.search-field {
  display: grid;
  gap: 7px;
  color: var(--muted);
  font-size: 0.86rem;
  font-weight: 900;
}

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

.community-post-card {
  display: block;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fffdfa;
  cursor: pointer;
  transition: border-color 160ms ease, background 160ms ease, transform 160ms ease;
}

.community-post-card:hover,
.community-post-card.active {
  border-color: rgba(39, 132, 142, 0.42);
  background: #f2fbfb;
  transform: translateY(-1px);
}

.community-post-main {
  min-width: 0;
}

.community-post-title-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 10px;
  align-items: start;
}

.community-post-title-row strong {
  color: var(--ink);
  font-size: 0.98rem;
  line-height: 1.25;
}

.community-post-main p {
  display: -webkit-box;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
  overflow: hidden;
  margin: 6px 0 9px;
  color: var(--muted);
  line-height: 1.35;
  font-size: 0.92rem;
}

.community-post-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 6px 10px;
  color: var(--muted);
  font-size: 0.82rem;
}

.community-post-meta span + span::before {
  content: "·";
  margin-right: 10px;
}

.reply-count {
  padding: 6px 9px;
  border-radius: 999px;
  background: #e8f4f5;
  color: var(--teal);
  font-size: 0.78rem;
  font-weight: 900;
  white-space: nowrap;
}

.community-form,
.reply-form {
  display: grid;
  gap: 12px;
}

.community-form textarea,
.reply-form textarea {
  min-height: 104px;
  resize: vertical;
}

.community-thread {
  min-height: 360px;
}

.community-thread-head {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  padding-bottom: 14px;
  border-bottom: 1px solid var(--line);
}

.community-thread-head h2 {
  margin: 5px 0;
  font-size: clamp(1.35rem, 2vw, 2rem);
  line-height: 1.15;
}

.community-thread-head p,
.reply-card span {
  color: var(--muted);
  font-size: 0.86rem;
}

.thread-body {
  margin: 16px 0;
  color: var(--ink);
  font-size: 1rem;
  line-height: 1.65;
  white-space: pre-wrap;
}

.reply-list {
  display: grid;
  gap: 14px;
  margin: 18px 0;
}

.reply-card {
  display: grid;
  grid-template-columns: 38px minmax(0, 1fr);
  gap: 10px;
  align-items: start;
}

.reply-avatar {
  width: 38px;
  height: 38px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  background: #e8f4f5;
  color: var(--teal);
  font-weight: 900;
  box-shadow: inset 0 0 0 1px rgba(39, 132, 142, 0.18);
}

.reply-content {
  padding: 12px 13px;
  border: 1px solid var(--line);
  border-radius: 8px 8px 8px 2px;
  background: #fffdfa;
}

.reply-card.own-reply .reply-content {
  border-color: rgba(39, 132, 142, 0.28);
  background: #f2fbfb;
}

.reply-card.own-reply .reply-avatar {
  background: #f6eae5;
  color: var(--coral);
  box-shadow: inset 0 0 0 1px rgba(209, 104, 87, 0.2);
}

.reply-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 7px;
}

.reply-head strong {
  display: block;
  color: var(--ink);
  line-height: 1.2;
}

.reply-head span {
  display: block;
  margin-top: 2px;
  color: var(--muted);
  font-size: 0.8rem;
}

.reply-card p {
  margin: 0;
  color: var(--ink);
  line-height: 1.5;
  white-space: pre-wrap;
}

.community-pagination {
  margin-top: 12px;
}

.community-empty {
  padding: 18px;
  border: 1px dashed var(--line);
  border-radius: 8px;
  background: #fffdfa;
  color: var(--muted);
  line-height: 1.5;
}

.community-empty.compact {
  padding: 12px;
}

.community-empty.error {
  border-color: rgba(177, 75, 64, 0.35);
  background: #fff1ee;
  color: var(--danger);
}

@media (max-width: 1280px) {
  .community-layout {
    grid-template-columns: minmax(330px, 0.95fr) minmax(420px, 1.25fr);
  }

  .community-side {
    grid-column: 1 / -1;
  }
}

@media (max-width: 920px) {
  .community-hero,
  .community-thread-head {
    flex-direction: column;
    align-items: stretch;
  }

  .community-layout {
    grid-template-columns: 1fr;
  }

  .community-side {
    grid-column: auto;
  }

  .community-thread {
    min-height: 0;
  }
}




.community-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-top: 10px;
}

.reply-head .community-actions {
  margin-top: 0;
  justify-content: flex-end;
}

.reply-head .small-action {
  min-height: 30px;
  padding: 6px 8px;
  font-size: 0.78rem;
}

@media (max-width: 720px) {
  .reply-card {
    grid-template-columns: 32px minmax(0, 1fr);
  }

  .reply-avatar {
    width: 32px;
    height: 32px;
    font-size: 0.85rem;
  }

  .reply-head {
    display: grid;
  }

  .reply-head .community-actions {
    justify-content: flex-start;
  }
}

.community-header-meta {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 10px;
}


.community-warning {
  margin-top: 12px;
  padding: 10px 22px;
  border: 1px solid rgba(184, 70, 79, 0.22);
  border-radius: 12px;
  background: #fff0ed;
  color: #dc2626 !important;
  font-size: 0.86rem;
  font-weight: 800;
  line-height: 1.45;
}


.moderation-reports {
  display: grid;
  gap: 10px;
  padding: 12px;
  border: 1px solid rgba(177, 75, 64, 0.22);
  border-radius: 8px;
  background: #fff7f5;
  color: var(--ink);
}

.moderation-reports-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}

.moderation-reports-head strong {
  color: var(--danger);
  font-size: 1rem;
}

.moderation-reports-head span {
  min-width: 30px;
  height: 30px;
  display: grid;
  place-items: center;
  border-radius: 999px;
  background: #ffe4df;
  color: var(--danger);
  font-weight: 900;
}

.moderation-report-card {
  display: grid;
  gap: 8px;
  padding: 12px;
  border: 1px solid rgba(177, 75, 64, 0.18);
  border-radius: 8px;
  background: #fffdfa;
}

.report-topline,
.report-details,
.report-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 6px 10px;
  align-items: center;
}

.report-type {
  padding: 4px 8px;
  border-radius: 999px;
  background: #ffe4df;
  color: var(--danger);
  font-size: 0.78rem;
  font-weight: 900;
}

.report-topline time,
.report-details span {
  color: var(--muted);
  font-size: 0.82rem;
}

.report-body {
  margin: 0;
  color: var(--ink);
  line-height: 1.45;
  font-size: 0.92rem;
}

.report-actions {
  padding-top: 4px;
}

.thread-actions {
  margin: -6px 0 14px;
}

.report-action {
  color: var(--muted);
}

.community-warning {
  grid-column: 1 / -1;
  color: var(--muted);
  font-size: 0.88rem;
  line-height: 1.45;
}

.home-personal {
  display: grid;
  grid-template-columns: minmax(0, 1.05fr) minmax(340px, 0.95fr);
  gap: 16px;
  align-items: stretch;
}

.home-today-card,
.home-community-card {
  min-width: 0;
  border: 1px solid rgba(229, 221, 210, 0.92);
  border-radius: 10px;
  background: rgba(255, 253, 250, 0.92);
  box-shadow: 0 14px 34px rgba(67, 48, 38, 0.07);
}

.home-today-card {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(230px, 0.62fr);
  gap: 16px;
  padding: 20px;
  background:
    linear-gradient(135deg, rgba(255, 236, 225, 0.96), rgba(255, 253, 250, 0.94) 52%, rgba(232, 244, 245, 0.78)),
    #fffdfa;
}

.home-kicker,
.home-card-head span {
  display: inline-flex;
  margin-bottom: 7px;
  color: var(--coral);
  font-size: 0.76rem;
  font-weight: 900;
  text-transform: uppercase;
}

.home-today-main h3,
.home-card-head h3 {
  margin: 0;
  font-size: clamp(1.25rem, 2vw, 1.85rem);
  line-height: 1.12;
}

.home-today-main p {
  max-width: 640px;
  margin: 10px 0 0;
  color: var(--muted);
  line-height: 1.55;
}

.home-warm-facts {
  display: grid;
  gap: 10px;
}

.home-warm-facts div {
  display: grid;
  gap: 5px;
  padding: 13px;
  border: 1px solid rgba(229, 221, 210, 0.8);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.72);
}

.home-warm-facts span,
.home-warm-facts small {
  color: var(--muted);
  font-size: 0.82rem;
}

.home-warm-facts strong {
  color: var(--ink);
  line-height: 1.2;
}

.home-community-card {
  display: grid;
  gap: 12px;
  padding: 18px;
}

.home-card-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 14px;
}

.home-card-head h3 {
  font-size: 1.1rem;
}

.home-community-list {
  display: grid;
  gap: 9px;
}

.home-community-item,
.home-empty-note {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fffdfa;
}

.home-community-item {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 12px;
  align-items: center;
  padding: 12px;
  cursor: pointer;
  transition: background 160ms ease, border-color 160ms ease, transform 160ms ease;
}

.home-community-item:hover {
  border-color: rgba(35, 119, 130, 0.34);
  background: #f2fbfb;
  transform: translateY(-1px);
}

.home-community-item strong {
  display: block;
  color: var(--ink);
}

.home-community-item p {
  margin: 5px 0 0;
  color: var(--muted);
  line-height: 1.4;
  font-size: 0.9rem;
}

.home-community-item > span {
  padding: 6px 9px;
  border-radius: 999px;
  background: #e8f4f5;
  color: var(--teal);
  font-size: 0.78rem;
  font-weight: 900;
  white-space: nowrap;
}

.home-empty-note {
  padding: 13px;
  color: var(--muted);
  line-height: 1.45;
}

.metric {
  background: linear-gradient(180deg, #fffdfa, #ffffff);
}

@media (max-width: 1080px) {
  .home-personal,
  .home-today-card {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 720px) {
  .home-card-head,
  .home-community-item {
    grid-template-columns: 1fr;
    flex-direction: column;
    align-items: stretch;
  }

  .home-card-head .ghost-button,
  .home-community-item > span {
    justify-self: start;
  }
}

/* Interactive polish */
.app-loader {
  position: fixed;
  inset: 0;
  z-index: 9999;
  display: grid;
  place-items: center;
  padding: 24px;
  background: rgba(0, 0, 0, 0.58);
  backdrop-filter: blur(3px);
  -webkit-backdrop-filter: blur(3px);
  transition: opacity 260ms ease, visibility 260ms ease;
}

.app-loader.is-hidden {
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
}

.loader-card {
  width: min(520px, 100%);
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  gap: 16px;
  align-items: center;
  padding: 18px;
  border: 1px solid rgba(255, 255, 255, 0.28);
  border-radius: 12px;
  background: rgba(255, 253, 250, 0.96);
  box-shadow: 0 28px 80px rgba(0, 0, 0, 0.35);
  animation: loaderCardIn 360ms cubic-bezier(.2, .75, .2, 1) both;
}

.loader-mark {
  width: 54px;
  height: 54px;
  display: grid;
  place-items: center;
  border-radius: 12px;
  background: var(--ink);
  color: #fff;
  font-weight: 900;
  box-shadow: 0 14px 30px rgba(47, 36, 32, 0.2);
  animation: loaderPulse 1300ms ease-in-out infinite;
}

.loader-copy strong {
  display: block;
  color: var(--ink);
  font-size: 1.05rem;
}

.loader-copy p {
  margin: 4px 0 0;
  color: var(--muted);
  line-height: 1.45;
}

.loader-dots {
  display: flex;
  align-items: center;
  gap: 5px;
}

.loader-dots span {
  width: 7px;
  height: 7px;
  border-radius: 999px;
  background: var(--teal);
  animation: dotBounce 900ms ease-in-out infinite;
}

.loader-dots span:nth-child(2) { animation-delay: 120ms; }
.loader-dots span:nth-child(3) { animation-delay: 240ms; }

.view.active {
  animation: viewEnter 220ms ease-out both;
}

.metric,
.panel,
.library-card,
.article-full,
.home-today-card,
.home-community-card,
.community-post-card,
.community-thread,
.child-dev-card {
  transition: transform 180ms ease, box-shadow 180ms ease, border-color 180ms ease, background 180ms ease;
}

.metric:hover,
.panel:hover,
.library-card:hover,
.article-full:hover,
.home-today-card:hover,
.home-community-card:hover,
.child-dev-card:hover {
  transform: translateY(-2px);
  box-shadow: 0 18px 42px rgba(47, 36, 32, 0.11);
  border-color: rgba(35, 119, 130, 0.24);
}

.community-post-card:hover {
  transform: translateY(-1px);
  box-shadow: 0 12px 28px rgba(47, 36, 32, 0.08);
}

.nav-item,
.stage-tab,
.primary-action,
.ghost-button,
.small-action,
.chip-button,
.library-card,
.community-post-card,
.home-community-item {
  transition: transform 150ms ease, background 150ms ease, box-shadow 150ms ease, border-color 150ms ease, color 150ms ease;
}

.nav-item:active,
.stage-tab:active,
.primary-action:active,
.ghost-button:active,
.small-action:active,
.chip-button:active,
.library-card:active,
.community-post-card:active,
.home-community-item:active {
  transform: translateY(1px) scale(0.99);
}

.primary-action:hover,
.ghost-button:hover,
.small-action:hover,
.chip-button:hover {
  box-shadow: 0 10px 24px rgba(47, 36, 32, 0.12);
}

.section-intro {
  position: relative;
  overflow: hidden;
}

.section-intro::after {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  background: linear-gradient(105deg, transparent 0%, rgba(255, 255, 255, 0.42) 48%, transparent 72%);
  transform: translateX(-120%);
  animation: introSheen 5200ms ease-in-out infinite;
}

@keyframes loaderCardIn {
  from {
    opacity: 0;
    transform: translateY(14px) scale(0.98);
  }
  to {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

@keyframes loaderPulse {
  0%, 100% { transform: scale(1); }
  50% { transform: scale(1.04); }
}

@keyframes dotBounce {
  0%, 80%, 100% { transform: translateY(0); opacity: 0.45; }
  40% { transform: translateY(-5px); opacity: 1; }
}

@keyframes viewEnter {
  from {
    opacity: 0;
    transform: translateY(8px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes introSheen {
  0%, 56% { transform: translateX(-120%); }
  78%, 100% { transform: translateX(120%); }
}

@media (max-width: 720px) {
  .loader-card {
    grid-template-columns: auto minmax(0, 1fr);
    align-items: start;
  }

  .loader-dots {
    grid-column: 2;
  }
}

@media (prefers-reduced-motion: reduce) {
  .app-loader,
  .loader-card,
  .loader-mark,
  .loader-dots span,
  .view.active,
  .section-intro::after,
  .metric,
  .panel,
  .library-card,
  .article-full,
  .home-today-card,
  .home-community-card,
  .community-post-card,
  .community-thread,
  .child-dev-card,
  .nav-item,
  .stage-tab,
  .primary-action,
  .ghost-button,
  .small-action,
  .chip-button,
  .home-community-item {
    animation: none !important;
    transition: none !important;
  }
}

.offline-page {
  min-height: 100vh;
  display: grid;
  place-items: center;
  padding: 22px;
  background: linear-gradient(135deg, #fff7ef, #eef8f8);
}

.offline-card {
  width: min(520px, 100%);
  display: grid;
  gap: 12px;
  padding: 28px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: #fffdfa;
  box-shadow: 0 24px 70px rgba(47, 36, 32, 0.15);
}

.offline-card h1 {
  margin: 0;
  color: var(--ink);
  font-size: clamp(2rem, 8vw, 3.6rem);
  line-height: 0.95;
}

.offline-card p:not(.eyebrow) {
  margin: 0 0 8px;
  color: var(--muted);
  line-height: 1.55;
}

/* Mascot splash */
.mascot-loader-card {
  width: min(430px, 100%);
  grid-template-columns: 1fr;
  justify-items: center;
  text-align: center;
  gap: 14px;
  padding: 28px 24px 24px;
  border-radius: 18px;
  background: rgba(255, 253, 250, 0.86);
  backdrop-filter: blur(14px);
}

.loader-mascot-wrap {
  position: relative;
  width: min(230px, 62vw);
  aspect-ratio: 1;
  display: grid;
  place-items: center;
}

.loader-glow {
  position: absolute;
  inset: 13%;
  border-radius: 999px;
  background: radial-gradient(circle, rgba(212, 107, 93, 0.22), rgba(35, 119, 130, 0.08) 58%, transparent 72%);
  animation: loaderGlow 1800ms ease-in-out infinite;
}

.loader-mascot {
  position: relative;
  z-index: 1;
  width: 100%;
  height: 100%;
  object-fit: contain;
  filter: drop-shadow(0 18px 22px rgba(47, 36, 32, 0.16));
  animation: mascotFloat 1800ms ease-in-out infinite;
}

.loader-copy span {
  display: inline-flex;
  margin-bottom: 6px;
  padding: 6px 10px;
  border-radius: 999px;
  background: #e8f4f5;
  color: var(--teal);
  font-size: 0.76rem;
  font-weight: 900;
  text-transform: uppercase;
}

.mascot-loader-card .loader-copy strong {
  font-size: clamp(1.35rem, 4.6vw, 2rem);
  line-height: 1.04;
}

.mascot-loader-card .loader-copy p {
  max-width: 330px;
  margin-inline: auto;
}

.mascot-loader-card .loader-dots {
  justify-content: center;
}

.offline-mascot {
  width: min(190px, 56vw);
  justify-self: center;
  filter: drop-shadow(0 18px 24px rgba(47, 36, 32, 0.16));
}

@keyframes mascotFloat {
  0%, 100% { transform: translateY(0) rotate(-1deg); }
  50% { transform: translateY(-10px) rotate(1deg); }
}

@keyframes loaderGlow {
  0%, 100% { transform: scale(0.94); opacity: 0.68; }
  50% { transform: scale(1.08); opacity: 1; }
}

@media (max-width: 720px) {
  .mascot-loader-card {
    padding: 22px 18px 20px;
  }

  .mascot-loader-card .loader-dots {
    grid-column: auto;
  }
}

@media (prefers-reduced-motion: reduce) {
  .loader-glow,
  .loader-mascot {
    animation: none !important;
  }
}

/* Modern account actions */
.sync-status {
  display: none !important;
}

.topbar-actions {
  position: sticky;
  top: 18px;
  z-index: 8;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 7px;
  border: 1px solid rgba(229, 221, 210, 0.78);
  border-radius: 999px;
  background: rgba(255, 253, 250, 0.78);
  box-shadow: 0 18px 44px rgba(47, 36, 32, 0.1);
  backdrop-filter: blur(18px);
}

.user-badge {
  position: relative;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  min-height: 38px;
  max-width: 180px;
  padding: 0 13px 0 8px;
  border-radius: 999px;
  border: 1px solid rgba(35, 119, 130, 0.14);
  background: #eef8f8;
  color: var(--teal);
  font-size: 0.8rem;
  font-weight: 900;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.user-badge::before {
  content: "";
  width: 26px;
  height: 26px;
  flex: 0 0 26px;
  border-radius: 999px;
  background: linear-gradient(135deg, #d46b5d, #237782);
  box-shadow: inset 0 0 0 3px rgba(255, 255, 255, 0.52);
}

.topbar-actions .ghost-button,
.topbar-actions .primary-action,
#logoutBtn.ghost-button,
#installAppBtn.ghost-button {
  min-height: 38px;
  padding: 0 14px;
  border-radius: 999px;
  font-size: 0.8rem;
  font-weight: 900;
  white-space: nowrap;
}

.topbar-actions .primary-action {
  background: var(--coral);
  box-shadow: 0 12px 24px rgba(204, 107, 90, 0.18);
}

#logoutBtn.ghost-button {
  border-color: transparent;
  background: transparent;
  color: var(--muted);
  box-shadow: none;
}

#logoutBtn.ghost-button:hover {
  background: rgba(47, 36, 32, 0.07);
  color: var(--ink);
}

#installAppBtn.ghost-button {
  background: #f3eee7;
  color: var(--ink);
  box-shadow: none;
}

@media (max-width: 960px) {
  .topbar {
    align-items: stretch;
  }

  .topbar-actions {
    position: static;
    align-self: stretch;
    width: 100%;
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto auto;
    border-radius: 16px;
  }

  .user-badge {
    max-width: none;
    justify-content: flex-start;
  }
}

@media (max-width: 720px) {
  .topbar-actions {
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 8px;
    padding: 8px;
    border-radius: 18px;
  }

  .user-badge,
  .topbar-actions .ghost-button,
  .topbar-actions .primary-action,
  #logoutBtn.ghost-button,
  #installAppBtn.ghost-button {
    width: auto;
  }

  .topbar-actions .primary-action {
    min-width: 96px;
  }

  #installAppBtn.ghost-button,
  #logoutBtn.ghost-button {
    grid-column: span 1;
  }

  #installAppBtn.ghost-button.hidden + .primary-action + #logoutBtn.ghost-button,
  #logoutBtn.ghost-button {
    padding-inline: 12px;
  }
}

@media (max-width: 420px) {
  .topbar-actions {
    grid-template-columns: 1fr 1fr;
  }

  .user-badge {
    grid-column: 1 / -1;
  }

  .topbar-actions .primary-action,
  #installAppBtn.ghost-button,
  #logoutBtn.ghost-button {
    width: 100%;
    justify-content: center;
  }
}

/* Mobile account bar refinement */
@media (max-width: 720px) {
  .topbar {
    gap: 14px;
  }

  .topbar-actions {
    width: 100%;
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto auto;
    align-items: center;
    gap: 7px;
    padding: 0;
    border: 0;
    border-radius: 0;
    background: transparent;
    box-shadow: none;
    backdrop-filter: none;
  }

  .user-badge {
    grid-column: auto;
    min-width: 0;
    min-height: 34px;
    max-width: 100%;
    padding: 0 10px 0 6px;
    background: rgba(232, 244, 245, 0.86);
    box-shadow: inset 0 0 0 1px rgba(35, 119, 130, 0.08);
  }

  .user-badge::before {
    width: 24px;
    height: 24px;
    flex-basis: 24px;
  }

  .topbar-actions .primary-action,
  #logoutBtn.ghost-button,
  #installAppBtn.ghost-button {
    width: auto;
    min-height: 34px;
    padding: 0 12px;
    font-size: 0.76rem;
  }

  .topbar-actions .primary-action {
    min-width: 74px;
    box-shadow: 0 8px 18px rgba(204, 107, 90, 0.15);
  }

  #logoutBtn.ghost-button {
    background: rgba(255, 253, 250, 0.7);
    border: 1px solid rgba(229, 221, 210, 0.72);
  }

  #installAppBtn.ghost-button:not(.hidden) {
    grid-column: 1 / -1;
    width: 100%;
    justify-content: center;
    background: rgba(255, 253, 250, 0.78);
    border: 1px solid rgba(229, 221, 210, 0.72);
  }
}

@media (max-width: 420px) {
  .topbar-actions {
    grid-template-columns: minmax(0, 1fr) auto auto;
  }

  .user-badge {
    grid-column: auto;
  }

  .topbar-actions .primary-action,
  #logoutBtn.ghost-button,
  #installAppBtn.ghost-button {
    width: auto;
  }
}

@media (max-width: 360px) {
  .topbar-actions {
    grid-template-columns: minmax(0, 1fr) auto;
  }

  #logoutBtn.ghost-button {
    grid-column: 2;
  }

  .topbar-actions .primary-action {
    grid-column: 1 / -1;
    width: 100%;
    justify-content: center;
  }
}

/* Pregnancy progress */
.pregnancy-progress-card {
  display: grid;
  gap: 11px;
  padding: 15px;
  border: 1px solid rgba(212, 107, 93, 0.18);
  border-radius: 10px;
  background: linear-gradient(135deg, #fff3eb, #f1fbfb);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.72);
}

.pregnancy-progress-head,
.pregnancy-progress-scale {
  display: flex;
  justify-content: space-between;
  gap: 12px;
}

.pregnancy-progress-head > div {
  display: grid;
  gap: 3px;
}

.pregnancy-progress-head > div:last-child {
  text-align: right;
}

.pregnancy-progress-head span,
.pregnancy-progress-scale small {
  color: var(--muted);
  font-size: 0.78rem;
  font-weight: 900;
}

.pregnancy-progress-head strong {
  color: var(--ink);
  line-height: 1.18;
}

.pregnancy-progress-track {
  position: relative;
  height: 14px;
  overflow: hidden;
  border-radius: 999px;
  background: rgba(47, 36, 32, 0.09);
  box-shadow: inset 0 1px 3px rgba(47, 36, 32, 0.12);
}

.pregnancy-progress-track span {
  position: absolute;
  inset: 0 auto 0 0;
  width: var(--pregnancy-progress, 0%);
  border-radius: inherit;
  background: linear-gradient(90deg, #d46b5d, #f2a35f 55%, #237782);
  box-shadow: 0 7px 18px rgba(212, 107, 93, 0.22);
  transition: width 420ms cubic-bezier(.2, .75, .2, 1);
}

.pregnancy-progress-track span::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.38), transparent);
  transform: translateX(-100%);
  animation: progressSheen 2600ms ease-in-out infinite;
}

@keyframes progressSheen {
  0%, 45% { transform: translateX(-100%); }
  78%, 100% { transform: translateX(100%); }
}

@media (max-width: 720px) {
  .pregnancy-progress-card {
    padding: 13px;
  }

  .pregnancy-progress-head {
    display: grid;
  }

  .pregnancy-progress-head > div:last-child {
    text-align: left;
  }
}

@media (prefers-reduced-motion: reduce) {
  .pregnancy-progress-track span,
  .pregnancy-progress-track span::after {
    animation: none !important;
    transition: none !important;
  }
}


.brand-mark {
  width: 46px;
  height: 46px;
  display: grid;
  place-items: center;
  border-radius: 12px;
  overflow: hidden;
  background: #ffd7c8;
}

.brand-mark img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

/* About page */
.about-hero {
  display: grid;
  grid-template-columns: minmax(0, 1.35fr) minmax(260px, 0.65fr);
  gap: 28px;
  align-items: center;
  overflow: hidden;
  background:
    linear-gradient(135deg, rgba(255, 243, 235, 0.92), rgba(238, 248, 248, 0.9)),
    #fffdfa;
}

.about-hero-copy {
  display: grid;
  gap: 14px;
}

.about-kicker,
.about-card span {
  width: fit-content;
  padding: 7px 10px;
  border-radius: 999px;
  background: #e8f4f5;
  color: var(--teal);
  font-size: 0.76rem;
  font-weight: 900;
  text-transform: uppercase;
}

.about-hero h2,
.about-donation-copy h2 {
  max-width: 820px;
  margin: 0;
  color: var(--ink);
  font-size: clamp(2.2rem, 5vw, 4.9rem);
  line-height: 0.94;
}

.about-hero p,
.about-donation-copy p,
.about-card p,
.about-values p {
  margin: 0;
  color: var(--muted);
  line-height: 1.6;
}

.about-hero p {
  max-width: 760px;
  font-size: 1.02rem;
}

.about-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 4px;
}

.about-mascot-card {
  min-height: 340px;
  display: grid;
  place-items: center;
  border-radius: 18px;
  background: radial-gradient(circle at 50% 35%, rgba(212, 107, 93, 0.17), rgba(35, 119, 130, 0.08) 58%, transparent 72%);
}

.about-mascot-card img {
  width: min(330px, 100%);
  filter: drop-shadow(0 24px 28px rgba(47, 36, 32, 0.15));
  animation: mascotFloat 2200ms ease-in-out infinite;
}

.about-grid {
  display: grid;
  grid-template-columns: 1.2fr 1fr 1fr;
  gap: 14px;
}

.about-card,
.about-values article {
  display: grid;
  gap: 10px;
  padding: 18px;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: linear-gradient(180deg, #fffdfa, #ffffff);
  box-shadow: 0 12px 30px rgba(47, 36, 32, 0.05);
}

.about-card h3 {
  margin: 0;
  color: var(--ink);
  font-size: clamp(1.25rem, 2.2vw, 2rem);
  line-height: 1.08;
}

.about-story-card {
  background: linear-gradient(135deg, #2f2420, #56372f);
}

.about-story-card h3,
.about-story-card p {
  color: #fff7ef;
}

.about-story-card span {
  background: rgba(255, 255, 255, 0.12);
  color: #fff7ef;
}

.about-donation-panel {
  display: grid;
  grid-template-columns: minmax(0, 1.1fr) minmax(280px, 0.9fr);
  gap: 22px;
  align-items: center;
  border-color: rgba(212, 107, 93, 0.22);
  background: linear-gradient(135deg, #fff7ef, #fffdfa 48%, #edf8f8);
}

.about-donation-copy {
  display: grid;
  gap: 12px;
}

.donation-box {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
  padding: 16px;
  border: 1px solid rgba(229, 221, 210, 0.9);
  border-radius: 14px;
  background: rgba(255, 253, 250, 0.8);
  box-shadow: 0 18px 42px rgba(47, 36, 32, 0.08);
}

.donation-box button {
  min-height: 48px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: #fffdfa;
  color: var(--ink);
  font: inherit;
  font-weight: 900;
  cursor: pointer;
  transition: transform 150ms ease, box-shadow 150ms ease, border-color 150ms ease;
}

.donation-box button:hover {
  transform: translateY(-1px);
  border-color: rgba(212, 107, 93, 0.28);
  box-shadow: 0 10px 24px rgba(47, 36, 32, 0.1);
}

.donation-box .donation-main {
  grid-column: 1 / -1;
  background: var(--coral);
  color: #fff;
  border-color: transparent;
}

.donation-box small {
  grid-column: 1 / -1;
  color: var(--muted);
  font-weight: 800;
  text-align: center;
}

.about-values {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 14px;
}

.about-values strong {
  color: var(--ink);
  font-size: 1.05rem;
}

@media (max-width: 1080px) {
  .about-hero,
  .about-donation-panel,
  .about-grid,
  .about-values {
    grid-template-columns: 1fr;
  }

  .about-mascot-card {
    min-height: 240px;
  }
}

@media (max-width: 720px) {
  .about-hero,
  .about-donation-panel,
  .about-card,
  .about-values article {
    padding: 16px;
  }

  .about-hero h2,
  .about-donation-copy h2 {
    font-size: clamp(2rem, 11vw, 3.1rem);
  }

  .about-actions,
  .about-actions .primary-action,
  .about-actions .ghost-button {
    width: 100%;
  }

  .donation-box {
    grid-template-columns: 1fr;
  }

  .donation-box .donation-main,
  .donation-box small {
    grid-column: auto;
  }
}

/* Discreet legal footer */
.app-footer {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 18px;
  align-items: center;
  padding: 18px 2px 6px;
  border-top: 1px solid rgba(229, 221, 210, 0.72);
  color: var(--muted);
}

.app-footer strong {
  display: block;
  margin-bottom: 5px;
  color: var(--ink);
  font-size: 0.92rem;
}

.app-footer p {
  max-width: 880px;
  margin: 0;
  font-size: 0.82rem;
  line-height: 1.55;
}

.footer-badges {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 8px;
}

.footer-badges span {
  padding: 7px 10px;
  border: 1px solid rgba(229, 221, 210, 0.82);
  border-radius: 999px;
  background: rgba(255, 253, 250, 0.72);
  color: var(--muted);
  font-size: 0.74rem;
  font-weight: 900;
  white-space: nowrap;
}

@media (max-width: 900px) {
  .app-footer {
    grid-template-columns: 1fr;
  }

  .footer-badges {
    justify-content: flex-start;
  }
}

@media (max-width: 720px) {
  .app-footer {
    padding: 16px 0 calc(8px + env(safe-area-inset-bottom));
  }

  .footer-badges span {
    white-space: normal;
  }
}

/* Auth security flows */
.auth-form-single {
  grid-column: 1 / -1;
  width: min(520px, 100%);
  justify-self: center;
}

.auth-small-copy {
  margin: 0;
  color: var(--muted);
  font-size: 0.9rem;
  line-height: 1.45;
}

.text-action {
  width: fit-content;
  justify-self: center;
  border: 0;
  background: transparent;
  color: var(--teal);
  font: inherit;
  font-size: 0.86rem;
  font-weight: 900;
  cursor: pointer;
}

.text-action:hover {
  text-decoration: underline;
}

.auth-link-row {
  display: flex;
  justify-content: center;
  flex-wrap: wrap;
  gap: 8px 14px;
}


