/* ═══════════════════ pencereler ve yeni bileşenler ═══════════════════ */

/* ── pencere ── */
.modal-layer { position: fixed; inset: 0; display: grid; place-items: center; padding: 20px; animation: fade-in .18s var(--ease); }
.modal-layer.is-leaving { animation: fade-out .16s var(--ease) forwards; }
.modal-backdrop { position: absolute; inset: 0; background: color-mix(in srgb, var(--night) 45%, transparent);
                  backdrop-filter: blur(3px); -webkit-backdrop-filter: blur(3px); }
.modal {
  position: relative; display: flex; flex-direction: column; width: 100%; max-height: min(92vh, 940px);
  background: var(--surface); border: 1px solid var(--line); border-radius: var(--r-xl);
  box-shadow: var(--shadow-lg); overflow: hidden; animation: modal-in .22s var(--ease);
}
.modal--sm { max-width: 440px; }
.modal--md { max-width: 620px; }
.modal--lg { max-width: 820px; }
.modal--xl { max-width: 1080px; }
.modal__head { display: flex; align-items: flex-start; gap: 12px; padding: 20px 20px 14px 24px; }
.modal__titles { flex: 1; min-width: 0; }
.modal__title { font-family: var(--display); font-size: 22px; font-weight: 700; letter-spacing: -.02em; line-height: 1.2; margin-top: 2px; }
.modal__sub { color: var(--text-2); font-size: var(--fs-sm); margin-top: 4px; }
.modal__actions { display: flex; align-items: center; gap: 4px; flex-wrap: wrap; justify-content: flex-end; }
.modal__tabs {
  display: flex; gap: 2px; padding: 0 16px; border-bottom: 1px solid var(--line);
  overflow-x: auto; scrollbar-width: none;
}
.modal__tabs::-webkit-scrollbar { display: none; }
.modal__tabs button {
  position: relative; display: inline-flex; align-items: center; gap: 7px; white-space: nowrap;
  height: 44px; padding: 0 12px; font-size: var(--fs-sm); font-weight: 600; color: var(--text-3);
  border-radius: 10px 10px 0 0; transition: color var(--dur), background var(--dur);
}
.modal__tabs button:hover { color: var(--text); background: var(--surface-2); }
.modal__tabs button[aria-selected="true"] { color: var(--text); }
.modal__tabs button[aria-selected="true"]::after {
  content: ""; position: absolute; left: 10px; right: 10px; bottom: -1px; height: 3px; border-radius: 3px 3px 0 0; background: var(--hot);
}
.tab-badge { min-width: 18px; height: 18px; padding: 0 5px; border-radius: 9px; background: var(--hot-soft); color: var(--hot-text);
             font-size: 10px; font-weight: 800; display: inline-grid; place-items: center; }
.modal__body { flex: 1; min-height: 0; padding: 20px 24px 24px; }
.modal__foot { padding: 12px 24px 16px; border-top: 1px solid var(--line); font-size: var(--fs-xs); color: var(--text-3); }
.modal__buttons { display: flex; justify-content: flex-end; gap: 8px; margin-top: 18px; }
.modal__buttons--split { justify-content: space-between; margin-top: 0; }
body.has-modal { overflow: hidden; }
@keyframes fade-in { from { opacity: 0; } }
@keyframes fade-out { to { opacity: 0; } }
@keyframes modal-in { from { opacity: 0; transform: translateY(12px) scale(.985); } }

.link { color: var(--accent-text); font-weight: 600; font-size: inherit; padding: 0; }
.link:hover:not(:disabled) { text-decoration: underline; }
.link:disabled { color: var(--text-3); cursor: default; }

/* ── giriş ── */
.auth .label { margin-left: 2px; }
.phone-field { display: flex; align-items: center; gap: 0; border-radius: var(--r-pill); background: var(--surface);
               border: 1px solid var(--line-2); transition: border-color var(--dur), box-shadow var(--dur); }
.phone-field:focus-within { border-color: var(--accent); box-shadow: var(--focus); }
.phone-field__cc { padding: 0 4px 0 16px; font-weight: 700; color: var(--text-2); font-variant-numeric: tabular-nums; }
.phone-field .input { border: 0; box-shadow: none !important; background: transparent; padding-left: 8px;
                      font-size: var(--fs-lg); font-variant-numeric: tabular-nums; letter-spacing: .02em; }
.input--code { height: 54px; text-align: center; font-size: 26px; font-weight: 700; letter-spacing: .5em;
               font-variant-numeric: tabular-nums; padding-left: calc(16px + .5em); }
.auth__note { display: flex; gap: 8px; align-items: flex-start; margin-top: 14px; font-size: var(--fs-xs); color: var(--text-3); line-height: 1.5; }
.auth__note .i { margin-top: 1px; flex: 0 0 auto; }
.auth__sent { display: flex; align-items: center; gap: 8px; padding: 10px 12px; margin-bottom: 14px; border-radius: var(--r-md);
              background: var(--surface-2); font-size: var(--fs-sm); }
.auth__sent .i { color: var(--accent-text); flex: 0 0 auto; }
.auth__sent span { flex: 1; }
.auth__resend { display: flex; justify-content: center; gap: 4px; margin-top: 12px; font-size: var(--fs-sm); }
.consent { display: flex; gap: 10px; align-items: flex-start; font-size: var(--fs-xs); color: var(--text-2); line-height: 1.5; cursor: pointer; }
.consent .check { margin-top: 1px; }

/* ── hesap / üyelik ── */
.acct__plan { display: flex; align-items: center; gap: 12px; padding: 14px; border-radius: var(--r-md); background: var(--surface-2); }
.acct__plan > .i { width: 22px; height: 22px; color: var(--accent-text); }
.acct__plan.is-pro { background: var(--hot-soft); }
.acct__plan.is-pro > .i { color: var(--hot-text); }
.acct__plan b { display: block; font-size: var(--fs-sm); }
.acct__plan small { display: block; font-size: var(--fs-xs); color: var(--text-3); }

.plan-card { padding: 18px; border-radius: var(--r-lg); background: linear-gradient(160deg, var(--hot-soft), var(--surface-2)); border: 1px solid var(--line); }
.plan-card__price { display: flex; align-items: baseline; gap: 6px; margin-bottom: 8px; }
.plan-card__price b { font-family: var(--display); font-size: 34px; letter-spacing: -.03em; }
.plan-card__price span { color: var(--text-3); font-weight: 600; }
.plan-card__list, .checklist { list-style: none; display: flex; flex-direction: column; gap: 8px; margin-top: 12px; }
.plan-card__list li, .checklist li { display: flex; gap: 8px; align-items: flex-start; font-size: var(--fs-sm); }
.plan-card__list .i, .checklist .i { color: var(--success); margin-top: 2px; }

/* ── kapı (giriş / yükseltme çağrısı) ── */
.gate-card {
  display: flex; align-items: center; gap: 12px; padding: 12px 12px 12px 14px; border-radius: var(--r-md);
  background: var(--hot-soft); border: 1px dashed color-mix(in srgb, var(--hot) 45%, transparent);
}
.gate-card__icon { width: 34px; height: 34px; border-radius: 11px; display: grid; place-items: center; flex: 0 0 auto;
                   background: var(--surface); color: var(--hot-text); }
.gate-card b { display: block; font-size: var(--fs-sm); }
.gate-card small { display: block; font-size: var(--fs-xs); color: var(--text-2); line-height: 1.4; }
.card .gate-card + #analizMode { margin-top: 10px; }

/* ── sanal drone ── */
.drone-card {
  display: flex; align-items: center; gap: 14px; padding: 16px; border-radius: var(--r-lg);
  background: linear-gradient(135deg, var(--navy), color-mix(in srgb, var(--navy) 70%, var(--navy-2)));
  color: #fff; box-shadow: var(--shadow-md);
}
.drone-card__art { width: 46px; height: 46px; border-radius: 15px; flex: 0 0 auto; display: grid; place-items: center;
                   background: rgba(255,255,255,.12); color: var(--orange); }
.drone-card__art .i { width: 26px; height: 26px; }
.drone-card .kicker { color: color-mix(in srgb, var(--tint) 80%, #fff); }
.drone-card b { display: block; font-family: var(--display); font-size: var(--fs-md); font-weight: 600; line-height: 1.3; margin-top: 1px; }
.drone-card p { font-size: var(--fs-xs); color: rgba(255,255,255,.75); margin-top: 4px; line-height: 1.45; }
.drone-card--compact { padding: 12px 12px 12px 14px; }
.drone-card--compact .drone-card__art { width: 38px; height: 38px; border-radius: 12px; }
.drone-hero { width: 72px; height: 72px; margin: 0 auto 14px; border-radius: 24px; display: grid; place-items: center;
              background: var(--hot-soft); color: var(--hot-text); }
.drone-hero .i { width: 36px; height: 36px; }

/* ── menü ── */
.menu-list { list-style: none; display: flex; flex-direction: column; gap: 2px; }
.menu-list button { width: 100%; display: flex; align-items: center; gap: 12px; padding: 12px; border-radius: var(--r-md);
                    font-weight: 600; font-size: var(--fs-md); text-align: left; }
.menu-list button:hover { background: var(--surface-2); }
.menu-list .i { color: var(--accent-text); }

/* ── içerik (sayfa) ── */
.prose { font-size: 15px; line-height: 1.7; color: var(--text); max-width: 70ch; }
.prose h2, .prose h3, .prose h4 { font-family: var(--display); letter-spacing: -.02em; line-height: 1.25; }
.prose h2 { font-size: 24px; margin: 0 0 12px; }
.prose h3 { font-size: 18px; margin: 26px 0 8px; }
.prose h4 { font-size: 16px; margin: 20px 0 6px; }
.prose p { margin: 0 0 12px; color: var(--text-2); }
.prose ul, .prose ol { margin: 0 0 14px 22px; color: var(--text-2); }
.prose li { margin: 4px 0; }
.prose li::marker { color: var(--hot); }
.prose strong { color: var(--text); }
.prose a { font-weight: 600; }
.prose blockquote { margin: 14px 0; padding: 10px 16px; border-left: 3px solid var(--hot); background: var(--surface-2); border-radius: 0 var(--r-sm) var(--r-sm) 0; }
.prose hr { border: 0; height: 1px; background: var(--line); margin: 20px 0; }
.prose img { max-width: 100%; border-radius: var(--r-md); }
.prose code { font-family: var(--mono); font-size: .9em; background: var(--surface-2); padding: 1px 6px; border-radius: 6px; }
.md-note { margin: 16px 0; padding: 12px 16px; border-radius: var(--r-md); background: var(--accent-soft); font-size: var(--fs-sm); }
.md-note p:last-child { margin: 0; }

/* ── parsel penceresi ── */
.parcel-modal .modal { height: min(86vh, 820px); }        /* sekmeler arasında boyut sıçramasın */
.parcel-modal .modal__body { background: var(--surface); }
.sec-title { display: flex; align-items: center; gap: 8px; font-family: var(--display); font-size: 14px; font-weight: 600;
             letter-spacing: -.01em; margin-bottom: 10px; color: var(--text); }
.sec-title .i { color: var(--hot-text); }
.attr-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 24px; }
.attr-table { width: 100%; border-collapse: collapse; font-size: var(--fs-sm); }
.attr-table th, .attr-table td { text-align: left; padding: 8px 10px; border-bottom: 1px solid var(--line); vertical-align: top; }
.attr-table th { width: 40%; color: var(--text-3); font-weight: 600; background: var(--surface-2); }
.attr-table tr:first-child th { border-top-left-radius: 10px; }
.attr-table td { font-weight: 600; word-break: break-word; }
.attr-table td small { font-weight: 500; }
.ctx-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 8px; }

.plan-read { padding: 14px; border: 1px solid var(--line); border-radius: var(--r-lg); }
.plan-read + .plan-read { margin-top: 10px; }
.plan-read__head { display: flex; justify-content: space-between; align-items: baseline; gap: 10px; margin-bottom: 10px; font-size: var(--fs-sm); }
.plan-read__body { display: grid; grid-template-columns: minmax(0, 1.15fr) minmax(0, 1fr); gap: 16px; align-items: start; }

.facts { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; }
.fact { padding: 12px 14px; border-radius: var(--r-md); background: var(--surface-2); min-width: 0; }
.fact span { display: block; font-size: 10.5px; font-weight: 700; letter-spacing: .06em; text-transform: uppercase; color: var(--text-3); }
.fact b { display: flex; align-items: center; gap: 5px; font-size: var(--fs-sm); margin-top: 3px; line-height: 1.35; }

.hit { padding: 14px; border: 1px solid var(--line); border-radius: var(--r-lg); }
.hit__head { display: flex; justify-content: space-between; align-items: baseline; gap: 10px; font-size: var(--fs-sm); }
.hit__pct { font-family: var(--display); font-weight: 700; color: var(--hot-text); }
.bar-lg { height: 8px; border-radius: 6px; background: var(--surface-3); margin: 8px 0 6px; overflow: hidden; }
.bar-lg b { display: block; height: 100%; border-radius: 6px; background: linear-gradient(90deg, var(--hot), color-mix(in srgb, var(--hot) 70%, #fff)); }
.hit__items { list-style: none; }
.hit__items li { display: flex; align-items: center; gap: 12px; padding: 7px 0; border-top: 1px solid var(--line); font-size: var(--fs-sm); }
.hit__items b { display: block; font-weight: 600; }
.hit__items small { display: block; color: var(--text-3); font-size: var(--fs-xs); }
.hit__num { text-align: right; flex: 0 0 auto; font-variant-numeric: tabular-nums; }

.near-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 8px; }
.near { display: flex; gap: 12px; align-items: flex-start; padding: 12px 14px; border-radius: var(--r-md); background: var(--surface-2); }
.near__icon { width: 36px; height: 36px; border-radius: 12px; display: grid; place-items: center; background: var(--surface); color: var(--accent-text); flex: 0 0 auto; }
.near span { display: block; font-size: 10.5px; font-weight: 700; letter-spacing: .06em; text-transform: uppercase; color: var(--text-3); }
.near b { display: block; font-family: var(--display); font-size: 18px; font-weight: 700; letter-spacing: -.01em; }
.near small { display: block; font-size: var(--fs-xs); color: var(--text-2); }

.table-wrap { overflow-x: auto; border: 1px solid var(--line); border-radius: var(--r-md); }
.data-table { width: 100%; border-collapse: collapse; font-size: var(--fs-sm); font-variant-numeric: tabular-nums; }
.data-table th, .data-table td { padding: 9px 12px; text-align: left; border-bottom: 1px solid var(--line); white-space: nowrap; }
.data-table thead th { background: var(--surface-2); color: var(--text-3); font-size: var(--fs-xs); font-weight: 700; }
.data-table tbody tr:last-child td { border-bottom: 0; }

.hide-sm { display: inline; }

/* ── yalnızca üyeler: karşılama ── */
body.is-walled > :not(.wall):not(.modal-layer):not(.toasts):not(script) { display: none !important; }
.wall {
  position: fixed; inset: 0; overflow-y: auto; display: grid; place-items: center; padding: 24px;
  background:
    radial-gradient(1200px 600px at 10% -10%, color-mix(in srgb, var(--navy-2) 30%, transparent), transparent 60%),
    radial-gradient(900px 500px at 110% 110%, color-mix(in srgb, var(--orange) 22%, transparent), transparent 60%),
    var(--bg);
}
.wall__card { width: min(520px, 100%); padding: 36px; border-radius: var(--r-xl); background: var(--glass-strong);
              border: 1px solid var(--line); box-shadow: var(--shadow-lg); backdrop-filter: blur(20px); -webkit-backdrop-filter: blur(20px); }
.wall__logo { height: 44px; width: auto; }
.wall__title { font-family: var(--display); font-size: 30px; line-height: 1.15; letter-spacing: -.03em; margin-top: 8px; }
.wall__lead { color: var(--text-2); margin-top: 10px; }
.wall__links { display: flex; flex-wrap: wrap; gap: 6px 16px; justify-content: center; margin-top: 18px; font-size: var(--fs-sm); }
.wall__foot { text-align: center; margin-top: 16px; }

@media (max-width: 820px) {
  .modal-layer { padding: 0; place-items: end center; }
  .modal { max-height: 94vh; border-radius: var(--r-xl) var(--r-xl) 0 0; }
  .modal--sm, .modal--md, .modal--lg, .modal--xl { max-width: none; }
  .modal__head { padding: 16px 14px 10px 18px; }
  .modal__body { padding: 16px 16px 20px; }
  .modal__title { font-size: 19px; }
  .attr-grid, .plan-read__body { grid-template-columns: 1fr; }
  .facts { grid-template-columns: 1fr; }
  .near-grid { grid-template-columns: 1fr; }
  .hide-sm { display: none; }
  .wall__card { padding: 26px 22px; }
  .wall__title { font-size: 25px; }
}
