/* Alpem — tek stil dosyası. Kurallar: docs/TASARIM.md
   Bölümler: 1 Tokenlar · 2 Temel · 3 Bileşenler · 4 Site · 5 Panel · 6 Yazdırma · 7 Teklif (düzenleyici, müşteri teklif sayfası, mobil kalem kartları) */

/* 1 ─ Tokenlar */
:root {
  --ink: #14181d;
  --ink-2: #222931;
  --ink-3: #343d47;
  --steel: #5d6874;
  --mute: #8a939c;
  --line: #dcd8cf;
  --line-2: #e9e6df;
  --paper: #f4f2ed;
  --card: #ffffff;
  --signal: #f2b600;
  --signal-2: #ffd24d;
  --signal-ink: #1b1600;
  --ok: #2d7a4c;
  --ok-bg: #e5f2ea;
  --bad: #b2372c;
  --bad-bg: #f8e6e3;
  --warn-bg: #fff4d1;
  --link: #1c4f7c;
  --radius: 3px;
  --wrap: 1240px;
  --font: "Barlow", system-ui, sans-serif;
  --font-cond: "Barlow Condensed", "Barlow", sans-serif;
  --mono: "IBM Plex Mono", ui-monospace, monospace;
  color-scheme: light;
}

/* 2 ─ Temel */
*, *::before, *::after { box-sizing: border-box; }
[hidden] { display: none !important; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; font: 400 16px/1.55 var(--font); color: var(--ink); background: var(--paper); }
img { max-width: 100%; display: block; }
a { color: var(--link); text-underline-offset: 3px; }
h1, h2, h3, h4 { font-family: var(--font-cond); font-weight: 700; line-height: 1.1; margin: 0 0 .5em; letter-spacing: .005em; }
h1 { font-size: clamp(2rem, 4vw, 2.75rem); }
h2 { font-size: clamp(1.5rem, 2.6vw, 2rem); }
h3 { font-size: 1.25rem; }
p { margin: 0 0 1em; }
.wrap { max-width: var(--wrap); margin: 0 auto; padding: 0 16px; }
.mono { font-family: var(--mono); font-size: .8125rem; letter-spacing: .02em; }
.mute { color: var(--steel); }
.right { text-align: right; }
.nowrap { white-space: nowrap; }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }
.ico { width: 20px; height: 20px; flex: none; stroke: currentColor; fill: none; stroke-width: 1.7; stroke-linecap: round; stroke-linejoin: round; }
.eyebrow { font-family: var(--mono); font-size: .75rem; letter-spacing: .14em; text-transform: uppercase; color: var(--steel); display: flex; align-items: center; gap: 10px; margin-bottom: 12px; }
.eyebrow::before { content: ""; width: 22px; height: 3px; background: var(--signal); }
:focus-visible { outline: 3px solid var(--signal); outline-offset: 2px; }

/* 3 ─ Bileşenler */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 44px; padding: 0 20px; border: 2px solid var(--ink); border-radius: var(--radius); background: var(--ink); color: #fff; font: 600 .9375rem/1 var(--font); text-decoration: none; cursor: pointer; transition: background .15s, color .15s, border-color .15s; }
.btn:hover { background: var(--ink-3); border-color: var(--ink-3); }
.btn-signal { background: var(--signal); border-color: var(--signal); color: var(--signal-ink); }
.btn-signal:hover { background: var(--signal-2); border-color: var(--signal-2); }
.btn-ghost { background: transparent; color: var(--ink); }
.btn-ghost:hover { background: var(--ink); color: #fff; }
.btn-light { background: transparent; color: #fff; border-color: rgba(255,255,255,.5); }
.btn-light:hover { background: #fff; color: var(--ink); border-color: #fff; }
.btn-sm { min-height: 34px; padding: 0 12px; font-size: .8125rem; }
.btn-danger { background: var(--card); color: var(--bad); border-color: var(--bad); }
.btn-danger:hover { background: var(--bad); color: #fff; border-color: var(--bad); }
.btn-block { width: 100%; }
.btn[disabled] { opacity: .5; cursor: not-allowed; }

.field { display: flex; flex-direction: column; gap: 6px; margin-bottom: 14px; }
.field > span, .label { font-size: .8125rem; font-weight: 600; color: var(--ink-2); }
.input, .field input:not([type=checkbox]):not([type=radio]):not([type=file]), .field select, .field textarea {
  width: 100%; min-height: 44px; padding: 10px 12px; border: 1px solid #c9c4b9; border-radius: var(--radius);
  background: var(--card); font: inherit; color: var(--ink);
}
.field textarea { min-height: 110px; resize: vertical; }
.field input:focus, .field select:focus, .field textarea:focus, .input:focus { outline: none; border-color: var(--ink); box-shadow: 0 0 0 3px rgba(242,182,0,.35); }
.field small { color: var(--steel); font-size: .78rem; }
.check { display: flex; gap: 10px; align-items: flex-start; font-size: .9rem; margin-bottom: 12px; }
.check input { width: 18px; height: 18px; margin-top: 2px; accent-color: var(--ink); flex: none; }
.grid-2 { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 0 16px; }
.grid-3 { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 0 16px; }
.val { color: var(--bad); font-size: .8rem; }
.val:empty { display: none; }
.validation-summary-valid { display: none; }

.alert { padding: 12px 16px; border-left: 4px solid var(--ink); background: var(--card); margin-bottom: 16px; font-size: .9375rem; }
.alert-ok { border-color: var(--ok); background: var(--ok-bg); }
.alert-bad { border-color: var(--bad); background: var(--bad-bg); }
.alert-warn { border-color: var(--signal); background: var(--warn-bg); }
.alert ul { margin: 0; padding-left: 18px; }

.card { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 22px; }
.card + .card { margin-top: 16px; }
.card h2, .card h3 { margin-top: 0; }

.tag { display: inline-block; padding: 3px 8px; border-radius: 2px; font: 600 .72rem/1.3 var(--mono); letter-spacing: .04em; text-transform: uppercase; background: var(--line-2); color: var(--ink-2); white-space: nowrap; }
.tag-ok { background: var(--ok-bg); color: var(--ok); }
.tag-bad { background: var(--bad-bg); color: var(--bad); }
.tag-warn { background: var(--warn-bg); color: #7a5a00; }
.tag-ink { background: var(--ink); color: #fff; }

.table-wrap { overflow-x: auto; background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); }
table.t { width: 100%; border-collapse: collapse; font-size: .9rem; }
.t th { text-align: left; font: 600 .72rem/1.2 var(--mono); letter-spacing: .06em; text-transform: uppercase; color: var(--steel); padding: 11px 12px; border-bottom: 2px solid var(--ink); white-space: nowrap; background: var(--card); }
.t td { padding: 10px 12px; border-bottom: 1px solid var(--line-2); vertical-align: middle; }
.t tbody tr:hover td { background: #faf9f6; }
.t tfoot td { font-weight: 700; border-top: 2px solid var(--ink); border-bottom: 0; }
.t .num { text-align: right; font-variant-numeric: tabular-nums; white-space: nowrap; }
.t input, .t select { min-height: 38px; padding: 6px 8px; border: 1px solid #c9c4b9; border-radius: var(--radius); font: inherit; width: 100%; background: #fff; }
.empty { padding: 40px 16px; text-align: center; color: var(--steel); }

.qty { display: inline-flex; border: 1px solid #c9c4b9; border-radius: var(--radius); background: #fff; }
.qty button { width: 38px; border: 0; background: none; font-size: 1.1rem; cursor: pointer; color: var(--ink); }
.qty input { width: 46px; text-align: center; border: 0; border-left: 1px solid var(--line); border-right: 1px solid var(--line); font: 600 1rem var(--font); min-height: 40px; -moz-appearance: textfield; }
.qty input::-webkit-inner-spin-button { -webkit-appearance: none; }

.pager { display: flex; gap: 6px; justify-content: center; margin-top: 24px; flex-wrap: wrap; }
.pager a, .pager span { min-width: 40px; height: 40px; display: grid; place-items: center; border: 1px solid var(--line); background: var(--card); text-decoration: none; color: var(--ink); border-radius: var(--radius); font-weight: 600; }
.pager .on { background: var(--ink); color: #fff; border-color: var(--ink); }

/* 4 ─ Mağaza */
.topbar { background: var(--ink); color: #c6ccd2; font-size: .8125rem; }
.topbar .wrap { display: flex; gap: 22px; align-items: center; min-height: 36px; }
.topbar a { color: #fff; text-decoration: none; display: inline-flex; gap: 6px; align-items: center; }
.topbar .ico { width: 15px; height: 15px; }
.topbar .push { margin-left: auto; }
.impersonate { background: var(--signal); color: var(--signal-ink); font-size: .875rem; }
.main > .impersonate { margin: 0 -32px; }
.main > .impersonate .wrap { max-width: none; padding: 0 32px; }
.impersonate .wrap { display: flex; gap: 12px; align-items: center; min-height: 40px; flex-wrap: wrap; }
.impersonate button { background: var(--ink); color: #fff; border: 0; padding: 6px 12px; border-radius: 2px; cursor: pointer; font: 600 .8rem var(--font); }

.header { background: var(--card); border-bottom: 1px solid var(--line); position: sticky; top: 0; z-index: 20; }
.header .wrap { display: flex; align-items: center; gap: 28px; min-height: 72px; }
.brand { display: flex; align-items: center; gap: 10px; text-decoration: none; color: var(--ink); }
.brand-logo { display: block; height: 47px; width: auto; border-radius: 2px; }
.aside .brand small { margin-top: 8px; }
.brand small { display: block; font: 500 .62rem/1.2 var(--mono); letter-spacing: .16em; color: var(--steel); margin-top: 3px; }
.nav { display: flex; gap: 4px; }
.nav a { padding: 8px 12px; text-decoration: none; color: var(--ink-2); font-weight: 600; font-size: .9375rem; border-bottom: 3px solid transparent; }
.nav a:hover, .nav a.on { border-bottom-color: var(--signal); color: var(--ink); }
.search { flex: 1; max-width: 340px; margin-left: auto; position: relative; }
.search input { width: 100%; min-height: 42px; padding: 0 12px 0 38px; border: 1px solid #cfcabf; border-radius: var(--radius); background: var(--paper); font: inherit; }
.search .ico { position: absolute; left: 11px; top: 11px; color: var(--steel); }
.hicons { display: flex; gap: 4px; }
.hicon { position: relative; display: grid; place-items: center; width: 44px; height: 44px; color: var(--ink); text-decoration: none; border-radius: var(--radius); }
.hicon:hover { background: var(--paper); }
.hicon .ico { width: 23px; height: 23px; }
.badge { position: absolute; top: 3px; right: 1px; min-width: 19px; height: 19px; padding: 0 5px; background: var(--signal); color: var(--signal-ink); border-radius: 10px; font: 700 .7rem/19px var(--font); text-align: center; }
.menu-btn { display: none; }

/* Kahraman alanı: açık zemin, ince teknik çizim ızgarası, altta uyarı bandı (sarı-siyah şerit) */
.hero { background: var(--paper); color: var(--ink); position: relative; overflow: hidden; }
.hero::after { content: ""; position: absolute; inset: 0; background-image: linear-gradient(rgba(20,24,29,.055) 1px, transparent 1px), linear-gradient(90deg, rgba(20,24,29,.055) 1px, transparent 1px); background-size: 40px 40px; -webkit-mask-image: linear-gradient(90deg, transparent 0, #000 35%); mask-image: linear-gradient(90deg, transparent 0, #000 35%); pointer-events: none; }
.hero::before { content: ""; position: absolute; left: 0; right: 0; bottom: 0; height: 10px; background: repeating-linear-gradient(-45deg, var(--signal) 0 14px, var(--ink) 14px 28px); z-index: 2; }
.hero .wrap { display: grid; grid-template-columns: 1.25fr 1fr; gap: 56px; padding-top: 72px; padding-bottom: 88px; position: relative; z-index: 1; }
.hero .eyebrow { color: var(--steel); }
.hero h1 { font-size: clamp(2.4rem, 5.6vw, 4.4rem); text-transform: uppercase; letter-spacing: .01em; line-height: .98; margin-bottom: 22px; }
.hero h1 em { font-style: normal; background: linear-gradient(transparent 58%, var(--signal) 58%, var(--signal) 90%, transparent 90%); padding: 0 .06em; }
.hero p.lead { font-size: 1.125rem; color: var(--ink-3); max-width: 34em; margin-bottom: 30px; }
.hero .cta { display: flex; gap: 12px; flex-wrap: wrap; }
.hero .pledge { display: inline-flex; gap: 10px; align-items: center; margin-top: 26px; font-size: .92rem; color: var(--ink-2); text-decoration: none; }
.hero .pledge .ico { width: 34px; height: 34px; padding: 7px; background: var(--ink); color: var(--signal); border-radius: var(--radius); }
.hero .pledge b { display: block; }
.spec { border: 1px solid var(--line); border-top: 3px solid var(--ink); background: var(--card); align-self: center; }
.spec-head { display: flex; justify-content: space-between; padding: 12px 18px; border-bottom: 1px solid var(--line); font: 500 .7rem var(--mono); letter-spacing: .14em; color: var(--steel); text-transform: uppercase; }
.spec-head i { width: 8px; height: 8px; border-radius: 50%; background: #3fbf6a; display: inline-block; margin-right: 8px; box-shadow: 0 0 0 3px rgba(63,191,106,.2); }
.spec a { display: grid; grid-template-columns: 44px 1fr auto; gap: 12px; align-items: center; padding: 14px 18px; border-bottom: 1px solid var(--line-2); text-decoration: none; color: var(--ink); transition: background .15s; }
.spec a:last-child { border-bottom: 0; }
.spec a:hover { background: var(--paper); }
.spec a:hover .arrow { transform: translateX(3px); }
.spec .arrow { color: var(--steel); transition: transform .15s; }
.spec .no { font: 500 .74rem var(--mono); background: var(--signal); color: var(--signal-ink); padding: 3px 6px; justify-self: start; border-radius: 2px; }
.spec b { font: 600 1.06rem/1.2 var(--font); display: block; }
.spec small { color: var(--steel); font-size: .8rem; }
.arrow { color: #5d6874; transition: transform .15s, color .15s; }

.strip { background: var(--signal); color: var(--signal-ink); }
.strip .wrap { display: grid; grid-template-columns: repeat(4, 1fr); }
.strip div { padding: 16px 18px; display: flex; gap: 12px; align-items: center; font-weight: 600; font-size: .9375rem; border-right: 1px solid rgba(27,22,0,.15); }
.strip div:last-child { border-right: 0; }

.section { padding: 72px 0; }
.section-head { display: flex; justify-content: space-between; align-items: flex-end; gap: 20px; margin-bottom: 28px; flex-wrap: wrap; }
.section-head h2 { margin: 0; }
.section-alt { background: var(--card); border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }

.cats { display: grid; grid-template-columns: repeat(5, 1fr); border-top: 1px solid var(--line); border-left: 1px solid var(--line); }
.cats a { border-right: 1px solid var(--line); border-bottom: 1px solid var(--line); background: var(--card); padding: 22px 18px; text-decoration: none; color: var(--ink); display: flex; flex-direction: column; gap: 22px; min-height: 140px; transition: background .15s; }
.cats a:hover { background: var(--ink); color: #fff; }
.cats a:hover .ico { color: var(--signal); }
.cats .ico { width: 30px; height: 30px; stroke-width: 1.5; }
.cats b { font: 600 1.02rem/1.2 var(--font); margin-top: auto; }
.cats small { font: 500 .7rem var(--mono); color: var(--mute); letter-spacing: .06em; }

.products { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 16px; }
.pcard { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); display: flex; flex-direction: column; transition: border-color .15s, transform .15s; }
.pcard:hover { border-color: var(--ink); }
.pcard .img { aspect-ratio: 4/3; background: #eeece6; display: grid; place-items: center; overflow: hidden; border-bottom: 1px solid var(--line-2); position: relative; }
.pcard .img img { width: 100%; height: 100%; object-fit: contain; padding: 14px; }
.pcard .img .ico { width: 54px; height: 54px; color: #b9b4a8; stroke-width: 1.2; }
.pcard .img .tag { position: absolute; top: 10px; left: 10px; }
.pcard .body { padding: 14px 16px 16px; display: flex; flex-direction: column; gap: 6px; flex: 1; }
.pcard .brandline { font: 500 .7rem var(--mono); letter-spacing: .08em; color: var(--steel); text-transform: uppercase; }
.pcard a.name { color: var(--ink); text-decoration: none; font-weight: 600; line-height: 1.3; }
.pcard a.name:hover { text-decoration: underline; }
.pcard form { margin-top: 10px; }

.steps { display: grid; grid-template-columns: repeat(4, 1fr); gap: 0; counter-reset: s; border-top: 3px solid var(--ink); }
.steps div { padding: 22px 22px 0 0; }
.steps div::before { counter-increment: s; content: "0" counter(s); font: 500 .8rem var(--mono); color: var(--steel); display: block; margin-bottom: 14px; }
.steps b { font: 700 1.25rem var(--font-cond); display: block; margin-bottom: 6px; }
.steps p { color: var(--steel); font-size: .9375rem; }

.band { background: var(--ink); color: #fff; }
.band .wrap { display: grid; grid-template-columns: 1fr auto; gap: 24px; align-items: center; padding-top: 44px; padding-bottom: 44px; }
.band h2 { margin: 0 0 6px; }
.band p { margin: 0; color: #b6bec6; }

.page-head { background: var(--card); border-bottom: 1px solid var(--line); padding: 34px 0 26px; }
.page-head h1 { margin: 0; }
.crumbs { font: 500 .75rem var(--mono); letter-spacing: .04em; color: var(--steel); margin-bottom: 10px; }
.crumbs a { color: var(--steel); text-decoration: none; }
.crumbs a:hover { color: var(--ink); }

.shop { display: grid; grid-template-columns: 240px 1fr; gap: 32px; padding-top: 32px; padding-bottom: 72px; }
.side h3 { font: 600 .72rem var(--mono); letter-spacing: .12em; text-transform: uppercase; color: var(--steel); margin: 0 0 10px; }
.side a { display: flex; justify-content: space-between; padding: 9px 12px; color: var(--ink); text-decoration: none; border-left: 3px solid transparent; font-size: .9375rem; }
.side a:hover { background: var(--card); }
.side a.on { border-left-color: var(--signal); background: var(--card); font-weight: 600; }
.side a span { color: var(--mute); font: 500 .75rem var(--mono); }
.toolbar { display: flex; justify-content: space-between; align-items: center; gap: 12px; margin-bottom: 16px; flex-wrap: wrap; }
.toolbar select { min-height: 40px; border: 1px solid #c9c4b9; border-radius: var(--radius); padding: 0 10px; font: inherit; background: #fff; }
.shop .products { grid-template-columns: repeat(3, minmax(0, 1fr)); }

.pd { display: grid; grid-template-columns: 1.1fr 1fr; gap: 48px; padding-top: 36px; padding-bottom: 72px; }
.pd-img { background: var(--card); border: 1px solid var(--line); aspect-ratio: 1; display: grid; place-items: center; }
.pd-img img { width: 100%; height: 100%; object-fit: contain; padding: 28px; }
.pd-img .ico { width: 96px; height: 96px; color: #c3beb2; stroke-width: 1; }
.pd h1 { font-size: clamp(1.8rem, 3.4vw, 2.5rem); }
.pd .buy { display: flex; gap: 12px; margin: 22px 0; flex-wrap: wrap; }
.specs { border-top: 1px solid var(--line); margin: 20px 0; }
.specs div { display: grid; grid-template-columns: 130px 1fr; padding: 10px 0; border-bottom: 1px solid var(--line); font-size: .9375rem; }
.specs dt, .specs span:first-child { font: 500 .75rem var(--mono); color: var(--steel); letter-spacing: .06em; text-transform: uppercase; padding-top: 2px; }
.assure { display: grid; gap: 10px; margin-top: 20px; font-size: .9rem; color: var(--ink-2); }
.assure div { display: flex; gap: 10px; align-items: center; }
.assure .ico { color: var(--ok); }
.desc { white-space: pre-line; }

.cart-line { display: grid; grid-template-columns: 84px 1fr auto auto; gap: 16px; align-items: center; padding: 16px; border-bottom: 1px solid var(--line-2); }
.cart-line:last-child { border-bottom: 0; }
.cart-line .thumb { width: 84px; height: 84px; background: #eeece6; display: grid; place-items: center; }
.cart-line .thumb img { width: 100%; height: 100%; object-fit: contain; padding: 6px; }
.cart-line .thumb .ico { color: #b9b4a8; width: 32px; height: 32px; }
.summary .row { display: flex; justify-content: space-between; padding: 8px 0; font-size: .9375rem; }
.summary .row.total { border-top: 2px solid var(--ink); margin-top: 8px; padding-top: 14px; font-weight: 700; font-size: 1.15rem; }
/* Teklif listesi: montaj önerisi, 7/24 destek kutusu, ürün sayfası montaj seçeneği */
.svc-offer { display: grid; grid-template-columns: 44px minmax(0, 1fr) auto; gap: 14px; align-items: center; background: var(--card); border: 1px solid var(--line); padding: 14px 16px; margin-bottom: 10px; }
.svc-offer > .ico { width: 44px; height: 44px; padding: 10px; background: var(--ink); color: var(--signal); border-radius: var(--radius); }
.svc-offer b { display: block; }
.svc-offer small { color: var(--steel); display: block; margin-top: 2px; }
.support { background: var(--ink); color: #c6ccd2; padding: 18px; margin-top: 14px; border-radius: var(--radius); }
.support .eyebrow { color: var(--signal); }
.support b { color: #fff; font: 700 1.25rem var(--font-cond); letter-spacing: .02em; display: block; margin: 4px 0; }
.support p { margin: 0 0 12px; font-size: .88rem; }
.support .actions { gap: 8px; }
.pd .buy + .addon, .pd form > .addon { margin: -8px 0 22px; }
.addon { display: flex; gap: 10px; align-items: flex-start; border: 1px dashed var(--signal); background: var(--warn-bg); padding: 12px 14px; margin: 14px 0 0; font-size: .92rem; }
.addon input { margin-top: 3px; width: 18px; height: 18px; accent-color: var(--ink); flex: none; }
.addon small { display: block; color: var(--steel); }


.auth { max-width: 440px; margin: 48px auto 80px; }
.legal { max-width: 820px; padding-top: 36px; padding-bottom: 72px; }
.legal h2 { font-size: 1.35rem; margin-top: 1.6em; }

.services { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; }
.service { background: var(--card); border: 1px solid var(--line); padding: 24px; border-top: 3px solid var(--ink); }
.service .ico { width: 32px; height: 32px; margin-bottom: 16px; stroke-width: 1.5; }
.service ul { padding-left: 18px; margin: 10px 0 0; color: var(--steel); font-size: .9375rem; }

.footer { background: var(--ink); color: #aab3bc; font-size: .9rem; padding: 56px 0 0; }
.footer .cols { display: grid; grid-template-columns: 1.6fr 1fr 1fr; gap: 32px; padding-bottom: 40px; }
.footer h4 { font: 600 .72rem var(--mono); letter-spacing: .14em; text-transform: uppercase; color: #fff; margin-bottom: 14px; }
.footer a { color: #d5dadf; text-decoration: none; display: block; padding: 3px 0; }
.footer a:hover { color: var(--signal); }
.footer .brand { color: #fff; }
.footer .legalbar { border-top: 1px solid var(--ink-3); padding: 18px 0; display: flex; justify-content: space-between; gap: 16px; flex-wrap: wrap; font-size: .8rem; }

.wa { position: fixed; right: 18px; bottom: 18px; width: 54px; height: 54px; border-radius: 50%; background: #1f9d55; color: #fff; display: grid; place-items: center; box-shadow: 0 6px 18px rgba(0,0,0,.2); z-index: 30; }
.wa .ico { width: 28px; height: 28px; }

/* Galeri: kare beyaz döşeme (görsel boyutları değişken, orantı korunur), altında açıklama + mono kategori etiketi */
.gallery { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 18px 16px; }
.gallery figure { margin: 0; min-width: 0; }
.gallery a { position: relative; display: block; aspect-ratio: 1; background: #fff; border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; transition: border-color .15s; }
.gallery a::after { content: ""; position: absolute; left: 0; right: 0; bottom: 0; height: 3px; background: var(--signal); transform: scaleX(0); transform-origin: left; transition: transform .2s; }
.gallery a:hover, .gallery a:focus-visible { border-color: var(--ink); }
.gallery a:hover::after, .gallery a:focus-visible::after { transform: scaleX(1); }
.gallery a img { width: 100%; height: 100%; object-fit: contain; padding: 12px; }
.gallery figcaption { display: flex; justify-content: space-between; align-items: flex-start; gap: 10px; margin-top: 8px; font-size: .875rem; line-height: 1.35; color: var(--ink-2); }
.gallery figcaption span { min-width: 0; }
.gallery figcaption small { flex: none; font: 500 .66rem/1.6 var(--mono); letter-spacing: .08em; text-transform: uppercase; color: var(--mute); }
.gallery-page { padding-top: 24px; }
.gallery-tabs { margin-bottom: 32px; scrollbar-width: thin; }
.gallery-tabs a span { font: 500 .72rem var(--mono); color: var(--mute); margin-left: 4px; }
.gallery-tabs a.on span { color: var(--steel); }
.gallery-group + .gallery-group { margin-top: 56px; padding-top: 40px; border-top: 1px solid var(--line); }
.gallery-head { margin-bottom: 22px; }
.gallery-head p { margin: 6px 0 0; max-width: 60em; }
.gallery-head .actions a:not(.btn) { font-weight: 600; }
.gallery-title { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; margin-bottom: 8px; }
.gallery-title .ico { width: 30px; height: 30px; stroke-width: 1.5; color: var(--ink); }
.gallery-title h2 { margin: 0; }
.gallery-intro { max-width: 60em; margin-bottom: 24px; }
.gallery-more { margin: 18px 0 0; }
.gallery-empty { display: grid; grid-template-columns: 56px minmax(0, 1fr); gap: 20px; border-top: 3px solid var(--ink); }
.gallery-empty > .ico { width: 56px; height: 56px; padding: 13px; background: var(--ink); color: var(--signal); border-radius: var(--radius); stroke-width: 1.5; }
.gallery-empty h3 { margin: 0 0 8px; }
.gallery-empty p { max-width: 60em; }
.gallery-empty ul { padding-left: 18px; margin: 0 0 20px; color: var(--steel); font-size: .9375rem; }

/* Büyütme penceresi: tam ekran <dialog>, koyu zemin; görselin üstünde sarı çizgi, köşeler düz */
.lightbox { position: fixed; inset: 0; width: 100%; height: 100%; max-width: none; max-height: none; margin: 0; padding: 0; border: 0; background: transparent; color: #fff; overflow: hidden; }
.lightbox[open] { display: grid; grid-template-rows: auto minmax(0, 1fr); }
.lightbox::backdrop { background: rgba(20, 24, 29, .93); }
.lightbox-bar { display: flex; justify-content: space-between; align-items: center; gap: 12px; padding: 12px 16px; font: 500 .8rem var(--mono); letter-spacing: .1em; color: #c6ccd2; pointer-events: none; }
.lightbox-fig { margin: 0; min-height: 0; display: grid; grid-template-rows: minmax(0, 1fr) auto; justify-items: center; align-items: center; gap: 14px; padding: 0 72px 20px; pointer-events: none; }
.lightbox-fig img { max-width: 100%; max-height: 100%; width: auto; height: auto; object-fit: contain; background: #fff; border-top: 3px solid var(--signal); pointer-events: auto; }
.lightbox-fig figcaption { font-size: .9375rem; color: #e6e9ec; text-align: center; max-width: 60ch; padding: 0 8px; }
.lightbox-btn { pointer-events: auto; display: grid; place-items: center; width: 48px; height: 48px; border: 2px solid rgba(255, 255, 255, .55); border-radius: var(--radius); background: rgba(20, 24, 29, .6); color: #fff; cursor: pointer; transition: background .15s, color .15s, border-color .15s; }
.lightbox-btn:hover { background: var(--signal); border-color: var(--signal); color: var(--signal-ink); }
.lightbox-btn:focus-visible { outline-color: var(--signal); }
.lightbox-btn .ico { width: 22px; height: 22px; }
.lightbox-prev, .lightbox-next { position: absolute; top: 50%; transform: translateY(-50%); }
.lightbox-prev { left: 12px; }
.lightbox-prev .ico { transform: scaleX(-1); }
.lightbox-next { right: 12px; }
@media (prefers-reduced-motion: reduce) {
  .gallery a, .gallery a::after, .lightbox-btn { transition: none; }
}

/* 5 ─ Panel */
.admin { display: grid; grid-template-columns: 244px minmax(0, 1fr); min-height: 100vh; }
.aside { background: var(--ink); color: #c6ccd2; padding: 20px 0; position: sticky; top: 0; height: 100vh; overflow-y: auto; }
.aside .brand { color: #fff; padding: 0 20px 20px; border-bottom: 1px solid var(--ink-3); margin-bottom: 10px; }
.aside .brand small { color: #8f99a3; }
.aside a { display: flex; align-items: center; gap: 12px; padding: 9px 20px; color: #d5dadf; text-decoration: none; font-size: .9375rem; border-left: 3px solid transparent; }
.aside a:hover { background: var(--ink-2); color: #fff; }
.aside a.on { border-left-color: var(--signal); background: var(--ink-2); color: #fff; font-weight: 600; }
.aside a .ico { width: 18px; height: 18px; color: #8f99a3; }
.aside a.on .ico { color: var(--signal); }
.aside .count { margin-left: auto; background: var(--signal); color: var(--signal-ink); font: 700 .7rem/18px var(--font); padding: 0 6px; border-radius: 9px; }
.main { padding: 0 32px 48px; min-width: 0; }
.abar { display: flex; align-items: center; gap: 16px; min-height: 64px; border-bottom: 1px solid var(--line); margin: 0 -32px 28px; padding: 0 32px; background: var(--card); position: sticky; top: 0; z-index: 10; }
.abar h1 { font-size: 1.5rem; margin: 0; }
.abar .push { margin-left: auto; display: flex; gap: 10px; align-items: center; font-size: .875rem; }
.stats { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 16px; margin-bottom: 24px; }
.stat { background: var(--card); border: 1px solid var(--line); padding: 18px 20px; border-radius: var(--radius); }
.stat small { font: 500 .7rem var(--mono); letter-spacing: .1em; text-transform: uppercase; color: var(--steel); display: block; }
.stat b { font: 700 1.9rem/1.2 var(--font-cond); display: block; margin-top: 6px; font-variant-numeric: tabular-nums; }
.stat.pos b { color: var(--ok); }
.stat.neg b { color: var(--bad); }
.stat em { font-style: normal; font-size: .8rem; color: var(--steel); }
.filters { display: flex; gap: 10px; flex-wrap: wrap; margin-bottom: 16px; align-items: flex-end; }
.filters .field { margin: 0; }
.filters .field input, .filters .field select { min-height: 40px; }
.tabs { display: flex; gap: 0; border-bottom: 1px solid var(--line); margin-bottom: 18px; overflow-x: auto; }
.tabs a { padding: 10px 16px; text-decoration: none; color: var(--steel); font-weight: 600; font-size: .9rem; border-bottom: 3px solid transparent; white-space: nowrap; }
.tabs a.on { color: var(--ink); border-bottom-color: var(--signal); }
.tabs.subnav { margin-top: -16px; border-bottom-color: var(--ink); }
.tabs.subnav a { font-size: .95rem; }
.cols-2 { display: grid; grid-template-columns: minmax(0, 2fr) minmax(0, 1fr); gap: 20px; align-items: start; }
.actions { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; }
.kv { display: grid; grid-template-columns: 140px 1fr; gap: 8px 12px; font-size: .9375rem; margin: 0; }
.kv dt { color: var(--steel); font-size: .85rem; }
.kv dd { margin: 0; }
.scan { border: 2px dashed #bdb7aa; border-radius: var(--radius); padding: 28px; text-align: center; background: #faf9f6; cursor: pointer; display: block; }
.scan .ico { width: 40px; height: 40px; margin: 0 auto 10px; display: block; }
.scan input { display: none; }
.scan-preview { max-height: 420px; object-fit: contain; margin: 0 auto 14px; border: 1px solid var(--line); background: #fff; }
.spinner { width: 18px; height: 18px; border: 2px solid currentColor; border-right-color: transparent; border-radius: 50%; animation: spin .7s linear infinite; display: inline-block; }
@keyframes spin { to { transform: rotate(360deg); } }
.bar { height: 8px; background: var(--line-2); border-radius: 4px; overflow: hidden; min-width: 60px; }
.bar i { display: block; height: 100%; background: var(--ink); }
.amount-pos { color: var(--ok); font-weight: 600; }
.amount-neg { color: var(--bad); font-weight: 600; }

/* Duyarlı */
@media (max-width: 1080px) {
  .products { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .cats { grid-template-columns: repeat(3, 1fr); }
  .stats { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .nav a { padding: 8px 8px; }
  .gallery { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}
@media (max-width: 900px) {
  .header .wrap { flex-wrap: wrap; gap: 10px; min-height: 64px; padding-top: 8px; padding-bottom: 8px; }
  .menu-btn { display: grid; }
  .nav { display: none; order: 4; width: 100%; flex-direction: column; padding-bottom: 8px; }
  .nav.open { display: flex; }
  .nav a { border-bottom: 1px solid var(--line-2); padding: 12px 4px; }
  .search { order: 5; max-width: none; width: 100%; flex-basis: 100%; margin: 0; }
  .hicons { margin-left: auto; }
  .main > .impersonate { margin: 0 -16px; }
  .main > .impersonate .wrap { padding: 0 16px; }
  .hero .wrap, .pd, .cols-2 { grid-template-columns: minmax(0, 1fr) !important; gap: 28px; }
  .hero .wrap { padding-top: 40px; padding-bottom: 58px; }
  .strip .wrap { grid-template-columns: 1fr 1fr; }
  .strip div:nth-child(2) { border-right: 0; }
  .shop { grid-template-columns: minmax(0, 1fr); gap: 16px; }
  .side { display: flex; gap: 6px; overflow-x: auto; padding-bottom: 4px; }
  .side h3 { display: none; }
  .side a { white-space: nowrap; border: 1px solid var(--line); background: var(--card); border-radius: var(--radius); }
  .side a.on { border-color: var(--ink); }
  .side a span { display: none; }
  .steps, .services { grid-template-columns: 1fr 1fr; gap: 16px; }
  .footer .cols { grid-template-columns: 1fr 1fr; }
  .summary { position: static; }
  .admin { grid-template-columns: minmax(0, 1fr); }
  .aside { position: static; height: auto; display: flex; overflow-x: auto; padding: 0; gap: 0; }
  .aside .brand { display: none; }
  .aside a { white-space: nowrap; border-left: 0; border-bottom: 3px solid transparent; padding: 14px 14px; }
  .aside a.on { border-bottom-color: var(--signal); }
  .main { padding: 0 16px 40px; }
  .abar { margin: 0 -16px 20px; padding: 0 16px; position: static; flex-wrap: wrap; min-height: 56px; }
  .band .wrap { grid-template-columns: 1fr; }
}
@media (max-width: 600px) {
  .products, .shop .products { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
  .pcard .body { padding: 10px 12px 12px; }
  .cats { grid-template-columns: repeat(2, 1fr); }
  .cats a { min-height: 112px; padding: 16px 14px; }
  .grid-2, .grid-3 { grid-template-columns: 1fr; }
  .steps, .services, .footer .cols { grid-template-columns: 1fr; }
  .strip .wrap { grid-template-columns: 1fr; }
  .strip div { border-right: 0; border-bottom: 1px solid rgba(27,22,0,.15); padding: 11px 0; }
  .topbar .hide-sm { display: none; }
  .section { padding: 48px 0; }
  .cart-line { grid-template-columns: 64px 1fr; }
  .cart-line .thumb { width: 64px; height: 64px; }
  .cart-line .qty-col, .cart-line .sum-col { grid-column: 2; }
  .svc-offer { grid-template-columns: 36px minmax(0, 1fr); }
  .svc-offer > .ico { width: 36px; height: 36px; padding: 7px; }
  .svc-offer form { grid-column: 2; text-align: left; }
  .stats { gap: 10px; }
  .stat { padding: 14px; }
  .stat b { font-size: 1.45rem; }
  .kv { grid-template-columns: 110px 1fr; }
  .brand small { display: none; }
  .gallery { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px 10px; }
  .gallery-page { padding-top: 20px; }
  .gallery-tabs { margin-bottom: 24px; }
  .gallery a img { padding: 8px; }
  .gallery figcaption { flex-direction: column; gap: 2px; font-size: .8125rem; }
  .gallery-group + .gallery-group { margin-top: 40px; padding-top: 32px; }
  .gallery-empty { grid-template-columns: minmax(0, 1fr); gap: 14px; }
  .gallery-empty > .ico { width: 44px; height: 44px; padding: 10px; }
  .lightbox-fig { padding: 0 12px 76px; }
  .lightbox-btn { width: 44px; height: 44px; }
  .lightbox-prev, .lightbox-next { top: auto; bottom: 16px; transform: none; }
  .lightbox-prev { left: 16px; }
  .lightbox-next { right: 16px; }
}

/* 6 ─ Yazdırma (fatura çıktısı) */
.print-doc { max-width: 820px; margin: 24px auto; background: #fff; padding: 40px; border: 1px solid var(--line); }
.print-doc .t th { background: #fff; }
.print-doc .head { display: flex; justify-content: space-between; gap: 24px; border-bottom: 3px solid var(--ink); padding-bottom: 18px; margin-bottom: 18px; }
@media (max-width: 600px) { .print-doc { margin: 0; padding: 16px; border: 0; } .print-doc .head { flex-direction: column; } .print-doc .head .right { text-align: left; } }
@media print {
  body { background: #fff; }
  .no-print, .aside, .abar { display: none !important; }
  .admin { display: block; }
  .main { padding: 0; }
  .print-doc { border: 0; margin: 0; padding: 0; max-width: none; }
}

/* 7 ─ Teklif: panel düzenleyici, müşteri teklif sayfası, mobil kalem kartları */
.count { display: inline-block; background: var(--signal); color: var(--signal-ink); font: 700 .7rem/18px var(--font); padding: 0 6px; border-radius: 9px; vertical-align: middle; }
.count.ok, .aside .count.ok { background: var(--ok); color: #fff; }
.btn-wa { background: #1fa855; border-color: #1fa855; color: #fff; }
.btn-wa:hover { background: #178a45; border-color: #178a45; }
.share-btns { display: grid; gap: 8px; }
.share-btns form { margin: 0; }
.timeline { list-style: none; margin: 0; padding: 0; }
.timeline li { position: relative; padding: 0 0 14px 26px; }
.timeline li::before { content: ""; position: absolute; left: 4px; top: 4px; width: 12px; height: 12px; border-radius: 50%; border: 2px solid var(--line); background: var(--card); }
.timeline li::after { content: ""; position: absolute; left: 10px; top: 18px; bottom: 0; width: 2px; background: var(--line-2); }
.timeline li:last-child::after { display: none; }
.timeline li.done::before { border-color: var(--ink); background: var(--ink); }
.timeline li.ok::before { border-color: var(--ok); background: var(--ok); }
.timeline li.bad::before { border-color: var(--bad); background: var(--bad); }
.timeline b { display: block; font-size: .95rem; }
.timeline small { color: var(--steel); font-size: .82rem; }
.alert-list { display: grid; gap: 8px; margin-bottom: 18px; }
.alert-list .alert { display: flex; gap: 12px; align-items: center; flex-wrap: wrap; margin: 0; }
.alert-list .alert > .btn { margin-left: auto; }

.offer-body { background: var(--paper); }
.offer-doc { max-width: 880px; margin: 28px auto 48px; background: var(--card); border: 1px solid var(--line); border-top: 4px solid var(--signal); padding: 36px 40px; }
.offer-head { display: flex; justify-content: space-between; gap: 24px; align-items: flex-start; padding-bottom: 22px; border-bottom: 2px solid var(--ink); flex-wrap: wrap; }
.offer-brand { display: flex; gap: 12px; align-items: center; }
.offer-brand img { max-height: 64px; max-width: 240px; object-fit: contain; }
.offer-firm { display: grid; gap: 2px; text-align: right; font-size: .85rem; color: var(--steel); }
.offer-firm b { color: var(--ink); font-size: .95rem; }
.offer-firm a { color: inherit; }
.offer-title { display: flex; justify-content: space-between; gap: 24px; align-items: flex-end; margin: 26px 0 18px; flex-wrap: wrap; }
.offer-title h1 { font-size: clamp(1.6rem, 4vw, 2.3rem); margin: 4px 0 0; }
.offer-meta { grid-template-columns: auto auto; font-size: .9rem; }
.offer-to { display: grid; gap: 2px; background: var(--paper); border-left: 3px solid var(--ink); padding: 12px 16px; margin-bottom: 18px; }
.offer-to small { color: var(--steel); font-size: .8rem; }
.offer-to b { font-size: 1.1rem; }
.offer-lines { margin-bottom: 0; }
.offer-totals { position: static; max-width: 360px; margin: 12px 0 0 auto; }
.offer-note { margin-top: 26px; padding-top: 18px; border-top: 1px solid var(--line); }
.offer-note h3 { font-size: 1rem; margin: 0 0 8px; }
.offer-respond { margin-top: 26px; }
.offer-approve { border: 2px solid var(--ink); margin: 0; }
.offer-change { margin-top: 12px; }
.offer-change summary { cursor: pointer; font-weight: 600; padding: 8px 0; }
.offer-stamp { display: flex; gap: 14px; align-items: center; border: 2px solid var(--line); padding: 16px; border-radius: var(--radius); }
.offer-stamp .ico { width: 34px; height: 34px; flex: none; }
.offer-stamp b { display: block; font-size: 1.1rem; }
.offer-stamp span { color: var(--steel); }
.offer-stamp.ok { border-color: var(--ok); background: var(--ok-bg); }
.offer-stamp.ok .ico { color: var(--ok); }
.offer-foot { margin-top: 28px; padding-top: 14px; border-top: 1px solid var(--line); font-size: .78rem; color: var(--steel); }

@media (max-width: 600px) {
  .offer-doc { margin: 0; border-left: 0; border-right: 0; padding: 22px 16px; }
  .offer-firm { text-align: left; }
  /* Kalem tablosu telefonda kart: her satır alt alta etiketli alanlar */
  .lines-t, .lines-t tbody, .lines-t tr, .lines-t td { display: block; width: 100%; }
  .lines-t { min-width: 0 !important; }
  .lines-t thead { display: none; }
  .lines-t tr { display: grid; grid-template-columns: 1fr 1fr; gap: 8px 10px; border: 1px solid var(--line); padding: 12px; margin-bottom: 10px; position: relative; }
  .lines-t td { border: 0; padding: 0; }
  .lines-t td[data-label="Açıklama"] { grid-column: 1 / -1; padding-right: 36px; }
  .lines-t td[data-label]::before { content: attr(data-label); display: block; font-size: .72rem; color: var(--steel); margin-bottom: 3px; }
  .lines-t td[data-out] { align-self: end; font-weight: 700; text-align: right; }
  .lines-t td:last-child { position: absolute; top: 6px; right: 6px; width: auto; }
  .offer-admin .share-btns .btn { min-height: 48px; }
  .lines-t input, .lines-t select { width: 100%; }
  .abar-user { display: none; }
  /* Müşteri teklif sayfası: kalemler telefonda kart */
  .offer-lines { border: 0; overflow: visible; }
  .offer-t, .offer-t tbody, .offer-t tr { display: block; }
  .offer-t thead { display: none; }
  .offer-t tr { display: grid; grid-template-columns: repeat(3, auto); justify-content: space-between; gap: 2px 12px; padding: 12px 0; border-bottom: 1px solid var(--line); }
  .offer-t td { border: 0; padding: 0; text-align: left; }
  .offer-t td:first-child { display: none; }
  .offer-t td.d { grid-column: 1 / -1; font-weight: 600; margin-bottom: 4px; }
  .offer-t td[data-label]::before { content: attr(data-label); display: block; font-size: .72rem; color: var(--steel); }
  .offer-t td.tot { grid-column: 1 / -1; text-align: right; font-weight: 700; }
  .offer-t td.tot::before { display: inline; margin-right: 6px; }
  .offer-totals { max-width: none; }
}
@media print {
  .offer-body { background: #fff; }
  .offer-doc { border: 0; margin: 0; padding: 0; max-width: none; }
}
