:root {
  color-scheme: light;
  --navy: #10132e;
  --navy-2: #171b3f;
  --coral: #ff6b5f;
  --coral-2: #ff8f86;
  --mint: #57d4b7;
  --mint-2: #dffbf4;
  --cream: #fff8f2;
  --cream-2: #fff1e8;
  --peach: #ffe5d8;
  --lavender: #eee7ff;
  --white: #ffffff;
  --ink: #25283d;
  --muted: #73798c;
  --line: #ece3da;
  --success: #159f70;
  --danger: #e34f5d;
  --amber: #f2a93b;
  --shadow: 0 20px 46px rgba(16, 19, 46, 0.1);
  --soft-shadow: 0 10px 26px rgba(16, 19, 46, 0.07);
  --shadow-sm: 0 8px 20px rgba(16, 19, 46, 0.06);
  --shadow-md: 0 16px 38px rgba(16, 19, 46, 0.1);
  --shadow-lg: 0 24px 70px rgba(16, 19, 46, 0.14);
  --shadow-floating: 0 22px 60px rgba(16, 19, 46, 0.18);
  --shadow-premium: 0 28px 80px rgba(16, 19, 46, 0.22);
  --radius-xl: 30px;
  --radius-lg: 24px;
  --radius-md: 18px;
  --radius-sm: 12px;
  --nav-height: 76px;
  --space-1: 4px;
  --space-2: 8px;
  --space-3: 12px;
  --space-4: 16px;
  --space-5: 20px;
  --space-6: 24px;
  --space-8: 32px;
  --motion-fast: 160ms cubic-bezier(0.2, 0.8, 0.2, 1);
  --motion-med: 240ms cubic-bezier(0.2, 0.8, 0.2, 1);
  --font: Inter, Poppins, Avenir Next, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

* {
  box-sizing: border-box;
}

html {
  min-height: 100%;
  background: var(--cream);
}

html.mobile-shell {
  width: 100%;
  overflow-x: hidden;
}

body {
  margin: 0;
  min-width: 320px;
  min-height: 100vh;
  min-height: 100dvh;
  overflow-x: hidden;
  background: var(--cream);
  color: var(--navy);
  font-family: var(--font);
  -webkit-font-smoothing: antialiased;
  text-rendering: geometricPrecision;
}

.mobile-shell body {
  width: 100%;
  min-height: 100dvh;
  overflow-x: hidden;
  overscroll-behavior-y: none;
}

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

button {
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
}

img,
svg {
  display: block;
}

noscript {
  display: block;
  padding: 24px;
}

.app-root,
.app-shell {
  min-height: 100vh;
  min-height: 100dvh;
  background:
    radial-gradient(circle at 10% -4%, rgba(255, 229, 216, 0.9), transparent 28%),
    radial-gradient(circle at 96% 4%, rgba(87, 212, 183, 0.16), transparent 24%),
    var(--cream);
}

.app-shell {
  width: 100%;
}

.screen-content {
  width: min(100%, 560px);
  min-height: 100vh;
  min-height: 100dvh;
  margin: 0 auto;
  padding:
    max(18px, env(safe-area-inset-top))
    16px
    calc(var(--nav-height) + 26px + env(safe-area-inset-bottom));
}

.mobile-shell .app-root,
.mobile-shell .app-shell {
  width: 100%;
  min-height: 100dvh;
  overflow-x: clip;
}

.mobile-shell .screen-content,
.mobile-shell .auth-screen,
.mobile-shell .onboarding-screen,
.mobile-shell .invite-screen {
  width: 100%;
  max-width: none;
  margin: 0;
}

.preview-shell body {
  background:
    radial-gradient(circle at 22% 0%, rgba(255, 107, 95, 0.08), transparent 28%),
    radial-gradient(circle at 82% 0%, rgba(87, 212, 183, 0.1), transparent 28%),
    #eee6dc;
}

.screen-content > * {
  animation: screenRise var(--motion-med) both;
}

.icon {
  width: 22px;
  height: 22px;
  flex: 0 0 auto;
}

.brand-symbol,
.brand-logo {
  display: block;
  max-width: 100%;
  height: auto;
}

.brand-symbol {
  width: 100%;
}

.splash-screen,
.auth-screen,
.onboarding-screen,
.invite-screen,
.error-screen {
  min-height: 100vh;
  min-height: 100dvh;
}

.splash-screen {
  display: grid;
  place-items: center;
  align-content: center;
  gap: 12px;
  padding: 28px;
  background:
    radial-gradient(circle at 18% 12%, rgba(255, 75, 80, 0.14), transparent 28%),
    radial-gradient(circle at 86% 84%, rgba(87, 212, 183, 0.14), transparent 30%),
    linear-gradient(180deg, #fffdf8 0%, var(--cream) 100%);
  color: var(--navy);
  text-align: center;
}

.splash-lockup {
  width: min(82vw, 430px);
  animation: screenRise 420ms ease both;
}

.paywall-mark {
  display: grid;
  place-items: center;
  width: 112px;
  height: 112px;
  border-radius: 32px;
  background: var(--cream);
  color: var(--coral);
  box-shadow: var(--shadow);
}

.paywall-mark .brand-symbol,
.auth-mark .brand-symbol {
  width: 72%;
}

.splash-screen strong {
  font-size: 2.25rem;
  font-weight: 950;
}

.splash-screen p {
  margin: 0;
  color: rgba(255, 255, 255, 0.72);
  font-weight: 800;
}

.onboarding-screen {
  display: grid;
  grid-template-rows: auto 1fr auto;
  width: min(100%, 560px);
  margin: 0 auto;
  padding:
    max(18px, env(safe-area-inset-top))
    18px
    max(18px, env(safe-area-inset-bottom));
  background:
    radial-gradient(circle at 85% 12%, rgba(255, 107, 95, 0.16), transparent 24%),
    linear-gradient(180deg, #fffbf8 0%, var(--cream) 100%);
}

.onboarding-top,
.simple-top,
.paywall-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  min-height: 48px;
}

.brand-mini {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  color: var(--navy);
  font-weight: 950;
}

.brand-mini span {
  display: grid;
  place-items: center;
  width: 34px;
  height: 34px;
  border-radius: 13px;
  background: transparent;
  color: var(--navy);
}

.brand-mini .brand-symbol {
  width: 34px;
  height: 24px;
  object-fit: contain;
}

.skip-button,
.link-button {
  min-height: 40px;
  border: 0;
  background: transparent;
  color: var(--coral);
  font-weight: 950;
}

.onboarding-body {
  display: grid;
  align-content: center;
  gap: clamp(28px, 8dvh, 64px);
  animation: slideIn 260ms ease both;
}

.onboarding-visual {
  position: relative;
  display: grid;
  place-items: center;
  width: min(64vw, 280px);
  aspect-ratio: 1;
  margin: 0 auto;
  border-radius: 42px;
  box-shadow: var(--shadow);
  overflow: hidden;
}

.onboarding-visual.tone-peach {
  background: linear-gradient(145deg, var(--peach), #fff8f2);
  color: var(--navy);
}

.onboarding-visual.tone-mint {
  background: linear-gradient(145deg, var(--mint-2), #f8fffc);
  color: var(--navy);
}

.onboarding-visual.tone-navy {
  background: linear-gradient(145deg, var(--navy), var(--navy-2));
  color: var(--white);
}

.onboarding-visual.tone-coral {
  background: linear-gradient(145deg, var(--coral), var(--coral-2));
  color: var(--white);
}

.onboarding-visual > .icon {
  width: 46%;
  height: 46%;
  z-index: 1;
  stroke-width: 1.8;
}

.visual-orbit {
  position: absolute;
  border-radius: 999px;
  border: 1px solid currentColor;
  opacity: 0.12;
}

.orbit-one {
  width: 74%;
  height: 74%;
}

.orbit-two {
  width: 104%;
  height: 104%;
}

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

.eyebrow {
  margin: 0;
  color: var(--coral);
  font-size: 0.74rem;
  font-weight: 950;
  letter-spacing: 0;
  text-transform: uppercase;
}

.onboarding-copy h1,
.invite-hero h1,
.paywall-hero h1,
.error-screen h1 {
  margin: 0;
  color: var(--navy);
  font-size: clamp(2.25rem, 10vw, 3.7rem);
  line-height: 0.98;
  letter-spacing: 0;
}

.onboarding-copy p,
.invite-hero p,
.paywall-hero p,
.empty-state p,
.fine-print {
  margin: 0;
  color: var(--muted);
  font-size: 1rem;
  line-height: 1.45;
}

.onboarding-footer,
.fixed-action-footer {
  display: grid;
  gap: 14px;
  padding-bottom: env(safe-area-inset-bottom);
}

.dots {
  display: flex;
  gap: 8px;
}

.dots span {
  width: 8px;
  height: 8px;
  border-radius: 999px;
  background: #e2d8ce;
  transition: width 200ms ease, background 200ms ease;
}

.dots span.active {
  width: 32px;
  background: var(--coral);
}

.invite-screen {
  display: grid;
  grid-template-rows: auto 1fr auto;
  width: min(100%, 560px);
  margin: 0 auto;
  padding:
    max(18px, env(safe-area-inset-top))
    16px
    max(18px, env(safe-area-inset-bottom));
  background: var(--cream);
}

.auth-screen {
  display: grid;
  align-content: start;
  gap: 18px;
  width: min(100%, 560px);
  margin: 0 auto;
  padding:
    max(18px, env(safe-area-inset-top))
    16px
    max(24px, env(safe-area-inset-bottom));
  background:
    radial-gradient(circle at 92% 8%, rgba(87, 212, 183, 0.18), transparent 25%),
    linear-gradient(180deg, #fffbf8 0%, var(--cream) 100%);
}

.auth-hero,
.auth-panel,
.auth-setup-card,
.auth-status-card {
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  background: rgba(255, 255, 255, 0.88);
  box-shadow: var(--soft-shadow);
}

.auth-hero {
  display: grid;
  gap: 12px;
  padding: 22px;
}

.auth-hero h1 {
  margin: 0;
  color: var(--navy);
  font-size: clamp(2.15rem, 9vw, 3.3rem);
  line-height: 0.98;
}

.auth-hero p {
  margin: 0;
  color: var(--muted);
  line-height: 1.45;
}

.auth-mark {
  display: grid;
  place-items: center;
  width: 68px;
  height: 68px;
  border-radius: 24px;
  background: var(--cream);
  color: var(--navy);
  box-shadow: var(--shadow-sm);
}

.auth-panel {
  display: grid;
  gap: 14px;
  padding: 16px;
}

.auth-panel form {
  display: grid;
  gap: 12px;
}

.button-google {
  display: inline-grid;
  grid-template-columns: auto 1fr;
  align-items: center;
  justify-items: center;
  gap: 10px;
  background: var(--white);
  color: var(--navy);
  border: 1px solid rgba(16, 19, 46, 0.12);
  box-shadow: var(--shadow-sm);
}

.google-mark {
  display: grid;
  place-items: center;
  width: 26px;
  height: 26px;
  border-radius: 50%;
  background: linear-gradient(135deg, #4285f4, #34a853 45%, #fbbc04 70%, #ea4335);
  color: var(--white);
  font-weight: 900;
  font-size: 0.86rem;
}

.auth-divider {
  display: flex;
  align-items: center;
  gap: 10px;
  color: var(--muted);
  font-size: 0.78rem;
  font-weight: 700;
}

.auth-divider::before,
.auth-divider::after {
  content: "";
  flex: 1;
  height: 1px;
  background: rgba(16, 19, 46, 0.1);
}

.segmented-control {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 6px;
  padding: 5px;
  border-radius: 18px;
  background: var(--cream);
}

.segmented-control button {
  min-height: 42px;
  border: 0;
  border-radius: 14px;
  background: transparent;
  color: var(--muted);
  font-weight: 950;
}

.segmented-control button.active {
  background: var(--navy);
  color: var(--white);
}

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

.auth-alert,
.auth-setup-card {
  padding: 13px;
  border-radius: 18px;
  line-height: 1.4;
}

.auth-alert.error {
  background: #fff1f2;
  color: var(--danger);
}

.auth-alert.success {
  background: var(--mint-2);
  color: var(--success);
}

.auth-setup-card {
  display: grid;
  gap: 6px;
  border-color: rgba(242, 169, 59, 0.35);
  background: #fff8ed;
}

.auth-setup-card strong {
  display: flex;
  align-items: center;
  gap: 8px;
  color: var(--navy);
}

.auth-setup-card p,
.auth-fine-print {
  margin: 0;
  color: var(--muted);
  line-height: 1.45;
}

.auth-setup-card code {
  color: var(--navy);
  font-weight: 850;
}

.auth-link {
  justify-self: center;
}

.auth-fine-print {
  padding: 0 4px;
  font-size: 0.82rem;
}

.invite-content {
  display: grid;
  align-content: center;
  gap: 18px;
}

.invite-hero {
  display: grid;
  gap: 12px;
}

.invite-icon,
.profile-avatar,
.feature-icon,
.card-icon,
.agreement-icon {
  display: grid;
  place-items: center;
  width: 54px;
  height: 54px;
  border-radius: 20px;
  background: var(--peach);
  color: var(--coral);
}

.invite-icon {
  width: 104px;
  height: 104px;
  border-radius: 32px;
  background: var(--navy);
  color: var(--white);
}

.invite-icon .icon {
  width: 54px;
  height: 54px;
}

.invite-code {
  display: grid;
  place-items: center;
  min-height: 82px;
  border: 1px dashed rgba(255, 107, 95, 0.58);
  border-radius: var(--radius-lg);
  background: var(--peach);
  color: var(--navy);
  font-size: 1.45rem;
  font-weight: 950;
}

.app-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 14px;
  margin-bottom: 18px;
}

.app-header-brand {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 8px;
  color: var(--coral);
  font-size: 0.76rem;
  font-weight: 800;
}

.app-header-brand .brand-symbol {
  width: 42px;
  height: 28px;
  object-fit: contain;
}

.app-header h1 {
  margin: 0;
  color: var(--navy);
  font-size: clamp(1.8rem, 7vw, 2.55rem);
  line-height: 1;
  letter-spacing: 0;
}

.app-header p {
  margin: 8px 0 0;
  color: var(--muted);
  line-height: 1.35;
}

.icon-action,
.icon-soft {
  display: inline-grid;
  place-items: center;
  width: 48px;
  height: 48px;
  border: 0;
  border-radius: 18px;
  background: var(--navy);
  color: var(--white);
}

.icon-action.light,
.icon-soft {
  border: 1px solid var(--line);
  background: var(--white);
  color: var(--navy);
}

.health-card,
.cash-hero,
.plans-hero,
.checkin-intro,
.profile-card,
.achievement-card,
.empty-state,
.error-screen,
.bill-summary article,
.money-card,
.bill-card,
.goal-card,
.agreement-card,
.insight-card,
.feature-card,
.settings-item,
.price-card,
.premium-entry-card,
.category-row {
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  background: rgba(255, 255, 255, 0.86);
  box-shadow: var(--soft-shadow);
}

.health-card {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 14px;
  align-items: center;
  padding: 20px;
  margin-bottom: 14px;
  background: linear-gradient(145deg, var(--navy), var(--navy-2));
  color: var(--white);
  overflow: hidden;
}

.health-card.risk-critical {
  border-color: rgba(227, 79, 93, 0.42);
  background: linear-gradient(145deg, #3a101c, #10132e);
}

.health-card.risk-attention {
  border-color: rgba(255, 107, 95, 0.36);
}

.health-copy {
  min-width: 0;
}

.health-copy h2,
.plans-hero h2,
.checkin-intro h2,
.paywall-hero h1 {
  margin: 0;
  line-height: 1.02;
  letter-spacing: 0;
}

.health-copy h2 {
  color: var(--white);
  font-size: 1.75rem;
}

.health-copy p {
  margin: 10px 0 0;
  color: rgba(255, 255, 255, 0.78);
  line-height: 1.35;
}

.health-copy small {
  display: block;
  margin-top: 10px;
  color: rgba(255, 255, 255, 0.62);
  line-height: 1.35;
}

.score-ring {
  width: 102px;
  height: 102px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  background:
    radial-gradient(circle, var(--navy) 58%, transparent 60%),
    conic-gradient(var(--mint) 0deg var(--score), rgba(255, 255, 255, 0.18) var(--score));
}

.health-card.risk-critical .score-ring {
  background:
    radial-gradient(circle, #3a101c 58%, transparent 60%),
    conic-gradient(var(--danger) 0deg var(--score), rgba(255, 255, 255, 0.18) var(--score));
}

.health-card.risk-attention .score-ring {
  background:
    radial-gradient(circle, var(--navy) 58%, transparent 60%),
    conic-gradient(var(--coral) 0deg var(--score), rgba(255, 255, 255, 0.18) var(--score));
}

.health-card.risk-critical .health-copy small {
  color: rgba(255, 255, 255, 0.78);
}

.score-ring strong {
  grid-area: 1 / 1;
  color: var(--white);
  font-size: 2rem;
  font-weight: 950;
}

.score-ring span {
  grid-area: 1 / 1;
  align-self: end;
  margin-bottom: 22px;
  color: rgba(255, 255, 255, 0.62);
  font-size: 0.65rem;
  font-weight: 900;
}

.metric-grid,
.feature-grid,
.price-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}

.stack,
.list-stack,
.settings-list,
.benefit-list,
.category-list {
  display: grid;
  gap: 12px;
}

.settings-button {
  width: 100%;
  border: 0;
  text-align: left;
  font: inherit;
  cursor: pointer;
}

.settings-button:active {
  transform: scale(0.99);
}

.action-row {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
  margin-top: 16px;
}

.money-card {
  display: grid;
  gap: 8px;
  min-height: 156px;
  padding: 15px;
}

.card-icon {
  width: 42px;
  height: 42px;
  border-radius: 16px;
}

.money-card span,
.bill-card p,
.goal-card span,
.insight-meta,
.category-row span,
.field span,
.price-card span,
.price-card small {
  color: var(--muted);
  font-size: 0.82rem;
  font-weight: 850;
}

.money-card strong,
.bill-card strong,
.cash-hero strong,
.category-row strong {
  display: block;
  color: var(--navy);
  font-size: 1.35rem;
  line-height: 1;
  font-weight: 950;
}

.money-card p,
.goal-card p,
.goal-card small,
.agreement-card p,
.agreement-card small,
.insight-card p,
.feature-card p,
.settings-item small,
.cash-hero span,
.checkin-intro p,
.plans-hero p {
  margin: 0;
  color: var(--muted);
  line-height: 1.38;
}

.tone-mint {
  background: #f1fffb;
}

.tone-peach,
.tone-coral {
  background: var(--peach);
}

.tone-lavender {
  background: var(--lavender);
}

.tone-cream {
  background: var(--white);
}

.section-block {
  margin-top: 20px;
}

.section-heading {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 10px;
}

.section-heading h2 {
  margin: 0;
  color: var(--navy);
  font-size: 1.18rem;
  letter-spacing: 0;
}

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

.cash-hero {
  display: grid;
  gap: 8px;
  margin-bottom: 14px;
  padding: 22px;
  background: linear-gradient(145deg, var(--peach), #fffaf6);
}

.cash-hero.is-empty {
  background: linear-gradient(145deg, rgba(255, 250, 246, 0.96), rgba(234, 248, 244, 0.54));
}

.cash-hero p {
  margin: 0;
  color: var(--muted);
  font-weight: 900;
}

.cash-hero strong {
  font-size: clamp(2.35rem, 13vw, 4rem);
}

.bill-card {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 12px;
  align-items: start;
  padding: 16px;
}

.bill-card.attention {
  border-color: rgba(255, 107, 95, 0.36);
  background: #fff4f1;
}

.bill-card.income-card {
  background: #f1fffb;
}

.bill-main {
  min-width: 0;
}

.bill-card h3,
.goal-card h3,
.agreement-card h3,
.insight-card h3,
.feature-card h3 {
  margin: 0;
  color: var(--navy);
  font-size: 1.04rem;
  letter-spacing: 0;
}

.bill-card p {
  margin: 7px 0 0;
}

.status-chip {
  display: inline-flex;
  align-items: center;
  min-height: 26px;
  margin-bottom: 10px;
  padding: 0 10px;
  border-radius: 999px;
  background: #f4f0ec;
  color: var(--muted);
  font-size: 0.7rem;
  font-weight: 950;
}

.status-chip.paid,
.status-chip.received,
.status-chip.active {
  background: rgba(21, 159, 112, 0.12);
  color: var(--success);
}

.status-chip.pending,
.status-chip.expected,
.status-chip.scheduled,
.status-chip.draft {
  background: rgba(242, 169, 59, 0.18);
  color: #956407;
}

.status-chip.overdue,
.status-chip.delayed,
.status-chip.archived {
  background: rgba(227, 79, 93, 0.12);
  color: var(--danger);
}

.bill-actions {
  grid-column: 1 / -1;
  display: flex;
  gap: 8px;
  justify-content: space-between;
}

.mini-primary,
.card-actions-inline button,
.goal-picker button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  min-height: 42px;
  border: 0;
  border-radius: 16px;
  background: var(--navy);
  color: var(--white);
  padding: 0 13px;
  font-weight: 900;
}

.mini-primary.success {
  background: var(--success);
}

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

.bill-summary article {
  display: grid;
  gap: 6px;
  padding: 12px;
  min-width: 0;
}

.bill-summary .icon {
  color: var(--coral);
}

.bill-summary strong {
  color: var(--navy);
  font-size: 0.95rem;
  font-weight: 950;
}

.filter-row,
.goal-picker {
  display: flex;
  gap: 8px;
  overflow-x: auto;
  padding: 0 0 8px;
  margin-bottom: 12px;
  scrollbar-width: none;
}

.filter-row::-webkit-scrollbar,
.goal-picker::-webkit-scrollbar {
  display: none;
}

.filter-row button,
.goal-picker button {
  flex: 0 0 auto;
  min-height: 40px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: var(--white);
  color: var(--navy);
  padding: 0 14px;
  font-size: 0.82rem;
  font-weight: 760;
  box-shadow: var(--shadow-sm);
  transition: background var(--motion-fast), color var(--motion-fast), border-color var(--motion-fast), transform var(--motion-fast);
}

.filter-row button.active {
  border-color: var(--navy);
  background: var(--navy);
  color: var(--white);
  box-shadow: 0 8px 20px rgba(16, 19, 46, 0.14);
}

.screen-sticky-header {
  position: sticky;
  top: 0;
  z-index: 2;
  margin: -18px -16px 12px;
  padding: max(18px, env(safe-area-inset-top)) 16px 4px;
  background: linear-gradient(180deg, var(--cream) 82%, rgba(255, 248, 242, 0));
}

.goal-card {
  display: grid;
  gap: 12px;
  padding: 16px;
}

.goal-card.hero {
  margin-bottom: 18px;
  background: linear-gradient(145deg, var(--navy), var(--navy-2));
}

.goal-card.hero h3,
.goal-card.hero p,
.goal-card.hero small {
  color: var(--white);
}

.goal-card.hero span {
  color: rgba(255, 255, 255, 0.62);
}

.goal-top {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
}

.goal-top strong {
  color: var(--coral);
  font-size: 1.55rem;
  font-weight: 950;
}

.progress-track {
  height: 12px;
  overflow: hidden;
  border-radius: 999px;
  background: #f1ebe4;
}

.progress-track div {
  height: 100%;
  border-radius: inherit;
  background: linear-gradient(90deg, var(--coral), var(--mint));
}

.plans-hero,
.checkin-intro {
  display: grid;
  gap: 10px;
  margin-bottom: 14px;
  padding: 20px;
  background: var(--white);
}

.plans-hero > div,
.checkin-intro > div {
  display: grid;
  place-items: center;
  width: 62px;
  height: 62px;
  border-radius: 22px;
  background: var(--navy);
  color: var(--white);
}

.feature-card {
  display: grid;
  gap: 12px;
  padding: 16px;
}

.feature-icon {
  background: var(--cream);
  color: var(--coral);
}

.achievement-card,
.profile-card {
  margin-top: 18px;
  padding: 16px;
}

.achievement-list {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.achievement-list span {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  min-height: 36px;
  padding: 0 12px;
  border-radius: 999px;
  background: #f4f0ec;
  color: var(--muted);
  font-size: 0.82rem;
  font-weight: 850;
}

.achievement-list span.unlocked {
  background: var(--peach);
  color: var(--coral);
}

.achievement-list .icon {
  width: 15px;
  height: 15px;
}

.agreement-card {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 12px;
  padding: 16px;
}

.agreement-card small {
  display: block;
  margin-top: 8px;
}

.card-actions-inline {
  grid-column: 1 / -1;
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
}

.card-actions-inline button {
  background: var(--cream);
  color: var(--navy);
}

.insight-card {
  display: grid;
  gap: 10px;
  padding: 16px;
}

.insight-meta,
.insight-action {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}

.insight-meta small {
  color: var(--coral);
  font-weight: 950;
}

.insight-action span {
  color: var(--navy);
  font-weight: 900;
}

.insight-card.tone-warning {
  background: #fff8ed;
}

.insight-card.tone-danger {
  background: #fff1f2;
}

.insight-card.tone-success {
  background: #f1fffb;
}

.premium-feature-card {
  display: grid;
  gap: 12px;
  border: 1px solid rgba(255, 107, 95, 0.26);
  border-radius: var(--radius-lg);
  background: linear-gradient(145deg, var(--navy), var(--navy-2));
  color: var(--white);
  padding: 18px;
  box-shadow: var(--shadow);
}

.premium-feature-card > div {
  display: grid;
  place-items: center;
  width: 46px;
  height: 46px;
  border-radius: 17px;
  background: rgba(255, 255, 255, 0.12);
  color: var(--mint);
}

.premium-feature-card h3,
.premium-feature-card p {
  margin: 0;
}

.premium-feature-card p {
  color: rgba(255, 255, 255, 0.72);
  line-height: 1.45;
}

.profile-card {
  display: flex;
  align-items: center;
  gap: 14px;
  margin-bottom: 14px;
}

.auth-status-card {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 14px;
  padding: 14px;
}

.auth-status-card > div {
  display: grid;
  place-items: center;
  width: 44px;
  height: 44px;
  border-radius: 16px;
  background: var(--mint-2);
  color: var(--success);
}

.auth-status-card span {
  display: grid;
  gap: 3px;
  min-width: 0;
}

.auth-status-card small {
  color: var(--muted);
  overflow-wrap: anywhere;
}

.profile-card strong {
  color: var(--navy);
  font-size: 1.1rem;
  font-weight: 950;
}

.profile-card p {
  margin: 4px 0 0;
  color: var(--muted);
}

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

.settings-item > div {
  display: grid;
  place-items: center;
  width: 42px;
  height: 42px;
  border-radius: 16px;
  background: var(--cream);
  color: var(--coral);
}

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

.settings-item strong {
  color: var(--navy);
}

.notification-panel {
  display: grid;
  gap: 12px;
}

.notification-status-card,
.toggle-row,
.check-row {
  display: grid;
  grid-template-columns: auto 1fr;
  align-items: center;
  gap: 12px;
  padding: 14px;
  border-radius: var(--radius);
  background: var(--cream);
}

.notification-status-card > div {
  display: grid;
  place-items: center;
  width: 42px;
  height: 42px;
  border-radius: 16px;
  background: var(--white);
  color: var(--coral);
}

.toggle-row,
.check-row {
  background: var(--white);
  border: 1px solid rgba(16, 19, 46, 0.08);
}

.toggle-row input,
.check-row input {
  width: 22px;
  height: 22px;
  accent-color: var(--coral);
}

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

.notification-panel strong,
.notification-panel small {
  display: block;
}

.notification-panel small {
  color: var(--muted);
  line-height: 1.35;
}

.legal-note,
.profile-actions {
  display: grid;
  gap: 10px;
  margin: 14px 0;
}

.legal-note {
  grid-template-columns: auto 1fr;
  align-items: start;
  border: 1px solid var(--line);
  border-radius: 20px;
  background: var(--white);
  padding: 14px;
  color: var(--muted);
}

.legal-note .icon {
  color: var(--coral);
}

.legal-note p {
  margin: 0;
  line-height: 1.4;
}

.category-row {
  display: grid;
  grid-template-columns: 1fr 88px 34px;
  align-items: center;
  gap: 10px;
  padding: 13px;
}

.category-row small {
  color: var(--muted);
  font-weight: 900;
  text-align: right;
}

.checkin-form,
.sheet form {
  display: grid;
  gap: 12px;
}

.field {
  display: grid;
  gap: 7px;
}

.field input,
.field select,
.field textarea {
  width: 100%;
  min-height: 54px;
  border: 1px solid var(--line);
  border-radius: var(--radius-md);
  background: var(--white);
  color: var(--navy);
  padding: 0 15px;
  outline: none;
}

.field textarea {
  min-height: 106px;
  resize: vertical;
  padding-top: 14px;
}

.field input:focus,
.field select:focus,
.field textarea:focus {
  border-color: rgba(255, 107, 95, 0.55);
  box-shadow: 0 0 0 4px rgba(255, 107, 95, 0.12);
}

.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  width: 100%;
  min-height: 54px;
  border: 0;
  border-radius: 20px;
  padding: 0 18px;
  font-weight: 950;
  letter-spacing: 0;
}

.button .icon {
  width: 19px;
  height: 19px;
}

.button-small {
  width: auto;
  min-height: 44px;
  padding: 0 14px;
  border-radius: 17px;
}

.button-primary {
  background: var(--coral);
  color: var(--white);
  box-shadow: 0 10px 22px rgba(255, 107, 95, 0.24);
}

.button:disabled,
.link-button:disabled {
  cursor: not-allowed;
  opacity: 0.48;
  box-shadow: none;
}

.button-dark {
  background: var(--navy);
  color: var(--white);
}

.button-ghost {
  border: 1px solid var(--line);
  background: var(--white);
  color: var(--navy);
}

.empty-state {
  display: grid;
  justify-items: start;
  gap: 10px;
  padding: 18px;
}

.empty-state > div {
  display: grid;
  place-items: center;
  width: 48px;
  height: 48px;
  border-radius: 18px;
  background: var(--cream);
  color: var(--coral);
}

.empty-state strong {
  color: var(--navy);
  font-size: 1.05rem;
}

.paywall-screen {
  display: grid;
  gap: 16px;
  min-height: calc(100vh - var(--nav-height));
  min-height: calc(100dvh - var(--nav-height));
}

.paywall-top span {
  color: var(--muted);
  font-weight: 950;
}

.paywall-hero {
  display: grid;
  gap: 14px;
  padding: 22px;
  border-radius: var(--radius-xl);
  background: linear-gradient(145deg, var(--navy), var(--navy-2));
  color: var(--white);
  box-shadow: var(--shadow);
}

.paywall-reason {
  display: grid;
  gap: 6px;
  border: 1px solid rgba(255, 107, 95, 0.28);
  border-radius: 20px;
  background: var(--peach);
  padding: 14px;
}

.paywall-reason strong {
  display: flex;
  align-items: center;
  gap: 8px;
  color: var(--navy);
}

.paywall-reason p {
  margin: 0;
  color: var(--muted);
  line-height: 1.35;
}

.paywall-hero h1 {
  color: var(--white);
  font-size: clamp(2.15rem, 8vw, 3.1rem);
}

.paywall-hero p,
.fine-print {
  color: rgba(255, 255, 255, 0.72);
}

.paywall-value-strip {
  display: grid;
  gap: 3px;
  padding: 14px;
  border: 1px solid rgba(87, 212, 183, 0.2);
  border-radius: 20px;
  background: linear-gradient(135deg, rgba(87, 212, 183, 0.18), rgba(255, 255, 255, 0.08));
}

.paywall-value-strip span,
.paywall-value-strip small {
  color: rgba(255, 255, 255, 0.72);
  font-weight: 700;
}

.paywall-value-strip strong {
  color: var(--white);
  font-size: 1.35rem;
  line-height: 1;
}

.paywall-screen .price-grid {
  grid-template-columns: 1fr;
}

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

.benefit-list span {
  display: flex;
  align-items: center;
  gap: 9px;
  min-height: 48px;
  border: 1px solid var(--line);
  border-radius: 17px;
  background: var(--white);
  padding: 0 13px;
  color: var(--navy);
  font-weight: 850;
}

.benefit-list .icon {
  width: 18px;
  height: 18px;
  color: var(--success);
}

.price-card {
  position: relative;
  display: grid;
  gap: 8px;
  text-align: left;
  color: var(--navy);
  padding: 16px;
  border: 1px solid rgba(16, 19, 46, 0.08);
  background: linear-gradient(145deg, rgba(255, 255, 255, 0.94), rgba(255, 248, 242, 0.92));
  overflow: hidden;
}

.price-card.highlighted {
  border-color: rgba(255, 107, 95, 0.45);
  background:
    radial-gradient(circle at 92% 0%, rgba(87, 212, 183, 0.22), transparent 30%),
    linear-gradient(145deg, #fff2eb, var(--peach));
}

.price-card.selected {
  border-color: rgba(255, 107, 95, 0.72);
  outline: 3px solid rgba(255, 107, 95, 0.18);
  box-shadow: var(--shadow-md);
}

.price-card-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}

.price-card-top span {
  color: var(--navy);
  font-weight: 850;
}

.price-card-top em {
  display: inline-flex;
  align-items: center;
  min-height: 26px;
  padding: 0 9px;
  border-radius: 999px;
  background: rgba(255, 107, 95, 0.12);
  color: var(--coral);
  font-size: 0.72rem;
  font-style: normal;
  font-weight: 850;
  white-space: nowrap;
}

.price-card strong {
  font-size: 1.72rem;
  font-weight: 950;
}

.price-period {
  margin-top: -7px;
}

.price-card p {
  margin: 0;
  color: var(--muted);
  font-size: 0.9rem;
  line-height: 1.35;
}

.price-detail-list {
  display: grid;
  gap: 4px;
  margin-top: 3px;
}

.price-detail-list small {
  color: var(--navy);
  font-size: 0.82rem;
  font-weight: 700;
}

.paywall-guarantee {
  margin: 0;
  border-radius: 18px;
  background: var(--mint-2);
  color: var(--navy);
  padding: 13px 14px;
  font-weight: 950;
  text-align: center;
}

.fine-print {
  color: var(--muted);
  font-size: 0.82rem;
  text-align: center;
}

.bottom-nav {
  position: fixed;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 20;
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  min-height: calc(var(--nav-height) + env(safe-area-inset-bottom));
  padding: 8px 8px calc(8px + env(safe-area-inset-bottom));
  border-top: 1px solid rgba(16, 19, 46, 0.08);
  background: rgba(255, 255, 255, 0.92);
  backdrop-filter: blur(18px);
  box-shadow: 0 -12px 30px rgba(16, 19, 46, 0.08);
}

.bottom-nav button {
  display: grid;
  place-items: center;
  gap: 3px;
  min-width: 0;
  min-height: 58px;
  border: 0;
  border-radius: 18px;
  background: transparent;
  color: var(--muted);
  font-size: 0.72rem;
  font-weight: 900;
}

.bottom-nav .icon {
  width: 21px;
  height: 21px;
}

.bottom-nav button.active {
  background: var(--navy);
  color: var(--white);
}

.sheet-backdrop {
  position: fixed;
  inset: 0;
  z-index: 40;
  display: grid;
  align-items: end;
  background: rgba(16, 19, 46, 0.38);
  animation: fadeIn 180ms ease both;
}

.sheet {
  width: min(100%, 560px);
  max-height: min(88vh, 760px);
  max-height: min(88dvh, 760px);
  margin: 0 auto;
  overflow-y: auto;
  border-radius: 30px 30px 0 0;
  background: var(--cream);
  padding: 10px 16px calc(18px + env(safe-area-inset-bottom));
  box-shadow: 0 -20px 60px rgba(16, 19, 46, 0.22);
  animation: sheetUp 220ms ease both;
}

.sheet-handle {
  width: 44px;
  height: 5px;
  margin: 2px auto 14px;
  border-radius: 999px;
  background: #ded4ca;
}

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

.sheet-header h2 {
  margin: 0;
  color: var(--navy);
  font-size: 1.35rem;
}

.detail-sheet,
.success-state {
  display: grid;
  gap: 14px;
}

.detail-sheet h3 {
  margin: 0;
  color: var(--navy);
  font-size: 1.4rem;
}

.detail-sheet strong {
  color: var(--navy);
  font-size: 2rem;
  font-weight: 950;
}

.detail-sheet p {
  margin: 0;
  color: var(--muted);
  line-height: 1.45;
}

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

.payment-summary,
.goal-movement-summary {
  display: grid;
  gap: 8px;
  padding: 16px;
  border: 1px solid rgba(16, 19, 46, 0.08);
  border-radius: 20px;
  background: linear-gradient(145deg, rgba(234, 248, 244, 0.92), rgba(255, 250, 246, 0.96));
  box-shadow: var(--shadow-sm);
}

.payment-summary.income {
  background: linear-gradient(145deg, rgba(234, 248, 244, 0.96), rgba(255, 255, 255, 0.94));
}

.payment-summary span,
.goal-movement-summary span,
.movement-balance {
  color: var(--muted);
  font-size: 0.86rem;
  font-weight: 700;
}

.payment-summary h3 {
  margin: 0;
  color: var(--navy);
  font-size: 1.15rem;
}

.payment-summary strong,
.goal-movement-summary strong {
  color: var(--navy);
  font-size: 1.9rem;
  font-weight: 900;
}

.payment-summary small,
.goal-movement-summary small {
  color: var(--muted);
  font-size: 0.84rem;
  line-height: 1.35;
}

.sheet-segmented {
  margin: 2px 0 4px;
}

.movement-balance {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  padding: 12px 14px;
  border-radius: 16px;
  background: rgba(255, 107, 95, 0.08);
}

.movement-balance strong {
  color: var(--navy);
  white-space: nowrap;
}

.cash-movements-card {
  display: grid;
  gap: 14px;
  padding: 18px;
  border: 1px solid rgba(16, 19, 46, 0.08);
  border-radius: var(--radius-lg);
  background: rgba(255, 255, 255, 0.78);
  box-shadow: var(--shadow-sm);
}

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

.movement-row {
  display: grid;
  grid-template-columns: 1fr auto;
  align-items: center;
  gap: 14px;
  padding: 12px 0;
  border-top: 1px solid rgba(16, 19, 46, 0.08);
}

.movement-row:first-child {
  border-top: 0;
  padding-top: 0;
}

.movement-row span,
.movement-row strong {
  color: var(--navy);
  font-weight: 850;
}

.movement-row small {
  display: block;
  margin-top: 3px;
  color: var(--muted);
  font-size: 0.78rem;
}

.movement-row.in strong {
  color: var(--success);
}

.movement-row.out strong {
  color: var(--coral);
}

.success-state {
  justify-items: start;
}

.success-state > div {
  display: grid;
  place-items: center;
  width: 58px;
  height: 58px;
  border-radius: 20px;
  background: var(--mint-2);
  color: var(--success);
}

.toast {
  position: fixed;
  left: 16px;
  right: 16px;
  bottom: calc(var(--nav-height) + 18px + env(safe-area-inset-bottom));
  z-index: 50;
  width: min(calc(100% - 32px), 528px);
  margin: 0 auto;
  border-radius: 18px;
  background: var(--navy);
  color: var(--white);
  padding: 14px 16px;
  box-shadow: var(--shadow);
  font-weight: 850;
  opacity: 0;
  transform: translateY(12px);
  pointer-events: none;
  transition: opacity 180ms ease, transform 180ms ease;
}

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

.error-screen {
  display: grid;
  place-content: center;
  gap: 12px;
  padding: 24px;
}

.error-screen pre {
  max-width: 100%;
  overflow: auto;
  color: var(--danger);
}

/* Million Dollar Polish */
.eyebrow {
  font-weight: 750;
  text-transform: none;
}

.app-header {
  margin-bottom: var(--space-5);
}

.app-header h1 {
  font-size: clamp(1.65rem, 6.4vw, 2.35rem);
  font-weight: 850;
  letter-spacing: 0;
}

.app-header p,
.health-copy small,
.money-card p,
.empty-state p,
.feature-card p,
.settings-item small {
  font-weight: 450;
  line-height: 1.48;
}

.health-card,
.money-card,
.bill-card,
.goal-card,
.agreement-card,
.insight-card,
.feature-card,
.settings-item,
.cash-hero,
.cashflow-card,
.relationship-today,
.plan-status-card,
.premium-entry-card,
.next-action-card,
.smart-summary-card {
  box-shadow: var(--shadow-sm);
  transition: transform var(--motion-fast), box-shadow var(--motion-fast), border-color var(--motion-fast);
}

.health-card:active,
.money-card:active,
.bill-card:active,
.goal-card:active,
.agreement-card:active,
.insight-card:active,
.feature-card:active,
.settings-item:active,
.premium-entry-card:active,
.smart-summary-card:active,
.price-card:active,
.button:active,
.mini-primary:active,
.card-actions-inline button:active,
.bottom-nav button:active {
  transform: scale(0.985);
}

.hero-status {
  display: inline-flex;
  align-items: center;
  gap: var(--space-2);
  margin-bottom: var(--space-3);
  color: rgba(255, 255, 255, 0.72);
  font-size: 0.76rem;
  font-weight: 750;
}

.hero-status span {
  width: 8px;
  height: 8px;
  border-radius: 999px;
  background: var(--mint);
  box-shadow: 0 0 0 6px rgba(87, 212, 183, 0.12);
}

.risk-critical .hero-status span {
  background: var(--danger);
  box-shadow: 0 0 0 6px rgba(227, 79, 93, 0.18);
}

.risk-attention .hero-status span {
  background: var(--coral);
  box-shadow: 0 0 0 6px rgba(255, 107, 95, 0.14);
}

.health-card {
  position: relative;
  padding: var(--space-6);
  border-color: rgba(255, 255, 255, 0.12);
  box-shadow: var(--shadow-premium);
}

.health-card::after {
  content: "";
  position: absolute;
  inset: auto -44px -58px auto;
  width: 150px;
  height: 150px;
  border-radius: 999px;
  background: radial-gradient(circle, rgba(87, 212, 183, 0.22), transparent 68%);
  pointer-events: none;
}

.health-copy h2 {
  font-size: clamp(1.45rem, 6vw, 1.85rem);
  font-weight: 850;
}

.health-copy p strong {
  white-space: nowrap;
}

.score-ring {
  animation: ringIn 700ms cubic-bezier(0.2, 0.8, 0.2, 1) both;
}

.money-card {
  min-height: 132px;
  padding: var(--space-4);
  border-color: rgba(16, 19, 46, 0.06);
  background-image: linear-gradient(145deg, rgba(255, 255, 255, 0.74), rgba(255, 255, 255, 0.94));
}

.money-card span,
.bill-card p,
.goal-card span,
.insight-meta,
.category-row span,
.field span,
.price-card span,
.price-card small {
  font-weight: 650;
}

.money-card strong,
.bill-card strong,
.cash-hero strong,
.category-row strong {
  font-weight: 850;
  white-space: nowrap;
}

.card-icon,
.invite-icon,
.profile-avatar,
.feature-icon,
.agreement-icon,
.premium-entry-icon,
.next-action-icon {
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.55);
}

.premium-entry-card {
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: center;
  gap: var(--space-3);
  margin-top: var(--space-3);
  padding: var(--space-4);
  border-color: rgba(255, 107, 95, 0.18);
  background:
    radial-gradient(circle at 92% 10%, rgba(87, 212, 183, 0.18), transparent 28%),
    linear-gradient(145deg, rgba(16, 19, 46, 0.97), rgba(23, 27, 63, 0.94));
  color: var(--white);
}

.premium-entry-icon {
  display: grid;
  place-items: center;
  width: 44px;
  height: 44px;
  border-radius: 17px;
  background: rgba(255, 255, 255, 0.1);
  color: var(--mint);
}

.premium-entry-card span {
  color: var(--mint);
  font-size: 0.76rem;
  font-weight: 800;
}

.premium-entry-card strong {
  display: block;
  margin-top: var(--space-1);
  color: var(--white);
  font-size: 0.98rem;
  line-height: 1.25;
}

.premium-entry-card p {
  margin: var(--space-1) 0 0;
  color: rgba(255, 255, 255, 0.66);
  font-size: 0.84rem;
  line-height: 1.35;
}

.premium-entry-card .mini-primary {
  background: var(--white);
  color: var(--navy);
  white-space: nowrap;
}

.next-action-card {
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: center;
  gap: var(--space-3);
  margin-top: var(--space-3);
  padding: var(--space-4);
  border: 1px solid rgba(16, 19, 46, 0.07);
  border-radius: var(--radius-lg);
  background: linear-gradient(145deg, rgba(255, 255, 255, 0.92), rgba(255, 241, 232, 0.9));
}

.next-action-icon {
  display: grid;
  place-items: center;
  width: 44px;
  height: 44px;
  border-radius: 17px;
  background: var(--navy);
  color: var(--mint);
}

.next-action-card span {
  color: var(--coral);
  font-size: 0.78rem;
  font-weight: 750;
}

.next-action-card strong {
  display: block;
  margin-top: var(--space-1);
  color: var(--navy);
  font-size: 0.95rem;
  font-weight: 720;
  line-height: 1.32;
}

.smart-summary-card {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: var(--space-3);
  margin-top: var(--space-3);
  padding: var(--space-4);
  border: 1px solid rgba(16, 19, 46, 0.07);
  border-radius: var(--radius-lg);
  background: linear-gradient(145deg, rgba(255, 255, 255, 0.96), rgba(223, 251, 244, 0.72));
}

.smart-summary-copy {
  display: grid;
  gap: var(--space-1);
}

.smart-summary-copy span {
  color: var(--coral);
  font-size: 0.78rem;
  font-weight: 750;
}

.smart-summary-copy strong {
  color: var(--navy);
  font-size: 1.04rem;
  font-weight: 820;
  line-height: 1.28;
}

.smart-summary-copy p {
  margin: 0;
  color: var(--muted);
  font-size: 0.9rem;
  line-height: 1.38;
}

.smart-summary-copy b {
  color: var(--navy);
  font-weight: 850;
}

.smart-summary-card .link-button {
  grid-column: 1 / -1;
  justify-self: start;
  min-height: 36px;
  padding: 0;
}

.mini-primary.soft {
  background: rgba(16, 19, 46, 0.07);
  color: var(--navy);
  box-shadow: none;
}

.cashflow-card,
.relationship-today,
.plan-status-card {
  margin-bottom: var(--space-4);
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  background: rgba(255, 255, 255, 0.86);
  padding: var(--space-4);
}

.bill-group {
  display: grid;
  gap: var(--space-3);
  margin-top: var(--space-4);
}

.bill-group .section-heading {
  margin-bottom: 0;
}

.cashflow-steps {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: var(--space-2);
}

.cashflow-step {
  display: grid;
  gap: 5px;
  min-width: 0;
  padding: 10px 8px;
  border-radius: 18px;
  background: var(--cream);
}

.cashflow-step .icon {
  width: 18px;
  height: 18px;
  color: var(--coral);
}

.cashflow-step span {
  color: var(--muted);
  font-size: 0.68rem;
  font-weight: 650;
}

.cashflow-step strong {
  overflow: hidden;
  color: var(--navy);
  font-size: clamp(0.72rem, 2.5vw, 0.84rem);
  font-weight: 880;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.cashflow-step.risk-critical strong {
  color: var(--danger);
}

.search-field {
  display: grid;
  grid-template-columns: auto 1fr;
  align-items: center;
  gap: var(--space-2);
  min-height: 48px;
  margin-bottom: var(--space-3);
  padding: 0 var(--space-3);
  border: 1px solid var(--line);
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.9);
  box-shadow: var(--shadow-sm);
}

.search-field .icon {
  width: 18px;
  height: 18px;
  color: var(--coral);
}

.search-field input {
  min-width: 0;
  border: 0;
  outline: 0;
  background: transparent;
  color: var(--navy);
  font-weight: 550;
}

.relationship-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: var(--space-2);
}

.relationship-grid article {
  display: grid;
  gap: var(--space-1);
  min-height: 92px;
  padding: var(--space-3);
  border-radius: 18px;
  background: var(--cream);
}

.relationship-grid .icon {
  color: var(--coral);
}

.relationship-grid strong {
  color: var(--navy);
  font-size: 1.15rem;
  font-weight: 820;
}

.relationship-grid span {
  color: var(--muted);
  font-size: 0.78rem;
  font-weight: 600;
}

.plan-status-card {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-4);
}

.plan-status-card span {
  color: var(--coral);
  font-size: 0.76rem;
  font-weight: 750;
}

.plan-status-card strong {
  display: block;
  margin-top: var(--space-1);
  color: var(--navy);
  font-size: 1.2rem;
  font-weight: 850;
}

.plan-status-card p {
  margin: var(--space-1) 0 0;
  color: var(--muted);
  line-height: 1.4;
}

.premium-pill {
  justify-self: start;
  padding: 7px 11px;
  border-radius: 999px;
  background: rgba(87, 212, 183, 0.16);
  color: var(--mint);
  font-size: 0.76rem;
  font-weight: 800;
}

.premium-preview {
  display: grid;
  gap: var(--space-1);
  margin-top: var(--space-1);
  padding: var(--space-4);
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: 22px;
  background: rgba(255, 255, 255, 0.08);
}

.premium-preview span,
.premium-preview small {
  color: rgba(255, 255, 255, 0.66);
}

.premium-preview strong {
  color: var(--white);
  font-size: 1.2rem;
}

.bottom-nav {
  left: max(0px, env(safe-area-inset-left));
  right: max(0px, env(safe-area-inset-right));
  min-height: calc(var(--nav-height) + env(safe-area-inset-bottom));
  padding: 7px 12px calc(7px + env(safe-area-inset-bottom));
  background: rgba(255, 255, 255, 0.82);
  box-shadow: 0 -14px 44px rgba(16, 19, 46, 0.12);
}

.bottom-nav button {
  min-height: 54px;
  border-radius: 17px;
  font-weight: 720;
  transition: background var(--motion-fast), color var(--motion-fast), transform var(--motion-fast);
}

.bottom-nav button.active {
  background: rgba(16, 19, 46, 0.08);
  color: var(--navy);
  box-shadow: inset 0 0 0 1px rgba(16, 19, 46, 0.06);
}

.sheet {
  background:
    radial-gradient(circle at 90% 0%, rgba(87, 212, 183, 0.12), transparent 28%),
    var(--cream);
}

.sheet-header {
  align-items: flex-start;
}

.sheet-header h2 {
  font-size: 1.28rem;
  font-weight: 820;
}

.sheet-header p {
  margin: var(--space-1) 0 0;
  color: var(--muted);
  line-height: 1.36;
}

.button,
.mini-primary,
.card-actions-inline button,
.filter-row button,
.goal-picker button {
  transition: transform var(--motion-fast), box-shadow var(--motion-fast), background var(--motion-fast);
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 1ms !important;
    transition-duration: 1ms !important;
  }
}

@media (max-width: 370px) {
  .screen-content {
    padding-left: 12px;
    padding-right: 12px;
  }

  .metric-grid,
  .price-grid {
    gap: 9px;
  }

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

  .premium-entry-card {
    grid-template-columns: auto 1fr;
  }

  .premium-entry-card .mini-primary {
    grid-column: 1 / -1;
    width: 100%;
  }

  .next-action-card {
    grid-template-columns: auto 1fr;
  }

  .next-action-card .link-button {
    grid-column: 1 / -1;
    justify-self: start;
    min-height: 36px;
    padding: 0;
  }

  .money-card {
    padding: 13px;
  }

  .health-card {
    grid-template-columns: 1fr;
  }
}

@media (min-width: 760px) {
  .screen-content,
  .auth-screen,
  .onboarding-screen,
  .invite-screen {
    width: min(100%, 620px);
  }

  .bottom-nav {
    left: 50%;
    width: min(100%, 620px);
    transform: translateX(-50%);
    border-radius: 28px 28px 0 0;
  }
}

@keyframes slideIn {
  from {
    opacity: 0;
    transform: translateX(10px);
  }
  to {
    opacity: 1;
    transform: translateX(0);
  }
}

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

@keyframes sheetUp {
  from {
    transform: translateY(32px);
  }
  to {
    transform: translateY(0);
  }
}

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

@keyframes ringIn {
  from {
    filter: saturate(0.8);
    transform: scale(0.92) rotate(-10deg);
  }
  to {
    filter: saturate(1);
    transform: scale(1) rotate(0deg);
  }
}
