:root {
  --bg: #f6f7fb;
  --card: #ffffff;
  --ink: #161a23;
  --muted: #5d6475;
  --line: #e1e4ec;
  --accent: #0b6e4f;
  --accent-ink: #ffffff;
  --accent-soft: #e4f3ed;
  --warn: #b3261e;
}
@media (prefers-color-scheme: dark) {
  :root {
    --bg: #10131a;
    --card: #191d27;
    --ink: #eceef3;
    --muted: #a0a7b8;
    --line: #2b3140;
    --accent: #3ecf9b;
    --accent-ink: #06261b;
    --accent-soft: #15332a;
    --warn: #ff8a80;
  }
}
* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font: 16px/1.6 system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
}
a { color: var(--accent); }
.wrap { max-width: 880px; margin: 0 auto; padding: 0 16px; }

header.site { background: var(--card); border-bottom: 1px solid var(--line); }
header.site .wrap { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 24px; padding-top: 12px; padding-bottom: 12px; }
.logo { font-weight: 800; font-size: 22px; letter-spacing: -0.02em; color: var(--ink); text-decoration: none; }
.logo { display: inline-flex; align-items: center; gap: 9px; }
.logo svg { display: block; flex: none; }
.logo .ad span { color: var(--accent); }
nav.main { display: flex; flex-wrap: wrap; gap: 2px 14px; font-size: 14.5px; }
nav.main a { color: var(--muted); text-decoration: none; padding: 4px 0; }
nav.main a:hover, nav.main a[aria-current="page"] { color: var(--accent); }

main { padding: 28px 0 48px; }
h1 { font-size: clamp(26px, 5vw, 36px); line-height: 1.2; letter-spacing: -0.02em; margin: 0 0 8px; }
h2 { font-size: 22px; margin: 36px 0 8px; }
h3 { font-size: 17px; margin: 20px 0 4px; }
.lead { color: var(--muted); margin: 0 0 24px; max-width: 62ch; }

.card { background: var(--card); border: 1px solid var(--line); border-radius: 14px; padding: 20px; }
.grid { display: grid; gap: 16px; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); }
a.tool { display: block; text-decoration: none; color: inherit; transition: border-color .15s; }
a.tool:hover { border-color: var(--accent); }
a.tool strong { display: block; font-size: 18px; margin-bottom: 4px; }
a.tool span { color: var(--muted); font-size: 15px; }

.stat { display: flex; flex-wrap: wrap; align-items: baseline; gap: 4px 12px; background: var(--accent-soft); border-radius: 14px; padding: 16px 20px; margin-bottom: 24px; }
.stat b { font-size: 30px; color: var(--accent); letter-spacing: -0.02em; }

form.calc { display: grid; gap: 14px; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); align-items: end; }
label { display: block; font-size: 14px; font-weight: 600; margin-bottom: 4px; }
input, select {
  width: 100%; height: 46px; padding: 0 12px;
  font: inherit; color: var(--ink); background: var(--bg);
  border: 1px solid var(--line); border-radius: 10px;
}
input:focus, select:focus { outline: 2px solid var(--accent); outline-offset: 1px; }
button {
  height: 46px; padding: 0 20px; font: inherit; font-weight: 700; cursor: pointer;
  color: var(--accent-ink); background: var(--accent); border: 0; border-radius: 10px;
}
.result { margin-top: 18px; border-top: 1px solid var(--line); padding-top: 16px; }
.result[hidden] { display: none; }
.result dl { display: grid; grid-template-columns: 1fr auto; gap: 8px 16px; margin: 0; }
.result dt { color: var(--muted); }
.result dd { margin: 0; font-weight: 700; text-align: right; font-variant-numeric: tabular-nums; }
.result .big dt, .result .big dd { font-size: 20px; color: var(--ink); }
.result .big dd { color: var(--accent); }
.neg { color: var(--warn) !important; }
.error { color: var(--warn); margin: 12px 0 0; font-size: 15px; }
.note { color: var(--muted); font-size: 14px; margin-top: 12px; }

table { width: 100%; border-collapse: collapse; font-variant-numeric: tabular-nums; }
th, td { padding: 8px 10px; border-bottom: 1px solid var(--line); text-align: right; }
th:first-child, td:first-child { text-align: left; }
th { font-size: 14px; color: var(--muted); font-weight: 600; }
.scroll { overflow-x: auto; }

footer.site { border-top: 1px solid var(--line); color: var(--muted); font-size: 14px; padding: 20px 0 32px; }

footer.site p { margin: 0 0 6px; }
footer.site a { color: var(--muted); }

@media (max-width: 480px) {
  th, td { padding: 8px 5px; font-size: 14px; }
}

.result h3 { margin: 22px 0 10px; }
details summary { cursor: pointer; color: var(--accent); font-weight: 600; }
details[open] summary { margin-bottom: 8px; }

table.giris td { padding: 4px; }
table.giris td:first-child { white-space: nowrap; font-size: 14px; padding-right: 10px; }
table.giris input { height: 36px; min-width: 78px; padding: 0 8px; text-align: right; }
table.giris th { font-size: 12px; white-space: normal; min-width: 78px; }

.result table td { white-space: nowrap; }

#cerez-bildirim {
  position: fixed; left: 12px; right: 12px; bottom: 12px; z-index: 50;
  max-width: 720px; margin: 0 auto; padding: 14px 16px;
  display: flex; flex-wrap: wrap; align-items: center; gap: 10px 16px;
  background: var(--card); color: var(--ink); border: 1px solid var(--line); border-radius: 14px;
  box-shadow: 0 8px 30px rgba(0, 0, 0, .18); font-size: 14px;
}
#cerez-bildirim p { margin: 0; flex: 1 1 280px; }
#cerez-bildirim div { display: flex; gap: 8px; }
#cerez-bildirim button { height: 40px; padding: 0 16px; }
#cerez-bildirim button.ikincil { background: transparent; color: var(--ink); border: 1px solid var(--line); }
