:root {
  --primary: #b4532a;
  --primary-rgb: 180, 83, 42;
  --bg: #f5f0e8;
  --card: #fffdf9;
  --ink: #1f1a17;
  --ink-2: #4a413a;
  --muted: #8a7d72;
  --line: #e9e0d4;
  --chip: #ece4d8;
  --shadow: 0 1px 2px rgba(60, 40, 20, .05), 0 6px 20px rgba(60, 40, 20, .06);
  --safe-b: env(safe-area-inset-bottom, 0px);
  --sans: 'Manrope', system-ui, -apple-system, 'Segoe UI', Roboto, sans-serif;
  --serif: 'Fraunces', Georgia, serif;
  --head-h: 60px;
  --tabs-h: 50px;
}
* { box-sizing: border-box; -webkit-tap-highlight-color: transparent; }
html, body { margin: 0; }
html { scroll-padding-top: calc(var(--head-h) + var(--tabs-h) + 8px); }
body { font-family: var(--sans); color: var(--ink); background: #e6ddd0; -webkit-font-smoothing: antialiased; }
button { font: inherit; color: inherit; background: none; border: 0; padding: 0; cursor: pointer; text-align: inherit; }
a { color: inherit; text-decoration: none; }
img { display: block; max-width: 100%; }
svg { flex: none; }
[hidden] { display: none !important; }
:focus-visible { outline: 2px solid var(--primary); outline-offset: 2px; }

.app { position: relative; overflow-x: clip; max-width: 480px; min-height: 100dvh; margin: 0 auto; background: var(--bg); }
.view { min-height: 100dvh; padding-bottom: calc(110px + var(--safe-b)); }
.view.enter { animation: enter .3s ease; }
@keyframes enter { from { opacity: 0; transform: translateY(8px); } to { opacity: 1; transform: none; } }

.ico { width: 20px; height: 20px; fill: none; stroke: currentColor; stroke-width: 1.9; stroke-linecap: round; stroke-linejoin: round; }

/* ============================== Ana sayfa ============================== */
.cover { position: relative; margin: 12px 12px 0; height: 330px; border-radius: 28px; overflow: hidden; color: #fff; background: linear-gradient(160deg, color-mix(in srgb, var(--primary) 85%, #fff) 0%, var(--primary) 35%, color-mix(in srgb, var(--primary) 40%, #120c08) 100%); isolation: isolate; }
.cover > img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; z-index: -2; }
.cover::after { content: ''; position: absolute; inset: 0; z-index: -1; background: linear-gradient(180deg, rgba(0,0,0,.15) 0%, rgba(0,0,0,0) 35%, rgba(0,0,0,.6) 100%); }
.cover-pattern { position: absolute; right: -30px; top: -20px; width: 230px; height: 230px; color: rgba(255,255,255,.12); z-index: -1; }
.cover-top { position: absolute; top: 16px; left: 16px; right: 16px; display: flex; justify-content: space-between; align-items: center; }
.pill { display: inline-flex; align-items: center; gap: 6px; height: 32px; padding: 0 12px; border-radius: 999px; font-size: 12px; font-weight: 700; background: rgba(255,255,255,.18); backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px); border: 1px solid rgba(255,255,255,.25); }
.pill .ico { width: 15px; height: 15px; }
.glass-btn { width: 38px; height: 38px; border-radius: 50%; display: grid; place-items: center; background: rgba(255,255,255,.18); backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px); border: 1px solid rgba(255,255,255,.25); }
.cover-body { position: absolute; left: 22px; right: 22px; bottom: 22px; }
.cover-logo { max-height: 72px; max-width: 220px; width: auto; object-fit: contain; margin-bottom: 10px; }
.cover-kicker { font-size: 11px; font-weight: 800; letter-spacing: .28em; text-transform: uppercase; opacity: .85; }
.cover-name { margin: 6px 0 0; font-family: var(--serif); font-weight: 600; font-size: 44px; line-height: 1; letter-spacing: -.02em; }
.cover-about { margin: 10px 0 0; font-size: 13.5px; line-height: 1.5; opacity: .9; max-width: 320px; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }

.searchbar { display: flex; align-items: center; gap: 10px; margin: -24px 24px 0; position: relative; z-index: 2; height: 52px; padding: 0 18px; border-radius: 16px; background: var(--card); box-shadow: var(--shadow); color: var(--muted); font-size: 14.5px; width: calc(100% - 48px); }
.searchbar .ico { color: var(--ink); }

.section { padding: 28px 16px 0; }
.section-head { display: flex; align-items: baseline; justify-content: space-between; margin: 0 4px 14px; }
.section-head h2 { margin: 0; font-family: var(--serif); font-weight: 600; font-size: 23px; letter-spacing: -.01em; }
.section-head span { font-size: 12.5px; color: var(--muted); font-weight: 600; }

.rail { display: flex; gap: 12px; overflow-x: auto; margin: 0 -16px; padding: 2px 16px 6px; scroll-snap-type: x mandatory; scrollbar-width: none; }
.rail::-webkit-scrollbar { display: none; }
.pick { flex: none; width: 168px; scroll-snap-align: start; background: var(--card); border-radius: 20px; padding: 8px; box-shadow: var(--shadow); }
.thumb { position: relative; border-radius: 14px; overflow: hidden; background: linear-gradient(150deg, color-mix(in srgb, var(--primary) 14%, var(--bg)), color-mix(in srgb, var(--primary) 28%, var(--bg))); color: color-mix(in srgb, var(--primary) 55%, transparent); display: grid; place-items: center; }
.thumb img { width: 100%; height: 100%; object-fit: cover; }
.pick .thumb { height: 118px; }
.pick .thumb svg { width: 54px; height: 54px; }
.pick-body { padding: 10px 6px 4px; }
.pick-name { font-weight: 700; font-size: 14px; line-height: 1.3; min-height: 36px; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.pick-foot { display: flex; align-items: center; justify-content: space-between; margin-top: 8px; }
.price { font-weight: 800; font-size: 15px; color: var(--ink); white-space: nowrap; }
.plus { width: 28px; height: 28px; border-radius: 10px; display: grid; place-items: center; background: var(--primary); color: #fff; }
.plus .ico { width: 16px; height: 16px; stroke-width: 2.4; }

.cats { display: flex; flex-direction: column; gap: 10px; }
.cat { display: flex; align-items: center; gap: 14px; padding: 12px 14px 12px 12px; border-radius: 20px; background: var(--card); box-shadow: var(--shadow); transition: transform .15s; }
.cat:active { transform: scale(.985); }
.cat-icon { width: 58px; height: 58px; border-radius: 16px; display: grid; place-items: center; background: color-mix(in srgb, var(--primary) 12%, var(--bg)); color: var(--primary); flex: none; overflow: hidden; }
.cat-icon svg { width: 34px; height: 34px; }
.cat-icon img { width: 100%; height: 100%; object-fit: cover; }
.cat-body { flex: 1; min-width: 0; display: block; }
.cat-name { display: block; font-family: var(--serif); font-weight: 600; font-size: 19px; line-height: 1.2; }
.cat-sub { display: block; margin-top: 3px; font-size: 12.5px; color: var(--muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.arrow { width: 34px; height: 34px; border-radius: 50%; display: grid; place-items: center; background: var(--bg); color: var(--ink); flex: none; }
.arrow .ico { width: 16px; height: 16px; }
.home-foot { text-align: center; color: var(--muted); font-size: 12px; padding: 26px 24px 0; }

/* ============================== Kategori ============================== */
.appbar { position: sticky; top: 0; z-index: 30; height: var(--head-h); display: grid; grid-template-columns: 44px 1fr 44px; align-items: center; padding: 0 10px; background: color-mix(in srgb, var(--bg) 92%, transparent); backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px); }
.appbar-title { text-align: center; font-family: var(--serif); font-weight: 600; font-size: 19px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.circle-btn { width: 40px; height: 40px; border-radius: 50%; display: grid; place-items: center; background: var(--card); box-shadow: var(--shadow); }
.tabs { position: sticky; top: var(--head-h); z-index: 29; height: var(--tabs-h); display: flex; gap: 22px; overflow-x: auto; padding: 0 20px; background: color-mix(in srgb, var(--bg) 92%, transparent); backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px); border-bottom: 1px solid var(--line); scrollbar-width: none; }
.tabs::-webkit-scrollbar { display: none; }
.tab { position: relative; flex: none; display: flex; align-items: center; font-size: 14px; font-weight: 700; color: var(--muted); white-space: nowrap; transition: color .2s; }
.tab::after { content: ''; position: absolute; left: 0; right: 0; bottom: -1px; height: 3px; border-radius: 3px 3px 0 0; background: var(--primary); transform: scaleX(0); transition: transform .25s; }
.tab.active { color: var(--ink); }
.tab.active::after { transform: scaleX(1); }

.intro { display: flex; gap: 14px; align-items: center; margin: 16px 16px 4px; padding: 16px; border-radius: 22px; background: var(--primary); color: #fff; overflow: hidden; position: relative; }
.intro.has-img { min-height: 150px; align-items: flex-end; background: #2a1f18; }
.intro > img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; opacity: .75; }
.intro.has-img::after { content: ''; position: absolute; inset: 0; background: linear-gradient(180deg, transparent 30%, rgba(0,0,0,.6)); }
.intro-icon { width: 54px; height: 54px; border-radius: 16px; background: rgba(255,255,255,.16); display: grid; place-items: center; flex: none; }
.intro-icon svg { width: 34px; height: 34px; }
.intro-text { position: relative; z-index: 1; }
.intro h1 { margin: 0; font-family: var(--serif); font-weight: 600; font-size: 26px; line-height: 1.1; }
.intro p { margin: 4px 0 0; font-size: 12.5px; opacity: .85; font-weight: 600; }

.group { padding: 22px 16px 0; }
.group-title { display: flex; align-items: baseline; gap: 8px; margin: 0 4px 12px; font-family: var(--serif); font-weight: 600; font-size: 21px; }
.group-title small { font-family: var(--sans); font-size: 12px; color: var(--muted); font-weight: 700; }
.items { display: flex; flex-direction: column; gap: 10px; }

.item { display: flex; gap: 14px; align-items: stretch; width: 100%; padding: 14px; border-radius: 20px; background: var(--card); box-shadow: var(--shadow); transition: transform .15s; }
.item:active { transform: scale(.985); }
.item-body { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.item-name { font-weight: 800; font-size: 15.5px; line-height: 1.3; }
.item-desc { margin-top: 5px; font-size: 13px; line-height: 1.5; color: var(--muted); display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.item-foot { margin-top: auto; padding-top: 10px; display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.item .thumb { width: 96px; height: 96px; flex: none; }
.item .thumb svg { width: 40px; height: 40px; }
.menu-price { display: inline-flex; align-items: center; height: 24px; padding: 0 9px; border-radius: 999px; font-size: 12px; font-weight: 800; color: var(--ink-2); background: var(--chip); white-space: nowrap; }
.group-note { margin: -4px 4px 12px; font-size: 12.5px; line-height: 1.5; color: var(--muted); }
.p-price + .p-price { margin-top: 10px; }
.p-price small { display: block; margin-top: 3px; font-size: 11.5px; font-weight: 500; color: var(--muted); line-height: 1.4; max-width: 220px; }
.tag { display: inline-flex; align-items: center; height: 22px; padding: 0 8px; border-radius: 999px; font-size: 11px; font-weight: 800; color: var(--primary); background: color-mix(in srgb, var(--primary) 12%, transparent); }
.empty { padding: 48px 24px; text-align: center; color: var(--muted); font-size: 14px; }

/* ============================== Alt menü ============================== */
.dock { position: fixed; z-index: 40; left: 50%; transform: translateX(-50%); bottom: calc(14px + var(--safe-b)); width: min(calc(100% - 28px), 452px); height: 66px; display: grid; grid-template-columns: repeat(4, 1fr); padding: 7px; border-radius: 24px; background: color-mix(in srgb, var(--ink) 94%, transparent); backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px); box-shadow: 0 12px 30px rgba(31, 26, 23, .28); }
.dock-btn { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 3px; border-radius: 17px; color: rgba(255,255,255,.6); font-size: 10.5px; font-weight: 700; transition: background .2s, color .2s; }
.dock-btn svg { width: 21px; height: 21px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.dock-btn.active { background: var(--primary); color: #fff; }
.dock-btn:active { background: rgba(255,255,255,.08); }

/* ============================== Paneller ============================== */
.sheet { position: fixed; z-index: 60; inset: 0; display: flex; align-items: flex-end; justify-content: center; background: rgba(31, 26, 23, .42); opacity: 0; pointer-events: none; transition: opacity .25s; }
.sheet.open { opacity: 1; pointer-events: auto; }
.sheet-panel { position: relative; width: 100%; max-width: 480px; max-height: 86dvh; overflow-y: auto; overscroll-behavior: contain; background: var(--bg); border-radius: 28px 28px 0 0; padding: 10px 18px calc(24px + var(--safe-b)); transform: translateY(40px); transition: transform .3s cubic-bezier(.2,.8,.2,1); }
.sheet-panel.tall { max-height: 94dvh; padding: 0 0 calc(24px + var(--safe-b)); }
.sheet.open .sheet-panel { transform: none; }
.grip { width: 42px; height: 5px; border-radius: 5px; background: #d5cabb; margin: 0 auto 16px; }
.sheet-title { margin: 0 0 16px; font-family: var(--serif); font-weight: 600; font-size: 24px; }

.cat-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.cat-tile { display: flex; flex-direction: column; gap: 14px; padding: 16px; border-radius: 20px; background: var(--card); box-shadow: var(--shadow); min-height: 128px; }
.cat-tile .cat-icon { width: 50px; height: 50px; border-radius: 14px; }
.cat-tile .cat-icon svg { width: 30px; height: 30px; }
.cat-tile b { font-family: var(--serif); font-weight: 600; font-size: 17px; line-height: 1.2; margin-top: auto; }
.cat-tile small { color: var(--muted); font-size: 12px; font-weight: 600; margin-top: -10px; }
.cat-tile.current { box-shadow: 0 0 0 2px var(--primary), var(--shadow); }

/* Ürün paneli */
.p-media { position: relative; height: 300px; margin: 10px 10px 0; border-radius: 22px; }
.p-media.thumb > svg { width: 120px; height: 120px; }
.p-close .ico { width: 18px; height: 18px; }
.p-media .grip { position: absolute; top: -2px; left: 50%; transform: translateX(-50%); z-index: 2; margin: 0; background: rgba(255,255,255,.7); }
.p-close { position: absolute; top: 12px; right: 12px; z-index: 2; width: 38px; height: 38px; border-radius: 50%; display: grid; place-items: center; background: rgba(255,255,255,.92); color: var(--ink); box-shadow: var(--shadow); }
.p-share { right: 58px; }
.p-body { padding: 20px 22px 0; }
.p-crumb { font-size: 11.5px; font-weight: 800; letter-spacing: .14em; text-transform: uppercase; color: var(--primary); }
.p-name { margin: 8px 0 0; font-family: var(--serif); font-weight: 600; font-size: 28px; line-height: 1.12; letter-spacing: -.01em; }
.p-desc { margin: 12px 0 0; font-size: 14.5px; line-height: 1.65; color: var(--ink-2); }
.p-price { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-top: 20px; padding: 14px 16px; border-radius: 18px; background: var(--card); box-shadow: var(--shadow); }
.p-price span { font-size: 13px; color: var(--muted); font-weight: 600; }
.p-price b { font-size: 22px; font-weight: 800; color: var(--primary); }
.p-similar { padding: 26px 22px 0; }
.p-similar h3 { margin: 0 0 12px; font-family: var(--serif); font-weight: 600; font-size: 19px; }
.p-similar .rail { margin: 0 -22px; padding: 2px 22px 6px; }
.p-similar .pick { width: 148px; }
.p-similar .pick .thumb { height: 100px; }

/* Bilgi */
.info-about { margin: -6px 0 18px; color: var(--ink-2); font-size: 14px; line-height: 1.6; }
.info-list { background: var(--card); border-radius: 20px; box-shadow: var(--shadow); padding: 4px 16px; }
.info-row { display: flex; gap: 14px; align-items: center; padding: 13px 0; border-bottom: 1px solid var(--line); font-size: 14px; font-weight: 600; }
.info-row:last-child { border-bottom: 0; }
.info-row .ii { width: 38px; height: 38px; border-radius: 12px; background: color-mix(in srgb, var(--primary) 12%, var(--bg)); color: var(--primary); display: grid; place-items: center; flex: none; }
.info-row small { display: block; color: var(--muted); font-size: 11.5px; font-weight: 600; margin-bottom: 2px; }
.copy { margin-left: auto; font-size: 12px; font-weight: 800; color: #fff; background: var(--primary); padding: 7px 12px; border-radius: 10px; }
.info-note { margin: 14px 0 0; font-size: 12px; color: var(--muted); text-align: center; }

/* Arama */
.search { position: fixed; z-index: 70; top: 0; bottom: 0; left: 50%; width: 100%; max-width: 480px; transform: translate(-50%, 16px); background: var(--bg); display: flex; flex-direction: column; opacity: 0; pointer-events: none; transition: opacity .2s, transform .2s; }
.search.open { opacity: 1; pointer-events: auto; transform: translate(-50%, 0); }
.search-head { display: flex; gap: 12px; align-items: center; padding: 14px 16px; }
.search-field { flex: 1; display: flex; align-items: center; gap: 10px; height: 50px; padding: 0 16px; border-radius: 16px; background: var(--card); box-shadow: var(--shadow); }
.search-field svg { width: 19px; height: 19px; fill: none; stroke: var(--ink); stroke-width: 2; stroke-linecap: round; }
.search-field input { flex: 1; min-width: 0; border: 0; outline: none; background: none; font: inherit; font-size: 16px; color: var(--ink); }
.text-btn { font-weight: 800; font-size: 14px; color: var(--primary); padding: 8px 2px; }
.search-results { flex: 1; overflow-y: auto; padding: 4px 16px 24px; display: flex; flex-direction: column; gap: 10px; }
.search-hint { padding: 48px 24px; text-align: center; color: var(--muted); font-size: 14px; }

.toast { position: fixed; z-index: 90; left: 50%; bottom: calc(96px + var(--safe-b)); transform: translate(-50%, 16px); background: var(--ink); color: #fff; font-size: 13px; font-weight: 600; padding: 10px 16px; border-radius: 12px; opacity: 0; pointer-events: none; transition: .2s; }
.toast.show { opacity: 1; transform: translate(-50%, 0); }

.loading { display: grid; place-items: center; min-height: 100dvh; }
.spinner { width: 32px; height: 32px; border-radius: 50%; border: 3px solid var(--chip); border-top-color: var(--primary); animation: spin .8s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }

@media (prefers-reduced-motion: reduce) { *, *::before, *::after { animation: none !important; transition: none !important; } html { scroll-behavior: auto; } }
