/* ── Base ─────────────────────────────────────────────────── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

html { overflow-x: hidden; }
body {
  font-family: 'Inter', sans-serif;
  background: #f2f4ee;
  color: #0e1e18;
  min-height: 100vh;
  overflow-x: hidden;
}

/* ── Header (green) ───────────────────────────────────────── */
.rz-header {
  background: #0c3f35;
  padding: 18px 20px 16px;
  position: sticky;
  top: 0;
  z-index: 60;
}

.rz-header-top {
  display: flex;
  align-items: center;
  gap: 14px;
  max-width: 1200px;
  margin: 0 auto 14px;
}

.rz-back {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 38px;
  height: 38px;
  border-radius: 50%;
  color: #fff;
  text-decoration: none;
  background: rgba(255,255,255,0.15);
  flex-shrink: 0;
  transition: background 0.15s;
}
.rz-back:hover { background: rgba(255,255,255,0.25); }

.rz-header-text {
  flex: 1;
}
.rz-header-title {
  font-size: 1.3rem;
  font-weight: 900;
  color: #fff;
  letter-spacing: -0.02em;
  line-height: 1.1;
}
.rz-header-sub {
  font-size: 0.78rem;
  color: rgba(255,255,255,0.65);
  font-weight: 500;
  margin-top: 2px;
}

/* Header button group */
.rz-header-btns {
  display: none; /* hidden on mobile, shown via media query */
  align-items: center;
  gap: 8px;
  flex-shrink: 0;
}
@media (min-width: 500px) {
  .rz-header-btns { display: flex; }
}

/* Mobile overflow menu */
.rz-header-more-wrap {
  position: relative;
  flex-shrink: 0;
}
@media (min-width: 500px) {
  .rz-header-more-wrap { display: none; }
}
.rz-header-more-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 38px;
  height: 38px;
  border-radius: 50%;
  background: rgba(255,255,255,0.15);
  border: none;
  color: #fff;
  cursor: pointer;
  transition: background 0.15s;
}
.rz-header-more-btn:hover,
.rz-header-more-btn[aria-expanded="true"] { background: rgba(255,255,255,0.28); }

.rz-header-dd {
  position: absolute;
  top: calc(100% + 10px);
  right: 0;
  background: #fff;
  border-radius: 14px;
  box-shadow: 0 8px 32px rgba(0,0,0,.18);
  overflow: hidden;
  min-width: 180px;
  z-index: 200;
}
.rz-dd-item {
  display: flex;
  align-items: center;
  gap: 10px;
  width: 100%;
  padding: 13px 16px;
  font-family: inherit;
  font-size: 0.88rem;
  font-weight: 700;
  color: #0e1e18;
  text-decoration: none;
  background: transparent;
  border: none;
  cursor: pointer;
  text-align: left;
  transition: background 0.12s;
}
.rz-dd-item:hover { background: #f0f7f4; }
.rz-dd-item + .rz-dd-item { border-top: 1px solid rgba(20,59,50,.07); }

/* "Meine Tagespläne" header button */
.rz-header-plans-btn {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 7px 14px;
  border-radius: 999px;
  background: rgba(255,255,255,0.15);
  color: #fff;
  text-decoration: none;
  font-family: inherit;
  font-size: 0.75rem;
  font-weight: 700;
  white-space: nowrap;
  flex-shrink: 0;
  transition: background 0.15s;
  border: 1px solid rgba(255,255,255,0.2);
}
.rz-header-plans-btn:hover { background: rgba(255,255,255,0.26); }

/* Search inside header */
.rz-search-wrap {
  position: relative;
  max-width: 1200px;
  margin: 0 auto;
}
.rz-search-icon {
  position: absolute;
  left: 14px;
  top: 50%;
  transform: translateY(-50%);
  color: rgba(0,0,0,0.4);
  pointer-events: none;
}
.rz-search {
  width: 100%;
  height: 46px;
  border: none;
  border-radius: 14px;
  background: #fff;
  padding: 0 1rem 0 2.75rem;
  font-family: inherit;
  font-size: 0.9rem;
  color: #0e1e18;
  outline: none;
  box-shadow: 0 2px 12px rgba(0,0,0,0.1);
}
.rz-search::placeholder { color: #aab8b2; }

/* ── Filter bar (sticky below header) ────────────────────── */
.rz-filter-bar {
  position: sticky;
  top: 120px; /* adjust if header height changes */
  z-index: 50;
  background: #f2f4ee;
  border-bottom: 1px solid rgba(20,59,50,0.08);
  padding: 10px 0;
}
.rz-filter-inner {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 20px;
}
.rz-filters {
  display: flex;
  gap: 8px;
  overflow-x: auto;
  scrollbar-width: none;
}
.rz-filters::-webkit-scrollbar { display: none; }

.rz-filter {
  flex-shrink: 0;
  padding: 7px 18px;
  border-radius: 999px;
  border: none;
  background: #fff;
  font-family: inherit;
  font-size: 0.82rem;
  font-weight: 600;
  color: #5f756d;
  cursor: pointer;
  transition: all 0.15s;
  box-shadow: 0 1px 4px rgba(0,0,0,0.07);
  -webkit-tap-highlight-color: transparent;
}
.rz-filter:hover { color: #0c3f35; }
.rz-filter.active {
  background: #0c3f35;
  color: #d1f843;
  box-shadow: none;
}

/* ── Main ─────────────────────────────────────────────────── */
.rz-main {
  max-width: 1200px;
  margin: 0 auto;
  padding: 16px 16px 40px;
  display: flex;
  flex-direction: column;
  gap: 14px;
}

/* On mobile: bottom nav padding */
@media (max-width: 767px) {
  .rz-main {
    padding-bottom: calc(80px + env(safe-area-inset-bottom, 0px));
  }
}

/* ── Section ──────────────────────────────────────────────── */
.rz-section {
  margin: 3rem 0;
  display: flex;
  flex-direction: column;
  gap: 14px;
  background: #ffffff;
  border-radius: 24px;
  padding: 18px 16px 20px;
  box-shadow: 0 2px 10px rgba(0,0,0,0.04);
}

.rz-section-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
}
.rz-section-title {
  font-size: 1.15rem;
  font-weight: 800;
  color: #0e1e18;
  letter-spacing: -0.01em;
}
.rz-section-link {
  font-size: 0.82rem;
  font-weight: 600;
  color: #0c3f35;
  text-decoration: none;
}
.rz-section-link:hover { text-decoration: underline; }

/* ── Highlights horizontal scroll ────────────────────────── */
.rz-highlights {
  display: flex;
  gap: 14px;
  overflow-x: auto;
  scrollbar-width: none;
  padding-bottom: 4px;
  min-width: 0;
}
.rz-highlights::-webkit-scrollbar { display: none; }

.rz-hl-card {
  flex-shrink: 0;
  width: 200px;
  background: #fff;
  border-radius: 22px;
  overflow: hidden;
  box-shadow: 0 4px 16px rgba(0,0,0,0.08);
  cursor: pointer;
  transition: transform 0.2s, box-shadow 0.2s;
}
.rz-hl-card:hover { transform: translateY(-3px); box-shadow: 0 10px 28px rgba(0,0,0,0.12); }

.rz-hl-img-wrap {
  width: 100%;
  height: 130px;
  overflow: hidden;
}
.rz-hl-img-wrap img {
  width: 100%; height: 100%; object-fit: cover;
  transition: transform 0.3s;
}
.rz-hl-card:hover .rz-hl-img-wrap img { transform: scale(1.05); }

.rz-hl-body {
  padding: 12px 14px 14px;
}
.rz-hl-badge {
  display: inline-block;
  background: #d1f843;
  color: #0c3f35;
  font-size: 0.65rem;
  font-weight: 800;
  padding: 2px 9px;
  border-radius: 999px;
  letter-spacing: 0.04em;
  margin-bottom: 6px;
}
.rz-hl-title {
  font-size: 0.875rem;
  font-weight: 700;
  color: #0e1e18;
  line-height: 1.3;
  margin-bottom: 3px;
}
.rz-hl-sub {
  font-size: 0.72rem;
  color: #7a9088;
  font-weight: 500;
}

/* ── Category groups (Nach Mahlzeit / Nach Art) ──────────── */
.rz-cats-groups {
  display: flex;
  flex-direction: column;
  gap: 14px;
}
.rz-cats-group {
  display: flex;
  flex-direction: column;
  gap: 7px;
}
.rz-cats-group-label {
  font-size: 0.7rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.07em;
  color: #8aab9e;
  padding: 0 2px;
}

/* ── Category tabs ────────────────────────────────────────── */
.rz-cats-row {
  overflow-x: auto;
  scrollbar-width: none;
  min-width: 0;
}
.rz-cats-row::-webkit-scrollbar { display: none; }

/* In-section search */
.rz-cat-search-wrap {
  position: relative;
}
.rz-cat-search-icon {
  position: absolute;
  left: 12px;
  top: 50%;
  transform: translateY(-50%);
  color: #aab8b2;
  pointer-events: none;
}
.rz-cat-search {
  width: 100%;
  height: 40px;
  border: 1.5px solid rgba(20,59,50,.1);
  border-radius: 12px;
  background: #f8faf8;
  padding: 0 14px 0 36px;
  font-family: inherit;
  font-size: 0.85rem;
  color: #0e1e18;
  outline: none;
  transition: border-color .15s, background .15s;
}
.rz-cat-search:focus {
  border-color: #0c3f35;
  background: #fff;
}
.rz-cat-search::placeholder { color: #aab8b2; }

.rz-cats {
  display: flex;
  gap: 10px;
  min-width: min-content;
}

.rz-cat {
  flex-shrink: 0;
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 10px 20px;
  border-radius: 14px;
  border: 2px solid transparent;
  background: #fff;
  font-family: inherit;
  font-size: 0.875rem;
  font-weight: 700;
  color: #5f756d;
  cursor: pointer;
  transition: all 0.15s;
  box-shadow: 0 1px 4px rgba(0,0,0,0.07);
  -webkit-tap-highlight-color: transparent;
}
.rz-cat:hover { border-color: #0c3f35; color: #0c3f35; }
.rz-cat.active {
  background: #0c3f35;
  color: #fff;
  border-color: transparent;
  box-shadow: none;
}

/* Favoriten tab: pink accent when active */
.rz-cat--favs { gap: 5px; }
.rz-cat--favs svg { transition: fill 0.15s; }
.rz-cat--favs.active {
  background: #e83f6f;
  border-color: transparent;
  color: #fff;
}

/* ── Recipe grid ──────────────────────────────────────────── */
.rz-grid-wrap {
  /* Extra top padding for first row's overflowing images */
  padding-top: 72px;
}

.rz-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 88px 16px; /* large row-gap to accommodate image overflow */
}

@media (min-width: 640px) {
  .rz-grid {
    grid-template-columns: repeat(3, 1fr);
    gap: 88px 20px;
  }
}

@media (min-width: 900px) {
  .rz-grid {
    grid-template-columns: repeat(4, 1fr);
    gap: 88px 24px;
  }
}

/* ── Recipe card (floating image style) ───────────────────── */
.rz-card {
  position: relative;
  background: #fff;
  border-radius: 24px;
  padding: 74px 14px 16px;
  text-align: center;
  box-shadow: 0 4px 20px rgba(0,0,0,0.07);
  transition: transform 0.2s, box-shadow 0.2s;
  cursor: pointer;
}
.rz-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 12px 32px rgba(0,0,0,0.12);
}

/* Image floats above card */
.rz-card-img-wrap {
  position: absolute;
  top: -64px;
  text-decoration: none;
  left: 50%;
  transform: translateX(-50%);
  width: 130px;
  height: 130px;
  border-radius: 26px;
  overflow: hidden;
  box-shadow: 0 8px 28px rgba(0,0,0,0.18);
  background: #e5ebe8;
}
.rz-card-img-wrap img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.3s;
}
.rz-card:hover .rz-card-img-wrap img { transform: scale(1.06); }

.rz-card-body {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
}

.rz-card-tags {
  display: flex;
  gap: 4px;
  justify-content: center;
  flex-wrap: wrap;
}
.rz-tag {
  font-size: 0.62rem;
  font-weight: 700;
  padding: 2px 8px;
  border-radius: 999px;
  background: #eef4f1;
  color: #0c3f35;
  letter-spacing: 0.02em;
}

.rz-phase-badge {
  font-size: 0.6rem;
  font-weight: 800;
  padding: 2px 7px;
  border-radius: 999px;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}
.rz-phase-badge--1 { background: #e6f4ee; color: #0c3f35; }
.rz-phase-badge--2 { background: #f5eedc; color: #7a5a1a; }
.rz-phase-badge--3 { background: #e8f0fa; color: #1e4d8c; }

.rz-card-title-link { text-decoration: none; }

.rz-card-title {
  font-size: 0.9rem;
  font-weight: 800;
  color: #0e1e18;
  line-height: 1.25;
  transition: color 0.15s;
}
.rz-card-title-link:hover .rz-card-title { color: #0c3f35; }

.rz-card-meta {
  font-size: 0.72rem;
  font-weight: 500;
  color: #8aab9e;
}

/* Bottom actions: + button left, ♥ right */
.rz-card-actions {
  display: flex;
  justify-content: space-between;
  align-items: center;
  width: 100%;
  margin-top: 6px;
}

.rz-card-add {
  width: 38px;
  height: 38px;
  border-radius: 50%;
  border: none;
  background: #0e1e18;
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: background 0.15s, transform 0.1s;
  -webkit-tap-highlight-color: transparent;
  text-decoration: none;
  flex-shrink: 0;
}
.rz-card-add:hover { background: #0c3f35; }
.rz-card-add:active { transform: scale(0.9); }

.rz-card-btns {
  display: flex;
  gap: 6px;
  align-items: center;
}

.rz-card-fav,
.rz-card-sl,
.rz-card-plan {
  width: 38px;
  height: 38px;
  border-radius: 50%;
  border: none;
  background: #f0f2ee;
  color: #8aab9e;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: color 0.15s, background 0.15s;
  -webkit-tap-highlight-color: transparent;
}
.rz-card-fav:hover { color: #e83f6f; background: #fdf0f3; }
.rz-card-fav.active { color: #e83f6f; background: #fdf0f3; }
.rz-card-sl:hover { color: #0c3f35; background: #e6f2ed; }
.rz-card-sl.active {
  background: #0c3f35;
  color: #d1f843;
  box-shadow: 0 2px 8px rgba(12, 63, 53,.35);
}

/* ── Pagination ───────────────────────────────────────────── */
.rz-pagination {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 14px;
  padding: 20px 0 8px;
}
.rz-page-btn {
  display: flex;
  align-items: center;
  gap: 5px;
  padding: 9px 18px;
  border-radius: 12px;
  border: 1.5px solid rgba(20,59,50,.15);
  background: #fff;
  font-family: inherit;
  font-size: 0.85rem;
  font-weight: 600;
  color: #0e1e18;
  cursor: pointer;
  transition: background 0.15s, border-color 0.15s;
  -webkit-tap-highlight-color: transparent;
}
.rz-page-btn:hover:not(:disabled) { background: #f0f4f0; border-color: #0c3f35; }
.rz-page-btn:disabled { opacity: 0.35; cursor: default; }
.rz-page-info {
  font-size: 0.82rem;
  font-weight: 600;
  color: #5f756d;
  text-align: center;
}
.rz-page-total { color: #9ab5ae; font-weight: 400; }

/* ── Toast notification ───────────────────────────────────── */
.rz-toast {
  position: fixed;
  bottom: 88px;
  left: 50%;
  transform: translateX(-50%) translateY(12px);
  background: #0e1e18;
  color: #fff;
  padding: 11px 22px;
  border-radius: 999px;
  font-size: 0.84rem;
  font-weight: 600;
  white-space: nowrap;
  pointer-events: none;
  opacity: 0;
  z-index: 2000;
  transition: opacity .18s ease, transform .18s ease;
  box-shadow: 0 4px 16px rgba(0,0,0,.25);
}
.rz-toast.show {
  opacity: 1;
  transform: translateX(-50%) translateY(0);
}

.rz-empty {
  grid-column: 1 / -1;
  text-align: center;
  color: #a0b0ab;
  font-size: 0.9rem;
  padding: 3rem 0;
}

/* ── Tagesplan section ────────────────────────────────────── */
.rz-planner-section {
  background: #fff;
  border-radius: 28px;
  padding: 28px 24px;
  box-shadow: 0 4px 20px rgba(0,0,0,0.07);
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.rz-planner-head {
  display: flex;
  align-items: center;
  gap: 10px;
  color: #0c3f35;
}
.rz-planner-title {
  font-size: 1.1rem;
  font-weight: 800;
  color: #0e1e18;
  letter-spacing: -0.01em;
}
.rz-planner-sub {
  font-size: 0.85rem;
  color: #7a9088;
  line-height: 1.55;
  margin-top: -6px;
}

/* Current weight badge */
.rz-weight-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: rgba(12, 63, 53,0.08);
  border-radius: 999px;
  padding: 6px 12px 6px 10px;
  font-size: 0.78rem;
  font-weight: 600;
  color: #0c3f35;
  margin-top: -4px;
}
.rz-weight-badge svg { flex-shrink: 0; opacity: 0.75; }

/* Preference chips */
.rz-prefs {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}
.rz-pref {
  padding: 7px 18px;
  border-radius: 999px;
  border: 2px solid rgba(20,59,50,0.12);
  background: #f5f7f4;
  font-family: inherit;
  font-size: 0.82rem;
  font-weight: 600;
  color: #5f756d;
  cursor: pointer;
  transition: all 0.15s;
  -webkit-tap-highlight-color: transparent;
}
.rz-pref:hover { border-color: #0c3f35; color: #0c3f35; }
.rz-pref.active {
  background: #0c3f35;
  border-color: #0c3f35;
  color: #d1f843;
}

/* Generate button */
.rz-plan-btn {
  width: 100%;
  height: 54px;
  border-radius: 16px;
  border: none;
  background: #0e1e18;
  color: #d1f843;
  font-family: inherit;
  font-size: 0.9375rem;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  cursor: pointer;
  transition: background 0.15s, transform 0.1s;
  -webkit-tap-highlight-color: transparent;
}
.rz-plan-btn:hover { background: #0c3f35; }
.rz-plan-btn:active { transform: scale(0.99); }

/* Plan result */
.rz-plan-result {
  margin-top: 4px;
  border-top: 1px solid rgba(20,59,50,0.08);
  padding-top: 20px;
}
.rz-plan-label {
  font-size: 0.72rem;
  font-weight: 700;
  color: #0c3f35;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  margin-bottom: 16px;
}
.rz-plan-timeline {
  display: flex;
  flex-direction: column;
  gap: 0;
}
.rz-plan-item {
  display: flex;
  gap: 14px;
  align-items: flex-start;
}
.rz-plan-time-col {
  display: flex;
  flex-direction: column;
  align-items: center;
  flex-shrink: 0;
  width: 44px;
  padding-top: 4px;
}
.rz-plan-time {
  font-size: 0.65rem;
  font-weight: 700;
  color: #0c3f35;
  letter-spacing: 0.04em;
  white-space: nowrap;
}
.rz-plan-dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: #0c3f35;
  margin: 5px 0 0;
}
.rz-plan-line {
  width: 2px;
  flex: 1;
  min-height: 40px;
  background: rgba(12, 63, 53,0.15);
  margin-bottom: -4px;
}
.rz-plan-item:last-child .rz-plan-line { display: none; }

.rz-plan-card {
  display: flex;
  gap: 12px;
  background: #f5f7f4;
  border-radius: 16px;
  overflow: hidden;
  flex: 1;
  margin-bottom: 12px;
}
.rz-plan-card img {
  width: 80px;
  height: 80px;
  object-fit: cover;
  flex-shrink: 0;
}
.rz-plan-card-body {
  padding: 10px 12px;
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 3px;
}
.rz-plan-meal-label {
  font-size: 0.65rem;
  font-weight: 700;
  color: #0c3f35;
  text-transform: uppercase;
  letter-spacing: 0.07em;
}
.rz-plan-card-title {
  font-size: 0.875rem;
  font-weight: 700;
  color: #0e1e18;
  line-height: 1.3;
}
.rz-plan-card-meta {
  font-size: 0.72rem;
  font-weight: 500;
  color: #8aab9e;
}

/* ── Bottom navigation (mobile only) ─────────────────────── */
.dash-bottom-nav {
  display: none;
}

@media (max-width: 767px) {
  .dash-bottom-nav {
    display: flex;
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    background: #0c3f35;
    box-shadow: 0 -4px 24px rgba(0,0,0,0.18);
    z-index: 100;
    padding: 0 0 env(safe-area-inset-bottom, 0);
  }
}

.dash-bn-item {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 3px;
  padding: 10px 4px 8px;
  border: none;
  background: transparent;
  cursor: pointer;
  color: #ffffff;
  font-family: inherit;
  font-size: 0.6rem;
  font-weight: 600;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  text-decoration: none;
  transition: color 0.12s;
  -webkit-tap-highlight-color: transparent;
  position: relative;
}
.dash-bn-item svg { transition: transform 0.15s; }
.dash-bn-item.active { color: #d1f843; }
.dash-bn-item.active svg { transform: translateY(-1px); }
.dash-bn-item.active::after {
  content: '';
  position: absolute;
  top: 0; left: 50%;
  transform: translateX(-50%);
  width: 28px; height: 3px;
  background: #d1f843;
  border-radius: 0 0 3px 3px;
}
/* „aktiv"-Badge unter dem Label (wie im Dashboard) */
.dash-bn-badge {
  font-size: 0.48rem; font-weight: 800; letter-spacing: 0.1em; text-transform: uppercase;
  color: rgba(255,255,255,0.6); line-height: 1; margin-top: -1px;
}
.dash-bn-item.active .dash-bn-badge { color: #d1f843; }
.dash-bn-badge--gold { color: rgba(201,169,110,0.7); }
.dash-bn-item.active .dash-bn-badge--gold { color: #c9a96e; }
/* Legacy: aktives Legacy-Item in Gold (Balken bleibt dunkelgrün) */
.dash-bn-item[data-tab="legacy"].active { color: #c9a96e; }
.dash-bn-item[data-tab="legacy"].active svg { color: #c9a96e; }
.dash-bn-item[data-tab="legacy"].active::after { background: #c9a96e; }
.dash-bn-item[data-tab="legacy"].active .dash-bn-badge--gold { color: #c9a96e; }

/* ── Desktop tweaks ───────────────────────────────────────── */

@media (min-width: 768px) {
  .rz-header { padding: 20px 32px 18px; }
  .rz-filter-inner { padding: 0 32px; }
  .rz-main { padding: 20px 28px 48px; gap: 16px; }
  .rz-filter-bar { top: 130px; }

  .rz-hl-card { width: 240px; }
  .rz-hl-img-wrap { height: 160px; }

  .rz-card-img-wrap { width: 150px; height: 150px; top: -74px; }
  .rz-card { padding-top: 86px; }
  .rz-grid-wrap { padding-top: 84px; }
}

@media (min-width: 1100px) {
  .rz-header { padding: 22px 40px 20px; }
  .rz-filter-inner { padding: 0 40px; }
  .rz-main { padding: 24px 40px 56px; gap: 18px; }
}

/* ── Date Section ─────────────────────────────────────────── */
.rz-date-section {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.rz-date-quick {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}

.rz-date-chip {
  display: flex;
  align-items: center;
  gap: 5px;
  padding: 7px 16px;
  border-radius: 999px;
  border: 1.5px solid rgba(20,59,50,0.14);
  background: #f5f7f4;
  font-family: inherit;
  font-size: 0.82rem;
  font-weight: 600;
  color: #5f756d;
  cursor: pointer;
  transition: all 0.15s;
  -webkit-tap-highlight-color: transparent;
}
.rz-date-chip:hover { border-color: #0c3f35; color: #0c3f35; }
.rz-date-chip.active {
  background: #0c3f35;
  border-color: #0c3f35;
  color: #d1f843;
}

.rz-date-display {
  font-size: 0.82rem;
  font-weight: 600;
  color: #0c3f35;
  padding: 0 2px;
}

/* ── Inline Calendar ──────────────────────────────────────── */
.rz-calendar {
  background: #f8faf7;
  border: 1px solid rgba(20,59,50,0.1);
  border-radius: 20px;
  padding: 16px;
  max-width: 320px;
}

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

.rz-cal-month-label {
  font-size: 0.875rem;
  font-weight: 700;
  color: #0e1e18;
}

.rz-cal-nav {
  width: 30px;
  height: 30px;
  border-radius: 50%;
  border: none;
  background: transparent;
  color: #5f756d;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background 0.15s, color 0.15s;
  -webkit-tap-highlight-color: transparent;
}
.rz-cal-nav:hover { background: rgba(12, 63, 53,0.08); color: #0c3f35; }

.rz-cal-weekdays {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  text-align: center;
  margin-bottom: 6px;
}
.rz-cal-weekdays span {
  font-size: 0.65rem;
  font-weight: 700;
  color: #aab8b2;
  letter-spacing: 0.04em;
  padding: 4px 0;
}

.rz-cal-grid {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  gap: 2px;
}

.rz-cal-empty { /* placeholder cells */ }

.rz-cal-day {
  aspect-ratio: 1;
  border-radius: 50%;
  border: none;
  background: transparent;
  font-family: inherit;
  font-size: 0.8rem;
  font-weight: 500;
  color: #0e1e18;
  cursor: pointer;
  transition: background 0.12s, color 0.12s;
  -webkit-tap-highlight-color: transparent;
  display: flex;
  align-items: center;
  justify-content: center;
}
.rz-cal-day:hover { background: rgba(12, 63, 53,0.08); color: #0c3f35; }
.rz-cal-day.today {
  background: rgba(12, 63, 53,0.1);
  color: #0c3f35;
  font-weight: 700;
}
.rz-cal-day.selected {
  background: #0c3f35 !important;
  color: #d1f843 !important;
  font-weight: 700;
}

/* ── Plan Save Button ─────────────────────────────────────── */
.rz-plan-save-btn {
  width: 100%;
  height: 50px;
  border-radius: 14px;
  border: 2px solid #0c3f35;
  background: transparent;
  color: #0c3f35;
  font-family: inherit;
  font-size: 0.9rem;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  cursor: pointer;
  margin-top: 16px;
  transition: background 0.15s, color 0.15s;
  -webkit-tap-highlight-color: transparent;
}
.rz-plan-save-btn:hover:not(:disabled) { background: #0c3f35; color: #d1f843; }
.rz-plan-save-btn:disabled { opacity: 0.6; cursor: default; }
.rz-plan-save-btn.saved { background: #0c3f35; color: #d1f843; border-color: #0c3f35; }

.rz-plan-save-status {
  font-size: 0.8rem;
  font-weight: 600;
  margin-top: 8px;
  text-align: center;
}
.rz-plan-save-status.success { color: #0c3f35; }
.rz-plan-save-status.error   { color: #e83f6f; }

/* ══════════════════════════════════════════════════════════
   PROGRAMMTYP / KALORIE-LOGIK
   ══════════════════════════════════════════════════════════ */

/* Goal selector */
.rz-goal-section {
  background: #fff;
  border: 1.5px solid rgba(20,59,50,0.1);
  border-radius: 16px;
  padding: 1.1rem 1.1rem 0.9rem;
  margin-bottom: 1.1rem;
}

.rz-goal-label {
  font-size: 0.72rem;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: #0c3f35;
  margin-bottom: 0.65rem;
}

.rz-goal-toggle {
  display: grid;
  grid-template-columns: 1fr;
  gap: 0.6rem;
  margin-bottom: 1rem;
}

@media (min-width: 460px) {
  .rz-goal-toggle {
    grid-template-columns: 1fr 1fr;
  }
}

.rz-goal-btn {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  padding: 0.75rem 0.9rem;
  border-radius: 12px;
  border: 2px solid rgba(20,59,50,0.12);
  background: #f8faf8;
  cursor: pointer;
  text-align: left;
  transition: border-color 0.15s, background 0.15s;
  -webkit-tap-highlight-color: transparent;
}
.rz-goal-btn:hover { border-color: rgba(12, 63, 53,0.3); background: #f0f7f4; }
.rz-goal-btn.active {
  border-color: #0c3f35;
  background: rgba(12, 63, 53,0.07);
}
.rz-goal-icon { font-size: 1.4rem; flex-shrink: 0; }
.rz-goal-text { display: flex; flex-direction: column; gap: 1px; }
.rz-goal-text strong { font-size: 0.88rem; font-weight: 800; color: #0e1e18; }
.rz-goal-text small  { font-size: 0.72rem; color: #415952; font-weight: 500; }
.rz-goal-btn.active .rz-goal-text strong { color: #0c3f35; }

/* Activity chips */
.rz-activity-row { margin-bottom: 0.75rem; }
.rz-activity-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 0.45rem;
}
.rz-act-chip {
  padding: 0.38rem 0.75rem;
  border-radius: 999px;
  border: 1.5px solid rgba(20,59,50,0.15);
  background: #f8faf8;
  font-size: 0.78rem;
  font-weight: 600;
  color: #415952;
  cursor: pointer;
  transition: background 0.12s, border-color 0.12s, color 0.12s;
}
.rz-act-chip:hover   { background: #f0f7f4; border-color: rgba(12, 63, 53,0.3); }
.rz-act-chip.active  { background: #0c3f35; border-color: #0c3f35; color: #fff; }

/* Sex chips */
.rz-sex-row {
  display: flex;
  gap: 0.45rem;
  margin-bottom: 1rem;
}
.rz-sex-chip {
  padding: 0.38rem 0.75rem;
  border-radius: 999px;
  border: 1.5px solid rgba(20,59,50,0.15);
  background: #f8faf8;
  font-size: 0.78rem;
  font-weight: 600;
  color: #415952;
  cursor: pointer;
  transition: background 0.12s, border-color 0.12s, color 0.12s;
}
.rz-sex-chip:hover  { background: #f0f7f4; }
.rz-sex-chip.active { background: #0c3f35; border-color: #0c3f35; color: #fff; }

/* Kcal target card */
.rz-kcal-target {
  background: linear-gradient(135deg, #0c3f35 0%, #007a57 100%);
  border-radius: 12px;
  padding: 0.9rem 1rem;
  color: #fff;
}
.rz-kcal-main {
  display: flex;
  align-items: baseline;
  gap: 0.4rem;
  margin-bottom: 0.5rem;
}
.rz-kcal-value {
  font-size: 2rem;
  font-weight: 900;
  letter-spacing: -0.03em;
  line-height: 1;
}
.rz-kcal-unit { font-size: 0.82rem; font-weight: 600; opacity: 0.8; }

.rz-kcal-macros {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin-bottom: 0.5rem;
}
.rz-macro {
  font-size: 0.78rem;
  font-weight: 700;
  background: rgba(255,255,255,0.15);
  border-radius: 999px;
  padding: 0.25rem 0.6rem;
}
.rz-kcal-note {
  font-size: 0.73rem;
  opacity: 0.75;
  line-height: 1.45;
  margin: 0;
}

/* ── Plan Nutrition Bar ─────────────────────────────────── */
.rz-plan-nutrition {
  background: #fff;
  border: 1.5px solid rgba(20,59,50,0.1);
  border-radius: 12px;
  padding: 0.9rem 1rem;
  margin-bottom: 1rem;
}
.rz-nutr-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 0.5rem;
}
.rz-nutr-label { font-size: 0.78rem; font-weight: 700; color: #415952; }
.rz-nutr-val   { font-size: 0.85rem; font-weight: 800; }
.rz-nutr-bar-wrap {
  height: 8px;
  background: rgba(20,59,50,0.1);
  border-radius: 999px;
  overflow: hidden;
  margin-bottom: 0.4rem;
}
.rz-nutr-bar-fill {
  height: 100%;
  border-radius: 999px;
  transition: width 0.4s ease;
}
.rz-nutr-diff { font-size: 0.75rem; font-weight: 700; margin: 0; }

/* ── Swap button on plan card ───────────────────────────── */
.rz-plan-card { position: relative; }

.rz-swap-btn {
  position: absolute;
  top: 8px;
  right: 8px;
  width: 32px;
  height: 32px;
  border-radius: 8px;
  border: 1.5px solid rgba(20,59,50,0.15);
  background: rgba(255,255,255,0.92);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  color: #415952;
  transition: background 0.12s, color 0.12s;
  -webkit-tap-highlight-color: transparent;
}
.rz-swap-btn:hover { background: #0c3f35; color: #fff; border-color: #0c3f35; }

/* ── Swap sheet (bottom sheet on mobile) ────────────────── */
.rz-swap-sheet {
  position: fixed;
  inset: 0;
  z-index: 200;
  display: flex;
  align-items: flex-end;
}
.rz-swap-sheet[hidden] { display: none; }

.rz-swap-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(14,30,24,0.5);
  backdrop-filter: blur(2px);
}
.rz-swap-panel {
  position: relative;
  background: #fff;
  border-radius: 20px 20px 0 0;
  width: 100%;
  max-height: 75vh;
  overflow-y: auto;
  padding: 0 0 calc(env(safe-area-inset-bottom) + 1.5rem);
  animation: slideUp 0.22s ease;
}
@keyframes slideUp {
  from { transform: translateY(100%); }
  to   { transform: translateY(0); }
}
.rz-swap-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1rem 1.1rem 0.75rem;
  border-bottom: 1px solid rgba(20,59,50,0.1);
  position: sticky;
  top: 0;
  background: #fff;
  z-index: 1;
}
.rz-swap-title { font-size: 1rem; font-weight: 800; color: #0e1e18; }
.rz-swap-close {
  width: 32px;
  height: 32px;
  border-radius: 8px;
  border: none;
  background: rgba(20,59,50,0.08);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  color: #415952;
}

.rz-swap-list {
  display: flex;
  flex-direction: column;
  gap: 0;
}
.rz-swap-option {
  display: flex;
  align-items: center;
  gap: 0.85rem;
  padding: 0.85rem 1.1rem;
  border: none;
  border-bottom: 1px solid rgba(20,59,50,0.07);
  background: none;
  cursor: pointer;
  text-align: left;
  width: 100%;
  transition: background 0.12s;
  position: relative;
  -webkit-tap-highlight-color: transparent;
}
.rz-swap-option:hover { background: #f8faf8; }
.rz-swap-option.is-current { background: rgba(12, 63, 53,0.05); cursor: default; }
.rz-swap-option img {
  width: 56px;
  height: 56px;
  border-radius: 10px;
  object-fit: cover;
  flex-shrink: 0;
}
.rz-swap-option-body { flex: 1; min-width: 0; }
.rz-swap-option-title {
  font-size: 0.88rem;
  font-weight: 700;
  color: #0e1e18;
  margin-bottom: 2px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.rz-swap-option-meta { font-size: 0.75rem; color: #415952; }
.rz-swap-current-badge {
  font-size: 0.7rem;
  font-weight: 700;
  background: #0c3f35;
  color: #fff;
  border-radius: 999px;
  padding: 0.2rem 0.55rem;
  flex-shrink: 0;
}

@media (min-width: 640px) {
  .rz-swap-panel {
    max-width: 480px;
    margin: 0 auto;
    border-radius: 20px;
    margin-bottom: 2rem;
    max-height: 80vh;
  }
  .rz-swap-sheet { align-items: center; justify-content: center; }
}

/* ══════════════════════════════════════════════════════════
   EINKAUFSLISTE (inline section)
   ══════════════════════════════════════════════════════════ */

.sl-section {
  max-width: 700px;
  margin: 0 auto;
  padding: 0 0 100px;
}


/* Filter bar */
.sl-filterbar {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 20px 14px;
  min-width: 0;
}
.sl-filters {
  display: flex;
  align-items: center;
  gap: 8px;
  flex: 1;
  min-width: 0;
  overflow-x: auto;
  scrollbar-width: none;
}
.sl-filters::-webkit-scrollbar { display: none; }
.sl-filter {
  display: inline-flex;
  align-items: center;
  white-space: nowrap;
  flex-shrink: 0;
  padding: 6px 16px;
  border-radius: 999px;
  border: 1.5px solid rgba(20,59,50,.14);
  background: #fff;
  font-family: inherit;
  font-size: 0.82rem;
  font-weight: 700;
  color: #415952;
  cursor: pointer;
  transition: background .13s, border-color .13s, color .13s;
}
.sl-filter:hover { border-color: #0c3f35; color: #0c3f35; }
.sl-filter.active {
  background: #0c3f35;
  border-color: #0c3f35;
  color: #d1f843;
}

/* Body */
.sl-body {
  padding: 4px 20px 20px;
}

/* Active state on header button */
.rz-header-sl-btn.active {
  background: #d1f843;
  color: #0e1e18;
  border-color: #d1f843;
}

/* Empty state */
.sl-empty {
  text-align: center;
  padding: 40px 20px;
  color: #7a9088;
  font-size: 0.88rem;
  line-height: 1.6;
}

/* Plan grid (overview) */
.sl-plans-grid {
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.sl-plan-tile {
  display: flex;
  align-items: center;
  gap: 12px;
  background: #fff;
  border: 1.5px solid rgba(20,59,50,.1);
  border-radius: 14px;
  padding: 14px 16px;
  cursor: pointer;
  text-align: left;
  width: 100%;
  font-family: inherit;
  transition: border-color .13s, background .13s;
}
.sl-plan-tile:hover { border-color: #0c3f35; background: #f0f7f4; }
.sl-plan-date {
  font-size: 0.92rem;
  font-weight: 800;
  color: #0e1e18;
  flex: 1;
}
.sl-plan-meta {
  font-size: 0.78rem;
  color: #7a9088;
  white-space: nowrap;
}
.sl-plan-arrow { color: #7a9088; margin-left: 4px; display: flex; }

/* Meal group (plan detail) */
.sl-meal-group {
  margin-bottom: 20px;
}
.sl-meal-label {
  font-size: 0.7rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: .08em;
  color: #0c3f35;
  margin-bottom: 8px;
}
.sl-meal-label span {
  font-weight: 500;
  color: #7a9088;
  text-transform: none;
  letter-spacing: 0;
}

/* Checklist */
.sl-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 4px;
}
.sl-item {
  display: flex;
  align-items: center;
  gap: 12px;
  background: #fff;
  border: 1.5px solid rgba(20,59,50,.08);
  border-radius: 12px;
  padding: 11px 14px;
  transition: opacity .15s;
  cursor: pointer;
}
.sl-item:hover { border-color: rgba(20,59,50,.2); }
.sl-item--done { opacity: .5; }
.sl-item--done .sl-item-name {
  text-decoration: line-through;
  color: #7a9088;
}
.sl-check {
  flex-shrink: 0;
  width: 26px;
  height: 26px;
  border-radius: 50%;
  border: 2px solid rgba(20,59,50,.2);
  background: transparent;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  color: transparent;
  transition: background .13s, border-color .13s, color .13s;
}
.sl-item--done .sl-check {
  background: #0c3f35;
  border-color: #0c3f35;
  color: #d1f843;
}
.sl-item-name {
  flex: 1;
  font-size: 0.88rem;
  font-weight: 600;
  color: #0e1e18;
}
.sl-item-amount {
  font-size: 0.78rem;
  color: #7a9088;
  font-weight: 500;
  white-space: nowrap;
}
.sl-item-del {
  flex-shrink: 0;
  width: 26px;
  height: 26px;
  border-radius: 50%;
  border: none;
  background: transparent;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #b0c4bc;
  cursor: pointer;
  transition: background .13s, color .13s;
  margin-left: auto;
  padding: 0;
}
.sl-item-del:hover { background: #fee2e2; color: #dc2626; }

/* Meine Rezepte tile with delete */
.sl-tile-wrap {
  position: relative;
  display: flex;
  align-items: stretch;
}
.sl-tile-wrap .sl-plan-tile {
  flex: 1;
  border-radius: 14px 0 0 14px;
  border-right: none;
}
.sl-tile-del {
  flex-shrink: 0;
  width: 42px;
  border: 1.5px solid rgba(20,59,50,.1);
  border-left: none;
  border-radius: 0 14px 14px 0;
  background: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #b0c4bc;
  cursor: pointer;
  transition: background .13s, color .13s;
  padding: 0;
}
.sl-tile-del:hover { background: #fee2e2; color: #dc2626; }

/* ── SL Add button (in filterbar) ─────── */
.sl-add-btn {
  flex-shrink: 0;
  width: 36px; height: 36px; border-radius: 50%;
  background: #0c3f35; color: #d1f843;
  display: flex; align-items: center; justify-content: center;
  font-size: 1.4rem; font-weight: 700; line-height: 1;
  border: none; cursor: pointer;
  transition: background .13s, transform .1s;
  box-shadow: 0 2px 8px rgba(12, 63, 53,.2);
}
.sl-add-btn:hover  { background: #004030; }
.sl-add-btn:active { transform: scale(.94); }

/* ── SL Add sheet modal ────────────────── */
.sl-add-sheet { position: fixed; inset: 0; z-index: 200; display: flex; align-items: flex-end; }
.sl-add-sheet.hidden { display: none; }
.sl-add-backdrop {
  position: absolute; inset: 0;
  background: rgba(14,30,24,.55);
  backdrop-filter: blur(3px);
}
.sl-add-panel {
  position: relative; width: 100%; max-width: 600px; margin: 0 auto;
  background: #fff; border-radius: 28px 28px 0 0;
  padding: 20px 20px calc(24px + env(safe-area-inset-bottom));
  max-height: 90vh; overflow-y: auto;
  animation: slSheetIn .22s cubic-bezier(.32,1,.54,1);
}
@keyframes slSheetIn { from { transform: translateY(100%); } to { transform: translateY(0); } }
.sl-add-header {
  display: flex; align-items: center; justify-content: space-between; margin-bottom: 18px;
}
.sl-add-title { font-size: 1rem; font-weight: 800; color: #0e1e18; }
.sl-add-close {
  width: 32px; height: 32px; border-radius: 50%;
  background: rgba(20,59,50,.08); color: #0e1e18;
  display: flex; align-items: center; justify-content: center;
  border: none; cursor: pointer; transition: background .13s;
}
.sl-add-close:hover { background: rgba(20,59,50,.15); }
.sl-add-field { display: flex; flex-direction: column; gap: 5px; margin-bottom: 12px; }
.sl-add-field label {
  font-size: .72rem; font-weight: 700; color: #5a7a70;
  text-transform: uppercase; letter-spacing: .04em;
}
.sl-add-field input {
  font-family: inherit; font-size: .9rem; font-weight: 500; color: #0e1e18;
  border: 1.5px solid rgba(20,59,50,.15); border-radius: 12px;
  background: #f5f7f4; padding: 10px 14px; width: 100%;
  transition: border-color .13s;
}
.sl-add-field input:focus { outline: none; border-color: #0c3f35; }
.sl-add-row { display: flex; gap: 10px; }
.sl-add-row .sl-add-field { flex: 1; }
.sl-add-nutr-section {
  border-top: 1.5px solid rgba(20,59,50,.08);
  margin: 4px 0 14px; padding-top: 14px;
}
.sl-add-nutr-label {
  font-size: .72rem; font-weight: 700; color: #7a9088;
  text-transform: uppercase; letter-spacing: .05em; margin-bottom: 12px;
}
.sl-add-nutr-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 8px 10px; }
.sl-add-confirm {
  width: 100%; padding: 14px; border-radius: 14px;
  background: #0e1e18; color: #d1f843;
  font-family: inherit; font-size: .9rem; font-weight: 800;
  border: none; cursor: pointer; margin-top: 6px;
  transition: background .13s, transform .1s;
}
.sl-add-confirm:hover  { background: #0c3f35; }
.sl-add-confirm:active { transform: scale(.98); }

/* ── SL Manual items ───────────────────── */
.sl-item-content { flex: 1; min-width: 0; }
.sl-item-row { display: flex; align-items: center; gap: 8px; }
.sl-item-row .sl-item-name { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.sl-nutr-chips { display: flex; flex-wrap: wrap; gap: 4px; margin-top: 5px; }
.sl-nutr-chip {
  font-size: .6rem; font-weight: 700; border-radius: 20px; padding: 2px 7px; white-space: nowrap;
}
.sl-nc-kcal { background: rgba(14,30,24,.08); color: #2f4a40; }
.sl-nc-p    { background: rgba(96,196,245,.15); color: #1a7fa0; }
.sl-nc-c    { background: rgba(245,200,66,.18); color: #7a5c00; }
.sl-nc-f    { background: rgba(245,146,76,.15); color: #c4560a; }
.sl-nc-b    { background: rgba(124,184,122,.18); color: #3a7a38; }
.sl-manual-group { margin-top: 22px; }
.sl-manual-group-label {
  font-size: .7rem; font-weight: 800; text-transform: uppercase;
  letter-spacing: .08em; color: #0c3f35; margin-bottom: 8px;
  display: flex; align-items: center; justify-content: space-between;
}
.sl-nutr-summary {
  background: #f5f7f4; border-radius: 14px; padding: 12px 14px 10px;
  margin-top: 12px; display: flex; flex-wrap: wrap; gap: 8px 16px;
}
.sl-nutr-sum-item { display: flex; flex-direction: column; align-items: flex-start; gap: 1px; }
.sl-nutr-sum-label { font-size: .6rem; font-weight: 600; color: #8aab9e; text-transform: uppercase; letter-spacing: .04em; }
.sl-nutr-sum-val   { font-size: .82rem; font-weight: 800; color: #0e1e18; }

/* ── Legacy Phase Banner ─────────────────────────────────── */
.rz-phase-banner {
  border-radius: 28px;
  margin-bottom: 3rem;
  background: linear-gradient(135deg, #0d1a14 0%, #1e3228 100%);
  box-shadow: 0 4px 20px rgba(8,15,13,.18), inset 0 0 0 1px rgba(201,169,110,.14);
  overflow: hidden;
}
.rz-phase-banner-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 16px 18px;
}
.rz-phase-banner-info {
  display: flex;
  flex-direction: column;
  gap: 3px;
  min-width: 0;
}
.rz-phase-banner-eyebrow {
  font-size: 10px;
  font-weight: 700;
  letter-spacing: .12em;
  text-transform: uppercase;
  color: #c9a96e;
}
.rz-phase-banner-title {
  font-size: 15px;
  font-weight: 700;
  color: #f5f0e8;
  line-height: 1.25;
}
.rz-phase-banner-desc {
  font-size: 12px;
  color: rgba(245,240,232,.5);
  line-height: 1.4;
}
.rz-phase-pills {
  display: flex;
  gap: 8px;
  flex-shrink: 0;
  align-items: stretch;
}
.rz-phase-pill {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1px;
  padding: 10px 14px;
  border-radius: 14px;
  border: 2px solid transparent;
  background: rgba(255,255,255,.06);
  color: rgba(245,240,232,.4);
  font-size: 10px;
  font-weight: 600;
  cursor: pointer;
  transition: background .2s, border-color .2s, color .2s, transform .15s, box-shadow .2s;
  line-height: 1.2;
  white-space: nowrap;
  min-width: 72px;
}
.rz-phase-pill-num {
  font-size: 17px;
  font-weight: 900;
  display: block;
  line-height: 1;
  margin-bottom: 3px;
}
.rz-phase-pill-label {
  font-size: 11px;
  font-weight: 700;
  display: block;
}
.rz-phase-pill-sub {
  font-size: 9px;
  font-weight: 500;
  opacity: .7;
  display: block;
  margin-top: 1px;
}

/* Phase 1 – Start (grün/teal) */
.rz-phase-pill--1 {
  border-color: rgba(80,200,130,.18);
  background: rgba(80,200,130,.07);
}
.rz-phase-pill--1:hover:not(:disabled):not(.rz-phase-pill--locked) {
  background: rgba(80,200,130,.15);
  border-color: rgba(80,200,130,.45);
  color: #5ec88a;
}
.rz-phase-pill--1.active {
  background: linear-gradient(135deg, #1e8f52 0%, #27ae60 100%);
  border-color: #2ecc71;
  color: #fff;
  box-shadow: 0 4px 14px rgba(46,204,113,.35);
  transform: translateY(-1px);
}
.rz-phase-pill--1.active .rz-phase-pill-num { color: #d4fce6; }

/* Phase 2 – Transformation (amber) */
.rz-phase-pill--2 {
  border-color: rgba(230,170,60,.18);
  background: rgba(230,170,60,.07);
}
.rz-phase-pill--2:hover:not(:disabled):not(.rz-phase-pill--locked) {
  background: rgba(230,170,60,.15);
  border-color: rgba(230,170,60,.45);
  color: #e6a83c;
}
.rz-phase-pill--2.active {
  background: linear-gradient(135deg, #b07a10 0%, #d4931a 100%);
  border-color: #e6a83c;
  color: #fff;
  box-shadow: 0 4px 14px rgba(214,147,26,.35);
  transform: translateY(-1px);
}
.rz-phase-pill--2.active .rz-phase-pill-num { color: #fdedc6; }

/* Phase 3 – Live in Life (gold) */
.rz-phase-pill--3 {
  border-color: rgba(201,169,110,.22);
  background: rgba(201,169,110,.07);
}
.rz-phase-pill--3:hover:not(:disabled):not(.rz-phase-pill--locked) {
  background: rgba(201,169,110,.15);
  border-color: rgba(201,169,110,.5);
  color: #c9a96e;
}
.rz-phase-pill--3.active {
  background: linear-gradient(135deg, #9a7230 0%, #c9a96e 100%);
  border-color: #e2c98a;
  color: #0d1a14;
  box-shadow: 0 4px 14px rgba(201,169,110,.4);
  transform: translateY(-1px);
}
.rz-phase-pill--3.active .rz-phase-pill-num { color: #0d1a14; }

.rz-phase-pill--locked {
  opacity: .25;
  cursor: not-allowed;
  transform: none !important;
  box-shadow: none !important;
}
@media (max-width: 480px) {
  .rz-phase-banner {
    border-radius: 20px;
  }
  .rz-phase-banner-inner {
    flex-direction: column;
    align-items: flex-start;
    gap: 12px;
  }
  .rz-phase-pills {
    width: 100%;
  }
  .rz-phase-pill {
    flex: 1;
    justify-content: center;
    min-width: 0;
    padding: 10px 8px;
  }
}

/* ── Tracker Widget ─────────────────────── */
.tr-widget {
  display: flex; align-items: center; justify-content: space-between;
  gap: 14px; padding: 14px 16px;
  background: #fff; border-radius: 20px;
  box-shadow: 0 2px 12px rgba(0,0,0,.06);
  text-decoration: none; color: #0e1e18;
  transition: box-shadow .15s, transform .15s;
}
.tr-widget:hover { box-shadow: 0 4px 20px rgba(0,0,0,.1); transform: translateY(-1px); }
.tr-widget-left { display: flex; align-items: center; gap: 12px; }
.tr-widget-icon {
  width: 38px; height: 38px; border-radius: 12px;
  background: #0c3f35; color: #d1f843;
  display: flex; align-items: center; justify-content: center; flex-shrink: 0;
}
.tr-widget-title { font-size: .82rem; font-weight: 700; color: #0e1e18; }
.tr-widget-sub   { font-size: .68rem; color: #8aab9e; font-weight: 500; margin-top: 2px; }
.tr-widget-right { display: flex; flex-direction: column; align-items: flex-end; gap: 5px; flex-shrink: 0; }
.tr-widget-bar-wrap {
  width: 80px; height: 6px; background: rgba(20,59,50,.1); border-radius: 999px; overflow: hidden;
}
.tr-widget-bar { height: 100%; background: #0c3f35; border-radius: 999px; width: 0%; transition: width .4s; }
.tr-widget-kcal { font-size: .75rem; font-weight: 800; color: #0c3f35; }

/* ── Plan Actions ───────────────────────── */
.rz-plan-actions {
  display: flex; align-items: center; justify-content: space-between;
  gap: 10px; padding: 0 0 4px;
}
.rz-plan-sync-badge {
  display: flex; align-items: center; gap: 5px;
  font-size: .68rem; font-weight: 600; color: #0c3f35;
  background: rgba(12, 63, 53,.08); border-radius: 20px;
  padding: 6px 10px; flex-shrink: 0;
}

/* ── Chefkoch-Style Filterbar ─────────────────────────────── */
.rz-filterbar-wrap {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  padding: 16px 16px 12px;
  border-bottom: 1px solid #e0e8e3;
  position: relative;
  align-items: center;
}
.rz-flt {
  position: relative;
}
.rz-flt-btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 8px 14px;
  border: 1.5px solid #c9d8d1;
  border-radius: 20px;
  background: #fff;
  color: #1a2e24;
  font-family: inherit;
  font-size: .82rem;
  font-weight: 600;
  cursor: pointer;
  white-space: nowrap;
  transition: all .15s;
}
.rz-flt-btn:hover {
  border-color: #0c3f35;
  color: #0c3f35;
}
.rz-flt-btn.has-active {
  background: #0c3f35;
  color: #fff;
  border-color: #0c3f35;
}
.rz-flt-btn.open {
  border-color: #0c3f35;
}
.rz-flt-btn svg.chevron {
  transition: transform .2s;
}
.rz-flt-btn.open svg.chevron {
  transform: rotate(180deg);
}
.rz-flt-badge {
  background: #d1f843;
  color: #003d2c;
  font-size: .65rem;
  font-weight: 800;
  border-radius: 999px;
  padding: 1px 6px;
  margin-left: 2px;
}

.rz-flt-panel {
  display: none;
  position: absolute;
  top: calc(100% + 8px);
  left: 0;
  z-index: 300;
  background: #fff;
  border-radius: 16px;
  box-shadow: 0 8px 32px rgba(0,0,0,.15);
  padding: 20px;
  min-width: 240px;
  max-width: 320px;
}
.rz-flt-panel.open {
  display: block;
}
.rz-flt-panel-title {
  font-size: .85rem;
  font-weight: 800;
  color: #0e1e18;
  margin-bottom: 4px;
}
.rz-flt-panel-sub {
  font-size: .75rem;
  color: #5f756d;
  margin-bottom: 14px;
}
.rz-flt-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 16px;
}
/* Kategorie-Panel: nach Chefkoch-Gruppen gegliedert */
.rz-flt-panel--wide {
  min-width: 300px;
  max-width: 420px;
  max-height: 70vh;
  overflow-y: auto;
}
.rz-flt-cat-groups {
  margin-bottom: 12px;
}
.rz-flt-group-label {
  font-size: .7rem;
  font-weight: 800;
  letter-spacing: .04em;
  text-transform: uppercase;
  color: #8a9b93;
  margin: 14px 0 8px;
}
.rz-flt-group-label:first-child { margin-top: 0; }
.rz-flt-chips-sub {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}
.rz-flt-chip {
  padding: 6px 13px;
  border-radius: 999px;
  border: 1.5px solid #c9d8d1;
  background: #fff;
  color: #0e1e18;
  font-family: inherit;
  font-size: .8rem;
  font-weight: 600;
  cursor: pointer;
  transition: all .15s;
}
.rz-flt-chip:hover {
  border-color: #0c3f35;
  color: #0c3f35;
}
.rz-flt-chip.active {
  background: #0c3f35;
  color: #fff;
  border-color: #0c3f35;
}
.rz-flt-reset-btn {
  display: block;
  width: 100%;
  padding: 8px;
  border: none;
  background: none;
  color: #5f756d;
  font-family: inherit;
  font-size: .8rem;
  font-weight: 600;
  cursor: pointer;
  text-align: center;
  border-top: 1px solid #e8efeb;
  padding-top: 12px;
  margin-top: 4px;
  transition: color .15s;
}
.rz-flt-reset-btn:hover { color: #0c3f35; }

/* ── Sortieren-Radios ── */
.rz-flt-radios {
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin-bottom: 16px;
}
.rz-flt-radio {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: .85rem;
  font-weight: 500;
  color: #1a2e24;
  cursor: pointer;
}
.rz-flt-radio input[type=radio] {
  accent-color: #0c3f35;
  width: 16px; height: 16px;
}

/* ── Zubereitungszeit Track ── */
.rz-time-track-wrap {
  padding: 8px 0 4px;
  margin-bottom: 12px;
}
.rz-time-track {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 32px;
  margin-bottom: 8px;
}
.rz-time-bg-line {
  position: absolute;
  left: 0; right: 0;
  height: 3px;
  background: #e0e8e3;
  border-radius: 2px;
  top: 50%;
  transform: translateY(-50%);
  z-index: 0;
}
.rz-time-active-line {
  position: absolute;
  left: 0;
  height: 3px;
  background: #0c3f35;
  border-radius: 2px;
  top: 50%;
  transform: translateY(-50%);
  z-index: 1;
  transition: width .2s;
}
.rz-time-dot {
  position: relative;
  z-index: 2;
  width: 18px; height: 18px;
  border-radius: 50%;
  border: 2.5px solid #0c3f35;
  background: #fff;
  cursor: pointer;
  padding: 0;
  transition: all .15s;
}
.rz-time-dot.passed,
.rz-time-dot.active {
  background: #0c3f35;
}
.rz-time-dot.active {
  width: 22px; height: 22px;
  box-shadow: 0 0 0 3px rgba(12, 63, 53,.2);
  background: #fff;
  border-color: #0c3f35;
}
.rz-time-labels {
  display: flex;
  justify-content: space-between;
  font-size: .72rem;
  color: #5f756d;
  font-weight: 600;
}

/* ── Clear all button ── */
.rz-flt-clear-all {
  padding: 7px 14px;
  border: 1.5px solid #e0e8e3;
  border-radius: 20px;
  background: #fff;
  color: #e53e3e;
  font-family: inherit;
  font-size: .78rem;
  font-weight: 700;
  cursor: pointer;
  transition: all .15s;
}
.rz-flt-clear-all:hover {
  background: #fef2f2;
  border-color: #fca5a5;
}

/* ── Filter-Panels auf Mobile (kein Viewport-Overflow) ── */
@media (max-width: 480px) {
  .rz-flt-panel,
  .rz-flt-panel--wide {
    min-width: 0;
    max-width: calc(100vw - 2rem);
    width: calc(100vw - 2rem);
    left: auto;
    right: 0;
  }

  /* Einkaufsliste-Filterleiste: 2×2-Grid statt horizontalem Scroll */
  .sl-filterbar {
    flex-direction: column;
    align-items: stretch;
    gap: 8px;
    padding: 10px 16px 12px;
  }
  .sl-add-btn {
    order: -1;
    align-self: flex-end;
  }
  .sl-filters {
    display: grid;
    grid-template-columns: 1fr 1fr;
    overflow-x: visible;
    gap: 6px;
    flex: none;
    min-width: 0;
  }
  .sl-filter {
    justify-content: center;
    white-space: normal;
  }
}

/* Phase-only group (only visible for legacy users) */
.rz-phase-group-only {
  display: none;
  padding: 8px 16px 0;
}
.rz-phase-group-only.visible {
  display: block;
}

/* ── Plan-Mahlzeit anklickbar → Rezept-Detail/Zubereitung ── */
.rz-plan-card[data-recipe-id],
.rz-week-meal[data-recipe-id] {
  cursor: pointer;
}
.rz-plan-card[data-recipe-id] .rz-plan-card-title,
.rz-week-meal[data-recipe-id] .rz-week-meal-title {
  transition: color 0.15s ease;
}
.rz-plan-card[data-recipe-id]:hover .rz-plan-card-title,
.rz-week-meal[data-recipe-id]:hover .rz-week-meal-title {
  color: #0c3f35;
}

/* ── Mobile: Plan-/Wochen-Aktionsbuttons untereinander statt in einer überlaufenden Zeile ── */
@media (max-width: 767px) {
  .rz-plan-actions {
    flex-direction: column;
    align-items: stretch;
    gap: 8px;
    margin-top: 16px;
  }
  .rz-plan-actions .rz-plan-save-btn { margin-top: 0; }
  .rz-plan-sync-badge { align-self: center; }
}

/* ── Sehr schmal (≤449px): Rezept-Grid bleibt 2-spaltig, aber alles kleiner, damit nichts überläuft ── */
@media (max-width: 449px) {
  .rz-grid-wrap { padding-top: 56px; }
  .rz-grid { gap: 60px 8px; }                    /* Spalten-gap 16→8, Row-gap an kleineres Bild */
  .rz-card { padding: 58px 8px 14px; min-width: 0; }
  .rz-card-img-wrap { width: 100px; height: 100px; top: -50px; border-radius: 22px; }
  .rz-card-add,
  .rz-card-sl,
  .rz-card-fav,
  .rz-card-plan { width: 28px; height: 28px; }
  .rz-card-btns { gap: 3px; }
}
