:root {
  --primary: #4f46e5;
  --primary-dark: #3730a3;
  --bg: #f4f5fb;
  --card: #ffffff;
  --text: #1c2033;
  --muted: #6b7288;
  --line: #e4e6f0;
  --red: #e5484d;
  --green: #12855f;
  --orange: #c26a00;
  --teal: #0e7490;
  --purple: #7c3aed;
  --radius: 16px;
  --shadow: 0 8px 24px rgba(28, 32, 51, 0.08);
  --nav-h: 72px;
  --top-h: 56px;
  --safe-b: env(safe-area-inset-bottom, 0px);
  --safe-t: env(safe-area-inset-top, 0px);
}

* { box-sizing: border-box; margin: 0; padding: 0; }
html {
  height: auto;
  max-width: 100%;
  overflow-x: hidden;
  overflow-y: auto;
  scroll-behavior: auto;
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
}
body {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  background: var(--bg);
  color: var(--text);
  line-height: 1.45;
  -webkit-tap-highlight-color: transparent;
  height: auto;
  max-width: 100%;
  overflow-x: hidden;
  overflow-y: auto;
  overscroll-behavior-y: contain;
  overflow-anchor: none;
}
html.sheet-open,
html.confirm-open,
body.sheet-open,
body.confirm-open {
  overflow: hidden;
  overscroll-behavior: none;
}
body.sheet-open #app { pointer-events: none; }
body.sheet-open.map-page #haritaEl { pointer-events: auto; }
body.sheet-open #scrim { pointer-events: auto; touch-action: pan-y; }
body.confirm-open #cscrim { pointer-events: auto; touch-action: pan-y; }
button, input, select, textarea { font-family: inherit; color: inherit; }
input, select, textarea { font-size: 16px !important; }
button { cursor: pointer; border: 0; background: none; font-size: inherit; touch-action: manipulation; }
img { max-width: 100%; height: auto; }
a { color: var(--primary); }
a.card, a.logo, a.nav-btn, a.nav-add, a.icon-btn, a.due-banner {
  text-decoration: none;
  color: inherit;
}
a.card { display: block; }
a.item-title { text-decoration: none; color: inherit; }
a.btn { text-decoration: none; color: #fff; }
a.btn.ghost { color: var(--text); }
.page-back { margin: 0 0 10px; }
.page-back a {
  display: inline-block;
  min-height: 40px;
  line-height: 40px;
  font-weight: 700;
  text-decoration: none;
  color: #4f46e5;
}

#app {
  max-width: 720px;
  width: 100%;
  margin: 0 auto;
  position: relative;
  padding-top: calc(var(--top-h) + var(--safe-t));
  padding-bottom: calc(var(--nav-h) + var(--safe-b) + 22px);
  transform: none;
  filter: none;
}
#app[hidden], [hidden] { display: none !important; }
html.authed #lock { display: none !important; }
html.authed #app[hidden] { display: block !important; }

/* —— Üst bar —— */
#topbar {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  width: 100%;
  max-width: none;
  margin: 0;
  min-height: calc(var(--top-h) + var(--safe-t));
  height: auto;
  padding: var(--safe-t) 16px 0;
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 8px;
  background: #fff;
  border-bottom: 1px solid var(--line);
  z-index: 20;
  transform: none;
  filter: none;
}
.nav-back-btn {
  flex: 0 0 auto;
  background: none;
  border: 0;
  color: #4f46e5;
  font-weight: 800;
  font-size: 15px;
  min-height: 40px;
  padding: 0 8px 0 0;
  white-space: nowrap;
  cursor: pointer;
  max-width: 100%;
}
.nav-back-btn[hidden] { display: none !important; }
.suggest-box {
  position: absolute;
  left: 0;
  right: 0;
  top: 100%;
  z-index: 8;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 12px;
  box-shadow: var(--shadow);
  max-height: 220px;
  overflow-y: auto;
  margin-top: 4px;
}
.suggest-item {
  display: block;
  width: 100%;
  text-align: left;
  background: none;
  border: 0;
  border-bottom: 1px solid var(--line);
  padding: 12px 14px;
  min-height: 44px;
  font-weight: 600;
  color: #1c2033;
}
.suggest-item:last-child { border-bottom: 0; }
.home-alert .card-hit {
  display: block;
  color: inherit;
  text-decoration: none;
  margin-bottom: 8px;
}
.logo {
  display: inline-flex;
  align-items: center;
  flex: 1 1 auto;
  min-width: 0;
  max-width: min(200px, calc(100% - 168px));
  overflow: hidden;
  font-weight: 800;
  font-size: 17px;
  letter-spacing: -0.02em;
  cursor: pointer;
  color: var(--text);
  background: none;
  padding: 4px 10px 4px 0;
  min-height: 40px;
}
.logo svg { color: var(--primary); flex-shrink: 0; }
.logo img {
  height: 34px;
  width: auto;
  max-height: 36px;
  max-width: 100%;
  display: block;
  object-fit: contain;
  object-position: left center;
}
.top-actions { display: flex; align-items: center; gap: 8px; }
.user-chip {
  font-size: 13px;
  color: var(--muted);
  max-width: 88px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.icon-btn {
  width: 40px; height: 40px;
  border-radius: 12px;
  background: var(--bg);
  color: var(--text);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}
.icon-btn svg { display: block; }

.due-banner {
  position: fixed;
  top: calc(var(--top-h) + var(--safe-t));
  left: 0;
  right: 0;
  width: 100%;
  max-width: none;
  margin: 0;
  z-index: 19;
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 10px 14px;
  background: #fff7ed;
  color: var(--orange);
  font-size: 13px;
  font-weight: 700;
  border: 0;
  border-bottom: 1px solid #fed7aa;
  text-align: left;
  cursor: pointer;
}
.due-banner svg { flex-shrink: 0; }
#app.has-banner { padding-top: calc(var(--top-h) + var(--safe-t) + 44px); }

/* —— Ana görünüm —— */
#view {
  padding: 14px 10px 16px;
  width: 100%;
  max-width: 100%;
  min-width: 0;
  overflow-wrap: anywhere;
  min-height: calc(100vh - var(--top-h) - var(--safe-t) - var(--nav-h) - var(--safe-b));
  min-height: calc(100dvh - var(--top-h) - var(--safe-t) - var(--nav-h) - var(--safe-b));
}
#app.has-banner #view {
  min-height: calc(100vh - var(--top-h) - var(--safe-t) - var(--nav-h) - var(--safe-b) - 44px);
  min-height: calc(100dvh - var(--top-h) - var(--safe-t) - var(--nav-h) - var(--safe-b) - 44px);
}

.cal-cta {
  margin-bottom: 12px;
}
.cal-buay {
  background: #fff;
  border-radius: 16px;
  padding: 14px;
  margin-bottom: 14px;
  box-shadow: var(--shadow);
}
.cal-buay-title {
  font-size: 18px;
  font-weight: 800;
  margin: 0 0 10px;
  color: #1c2033;
}
.cal-focus { margin-bottom: 10px; }
.cal-focus-hit {
  display: block;
  width: 100%;
  max-width: 100%;
  text-align: left;
  background: none;
  border: 0;
  padding: 0;
  color: inherit;
  min-height: 44px;
}
.cal-now-pill {
  background: #4f46e5;
  color: #fff;
  flex-shrink: 0;
}
.cal-cat-btn {
  margin-top: 8px;
}
.cal-oneri {
  margin: 8px 0 0;
  font-size: 13px;
  line-height: 1.4;
  word-break: break-word;
}

.home-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
  margin-bottom: 12px;
  max-width: 100%;
}
@media (min-width: 520px) {
  .home-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}
.home-tile {
  margin-bottom: 0;
  min-height: 96px;
  padding: 12px;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  justify-content: flex-start;
  gap: 4px;
  text-align: left;
}
button.home-tile.card.tap { display: flex; }
a.home-tile { color: inherit; }
.home-tile .item-title { font-size: 13px; line-height: 1.3; }
.home-tile .pill { margin-top: 4px; }
.home-tile-warn { box-shadow: 0 8px 24px rgba(229, 72, 77, 0.12); }

.page-title {
  font-size: 22px;
  font-weight: 800;
  margin-bottom: 12px;
  letter-spacing: -0.03em;
  overflow-wrap: anywhere;
  word-break: break-word;
}

.muted { color: var(--muted); font-size: 13px; }
.small { font-size: 12px; color: var(--muted); }

/* —— Kart —— */
.card {
  background: var(--card);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: 14px;
  margin-bottom: 10px;
  max-width: 100%;
  min-width: 0;
  overflow-wrap: anywhere;
  word-break: break-word;
}
.card.tap { cursor: pointer; }
.card.tap:active { transform: none; }
button.card.tap {
  width: 100%;
  text-align: left;
  font: inherit;
  color: inherit;
  appearance: none;
  -webkit-appearance: none;
  display: block;
}

.row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  flex-wrap: wrap;
  min-width: 0;
  max-width: 100%;
}
.row > * { min-width: 0; max-width: 100%; }

/* —— İstatistik —— */
.stats {
  display: grid;
  grid-template-columns: 1fr 1fr 1fr;
  gap: 8px;
  margin-bottom: 12px;
  min-width: 0;
  max-width: 100%;
}
.stat {
  background: var(--card);
  border-radius: 14px;
  padding: 12px 8px;
  text-align: center;
  box-shadow: var(--shadow);
}
a.stat {
  text-decoration: none;
  color: inherit;
  display: block;
}
.stat .n {
  font-size: 16px;
  font-weight: 800;
  letter-spacing: -0.03em;
  word-break: break-word;
}
.stat.tahsil .n { color: #4f46e5; }
.stat.bekleyen .n { color: #e5484d; }
.stat.gider .n { color: #e5484d; }

.home-alert {
  border: 1px solid rgba(229, 72, 77, 0.35);
  margin-bottom: 10px;
}
.home-alert .item-title { color: #e5484d; font-size: 14px; }
button.card.tap.home-alert {
  display: block;
  width: 100%;
  text-align: left;
}
.ay-kapanis-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  flex-wrap: wrap;
  margin-bottom: 10px;
  min-width: 0;
  max-width: 100%;
}
.ay-kapanis-row .ay-geri-al {
  min-height: 36px;
  padding: 6px 10px;
  font-size: 13px;
  font-weight: 600;
  white-space: nowrap;
}
.btn.block[data-act="ay-kapat"] {
  margin-bottom: 10px;
  white-space: normal;
}

.pay-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 42px;
  padding: 8px 14px;
  border-radius: 12px;
  font-weight: 800;
  font-size: 14px;
  color: #fff;
  width: 100%;
  max-width: 100%;
  border: 0;
}
.pay-btn-on { background: #4f46e5; }
.pay-btn-off { background: #e5484d; }
.pay-btn.locked { opacity: 0.72; pointer-events: none; }
.pay-tag {
  display: inline-block;
  pointer-events: none;
  user-select: none;
  font-weight: 800;
  font-size: 12px;
  line-height: 1.2;
  padding: 4px 10px;
  border-radius: 999px;
  color: #fff;
  margin-top: 6px;
  max-width: 100%;
}
.pay-tag-on { background: #4f46e5; }
.pay-tag-off { background: #e5484d; }
a.card-hit {
  display: block;
  color: inherit;
  text-decoration: none;
  min-width: 0;
}
.locked-card { opacity: 0.85; }

.group-h.warn { color: #e5484d; }
.group-h.soon { color: #0e7490; }
.group-h.done { color: #12855f; }

/* —— 3 durum tek sıra —— */
.stage-row {
  display: grid;
  grid-template-columns: 1fr 1fr 1fr;
  gap: 8px;
  margin-bottom: 12px;
}
.stage-cell {
  background: var(--card);
  border-radius: 12px;
  padding: 10px 8px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 4px;
  box-shadow: var(--shadow);
  min-width: 0;
  text-align: center;
}
.stage-cell .lab {
  font-size: 12px;
  font-weight: 600;
  white-space: normal;
  text-align: center;
}
.stage-cell .cnt {
  font-weight: 800;
  font-size: 16px;
}

/* —— Butonlar —— */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  min-height: 44px;
  padding: 10px 14px;
  border-radius: 12px;
  font-weight: 700;
  font-size: 14px;
  background: var(--primary);
  color: #fff;
  white-space: nowrap;
  max-width: 100%;
}
.btn.ghost {
  background: var(--bg);
  color: var(--text);
  border: 1px solid var(--line);
}
.btn.ok { background: var(--green); color: #fff; }
.btn.wa { background: #128c7e; color: #fff; }
.btn.mail { background: var(--teal); color: #fff; }
.btn.danger { background: var(--red); color: #fff; }
.btn.teal { background: var(--teal); color: #fff; }
.btn.block { width: 100%; }
.btn:disabled { opacity: 0.5; }
.btn svg, .btn-row > a.btn svg { flex-shrink: 0; pointer-events: none; }
.btn-row .btn, .btn-row a.btn { white-space: normal; text-decoration: none; }
.gd-actions .btn { flex: 1 1 40%; }

.btn-row {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 10px;
}
.btn-row > .btn { flex: 1 1 calc(50% - 8px); min-width: 0; max-width: 100%; }
.btn-row.tight > .btn { flex: 1 1 auto; min-width: 0; }

/* —— Etiket / pill —— */
.pill {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 4px 10px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 700;
  background: var(--bg);
  color: var(--text);
  max-width: 100%;
  overflow-wrap: anywhere;
  white-space: normal;
}
.pill svg { flex-shrink: 0; }
.pill.gorusuldu { background: #ecfeff; color: var(--teal); }
.pill.anlasti { background: #ecfdf5; color: var(--green); }
.pill.olumsuz { background: #fef2f2; color: var(--red); }
.pill.teklif { background: #fff7ed; color: var(--orange); }
.pill.pri-cokyuksek { background: #fef2f2; color: #e5484d; }
.pill.pri-yuksek { background: #fff7ed; color: #c26a00; }
.pill.pri-ortayuksek { background: #ecfeff; color: #0e7490; }
.pill.pri-orta { background: #eef2ff; color: #4f46e5; }

.season-note {
  font-size: 12px;
  color: var(--muted);
  margin-top: 6px;
}
.pill.kendi { background: #eef2ff; color: var(--primary); }
.pill.partner { background: #fff7ed; color: var(--orange); }
.pill.bos { background: #ecfdf5; color: var(--green); }
.pill.dolu { background: #fef2f2; color: var(--red); }

.chips {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin: 8px 0 12px;
}
.chip {
  min-height: 36px;
  padding: 6px 12px;
  border-radius: 999px;
  background: #fff;
  border: 1px solid var(--line);
  font-size: 13px;
  font-weight: 600;
  display: inline-flex;
  align-items: center;
  text-decoration: none;
  color: inherit;
}
.chip.on {
  background: var(--primary);
  color: #fff;
  border-color: var(--primary);
}

/* —— Form —— */
.field { margin-bottom: 12px; position: relative; }
.field label {
  display: block;
  font-size: 12px;
  font-weight: 700;
  color: var(--muted);
  margin-bottom: 6px;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}
.field input, .field select, .field textarea {
  width: 100%;
  min-height: 44px;
  padding: 10px 12px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: #fff;
  outline: none;
  font-size: 16px;
}
.field textarea { min-height: 88px; resize: vertical; }
.field input:focus, .field select:focus, .field textarea:focus {
  border-color: var(--primary);
  box-shadow: 0 0 0 3px rgba(79, 70, 229, 0.15);
}

.seg {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}
.seg button {
  flex: 1 1 calc(33.33% - 6px);
  min-height: 40px;
  border-radius: 10px;
  border: 1px solid var(--line);
  background: #fff;
  font-size: 13px;
  font-weight: 600;
}
.seg button.on { background: var(--primary); color: #fff; border-color: var(--primary); }

.pay-toggle {
  display: inline-flex;
  align-items: center;
  background: transparent;
  border: 0;
  padding: 0;
  min-height: 36px;
}
.pay-toggle .pill {
  font-size: 14px;
  padding: 8px 14px;
}

.check-line {
  display: flex;
  align-items: center;
  gap: 10px;
  min-height: 44px;
  padding: 4px 0;
  font-weight: 700;
  cursor: pointer;
}
.check-line input[type="checkbox"] {
  width: 22px;
  height: 22px;
  flex-shrink: 0;
  accent-color: #4f46e5;
}

.search-wrap {
  position: relative;
  margin-bottom: 8px;
}
.search-wrap .search-ico {
  position: absolute;
  left: 12px;
  top: 50%;
  transform: translateY(-50%);
  color: var(--muted);
  display: flex;
  pointer-events: none;
}
.search {
  width: 100%;
  min-height: 44px;
  padding: 10px 14px 10px 40px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: #fff;
  font-size: 16px;
}
.search-wrap .search { margin-bottom: 0; }

/* —— Alt menü —— */
#bottomnav {
  position: fixed;
  left: 0;
  right: 0;
  bottom: 0;
  width: 100%;
  max-width: none;
  margin: 0;
  height: calc(var(--nav-h) + var(--safe-b));
  padding: 6px 4px env(safe-area-inset-bottom, 0px);
  display: flex;
  align-items: stretch;
  justify-content: space-between;
  background: #fff;
  border-top: 1px solid var(--line);
  z-index: 20;
  transform: none;
  filter: none;
  will-change: auto;
  overflow: visible;
  box-sizing: border-box;
}
.nav-side {
  flex: 1 1 0;
  min-width: 0;
  display: flex;
  align-items: stretch;
  transform: none;
  filter: none;
  overflow: visible;
}
.nav-btn {
  flex: 1 1 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: flex-start;
  gap: 2px;
  padding: 6px 2px 0;
  font-size: 10px;
  font-weight: 600;
  color: var(--muted);
  min-width: 0;
  max-width: none;
  overflow: visible;
}
.nav-btn span:last-child {
  max-width: 100%;
  overflow: hidden;
  text-align: center;
  line-height: 1.15;
  white-space: nowrap;
  text-overflow: ellipsis;
}
.nav-btn.active { color: var(--primary); font-weight: 800; }
.nav-ico {
  display: flex;
  align-items: center;
  justify-content: center;
  height: 22px;
  line-height: 1;
  flex: 0 0 auto;
}
.nav-add-slot {
  flex: 0 0 56px;
  width: 56px;
  position: relative;
  overflow: visible;
  transform: none;
  filter: none;
  pointer-events: none;
}
.nav-add {
  position: absolute;
  left: 50%;
  bottom: 22px;
  width: 52px;
  height: 52px;
  margin-left: -26px;
  border-radius: 50%;
  background: var(--primary);
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 8px 20px rgba(79, 70, 229, 0.4);
  transform: translateY(-22px);
  z-index: 21;
  pointer-events: auto;
}
.nav-add-label {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 6px;
  font-size: 10px;
  font-weight: 600;
  color: var(--muted);
  text-align: center;
  line-height: 1.15;
  pointer-events: none;
}

/* —— Bottom sheet —— */
#scrim {
  position: fixed;
  inset: 0;
  background: rgba(28, 32, 51, 0.45);
  z-index: 40;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: flex-end;
  padding-top: var(--safe-t);
  overflow: hidden;
  overscroll-behavior: none;
}
#sheet {
  width: 100%;
  max-width: 720px;
  max-height: 90vh;
  max-height: 90dvh;
  max-height: 90svh;
  min-height: 0;
  background: var(--bg);
  border-radius: 20px 20px 0 0;
  overflow-x: hidden;
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
  overscroll-behavior: contain;
  touch-action: pan-y;
  padding: 0;
  padding-bottom: calc(24px + env(safe-area-inset-bottom, 0px));
  animation: none;
}
.sheet-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 8px;
  padding: 10px 14px 12px;
  position: sticky;
  top: 0;
  background: var(--bg);
  z-index: 2;
}
.sheet-head-right { display: flex; align-items: center; gap: 6px; }
.sheet-head > button,
.sheet-head-right > button:not(.icon-btn) {
  min-height: 44px;
  padding: 8px 12px;
  border-radius: 10px;
  font-weight: 700;
  color: var(--primary);
  background: #fff;
  display: inline-flex;
  align-items: center;
  gap: 4px;
}
.sheet-head .icon-btn {
  background: #fff;
  color: var(--primary);
  border: 1px solid var(--line);
}
#sheetBody {
  padding: 4px 14px 16px;
  min-width: 0;
}
#sheetBody h2 {
  font-size: 20px;
  font-weight: 800;
  margin: 0 0 12px;
  padding-top: 2px;
  letter-spacing: -0.03em;
  overflow-wrap: anywhere;
  word-break: break-word;
}
.preview-val {
  font-size: 16px;
  font-weight: 600;
  line-height: 1.4;
  overflow-wrap: anywhere;
  word-break: break-word;
}

@keyframes sheetUp {
  from { opacity: 0.55; }
  to { opacity: 1; }
}

/* —— Onay modalı —— */
#cscrim {
  position: fixed;
  inset: 0;
  background: rgba(28, 32, 51, 0.5);
  z-index: 100;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: calc(20px + var(--safe-t)) 20px calc(20px + var(--safe-b));
  pointer-events: auto;
  overflow-x: hidden;
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
  overscroll-behavior: contain;
  touch-action: pan-y;
}
body.confirm-open #scrim,
body.confirm-open #sheet {
  pointer-events: none !important;
}
#cbox {
  width: 100%;
  max-width: 360px;
  max-height: min(90vh, 90dvh);
  overflow-x: hidden;
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
  overscroll-behavior: contain;
  background: #fff;
  border-radius: 18px;
  padding: 20px;
  box-shadow: 0 20px 50px rgba(0,0,0,0.2);
  pointer-events: auto;
  position: relative;
  z-index: 2;
}
#cbox h3 { font-size: 18px; margin-bottom: 8px; }
#cbox p { color: var(--muted); font-size: 14px; margin-bottom: 16px; }
.c-actions { display: flex; flex-wrap: wrap; gap: 8px; }
.c-actions .btn {
  flex: 1 1 120px;
  pointer-events: auto;
  position: relative;
  z-index: 3;
  touch-action: manipulation;
  min-height: 48px;
}
#cYes svg, #cNo svg { pointer-events: none; }

/* —— Toast —— */
#toast {
  position: fixed;
  left: 16px;
  right: 16px;
  bottom: calc(var(--nav-h) + var(--safe-b) + 28px);
  margin: 0 auto;
  width: auto;
  max-width: 400px;
  background: var(--text);
  color: #fff;
  padding: 10px 16px;
  border-radius: 12px;
  font-size: 14px;
  font-weight: 600;
  z-index: 80;
  text-align: center;
  overflow-wrap: anywhere;
}

/* —— Giriş —— */
#lock {
  position: fixed;
  inset: 0;
  background: linear-gradient(165deg, #4f46e5 0%, #3730a3 55%, #1c2033 100%);
  z-index: 50;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: calc(20px + var(--safe-t)) 20px calc(20px + var(--safe-b));
  overflow-x: hidden;
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
}
.lock-card {
  width: 100%;
  max-width: 400px;
  background: #fff;
  border-radius: 20px;
  padding: 28px 22px 22px;
  box-shadow: 0 24px 60px rgba(0,0,0,0.25);
}
.lock-brand {
  width: 56px; height: 56px;
  border-radius: 16px;
  background: var(--primary);
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 12px;
}
.lock-brand svg { display: block; }
.lock-card h1 { font-size: 24px; font-weight: 800; margin-bottom: 4px; }
.lock-card .muted { margin-bottom: 18px; }
.lock-error {
  background: #fef2f2;
  color: var(--red);
  padding: 10px 12px;
  border-radius: 10px;
  font-size: 13px;
  font-weight: 600;
  margin-bottom: 10px;
}
.linkish {
  display: block;
  text-align: center;
  margin-top: 12px;
  color: var(--muted);
  font-size: 13px;
  font-weight: 600;
  width: 100%;
}

/* —— Liste öğeleri —— */
.item-title {
  font-weight: 800;
  font-size: 16px;
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 6px;
  min-width: 0;
  max-width: 100%;
  overflow-wrap: anywhere;
  word-break: break-word;
  white-space: normal;
}
.item-meta {
  font-size: 13px;
  color: var(--muted);
  margin-top: 4px;
  overflow-wrap: anywhere;
  word-break: break-word;
  max-width: 100%;
}
.hist {
  border-top: 1px solid var(--line);
  padding-top: 12px;
  margin-top: 8px;
}
.hist-item { padding: 10px 0; border-bottom: 1px solid var(--line); }
.hist-item:last-child { border-bottom: 0; }
.tags { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 6px; }

.collapse-btn {
  width: 100%;
  text-align: left;
  background: #fff;
  border: 1px dashed var(--line);
  border-radius: 12px;
  padding: 12px 14px;
  font-weight: 700;
  margin-bottom: 10px;
  display: flex;
  align-items: center;
  gap: 8px;
}
.group-h {
  font-size: 13px;
  font-weight: 800;
  color: var(--text);
  margin: 12px 0 6px;
  display: flex;
  align-items: center;
  gap: 6px;
  flex-wrap: wrap;
}

.quick {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}
.quick button {
  min-height: 36px;
  padding: 6px 10px;
  border-radius: 10px;
  background: #fff;
  border: 1px solid var(--line);
  font-size: 13px;
  font-weight: 600;
}
.quick button.on { background: var(--primary); color: #fff; border-color: var(--primary); }

.warn {
  background: #fff7ed;
  color: var(--orange);
  padding: 10px 12px;
  border-radius: 12px;
  font-size: 13px;
  font-weight: 600;
  margin-bottom: 10px;
}

.empty {
  text-align: center;
  padding: 28px 12px;
  color: var(--muted);
}

.subtabs {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-bottom: 12px;
}
.subtabs button,
.subtabs a {
  flex: 1 1 140px;
  min-height: 40px;
  border-radius: 12px;
  background: #fff;
  border: 1px solid var(--line);
  font-weight: 700;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  text-decoration: none;
  color: var(--text);
}
.subtabs button.on,
.subtabs a.on { background: var(--primary); color: #fff; border-color: var(--primary); }

.finans-sekme {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 8px;
  width: 100%;
  margin: 0 0 12px;
  box-sizing: border-box;
}
.finans-sekme a {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  min-width: 0;
  box-sizing: border-box;
  margin: 0;
  min-height: 40px;
  border-radius: 12px;
  background: #fff;
  border: 1px solid var(--line);
  font-weight: 700;
  font-size: 13px;
  line-height: 1.15;
  padding: 10px 6px;
  white-space: normal;
  text-align: center;
  text-decoration: none;
  color: var(--text);
}
.finans-sekme a.on {
  background: var(--primary);
  color: #fff;
  border-color: var(--primary);
}

body.map-page {
  overflow: hidden;
}
body.map-page #app {
  height: 100vh;
  height: 100dvh;
  overflow: visible;
  display: flex;
  flex-direction: column;
  padding-bottom: calc(var(--nav-h) + var(--safe-b) + 22px);
}
body.map-page #view {
  padding: 8px 8px 0;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  flex: 1 1 auto;
  min-height: 0;
  height: auto;
}
body.map-page #app.has-banner #view {
  min-height: 0;
}
.harita-toolbar { flex: 0 0 auto; margin-bottom: 8px; }
.harita-filtre {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-bottom: 8px;
}
.harita-filtre button,
.harita-filtre select {
  min-height: 40px;
  border-radius: 12px;
  background: #fff;
  border: 1px solid var(--line);
  font-weight: 700;
  font-size: 13px;
  padding: 8px 10px;
  color: var(--text);
  min-width: 0;
}
.harita-filtre select { flex: 1 1 140px; }
.harita-filtre button.on {
  background: var(--primary);
  color: #fff;
  border-color: var(--primary);
}
.harita-filtre button.siteler-btn.on {
  background: #0e7490;
  border-color: #0e7490;
  color: #fff;
}
.harita-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-bottom: 8px;
}
.harita-actions .btn { flex: 1 1 140px; min-width: 0; white-space: normal; }
#haritaEl {
  flex: 1 1 auto;
  min-height: 220px;
  width: 100%;
  border-radius: 16px;
  overflow: hidden;
  background: #f4ead8;
  z-index: 1;
  position: relative;
}
#haritaEl .leaflet-control-container .leaflet-top,
#haritaEl .leaflet-control-container .leaflet-bottom { z-index: 8; }
.h-pin-wrap { background: none !important; border: none !important; }
.h-pin {
  display: flex;
  align-items: flex-end;
  gap: 4px;
  pointer-events: none;
}
.h-pin-ico { flex-shrink: 0; display: block; }
.h-pin-lab {
  pointer-events: none;
  border-radius: 8px;
  padding: 2px 6px;
  font-size: 11px;
  font-weight: 800;
  line-height: 1.2;
  box-shadow: 0 2px 8px rgba(28, 32, 51, 0.16);
  max-width: 132px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.hp-leaflet-pop .leaflet-popup-content {
  margin: 12px 14px;
  min-width: 0;
}
.hp-popup .field { margin-bottom: 8px; }
.hp-popup .btn-row { margin-top: 10px; }
.hp-palet {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}
.hp-swatch {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  border: 2px solid transparent;
  padding: 0;
  box-shadow: 0 0 0 1px rgba(28, 32, 51, 0.14);
  flex-shrink: 0;
}
.hp-swatch.on {
  border-color: #1c2033;
  box-shadow: 0 0 0 2px #fff, 0 0 0 4px var(--primary);
}
.hp-gorsel-list {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 8px;
}
.hp-gorsel-alani { position: relative; }
.hp-file {
  position: absolute;
  width: 1px;
  height: 1px;
  opacity: 0;
  overflow: hidden;
  pointer-events: none;
}
.hp-gorsel-item {
  position: relative;
  width: 72px;
  height: 72px;
}
.hp-gorsel-item img {
  width: 72px;
  height: 72px;
  object-fit: cover;
  border-radius: 10px;
  display: block;
  background: #eef0f7;
}
.hp-gorsel-sil {
  position: absolute;
  top: 2px;
  right: 2px;
  width: 24px;
  height: 24px;
  border-radius: 50%;
  border: 0;
  background: rgba(28, 32, 51, 0.78);
  color: #fff;
  font-size: 16px;
  line-height: 24px;
  padding: 0;
}
.hp-thumbs {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin: 8px 0;
}
.hp-mesafe { margin: 8px 0 4px; }
.hp-mesafe-bas {
  font-size: 11px;
  font-weight: 700;
  color: #6b7288;
  margin-bottom: 4px;
}
.hp-mesafe-list {
  list-style: none;
  margin: 0;
  padding: 0;
}
.hp-mesafe-list li {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 2px 4px;
  font-size: 13px;
  font-weight: 700;
  padding: 4px 0;
  border-bottom: 1px solid var(--line);
}
.hp-mesafe-list li:last-child { border-bottom: 0; }
.hp-mesafe-ico { font-size: 12px; line-height: 1; }
.hp-mesafe-m { font-weight: 600; color: #6b7288; }
.hp-mesafe-not {
  margin: 6px 0 0;
  font-size: 11px;
  color: #6b7288;
  font-weight: 600;
}
.hp-mesafe-daha {
  margin-top: 4px;
  border: 0;
  background: none;
  color: var(--primary);
  font-weight: 700;
  font-size: 13px;
  padding: 6px 0;
  min-height: 36px;
}
.hp-thumb {
  padding: 0;
  border: 0;
  background: none;
  border-radius: 8px;
  line-height: 0;
}
.hp-thumb img {
  width: 72px;
  height: 72px;
  object-fit: cover;
  border-radius: 8px;
  display: block;
  pointer-events: none;
  background: #eef0f7;
}
#hpLb {
  position: fixed;
  inset: 0;
  z-index: 2000;
  background: rgba(28, 32, 51, 0.88);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: calc(48px + var(--safe-t)) 44px calc(24px + var(--safe-b));
}
#hpLb[hidden] { display: none !important; }
#hpLbImg {
  max-width: 100%;
  max-height: 100%;
  object-fit: contain;
  border-radius: 8px;
}
.hp-lb-x,
.hp-lb-nav {
  position: absolute;
  border: 0;
  background: rgba(255, 255, 255, 0.16);
  color: #fff;
  font-size: 22px;
  font-weight: 700;
  line-height: 1;
  min-width: 40px;
  min-height: 40px;
  border-radius: 12px;
}
.hp-lb-x {
  top: calc(10px + var(--safe-t));
  right: 12px;
}
.hp-lb-nav { top: 50%; transform: translateY(-50%); }
.hp-lb-prev { left: 8px; }
.hp-lb-next { right: 8px; }
body.lightbox-open,
html.lightbox-open {
  overflow: hidden;
}
.harita-tip {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(96px, 1fr));
  gap: 6px;
  margin-bottom: 10px;
}
.harita-tip button {
  min-height: 40px;
  border-radius: 12px;
  background: #fff;
  border: 1px solid var(--line);
  font-weight: 700;
  font-size: 13px;
}
.harita-tip button.on {
  background: var(--primary);
  color: #fff;
  border-color: var(--primary);
}

.log-row {
  padding: 10px 0;
  border-bottom: 1px solid var(--line);
  font-size: 13px;
}
.log-row .who { font-weight: 700; display: inline-flex; align-items: center; gap: 6px; }

.as-blok-head {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-end;
  gap: 8px;
  margin-bottom: 10px;
}
.as-adet-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  margin-bottom: 10px;
}
.as-adet-row label {
  font-size: 12px;
  font-weight: 700;
  color: var(--muted);
  text-transform: uppercase;
  letter-spacing: 0.04em;
}
.as-adet-row input {
  width: 76px;
  min-height: 44px;
  padding: 10px 12px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: #fff;
  font-size: 16px;
}
.as-lift-wrap { margin-bottom: 8px; }
.as-lift-row {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 8px;
}
.as-lift-row input {
  flex: 1 1 auto;
  min-width: 0;
  min-height: 44px;
  padding: 10px 12px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: #fff;
  font-size: 16px;
}
.as-x {
  flex: 0 0 44px;
  width: 44px;
  height: 44px;
  border-radius: 12px;
  color: var(--red);
  background: #fef2f2;
  display: flex;
  align-items: center;
  justify-content: center;
}
.as-lift-line {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 6px 8px;
  background: var(--card);
  border-radius: 14px;
  padding: 10px 12px;
  margin-bottom: 8px;
  box-shadow: var(--shadow);
}
.as-lift-line .item-title {
  flex: 1 1 72px;
  min-width: 0;
}
.as-lift-line .tags { margin-top: 0; }
.as-lift-line > .btn {
  min-height: 36px;
  padding: 6px 10px;
  font-size: 13px;
  white-space: nowrap;
}
.as-lift-ads {
  width: 100%;
  display: flex;
  flex-direction: column;
  gap: 2px;
}
.as-lift-ads button {
  text-align: left;
  font-size: 13px;
  font-weight: 600;
  color: var(--text);
  padding: 4px 0;
  min-height: 32px;
}

@media (min-width: 640px) {
  .btn-row > .btn { flex: 1 1 calc(33.33% - 8px); }
}
