:root {
  --bg: #f5f7f2;
  --surface: #ffffff;
  --surface-2: #eef5eb;
  --ink: #172018;
  --muted: #607060;
  --border: #dce7d7;
  --green: #1f7a3d;
  --green-dark: #0f2e1d;
  --lime: #c9f284;
  --lime-soft: #ecffd2;
  --danger: #b34141;
  --shadow: 0 24px 70px rgba(23, 32, 24, 0.12);
  --radius-lg: 28px;
  --radius-md: 18px;
  --radius-sm: 12px;
}

* { box-sizing: border-box; }

body {
  margin: 0;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Arial, sans-serif;
  color: var(--ink);
  background:
    radial-gradient(circle at 15% 8%, rgba(201, 242, 132, 0.58), transparent 24rem),
    radial-gradient(circle at 82% 18%, rgba(46, 138, 71, 0.24), transparent 28rem),
    linear-gradient(135deg, #f8faf5, #e8f0e4 54%, #f6f8f0);
  line-height: 1.45;
}

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

.app-shell {
  min-height: 100vh;
  display: grid;
  grid-template-columns: 280px 1fr;
}

.sidebar {
  background: linear-gradient(180deg, #0b120d 0%, #101710 58%, #142116 100%);
  color: #f8fff0;
  padding: 24px;
  display: flex;
  flex-direction: column;
  gap: 22px;
  position: sticky;
  top: 0;
  height: 100vh;
  border-right: 1px solid rgba(255,255,255,0.08);
}

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

.brand-mark {
  width: 48px;
  height: 48px;
  border-radius: 16px;
  background: linear-gradient(135deg, var(--lime), #59d66a);
  color: #101710;
  display: grid;
  place-items: center;
  font-weight: 900;
  letter-spacing: -0.05em;
  box-shadow: 0 14px 35px rgba(201,242,132,0.22);
}

.brand strong { display: block; font-size: 18px; }
.brand span { color: rgba(248, 255, 240, 0.62); font-size: 13px; }

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

.nav button {
  width: 100%;
  border: 1px solid rgba(255,255,255,0.08);
  background: rgba(255,255,255,0.04);
  color: rgba(248, 255, 240, 0.78);
  border-radius: 14px;
  padding: 12px;
  text-align: left;
  display: flex;
  justify-content: space-between;
  align-items: center;
  transition: transform .18s ease, background .18s ease, border-color .18s ease;
}

.nav button:hover { transform: translateX(3px); border-color: rgba(201,242,132,0.28); }

.nav button.active {
  background: var(--lime);
  color: #101710;
  border-color: transparent;
  font-weight: 800;
}

.sidebar-card {
  margin-top: auto;
  padding: 16px;
  border: 1px solid rgba(255,255,255,0.12);
  background: rgba(255,255,255,0.06);
  border-radius: 18px;
}

.sidebar-card p { margin: 8px 0 0; color: rgba(248,255,240,0.72); font-size: 14px; }

.main { padding: 28px; min-width: 0; }

.topbar {
  max-width: 1240px;
  margin: 0 auto 22px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 18px;
}

.eyebrow {
  margin: 0 0 6px;
  text-transform: uppercase;
  letter-spacing: 0.11em;
  color: var(--green);
  font-weight: 850;
  font-size: 12px;
}

h1, h2, h3, p { text-wrap: pretty; }
h1 { margin: 0; font-size: clamp(30px, 5vw, 58px); letter-spacing: -0.055em; line-height: 0.95; }
h2 { margin: 0 0 12px; font-size: clamp(26px, 3vw, 42px); letter-spacing: -0.045em; line-height: 1; }
h3 { margin: 0 0 8px; font-size: 20px; letter-spacing: -0.025em; }
p { color: var(--muted); }

.ghost-button, .primary-button, .secondary-button {
  border: 0;
  border-radius: 14px;
  min-height: 44px;
  padding: 0 16px;
  font-weight: 800;
  transition: transform .18s ease, box-shadow .18s ease, background .18s ease;
}

.ghost-button { background: var(--surface); color: var(--ink); border: 1px solid var(--border); }
.primary-button { background: var(--ink); color: white; box-shadow: 0 12px 26px rgba(23,32,24,0.18); }
.secondary-button { background: var(--lime); color: var(--ink); }
.ghost-button:hover, .primary-button:hover, .secondary-button:hover { transform: translateY(-2px); }

.prototype-frame {
  max-width: 1240px;
  margin: 0 auto;
  background: rgba(255,255,255,0.58);
  border: 1px solid rgba(255,255,255,0.72);
  border-radius: 34px;
  padding: 22px;
  box-shadow: 0 30px 100px rgba(23, 32, 24, 0.14);
  min-height: 690px;
  backdrop-filter: blur(18px);
  -webkit-backdrop-filter: blur(18px);
}

.hero-layout {
  display: grid;
  grid-template-columns: 1.05fr 0.95fr;
  gap: 22px;
  align-items: stretch;
}

.hero-panel {
  background: linear-gradient(135deg, var(--green-dark), var(--green));
  color: white;
  border-radius: var(--radius-lg);
  padding: clamp(24px, 4vw, 48px);
  min-height: 520px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  overflow: hidden;
  position: relative;
}

.hero-panel::after {
  content: "";
  position: absolute;
  width: 280px;
  height: 280px;
  border-radius: 50%;
  background: rgba(201,242,132,0.22);
  right: -80px;
  top: -80px;
}

.hero-panel h2 { color: white; max-width: 620px; }
.hero-panel p { color: rgba(255,255,255,0.78); max-width: 580px; }
.hero-actions { display: flex; gap: 12px; flex-wrap: wrap; position: relative; z-index: 1; }
.hero-actions .primary-button { background: white; color: var(--green-dark); }

.card-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px; }
.card-grid.three { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.card-grid.single { grid-template-columns: 1fr; }

.card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  padding: 18px;
  box-shadow: 0 12px 34px rgba(23,32,24,0.07);
}

.choice-card {
  min-height: 170px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  transition: transform .18s ease, border-color .18s ease, background .18s ease;
}

.choice-card:hover, .choice-card:focus-within { transform: translateY(-3px); border-color: rgba(31,122,61,0.42); }
.choice-card.selected { background: var(--lime-soft); border-color: var(--green); }

.icon-bubble {
  width: 44px;
  height: 44px;
  border-radius: 14px;
  background: var(--surface-2);
  display: grid;
  place-items: center;
  font-weight: 900;
  color: var(--green-dark);
  margin-bottom: 12px;
}

.form-layout { display: grid; grid-template-columns: 0.9fr 1.1fr; gap: 22px; }
.form-panel { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius-lg); padding: 22px; }
.field { display: grid; gap: 8px; margin-bottom: 16px; }
.field label { font-weight: 800; font-size: 14px; }
.field input, .field select, .field textarea {
  border: 1px solid var(--border);
  background: #fbfdf9;
  border-radius: 12px;
  padding: 12px;
  min-height: 44px;
  color: var(--ink);
}

.chips { display: flex; flex-wrap: wrap; gap: 8px; }
.chip {
  border: 1px solid var(--border);
  background: white;
  color: var(--ink);
  border-radius: 999px;
  padding: 9px 12px;
  font-weight: 750;
}
.chip.active { background: var(--ink); color: white; border-color: var(--ink); }

.discovery-layout { display: grid; grid-template-columns: 320px 1fr; gap: 18px; }
.filters-panel { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius-lg); padding: 18px; height: fit-content; }
.match-list { display: grid; gap: 12px; }
.match-card { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius-md); padding: 18px; display: grid; gap: 12px; }
.match-top { display: flex; justify-content: space-between; gap: 12px; }
.match-type { color: var(--green); font-weight: 900; font-size: 12px; letter-spacing: .08em; text-transform: uppercase; }
.score { background: var(--lime); color: var(--ink); padding: 7px 10px; border-radius: 999px; font-weight: 950; height: fit-content; white-space: nowrap; }
.reasons { display: flex; flex-wrap: wrap; gap: 8px; }
.reason { background: var(--surface-2); border: 1px solid var(--border); border-radius: 999px; padding: 7px 10px; color: #405040; font-size: 13px; }
.match-actions { display: flex; gap: 10px; flex-wrap: wrap; }

.detail-layout { display: grid; grid-template-columns: 1.15fr 0.85fr; gap: 18px; }
.profile-hero { background: linear-gradient(135deg, var(--green-dark), #2e8a47); border-radius: var(--radius-lg); padding: 26px; color: white; min-height: 300px; }
.profile-hero p { color: rgba(255,255,255,0.78); }
.big-score { font-size: 54px; letter-spacing: -0.06em; font-weight: 950; color: var(--lime); }
.metric-grid { display: grid; grid-template-columns: repeat(2,1fr); gap: 12px; margin-top: 18px; }
.metric { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius-md); padding: 16px; }
.metric strong { display: block; font-size: 24px; letter-spacing: -0.04em; }

/* Sharper modern home screen inspired by translucent hero backdrops + solid foreground app previews */
.modern-home {
  position: relative;
  min-height: 646px;
  isolation: isolate;
  overflow: hidden;
  border-radius: 28px;
  background:
    linear-gradient(135deg, rgba(10,16,12,0.88), rgba(18,36,22,0.82)),
    radial-gradient(circle at 78% 16%, rgba(201,242,132,0.42), transparent 24rem);
  color: white;
}

.home-backdrop {
  position: absolute;
  inset: 0;
  z-index: 0;
  background:
    linear-gradient(90deg, rgba(8,13,10,0.88) 0%, rgba(8,13,10,0.58) 48%, rgba(8,13,10,0.72) 100%),
    url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='1400' height='760' viewBox='0 0 1400 760'%3E%3Cdefs%3E%3ClinearGradient id='g' x1='0' y1='0' x2='1' y2='1'%3E%3Cstop stop-color='%231d6f3c'/%3E%3Cstop offset='1' stop-color='%230a100c'/%3E%3C/linearGradient%3E%3Cfilter id='blur'%3E%3CfeGaussianBlur stdDeviation='2'/%3E%3C/filter%3E%3C/defs%3E%3Crect width='1400' height='760' fill='url(%23g)'/%3E%3Cg opacity='.28' filter='url(%23blur)'%3E%3Ccircle cx='190' cy='170' r='110' fill='%23c9f284'/%3E%3Ccircle cx='1140' cy='150' r='150' fill='%2359d66a'/%3E%3Ccircle cx='1020' cy='610' r='190' fill='%232e8a47'/%3E%3Cpath d='M-40 560 C 240 420, 470 660, 760 520 S 1180 380, 1460 500' fill='none' stroke='%23eaffc2' stroke-width='42' opacity='.18'/%3E%3C/g%3E%3Cg opacity='.16'%3E%3Cpath d='M0 620 L1400 260' stroke='%23ffffff'/%3E%3Cpath d='M0 520 L1400 160' stroke='%23ffffff'/%3E%3Cpath d='M0 720 L1400 360' stroke='%23ffffff'/%3E%3C/g%3E%3C/svg%3E") center / cover;
  transform: scale(1.02);
}

.home-backdrop::after {
  content: "";
  position: absolute;
  inset: 0;
  backdrop-filter: blur(3px);
  -webkit-backdrop-filter: blur(3px);
}

.backdrop-card {
  position: absolute;
  width: 250px;
  padding: 16px;
  border: 1px solid rgba(255,255,255,0.20);
  border-radius: 22px;
  background: rgba(255,255,255,0.11);
  box-shadow: 0 28px 70px rgba(0,0,0,0.25);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  color: rgba(255,255,255,0.84);
}
.backdrop-card span { display: block; color: var(--lime); font-size: 12px; font-weight: 900; text-transform: uppercase; letter-spacing: .08em; }
.backdrop-card strong { display: block; margin: 6px 0 3px; color: white; }
.backdrop-card small { color: rgba(255,255,255,0.58); }
.backdrop-card-one { left: 42%; top: 32px; opacity: .62; transform: rotate(-5deg); }
.backdrop-card-two { right: 34px; top: 210px; opacity: .52; transform: rotate(4deg); }
.backdrop-card-three { left: 54%; bottom: 38px; opacity: .42; transform: rotate(-2deg); }

.home-foreground {
  position: relative;
  z-index: 1;
  min-height: 540px;
  display: grid;
  grid-template-columns: minmax(0, 1fr) 470px;
  gap: 34px;
  align-items: center;
  padding: clamp(30px, 5vw, 62px);
}

.hero-copy-block {
  max-width: 650px;
  padding: clamp(24px, 4vw, 44px);
  border-radius: 34px;
  background: rgba(255,255,255,0.92);
  color: var(--ink);
  box-shadow: 0 30px 90px rgba(0,0,0,0.26);
  border: 1px solid rgba(255,255,255,0.8);
}

.launch-pill {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  padding: 9px 12px;
  border-radius: 999px;
  background: #edf8df;
  color: #195f31;
  font-size: 12px;
  font-weight: 900;
  text-transform: uppercase;
  letter-spacing: .08em;
  margin-bottom: 18px;
}
.launch-pill span {
  width: 8px;
  height: 8px;
  border-radius: 999px;
  background: var(--green);
  box-shadow: 0 0 0 6px rgba(31,122,61,0.12);
}

.hero-copy-block h2 {
  font-size: clamp(38px, 6vw, 76px);
  line-height: .92;
  letter-spacing: -0.075em;
  color: #111812;
  margin-bottom: 18px;
}
.hero-copy-block p {
  max-width: 560px;
  font-size: 17px;
  color: #506252;
}
.modern-actions { margin-top: 26px; }
.modern-actions .primary-button { background: #101710; color: white; }
.modern-actions .secondary-button { background: var(--lime); color: #101710; }
.hero-proof-row {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
  margin-top: 22px;
}
.hero-proof-row span {
  padding: 9px 11px;
  border-radius: 999px;
  background: #f2f6ef;
  color: #586857;
  font-size: 12px;
  font-weight: 750;
}
.hero-proof-row strong { color: #142116; }

.phone-showcase {
  min-height: 520px;
  position: relative;
  display: grid;
  place-items: center;
}
.phone {
  width: 234px;
  height: 482px;
  border-radius: 42px;
  padding: 12px;
  background: #111812;
  border: 1px solid rgba(255,255,255,0.18);
  box-shadow: 0 34px 90px rgba(0,0,0,0.38);
  position: relative;
}
.phone-main { transform: rotate(-3deg) translateX(-46px); z-index: 2; }
.phone-secondary { position: absolute; right: 10px; top: 52px; transform: rotate(7deg) scale(.88); opacity: .96; z-index: 1; }
.phone-speaker {
  position: absolute;
  top: 17px;
  left: 50%;
  transform: translateX(-50%);
  width: 66px;
  height: 6px;
  border-radius: 999px;
  background: rgba(255,255,255,0.16);
  z-index: 4;
}
.phone-screen {
  height: 100%;
  border-radius: 32px;
  overflow: hidden;
  padding: 28px 14px 14px;
  background:
    radial-gradient(circle at 20% 8%, rgba(201,242,132,0.85), transparent 8rem),
    linear-gradient(180deg, #f9fff0 0%, #eef7e9 55%, #dcebd5 100%);
  color: #111812;
}
.dark-screen {
  background: linear-gradient(180deg, #142116 0%, #0c130e 100%);
  color: white;
}
.mobile-topline {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 12px;
  font-weight: 900;
  margin-bottom: 16px;
}
.mobile-topline strong {
  background: var(--lime);
  color: #111812;
  border-radius: 999px;
  padding: 6px 8px;
}
.mobile-map {
  height: 205px;
  border-radius: 26px;
  position: relative;
  overflow: hidden;
  background:
    linear-gradient(120deg, rgba(31,122,61,.18) 16%, transparent 16% 34%, rgba(31,122,61,.14) 34% 50%, transparent 50%),
    radial-gradient(circle at 35% 35%, white, #e4f0de);
  border: 1px solid rgba(17,24,18,.08);
}
.mobile-map::before, .mobile-map::after {
  content: "";
  position: absolute;
  inset: 36px -20px auto;
  height: 2px;
  background: rgba(31,122,61,.20);
  transform: rotate(-24deg);
}
.mobile-map::after { inset: auto -30px 58px; transform: rotate(19deg); }
.map-pin {
  position: absolute;
  display: grid;
  place-items: center;
  width: 42px;
  height: 42px;
  border-radius: 16px 16px 16px 4px;
  background: #101710;
  color: var(--lime);
  font-size: 10px;
  font-weight: 950;
  transform: rotate(-45deg);
  box-shadow: 0 12px 26px rgba(16,23,16,.24);
}
.map-pin::first-letter { transform: rotate(45deg); }
.pin-one { left: 26px; top: 70px; }
.pin-two { right: 24px; top: 42px; background: var(--green); color: white; }
.pin-three { left: 84px; bottom: 34px; background: var(--lime); color: #101710; }
.map-route {
  position: absolute;
  width: 118px;
  height: 70px;
  border: 3px dashed rgba(31,122,61,.45);
  border-top: 0;
  border-right: 0;
  left: 56px;
  top: 88px;
  border-radius: 0 0 0 40px;
}
.mobile-card {
  margin-top: 12px;
  border-radius: 22px;
  padding: 13px;
  background: white;
  box-shadow: 0 16px 30px rgba(17,24,18,.12);
}
.mobile-card small { color: var(--green); font-weight: 900; text-transform: uppercase; letter-spacing: .05em; }
.mobile-card strong { display: block; margin: 5px 0; font-size: 15px; }
.mobile-card p { margin: 0; font-size: 12px; color: #607060; }
.mobile-tabs { display: flex; justify-content: center; gap: 6px; margin-top: 14px; }
.mobile-tabs span { width: 7px; height: 7px; border-radius: 999px; background: rgba(16,23,16,.22); }
.mobile-tabs .active { width: 20px; background: #101710; }
.mini-profile-row {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 12px;
  border-radius: 18px;
  background: rgba(255,255,255,0.08);
  border: 1px solid rgba(255,255,255,0.10);
  margin-bottom: 10px;
}
.mini-profile-row strong { display: block; font-size: 13px; }
.mini-profile-row small { display: block; color: rgba(255,255,255,0.58); font-size: 11px; }
.avatar {
  width: 38px;
  height: 38px;
  border-radius: 14px;
  display: grid;
  place-items: center;
  background: var(--lime);
  color: #101710;
  font-size: 12px;
  font-weight: 950;
}
.provider-row .avatar { background: #2e8a47; color: white; }
.goal-stack { display: grid; gap: 8px; margin-top: 20px; }
.goal-stack span {
  padding: 10px 12px;
  border-radius: 999px;
  background: rgba(201,242,132,0.14);
  color: var(--lime);
  font-size: 12px;
  font-weight: 850;
}

.home-feature-strip {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1px;
  margin: 0 clamp(18px, 4vw, 42px) clamp(18px, 4vw, 42px);
  overflow: hidden;
  border-radius: 24px;
  background: rgba(255,255,255,0.18);
  border: 1px solid rgba(255,255,255,0.18);
}
.home-feature-strip article {
  padding: 22px;
  background: rgba(8,13,10,0.42);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
}
.home-feature-strip span { color: var(--lime); font-weight: 950; font-size: 12px; }
.home-feature-strip h3 { color: white; margin-top: 8px; }
.home-feature-strip p { color: rgba(255,255,255,0.66); margin-bottom: 0; }

.toast {
  position: fixed;
  right: 22px;
  bottom: 22px;
  background: var(--ink);
  color: white;
  padding: 14px 16px;
  border-radius: 16px;
  box-shadow: var(--shadow);
  transform: translateY(24px);
  opacity: 0;
  pointer-events: none;
  transition: .22s ease;
  max-width: 320px;
}
.toast.show { transform: translateY(0); opacity: 1; }

.empty-state {
  text-align: center;
  padding: 56px 24px;
  background: var(--surface);
  border: 1px dashed #bdd0b7;
  border-radius: var(--radius-lg);
}

@media (max-width: 1100px) {
  .home-foreground { grid-template-columns: 1fr; }
  .phone-showcase { min-height: 430px; }
  .phone-main { transform: rotate(-3deg) translateX(-88px); }
  .phone-secondary { right: 18%; top: 24px; }
}

@media (max-width: 980px) {
  .app-shell { grid-template-columns: 1fr; }
  .sidebar { position: static; height: auto; }
  .main { padding: 18px; }
  .topbar, .hero-layout, .form-layout, .discovery-layout, .detail-layout { grid-template-columns: 1fr; }
  .topbar { align-items: flex-start; }
  .card-grid, .card-grid.three { grid-template-columns: 1fr; }
  .home-feature-strip { grid-template-columns: 1fr; }
}

@media (max-width: 680px) {
  .prototype-frame { padding: 12px; border-radius: 24px; }
  .modern-home { border-radius: 20px; }
  .home-foreground { padding: 18px; }
  .hero-copy-block { padding: 22px; border-radius: 24px; }
  .hero-copy-block h2 { font-size: 42px; }
  .phone-showcase { min-height: 380px; overflow: hidden; }
  .phone { width: 196px; height: 408px; border-radius: 34px; }
  .phone-screen { border-radius: 26px; }
  .phone-main { transform: rotate(-3deg) translateX(-54px) scale(.86); }
  .phone-secondary { right: -8px; top: 40px; transform: rotate(7deg) scale(.76); }
  .backdrop-card { display: none; }
}

@media (prefers-reduced-motion: reduce) {
  * { transition: none !important; scroll-behavior: auto !important; }
}
