/* =========================================================================
   KARATAHTA 21 — bölüm bölüm yeniden kurulmuş tasarım katmanı
   Dünya: pit'in arkasındaki ders tahtası. Gerçek arduvaz, meşe çerçeve,
   tebeşir tozu, tebeşir oluğu — üstünde gerçek kart ve jeton rengi.
   Ritim: ARDUVAZ (ders) ↔ ÇUHA (masa) bandı.
   ========================================================================= */

:root {
  --slate-1: #1E2724;
  --slate-2: #141B19;
  --slate-3: #0C110F;
  --oak-1: #8A5A2B;
  --oak-2: #5E3A17;
  --oak-3: #3A2209;
  --chalk: #F1F3EC;
  --felt-g: #11463A;
  --felt-g2: #0A2E26;
  --am: #E2A13B;
  --am-hi: #FFD489;

  /* arduvaz dokusu: ince tane + tebeşir tozu */
  --slate-tex: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='180' height='180'><filter id='s'><feTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='3'/><feColorMatrix values='0 0 0 0 1 0 0 0 0 1 0 0 0 0 1 0 0 0 0.07 0'/></filter><rect width='180' height='180' filter='url(%23s)'/></svg>");
  --chalk-smudge: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='520' height='520'><filter id='b'><feTurbulence type='fractalNoise' baseFrequency='0.012' numOctaves='3'/><feColorMatrix values='0 0 0 0 1 0 0 0 0 1 0 0 0 0 1 0 0 0 0.055 -0.02'/></filter><rect width='520' height='520' filter='url(%23b)'/></svg>");
  /* meşe çerçeve */
  --oak: linear-gradient(180deg, #A4703A 0%, var(--oak-1) 22%, var(--oak-2) 62%, var(--oak-3) 100%);
}

/* ============================================================ ARDUVAZ */
body {
  background-color: var(--slate-3);
  background-image:
    radial-gradient(90% 55% at 50% 0%, rgba(241,243,236,.07), transparent 62%),
    var(--chalk-smudge),
    var(--slate-tex),
    linear-gradient(180deg, var(--slate-1), var(--slate-2) 60%, var(--slate-3));
  background-size: auto, 520px 520px, 180px 180px, auto;
  background-attachment: fixed;
}

/* ====================================================== BÖLÜM RİTMİ */
main > section { position: relative; isolation: isolate; }

/* — ARDUVAZ bölümü: tebeşirle çizilmiş çerçeve + üstte meşe çıta */
main > section:not(.hero) {
  background: transparent;
  border-block: 0;
}
main > section:not(.hero)::before {
  content: "";
  position: absolute;
  top: 0; left: 0; right: 0;
  height: 13px;
  background: var(--oak);
  box-shadow: inset 0 1px 0 rgba(255,220,170,.5), inset 0 -2px 3px rgba(0,0,0,.6),
              0 6px 16px -8px rgba(0,0,0,.9);
  z-index: 2;
}
/* — ÇUHA bandı: dersin uygulandığı masa */
.sec-band {
  background-color: var(--felt-g2) !important;
  background-image:
    radial-gradient(70% 50% at 50% 0%, rgba(226,161,59,.14), transparent 65%),
    var(--slate-tex),
    linear-gradient(180deg, var(--felt-g), var(--felt-g2) 65%, #061D18) !important;
  background-size: auto, 180px 180px, auto;
  box-shadow: inset 0 0 140px -40px rgba(0,0,0,.95);
}

/* tebeşirle çizilmiş bölüm kutusu */
main > section:not(.hero) > .container {
  position: relative;
  padding-top: clamp(40px, 5vw, 64px);
}
main > section:not(.hero) > .container::before {
  content: "";
  position: absolute;
  inset: 16px 10px;
  border: 2px solid rgba(241,243,236,.22);
  border-radius: 12px;
  pointer-events: none;
  z-index: 0;
  box-shadow:
    inset 0 0 0 4px rgba(241,243,236,.05),
    0 0 0 1px rgba(241,243,236,.07);
}
main > section:not(.hero) > .container > .chalk-x { display: none; }
main > section:not(.hero) > .container > * { position: relative; z-index: 1; }

/* ders numarası — tebeşirle köşeye yazılmış */
main { counter-reset: ders; }
main > section:not(.hero) { counter-increment: ders; }
main > section:not(.hero) > .container::after {
  content: "DERS " counter(ders, decimal-leading-zero);
  position: absolute;
  top: 24px; right: clamp(18px, 4vw, 36px);
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: .3em;
  color: rgba(241,243,236,.4);
  z-index: 1;
}

/* ====================================================== BAŞLIKLAR */
.eyebrow {
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: .26em;
  text-transform: uppercase;
  color: #19120A;
  background: linear-gradient(180deg, var(--am-hi), var(--am) 50%, #9A6410);
  padding: 5px 12px;
  border-radius: 2px;
  display: inline-block;
  box-shadow: inset 0 1px 0 rgba(255,255,255,.55), 0 5px 14px -7px rgba(0,0,0,.9);
}
.eyebrow::before { content: none; }
.sec-head h2, .hero h1 {
  font-family: var(--font-display);
  text-transform: uppercase;
  letter-spacing: .005em;
  line-height: .96;
  color: #FBFDF6;
  text-shadow: 0 2px 0 rgba(0,0,0,.65), 0 0 36px rgba(241,243,236,.16);
}
.sec-head h2 { font-size: clamp(2.2rem, 5.2vw, 3.7rem); margin-top: 14px; }
.sec-head h2::after {
  content: "";
  display: block;
  width: 190px; height: 7px;
  margin-top: 16px;
  background: repeating-linear-gradient(90deg, rgba(241,243,236,.85) 0 26px, transparent 26px 34px);
  mask-image: linear-gradient(90deg, #000, transparent);
  -webkit-mask-image: linear-gradient(90deg, #000, transparent);
  opacity: .6;
}

/* ====================================================== HERO */
.hero {
  background:
    radial-gradient(60% 50% at 24% 30%, rgba(241,243,236,.12), transparent 66%),
    radial-gradient(70% 60% at 82% 70%, rgba(226,161,59,.18), transparent 66%),
    linear-gradient(180deg, #202A27, #101614 70%, #0A0F0D);
  border-bottom: 0;
}
.hero::before {
  content: "";
  position: absolute;
  inset: 0;
  background-image: var(--chalk-smudge);
  background-size: 520px 520px;
  opacity: .8;
  pointer-events: none;
}
/* tebeşir oluğu — hero'nun altında meşe raf, üstünde tebeşir çubukları */
.hero::after {
  content: "";
  position: absolute !important;
  left: 0; right: 0; bottom: 0; top: auto !important;
  height: 22px;
  background: var(--oak);
  box-shadow: inset 0 2px 0 rgba(255,222,176,.55), inset 0 -3px 6px rgba(0,0,0,.7),
              0 -2px 10px rgba(0,0,0,.5);
  opacity: 1 !important;
  z-index: 3;
}
.hero h1 { font-size: clamp(2.8rem, 7.4vw, 5rem); }
.hero h1 .accent { color: var(--am-hi); text-shadow: 0 0 26px rgba(255,212,137,.6); }

/* ====================================================== KARTLAR / PANO */
.card,
.note,
.answer {
  background: linear-gradient(180deg, rgba(241,243,236,.07), rgba(0,0,0,.26));
  border: 1px solid rgba(241,243,236,.18);
  border-radius: 8px;
  box-shadow: inset 0 1px 0 rgba(241,243,236,.14), 0 24px 48px -34px #000;
}
.card .k {
  font-family: var(--font-display);
  color: #19120A;
  background: linear-gradient(180deg, var(--am-hi), var(--am) 55%, #9A6410);
  padding: 2px 10px;
  border-radius: 2px;
  display: inline-block;
  box-shadow: inset 0 1px 0 rgba(255,255,255,.5);
}
.card:hover { border-color: rgba(226,161,59,.55); }

/* adım şeridi */
.step {
  background: linear-gradient(180deg, rgba(241,243,236,.05), transparent 40%);
  border: 1px solid rgba(241,243,236,.14);
  border-radius: 8px;
  padding: 20px;
}
.step .st-num, .st-num {
  font-family: var(--font-display);
  color: #061A16;
  background: radial-gradient(circle at 35% 28%, #CFF0E6, #6FA8A0 55%, #255B52);
  width: 42px; height: 42px;
  border-radius: 50%;
  display: grid; place-items: center;
  box-shadow: inset 0 -3px 6px rgba(0,0,0,.4), 0 6px 14px -8px rgba(0,0,0,.9);
}
.st-time { font-family: var(--font-mono); color: var(--am-hi); }

/* karar tablosu — tahtaya çizilmiş ızgara */
.table-scroll {
  border: 2px solid rgba(241,243,236,.3);
  border-radius: 6px;
  background: rgba(8,14,12,.5);
  box-shadow: inset 0 0 0 1px rgba(0,0,0,.6), 0 26px 52px -36px #000;
}
.table-scroll > table thead th {
  background: linear-gradient(180deg, rgba(241,243,236,.16), rgba(241,243,236,.05));
  color: #FBFDF6;
  font-family: var(--font-display);
  text-transform: uppercase;
  letter-spacing: .1em;
}

/* antrenör düğmeleri */
.tr-act {
  border-radius: 6px;
  border: 2px solid rgba(241,243,236,.3);
  background: linear-gradient(180deg, rgba(241,243,236,.08), rgba(0,0,0,.3));
  font-family: var(--font-display);
  text-transform: uppercase;
  letter-spacing: .06em;
  box-shadow: inset 0 1px 0 rgba(241,243,236,.16);
}
.tr-act:hover:not(:disabled) { border-color: var(--am); background: linear-gradient(180deg, rgba(226,161,59,.2), rgba(0,0,0,.3)); }

/* ====================================================== DÜĞMELER */
.btn { border-radius: 4px; font-family: var(--font-display); text-transform: uppercase; letter-spacing: .05em; }
.btn-primary, .btn.primary {
  background: linear-gradient(180deg, var(--am-hi), var(--am) 48%, #96620F);
  color: #190F02;
  border: 1px solid #6E4708;
  box-shadow: inset 0 1px 0 rgba(255,255,255,.6), 0 12px 26px -14px rgba(226,161,59,.9);
}
.btn-ghost, .btn.ghost {
  background: rgba(241,243,236,.08);
  border: 2px solid rgba(241,243,236,.34);
  color: #EDEFEA;
}

/* ====================================================== ÜST / ALT */
.site-header,
.site-header.is-scrolled {
  background: linear-gradient(180deg, rgba(11,16,14,.97), rgba(11,16,14,.9));
  border-bottom: 0;
  box-shadow: inset 0 -5px 0 var(--oak-3), inset 0 -9px 0 var(--oak-2), inset 0 -12px 0 var(--oak-1),
              0 10px 28px -22px #000;
}
.brand .brand-mark {
  width: 36px; height: 36px;
  border-radius: 0 !important;
  background: url("../images/mark.svg") center/contain no-repeat !important;
  border: 0 !important;
  box-shadow: none;
}
.brand .brand-mark::before, .brand .brand-mark::after { content: none; }

.site-footer {
  position: relative;
  background: linear-gradient(180deg, #0C110F, #070A09);
}
.site-footer::before {
  content: "";
  position: absolute;
  left: 0; right: 0; top: 0;
  height: 13px;
  background: var(--oak);
  box-shadow: inset 0 1px 0 rgba(255,220,170,.5);
}
.site-footer > .container { padding-top: 34px; }

@media (max-width: 760px) {
  main > section:not(.hero) > .container::before { inset: 12px 0; }
  main > section:not(.hero) > .container::after { display: none; }
}
