/* ============================================================
   APEX — Özel CMS teması · F1Racing.com.tr
   Karbon siyahı + yarış kırmızısı motorsport kimliği. Çapraz hız
   çizgileri, kayan (marquee) bant, damalı bayrak dokusu, podyum
   temalı bölüm, yüklemede canlanan hero.

   Yükleme sırası: main.css → bu dosya (theme.php → theme_headAssets)
   1) main.css :root token'larını yarış paletiyle YENİDEN TANIMLAR
      → header, footer, blog, .cat-card, SSS akordeonu vb. otomatik döner
   2) main.css'te değişken DEĞİL, hardcode turuncu rgba(232,66,10,…) /
      koyu lacivert #1e293b / #111827 noktalarını aynı seçicilerle üzerine yazar
   3) Blog / yazı / sayfa başlığı bileşenlerini yarış kimliğine çeker
   4) Ana sayfa "apx-" bileşenleri (homepage-content.html içinde)
   ============================================================ */

/* ── 1) SİTE GENELİ TOKEN OVERRIDE ─────────────────────────── */
:root{
  --clr-primary:     #E10600;   /* yarış kırmızısı (eski: turuncu #E8420A) */
  --clr-primary-dk:  #A80500;
  --clr-primary-lt:  #FF7A6B;   /* koyu zeminde metin/ikon için (WCAG AA) */

  --clr-dark:    #0a0a0d;       /* karbon siyahı */
  --clr-dark-2:  #16161b;
  --clr-dark-3:  #2a2a32;
  --clr-gray:    #68686f;
  --clr-light:   #f3f3f5;
  --clr-white:   #ffffff;
  --clr-border:  #e4e4e8;

  --ff-display: 'Racing Sans One', 'Titillium Web', sans-serif;
  --ff-body:    'Titillium Web', -apple-system, 'Segoe UI', sans-serif;

  --shadow-sm:  0 1px 3px rgba(0,0,0,.10), 0 1px 2px rgba(0,0,0,.08);
  --shadow-md:  0 8px 24px rgba(0,0,0,.16);
  --shadow-lg:  0 24px 64px rgba(0,0,0,.28);

  --radius-sm:  3px;
  --radius-md:  6px;
  --radius-lg:  10px;

  /* Apex'e özel yardımcı renkler */
  --apx-accent:      #F5C400;   /* veri/uyarı sarısı — sektör vurgusu */
  --apx-accent2:     #8E5CF6;   /* en hızlı tur moru — nadiren, hover glint */
  --apx-glow:         0 0 0 1px rgba(225,6,0,.4), 0 0 40px -6px rgba(225,6,0,.55);
  --apx-gutter: clamp(20px, 6vw, 100px);
  --apx-cut: 14px; /* kırpık köşe (clip-path) ölçüsü */
}

body{
  background: var(--clr-white);
  color: var(--clr-dark);
  font-family: var(--ff-body);
  -webkit-font-smoothing: antialiased;
}

/* Racing Sans One — büyük başlıklarda main.css'in Bebas ayarlarının üstüne */
.hero h1, .section__title, .card__title, .cat-card__name, .logo,
.page-hero h1, .post-title{
  font-family: var(--ff-display);
  letter-spacing: .01em;
  text-transform: none;
  font-weight: 400;
  line-height: 1.02;
}

@media (prefers-reduced-motion: reduce){
  *,*::before,*::after{ animation-duration: .001ms !important; animation-iteration-count: 1 !important; transition-duration: .001ms !important; }
}

/* ============================================================
   2) main.css TURUNCU HARDCODE OVERRIDE  (RGB 232,66,10 → 225,6,0)
   ============================================================ */
.nav__link:hover,
.nav__link.active            { background: rgba(225,6,0,.08); }
.dropdown__item:hover        { background: rgba(225,6,0,.08); color: var(--clr-primary); }
.nav-toggle                  { box-shadow: 0 2px 8px rgba(225,6,0,.35); }
.nav-toggle:hover            { box-shadow: 0 4px 14px rgba(225,6,0,.5); }
.btn--primary:hover          { box-shadow: 0 4px 15px rgba(225,6,0,.35); }
.hero__badge{
  background: rgba(225,6,0,.15);
  border: 1px solid rgba(225,6,0,.3);
}
.form-control:focus,
.form-control:focus-visible  { box-shadow: 0 0 0 3px rgba(225,6,0,.1); }
.mega-menu__cat-item:hover,
.mega-menu__link:hover,
.mega-menu__post:hover       { background: rgba(225,6,0,.07); color: var(--clr-primary); }
.mega-menu__count            { background: rgba(225,6,0,.1); }

@media (max-width: 1024px){
  .header{ background: var(--clr-dark) !important; }
  .nav__link:hover,
  .nav__link.active { background: linear-gradient(90deg, rgba(225,6,0,.25) 0%, rgba(225,6,0,.05) 100%) !important; }
  .dropdown         { border-left-color: rgba(225,6,0,.3); }
  .dropdown__item:hover { background: rgba(225,6,0,.12) !important; }
  .mega-menu        { border-left: 3px solid rgba(225,6,0,.3) !important; }
  .mega-menu__cat-item:hover,
  .mega-menu__link:hover,
  .mega-menu__post:hover { background: rgba(225,6,0,.12) !important; }
  .mega-menu__all-link  { border-color: rgba(225,6,0,.5) !important; }
}

/* Sayfa üstü banner (Blog, Kategoriler…): #1e293b hardcode → karbon gradyanı */
.page-hero,
.cat-hero,
.section--dark,
.sidebar-widget--cta{
  background: linear-gradient(135deg, var(--clr-dark) 0%, #1a1a20 100%);
  position: relative;
  overflow: hidden;
}
.page-hero::after, .cat-hero::after{
  content:"";
  position:absolute; inset:auto -10% -60% auto; width:70%; aspect-ratio:1;
  background: radial-gradient(closest-side, rgba(225,6,0,.28), transparent 70%);
  pointer-events:none;
}
.page-hero h1, .cat-hero h1{ color: var(--clr-white); position:relative; }
.page-hero p,  .cat-hero p { color: rgba(255,255,255,.72); position:relative; }

.btn--primary{ background: var(--clr-primary); border-radius: var(--radius-sm); }
.btn--primary:hover{ background: var(--clr-primary-dk); }

/* Koyu zemin kontrast düzeltmeleri */
.header__mobile-tagline        { color: var(--clr-primary-lt); }
.footer .btn--outline          { color: var(--clr-primary-lt); border-color: var(--clr-primary-lt); }
.footer .btn--outline:hover    { background: var(--clr-primary-lt); color: var(--clr-dark); }
.footer__links a::before,
.footer__links a:hover,
.footer__contact-list i,
.footer__contact-list a:hover  { color: var(--clr-primary-lt); }
#cookieConsent .cc-desc a      { color: var(--clr-primary-lt); }

/* ============================================================
   3) EDİTORYAL — paylaşılan blog / yazı / sayfa bileşenleri
   ============================================================ */
.section{ padding: clamp(56px, 9vw, 108px) 0; }
.section--gray{ background: var(--clr-light); }

.card, .cat-card{
  border-radius: var(--radius-md);
  border-top: 3px solid var(--clr-primary);
  transition: transform .25s cubic-bezier(.2,.8,.2,1), box-shadow .25s ease;
}
.card:hover, .cat-card:hover{ transform: translateY(-4px); box-shadow: var(--shadow-lg); }
.card__img{ border-radius: 0; overflow:hidden; }
.card__img img{ transition: transform .5s cubic-bezier(.2,.8,.2,1); }
.card:hover .card__img img{ transform: scale(1.06); }
.card__cat{
  font-family: var(--ff-body); font-weight: 700; font-size: .68rem;
  letter-spacing: .12em; text-transform: uppercase; color: var(--clr-primary);
}

.post-title{ font-size: clamp(2.1rem, 5vw, 3.6rem); line-height: 1.02; }
.post-content{ font-size: 1.05rem; line-height: 1.75; }
.post-content h2{ border-left: 4px solid var(--clr-primary); padding-left: 14px; }
.post-content a{ color: var(--clr-primary-dk); text-decoration: underline; text-underline-offset: 3px; }
.post-content blockquote{
  border-left: 3px solid var(--apx-accent); background: var(--clr-light);
  font-style: italic; padding: 14px 20px; margin: 1.6em 0;
}

/* ============================================================
   4) ANA SAYFA — "apx-" bileşenleri  (homepage-content.html)
   ============================================================ */
.apx-root{ font-family: var(--ff-body); line-height: 1.6; color: var(--clr-dark); overflow-x: clip; background: var(--clr-white); }
.apx-root *, .apx-root *::before, .apx-root *::after{ box-sizing: border-box; }
.apx-root img, .apx-root svg{ max-width: 100%; display: block; }
.apx-root a{ color: inherit; text-decoration: none; }
.apx-root p{ margin: 0; }
.apx-root h1, .apx-root h2, .apx-root h3{
  font-family: var(--ff-display); font-weight: 400; margin: 0; line-height: 1.02;
}
.apx-i{ width: 1em; height: 1em; stroke: currentColor; fill: none; stroke-width: 1.6; stroke-linecap: round; stroke-linejoin: round; flex: 0 0 auto; }
.apx-vh{ position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

/* damalı bayrak dokusu — küçük tekrarlayan satranç deseni */
.apx-checker{
  background-image:
    linear-gradient(45deg, #000 25%, transparent 25%, transparent 75%, #000 75%, #000),
    linear-gradient(45deg, #000 25%, transparent 25%, transparent 75%, #000 75%, #000);
  background-size: 14px 14px;
  background-position: 0 0, 7px 7px;
  background-color: #fff;
}

.apx-band{ padding: 0 var(--apx-gutter); }

.apx-eyebrow{
  display: inline-flex; align-items: center; gap: 10px;
  font-weight: 700; font-size: .72rem; letter-spacing: .18em; text-transform: uppercase;
  color: var(--clr-primary);
}
.apx-dot{
  width: 8px; height: 8px; border-radius: 50%; background: var(--clr-primary);
  box-shadow: 0 0 0 0 rgba(225,6,0,.6);
  animation: apx-pulse 1.6s ease-out infinite;
}
@keyframes apx-pulse{
  0%   { box-shadow: 0 0 0 0 rgba(225,6,0,.55); }
  70%  { box-shadow: 0 0 0 9px rgba(225,6,0,0); }
  100% { box-shadow: 0 0 0 0 rgba(225,6,0,0); }
}

.apx-btn{
  display: inline-flex; align-items: center; gap: 10px;
  padding: 15px 28px; font-weight: 700; font-size: .92rem;
  clip-path: polygon(var(--apx-cut) 0, 100% 0, 100% calc(100% - var(--apx-cut)), calc(100% - var(--apx-cut)) 100%, 0 100%, 0 var(--apx-cut));
  cursor: pointer; transition: transform .18s ease, box-shadow .18s ease, background .18s ease, color .18s ease;
  position: relative; overflow: hidden;
}
.apx-btn .apx-i{ width: 16px; height: 16px; }
.apx-btn.apx-btn--solid{ background: var(--clr-primary); color: var(--clr-white); }
.apx-btn.apx-btn--solid:hover{ background: var(--clr-primary-dk); transform: translateY(-2px); box-shadow: var(--apx-glow); }
.apx-btn.apx-btn--line{ background: transparent; color: var(--clr-white); box-shadow: inset 0 0 0 1.5px rgba(255,255,255,.5); }
.apx-btn.apx-btn--line:hover{ box-shadow: inset 0 0 0 1.5px #fff; background: rgba(255,255,255,.08); }
.apx-btn.apx-btn--dark{ background: var(--clr-dark); color: var(--clr-white); }
.apx-btn.apx-btn--dark:hover{ background: var(--clr-primary); transform: translateY(-2px); }

/* ---------- HERO ---------- */
.apx-hero{
  position: relative; min-height: 92vh; display: flex; align-items: center;
  background: radial-gradient(120% 90% at 100% 0%, #2a0a08 0%, var(--clr-dark) 55%);
  color: var(--clr-white); overflow: hidden;
  padding: clamp(120px, 16vh, 180px) var(--apx-gutter) clamp(64px, 9vh, 110px);
}
.apx-hero::before{
  /* çapraz hız çizgileri — sürekli kayan */
  content:""; position:absolute; inset: -20% -50%;
  background: repeating-linear-gradient(
    115deg, rgba(225,6,0,.16) 0 3px, transparent 3px 90px
  );
  animation: apx-speed 5.5s linear infinite;
  pointer-events: none;
}
@keyframes apx-speed{ from{ transform: translateX(0); } to{ transform: translateX(90px); } }
.apx-hero::after{
  content:""; position:absolute; right: -8%; bottom: -18%; width: min(60vw, 720px); aspect-ratio: 1;
  background: radial-gradient(closest-side, rgba(225,6,0,.35), transparent 72%);
  filter: blur(4px); animation: apx-glow-pulse 4s ease-in-out infinite;
  pointer-events: none;
}
@keyframes apx-glow-pulse{ 0%,100%{ opacity:.75; } 50%{ opacity:1; } }

.apx-hero__inner{ position: relative; z-index: 2; max-width: 900px; }
.apx-hero__ghost{
  position: absolute; z-index: 1; right: clamp(-40px,4vw,40px); top: 50%; transform: translateY(-50%);
  font-family: var(--ff-display); font-size: clamp(9rem, 24vw, 22rem); line-height: 1;
  color: transparent; -webkit-text-stroke: 1.5px rgba(255,255,255,.09);
  user-select: none; pointer-events: none;
  animation: apx-float 6s ease-in-out infinite;
}
@keyframes apx-float{ 0%,100%{ transform: translateY(-50%); } 50%{ transform: translateY(calc(-50% - 14px)); } }

.apx-hero h1{
  font-size: clamp(2.8rem, 7.5vw, 6.2rem); margin: 18px 0 20px; max-width: 14ch;
  opacity: 0; animation: apx-in .7s .15s cubic-bezier(.2,.8,.2,1) forwards;
}
.apx-hero h1 em{ font-style: normal; color: var(--clr-primary); }
.apx-hero__lead{
  font-size: clamp(1.05rem, 2vw, 1.35rem); color: rgba(255,255,255,.78); max-width: 52ch; margin-bottom: 34px;
  opacity: 0; animation: apx-in .7s .3s cubic-bezier(.2,.8,.2,1) forwards;
}
.apx-hero__actions{
  display: flex; gap: 14px; flex-wrap: wrap; margin-bottom: 48px;
  opacity: 0; animation: apx-in .7s .45s cubic-bezier(.2,.8,.2,1) forwards;
}
.apx-hero__facts{
  display: flex; gap: clamp(24px, 4vw, 56px); flex-wrap: wrap;
  padding-top: 28px; border-top: 1px solid rgba(255,255,255,.16);
  opacity: 0; animation: apx-in .7s .6s cubic-bezier(.2,.8,.2,1) forwards;
}
.apx-fact strong{ display:block; font-family: var(--ff-display); font-size: clamp(1.6rem, 3vw, 2.3rem); color: var(--clr-white); }
.apx-fact span{ font-size: .74rem; letter-spacing: .1em; text-transform: uppercase; color: rgba(255,255,255,.55); }
@keyframes apx-in{ from{ opacity:0; transform: translateY(16px); } to{ opacity:1; transform: translateY(0); } }

.apx-hero__flag{
  position: absolute; left: 0; right: 0; bottom: 0; height: 8px;
  transform: skewX(-24deg) translateX(-4%);
}

/* ---------- MARQUEE — kayan bant ---------- */
.apx-marquee{
  background: var(--clr-dark); color: var(--clr-white); overflow: hidden;
  border-top: 1px solid rgba(255,255,255,.08); border-bottom: 3px solid var(--clr-primary);
  padding: 16px 0;
}
.apx-marquee__track{
  display: flex; width: max-content; gap: 0;
  animation: apx-marquee 26s linear infinite;
}
.apx-marquee:hover .apx-marquee__track{ animation-play-state: paused; }
.apx-marquee__item{
  display: flex; align-items: center; gap: 12px;
  padding: 0 28px; font-weight: 700; font-size: .95rem; letter-spacing: .04em;
  white-space: nowrap;
}
.apx-marquee__item .apx-i{ width: 16px; height: 16px; color: var(--clr-primary); }
@keyframes apx-marquee{ from{ transform: translateX(0); } to{ transform: translateX(-50%); } }

/* ---------- BÖLÜM KABUĞU ---------- */
.apx-sec{ padding-top: clamp(64px, 10vw, 128px); padding-bottom: clamp(64px, 10vw, 128px); }
.apx-sec--dark{ background: var(--clr-dark); color: var(--clr-white); }
.apx-sec__head{
  display: flex; justify-content: space-between; align-items: flex-end; flex-wrap: wrap;
  gap: 20px; margin-bottom: clamp(32px, 5vw, 56px);
}
.apx-sec__head h2{ font-size: clamp(1.9rem, 4.6vw, 3.2rem); margin-top: 10px; max-width: 16ch; }
.apx-sec__head p{ color: var(--clr-gray); max-width: 42ch; }
.apx-sec--dark .apx-sec__head p{ color: rgba(255,255,255,.6); }

/* ---------- KATEGORİLER / SON YAZILAR wrapper ---------- */
.apx-categories .cat-card,
.apx-latest .card{ height: 100%; }

/* ---------- MANİFESTO ---------- */
.apx-manifesto{
  position: relative; overflow: hidden;
  background: var(--clr-dark); color: var(--clr-white);
  padding: clamp(72px, 12vw, 150px) var(--apx-gutter);
  text-align: center;
}
.apx-manifesto::before{
  content:""; position:absolute; inset:0;
  background: repeating-linear-gradient(115deg, rgba(225,6,0,.10) 0 2px, transparent 2px 70px);
}
.apx-manifesto p{
  position: relative; font-family: var(--ff-display); font-weight: 400;
  font-size: clamp(1.7rem, 4.4vw, 3.2rem); line-height: 1.18; max-width: 22ch; margin: 0 auto;
}
.apx-manifesto p em{ font-style: normal; color: var(--clr-primary); }
.apx-manifesto__by{
  position: relative; display: block; margin-top: 28px;
  font-family: var(--ff-body); font-weight: 700; font-size: .78rem; letter-spacing: .18em;
  text-transform: uppercase; color: rgba(255,255,255,.5);
}

/* ---------- PODYUM — P1/P2/P3 ---------- */
.apx-podium{
  display: grid; grid-template-columns: repeat(3, 1fr); gap: clamp(14px, 2.4vw, 26px);
  align-items: end;
}
.apx-p{
  background: var(--clr-light); border-radius: var(--radius-md) var(--radius-md) 0 0;
  padding: 30px 22px; text-align: center; position: relative;
  border-top: 4px solid var(--clr-primary);
  transition: transform .25s ease, box-shadow .25s ease;
}
.apx-p:hover{ transform: translateY(-6px); box-shadow: var(--shadow-lg); }
.apx-p__rank{
  display:inline-flex; align-items:center; justify-content:center;
  width: 46px; height: 46px; border-radius: 50%;
  background: var(--clr-dark); color: var(--clr-white);
  font-family: var(--ff-display); font-size: 1.3rem;
  margin-bottom: 14px;
}
.apx-p h3{ font-size: 1.3rem; margin-bottom: 8px; }
.apx-p p{ color: var(--clr-gray); font-size: .95rem; }
.apx-p--1{ padding-top: 44px; padding-bottom: 46px; order: 2; }
.apx-p--1 .apx-p__rank{ background: var(--clr-primary); width: 56px; height: 56px; font-size: 1.6rem; }
.apx-p--2{ order: 1; padding-bottom: 26px; }
.apx-p--3{ order: 3; padding-bottom: 14px; }
@media (max-width: 760px){
  .apx-podium{ grid-template-columns: 1fr; }
  .apx-p--1, .apx-p--2, .apx-p--3{ order: initial; padding-bottom: 30px; }
}

/* ---------- İSTATİSTİK BANDI ([stat-bant] sarmalayıcı) ---------- */
.apx-stats{ background: var(--clr-dark); color: var(--clr-white); position: relative; overflow: hidden; }
.apx-stats::before{
  content:""; position:absolute; top:0; left:0; right:0; height:6px;
}
.apx-stats .stat-item strong, .apx-stats .stat b{ color: var(--clr-white); }

/* ---------- KAPANIŞ CTA ---------- */
.apx-cta{
  position: relative; overflow: hidden; text-align: center;
  background: linear-gradient(135deg, var(--clr-primary-dk) 0%, var(--clr-primary) 60%, #7a0400 130%);
  color: var(--clr-white); padding: clamp(80px, 14vw, 170px) var(--apx-gutter);
}
.apx-cta::before{
  content:""; position:absolute; inset:-20% -30%;
  background: repeating-linear-gradient(115deg, rgba(255,255,255,.08) 0 2px, transparent 2px 80px);
  animation: apx-speed 6s linear infinite;
}
.apx-cta__inner{ position: relative; max-width: 720px; margin: 0 auto; }
.apx-cta h2{ font-size: clamp(2.2rem, 6vw, 4.2rem); margin-bottom: 16px; }
.apx-cta p{ color: rgba(255,255,255,.85); margin-bottom: 30px; font-size: 1.05rem; }

/* ---------- Duyarlı düzeltmeler ---------- */
@media (max-width: 700px){
  .apx-hero{ min-height: 0; padding-top: clamp(96px, 16vh, 140px); }
  .apx-hero__ghost{ display: none; }
  .apx-sec__head{ align-items: flex-start; }
}
