/* ir-globe — editorial serif line (newspaper), grey globe centred, articles hug it left+right.
   one navy accent = meaning. sharp corners, hairline rules, no glow. */

* { margin: 0; padding: 0; box-sizing: border-box; }

:root {
  --paper: #ffffff;
  --ink: #16191f;
  --muted: #6b7280;
  --faint: #aeb4be;
  --rule: #e4e7ec;
  --navy: #17356b;
  --royal: #2b5cad;
  /* our fonts: warm editorial serif for headlines, clean sans everywhere else */
  --serif: "Newsreader", Georgia, serif;
  --sans: "Inter", -apple-system, "Helvetica Neue", Arial, sans-serif;
}

body {
  background: var(--paper);
  color: var(--ink);
  font-family: var(--sans);
}
/* ── 3-page magazine: editorial / küre / katıl (window scrolls; JS eases page-to-page) ── */
html { scroll-snap-type: y proximity; }
.page {
  min-height: 100vh; height: 100vh; scroll-snap-align: start;
  display: flex; flex-direction: column; position: relative; overflow: hidden;
  max-width: 1180px; margin: 0 auto;
}

/* sayfa geçme hissi: içerik, o sayfaya snap olunca belirir (fade + yukarı kayma) */
.ed-in, .jn-in, .gl #layers, .gl .stage, .gl #countries {
  opacity: 0; transform: translateY(18px);
  transition: opacity 0.6s ease, transform 0.6s ease;
}
.page.in .ed-in, .page.in .jn-in,
.gl.in #layers, .gl.in .stage, .gl.in #countries { opacity: 1; transform: none; }
.gl .stage { transition-delay: 0.08s; }
.gl #countries { transition-delay: 0.16s; }

/* SAYFA 1 — editorial: masthead + manşet digesti (üstte), sayaç en altta */
.page.ed { justify-content: flex-start; }
.ed-in { flex: 1 1 auto; width: 100%; max-width: 1000px; margin: 0 auto; padding: 0 40px;
  display: flex; flex-direction: column; justify-content: center; }
.mast { display: block; padding: 0; }
.mast h1 { font-size: 34px; white-space: normal; }
.mast-sub { display: block; font-size: 13px; color: var(--muted); margin-top: 4px; }
.mast-fresh { display: block; font-size: 12px; color: var(--faint); margin-top: 3px; font-variant-numeric: tabular-nums; }
.dg-new { color: var(--navy); font-weight: 700; text-transform: lowercase; }
.countdown { margin-top: 22px; font-size: 12.5px; color: var(--faint); font-variant-numeric: tabular-nums; }
/* makaleler doğal kolonlara akar — satır hizası kaynaklı boşluk yok */
.digest { column-count: 3; column-gap: 40px; margin-top: 22px; }
.dg { display: block; break-inside: avoid; margin-bottom: 16px; }
.dg-t { display: block; font-family: var(--serif); font-size: 15.5px; line-height: 1.25; color: var(--ink); }
.dg:hover .dg-t { color: var(--navy); }
.dg-m { display: block; font-size: 11.5px; color: var(--muted); margin-top: 3px; }
.dg-load { color: var(--faint); font-size: 13px; }
.ed-scroll { margin-top: 26px; font-size: 12.5px; color: var(--faint); }

/* SAYFA 2 — küre: kategoriler + globe fill the screen */
.page.gl { justify-content: flex-start; }
.page.gl .stage { height: auto; flex: 1; min-height: 0; }

/* HERO (katıl): arka planda soluk gerçek başlık duvarı, önünde net metin.
   .page global 1180px'de ortalanıyor — hero'yu TAM viewport genişliğine aç ki
   duvar ekranın kenarından kenarına yayılsın (sağ-sol boşluk kalmasın). */
.page.jn { justify-content: flex-start; position: relative; overflow: hidden; max-width: none; width: 100%; }

/* arka plan duvarı: kolon YOK — başlıklar justify akışla iç içe geçer, biri
   ötekinin girintisinden başlar; her başlığın fontu hafif farklı; alt-üst solar. */
.jn-wall {
  position: absolute; inset: 0; z-index: 0;
  padding: 8px 12px; overflow: hidden; pointer-events: none;
  /* SİS YOK: sadece alt-üst yumuşak solma (tek hafif maske, kasmıyor). Duvar soluk
     olduğu için ortada yazı net okunur. Bloklar JS masonry ile iç içe yerleşir. */
  -webkit-mask-image: linear-gradient(to bottom, transparent 0, #000 6%, #000 92%, transparent 100%);
  mask-image: linear-gradient(to bottom, transparent 0, #000 6%, #000 92%, transparent 100%);
}
.jn-wall .wl {
  position: absolute; top: 0; left: 0;                    /* JS masonry yerleştirir */
  font-family: var(--serif); color: #e2e5ea; text-decoration: none;   /* soluk — yazı üstünde net */
  transition: transform 0.24s cubic-bezier(0.22, 1, 0.36, 1), color 0.18s ease;
}
.jn-wall .wl.s1 { font-size: 11px; line-height: 1.22; }
.jn-wall .wl.s2 { font-size: 12.5px; line-height: 1.22; }
.jn-wall .wl.s3 { font-size: 14px; line-height: 1.2; }
.jn-wall .wl.s4 { font-size: 15.5px; line-height: 1.18; }
.jn-wall .wl.s5 { font-size: 17px; line-height: 1.15; }
/* masaüstü: üstüne gelince BÜYÜR (font) → JS aynı kolondaki altındakileri kaydırır;
   rengi koyu gri olur (simsiyah değil). .big sınıfı boyut sınıflarını ezmeli → sonda. */
@media (hover: hover) and (pointer: fine) {
  .jn-wall .wl { pointer-events: auto; cursor: default; }
  .jn-wall .wl.big { font-size: 19px; line-height: 1.18; color: #4b515e; z-index: 2; }
}

.jn-in { position: relative; z-index: 2; flex: 1 1 auto; width: 100%; max-width: 640px; margin: 0 auto; padding: 0 40px;
  display: flex; flex-direction: column; justify-content: center; align-items: center; text-align: center;
  pointer-events: none; }                                 /* altındaki duvar başlıkları da hover alsın */
.jn-in a, .jn-in .jn-cta { pointer-events: auto; }        /* linkler yine tıklanır */
/* önündeki metin duvarın üstünde net okunsun: GÜÇLÜ beyaz hale (ortada duvar
   zaten silik ama emniyet için katmanlı hale) */
.jn-in .hero-mast h1, .jn-in .mast-fresh, .jn-in .bhead, .jn-in .btext, .jn-in .bfine, .jn-in .ed-scroll {
  text-shadow: 0 0 7px #fff, 0 0 7px #fff, 0 0 14px #fff, 0 0 14px #fff, 0 0 22px #fff, 0 0 32px #fff;
}
.jn-in .btext { margin: 0 auto 14px; color: #16191f; }
.jn-in .bhead { color: #16191f; }
/* hero başlığı (marka) — pitch'in üstünde, ondan küçük */
.hero-mast { display: block; margin-bottom: 12px; }
.hero-mast h1 { font-size: 24px; }
.hero-mast .mast-fresh { margin-top: 2px; }
.jn-in .ed-scroll { margin-top: 24px; }

/* SAYFA 3 — kapanış: temiz beyaz, sayaç + künye (kürenin altındaki sayfa) */
.page.close { justify-content: center; position: relative; }
.close-in { width: 100%; max-width: 620px; margin: 0 auto; padding: 0 40px; text-align: center; }
.close-in .bhead { margin-bottom: 24px; }
.close-in .stats { padding: 8px 0 0; }
.page.close footer { position: absolute; left: 0; right: 0; bottom: 0; }

/* sayaç — ortada, kolonlara yakın (en alttan biraz yukarı) */
.stats { display: flex; justify-content: center; flex-wrap: wrap; gap: 22px 48px; padding: 6px 40px 60px; }
.stat { display: flex; flex-direction: column; align-items: center; gap: 1px; }
.statn { font-family: var(--sans); font-weight: 700; font-size: 30px; line-height: 1; letter-spacing: -0.01em; color: var(--navy); font-variant-numeric: tabular-nums; }
.statl { font-size: 12px; color: var(--muted); }
.page.jn footer { margin-top: 0; position: relative; z-index: 2; }
.page.jn footer .foot-nav, .page.jn footer .foot-src { text-shadow: 0 0 8px #fff, 0 0 8px #fff, 0 0 14px #fff; }

/* serif only for headlines + the editorial writing — the authority voice */
h1, .col h2, .writing, .card-title { font-family: var(--serif); }
.cnt { font-variant-numeric: tabular-nums; }

/* globe.gl's own hover tooltip renders outside our tree — force it to match */
.scene-tooltip, .scene-tooltip * { font-family: var(--sans) !important; font-size: 12.5px !important; }

a { color: var(--royal); text-decoration: none; }
a:hover { text-decoration: underline; text-underline-offset: 3px; }
button { font: inherit; color: inherit; background: none; border: none; cursor: pointer; }

/* title + categories side by side on one top line, no divider lines */
header {
  display: flex;
  align-items: baseline;
  gap: 26px;
  padding: 12px 32px 8px;
}
h1 { font-size: 22px; font-weight: 400; letter-spacing: -0.01em; white-space: nowrap; }

/* kategoriler: kenara yapışmasın, biraz aşağı */
#layers {
  display: flex;
  flex-wrap: wrap;
  gap: 4px 18px;
  padding: 30px 40px 14px;
}
.layerbtn { font-size: 16px; color: var(--muted); transition: color 0.15s; }
.layerbtn:hover { color: var(--ink); }
.layerbtn.on { color: var(--navy); font-weight: 700; }
.layerbtn.soon { color: var(--faint); }
.layerbtn.viewcap { font-size: 13px; color: var(--faint); font-style: italic; }
.layerbtn.viewcap:hover { color: var(--navy); }

/* stage: globe dead-centre, articles hug it left + right — ( o ) */
.stage { position: relative; height: 82vh; min-height: 520px; }
#globe { position: absolute; inset: 0; }

.intro-writing { color: var(--muted); }
.intro-writing strong { color: var(--navy); }

/* hikaye paneli: dikey ortalı, sol kavise yaslı, iki yana nefes payı (kart-simetrisi) */
.col {
  position: absolute;
  top: 0;
  bottom: 0;
  width: 300px;
  display: flex; flex-direction: column; justify-content: center;   /* dikey ortala → kürenin sol kavisi hizasında */
  overflow-y: auto;
  padding: 26px 26px 26px 44px;                                     /* soldan nefes payı */
  z-index: 2;
}
.col.left { left: 0; }

/* deploy geldi mi diye kontrol için görünür sürüm etiketi */
.build { color: var(--faint); font-variant-numeric: tabular-nums; }

/* section labels: tracked small caps, the editorial signature */
.lbl { font-size: 11px; font-weight: 700; letter-spacing: 0.1em; text-transform: uppercase; color: var(--muted); margin: 12px 0 4px; }
.lbl:first-child { margin-top: 0; }

.col h2 { font-size: 22px; font-weight: 400; line-height: 1.15; margin-bottom: 7px; }

/* tight, like the article headlines */
.writing { font-size: 14px; line-height: 1.4; color: #262f3a; }
.writing p { margin-bottom: 5px; }
.writing strong { font-weight: 700; color: var(--navy); }

/* ── liquid headlines: real articles placed along the globe's right arc, wrapping it ── */
#cards {
  position: absolute;
  inset: 0;
  z-index: 2;
  pointer-events: none;
  opacity: 0;
  transition: opacity 0.45s;
}
#cards.show { opacity: 1; }
.cards-lbl { display: none; }
.card {
  position: absolute;            /* JS places each along the sphere's edge */
  width: 250px;
  pointer-events: auto;
  color: var(--ink);
  transform: translateY(-50%);
  /* soft white halo so headlines stay readable floating over the globe — not a box */
  text-shadow: 0 0 7px #fff, 0 0 7px #fff, 0 0 14px #fff, 0 1px 2px #fff;
  transition: left 0.6s cubic-bezier(0.22, 1, 0.36, 1), top 0.6s cubic-bezier(0.22, 1, 0.36, 1), color 0.15s;
  opacity: 0;
  translate: 0 0;
  animation: card-in 0.55s ease forwards, card-float 6s ease-in-out infinite;
  animation-delay: calc(var(--i) * 70ms), calc(var(--i) * 320ms);
}
.card:hover { color: var(--royal); text-decoration: none; }
.card-title { display: block; font-size: 14.5px; line-height: 1.3; }
.card-meta { display: block; margin-top: 2px; font-size: 10.5px; color: var(--muted); }
@keyframes card-in { to { opacity: 1; } }
@keyframes card-float { 0%, 100% { translate: 0 0; } 50% { translate: 0 -3px; } }

.src { font-size: 12px; color: var(--muted); margin-top: 16px; }
.src em { font-style: italic; }

/* numbers — tight, no divider lines */
.row { display: flex; justify-content: space-between; align-items: baseline; gap: 10px; font-size: 13.5px; padding: 2px 0; }
.row b { color: var(--navy); }

/* country wall: kenara yapışmasın, biraz yukarı */
#countries {
  display: flex;
  flex-wrap: wrap;
  gap: 2px 14px;
  align-items: baseline;
  padding: 8px 40px 30px;
}
.country { color: var(--muted); transition: color 0.15s; }
.country:hover { color: var(--ink); }
.country.on { color: var(--navy); font-weight: 700; }

/* künye: en altta, sola yakın ama uçta değil */
footer {
  padding: 10px 40px 26px;
  color: var(--muted);
  font-size: 11.5px;
  text-align: left;
}
.foot-nav { display: block; margin-bottom: 4px; }
.foot-nav a { color: var(--muted); }
.foot-nav a:hover { color: var(--navy); text-decoration: none; }
.sig { color: var(--royal); }

/* newsletter signup in the footer */
.subscribe { display: inline-flex; align-items: baseline; gap: 8px; margin-bottom: 4px; }
.sub-label { color: var(--muted); font-size: 11.5px; }
.subscribe input { border: 1px solid var(--rule); padding: 3px 8px; font: inherit; font-size: 12px; outline: none; width: 160px; }
.subscribe input:focus { border-color: var(--navy); }
.subscribe button { border: none; background: var(--navy); color: #fff; padding: 3px 12px; font: inherit; font-size: 12px; cursor: pointer; }
.subscribe button:hover { background: var(--royal); }
#sub-msg { color: var(--muted); font-size: 11.5px; }
.foot-src { display: block; }

/* ── above data: editorial lead / bu haftanın bağı (küre convention: serif başlık+yazı) ── */
.lead { padding: 6px 32px 16px; }
.kick { font-size: 11px; font-weight: 700; letter-spacing: 0.12em; text-transform: uppercase; color: var(--navy); margin-bottom: 8px; }
.lead-h { font-family: var(--serif); font-size: 30px; line-height: 1.08; letter-spacing: -0.015em; margin-bottom: 10px; }
.lead-h a { color: var(--ink); }
.lead-h a:hover { color: var(--navy); text-decoration: none; }
.lead-body { font-family: var(--serif); font-size: 15px; line-height: 1.55; color: #37414d; max-width: 74ch; }

/* ── below data: bülten, centred ── */
.below { padding: 26px 32px 10px; text-align: center; max-width: 620px; margin: 0 auto; }
.below .lbl { text-align: center; }
.below .btext { max-width: none; margin: 0 auto 14px; }
.below .subscribe { justify-content: center; }
.below-grid { display: grid; grid-template-columns: 1fr 1.6fr; gap: 48px; align-items: start; }
.lbl { font-size: 11px; font-weight: 700; letter-spacing: 0.1em; text-transform: uppercase; color: var(--muted); margin-bottom: 10px; }
.toc { list-style: none; }
.toc li a { display: flex; align-items: baseline; gap: 12px; padding: 5px 0; font-size: 16px; color: var(--ink); }
.toc li a:hover { color: var(--navy); text-decoration: none; }
.toc .no { font-size: 11px; color: var(--faint); font-variant-numeric: tabular-nums; min-width: 18px; }
.cwall { display: flex; flex-wrap: wrap; gap: 4px 16px; align-items: baseline; }
.cwall a { font-size: 17px; color: var(--ink); }
.cwall a:hover { color: var(--navy); text-decoration: none; }
.cwall-all { margin-top: 12px; font-size: 13.5px; }
.bhead { font-family: var(--serif); font-size: 24px; letter-spacing: -0.01em; margin-bottom: 8px; }
.btext { font-size: 14px; color: #4b5563; max-width: 62ch; margin-bottom: 14px; line-height: 1.55; }
.bfine { font-size: 12.5px; color: var(--muted); margin-top: 10px; }
.foot-nav { display: block; margin-bottom: 5px; }
.foot-nav a { color: var(--muted); }
.foot-nav a:hover { color: var(--navy); text-decoration: none; }

@media (max-width: 1040px) {
  .masthead { flex-direction: column; gap: 10px; }
  .intro { max-width: none; }
  .stage { min-height: 60vh; height: 66vh; }
  .below-grid { grid-template-columns: 1fr; gap: 28px; }
  .card { transform: none !important; }
}

/* ── MOBİL: 3-kolon küre sahnesini dikey istifle, tam-sayfa kilidini bırak,
   içeriği her zaman göster (uzun sayfada observer'a bel bağlama) ── */
@media (max-width: 820px) {
  html { scroll-snap-type: none; }
  .page {
    height: auto; min-height: 0; max-width: 100%;
    overflow: visible; scroll-snap-align: none;
  }
  .page.ed, .page.jn { min-height: 100vh; }

  /* mobilde içerik daima görünür — IntersectionObserver'a bağlı kalma */
  .ed-in, .jn-in, .gl #layers, .gl .stage, .gl #countries { opacity: 1 !important; transform: none !important; }

  .ed-in, .jn-in { padding: 0 20px; }
  .mast h1 { font-size: 28px; }
  .digest { column-count: 2; column-gap: 24px; margin-top: 18px; }
  .ed-scroll { margin-top: 20px; }

  /* küre sayfası: hikâye → küre → başlıklar → ülkeler (akış, üst üste değil) */
  .page.gl { padding-bottom: 24px; }
  #layers { padding: 18px 20px 10px; gap: 8px 16px; }
  .layerbtn { font-size: 15px; }
  .page.gl .stage, .stage {
    position: relative; display: block;
    height: auto; min-height: 0; flex: none;
  }
  .col {
    position: static; width: auto; overflow: visible;
    padding: 14px 20px; z-index: auto;
  }
  #globe {
    position: relative; inset: auto;
    width: 100%; height: 58vh; min-height: 320px;
  }
  /* başlıklar: küre kavisi yerine kürenin altında düz liste olarak aksın */
  #cards {
    position: static; inset: auto; opacity: 1;
    pointer-events: auto; padding: 4px 20px 10px;
  }
  .card {
    position: static !important; width: auto;
    transform: none !important; translate: 0 !important;
    text-shadow: none; animation: none; opacity: 1;
    margin-bottom: 12px;
  }
  .card-title { font-size: 15px; }

  #countries { padding: 10px 20px 22px; gap: 3px 14px; }
  .stats { gap: 16px 30px; padding: 6px 20px 40px; }
  .statn { font-size: 26px; }
  .jn-in .subscribe { flex-wrap: wrap; }
  .subscribe input { width: 100%; max-width: 240px; }
  footer { padding: 10px 20px 26px; }
}

@media (max-width: 560px) {
  .mast h1 { font-size: 24px; }
  .digest { column-count: 1; }
  #globe { height: 52vh; min-height: 300px; }
  .col h2 { font-size: 20px; }
  .stats { gap: 12px 24px; }
  .statn { font-size: 22px; }
}

/* çıkış partı: hesap aç çağrısı */
.jn-cta { font-family: var(--serif); font-size: 20px; color: var(--navy); border-bottom: 1px solid var(--navy); padding-bottom: 2px; }
.jn-cta:hover { color: var(--royal); border-color: var(--royal); }
