@font-face{font-family:"IBM Plex Sans";font-style:normal;font-weight:400;font-display:swap;src:url(/fonts/plex-latin-ext-400.woff2) format("woff2");unicode-range:U+0100-02BA,U+02BD-02C5,U+02C7-02CC,U+02CE-02D7,U+02DD-02FF,U+1E00-1E9F,U+1EF2-1EFF,U+2020,U+20A0-20AB,U+20AD-20C0,U+2113,U+2C60-2C7F,U+A720-A7FF}
@font-face{font-family:"IBM Plex Sans";font-style:normal;font-weight:400;font-display:swap;src:url(/fonts/plex-latin-400.woff2) format("woff2");unicode-range:U+0000-00FF,U+0131,U+0152-0153,U+02BB-02BC,U+02C6,U+02DA,U+02DC,U+0304,U+0308,U+0329,U+2000-206F,U+20AC,U+2122,U+2191,U+2193,U+2212,U+2215,U+FEFF,U+FFFD}
@font-face{font-family:"IBM Plex Sans";font-style:normal;font-weight:500;font-display:swap;src:url(/fonts/plex-latin-ext-500.woff2) format("woff2");unicode-range:U+0100-02BA,U+02BD-02C5,U+02C7-02CC,U+02CE-02D7,U+02DD-02FF,U+1E00-1E9F,U+1EF2-1EFF,U+2020,U+20A0-20AB,U+20AD-20C0,U+2113,U+2C60-2C7F,U+A720-A7FF}
@font-face{font-family:"IBM Plex Sans";font-style:normal;font-weight:500;font-display:swap;src:url(/fonts/plex-latin-500.woff2) format("woff2");unicode-range:U+0000-00FF,U+0131,U+0152-0153,U+02BB-02BC,U+02C6,U+02DA,U+02DC,U+0304,U+0308,U+0329,U+2000-206F,U+20AC,U+2122,U+2191,U+2193,U+2212,U+2215,U+FEFF,U+FFFD}
@font-face{font-family:"IBM Plex Sans";font-style:normal;font-weight:600;font-display:swap;src:url(/fonts/plex-latin-ext-600.woff2) format("woff2");unicode-range:U+0100-02BA,U+02BD-02C5,U+02C7-02CC,U+02CE-02D7,U+02DD-02FF,U+1E00-1E9F,U+1EF2-1EFF,U+2020,U+20A0-20AB,U+20AD-20C0,U+2113,U+2C60-2C7F,U+A720-A7FF}
@font-face{font-family:"IBM Plex Sans";font-style:normal;font-weight:600;font-display:swap;src:url(/fonts/plex-latin-600.woff2) format("woff2");unicode-range:U+0000-00FF,U+0131,U+0152-0153,U+02BB-02BC,U+02C6,U+02DA,U+02DC,U+0304,U+0308,U+0329,U+2000-206F,U+20AC,U+2122,U+2191,U+2193,U+2212,U+2215,U+FEFF,U+FFFD}
@font-face{font-family:"IBM Plex Sans";font-style:normal;font-weight:700;font-display:swap;src:url(/fonts/plex-latin-ext-700.woff2) format("woff2");unicode-range:U+0100-02BA,U+02BD-02C5,U+02C7-02CC,U+02CE-02D7,U+02DD-02FF,U+1E00-1E9F,U+1EF2-1EFF,U+2020,U+20A0-20AB,U+20AD-20C0,U+2113,U+2C60-2C7F,U+A720-A7FF}
@font-face{font-family:"IBM Plex Sans";font-style:normal;font-weight:700;font-display:swap;src:url(/fonts/plex-latin-700.woff2) format("woff2");unicode-range:U+0000-00FF,U+0131,U+0152-0153,U+02BB-02BC,U+02C6,U+02DA,U+02DC,U+0304,U+0308,U+0329,U+2000-206F,U+20AC,U+2122,U+2191,U+2193,U+2212,U+2215,U+FEFF,U+FFFD}

/* Tokens. --brand and --brand-ink come from the firm's colour, set per page. */
:root {
    --brand: #1d4ed8;
    --brand-ink: #fff;
    --brand-soft: color-mix(in srgb, var(--brand) 8%, #fff);
    --brand-line: color-mix(in srgb, var(--brand) 28%, #fff);
    --shell: #0e1a2b;
    --shell-2: #17263c;
    --shell-line: rgba(255, 255, 255, .09);
    --shell-text: #c5cfdd;
    --shell-dim: #8795a8;
    --bg: #f4f6f9;
    --surface: #fff;
    --surface-2: #f8f9fb;
    --line: #e2e7ee;
    --line-2: #cbd3de;
    --text: #131f30;
    --text-2: #46546a;
    --text-3: #627085;
    --ok: #0b7a4b;
    --ok-soft: #e6f4ee;
    --warn: #9a5b00;
    --warn-soft: #fdf3e1;
    --bad: #b42318;
    --bad-soft: #fdecea;
    --radius: 10px;
    --radius-sm: 7px;
    --shadow: 0 1px 2px rgba(14, 26, 43, .05);
    --shadow-lg: 0 12px 32px rgba(14, 26, 43, .14);
    --side: 256px;
}

.theme-kurumsal { --shell: #0b2545; --shell-2: #13315c; }
.theme-sanayi { --shell: #1c1f23; --shell-2: #2a2e34; }
.theme-atlas { --shell: #0c2b33; --shell-2: #14404b; }
.theme-okyanus { --shell: #06283d; --shell-2: #0d3b57; }
.theme-toprak { --shell: #2b211a; --shell-2: #3d2f25; }
.theme-sade { --shell: #fff; --shell-2: #f1f3f6; --shell-line: #e2e7ee; --shell-text: #33415a; --shell-dim: #627085; }
.theme-gece {
    --bg: #0c1420; --surface: #141f2e; --surface-2: #192637; --line: #26354a; --line-2: #36475f;
    --text: #e8edf4; --text-2: #b4c0d0; --text-3: #93a1b4; --shell: #0a111b; --shell-2: #141f2e;
    --brand-soft: color-mix(in srgb, var(--brand) 18%, #141f2e); --brand-line: color-mix(in srgb, var(--brand) 45%, #141f2e);
    --ok-soft: #10352a; --warn-soft: #3a2a10; --bad-soft: #3d1a18; --ok: #5fd0a2; --warn: #eab765; --bad: #f59a92;
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
    margin: 0; background: var(--bg); color: var(--text);
    font: 400 14px/1.5 "IBM Plex Sans", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
    -webkit-font-smoothing: antialiased;
}
h1, h2, h3, p { margin: 0; }
a { color: inherit; }
img, svg { display: block; }
button, input, select, textarea { font: inherit; color: inherit; }
code { font-family: ui-monospace, "Cascadia Mono", Consolas, monospace; }
:focus-visible { outline: 2px solid var(--brand); outline-offset: 2px; }
.num { font-variant-numeric: tabular-nums; }
.muted { color: var(--text-3); }
.skip { position: absolute; left: 12px; top: -48px; z-index: 50; background: var(--surface); padding: 8px 12px; border-radius: var(--radius-sm); }
.skip:focus { top: 12px; }

/* Monogram: stands in for a logo until the firm uploads one. */
.mark {
    flex: none; display: grid; place-items: center; width: 36px; height: 36px; border-radius: 8px;
    background: var(--brand); color: var(--brand-ink); font-weight: 700; font-size: 14px; letter-spacing: .02em;
}
.mark.lg { width: 44px; height: 44px; font-size: 17px; border-radius: 10px; }
.logo { max-height: 36px; max-width: 160px; object-fit: contain; }

/* Buttons and fields */
.btn {
    display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 38px; padding: 0 14px;
    border: 1px solid var(--line-2); border-radius: var(--radius-sm); background: var(--surface); color: var(--text);
    font-weight: 500; text-decoration: none; white-space: nowrap; cursor: pointer; transition: background .12s, border-color .12s;
}
.btn:hover { background: var(--surface-2); border-color: var(--text-3); }
.btn-primary { background: var(--brand); border-color: var(--brand); color: var(--brand-ink); }
.btn-primary:hover { background: color-mix(in srgb, var(--brand) 88%, #000); border-color: color-mix(in srgb, var(--brand) 88%, #000); }
.btn-block { width: 100%; min-height: 44px; font-weight: 600; }
.link { padding: 0; border: 0; background: none; color: var(--text-2); font-weight: 500; text-decoration: underline; text-underline-offset: 3px; cursor: pointer; }
.field { display: grid; gap: 6px; margin-bottom: 16px; }
.field label { font-weight: 500; color: var(--text-2); }
.input {
    width: 100%; min-height: 44px; padding: 0 12px; border: 1px solid var(--line-2); border-radius: var(--radius-sm);
    background: var(--surface); transition: border-color .12s, box-shadow .12s;
}
.input:focus { outline: 0; border-color: var(--brand); box-shadow: 0 0 0 3px var(--brand-soft); }
.input-code { font-size: 20px; letter-spacing: .3em; text-align: center; font-variant-numeric: tabular-nums; }
.check { display: inline-flex; align-items: center; gap: 8px; color: var(--text-2); }
.check input { width: 16px; height: 16px; accent-color: var(--brand); }

.alert { display: flex; gap: 10px; align-items: flex-start; padding: 10px 12px; margin-bottom: 16px; border-radius: var(--radius-sm); border: 1px solid transparent; }
.alert svg { flex: none; margin-top: 1px; }
.alert-bad { background: var(--bad-soft); color: var(--bad); border-color: color-mix(in srgb, var(--bad) 22%, transparent); }
.alert-ok { background: var(--ok-soft); color: var(--ok); border-color: color-mix(in srgb, var(--ok) 22%, transparent); }

.badge { display: inline-flex; align-items: center; gap: 6px; padding: 2px 8px; border-radius: 999px; font-size: 12px; font-weight: 500; background: var(--surface-2); color: var(--text-2); border: 1px solid var(--line); white-space: nowrap; }
.badge::before { content: ""; width: 6px; height: 6px; border-radius: 50%; background: currentColor; }
.badge-ok { background: var(--ok-soft); color: var(--ok); border-color: transparent; }
.badge-warn { background: var(--warn-soft); color: var(--warn); border-color: transparent; }
.badge-bad { background: var(--bad-soft); color: var(--bad); border-color: transparent; }

/* Sign-in */
.auth { min-height: 100vh; display: grid; grid-template-columns: minmax(420px, 46%) 1fr; }
.auth-aside {
    position: relative; overflow: hidden; display: flex; flex-direction: column; justify-content: space-between; gap: 48px;
    padding: 40px 56px; color: #fff; background-color: var(--auth-bg, var(--shell)); border-top: 4px solid var(--brand);
}
.auth-aside::before {
    content: ""; position: absolute; inset: 0;
    background-image: linear-gradient(rgba(255,255,255,.035) 1px, transparent 1px), linear-gradient(90deg, rgba(255,255,255,.035) 1px, transparent 1px);
    background-size: 44px 44px;
}
.auth-photo { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; opacity: .32; }
.auth-aside > div { position: relative; }
.auth-brand { display: flex; align-items: center; gap: 12px; font-size: 16px; font-weight: 600; }
.auth-brand .logo { max-height: 44px; background: #fff; padding: 4px 8px; border-radius: 6px; }
.auth-pitch h2 { max-width: 15em; font-size: clamp(28px, 2.7vw, 40px); line-height: 1.16; font-weight: 600; letter-spacing: -.015em; }
.auth-points { list-style: none; display: grid; gap: 14px; margin: 32px 0 0; padding: 0; color: #cdd6e3; font-size: 15px; }
.auth-points li { display: flex; align-items: center; gap: 12px; }
.auth-points span { display: grid; place-items: center; width: 30px; height: 30px; border-radius: 7px; background: rgba(255,255,255,.08); color: #fff; }
.auth-legal { color: #8f9db0; font-size: 13px; }
.auth-main { display: flex; flex-direction: column; align-items: center; justify-content: center; padding: 40px 24px; background: var(--surface); }
.auth-form { width: 100%; max-width: 380px; }
.auth-form h1 { font-size: 26px; line-height: 1.25; font-weight: 600; letter-spacing: -.01em; }
.auth-form .lead { margin: 6px 0 28px; color: var(--text-3); }
.auth-row { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin: -2px 0 20px; }
.auth-help { margin-top: 28px; padding-top: 20px; border-top: 1px solid var(--line); color: var(--text-3); font-size: 13px; }
.auth-help a { display: block; margin-top: 4px; color: var(--text-2); font-weight: 500; white-space: nowrap; }

/* Admin and platform shell */
.shell { min-height: 100vh; display: grid; grid-template-columns: var(--side) minmax(0, 1fr); }
.side { position: sticky; top: 0; height: 100vh; display: flex; flex-direction: column; background: var(--shell); color: var(--shell-text); z-index: 30; }
.side-brand { display: flex; align-items: center; gap: 10px; min-height: 64px; padding: 14px 18px; border-bottom: 1px solid var(--shell-line); text-decoration: none; color: inherit; }
.side-brand strong { display: block; color: var(--shell-title, #fff); font-weight: 600; line-height: 1.25; }
.theme-sade .side-brand strong { color: var(--text); }
.side-brand small { color: var(--shell-dim); font-size: 12px; }
.side-filter { padding: 12px 12px 0; }
.side-filter label { display: flex; align-items: center; gap: 8px; height: 36px; padding: 0 10px; border: 1px solid var(--shell-line); border-radius: var(--radius-sm); background: rgba(255, 255, 255, .05); color: var(--shell-dim); }
.side-filter label:focus-within { border-color: var(--brand); color: var(--shell-text); }
.side-filter input { flex: 1; min-width: 0; border: 0; outline: 0; background: transparent; color: var(--shell-title, #fff); font: inherit; font-size: 14px; }
.theme-sade .side-filter input { color: var(--text); }
.side-filter input::placeholder { color: var(--shell-dim); }
.side-empty { margin: 8px 10px; color: var(--shell-dim); font-size: 13px; line-height: 1.5; }
.side-empty button { display: block; margin-top: 6px; padding: 0; border: 0; background: none; color: var(--shell-title, #fff); font: inherit; font-weight: 600; text-decoration: underline; cursor: pointer; }
.theme-sade .side-empty button { color: var(--text); }
.side-nav { flex: 1; overflow-y: auto; padding: 12px; scrollbar-width: thin; scrollbar-color: var(--shell-2) transparent; }
.side-sec > summary { display: flex; align-items: center; justify-content: space-between; min-height: 34px; margin-top: 6px; padding: 0 10px; color: var(--shell-dim); font-size: 11px; font-weight: 600; letter-spacing: .07em; text-transform: uppercase; cursor: pointer; list-style: none; }
.side-sec > summary::-webkit-details-marker { display: none; }
.side-sec > summary::after { content: "+"; font-size: 14px; }
.side-sec[open] > summary::after { content: "−"; }
.side-group { margin: 16px 8px 6px; color: var(--shell-dim); font-size: 11px; font-weight: 600; letter-spacing: .07em; text-transform: uppercase; }
.side-group:first-child { margin-top: 4px; }
.side-nav a { position: relative; display: flex; align-items: center; gap: 10px; min-height: 38px; padding: 0 10px; border-radius: var(--radius-sm); color: inherit; font-weight: 500; text-decoration: none; }
.side-nav a:hover { background: var(--shell-2); }
.side-nav a.active { background: var(--shell-2); color: var(--shell-title, #fff); }
.theme-sade .side-nav a.active { color: var(--text); }
.side-nav a.active::before { content: ""; position: absolute; left: -12px; top: 8px; bottom: 8px; width: 3px; border-radius: 0 3px 3px 0; background: var(--brand); }
.side-foot { padding: 14px 18px; border-top: 1px solid var(--shell-line); color: var(--shell-dim); font-size: 12px; }
.top { position: sticky; top: 0; z-index: 20; display: flex; align-items: center; justify-content: space-between; gap: 12px; min-height: 64px; padding: 0 32px; background: var(--surface); border-bottom: 1px solid var(--line); }
.top-title { min-width: 0; color: var(--text-3); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.top-title b { color: var(--text); font-weight: 600; }
.menu-btn { display: none; flex: none; width: 40px; height: 40px; place-items: center; border: 1px solid var(--line); border-radius: var(--radius-sm); background: var(--surface); cursor: pointer; }
.content { width: 100%; max-width: 1680px; padding: 28px 32px 48px; }
.scrim { display: none; }

.user { position: relative; flex: none; }
.user summary { list-style: none; display: flex; align-items: center; gap: 10px; padding: 4px 6px; border-radius: var(--radius-sm); cursor: pointer; }
.user summary::-webkit-details-marker { display: none; }
.user summary:hover { background: var(--surface-2); }
.avatar { display: grid; place-items: center; width: 34px; height: 34px; border-radius: 50%; background: var(--brand-soft); color: var(--text); font-size: 12px; font-weight: 600; border: 1px solid var(--brand-line); }
.user-name { line-height: 1.25; font-weight: 500; }
.user-name small { display: block; color: var(--text-3); font-size: 12px; font-weight: 400; }
.user-menu { position: absolute; right: 0; top: calc(100% + 6px); min-width: 230px; padding: 6px; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow-lg); }
.user-menu a, .user-menu button { display: flex; align-items: center; gap: 10px; width: 100%; min-height: 36px; padding: 0 10px; border: 0; border-radius: 6px; background: none; color: var(--text); text-align: left; text-decoration: none; cursor: pointer; }
.user-menu a:hover, .user-menu button:hover { background: var(--surface-2); }

/* Page building blocks */
.page-head { display: flex; align-items: flex-end; justify-content: space-between; gap: 16px; margin-bottom: 22px; }
.page-head h1 { font-size: 24px; line-height: 1.25; font-weight: 600; letter-spacing: -.01em; }
.page-head p { margin-top: 4px; color: var(--text-3); }
.kpis { display: grid; grid-template-columns: repeat(auto-fit, minmax(210px, 1fr)); gap: 14px; margin-bottom: 18px; }
.kpi { padding: 16px 18px; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow); }
.kpi-label { display: flex; align-items: center; justify-content: space-between; color: var(--text-3); font-weight: 500; }
.kpi-value { margin-top: 8px; font-size: 28px; line-height: 1.15; font-weight: 600; letter-spacing: -.01em; font-variant-numeric: tabular-nums; }
.kpi-note { margin-top: 4px; color: var(--text-3); font-size: 13px; }
.grid-main { display: grid; grid-template-columns: minmax(0, 2fr) minmax(280px, 1fr); gap: 14px; align-items: start; }
.panel { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow); }
.panel + .panel { margin-top: 14px; }
.grid-main .panel + .panel { margin-top: 0; }
.panel-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 14px 18px; border-bottom: 1px solid var(--line); }
.panel-head h2 { font-size: 15px; font-weight: 600; }
.panel-body { padding: 18px; }
.table-wrap { overflow-x: auto; }
.table { width: 100%; border-collapse: collapse; }
.table th { padding: 10px 18px; background: var(--surface-2); border-bottom: 1px solid var(--line); color: var(--text-3); font-size: 12px; font-weight: 600; text-align: left; white-space: nowrap; }
.table td { padding: 11px 18px; border-bottom: 1px solid var(--line); white-space: nowrap; }
.table tr:last-child td { border-bottom: 0; }
.table tbody tr:hover { background: var(--surface-2); }
.table .right { text-align: right; }
.table small { display: block; color: var(--text-3); font-size: 12px; }
.empty { display: grid; justify-items: center; gap: 6px; padding: 56px 24px; text-align: center; }
.empty-icon { display: grid; place-items: center; width: 48px; height: 48px; margin-bottom: 8px; border-radius: 12px; background: var(--brand-soft); color: var(--text); border: 1px solid var(--brand-line); }
.empty h2 { font-size: 16px; font-weight: 600; }
.empty p { max-width: 46ch; color: var(--text-3); }
.meter { height: 8px; margin: 10px 0 8px; border-radius: 999px; background: var(--line); overflow: hidden; }
.meter span { display: block; height: 100%; background: var(--brand); }
.rows { display: grid; gap: 12px; margin: 0; }
.rows div { display: flex; justify-content: space-between; gap: 12px; }
.rows dt { color: var(--text-3); }
.rows dd { margin: 0; font-weight: 500; text-align: right; }
.steps { display: grid; gap: 14px; margin: 0; padding: 0; list-style: none; counter-reset: s; }
.steps li { position: relative; padding-left: 36px; counter-increment: s; color: var(--text-2); }
.steps li::before { content: counter(s); position: absolute; left: 0; top: -1px; display: grid; place-items: center; width: 24px; height: 24px; border-radius: 50%; background: var(--brand-soft); border: 1px solid var(--brand-line); color: var(--text); font-size: 12px; font-weight: 600; }
.setup { display: grid; grid-template-columns: minmax(0, 1fr) 232px; gap: 28px; align-items: start; }
.qr { padding: 12px; background: #fff; border: 1px solid var(--line); border-radius: var(--radius); }
.qr svg { width: 100%; height: auto; }
.secret { display: block; padding: 10px 12px; background: var(--surface-2); border: 1px dashed var(--line-2); border-radius: var(--radius-sm); font-size: 13px; word-break: break-all; }
.narrow { max-width: 780px; }
.form-narrow { max-width: 280px; }

/* Lists and forms */
.toolbar { display: flex; flex-wrap: wrap; align-items: center; gap: 10px; padding: 12px 18px; border-bottom: 1px solid var(--line); }
.toolbar .grow { flex: 1 1 240px; min-width: 0; }
.toolbar-break { flex-basis: 100%; height: 0; }
.input-sm { min-height: 38px; }
select.input { padding-right: 8px; }
input[type="file"].input { display: block; padding: 0 12px 0 0; line-height: 36px; color: var(--text-3); cursor: pointer; }
input[type="file"].input::file-selector-button { height: 36px; margin-right: 12px; padding: 0 14px; border: 0; border-right: 1px solid var(--line-2); background: var(--surface-2); color: var(--text); font: inherit; font-weight: 500; cursor: pointer; }
textarea.input { min-height: 84px; padding: 10px 12px; resize: vertical; }
.search { position: relative; }
.search svg { position: absolute; left: 11px; top: 50%; transform: translateY(-50%); color: var(--text-3); pointer-events: none; }
.search .input { padding-left: 36px; }
.pager { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 12px 18px; border-top: 1px solid var(--line); color: var(--text-3); }
.pager div { display: flex; gap: 6px; }
.pager .off { opacity: .45; pointer-events: none; }
.row-link { font-weight: 600; text-decoration: none; }
.row-link:hover { text-decoration: underline; text-underline-offset: 3px; }
.thumb { flex: none; display: grid; place-items: center; width: 40px; height: 40px; overflow: hidden; border-radius: 6px; background: var(--surface-2); border: 1px solid var(--line); color: var(--text-3); }
.thumb img { width: 100%; height: 100%; object-fit: contain; }
.cell-media { display: flex; align-items: center; gap: 12px; }
.wrap-cell { white-space: normal; min-width: 220px; }
.form-layout { display: grid; grid-template-columns: minmax(0, 1fr) 340px; gap: 14px; align-items: start; }
.form-layout > div { display: grid; grid-template-columns: minmax(0, 1fr); gap: 14px; min-width: 0; }
.form-layout .panel + .panel { margin-top: 0; }
.form-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 0 16px; }
.form-grid .span-2 { grid-column: 1 / -1; }
.form-grid.three { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.form-actions { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; }
.table .form-actions { flex-wrap: nowrap; }
.table.compact th, .table.compact td { padding-left: 12px; padding-right: 12px; }
.hint { color: var(--text-3); font-size: 13px; }
.stack { display: grid; grid-template-columns: minmax(0, 1fr); gap: 10px; }
.product-image { position: relative; display: grid; place-items: center; aspect-ratio: 4 / 3; margin-bottom: 12px; overflow: hidden; border-radius: var(--radius-sm); background: var(--surface-2); border: 1px solid var(--line); color: var(--text-3); }
/* Mutlak konum: grid içinde height:100% doğal yüksekliğe döner ve uzun görsel kesilirdi. */
.product-image img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: contain; padding: 6px; }
img[data-zoom] { cursor: zoom-in; }
.zoom-dialog { border: 0; padding: 0; max-width: 96vw; max-height: 94vh; background: transparent; overflow: visible; }
.zoom-dialog::backdrop { background: rgba(15, 23, 42, .78); }
.zoom-dialog img { display: block; max-width: 92vw; max-height: 90vh; border-radius: var(--radius-sm); background: #fff; cursor: zoom-out; }
.zoom-dialog-close { position: fixed; top: 12px; right: 18px; width: 40px; height: 40px; border: 0; border-radius: 50%; background: var(--surface); color: var(--text); font-size: 26px; line-height: 1; cursor: pointer; }
.errors { margin: 0; padding: 12px 18px 12px 34px; color: var(--bad); font-size: 13px; }
.discounts { display: grid; grid-template-columns: minmax(120px, 1.6fr) repeat(5, minmax(52px, 1fr)) auto; gap: 8px; align-items: end; }
.discounts label { color: var(--text-3); font-size: 12px; font-weight: 500; }

/* Catalog */
.filters { display: grid; grid-template-columns: minmax(220px, 2fr) repeat(3, minmax(130px, 1fr)) auto; gap: 10px; padding: 14px; margin-bottom: 14px; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow); }
.filters-row { grid-column: 1 / -1; display: flex; flex-wrap: wrap; align-items: center; gap: 16px; }
.filters-row .push { margin-left: auto; display: flex; gap: 10px; align-items: center; }
.segment { display: inline-flex; border: 1px solid var(--line-2); border-radius: var(--radius-sm); overflow: hidden; }
.segment a { display: grid; place-items: center; width: 36px; height: 36px; color: var(--text-3); }
.segment a.active { background: var(--brand-soft); color: var(--text); }
.result-count { margin: 0 2px 12px; color: var(--text-3); }
[data-live-results] { transition: opacity .15s ease; }
[data-live-results][aria-busy="true"] { opacity: .55; }
.product-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(236px, 1fr)); gap: 14px; }
.product { display: flex; flex-direction: column; overflow: hidden; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow); }
.product-photo { position: relative; display: grid; place-items: center; aspect-ratio: 16 / 10; background: var(--surface-2); border-bottom: 1px solid var(--line); color: var(--line-2); }
.product-photo img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: contain; padding: 6px; }
.product-photo .badge { position: absolute; left: 10px; top: 10px; }
.product-photo.empty-photo { aspect-ratio: auto; height: 76px; }
.product-body { flex: 1; display: flex; flex-direction: column; gap: 4px; padding: 14px; }
.product-code { color: var(--text-3); font-size: 12px; font-variant-numeric: tabular-nums; letter-spacing: .02em; }
.product-name { font-weight: 600; line-height: 1.35; display: -webkit-box; -webkit-line-clamp: 2; line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.product-meta { color: var(--text-3); font-size: 13px; }
.product-fit { color: var(--text-2); font-size: 12.5px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.product-foot { display: flex; align-items: flex-end; justify-content: space-between; gap: 8px; margin-top: auto; padding-top: 12px; }
.price { font-size: 18px; font-weight: 600; line-height: 1.2; font-variant-numeric: tabular-nums; white-space: nowrap; }
.price small { display: block; color: var(--text-3); font-size: 12px; font-weight: 400; }
.price s { display: block; color: var(--text-3); font-size: 12px; font-weight: 400; }

/* Cart and orders */
.cart-layout { display: grid; grid-template-columns: minmax(0, 1fr) 340px; gap: 14px; align-items: start; }
.cart-layout .panel + .panel { margin-top: 0; }
.add-form { display: flex; gap: 6px; }
.add-form .input { width: 64px; min-height: 36px; padding: 0 8px; text-align: center; }
.add-form .btn { min-height: 36px; padding: 0 10px; }
.product-add { margin-top: 10px; }
.product-add .btn { flex: 1; }
.qty-form { display: flex; gap: 6px; align-items: center; }
.qty-form .input { width: 76px; min-height: 34px; padding: 0 8px; text-align: right; }
.totals { display: grid; gap: 8px; margin: 0; }
.totals div { display: flex; justify-content: space-between; gap: 12px; }
.totals dt { color: var(--text-3); }
.totals dd { margin: 0; font-variant-numeric: tabular-nums; }
.totals .grand { padding-top: 10px; border-top: 1px solid var(--line); font-size: 18px; font-weight: 600; }
.totals .grand dt { color: var(--text); }
.acting { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 8px; padding: 8px 32px; background: var(--shell); color: var(--shell-text); font-size: 13px; }
.acting strong { color: #fff; font-weight: 600; }
.theme-sade .acting strong { color: var(--text); }
.acting .link { color: inherit; }
.cart-pill { display: inline-grid; place-items: center; min-width: 20px; height: 20px; padding: 0 6px; border-radius: 999px; background: var(--brand); color: var(--brand-ink); font-size: 12px; font-weight: 600; }
.pick-list { max-height: 460px; overflow-y: auto; border: 1px solid var(--line); border-radius: var(--radius-sm); }
.pick-list label { display: flex; align-items: center; gap: 10px; padding: 8px 12px; border-bottom: 1px solid var(--line); }
.pick-list label:last-child { border-bottom: 0; }
.answer { margin-top: 6px; padding: 8px 10px; border-left: 3px solid var(--brand); background: var(--surface-2); white-space: normal; }

/* Accounting */
.lines td { padding: 6px 8px; vertical-align: top; }
.lines th { padding: 8px; }
.lines .input { min-height: 36px; padding: 0 8px; }
.lines .w-code { width: 170px; min-width: 130px; }
.lines .w-name { min-width: 240px; }
.side-ext { margin-left: auto; font-size: 12px; color: var(--muted); }
.lines .w-num { width: 104px; min-width: 88px; }
.lines .hint { display: block; margin-top: 2px; }
.lines .line-name { display: block; margin-top: 3px; color: var(--muted); }
.lines .line-name:empty { display: none; }
.lines .line-total { min-width: 110px; padding-top: 14px; font-weight: 600; }
.lines-foot { display: flex; justify-content: space-between; align-items: flex-start; gap: 16px; flex-wrap: wrap; padding: 14px 18px; border-top: 1px solid var(--line); }
.lines-foot .totals { min-width: 280px; margin: 0; }
.lines .input.is-invalid { border-color: var(--bad); box-shadow: 0 0 0 2px color-mix(in srgb, var(--bad) 18%, transparent); }
.line-errors { margin: 0; padding: 10px 18px; border-top: 1px solid var(--line); color: var(--bad); font-size: 14px; }
.totals.is-over .grand dd { color: var(--bad); }
.row-actions { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; justify-content: flex-end; }
.row-actions form { display: flex; gap: 6px; align-items: center; }
.row-actions .input { width: 150px; }
details.mini > summary { cursor: pointer; color: var(--text-2); font-weight: 500; text-decoration: underline; text-underline-offset: 3px; list-style: none; }
details.mini > summary::-webkit-details-marker { display: none; }
details.mini[open] > form { margin-top: 6px; }
.doc-actions { display: grid; gap: 10px; }
.action-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 14px; }
details.action { border: 1px solid var(--line); border-radius: var(--radius-sm); }
details.action > summary { display: flex; align-items: center; justify-content: space-between; min-height: 42px; padding: 0 12px; cursor: pointer; font-weight: 500; list-style: none; }
details.action > summary::-webkit-details-marker { display: none; }
details.action > summary::after { content: "+"; color: var(--text-3); font-size: 18px; }
details.action[open] > summary::after { content: "−"; }
details.action[open] > summary { border-bottom: 1px solid var(--line); }
details.action > form { padding: 12px; }
.sum-note { font-size: 13px; color: var(--text-3); }

.grid-two { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px; }
.grid-two .panel + .panel { margin-top: 0; }

.home-search { margin-bottom: 14px; }

/* Management compass */
.compass-bar { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 10px; margin-bottom: 14px; }
.compass-bar .tabs { margin-bottom: 0; }
.compass-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px; align-items: start; }
.compass-grid .panel + .panel { margin-top: 0; }
.meters { display: grid; gap: 12px; }
.meter-text { display: flex; justify-content: space-between; gap: 12px; margin-bottom: 5px; font-size: 14px; }
.meter-text small { display: block; color: var(--text-3); }
.meter-text > span:last-child { text-align: right; white-space: nowrap; }
.meter { height: 6px; border-radius: 4px; background: var(--surface-2); box-shadow: inset 0 0 0 1px var(--line); overflow: hidden; }
.meter i { display: block; height: 100%; border-radius: 4px; background: var(--text-2); }

/* Reports */
.tabs { display: flex; flex-wrap: wrap; gap: 4px; margin-bottom: 14px; }
.tabs a { min-height: 38px; display: inline-flex; align-items: center; padding: 0 12px; border-radius: var(--radius-sm); color: var(--text-2); font-weight: 500; text-decoration: none; }
.tabs a.active { background: var(--surface); color: var(--text); box-shadow: inset 0 0 0 1px var(--line); }
.table tfoot td { background: var(--surface-2); font-weight: 600; border-top: 1px solid var(--line-2); }

/* Printable documents */
.sheet { max-width: 900px; margin: 24px auto; padding: 40px 44px; background: #fff; color: #131f30; border: 1px solid var(--line); border-radius: var(--radius); }
.sheet-bar { display: flex; justify-content: flex-end; gap: 10px; max-width: 900px; margin: 24px auto -12px; padding: 0 2px; }
.sheet-head { display: flex; justify-content: space-between; gap: 24px; padding-bottom: 18px; border-bottom: 2px solid #131f30; }
.sheet-firm { display: flex; gap: 12px; align-items: flex-start; }
.sheet-firm strong { display: block; font-size: 16px; }
.sheet-firm small { display: block; color: #46546a; }
.sheet-title { text-align: right; }
.sheet-title h1 { font-size: 20px; font-weight: 600; }
.sheet-title p { color: #46546a; font-variant-numeric: tabular-nums; }
.sheet-fields { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 6px 24px; margin: 18px 0; }
.sheet-fields div { display: flex; gap: 8px; }
.sheet-fields dt { flex: none; width: 96px; color: #46546a; }
.sheet-fields dd { margin: 0; font-weight: 500; }
.sheet table { width: 100%; border-collapse: collapse; margin-top: 8px; font-size: 13px; }
.sheet th { padding: 7px 8px; border-bottom: 1px solid #131f30; text-align: left; font-weight: 600; }
.sheet td { padding: 6px 8px; border-bottom: 1px solid #e2e7ee; vertical-align: top; }
.sheet .r { text-align: right; font-variant-numeric: tabular-nums; white-space: nowrap; }
.sheet-totals { display: grid; gap: 4px; width: 280px; margin: 16px 0 0 auto; }
.sheet-totals div { display: flex; justify-content: space-between; gap: 12px; font-variant-numeric: tabular-nums; }
.sheet-totals div:last-child { padding-top: 6px; border-top: 1px solid #131f30; font-size: 15px; font-weight: 600; }
.sheet-sign { display: grid; grid-template-columns: repeat(2, 1fr); gap: 48px; margin-top: 56px; color: #46546a; font-size: 13px; }
.sheet-sign div { padding-top: 8px; border-top: 1px solid #cbd3de; }
.sheet-note { margin-top: 28px; color: #627085; font-size: 12px; }
.hide-prices [data-money], .hide-prices .sheet-totals, .hide-sign .sheet-sign { display: none; }
.sheet-bar { align-items: center; }
.sheet .sheet-sub td { padding-top: 2px; padding-bottom: 2px; border-bottom-color: #f3f5f8; color: #46546a; font-size: 12px; }
.sheet-flash { max-width: 900px; margin: 16px auto 0; padding: 0 2px; }

/* E-mail form: opens under its button, page stays where it is */
.send-mail { position: relative; }
.send-mail > summary { list-style: none; cursor: pointer; }
.send-mail > summary::-webkit-details-marker { display: none; }
.send-mail-form { position: absolute; right: 0; top: calc(100% + 6px); z-index: 30; width: min(380px, calc(100vw - 32px)); padding: 16px; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); box-shadow: 0 12px 32px rgba(15, 23, 42, .14); text-align: left; }
.send-mail-form .field:last-of-type { margin-bottom: 14px; }
@media (max-width: 640px) {
    .sheet-bar { flex-wrap: wrap; }
    /* On a phone the form opens as a sheet at the bottom of the screen */
    .send-mail-form { position: fixed; left: 16px; right: 16px; top: auto; bottom: 16px; width: auto; max-height: calc(100vh - 32px); overflow: auto; }
}

@media print {
    @page { size: A4; margin: 14mm; }
    body { background: #fff; }
    .sheet-bar, .sheet-flash { display: none; }
    .sheet { max-width: none; margin: 0; padding: 0; border: 0; }
    .sheet tr { break-inside: avoid; }
}

.site-foot { display: flex; flex-wrap: wrap; gap: 8px 18px; max-width: 1320px; margin: 0 auto; padding: 20px 32px 32px; color: var(--text-3); font-size: 13px; }
.site-foot a { color: inherit; }
.prose { max-width: 760px; white-space: pre-line; line-height: 1.7; }
.check-grid { display: grid; gap: 8px; }
.feature-row { display: flex; flex-wrap: wrap; gap: 8px 16px; }

/* Dealer portal */
.dealer-top { position: sticky; top: 0; z-index: 20; background: var(--surface); border-bottom: 1px solid var(--line); }
.dealer-bar { display: flex; align-items: center; justify-content: space-between; gap: 16px; max-width: 1320px; min-height: 68px; margin: 0 auto; padding: 0 32px; }
.dealer-brand { display: flex; align-items: center; gap: 10px; min-width: 0; font-size: 16px; font-weight: 600; text-decoration: none; }
.dealer-brand span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.dealer-nav { flex: 1; display: flex; gap: 4px; padding-left: 24px; }
.dealer-nav a { display: inline-flex; align-items: center; gap: 8px; min-height: 38px; padding: 0 12px; border-radius: var(--radius-sm); color: var(--text-2); font-weight: 500; text-decoration: none; }
.dealer-nav a.active { background: var(--brand-soft); color: var(--text); }
.dealer-tabs { display: none; }
.dealer-main { max-width: 1320px; margin: 0 auto; padding: 24px 32px 48px; }
.hero { position: relative; overflow: hidden; display: flex; align-items: center; justify-content: space-between; gap: 24px; padding: 32px 36px; margin-bottom: 18px; border-radius: var(--radius); background: var(--shell); color: #fff; border-left: 4px solid var(--brand); }
.theme-sade .hero { color: var(--text); border: 1px solid var(--line); border-left: 4px solid var(--brand); }
.hero::before { content: ""; position: absolute; inset: 0; background-image: linear-gradient(rgba(255,255,255,.035) 1px, transparent 1px), linear-gradient(90deg, rgba(255,255,255,.035) 1px, transparent 1px); background-size: 36px 36px; }
.hero > * { position: relative; }
.hero h1 { font-size: 26px; line-height: 1.2; font-weight: 600; letter-spacing: -.01em; }
.hero p { margin-top: 6px; color: var(--shell-text); }
.hero-contact { flex: none; display: grid; gap: 2px; text-align: right; color: var(--shell-text); font-size: 13px; }
.hero-contact a { color: inherit; font-size: 16px; font-weight: 600; text-decoration: none; }
.tiles { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 14px; }
.tile { display: block; color: inherit; text-decoration: none; padding: 20px; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow); }
.tile .empty-icon { width: 40px; height: 40px; margin-bottom: 12px; border-radius: 10px; }
.tile h2 { font-size: 15px; font-weight: 600; }
.tile p { margin-top: 4px; color: var(--text-3); }

/* Standalone message pages */
.notice { min-height: 100vh; display: grid; place-items: center; padding: 24px; }
.notice-card { width: 100%; max-width: 440px; padding: 32px; background: var(--surface); border: 1px solid var(--line); border-top: 3px solid var(--brand); border-radius: var(--radius); box-shadow: var(--shadow); }
.notice-card h1 { margin-top: 18px; font-size: 22px; font-weight: 600; }
.notice-card p { margin-top: 8px; color: var(--text-2); }
.notice-card .btn { margin-top: 20px; }

.grid-main .table th, .grid-main .table td { padding-left: 12px; padding-right: 12px; }

/* Laptops and projectors: the sidebar stays, so tables give up padding rather than scroll. */
@media (max-width: 1320px) {
    .table th, .table td { padding-left: 10px; padding-right: 10px; }
    .table th:first-child, .table td:first-child { padding-left: 18px; }
    .table th:last-child, .table td:last-child { padding-right: 18px; }
    .wrap-cell { min-width: 150px; }
    .lines td { padding: 6px; }
    .grid-main { grid-template-columns: minmax(0, 1fr) 262px; }
    .grid-main .table th, .grid-main .table td { padding-left: 8px; padding-right: 8px; }
    .table .form-actions { gap: 6px; }
}

@media (max-width: 1100px) {
    .grid-main, .form-layout, .cart-layout, .grid-two { grid-template-columns: minmax(0, 1fr); }
    .compass-grid { grid-template-columns: minmax(0, 1fr); }
    .grid-main .panel + .panel { margin-top: 0; }
    .filters { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .filters .search { grid-column: 1 / -1; }
}
@media (max-width: 960px) {
    .auth { grid-template-columns: minmax(0, 1fr); grid-template-rows: auto 1fr; }
    .auth-aside { padding: 18px 16px; gap: 0; }
    .auth-pitch, .auth-legal { display: none; }
    .auth-main { justify-content: flex-start; padding: 32px 16px; }
    .shell { grid-template-columns: minmax(0, 1fr); }
    .side { position: fixed; left: 0; top: 0; bottom: 0; width: min(var(--side), 84vw); transform: translateX(-100%); transition: transform .18s; }
    .nav-open .side { transform: none; box-shadow: var(--shadow-lg); }
    .nav-open .scrim { display: block; position: fixed; inset: 0; z-index: 25; background: rgba(14, 26, 43, .45); }
    .menu-btn { display: grid; }
    .top { padding: 0 16px; }
    .content { padding: 20px 16px 40px; }
    .user-name { display: none; }
    .dealer-bar { padding: 0 16px; }
    .site-foot { padding: 16px; }
    .acting { padding: 8px 16px; }
    .dealer-nav { display: none; }
    .dealer-tabs { display: flex; gap: 4px; padding: 0 16px 8px; overflow-x: auto; }
    .dealer-tabs a { display: inline-flex; align-items: center; gap: 6px; min-height: 36px; padding: 0 10px; border-radius: var(--radius-sm); color: var(--text-2); font-weight: 500; text-decoration: none; white-space: nowrap; }
    .dealer-tabs a.active { background: var(--brand-soft); color: var(--text); }
    .dealer-main { padding: 16px 16px 40px; }
    .hero { display: block; padding: 24px 20px; }
    .hero-contact { margin-top: 14px; text-align: left; }
    .setup { grid-template-columns: minmax(0, 1fr); }
    .qr { max-width: 232px; }
    .form-narrow { max-width: none; }
    .sheet { margin: 12px 0; padding: 20px 16px; overflow-x: auto; }
    .sheet-bar { margin: 12px 0 0; }
    .sheet-head { flex-direction: column; }
    .sheet-title { text-align: left; }
    .sheet-fields { grid-template-columns: minmax(0, 1fr); }
    .form-grid, .form-grid.three { grid-template-columns: minmax(0, 1fr); }
    .discounts { grid-template-columns: repeat(5, minmax(0, 1fr)); }
    .discounts .wide { grid-column: 1 / -1; }
}
@media (max-width: 560px) {
    .kpis { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
    .kpi { padding: 12px 14px; }
    .kpi-value { font-size: 22px; }
    .kpi-note { font-size: 12px; }
    .hide-sm { display: none; }
    .qty-form .link { display: none; }
    .qty-form .input { width: 60px; }
    .wrap-cell { min-width: 110px; }
    .product-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
    .product-body { padding: 10px; }
    .product-foot { flex-direction: column; align-items: flex-start; }
    .price { font-size: 16px; }
    .filters-row .push { margin-left: 0; }
    .table th, .table td, .table th:first-child, .table td:first-child, .table th:last-child, .table td:last-child { padding-left: 10px; padding-right: 10px; }
}
@media (prefers-reduced-motion: reduce) { * { transition: none !important; } }

/* Optional field groups and the slip type tabs */
.fieldset { border: 1px solid var(--line); border-radius: var(--radius-sm); padding: 10px 12px 12px; margin: 0 0 16px; }
.fieldset legend { padding: 0 6px; font-size: 12px; font-weight: 600; color: var(--text-2); }
.slip-nav { overflow-x: auto; flex-wrap: nowrap; padding-bottom: 2px; }
.slip-nav a { white-space: nowrap; }
[hidden] { display: none !important; }

/* Licence and modules */
.module-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); gap: 16px; }
.module-card { margin: 0; }
.module-card.is-on { border-color: color-mix(in srgb, var(--ok) 35%, var(--line)); }
.module-card p { margin: 6px 0 0; }
.module-head { display: flex; align-items: center; justify-content: space-between; gap: 10px; }
.module-head h2 { margin: 0; font-size: 16px; }
.module-card .warn { color: var(--warn); font-weight: 600; }
.module-pick { border: 1px solid var(--line); border-radius: var(--radius-sm); padding: 10px 14px 12px; margin: 0 0 16px; display: grid; gap: 8px; }
.module-pick legend { padding: 0 6px; font-weight: 600; }
.table.modules .input-sm { min-width: 0; width: 100%; }
.table.modules td:nth-child(3) { min-width: 140px; }

/* Pazaryeri */
.pick-list button { display: block; width: 100%; padding: 8px 12px; text-align: left; background: none; border: 0; border-bottom: 1px solid var(--line); color: var(--text); cursor: pointer; }
.pick-list button:hover, .pick-list button:focus-visible { background: var(--brand-soft); }
.pick-list button:last-child { border-bottom: 0; }
small.warn, p.warn { color: var(--warn); font-weight: 600; }
.claim-item { padding: 12px 0; border-bottom: 1px solid var(--line); }
.claim-item:last-child { border-bottom: 0; }
.question { padding: 16px 18px; border-bottom: 1px solid var(--line); }
.question:last-child { border-bottom: 0; }
.question blockquote { margin: 8px 0; padding: 10px 12px; background: var(--surface-2); border-radius: var(--radius-sm); }
a.kpi { display: block; color: inherit; text-decoration: none; }
a.kpi:hover { border-color: var(--line-2); }
span.warn { color: var(--warn); font-weight: 600; }

/* Pazaryeri fiyatları (ürün kartı) */
.market-price + .market-price { border-top: 1px solid var(--line); }
.market-price-head { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; margin-bottom: 6px; }
.market-price .hint { margin-bottom: 10px; }

/* V2: top bar tools: search that opens the command palette, and quick "new" actions. */
.top-tools { display: flex; align-items: center; gap: 10px; margin-left: auto; margin-right: 8px; }
.top-search { display: flex; align-items: center; gap: 10px; width: 340px; height: 38px; padding: 0 8px 0 12px; border: 1px solid var(--line); border-radius: var(--radius-sm); background: var(--surface-2); color: var(--text-3); cursor: pointer; text-align: left; }
.top-search:hover { border-color: var(--line-2); color: var(--text-2); }
.top-search span { flex: 1; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
kbd { display: inline-block; min-width: 20px; padding: 1px 6px; border: 1px solid var(--line-2); border-bottom-width: 2px; border-radius: 5px; background: var(--surface); color: var(--text-2); font: 500 11px/1.5 "IBM Plex Sans", system-ui, sans-serif; text-align: center; }
.quick { position: relative; }
.quick > summary { list-style: none; display: inline-flex; align-items: center; gap: 6px; cursor: pointer; }
.quick > summary::-webkit-details-marker { display: none; }
.quick .user-menu { min-width: 220px; }
.btn-sm { min-height: 38px; padding: 0 14px; }
.palette { width: min(680px, calc(100vw - 32px)); max-height: min(560px, calc(100vh - 96px)); margin: 72px auto auto; padding: 0; border: 1px solid var(--line); border-radius: 14px; background: var(--surface); color: var(--text); box-shadow: var(--shadow-lg); overflow: hidden; }
.palette::backdrop { background: rgba(14, 26, 43, .45); }
.palette-box { display: flex; flex-direction: column; max-height: inherit; }
.palette-input { display: flex; align-items: center; gap: 10px; padding: 14px 16px; border-bottom: 1px solid var(--line); color: var(--text-3); }
.palette-input input { flex: 1; min-width: 0; border: 0; outline: 0; background: none; font-size: 16px; color: var(--text); }
.palette-input input::-webkit-search-cancel-button { display: none; }
.palette-list { overflow-y: auto; padding: 6px; }
.palette-group { padding: 10px 10px 4px; color: var(--text-3); font-size: 11px; font-weight: 600; letter-spacing: .06em; text-transform: uppercase; }
.palette-item { display: flex; align-items: center; gap: 12px; padding: 9px 10px; border-radius: 8px; color: var(--text); text-decoration: none; cursor: pointer; }
.palette-item[aria-selected="true"] { background: var(--brand-soft); box-shadow: inset 3px 0 0 var(--brand); }
.palette-item b { display: block; font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.palette-item small { display: block; color: var(--text-3); font-size: 12px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.palette-item .main { flex: 1; min-width: 0; }
.palette-item .meta { flex: none; color: var(--text-2); font-size: 12px; font-variant-numeric: tabular-nums; text-align: right; }
.palette-empty { padding: 28px 16px; color: var(--text-3); text-align: center; }
.palette-foot { display: flex; gap: 16px; padding: 10px 16px; border-top: 1px solid var(--line); background: var(--surface-2); color: var(--text-3); font-size: 12px; }
@media (max-width: 900px) {
    .top-search { width: 38px; padding: 0; justify-content: center; }
    .top-search span, .top-search kbd { display: none; }
    .quick > summary span { display: none; }
    .quick > summary { padding: 0 10px; }
    .palette { margin-top: 16px; }
    .palette-foot { display: none; }
}

/* V2: customer snapshot, meters, record header chips and the activity timeline. */
.snap-who { display: grid; gap: 2px; padding-bottom: 14px; margin-bottom: 14px; border-bottom: 1px solid var(--line); }
.snap-who strong { font-size: 15px; }
.snap-who small { color: var(--text-3); }
.snap-contact { display: flex; flex-wrap: wrap; gap: 6px 14px; margin-top: 6px; }
.snap-contact a { display: inline-flex; align-items: center; gap: 6px; color: var(--text-2); text-decoration: none; font-size: 13px; }
.snap-contact a:hover { color: var(--text); text-decoration: underline; }
.snap-rows { display: grid; gap: 11px; margin: 0; }
.snap-rows > div { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: baseline; gap: 4px 12px; }
.snap-rows dt { color: var(--text-3); }
.snap-rows dd { margin: 0; font-weight: 500; text-align: right; }
.snap-rows dd a { color: inherit; }
.snap-limit .meter { flex-basis: 100%; }
.snap-limit small { flex-basis: 100%; color: var(--text-3); font-size: 12px; }
.strong { font-weight: 600; }
.tone-ok { color: var(--ok); }
.tone-warn { color: var(--warn); }
.tone-bad { color: var(--bad); }
.meter { height: 6px; border-radius: 99px; background: var(--surface-2); box-shadow: inset 0 0 0 1px var(--line); overflow: hidden; }
.meter span { display: block; height: 100%; border-radius: inherit; background: var(--ok); }
.meter-warn span { background: var(--warn); }
.meter-bad span { background: var(--bad); }
.chips { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; margin-top: 8px; }
.chip { display: inline-flex; align-items: center; gap: 6px; height: 26px; padding: 0 10px; border: 1px solid var(--line); border-radius: 99px; background: var(--surface); color: var(--text-2); font-size: 12px; font-weight: 500; text-decoration: none; }
.chip svg { width: 14px; height: 14px; }
a.chip:hover { border-color: var(--line-2); color: var(--text); }
.chip-brand { border-color: var(--brand-line); background: var(--brand-soft); color: var(--text); }
.record-grid { display: grid; grid-template-columns: minmax(0, 1fr) 340px; gap: 16px; align-items: start; }
.record-side { display: grid; gap: 16px; }
.timeline { list-style: none; margin: 0; padding: 4px 0 0; }
.timeline li { position: relative; display: grid; grid-template-columns: 18px minmax(0, 1fr) auto; gap: 10px; padding-bottom: 14px; }
.timeline li::before { content: ""; position: absolute; left: 8px; top: 18px; bottom: 0; width: 2px; background: var(--line); }
.timeline li:last-child { padding-bottom: 0; }
.timeline li:last-child::before { display: none; }
.timeline .dot { width: 10px; height: 10px; margin: 5px 4px; border-radius: 50%; background: var(--line-2); box-shadow: 0 0 0 3px var(--surface); }
.timeline .dot-ok { background: var(--ok); }
.timeline .dot-warn { background: var(--warn); }
.timeline .dot-bad { background: var(--bad); }
.timeline .dot-brand { background: var(--brand); }
.timeline b { font-weight: 600; }
.timeline small { display: block; color: var(--text-3); }
.timeline time { color: var(--text-3); font-size: 12px; white-space: nowrap; font-variant-numeric: tabular-nums; }
.stock-ok { color: var(--ok); }
.stock-short { color: var(--bad); font-weight: 600; }
.note-box { padding: 12px 14px; border-left: 3px solid var(--brand); border-radius: 0 var(--radius-sm) var(--radius-sm) 0; background: var(--brand-soft); white-space: pre-line; }
@media (max-width: 1100px) { .record-grid { grid-template-columns: minmax(0, 1fr); } }

/* V2: searchable select (combobox) and the customer strip under document forms. */
.span-all { grid-column: 1 / -1; }
.combo { position: relative; }
.combo-input { padding-right: 34px; }
.combo-clear { position: absolute; right: 6px; top: 50%; transform: translateY(-50%); width: 26px; height: 26px; border: 0; border-radius: 6px; background: none; color: var(--text-3); cursor: pointer; }
.combo-clear:hover { background: var(--surface-2); color: var(--text); }
.combo-list { position: absolute; z-index: 30; left: 0; right: 0; top: calc(100% + 4px); max-height: 300px; overflow-y: auto; padding: 4px; border: 1px solid var(--line); border-radius: var(--radius-sm); background: var(--surface); box-shadow: var(--shadow-lg); }
.combo-opt { display: flex; justify-content: space-between; gap: 12px; padding: 8px 10px; border-radius: 6px; cursor: pointer; }
.combo-opt small { color: var(--text-3); font-variant-numeric: tabular-nums; white-space: nowrap; }
.combo-opt[aria-selected="true"] { background: var(--brand-soft); }
.combo-empty { padding: 10px; color: var(--text-3); }
.strip { display: flex; flex-wrap: wrap; align-items: center; gap: 10px 22px; padding: 12px 14px; margin-bottom: 16px; border: 1px solid var(--line); border-radius: var(--radius-sm); background: var(--surface-2); }
.strip span { display: grid; gap: 1px; }
.strip small { color: var(--text-3); font-size: 11px; font-weight: 600; letter-spacing: .04em; text-transform: uppercase; }
.strip b { font-weight: 600; }
.strip .link { margin-left: auto; }

/* V2: dashboard. Indicators are links to the screen behind them; "today" lists what needs a decision; daily sales bars. */
a.kpi-link { color: inherit; text-decoration: none; transition: border-color .12s, box-shadow .12s; }
a.kpi-link:hover { border-color: var(--line-2); box-shadow: var(--shadow-lg); }
.trend { font-weight: 600; }
.todo { list-style: none; margin: 0; padding: 4px 0; }
.todo li + li { border-top: 1px solid var(--line); }
.todo a { display: flex; align-items: center; gap: 12px; padding: 12px 18px; color: inherit; text-decoration: none; }
.todo a:hover { background: var(--surface-2); }
.todo-icon { flex: none; display: grid; place-items: center; width: 34px; height: 34px; border-radius: 9px; background: var(--surface-2); }
.todo-icon.tone-bad { background: var(--bad-soft); }
.todo-icon.tone-warn { background: var(--warn-soft); }
.todo-icon.tone-ok { background: var(--ok-soft); }
.todo-main { flex: 1; min-width: 0; }
.todo-main b { display: block; font-weight: 600; }
.todo-main small { display: block; color: var(--text-3); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.todo-go { color: var(--text-3); font-size: 20px; }
.bars { width: 100%; height: auto; margin-bottom: 8px; }
.bars-axis { stroke: var(--line-2); stroke-width: 1; }
.bars-bar { fill: var(--brand); opacity: .85; }
.bars-hit { fill: transparent; }
.bars-day:hover .bars-bar { opacity: 1; }
.bars-day:hover .bars-hit { fill: var(--surface-2); }
.bars-label { fill: var(--text-3); font-size: 11px; font-family: inherit; }

/* V2: lists. Status tabs carry their counts; a whole row opens its record; totals sit in the table foot. */
.tabs-count .count { display: inline-grid; place-items: center; min-width: 22px; height: 20px; margin-left: 6px; padding: 0 6px; border-radius: 99px; background: var(--surface-2); color: var(--text-2); font-size: 12px; font-variant-numeric: tabular-nums; }
.tabs-count a.active .count { background: var(--brand); color: var(--brand-ink); }
tr[data-href] { cursor: pointer; }
tr[data-href]:hover td { background: var(--surface-2); }
.table tfoot td { padding: 12px 18px; border-top: 1px solid var(--line-2); background: var(--surface-2); }
.table tfoot small { margin-left: 8px; color: var(--text-3); }

/* V2: dealer bar shows the credit left; the cart takes pasted "code quantity" lines. */
.limit-chip { display: grid; gap: 0; padding: 4px 12px; margin-right: 8px; border: 1px solid var(--line); border-radius: var(--radius-sm); color: var(--text); text-decoration: none; line-height: 1.25; white-space: nowrap; }
.limit-chip small { color: var(--text-3); font-size: 11px; }
.limit-chip b { font-weight: 600; font-size: 13px; }
.limit-chip.tone-bad { border-color: var(--bad); background: var(--bad-soft); }
.limit-chip:hover { border-color: var(--line-2); }
.quick-add { border-top: 1px solid var(--line); }
.quick-add summary { display: flex; flex-wrap: wrap; align-items: baseline; gap: 4px 10px; padding: 14px 18px; cursor: pointer; list-style: none; }
.quick-add summary::-webkit-details-marker { display: none; }
.quick-add summary::before { content: "+"; display: inline-grid; place-items: center; width: 20px; height: 20px; border-radius: 6px; background: var(--brand-soft); color: var(--text); font-weight: 700; }
.quick-add details[open] summary::before { content: "−"; }
.quick-add-body { display: grid; gap: 10px; padding: 0 18px 16px; }
.quick-add-foot { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 10px; }
@media (max-width: 900px) { .limit-chip { display: none; } }

/* V2: narrow screens. Record columns may shrink so tables scroll inside their panel; the summary/actions column comes first. */
.record-grid > *, .record-side > * { min-width: 0; }
.page-head .form-actions { flex-wrap: wrap; }
@media (max-width: 1100px) {
    .record-grid > .record-side:last-child { order: -1; }
}
@media (max-width: 700px) {
    .page-head { flex-direction: column; align-items: stretch; }
    .page-head .form-actions { justify-content: flex-start; }
    .tabs-count { flex-wrap: nowrap; overflow-x: auto; }
    .tabs-count a { flex: none; }
    .strip { gap: 8px 16px; }
    .strip .link { margin-left: 0; }
}

/* Service / expense cards: kind switch and side help. */
.field .label { font-weight: 500; color: var(--text-2); }
.segmented { display: inline-flex; flex-wrap: wrap; gap: 6px; }
.segmented label { display: inline-flex; align-items: center; gap: 8px; padding: 8px 14px; border: 1px solid var(--line); border-radius: var(--radius-sm); cursor: pointer; font-weight: 500; color: var(--text); background: var(--surface); }
.segmented label:has(input:checked) { border-color: var(--brand); background: var(--brand-soft); }
.segmented input { accent-color: var(--brand); }
.help-list p { margin: 0; color: var(--text-2); line-height: 1.5; }
.help-list strong { color: var(--text); }
.stmt-group td { background: var(--surface-2); font-weight: 600; color: var(--text-2); }
.stmt-total td { font-weight: 700; border-top: 2px solid var(--line-2); }
.tone-good { color: var(--ok); }
.form-grid > .field { align-content: start; }

/* Help centre: contents on the left, sections with screenshots, search and zoom. */
.top-help { display: inline-grid; place-items: center; width: 34px; height: 34px; flex: none; border: 1px solid var(--line); border-radius: 50%; color: var(--text-2); font-weight: 700; text-decoration: none; background: var(--surface); }
.top-help:hover { border-color: var(--line-2); color: var(--text); }
.help-layout { display: grid; grid-template-columns: 260px minmax(0, 1fr); gap: 24px; align-items: start; }
.help-toc { position: sticky; top: 76px; max-height: calc(100vh - 96px); overflow: auto; display: grid; gap: 10px; padding-right: 4px; }
.help-toc nav { display: grid; gap: 1px; }
.help-toc a { display: block; padding: 5px 10px; border-radius: var(--radius-sm); color: var(--text-2); text-decoration: none; font-size: 13px; line-height: 1.35; }
.help-toc a:hover { background: var(--surface-2); color: var(--text); }
.help-toc a.active { background: var(--brand-soft); color: var(--text); }
.help-toc .help-toc-main { font-weight: 600; color: var(--text); margin-top: 8px; }
.help-toc .help-toc-sub { padding-left: 20px; }
.help-toc a[hidden] { display: none; }
.help-body { display: grid; gap: 22px; min-width: 0; }
.help-sec { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 24px 28px; scroll-margin-top: 76px; }
.help-sec[hidden], .help-sub[hidden] { display: none; }
.help-sec > h2 { font-size: 22px; margin: 0 0 8px; }
.help-lead { color: var(--text-2); font-size: 15px; line-height: 1.6; margin: 0 0 8px; max-width: 900px; }
.help-sub { border-top: 1px solid var(--line); padding-top: 20px; margin-top: 20px; scroll-margin-top: 76px; }
.help-sub h3 { font-size: 17px; margin: 0 0 12px; }
.help-sub h4 { font-size: 14px; margin: 0 0 8px; }
.help-sub p, .help-sec > p { line-height: 1.65; margin: 10px 0; max-width: 900px; }
.help-list, .help-steps { margin: 10px 0; padding-left: 22px; line-height: 1.65; max-width: 900px; }
.help-list li, .help-steps li { margin: 4px 0; }
.help-list ul, .help-steps ul { margin: 4px 0; padding-left: 20px; }
.help-steps > li::marker { font-weight: 700; color: var(--brand); }
.help-tip { background: var(--surface-2); border-left: 3px solid var(--brand); padding: 10px 14px; border-radius: 0 var(--radius-sm) var(--radius-sm) 0; }
.help-callout { background: var(--brand-soft); border-radius: var(--radius-sm); padding: 12px 16px; margin: 12px 0; line-height: 1.6; }
.help-callout ul { margin: 6px 0 0; padding-left: 20px; }
.help-fig { margin: 14px 0; }
.help-zoom { display: block; padding: 0; border: 1px solid var(--line); border-radius: var(--radius-sm); background: var(--surface-2); cursor: zoom-in; overflow: hidden; box-shadow: 0 1px 3px rgba(15, 23, 42, .06), 0 6px 20px rgba(15, 23, 42, .06); max-width: 100%; }
.help-zoom img { display: block; max-width: 100%; height: auto; }
.help-fig figcaption { margin-top: 6px; font-size: 12.5px; color: var(--text-3); }
.help-fig.narrow .help-zoom { max-width: 360px; }
.help-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 18px; align-items: start; }
.help-grid > .help-fig { margin: 14px 0 0; }
.help-table { margin: 12px 0; max-width: 900px; }
.help-table td { white-space: normal; vertical-align: top; }
.help-faq { display: grid; gap: 0; }
.help-faq details { border-top: 1px solid var(--line); padding: 12px 0; margin: 0; }
.help-faq summary { cursor: pointer; font-weight: 600; }
.help-faq details p, .help-faq details ul { margin: 8px 0 0; }
.help-empty { color: var(--text-2); }
.help-dialog { border: 0; padding: 0; max-width: 96vw; max-height: 94vh; background: transparent; }
.help-dialog::backdrop { background: rgba(15, 23, 42, .78); }
.help-dialog img { display: block; max-width: 96vw; max-height: 94vh; border-radius: var(--radius-sm); }
.help-dialog-close { position: fixed; top: 12px; right: 18px; width: 40px; height: 40px; border: 0; border-radius: 50%; background: var(--surface); color: var(--text); font-size: 26px; line-height: 1; cursor: pointer; }
kbd { display: inline-block; padding: 0 6px; border: 1px solid var(--line-2); border-bottom-width: 2px; border-radius: 5px; font-size: 11.5px; font-weight: 600; line-height: 1.7; background: var(--surface); }
@media (max-width: 1000px) {
    .help-layout { grid-template-columns: minmax(0, 1fr); }
    .help-toc { position: static; max-height: none; }
    .help-toc nav { display: none; }
    .help-grid { grid-template-columns: minmax(0, 1fr); }
    .help-sec { padding: 18px 16px; }
}
@media print { .help-toc, .side, .top, .dealer-top { display: none !important; } .help-layout { display: block; } .help-sec { border: 0; } }
/* İlk girişte zorunlu şifre penceresi */
.forced-dialog { border: 0; padding: 0; width: min(440px, 94vw); background: transparent; }
.forced-dialog::backdrop { background: rgba(15, 23, 42, .78); }
.forced-dialog .panel { margin: 0; }
.forced-dialog-exit { margin-top: 10px; text-align: center; }
