/*
 * Respawn landing — design polish & bugfixes (features unchanged)
 */

:root {
  --brand-primary: #17457a;
  --brand-primary-dark: #223b59;
  --brand-accent: #f4813f;
  --text-muted: #6b7280;
  --text-body: #4b5563;
  --surface: #ffffff;
  --shadow-sm: 0 4px 24px rgba(23, 69, 122, 0.08);
  --shadow-md: 0 12px 40px rgba(0, 0, 0, 0.1);
  --radius-md: 12px;
  --header-height: 80px;
}

html {
  scroll-behavior: smooth;
}

body {
  color: var(--text-body);
  overflow-x: hidden;
}

#welcome,
#promotion,
#contact-us {
  scroll-margin-top: calc(var(--header-height) + 16px);
}

/* ----- Header ----- */
.header-area .main-nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  position: relative;
}

.header-area .main-nav .logo {
  float: none;
  flex-shrink: 0;
  display: flex;
  align-items: center;
  height: var(--header-height);
  line-height: 1;
}

.header-area .main-nav .logo img {
  max-height: 48px;
  width: auto;
  height: auto;
  object-fit: contain;
}

.header-area .main-nav .nav {
  float: none;
  margin-left: auto;
  margin-right: 0;
  margin-top: 0;
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 0.25rem;
  border-radius: 999px;
  padding: 6px 12px;
  box-shadow: var(--shadow-sm);
}

.header-area.header-sticky .nav li a.active,
.header-area .main-nav .nav li a.active {
  color: var(--brand-primary) !important;
  font-weight: 600;
}

.background-header .main-nav .nav li a.active {
  color: var(--brand-accent) !important;
}

.header-area .main-nav .nav li a {
  border-radius: 999px;
  padding: 0 14px;
  transition: color 0.2s ease, background-color 0.2s ease;
}

.header-area .main-nav .nav li a:hover,
.background-header .main-nav .nav li:hover a {
  color: var(--brand-primary) !important;
  background-color: rgba(23, 69, 122, 0.06);
}

.header-area .main-nav .menu-trigger {
  right: 0;
  text-indent: -9999em;
  width: 44px;
  height: 44px;
  top: 50%;
  transform: translateY(-50%);
}

@media (max-width: 991px) {
  .header-area .main-nav .nav {
    border-radius: 0;
    box-shadow: none;
    padding: 0;
  }

  .header-area .main-nav .menu-trigger {
    display: block !important;
    position: absolute;
    top: 50%;
    right: 15px;
    transform: translateY(-50%);
  }
}

/* ----- Hero ----- */
.welcome-area {
  height: auto !important;
  min-height: 0 !important;
  max-height: none;
  padding-bottom: 4rem;
  background-size: 48% auto;
  background-position: top right !important;
  background-repeat: no-repeat;
}

.welcome-area .header-text {
  width: 100% !important;
  margin-left: 0 !important;
  margin-right: 0 !important;
}

.welcome-area .hero-row {
  direction: ltr;
}

.welcome-area .header-text .hero-content,
.welcome-area .header-text .left-text {
  margin-top: 0 !important;
  transform: none !important;
  max-width: 36rem;
  padding-top: clamp(12rem, 32vw, 22rem);
  margin-right: auto !important;
  margin-left: 0 !important;
}

html[dir="rtl"] .welcome-area .hero-content {
  direction: rtl;
  text-align: right;
}

@media (min-width: 1141px) {
  .welcome-area {
    min-height: 520px !important;
    background-size: 42% auto;
  }

  .welcome-area .header-text .left-text {
    padding-top: clamp(10rem, 18vw, 16rem);
  }
}

.welcome-area .header-text h1 {
  font-size: clamp(2rem, 4vw, 2.75rem);
  line-height: 1.2;
  letter-spacing: -0.02em;
  margin-bottom: 1.25rem;
}

.welcome-area .header-text h1 em {
  display: block;
  margin-top: 0.25rem;
}

.welcome-area .header-text p {
  font-size: 1rem;
  line-height: 1.75;
  color: var(--text-muted);
  max-width: 32rem;
}

.donlwad,
.download-buttons {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 1rem;
  margin-top: 2rem;
}

.donlwad a,
.download-buttons a {
  width: 150px;
  height: 52px;
  flex-shrink: 0;
  border-radius: 10px;
  overflow: hidden;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
  box-shadow: var(--shadow-sm);
}

.donlwad a:last-child,
.download-buttons a:last-child {
  margin-right: 0;
}

.donlwad a:hover,
.download-buttons a:hover {
  transform: translateY(-3px);
  box-shadow: var(--shadow-md);
}

.donlwad a img,
.download-buttons a img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  display: block;
}

@media (max-width: 1140px) {
  .welcome-area {
    background-size: 58% auto;
    background-position: top right !important;
  }

  .welcome-area .header-text {
    padding-top: 0 !important;
  }

  .welcome-area .header-text .left-text {
    padding-top: clamp(11rem, 42vw, 18rem);
    max-width: 100%;
  }
}

@media (max-width: 810px) {
  .welcome-area {
    background-size: 72% auto;
    max-width: 100vw;
    padding-bottom: 2.5rem;
  }

  .welcome-area .header-text {
    padding-top: 0 !important;
    width: 100%;
    margin-left: 0;
    padding-left: 15px;
    padding-right: 15px;
  }

  .welcome-area .header-text .left-text {
    padding-top: clamp(9rem, 50vw, 14rem);
  }
}

@media (max-width: 480px) {
  .welcome-area {
    background-size: 85% auto;
  }

  .welcome-area .header-text .left-text {
    padding-top: clamp(8rem, 48vw, 11rem);
  }
}

/* ----- Features / About ----- */
.left-image-decor,
.right-image-decor {
  pointer-events: none;
  z-index: 0;
  height: 70% !important;
  margin-top: -80px !important;
  opacity: 0.85;
}

#promotion {
  position: relative;
  z-index: 1;
  padding-top: 60px;
  padding-bottom: 60px;
}

#promotion .promotion-row {
  direction: ltr;
}

#promotion .promotion-content {
  direction: rtl;
}

html[dir="ltr"] #promotion .promotion-content {
  direction: ltr;
}

#promotion .promotion-media,
#promotion .left-image {
  max-width: 300px;
  margin-left: auto;
  margin-right: 0;
}

#promotion .left-image img,
#promotion .feature-showcase-img {
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-md);
  max-height: 340px;
  width: auto;
  max-width: 100%;
  height: auto;
  object-fit: contain;
  display: block;
  margin: 0 auto;
}

@media (min-width: 992px) {
  #promotion .promotion-media,
  #promotion .left-image {
    max-width: 280px;
    margin-left: auto;
    margin-right: 0;
  }

  #promotion .promotion-media img,
  #promotion .left-image img {
    max-height: 380px;
  }
}

@media (max-width: 991px) {
  #promotion .promotion-row {
    direction: ltr;
  }

  #promotion .promotion-media,
  #promotion .left-image {
    max-width: 220px;
    margin-left: auto;
    margin-right: auto;
    margin-bottom: 0 !important;
  }

  #promotion .promotion-media img,
  #promotion .left-image img {
    max-height: 240px;
  }

  #promotion .promotion-content {
    margin-bottom: 1.5rem;
  }

  #promotion .mobile-bottom-fix-big {
    margin-bottom: 0 !important;
  }
}

#promotion .right-text ul li {
  margin-bottom: 2rem;
  gap: 1.5rem;
}

#promotion .right-text ul li .img {
  flex-shrink: 0;
  box-shadow: 0 8px 24px rgba(23, 69, 122, 0.25);
}

#promotion .right-text ul li .text {
  flex: 1;
  min-width: 0;
}

#promotion .right-text ul li .text p {
  font-size: 1rem;
  line-height: 1.7;
  color: var(--text-body);
  margin: 0;
  text-transform: none;
}

/* ----- Footer & contact ----- */
footer {
  margin-top: 120px;
}

.contact-form {
  text-align: start;
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-md);
}

.contact-form input,
.contact-form textarea {
  background-color: #f9fafb !important;
  border: 1px solid #e5e7eb;
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.contact-form input:focus,
.contact-form textarea:focus {
  border-color: var(--brand-primary);
  box-shadow: 0 0 0 3px rgba(23, 69, 122, 0.12);
  outline: none;
}

.contact-form button.main-button,
.contact-form #form-submit.main-button {
  width: 100%;
  background: linear-gradient(145deg, var(--brand-accent) 0%, #e86b4a 100%);
  border: none;
  cursor: pointer;
  transition: transform 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
}

.contact-form button.main-button:hover,
.contact-form #form-submit.main-button:hover {
  background: var(--brand-primary-dark);
  transform: translateY(-1px);
  box-shadow: 0 8px 20px rgba(34, 59, 89, 0.25);
}

.footer-content .right-content p {
  line-height: 1.75;
  opacity: 0.95;
}

footer .social {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.75rem;
  margin-top: 1.75rem;
  padding: 0;
}

footer .social li {
  margin: 0 !important;
}

footer .social li a {
  width: 48px;
  height: 48px;
  line-height: 48px;
  padding: 8px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-color: rgba(255, 255, 255, 0.5);
  background: rgba(255, 255, 255, 0.08);
  backdrop-filter: blur(4px);
}

footer .social li a img {
  max-width: 24px;
  max-height: 24px;
  width: auto;
  height: auto;
  object-fit: contain;
}

footer .social li a:hover {
  background: #fff;
  border-color: #fff;
  transform: translateY(-2px);
}

footer .sub-footer p {
  opacity: 0.9;
}

@media (max-width: 992px) {
  footer {
    margin-top: 80px;
    padding-top: 80px;
  }

  footer .footer-content {
    padding: 60px 0 !important;
  }

  .footer-content .right-content {
    margin-top: 2rem;
  }
}

/* ----- RTL (Arabic) ----- */
html[dir="rtl"] .header-area .main-nav .nav {
  margin-left: 0;
  margin-right: auto;
}

html[dir="rtl"] .header-area .main-nav .menu-trigger {
  right: auto;
  left: 15px;
}

html[dir="rtl"] #promotion .right-text ul li .img {
  margin-right: 0;
  margin-left: 30px;
}

html[dir="rtl"] .welcome-area {
  background-position: top right !important;
}

html[dir="rtl"] .donlwad,
html[dir="rtl"] .download-buttons {
  flex-direction: row-reverse;
  justify-content: flex-end;
}

@media (min-width: 992px) {
  html[dir="rtl"] .header-area .main-nav .nav li {
    padding-left: 20px;
    padding-right: 20px;
  }
}

/* ----- Accessibility ----- */
.visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

:focus-visible {
  outline: 2px solid var(--brand-accent);
  outline-offset: 2px;
}
