:root {
  /* Фоны */
  --bg-primary:       #1a1f2e;   /* основной тёмно-синий фон */
  --bg-secondary:     #242938;   /* карточки, боковые панели */
  --bg-tertiary:      #2d3347;   /* hover-состояния, строки таблиц */
  --bg-header:        #1c2133;   /* хедер */
  --bg-nav:           #111521;   /* верхняя навигация */
  --bg-footer:        #151826;   /* футер */

  /* Акцентный цвет — основной бренд */
  --accent-primary:   #1e88e5;   /* синий CTA */
  --accent-hover:     #1976d2;   /* hover для синих кнопок */

  /* Акцентный цвет — вторичный */
  --accent-orange:    #f5a623;   /* промо-баннеры */
  --accent-yellow:    #fce974;   /* иконки */
  --accent-red:       #e53935;   /* live-метка */
  --accent-green:     #43a047;   /* выигрыш */

  /* Текст */
  --text-primary:     #ffffff;
  --text-secondary:   #b0b8c8;
  --text-muted:       #6b7590;
  --text-link:        #64b5f6;

  /* Границы */
  --border-primary:   #2e3549;
  --border-hover:     #3d4560;

  /* Градиенты */
  --gradient-hero: linear-gradient(135deg, #1a237e 0%, #0d47a1 50%, #1565c0 100%);
  --gradient-promo: linear-gradient(90deg, #e65100 0%, #f57c00 100%);
  
  /* Шрифты */
  --font-xs:    11px;
  --font-sm:    12px;
  --font-base:  13px;
  --font-md:    14px;
  --font-lg:    16px;
  --font-xl:    18px;
  --font-2xl:   22px;
  --font-3xl:   28px;
  --font-hero:  36px;
}

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

body {
  font-family: 'Cairo', 'Noto Sans Arabic', 'Tahoma', 'Arial Unicode MS', Arial, sans-serif;
  background-color: var(--bg-primary);
  color: var(--text-primary);
  direction: rtl;
  line-height: 1.6;
  overflow-x: hidden;
}

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

ul {
  list-style: none;
}

/* HEADER */
.site-header {
  height: 52px;
  background-color: var(--bg-header);
  box-shadow: 0 2px 8px rgba(0,0,0,0.4);
  position: sticky;
  top: 0;
  z-index: 1000;
  display: flex;
  align-items: center;
  padding: 0 16px;
}

.header-logo {
  margin-inline-end: auto;
  height: 32px;
}

.header-auth {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-inline-start: auto;
}

.lang-switcher {
  display: flex;
  align-items: center;
  gap: 4px;
  margin: 0 8px;
}

.lang-btn {
  color: var(--text-secondary);
  font-size: var(--font-sm);
  font-weight: 700;
  text-decoration: none;
  padding: 4px 8px;
  border-radius: 4px;
  border: 1px solid var(--border-primary);
  transition: all 0.2s;
}

.lang-btn:hover, .lang-btn.active {
  color: #fff;
  border-color: var(--accent-primary);
  background: rgba(30, 136, 229, 0.1);
}

.btn-register {
  background: var(--accent-primary);
  color: #fff;
  border: none;
  border-radius: 4px;
  padding: 8px 18px;
  font-size: var(--font-base);
  font-weight: 700;
  font-family: 'Cairo', sans-serif;
  cursor: pointer;
  transition: background 0.2s;
}

.btn-register:hover {
  background: var(--accent-hover);
}

.btn-login {
  background: transparent;
  color: #fff;
  border: 1px solid rgba(255,255,255,0.25);
  border-radius: 4px;
  padding: 7px 16px;
  font-size: var(--font-base);
  font-weight: 600;
}

.btn-login:hover {
  border-color: rgba(255,255,255,0.6);
}

/* TOP NAV */
.top-nav {
  height: 40px;
  background-color: var(--bg-nav);
  border-bottom: 1px solid var(--border-primary);
  display: flex;
  overflow-x: auto;
  padding: 0 16px;
}

.top-nav::-webkit-scrollbar {
  display: none;
}

.nav-item {
  color: var(--text-secondary);
  font-size: var(--font-base);
  font-weight: 600;
  padding: 0 14px;
  height: 40px;
  display: flex;
  align-items: center;
  border-bottom: 2px solid transparent;
  transition: all 0.2s;
  white-space: nowrap;
  position: relative;
}

.nav-item:hover, .nav-item--active {
  color: #ffffff;
  border-bottom-color: var(--accent-primary);
}

/* FLOATING MENU (MOBILE & BOTTOM) */
.floating-menu {
  position: fixed;
  bottom: 20px;
  left: 50%;
  transform: translateX(-50%);
  background: var(--bg-secondary);
  border: 1px solid var(--border-primary);
  border-radius: 30px;
  display: flex;
  padding: 8px 16px;
  gap: 20px;
  box-shadow: 0 10px 25px rgba(0,0,0,0.5);
  z-index: 1001;
  backdrop-filter: blur(10px);
}

.floating-item {
  color: var(--text-secondary);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
  font-size: var(--font-xs);
  transition: 0.2s;
}

.floating-item i {
  font-size: 18px;
}

.floating-item:hover, .floating-item.active {
  color: var(--accent-primary);
}

.floating-action {
  background: var(--accent-orange);
  color: #fff;
  border-radius: 50%;
  width: 40px;
  height: 40px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-top: -15px;
  box-shadow: 0 4px 10px rgba(245, 166, 35, 0.4);
  font-size: 20px;
}

/* LAYOUT */
.page-wrapper {
  max-width: 1440px;
  margin: 0 auto;
  padding: 16px 8px 80px; /* padding-bottom for floating menu */
}

.main-layout {
  display: grid;
  grid-template-columns: 1fr;
  gap: 16px;
}

/* SIDEBAR */
.sports-sidebar {
  display: none;
  background: var(--bg-secondary);
  border-radius: 6px;
  overflow: hidden;
  position: sticky;
  top: 108px;
}

@media (min-width: 1024px) {
  .sports-sidebar {
    display: block;
  }
}

.sports-sidebar__item {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 9px 14px;
  color: #c0c8d8;
  font-size: var(--font-base);
  border-bottom: 1px solid var(--border-primary);
  transition: all 0.15s;
}

.sports-sidebar__item:hover, .sports-sidebar__item--active {
  background: var(--bg-tertiary);
  color: #fff;
}

/* HERO BANNER */
.hero-banner {
  background: var(--gradient-hero);
  border-radius: 8px;
  padding: 24px;
  position: relative;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 16px;
  margin-bottom: 24px;
}

@media (min-width: 768px) {
  .hero-banner {
    padding: 32px 40px;
    flex-direction: row;
    align-items: center;
    justify-content: space-between;
  }
}

.hero-banner__content {
  max-width: 600px;
  z-index: 2;
}

.hero-banner__badge {
  background: var(--accent-orange);
  color: #fff;
  font-size: var(--font-xs);
  font-weight: 700;
  padding: 3px 8px;
  border-radius: 3px;
  display: inline-block;
  margin-bottom: 12px;
  text-transform: uppercase;
}

.hero-banner__title {
  font-size: var(--font-2xl);
  font-weight: 900;
  color: #fff;
  line-height: 1.3;
  margin-bottom: 16px;
}

@media (min-width: 768px) {
  .hero-banner__title {
    font-size: var(--font-3xl);
  }
}

.hero-banner__cta {
  background: var(--accent-orange);
  color: #fff;
  border: none;
  border-radius: 4px;
  padding: 12px 28px;
  font-size: var(--font-md);
  font-weight: 700;
  cursor: pointer;
  transition: 0.2s;
  font-family: inherit;
}

.hero-banner__cta:hover {
  background: #e65100;
  transform: translateY(-2px);
}

/* AGENTS GRID */
.agents-section {
  margin-bottom: 32px;
}

.section-title {
  font-size: var(--font-2xl);
  font-weight: 700;
  color: #fff;
  margin-bottom: 20px;
  display: flex;
  align-items: center;
  gap: 10px;
}

.section-title i {
  color: var(--accent-primary);
}

.agents-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 16px;
}

.agent-card {
  background: var(--bg-secondary);
  border: 1px solid var(--border-primary);
  border-radius: 8px;
  padding: 16px;
  transition: all 0.2s;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.agent-card:hover {
  transform: translateY(-4px);
  border-color: var(--accent-primary);
  box-shadow: 0 4px 12px rgba(0,0,0,0.3);
}

.agent-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.agent-name {
  font-size: var(--font-lg);
  font-weight: 700;
  color: #fff;
  display: flex;
  align-items: center;
  gap: 8px;
}

.verified-badge {
  color: var(--accent-primary);
  font-size: 14px;
}

.agent-city {
  background: var(--bg-tertiary);
  color: var(--text-secondary);
  font-size: var(--font-xs);
  padding: 3px 8px;
  border-radius: 12px;
}

.agent-stats {
  display: flex;
  justify-content: space-between;
  border-top: 1px solid var(--border-primary);
  border-bottom: 1px solid var(--border-primary);
  padding: 12px 0;
}

.stat-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
}

.stat-value {
  color: #fff;
  font-weight: 700;
  font-size: var(--font-md);
}

.stat-label {
  color: var(--text-muted);
  font-size: var(--font-xs);
}

.agent-extra-info {
  display: flex;
  justify-content: space-between;
  margin-top: 12px;
  padding-top: 12px;
  border-top: 1px dashed rgba(255,255,255,0.1);
  font-size: var(--font-sm);
  color: var(--text-secondary);
}

.info-row {
  display: flex;
  align-items: center;
  gap: 6px;
}

.info-row strong {
  color: #fff;
}

/* SEO TEXT BLOCKS */
.seo-block {
  background: var(--bg-secondary);
  border-radius: 8px;
  padding: 24px 28px;
  margin-bottom: 24px;
  color: var(--text-secondary);
  font-size: var(--font-md);
  line-height: 1.8;
  border-right: 4px solid var(--accent-primary);
}

.seo-block h1, .seo-block h2, .seo-block h3 {
  color: #fff;
  margin-bottom: 16px;
  font-weight: 700;
}

.seo-block h1 {
  font-size: var(--font-2xl);
  border-bottom: 1px solid var(--border-primary);
  padding-bottom: 12px;
}

.seo-block h2 {
  font-size: var(--font-xl);
  margin-top: 24px;
}

.seo-block h3 {
  font-size: var(--font-lg);
  margin-top: 20px;
}

.seo-block p {
  margin-bottom: 16px;
  text-align: justify;
}

.seo-block ul {
  margin-bottom: 16px;
  padding-inline-start: 20px;
}

.seo-block li {
  margin-bottom: 8px;
  position: relative;
}

.seo-block li::before {
  content: "•";
  color: var(--accent-primary);
  position: absolute;
  right: -15px;
  font-size: 20px;
  line-height: 1;
}

.seo-block strong {
  color: #fff;
}

/* GALLERY */
.gallery-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
  gap: 16px;
  margin-bottom: 32px;
}

.gallery-item {
  border-radius: 8px;
  overflow: hidden;
  border: 1px solid var(--border-primary);
  aspect-ratio: 9/16;
  position: relative;
  background: var(--bg-tertiary);
}

.gallery-item img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.3s;
}

.gallery-item:hover img {
  transform: scale(1.05);
}

.gallery-caption {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  background: rgba(0,0,0,0.8);
  color: #fff;
  padding: 8px;
  font-size: var(--font-sm);
  text-align: center;
}

/* FOOTER */
.site-footer {
  background: var(--bg-footer);
  border-top: 1px solid var(--border-primary);
  padding: 40px 16px 20px;
  margin-top: 40px;
}

.footer-grid {
  max-width: 1440px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 32px;
  border-bottom: 1px solid var(--border-primary);
  padding-bottom: 32px;
}

.footer-col__title {
  font-size: var(--font-base);
  font-weight: 700;
  color: #fff;
  text-transform: uppercase;
  margin-bottom: 16px;
}

.footer-col__link {
  display: block;
  color: var(--text-muted);
  font-size: var(--font-sm);
  margin-bottom: 10px;
  transition: color 0.15s;
}

.footer-col__link:hover {
  color: var(--text-secondary);
}

/* NOTIFICATION */
.notification {
  position: fixed;
  top: -150px;
  left: 50%;
  transform: translateX(-50%);
  background: var(--accent-green);
  color: #fff;
  padding: 16px 32px;
  border-radius: 8px;
  font-weight: 700;
  font-size: var(--font-md);
  box-shadow: 0 4px 15px rgba(0,0,0,0.3);
  z-index: 9999;
  transition: top 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
  display: flex;
  align-items: center;
  gap: 12px;
  width: max-content;
  max-width: 90vw;
}

.notification.show {
  top: 20px;
}

.spinner {
  width: 20px;
  height: 20px;
  border: 3px solid rgba(255,255,255,0.3);
  border-radius: 50%;
  border-top-color: #fff;
  animation: spin 1s ease-in-out infinite;
}

@keyframes spin {
  to { transform: rotate(360deg); }
}

/* FEATURE GRID (TRUST) */
.feature-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
  gap: 16px;
  margin-bottom: 24px;
}

.feature-card {
  background: var(--bg-tertiary);
  border: 1px solid var(--border-primary);
  border-radius: 8px;
  padding: 20px;
  display: flex;
  flex-direction: column;
  gap: 12px;
  transition: transform 0.2s;
}

.feature-card:hover {
  transform: translateY(-4px);
  border-color: var(--accent-primary);
}

.feature-icon {
  width: 48px;
  height: 48px;
  background: rgba(30, 136, 229, 0.15);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--accent-primary);
  font-size: 24px;
}

.feature-card h4 {
  color: #fff;
  font-size: var(--font-lg);
  font-weight: 700;
  margin: 0;
}

.feature-card p {
  font-size: var(--font-sm);
  margin: 0;
  line-height: 1.5;
}

.warning-box {
  background: rgba(229, 57, 53, 0.1);
  border-right: 4px solid var(--accent-red);
  padding: 16px;
  border-radius: 8px;
  display: flex;
  gap: 16px;
  align-items: flex-start;
  color: #fff;
}

.warning-box i {
  color: var(--accent-red);
  font-size: 24px;
  margin-top: 4px;
}

/* FAQ ACCORDION */
.faq-accordion {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.faq-item {
  background: var(--bg-tertiary);
  border: 1px solid var(--border-primary);
  border-radius: 8px;
  overflow: hidden;
}

.faq-question {
  padding: 16px 20px;
  color: #fff;
  font-weight: 700;
  font-size: var(--font-lg);
  cursor: pointer;
  list-style: none; /* Hide default arrow */
  position: relative;
  transition: background 0.2s;
}

.faq-question::-webkit-details-marker {
  display: none; /* Hide Safari arrow */
}

.faq-question:hover {
  background: rgba(255,255,255,0.05);
}

.faq-question::after {
  content: '\f078';
  font-family: 'Font Awesome 6 Free';
  font-weight: 900;
  position: absolute;
  left: 20px;
  top: 50%;
  transform: translateY(-50%);
  color: var(--accent-primary);
  transition: transform 0.3s;
}

details[open] .faq-question::after {
  transform: translateY(-50%) rotate(180deg);
}

.faq-answer {
  padding: 0 20px 20px;
  color: var(--text-secondary);
  font-size: var(--font-md);
  line-height: 1.6;
  border-top: 1px solid var(--border-primary);
  margin-top: 16px;
  padding-top: 16px;
}

/* PAYMENT GRID */
.payment-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 20px;
}

.payment-card {
  background: var(--bg-tertiary);
  border: 1px solid var(--border-primary);
  border-radius: 8px;
  padding: 20px;
}

.payment-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 16px;
  font-size: 24px;
  color: var(--text-muted);
}

.payment-badge {
  font-size: var(--font-xs);
  font-weight: 700;
  padding: 4px 10px;
  border-radius: 4px;
  color: #fff;
}

.cih-bg { background: #e31837; }
.wafa-bg { background: #f5a623; }
.attijari-bg { background: #d4a350; }

.payment-card h4 {
  color: #fff;
  font-size: var(--font-lg);
  margin-bottom: 8px;
}

.payment-card p {
  font-size: var(--font-sm);
  margin: 0;
}

/* GEO GRID */
.geo-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 16px;
}

@media (min-width: 768px) {
  .geo-grid {
    grid-template-columns: repeat(3, 1fr);
  }
}

.geo-card {
  background: var(--bg-tertiary);
  border-left: 3px solid var(--accent-orange);
  padding: 16px;
  border-radius: 8px;
  display: flex;
  gap: 16px;
  align-items: flex-start;
}

.geo-icon {
  background: rgba(245, 166, 35, 0.1);
  color: var(--accent-orange);
  width: 40px;
  height: 40px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 20px;
  flex-shrink: 0;
}

.geo-card h4 {
  color: #fff;
  margin-bottom: 6px;
}

.geo-card p {
  font-size: var(--font-sm);
  margin: 0;
}

/* HIGHLIGHT BOX (RATES) */
.highlight-box {
  background: linear-gradient(90deg, rgba(67, 160, 71, 0.1) 0%, transparent 100%);
  border: 1px solid var(--accent-green);
  border-radius: 8px;
  padding: 24px;
  display: flex;
  gap: 24px;
  align-items: center;
}

.highlight-icon {
  font-size: 48px;
  font-weight: 900;
  color: var(--accent-green);
  line-height: 1;
}

.highlight-content h4 {
  color: #fff;
  font-size: var(--font-xl);
  margin-bottom: 8px;
}

.highlight-content p {
  margin: 0;
  font-size: var(--font-md);
}

/* PROCESS LIST (WITHDRAWALS) */
.process-list {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.process-item {
  display: flex;
  align-items: center;
  gap: 16px;
  background: var(--bg-tertiary);
  padding: 12px 20px;
  border-radius: 8px;
}

.process-step {
  width: 32px;
  height: 32px;
  background: var(--accent-primary);
  color: #fff;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  flex-shrink: 0;
}

.process-text {
  color: #fff;
}

/* STEPS GRID (PARTNERSHIP) */
.steps-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 16px;
}

.step-card {
  background: var(--bg-tertiary);
  border: 1px solid var(--border-primary);
  border-radius: 8px;
  padding: 24px;
  text-align: center;
  position: relative;
  overflow: hidden;
}

.step-number {
  position: absolute;
  top: -10px;
  right: -10px;
  font-size: 64px;
  font-weight: 900;
  color: rgba(255,255,255,0.03);
  line-height: 1;
}

.step-card h4 {
  color: #fff;
  margin-bottom: 12px;
  font-size: var(--font-lg);
  position: relative;
  z-index: 2;
}

.step-card p {
  font-size: var(--font-sm);
  margin: 0;
  position: relative;
  z-index: 2;
}

@media (max-width: 480px) {
  .btn-login, .btn-register {
    padding: 6px 10px;
    font-size: 12px;
  }
  .header-auth {
    gap: 4px;
  }
  .lang-switcher {
    margin: 0 4px;
  }
  .site-header {
    padding: 0 8px;
  }
}
