/* simurg.concept — LGOrder stilleri — MOBILE-FIRST
 * Host sitenin --sans/--mono/--line/--ink/--accent tokenlarını kullanır.
 * Taban = mobil (bottom-sheet), ≥560px = masaüstü modal.
 */

/* —— satır + buton: asla fiyatın üstüne binme — grid kolon —— */
.og-add {
  width: 42px; height: 42px; border-radius: 10px;
  border: 1.5px solid color-mix(in srgb, var(--chalk, #f4efe3) 28%, transparent);
  background: color-mix(in srgb, var(--chalk, #f4efe3) 7%, transparent);
  color: var(--chalk, #f4efe3);
  display: flex; align-items: center; justify-content: center; cursor: pointer;
  flex: 0 0 auto;
  transition: background .15s, color .15s;
}
.og-add:hover { background: var(--accent, #e05f0d); color: var(--accent-ink, #fff); border-color: var(--accent, #e05f0d); }
.og-add:focus-visible { outline: 2px solid var(--accent, #e05f0d); outline-offset: 2px; }
@media (min-width: 560px) {
  .og-add { width: 36px; height: 36px; border-radius: 9px; }
}

/* —— modal (bottom-sheet mobil / merkez masaüstü) —— */
.og-modal-overlay {
  position: fixed; inset: 0; z-index: 200;
  background: rgba(18, 16, 12, .58);
  display: flex; align-items: flex-end; justify-content: center;
}
.og-modal {
  width: 100%; max-width: 480px;
  max-height: 92dvh; overflow-y: auto; -webkit-overflow-scrolling: touch;
  background: var(--card, #fffdf8); color: var(--ink, #1f1c17);
  border-radius: 20px 20px 0 0;
  padding: 16px 16px calc(18px + env(safe-area-inset-bottom));
  font-family: var(--sans, system-ui, sans-serif);
  box-shadow: 0 -10px 40px rgba(0, 0, 0, .3);
  animation: og-slide-up .22s ease-out;
}
@keyframes og-slide-up { from { transform: translateY(24px); opacity: .6; } }
@media (min-width: 560px) {
  .og-modal-overlay { align-items: center; padding: 18px; }
  .og-modal {
    border-radius: 16px; padding: 22px; max-height: 86vh;
    box-shadow: 0 20px 60px rgba(0, 0, 0, .28);
    animation: og-pop .18s ease-out;
  }
  @keyframes og-pop { from { transform: scale(.97); opacity: .7; } }
}
.og-modal-title { margin: 0 0 12px; font-size: 17px; font-weight: 700; line-height: 1.3; }

/* —— varyant seçimi —— */
.og-variants { display: grid; gap: 8px; margin-bottom: 14px; }
.og-variant {
  display: flex; justify-content: space-between; align-items: center; gap: 10px;
  min-height: 50px; padding: 12px 14px; border-radius: 12px;
  border: 1.5px solid var(--line, #d4c6ab);
  background: transparent; cursor: pointer; font: inherit; text-align: left;
  font-size: 15px;
}
.og-variant.sel { border-color: var(--accent, #e05f0d); background: color-mix(in srgb, var(--accent, #e05f0d) 9%, transparent); }
.og-variant .og-vp { font-family: var(--mono, monospace); font-weight: 600; white-space: nowrap; }

/* —— butonlar —— */
.og-btn {
  font: inherit; font-size: 14px; font-weight: 650; letter-spacing: .01em;
  min-height: 46px; padding: 11px 18px;
  border-radius: 12px; border: 1.5px solid var(--line, #d4c6ab);
  background: transparent; color: var(--ink, #1f1c17); cursor: pointer;
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  white-space: nowrap;             /* WhatsApp metni alt satıra düşmez */
}
.og-btn svg { flex: 0 0 auto; }
.og-btn:hover { background: rgba(0, 0, 0, .05); }
.og-btn.primary { background: var(--accent, #e05f0d); border-color: var(--accent, #e05f0d); color: var(--accent-ink, #fff); }
.og-btn.primary:hover { filter: brightness(1.08); }

.og-modal-actions {
  display: flex; flex-direction: column-reverse; gap: 8px;  /* mobil: ana buton en üstte, tam genişlik */
}
.og-modal-actions .og-btn { width: 100%; }
@media (min-width: 560px) {
  .og-modal-actions { flex-direction: row; justify-content: flex-end; }
  .og-modal-actions .og-btn { width: auto; }
}
.og-send { background: #1faa53 !important; border-color: #1faa53 !important; }
.og-send:hover { filter: brightness(1.06) !important; }

/* —— sepet çubuğu —— */
.og-bar {
  position: fixed; left: 12px; right: 12px;
  bottom: calc(12px + env(safe-area-inset-bottom)); z-index: 150;
  background: var(--ink, #1f1c17); color: #f4efe3;
  border-radius: 16px; padding: 12px 14px;
  box-shadow: 0 14px 40px rgba(0, 0, 0, .4);
  font-family: var(--sans, system-ui, sans-serif); font-size: 14.5px;
  max-width: 560px; margin: 0 auto;
}
@media (min-width: 560px) {
  .og-bar { left: 50%; right: auto; transform: translateX(-50%); width: 560px; padding: 11px 16px; }
}
.og-bar .og-hint, .og-bar .og-closed { display: block; text-align: center; padding: 4px 0; font-size: 13.5px; }
.og-bar .og-closed { color: #e8c9a0; }
.og-bar .og-closed-sub { display: block; text-align: center; font-size: 11.5px; color: #e8c9a0; padding-top: 3px; }
.og-bar-go { all: unset; display: flex; align-items: center; gap: 12px; width: 100%; cursor: pointer; color: inherit; }
.og-bar-go b {
  background: var(--accent, #e05f0d); color: var(--accent-ink, #fff); min-width: 24px; height: 24px;
  border-radius: 999px; display: inline-flex; align-items: center; justify-content: center;
  font-size: 13px; font-weight: 700;
}
.og-bar-total { font-family: var(--mono, monospace); font-weight: 600; font-size: 14px; }
.og-bar-cta { margin-left: auto; font-weight: 650; font-size: 13.5px; color: #fff; }
@media (max-width: 420px) { .og-bar-cta { display: none; } }

/* —— checkout satırları —— */
.og-lines { display: grid; gap: 6px; margin-bottom: 12px; }
.og-line {
  display: grid; grid-template-columns: auto 1fr auto; gap: 8px; align-items: center;
  font-size: 14px; padding: 8px 10px;
  border: 1px dashed var(--line, #d4c6ab); border-radius: 10px;
}
.og-qty { display: inline-flex; align-items: center; gap: 6px; }
.og-qty svg { cursor: pointer; color: var(--accent, #e05f0d); padding: 7px; box-sizing: content-box; }
.og-qty b { min-width: 16px; text-align: center; font-size: 15px; }
.og-label { overflow-wrap: anywhere; }
.og-price { font-family: var(--mono, monospace); font-weight: 600; white-space: nowrap; }

.og-mode { display: flex; gap: 8px; margin-bottom: 12px; }
.og-mode-btn {
  flex: 1; font: inherit; font-size: 13.5px; font-weight: 650;
  min-height: 44px; padding: 10px 0;
  border-radius: 12px; border: 1.5px solid var(--line, #d4c6ab);
  background: transparent; cursor: pointer; color: inherit;
}
.og-mode-btn.sel { border-color: var(--accent, #e05f0d); background: color-mix(in srgb, var(--accent, #e05f0d) 9%, transparent); }

.og-form { display: grid; gap: 8px; margin-bottom: 12px; font-size: 13.5px; }
.og-form label { display: grid; gap: 4px; font-weight: 550; }
.og-f {
  font: inherit; min-height: 46px; padding: 11px 12px; border-radius: 12px;
  border: 1.5px solid var(--line, #d4c6ab); background: #fff; color: inherit;
  font-size: 15px;               /* iOS zoom'u engellemek için ≥16px'ye yakın */
}
@media (max-width: 559px) { .og-f { font-size: 16px; } }
.og-f:focus { outline: 2px solid var(--accent, #e05f0d); outline-offset: 1px; border-color: var(--accent, #e05f0d); }

.og-sum { border-top: 1px solid var(--line, #d4c6ab); padding-top: 10px; font-size: 14px; }
.og-sum div { display: flex; justify-content: space-between; padding: 3px 0; }
.og-sum .og-grand { font-weight: 700; font-size: 16px; border-top: 1px dashed var(--line, #d4c6ab); margin-top: 6px; padding-top: 9px; }
.og-sum .og-grand span:last-child { font-family: var(--mono, monospace); }
.og-minerr { color: #8c3a3a; font-weight: 600; margin-top: 6px; font-size: 13px; }

/* —— toast —— */
.og-toast {
  position: fixed; left: 50%; transform: translateX(-50%) translateY(6px);
  bottom: calc(84px + env(safe-area-inset-bottom)); z-index: 220;
  background: #14120f; color: #f4efe3;
  padding: 10px 18px; border-radius: 12px;
  font-size: 13.5px; font-family: var(--sans, system-ui, sans-serif);
  opacity: 0; transition: opacity .22s, transform .22s; pointer-events: none;
  max-width: min(92vw, 420px); text-align: center;
}
.og-toast.show { opacity: .97; transform: translateX(-50%) translateY(0); }

@media print {
  .og-add, .og-bar, .og-toast, .og-modal-overlay, .og-detail, .og-topbar { display: none !important; }
  .item { padding-right: 0; }
}

[data-mode="paper"] .og-add,
[data-menu="paper"] .og-add,
[data-menu="cards"] .og-add {
  border-color: var(--line, #d4c6ab);
  background: var(--card, #fffaf0);
  color: var(--ink, #161513);
}

/* ==========================================================================
   Sipariş modu (orderkit yüklü) — app davranışı
   ========================================================================== */
:root { --topbar-h: 3.15rem; }

/* satır artık dokunulabilir: detay sayfasını açar */
[data-order="1"] .item { cursor: pointer; }
[data-order="1"] .fcard { cursor: pointer; }

/* satır içi varyant listesi app modunda gizlenir, yerine ince ipucu */
[data-order="1"] .item-variants { display: none; }
.item-opt-hint { display: none; }
[data-order="1"] .item-opt-hint {
  display: block;
  margin-top: 0.18rem;
  color: var(--muted, #8a857c);
  font-size: 0.8rem;
  line-height: 1.4;
}

/* --- sticky mini-header: marka + sepet sayacı --- */
.og-topbar {
  position: fixed; top: 0; left: 0; right: 0; z-index: 160;
  min-height: var(--topbar-h);
  display: flex; align-items: center; gap: 0.6rem;
  padding: 0 1.15rem;
  background: color-mix(in srgb, var(--paper, #fff) 90%, transparent);
  backdrop-filter: blur(12px); -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--line, #e9e7e2);
  font-family: var(--sans, system-ui, sans-serif); color: var(--ink, #1f1c17);
  transform: translateY(-110%); opacity: 0; pointer-events: none;
  transition: transform .22s ease, opacity .22s ease;
}
body.mini-on .og-topbar { transform: none; opacity: 1; pointer-events: auto; }
.og-topbar-brand {
  flex: 1 1 auto; min-width: 0;
  font-family: var(--display, Georgia, serif);
  font-size: 1.02rem; font-weight: 700; letter-spacing: -0.01em;
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.og-topbar-cart {
  flex: 0 0 auto; display: inline-flex; align-items: center; gap: 0.45rem;
  min-height: 2.3rem; padding: 0 0.6rem;
  border-radius: 999px; border: 1.5px solid var(--line-strong, #dcd9d3);
  background: var(--card, #fff); color: var(--ink, #1f1c17);
  cursor: pointer; font: inherit;
  transition: background .15s, color .15s, border-color .15s;
}
.og-topbar-cart.has {
  background: var(--ink, #1f1c17); color: var(--paper, #fff); border-color: var(--ink, #1f1c17);
}
.og-topbar-cart b {
  background: var(--accent, #e05f0d); color: var(--accent-ink, #fff);
  min-width: 1.35rem; height: 1.35rem; padding: 0 0.25rem;
  border-radius: 999px; display: inline-flex; align-items: center; justify-content: center;
  font-size: 0.76rem; font-weight: 700;
}
.og-topbar-total {
  font-family: var(--mono, monospace); font-size: 0.8rem; font-weight: 600;
  font-variant-numeric: tabular-nums;
}
.og-topbar-cart svg { display: block; }

/* mini-header açıkken kategori çubuğu onun altına yapışır */
body.mini-on .menu-stick { top: var(--topbar-h); }
body.mini-on .menu-section { scroll-margin-top: calc(var(--stick-h, 3.2rem) + var(--topbar-h) + 0.6rem); }

/* --- tam ekran ürün detay sayfası (modal değil, app sayfa akışı) --- */
.og-detail {
  position: fixed; inset: 0; z-index: 210;
  background: var(--paper, #fff); color: var(--ink, #1f1c17);
  overflow-y: auto; -webkit-overflow-scrolling: touch;
  font-family: var(--sans, system-ui, sans-serif);
  transform: translateX(100%);
  transition: transform .3s cubic-bezier(.32, .72, .25, 1);
}
.og-detail.in { transform: none; }
.og-detail-inner {
  max-width: 560px; margin: 0 auto; min-height: 100%;
  display: flex; flex-direction: column;
}
@media (min-width: 720px) {
  .og-detail-inner { max-width: 640px; border-left: 1px solid var(--line, #e9e7e2); border-right: 1px solid var(--line, #e9e7e2); }
}
.og-detail-media { position: relative; background: var(--paper-2, #f6f5f2); }
.og-detail-img { display: block; width: 100%; aspect-ratio: 4 / 3; object-fit: cover; }
@media (min-width: 720px) { .og-detail-img { aspect-ratio: 16 / 9; } }
.og-detail-topbar {
  display: flex; align-items: center; gap: 0.6rem;
  padding: 0.7rem 0.9rem; border-bottom: 1px solid var(--line, #e9e7e2);
}
.og-detail-back {
  position: absolute; top: 0.75rem; left: 0.75rem;
  width: 2.5rem; height: 2.5rem; border-radius: 999px; border: 0;
  background: rgba(255, 255, 255, 0.94); color: var(--ink, #1f1c17);
  display: flex; align-items: center; justify-content: center; cursor: pointer;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.18);
  transition: transform .15s;
}
.og-detail-topbar .og-detail-back { position: static; box-shadow: none; background: var(--paper-2, #f6f5f2); }
.og-detail-back:hover { transform: scale(1.06); }
.og-detail-back:focus-visible { outline: 2px solid var(--accent, #e05f0d); outline-offset: 2px; }

.og-detail-body { flex: 1 1 auto; padding: 1.15rem 1.15rem 0; }
.og-detail-name {
  margin: 0; font-family: var(--display, Georgia, serif);
  font-size: 1.6rem; font-weight: 700; letter-spacing: -0.02em; line-height: 1.12;
}
.og-detail-desc { margin: 0.5rem 0 0; color: var(--ink-soft, #4a463f); font-size: 0.95rem; line-height: 1.5; }
.og-detail-tag {
  display: inline-block; margin-top: 0.6rem;
  font-size: 0.62rem; font-weight: 750; letter-spacing: 0.06em; text-transform: uppercase;
  padding: 0.12rem 0.5rem; border-radius: 999px;
  background: color-mix(in srgb, #4c8b2f 14%, transparent); color: #4c8b2f;
}

.og-detail-opts { display: grid; gap: 0.5rem; margin-top: 1.2rem; }
.og-detail-optlabel {
  margin: 0 0 0.15rem;
  font-size: 0.72rem; font-weight: 700; letter-spacing: 0.1em; text-transform: uppercase;
  color: var(--muted, #8a857c);
}
.og-opt {
  display: flex; align-items: center; gap: 0.7rem; width: 100%;
  min-height: 3.6rem; padding: 0.5rem 0.65rem 0.5rem 0.5rem;
  border-radius: 14px; border: 1.5px solid var(--line, #e9e7e2);
  background: var(--card, #fff); color: inherit;
  font: inherit; text-align: left; cursor: pointer;
  transition: border-color .15s, background .15s;
}
.og-opt.sel { border-color: var(--accent, #e05f0d); background: color-mix(in srgb, var(--accent, #e05f0d) 6%, transparent); }
.og-opt:focus-visible { outline: 2px solid var(--accent, #e05f0d); outline-offset: 2px; }
.og-opt-media {
  flex: 0 0 auto; width: 3.4rem; height: 3.4rem; border-radius: 10px; overflow: hidden;
  background: var(--paper-2, #f6f5f2);
}
.og-opt-media img { width: 100%; height: 100%; object-fit: cover; display: block; }
.og-opt-body { flex: 1 1 auto; min-width: 0; display: flex; flex-direction: column; gap: 0.1rem; }
.og-opt-name { font-weight: 650; font-size: 0.98rem; line-height: 1.3; }
.og-opt-price {
  font-family: var(--mono, monospace); font-size: 0.86rem; font-weight: 600;
  color: var(--ink-soft, #4a463f); font-variant-numeric: tabular-nums;
}
.og-opt-dot {
  flex: 0 0 auto; width: 1.15rem; height: 1.15rem; border-radius: 999px;
  border: 2px solid var(--line-strong, #dcd9d3); position: relative;
}
.og-opt.sel .og-opt-dot { border-color: var(--accent, #e05f0d); }
.og-opt.sel .og-opt-dot::after {
  content: ""; position: absolute; inset: 3px; border-radius: 999px; background: var(--accent, #e05f0d);
}

.og-detail-qtyrow {
  display: flex; align-items: center; justify-content: space-between; gap: 1rem;
  margin-top: 1.3rem; padding-top: 0.95rem; border-top: 1px solid var(--line, #e9e7e2);
}
.og-detail-qlabel {
  font-size: 0.72rem; font-weight: 700; letter-spacing: 0.1em; text-transform: uppercase;
  color: var(--muted, #8a857c);
}
.og-stepper {
  display: flex; align-items: center; gap: 0.15rem;
  border: 1.5px solid var(--line-strong, #dcd9d3); border-radius: 999px; padding: 0.15rem;
}
.og-step {
  width: 2.4rem; height: 2.4rem; border-radius: 999px; border: 0;
  background: transparent; color: var(--ink, #1f1c17); cursor: pointer;
  display: flex; align-items: center; justify-content: center;
}
.og-step:hover { background: color-mix(in srgb, var(--ink, #1f1c17) 8%, transparent); }
.og-step:focus-visible { outline: 2px solid var(--accent, #e05f0d); outline-offset: 2px; }
.og-step-val { min-width: 1.7rem; text-align: center; font-family: var(--mono, monospace); font-weight: 600; }

.og-detail-cta {
  position: sticky; bottom: 0; margin-top: 1.4rem;
  padding: 0.75rem 1.15rem calc(0.75rem + env(safe-area-inset-bottom));
  background: color-mix(in srgb, var(--paper, #fff) 94%, transparent);
  backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px);
  border-top: 1px solid var(--line, #e9e7e2);
}
.og-detail-add {
  width: 100%; min-height: 3.2rem; border: 0; cursor: pointer;
  border-radius: var(--btn-radius, 999px);
  background: var(--accent, #e05f0d); color: var(--accent-ink, #fff);
  font: inherit; font-size: 1rem; font-weight: 700;
  display: flex; align-items: center; justify-content: center; gap: 0.6rem;
  transition: filter .15s, transform .1s;
}
.og-detail-add:hover { filter: brightness(1.06); }
.og-detail-add:active { transform: scale(0.985); }
.og-detail-addp { font-family: var(--mono, monospace); font-variant-numeric: tabular-nums; font-weight: 600; }

@media (prefers-reduced-motion: reduce) {
  .og-detail { transition: none; }
  .og-topbar { transition: none; }
  .og-detail-back { transition: none; }
}

/* ---- v1.2: seçenek grupları + servis-bazlı uygunluk ---- */
.og-hidden { display: none !important; }
.og-optgroup { display: grid; gap: 0.5rem; margin-top: 1.2rem; }
.og-optgroup .og-detail-optlabel {
  display: flex; align-items: center; gap: 0.45rem; flex-wrap: wrap;
}
.og-req {
  font-size: 0.62rem; font-weight: 750; letter-spacing: 0.06em; text-transform: uppercase;
  color: var(--accent, #e05f0d); border: 1px solid currentColor;
  border-radius: 999px; padding: 0.05rem 0.45rem;
}
.og-max { color: var(--muted, #8a857c); font-weight: 500; letter-spacing: 0.02em; text-transform: none; }
.og-opt.multi .og-opt-dot { border-radius: 5px; }
.og-opt.multi.sel .og-opt-dot::after { border-radius: 2px; }
.og-label em {
  display: block; font-style: normal; font-size: 0.82rem;
  color: var(--muted, #8a857c); margin-top: 0.1rem; line-height: 1.35;
}
.item-price small { font-weight: 500; }
