/* =========================================================
   COD Tournament Showcase Site (Static)
   Light, modern, responsive, high-polish UI
   ========================================================= */

:root {
  --bg: #f6f8ff;
  --bg2: #eef2ff;
  --card: #ffffffcc;
  --text: #0f172a;
  --muted: #475569;
  --brand: #2563eb;
  --brand2: #7c3aed;
  --accent: #06b6d4;
  --good: #10b981;
  --warn: #f59e0b;
  --danger: #ef4444;

  --shadow: 0 18px 55px rgba(2, 8, 23, .14);
  --shadow2: 0 10px 30px rgba(2, 8, 23, .12);
  --radius: 22px;
  --radius2: 16px;
  --border: 1px solid rgba(15, 23, 42, .10);
  --glass: blur(12px);

  --max: 1120px;
}

* {
  box-sizing: border-box
}

html {
  scroll-behavior: smooth
}

body {
  margin: 0;
  font-family: ui-sans-serif, system-ui, -apple-system, Segoe UI, Roboto, "Helvetica Neue", Arial, "Noto Sans", "Apple Color Emoji", "Segoe UI Emoji";
  color: var(--text);
  background:
    radial-gradient(1200px 600px at 15% 10%, rgba(37, 99, 235, .22), transparent 60%),
    radial-gradient(900px 500px at 85% 15%, rgba(124, 58, 237, .22), transparent 60%),
    radial-gradient(900px 650px at 60% 90%, rgba(6, 182, 212, .18), transparent 60%),
    linear-gradient(180deg, var(--bg) 0%, var(--bg2) 100%);
}

a {
  color: inherit;
  text-decoration: none
}

img {
  max-width: 100%;
  display: block
}

button {
  font-family: inherit
}

::selection {
  background: rgba(37, 99, 235, .18)
}

.container {
  width: min(var(--max), calc(100% - 32px));
  margin-inline: auto
}

.section {
  padding: 70px 0
}

.section-tight {
  padding: 45px 0
}

.kicker {
  display: inline-flex;
  gap: 10px;
  align-items: center;
  padding: 10px 14px;
  border: var(--border);
  background: rgba(255, 255, 255, .70);
  backdrop-filter: var(--glass);
  border-radius: 999px;
  box-shadow: 0 10px 30px rgba(2, 8, 23, .06);
  color: var(--muted);
  font-weight: 700;
  letter-spacing: .2px;
}

.kicker i {
  color: var(--brand)
}

h1,
h2,
h3 {
  margin: 0 0 12px 0
}

p {
  margin: 0 0 14px 0;
  color: var(--muted);
  line-height: 1.85
}

.small {
  font-size: .95rem
}

.muted {
  color: var(--muted)
}

hr.sep {
  border: none;
  height: 1px;
  background: linear-gradient(90deg, transparent, rgba(15, 23, 42, .14), transparent);
  margin: 30px 0;
}

/* Header */
.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  border-bottom: 1px solid rgba(15, 23, 42, .08);
  background: rgba(246, 248, 255, .70);
  backdrop-filter: blur(14px);
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 14px 0;
  gap: 14px;
}

.brand {
  display: flex;
  align-items: center;
  gap: 12px;
  min-width: 180px;
}

.brand-logo {
  width: 42px;
  height: 42px;
  display: block;
  object-fit: contain;
  /* کل آیکن دیده شود */
  background: none;
  border-radius: 0;
  box-shadow: none;
  outline: none;
}

.brand-logo:after {
  content: "";
  position: absolute;
  inset: 9px;
  border-radius: 10px;
  border: 1px dashed rgba(255, 255, 255, .55);
  opacity: .9;
}

.brand-name {
  display: flex;
  flex-direction: column;
  line-height: 1.05;
}

.brand-name strong {
  font-size: 1.05rem
}

.brand-name span {
  font-size: .82rem;
  color: var(--muted);
  font-weight: 700
}

.nav {
  display: flex;
  align-items: center;
  gap: 10px;
}

.nav a {
  position: relative;
  padding: 10px 12px;
  border-radius: 12px;
  color: rgba(15, 23, 42, .86);
  font-weight: 800;
  letter-spacing: .1px;
  transition: transform .12s ease, background .18s ease, box-shadow .18s ease;
}

.nav a:hover {
  background: rgba(255, 255, 255, .85);
  box-shadow: 0 12px 30px rgba(2, 8, 23, .08);
  transform: translateY(-1px);
}

.nav a.active {
  background: rgba(37, 99, 235, .12);
  color: var(--brand);
  box-shadow: inset 0 0 0 1px rgba(37, 99, 235, .18);
}

.header-cta {
  display: flex;
  gap: 10px;
  align-items: center
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  padding: 11px 14px;
  border-radius: 14px;
  border: 1px solid rgba(15, 23, 42, .12);
  background: rgba(255, 255, 255, .86);
  color: rgba(15, 23, 42, .92);
  font-weight: 900;
  letter-spacing: .15px;
  box-shadow: 0 10px 25px rgba(2, 8, 23, .06);
  transition: transform .12s ease, box-shadow .18s ease, background .18s ease;
  cursor: pointer;
}

.btn:hover {
  transform: translateY(-1px);
  box-shadow: 0 18px 45px rgba(2, 8, 23, .12);
  background: #fff;
}

.btn:active {
  transform: translateY(0px);
  box-shadow: 0 10px 25px rgba(2, 8, 23, .08)
}

.btn-primary {
  border: none;
  color: #fff;
  background: linear-gradient(135deg, var(--brand), var(--brand2));
  box-shadow: 0 18px 45px rgba(37, 99, 235, .24);
}

.btn-primary:hover {
  box-shadow: 0 24px 65px rgba(37, 99, 235, .30)
}

.btn-ghost {
  background: rgba(255, 255, 255, .55);
  backdrop-filter: var(--glass);
}

.btn-sm {
  padding: 9px 12px;
  border-radius: 12px;
  font-weight: 900;
  font-size: .95rem
}

.burger {
  display: none;
  width: 44px;
  height: 44px;
  border-radius: 14px;
  border: 1px solid rgba(15, 23, 42, .12);
  background: rgba(255, 255, 255, .76);
  box-shadow: 0 10px 25px rgba(2, 8, 23, .06);
  cursor: pointer;
}

.burger i {
  font-size: 18px
}

/* Mobile nav drawer */
.drawer {
  display: none;
  position: fixed;
  inset: 0;
  z-index: 60;
  background: rgba(2, 8, 23, .45);
  backdrop-filter: blur(6px);
}

.drawer-panel {
  position: absolute;
  right: 12px;
  top: 12px;
  width: min(360px, calc(100% - 24px));
  border-radius: 22px;
  background: rgba(255, 255, 255, .90);
  border: 1px solid rgba(15, 23, 42, .10);
  box-shadow: var(--shadow);
  overflow: hidden;
}

.drawer-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 14px 14px;
  border-bottom: 1px solid rgba(15, 23, 42, .08);
}

.drawer-links {
  display: flex;
  flex-direction: column;
  padding: 10px
}

.drawer-links a {
  padding: 12px 12px;
  border-radius: 14px;
  font-weight: 900;
  color: rgba(15, 23, 42, .90);
}

.drawer-links a:hover {
  background: rgba(37, 99, 235, .08)
}

.drawer-cta {
  display: flex;
  gap: 10px;
  padding: 10px 12px 14px
}

/* Hero */
.hero {
  padding: 58px 0 40px;
}

.hero-grid {
  display: grid;
  grid-template-columns: 1.15fr .85fr;
  gap: 24px;
  align-items: stretch;
}

.hero-card {
  border-radius: var(--radius);
  border: var(--border);
  background: rgba(255, 255, 255, .72);
  backdrop-filter: var(--glass);
  box-shadow: var(--shadow);
  overflow: hidden;
  position: relative;
}

.hero-card:before {
  content: "";
  position: absolute;
  inset: -1px;
  background:
    radial-gradient(550px 250px at 15% 10%, rgba(37, 99, 235, .22), transparent 65%),
    radial-gradient(420px 220px at 80% 15%, rgba(124, 58, 237, .20), transparent 65%),
    radial-gradient(420px 260px at 60% 100%, rgba(6, 182, 212, .16), transparent 65%);
  pointer-events: none;
  opacity: .95;
}

.hero-left {
  padding: 30px 28px 26px;
  position: relative;
}

.hero-left h1 {
  font-size: clamp(1.9rem, 3.8vw, 3.1rem);
  line-height: 1.18;
  letter-spacing: -.6px;
  margin-top: 12px;
}

.hero-left h1 span {
  background: linear-gradient(135deg, var(--brand), var(--brand2));
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.hero-left p {
  font-size: 1.03rem;
  margin-top: 10px;
  max-width: 58ch;
}

.hero-actions {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
  margin-top: 16px;
}

.hero-bullets {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
  margin-top: 18px;
}

.pill {
  display: flex;
  gap: 10px;
  align-items: flex-start;
  padding: 12px 12px;
  border-radius: 18px;
  border: 1px solid rgba(15, 23, 42, .10);
  background: rgba(255, 255, 255, .75);
  box-shadow: 0 10px 25px rgba(2, 8, 23, .05);
}

.pill i {
  color: var(--brand);
  margin-top: 2px
}

.pill strong {
  display: block;
  font-size: .95rem
}

.pill span {
  display: block;
  font-size: .85rem;
  color: var(--muted);
  margin-top: 2px
}

.hero-right {
  position: relative;
  padding: 16px;
}

.poster {
  height: 100%;
  min-height: 340px;
  border-radius: 22px;
  border: 1px solid rgba(15, 23, 42, .10);
  overflow: hidden;
  background:
    radial-gradient(400px 240px at 40% 20%, rgba(255, 255, 255, .85), transparent 55%),
    linear-gradient(135deg, rgba(37, 99, 235, .80), rgba(124, 58, 237, .85));
  box-shadow: 0 18px 55px rgba(124, 58, 237, .18);
  display: flex;
  flex-direction: column;
}

.poster-top {
  padding: 18px 18px 12px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  color: rgba(255, 255, 255, .92);
}

.chip {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 9px 12px;
  border-radius: 999px;
  background: rgba(255, 255, 255, .16);
  border: 1px solid rgba(255, 255, 255, .22);
  font-weight: 900;
}

.poster-mid {
  margin-top: auto;
  padding: 18px;
  color: rgba(255, 255, 255, .92);
}

.stat-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
}

.stat {
  border-radius: 18px;
  background: rgba(255, 255, 255, .16);
  border: 1px solid rgba(255, 255, 255, .22);
  padding: 12px;
}

.stat .v {
  font-size: 1.2rem;
  font-weight: 950
}

.stat .k {
  font-size: .82rem;
  opacity: .9
}

.poster-note {
  margin-top: 10px;
  font-size: .92rem;
  opacity: .92;
}

/* Leaderboard */
.cards-grid {
  display: grid;
  grid-template-columns: repeat(12, 1fr);
  gap: 18px;
}

.lb-headline {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
}

.lb-subtitle {
  font-weight: bold;
  color: rgba(15, 23, 42, .88);
  letter-spacing: -.2px;
  font-size: 25px;
}

.panel {
  border-radius: var(--radius);
  border: var(--border);
  background: rgba(255, 255, 255, .72);
  backdrop-filter: var(--glass);
  box-shadow: var(--shadow2);
  overflow: hidden;
}

.panel-head {
  padding: 18px 18px 0;
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 14px;
}

.panel-head h2 {
  font-size: clamp(1.25rem, 2.6vw, 1.7rem);
  margin: 0
}

.panel-head p {
  margin: 0;
  max-width: 70ch
}

.panel-body {
  padding: 16px 18px 18px
}

.lb-wrap {
  display: flex;
  align-items: flex-end;
  justify-content: center;
  gap: 16px;
  margin-top: 10px;
  flex-wrap: wrap;
}

.podium {
  width: min(260px, 100%);
  border-radius: 22px;
  border: 1px solid rgba(15, 23, 42, .10);
  background: rgba(255, 255, 255, .78);
  box-shadow: 0 18px 55px rgba(2, 8, 23, .10);
  padding: 14px 14px 12px;
  position: relative;
  transition: transform .18s ease, box-shadow .18s ease;
}

.podium:hover {
  transform: translateY(-3px);
  box-shadow: 0 26px 75px rgba(2, 8, 23, .14)
}

.podium.rank-1 {
  transform: translateY(-10px)
}

.podium.rank-1:hover {
  transform: translateY(-14px)
}

.rank-badge {
  position: absolute;
  top: 12px;
  left: 12px;
  width: 42px;
  height: 42px;
  display: grid;
  place-items: center;
  border-radius: 16px;
  font-weight: 950;
  color: #fff;
  box-shadow: 0 18px 45px rgba(2, 8, 23, .14);
}

.rank-1 .rank-badge {
  background: linear-gradient(135deg, #fbbf24, #f59e0b)
}

.rank-2 .rank-badge {
  /* Bronze */
  background: linear-gradient(135deg, #d97706, #b45309)
}

.rank-3 .rank-badge {
  /* Silver */
  background: linear-gradient(135deg, #e5e7eb, #94a3b8)
}

/* Rank glow / halo */
.podium::before {
  content: "";
  position: absolute;
  inset: -2px;
  border-radius: 26px;
  pointer-events: none;
  opacity: .0;
  filter: blur(10px);
  transition: opacity .18s ease;
}

.podium.rank-1::before {
  opacity: .85;
  background: radial-gradient(circle at 50% 40%, rgba(251, 191, 36, .55), rgba(245, 158, 11, .20) 45%, rgba(245, 158, 11, 0) 70%);
}

.podium.rank-2::before {
  opacity: .55;
  background: radial-gradient(circle at 50% 40%, rgba(217, 119, 6, .45), rgba(180, 83, 9, .18) 45%, rgba(180, 83, 9, 0) 70%);
}

.podium.rank-3::before {
  opacity: .55;
  background: radial-gradient(circle at 50% 40%, rgba(229, 231, 235, .55), rgba(148, 163, 184, .22) 45%, rgba(148, 163, 184, 0) 70%);
}

.podium-top {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 8px;
  color: var(--muted);
  font-weight: 900;
}

.avatar {
  width: 86px;
  height: 86px;
  border-radius: 26px;
  overflow: hidden;
  border: 1px solid rgba(15, 23, 42, .10);
  box-shadow: 0 16px 40px rgba(2, 8, 23, .10);
  background: #fff;
  margin: 14px auto 10px;
}

.avatar img {
  width: 100%;
  height: 100%;
  object-fit: cover
}

.podium h3 {
  font-size: 1.06rem;
  text-align: center;
  margin: 0 0 4px;
}

.podium .gid {
  text-align: center;
  font-weight: 950;
  letter-spacing: .6px;
  color: rgba(15, 23, 42, .86);
}

.podium .bal {
  text-align: center;
  margin-top: 8px;
  padding: 10px 12px;
  border-radius: 18px;
  border: 1px solid rgba(15, 23, 42, .10);
  background: rgba(37, 99, 235, .06);
  font-weight: 950;
  color: rgba(15, 23, 42, .92);
}

.rank-1 .bal {
  background: rgba(245, 158, 11, .10)
}

.rank-2 .bal {
  /* Bronze */
  background: rgba(217, 119, 6, .14)
}

.rank-3 .bal {
  /* Silver */
  background: rgba(148, 163, 184, .14)
}

/* FAQ */
.accordion {
  display: grid;
  gap: 12px;
  margin-top: 10px;
}

.acc-item {
  border-radius: 20px;
  border: 1px solid rgba(15, 23, 42, .10);
  background: rgba(255, 255, 255, .76);
  box-shadow: 0 14px 35px rgba(2, 8, 23, .07);
  overflow: hidden;
  transition: transform .16s ease, box-shadow .16s ease;
}

.acc-item:hover {
  transform: translateY(-1px);
  box-shadow: 0 20px 50px rgba(2, 8, 23, .10)
}

.acc-btn {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  padding: 16px 16px;
  background: transparent;
  border: none;
  cursor: pointer;
  text-align: right;
}

.acc-q {
  font-weight: 950;
  color: rgba(15, 23, 42, .92);
  line-height: 1.4;
  font-size: 1.02rem;
}

.acc-btn i {
  width: 34px;
  height: 34px;
  border-radius: 14px;
  display: grid;
  place-items: center;
  background: rgba(37, 99, 235, .10);
  color: var(--brand);
  transition: transform .2s ease;
  flex: 0 0 auto;
}

.acc-item.open .acc-btn i {
  transform: rotate(180deg)
}

.acc-panel {
  max-height: 0;
  overflow: hidden;
  transition: max-height .28s ease;
}

.acc-panel>div {
  padding: 0 16px 16px;
  color: var(--muted);
  line-height: 1.9;
}

/* Forms / contact */
.form-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
}

.field {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

label {
  font-weight: 900;
  color: rgba(15, 23, 42, .86)
}

input,
textarea {
  padding: 12px 12px;
  border-radius: 16px;
  border: 1px solid rgba(15, 23, 42, .12);
  background: rgba(255, 255, 255, .86);
  outline: none;
  box-shadow: 0 10px 25px rgba(2, 8, 23, .05);
  transition: border-color .16s ease, box-shadow .16s ease, transform .12s ease;
}

input:focus,
textarea:focus {
  border-color: rgba(37, 99, 235, .45);
  box-shadow: 0 18px 45px rgba(37, 99, 235, .14);
  transform: translateY(-1px);
}

textarea {
  min-height: 140px;
  resize: vertical
}

.full {
  grid-column: 1 / -1
}

.contact-cards {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 14px;
  margin-top: 18px;
}

.info-card {
  border-radius: 22px;
  border: 1px solid rgba(15, 23, 42, .10);
  background: rgba(255, 255, 255, .74);
  box-shadow: 0 18px 55px rgba(2, 8, 23, .08);
  padding: 16px;
  display: flex;
  gap: 12px;
}

.info-card i {
  width: 42px;
  height: 42px;
  border-radius: 16px;
  display: grid;
  place-items: center;
  background: rgba(37, 99, 235, .10);
  color: var(--brand);
  flex: 0 0 auto;
}

.info-card strong {
  display: block;
  margin-bottom: 2px
}

.info-card a,
.info-card span {
  color: var(--muted);
  font-weight: 800
}

/* Terms */
.term-list {
  display: grid;
  gap: 12px;
  margin-top: 10px;
}

.term {
  border-radius: 22px;
  border: 1px solid rgba(15, 23, 42, .10);
  background: rgba(255, 255, 255, .74);
  box-shadow: 0 18px 55px rgba(2, 8, 23, .08);
  padding: 16px;
  display: flex;
  gap: 12px;
}

.term i {
  width: 44px;
  height: 44px;
  border-radius: 18px;
  display: grid;
  place-items: center;
  background: rgba(16, 185, 129, .12);
  color: var(--good);
  flex: 0 0 auto;
}

.term strong {
  display: block;
  margin-bottom: 4px
}

/* Footer */
.site-footer {
  padding: 28px 0 34px;
  border-top: 1px solid rgba(15, 23, 42, .08);
  background: rgba(246, 248, 255, .70);
  backdrop-filter: blur(14px);
}

.footer-inner {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
}

.trust-row {
  display: flex;
  gap: 14px;
  flex-wrap: wrap;
  justify-content: center;
  align-items: center;
  width: 100%;
}

.trust-badge {
  display: grid;
  place-items: center;
  width: 120px;
  height: 78px;
  border-radius: 18px;
  border: 1px solid rgba(15, 23, 42, .10);
  background: rgba(255, 255, 255, .82);
  box-shadow: 0 14px 35px rgba(2, 8, 23, .06);
  transition: transform .14s ease, box-shadow .14s ease;
}

.trust-badge:hover {
  transform: translateY(-2px);
  box-shadow: 0 22px 60px rgba(2, 8, 23, .10);
}

.footer-note {
  text-align: center;
  color: var(--muted);
  font-weight: 800;
  font-size: .95rem;
}

/* Helpers */
.grid-2 {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 18px;
}

.callout {
  border-radius: var(--radius);
  border: var(--border);
  background: rgba(255, 255, 255, .72);
  backdrop-filter: var(--glass);
  box-shadow: var(--shadow2);
  padding: 18px;
}

.callout h3 {
  margin: 0 0 8px
}

.breadcrumb {
  display: flex;
  align-items: center;
  gap: 8px;
  color: var(--muted);
  font-weight: 900;
  margin-top: 6px;
}

.breadcrumb a {
  color: var(--brand)
}

.breadcrumb i {
  opacity: .85
}

/* Responsive */
@media (max-width: 980px) {
  .hero-grid {
    grid-template-columns: 1fr
  }

  .hero-right .poster {
    min-height: 280px
  }

  .contact-cards {
    grid-template-columns: 1fr
  }
}

@media (max-width: 880px) {
  .nav {
    display: none
  }

  .header-cta {
    display: none
  }

  .burger {
    display: grid;
    place-items: center
  }

  .form-grid {
    grid-template-columns: 1fr
  }

  .grid-2 {
    grid-template-columns: 1fr
  }
}

@media (max-width: 520px) {
  .lb-wrap {
    flex-direction: column;
    align-items: stretch;
  }

  /* On mobile, show the champion first */
  .podium.rank-1 {
    order: 1;
    transform: none;
  }

  .podium.rank-1:hover {
    transform: none;
  }

  .podium.rank-2 {
    order: 2;
  }

  .podium.rank-3 {
    order: 3;
  }

  .hero-left {
    padding: 24px 18px 20px
  }

  .panel-head {
    flex-direction: column;
    align-items: flex-start
  }

  .podium {
    width: 100%
  }

  .hero-bullets {
    grid-template-columns: 1fr
  }

  .trust-badge {
    width: 106px;
    height: 72px
  }
}


/* Poster center emblem */
.poster-center {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  pointer-events: none;
}

.emblem-wrap {
  width: min(220px, 52vw);
  aspect-ratio: 1 / 1;
  border-radius: 28px;
  background: rgba(255, 255, 255, .14);
  border: 1px solid rgba(255, 255, 255, .24);
  backdrop-filter: blur(10px);
  box-shadow: 0 24px 75px rgba(2, 8, 23, .18);
  display: grid;
  place-items: center;
}

.emblem-wrap img {
  width: 72%;
  height: 72%;
  object-fit: contain;
  opacity: .96;
  filter: drop-shadow(0 18px 28px rgba(2, 8, 23, .22));
}

@media (max-width: 520px) {
  .emblem-wrap {
    border-radius: 22px
  }
}


/* =========================================================
   Dark Gaming Theme Override (Background images + Persian fonts)
   Notes:
   - Background assets expected at: /webapp/assets/img/
   ========================================================= */

:root {
  --bg: #060812;
  --bg2: #0b1024;
  --card: rgba(12, 16, 34, .62);
  --text: rgba(255, 255, 255, .92);
  --muted: rgba(255, 255, 255, .72);

  /* Gaming accents */
  --brand: #3b82f6;
  --brand2: #a855f7;
  --accent: #22d3ee;
  --good: #22c55e;
  --warn: #fbbf24;
  --danger: #fb7185;

  --shadow: 0 22px 70px rgba(0, 0, 0, .45);
  --shadow2: 0 14px 40px rgba(0, 0, 0, .38);
  --border: 1px solid rgba(255, 255, 255, .10);
  --glass: blur(14px);

  /* background image urls (primary: webapp path, fallback: assets/img) */
  --bckgd-main: url("../../webapp/assets/img/main-home-bckgd-img.png");
  --bckgd-rev-1: url("../../webapp/assets/img/main-home-rev-1.png");
  --bckgd-rev-2: url("../../webapp/assets/img/main-home-rev-2.png");
  --bckgd-rev-3: url("../../webapp/assets/img/main-home-rev-3.png");

  /* per-page background (single background per page) */
  --page-bckgd: var(--bckgd-main);
}

/* Persian font stack: uses installed fonts if present */
body {
  font-family: "B Nazanin", "B Nazanin Bold", "B Titr", "Vazirmatn", "IRANSans", "IRANSansWeb", "Sahel", "Shabnam", "Tahoma", Arial, sans-serif;
  background-color: var(--bg);
  color: var(--text);
  /* single background image per page (plus a subtle dark overlay) */
  background-image:
    linear-gradient(180deg, rgba(6, 8, 18, .82), rgba(6, 8, 18, .92)),
    var(--page-bckgd);
  background-size: auto, cover;
  background-position: center, center;
  background-repeat: no-repeat;
  background-attachment: scroll, fixed;
}

@media (max-width: 820px) {
  body {
    background-attachment: scroll, scroll;
  }
}

/* Assign exactly one background per page */
body.page-home {
  --page-bckgd: var(--bckgd-main);
}

body.page-about {
  --page-bckgd: var(--bckgd-rev-1);
}

body.page-terms {
  --page-bckgd: var(--bckgd-rev-2);
}

body.page-contact {
  --page-bckgd: var(--bckgd-rev-3);
}

/* Assign one background per page */
body.page-home {
  --page-bckgd: var(--bckgd-main);
}

body.page-about {
  --page-bckgd: var(--bckgd-rev-1);
}

body.page-terms {
  --page-bckgd: var(--bckgd-rev-2);
}

body.page-contact {
  --page-bckgd: var(--bckgd-rev-3);
}

h1,
h2,
h3,
.brand-name strong,
.lb-subtitle {
  font-family: "B Titr", "B Nazanin Bold", "Vazirmatn", "IRANSans", "Tahoma", Arial, sans-serif;
  letter-spacing: 0;
}

p {
  color: var(--muted);
}

/* Glassy dark surfaces */
.site-header {
  background: rgba(6, 8, 18, .60);
  border-bottom: 1px solid rgba(255, 255, 255, .08);
  backdrop-filter: blur(16px);
}

.nav a {
  color: rgba(255, 255, 255, .88);
}

.nav a:hover {
  background: rgba(255, 255, 255, .06);
}

.kicker {
  background: rgba(255, 255, 255, .06);
  border: 1px solid rgba(255, 255, 255, .10);
  color: rgba(255, 255, 255, .78);
  box-shadow: 0 14px 40px rgba(0, 0, 0, .22);
}

.kicker i {
  color: var(--accent);
}

.panel,
.hero-card,
.callout,
.acc-item {
  background: var(--card);
  border: var(--border);
  box-shadow: var(--shadow2);
}

/* Contact / forms (dark theme) */
label {
  color: rgba(255, 255, 255, .88);
}

input,
textarea {
  background: rgba(0, 0, 0, .26);
  border: 1px solid rgba(255, 255, 255, .14);
  color: rgba(255, 255, 255, .92);
  box-shadow: 0 14px 38px rgba(0, 0, 0, .24);
}

input::placeholder,
textarea::placeholder {
  color: rgba(255, 255, 255, .55);
}

input:focus,
textarea:focus {
  border-color: rgba(34, 211, 238, .55);
  box-shadow: 0 20px 55px rgba(34, 211, 238, .16);
}

.info-card,
.term {
  background: rgba(255, 255, 255, .06) !important;
  border: 1px solid rgba(255, 255, 255, .12) !important;
  box-shadow: 0 18px 55px rgba(0, 0, 0, .24) !important;
}

.info-card strong,
.term strong {
  color: rgba(255, 255, 255, .92);
}

.info-card a {
  color: rgba(34, 211, 238, .96);
  font-weight: 950;
  text-decoration: none;
}

.info-card a:hover {
  text-decoration: underline;
}

.info-card i {
  background: rgba(34, 211, 238, .14);
  color: rgba(34, 211, 238, .95);
}

hr.sep {
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, .14), transparent);
}

/* IMPORTANT: single background per page
   (disable per-section background images that made pages "multi-background") */
.hero,
.section,
#leaderboard-sec,
.section-tight,
.site-footer {
  position: relative;
}

.hero::before,
.section::before,
#leaderboard-sec::before,
.section-tight::before,
.site-footer::before,
.hero::after,
.section::after,
#leaderboard-sec::after,
.section-tight::after,
.site-footer::after {
  display: none !important;
}

/* Buttons: more gaming + contrast */
.btn {
  border: 1px solid rgba(255, 255, 255, .12);
  background: rgba(255, 255, 255, .06);
  color: rgba(255, 255, 255, .90);
  box-shadow: 0 12px 30px rgba(0, 0, 0, .22);
}

.btn:hover {
  background: rgba(255, 255, 255, .10);
  transform: translateY(-1px);
}

.btn-primary {
  background: linear-gradient(135deg, rgba(59, 130, 246, .92), rgba(168, 85, 247, .92));
  border-color: rgba(255, 255, 255, .18);
}

.btn-primary:hover {
  filter: saturate(1.08) brightness(1.02);
}

.btn-ghost {
  background: rgba(255, 255, 255, .05);
}

/* Poster + emblem: bigger & always crisp */
.hero-right .poster {
  border: 1px solid rgba(255, 255, 255, .14);
  box-shadow: 0 26px 85px rgba(0, 0, 0, .48);
  background:
    radial-gradient(520px 320px at 40% 20%, rgba(255, 255, 255, .12), transparent 60%),
    linear-gradient(135deg, rgba(59, 130, 246, .55), rgba(168, 85, 247, .62));
}

.emblem-wrap {
  width: clamp(220px, 34vw, 360px);
  border-radius: 30px;
}

.emblem-wrap img {
  width: 82%;
  height: 82%;
  image-rendering: auto;
  filter: drop-shadow(0 26px 42px rgba(0, 0, 0, .55));
}

@media (max-width: 520px) {
  .emblem-wrap {
    width: clamp(190px, 70vw, 280px);
    border-radius: 24px;
  }

  .emblem-wrap img {
    width: 84%;
    height: 84%;
  }
}

/* Leaderboard: keep 3-wide on small screens (no stacking) */
.lb-subtitle {
  color: rgba(255, 255, 255, .88);
}

.lb-wrap {
  flex-wrap: nowrap;
}

.podium {
  background: rgba(10, 14, 30, .62);
  border: 1px solid rgba(255, 255, 255, .12);
}

.podium .gid {
  color: rgba(255, 255, 255, .90);
}

.podium-top {
  color: rgba(255, 255, 255, .70);
}

.avatar {
  background: rgba(255, 255, 255, .10);
  border: 1px solid rgba(255, 255, 255, .14);
}

.podium .bal {
  border: 1px solid rgba(255, 255, 255, .12);
  color: rgba(255, 255, 255, .92);
  background: rgba(59, 130, 246, .12);
}

@media (max-width: 940px) {

  /* override existing "width:100%" which caused stacking */
  .lb-wrap {
    gap: 10px;
  }

  .podium {
    width: min(32%, 200px);
    flex: 1 1 0;
  }

  .podium.rank-1 {
    transform: translateY(-10px);
  }

  .podium.rank-1:hover {
    transform: translateY(-14px);
  }
}

@media (max-width: 520px) {
  .lb-wrap {
    gap: 8px;
  }

  .podium {
    width: min(32%, 150px);
    padding: 12px 10px 10px;
    border-radius: 18px;
  }

  .avatar {
    width: 68px;
    height: 68px;
    border-radius: 20px;
  }

  .podium .gid {
    font-size: .92rem;
    letter-spacing: .3px;
  }

  .podium .bal {
    padding: 8px 10px;
    border-radius: 14px;
    font-size: .9rem;
  }

  .rank-badge {
    width: 36px;
    height: 36px;
    border-radius: 14px;
  }
}

/* Footer */
.site-footer {
  border-top: 1px solid rgba(255, 255, 255, .08);
}

.footer-note {
  color: rgba(255, 255, 255, .72);
}




/* =========================================================
   FIX PACK v3 (visibility, hero layout, leaderboard mobile, FAQ colors, footer)
   ========================================================= */

/* Ensure section background layers never block interactions */
.hero::before,
.hero::after,
.section::before,
.section::after,
#leaderboard-sec::before,
#leaderboard-sec::after,
.section-tight::before,
.section-tight::after,
.site-footer::before,
.site-footer::after {
  pointer-events: none;
}

/* Lift real content above pseudo background layers */
.hero>*,
.section>*,
#leaderboard-sec>*,
.section-tight>*,
.site-footer>* {
  position: relative;
  z-index: 1;
}

/* Fix faded headings/subtitles on dark */
.lb-subtitle {
  color: rgba(255, 255, 255, .90) !important;
}

.panel-head h2,
.panel-head h3 {
  color: rgba(255, 255, 255, .92);
}

/* Hero bullets (ویترین تورنومنت‌ها و بقیه) – dark gaming cards */
.pill {
  background: rgba(255, 255, 255, .06) !important;
  border: 1px solid rgba(255, 255, 255, .12) !important;
  box-shadow: 0 14px 34px rgba(0, 0, 0, .24) !important;
}

.pill strong {
  color: rgba(255, 255, 255, .92);
}

.pill i {
  color: var(--accent);
}

/* Poster/emblem: keep it inside poster and never overlap other blocks */
.poster {
  position: relative;
  border: 1px solid rgba(255, 255, 255, .12);
  background:
    radial-gradient(520px 320px at 38% 18%, rgba(59, 130, 246, .18), transparent 60%),
    radial-gradient(520px 360px at 78% 22%, rgba(168, 85, 247, .16), transparent 62%),
    linear-gradient(180deg, rgba(6, 8, 18, .55), rgba(6, 8, 18, .82));
}

.poster-top,
.poster-mid {
  position: relative;
  z-index: 2;
}

.poster-center {
  position: absolute;
  left: 0;
  right: 0;
  top: 74px;
  /* below poster-top */
  bottom: 140px;
  /* above poster-mid */
  display: grid;
  place-items: center;
  z-index: 1;
  pointer-events: none;
}

.emblem-wrap {
  width: clamp(180px, 34vw, 280px);
  border-radius: 28px;
  background: rgba(255, 255, 255, .08);
  border: 1px solid rgba(255, 255, 255, .16);
  backdrop-filter: blur(12px);
  box-shadow: 0 26px 80px rgba(0, 0, 0, .40);
}

.emblem-wrap img {
  width: 76%;
  height: 76%;
  opacity: 1;
  filter: drop-shadow(0 22px 34px rgba(0, 0, 0, .50));
}

@media (max-width: 768px) {
  .poster-center {
    top: 68px;
    bottom: 150px;
  }

  .emblem-wrap {
    width: clamp(160px, 52vw, 240px);
  }
}

/* On narrow devices, hide the right hero card entirely (prevents overlap/ugly stacking) */
@media (max-width: 980px) {
  .hero-card.hero-right {
    display: none !important;
  }

  .hero-grid {
    grid-template-columns: 1fr !important;
  }
}

@media (max-width: 520px) {
  .poster-top {
    flex-wrap: wrap;
    gap: 10px;
  }

  .poster-center {
    top: 96px;
    bottom: 170px;
  }

  /* give space so chips don't overlap emblem */
  .emblem-wrap {
    width: min(220px, 78vw);
    border-radius: 22px;
  }
}

/* Leaderboard Top3: keep 2-1-3 layout on small widths */
.lb-wrap {
  flex-wrap: nowrap;
}

.podium {
  background: rgba(255, 255, 255, .06) !important;
  border: 1px solid rgba(255, 255, 255, .12) !important;
  box-shadow: 0 18px 55px rgba(0, 0, 0, .28) !important;
}

@media (max-width: 640px) {
  .lb-wrap {
    gap: 10px;
    align-items: flex-end;
  }

  .podium {
    width: auto;
    flex: 1 1 0;
    min-width: 0;
    padding: 10px 10px 10px;
  }

  .podium.rank-1 {
    transform: translateY(-12px);
  }
}

/* Force Top3 to stay in ONE ROW on phones (override base mobile column styles) */
@media (max-width: 520px) {
  .lb-wrap {
    flex-direction: row !important;
    flex-wrap: nowrap !important;
    justify-content: center;
    align-items: flex-end !important;
    gap: 8px;
  }

  .podium {
    padding: 10px 8px 10px;
  }

  .podium.rank-1 {
    order: 0 !important;
    transform: translateY(-10px) !important;
  }

  .podium.rank-2 {
    order: 0 !important;
  }

  .podium.rank-3 {
    order: 0 !important;
  }

  .avatar {
    width: 58px;
    height: 58px;
    border-radius: 18px;
    margin: 10px auto 8px;
  }

  .rank-badge {
    width: 34px;
    height: 34px;
    border-radius: 14px;
    top: 10px;
    left: 10px;
  }

  .podium .gid {
    font-size: .84rem;
    letter-spacing: .2px;
  }

  .podium .bal {
    padding: 8px 8px;
    border-radius: 14px;
    font-size: .85rem;
  }
}

@media (max-width: 380px) {
  .podium {
    width: 31vw;
  }

  .podium.rank-1 {
    transform: translateY(-10px);
  }
}

/* FAQ: fix dark text (questions) on dark theme */
.acc-btn {
  color: rgba(255, 255, 255, .92) !important;
}

.acc-q {
  color: rgba(255, 255, 255, .92) !important;
}

.acc-btn i {
  color: var(--accent);
}

/* Footer: reduce height */
.site-footer {
  padding: 18px 0 20px !important;
}

.site-footer .footer-grid {
  row-gap: 14px;
}

/* =========================
   FIX: Footer must be DARK
   ========================= */
.site-footer {
  background: rgba(6, 8, 18, .72) !important;
  border-top: 1px solid rgba(255, 255, 255, .10) !important;
  backdrop-filter: blur(16px);
}

.footer-note {
  color: rgba(255, 255, 255, .76) !important;
}

.site-footer a {
  color: rgba(34, 211, 238, .92) !important;
  /* accent */
}

.site-footer a:hover {
  text-decoration: underline;
}

/* trust badges inside footer should not be white */
.trust-badge {
  background: rgba(255, 255, 255, .06) !important;
  border: 1px solid rgba(255, 255, 255, .12) !important;
  box-shadow: 0 18px 55px rgba(0, 0, 0, .30) !important;
}

.trust-badge img {
  filter: brightness(.95) contrast(1.05);
}

/* =========================================
   Dark Fix: Mobile Burger + Drawer (centered)
   ========================================= */

/* Burger button (mobile) */
.burger {
  background: rgba(6, 8, 18, .62) !important;
  border: 1px solid rgba(255, 255, 255, .14) !important;
  box-shadow: 0 18px 55px rgba(0, 0, 0, .45) !important;
}

.burger i {
  color: rgba(255, 255, 255, .92) !important;
}

/* Drawer overlay stays dark */
.drawer {
  background: rgba(2, 8, 23, .62) !important;
  backdrop-filter: blur(10px) !important;
}

/* Center the panel (instead of top-right) */
.drawer-panel {
  left: 50% !important;
  top: 50% !important;
  right: auto !important;
  transform: translate(-50%, -50%) !important;

  width: min(380px, calc(100% - 28px)) !important;
  border-radius: 22px !important;

  background: rgba(10, 14, 30, .78) !important;
  border: 1px solid rgba(255, 255, 255, .12) !important;
  box-shadow: 0 26px 85px rgba(0, 0, 0, .55) !important;
  overflow: hidden;
}

/* Header inside drawer */
.drawer-head {
  border-bottom: 1px solid rgba(255, 255, 255, .10) !important;
}

.drawer-head * {
  color: rgba(255, 255, 255, .92) !important;
}

/* Links inside drawer */
.drawer-links a {
  color: rgba(255, 255, 255, .90) !important;
  background: transparent !important;
  border: 1px solid transparent;
}

.drawer-links a:hover {
  background: rgba(255, 255, 255, .06) !important;
  border-color: rgba(255, 255, 255, .10) !important;
}

/* CTA buttons inside drawer (Login / Register) */
.drawer-cta .btn {
  background: rgba(255, 255, 255, .06) !important;
  border: 1px solid rgba(255, 255, 255, .14) !important;
  color: rgba(255, 255, 255, .92) !important;
  box-shadow: 0 16px 45px rgba(0, 0, 0, .35) !important;
}

.drawer-cta .btn:hover {
  background: rgba(255, 255, 255, .10) !important;
}

.drawer-cta .btn-primary {
  background: linear-gradient(135deg, rgba(59, 130, 246, .95), rgba(168, 85, 247, .95)) !important;
  border-color: rgba(255, 255, 255, .18) !important;
  color: #fff !important;
}

/* If one of the buttons is .btn-ghost (often Login), keep it visible */
.drawer-cta .btn-ghost {
  background: rgba(34, 211, 238, .10) !important;
  border-color: rgba(34, 211, 238, .22) !important;
  color: rgba(34, 211, 238, .95) !important;
}

/* Make close icon (if any) visible in dark */
.drawer-head button,
.drawer-head .btn,
.drawer-head i {
  color: rgba(255, 255, 255, .90) !important;
}