/* =========================================================================
   AICO Portal — aicoelektronik.com tasarım sistemiyle aynı renkler
   ========================================================================= */
:root {
  --bg: #FAFAF7;
  --surface: #FFFFFF;
  --alt: #F3F2ED;
  --ink: #0F1012;
  --ink-2: #2B2D31;
  --muted: #62666E;
  --line: #E7E5DF;
  --line-2: #D9D6CE;
  --accent: #FF5E0E;
  --accent-ink: #D94A00;
  --accent-soft: #FFF2EA;
  --ok: #1F9D61;
  --ok-soft: #E6F6EE;
  --warn: #B7791F;
  --warn-soft: #FFF6DB;
  --bad: #D93B3D;
  --bad-soft: #FDECEC;
  --info: #2563EB;
  --info-soft: #EAF1FE;

  --side: #15171A;
  --side-2: #1A1C20;
  --side-line: #2A2D32;
  --side-text: #C9CED6;
  --side-muted: #9AA1AA;
  --live: #3DDC97;

  --sans: 'Plus Jakarta Sans', ui-sans-serif, system-ui, -apple-system, 'Segoe UI', sans-serif;
  --mono: 'Geist Mono', ui-monospace, 'SF Mono', Menlo, monospace;
  --r-sm: 8px;
  --r: 12px;
  --r-lg: 18px;
  --shadow: 0 1px 2px rgba(15, 16, 18, .04), 0 8px 24px -12px rgba(15, 16, 18, .12);
  --shadow-lg: 0 2px 4px rgba(15, 16, 18, .04), 0 24px 60px -24px rgba(15, 16, 18, .28);
  --ease: cubic-bezier(.2, .7, .2, 1);
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0; background: var(--bg); color: var(--ink);
  font: 400 15px/1.55 var(--sans);
  -webkit-font-smoothing: antialiased;
}
img, svg { display: block; max-width: 100%; }
a { color: inherit; text-decoration: none; }
button, input, select, textarea { font: inherit; color: inherit; }
button { cursor: pointer; }
h1, h2, h3, h4 { margin: 0; font-weight: 600; letter-spacing: -0.02em; line-height: 1.15; }
p { margin: 0; }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; border-radius: 6px; }
::selection { background: var(--accent); color: #fff; }
.mono { font-family: var(--mono); font-size: .92em; letter-spacing: 0; }
.muted { color: var(--muted); }
.i { width: 18px; height: 18px; flex: none; }

/* ---------- Butonlar ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  height: 40px; padding: 0 16px; border-radius: 999px; border: 1px solid transparent;
  font-weight: 500; font-size: 14px; white-space: nowrap; background: none;
  transition: background .2s, box-shadow .2s, border-color .2s, transform .2s var(--ease);
}
.btn:active { transform: translateY(1px); }
.btn-accent { background: var(--accent); color: #fff; }
.btn-accent:hover { background: var(--accent-ink); }
.btn-dark { background: var(--ink); color: #fff; }
.btn-dark:hover { background: #26282C; }
.btn-ghost { border-color: var(--line-2); background: var(--surface); }
.btn-ghost:hover { border-color: var(--ink-2); }
.btn-sm { height: 32px; padding: 0 12px; font-size: 13px; }
.btn-ok { background: var(--ok); color: #fff; }
.btn-bad { background: var(--surface); color: var(--bad); border-color: #F2C4C5; }
.btn-bad:hover { background: var(--bad-soft); }
.icon-btn {
  width: 36px; height: 36px; border-radius: 10px; border: 1px solid var(--line);
  background: var(--surface); display: inline-grid; place-items: center;
}
.icon-btn:hover { border-color: var(--line-2); }

/* ---------- Giriş ---------- */
.login {
  min-height: 100vh; display: grid; grid-template-columns: 1.05fr 1fr;
}
.login-hero {
  background: var(--side); color: #fff; padding: 48px; position: relative; overflow: hidden;
  display: flex; flex-direction: column; justify-content: space-between; gap: 40px;
}
.login-hero::before {
  content: ""; position: absolute; inset: 0;
  background-image: linear-gradient(var(--side-line) 1px, transparent 1px), linear-gradient(90deg, var(--side-line) 1px, transparent 1px);
  background-size: 48px 48px; opacity: .35;
  mask-image: radial-gradient(ellipse at 30% 40%, #000 20%, transparent 75%);
}
.login-hero::after {
  content: ""; position: absolute; width: 520px; height: 520px; right: -160px; bottom: -200px;
  background: radial-gradient(circle, rgba(255, 94, 14, .35), transparent 65%);
}
.login-hero > * { position: relative; z-index: 1; }
.login-logo { width: 150px; }
.login-hero h1 { font-size: clamp(32px, 4vw, 52px); font-weight: 700; max-width: 14ch; }
.login-hero h1 em { font-style: normal; color: var(--accent); }
.login-hero p { color: var(--side-text); max-width: 46ch; margin-top: 16px; font-size: 16px; }
.live-pill {
  display: inline-flex; align-items: center; gap: 8px; font: 500 12px var(--mono);
  color: var(--side-text); border: 1px solid var(--side-line); padding: 6px 12px; border-radius: 999px; background: var(--side-2);
}
.dot { width: 8px; height: 8px; border-radius: 50%; background: var(--live); box-shadow: 0 0 0 4px rgba(61, 220, 151, .15); }
.login-stats { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; }
.login-stats div { border: 1px solid var(--side-line); background: rgba(26, 28, 32, .7); border-radius: var(--r); padding: 14px 16px; }
.login-stats b { display: block; font-size: 22px; }
.login-stats span { font-size: 12.5px; color: var(--side-muted); }

.login-panel { padding: 48px; display: flex; flex-direction: column; justify-content: center; max-width: 620px; width: 100%; margin: 0 auto; }
.login-panel h2 { font-size: 28px; }
.login-panel > p { color: var(--muted); margin: 8px 0 28px; }
.role-tabs { display: flex; gap: 6px; padding: 4px; background: var(--alt); border-radius: 999px; margin-bottom: 18px; }
.role-tabs button {
  flex: 1; border: 0; background: none; padding: 9px 10px; border-radius: 999px; font-weight: 500; font-size: 14px; color: var(--muted);
}
.role-tabs button[aria-selected="true"] { background: var(--surface); color: var(--ink); box-shadow: var(--shadow); }
.user-pick { display: grid; gap: 10px; }
.user-card {
  display: flex; align-items: center; gap: 14px; width: 100%; text-align: left;
  padding: 14px 16px; border-radius: var(--r); border: 1px solid var(--line); background: var(--surface);
  transition: border-color .2s, box-shadow .2s, transform .2s var(--ease);
}
.user-card:hover { border-color: var(--accent); box-shadow: var(--shadow); transform: translateY(-1px); }
.user-card .grow { flex: 1; min-width: 0; }
.user-card b { display: block; font-weight: 600; }
.user-card small { color: var(--muted); }
.demo-note { margin-top: 20px; font-size: 13px; color: var(--muted); padding: 12px 14px; border-radius: var(--r-sm); background: var(--alt); }

.avatar {
  width: 38px; height: 38px; border-radius: 50%; display: grid; place-items: center; flex: none;
  font-weight: 600; font-size: 13.5px; color: #fff; background: var(--ink-2);
}
.avatar.patron { background: var(--accent); }
.avatar.satis { background: #2F6FEB; }
.avatar.personel { background: #2A3038; }
.avatar.sm { width: 28px; height: 28px; font-size: 11px; }
.avatar.lg { width: 52px; height: 52px; font-size: 17px; }

/* ---------- Uygulama iskeleti ---------- */
.shell { display: grid; grid-template-columns: 252px 1fr; min-height: 100vh; }
.side {
  background: var(--side); color: var(--side-text); position: sticky; top: 0; height: 100vh;
  display: flex; flex-direction: column; padding: 20px 14px; gap: 18px; overflow-y: auto;
}
.side-brand { display: flex; align-items: center; justify-content: space-between; padding: 4px 8px 10px; }
.side-brand img { width: 104px; }
.side-brand span { font: 500 11px var(--mono); color: var(--side-muted); border: 1px solid var(--side-line); padding: 3px 8px; border-radius: 999px; }
.nav { display: grid; gap: 2px; }
.nav-label { font: 500 11px var(--mono); text-transform: uppercase; letter-spacing: .08em; color: var(--side-muted); padding: 10px 10px 6px; }
.nav a {
  display: flex; align-items: center; gap: 11px; padding: 9px 10px; border-radius: 10px; font-size: 14px; font-weight: 500;
  color: var(--side-text); transition: background .15s, color .15s;
}
.nav a:hover { background: var(--side-2); color: #fff; }
.nav a[aria-current="page"] { background: #232930; color: #fff; }
.nav a[aria-current="page"] .i { color: var(--accent); }
.nav .badge { margin-left: auto; background: var(--accent); color: #fff; font: 600 11px var(--mono); padding: 1px 7px; border-radius: 999px; }
.side-user {
  margin-top: auto; display: flex; align-items: center; gap: 10px; padding: 12px; border-radius: var(--r);
  background: var(--side-2); border: 1px solid var(--side-line);
}
.side-user .grow { flex: 1; min-width: 0; }
.side-user b { display: block; color: #fff; font-size: 13.5px; font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.side-user small { color: var(--side-muted); font-size: 12px; }
.side-user button { background: none; border: 1px solid var(--side-line); color: var(--side-text); width: 32px; height: 32px; border-radius: 8px; display: grid; place-items: center; }
.side-user button:hover { color: #fff; border-color: var(--side-muted); }

.main { min-width: 0; }
.topbar {
  position: sticky; top: 0; z-index: 20; background: rgba(250, 250, 247, .86); backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--line); height: 64px; display: flex; align-items: center; gap: 12px; padding: 0 32px;
}
.topbar h1 { font-size: 18px; }
.topbar .crumb { font: 500 12px var(--mono); color: var(--muted); }
.topbar .spacer { flex: 1; }
.menu-btn { display: none; }
.content { padding: 28px 32px 64px; max-width: 1320px; }

/* ---------- Kartlar ---------- */
.hello { display: flex; align-items: flex-end; justify-content: space-between; gap: 16px; margin-bottom: 24px; flex-wrap: wrap; }
.hello h2 { font-size: 28px; }
.hello p { color: var(--muted); margin-top: 6px; }
.grid { display: grid; gap: 16px; }
.kpis { grid-template-columns: repeat(4, minmax(0, 1fr)); margin-bottom: 16px; }
.cols-2 { grid-template-columns: minmax(0, 1.6fr) minmax(0, 1fr); }
.cols-2e { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--r-lg); padding: 20px; min-width: 0; }
.card-h { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 16px; }
.card-h h3 { font-size: 16px; }
.card-h a { font-size: 13px; color: var(--accent-ink); font-weight: 500; }
.kpi { position: relative; overflow: hidden; }
.kpi small { color: var(--muted); font-size: 13px; display: flex; align-items: center; gap: 8px; }
.kpi b { display: block; font-size: 26px; font-weight: 700; letter-spacing: -0.02em; margin-top: 10px; }
.kpi .sub { font-size: 12.5px; color: var(--muted); margin-top: 4px; }
.kpi .ico { width: 30px; height: 30px; border-radius: 9px; background: var(--accent-soft); color: var(--accent-ink); display: grid; place-items: center; }
.kpi.dark { background: var(--side); border-color: var(--side); color: #fff; }
.kpi.dark small, .kpi.dark .sub { color: var(--side-muted); }
.kpi.dark .ico { background: #232930; color: var(--accent); }

.empty { text-align: center; padding: 28px 12px; color: var(--muted); font-size: 14px; }

/* ---------- Tablolar ---------- */
.table-wrap { overflow-x: auto; margin: 0 -20px -20px; }
table { width: 100%; border-collapse: collapse; font-size: 14px; }
th { text-align: left; font: 500 11.5px var(--mono); text-transform: uppercase; letter-spacing: .06em; color: var(--muted); padding: 10px 20px; border-bottom: 1px solid var(--line); background: #FCFCFA; white-space: nowrap; }
td { padding: 12px 20px; border-bottom: 1px solid var(--line); vertical-align: middle; }
tr:last-child td { border-bottom: 0; }
tbody tr:hover td { background: #FCFCFA; }
td a.mono { white-space: nowrap; font-weight: 500; }
td a.mono:hover { color: var(--accent-ink); }
td.num, th.num { text-align: right; font-variant-numeric: tabular-nums; }
.who { display: flex; align-items: center; gap: 10px; white-space: nowrap; }
.who b { font-weight: 600; }
.row-actions { display: flex; gap: 6px; justify-content: flex-end; }

.tag {
  display: inline-flex; align-items: center; gap: 6px; font-size: 12px; font-weight: 600; padding: 3px 9px; border-radius: 999px;
  background: var(--alt); color: var(--ink-2); white-space: nowrap;
}
.tag::before { content: ""; width: 6px; height: 6px; border-radius: 50%; background: currentColor; opacity: .8; }
.tag.ok { background: var(--ok-soft); color: var(--ok); }
.tag.warn { background: var(--warn-soft); color: var(--warn); }
.tag.bad { background: var(--bad-soft); color: var(--bad); }
.tag.info { background: var(--info-soft); color: var(--info); }
.tag.acc { background: var(--accent-soft); color: var(--accent-ink); }
.tag.plain::before { display: none; }

/* ---------- Araç çubuğu ---------- */
.toolbar { display: flex; gap: 10px; flex-wrap: wrap; align-items: center; margin-bottom: 16px; }
.toolbar .spacer { flex: 1; }
.search {
  display: flex; align-items: center; gap: 8px; height: 40px; padding: 0 14px; border: 1px solid var(--line-2); border-radius: 999px;
  background: var(--surface); min-width: 240px; color: var(--muted);
}
.search input { border: 0; outline: 0; background: none; flex: 1; min-width: 0; color: var(--ink); }
.chips { display: flex; gap: 6px; flex-wrap: wrap; }
.chip { border: 1px solid var(--line-2); background: var(--surface); padding: 6px 12px; border-radius: 999px; font-size: 13px; font-weight: 500; color: var(--muted); }
.chip[aria-pressed="true"] { background: var(--ink); border-color: var(--ink); color: #fff; }

/* ---------- Çubuk grafikler ---------- */
.bars { display: grid; gap: 14px; }
.bar-row { display: grid; grid-template-columns: 150px 1fr auto; gap: 12px; align-items: center; font-size: 13.5px; }
.bar-row .who b { font-size: 13.5px; }
.bar { height: 10px; background: var(--alt); border-radius: 999px; overflow: hidden; position: relative; }
.bar i { display: block; height: 100%; background: var(--accent); border-radius: 999px; transition: width .6s var(--ease); }
.bar.ok i { background: var(--ok); }
.bar-row .val { font: 500 12.5px var(--mono); color: var(--muted); text-align: right; min-width: 92px; }


  background: conic-gradient(var(--accent) calc(var(--p) * 1%), var(--alt) 0); }

/* ---------- Listeler ---------- */
.list { display: grid; }
.list-item { display: flex; gap: 12px; align-items: flex-start; padding: 12px 0; border-bottom: 1px solid var(--line); }
.list-item:last-child { border-bottom: 0; padding-bottom: 0; }
.list-item:first-child { padding-top: 0; }
.list-item .grow { flex: 1; min-width: 0; }
.list-item b { font-weight: 600; font-size: 14px; }
.list-item p { font-size: 13.5px; color: var(--muted); margin-top: 2px; }
.date-box { width: 46px; flex: none; text-align: center; border: 1px solid var(--line); border-radius: 10px; padding: 4px 0; background: var(--bg); }
.date-box b { display: block; font-size: 17px; line-height: 1.1; }
.date-box small { font: 500 10.5px var(--mono); text-transform: uppercase; color: var(--accent-ink); }

.ann { padding: 18px 20px; border-radius: var(--r-lg); border: 1px solid var(--line); background: var(--surface); }
.ann.pinned { border-color: #FFD4BD; background: linear-gradient(180deg, var(--accent-soft), var(--surface) 70%); }
.ann-h { display: flex; align-items: center; gap: 10px; margin-bottom: 10px; }
.ann-h .grow { flex: 1; }
.ann h3 { font-size: 16.5px; margin-bottom: 6px; }
.ann p { color: var(--ink-2); white-space: pre-wrap; }

/* ---------- Kanban ---------- */
.kanban { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; align-items: start; }
.col { background: var(--alt); border-radius: var(--r-lg); padding: 12px; min-height: 120px; }
.col-h { display: flex; align-items: center; justify-content: space-between; padding: 4px 6px 12px; font-weight: 600; font-size: 14px; }
.col-h span { font: 500 12px var(--mono); color: var(--muted); }
.col.drag-over { outline: 2px dashed var(--accent); outline-offset: -2px; }
.task { background: var(--surface); border: 1px solid var(--line); border-radius: var(--r); padding: 12px 14px; margin-bottom: 10px; cursor: grab; }
.task:last-child { margin-bottom: 0; }
.task.dragging { opacity: .5; }
.task b { font-weight: 600; font-size: 14px; display: block; }
.task .meta { display: flex; align-items: center; gap: 8px; margin-top: 10px; font-size: 12.5px; color: var(--muted); flex-wrap: wrap; }
.task .meta .spacer { flex: 1; }
.task .move { display: flex; gap: 4px; margin-top: 10px; }
.task .move button { flex: 1; border: 1px solid var(--line); background: var(--bg); border-radius: 8px; font-size: 12px; padding: 4px 6px; color: var(--muted); }
.task .move button:hover { border-color: var(--accent); color: var(--accent-ink); }
.overdue { color: var(--bad); font-weight: 600; }

/* ---------- Ekip ---------- */
.people { grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); }
.person { display: flex; flex-direction: column; gap: 14px; }
.person-top { display: flex; gap: 12px; align-items: center; }
.person-top b { display: block; font-weight: 600; }
.person-top small { color: var(--muted); font-size: 13px; }
.person dl { margin: 0; display: grid; gap: 6px; font-size: 13px; }
.person dl div { display: flex; gap: 8px; color: var(--muted); align-items: center; }
.person dl a:hover { color: var(--accent-ink); }

/* ---------- Ürünler ---------- */
.products { grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); }
.product { display: flex; flex-direction: column; gap: 10px; }
.product .tagline { color: var(--muted); font-size: 14px; flex: 1; }
.product .eyebrow { font: 500 11.5px var(--mono); color: var(--accent-ink); text-transform: uppercase; letter-spacing: .06em; }
.product h3 { font-size: 19px; }
.product .stats { display: flex; gap: 18px; padding-top: 12px; border-top: 1px solid var(--line); }
.product .stats b { display: block; font-size: 16px; }
.product .stats small { font-size: 12px; color: var(--muted); }

/* ---------- Modal & formlar ---------- */
.modal-back {
  position: fixed; inset: 0; background: rgba(15, 16, 18, .45); z-index: 50; display: grid; place-items: center; padding: 16px;
  animation: fade .2s var(--ease);
}
.modal {
  background: var(--surface); border-radius: var(--r-lg); width: 100%; max-width: 560px; max-height: calc(100vh - 32px); overflow: auto;
  box-shadow: var(--shadow-lg); animation: pop .25s var(--ease);
}
.modal.wide { max-width: 760px; }
.modal-h { display: flex; align-items: center; justify-content: space-between; padding: 18px 22px; border-bottom: 1px solid var(--line); position: sticky; top: 0; background: var(--surface); z-index: 1; }
.modal-h h3 { font-size: 17px; }
.modal-b { padding: 20px 22px; display: grid; gap: 14px; }
.modal-f { display: flex; justify-content: flex-end; gap: 8px; padding: 14px 22px; border-top: 1px solid var(--line); background: #FCFCFA; position: sticky; bottom: 0; }
@keyframes fade { from { opacity: 0; } }
@keyframes pop { from { opacity: 0; transform: translateY(8px) scale(.98); } }

.field { display: grid; gap: 6px; }
.field label { font-size: 13px; font-weight: 600; color: var(--ink-2); }
.field input, .field select, .field textarea, .lines input, .lines select {
  width: 100%; height: 42px; padding: 0 12px; border: 1px solid var(--line-2); border-radius: 10px; background: var(--surface); outline: 0;
  transition: border-color .15s, box-shadow .15s;
}
.field textarea { height: auto; min-height: 96px; padding: 10px 12px; resize: vertical; }
.field input:focus, .field select:focus, .field textarea:focus, .lines input:focus, .lines select:focus { border-color: var(--accent); box-shadow: 0 0 0 3px var(--accent-soft); }
.row2 { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.check { display: flex; gap: 8px; align-items: center; font-size: 14px; }
.check input { width: 16px; height: 16px; accent-color: var(--accent); }

.lines { display: grid; gap: 8px; }
.line { display: grid; grid-template-columns: minmax(0, 2fr) 70px minmax(0, 1fr) 36px; gap: 8px; align-items: center; }
.line-head { font: 500 11px var(--mono); text-transform: uppercase; color: var(--muted); letter-spacing: .05em; }
.total-box { display: flex; justify-content: space-between; align-items: center; padding: 14px 16px; background: var(--alt); border-radius: var(--r); }
.total-box b { font-size: 20px; }

.detail dl { margin: 0; display: grid; grid-template-columns: 140px 1fr; gap: 10px 16px; font-size: 14px; }
.detail dt { color: var(--muted); }
.detail dd { margin: 0; font-weight: 500; }

/* ---------- Bildirim ---------- */
#toast {
  position: fixed; bottom: 20px; left: 50%; transform: translate(-50%, 20px); opacity: 0; pointer-events: none; z-index: 60;
  background: var(--ink); color: #fff; padding: 11px 18px; border-radius: 999px; font-size: 14px; font-weight: 500;
  box-shadow: var(--shadow-lg); transition: opacity .25s, transform .25s var(--ease); display: flex; gap: 8px; align-items: center;
}
#toast.show { opacity: 1; transform: translate(-50%, 0); }
#toast::before { content: ""; width: 8px; height: 8px; border-radius: 50%; background: var(--live); }

/* ---------- Duyarlı ---------- */
@media (max-width: 1100px) {
  .kpis { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .cols-2, .cols-2e { grid-template-columns: minmax(0, 1fr); }
}
@media (max-width: 900px) {
  .login { grid-template-columns: 1fr; }
  .login-hero { padding: 28px 16px; gap: 24px; }
  .login-hero p, .login-stats { display: none; }
  .login-logo { width: 120px; }
  .login-panel { padding: 32px 16px 48px; }
  .shell { grid-template-columns: 1fr; }
  .side { position: fixed; left: 0; top: 0; bottom: 0; width: 272px; z-index: 40; transform: translateX(-100%); transition: transform .25s var(--ease); }
  .shell.nav-open .side { transform: none; box-shadow: var(--shadow-lg); }
  .shell.nav-open::after { content: ""; position: fixed; inset: 0; background: rgba(15, 16, 18, .4); z-index: 30; }
  .menu-btn { display: inline-grid; }
  .topbar { padding: 0 16px; }
  .content { padding: 20px 16px 48px; }
  .kanban { grid-template-columns: minmax(0, 1fr); }
}
@media (max-width: 560px) {
  .kpis { grid-template-columns: minmax(0, 1fr); }
  .login-stats { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .login-stats b { font-size: 18px; }
  .row2 { grid-template-columns: 1fr; }
  .bar-row { grid-template-columns: 1fr auto; }
  .bar-row .bar { grid-column: 1 / -1; grid-row: 2; }
  .search { min-width: 0; flex: 1; }
  .hello h2 { font-size: 23px; }
  .topbar .crumb { display: none; }
  .line { grid-template-columns: 1fr 60px; }
  .line select { grid-column: 1 / -1; }
  .detail dl { grid-template-columns: 1fr; gap: 2px; }
  .detail dd { margin-bottom: 8px; }
  .modal-f { flex-wrap: wrap; }
}

/* =========================================================================
   Takvimler, stok ve satış
   ========================================================================= */
.cols-cal { grid-template-columns: minmax(0, 2fr) minmax(0, 1fr); align-items: start; }
.cal-bar { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 14px; }
.cal-bar h3 { font-size: 18px; text-transform: capitalize; }
.cal-nav { display: flex; gap: 6px; align-items: center; }
.cal-head, .cal-grid { display: grid; grid-template-columns: repeat(7, minmax(0, 1fr)); }
.cal-head span { font: 500 11px var(--mono); text-transform: uppercase; letter-spacing: .06em; color: var(--muted); padding: 0 8px 8px; }
.cal-grid { border-top: 1px solid var(--line); border-left: 1px solid var(--line); border-radius: var(--r); overflow: hidden; }
.cal-cell { min-height: 108px; padding: 6px; border-right: 1px solid var(--line); border-bottom: 1px solid var(--line); display: flex; flex-direction: column; gap: 3px; min-width: 0; }
.cal-cell.can-add { cursor: pointer; }
.cal-cell.can-add:hover { background: #FCFBF8; }
.cal-cell.out { background: var(--alt); }
.cal-cell.out .cal-num { color: var(--line-2); }
.cal-num { font: 500 12px var(--mono); color: var(--muted); width: 24px; height: 24px; display: grid; place-items: center; border-radius: 50%; }
.cal-cell.today .cal-num { background: var(--accent); color: #fff; font-weight: 600; }
.cal-ev {
  display: block; width: 100%; text-align: left; border: 0; border-left: 3px solid var(--line-2); border-radius: 5px; padding: 2px 6px;
  font-size: 11.5px; font-weight: 500; line-height: 1.45; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; background: var(--alt); color: var(--ink-2);
}
.cal-ev:hover { filter: brightness(.96); }
.cal-ev.meet { background: #EEF0F3; border-left-color: #6B7380; }
.cal-ev.meet.mine { background: var(--accent-soft); border-left-color: var(--accent); color: var(--accent-ink); }
.cal-ev.past { opacity: .6; }
.cal-ev.in { background: var(--ok-soft); border-left-color: var(--ok); color: #16774A; }
.cal-ev.out { background: var(--accent-soft); border-left-color: var(--accent); color: var(--accent-ink); }
.cal-ev.planned { background: var(--surface); border: 1px dashed currentColor; border-left-width: 3px; border-left-style: solid; }
.cal-more { font-size: 11px; color: var(--muted); padding-left: 4px; }
.cal-hint { font-size: 12.5px; margin-top: 10px; }
.legend { display: flex; gap: 16px; flex-wrap: wrap; margin-top: 12px; font-size: 12.5px; color: var(--muted); }
.legend span { display: inline-flex; align-items: center; gap: 6px; }
.lg { width: 14px; height: 10px; border-radius: 3px; display: inline-block; }
.lg.in { background: var(--ok); }
.lg.out { background: var(--accent); }
.lg.planned { border: 1px dashed var(--muted); }

.stack { display: flex; }
.stack .avatar { border: 2px solid var(--surface); margin-left: -8px; }
.stack .avatar:first-child { margin-left: 0; }
.avatar.more { background: var(--alt); color: var(--muted); }
.list-item b a:hover { color: var(--accent-ink); }

.row3 { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; }
.form-sec { font: 500 11.5px var(--mono); text-transform: uppercase; letter-spacing: .08em; color: var(--accent-ink); padding-top: 6px; border-top: 1px solid var(--line); margin-top: 4px; }
.form-sec:first-child { border-top: 0; margin-top: 0; padding-top: 0; }
.link-btn { border: 0; background: none; padding: 0; color: var(--accent-ink); font-weight: 600; font-size: 12.5px; margin-left: 8px; }
.link-btn:hover { text-decoration: underline; }
.pick { display: grid; grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); gap: 6px; }
.pick-item { display: flex; align-items: center; gap: 10px; padding: 8px 10px; border: 1px solid var(--line); border-radius: 10px; font-size: 13.5px; font-weight: 500; }
label.pick-item { cursor: pointer; }
label.pick-item:has(input:checked) { border-color: var(--accent); background: var(--accent-soft); }
.pick-item input { width: 16px; height: 16px; accent-color: var(--accent); margin: 0; }
.pick-item small { display: block; color: var(--muted); font-weight: 400; font-size: 12px; }

.seg { display: inline-flex; gap: 4px; padding: 4px; background: var(--alt); border-radius: 999px; justify-self: start; }
.seg label { position: relative; cursor: pointer; }
.seg input { position: absolute; opacity: 0; pointer-events: none; }
.seg span { display: block; padding: 8px 18px; border-radius: 999px; font-weight: 600; font-size: 14px; color: var(--muted); }
.seg input:checked + span { background: var(--surface); color: var(--ink); box-shadow: var(--shadow); }
.seg input:focus-visible + span { outline: 2px solid var(--accent); }
.conv { font-size: 12.5px; color: var(--muted); }
.conv b { color: var(--ink); }
.total-fx { gap: 12px; }
.total-fx .conv { display: block; margin-top: 2px; }
.total-fx b { font-size: 24px; }

.fx-card b { font-size: 21px; }
.fx-actions { display: flex; gap: 6px; margin-top: 12px; flex-wrap: wrap; }
.fx-btn { background: #232930; color: #fff; border-color: var(--side-line); }
.fx-btn:hover { background: #2E353E; }

@media (max-width: 1100px) { .cols-cal { grid-template-columns: minmax(0, 1fr); } }
@media (max-width: 560px) {
  .row3 { grid-template-columns: 1fr; }
  .cal-cell { min-height: 56px; padding: 3px; display: block; }
  .cal-num { width: 22px; height: 22px; font-size: 11px; margin-bottom: 2px; }
  .cal-ev { display: inline-block; width: 7px; height: 7px; padding: 0; border: 0; border-radius: 50%; font-size: 0; margin: 0 2px 0 0; vertical-align: middle; }
  .cal-ev.meet, .cal-ev.meet.mine, .cal-ev.out { background: var(--accent); }
  .cal-ev.meet { background: #6B7380; }
  .cal-ev.in { background: var(--ok); }
  .cal-ev.planned { background: none; border: 1.5px solid currentColor; }
  .cal-more { display: none; }
  .cal-head span { padding: 0 3px 6px; font-size: 10px; }
  .cal-bar h3 { font-size: 16px; }
}

/* =========================================================================
   Stok sekmeleri, parçalar ve Ar-Ge
   ========================================================================= */
.tabs { display: flex; gap: 4px; padding: 4px; background: var(--alt); border-radius: 14px; margin-bottom: 16px; overflow-x: auto; }
.tabs button {
  display: inline-flex; align-items: center; gap: 8px; border: 0; background: none; padding: 9px 14px; border-radius: 10px;
  font-weight: 600; font-size: 14px; color: var(--muted); white-space: nowrap;
}
.tabs button span { font: 500 11.5px var(--mono); background: var(--line); color: var(--muted); padding: 1px 7px; border-radius: 999px; }
.tabs button[aria-selected="true"] { background: var(--surface); color: var(--ink); box-shadow: var(--shadow); }
.tabs button[aria-selected="true"] .i { color: var(--accent); }
.tabs button[aria-selected="true"] span { background: var(--accent-soft); color: var(--accent-ink); }

.projects { grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); }
.proj { display: flex; flex-direction: column; gap: 12px; cursor: pointer; transition: border-color .2s, box-shadow .2s, transform .2s var(--ease); }
.proj:hover { border-color: var(--accent); box-shadow: var(--shadow); transform: translateY(-1px); }
.proj h3 { font-size: 17px; }
.proj-top { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; font-size: 12.5px; }
.proj-desc { font-size: 13.5px; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; flex: 1; }
.proj-prog { display: flex; justify-content: space-between; font-size: 12.5px; color: var(--muted); margin-bottom: 6px; }
.proj-prog b { color: var(--ink); }
.proj-foot { display: flex; align-items: center; gap: 12px; font-size: 13px; padding-top: 12px; border-top: 1px solid var(--line); }
.proj-foot .spacer { flex: 1; }
.proj-foot > span { display: inline-flex; align-items: center; gap: 4px; }
.proj-foot .i { width: 15px; height: 15px; }

.proj-head h2 { font-size: 26px; margin-top: 8px; }
.proj-meta { display: flex; flex-wrap: wrap; gap: 14px 32px; margin-top: 18px; padding-top: 16px; border-top: 1px solid var(--line); align-items: flex-start; }
.proj-meta > div { display: grid; gap: 6px; }
.proj-meta small { font-size: 12px; color: var(--muted); }
.proj-meta .grow { flex: 1; min-width: 200px; }

.dropzone {
  display: grid; justify-items: center; gap: 6px; text-align: center; padding: 22px 16px; border: 1.5px dashed var(--line-2); border-radius: var(--r);
  background: var(--bg); cursor: pointer; transition: border-color .2s, background .2s;
}
.dropzone:hover, .dropzone.drag-over { border-color: var(--accent); background: var(--accent-soft); }
.dropzone .i { width: 24px; height: 24px; color: var(--accent); }
.dropzone b { font-size: 14px; font-weight: 600; }
.dropzone small { font-size: 12.5px; color: var(--muted); }
.file-name { display: flex; align-items: center; gap: 10px; min-width: 230px; }
.file-name .i { color: var(--muted); }
.file-name b { display: block; font-weight: 600; font-size: 13.5px; overflow-wrap: anywhere; }
.file-name small { display: block; font-size: 12px; }
.bottleneck { color: var(--bad); }
.note-form { display: grid; gap: 8px; margin-bottom: 16px; }
.note-form textarea { width: 100%; min-height: 76px; padding: 10px 12px; border: 1px solid var(--line-2); border-radius: 10px; resize: vertical; outline: 0; }
.note-form textarea:focus { border-color: var(--accent); box-shadow: 0 0 0 3px var(--accent-soft); }
.note-form button { justify-self: end; }
.btn[disabled] { opacity: .45; cursor: not-allowed; }
.field input:disabled { background: var(--alt); color: var(--muted); }
td .mono { white-space: nowrap; }
td .row-actions { flex-wrap: nowrap; }

/* =========================================================================
   Ar-Ge: proje klasörleri ve istek listeleri
   ========================================================================= */
.i-xs { width: 13px; height: 13px; display: inline-block; vertical-align: -2px; }
.folders { grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); }
.folder { display: flex; flex-direction: column; gap: 12px; cursor: pointer; transition: border-color .2s, box-shadow .2s, transform .2s var(--ease); }
.folder:hover, .folder:focus-visible { border-color: var(--accent); box-shadow: var(--shadow); transform: translateY(-1px); }
.folder-top { display: flex; gap: 12px; align-items: center; }
.folder-top h3 { font-size: 17px; }
.folder-top small { font-size: 12.5px; }
.folder-ico { width: 44px; height: 44px; border-radius: 12px; background: var(--accent-soft); color: var(--accent); display: grid; place-items: center; flex: none; }
.folder-ico .i { width: 22px; height: 22px; }
.folder-ico.lg { width: 60px; height: 60px; border-radius: 16px; }
.folder-ico.lg .i { width: 30px; height: 30px; }
.folder-desc { font-size: 13.5px; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; flex: 1; }
.kind-row { display: flex; flex-wrap: wrap; gap: 6px; }
.kind-chip { display: inline-flex; align-items: center; gap: 6px; font-size: 12px; font-weight: 500; color: var(--ink-2); background: var(--alt); padding: 3px 9px; border-radius: 999px; }
.dotc { width: 8px; height: 8px; border-radius: 50%; display: inline-block; flex: none; }
.chip .dotc { margin-right: 6px; vertical-align: 0; }
.folder-new {
  display: grid; place-items: center; align-content: center; gap: 6px; min-height: 200px; text-align: center;
  border: 1.5px dashed var(--line-2); background: transparent; color: var(--muted); font: inherit; transition: border-color .2s, background .2s;
}
.folder-new:hover { border-color: var(--accent); background: var(--accent-soft); color: var(--accent-ink); }
.folder-new .i { width: 26px; height: 26px; }
.folder-new b { color: var(--ink); font-size: 15px; }
.folder-new small { font-size: 12.5px; }
.folder-head { display: flex; gap: 18px; align-items: flex-start; }
.folder-head h2 { font-size: 26px; margin-bottom: 4px; }
.folder-head .grow { flex: 1; min-width: 0; }

.ext {
  display: inline-grid; place-items: center; min-width: 46px; height: 30px; padding: 0 6px; border-radius: 7px; flex: none;
  font: 600 10px var(--mono); letter-spacing: .02em; color: #fff; background: #62666E;
}
.ext-altium { background: #D94A00; }
.ext-kod { background: #1F2937; }
.ext-excel { background: #1F7A45; }
.ext-pdf { background: #C8302F; }
.ext-word { background: #2563EB; }
.ext-sunum { background: #C2410C; }
.ext-gorsel { background: #7C3AED; }
.ext-arsiv { background: #A16207; }
.ext-model { background: #0E7490; }
.ext-metin, .ext-diger { background: #62666E; }
.link-strong { color: var(--accent-ink); font-weight: 600; }
.link-strong:hover { text-decoration: underline; }
.ext-link { font-size: 12.5px; color: var(--info); font-weight: 500; }
.ext-link:hover { text-decoration: underline; }
.preview-img { max-width: 100%; max-height: 70vh; margin: 0 auto; border-radius: var(--r); }

.item-add {
  display: grid; grid-template-columns: minmax(0, 2fr) minmax(0, 2fr) 70px minmax(0, 1fr) 64px auto; gap: 8px; align-items: center;
  margin-top: 16px; padding: 14px; border-radius: var(--r); background: var(--alt);
}
.item-add-title { grid-column: 1 / -1; display: flex; align-items: center; gap: 6px; font-size: 13px; font-weight: 600; color: var(--ink-2); }
.item-add input, .item-add select { height: 38px; padding: 0 10px; border: 1px solid var(--line-2); border-radius: 9px; background: var(--surface); outline: 0; min-width: 0; width: 100%; }
.item-add input:focus, .item-add select:focus { border-color: var(--accent); box-shadow: 0 0 0 3px var(--accent-soft); }
.reject-note { margin-top: 12px; padding: 10px 14px; border-radius: var(--r-sm); background: var(--bad-soft); color: var(--bad); font-size: 14px; }
.timeline { display: grid; gap: 14px; }
.tl-item { display: flex; gap: 10px; align-items: flex-start; position: relative; }
.tl-item b { display: block; font-size: 14px; font-weight: 600; }
.tl-item small { font-size: 12.5px; }
@media (max-width: 900px) {
  .item-add { grid-template-columns: 1fr 1fr; }
  .item-add input[name="name"], .item-add input[name="url"] { grid-column: 1 / -1; }
  .folder-head { flex-direction: column; }
}

/* Onay kartları ve açıklama kutusu */
.approvals { display: grid; gap: 12px; }
.approval { border: 1px solid var(--line); border-radius: var(--r); padding: 16px; display: grid; gap: 12px; background: var(--surface); }
.approval-h { display: flex; gap: 16px; align-items: flex-start; }
.approval-h .grow { flex: 1; min-width: 0; }
.approval-h h4 { font-size: 16px; font-weight: 600; margin-top: 4px; }
.approval-amt { text-align: right; display: grid; }
.approval-amt b { font-size: 20px; }
.approval-amt small { font-size: 12px; }
.approval-meta { display: flex; gap: 16px; align-items: center; flex-wrap: wrap; font-size: 13px; }
.approval-f { display: flex; gap: 8px; align-items: center; }
.approval-f .spacer { flex: 1; }
.desc-box { background: var(--alt); border-left: 3px solid var(--accent); border-radius: 0 var(--r-sm) var(--r-sm) 0; padding: 10px 14px; }
.desc-box span { display: block; font: 500 11px var(--mono); text-transform: uppercase; letter-spacing: .06em; color: var(--accent-ink); margin-bottom: 4px; }
.desc-box p { white-space: pre-wrap; font-size: 14px; color: var(--ink-2); }
.field textarea.tall { min-height: 130px; }
.field small.muted { font-size: 12.5px; }
.clamp2 { display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; max-width: 46ch; }
@media (max-width: 560px) { .approval-h { flex-direction: column; gap: 6px; } .approval-amt { text-align: left; } }

/* =========================================================================
   Giriş ekranı
   ========================================================================= */
.auth { min-height: 100vh; display: grid; grid-template-columns: minmax(0, 1.08fr) minmax(0, 1fr); background: var(--bg); }

/* Sol: marka alanı */
.auth-art {
  position: relative; overflow: hidden; isolation: isolate; color: #fff; background: #0E0F11;
  padding: 44px 56px 36px; display: flex; flex-direction: column; justify-content: space-between; gap: 40px; min-height: 100vh;
}
.auth-traces { position: absolute; inset: 0; width: 100%; height: 100%; color: #2A2D32; z-index: -1; }
.auth-glow {
  position: absolute; inset: 0; z-index: -1; pointer-events: none;
  background:
    radial-gradient(520px 420px at 88% 92%, rgba(255, 94, 14, .38), transparent 70%),
    radial-gradient(420px 360px at 8% 0%, rgba(47, 111, 235, .22), transparent 70%);
}
.auth-logo { width: 132px; }
.auth-copy { max-width: 520px; }
.auth-copy h1 { font-size: clamp(42px, 5vw, 68px); font-weight: 700; letter-spacing: -0.035em; line-height: 1.02; margin-top: 22px; }
.auth-copy h1 em { font-style: normal; color: var(--accent); }

.auth-foot { font-size: 12.5px; color: #6B7280; }

/* Sağ: form */
.auth-main { display: flex; align-items: center; justify-content: center; padding: 48px 24px; }
.auth-box { width: 100%; max-width: 410px; }
.auth-logo-m { display: none; width: 112px; margin-bottom: 28px; }
.auth-box h2 { font-size: 32px; font-weight: 700; letter-spacing: -0.03em; }
.auth-lead { color: var(--muted); margin: 8px 0 28px; font-size: 15px; }
.auth-form { display: grid; gap: 16px; }


.auth-field { display: grid; gap: 7px; }
.auth-field > span:first-child { font-size: 13px; font-weight: 600; color: var(--ink-2); }
.auth-input { position: relative; display: flex; align-items: center; }
.auth-input > .i { position: absolute; left: 15px; color: var(--muted); pointer-events: none; }
.auth-input input {
  width: 100%; height: 52px; padding: 0 48px 0 44px; border: 1px solid var(--line-2); border-radius: 14px; background: var(--surface);
  font-size: 15px; outline: 0; transition: border-color .15s, box-shadow .15s;
}
.auth-input input::placeholder { color: #A3A7AE; }
.auth-input input:focus { border-color: var(--accent); box-shadow: 0 0 0 4px var(--accent-soft); }
.auth-input:focus-within > .i { color: var(--accent); }
.pw-toggle { position: absolute; right: 8px; width: 36px; height: 36px; border: 0; background: none; border-radius: 9px; display: grid; place-items: center; color: var(--muted); }
.pw-toggle:hover { color: var(--ink); background: var(--alt); }
.auth-row { display: flex; align-items: center; justify-content: space-between; gap: 12px; font-size: 14px; }
.auth-link { color: var(--accent-ink); font-weight: 600; font-size: 13.5px; }
.auth-link:hover { text-decoration: underline; }
.auth-submit {
  height: 54px; border: 0; border-radius: 14px; background: var(--accent); color: #fff; font-weight: 600; font-size: 16px;
  display: inline-flex; align-items: center; justify-content: center; gap: 10px; margin-top: 4px;
  box-shadow: 0 10px 24px -10px rgba(255, 94, 14, .7); transition: background .2s, transform .2s var(--ease), box-shadow .2s;
}
.auth-submit:hover { background: var(--accent-ink); box-shadow: 0 14px 30px -12px rgba(255, 94, 14, .8); }
.auth-submit:active { transform: translateY(1px); }
.auth-submit .i { transition: transform .2s var(--ease); }
.auth-submit:hover .i { transform: translateX(3px); }


@media (max-width: 1100px) { .auth-art { padding: 36px 36px 28px; } }
@media (max-width: 900px) {
  .auth { grid-template-columns: 1fr; }
  .auth-art { display: none; }
  .auth-main { align-items: flex-start; padding: 40px 16px; min-height: 100vh;
    background: radial-gradient(400px 260px at 100% 0%, rgba(255, 94, 14, .12), transparent 70%), var(--bg); }
  .auth-logo-m { display: block; }
}
@media (max-width: 420px) { .auth-box h2 { font-size: 27px; } }

/* =========================================================================
   Proforma fatura
   ========================================================================= */
.approved-card { margin-bottom: 16px; border-color: #BFE6D2; background: linear-gradient(180deg, var(--ok-soft), var(--surface) 60%); }
.approved-card h3 { display: flex; align-items: center; gap: 8px; }
.approved-card h3 .i { color: var(--ok); }

.pf-overlay { position: fixed; inset: 0; z-index: 45; background: #E9E8E3; overflow-y: auto; padding: 0 16px 40px; }
.pf-bar { position: sticky; top: 0; z-index: 1; display: flex; align-items: center; gap: 8px; max-width: 840px; margin: 0 auto; padding: 14px 0; background: #E9E8E3; }
.pf-bar .spacer { flex: 1; }
.pf-warn { max-width: 840px; margin: 0 auto 12px; padding: 10px 14px; border-radius: var(--r-sm); background: var(--warn-soft); color: var(--warn); font-size: 13.5px; }
.pf-warn a { font-weight: 600; text-decoration: underline; }
.pf-page { max-width: 840px; margin: 0 auto; background: #fff; box-shadow: var(--shadow-lg); border-radius: 6px; }
.pf-hint { max-width: 840px; margin: 14px auto 0; font-size: 12.5px; color: var(--muted); text-align: center; }
body.pf-open { overflow: hidden; }

.pf { padding: 44px 48px; color: #111; font-size: 13px; line-height: 1.5; }
.pf-head { display: flex; justify-content: space-between; gap: 24px; padding-bottom: 20px; border-bottom: 3px solid var(--accent); }
.pf-brand { display: flex; gap: 16px; align-items: flex-start; }
.pf-brand img { width: 120px; }
.pf-co { display: grid; gap: 2px; font-size: 12px; color: #444; }
.pf-co b { font-size: 14px; color: #111; }
.pf-title { text-align: right; }
.pf-title h1 { font-size: 20px; letter-spacing: .04em; color: var(--accent-ink); }
.pf-title dl { margin: 10px 0 0; display: grid; grid-template-columns: auto auto; gap: 2px 12px; font-size: 12px; justify-content: end; }
.pf-title dt { color: #666; text-align: right; }
.pf-title dd { margin: 0; font-weight: 600; font-family: var(--mono); }
.pf-parties { display: grid; grid-template-columns: 1.4fr 1fr; gap: 24px; margin: 22px 0; }
.pf-parties > div { padding: 14px 16px; border: 1px solid #E3E1DA; border-radius: 8px; }
.pf-parties b { display: block; font-size: 14px; margin-bottom: 4px; }
.pf-parties p { color: #444; font-size: 12px; }
.pf-label { display: block; font: 500 10.5px var(--mono); text-transform: uppercase; letter-spacing: .08em; color: #888; margin-bottom: 4px; }
.pf-items { width: 100%; border-collapse: collapse; font-size: 12.5px; }
.pf-items th { background: #15171A; color: #fff; font: 500 10.5px var(--mono); text-transform: uppercase; letter-spacing: .06em; padding: 9px 10px; text-align: left; border: 0; }
.pf-items td { padding: 10px; border-bottom: 1px solid #ECEAE4; vertical-align: top; background: #fff !important; }
.pf-items td small { color: #777; }
.pf-items .num { text-align: right; white-space: nowrap; font-variant-numeric: tabular-nums; }
.pf-sum { margin: 14px 0 0 auto; width: 320px; display: grid; gap: 4px; }
.pf-sum > div { display: flex; justify-content: space-between; font-size: 13px; color: #444; }
.pf-sum b { color: #111; font-variant-numeric: tabular-nums; }
.pf-sum .pf-grand { margin-top: 6px; padding: 10px 12px; background: var(--accent-soft); border-radius: 6px; color: #111; font-weight: 600; }
.pf-sum .pf-grand b { font-size: 16px; color: var(--accent-ink); }
.pf-terms { display: grid; grid-template-columns: repeat(3, 1fr); gap: 14px 20px; margin-top: 26px; padding-top: 18px; border-top: 1px solid #E3E1DA; font-size: 12.5px; }
.pf-terms .pf-bank, .pf-terms .pf-note { grid-column: 1 / -1; }
.pf-terms .pf-note { white-space: pre-wrap; }
.pf-foot { display: flex; justify-content: space-between; align-items: flex-end; gap: 24px; margin-top: 30px; font-size: 11px; color: #777; }
.pf-foot p { max-width: 60ch; }
.pf-sign { width: 200px; height: 80px; border: 1px dashed #CCC; border-radius: 6px; display: flex; align-items: flex-end; justify-content: center; padding-bottom: 6px; }

@media (max-width: 700px) {
  .pf { padding: 24px 18px; }
  .pf-head { flex-direction: column; }
  .pf-title { text-align: left; }
  .pf-title dl { justify-content: start; }
  .pf-parties, .pf-terms { grid-template-columns: 1fr; }
  .pf-sum { width: 100%; }
  .pf-bar { flex-wrap: wrap; }
}

/* Yazdırma: yalnızca proforma sayfası */
@page { size: A4; margin: 12mm; }
@media print {
  body.pf-open > *:not(#print-root) { display: none !important; }
  body.pf-open { background: #fff; overflow: visible; }
  body.pf-open .pf-overlay { position: static; background: #fff; padding: 0; overflow: visible; }
  body.pf-open .pf-bar, body.pf-open .pf-warn, body.pf-open .pf-hint { display: none !important; }
  body.pf-open .pf-page { box-shadow: none; max-width: none; border-radius: 0; }
  body.pf-open .pf { padding: 0; }
  .pf-items th { -webkit-print-color-adjust: exact; print-color-adjust: exact; }
  .pf-sum .pf-grand, .pf-head { -webkit-print-color-adjust: exact; print-color-adjust: exact; }
}
.pf-sum .pf-rate { display: grid; gap: 2px; justify-content: end; justify-items: end; text-align: right; font-size: 11.5px; color: #777; margin-top: 4px; }

/* Şifre uyarısı */
.pw-banner { display: flex; align-items: center; gap: 12px; padding: 12px 16px; margin-bottom: 18px; border-radius: var(--r); background: var(--warn-soft); color: #7A5A12; font-size: 14px; border: 1px solid #F1DFA8; }
.pw-banner .i { color: var(--warn); flex: none; }
.pw-banner span { flex: 1; }
.side-user button + button { margin-left: -4px; }
