:root{
  --bg:#f6f8fb;
  --card:#ffffff;
  --text:#0f172a;
  --muted:#64748b;
  --border:#e5e7eb;

  --teal:#0b7c79;
  --teal-2:#0a6f6c;

  --pill:#eef2f7;
  --shadow:0 12px 35px rgba(15,23,42,.08);

  --bs-bg:#e9fbf2;
  --bs-text:#0f7a43;

  --ch-bg:#e9f1ff;
  --ch-text:#1f58d7;

  --radius:16px;
}

*{box-sizing:border-box}
html,body{height:100%}
body{
  margin:0;
  font-family: system-ui,-apple-system,Segoe UI,Roboto,Arial,sans-serif;
  background:var(--bg);
  color:var(--text);
  line-height:1.4;
}

a{color:inherit;text-decoration:none}
.container{max-width:1200px;margin:0 auto;padding:0 18px}

.topbar{
  position:sticky; top:0; z-index:50;
  background:#fff;
  border-bottom:1px solid var(--border);
}
.topbar-inner{
  height:64px;
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:16px;
}
.brand{
  display:flex; align-items:center; gap:10px;
  font-weight:700; /* only brand is bold */
}
.brand-badge{
  width:34px;height:34px;border-radius:10px;
  background:#e8f7f7;
  display:grid;place-items:center;
  border:1px solid #d6eeee;
}
.nav{
  display:flex; gap:14px; flex-wrap:wrap;
  font-size:14px;
  color:#334155;
}
.nav a{
  padding:8px 10px;
  border-radius:999px;
}
.nav a.active{
  background:#dcf6f3;
  color:#0b7c79;
  border:1px solid #bdebe6;
}

.hero{
  background:linear-gradient(90deg,var(--teal),#0a6f6c 55%, #085f74);
  color:#fff;
  padding:44px 0;
}
.hero h1{
  margin:0 0 10px;
  font-size:44px;
  letter-spacing:-.02em;
  font-weight:700; /* headline can be bold */
}
.hero p{
  margin:0;
  max-width:820px;
  color:rgba(255,255,255,.9);
  font-size:16px;
  font-weight:400;
}

.card{
  background:var(--card);
  border:1px solid var(--border);
  border-radius:var(--radius);
  box-shadow:var(--shadow);
}

.section{
  margin:22px 0;
}

.pref-card{
  padding:18px 18px;
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:14px;
}
.pref-title{
  font-size:18px;
  font-weight:600; /* light bold */
  margin:0 0 6px;
}
.pref-sub{
  margin:0;
  font-size:13px;
  color:var(--muted);
  font-weight:400;
}

.segment{
  display:inline-flex;
  background:#f1f5f9;
  border:1px solid var(--border);
  border-radius:999px;
  overflow:hidden;
}
.segment button{
  border:0;
  background:transparent;
  padding:9px 14px;
  font-size:13px;
  color:#475569;
  cursor:pointer;
  font-weight:500; /* not heavy */
}
.segment button.active{
  background:#fff;
  color:#0f172a;
  box-shadow:0 6px 18px rgba(15,23,42,.08);
}

.toolbar{
  margin-top:14px;
  display:flex;
  gap:10px;
  flex-wrap:wrap;
}
.btn{
  border:1px solid var(--border);
  background:#fff;
  padding:10px 14px;
  border-radius:12px;
  cursor:pointer;
  font-size:14px;
  font-weight:600;
  display:inline-flex;
  align-items:center;
  gap:8px;
}
.btn.primary{
  background:#0b7c79;
  border-color:#0b7c79;
  color:#fff;
}
.btn:active{transform:translateY(1px)}

.week-card{padding:18px}
.week-title{
  margin:0 0 6px;
  font-size:18px;
  font-weight:600;
}
.week-sub{
  margin:0 0 14px;
  font-size:13px;
  color:var(--muted);
  font-weight:400;
}

.grid{
  display:grid;
  grid-template-columns: repeat(7, minmax(165px, 1fr));
  gap:12px;
  overflow:auto;
  padding-bottom:6px;
}

.day{
  border:1px solid var(--border);
  border-radius:14px;
  background:#fff;
  overflow:hidden;
}
.day-head{
  padding:10px 12px;
  background:#e9fbf2;
  border-bottom:1px solid #d7f3e4;
  font-weight:700;
  color:#0b7c79;
}
.meal-block{
  padding:10px 12px 12px;
}
.meal-label{
  font-size:11px;
  letter-spacing:.08em;
  text-transform:uppercase;
  color:#64748b;
  margin-bottom:6px;
  font-weight:600;
}

.meal-card{
  border:1px solid var(--border);
  border-radius:12px;
  padding:10px 10px;
  background:#fff;
}
.meal-name{
  margin:0 0 10px;
  font-size:14px;
  font-weight:600; /* readable, not heavy */
  color:#0f172a;
  line-height:1.2;
}

.badges{
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:10px;
}
.badge-row{display:flex;gap:8px;flex-wrap:wrap}
.pill{
  font-size:12px;
  padding:3px 8px;
  border-radius:999px;
  border:1px solid var(--border);
  background:var(--pill);
  color:#334155;
  font-weight:600;
}
.pill.bs{background:var(--bs-bg);border-color:#bdebd1;color:var(--bs-text)}
.pill.ch{background:var(--ch-bg);border-color:#bfd2ff;color:var(--ch-text)}

.swap{
  border:0;
  background:transparent;
  color:#0b7c79;
  cursor:pointer;
  font-size:13px;
  font-weight:700;
  display:flex;
  align-items:center;
  gap:6px;
}
.legend{
  margin-top:12px;
  display:flex;
  gap:14px;
  align-items:center;
  font-size:13px;
  color:#475569;
}
.legend .pill{font-weight:700}

.footer{
  margin:28px 0 40px;
  text-align:center;
  color:#64748b;
  font-size:13px;
}
.footer a{color:#334155}

@media (max-width: 980px){
  .nav{display:none}
  .hero h1{font-size:34px}
  .grid{grid-template-columns: repeat(7, minmax(210px, 1fr))}
}

/* Print */
@media print{
  .topbar, .hero, .toolbar, .segment {display:none !important;}
  body{background:#fff}
  .card{box-shadow:none}
  .grid{overflow:visible}
}