/* Rota: "Postmark" world. Paper, postal yellow, postal navy, stamp violet. */
:root {
  --paper: #F6F4EE;
  --paper-2: #FFFFFF;
  --paper-3: #ECE8DE;
  /* Theme colours: --yellow (main) and --ink (secondary) can be overridden from Ayarlar → Tema (inc/theme.php) */
  --yellow: #FFE873;
  --ink: #1C2541;
  --yellow-2: color-mix(in srgb, var(--yellow) 82%, var(--ink));
  --ink-2: color-mix(in srgb, var(--ink) 80%, var(--paper));
  --ink-3: color-mix(in srgb, var(--ink) 72%, var(--paper));
  --line: #DCD7CA;
  --line-2: #C6BFAE;
  --stamp: #5B2A86;
  --post: #2E4A8C;
  --red: #B3261E;
  --land: #E6E1D5;
  --land-edge: #C9C1AE;
  --water: #EEF1F2;
  --focus: #2E4A8C;
  --sans: "Montserrat", system-ui, -apple-system, "Segoe UI", sans-serif;
  --serif: "Lora", Georgia, "Times New Roman", serif;
  --display: "Big Shoulders Stencil", "Montserrat", Impact, sans-serif;
  --hand: "Caveat", "Segoe Print", cursive;
  --logo: "Kaushan Script", "Caveat", "Segoe Script", cursive;
  /* logo font settings; Ayarlar → Tema overrides them (inc/logo_fonts.php) */
  --logo-w: 400; --logo-st: normal; --logo-scale: 1; --logo-tt: none; --logo-ls: 0;
  --r-s: 6px;
  --r-m: 12px;
  --gutter: clamp(18px, 4.5vw, 48px);
  --measure: 66ch;
  --safe-b: env(safe-area-inset-bottom, 0px);
  color-scheme: light;
}
* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scrollbar-color: var(--line-2) var(--paper); }
body { margin: 0; background: var(--paper); color: var(--ink); font: 400 17px/1.6 var(--sans); -webkit-font-smoothing: antialiased; }
::selection { background: var(--yellow); color: var(--ink); }
img { max-width: 100%; height: auto; display: block; }
a { color: var(--post); text-underline-offset: 3px; text-decoration-thickness: 1px; }
a:hover { text-decoration-thickness: 2px; }
:focus-visible { outline: 2.5px solid var(--focus); outline-offset: 3px; border-radius: 3px; }
h1, h2, h3 { font-family: var(--sans); font-weight: 700; line-height: 1.15; letter-spacing: -0.02em; margin: 0 0 .5em; text-wrap: balance; }
h1 { font-size: clamp(32px, 6.4vw, 60px); }
h2 { font-size: clamp(22px, 3.2vw, 28px); }
h3 { font-size: 20px; }
p { margin: 0 0 1em; text-wrap: pretty; }
.muted { color: var(--ink-2); }
.small { font-size: 14px; }
.serif { font-family: var(--serif); }
.skip { position: absolute; left: -999px; top: 0; background: var(--ink); color: #fff; padding: 8px 12px; z-index: 50; }
.skip:focus { left: 8px; top: 8px; }
.wrap { max-width: 1180px; margin: 0 auto; padding-left: var(--gutter); padding-right: var(--gutter); }
.narrow { max-width: 760px; margin: 0 auto; padding-left: var(--gutter); padding-right: var(--gutter); }
.postmark { color: var(--stamp); flex: none; overflow: visible; --pm-bg: transparent; }
.ph .postmark { --pm-bg: rgba(246, 244, 238, .9); }

/* Yellow masthead */
.topbar {
  position: sticky; top: 0; z-index: 20; background: var(--yellow); color: var(--ink);
  display: flex; align-items: center; justify-content: space-between; gap: 16px;
  padding: calc(8px + env(safe-area-inset-top, 0px)) var(--gutter) 8px;
}
.brand { display: inline-flex; align-items: center; gap: 12px; font: var(--logo-st) var(--logo-w) calc(32px * var(--logo-scale))/1.1 var(--logo); text-transform: var(--logo-tt); letter-spacing: var(--logo-ls); color: var(--ink); text-decoration: none; white-space: nowrap; }
.brand span { padding-bottom: 3px; }
.topnav { display: flex; align-items: center; gap: 2px; font: 600 15px/1 var(--sans); }
.topnav a, .topnav .linkish { color: var(--ink); text-decoration: none; padding: 0 12px; min-height: 44px; border-radius: 999px; display: inline-flex; align-items: center; }
.topnav a:hover { background: color-mix(in srgb, var(--ink) 8%, transparent); }
.topnav a[aria-current="page"] { background: var(--ink); color: var(--yellow); }
.topnav .admin-link { border: 1.5px solid var(--ink); margin-left: 6px; gap: 6px; }

/* Opening: latest post */
.lead { padding-top: clamp(32px, 6vw, 72px); padding-bottom: clamp(40px, 6vw, 80px); }
.lead-empty { display: flex; flex-wrap: wrap; align-items: center; gap: clamp(16px, 4vw, 40px); padding: clamp(12px, 4vw, 40px) 0; }
.lead-empty h1 { margin-bottom: 10px; }
.lead-empty p { font-family: var(--serif); font-size: 19px; color: var(--ink-2); max-width: 44ch; margin: 0; }
.lead-post { display: grid; grid-template-columns: minmax(0, 1fr); gap: 22px; text-decoration: none; color: inherit; align-items: center; }
@media (min-width: 900px) { .lead-post { grid-template-columns: minmax(0, 5fr) minmax(0, 6fr); gap: 56px; } }
.lead-post .ph { position: relative; aspect-ratio: 4 / 3; border-radius: var(--r-m); background: var(--paper-3); }
.lead-post .ph img { width: 100%; height: 100%; object-fit: cover; border-radius: var(--r-m); }

.lead-post .stamp-only { display: flex; justify-content: flex-start; }
.lead-post .stamp-only .postmark { transform: rotate(-6deg); }
.lead-post h2 { font-size: clamp(30px, 5vw, 52px); margin: 0 0 12px; }
.lead-post .post-meta { margin-bottom: 14px; }
.lead-post:hover h2 { text-decoration: underline; text-decoration-thickness: 3px; text-underline-offset: 6px; text-decoration-color: var(--yellow-2); }
.lead-post .ex { font-family: var(--serif); font-size: clamp(18px, 2vw, 20px); line-height: 1.6; color: var(--ink-2); max-width: 46ch; margin: 0 0 16px; }
.read-on { font: 700 15px var(--sans); color: var(--post); }

.post-meta { font: 500 14px/1.45 var(--sans); color: var(--ink-2); margin: 0 0 6px; font-variant-numeric: tabular-nums; }
.post-meta .where { color: var(--ink); font-weight: 700; }

/* Harita */
.atlas-section { background: var(--water); border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); padding-top: 40px; }
.atlas-section .atlas-intro { margin-bottom: 4px; }
.atlas-intro { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: end; gap: 12px 24px; }
.atlas-intro h2 { margin: 0 0 6px; }
.atlas-intro p { margin: 0; color: var(--ink-2); font-family: var(--serif); font-size: 18px; max-width: 52ch; }
.atlas { position: relative; }
.atlas-head { position: absolute; z-index: 3; left: var(--gutter); top: 14px; right: var(--gutter); pointer-events: none; display: flex; justify-content: flex-end; }
.atlas-head > * { pointer-events: auto; }
.atlas-head .atlas-title:empty { display: none; }
.atlas-canvas { width: 100%; height: min(64vh, 620px); min-height: 400px; display: block; touch-action: pan-x pan-y; cursor: grab; }
.atlas-canvas:active { cursor: grabbing; }
.atlas-canvas .land { fill: var(--land); stroke: var(--land-edge); stroke-width: .6; vector-effect: non-scaling-stroke; transition: fill .2s; }
.atlas-canvas .land.has { stroke: var(--paper-2); stroke-width: 1; }
.atlas-canvas .land.dim { opacity: .25; }
.atlas-canvas .land.sel { stroke: var(--ink); stroke-width: 2; }
.atlas-canvas .land:hover { stroke: var(--ink); stroke-width: 1.2; }
.atlas-canvas .land:focus-visible { outline: none; stroke: var(--focus); stroke-width: 2.5; }
.atlas-canvas .graticule { fill: none; stroke: rgba(46, 74, 140, .1); stroke-width: .5; vector-effect: non-scaling-stroke; pointer-events: none; }
.atlas-canvas .label { font: 700 11px var(--sans); fill: var(--ink); paint-order: stroke; stroke: var(--paper-2); stroke-width: 3px; pointer-events: none; text-anchor: middle; }
.atlas-controls { position: absolute; z-index: 3; right: var(--gutter); bottom: calc(18px + var(--safe-b)); display: flex; flex-direction: column; gap: 6px; }
.atlas-controls button, .crumbs button, .chip-btn {
  font: 600 15px/1 var(--sans); color: var(--ink); background: var(--paper-2);
  border: 1.5px solid var(--line-2); border-radius: 999px; min-width: 44px; min-height: 44px; padding: 0 14px; cursor: pointer;
}
.atlas-controls button { border-radius: 50%; padding: 0; font-size: 18px; }
.atlas-controls button:hover, .crumbs button:hover, .chip-btn:hover { border-color: var(--ink); }
.crumbs { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; font-size: 14px; }
.crumbs button { min-height: 38px; }
.crumbs button[aria-current="true"] { background: var(--ink); color: var(--yellow); border-color: var(--ink); }
.crumbs .sep { color: var(--ink-3); }
.atlas-foot { position: absolute; z-index: 3; left: var(--gutter); bottom: calc(18px + var(--safe-b)); right: 80px; }
.legend { display: flex; flex-wrap: wrap; gap: 6px; }
.chip-btn { display: inline-flex; align-items: center; gap: 7px; font-size: 13px; min-height: 36px; padding: 0 12px; }
.chip-btn .dot, .badge .dot { width: 10px; height: 10px; border-radius: 50%; background: var(--c, var(--post)); flex: none; }
.chip-btn[aria-pressed="true"] { background: var(--ink); color: var(--paper-2); border-color: var(--ink); }
.chip-btn .n { color: var(--ink-3); font-variant-numeric: tabular-nums; }
.chip-btn[aria-pressed="true"] .n { color: var(--yellow); }
.place-card {
  position: absolute; z-index: 4; left: 50%; bottom: calc(14px + var(--safe-b)); transform: translateX(-50%);
  width: min(420px, calc(100% - 2 * var(--gutter))); background: var(--paper-2); border-radius: var(--r-m); padding: 18px 20px;
  box-shadow: 0 18px 40px -16px color-mix(in srgb, var(--ink) 45%, transparent);
}
.place-card[hidden] { display: none; }
.place-card h3 { margin: 0 0 4px; font-size: 22px; }
.place-card .meta { font: 500 14px/1.4 var(--sans); color: var(--ink-2); margin: 0 0 10px; }
.place-card .actions { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 14px; }
.place-card .x { position: absolute; top: 8px; right: 8px; width: 44px; height: 44px; border: 0; background: none; font-size: 24px; color: var(--ink-2); cursor: pointer; border-radius: 50%; }
.place-card .x:hover { background: var(--paper-3); }
.tooltip { position: absolute; z-index: 5; pointer-events: none; font: 600 13px var(--sans); background: var(--ink); color: var(--paper-2); padding: 6px 10px; border-radius: var(--r-s); white-space: nowrap; transform: translate(-50%, calc(-100% - 10px)); }
.tooltip[hidden] { display: none; }

/* Buttons */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; font: 700 15px/1 var(--sans); min-height: 44px; padding: 0 18px; border-radius: 999px; border: 1.5px solid var(--ink); background: var(--ink); color: var(--paper-2); text-decoration: none; cursor: pointer; }
.btn:hover { background: #0F1630; text-decoration: none; }
.btn:disabled { opacity: .45; cursor: not-allowed; }
.btn.ghost { background: transparent; color: var(--ink); border-color: var(--line-2); }
.btn.ghost:hover { border-color: var(--ink); background: var(--paper-2); }
.btn.yellow { background: var(--yellow); border-color: var(--yellow); color: var(--ink); }
.btn.danger { background: var(--red); border-color: var(--red); }
.btn.sm { min-height: 38px; padding: 0 14px; font-size: 14px; }

/* Rozet */
.badges { display: flex; flex-wrap: wrap; gap: 6px; }
.badge { display: inline-flex; align-items: center; gap: 7px; font: 600 13px/1 var(--sans); padding: 8px 12px; border-radius: 999px; background: color-mix(in srgb, var(--c) 12%, var(--paper-2)); color: color-mix(in srgb, var(--c) 75%, var(--ink)); text-decoration: none; }
a.badge:hover { background: color-mix(in srgb, var(--c) 22%, var(--paper-2)); }

/* Home grid */
.home-grid { display: grid; grid-template-columns: minmax(0, 1fr); gap: 56px; padding-top: 56px; padding-bottom: 80px; }
@media (min-width: 960px) { .home-grid { grid-template-columns: minmax(0, 1.75fr) minmax(0, 1fr); gap: 72px; } }
.sec-title { display: flex; align-items: baseline; justify-content: space-between; gap: 12px; margin-bottom: 8px; padding-bottom: 12px; border-bottom: 2px solid var(--ink); }
.sec-title h2 { margin: 0; }
.sec-title a { font: 600 14px var(--sans); }
.post-row { display: grid; grid-template-columns: 104px minmax(0, 1fr); gap: 18px; padding: 22px 0; border-bottom: 1px solid var(--line); text-decoration: none; color: inherit; align-items: start; }
@media (min-width: 640px) { .post-row { grid-template-columns: 176px minmax(0, 1fr); gap: 24px; } }
.post-row .ph { position: relative; aspect-ratio: 1; border-radius: var(--r-s); background: var(--paper-3); }
.post-row .ph img { width: 100%; height: 100%; object-fit: cover; border-radius: var(--r-s); }

.post-row .ph.empty-ph { display: grid; place-items: center; background: transparent; }
.post-row .ph.empty-ph .postmark { position: static; transform: rotate(-6deg); height: 86%; }
.post-row h3 { margin: 2px 0 6px; font-size: clamp(19px, 2.2vw, 23px); }
.post-row:hover h3 { text-decoration: underline; text-underline-offset: 4px; text-decoration-thickness: 2px; text-decoration-color: var(--yellow-2); }
.post-row p:last-child { margin: 0; font-family: var(--serif); font-size: 16px; color: var(--ink-2); }
.ranked { list-style: none; margin: 0; padding: 0; counter-reset: r; }
.ranked li { counter-increment: r; display: grid; grid-template-columns: 36px minmax(0, 1fr); gap: 10px; padding: 16px 0; border-bottom: 1px solid var(--line); }
.ranked li::before { content: counter(r); font: 900 34px/0.9 var(--display); color: var(--stamp); font-variant-numeric: tabular-nums; }
.ranked a { color: var(--ink); text-decoration: none; font-weight: 700; font-size: 17px; }
.ranked a:hover { text-decoration: underline; }
.ranked .post-meta { margin: 4px 0 0; }
.aside-block { margin-bottom: 48px; }
.place-list { display: flex; flex-wrap: wrap; gap: 8px; list-style: none; padding: 14px 0 0; margin: 0; }
.empty { padding: 24px; background: var(--paper-2); border-radius: var(--r-m); color: var(--ink-2); font-size: 16px; }
.tally { font-family: var(--serif); font-size: 18px; color: var(--ink-2); padding-top: 14px; }
.tally strong { font-family: var(--sans); color: var(--ink); font-variant-numeric: tabular-nums; }

/* Post */
.post-head { padding-top: clamp(28px, 6vw, 56px); }
.post-open { display: flex; align-items: center; gap: 14px 22px; flex-wrap: wrap; margin-bottom: 18px; }
.post-open .postmark { transform: rotate(-6deg); }
.post-head h1 { margin-bottom: 16px; }
.where-line { display: flex; flex-wrap: wrap; gap: 6px; }
.post-facts { display: flex; flex-wrap: wrap; gap: 6px 20px; font: 500 15px/1.5 var(--sans); color: var(--ink-2); margin-bottom: 32px; font-variant-numeric: tabular-nums; }
.post-facts strong { color: var(--ink); font-weight: 700; }
.post-hero { margin: 0 auto 40px; max-width: 1180px; padding: 0 var(--gutter); }
.post-hero img { width: 100%; max-height: 80vh; object-fit: cover; border-radius: var(--r-m); cursor: zoom-in; }
.prose { font-family: var(--serif); font-size: 18px; line-height: 1.75; max-width: var(--measure); }
.prose h2 { font-family: var(--sans); margin-top: 1.7em; font-size: 26px; }
.prose h3 { font-family: var(--sans); margin-top: 1.5em; }
.prose blockquote { margin: 1.6em 0; padding: 0 0 0 1.4em; text-indent: -0.55em; font-style: italic; font-size: 1.1em; color: var(--stamp); }
.prose blockquote::before { content: "“"; font-family: var(--sans); font-weight: 800; color: var(--yellow-2); margin-right: .1em; }
.prose figure { margin: 2.2em 0; }
.prose img { border-radius: var(--r-s); cursor: zoom-in; }
.prose figcaption, .post-hero figcaption { font: 600 21px/1.2 var(--hand); color: var(--ink-2); margin-top: 10px; }
.prose hr { border: 0; height: 12px; margin: 2.4em 0; background: radial-gradient(circle, var(--line-2) 2px, transparent 2.5px) center / 14px 12px repeat-x; }
.prose ul, .prose ol { padding-left: 1.3em; }
.prose li::marker { color: var(--stamp); font-family: var(--sans); font-weight: 700; }
.prose a { color: var(--post); }
.gallery { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; margin: 44px 0; }
@media (min-width: 720px) { .gallery { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
.gallery button { padding: 0; border: 0; background: var(--paper-3); aspect-ratio: 1; overflow: hidden; border-radius: var(--r-s); cursor: zoom-in; }
.gallery img { width: 100%; height: 100%; object-fit: cover; transition: transform .4s cubic-bezier(.2, .8, .2, 1); }
.gallery button:hover img { transform: scale(1.04); }
.post-nav { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; padding: 28px 0 8px; border-top: 2px solid var(--ink); margin-top: 48px; }
.post-nav a { text-decoration: none; color: var(--ink); font-weight: 700; }
.post-nav a:hover { color: var(--post); }
.post-nav small { display: block; color: var(--ink-3); font-size: 13px; font-weight: 500; margin-bottom: 2px; }
.post-nav .next { text-align: right; }
.notice { padding: 12px 16px; border-radius: var(--r-s); background: color-mix(in srgb, var(--yellow) 30%, var(--paper-2)); margin-bottom: 22px; font-size: 15px; }

/* Lightbox */
.lightbox { position: fixed; inset: 0; z-index: 100; background: rgba(16, 21, 38, .95); display: flex; align-items: center; justify-content: center; padding: 60px 12px calc(60px + var(--safe-b)); touch-action: pan-y; }
.lightbox[hidden] { display: none; }
.lightbox img { max-height: 100%; max-width: 100%; object-fit: contain; border-radius: 4px; }
.lightbox .cap { position: absolute; left: 0; right: 0; bottom: calc(16px + var(--safe-b)); text-align: center; color: #E6E1D5; font: 500 14px var(--sans); padding: 0 64px; }
.lightbox button { position: absolute; background: rgba(255, 255, 255, .1); color: #fff; border: 0; width: 48px; height: 48px; border-radius: 50%; font-size: 24px; cursor: pointer; }
.lightbox button:hover { background: rgba(255, 255, 255, .2); }
.lightbox .close { top: calc(10px + env(safe-area-inset-top, 0px)); right: 12px; }
.lightbox .prev { left: 10px; top: 50%; transform: translateY(-50%); }
.lightbox .next { right: 10px; top: 50%; transform: translateY(-50%); }

/* Yer */
.place-head { display: flex; align-items: center; gap: clamp(16px, 4vw, 36px); padding: clamp(28px, 6vw, 56px) 0 28px; margin-bottom: 32px; border-bottom: 2px solid var(--ink); }
.place-head .crumb { font: 500 14px var(--sans); color: var(--ink-2); margin: 0 0 8px; }
.place-head .crumb a { color: var(--ink-2); }
.place-head h1 { margin-bottom: 12px; }
.place-head .postmark { transform: rotate(-6deg); }
.visits { list-style: none; margin: 0; padding: 0; }
.visits li { display: grid; grid-template-columns: 100px minmax(0, 1fr); gap: 18px; padding: 24px 0; border-bottom: 1px solid var(--line); }
.visits li > .letter-stamp { transform: rotate(-4deg); transform-origin: 50% 0; margin-top: 4px; }
.visits h3 { margin: 0 0 6px; font-size: 22px; }
.visits h3 a { color: var(--ink); text-decoration: none; }
.visits h3 a:hover { text-decoration: underline; }
.visits img { border-radius: var(--r-s); aspect-ratio: 16 / 9; object-fit: cover; width: 100%; max-width: 560px; margin-top: 12px; }
.visits p.muted { font-family: var(--serif); }
.children { columns: 2 180px; column-gap: 24px; padding: 14px 0 0; margin: 0; list-style: none; font-size: 15px; }
.children li { break-inside: avoid; padding: 5px 0; display: flex; align-items: center; gap: 9px; }
.children .dot { width: 10px; height: 10px; border-radius: 50%; background: var(--c); }

/* Archive, search */
.page-head { padding: clamp(28px, 6vw, 56px) 0 24px; }
.page-head p { font-family: var(--serif); font-size: 18px; }
.year-block { display: grid; grid-template-columns: minmax(0, 1fr); gap: 4px; margin-bottom: 48px; }
@media (min-width: 760px) { .year-block { grid-template-columns: 140px minmax(0, 1fr); gap: 32px; } }
.year-block h2 { font: 900 64px/0.9 var(--display); color: var(--stamp); position: sticky; top: 84px; align-self: start; font-variant-numeric: tabular-nums; letter-spacing: -0.02em; }
.search-form { display: flex; gap: 8px; margin: 0 0 32px; }
.search-form input { flex: 1; }
input[type=text], input[type=search], input[type=email], input[type=password], input[type=date], input[type=datetime-local], input[type=url], input[type=number], select, textarea {
  font: 400 16px/1.4 var(--sans); color: var(--ink); background: var(--paper-2); border: 1.5px solid var(--line-2); border-radius: var(--r-s); padding: 11px 13px; width: 100%; min-height: 46px; caret-color: var(--stamp);
}
input::placeholder, textarea::placeholder { color: var(--ink-3); }
input:focus, select:focus, textarea:focus { outline: none; border-color: var(--focus); box-shadow: 0 0 0 3px rgba(46, 74, 140, .18); }
mark { background: color-mix(in srgb, var(--yellow) 55%, transparent); color: inherit; padding: 0 2px; border-radius: 2px; }
.pager { display: flex; justify-content: space-between; gap: 12px; margin: 32px 0; }

.avatar { display: block; flex: none; border-radius: 50%; object-fit: cover; background: var(--paper); }
.brand .avatar { width: 44px; height: 44px; box-shadow: 0 0 0 2px var(--ink); }
.site-footer { background: var(--ink); color: #C9CDDC; padding: 48px var(--gutter) calc(20px + var(--safe-b)); font: 400 14px/1.6 var(--sans); }
.site-footer p { margin: 0; }
.site-footer a { color: #E6E8F0; }
.f-grid { max-width: var(--wrap, 1180px); margin: 0 auto; display: grid; grid-template-columns: minmax(0, 1.6fr) minmax(0, 1fr) minmax(0, 1fr); gap: 36px 48px; }
.site-footer .fowner { display: flex; align-items: center; gap: 16px; text-decoration: none; color: inherit; }
.site-footer .fowner .avatar { width: 72px; height: 72px; box-shadow: 0 0 0 3px var(--yellow); }
.site-footer .fowner > span { display: flex; flex-direction: column; }
.site-footer .ftag { color: #C9CDDC; max-width: 34ch; }
.site-footer .fbrand { display: block; font: var(--logo-st) var(--logo-w) calc(34px * var(--logo-scale))/1.15 var(--logo); text-transform: var(--logo-tt); letter-spacing: var(--logo-ls); color: var(--yellow); margin-bottom: 4px; }
.site-footer .socials { margin-top: 22px; gap: 10px; }
.site-footer .social { width: 42px; height: 42px; color: #E6E8F0; background: transparent; box-shadow: inset 0 0 0 1.5px rgba(230, 232, 240, .28); transition: background .18s, color .18s, box-shadow .18s, transform .18s; }
.site-footer .social:hover, .site-footer .social:focus-visible { background: var(--yellow); color: var(--ink); box-shadow: inset 0 0 0 1.5px var(--yellow); transform: translateY(-2px); }
.f-col h2 { font: 700 13px/1 var(--sans); color: var(--yellow); letter-spacing: .02em; margin: 6px 0 14px; }
.f-col ul { list-style: none; margin: 0; padding: 0; display: grid; gap: 2px; }
.f-col a { display: inline-flex; align-items: center; gap: 9px; min-height: 34px; font-weight: 500; font-size: 15px; text-decoration: none; }
.f-col a:hover { color: var(--yellow); text-decoration: underline; text-underline-offset: 4px; }
.f-col .dot { flex: none; width: 9px; height: 9px; border-radius: 50%; background: var(--c); box-shadow: 0 0 0 2px rgba(255, 255, 255, .12); }
.f-bottom { max-width: var(--wrap, 1180px); margin: 40px auto 0; padding-top: 18px; border-top: 1px solid rgba(230, 232, 240, .14); display: flex; flex-wrap: wrap; justify-content: space-between; gap: 6px 24px; font-size: 13px; color: #9CA3BD; }
.f-bottom a { color: #E6E8F0; }
@media (max-width: 760px) {
  .f-grid { grid-template-columns: 1fr 1fr; }
  .f-owner { grid-column: 1 / -1; }
}

@media (max-width: 640px) {
  body { font-size: 16px; }
  .brand { font-size: calc(26px * var(--logo-scale)); gap: 8px; }
  .brand .avatar { width: 38px; height: 38px; }
  .site-footer .fowner .avatar { width: 60px; height: 60px; }
  .topnav .admin-link { padding: 0; width: 40px; justify-content: center; }
  .topnav .admin-link span { display: none; }
  .topnav a { padding: 0 10px; font-size: 14px; }
  .atlas-canvas { height: 62vh; min-height: 380px; }
  .atlas-foot { right: 70px; }
  .prose { font-size: 17.5px; line-height: 1.72; }
  .place-head { flex-direction: column; align-items: flex-start; }
  .visits li { grid-template-columns: 72px minmax(0, 1fr); gap: 14px; }
  .visits li > .letter-stamp { --h: 88px !important; }
  .place-head > .letter-stamp { --h: 118px !important; }
}
@media (prefers-reduced-motion: reduce) { *, *::before, *::after { transition: none !important; animation: none !important; } }
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0; }
/* The single signature motion: the opening postmark is stamped onto the paper */
@media (prefers-reduced-motion: no-preference) {
  .lead-empty .postmark { animation: stamp .55s cubic-bezier(.16, 1, .3, 1) .15s both; transform-origin: 30% 50%; }
}
@keyframes stamp { from { opacity: .3; transform: scale(1.25) rotate(-16deg); } to { opacity: .88; transform: scale(1) rotate(-10deg); } }
[id] { scroll-margin-top: 76px; }
aside .post-row { grid-template-columns: 84px minmax(0, 1fr); gap: 16px; padding: 16px 0; }
aside .post-row h3 { font-size: 17px; }
aside .post-row p:last-child { display: none; }
@media (max-width: 640px) {
  .lead-post .ex { display: -webkit-box; -webkit-line-clamp: 4; -webkit-box-orient: vertical; overflow: hidden; }
  .lead-empty .postmark { width: auto; height: 104px; }
  .post-open .postmark { width: auto; height: 88px; }
}
@media (max-width: 640px) { .place-head .postmark { width: auto; height: 96px; } }
/* Map shapes: show focus on the shape's own outline instead of the browser's box-shaped ring */
.atlas-canvas, .atlas-canvas .land { outline: none !important; -webkit-tap-highlight-color: transparent; }
.atlas-canvas .land:focus-visible { stroke: var(--focus); stroke-width: 2.5; }

.atlas-msg { position: absolute; z-index: 6; left: 50%; top: 50%; transform: translate(-50%, -50%); max-width: min(360px, calc(100% - 48px)); text-align: center; background: var(--ink); color: var(--paper-2); font: 600 15px/1.45 var(--sans); padding: 14px 18px; border-radius: var(--r-m); box-shadow: 0 18px 40px -16px color-mix(in srgb, var(--ink) 50%, transparent); }
.atlas-msg[hidden] { display: none; }
.atlas-msg.err { background: var(--red); }
.atlas.loading .atlas-canvas { opacity: .55; transition: opacity .2s; }

/* Keep the footer at the bottom of the viewport on short pages */
body:not(.admin) { min-height: 100vh; min-height: 100dvh; display: flex; flex-direction: column; }
body:not(.admin) > main { flex: 1 0 auto; }
body:not(.admin) > .site-footer { flex-shrink: 0; }


/* Share rail: vertical, fixed beside the article; a floating button on phones */

.share-rail { position: fixed; z-index: 25; display: flex; flex-direction: column; align-items: center; gap: 8px;
  opacity: 0; pointer-events: none; transition: opacity .25s ease, transform .25s cubic-bezier(.16, 1, .3, 1); }
.share-rail.show { opacity: 1; pointer-events: auto; }
.rail-items { display: flex; flex-direction: column; gap: 8px; }
.rail-btn { position: relative; display: grid; place-items: center; width: 46px; height: 46px; border-radius: 50%; border: 1.5px solid var(--line-2);
  background: var(--paper-2); color: var(--ink); cursor: pointer; text-decoration: none; padding: 0; transition: background .15s, color .15s, border-color .15s; }
.rail-btn:hover, .rail-btn:focus-visible { background: var(--brand, var(--ink)); border-color: var(--brand, var(--ink)); color: #fff; }
.rail-btn[hidden] { display: none; }
.rail-toggle { display: none; }
@media (min-width: 900px) {
  .share-rail { left: max(12px, calc(50% - 380px - 22px)); top: 50%; transform: translate(-6px, -50%); }
  .share-rail.show { transform: translate(0, -50%); }
  .rail-btn::after { content: attr(data-tip); position: absolute; left: calc(100% + 10px); top: 50%; transform: translateY(-50%); white-space: nowrap;
    background: var(--ink); color: var(--paper-2); font: 600 13px var(--sans); padding: 6px 10px; border-radius: var(--r-s); opacity: 0; pointer-events: none; transition: opacity .15s; }
  .rail-btn:hover::after, .rail-btn:focus-visible::after { opacity: 1; }
}
@media (max-width: 899px) {
  .share-rail { right: 14px; bottom: calc(16px + var(--safe-b)); flex-direction: column-reverse; transform: translateY(8px); }
  .share-rail.show { transform: none; }
  .rail-toggle { display: grid; place-items: center; width: 56px; height: 56px; border-radius: 50%; border: 0; background: var(--yellow); color: var(--ink);
    box-shadow: 0 10px 24px -10px color-mix(in srgb, var(--ink) 55%, transparent); cursor: pointer; }
  .rail-items { display: none; }
  .share-rail.open .rail-items { display: flex; }
  .share-rail.open .rail-toggle { background: var(--ink); color: var(--yellow); }
  .rail-btn { box-shadow: 0 6px 16px -10px color-mix(in srgb, var(--ink) 50%, transparent); }
}
.share-toast { position: fixed; z-index: 30; left: 50%; bottom: calc(24px + var(--safe-b)); transform: translateX(-50%); background: var(--ink); color: var(--paper-2);
  font: 600 14px var(--sans); padding: 10px 16px; border-radius: 999px; box-shadow: 0 10px 24px -12px color-mix(in srgb, var(--ink) 60%, transparent); }
.share-toast[hidden] { display: none; }

/* Home: the map is the first viewport */
.atlas-section.first { padding-top: clamp(20px, 3vw, 32px); }
.atlas-h1 { font: var(--logo-st) var(--logo-w) calc(clamp(46px, 7vw, 78px) * var(--logo-scale))/1.05 var(--logo); text-transform: var(--logo-tt); letter-spacing: var(--logo-ls); margin: 0 0 8px; }
.atlas-section.first .atlas-canvas { height: min(68vh, 680px); }
.lead .sec-label { font-size: clamp(22px, 3.2vw, 28px); margin: 0 0 18px; padding-bottom: 12px; border-bottom: 2px solid var(--ink); }
@media (max-width: 640px) { .atlas-section.first .atlas-canvas { height: 58vh; min-height: 360px; } }

/* Letter stamp: perforated postage stamp with a postmark cancelling its corner */
.letter-stamp { position: absolute; display: block; width: calc(var(--h) * 0.82); height: var(--h); pointer-events: none; }
.letter-stamp .pstamp { position: absolute; inset: 0; width: 100%; height: 100%; transform: rotate(4deg); overflow: visible; }
.letter-stamp .cancel { position: absolute; left: -92%; bottom: 38%; width: auto; height: 42%; transform: rotate(-4deg); color: var(--stamp); }
.lead-post .ph .letter-stamp { right: 22px; top: -34px; }
.post-row .ph .letter-stamp { right: -12px; bottom: -14px; }
.post-row .ph .letter-stamp.sm .cancel { display: none; }
.letter-stamp.inline { position: relative; flex: none; margin: 8px 18px 8px 4px; }
@media (prefers-reduced-motion: no-preference) {
  .lead .letter-stamp .cancel { animation: cancel .5s cubic-bezier(.16, 1, .3, 1) .2s both; }
  @keyframes cancel { from { opacity: 0; transform: translateX(-10px) rotate(-4deg); } to { opacity: 1; transform: rotate(-4deg); } }
}
@media (max-width: 640px) {
  .lead-post .ph .letter-stamp { --h: 112px !important; right: 10px; top: -22px; }
  .letter-stamp.inline { --h: 104px !important; }
}

/* Footer social accounts */
.socials { display: flex; flex-wrap: wrap; gap: 8px; }
.socials a { display: grid; place-items: center; width: 44px; height: 44px; border-radius: 50%; color: var(--ink); background: var(--yellow); transition: transform .15s, background .15s; }
.socials a:hover, .socials a:focus-visible { background: var(--paper-2); transform: translateY(-2px); }

/* Post strip: horizontally scrolling cards with stamps */
.strip { margin-top: 56px; padding-bottom: 64px; }
.strip-head { display: flex; align-items: end; justify-content: space-between; gap: 12px; border-bottom: 2px solid var(--ink); padding-bottom: 12px; margin-bottom: 8px; }
.strip-head h2 { margin: 0; }
.strip-nav { display: flex; gap: 6px; }
.strip-btn { display: grid; place-items: center; width: 44px; height: 44px; border-radius: 50%; border: 1.5px solid var(--line-2); background: var(--paper-2); color: var(--ink); cursor: pointer; }
.strip-btn:hover:not(:disabled) { border-color: var(--ink); }
.strip-btn:disabled { opacity: .35; cursor: default; }
.strip-track { display: grid; grid-auto-flow: column; grid-auto-columns: minmax(240px, 280px); gap: 20px; overflow-x: auto; scroll-snap-type: x mandatory;
  padding: 34px 4px 18px; margin: 0 -4px; scrollbar-width: thin; overscroll-behavior-x: contain; }
.strip-track:focus-visible { outline-offset: -2px; }
.post-card { scroll-snap-align: start; text-decoration: none; color: inherit; display: block; }
.post-card .ph { position: relative; aspect-ratio: 4 / 5; border-radius: var(--r-m); background: var(--paper-3); margin-bottom: 14px; }
.post-card .ph img { width: 100%; height: 100%; object-fit: cover; border-radius: var(--r-m); }
.post-card .letter-stamp { right: 12px; top: -24px; }
.post-card .letter-stamp .cancel { left: -78%; height: 40%; bottom: 40%; }
.post-card h3 { font-size: 19px; margin: 0 0 6px; }
.post-card:hover h3 { text-decoration: underline; text-underline-offset: 4px; text-decoration-thickness: 2px; text-decoration-color: var(--yellow-2); }
@media (max-width: 640px) { .strip-track { grid-auto-columns: 74%; } .strip-nav { display: none; } }

/* Author */
.author-card { display: flex; align-items: center; gap: 16px; padding: 18px; background: var(--paper-2); border-radius: var(--r-m); }
.author-card img, .ac-initial { width: 72px; height: 72px; border-radius: 50%; object-fit: cover; flex: none; }
.ac-initial { display: grid; place-items: center; background: var(--yellow); color: var(--ink); font: var(--logo-st) var(--logo-w) calc(38px * var(--logo-scale))/1 var(--logo); text-transform: var(--logo-tt); letter-spacing: var(--logo-ls); }
.ac-initial.big { width: 96px; height: 96px; font-size: 44px; }
.author-card p { margin: 0; }
.ac-name { font-weight: 800; font-size: 18px; }
.ac-tag { color: var(--ink-2); font-family: var(--serif); font-size: 16px; line-height: 1.5; margin-top: 2px !important; }
.ac-more { display: inline-block; margin-top: 6px; font-weight: 700; font-size: 14px; }
.author-card.after-post { margin-top: 48px; }
.about-head { display: flex; flex-wrap: wrap; align-items: center; gap: 24px 36px; padding: clamp(28px, 6vw, 56px) 0 28px; margin-bottom: 28px; border-bottom: 2px solid var(--ink); }
.about-head h1 { margin-bottom: 10px; }
.about-tag { font-family: var(--serif); font-size: 21px; color: var(--ink-2); margin: 0 0 10px; max-width: 40ch; }
.about-stamp .letter-stamp.inline { margin: 12px 8px; }
.about-social { margin-top: 40px; }
.about-social h2 { font-size: 22px; }
.about-social ul { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: 8px; }
.about-social a { display: inline-flex; align-items: center; gap: 8px; min-height: 44px; padding: 0 16px; border-radius: 999px; border: 1.5px solid var(--line-2); background: var(--paper-2); color: var(--ink); text-decoration: none; font-weight: 600; }
.about-social a:hover { border-color: var(--ink); }
@media (max-width: 640px) { .about-head .letter-stamp.inline { --h: 170px !important; } }

/* Narrow phones: keep the avatar, wordmark and four nav items on one row */
@media (max-width: 400px) {
  .topbar { padding-left: 14px; padding-right: 10px; }
  .brand { font-size: calc(23px * var(--logo-scale)); gap: 7px; }
  .brand .avatar { width: 34px; height: 34px; }
  .topnav a { padding: 0 7px; }
}


/* Phones: the logo already opens the map, so "Harita" steps aside to leave room for the handwritten logo and Yönet */
@media (max-width: 440px) {
  .topnav .nav-map { display: none; }
  .topbar { gap: 6px; }
  .brand { font-size: calc(21px * var(--logo-scale)); gap: 6px; }
  .brand .avatar { width: 32px; height: 32px; }
  .topnav a { padding: 0 8px; }
  .topnav .admin-link { width: 38px; margin-left: 4px; padding: 0; }
}
@media (max-width: 360px) {
  .brand { font-size: calc(19px * var(--logo-scale)); }
  .topnav a { padding: 0 5px; }
  .topbar:has(.has-admin) .brand span { display: none; } /* tiny phones + Yönet: the avatar alone is the home link */
}
@media (max-width: 360px) {
  .topbar { padding-left: 10px; padding-right: 6px; }
  .brand { font-size: calc(20px * var(--logo-scale)); gap: 6px; }
  .brand .avatar { width: 30px; height: 30px; }
  .topnav a { padding: 0 5px; font-size: 13px; }
  .topnav .nav-map { display: none; }
}
.badge-group { margin-bottom: 32px; }
.place-list .badge.whole { font-weight: 700; }

/* Postage stamps replace the round postmarks on place pages and photo-less posts; here they sit in the flow */
.place-head > .letter-stamp, .visits li > .letter-stamp, .empty-ph .letter-stamp, .stamp-only .letter-stamp, .lead-empty .letter-stamp, .auth-card .letter-stamp { position: relative; inset: auto; flex: none; }
.place-head > .letter-stamp { transform: rotate(-4deg); margin: 6px 8px; }
.post-row .ph.empty-ph { display: grid; place-items: center; }
.post-row .ph.empty-ph .letter-stamp, .lead-post .stamp-only .letter-stamp { transform: rotate(-5deg); }

/* Badge icons (Iconify or emoji) take the place of the coloured dot */
.bicon { display: inline-block; flex: none; width: 1.15em; height: 1.15em; font-size: 15px; line-height: 1; color: var(--c, var(--post)); }
.bicon.emoji { width: auto; height: auto; }
iconify-icon.bicon { vertical-align: -0.2em; }
.f-ic { display: inline-flex; width: 18px; justify-content: center; }
.f-ic .bicon { font-size: 16px; color: color-mix(in srgb, var(--c) 45%, #fff); }
.f-ic .dot { flex: none; width: 9px; height: 9px; border-radius: 50%; background: var(--c); box-shadow: 0 0 0 2px rgba(255, 255, 255, .12); }

/* 2B / 3B switch and the globe */
.view-toggle { display: inline-flex; margin-right: auto; border-radius: 999px; background: var(--paper-2); box-shadow: inset 0 0 0 1.5px var(--line-2); padding: 3px; gap: 2px; align-self: flex-start; }
.view-toggle button { min-height: 34px; min-width: 44px; padding: 0 12px; border: 0; border-radius: 999px; background: transparent; font: 700 14px/1 var(--sans); color: var(--ink); cursor: pointer; }
.view-toggle button[aria-pressed="true"] { background: var(--ink); color: var(--yellow); }
.view-toggle button:focus-visible { outline: 3px solid var(--focus); outline-offset: 2px; }
.atlas-canvas .ocean { fill: url(#globe-shade); stroke: var(--land-edge); stroke-width: 1; }
.atlas-canvas .gs-0 { stop-color: var(--paper-2); }
.atlas-canvas .gs-1 { stop-color: color-mix(in srgb, var(--post) 16%, var(--water)); }
.is-globe .atlas-canvas { cursor: grab; }
.is-globe .atlas-canvas:active { cursor: grabbing; }
.is-globe .atlas-canvas .graticule { stroke: color-mix(in srgb, var(--post) 18%, transparent); }
/* Any logo font (also a custom one) must leave room for the menu: the name shrinks with an ellipsis instead of pushing the page wider */
.topbar .brand { min-width: 0; flex-shrink: 1; }
.brand span { overflow: hidden; text-overflow: ellipsis; }
.topbar .topnav { flex-shrink: 0; }

/* Embedded players (YouTube, Instagram, Spotify…) inside posts and the about page */
.prose figure.embed { margin: 2.2em auto; }
.embed-frame { position: relative; border-radius: var(--r-s); overflow: hidden; background: var(--paper-2); }
.embed-frame iframe { display: block; width: 100%; height: 100%; border: 0; }
.embed-wide .embed-frame { aspect-ratio: 16 / 9; }
.prose figure.embed-tall { max-width: 420px; }
.embed-tall .embed-frame { height: 720px; max-height: 85vh; }
.embed-tall[data-provider="tiktok"] .embed-frame { height: 760px; }
.embed-audio .embed-frame { height: 152px; border-radius: 12px; }
.embed-audio.audio-big .embed-frame { height: 380px; }
.prose figure.embed-post { max-width: 550px; }
.embed-post .embed-frame { height: 620px; max-height: 85vh; background: #fff; }
.embed figcaption a { color: inherit; }

/* Map: search, tiny-country dots, country names, gesture hint */
.atlas-search { position: absolute; z-index: 5; left: var(--gutter); top: 14px; width: min(300px, 40%); }
.atlas-search > svg { position: absolute; left: 14px; top: 50%; transform: translateY(-50%); color: var(--ink-3); pointer-events: none; }
.atlas-search input { width: 100%; min-height: 44px; padding: 0 14px 0 40px; border-radius: 999px; border: 1.5px solid var(--line-2); background: var(--paper-2); color: var(--ink); font: 500 15px var(--sans); }
.atlas-search input:focus { outline: none; border-color: var(--ink); box-shadow: 0 0 0 3px color-mix(in srgb, var(--yellow) 60%, transparent); }
.atlas-search .picker-list { position: absolute; left: 0; right: 0; top: calc(100% + 6px); list-style: none; margin: 0; padding: 6px; background: var(--paper-2); border-radius: var(--r-m); box-shadow: 0 18px 40px -16px color-mix(in srgb, var(--ink) 45%, transparent); max-height: 320px; overflow-y: auto; }
.atlas-search .picker-list li { display: flex; justify-content: space-between; gap: 12px; padding: 11px 12px; border-radius: var(--r-s); cursor: pointer; font-weight: 600; font-size: 15px; }
.atlas-search .picker-list li small { color: var(--ink-3); font-weight: 500; white-space: nowrap; }
.atlas-search .picker-list li:hover, .atlas-search .picker-list li[aria-selected="true"] { background: color-mix(in srgb, var(--yellow) 35%, var(--paper-2)); }
@media (max-width: 639px) {
  .atlas-search { right: var(--gutter); width: auto; }
  .atlas-search ~ .atlas-head, .atlas-head:has(~ .atlas-search) { top: 66px; }
}
.atlas-canvas .land.dot { stroke: var(--land-edge); stroke-width: 1.2px; vector-effect: non-scaling-stroke; cursor: pointer; }
.atlas-canvas .land.dot:not(.has) { fill: color-mix(in srgb, var(--land) 70%, var(--ink)); }
.atlas-canvas .wlabel { font-weight: 600; fill: var(--ink-2); letter-spacing: .01em; }
.atlas-canvas .wlabel.has { font-weight: 700; fill: var(--ink); }
.atlas-canvas .land.flash { animation: land-flash 1.4s ease-out 2; }
@keyframes land-flash { 0%, 100% { stroke-width: 2px; } 40% { stroke-width: 6px; stroke: var(--yellow-2); } }
@media (prefers-reduced-motion: reduce) { .atlas-canvas .land.flash { animation: none; } }
.atlas-hint { position: absolute; z-index: 6; left: 50%; top: 50%; transform: translate(-50%, -50%); padding: 12px 18px; border-radius: 999px; background: color-mix(in srgb, var(--ink) 86%, transparent); color: #fff; font: 600 15px var(--sans); text-align: center; pointer-events: none; opacity: 0; transition: opacity .25s; max-width: calc(100% - 40px); }
.atlas-hint.on { opacity: 1; }
/* with the search box on the left, the 2B/3B switch sits with the level buttons on the right */
.atlas:has(.atlas-search) .view-toggle { margin: 0 10px 0 0; }
.atlas:has(.atlas-search) .atlas-head { gap: 0; flex-wrap: wrap; justify-content: flex-end; }
@media (min-width: 640px) { .atlas:has(.atlas-search) .atlas-head { left: calc(var(--gutter) + min(300px, 40%) + 16px); } }

/* Header menu: inline links on wide screens, a block dropdown under the masthead on phones */
.menu-btn { display: none; }
.topnav a > svg { display: none; }
.topnav .nav-search > svg, .topnav .admin-link > svg { display: block; }
.topnav .nav-search span { display: none; }
@media (max-width: 640px) {
  .topbar { gap: 10px; }
  .topbar .brand { font-size: calc(26px * var(--logo-scale)); }
  .topbar .brand span { display: inline !important; }
  .menu-btn { display: grid; place-items: center; flex: none; width: 46px; height: 46px; margin-right: -4px; border: 0; border-radius: 50%; background: none; color: var(--ink); cursor: pointer; }
  .menu-btn:hover { background: color-mix(in srgb, var(--ink) 8%, transparent); }
  .menu-btn:focus-visible { outline: 3px solid var(--ink); outline-offset: 1px; }
  .menu-icon { position: relative; width: 22px; height: 16px; }
  .menu-icon span { position: absolute; left: 0; width: 100%; height: 2.5px; border-radius: 2px; background: currentColor; transition: transform .2s, opacity .2s, top .2s; }
  .menu-icon span:nth-child(1) { top: 0; }
  .menu-icon span:nth-child(2) { top: 7px; }
  .menu-icon span:nth-child(3) { top: 14px; }
  .menu-open .menu-icon span:nth-child(1) { top: 7px; transform: rotate(45deg); }
  .menu-open .menu-icon span:nth-child(2) { opacity: 0; }
  .menu-open .menu-icon span:nth-child(3) { top: 7px; transform: rotate(-45deg); }

  .topbar .topnav { display: none; position: absolute; left: 0; right: 0; top: 100%; flex-direction: column; align-items: stretch; gap: 2px;
    padding: 8px var(--gutter) 14px; background: var(--yellow); border-top: 1.5px solid color-mix(in srgb, var(--ink) 14%, transparent);
    box-shadow: 0 22px 30px -18px color-mix(in srgb, var(--ink) 45%, transparent); }
  .topbar.menu-open .topnav { display: flex; }
  .topbar .topnav a, .topbar .topnav .admin-link { display: flex !important; width: auto; min-height: 52px; margin: 0; padding: 0 14px !important; gap: 14px; border: 0; border-radius: var(--r-s); font: 600 17px/1 var(--sans); justify-content: flex-start; }
  .topbar .topnav a > svg { display: block; flex: none; }
  .topbar .topnav a span { display: inline !important; }
  .topbar .topnav .admin-link { margin-top: 6px; border: 1.5px solid var(--ink); }
  .topbar .topnav a[aria-current="page"] { background: var(--ink); color: var(--yellow); }
}
@media (max-width: 640px) and (prefers-reduced-motion: no-preference) {
  .topbar.menu-open .topnav { animation: menu-in .16s ease-out; }
  @keyframes menu-in { from { opacity: 0; transform: translateY(-6px); } }
}
@media (max-width: 360px) { .topbar .brand { font-size: calc(22px * var(--logo-scale)); } }

/* Rich text: nested lists, tables, highlight, code */
.prose li > ul, .prose li > ol { margin: .35em 0 .35em; }
.prose ul ul { list-style-type: circle; }
.prose ul ul ul { list-style-type: square; }
.prose ol ol { list-style-type: lower-alpha; }
.prose ol ol ol { list-style-type: lower-roman; }
.prose table { display: block; max-width: 100%; overflow-x: auto; margin: 1.8em 0; border-collapse: collapse; font-family: var(--sans); font-size: .82em; line-height: 1.45; -webkit-overflow-scrolling: touch; }
.prose th, .prose td { padding: .65em .9em; border-bottom: 1px solid var(--line); text-align: left; vertical-align: top; min-width: 6em; }
.prose thead th { border-bottom: 2px solid var(--ink); font-weight: 700; white-space: nowrap; }
.prose tbody tr:nth-child(even) { background: color-mix(in srgb, var(--yellow) 14%, transparent); }
.prose mark { background: color-mix(in srgb, var(--yellow) 85%, transparent); color: inherit; padding: 0 .15em; border-radius: 3px; }
.prose code { font-family: ui-monospace, "SF Mono", Menlo, Consolas, monospace; font-size: .85em; padding: .1em .35em; border-radius: 4px; background: color-mix(in srgb, var(--ink) 8%, transparent); }
.prose sup { font-size: .7em; }
@media (min-width: 641px) { .prose table { display: table; width: 100%; } }

/* Route map, series */
.route-map { margin: 2.2em 0; }
.route-map svg { width: 100%; height: auto; display: block; border-radius: var(--r-m); background: color-mix(in srgb, var(--ink) 6%, var(--paper-2)); }
.route-map .rm-sea { fill: color-mix(in srgb, #8DB8D3 45%, var(--paper-2)); }
.route-map .rm-land { fill: var(--land); stroke: var(--land-edge); stroke-width: .6; }
.route-map .rm-route { fill: none; stroke: var(--ink); stroke-width: 3; stroke-linecap: round; stroke-linejoin: round; }
.route-map .rm-stop { fill: var(--yellow); stroke: var(--ink); stroke-width: 2.5; }
.route-map a:hover .rm-stop, .route-map a:focus .rm-stop { fill: var(--ink); }
.route-map a:hover .rm-n, .route-map a:focus .rm-n { fill: var(--yellow); }
.route-map .rm-n { font: 800 13px var(--sans); fill: var(--ink); text-anchor: middle; pointer-events: none; }
.route-map .rm-name { font: 700 13px var(--sans); fill: var(--ink); text-anchor: middle; paint-order: stroke; stroke: var(--paper-2); stroke-width: 4px; pointer-events: none; }
.route-list { display: flex; flex-wrap: wrap; gap: 4px 0; margin: 10px 0 0; padding: 0; list-style: none; counter-reset: st; font: 600 14px var(--sans); }
.route-list li { counter-increment: st; }
.route-list li::before { content: counter(st) ". "; color: var(--ink-3); }
.route-list li:not(:last-child)::after { content: "→"; margin: 0 10px; color: var(--ink-3); }
.route-list a { color: var(--ink); }
.series-box { margin: 2.4em 0; padding: 18px 20px; border-radius: var(--r-m); background: color-mix(in srgb, var(--yellow) 30%, var(--paper-2)); font-family: var(--sans); }
.series-box p { margin: 0 0 12px; font-size: 15px; }
.series-box a { color: var(--ink); }
.series-nav { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.series-nav a { display: grid; gap: 2px; text-decoration: none; font-weight: 700; font-size: 15px; line-height: 1.35; }
.series-nav a span { font-size: 12px; font-weight: 600; color: var(--ink-2); }
.series-nav a.next { text-align: right; }
.series-list { list-style: none; margin: 0; padding: 0; }
.eyebrow-line { margin: 0 0 4px; font: 700 13px var(--sans); color: var(--stamp); }
.series-desc { margin-top: 12px; }
.atlas-canvas .photo-dot { fill: #fff; stroke: var(--stamp); cursor: pointer; vector-effect: non-scaling-stroke; }
.atlas-canvas .photo-dot:hover, .atlas-canvas .photo-dot:focus-visible { fill: var(--yellow); outline: none; }
.chip-btn.photo-toggle svg { flex: none; }
.photo-card { display: flex; gap: 14px; align-items: center; color: var(--ink); text-decoration: none; padding-right: 30px; }
.photo-card img { width: 96px; height: 96px; object-fit: cover; border-radius: var(--r-s); flex: none; }
.photo-card span { display: grid; gap: 4px; }
.photo-card strong { font-size: 16px; line-height: 1.3; }
.photo-card small { color: var(--ink-2); font-size: 13px; }
.photo-card:hover strong { text-decoration: underline; }

/* Statistics page */
.stats-page { padding-bottom: 40px; }
.stat-big { display: grid; grid-template-columns: repeat(auto-fit, minmax(130px, 1fr)); gap: 12px; margin: 8px 0 40px; }
.stat-big div { padding: 18px 20px; border-radius: var(--r-m); background: var(--paper-2); box-shadow: inset 0 0 0 1.5px var(--line); display: grid; gap: 2px; }
.stat-big strong { font: 900 clamp(40px, 6vw, 60px)/1 var(--display); color: var(--ink); font-variant-numeric: tabular-nums; }
.stat-big span { font: 600 14px var(--sans); color: var(--ink-2); }
.stat-sec { margin-bottom: 40px; }
.stat-sec h2 { font-size: clamp(22px, 3vw, 28px); margin-bottom: 18px; }
.stat-sec .h-sub { font-size: 20px; margin: 28px 0 12px; }
.pbar { margin-bottom: 22px; font-family: var(--sans); }
.pbar-head { display: flex; justify-content: space-between; align-items: baseline; font-weight: 600; margin-bottom: 8px; }
.pbar-head strong { font: 900 28px/1 var(--display); }
.pbar-track { height: 16px; border-radius: 999px; background: color-mix(in srgb, var(--ink) 9%, transparent); overflow: hidden; }
.pbar-track span { display: block; height: 100%; border-radius: inherit; background: var(--ink); }
.pbar-note { margin: 6px 0 0; font-size: 13px; color: var(--ink-3); }
.stat-cols { display: grid; grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); gap: 0 40px; }
.stat-badges { list-style: none; margin: 0; padding: 0; display: grid; gap: 8px; }
.stat-badges a { display: grid; grid-template-columns: 28px 1fr auto; align-items: center; gap: 10px; padding: 10px 14px; border-radius: var(--r-s); background: var(--paper-2); color: var(--ink); text-decoration: none; font: 600 15px var(--sans); box-shadow: inset 4px 0 0 var(--c); }
.stat-badges a:hover { box-shadow: inset 4px 0 0 var(--c), inset 0 0 0 1.5px var(--ink); }
.stat-badges .bicon, .stat-badges .dot { color: var(--c); font-size: 20px; justify-self: center; }
.stat-badges .dot { width: 12px; height: 12px; border-radius: 50%; background: var(--c); }
.stat-badges strong { font-variant-numeric: tabular-nums; }
.year-bars { list-style: none; margin: 0; padding: 0; display: grid; gap: 8px; font: 600 14px var(--sans); }
.year-bars li { display: grid; grid-template-columns: 48px 1fr 32px; align-items: center; gap: 10px; }
.year-bars .yb { height: 14px; border-radius: 999px; background: color-mix(in srgb, var(--ink) 8%, transparent); overflow: hidden; }
.year-bars .yb span { display: block; height: 100%; background: var(--yellow-2); border-radius: inherit; }
.year-bars strong { text-align: right; font-variant-numeric: tabular-nums; }
.top-places { margin: 0; padding-left: 22px; font: 600 15px var(--sans); display: grid; gap: 6px; }
.top-places li span { color: var(--ink-3); font-weight: 500; margin-left: 8px; }
.top-places a, .wish-list a { color: var(--ink); }
.wish-list { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: 8px; }
.wish-list a { display: inline-block; padding: 8px 14px; border-radius: 999px; background: var(--paper-2); box-shadow: inset 0 0 0 1.5px var(--line-2); font: 600 14px var(--sans); text-decoration: none; }
.wish-list a:hover { box-shadow: inset 0 0 0 1.5px var(--ink); }

/* Newsletter */
.nl-form { display: grid; gap: 8px; max-width: 460px; font-family: var(--sans); }
.nl-form label { font-weight: 600; font-size: 14px; }
.nl-row { display: flex; gap: 8px; }
.nl-row input { flex: 1; min-width: 0; }
.nl-row .btn { flex: none; }
.nl-hp { position: absolute !important; left: -9999px; width: 1px; height: 1px; opacity: 0; }
.nl-note { margin: 0; font-size: 12.5px; line-height: 1.5; color: var(--ink-3); }
.nl-msg { padding: 14px 16px; border-radius: var(--r-m); font: 600 15px/1.5 var(--sans); }
.nl-msg.ok { background: color-mix(in srgb, #2E8B57 14%, var(--paper-2)); color: #1d5c3a; }
.nl-msg.err { background: color-mix(in srgb, var(--red) 10%, var(--paper-2)); color: var(--red); }
.site-footer .f-nl { margin-top: 22px; }
.site-footer .f-nl-h { margin: 0 0 8px; font: 700 15px var(--sans); color: #fff; }
.site-footer .nl-form label { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }
.site-footer .nl-form input { background: rgba(255,255,255,.08); border-color: rgba(230,232,240,.25); color: #fff; }
.site-footer .nl-form input::placeholder { color: #9CA3BD; }
.site-footer .nl-form .btn { background: var(--yellow); color: var(--ink); border-color: var(--yellow); }
.site-footer .nl-note { color: #9CA3BD; }
.series-index { list-style: none; margin: 0 0 48px; padding: 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 18px; }
.series-index a { display: grid; gap: 6px; padding: 14px; border-radius: var(--r-m); background: var(--paper-2); box-shadow: inset 0 0 0 1.5px var(--line); color: var(--ink); text-decoration: none; font-family: var(--sans); }
.series-index a:hover { box-shadow: inset 0 0 0 2px var(--ink); }
.series-index strong { font-size: 19px; }
.series-index .muted { font-size: 14px; }
.si-pics { display: grid; grid-template-columns: 2fr 1fr; grid-template-rows: 1fr 1fr; gap: 4px; aspect-ratio: 3 / 2; margin-bottom: 6px; border-radius: var(--r-s); overflow: hidden; background: color-mix(in srgb, var(--ink) 8%, transparent); }
.si-pics picture:first-child { grid-row: 1 / 3; }
.si-pics img { width: 100%; height: 100%; object-fit: cover; display: block; }
.si-pics picture { min-height: 0; }
.si-pics:not(:has(picture:nth-child(3))) { grid-template-columns: 1fr 1fr; grid-template-rows: 1fr; }
.si-pics:not(:has(picture:nth-child(3))) picture:first-child { grid-row: auto; }
.si-pics:not(:has(picture:nth-child(2))) { grid-template-columns: 1fr; }

/* Fields: theme focus ring; native selects (no JS, or the date picker's time) with a matching chevron */
input:focus, select:focus, textarea:focus { border-color: var(--ink); box-shadow: 0 0 0 3px color-mix(in srgb, var(--yellow) 65%, transparent); }
select { -webkit-appearance: none; appearance: none; padding-right: 38px; cursor: pointer;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='18' height='18' viewBox='0 0 24 24' fill='none' stroke='%23596079' stroke-width='2.2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M6 9l6 6 6-6'/%3E%3C/svg%3E");
  background-repeat: no-repeat; background-position: right 12px center; }
select option { color: var(--ink); background: var(--paper-2); }
/* medium screens: with "Rotalar" added, Yönet shows only its icon so the header stays on one line */
@media (min-width: 641px) and (max-width: 860px) {
  .topnav .admin-link { padding: 0; width: 40px; justify-content: center; }
  .topnav .admin-link span { display: none; }
  .topnav a { padding: 0 9px; }
}

/* Phones: a lighter map toolbar so the map itself gets the room */
@media (max-width: 639px) {
  .atlas-search { top: 10px; }
  .atlas-search input { min-height: 38px; padding: 0 12px 0 34px; font-size: 14px; }
  .atlas-search > svg { left: 11px; width: 16px; height: 16px; }
  .atlas-search ~ .atlas-head, .atlas-head:has(~ .atlas-search) { top: 56px; }
  .atlas-head .crumbs { gap: 4px; font-size: 13px; }
  .atlas-head .crumbs button { min-height: 32px; min-width: 0; padding: 0 11px; font-size: 13px; border-width: 1.5px; }
  .atlas-head .view-toggle { padding: 2px; }
  .atlas-head .view-toggle button { min-height: 28px; min-width: 34px; padding: 0 9px; font-size: 12.5px; }
  .atlas:has(.atlas-search) .view-toggle { margin-right: 6px; }
  .atlas-controls { gap: 5px; right: 10px; bottom: calc(12px + var(--safe-b)); }
  .atlas-controls button { min-width: 36px; min-height: 36px; width: 36px; height: 36px; font-size: 15px; }
  .atlas-controls button svg { width: 17px; height: 17px; }
  .atlas-foot { left: 10px; right: 56px; bottom: calc(12px + var(--safe-b)); }
  .legend { gap: 5px; }
  .chip-btn { min-height: 30px; padding: 0 10px; gap: 5px; font-size: 12px; border-width: 1.5px; }
  .chip-btn .dot { width: 8px; height: 8px; }
  .chip-btn svg, .chip-btn .bicon { width: 13px; height: 13px; font-size: 13px; }
}
