/* ===== BABBLY CUSTOM STYLES ===== */

/* === FC Slideshow === */
.fc_slideshow {
  margin: 30px 0; /* เว้นช่องว่างบน-ล่าง */
}

/* === Alpha Wave Learning - Portrait Images === */
body:has(.alpha-wave-slideshow) .fc_slideshow .slick-slide,
.alpha-wave-slideshow .slick-slide {
  height: 300px !important;
}

body:has(.alpha-wave-slideshow) .fc_slideshow .slick-track,
.alpha-wave-slideshow .slick-track {
  height: 300px !important;
}

body:has(.alpha-wave-slideshow) .fc_slideshow .slick-list,
.alpha-wave-slideshow .slick-list {
  height: 300px !important;
}

body:has(.alpha-wave-slideshow) .fc_slideshow > div > img,
body:has(.alpha-wave-slideshow) .fc_slideshow .slick-slide img,
.alpha-wave-slideshow > div > img,
.alpha-wave-slideshow .slick-slide img {
  width: 190px;
  height: 285px; /* สูงขึ้นตามอัตราส่วน 512:768 */
  object-fit: cover;
}

/* === Alpha Wave Learning - Mobile Portrait === */
@media (max-width: 768px) {
  .alpha-wave-slideshow .slick-slide {
    height: 270px !important;
    padding: 0 3px !important;
  }
  
  .alpha-wave-slideshow .slick-track {
    height: 270px !important;
  }
  
  .alpha-wave-slideshow .slick-list {
    height: 270px !important;
    margin: 0 -3px !important;
  }
  
  .alpha-wave-slideshow > div > img,
  .alpha-wave-slideshow .slick-slide img {
    width: 174px !important;
    height: 261px !important; /* สูงขึ้นตามอัตราส่วน */
    min-width: 174px !important;
    min-height: 261px !important;
    max-width: 174px !important;
    max-height: 261px !important;
  }
}

.fc_slideshow .slick-slide {
  height: 200px !important;
  display: flex !important;
  align-items: center;
  justify-content: center;
  padding: 0 5px; /* เว้นช่องว่างซ้าย-ขวา */
}

.fc_slideshow .slick-track {
  height: 200px !important;
}

.fc_slideshow .slick-list {
  height: 200px !important;
  margin: 0 -5px; /* ชดเชยการ padding ของ slide */
}

.fc_slideshow > div > img,
.fc_slideshow .slick-slide img {
  width: 190px; /* ลดขนาดเล็กน้อยเพื่อให้พอดีกับ padding */
  height: 190px;
  object-fit: cover;
  display: block;
  border-radius: 8px; /* เพิ่มมุมโค้งให้สวย */
}

/* Responsive - บังคับให้ภาพเป็นจัตุรัสในทุกขนาดจอ */
@media (max-width: 768px) {
  .fc_slideshow:not(.alpha-wave-slideshow) .slick-slide {
    height: 180px !important;
    padding: 0 3px !important; 
  }
  
  .fc_slideshow:not(.alpha-wave-slideshow) .slick-track {
    height: 180px !important;
  }
  
  .fc_slideshow:not(.alpha-wave-slideshow) .slick-list {
    height: 180px !important;
    margin: 0 -3px !important;
  }
  
  .fc_slideshow:not(.alpha-wave-slideshow) > div > img,
  .fc_slideshow:not(.alpha-wave-slideshow) .slick-slide img {
    width: 174px !important;
    height: 174px !important;
    min-width: 174px !important;
    min-height: 174px !important;
    max-width: 174px !important;
    max-height: 174px !important;
  }
}


/* === Global Typography and Base Styles === */
body {
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

/* === Web Font Alternatives for Apple-like Typography === */
html:lang(en) body, html:lang(en) * {
  font-family: "Inter", "Noto Sans", "Helvetica Neue", "Arial", sans-serif !important;
}

html:lang(th) body, html:lang(th) * {
  font-family: "Noto Sans Thai", "Noto Sans", "Sukhumvit Set", "Leelawadee UI", "Tahoma", sans-serif !important;
  line-height: 1.35718;
  letter-spacing: 0em;
}

html:lang(ja) body, html:lang(ja) * {
  font-family: "Noto Sans JP", "Hiragino Kaku Gothic ProN", "Hiragino Sans", "Yu Gothic UI", "Meiryo", sans-serif !important;
}

/* === Logo and Branding === */
.hero-logo {
  border-radius: 22.8px; /* 22.37% of 102px width - iOS App Icon Style */
  overflow: hidden;
}

.logo-text {
  font-size: 16px;
  font-weight: bold;
  color: black;
  font-family: 'Inter', sans-serif;
}

/* === Hero Section Styles === */
.hero-subtitle {
  font-size: 1.5rem;
  font-weight: 500;
  margin: 1rem 0;
  color: #666;
}

/* === Languages Section === */
.languages-description {
  text-align: center;
  color: #666;
  margin: 1rem 0 2rem 0;
  max-width: 600px;
  margin-left: auto;
  margin-right: auto;
}

.languages-list {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 1rem;
  align-items: center;
}

.language-item {
  display: inline-block;
  padding: 0.5rem 1rem;
  font-size: 1.4rem;
  font-weight: 700;
  color: rgb(128, 128, 128);
  height: 60px;
  line-height: 60px;
  text-align: center;
  min-width: 80px;
}

/* === Font Families for Each Language - Bold and Prominent === */
.lang-en-us, .lang-en-gb { 
  font-family: 'Inter', 'Helvetica Neue', sans-serif; 
  font-weight: 800; 
}
.lang-zh-cn, .lang-zh-tw, .lang-yue-hk { 
  font-family: 'Noto Sans SC', 'PingFang SC', 'Source Han Sans SC', sans-serif; 
  font-weight: 700; 
}
.lang-hi-in { 
  font-family: 'Noto Sans Devanagari', 'Lohit Devanagari', sans-serif; 
  font-weight: 700; 
}
.lang-es-es, .lang-fr-fr, .lang-pt-pt, .lang-de-de, .lang-it-it, .lang-ru-ru { 
  font-family: 'Inter', 'Roboto', 'Arial', sans-serif; 
  font-weight: 800; 
}
.lang-ar-sa { 
  font-family: 'Noto Sans Arabic', 'Tajawal', 'Cairo', sans-serif; 
  direction: rtl; 
  font-weight: 700; 
}
.lang-ja-jp { 
  font-family: 'Noto Sans JP', 'Hiragino Sans', 'Yu Gothic UI', sans-serif; 
  font-weight: 700; 
}
.lang-ko-kr { 
  font-family: 'Noto Sans KR', 'Malgun Gothic', 'Apple SD Gothic Neo', sans-serif; 
  font-weight: 700; 
}
.lang-tr-tr { 
  font-family: 'Inter', 'Roboto', sans-serif; 
  font-weight: 800; 
}
.lang-vi-vn { 
  font-family: 'Noto Sans Vietnamese', 'Inter', sans-serif; 
  font-weight: 700; 
}
.lang-id-id, .lang-ms-my { 
  font-family: 'Noto Sans', 'Inter', 'Roboto', sans-serif; 
  font-weight: 700; 
}
.lang-th-th { 
  font-family: 'LINE Seed Sans TH', 'Noto Sans Thai', 'Kanit', sans-serif; 
  font-weight: 700; 
}

/* === RTL Support for Arabic, Persian, and Urdu === */
html:lang(ar), html:lang(fa), html:lang(ur) {
  direction: rtl;
}

html:lang(ar) body, html:lang(fa) body, html:lang(ur) body {
  direction: rtl;
}

/* RTL for paragraphs and text content (but not centered content) */
html:lang(ar) p:not(.hero-description):not(.languages-description):not(.features-description),
html:lang(fa) p:not(.hero-description):not(.languages-description):not(.features-description),
html:lang(ur) p:not(.hero-description):not(.languages-description):not(.features-description) {
  text-align: right;
}

/* Keep centered content centered in RTL */
html:lang(ar) .heading-small,
html:lang(ar) .languages-description,
html:lang(ar) .hero-description,
html:lang(ar) .features-description,
html:lang(fa) .heading-small,
html:lang(fa) .languages-description, 
html:lang(fa) .hero-description,
html:lang(fa) .features-description,
html:lang(ur) .heading-small,
html:lang(ur) .languages-description,
html:lang(ur) .hero-description,
html:lang(ur) .features-description {
  text-align: center;
}

/* === RTL-specific Layout Adjustments === */
html:lang(ar) .nav-wrapper,
html:lang(fa) .nav-wrapper, 
html:lang(ur) .nav-wrapper {
  flex-direction: row-reverse;
}

html:lang(ar) .footer-wrapper,
html:lang(fa) .footer-wrapper,
html:lang(ur) .footer-wrapper {
  flex-direction: row-reverse;
}

html:lang(ar) .button-arrow,
html:lang(fa) .button-arrow,
html:lang(ur) .button-arrow {
  transform: scaleX(-1);
}

/* === Content Template Specific - 1 Column Layout === */
.overview-grid {
  display: grid !important;
  grid-template-columns: 1fr !important;
  grid-template-rows: none !important;
  max-width: 800px;
  margin: 0 auto;
  gap: 2rem;
}

.overview-grid .overview-card,
.overview-grid .overview-highlight {
  grid-column: 1 !important;
  max-width: none !important;
  width: 100% !important;
}

/* Fix button width in overview-content */
.overview-content {
  align-items: flex-start !important;
}

/* === Cookie Consent Styling === */
.cc-window {
  box-shadow: 0 4px 24px rgba(0, 0, 0, 0.1);
  border-radius: 16px;
  padding: 24px !important;
  font-family: 'Inter', sans-serif;
}

.cc-message {
  margin-right: 16px !important;
  font-size: 14px;
  line-height: 1.5;
}

.cc-btn {
  background-color: #39D2C0 !important;
  color: white !important;
  border-radius: 40px !important;
  padding: 12px 32px !important;
  font-weight: 500 !important;
  font-size: 14px !important;
  transition: all 0.3s ease !important;
  text-transform: none !important;
  min-width: auto !important;
  border: none !important;
}

.cc-btn:hover {
  background-color: #2eb8a8 !important;
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(57, 210, 192, 0.3);
}

.cc-link {
  color: #39D2C0 !important;
  text-decoration: underline;
}

.cc-link:hover {
  color: #2eb8a8 !important;
}

/* === Pricing Section === */
.pricing-section {
  padding: 0 0 80px 0;
}

/* Billing Toggle */
.billing-toggle-section {
  margin-bottom: 50px;
}

.billing-toggle {
  display: flex;
  justify-content: space-between;
  align-items: center;
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 20px;
}

/* RTL Support for billing toggle */
[dir="rtl"] .billing-toggle {
  direction: rtl;
}

@media (max-width: 768px) {
  .billing-toggle {
    flex-direction: column;
    gap: 20px;
    text-align: center;
  }

  .billing-info {
    margin: 0;
  }
}

.billing-info {
  font-size: 17px;
  color: var(--black--primary);
  line-height: 1.4;
  margin: 0;
  flex: 1;
}

.highlight-badge {
  background-color: var(--accent);
  color: white;
  padding: 2px 8px;
  border-radius: 12px;
  font-size: 14px;
  font-weight: 600;
  text-transform: uppercase;
  white-space: nowrap;
}

.billing-buttons {
  display: flex;
  gap: 12px;
}

.billing-btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 8px 16px;
  border: 1px solid var(--gray--secondary);
  border-radius: 40px;
  background-color: var(--accent);
  color: white;
  border-color: var(--accent);
  font-size: 14px;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.3s ease;
}

.billing-btn[data-period="threeMonth"] {
  background-color: var(--white--primary);
  color: var(--black--primary);
  border-color: var(--accent);
  border-width: 2px;
}

.billing-btn[data-period="threeMonth"] .button-arrow {
  filter: brightness(0) saturate(100%) invert(58%) sepia(100%) saturate(1380%) hue-rotate(134deg) brightness(96%) contrast(85%);
}

.billing-btn .button-arrow {
  transition: transform 0.3s ease;
}

.billing-btn:hover .button-arrow {
  transform: rotate(-90deg);
}

/* Yellow badge for 3-month discount */
.pricing-yearly-badge.badge-3month {
  background-color: #fbbf24;
  color: var(--black--primary);
}

.pricing-wrapper {
  text-align: center;
}

.pricing-plans {
  display: flex;
  justify-content: center;
  align-items: stretch;
  gap: 30px;
  flex-wrap: wrap;
  margin-top: 40px;
}

.pricing-plan {
  background-color: var(--white--primary);
  box-shadow: 0 -1px 0 0 var(--gray--secondary), 0 1px 3px 0 var(--gray--secondary), inset 0 0 0 1px var(--gray--secondary);
  border-radius: 20px;
  padding: 40px 30px;
  text-align: center;
  transition: all 0.3s ease;
  cursor: pointer;
  position: relative;
  max-width: 300px;
  flex: 1;
  display: flex;
  flex-direction: column;
}

.pricing-plan:hover {
  transform: translateY(-4px);
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.pricing-plan-popular {
  border: 2px solid var(--accent);
}

.pricing-plan-popular:hover {
  transform: translateY(-4px);
  box-shadow: 0 2px 8px rgba(57, 210, 192, 0.2);
}

.pricing-badge {
  position: absolute;
  top: -15px;
  left: 50%;
  transform: translateX(-50%);
  background-color: var(--accent);
  color: white;
  padding: 8px 24px;
  font-size: 14px;
  font-weight: 600;
  border-radius: 20px;
  white-space: nowrap;
}

.pricing-plan h2 {
  font-size: 24px;
  font-weight: 600;
  margin-bottom: 16px;
  color: var(--black--primary);
}

.pricing-regular {
  font-size: 16px;
  color: var(--black--primary);
  text-decoration: line-through;
  margin-bottom: 8px;
  height: 20px; /* Fixed height for alignment */
}

.pricing-price {
  font-size: 36px;
  font-weight: 700;
  line-height: 1.2;
  margin-bottom: 15px;
  color: var(--black--primary);
}

.pricing-yearly {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  margin-bottom: 30px;
}

/* RTL Support for pricing yearly */
[dir="rtl"] .pricing-yearly {
  direction: rtl;
}

.pricing-yearly-price {
  font-size: 14px;
  color: var(--black--primary);
  font-weight: 500;
}

.pricing-yearly-badge {
  background-color: var(--accent);
  color: white;
  font-size: 12px;
  font-weight: 600;
  padding: 4px 8px;
  border-radius: 12px;
  text-transform: uppercase;
}

.pricing-yearly-spacer {
  height: 35px; /* Same height as pricing-yearly with content */
}

.pricing-features {
  list-style: none;
  text-align: left;
  margin-bottom: 40px;
  padding: 0;
}

/* RTL Support for Arabic, Persian, Urdu */
html:lang(ar) .pricing-features li,
html:lang(fa) .pricing-features li,
html:lang(ur) .pricing-features li {
  text-align: right;
}

html:lang(ar) .pricing-icon,
html:lang(fa) .pricing-icon,
html:lang(ur) .pricing-icon {
  margin-right: 0;
  margin-left: 12px;
}

.feature-text {
  flex: 1;
}

/* Pricing Disclaimer */
.pricing-disclaimer {
  margin-top: 40px;
  text-align: center;
}

.pricing-disclaimer p {
  font-size: 14px;
  color: var(--black--primary);
  font-style: italic;
  margin: 0;
}

.pricing-features li {
  margin: 12px 0;
  display: flex;
  align-items: center;
  font-size: 16px;
  color: var(--black--primary);
}

.pricing-icon {
  width: 20px;
  height: 20px;
  margin-right: 12px;
  border-radius: 50%;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 12px;
  font-weight: bold;
  flex-shrink: 0;
}

/* RTL Support for pricing icons */
[dir="rtl"] .pricing-icon {
  margin-right: 0;
  margin-left: 12px;
}

.pricing-icon-check {
  background-color: var(--accent);
  color: white;
}

.pricing-icon-check::before {
  content: "✓";
}

.pricing-icon-times {
  background-color: #ff6b6b;
  color: white;
}

.pricing-icon-times::before {
  content: "✕";
}

.pricing-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  grid-column-gap: 8px;
  grid-row-gap: 8px;
  width: 100%;
  padding: 8px 16px 8px 8px;
  border-radius: 40px;
  text-decoration: none;
  font-weight: 500;
  font-size: 14px;
  transition: all 0.3s ease;
  border: none;
  margin-top: auto;
}

.pricing-button-primary {
  background-color: var(--accent);
  color: var(--white--primary);
}

.pricing-button-primary:hover {
  /* No hover effect - only arrow rotates */
}

.pricing-button-primary .button-arrow {
  transform: rotate(0deg);
  transition: transform 0.3s ease;
}

.pricing-button-primary:hover .button-arrow {
  transform: rotate(-90deg);
}

.pricing-button-secondary {
  background-color: var(--gray--secondary);
  color: var(--black--primary);
}

.pricing-button-secondary:hover {
  background-color: #e0e0e0;
}

/* === Pricing Responsive Fix === */
@media (max-width: 768px) {
  .pricing-section .container {
    padding: 0 15px !important;
  }

  .pricing-plans {
    flex-direction: column;
    align-items: center;
  }

  .pricing-plan {
    width: 100%;
    max-width: 400px;
    margin: 0 auto 20px auto;
  }
}


/* === Navigation Width Enhancement === */
.nav-wrapper {
  max-width: 800px !important; /* Increased from 540px */
}


/* === Mobile Responsive === */
@media (max-width: 768px) {
  .cc-window {
    margin: 16px !important;
    bottom: 0 !important;
    left: 0 !important;
    right: 0 !important;
    max-width: none !important;
  }

  /* Footer responsive - center align on mobile */
  .footer-wrapper.bottom {
    flex-direction: column !important;
    text-align: center !important;
    gap: 16px !important;
    align-items: center !important;
  }

  .footer-copyright {
    order: 2 !important;
    text-align: center !important;
  }

  .footer-menu {
    order: 1 !important;
    justify-content: center !important;
    text-align: center !important;
  }
}

/* === Download Page Styles === */
.download-section {
  padding: 80px 0;
}

.download-wrapper {
  text-align: center;
  max-width: 800px;
  margin: 0 auto;
}

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

.download-button-wrapper {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 16px;
}

.download-button-img {
  width: 200px;
  height: auto;
  opacity: 0.5;
  transition: opacity 0.3s ease;
  filter: grayscale(20%);
}

/* Apple App Store - Live and clickable */
.download-button-link .download-button-img {
  opacity: 1;
  filter: none;
  cursor: pointer;
}

.download-button-link:hover .download-button-img {
  transform: scale(1.05);
  transition: all 0.3s ease;
}

/* Android coming soon - same styling as link but no hover */
.android-coming-soon {
  display: inline-block;
}

.android-coming-soon .download-button-img {
  opacity: 0.5;
  filter: grayscale(20%);
  cursor: default;
}

.coming-soon-text {
  font-size: 14px;
  color: #999;
  font-style: italic;
  font-weight: 500;
}

/* Mobile Responsive */
@media (max-width: 768px) {
  .download-buttons {
    flex-direction: column;
    gap: 40px;
  }

  .download-button-img {
    width: 180px;
  }

  .download-section {
    padding: 60px 0;
  }
}

/* === Temporarily Hide Ask Menu === */
.nav-link:nth-child(3) {
  display: none !important;
}

/* === App Mode - Hide Navigation and Footer === */
.app-mode-default .navigation,
.app-mode-default .section.footer,
.app-mode .navigation,
.app-mode .section.footer {
  display: none !important;
}

/* Hide download buttons in app mode */
.app-mode-default .button-primary,
.app-mode .button-primary {
  display: none !important;
}

/* Hide ElevenLabs ConvAI widget in app mode */
.app-mode-default elevenlabs-convai,
.app-mode elevenlabs-convai {
  display: none !important;
}

/* Internal link buttons - exact copy of button-primary */
.button-internal {
  grid-column-gap: 8px;
  grid-row-gap: 8px;
  background-color: var(--accent);
  color: var(--white--primary);
  border-radius: 40px;
  align-items: center;
  padding: 8px 16px 8px 8px;
  font-weight: 500;
  display: inline-flex;
  text-decoration: none;
}

/* Webflow-style hover effects - arrow rotation like button-primary */
.button-internal .button-arrow {
  transform: rotate(0deg);
  transition: transform 0.3s ease;
}

.button-internal:hover .button-arrow {
  transform: rotate(-90deg) !important;
  transition: transform 0.3s ease !important;
}

/* App mode - remove top padding when navigation is hidden */
.app-mode-default .section[style*="padding-top: 200px"],
.app-mode .section[style*="padding-top: 200px"] {
  padding-top: 40px !important;
}

/* === Language Flag Responsive Positioning === */
/* Show desktop flag by default */
.language-flag {
  display: inline-block !important;
}

/* Hide mobile flag by default */
.mobile-flag {
  display: none !important;
}


/* Smaller font for hamburger menu */
@media (max-width: 479px) {
  .nav-link {
    font-size: 14px !important;
  }
}

/* Only for very small mobile phones - show mobile flag instead */
@media (max-width: 479px) {
  .language-flag {
    display: none !important;
  }
  .mobile-flag {
    display: inline-block !important;
  }
}

/* === Language Switcher Modal === */
.language-modal {
  display: none;
  position: fixed;
  z-index: 10000;
  left: 0;
  top: 0;
  width: 100%;
  height: 100%;
  background-color: rgba(0, 0, 0, 0.6);
  justify-content: center;
  align-items: center;
  backdrop-filter: blur(5px);
}

.language-modal-content {
  background-color: white;
  border-radius: 16px;
  padding: 0;
  max-width: 600px;
  width: 90%;
  max-height: 80vh;
  overflow-y: auto;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.2);
  animation: modalSlideIn 0.3s ease-out;
}

@keyframes modalSlideIn {
  from {
    opacity: 0;
    transform: translateY(-30px) scale(0.9);
  }
  to {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

.language-modal-header {
  padding: 24px 24px 16px 24px;
  border-bottom: 1px solid #f0f0f0;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.language-modal-header h3 {
  margin: 0;
  font-size: 20px;
  font-weight: 600;
  color: #333;
}

.language-modal-close {
  font-size: 28px;
  cursor: pointer;
  color: #999;
  line-height: 1;
  padding: 4px;
  border-radius: 50%;
  width: 32px;
  height: 32px;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.2s ease;
}

.language-modal-close:hover {
  background-color: #f5f5f5;
  color: #666;
}

.language-modal-body {
  padding: 20px 24px 24px 24px;
}

/* Language modal - 2 columns */
.language-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}

/* Features modal - 1 column for proper text display */
#bModal .language-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 12px;
}

.language-item {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 12px 16px;
  border: 1px solid #e8e8e8;
  border-radius: 12px;
  cursor: pointer;
  transition: all 0.2s ease;
  background: white;
}

.language-item:hover {
  border-color: #39D2C0;
  background-color: #f0fffe;
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(57, 210, 192, 0.15);
}

.language-item img {
  width: 24px;
  height: 24px;
  border-radius: 4px;
  object-fit: cover;
  margin-right: 12px;
  flex-shrink: 0;
}

.language-item span {
  font-size: 15px;
  font-weight: 500;
  color: #333;
  white-space: normal;
  word-wrap: break-word;
  line-height: 1.4;
  text-align: center;
}

/* Mobile responsive */
@media (max-width: 768px) {
  .language-modal-content {
    width: 95%;
    max-height: 85vh;
  }

  .language-grid {
    grid-template-columns: 1fr;
    gap: 10px;
  }

  .language-item {
    padding: 10px 12px;
  }

  .language-item span {
    font-size: 14px;
    white-space: normal;
    word-wrap: break-word;
    line-height: 1.4;
    text-align: center;
  }

  .language-modal-header {
    padding: 20px 20px 14px 20px;
  }

  .language-modal-header h3 {
    font-size: 18px;
  }

  .language-modal-body {
    padding: 16px 20px 20px 20px;
  }
}

/* === Contact Form Styles === */
.contact-section {
  padding: 80px 0;
  background-color: #f9f9f9;
}

.contact-wrapper {
  display: flex;
  flex-direction: column;
  gap: 60px;
  max-width: 1200px;
  margin: 0 auto;
}

.contact-section-wrapper {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 60px;
  align-items: start;
}

.contact-info h2 {
  font-size: 28px;
  font-weight: 600;
  margin-bottom: 24px;
  color: var(--black--primary);
}

.contact-address {
  font-size: 16px;
  line-height: 1.6;
  color: var(--black--primary);
}

.company-name {
  font-size: 1.2em;
  font-weight: 600;
  margin-bottom: 16px;
  color: var(--black--primary);
}

.contact-details {
  margin-top: 20px;
}

.contact-phone,
.contact-email {
  margin: 8px 0;
  font-size: 16px;
}

.country-flag {
  width: 16px;
  height: 16px;
  display: inline-block;
  vertical-align: middle;
  margin: 0 4px;
}

/* === Office Map Styles === */
.office-map {
  height: 320px;
  width: 100%;
  margin-bottom: 24px;
  border-radius: 12px;
  overflow: hidden;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
  position: relative;
  z-index: 1;
}

/* Custom Map Marker */
.custom-marker {
  background: transparent;
  border: none;
}

.marker-pin {
  width: 30px;
  height: 30px;
  border-radius: 50% 50% 50% 0;
  background: #39D2C0;
  position: absolute;
  transform: rotate(-45deg);
  left: 50%;
  top: 50%;
  margin: -15px 0 0 -15px;
  box-shadow: 0 2px 8px rgba(57, 210, 192, 0.4);
}

.marker-pin:after {
  content: '';
  width: 14px;
  height: 14px;
  background: #fff;
  position: absolute;
  border-radius: 50%;
  left: 50%;
  top: 50%;
  transform: translate(-50%, -50%);
}

/* Show text by default, hide links */
.contact-phone-text,
.contact-email-text {
  display: inline;
}

.contact-phone-link,
.contact-email-link {
  display: none;
}

/* Mobile/Tablet - Show links, hide text */
@media (max-width: 1024px) {
  .contact-phone-text,
  .contact-email-text {
    display: none;
  }

  .contact-phone-link,
  .contact-email-link {
    display: inline;
    color: var(--accent);
    text-decoration: none;
  }

  .contact-phone-link:hover,
  .contact-email-link:hover {
    text-decoration: underline;
  }
}

.contact-form-wrapper h2 {
  font-size: 28px;
  font-weight: 600;
  margin-bottom: 32px;
  color: var(--black--primary);
}

.contact-form {
  display: flex;
  flex-direction: column;
  gap: 24px;
}

.form-group {
  display: flex;
  flex-direction: column;
}

.form-group label {
  font-size: 16px;
  font-weight: 500;
  color: var(--black--primary);
  margin-bottom: 8px;
}

.form-input,
.form-select,
.form-textarea {
  width: 100%;
  padding: 12px 16px;
  border: 2px solid #e8e8e8;
  border-radius: 12px;
  font-size: 16px;
  font-family: inherit;
  transition: all 0.3s ease;
  background-color: white;
}

/* Force same height for all form elements - iOS fix */
.contact-form .form-select,
.contact-form select[name="subject"] {
  height: 50px !important;
  min-height: 50px !important;
  max-height: 50px !important;
  -webkit-appearance: none !important;
  appearance: none !important;
  padding: 12px 16px !important;
  line-height: normal !important;
  box-sizing: border-box !important;
  background-image: url("data:image/svg+xml;charset=US-ASCII,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 4 5'><path fill='%23666' d='M2 0L0 2h4zm0 5L0 3h4z'/></svg>") !important;
  background-repeat: no-repeat !important;
  background-position: right 16px center !important;
  background-size: 12px !important;
  padding-right: 40px !important;
}

.form-input:focus,
.form-select:focus,
.form-textarea:focus {
  outline: none;
  border-color: var(--accent);
  box-shadow: 0 0 0 3px rgba(57, 210, 192, 0.1);
}

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

.contact-submit-btn {
  background-color: var(--accent);
  color: white;
  border: none;
  padding: 8px 16px 8px 8px;
  font-size: 16px;
  font-weight: 600;
  border-radius: 40px;
  cursor: pointer;
  align-self: flex-start;
  display: inline-flex;
  align-items: center;
  grid-column-gap: 8px;
  grid-row-gap: 8px;
}

.contact-submit-btn .button-arrow {
  transform: rotate(0deg);
  transition: transform 0.3s ease;
}

.contact-submit-btn:hover .button-arrow {
  transform: rotate(-90deg);
}

.contact-social {
  text-align: center;
  padding: 40px 0;
}

.contact-social h3 {
  font-size: 24px;
  font-weight: 600;
  margin-bottom: 32px;
  color: var(--black--primary);
}

.social-icons {
  display: flex;
  justify-content: center;
  gap: 20px;
  flex-wrap: wrap;
}

.social-icon {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 50px;
  height: 50px;
  background-color: var(--accent);
  border-radius: 50%;
  color: white;
  font-size: 20px;
  transition: all 0.3s ease;
  text-decoration: none;
}

.social-icon-img {
  width: 24px;
  height: 24px;
  object-fit: contain;
}

.social-icon:hover {
  transform: translateY(-3px);
  box-shadow: 0 6px 20px rgba(57, 210, 192, 0.3);
  background-color: #2eb8a8;
}

/* RTL Support for Contact Form */
html:lang(ar) .contact-form-wrapper,
html:lang(fa) .contact-form-wrapper,
html:lang(ur) .contact-form-wrapper {
  text-align: right;
}

html:lang(ar) .contact-info,
html:lang(fa) .contact-info,
html:lang(ur) .contact-info {
  text-align: right;
}

html:lang(ar) .contact-submit-btn,
html:lang(fa) .contact-submit-btn,
html:lang(ur) .contact-submit-btn {
  align-self: flex-end;
}

/* Medium Screen Responsive for Contact */
@media (min-width: 769px) and (max-width: 1200px) {
  .contact-wrapper {
    padding: 0 40px;
  }
}

/* Mobile Responsive for Contact */
@media (max-width: 768px) {
  .contact-section {
    padding: 60px 0;
  }

  .contact-wrapper {
    gap: 40px;
    padding: 0 20px;
  }

  .contact-section-wrapper {
    grid-template-columns: 1fr;
    gap: 40px;
  }

  .contact-info h2,
  .contact-form-wrapper h2 {
    font-size: 24px;
  }

  .contact-info {
    text-align: center;
  }

  .social-icons {
    gap: 15px;
  }

  .social-icon {
    width: 45px;
    height: 45px;
    font-size: 18px;
  }

  .contact-submit-btn {
    align-self: center;
  }
}

/* === Contact Form Toast Notifications === */
.contact-toast {
  position: fixed;
  bottom: 20px;
  right: 20px;
  z-index: 10000;
  min-width: 300px;
  max-width: 500px;
  background-color: white;
  border-radius: 12px;
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.12);
  transform: translateX(100%);
  opacity: 0;
  transition: all 0.3s ease;
}

.contact-toast-show {
  transform: translateX(0);
  opacity: 1;
}

.contact-toast-error {
  border-left: 4px solid var(--accent);
}

.contact-toast-content {
  display: flex;
  align-items: center;
  padding: 16px 20px;
  gap: 12px;
}

.contact-toast-icon {
  font-size: 20px;
  flex-shrink: 0;
}

.contact-toast-message {
  flex: 1;
  font-size: 14px;
  font-weight: 500;
  color: var(--black--primary);
  line-height: 1.4;
}

.contact-toast-close {
  background: none;
  border: none;
  font-size: 20px;
  color: #999;
  cursor: pointer;
  padding: 4px;
  line-height: 1;
  border-radius: 4px;
  transition: all 0.2s ease;
  flex-shrink: 0;
}

.contact-toast-close:hover {
  background-color: #f5f5f5;
  color: #666;
}

/* Mobile responsive for toast */
@media (max-width: 768px) {
  .contact-toast {
    bottom: 10px;
    right: 10px;
    left: 10px;
    min-width: auto;
    max-width: none;
  }

  .contact-toast-content {
    padding: 14px 16px;
  }

  .contact-toast-message {
    font-size: 13px;
  }
}

/* === Contact Form Loading Animation === */
.contact-form-loading {
  animation: contact-form-spin 1s linear infinite !important;
  transform-origin: center !important;
}

.button-arrow.contact-form-loading {
  animation: contact-form-spin 1s linear infinite !important;
  transform-origin: center !important;
}

@keyframes contact-form-spin {
  from {
    transform: rotate(0deg);
  }
  to {
    transform: rotate(360deg);
  }
}

/* === Temporarily Hide Testimonials === */
.testimonials-section {
  display: none !important;
}

/* === Footer Consistency Fix === */
.section.footer {
  margin-bottom: 0 !important;
  padding-bottom: 0 !important;
}

.footer-section,
.section.footer {
  position: relative;
  z-index: 1;
}

/* === NEWSLETTER FORM STYLES === */
.newsletter-section {
  padding: 60px 0;
  background-color: #f9f9f9;
}

.newsletter-wrapper {
  max-width: 600px;
  margin: 0 auto;
  text-align: center;
}

.newsletter-wrapper h2 {
  font-size: 32px;
  font-weight: 600;
  margin-bottom: 16px;
  color: var(--black--primary);
}

.newsletter-description {
  font-size: 18px;
  color: var(--black--secondary);
  margin-bottom: 40px;
  line-height: 1.6;
}

.newsletter-form {
  display: flex;
  flex-direction: column;
  gap: 24px;
  text-align: left;
}

.newsletter-form .form-group {
  display: flex;
  flex-direction: column;
}

.newsletter-form .form-group label {
  font-size: 16px;
  font-weight: 500;
  color: var(--black--primary);
  margin-bottom: 8px;
}

.newsletter-form .form-input {
  width: 100%;
  padding: 12px 16px;
  border: 2px solid #e8e8e8;
  border-radius: 12px;
  font-size: 16px;
  font-family: inherit;
  transition: all 0.3s ease;
  background-color: white;
  height: 50px;
  box-sizing: border-box;
}

.newsletter-form .form-input:focus {
  outline: none;
  border-color: var(--accent);
  box-shadow: 0 0 0 3px rgba(57, 210, 192, 0.1);
}

.newsletter-preferences {
  margin-top: 8px;
}

.preferences-title {
  font-size: 16px;
  font-weight: 500;
  color: var(--black--primary);
  margin-bottom: 16px;
}

.checkbox-group {
  margin-bottom: 12px;
}

.checkbox-label {
  display: flex;
  align-items: flex-start;
  cursor: pointer;
  font-size: 15px;
  line-height: 1.5;
  gap: 12px;
}

.checkbox-input {
  position: absolute;
  opacity: 0;
  cursor: pointer;
}

.checkbox-custom {
  width: 20px;
  height: 20px;
  border: 2px solid #e8e8e8;
  border-radius: 4px;
  background-color: white;
  position: relative;
  flex-shrink: 0;
  margin-top: 2px;
  transition: all 0.3s ease;
}

.checkbox-input:checked + .checkbox-custom {
  background-color: var(--accent);
  border-color: var(--accent);
}

.checkbox-input:checked + .checkbox-custom::after {
  content: '';
  position: absolute;
  left: 6px;
  top: 2px;
  width: 6px;
  height: 10px;
  border: solid white;
  border-width: 0 2px 2px 0;
  transform: rotate(45deg);
}

.checkbox-input:focus + .checkbox-custom {
  box-shadow: 0 0 0 3px rgba(57, 210, 192, 0.1);
}

.checkbox-text {
  color: var(--black--primary);
}

.newsletter-submit-btn {
  background-color: var(--accent);
  color: white;
  border: none;
  padding: 8px 16px 8px 8px;
  font-size: 16px;
  font-weight: 600;
  border-radius: 40px;
  cursor: pointer;
  align-self: center;
  display: inline-flex;
  align-items: center;
  grid-column-gap: 8px;
  grid-row-gap: 8px;
}

.newsletter-submit-btn .button-arrow {
  transform: rotate(0deg);
  transition: transform 0.3s ease;
}

.newsletter-submit-btn:hover .button-arrow {
  transform: rotate(-90deg);
}

.newsletter-form-loading {
  animation: contact-form-spin 1s linear infinite !important;
}

/* Mobile responsiveness for newsletter */
@media (max-width: 768px) {
  .newsletter-section {
    padding: 40px 0;
  }

  .newsletter-wrapper {
    padding: 0 20px;
  }

  .newsletter-wrapper h2 {
    font-size: 28px;
  }

  .newsletter-description {
    font-size: 16px;
  }

  .newsletter-submit-btn {
    align-self: center;
  }
}