/* ==========================================================================
   1. KOMPONENT CSS FAYLLARININ İMPORTU (HƏMİŞƏ ƏN ÜSTDƏ OLMALIDIR)
   ========================================================================== */

/* ==========================================================================
   2. QLOBAL DƏYİŞƏNLƏR VƏ BAZA TƏNZİMLƏMƏLƏRİ
   ========================================================================== */
:root {
  --primary-bg: #1c44a2;
  --dark-bg: #111c33;
  --navbar-bg: rgba(15, 23, 42, 0.85);
  --card-bg: #0f172abf;
  --gold: #F80505;
  --gold-hover: #c50404;
  --text-main: #ffffff;
  --text-muted: #CBD5E1;
}

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

html {
  scroll-behavior: smooth;
  width: 100%;
  overflow-x: hidden; 
  font-size: 16px;
}

body {
  font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
  background: var(--primary-bg) !important;
  background-image: none !important; /* Arxa fon şəklinin dublikatlaşmasının qarşısını alır */
  color: var(--text-main);
  width: 100%;
  overflow-x: hidden; 
}

main {
  width: 100%;
  overflow-x: hidden; 
  background-image: none !important;
}

section {
  padding: 80px 40px;
  text-align: center;
  scroll-margin-top: 80px;
}

section h2 {
  font-size: clamp(22px, 4vw, 42px);
  margin-bottom: 35px;
}

/* ==========================================================================
   3. ORTAQ DÜYMƏ VƏ KART STİLLƏRİ
   ========================================================================== */
.btn-gold,
.btn-outline {
  display: inline-flex; 
  align-items: center;
  justify-content: center;
  transition: all 0.3s ease;
  text-decoration: none;
  padding: 15px 35px;
  border-radius: 8px;
  font-weight: 600;
  cursor: pointer;
}

.btn-gold {
  background: var(--gold);
  color: #ffffff;
  border: none;
}

.btn-outline {
  border: 2px solid var(--text-main);
  color: var(--text-main);
  background: transparent;
}

.btn-gold:hover {
  transform: translateY(-2px);
  background: var(--gold-hover);
  box-shadow: 0 10px 25px rgba(248, 5, 5, 0.3);
}

.btn-outline:hover {
  transform: translateY(-2px);
  background: var(--text-main);
  color: var(--dark-bg);
}

.card {
  background: var(--card-bg);
  padding: 30px;
  border-radius: 12px;
  color: var(--text-main);
  transition: all 0.3s ease;
  cursor: pointer;
  box-shadow: 0 10px 30px rgba(0,0,0,0.25);
}

.card:hover {
  transform: translateY(-12px) scale(1.02);
  background: var(--primary-bg);
  box-shadow: 0 20px 40px rgba(248, 5, 5, 0.25); 
}

.card h3 {
  color: var(--text-main);
  margin-bottom: 10px;
}

/* ==========================================================================
   4. INPUT VƏ FORM DÜZƏLTMƏLƏRİ (MESAJ ALANI VƏ PLACEHOLDER)
   ========================================================================== */
input, textarea, select {
  color: #1e293b !important;
  background-color: #ffffff !important;
  font-family: inherit;
  font-size: 15px;
}

input::placeholder, 
textarea::placeholder {
  color: #64748b !important;
  opacity: 1;
}

/* ==========================================================================
   5. MODAL STILLƏRİ (KALKULYATOR, SERTİFİKAT VƏ MÜƏLLİM)
   ========================================================================== */
#calc-modal-container,
#cert-modal-container,
#modal-container,
.modal {
  position: fixed;
  inset: 0;
  width: 100%;
  height: 100vh;
  height: 100dvh;
  background: rgba(15, 23, 42, 0.85);
  backdrop-filter: blur(8px);
  display: none;
  align-items: center;
  justify-content: center;
  z-index: 99999;
  padding: 20px;
  box-sizing: border-box;
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
}

.modal.show { 
  display: flex !important;
  opacity: 1; 
  pointer-events: auto; 
}

#calc-modal-container > div,
#cert-modal-container > div,
#modal-container > div,
.calc-modal,
.modal-content {
  margin: auto;
  max-height: 85vh;
  max-height: 85dvh;
  max-width: 600px;
  width: 100%;
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
  box-sizing: border-box;
}

.calculator-modal-content,
.modal-content {
  background: var(--dark-bg);
  padding: 35px;
  border-radius: 16px;
  width: 100%;
  max-width: 650px; 
  border: 1px solid rgba(255, 255, 255, 0.1) !important;
  box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.5) !important;
  display: flex;
  flex-direction: column; 
  gap: 20px;
  position: relative;
  box-sizing: border-box;
}

.calc-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  border-bottom: 1px solid #2e3d5c;
  padding-bottom: 15px;
}

.calc-header h3,
.modal-header-content h2,
#modalTitle { 
  font-size: 22px; 
  color: #ffffff; 
  margin: 0; 
}

.close-calc,
.close-modal { 
  position: absolute; 
  top: 18px; 
  right: 22px; 
  font-size: 28px; 
  color: var(--text-muted); 
  cursor: pointer; 
  transition: 0.2s;
  background: none;
  border: none;
  line-height: 1;
  z-index: 10;
}

.close-calc:hover,
.close-modal:hover { 
  color: #ffffff; 
}

.modal-header-content p,
#modalDescription { 
  color: var(--text-muted); 
  font-size: 15px; 
  line-height: 1.6; 
  margin: 0; 
}

.calc-tabs {
  display: flex;
  gap: 10px;
  width: 100%;
}

.calc-tabs .tab-btn {
  flex: 1;
  padding: 12px;
  background: #0f172a;
  border: 1px solid #334155;
  color: #fff;
  cursor: pointer;
  border-radius: 6px;
  font-weight: 500;
  transition: all 0.3s ease;
}

.calc-tabs .tab-btn.active {
  background: var(--gold);
  color: #fff;
  font-weight: bold;
  border-color: var(--gold);
}

.input-grid {
  display: grid;
  grid-template-columns: 1fr 1fr; 
  gap: 15px;
  width: 100%;
  text-align: left;
  box-sizing: border-box;
}

.input-group {
  display: flex;
  flex-direction: column;
  gap: 5px;
}

.input-group label {
  font-size: 14px;
  color: var(--text-muted);
}

.input-group input, 
.input-group select {
  width: 100%;
  padding: 12px;
  border-radius: 6px;
  border: 1px solid #334155;
  background: #ffffff;
  color: #1e293b;
  font-size: 14px;
  box-sizing: border-box;
}

.calc-result {
  margin-top: 15px;
  padding: 15px;
  background: #0f172a;
  border-radius: 6px;
  text-align: left;
  border-left: 4px solid var(--gold);
  width: 100%;
  box-sizing: border-box;
}

/* Müəllim Kartı Stilləri */
.teacher-card {
  width: 100%; 
  padding: 20px; 
  border-radius: 14px; 
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.12); 
  display: flex; 
  align-items: center; 
  gap: 20px; 
  box-sizing: border-box;
  text-align: left;
}

.teacher-card img { 
  width: 90px !important; 
  height: 90px !important; 
  border-radius: 50%; 
  object-fit: cover !important; 
  border: 3px solid var(--gold); 
  flex-shrink: 0;
}

.teacher-info {
  display: flex;
  flex-direction: column;
  gap: 6px;
  width: 100%;
}

.teacher-card h3 { 
  font-size: 19px; 
  color: #fff; 
  margin: 0; 
  font-weight: 700;
}

.teacher-card p { 
  font-size: 14px; 
  color: var(--text-muted); 
  margin: 0; 
}

#modalCloseBtn, 
.modal-content .btn-gold { 
  background-color: var(--gold) !important;
  color: #ffffff !important;
  width: 100%;
  padding: 14px;
  border-radius: 8px;
  text-align: center;
  font-weight: bold;
  font-size: 16px;
  border: none;
  cursor: pointer;
  box-sizing: border-box;
  transition: opacity 0.3s ease;
  margin-top: 10px;
}

/* ==========================================================================
   6. DİL DƏYİŞDİRİCİ DÜYMƏLƏR
   ========================================================================== */
.lang-switcher {
  display: flex;
  align-items: center;
  gap: 6px;
}

.lang-btn {
  background: transparent;
  color: #ffffff;
  border: 1px solid #475569;
  padding: 4px 10px;
  cursor: pointer;
  border-radius: 4px;
  font-weight: 600;
  font-size: 14px;
  transition: all 0.2s ease-in-out;
}

.lang-btn.active {
  border-color: var(--gold) !important;
  background: var(--gold);
  color: #ffffff !important;
}

/* ==========================================================================
   7. RESPONSIVE / MOBİL VƏ PLANŞET NİZAMLANMALARI
   ========================================================================== */
h1 { font-size: clamp(26px, 5vw, 44px) !important; line-height: 1.3 !important; }
h2 { font-size: clamp(20px, 4vw, 32px) !important; line-height: 1.35 !important; }
h3 { font-size: clamp(17px, 3vw, 24px) !important; line-height: 1.4 !important; }

@media (max-width: 1024px) {
  section { padding: 50px 24px; }
}

@media (max-width: 600px) {
  /* Bütün bölmələr üçün ümumi daxili boşluqlar */
  section { 
    padding: 35px 18px !important;
    min-height: auto !important;
    display: flex !important;
    flex-direction: column !important;
    align-items: center !important;
    justify-content: center !important;
    box-sizing: border-box !important;
    text-align: center !important;
  }

  section h2 {
    margin-bottom: 20px !important;
    text-align: center !important;
  }

  /* YALNIZCA İLK SAYFA (HERO) TAM EKRANI TUTUR */
  #hero, 
  section:first-of-type, 
  .hero {
    min-height: 100vh !important;
    min-height: 100dvh !important;
    display: flex !important;
    flex-direction: column !important;
    justify-content: center !important;
    align-items: center !important;
    padding-top: 80px !important;
    padding-bottom: 20px !important;
  }

  /* YALNIZ MOBİL ÜÇÜN QALEREYA VƏ KARUSEL BOŞLUQLARININ MİNİMUMA ENDİRİLMƏSİ */
  #gallery, 
  .gallery, 
  .gallery-section {
    padding-top: 15px !important;
    padding-bottom: 15px !important;
    padding-left: 10px !important;
    padding-right: 10px !important;
  }

  #gallery h2, 
  .gallery h2 {
    margin-bottom: 10px !important;
  }

  .gallery-container, 
  .gallery-grid, 
  .gallery-wrapper,
  .swiper,
  .swiper-container {
    width: 100% !important;
    max-width: 100% !important;
    margin: 0 auto !important;
    padding-left: 0 !important;
    padding-right: 0 !important;
    gap: 8px !important;
  }

  .swiper-slide, 
  .gallery-slide {
    width: 85% !important;
  }

  .swiper-slide img, 
  .gallery-slide img {
    width: 100% !important;
    height: auto !important;
    max-height: 320px !important;
    object-fit: cover !important;
    border-radius: 12px !important;
  }

  .swiper-pagination {
    position: relative !important;
    margin-top: 8px !important;
    bottom: 0 !important;
  }

  /* KARTLAR VƏ BİLƏŞƏNLƏRİN SİMETRİK ORTALANMASI */
  .container, .grid, .card-container, .cards-wrapper {
    width: 100% !important;
    display: flex !important;
    flex-direction: column !important;
    align-items: center !important;
    justify-content: center !important;
    gap: 16px !important;
  }

  .card {
    width: 100% !important;
    max-width: 400px !important;
    margin: 0 auto !important;
    text-align: center !important;
  }

  /* FOOTER VƏ SƏHİFƏLƏR / ƏLAQƏ HİSSƏSİNİN MƏRKƏZLƏŞDİRİLMƏSİ */
  footer, .footer, .footer-content, .footer-section, .footer-col {
    text-align: center !important;
    display: flex !important;
    flex-direction: column !important;
    align-items: center !important;
    justify-content: center !important;
  }

  footer ul, .footer ul {
    padding: 0 !important;
    margin: 0 auto 15px auto !important;
    list-style: none !important;
    text-align: center !important;
  }

  footer ul li, .footer ul li {
    text-align: center !important;
    margin-bottom: 8px !important;
  }

  footer ul li a, .footer ul li a {
    display: inline-block !important;
    text-align: center !important;
  }

  .footer-info, .contact-item {
    display: flex !important;
    flex-direction: column !important;
    align-items: center !important;
    justify-content: center !important;
    text-align: center !important;
  }

  /* FORM ELEMANLARI */
  .input-grid { grid-template-columns: 1fr; }
  .calc-tabs { flex-direction: column; }

  .teacher-card {
    flex-direction: column;
    text-align: center;
    padding: 20px 15px;
    align-items: center;
  }

  .teacher-info {
    align-items: center;
    text-align: center;
  }

  #calc-modal-container,
  #cert-modal-container,
  #modal-container,
  .modal {
    padding: 12px;
  }

  .calculator-modal-content,
  .modal-content {
    padding: 25px 18px;
  }

  .btn, .btn-gold, .btn-outline {
    width: 100%;
    max-width: 350px;
    padding: 12px 20px;
    margin: 0 auto;
  }
}

/* ===== header ===== */
/* ==========================================================================
   DESKTOP NAVBAR STİLLERİ
   ========================================================================== */
header, .header, .navbar {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  z-index: 9999;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.25);
  background: var(--navbar-bg, #0b1329); 
  backdrop-filter: blur(12px);
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
  box-sizing: border-box;
}

.navbar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  width: 100%;
  max-width: 1750px;
  margin: 0 auto;
  padding: 0 35px;   
  height: 95px;
  gap: 24px;
}

.logo {
  display: flex;
  align-items: center;
  text-decoration: none;
  flex-shrink: 0;
}

.logo img {
  height: 48px;
  width: auto;
  object-fit: contain;
  transition: transform 0.3s ease;
}

.nav-menu {
  display: flex;
  align-items: center;
  justify-content: center;
  flex-grow: 1;
  margin: 0;
}

.menu {
  display: flex;
  gap: 24px;
  list-style: none;
  align-items: center;
  margin: 0;
  padding: 0;
  justify-content: center;
}

.menu a {
  color: var(--text-main, #ffffff);
  text-decoration: none;
  font-size: 15px;
  font-weight: 500;
  white-space: nowrap;
  transition: color 0.3s ease;
}

.menu a:hover {
  color: #FF0000;
}

/* Əməliyyat Düymələri və Dil Seçimi */
.nav-actions {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-shrink: 0;
}

.calc-tab-btn, .cert-tab-btn {
  padding: 9px 16px !important;
  border-radius: 6px;
  background: #FF0000;
  border: 1px solid #FF0000 !important;
  color: #ffffff !important;
  text-decoration: none;
  font-size: 14px !important;
  font-weight: 600 !important;
  display: inline-flex !important;
  align-items: center;
  justify-content: center;
  white-space: nowrap !important;
  box-sizing: border-box !important;
}

.lang-switcher {
  display: flex;
  gap: 6px;
  align-items: center;
  flex-shrink: 0;
}

.lang-btn {
  background: transparent;
  border: 1px solid rgba(255, 255, 255, 0.25);
  color: #ffffff;
  padding: 5px 10px;
  border-radius: 5px;
  cursor: pointer;
  font-size: 13px;
  font-weight: 700;
  transition: all 0.3s ease;
}

.lang-btn.active {
  color: #ffffff;
  background: #FF0000;
  border-color: #FF0000;
}

.menu-toggle {
  display: none !important;
}

/* ==========================================================================
   MOBİL VƏ TABLET RESPONSİV STİLLERİ
   ========================================================================== */
@media screen and (max-width: 1180px) {
  .navbar {
    height: 75px;
    padding: 0 20px;
  }

  .logo img {
    height: 38px !important;
  }

  .menu-toggle {
    display: flex !important;
    flex-direction: column !important;
    justify-content: space-between !important;
    width: 28px !important;
    height: 20px !important;
    background: transparent !important;
    border: none !important;
    cursor: pointer;
    padding: 0 !important;
    z-index: 10001;
  }

  .menu-toggle .bar {
    display: block !important;
    height: 3px !important;
    width: 100% !important;
    background-color: #ffffff !important;
    border-radius: 3px;
  }

  .nav-menu {
    display: none; 
    position: absolute;
    top: 75px;
    left: 0;
    width: 100%;
    max-height: 85vh;
    overflow-y: auto;
    background-color: #0b1329;
    flex-direction: column;
    align-items: center;
    padding: 25px 0 35px 0;
    margin: 0 !important;
    gap: 20px;
  }

  .nav-menu.active {
    display: flex !important;
  }

  .nav-menu ul.menu {
    flex-direction: column;
    width: 100%;
    padding: 0 24px;
    gap: 16px;
    margin-bottom: 10px;
  }

  .nav-actions {
    flex-direction: column;
    width: 100%;
    padding: 0 24px;
    gap: 12px;
  }

  /* MOBİLDƏ QIRMIZI DÜYMƏLƏRİN DÜZƏLİŞİ */
  .calc-tab-btn, 
  .cert-tab-btn {
    width: 100% !important;
    max-width: 280px !important; /* Çox enli olmaması üçün */
    padding: 12px 20px !important;
    font-size: 15px !important;
    white-space: nowrap !important;
    text-align: center !important;
    box-sizing: border-box !important;
    margin: 0 auto !important;
    border-radius: 8px !important;
  }

  .lang-switcher {
    margin-top: 8px !important;
    justify-content: center !important;
  }
}

/* ===== hero ===== */
/* ==========================================================================
   HERO / ƏSAS SƏHİFƏ BANNER STİLLERİ (HƏFİF ZOOMLANMIŞ)
   ========================================================================== */

.hero, #hero-component, #hero {
  /* Arxa plan şəklinə 108% zoom verərək çərçivə xəttlərini itiririk */
  background: linear-gradient(rgba(11, 19, 41, 0.80), rgba(11, 19, 41, 0.88)), 
              url("/images/seminar.png") no-repeat center center / 108% auto !important;
  
  position: relative;
  width: 100%;
  height: 100vh;
  height: 100dvh;
  margin: 0 !important;
  padding: 95px 20px 0 20px;
  
  display: flex !important;
  flex-direction: column !important;
  justify-content: center !important;
  align-items: center !important;
  text-align: center;
  box-sizing: border-box;
  overflow: hidden;
}

/* Əlavə layların yaranmasının qarşısı alınır */
.hero::before, #hero-component::before, #hero::before,
.hero::after, #hero-component::after, #hero::after {
  display: none !important;
  content: none !important;
  background: none !important;
}

.hero h1 {
  font-size: 42px;
  line-height: 1.35;
  max-width: 900px;
  margin: 0 auto 20px auto;
  color: #ffffff !important;
  background: none !important;
  -webkit-text-fill-color: initial !important;
  font-weight: 700;
  text-shadow: 0 4px 15px rgba(0, 0, 0, 0.6);
}

.hero p {
  font-size: 18px;
  line-height: 1.6;
  color: var(--text-muted, #e2e8f0);
  max-width: 750px;
  margin: 0 auto 32px auto;
  text-shadow: 0 2px 10px rgba(0, 0, 0, 0.5);
}

.buttons {
  display: flex;
  gap: 16px;
  justify-content: center;
  align-items: center;
}

/* Planşet Ekranı */
@media (max-width: 1024px) { 
  .hero, #hero-component, #hero {
    background-size: cover !important;
  }
  .hero h1 { 
    font-size: 34px; 
  } 
  .hero p {
    font-size: 16px;
  }
}

/* Mobil Ekranlar */
@media (max-width: 600px) { 
  .hero, #hero-component, #hero {
    padding-top: 75px !important;
    background-size: cover !important;
  }

  .hero h1 { 
    font-size: 26px !important;
    line-height: 1.35;
    margin-bottom: 16px;
  }

  .hero p {
    font-size: 14px;
    line-height: 1.5;
    margin-bottom: 24px;
  }

  .buttons {
    gap: 12px;
    width: 100%;
    max-width: 320px;
    flex-direction: column;
  }

  .buttons a, .buttons button {
    width: 100%;
    padding: 12px 18px;
    font-size: 15px;
  }
}

/* ===== services ===== */
.services {
  background: linear-gradient(rgba(95, 120, 180, 0.85), rgba(15, 23, 42, 0.9)), url("/images/back.png") no-repeat center center / cover;
  background-attachment: scroll;
}

.service-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 25px;
  margin-top: 25px;
}

.service-grid > div {
  transition: transform 0.3s ease, border-color 0.3s ease, box-shadow 0.3s ease;
  border: 1px solid transparent;
}

.service-grid > div:hover {
  border-color: #F80505;
  box-shadow: 0 10px 25px rgba(248, 5, 5, 0.25);
}

@media (max-width: 1024px) { 
  .service-grid { 
    grid-template-columns: repeat(2, 1fr); 
  } 
}

@media (max-width: 600px) { 
  .services {
    padding-top: 35px !important;
    padding-bottom: 35px !important;
  }

  .service-grid { 
    grid-template-columns: 1fr; 
    gap: 16px;
    margin-top: 18px;
  } 
}

/* ===== trainings ===== */
.trainings {
  background: linear-gradient(rgba(15, 23, 42, 0.85), rgba(15, 23, 42, 0.9)), url("/images/telimler.png") no-repeat center center;
  background-size: cover;
  background-attachment: fixed;
  
  min-height: 100vh;
  width: 100%;
  padding: 120px 40px 80px 40px;
  display: flex;
  flex-direction: column;
  justify-content: flex-start;
  align-items: center;
}

.trainings h2, .trainings .section-title {
  margin-top: 0 !important;
  margin-bottom: 50px;
  text-align: center;
}

.training-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 40px;
  width: 100%;
  max-width: 1400px;
  margin: 0 auto;
  align-items: stretch; /* Bütün kartları eyni hündürlükdə və eyni xətt üzrə saxlayır */
}

/* Birbaşa .card klassına müraciət edirik */
.training-grid .card {
  height: 100%;
  padding: 30px 25px;
  background: rgba(15, 23, 42, 0.6);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 12px;
  display: flex;
  flex-direction: column;
  justify-content: flex-start;
  transition: transform 0.3s ease, box-shadow 0.3s ease, border-color 0.3s ease;
  text-decoration: none !important;
  color: inherit !important;
  box-sizing: border-box;
}

.training-grid .card:hover {
  border-color: #F80505;
  box-shadow: 0 12px 30px rgba(248, 5, 5, 0.25);
  transform: translateY(-5px);
}

.training-grid .card h3 {
  margin-top: 0;
  margin-bottom: 15px;
  font-size: 1.25rem;
  color: #ffffff;
}

.training-grid .card p {
  margin: 0;
  font-size: 0.95rem;
  line-height: 1.6;
  color: #cbd5e1;
}

@media (max-width: 1024px) { 
  .trainings { padding: 100px 20px 60px 20px; }
  .training-grid { grid-template-columns: repeat(2, 1fr); gap: 30px; } 
}

@media (max-width: 600px) { 
  .trainings { padding: 90px 15px 50px 15px; }
  .training-grid { grid-template-columns: 1fr; gap: 25px; } 
}

/* ===== about ===== */
.about {
  /* Qovluq yolu iki pillə geriyə çıxarılaraq düzəldildi */
  background: linear-gradient(rgba(95, 120, 180, 0.85), rgba(15, 23, 42, 0.9)), url("/images/back.png") no-repeat center center / cover;
  background-attachment: -webkit-scroll;
  background-attachment: fixed;
}

.about-text {
  max-width: 800px;
  margin: 0 auto 60px auto;
  font-size: 18px;
  color: var(--text-muted);
  line-height: 1.7;
}

.stats {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 25px;
}

.stat-box {
  background: rgba(17, 28, 51, 0.7);
  backdrop-filter: blur(10px);
  border: 1px solid rgba(255,255,255,0.08);
  padding: 40px;
  border-radius: 12px;
  transition: 0.3s;
}

.stat-box:hover { 
  transform: translateY(-10px); 
  border-color: #F80505; /* Parlaq qırmızı çərçivə */
  box-shadow: 0 10px 25px rgba(248, 5, 5, 0.25); /* Parlaq qırmızı işıqlanma */
}

.stat-box h3 { font-size: 40px; color: var(--text-main); margin-bottom: 10px; }
.stat-box p { color: var(--text-muted); }

@media (max-width: 1024px) { .stats { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 600px) { .stats { grid-template-columns: 1fr; } }

/* ===== whyour ===== */
.whyour {
  background: var(--dark-bg);
}

.why-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 30px;
  margin-top: 40px;
}

.why-box {
  padding: 30px;
  background: rgba(15, 23, 42, 0.5);
  border-left: 4px solid var(--gold); 
  border-radius: 4px;
  text-align: left;
  transition: 0.3s;
  cursor: pointer;
}

.why-box:hover {
  transform: translateY(-12px) scale(1.02);
  background: var(--primary-bg);
  box-shadow: 0 20px 40px rgba(0,0,0,0.35);
  border-left-color: white; 
} 

.why-box h3 { margin-bottom: 10px; font-size: 20px; }
.why-box p { color: var(--text-muted); font-size: 15px; }

@media (max-width: 768px) { .why-grid { grid-template-columns: 1fr; } }

/* ===== testimonials ===== */
.testimonials {
  background: linear-gradient(rgba(95, 120, 180, 0.85), rgba(15, 23, 42, 0.9)), url("/images/back.png") no-repeat center center / cover;
  background-attachment: -webkit-scroll;
  background-attachment: fixed;
}

.testimonial-grid {
  display: flex;
  justify-content: center;
  gap: 30px;
  flex-wrap: wrap;
  margin-top: 40px;
}

.testimonial-card {
  background: rgba(15, 23, 42, 0.7);
  padding: 40px 30px;
  border-radius: 12px;
  max-width: 500px;
  flex: 1;
  min-width: 300px;
  text-align: left;
  border-top: 4px solid #F80505; /* Qırmızı kənar üst xətt */
  box-shadow: 0 10px 30px rgba(0,0,0,0.15);
}

.testimonial-card .review {
  font-style: italic;
  color: var(--text-muted);
  margin-bottom: 20px;
  font-size: 16px;
  line-height: 1.6;
}

.testimonial-card h4 { 
  color: var(--text-main); 
  font-size: 18px; 
  margin-bottom: 5px; 
}

/* Rəylərdəki vəzifə mətnləri ağ edildi */
.testimonial-card span { 
  color: #ffffff !important; 
  font-size: 14px; 
}

/* ===== team ===== */
.team {
  background: var(--dark-bg);
  padding: 80px 80px;
}

.team h2 { 
  margin-bottom: 50px; 
  font-size: 48px; 
  color: #ffffff;
}

.team-grid { 
  display: grid; 
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr)); 
  gap: 30px; 
}

.team-card {
  background: linear-gradient(rgba(95, 120, 180, 0.85), rgba(15, 23, 42, 0.9)), url("/images/back.png") no-repeat center center / cover;
  border-radius: 15px;
  padding: 25px;
  transition: .3s;
  text-align: center;
}

.team-card:hover { 
  transform: translateY(-8px); 
}

.team-card img {
  width: 140px;
  height: 140px;
  object-fit: cover;
  border-radius: 50%;
  margin-bottom: 15px;
}

/* Komanda üzvlərinin vəzifə mətni ağ edildi */
.position { 
  color: #ffffff !important; 
  font-weight: 600; 
  margin: 10px 0; 
}

/* ===== gallery ===== */
/* ==========================================================================
   MANDCO - Qalereya Bölməsi (Gallery Component CSS)
   ========================================================================== */

.gallery-section {
  padding: 80px 20px; 
  background: linear-gradient(rgba(95, 120, 180, 0.85), rgba(15, 23, 42, 0.95)), 
  url("/images/back.png") no-repeat center center / cover;
  background-attachment: fixed;
  position: relative;
}

.gallery-section h2 {
  text-align: center;
  margin-bottom: 50px;
  font-size: 48px;
  font-weight: 700;
  letter-spacing: 1px;
  background: linear-gradient(90deg, #ffffff, #ffffff);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

.gallery-wrapper {
  position: relative;
}

.gallery-slider {
  display: flex;
  gap: 25px;
  overflow: hidden;
  scroll-behavior: smooth;
  padding: 15px 0;
}

.gallery-slider img {
  width: 360px;
  height: 250px;
  object-fit: cover;
  border-radius: 16px;
  flex-shrink: 0;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
}

.gallery-slider img:hover {
  transform: scale(1.04);
  box-shadow: 0 12px 25px rgba(0, 0, 0, 0.4);
}

.gallery-btn {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  width: 55px;
  height: 55px;
  border: none;
  border-radius: 50%;
  background: #F80505;
  color: white;
  font-size: 24px;
  cursor: pointer;
  z-index: 10;
  display: flex;
  justify-content: center;
  align-items: center;
  transition: background 0.3s ease, transform 0.2s ease, box-shadow 0.3s ease;
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.3);
}

.gallery-btn:hover { 
  background: #c40404;
  box-shadow: 0 6px 15px rgba(248, 5, 5, 0.4);
}

.gallery-btn:active {
  transform: translateY(-50%) scale(0.95);
}

.gallery-btn.prev { left: -30px; }
.gallery-btn.next { right: -30px; }

@media (max-width: 1200px) {
  .gallery-btn.prev { left: -10px; }
  .gallery-btn.next { right: -10px; }
}

@media (max-width: 992px) { 
  .gallery-section { padding: 80px 20px; }
  .gallery-section h2 { font-size: 38px; }
  .gallery-slider img { 
    width: calc(33.33% - 16px); 
    min-width: calc(33.33% - 16px); 
  } 
}

@media (max-width: 768px) { 
  .gallery-section h2 { font-size: 32px; }
  .gallery-slider img { 
    width: calc(50% - 12px); 
    min-width: calc(50% - 12px); 
    height: 200px;
  } 
}

@media (max-width: 500px) { 
  .gallery-section { padding: 60px 15px; }
  .gallery-section h2 { font-size: 28px; margin-bottom: 30px; }
  .gallery-btn { display: none; }
  .gallery-slider { overflow-x: auto; } 
  .gallery-slider img { 
    width: 100%; 
    min-width: 100%; 
    height: 220px;
  } 
}

/* ===== contact ===== */
.contact {
  background: linear-gradient(rgba(11, 18, 32, 0.85), rgba(11, 18, 32, 0.9)), url("/images/haqqimizda.png") no-repeat center center / cover;
  background-attachment: scroll;
}

.contact-container {
  display: flex;
  justify-content: space-between;
  gap: 30px;
  margin-top: 25px;
  flex-wrap: wrap;
}

.contact-info {
  flex: 1;
  background: #124573;
  padding: 30px;
  border-radius: 12px;
  box-shadow: 0 15px 35px rgba(0,0,0,0.25);
}

.contact-info h3 { margin-bottom: 20px; color: var(--text-main); }
.contact-info p { margin-bottom: 10px; color: var(--text-muted); }

.whatsapp {
  display: inline-block;
  margin-top: 20px;
  background: #25D366;
  color: white;
  padding: 12px 20px;
  border-radius: 8px;
  text-decoration: none;
  font-weight: bold;
}

.contact-form {
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 15px;
  box-shadow: 0 15px 35px rgba(0,0,0,0.25);
  padding: 30px;
  border-radius: 12px;
  background: var(--card-bg);
}

/* Mesaj sahəsi və bütün inputların oxunurluğu */
.contact-form input, 
.contact-form textarea { 
  padding: 12px; 
  border: none; 
  border-radius: 8px; 
  outline: none; 
  background-color: #ffffff !important;
  color: #1e293b !important;
  font-size: 15px;
}

.contact-form textarea {
  min-height: 110px;
  resize: vertical;
}

.contact-form input::placeholder,
.contact-form textarea::placeholder {
  color: #64748b !important;
  opacity: 1;
}

/* Göndər düyməsi */
.contact-form button { 
  background: #F80505; 
  color: #ffffff;
  padding: 14px; 
  border: none; 
  border-radius: 8px; 
  cursor: pointer; 
  font-weight: bold; 
  font-size: 16px;
  transition: background 0.3s ease;
}

.contact-form button:hover {
  background: #c40404;
}

.map { margin-top: 30px; border-radius: 12px; overflow: hidden; }

@media (max-width: 600px) { 
  .contact {
    padding-top: 35px !important;
    padding-bottom: 35px !important;
  }

  .contact-container { 
    flex-direction: column; 
    gap: 20px;
    margin-top: 20px;
  } 

  .contact-info, .contact-form {
    padding: 20px 16px;
    width: 100%;
    text-align: center;
  }
}

/* ===== footer ===== */
/* ==========================================================================
   MANDCO - Modern Footer Komponenti
   ========================================================================== */

.main-footer {
  position: relative;
  z-index: 10;
  background: #0b1329;
  border-top: 1px solid rgba(255, 255, 255, 0.08);
  padding: 60px 40px 30px 40px;
  width: 100%;
  color: #cbd5e1;
  font-family: sans-serif;
  box-sizing: border-box;
}

.footer-container {
  display: grid;
  grid-template-columns: 1.2fr 0.8fr 1fr 1fr;
  gap: 40px;
  max-width: 1400px;
  margin: 0 auto;
}

/* Footer Başlıqları */
.footer-column h3 {
  color: #ffffff !important;
  font-size: 20px;
  font-weight: 600;
  margin-top: 0;
  margin-bottom: 25px;
  position: relative;
}

.footer-column h3::after {
  content: '';
  position: absolute;
  left: 0;
  bottom: -6px;
  width: 35px;
  height: 2px;
  background-color: #F80505;
}

/* Brend Sütunu */
.brand-column {
  display: flex;
  flex-direction: column;
  justify-content: flex-start;
  align-items: flex-start;
  gap: 15px;
  margin-top: 0 !important;
  padding-top: 0 !important;
}

.footer-logo {
  max-width: 220px;
  width: 100%;
  height: auto;
  display: block;
  margin: 0 !important;
  padding: 0 !important;
  object-fit: contain;
}

.footer-desc {
  font-size: 14px;
  line-height: 1.6;
  color: #94a3b8;
  margin: 0 !important;
  padding: 0 !important;
}

.footer-establishment {
  font-size: 13px;
  color: #64748b;
  margin-top: 5px !important;
  display: block;
}

/* Keçidlər */
.footer-links {
  list-style: none;
  padding: 0;
  margin: 0;
}

.footer-links li {
  margin-bottom: 12px;
}

.footer-links a {
  color: #cbd5e1;
  text-decoration: none;
  font-size: 15px;
  transition: color 0.3s ease, padding-left 0.3s ease;
}

.footer-links a:hover {
  color: #F80505;
  padding-left: 6px;
}

/* Əlaqə Məlumatları */
.footer-contact-info {
  list-style: none;
  padding: 0;
  margin: 0;
}

.footer-contact-info li {
  display: flex;
  align-items: flex-start;
  gap: 15px;
  margin-bottom: 20px;
}

.footer-contact-info i {
  color: #F80505;
  font-size: 18px;
  margin-top: 3px;
}

.footer-contact-info div {
  display: flex;
  flex-direction: column;
}

.footer-contact-info span {
  font-size: 13px;
  color: #64748b;
}

.footer-contact-info a {
  color: #fff;
  text-decoration: none;
  font-size: 16px;
  font-weight: 500;
  transition: color 0.3s ease;
}

.footer-contact-info a:hover {
  color: #F80505;
}

/* Ünvan və Sosial Şəbəkələr */
.footer-address {
  font-size: 15px;
  line-height: 1.6;
  margin-bottom: 25px;
}

.footer-address i {
  color: #F80505;
  margin-right: 8px;
}

.footer-socials {
  display: flex;
  gap: 12px;
}

.footer-socials a {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.05);
  color: #fff;
  text-decoration: none;
  font-size: 16px;
  transition: all 0.3s ease;
  border: 1px solid rgba(255, 255, 255, 0.05);
}

.footer-socials a:hover {
  background: #F80505;
  color: #ffffff;
  transform: translateY(-4px);
}

/* ==========================================================================
   CHATBOT VƏ BACK TO TOP STİLLƏRİ (Bura Bərpa Olundu)
   ========================================================================== */

/* Çat Açma/Bağlama Düyməsi */
.chat-toggle {
  position: fixed !important;
  bottom: 25px !important;
  right: 25px !important;
  width: 55px;
  height: 55px;
  background-color: #F80505;
  color: #ffffff;
  border-radius: 50%;
  display: flex !important;
  align-items: center;
  justify-content: center;
  font-size: 24px;
  cursor: pointer;
  box-shadow: 0 4px 15px rgba(248, 5, 5, 0.4);
  z-index: 99998;
  border: none !important;
  outline: none !important;
}

.chat-toggle:hover {
  transform: scale(1.08);
  background-color: #c50404;
}

/* Yuxarı Çıx (Back To Top) Düyməsi */
.back-to-top {
  position: fixed !important;
  bottom: 90px !important;
  right: 25px !important;
  width: 45px;
  height: 45px;
  background-color: rgba(15, 23, 42, 0.9);
  color: #ffffff;
  border: 1px solid rgba(255, 255, 255, 0.15);
  border-radius: 50%;
  display: flex !important;
  align-items: center;
  justify-content: center;
  font-size: 16px;
  text-decoration: none;
  cursor: pointer;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
  z-index: 99997;
  outline: none !important;
}

.back-to-top:hover {
  background-color: #F80505;
  border-color: #F80505;
  color: #ffffff;
}

/* Chatbot Ana Pəncərəsi */
.chatbot {
  display: none; 
  position: fixed !important;
  bottom: 90px !important;
  right: 25px !important;
  width: 350px;
  max-width: calc(100vw - 40px);
  height: 480px;
  background-color: #0b1329;
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 16px;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.5);
  z-index: 99999;
  flex-direction: column;
  overflow: hidden;
}

/* Çat Başlığı */
.chat-header {
  background-color: #111c33;
  padding: 12px 16px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.chat-header span {
  color: #ffffff;
  font-weight: 600;
  font-size: 15px;
}

.chat-header button {
  background: transparent;
  border: none;
  color: #cbd5e1;
  font-size: 22px;
  cursor: pointer;
}

/* Çat Gövdəsi (Mesajlar) */
.chat-body {
  flex: 1;
  padding: 15px;
  overflow-y: auto;
  display: flex;
  flex-direction: column;
  gap: 10px;
  background-color: #0b1329;
}

.bot-msg, .user-msg {
  max-width: 80%;
  padding: 8px 12px;
  border-radius: 10px;
  font-size: 14px;
  line-height: 1.4;
  word-break: break-word;
}

.bot-msg {
  background-color: #1c44a2;
  color: #ffffff;
  align-self: flex-start;
  border-bottom-left-radius: 2px;
}

.user-msg {
  background-color: #F80505;
  color: #ffffff;
  align-self: flex-end;
  border-bottom-right-radius: 2px;
}

/* Tez Mesajlar */
.quick-messages {
  padding: 8px;
  display: flex;
  gap: 6px;
  overflow-x: auto;
  background-color: #0d1733;
  border-top: 1px solid rgba(255, 255, 255, 0.05);
  white-space: nowrap;
}

.quick-messages button {
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.15);
  color: #cbd5e1;
  padding: 5px 12px;
  border-radius: 15px;
  font-size: 12px;
  cursor: pointer;
}

.quick-messages button:hover {
  background: #F80505;
  color: #ffffff;
  border-color: #F80505;
}

/* Çat Daxili Input */
.chat-input {
  display: flex;
  padding: 10px;
  background-color: #111c33;
  border-top: 1px solid rgba(255, 255, 255, 0.08);
  gap: 8px;
}

.chat-input input {
  flex: 1;
  background: #1c2a4a !important;
  border: 1px solid rgba(255, 255, 255, 0.1) !important;
  color: #ffffff !important;
  padding: 8px 12px !important;
  border-radius: 6px !important;
  font-size: 14px !important;
}

.chat-input button {
  background-color: #F80505;
  color: #ffffff;
  border: none;
  padding: 0 14px;
  border-radius: 6px;
  cursor: pointer;
}

/* Responsive */
@media (max-width: 600px) {
  .main-footer {
    padding: 40px 20px 25px 20px;
  }
  .footer-container {
    grid-template-columns: 1fr;
    gap: 35px;
  }
  .brand-column, .footer-column h3 {
    text-align: center;
  }
  .footer-column h3::after {
    left: 50%;
    transform: translateX(-50%);
  }
  .footer-contact-info li, .footer-address, .footer-socials {
    justify-content: center;
    text-align: center;
  }
  .chatbot {
    right: 15px !important;
    bottom: 80px !important;
    width: calc(100vw - 30px);
  }
  .chat-toggle {
    right: 15px !important;
    bottom: 15px !important;
  }
  .back-to-top {
    right: 15px !important;
    bottom: 80px !important;
  }
}

/* ===== utilities ===== */
/* Modal Pəncərəsi - bağlama düyməsi artıq scroll olan hissədən kənardadır,
   ona görə məzmun uzun olanda da həmişə görünür */
#courseModal .modal-content {
  padding: 0;
  overflow: visible;
  max-height: 90vh;
}

#courseModal .close-modal {
  top: 14px;
  right: 16px;
  background: rgba(15, 23, 42, 0.55);
  border-radius: 50%;
  width: 34px;
  height: 34px;
  display: flex;
  align-items: center;
  justify-content: center;
}

/* Xarici konteyner həmişə şaquli (column) axır - "Təlim haqqında" yuxarıda,
   foto+təlimçi sətri aşağıda. Bu, uzun mətnlərdə və fərqli zoom
   səviyyələrində balansın pozulmasının qarşısını alır. */
#courseModal .modal-scroll-body {
  overflow-y: auto;
  max-height: 90vh;
  padding: 35px 30px;
  display: flex;
  flex-direction: column;
  gap: 24px;
  box-sizing: border-box;
}

.course-info-top h2 {
  margin: 0 0 8px;
}

.course-info-top p {
  margin: 0;
}

/* Müəllimli (Vergi/Mühasibat) modalda: foto solda (kiçik), məlumat sağda -
   yalnız bu daxili sətir üfüqi (row) düzülür */
.teacher-row {
  display: flex;
  flex-direction: row;
  align-items: stretch;
  gap: 24px;
}

.teacher-photo-side {
  flex: 0 0 180px;
}

.teacher-photo-side img {
  width: 100%;
  height: 100%;
  min-height: 220px;
  object-fit: cover;
  border-radius: 16px;
  display: block;
  box-shadow: 0 12px 28px rgba(0, 0, 0, 0.35);
}

.teacher-text {
  flex: 1;
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 8px;
  justify-content: center;
}

.teacher-text h3 {
  font-size: 21px;
  color: #fff;
  margin: 0;
  font-weight: 700;
}

.teacher-text p {
  font-size: 15px;
  color: var(--text-muted);
  margin: 0;
  line-height: 1.4;
}

.teacher-text span {
  font-size: 14px;
  color: #ffffff;
  font-weight: 600;
}

.modal-divider {
  border: none;
  border-top: 1px solid rgba(255, 255, 255, 0.12);
  margin: 2px 0;
}

/* Mobil: foto+mətn sətri şaquliyə keçir, foto yuxarıda mərkəzdə,
   boşluqlar və şrift ölçüləri kiçilir ki, kiçik ekranda sıxılmasın */
@media (max-width: 640px) {
  #courseModal .modal-content {
    max-height: 92vh;
  }

  #courseModal .modal-scroll-body {
    max-height: 92vh;
    padding: 28px 18px;
    gap: 18px;
  }

  .course-info-top h2 {
    font-size: 20px;
  }

  .course-info-top p {
    font-size: 14px;
  }

  .teacher-row {
    flex-direction: column;
    align-items: center;
    gap: 14px;
    text-align: center;
  }

  .teacher-photo-side {
    flex: 0 0 auto;
    width: 140px;
  }

  .teacher-photo-side img {
    min-height: 0;
    aspect-ratio: 1 / 1;
    height: auto;
  }

  .teacher-text {
    align-items: center;
    justify-content: flex-start;
  }

  .teacher-text h3 {
    font-size: 18px;
  }

  #courseModal .close-modal {
    top: 10px;
    right: 10px;
    width: 30px;
    height: 30px;
  }
}