
/* lock */
.lock__card {
  transition: opacity .35s ease, transform .35s ease;
}
.lock.is-leaving .lock__card {
  opacity: 0;
  transform: translateY(-10px) scale(.98);
}
.lock__dots {
  gap: 18px;
  margin-bottom: 26px;
  padding: 4px 0;
}
.lock__dot {
  width: 14px;
  height: 14px;
  border: 1.5px solid var(--ink-2);
}
.lock__dot.is-filled {
  background: var(--ink);
  border-color: var(--ink);
}
.lock__dots.is-error .lock__dot {
  border-color: var(--rust, #b3261e);
}
.lock__dots.is-error .lock__dot.is-filled {
  background: var(--rust, #b3261e);
}
.lock__pad {
  grid-template-columns: repeat(3, clamp(64px, 21vw, 76px));
  gap: 14px clamp(14px, 5vw, 22px);
}
.lock__key {
  width: clamp(64px, 21vw, 76px);
  height: clamp(64px, 21vw, 76px);
  background: rgba(255, 252, 244, .6);
  border: 1px solid rgba(40, 30, 20, .08);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, .7), 0 1px 2px rgba(40, 30, 20, .06);
  -webkit-backdrop-filter: blur(6px);
  backdrop-filter: blur(6px);
  transition: transform 120ms cubic-bezier(.2, .8, .3, 1), background 120ms ease, color 120ms ease;
}
.lock__key:active,
.lock__key.is-pressed {
  transform: scale(.92);
  background: rgba(40, 30, 20, .14);
}
.lock__key--del {
  background: transparent;
  border-color: transparent;
  box-shadow: none;
}
.lock__key--del:active,
.lock__key--del.is-pressed {
  background: rgba(40, 30, 20, .1);
}
@media (max-width: 360px) {
  .lock__pad { grid-template-columns: repeat(3, 64px); gap: 12px 14px; }
  .lock__key { width: 64px; height: 64px; }
}

#app.is-revealing {
  animation: lock-reveal 600ms cubic-bezier(.2, .8, .3, 1) both;
}
@keyframes lock-reveal {
  from { opacity: 0; transform: translateY(14px); }
  to   { opacity: 1; transform: none; }
}

/* nav: mobilde yatay kaydırılabilir */
@media (max-width: 767px) {
  .topbar__nav {
    margin-right: calc(var(--wrap-pad, 16px) * -1);
    padding-right: var(--wrap-pad, 16px);
    overscroll-behavior-x: contain;
    scroll-snap-type: x proximity;
    -webkit-mask-image: linear-gradient(to right, #000 88%, transparent);
    mask-image: linear-gradient(to right, #000 88%, transparent);
  }
  .topbar__nav a { scroll-snap-align: start; }
}

@media (prefers-reduced-motion: reduce) {
  #app.is-revealing { animation: none; }
  .lock__card,
  .lock__key { transition: none; }
}

/* ==========================================================================
   POLISH (ikinci kat) - style.css'in ustune biner. Mevcut kurallar silinmez,
   sadece ezilir. Kagit/damga dili korunur; hareket reduced-motion altinda kapanir.
   ========================================================================== */

/* ---------- Tipografi ritmi ---------- */

body {
  font-size: 17px;
  line-height: 1.6;
  text-rendering: optimizeLegibility;
  font-kerning: normal;
  overflow-wrap: break-word;
}

p, li, dd, figcaption { text-wrap: pretty; }

h1, h2, h3, h4 { text-wrap: balance; }

.hero__sub,
.section__lead,
.footer__note,
.window-card__note,
.result-card__tag {
  overflow-wrap: anywhere;
}

.eyebrow { line-height: 1.5; }

.h3 {
  margin: 64px 0 20px;
  padding-top: 14px;
  border-top: 1px solid var(--line);
  letter-spacing: -.005em;
}

/* ---------- Bolum basliklari ---------- */

.section__head {
  padding-top: 16px;
  margin-bottom: 32px;
  border-top: 1px solid var(--ink);
}

.section__head::before {
  content: "";
  position: absolute;
  top: -4px;
  left: 0;
  width: 56px;
  height: 1px;
  background: var(--talha);
}

.section__num {
  padding-top: 6px;
  color: var(--talha);
  letter-spacing: .14em;
}

.section__head h2 {
  letter-spacing: -.02em;
  line-height: 1.04;
}

.section__lead {
  margin-top: 8px;
  line-height: 1.5;
}

.section__lead .dot { vertical-align: middle; }

/* ---------- Damgalar: hafif egik, kagit uzerinde ---------- */

.stamp {
  transform: rotate(var(--rot, -3deg));
  letter-spacing: .14em;
  mix-blend-mode: multiply;
}

.hero__stamp { box-shadow: inset 0 0 0 1px rgba(30, 27, 22, .04); }

.window-card__days,
.score-stamp {
  transform: rotate(-4deg);
  border: 1.5px solid currentColor;
  border-radius: 3px;
  padding: 2px 6px;
  line-height: 1.1;
}

/* ---------- Kartlar: kagit bilet, dikis cizgisi, hover ---------- */

.card,
.alt-card,
.result-card,
.window-card {
  background-color: var(--paper-2);
  background-image: linear-gradient(180deg, rgba(255, 255, 255, .35), rgba(255, 255, 255, 0) 40%);
  box-shadow: 0 1px 0 rgba(30, 27, 22, .06);
}

.result-card,
.window-card,
.alt-card {
  outline: 1px dashed rgba(30, 27, 22, .14);
  outline-offset: -6px;
}

.alt-card.is-active {
  outline-color: rgba(184, 67, 47, .35);
}

.card::before {
  width: 22px;
  height: 22px;
  background: linear-gradient(225deg, var(--paper) 50%, var(--paper-3) 50%);
}

@media (hover: hover) and (pointer: fine) {
  .card:hover,
  .alt-card:hover,
  .window-card:hover,
  .result-card:hover {
    transform: translateY(-3px) rotate(-.15deg);
    box-shadow: 0 2px 0 rgba(30, 27, 22, .08), 0 14px 28px -16px rgba(30, 27, 22, .4);
  }

  .city-card:hover {
    transform: translateY(-3px);
    box-shadow: 0 2px 0 rgba(30, 27, 22, .08), 0 16px 30px -18px rgba(30, 27, 22, .45);
  }

  .alt-card:hover { border-color: var(--ink-2); }
}

.alt-card,
.window-card,
.result-card {
  transition: transform .22s cubic-bezier(.2, .7, .2, 1), box-shadow .22s ease, border-color .22s ease;
}

.alt-card { padding: 16px 18px; gap: 6px 12px; }

.alt-card__title { font-size: 19px; line-height: 1.2; }

.window-card h4 { font-size: 21px; letter-spacing: -.01em; }

.result-card { padding: 20px 18px; }

.result-card__title { font-size: clamp(24px, 6vw, 28px); letter-spacing: -.01em; }

.city-card { border-radius: var(--r); }

.city-card h3 { letter-spacing: -.01em; }

/* ---------- Butonlar ---------- */

.btn {
  letter-spacing: .1em;
  transition: background .18s ease, color .18s ease, border-color .18s ease, transform .12s ease, box-shadow .18s ease;
}

.btn:active { transform: translateY(1px); }

.btn--primary {
  box-shadow: 0 1px 0 rgba(0, 0, 0, .25), 0 6px 14px -8px rgba(30, 27, 22, .6);
}

.btn--primary:hover { box-shadow: 0 1px 0 rgba(0, 0, 0, .25), 0 10px 18px -10px rgba(30, 27, 22, .7); }

.btn--ghost {
  background: rgba(255, 252, 244, .45);
}

.btn--ghost:hover { background: var(--paper-2); }

.btn:disabled,
.btn[aria-disabled="true"] {
  opacity: .45;
  cursor: not-allowed;
  transform: none;
}

/* ---------- Odak durumlari ---------- */

:focus-visible {
  outline: 2px solid var(--talha);
  outline-offset: 3px;
  border-radius: 2px;
}

.btn:focus-visible,
.tab:focus-visible,
.chip:focus-visible,
.seg button:focus-visible,
.alt-card:focus-visible,
.topbar__nav a:focus-visible {
  outline: 2px solid var(--ink);
  outline-offset: 2px;
}

input:focus-visible,
select:focus-visible,
textarea:focus-visible {
  outline: 2px solid var(--ink);
  outline-offset: 1px;
}

a:focus-visible { outline-color: var(--talha); }

/* ---------- Ust bar: dolu kagit, ince cizgi, blur yok ---------- */

.topbar {
  background: var(--paper);
  -webkit-backdrop-filter: none;
  backdrop-filter: none;
  border-bottom: 0;
  box-shadow: 0 1px 0 var(--line), 0 2px 0 var(--paper), 0 3px 0 rgba(201, 191, 174, .45);
}

.topbar__brand {
  display: inline-flex;
  align-items: center;
  padding: 0;
  min-height: 44px;
  letter-spacing: .16em;
}

.topbar__nav a {
  position: relative;
  letter-spacing: .08em;
  color: var(--ink-2);
}

.topbar__nav a::after {
  content: "";
  position: absolute;
  left: 8px;
  right: 8px;
  bottom: 9px;
  height: 1px;
  background: var(--talha);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform .2s ease;
}

.topbar__nav a:hover::after,
.topbar__nav a:focus-visible::after { transform: scaleX(1); }

/* ---------- Sekmeler ve planlayici ---------- */

.tabs { gap: 4px; }

.tab { min-height: 44px; }

.seg button { min-height: 40px; }

.chip { min-height: 36px; }

.cal__day { min-width: 0; }

/* ---------- Tablo: tasma yok, uzun kelimeler kirilir ---------- */

.budget th,
.budget td {
  overflow-wrap: anywhere;
  hyphens: auto;
}

.legs__who,
.ticket__row,
.ticket__meta,
.ticket__note,
.alt-card__title,
.city-card__text,
.window-card__note {
  overflow-wrap: anywhere;
}

/* ---------- Footer: damgali kapanis ---------- */

.footer {
  position: relative;
  margin-top: 56px;
  padding-top: 36px;
  border-top: 3px double var(--line);
  gap: 14px;
}

.footer::before {
  content: "T & E · ARŞİV";
  position: absolute;
  top: -11px;
  left: var(--wrap-pad);
  padding: 0 10px;
  background: var(--paper);
  font: 500 10px/1 var(--font-mono);
  letter-spacing: .24em;
  color: var(--muted);
}

.kur {
  padding: 10px 12px;
  border: 1px dashed var(--line);
  border-radius: var(--r);
  min-height: 44px;
}

.kur input:focus-visible {
  outline: 2px solid var(--ink);
  outline-offset: 1px;
}

.footer__note {
  line-height: 1.55;
  color: var(--muted);
}

.footer .btn { min-width: 0; }

/* ---------- Mobil: 360-430px ---------- */

@media (max-width: 430px) {
  body { font-size: 16.5px; }

  :root { --section-y: 52px; }

  .section__head { margin-bottom: 24px; }

  .section__head h2 { font-size: clamp(30px, 9vw, 38px); }

  .section__lead { font-size: 15px; }

  .hero__sub { font-size: 16px; }

  .hero__meta { margin-top: 14px; }

  .result-card__head { gap: 10px; }

  .result-card__actions .btn { flex-basis: 100%; }

  .window-card { padding: 16px 16px 14px; }

  .window-card h4 { padding-right: 84px; font-size: 19px; }

  .ticket__stub { flex: 0 0 68px; }

  .alt-card { grid-template-columns: auto minmax(0, 1fr); }

  .alt-card .badge { grid-column: 2; grid-row: auto; justify-self: start; }
}

@media (max-width: 360px) {
  .wrap { --wrap-pad: 14px; }

  .hero__title { font-size: clamp(40px, 13vw, 52px); }

  .section__head { grid-template-columns: 1fr; gap: 6px; }

  .section__num { grid-row: auto; padding-top: 0; }

  .section__head h2 { font-size: 30px; }

  .section__lead { grid-column: 1; }

  .budget { font-size: 12px; }

  .budget th,
  .budget td { padding-left: 4px; padding-right: 4px; }

  .topbar__brand { font-size: 12px; letter-spacing: .12em; }

  .topbar__nav a { padding: 0 7px; font-size: 10.5px; }

  .footer::before { left: 14px; }
}

/* ---------- Yatay tasma koruyucu ---------- */

html,
body { max-width: 100%; }

#app,
.section,
.hero,
.footer,
.planner,
.alt,
.cities,
.season,
.windows {
  max-width: 100%;
  min-width: 0;
}

.leaflet-container { max-width: 100%; }

/* ---------- Hareket: azaltilmis hareket tercihinde kapali ---------- */

@media (prefers-reduced-motion: reduce) {
  .card,
  .alt-card,
  .window-card,
  .result-card,
  .city-card,
  .btn,
  .topbar__nav a::after {
    transition: none !important;
    transform: none !important;
  }

  .card:hover,
  .alt-card:hover,
  .window-card:hover,
  .result-card:hover,
  .city-card:hover {
    transform: none !important;
  }
}
