/* ===== Renkler ve temel ölçüler ===== */
:root {
  --bg: #faf7f2;
  --surface: #ffffff;
  --surface-2: #f3eee6;
  --text: #2b2520;
  --muted: #6f655b;
  --border: #e6ded3;
  --accent: #c8553d;
  --accent-hover: #b0462f;
  --accent-soft: #f6e3dd;
  --green: #3f7d4e;
  --green-soft: #e3f0e5;
  --fav: #d99a00;
  --danger: #b3261e;
  --shadow: 0 1px 2px rgba(43, 37, 32, .06), 0 4px 14px rgba(43, 37, 32, .06);
  --radius: 14px;
  --nav-h: 64px;
  color-scheme: light;
}

@media (prefers-color-scheme: dark) {
  :root {
    --bg: #1b1815;
    --surface: #25211d;
    --surface-2: #2f2a25;
    --text: #f1ebe4;
    --muted: #b1a597;
    --border: #3a342e;
    --accent: #e27458;
    --accent-hover: #ec8a71;
    --accent-soft: #3d2a24;
    --green: #7cc08b;
    --green-soft: #22342a;
    --fav: #f2c14e;
    --danger: #f2867f;
    --shadow: 0 1px 2px rgba(0, 0, 0, .3), 0 4px 14px rgba(0, 0, 0, .25);
    color-scheme: dark;
  }
}

* { box-sizing: border-box; }

body {
  margin: 0;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  background: var(--bg);
  color: var(--text);
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  line-height: 1.55;
  -webkit-text-size-adjust: 100%;
}
body.cook-open { overflow: hidden; }

a { color: inherit; text-decoration: none; }
h1, h2, h3 { line-height: 1.2; }
img { max-width: 100%; display: block; }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }

.container { width: 100%; max-width: 1080px; margin: 0 auto; padding: 20px 16px 64px; }
.container:focus { outline: none; }
.visually-hidden { position: absolute !important; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.skip-link { position: absolute; left: -999px; top: 8px; z-index: 100; background: var(--surface); padding: 8px 14px; border-radius: 8px; }
.skip-link:focus { left: 8px; }

/* ===== Üst bar ===== */
.topbar {
  position: sticky; top: 0; z-index: 20;
  display: flex; align-items: center; justify-content: space-between; gap: 12px;
  padding: 10px max(16px, calc((100% - 1080px) / 2 + 16px));
  padding-top: max(10px, env(safe-area-inset-top));
  background: color-mix(in srgb, var(--bg) 88%, transparent);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--border);
}
.brand { font-weight: 800; font-size: 1.15rem; display: flex; align-items: center; gap: 8px; white-space: nowrap; }
.brand-icon { width: 28px; height: 28px; border-radius: 7px; display: block; }
.topbar-actions { display: flex; gap: 6px; align-items: center; }
.nav-link {
  position: relative; display: inline-flex; align-items: center; gap: 6px;
  padding: 8px 12px; border-radius: 999px; color: var(--muted); font-weight: 600; font-size: .92rem;
}
.nav-link:hover, .nav-link[aria-current="page"] { background: var(--surface-2); color: var(--text); }
.nav-badge {
  display: inline-grid; place-items: center; min-width: 20px; height: 20px; padding: 0 6px;
  border-radius: 999px; background: var(--accent); color: #fff; font-size: .72rem; font-weight: 700;
}

/* ===== Düğmeler ===== */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 6px;
  padding: 9px 16px; min-height: 40px; border-radius: 999px; border: 1px solid var(--border);
  background: var(--surface); color: var(--text);
  font: inherit; font-weight: 600; font-size: .93rem; cursor: pointer; white-space: nowrap;
  transition: background .15s, border-color .15s, transform .05s;
}
.btn:hover { background: var(--surface-2); }
.btn:active { transform: translateY(1px); }
.btn:disabled { opacity: .55; cursor: not-allowed; }
.btn-primary { background: var(--accent); border-color: var(--accent); color: #fff; }
.btn-primary:hover { background: var(--accent-hover); border-color: var(--accent-hover); }
.btn-danger { color: var(--danger); }
.btn-sm { padding: 6px 12px; min-height: 34px; font-size: .85rem; }
.icon-btn { width: 40px; padding: 0; border-radius: 50%; font-size: 1.1rem; line-height: 1; }
.btn-sm.icon-btn { width: 34px; }

[hidden] { display: none !important; }

/* ===== Günün akşam menüsü ===== */
.menu-card { margin: 4px 0 18px; padding: 16px 18px; }
.menu-head { display: flex; justify-content: space-between; align-items: flex-start; gap: 10px; }
.menu-head h2 { margin: 0 0 6px; font-size: 1.2rem; }
.menu-date { margin: 0; color: var(--muted); font-size: .82rem; font-weight: 600; text-transform: capitalize; }
.menu-list { list-style: none; padding: 0; margin: 4px 0 0; display: grid; grid-template-columns: repeat(auto-fit, minmax(230px, 1fr)); column-gap: 18px; }
.menu-list li { border-top: 1px solid var(--border); }
.menu-row { display: flex; align-items: center; gap: 12px; padding: 9px 2px; }
.menu-row:hover b { color: var(--accent); }
.menu-thumb { width: 46px; height: 46px; flex: none; border-radius: 12px; overflow: hidden; background: var(--accent-soft); }
.menu-thumb img { width: 100%; height: 100%; object-fit: cover; }
.menu-thumb .media-emoji { font-size: 1.6rem; }
.menu-text { display: flex; flex-direction: column; min-width: 0; flex: 1; }
.menu-text small { color: var(--muted); font-size: .75rem; font-weight: 700; text-transform: uppercase; letter-spacing: .04em; }
.menu-text b { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.menu-time { color: var(--muted); font-size: .82rem; white-space: nowrap; }
.menu-actions { display: flex; gap: 8px; margin-top: 10px; flex-wrap: wrap; }
.menu-actions .btn { flex: 1 1 140px; }
.menu-note { margin: 10px 0 0; color: var(--muted); font-size: .85rem; }
.link-btn { border: 0; background: none; padding: 0; color: var(--accent); font: inherit; font-weight: 600; cursor: pointer; }
.menu-editor { display: grid; gap: 12px; }
.menu-editor .menu-head h2 { margin: 0; }

/* ===== Kategori listesi (Kategoriler paneli) ===== */
.cat-item {
  display: flex; align-items: center; justify-content: space-between; gap: 8px;
  padding: 10px 12px; min-height: 44px; border: 0; border-radius: 10px; background: transparent;
  color: var(--text); font: inherit; text-align: left; cursor: pointer;
}
.cat-item:hover { background: var(--surface-2); }
.cat-item.active { background: var(--accent-soft); color: var(--accent); font-weight: 700; }
.cat-item.is-zero { color: var(--muted); }
.cat-name { display: flex; align-items: center; gap: 10px; }
.cat-icon { width: 1.4em; text-align: center; }
.cat-count { color: var(--muted); font-size: .85rem; font-variant-numeric: tabular-nums; }
.cat-item.active .cat-count { color: var(--accent); }

/* ===== Arama ve filtreler ===== */
.hero-search { padding: 0 0 14px; }
.hero-search h1 { margin: 0 0 14px; font-size: clamp(1.5rem, 5vw, 2.1rem); letter-spacing: -.02em; }
.search-row { display: flex; gap: 8px; }
.search {
  flex: 1; min-width: 0; padding: 12px 16px 12px 42px; border-radius: 999px;
  border: 1px solid var(--border); background: var(--surface) no-repeat 16px center;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' fill='none' stroke='%237a6f65' stroke-width='2' viewBox='0 0 24 24'%3E%3Ccircle cx='11' cy='11' r='7'/%3E%3Cpath d='m20 20-3.5-3.5'/%3E%3C/svg%3E");
  color: var(--text); font: inherit; font-size: 1rem; box-shadow: var(--shadow);
}
.search:focus { outline: 2px solid var(--accent); outline-offset: 1px; }
.quick-links { display: flex; gap: 8px; flex-wrap: wrap; margin-top: 10px; }
.quick { color: var(--accent); font-weight: 600; font-size: .92rem; }
.quick:hover { text-decoration: underline; }

.chips { display: flex; gap: 8px; overflow-x: auto; padding: 2px 2px 6px; scrollbar-width: none; }
.chips::-webkit-scrollbar { display: none; }
.chips.wrap { flex-wrap: wrap; overflow: visible; }
.chip {
  flex: none; display: inline-flex; align-items: center; gap: 6px;
  padding: 6px 14px; min-height: 34px; border-radius: 999px; border: 1px solid var(--border);
  background: var(--surface); color: var(--muted); font: inherit; font-size: .88rem; cursor: pointer;
}
.chip:hover { color: var(--text); }
.chip.active { background: var(--accent); border-color: var(--accent); color: #fff; }
.chip-x { border: 0; background: transparent; color: inherit; cursor: pointer; padding: 0 0 0 4px; font-size: .8rem; }
.check-chip input { accent-color: var(--accent); margin: 0; }
.check-chip:has(input:checked) { background: var(--accent-soft); border-color: var(--accent); color: var(--text); }

.filter-grid { display: grid; gap: 14px; padding: 4px 16px 16px; }
.filter-group { display: grid; gap: 6px; }
.filter-label { font-size: .8rem; font-weight: 700; color: var(--muted); text-transform: uppercase; letter-spacing: .04em; }
.filter-row { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.filter-row select { width: auto; }

.section-head { display: flex; align-items: baseline; justify-content: space-between; margin: 0 0 12px; }
.section-head h2 { margin: 0; font-size: 1.15rem; }
.count { color: var(--muted); font-size: .9rem; }

/* Fotoğrafı olmayan tarifin simgesi (menü kartı, tarif sayfası, Dolabım) */
.media-emoji { display: grid; place-items: center; width: 100%; height: 100%; font-size: 4rem; }

/* ===== Tarif listesi (emojisiz satırlar) ===== */
.recipe-list {
  list-style: none; margin: 0; padding: 0 16px;
  background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); box-shadow: var(--shadow);
  display: grid; grid-template-columns: minmax(0, 1fr); column-gap: 28px;
}
.recipe-list.is-empty { display: block; }
.recipe-row { display: flex; align-items: center; gap: 8px; min-width: 0; border-top: 1px solid var(--border); }
.recipe-row:first-child { border-top: 0; }
@media (min-width: 760px) {
  .recipe-list { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); }
  .recipe-row:nth-child(2) { border-top: 0; }
}
.recipe-link { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 3px; padding: 14px 0; }
.recipe-title { font-weight: 700; font-size: 1.02rem; line-height: 1.3; }
.recipe-link:hover .recipe-title { color: var(--accent); }
.recipe-desc { color: var(--muted); font-size: .88rem; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.recipe-meta { display: flex; flex-wrap: wrap; align-items: center; gap: 4px 6px; color: var(--muted); font-size: .8rem; margin-top: 3px; }
.recipe-meta .sep { opacity: .6; }
.recipe-meta .badge { margin-left: 4px; }
.fav-star {
  flex: none; width: 40px; height: 40px; display: grid; place-items: center; border: 0; border-radius: 50%;
  background: transparent; color: var(--muted); font-size: 1.25rem; cursor: pointer;
}
.fav-star:hover { background: var(--surface-2); color: var(--text); }
.fav-star.on { color: var(--fav); }
.badge {
  align-self: flex-start; font-size: .74rem; font-weight: 700; padding: 2px 10px; border-radius: 999px;
  background: var(--surface-2); color: var(--muted);
}
.badge-diet { background: var(--green-soft); color: var(--green); }

.empty { text-align: center; color: var(--muted); padding: 48px 16px; }
.empty .big { font-size: 3rem; }
.spinner { width: 36px; height: 36px; margin: 0 auto 10px; border-radius: 50%; border: 3px solid var(--accent-soft); border-top-color: var(--accent); animation: spin .9s linear infinite; }
.photo-none { display: grid; place-items: center; width: 100%; height: 100%; color: var(--muted); font-size: .8rem; text-align: center; }
.detail-hero.no-media { grid-template-columns: 1fr; }
.match.no-media { grid-template-columns: 1fr auto; padding-left: 14px; }

/* ===== Tarif sayfası ===== */
.back { display: inline-flex; gap: 6px; color: var(--muted); margin-bottom: 14px; font-weight: 600; }
.back:hover { color: var(--text); }
.back-row { display: flex; flex-wrap: wrap; align-items: baseline; gap: 4px 8px; margin-bottom: 14px; }
.back-row .back { margin-bottom: 0; }
.back-sep { color: var(--muted); }
.detail-hero {
  display: grid; grid-template-columns: 120px 1fr; gap: 22px; align-items: center;
  background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius);
  padding: 20px; box-shadow: var(--shadow); margin-bottom: 14px;
}
.detail-hero.has-image { grid-template-columns: minmax(0, 1.05fr) minmax(0, 1fr); align-items: start; padding: 0; overflow: hidden; }
.detail-hero.has-image .detail-info { padding: 22px 22px 22px 0; }
.detail-media { aspect-ratio: 1; border-radius: 50%; background: var(--accent-soft); overflow: hidden; }
.detail-media .media-emoji { font-size: 4.2rem; }
.has-image .detail-media { aspect-ratio: 4 / 3; border-radius: 0; height: 100%; }
.detail-img { width: 100%; height: 100%; object-fit: cover; }
.detail-info h1 { margin: 6px 0 6px; font-size: clamp(1.6rem, 4.5vw, 2.2rem); letter-spacing: -.02em; }
.lead { margin: 0 0 12px; color: var(--muted); font-size: 1.05rem; }
.facts { display: flex; flex-wrap: wrap; gap: 8px; margin: 0 0 12px; }
.facts div { background: var(--surface-2); border-radius: 10px; padding: 6px 12px; }
.facts dt { font-size: .72rem; font-weight: 700; color: var(--muted); text-transform: uppercase; letter-spacing: .04em; }
.facts dd { margin: 0; font-weight: 700; font-size: .95rem; }
.tag-row { display: flex; gap: 6px; flex-wrap: wrap; margin-bottom: 14px; }
.detail-actions { display: flex; gap: 8px; flex-wrap: wrap; }

.cooked-bar {
  display: flex; align-items: center; justify-content: space-between; gap: 10px; flex-wrap: wrap;
  padding: 10px 16px; margin-bottom: 18px; border-radius: var(--radius);
  background: var(--green-soft); color: var(--text); font-size: .92rem;
}

.detail-cols { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.45fr); gap: 18px; align-items: start; }
.panel {
  background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius);
  padding: 20px; box-shadow: var(--shadow);
}
.panel h2 { margin: 0 0 14px; font-size: 1.15rem; }
.panel-head { display: flex; justify-content: space-between; align-items: center; gap: 8px; margin-bottom: 12px; flex-wrap: wrap; }
.panel-head h2 { margin: 0; }
#malzemeler { position: sticky; top: 76px; }

.stepper { display: inline-flex; align-items: center; gap: 4px; border: 1px solid var(--border); border-radius: 999px; padding: 3px; }
.stepper button { width: 32px; height: 32px; border-radius: 50%; border: 0; background: var(--surface-2); color: var(--text); font-size: 1.05rem; cursor: pointer; }
.stepper span { min-width: 72px; text-align: center; font-size: .88rem; font-weight: 700; }

.segmented { display: inline-flex; padding: 3px; border-radius: 999px; background: var(--surface-2); margin-bottom: 10px; }
.segmented button {
  border: 0; background: transparent; color: var(--muted); font: inherit; font-size: .85rem; font-weight: 600;
  padding: 6px 14px; border-radius: 999px; cursor: pointer;
}
.segmented button[aria-pressed="true"] { background: var(--surface); color: var(--text); box-shadow: var(--shadow); }

.ingredients { list-style: none; padding: 0; margin: 0; }
.ingredients li { padding: 8px 0; border-bottom: 1px dashed var(--border); }
.ingredients li:last-child { border-bottom: 0; }
.ingredients label { display: flex; gap: 10px; cursor: pointer; align-items: flex-start; }
.ingredients input { accent-color: var(--accent); margin-top: 5px; width: 18px; height: 18px; flex: none; }
.ingredients input:checked + span { text-decoration: line-through; color: var(--muted); }
.ing-section {
  font-weight: 800; font-size: .8rem; text-transform: uppercase; letter-spacing: .05em; color: var(--accent);
  padding-top: 14px !important; border-bottom: 0 !important;
}
.ing-section:first-child { padding-top: 0 !important; }
.qty { font-weight: 700; }
.alt { color: var(--muted); font-size: .8rem; }
.hint-line { color: var(--muted); font-size: .82rem; margin: 12px 0 0; }
.hint-line a { color: var(--accent); font-weight: 600; }

.steps { list-style: none; counter-reset: step; padding: 0; margin: 0; }
.steps li { counter-increment: step; position: relative; padding: 2px 0 18px 46px; cursor: pointer; scroll-margin-top: 90px; }
.steps li::before {
  content: counter(step); position: absolute; left: 0; top: -1px;
  width: 32px; height: 32px; border-radius: 50%; display: grid; place-items: center;
  background: var(--accent-soft); color: var(--accent); font-weight: 800; font-size: .9rem;
}
.steps li.done { color: var(--muted); }
.steps li.done::before { content: "✓"; background: var(--accent); color: #fff; }
.steps li:target { background: var(--accent-soft); border-radius: 10px; }

.timer-chip {
  display: inline-flex; align-items: center; gap: 2px; padding: 1px 9px; margin: 0 1px;
  border: 1px solid var(--accent); border-radius: 999px; background: var(--accent-soft); color: var(--accent);
  font: inherit; font-weight: 700; font-size: .92em; cursor: pointer; vertical-align: baseline;
}
.timer-chip:hover { background: var(--accent); color: #fff; }

.extras { display: grid; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); gap: 18px; margin-top: 18px; }
.extras:empty { display: none; }
.extra p { margin: 0 0 8px; }
.extra p:last-child { margin: 0; }
.notes { margin-top: 18px; }
.notes textarea { min-height: 80px; }
.similar { margin-top: 32px; }
.similar .recipe-list { margin-top: 4px; }
.similar h2 { font-size: 1.15rem; }

/* ===== Form ===== */
.form { display: flex; flex-direction: column; gap: 18px; }
.form h1 { margin: 0; }
.form.narrow { max-width: 420px; margin: 0 auto; width: 100%; }
.field { display: flex; flex-direction: column; gap: 6px; border: 0; padding: 0; margin: 0; min-width: 0; }
.field label, .field .label { font-weight: 700; font-size: .9rem; padding: 0; }
.field .hint, .hint { color: var(--muted); font-size: .8rem; font-weight: 400; }
.row { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 14px; }
input[type="text"], input[type="number"], input[type="email"], input[type="password"], input[type="search"]:not(.search), select, textarea {
  width: 100%; padding: 10px 12px; border-radius: 10px; border: 1px solid var(--border);
  background: var(--surface); color: var(--text); font: inherit; font-size: 1rem;
}
input:focus, select:focus, textarea:focus { outline: 2px solid var(--accent); outline-offset: 1px; }
textarea { resize: vertical; min-height: 110px; }

.photo-field { display: flex; gap: 14px; align-items: center; flex-wrap: wrap; }
.photo-preview {
  width: 160px; aspect-ratio: 16 / 10; border-radius: 12px; overflow: hidden;
  background: var(--accent-soft); border: 1px solid var(--border);
}
.photo-preview img { width: 100%; height: 100%; object-fit: cover; }
.photo-preview.loading { opacity: .5; animation: pulse 1s ease-in-out infinite; }
.photo-preview .media-emoji { font-size: 2.6rem; }
.photo-actions { display: flex; gap: 8px; flex-wrap: wrap; }

.emoji-picker { display: flex; flex-wrap: wrap; gap: 6px; }
.emoji-picker button {
  width: 44px; height: 44px; font-size: 1.4rem; border-radius: 10px; cursor: pointer;
  border: 1px solid var(--border); background: var(--surface);
}
.emoji-picker button.active { border-color: var(--accent); background: var(--accent-soft); }

.ing-preview { display: flex; flex-wrap: wrap; gap: 6px; align-items: center; }
.pill { padding: 2px 10px; border-radius: 999px; background: var(--surface-2); font-size: .8rem; }
.pill-section { background: var(--accent-soft); color: var(--accent); font-weight: 700; }

.form-actions { display: flex; gap: 10px; justify-content: flex-end; flex-wrap: wrap; align-items: center; }
.form-actions.wrap-left { justify-content: flex-start; margin-top: 16px; }
.spacer { flex: 1; }
.error { color: var(--danger); font-size: .92rem; margin: 0; font-weight: 600; }
.notice { margin: 0; padding: 10px 14px; border-radius: 10px; background: var(--accent-soft); color: var(--text); font-size: .92rem; }
code { background: var(--surface-2); padding: 1px 6px; border-radius: 6px; font-size: .9em; }

/* ===== Alışveriş listesi ve dolap ===== */
.page-panel h1 { margin: 0 0 8px; font-size: clamp(1.4rem, 4vw, 1.8rem); }
.page-panel h2 { margin: 24px 0 8px; }
.add-row { display: flex; gap: 8px; margin: 14px 0; }
.add-row input { flex: 1; min-width: 0; }
.shop-list { list-style: none; padding: 0; margin: 0; }
.shop-list li { display: flex; align-items: center; gap: 8px; padding: 8px 0; border-bottom: 1px dashed var(--border); }
.shop-list label { display: flex; gap: 12px; align-items: flex-start; flex: 1; cursor: pointer; min-width: 0; }
.shop-list input { accent-color: var(--accent); width: 20px; height: 20px; margin-top: 3px; flex: none; }
.shop-list label > span { display: flex; flex-direction: column; min-width: 0; }
.shop-src { color: var(--muted); font-size: .78rem; }
.shop-list li.checked .shop-name { text-decoration: line-through; color: var(--muted); }

.pantry-chips { margin: 4px 0 10px; }
.check-line { display: flex; gap: 10px; align-items: flex-start; font-size: .9rem; color: var(--muted); cursor: pointer; }
.check-line input { accent-color: var(--accent); margin-top: 4px; }
.page-panel + .section-head { margin-top: 24px; }
.match-list { display: grid; gap: 12px; }
.match {
  display: grid; grid-template-columns: 72px 1fr auto; gap: 14px; align-items: center;
  background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); padding: 10px 14px 10px 10px;
}
.match-media { width: 72px; height: 72px; border-radius: 12px; overflow: hidden; background: var(--accent-soft); }
.match-media img { width: 100%; height: 100%; object-fit: cover; }
.match-media .media-emoji { font-size: 2.2rem; }
.match-title { font-weight: 700; }
.match-title:hover { color: var(--accent); }
.match-bar { height: 6px; border-radius: 999px; background: var(--surface-2); overflow: hidden; margin: 6px 0; }
.match-bar span { display: block; height: 100%; background: var(--green); border-radius: inherit; }
.match-text { margin: 0; font-size: .85rem; color: var(--muted); }

.table-wrap { overflow-x: auto; }
table { width: 100%; border-collapse: collapse; font-size: .95rem; }
th, td { text-align: left; padding: 8px 10px; border-bottom: 1px solid var(--border); white-space: nowrap; }
th { font-size: .78rem; text-transform: uppercase; letter-spacing: .04em; color: var(--muted); }

/* ===== Zamanlayıcılar ===== */
.timers {
  position: fixed; right: 16px; bottom: max(16px, env(safe-area-inset-bottom)); z-index: 60;
  display: flex; flex-direction: column; gap: 8px; width: min(340px, calc(100vw - 32px));
}
.timer {
  display: flex; align-items: center; gap: 10px; padding: 10px 12px;
  background: var(--surface); border: 1px solid var(--border); border-radius: 14px;
  box-shadow: 0 8px 28px rgba(0, 0, 0, .18);
}
.timer-info { flex: 1; min-width: 0; display: grid; gap: 2px; }
.timer-label { font-size: .75rem; color: var(--muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.timer-left { font-size: 1.35rem; font-weight: 800; font-variant-numeric: tabular-nums; }
.timer-bar { height: 4px; background: var(--surface-2); border-radius: 999px; overflow: hidden; }
.timer-bar span { display: block; height: 100%; background: var(--accent); }
.timer-actions { display: flex; gap: 4px; }
.timer.paused .timer-left { color: var(--muted); }
.timer.done { border-color: var(--accent); background: var(--accent-soft); animation: pulse 1s ease-in-out infinite; }
.timer.done .timer-left { color: var(--accent); font-size: 1.1rem; }
@keyframes pulse { 50% { transform: scale(1.02); } }

/* ===== Pişirme modu ===== */
.cook {
  --cook-scale: 1;
  position: fixed; inset: 0; z-index: 50; display: flex; flex-direction: column;
  background: var(--bg); color: var(--text);
  padding-top: env(safe-area-inset-top); padding-bottom: env(safe-area-inset-bottom);
}
.cook-head { display: flex; align-items: center; gap: 12px; padding: 10px 16px; border-bottom: 1px solid var(--border); flex-wrap: wrap; }
.cook-title { display: flex; flex-direction: column; min-width: 0; flex: 1; }
.cook-title strong { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.cook-title span { color: var(--muted); font-size: .85rem; }
.cook-tools { display: flex; gap: 6px; flex-wrap: wrap; }
.cook-tools [aria-pressed="true"], .cook-tools [aria-expanded="true"] { background: var(--accent-soft); border-color: var(--accent); }
.cook-progress { height: 5px; background: var(--surface-2); }
.cook-progress span { display: block; height: 100%; background: var(--accent); transition: width .25s; }
.cook-main { flex: 1; display: flex; min-height: 0; }
.cook-body { flex: 1; overflow-y: auto; padding: clamp(20px, 5vw, 56px); max-width: 900px; margin: 0 auto; width: 100%; }
.cook-step-num { margin: 0 0 8px; color: var(--accent); font-weight: 800; text-transform: uppercase; letter-spacing: .06em; font-size: .9rem; }
.cook-step { margin: 0 0 28px; font-size: calc(clamp(1.35rem, 3.6vw, 2.1rem) * var(--cook-scale)); line-height: 1.45; font-weight: 500; }
.cook-uses { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); padding: 14px 18px; }
.cook-uses h3, .cook-ings h3 { margin: 0 0 8px; font-size: .8rem; text-transform: uppercase; letter-spacing: .05em; color: var(--muted); }
.cook-uses ul { margin: 0; padding-left: 18px; font-size: calc(1.1rem * var(--cook-scale)); }
.cook-uses li { margin: 4px 0; }
.cook-ings {
  width: min(340px, 85vw); overflow-y: auto; padding: 18px; border-left: 1px solid var(--border); background: var(--surface);
}
.cook-ings ul { list-style: none; padding: 0; margin: 0; }
.cook-ings li { padding: 6px 0; border-bottom: 1px dashed var(--border); }
.cook-ings label { display: flex; gap: 10px; cursor: pointer; }
.cook-ings input { accent-color: var(--accent); width: 18px; height: 18px; flex: none; margin-top: 3px; }
.cook-ings input:checked + span { text-decoration: line-through; color: var(--muted); }
.cook-foot { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 12px 16px; border-top: 1px solid var(--border); }
.cook-foot .btn { min-height: 52px; padding: 0 26px; font-size: 1.05rem; }
.cook-wake { color: var(--muted); font-size: .82rem; text-align: center; }

/* ===== Diğer ===== */

.toast {
  position: fixed; left: 50%; bottom: 24px; z-index: 70; transform: translateX(-50%) translateY(20px);
  background: var(--text); color: var(--bg); padding: 10px 18px; border-radius: 999px; max-width: calc(100vw - 32px);
  font-weight: 600; font-size: .9rem; opacity: 0; transition: opacity .2s, transform .2s; pointer-events: none;
}
.toast.show { opacity: 1; transform: translateX(-50%) translateY(0); }
.spin { display: inline-block; animation: spin 1.2s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }

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



/* ===== Önceki akşamlar ve bir akşamın menü sayfası ===== */
.past-menus { margin-top: 22px; }
.past-menus h2 { margin: 0 0 10px; font-size: 1.1rem; }
.row-chev { flex: none; width: 28px; text-align: center; color: var(--muted); font-size: 1.5rem; line-height: 1; }
.recipe-row:hover .row-chev { color: var(--accent); }
.menu-head h1 { margin: 0 0 6px; font-size: 1.35rem; }
.day-nav { display: flex; justify-content: space-between; gap: 10px; margin-top: 14px; }
.day-nav .btn { flex: 0 1 auto; }

/* ===== ⋯ menüsü (sağ üst) ===== */
.more { position: relative; }
.more-btn { font-size: 1.3rem; letter-spacing: 1px; }
.more-btn[aria-expanded="true"] { background: var(--surface-2); border-color: var(--accent); }
.more-menu {
  position: absolute; right: 0; top: calc(100% + 8px); z-index: 45; min-width: 230px; max-width: calc(100vw - 32px);
  display: flex; flex-direction: column; padding: 6px; border-radius: 14px;
  background: var(--surface); border: 1px solid var(--border); box-shadow: 0 10px 30px rgba(0, 0, 0, .25);
}
.more-menu a, .more-menu button {
  display: flex; align-items: center; gap: 10px; padding: 11px 12px; min-height: 44px; border: 0; border-radius: 10px;
  background: transparent; color: var(--text); font: inherit; font-weight: 600; font-size: .95rem; text-align: left; cursor: pointer;
}
.more-menu a:hover, .more-menu button:hover { background: var(--surface-2); }
.more-user { padding: 8px 12px 2px; color: var(--text); font-weight: 600; font-size: .85rem; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; border-top: 1px solid var(--border); margin-top: 4px; }
.more-user small { display: block; color: var(--muted); font-weight: 400; font-size: .78rem; overflow: hidden; text-overflow: ellipsis; }

/* ===== Üyelik: giriş, Sayfam, tarif durumu ===== */
.login { display: grid; gap: 14px; }
.login h1 { margin: 0; }
.login-lead { margin: 0; color: var(--muted); line-height: 1.5; }
.login .hint-line { margin: 0; }
.btn-google {
  display: flex; align-items: center; justify-content: center; gap: 10px; width: 100%; min-height: 50px;
  background: #fff; color: #1f1f1f; border: 1px solid #c7c7c7; font-weight: 600; font-size: 1rem;
}
.btn-google:hover { background: #f6f6f6; border-color: #a8a8a8; }
.btn-google:disabled { opacity: .7; }
.email-login { border-top: 1px solid var(--border); padding-top: 12px; }
.email-login summary { cursor: pointer; color: var(--muted); font-size: .9rem; font-weight: 600; }
.email-login form { display: grid; gap: 12px; margin-top: 10px; }

.status-box {
  display: grid; gap: 8px; justify-items: start; margin: 0 0 16px; padding: 12px 16px;
  border: 1px solid var(--border); border-radius: var(--radius); background: var(--surface-2);
}
.status-box p { margin: 0; font-size: .92rem; }
.status-actions { display: flex; gap: 8px; flex-wrap: wrap; }
.status-pill { display: inline-block; padding: 2px 10px; border-radius: 999px; font-size: .75rem; font-weight: 700; white-space: nowrap; }
.st-wait { background: #fdf0d2; color: #7a5300; }
.st-live { background: var(--green-soft); color: var(--green); }
.st-no { background: var(--surface-2); color: var(--muted); border: 1px solid var(--border); }
@media (prefers-color-scheme: dark) { .st-wait { background: #3d3115; color: #f2c14e; } }
.byline { margin: -4px 0 12px; color: var(--muted); font-size: .9rem; }
.byline b { color: var(--text); }

.account-head { display: flex; align-items: center; gap: 14px; margin: 4px 0 6px; }
.account-head h1 { margin: 0; font-size: 1.4rem; }
.account-head .hint-line { margin: 2px 0 0; overflow-wrap: anywhere; }
.avatar {
  flex: 0 0 auto; width: 52px; height: 52px; border-radius: 50%; display: grid; place-items: center;
  background: var(--accent-soft); color: var(--accent); font-weight: 800; font-size: 1.4rem;
}
.sync-line { margin: 0 0 16px; }
.account-section { margin-bottom: 14px; }
.section-head { display: flex; align-items: center; justify-content: space-between; gap: 10px; flex-wrap: wrap; margin-bottom: 4px; }
.section-head h2 { margin: 0; font-size: 1.1rem; }
.account-section > .hint-line { margin-top: 6px; }
.account-section > .btn { margin-top: 10px; }
.account-section .recipe-list { margin-top: 8px; }
.plain-list { list-style: none; margin: 6px 0 0; padding: 0; }
.plain-list > li { border-top: 1px solid var(--border); }
.plain-list > li:first-child { border-top: 0; }
.plain-list a { display: grid; gap: 2px; padding: 10px 0; color: inherit; text-decoration: none; min-width: 0; }
.plain-list a:hover .plain-title { color: var(--accent); }
.plain-title { font-weight: 600; }
.plain-sub { color: var(--muted); font-size: .85rem; display: flex; align-items: center; gap: 6px; flex-wrap: wrap; min-width: 0; }
.note-text { display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; white-space: pre-line; }
.review-list > li { display: grid; gap: 4px; padding-bottom: 10px; }
.review-list a { padding-bottom: 0; }
.review-actions { display: flex; gap: 8px; flex-wrap: wrap; }
.account-foot { display: flex; justify-content: center; gap: 10px; flex-wrap: wrap; margin: 22px 0 8px; }
.more-menu .more-family { color: var(--muted); font-weight: 500; font-size: .78rem; min-height: 0; padding: 10px 12px 8px; border-top: 1px solid var(--border); border-radius: 0 0 10px 10px; margin-top: 4px; }

/* ===== Alttaki sabit menü ===== */
body { padding-bottom: calc(var(--nav-h) + env(safe-area-inset-bottom)); }
.bottom-nav {
  position: fixed; left: 50%; bottom: 0; transform: translateX(-50%); z-index: 40;
  width: min(640px, 100%); display: grid; grid-template-columns: repeat(5, 1fr);
  padding: 6px 4px calc(6px + env(safe-area-inset-bottom));
  background: color-mix(in srgb, var(--surface) 94%, transparent);
  -webkit-backdrop-filter: blur(12px); backdrop-filter: blur(12px);
  border-top: 1px solid var(--border);
}
@media (min-width: 680px) { .bottom-nav { border: 1px solid var(--border); border-bottom: 0; border-radius: 18px 18px 0 0; } }
.tab {
  position: relative; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 2px;
  min-height: 50px; padding: 4px 2px; border: 0; border-radius: 12px; background: transparent;
  color: var(--muted); font: inherit; font-size: .72rem; font-weight: 600; cursor: pointer; text-decoration: none;
}
.tab:hover { color: var(--text); }
.tab.on { color: var(--accent); }
.tab.on .tab-icon { background: var(--accent-soft); }
.tab-icon { display: grid; place-items: center; line-height: 1; padding: 3px 12px; border-radius: 999px; }
.tab-icon svg { display: block; }
.tab-center .tab-icon svg { width: 26px; height: 26px; }
.tab-label { white-space: nowrap; }
.tab-badge {
  position: absolute; top: 2px; left: calc(50% + 8px); min-width: 18px; height: 18px; padding: 0 5px;
  display: grid; place-items: center; border-radius: 999px; background: var(--accent); color: #fff; font-size: .68rem; font-weight: 700;
}
/* Ortadaki büyük Kategoriler düğmesi */
.tab-center .tab-icon {
  display: grid; place-items: center; width: 54px; height: 54px; padding: 0; margin-top: -26px;
  border-radius: 50%; font-size: 1.5rem; background: var(--accent); color: #fff;
  border: 4px solid var(--bg); box-shadow: 0 4px 14px rgba(0, 0, 0, .25);
}
.tab-center.on .tab-icon, .tab-center:hover .tab-icon { background: var(--accent-hover); }
.tab-center .tab-label { color: var(--text); }
.tab-center.on .tab-label { color: var(--accent); }
body.cook-open .bottom-nav { display: none; }

/* Aşağı çekip yenileme göstergesi (yalnızca ana ekrandan açıldığında) */
.ptr {
  position: fixed; top: calc(env(safe-area-inset-top) + 8px); left: 50%; z-index: 30;
  display: none; align-items: center; gap: 8px; padding: 8px 14px 8px 10px; border-radius: 999px;
  background: var(--surface); border: 1px solid var(--border); box-shadow: var(--shadow);
  color: var(--muted); font-size: .82rem; font-weight: 600; pointer-events: none;
  transform: translate(-50%, -56px); opacity: 0;
}
.ptr.on { display: flex; }
.ptr-icon { display: grid; place-items: center; width: 26px; height: 26px; border-radius: 50%; font-size: 1.1rem; color: var(--accent); }
.ptr.ready { color: var(--accent); }
.ptr.ready .ptr-icon { background: var(--accent-soft); }
.ptr.refreshing .ptr-icon { animation: spin .8s linear infinite; }
@media (display-mode: standalone) { html, body { overscroll-behavior-y: contain; } }
.timers { bottom: calc(var(--nav-h) + 12px + env(safe-area-inset-bottom)); }
.toast { bottom: calc(var(--nav-h) + 16px + env(safe-area-inset-bottom)); }

/* ===== Alttan açılan paneller ===== */
body.sheet-open { overflow: hidden; }
.sheet-backdrop {
  position: fixed; inset: 0; z-index: 55; display: flex; align-items: flex-end; justify-content: center;
  background: rgba(0, 0, 0, .45); animation: fade-in .15s ease-out;
}
.sheet {
  width: min(640px, 100%); max-height: 85vh; display: flex; flex-direction: column;
  background: var(--surface); color: var(--text); border-radius: 20px 20px 0 0;
  padding: 6px 16px calc(14px + env(safe-area-inset-bottom)); box-shadow: 0 -8px 30px rgba(0, 0, 0, .25);
  animation: sheet-up .2s ease-out;
}
.sheet-grip { width: 40px; height: 4px; border-radius: 999px; background: var(--border); margin: 4px auto 8px; flex: none; }
.sheet-head { display: flex; align-items: center; justify-content: space-between; flex: none; }
.sheet-head h2 { margin: 0; font-size: 1.15rem; }
.sheet-body { overflow-y: auto; padding: 10px 0 4px; overscroll-behavior: contain; }
.sheet-search { display: flex; gap: 8px; margin-bottom: 10px; }
.sheet-search input { flex: 1; min-width: 0; }
.cat-list { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 2px; }
.sheet-actions { display: flex; gap: 8px; flex-wrap: wrap; margin-top: 16px; position: sticky; bottom: 0; background: var(--surface); padding-top: 8px; }
.sheet-actions [data-apply] { flex: 1 1 160px; }
@keyframes sheet-up { from { transform: translateY(40px); opacity: .4; } }
@keyframes fade-in { from { opacity: 0; } }

/* ===== Tarifler sayfası ===== */
.page-head { display: flex; align-items: baseline; justify-content: space-between; gap: 12px; margin: 4px 0 10px; }
.page-head h1 { margin: 0; font-size: clamp(1.4rem, 5vw, 1.9rem); letter-spacing: -.02em; }
.pill-row { display: flex; gap: 8px; flex-wrap: wrap; margin: 0 0 16px; }
.pill-x {
  display: inline-flex; align-items: center; gap: 6px; padding: 6px 12px; min-height: 34px; border-radius: 999px;
  border: 1px solid var(--border); background: var(--surface); color: var(--text); font: inherit; font-size: .85rem; cursor: pointer;
}
.pill-x:hover { border-color: var(--accent); }

/* ===== Telefon ===== */
@media (max-width: 760px) {
  .nav-text, .hide-sm { display: none; }
  .nav-link { padding: 8px 10px; font-size: 1.1rem; }
  .nav-new { width: 38px; padding: 0; font-size: 1.2rem; }
  .detail-hero, .detail-hero.has-image { grid-template-columns: 1fr; padding: 0; }
  .detail-hero:not(.has-image) { padding: 18px; }
  .detail-hero:not(.has-image) .detail-media { width: 88px; }
  .detail-hero.has-image .detail-info { padding: 16px 18px 18px; }
  .has-image .detail-media { aspect-ratio: 16 / 10; }
  .detail-cols { grid-template-columns: 1fr; }
  #malzemeler { position: static; }
  .detail-actions .btn { flex: 1 1 auto; }
  .detail-actions .btn-primary { flex-basis: 100%; }
  .match { grid-template-columns: 56px 1fr; }
  .match-media { width: 56px; height: 56px; }
  .match > .btn { grid-column: 1 / -1; }
  .match.no-media { grid-template-columns: 1fr; }
  .cook-ings { position: absolute; right: 0; top: 0; bottom: 0; box-shadow: -8px 0 24px rgba(0, 0, 0, .2); }
  .cook-main { position: relative; }
  .cook-foot .btn { padding: 0 18px; }
  .cook-wake { font-size: .72rem; }
  .timers { right: 12px; left: 12px; width: auto; bottom: calc(var(--nav-h) + 10px + env(safe-area-inset-bottom)); }
}

/* ===== Yazdırma ===== */
/* ===== Yeni etiketleri, yeni tarifler şeridi ===== */
.badge-new { background: var(--green-soft); color: var(--green); font-size: .7rem; padding: 1px 7px; vertical-align: 2px; font-weight: 600; }
.recipe-title .badge-new { margin-left: 4px; }
.cat-name .badge-new { margin-left: 6px; }
.new-banner { display: flex; align-items: center; gap: 8px; background: var(--green-soft); border: 1px solid var(--border);
  border-radius: var(--radius); padding: 8px 8px 8px 14px; margin: 0 0 14px; }
.new-banner a { flex: 1; min-width: 0; display: grid; gap: 1px; color: var(--text); text-decoration: none; }
.new-banner b { color: var(--green); }
.new-banner span { font-size: .88rem; color: var(--muted); }
.new-group { margin: 0 0 18px; }
.new-group .section-head { margin-bottom: 6px; }
.new-foot { text-align: center; margin: 20px 0 8px; }
.age-note { font-size: .85rem; color: var(--muted); background: var(--surface-2); border-radius: 10px; padding: 8px 12px; margin: 0 0 12px; }
.detail-info .age-note { margin: 10px 0 0; }

/* ===== Sayfam › Üyeler ===== */
.member-list { list-style: none; margin: 6px 0 0; padding: 0; }
.member-list > li { border-top: 1px solid var(--border); }
.member-list > li:first-child { border-top: 0; }
.member-list summary { display: flex; align-items: center; gap: 8px; padding: 11px 0; cursor: pointer; list-style: none; font-weight: 600; }
.member-list summary::-webkit-details-marker { display: none; }
.member-list summary::after { content: "▾"; margin-left: auto; color: var(--muted); transition: transform .15s; }
.member-list details[open] summary::after { transform: rotate(180deg); }
.member-name { min-width: 0; overflow-wrap: anywhere; }
.member-info { display: grid; grid-template-columns: auto 1fr; gap: 4px 14px; margin: 0 0 12px; font-size: .88rem; }
.member-info div { display: contents; }
.member-info dt { color: var(--muted); }
.member-info dd { margin: 0; overflow-wrap: anywhere; }

/* ===== Bildirimler ===== */
.notify-box p { margin: 0 0 10px; line-height: 1.55; }
.notify-state { font-weight: 600; }
.notify-state.on { color: var(--green); }
.notify-actions { display: flex; gap: 10px; flex-wrap: wrap; margin: 6px 0 4px; }
.notify-steps { margin: 0 0 6px; padding-left: 20px; line-height: 1.7; }
.notify-ask { margin: 0 0 14px; }
.notify-ask-body { display: flex; gap: 12px; align-items: flex-start; }
.notify-ask-icon { flex: none; width: 36px; height: 36px; border-radius: 10px; display: grid; place-items: center;
  background: var(--green-soft); color: var(--green); }
.notify-ask h2 { margin: 0 0 4px; font-size: 1.02rem; }
.notify-ask p { margin: 0; color: var(--muted); font-size: .88rem; line-height: 1.5; }
.notify-ask-actions { display: flex; gap: 8px; flex-wrap: wrap; margin: 12px 0 0 48px; }

@media print {
  .topbar, .back, .detail-actions, .stepper, .segmented, .fav-star, .site-footer, .cooked-bar,
  .notes, .similar, .timers, .bottom-nav, .hint-line, .panel-head .btn, .toast, .skip-link, .more, .day-nav, .past-menus, .status-box { display: none !important; }
  body { background: #fff; color: #000; }
  .panel, .detail-hero { box-shadow: none; border: 0; padding: 0; }
  .detail-cols { grid-template-columns: 1fr 1.4fr; }
  #malzemeler { position: static; }
  .timer-chip { border: 0; background: none; color: inherit; padding: 0; font-weight: 400; }
  .ingredients input { display: none; }
}

/* ===== Üye versiyonları ve puanlama ===== */
.badge-row { display: flex; gap: 6px; flex-wrap: wrap; }
.badge-site { background: var(--green-soft); color: var(--green); }
.version-of { margin: 8px 0 -4px; color: var(--muted); font-size: .9rem; }
.version-of a { color: var(--accent); font-weight: 600; }
.versions, .rate-box { margin-top: 14px; }
.versions h2, .rate-box h2 { margin: 0; font-size: 1.1rem; }
.versions .plain-list a { gap: 3px; }
.stars { display: flex; gap: 4px; margin-top: 8px; }
.star {
  width: 44px; height: 44px; border: 0; background: none; padding: 0; cursor: pointer;
  font-size: 2rem; line-height: 1; color: var(--muted);
}
.star.on { color: var(--fav); }
.star:hover, .star:focus-visible { color: var(--fav); }
.star:disabled { opacity: .6; cursor: default; }
.rate-box .hint-line { margin-top: 6px; }
@media print { .versions, .rate-box { display: none !important; } }
