/* ════════════════════════════════════════════════════════════════
   WORTHAM GÖRÜNÜM KATMANI  v2 (2026-09-23)
   Kırmızı ağırlıklı, yumuşak altın vurgulu, sıcak koyu zemin.
   Yazı: Barlow Condensed (başlık/etiket) + Barlow (gövde) — latin-ext, Türkçe tam.
   Tek dosya; tema layout'larına tek satır <link> ile bağlanır.
   DOSYA ADI SÜRÜMLÜ: Cloudflare ?v= parametresini yok sayıyor; değişiklikte yeni ad (wortham-v3.css) + layout satırını güncelle.
   GERİ ALMA: layouts/{fresh,main,auth,error}.php içindeki
   "WORTHAM-CSS" işaretli satırı silmek yeterli.
   LeaderOS çekirdeğine ve DB ayarlarına dokunmaz.
   ════════════════════════════════════════════════════════════════ */

@import url("https://fonts.googleapis.com/css2?family=Barlow+Condensed:wght@500;600;700&family=Barlow:wght@400;500;600;700&display=swap");

/* ---------- 1. Jetonlar ---------- */
:root {
  --w-red: #D2434A;
  --w-red-hi: #E0575E;
  --w-red-deep: #A8262E;
  --w-red-dark: #6E161C;
  --w-rose: #EE8E92;          /* koyu zeminde okunur bağlantı rengi */
  --w-gold: #E3B55B;          /* ikincil vurgu: sayı, fiyat, küçük etiket */
  --w-gold-deep: #C4923A;
  --w-text: #ECE6E3;
  --w-soft: #BDB0AB;
  --w-muted: #8C807C;

  --acc: var(--w-red);
  --acc-2: var(--w-gold);
  --acc-warm: var(--w-gold);
  --acc-coral: var(--w-rose);
  --acc-ink: #FFFFFF;

  --font-display: "Barlow Condensed", "Arial Narrow", system-ui, sans-serif;
  --font-body: "Barlow", ui-sans-serif, system-ui, -apple-system, "Segoe UI", sans-serif;
  --font-mono: "Barlow Condensed", "Arial Narrow", system-ui, sans-serif;

  --w-btn: linear-gradient(180deg, #DB4B52 0%, #B9333B 100%);
  --w-btn-hi: linear-gradient(180deg, #E55D63 0%, #C63B43 100%);
  --w-ring: rgba(210, 67, 74, .38);
}

/* Açık mod (altbilgideki "Açık" düğmesi) */
body[data-bs-theme="light"] {
  --acc: #B8323A;
  --w-rose: #A8262E;
  --w-gold: #9A6A12;
}

/* Koyu mod zemini: kırmızıya çalan sıcak siyah */
html body[data-bs-theme="dark"] {
  --bg: #120C0C;
  --bg-2: #0B0707;
  --ink: var(--w-text);
  --ink-soft: var(--w-soft);
  --ink-mute: var(--w-muted);
  --surface: #1A1212;
  --surface-2: #241918;
  --line: #3A2A29;
  --line-soft: #2A1F1E;
  --shadow-sm: 0 1px 2px rgba(0, 0, 0, .45);
  --shadow: 0 1px 0 rgba(255, 255, 255, .025) inset, 0 10px 28px -14px rgba(0, 0, 0, .75);
  --shadow-lg: 0 1px 0 rgba(255, 255, 255, .035) inset, 0 30px 60px -30px rgba(0, 0, 0, .9);
  background: var(--bg);
}

/* ---------- 2. Arka plan ---------- */
body[data-bs-theme="dark"] .page-bg {
  background:
    radial-gradient(1000px 560px at 12% -12%, rgba(210, 67, 74, .20) 0%, transparent 62%),
    radial-gradient(760px 480px at 96% 2%, rgba(168, 38, 46, .16) 0%, transparent 58%),
    radial-gradient(900px 600px at 50% 115%, rgba(227, 181, 91, .06) 0%, transparent 65%),
    linear-gradient(180deg, var(--bg) 0%, var(--bg-2) 100%);
}
/* ızgara dokusu kaldırıldı: sade zemin */
body[data-bs-theme="dark"] .page-bg::before,
body[data-bs-theme="dark"] .hero-main::before { opacity: 0 !important; }

/* ---------- 3. Tipografi ---------- */
body { font-family: var(--font-body); font-feature-settings: normal; letter-spacing: .005em; }
.hero h1,
.auth-art-mid h2,
body.t-skin .page-title,
body.t-skin .card-title,
.sg-head h2, .sg-head h1,
.store-banner h1,
.nh-body h2, .nh-body h3,
.card-h h3, .card-h h2,
.mode h4,
.prod-name,
.cat-card h3,
h1.page-title {
  font-family: var(--font-display);
  font-weight: 700;
  letter-spacing: .005em;
}
.hero h1 { font-size: clamp(44px, 5.4vw, 70px); line-height: 1; letter-spacing: 0; }
.hero h1 em,
.auth-art-mid h2 em {
  background: linear-gradient(100deg, #E0575E 0%, #D2434A 45%, #E3A55B 100%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}
body[data-bs-theme="dark"] .hero h1,
body[data-bs-theme="dark"] .auth-art-mid h2 { color: #F4EEEA; }
.hero p.lede { font-size: 17px; line-height: 1.6; }

/* Monospace "AI" etiketleri yerine sıkışık, aralıklı büyük harf */
.metric .lbl, .ru-title, .ip-l small, .auth-ip-l small, .footer h4, .footer h5, .footer h6,
.sc-title, .sg-head .count, .nh-arttag, .ticker-label, .subhead .tag, .preview-meta .badge,
.buy-ago, .lb-score, .prod-cat, .hero-eyebrow, .crumb, .breadcrumb {
  font-family: var(--font-display) !important;
  letter-spacing: .12em;
  font-weight: 600;
}

/* ---------- 4. Logo (DB'deki headerLogo hâlâ LeaderOS yer tutucusu) ----------
   Yalnız yer tutucu dosyayı hedefler; panelden gerçek logo yüklenince bu kural kendiliğinden devre dışı kalır. */
.brand { gap: 10px; }
.brand-mark {
  width: 46px !important;
  height: 46px !important;
  border-radius: 0 !important;
  overflow: visible !important;
  box-shadow: none !important;
  background: none !important;
}
.brand-mark img[src*="/assets/flat/img/header-logo.png"],
.footer img[src*="/assets/flat/img/header-logo.png"] {
  content: url("/assets/fresh/img/wortham-amblem-120.png");
  object-fit: contain !important;
  border-radius: 0 !important;
  filter: drop-shadow(0 4px 10px rgba(0, 0, 0, .55)) drop-shadow(0 0 10px rgba(210, 67, 74, .25));
  transition: transform .25s ease;
}
.brand:hover .brand-mark img { transform: rotate(-6deg) scale(1.06); }
.brand-name {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 24px;
  letter-spacing: .08em;
  text-transform: uppercase;
  line-height: .95;
}
.brand-name::after {
  content: "Towny Sunucusu";
  display: block;
  margin-top: 3px;
  font-size: 10.5px;
  font-weight: 600;
  letter-spacing: .26em;
  color: var(--w-gold);
  opacity: .9;
}
body[data-bs-theme="dark"] .brand-name { color: #F4EEEA; }
.auth-brand img[src*="/assets/flat/img/header-logo.png"],
.auth-logo-sm img[src*="/assets/flat/img/header-logo.png"] {
  content: url("/assets/fresh/img/wortham-amblem-320.png");
  height: 110px;
  max-height: 110px !important;
  width: auto;
  filter: drop-shadow(0 10px 24px rgba(0, 0, 0, .6)) drop-shadow(0 0 24px rgba(210, 67, 74, .3));
}
.auth-logo-sm img[src*="/assets/flat/img/header-logo.png"] { height: 72px; max-height: 72px !important; }

/* ---------- 5. Üst bar ---------- */
body[data-bs-theme="dark"] .topbar {
  background: rgba(22, 15, 15, .82);
  border-color: rgba(255, 255, 255, .06);
  box-shadow: 0 14px 34px -18px rgba(0, 0, 0, .85);
}
.tnav a { font-weight: 500; font-size: 15px; white-space: nowrap; letter-spacing: .01em; }
@media (min-width: 881px) {
  .tnav a { padding: 8px 11px; gap: 6px; }
  .topbar { gap: 14px; }
  .top-auth .btn, .top-actions .btn { white-space: nowrap; }
}
@media (min-width: 881px) and (max-width: 1180px) {
  .tnav a > i:first-child { display: none; }
  .tnav a { padding: 8px 9px; font-size: 14px; }
  .brand-name::after { display: none; }
}
body[data-bs-theme="dark"] .tnav a { color: var(--w-soft); }
body[data-bs-theme="dark"] .tnav a:hover { color: #fff; background: rgba(255, 255, 255, .04); }
body[data-bs-theme="dark"] .tnav a.is-active {
  color: #fff;
  background: rgba(210, 67, 74, .16);
  box-shadow: inset 0 0 0 1px var(--w-ring);
}
.tnav a.w-wiki-link i { color: var(--w-gold); }

/* ---------- 6. Butonlar ---------- */
.btn { font-family: var(--font-body); font-weight: 600; letter-spacing: .01em; }
.btn-acc,
.btn.btn-primary,
body.t-skin .btn-primary {
  background: var(--w-btn) !important;
  color: #fff !important;
  border: 1px solid rgba(0, 0, 0, .2) !important;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, .18), 0 10px 22px -12px rgba(210, 67, 74, .65) !important;
}
.btn-acc:hover,
.btn.btn-primary:hover,
body.t-skin .btn-primary:hover {
  background: var(--w-btn-hi) !important;
  color: #fff !important;
}
body[data-bs-theme="dark"] .btn-secondary,
body[data-bs-theme="dark"] .btn-ghost {
  background: rgba(255, 255, 255, .03);
  border-color: rgba(255, 255, 255, .09);
  color: var(--w-text);
}
body[data-bs-theme="dark"] .btn-secondary:hover,
body[data-bs-theme="dark"] .btn-ghost:hover { border-color: var(--w-ring); color: #fff; background: rgba(210, 67, 74, .08); }
.copy-btn { background: var(--w-btn) !important; color: #fff !important; }

/* ---------- 7. Kartlar / paneller ---------- */
body[data-bs-theme="dark"] .hero-main,
body[data-bs-theme="dark"] .hero-aside,
body[data-bs-theme="dark"] .card,
body[data-bs-theme="dark"] .cat-card,
body[data-bs-theme="dark"] .product,
body[data-bs-theme="dark"] .store-banner,
body[data-bs-theme="dark"] .store-cats,
body[data-bs-theme="dark"] .footer,
body[data-bs-theme="dark"] .subhead,
body[data-bs-theme="dark"] .ticker {
  border-color: rgba(255, 255, 255, .06) !important;
}
body[data-bs-theme="dark"] .hero-main {
  background:
    radial-gradient(760px 420px at 90% 120%, rgba(210, 67, 74, .26) 0%, transparent 60%),
    radial-gradient(520px 320px at -10% -25%, rgba(227, 181, 91, .07) 0%, transparent 60%),
    var(--surface);
}
body[data-bs-theme="dark"] .card,
body[data-bs-theme="dark"] .cat-card,
body[data-bs-theme="dark"] .product {
  background-image: linear-gradient(180deg, rgba(255, 255, 255, .018), transparent 140px);
  transition: border-color .2s ease, transform .2s ease, box-shadow .2s ease;
}
body[data-bs-theme="dark"] .cat-card:hover,
body[data-bs-theme="dark"] .product:hover {
  border-color: var(--w-ring) !important;
  transform: translateY(-2px);
  box-shadow: 0 20px 40px -24px rgba(210, 67, 74, .45);
}
.metric .num { font-family: var(--font-display); font-weight: 700; font-size: 34px; letter-spacing: .01em; }
body[data-bs-theme="dark"] .metric .num { color: #F4EEEA; }
body[data-bs-theme="dark"] .metric .num .unit { color: var(--w-gold); }
.buy-price, .prod-price, .price, .lb-score { font-variant-numeric: tabular-nums; }
.buy-price { color: var(--w-gold) !important; background: rgba(227, 181, 91, .10) !important; border: 1px solid rgba(227, 181, 91, .22); font-family: var(--font-display) !important; letter-spacing: .04em; }
body[data-bs-theme="dark"] .prod-name,
body[data-bs-theme="dark"] .cat-card h3 { color: #F4EEEA; }

/* Vurgu zeminli rozetler: kırmızı + beyaz */
.nav-badge, .cart-badge, .subhead .tag, .sc-btn.on .sc-ic, .prod-discount, .page-item.active .page-link, .prod-flag.hot {
  background: var(--w-red) !important;
  color: #fff !important;
}
body[data-bs-theme="dark"] .ticker-label { background: var(--w-red); color: #fff; }
body[data-bs-theme="dark"] .subhead a { color: var(--w-rose); }
body.t-skin { --tblr-link-color: var(--w-rose); --tblr-link-hover-color: #fff; }
body[data-bs-theme="dark"].t-skin .text-primary { color: var(--w-rose) !important; }

/* ---------- 8. Hero sağ panel: Minecraft küpleri kaldırıldı → bulanık ışık + süzülen amblem ---------- */
body[data-bs-theme="dark"] .preview-art,
.preview-art {
  height: 230px;
  background:
    radial-gradient(260px 160px at 50% 58%, rgba(210, 67, 74, .28) 0%, transparent 70%),
    linear-gradient(180deg, #1B1112 0%, #120B0C 100%);
  isolation: isolate;
}
.preview-art .tree,
.preview-art .terrain { display: none !important; }

/* 3 bulut → yavaşça dolaşan bulanık ışık lekeleri */
.preview-art .cloud {
  width: 220px !important;
  height: 220px !important;
  border-radius: 50% !important;
  opacity: .5 !important;
  filter: blur(46px) !important;
  z-index: 0;
  will-change: transform;
}
.preview-art .cloud:nth-child(2) { background: #D2434A !important; top: -60px !important; left: -40px !important; animation: w-drift-a 16s ease-in-out infinite alternate; }
.preview-art .cloud:nth-child(3) { background: #7A1A21 !important; top: 60px !important; left: auto !important; right: -70px !important; animation: w-drift-b 19s ease-in-out infinite alternate; }
.preview-art .cloud:nth-child(4) { background: #E3B55B !important; opacity: .22 !important; width: 160px !important; height: 160px !important; top: 110px !important; right: auto !important; left: 36% !important; animation: w-drift-c 22s ease-in-out infinite alternate; }

/* güneş → süzülen Wortham amblemi */
.preview-art .sun {
  top: 50% !important;
  left: 50% !important;
  right: auto !important;
  width: 150px !important;
  height: 150px !important;
  margin: -88px 0 0 -75px;
  background: url("/assets/fresh/img/wortham-amblem-320.png") center / contain no-repeat !important;
  box-shadow: none !important;
  image-rendering: auto !important;
  filter: drop-shadow(0 16px 26px rgba(0, 0, 0, .65)) drop-shadow(0 0 28px rgba(210, 67, 74, .35));
  z-index: 2;
  animation: w-float 6s ease-in-out infinite;
}

/* dönen ince rün halkası (SVG) */
.preview-art::before {
  content: "";
  position: absolute;
  top: 50%;
  left: 50%;
  width: 210px;
  height: 210px;
  margin: -118px 0 0 -105px;
  background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 200 200'%3E%3Cg fill='none' stroke='%23E3B55B'%3E%3Ccircle cx='100' cy='100' r='96' stroke-opacity='.28' stroke-width='1'/%3E%3Ccircle cx='100' cy='100' r='84' stroke-opacity='.45' stroke-width='1.2' stroke-dasharray='2 9'/%3E%3Ccircle cx='100' cy='100' r='70' stroke='%23D2434A' stroke-opacity='.35' stroke-width='1'/%3E%3C/g%3E%3Cg fill='%23E3B55B' fill-opacity='.6'%3E%3Crect x='98' y='1' width='4' height='4' transform='rotate(45 100 3)'/%3E%3Crect x='98' y='195' width='4' height='4' transform='rotate(45 100 197)'/%3E%3Crect x='1' y='98' width='4' height='4' transform='rotate(45 3 100)'/%3E%3Crect x='195' y='98' width='4' height='4' transform='rotate(45 197 100)'/%3E%3C/g%3E%3C/svg%3E") center / contain no-repeat;
  z-index: 1;
  animation: w-spin 60s linear infinite;
  pointer-events: none;
}

/* yükselen kıvılcımlar (SVG) */
.preview-art::after {
  content: "";
  position: absolute;
  inset: 0;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='240' height='240'%3E%3Cg fill='%23F0A15E'%3E%3Ccircle cx='20' cy='30' r='1.3' opacity='.7'/%3E%3Ccircle cx='70' cy='150' r='1' opacity='.5'/%3E%3Ccircle cx='120' cy='60' r='1.6' opacity='.6'/%3E%3Ccircle cx='170' cy='200' r='1.1' opacity='.55'/%3E%3Ccircle cx='215' cy='95' r='1.4' opacity='.65'/%3E%3Ccircle cx='45' cy='215' r='1.2' opacity='.45'/%3E%3Ccircle cx='150' cy='120' r='.9' opacity='.5'/%3E%3C/g%3E%3C/svg%3E");
  background-size: 240px 240px;
  z-index: 1;
  opacity: .8;
  mask-image: linear-gradient(0deg, transparent 0%, #000 30%, #000 70%, transparent 100%);
  -webkit-mask-image: linear-gradient(0deg, transparent 0%, #000 30%, #000 70%, transparent 100%);
  animation: w-embers 14s linear infinite;
  pointer-events: none;
}
.preview-meta { z-index: 3 !important; }
body[data-bs-theme="dark"] .preview-meta .badge {
  background: rgba(18, 12, 12, .72);
  border: 1px solid rgba(255, 255, 255, .08);
  color: var(--w-text);
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
}

@keyframes w-float { 0%, 100% { transform: translateY(0) rotate(-1deg); } 50% { transform: translateY(-9px) rotate(1deg); } }
@keyframes w-spin { to { transform: rotate(360deg); } }
@keyframes w-embers { from { background-position: 0 0; } to { background-position: 30px -240px; } }
@keyframes w-drift-a { to { transform: translate(90px, 40px) scale(1.15); } }
@keyframes w-drift-b { to { transform: translate(-110px, -30px) scale(.9); } }
@keyframes w-drift-c { to { transform: translate(-70px, -50px) scale(1.2); } }
@media (prefers-reduced-motion: reduce) {
  .preview-art .sun, .preview-art .cloud, .preview-art::before, .preview-art::after { animation: none !important; }
}

/* ---------- 9. Formlar (giriş/kayıt/sepet) ---------- */
body[data-bs-theme="dark"].t-skin .form-control,
body[data-bs-theme="dark"].t-skin .form-select {
  background: #140E0E;
  border-color: var(--line);
}
body.t-skin .form-control:focus,
body.t-skin .form-select:focus {
  border-color: var(--w-red);
  box-shadow: 0 0 0 3px rgba(210, 67, 74, .18);
}
body.t-skin .form-check-input:checked { background-color: var(--w-red); border-color: var(--w-red); }

/* Giriş sayfası sol panel (auth.php içindeki satır içi #0f172a'yı ezer) */
html body[data-bs-theme="dark"] .auth-art {
  background:
    radial-gradient(720px 520px at 12% 4%, rgba(210, 67, 74, .30) 0%, transparent 60%),
    radial-gradient(680px 520px at 95% 95%, rgba(110, 22, 28, .45) 0%, transparent 55%),
    linear-gradient(160deg, #1C1212 0%, #0D0808 100%);
  border-right: 1px solid rgba(255, 255, 255, .06);
}
body[data-bs-theme="dark"] .auth-art::before { opacity: 0 !important; }
body[data-bs-theme="dark"] .auth-main { background: transparent; }
body[data-bs-theme="dark"] .auth-feats i,
body[data-bs-theme="dark"] .auth-ip i { color: var(--w-gold); }
body[data-bs-theme="dark"] .auth-box a:not([class*="btn"]) { color: var(--w-rose); }

/* ---------- 10. Altbilgi ---------- */
body[data-bs-theme="dark"] .footer {
  background:
    radial-gradient(640px 320px at 0% 0%, rgba(210, 67, 74, .12) 0%, transparent 60%),
    var(--surface);
}
.footer h4, .footer h5, .footer h6 { color: var(--w-gold) !important; }
body[data-bs-theme="dark"] .footer a:hover { color: #fff; }

/* ---------- 11. Çerez bandı (termsfeed) ---------- */
.termsfeed-com---nb { font-family: var(--font-body) !important; }
.termsfeed-com---palette-dark.termsfeed-com---nb,
.termsfeed-com---palette-dark .cc-nb-main-container {
  background: #1A1212 !important;
  color: var(--w-text) !important;
}
.termsfeed-com---palette-dark.termsfeed-com---nb {
  border: 1px solid rgba(255, 255, 255, .08) !important;
  border-radius: 16px !important;
  box-shadow: 0 24px 60px -20px rgba(0, 0, 0, .85) !important;
}
.termsfeed-com---palette-dark .cc-nb-title { font-family: var(--font-display) !important; font-weight: 700 !important; color: #F4EEEA !important; font-size: 24px !important; letter-spacing: .01em; }
.termsfeed-com---palette-dark .cc-nb-text { color: var(--w-soft) !important; font-size: 15px !important; }
.termsfeed-com---palette-dark .cc-nb-okagree {
  background: var(--w-btn) !important;
  color: #fff !important;
  border-radius: 10px !important;
  font-weight: 600 !important;
}
.termsfeed-com---palette-dark .cc-nb-changep,
.termsfeed-com---palette-dark .cc-nb-reject {
  background: transparent !important;
  color: var(--w-text) !important;
  border: 1px solid rgba(255, 255, 255, .14) !important;
  border-radius: 10px !important;
  font-weight: 500 !important;
}
@media (min-width: 768px) {
  .termsfeed-com---nb-simple { max-width: 480px !important; right: 16px !important; bottom: 16px !important; }
}
@media (max-width: 767px) {
  .termsfeed-com---nb-simple { left: 8px !important; right: 8px !important; bottom: 8px !important; max-height: 70vh; overflow: auto; }
  .termsfeed-com---palette-dark .cc-nb-title { font-size: 20px !important; }
  .termsfeed-com---palette-dark .cc-nb-text { font-size: 14px !important; }
}

/* ---------- 12. Seçim / kaydırma çubuğu ---------- */
::selection { background: rgba(210, 67, 74, .75); color: #fff; }
body[data-bs-theme="dark"] { scrollbar-color: #3A2A29 #0B0707; }

/* ---------- 13. Mobil ---------- */
@media (max-width: 560px) {
  .hero h1 { font-size: 42px; }
  .brand-mark { width: 38px !important; height: 38px !important; }
  .brand-name { font-size: 19px; letter-spacing: .06em; }
  .brand-name::after { display: none; }
  .topbar { gap: 8px; padding-left: 12px; padding-right: 8px; }
  .top-actions { gap: 6px; }
  .top-auth .btn.sm { padding-left: 10px; padding-right: 10px; }
  .top-auth .btn.sm .btn-label { white-space: nowrap; }
  .preview-art .sun { width: 130px !important; height: 130px !important; margin: -78px 0 0 -65px; }
}

/* ---------- 14. Sunucu adresi okunur olsun ---------- */
.ip-l b, .auth-ip-l b {
  font-family: var(--font-body) !important;
  font-weight: 600;
  font-size: 17px;
  letter-spacing: .02em;
  color: #F4EEEA;
}
