/* ZEY Panel — tek dosya, derleme gerektirmez */
:root {
  --bg: #f3f6f4;
  --surface: #ffffff;
  --text: #17211d;
  --muted: #5a6a63;
  --line: #dce5e0;
  --brand: #0d6e55;
  --brand-dark: #0a5643;
  --brand-tint: #e3f2ec;
  --accent: #d98e04;
  --danger: #b3261e;
  --danger-tint: #fbe6e4;
  --warn: #8a5a00;
  --warn-tint: #fdf0d0;
  --ok: #14612e;
  --ok-tint: #e2f4e7;
  --info-tint: #e4eefb;
  --info: #1d4f91;
  --radius: 12px;
  --shadow: 0 1px 2px rgba(20, 40, 30, .06), 0 2px 8px rgba(20, 40, 30, .04);
  --sidebar-w: 248px;
  --font: system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  color-scheme: light;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; font-family: var(--font); font-size: 1rem; line-height: 1.5; color: var(--text); background: var(--bg); }
h1, h2, h3 { line-height: 1.25; margin: 0; }
h1 { font-size: 1.5rem; }
h2 { font-size: 1.05rem; }
h3 { font-size: 1rem; margin: 1.2rem 0 .5rem; }
p { margin: 0 0 .75rem; }
a { color: var(--brand); text-underline-offset: 2px; }
a:hover { color: var(--brand-dark); }
img { max-width: 100%; }
small, .small { font-size: .85rem; }
.muted { color: var(--muted); }
.block { display: block; }
.num { text-align: right; font-variant-numeric: tabular-nums; }
.neg { color: var(--danger); }
.pos { color: var(--ok); }
.warn { color: var(--warn); }
.big { font-size: 1.8rem; font-weight: 700; margin: 0 0 .25rem; font-variant-numeric: tabular-nums; }
:focus-visible { outline: 3px solid #1a73e8; outline-offset: 2px; border-radius: 4px; }
.skip { position: absolute; left: -999px; top: 0; background: #fff; padding: .5rem 1rem; z-index: 100; }
.skip:focus { left: 8px; top: 8px; }
[hidden] { display: none !important; }

/* ---------- Kabuk / kenar çubuğu ---------- */
.shell { display: grid; grid-template-columns: var(--sidebar-w) minmax(0, 1fr); min-height: 100vh; }
.sidebar { background: #0c3b30; color: #dcebe5; display: flex; flex-direction: column; position: sticky; top: 0; height: 100vh; overflow-y: auto; }
.brand { display: flex; gap: .75rem; align-items: center; padding: 1.1rem 1.1rem; color: #fff; font-weight: 700; border-bottom: 1px solid rgba(255,255,255,.08); }
.brand small { display: block; font-weight: 400; opacity: .7; font-size: .78rem; }
.sidebar nav { padding: .75rem .6rem; display: grid; gap: 2px; flex: 1; align-content: start; }
.sidebar nav a { display: flex; align-items: center; gap: .7rem; color: #cfe3da; text-decoration: none; padding: .62rem .8rem; border-radius: 9px; min-height: 44px; }
.sidebar nav a:hover { background: rgba(255,255,255,.07); color: #fff; }
.sidebar nav a[aria-current="page"] { background: rgba(255,255,255,.14); color: #fff; font-weight: 600; }
.sidebar .icon { flex: none; opacity: .9; }
.count { margin-left: auto; font-style: normal; background: var(--accent); color: #1a1200; border-radius: 999px; padding: 0 .5rem; font-size: .75rem; font-weight: 700; }
.sidebar-foot { padding: .9rem 1rem; border-top: 1px solid rgba(255,255,255,.08); display: flex; align-items: center; justify-content: space-between; gap: .5rem; }
.whoami strong { display: block; font-size: .9rem; color: #fff; }
.whoami small { opacity: .7; }
.sidebar .btn-ghost { color: #dcebe5; border-color: rgba(255,255,255,.2); }
.sidebar .btn-ghost:hover { background: rgba(255,255,255,.1); }

.main-col { min-width: 0; }
.topbar { display: none; align-items: center; gap: .5rem; padding: .5rem .75rem; background: var(--surface); border-bottom: 1px solid var(--line); position: sticky; top: 0; z-index: 20; }
.topbar-title { font-weight: 600; }
main { padding: 1.5rem clamp(1rem, 3vw, 2rem) 3rem; max-width: 1280px; }
main:focus { outline: none; }

/* ---------- Sayfa başlığı ---------- */
.page-head { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: flex-start; gap: .75rem 1rem; margin-bottom: 1.25rem; }
.page-head p { margin: .2rem 0 0; }
.page-actions, .btn-row { display: flex; flex-wrap: wrap; gap: .5rem; align-items: center; }

/* ---------- Butonlar ---------- */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: .4rem; min-height: 44px; padding: .5rem 1rem; border: 1px solid var(--line); border-radius: 10px; background: var(--surface); color: var(--text); font: inherit; font-weight: 600; text-decoration: none; cursor: pointer; transition: background .15s, border-color .15s; }
.btn:hover { background: #eef3f0; color: var(--text); border-color: #c5d3cc; }
.btn-primary { background: var(--brand); border-color: var(--brand); color: #fff; }
.btn-primary:hover { background: var(--brand-dark); border-color: var(--brand-dark); color: #fff; }
.btn-ghost { background: transparent; border-color: transparent; }
.btn-sm { min-height: 36px; padding: .25rem .7rem; font-size: .9rem; border-radius: 8px; }
.btn-lg { min-height: 52px; font-size: 1.05rem; padding: .7rem 1.4rem; }
.btn-block { display: flex; width: 100%; }
.btn[disabled] { opacity: .6; cursor: progress; }
.icon-btn { padding: .4rem; min-width: 44px; }
form.inline { display: inline; margin: 0; }

/* ---------- Kartlar / ızgaralar ---------- */
.card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 1.1rem 1.25rem; box-shadow: var(--shadow); margin-bottom: 1.1rem; min-width: 0; }
.card.flush { padding: 0; overflow: hidden; }
.card-head { display: flex; justify-content: space-between; align-items: center; gap: .75rem; margin-bottom: .8rem; }
.card-head.pad { padding: 1.1rem 1.25rem 0; }
.card-head a { font-size: .9rem; }
.card-head h3 { margin: 0; }
.grid-2 { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 0 1.1rem; }
.grid-3 { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 0 1.1rem; }
.cards { display: grid; grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); gap: 1rem; margin-bottom: 1.2rem; }
.cards > .card { margin: 0; }
.section-title { margin: 1.4rem 0 .7rem; font-size: 1.05rem; }
.empty { padding: 1.5rem 1rem; text-align: center; color: var(--muted); }
.card:not(.flush) > .empty { padding: .75rem 0; }
.note { background: #f6f8f2; border-left: 3px solid var(--accent); padding: .55rem .75rem; border-radius: 6px; font-size: .92rem; }

/* KPI */
.kpis { display: grid; grid-template-columns: repeat(auto-fit, minmax(190px, 1fr)); gap: .9rem; margin-bottom: 1.25rem; }
.kpis-3 { grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); }
.kpi { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: .9rem 1.1rem; box-shadow: var(--shadow); display: flex; flex-direction: column; gap: .15rem; text-decoration: none; color: inherit; }
.kpi span { color: var(--muted); font-size: .85rem; }
.kpi strong { font-size: 1.35rem; font-variant-numeric: tabular-nums; }
.kpi small { color: var(--muted); }
.kpi-pos strong { color: var(--ok); }
.kpi-neg strong { color: var(--danger); }
.kpi-link:hover { border-color: var(--brand); }

.attention { display: flex; flex-wrap: wrap; gap: .6rem; margin-bottom: 1.1rem; }
.attention a { display: inline-flex; align-items: center; gap: .45rem; padding: .5rem .9rem; border-radius: 999px; background: var(--warn-tint); color: var(--warn); text-decoration: none; font-weight: 500; min-height: 40px; }
.attention a:hover { filter: brightness(.97); }

/* Listeler */
.list { list-style: none; margin: 0; padding: 0; }
.list li { display: flex; justify-content: space-between; align-items: center; gap: .75rem; padding: .6rem 0; border-bottom: 1px solid var(--line); }
.list li:last-child { border-bottom: 0; }
.list.card { padding: .3rem 1.25rem; }
.list-main { display: flex; align-items: center; gap: .75rem; text-decoration: none; color: inherit; min-width: 0; flex: 1; }
.list-main strong, .list li strong { display: block; }
.list small { display: block; color: var(--muted); }
.time { display: inline-block; min-width: 3.4rem; text-align: center; padding: .25rem .4rem; border-radius: 8px; background: var(--brand-tint); color: var(--brand-dark); font-weight: 700; font-variant-numeric: tabular-nums; }
.time.warn { background: var(--warn-tint); color: var(--warn); }
ul.plain { margin: 0; padding-left: 1.2rem; }

/* Tanım listesi */
.dl { display: grid; grid-template-columns: minmax(90px, 30%) 1fr; gap: .45rem .9rem; margin: 0; }
.dl dt { color: var(--muted); }
.dl dd { margin: 0; overflow-wrap: anywhere; }
.dl-wide { grid-template-columns: minmax(120px, 20%) 1fr; }

/* ---------- Tablolar ---------- */
.table-wrap { overflow-x: auto; -webkit-overflow-scrolling: touch; }
table { width: 100%; border-collapse: collapse; font-size: .95rem; }
th, td { padding: .65rem .9rem; text-align: left; vertical-align: top; border-bottom: 1px solid var(--line); }
th { font-size: .8rem; text-transform: uppercase; letter-spacing: .03em; color: var(--muted); background: #f8faf9; white-space: nowrap; font-weight: 600; }
th.num, td.num { text-align: right; }
tbody tr:hover { background: #fafcfb; }
tbody tr:last-child td { border-bottom: 0; }
.card:not(.flush) .table-wrap { margin: 0 -1.25rem; }

/* ---------- Rozetler ---------- */
.badge { display: inline-block; padding: .1rem .6rem; border-radius: 999px; font-size: .78rem; font-weight: 600; background: #e9eeeb; color: #33413b; white-space: nowrap; }
.badge-job_status-planned, .badge-request_status-new { background: var(--info-tint); color: var(--info); }
.badge-job_status-in_progress { background: var(--warn-tint); color: var(--warn); }
.badge-job_status-completed, .badge-ok, .badge-contract_status-active, .badge-request_status-closed { background: var(--ok-tint); color: var(--ok); }
.badge-job_status-cancelled, .badge-contract_status-cancelled, .badge-danger { background: var(--danger-tint); color: var(--danger); }
.badge-contract_status-ended, .badge-warn, .badge-request_status-scheduled { background: var(--warn-tint); color: var(--warn); }
.badge-risk-low { background: var(--ok-tint); color: var(--ok); }
.badge-risk-medium { background: var(--warn-tint); color: var(--warn); }
.badge-risk-high { background: var(--danger-tint); color: var(--danger); }

/* ---------- Bildirimler ---------- */
.alert { padding: .75rem 1rem; border-radius: 10px; margin-bottom: 1rem; border: 1px solid transparent; }
.alert ul { margin: .3rem 0 0; padding-left: 1.2rem; }
.alert-success { background: var(--ok-tint); color: var(--ok); border-color: #bfe3c9; }
.alert-error { background: var(--danger-tint); color: #7d1a14; border-color: #f0bcb8; }
.alert-info { background: var(--info-tint); color: var(--info); border-color: #bfd4f1; }
.field-error { color: var(--danger); font-weight: 600; margin: .5rem 0 0; }

/* ---------- Formlar ---------- */
.form-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 1rem 1rem; align-items: start; }
.form-stack { display: grid; gap: .9rem; }
.field { display: flex; flex-direction: column; gap: .3rem; min-width: 0; grid-column: span 4; }
.span-1 { grid-column: span 1; } .span-2 { grid-column: span 2; } .span-3 { grid-column: span 3; } .span-4 { grid-column: span 4; }
label { font-weight: 600; font-size: .92rem; }
.req { color: var(--danger); }
input, select, textarea { width: 100%; font: inherit; font-size: 1rem; color: var(--text); background: #fff; border: 1px solid #b9c7c0; border-radius: 9px; padding: .6rem .75rem; min-height: 46px; }
textarea { min-height: 88px; resize: vertical; }
input:focus-visible, select:focus-visible, textarea:focus-visible { outline: 3px solid #1a73e8; outline-offset: 1px; }
input:user-invalid, select:user-invalid, textarea:user-invalid { border-color: var(--danger); background: #fffafa; }
input[type=checkbox], input[type=radio] { width: 1.15rem; height: 1.15rem; min-height: 0; accent-color: var(--brand); }
input[type=file] { padding: .5rem; }
.hint { color: var(--muted); font-size: .84rem; margin: 0; }
.check, .radio { display: inline-flex; align-items: center; gap: .55rem; font-weight: 500; min-height: 44px; cursor: pointer; }
.radio-row { display: flex; flex-wrap: wrap; gap: .5rem 1.5rem; }
.fieldset { border: 1px solid var(--line); border-radius: 10px; padding: .75rem 1rem 1rem; margin: 0; min-width: 0; }
.fieldset legend { font-weight: 600; padding: 0 .4rem; }
.actions { display: flex; gap: .6rem; }
.filters { display: flex; flex-wrap: wrap; gap: .75rem; align-items: flex-end; margin-bottom: 1rem; }
.filters .field { grid-column: auto; min-width: 150px; }
.filters .field.grow { flex: 1 1 220px; }
.filters .btn { align-self: flex-end; }
.inline-filters { margin: 0; }
details.add-box { margin-top: 1rem; }
details.add-box summary { cursor: pointer; list-style: none; }
details.add-box summary::-webkit-details-marker { display: none; }
details.add-box[open] summary { margin-bottom: 1rem; }
.chips { display: flex; flex-wrap: wrap; gap: .4rem; margin: .4rem 0 0; }
.chip { border: 1px solid var(--line); background: var(--brand-tint); color: var(--brand-dark); padding: .35rem .75rem; min-height: 38px; border-radius: 999px; font: inherit; font-size: .9rem; cursor: pointer; }
.chip:hover { border-color: var(--brand); }

.tabs { display: flex; gap: .3rem; margin-bottom: 1rem; border-bottom: 1px solid var(--line); }
.tabs a { padding: .6rem 1rem; text-decoration: none; color: var(--muted); border-bottom: 3px solid transparent; margin-bottom: -1px; min-height: 44px; }
.tabs a[aria-current="page"] { color: var(--brand-dark); border-bottom-color: var(--brand); font-weight: 600; }

.pager { display: flex; justify-content: space-between; align-items: center; margin-top: .75rem; flex-wrap: wrap; gap: .5rem; }
.pager-links { display: flex; align-items: center; gap: .6rem; }

/* ---------- İş / rapor ekranları ---------- */
.status-strip { display: flex; align-items: center; flex-wrap: wrap; gap: .75rem; margin-bottom: 1rem; }
.cta-bar { display: flex; flex-wrap: wrap; gap: .75rem; align-items: center; margin-bottom: 1.1rem; }
.job-card { background: var(--surface); border: 1px solid var(--line); border-left: 5px solid var(--info); border-radius: var(--radius); padding: 1rem 1.1rem; box-shadow: var(--shadow); display: flex; flex-direction: column; gap: .3rem; }
.job-card.st-in_progress { border-left-color: var(--accent); }
.job-card.st-completed { border-left-color: var(--ok); }
.job-card header { display: flex; justify-content: space-between; align-items: center; }
.job-card h3 { margin: .2rem 0 0; font-size: 1.1rem; }
.job-card p { margin: 0; }
.job-card footer { display: flex; flex-wrap: wrap; gap: .5rem; margin-top: .6rem; }
.job-meta { color: var(--muted); font-size: .9rem; }

.report-form .card { margin-bottom: 1rem; }
.product-rows { display: grid; gap: .75rem; margin-bottom: .75rem; }
.product-row { display: flex; gap: .6rem; align-items: flex-end; flex-wrap: wrap; }
.product-row .grow { flex: 1 1 240px; }
.product-row .qty { flex: 0 0 120px; }
.sigpad { border: 2px dashed #9fb3aa; border-radius: 12px; background: #fff; margin: .5rem 0 1rem; padding: .5rem; }
.sigpad-canvas { display: block; width: 100%; height: auto; aspect-ratio: 700 / 240; touch-action: none; background: repeating-linear-gradient(transparent, transparent 47px, #eef2f0 48px); border-radius: 8px; cursor: crosshair; }
.sigpad-actions { display: flex; justify-content: space-between; align-items: center; padding-top: .3rem; }
.sigpad.disabled { opacity: .45; }
.sticky-actions { position: sticky; bottom: 0; padding: .75rem 0 1rem; background: linear-gradient(to top, var(--bg) 70%, transparent); }
.sig-box { display: inline-flex; flex-direction: column; border: 1px solid var(--line); padding: .5rem 1rem; border-radius: 10px; background: #fff; }
.sig-box img { max-height: 90px; max-width: 260px; }
.photos { display: flex; flex-wrap: wrap; gap: .6rem; }
.photos img { width: 130px; height: 100px; object-fit: cover; border-radius: 8px; border: 1px solid var(--line); }

/* ---------- Takvim ---------- */
.cal-toolbar { display: flex; justify-content: space-between; align-items: flex-end; flex-wrap: wrap; gap: .75rem; margin-bottom: 1rem; }
.cal-nav { display: flex; align-items: center; gap: .5rem; }
.cal-title { min-width: 9rem; text-align: center; font-size: 1.1rem; }
.cal { border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; background: var(--surface); box-shadow: var(--shadow); }
.cal-row { display: grid; grid-template-columns: repeat(7, minmax(0, 1fr)); }
.cal-head div { background: #f8faf9; padding: .5rem; text-align: center; font-size: .8rem; font-weight: 600; color: var(--muted); border-bottom: 1px solid var(--line); }
.cal-cell { min-height: 118px; padding: .3rem; border-right: 1px solid var(--line); border-bottom: 1px solid var(--line); display: flex; flex-direction: column; gap: 3px; min-width: 0; }
.cal-cell:nth-child(7n) { border-right: 0; }
.cal-cell.out { background: #f7f9f8; }
.cal-cell.out .cal-date { opacity: .45; }
.cal-cell.today { background: #f0f8f4; box-shadow: inset 0 0 0 2px var(--brand); }
.cal-date { align-self: flex-end; text-decoration: none; font-weight: 600; font-size: .85rem; padding: .1rem .45rem; border-radius: 6px; color: var(--text); }
.cal-date:hover { background: var(--brand-tint); }
.cal-job { display: block; text-decoration: none; font-size: .76rem; line-height: 1.3; padding: .15rem .35rem; border-radius: 5px; background: var(--info-tint); color: var(--info); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.cal-job.st-in_progress { background: var(--warn-tint); color: var(--warn); }
.cal-job.st-completed { background: var(--ok-tint); color: var(--ok); }
.cal-more { font-size: .75rem; color: var(--muted); padding-left: .3rem; }
.legend { display: flex; flex-wrap: wrap; gap: .4rem 1rem; align-items: center; color: var(--muted); font-size: .85rem; margin: .7rem 0 0; }
.dot { display: inline-block; width: .7rem; height: .7rem; border-radius: 50%; margin-right: .3rem; background: var(--info); }
.dot.st-in_progress, .dot-out { background: var(--accent); }
.dot.st-completed, .dot-in { background: var(--brand); }

/* Grafikler */
.bars { display: flex; align-items: flex-end; gap: .75rem; height: 170px; padding-top: .5rem; }
.bar-col { flex: 1; display: flex; flex-direction: column; align-items: center; gap: .3rem; height: 100%; }
.bar-pair { flex: 1; display: flex; align-items: flex-end; gap: 3px; width: 100%; justify-content: center; }
.bar { display: block; width: 42%; max-width: 26px; min-height: 2px; border-radius: 4px 4px 0 0; }
.bar-in { background: var(--brand); }
.bar-out { background: var(--accent); }
.hbars { list-style: none; margin: 0; padding: 0; display: grid; gap: .7rem; }
.hbars li { display: grid; grid-template-columns: 8rem 1fr auto; gap: .6rem; align-items: center; font-size: .92rem; }
.hbar { height: 10px; background: #e9eeeb; border-radius: 6px; overflow: hidden; display: block; }
.hbar i { display: block; height: 100%; background: var(--brand); }

/* ---------- Onay penceresi ---------- */
dialog.confirm-dialog { border: 0; border-radius: 14px; padding: 1.4rem; max-width: min(92vw, 420px); box-shadow: 0 12px 40px rgba(0, 0, 0, .25); }
dialog.confirm-dialog::backdrop { background: rgba(10, 30, 24, .5); }
.confirm-msg { font-size: 1.05rem; margin-bottom: 1.1rem; }
.confirm-actions { display: flex; justify-content: flex-end; gap: .6rem; }

/* ---------- Giriş / hata ---------- */
body.guest { min-height: 100vh; display: grid; place-items: center; padding: 1rem; background: linear-gradient(160deg, #0c3b30, #0d6e55 60%, #2a8a6f); }
.guest-card { background: var(--surface); width: min(100%, 400px); border-radius: 16px; padding: 2rem 1.75rem; box-shadow: 0 20px 50px rgba(0, 0, 0, .25); }
.guest-brand { text-align: center; margin-bottom: 1.5rem; color: var(--brand); }
.guest-brand h1 { font-size: 1.4rem; color: var(--text); margin-top: .4rem; }
.guest-brand p { color: var(--muted); margin: 0; }
.error-page { text-align: center; padding: 3rem 1rem; }
.error-code { font-size: 4rem; font-weight: 800; color: var(--brand); margin: 0; line-height: 1; }
body.guest .error-page { padding: 0; }

/* ---------- Duyarlı ---------- */
@media (max-width: 1100px) {
  .grid-3 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 900px) {
  .shell { grid-template-columns: 1fr; }
  .sidebar { position: fixed; inset: 0 auto 0 0; width: min(82vw, 300px); z-index: 50; transform: translateX(-100%); transition: transform .2s ease; }
  body.menu-open .sidebar { transform: none; box-shadow: 0 0 40px rgba(0, 0, 0, .4); }
  .scrim { position: fixed; inset: 0; background: rgba(0, 0, 0, .45); z-index: 40; }
  .topbar { display: flex; }
  .grid-2, .grid-3 { grid-template-columns: 1fr; }
  .form-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .span-3, .span-4 { grid-column: span 2; }
  .field { grid-column: span 2; }
  .field.span-1 { grid-column: span 1; }
  .dl, .dl-wide { grid-template-columns: 1fr; gap: .1rem; }
  .dl dt { margin-top: .5rem; font-size: .85rem; }
  .cal-cell { min-height: 84px; }
  .cal-job b { display: none; }
}
@media (max-width: 560px) {
  main { padding: 1rem .9rem 3rem; }
  h1 { font-size: 1.3rem; }
  .form-grid { grid-template-columns: 1fr; }
  .span-1, .span-2, .span-3, .span-4, .field, .field.span-1 { grid-column: 1; }
  .page-actions { width: 100%; }
  .page-actions .btn { flex: 1 1 auto; }
  .cards { grid-template-columns: 1fr; }
  .cal-cell { min-height: 64px; padding: .15rem; }
  .cal-job { font-size: .68rem; padding: .1rem .2rem; }
  .cal-more { font-size: .66rem; }
  .hbars li { grid-template-columns: 6rem 1fr auto; }
  th, td { padding: .55rem .6rem; }
}
@media (prefers-reduced-motion: reduce) {
  * { transition: none !important; scroll-behavior: auto !important; }
}
@media print {
  .sidebar, .topbar, .page-actions, .btn, .scrim, .filters { display: none !important; }
  .shell { display: block; }
  body { background: #fff; }
  .card { box-shadow: none; break-inside: avoid; }
}

/* Tek sütunlu form yığınında alanlar ızgara aralığı kullanmasın */
.form-stack .field { grid-column: auto; }

/* ---------- İstasyonlar ---------- */
.badge-station_status-ok { background: var(--ok-tint); color: var(--ok); }
.badge-station_status-activity { background: var(--danger-tint); color: var(--danger); }
.badge-station_status-damaged, .badge-station_status-missing { background: var(--warn-tint); color: var(--warn); }
.badge-station_status-blocked { background: var(--info-tint); color: var(--info); }
.st-scroll { max-height: 420px; overflow-y: auto; }
.st-group { margin: 1.2rem 0 .4rem; padding-bottom: .3rem; border-bottom: 2px solid var(--brand-tint); font-size: 1.05rem; }
.st-tools { margin: .5rem 0 .25rem; }
.st-row { border: 1px solid var(--line); border-radius: 10px; padding: .6rem .75rem .75rem; margin: .5rem 0; background: #fbfdfc; scroll-margin-top: 4.5rem; }
.st-row:target { border-color: var(--brand); box-shadow: 0 0 0 3px var(--brand-tint); background: #fff; }
.st-title { display: flex; flex-wrap: wrap; gap: .25rem .6rem; align-items: baseline; margin-bottom: .4rem; }
.st-last { flex-basis: 100%; }
.st-fields { display: grid; grid-template-columns: 1.3fr .7fr 1.5fr .7fr; gap: .5rem .6rem; }
.st-fields .field { grid-column: auto; }
.st-fields .st-act, .st-fields .st-note { grid-column: span 2; }
.st-fields .field label { font-size: .82rem; }
.st-fields input, .st-fields select { min-height: 42px; padding: .45rem .6rem; }
.type-row { display: flex; flex-wrap: wrap; gap: .6rem; align-items: flex-end; }
.type-row .grow { flex: 1 1 240px; }
.type-row .pfx { flex: 0 0 110px; }
.type-row .kind { flex: 0 0 210px; }
.type-row .tcheck { padding-bottom: .7rem; }
.type-row .tcount { padding-bottom: .8rem; }
@media (max-width: 720px) {
  .st-fields { grid-template-columns: 1fr 1fr; }
  .st-fields .st-status, .st-fields .st-prod, .st-fields .st-act, .st-fields .st-note { grid-column: span 2; }
  .st-fields .st-status { order: 1; }
  .st-fields .st-amount { order: 2; }
  .st-fields .st-qty { order: 3; }
  .st-fields .st-prod { order: 4; }
  .st-fields .st-act { order: 5; }
  .st-fields .st-note { order: 6; }
}

/* ---------- Yardım / kılavuz ---------- */
.help-h2 { margin: 1.6rem 0 .6rem; font-size: 1.25rem; }
.help-toc ul { columns: 2; column-gap: 2rem; margin: .4rem 0 0; padding: 0; list-style: none; }
.help-toc li { padding: .15rem 0; break-inside: avoid; }
.help-page { scroll-margin-top: 4.5rem; }
.help-page h3 { font-size: .95rem; margin: 1rem 0 .3rem; color: var(--brand-dark); }
.help-purpose { font-size: 1.02rem; margin-top: 0; }
.help-list, .help-steps { margin: .3rem 0 .6rem; padding-left: 1.3rem; }
.help-list li, .help-steps li { margin: .3rem 0; }
.help-faq { border-bottom: 1px solid var(--line); padding: .5rem 0; }
.help-faq summary { cursor: pointer; font-weight: 600; min-height: 32px; }
.help-faq p { margin: .4rem 0 .2rem; }
code { background: #eef3f0; padding: .05rem .35rem; border-radius: 5px; font-size: .85em; }
@media (max-width: 720px) { .help-toc ul { columns: 1; } }
@media print { .help-page, .card { break-inside: avoid; box-shadow: none; } .help-faq[open] summary ~ * { display: block; } }
