@import url('https://fonts.googleapis.com/css2?family=Manrope:wght@400;500;600;700;800&family=Noto+Sans+Arabic:wght@400;500;600;700;800&display=swap');

:root {
  --bg: #fcfbf8;
  --text: #202a33;
  --muted: #65717a;
  --primary: #4a7d9e;
  --primary-dark: #173247;
  --primary-light: #e7eff4;
  --accent: #6f95ad;
  --soft: #f5f2ed;
  --border: #e2ded7;
  --steel: #7a858c;
  --dark-slate: #172d3d;
  --max: 1200px;
  --transition: all 0.25s ease;
}

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

body {
  font-family: 'Manrope', sans-serif;
  color: var(--text);
  background: var(--bg);
  line-height: 1.7;
  font-weight: 400;
  overflow-x: hidden;
}

a {
  color: inherit;
  text-decoration: none;
  transition: var(--transition);
}

.container {
  max-width: var(--max);
  margin: 0 auto;
  padding: 0 24px;
}

/* Header & Navigation */
.header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(252, 251, 248, 0.94);
  backdrop-filter: blur(14px);
  border-bottom: 1px solid var(--border);
  box-shadow: 0 8px 32px rgba(24, 36, 46, 0.04);
  transition: var(--transition);
}

.nav {
  min-height: 102px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
}

.logo {
  display: inline-flex;
  align-items: center;
  order: 1;
}

.logo img {
  display: block;
  width: auto;
  height: 80px;
  object-fit: contain;
}

.logo-text {
  font-weight: 800;
  font-size: 24px;
  color: var(--dark-slate);
  letter-spacing: -0.5px;
  display: flex;
  align-items: center;
  gap: 8px;
}

.logo-text span {
  color: var(--primary-dark);
}

.menu {
  display: flex;
  order: 2;
  margin-inline-start: auto;
  gap: 26px;
  align-items: center;
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 0.06em;
}

.menu a {
  position: relative;
  color: var(--muted);
  padding: 8px 0;
}

.menu a::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  width: 0;
  height: 1px;
  background-color: var(--accent);
  transition: var(--transition);
}

.menu a:hover {
  color: var(--dark-slate);
}

.menu a:hover::after,
.menu a.active::after {
  width: 100%;
}

.menu a.active {
  color: var(--primary-dark);
  font-weight: 700;
}

.nav-actions {
  display: flex;
  order: 3;
  align-items: center;
  gap: 16px;
}

.language-switch {
  border: 1px solid var(--primary-dark);
  border-radius: 999px;
  padding: 7px 15px;
  color: var(--primary-dark);
  font-size: 13px;
  font-weight: 600;
  white-space: nowrap;
  transition: var(--transition);
  background: transparent;
}

.language-switch:hover {
  background: var(--primary-dark);
  color: white;
}

.mobile-btn {
  display: none;
  border: 1px solid var(--border);
  background: white;
  padding: 8px 14px;
  border-radius: 8px;
  cursor: pointer;
  font-weight: 600;
  color: var(--dark-slate);
  transition: var(--transition);
}

.mobile-btn:hover {
  background: var(--soft);
}

/* Hero Section */
.hero {
  min-height: 620px;
  position: relative;
  overflow: hidden;
  background: var(--dark-slate);
  color: white;
}

.hero-slides {
  min-height: inherit;
  position: relative;
}

.hero-slide {
  position: absolute;
  inset: 0;
  display: grid;
  align-items: center;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.8s cubic-bezier(0.4, 0, 0.2, 1);
  background: 
    linear-gradient(90deg, rgba(12, 27, 39, 0.97) 8%, rgba(12, 27, 39, 0.84) 58%, rgba(12, 27, 39, 0.46)),
    var(--slide-image);
  background-size: cover;
  background-position: center;
}

.hero-slide.is-active {
  z-index: 1;
  opacity: 1;
  pointer-events: auto;
}

.hero-slide .container {
  position: relative;
  z-index: 2;
  transform: translateY(20px);
  transition: transform 0.8s ease;
}

.hero-slide.is-active .container {
  transform: translateY(0);
}

.hero h1,
.hero h2 {
  max-width: 850px;
  font-size: clamp(40px, 5vw, 66px);
  line-height: 1.08;
  font-weight: 800;
  margin-bottom: 20px;
  letter-spacing: -0.045em;
  text-shadow: 0 3px 18px rgba(0, 0, 0, 0.38);
}

.hero h1 span,
.hero h2 span {
  color: var(--primary);
}

.hero p {
  max-width: 650px;
  font-size: clamp(16px, 2.5vw, 20px);
  margin-bottom: 35px;
  color: #eef3f6;
  font-weight: 500;
  line-height: 1.75;
  text-shadow: 0 2px 12px rgba(0, 0, 0, 0.45);
}

.hero-controls {
  position: absolute;
  z-index: 10;
  left: 50%;
  bottom: 24px;
  display: flex;
  gap: 8px;
  transform: translateX(-50%);
}

.hero-dot {
  width: 40px;
  height: 40px;
  padding: 0;
  border: 0;
  background: transparent;
  cursor: pointer;
  display: grid;
  place-items: center;
}

.hero-dot::before {
  content: '';
  width: 12px;
  height: 6px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.4);
  transition: width 0.3s ease, background 0.3s ease;
}

.hero-dot.is-active::before {
  width: 28px;
  background: var(--primary);
}

/* Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: var(--primary-dark);
  color: white;
  padding: 13px 28px;
  border-radius: 8px;
  font-weight: 700;
  box-shadow: 0 10px 24px rgba(18, 46, 65, 0.2);
  border: none;
  cursor: pointer;
  font-size: 14px;
  letter-spacing: 0.02em;
  transition: var(--transition);
}

.btn:hover {
  transform: translateY(-1px);
  box-shadow: 0 14px 28px rgba(18, 46, 65, 0.28);
  background: #0f2636;
}

.btn.light {
  background: white;
  color: var(--dark-slate);
  box-shadow: 0 10px 25px rgba(0, 0, 0, 0.05);
}

.btn.light:hover {
  background: var(--primary-light);
  color: var(--primary-dark);
}

.cta-row {
  display: flex;
  justify-content: center;
  margin-top: 40px;
}

/* Sections */
.section {
  padding: 88px 0;
}

.section.soft {
  background: var(--soft);
}

.section-title {
  max-width: 800px;
  margin-bottom: 42px;
}

.section-title h2 {
  font-size: clamp(30px, 3.6vw, 43px);
  font-weight: 800;
  letter-spacing: -0.035em;
  color: var(--dark-slate);
  margin-bottom: 12px;
}

.section-title h2 span {
  color: var(--primary-dark);
}

.section-title p {
  color: var(--muted);
  font-size: 18px;
  font-weight: 400;
  line-height: 1.75;
}

/* Grids & Cards */
.grid {
  display: grid;
  gap: 24px;
}

.grid.cards-2 { grid-template-columns: repeat(2, 1fr); }
.grid.cards-3 { grid-template-columns: repeat(3, 1fr); }
.grid.cards-4 { grid-template-columns: repeat(4, 1fr); }

.card {
  background: white;
  border: 1px solid var(--border);
  border-radius: 14px;
  padding: 32px;
  box-shadow: 0 12px 34px rgba(24, 36, 46, 0.035);
  transition: var(--transition);
  display: flex;
  flex-direction: column;
}

.card:hover {
  transform: translateY(-4px);
  box-shadow: 0 18px 42px rgba(24, 36, 46, 0.08);
  border-color: #cbd8e1;
}

.card-icon {
  width: 52px;
  height: 52px;
  background: var(--primary-light);
  color: var(--primary-dark);
  border-radius: 10px;
  display: grid;
  place-items: center;
  margin-bottom: 24px;
  font-size: 20px;
  font-weight: 700;
}

.card h3 {
  font-size: 22px;
  font-weight: 700;
  margin-bottom: 12px;
  color: var(--dark-slate);
}

.card p {
  color: var(--muted);
  font-size: 15px;
  flex-grow: 1;
}

/* Category Cards (Images) */
.category-card {
  display: flex;
  flex-direction: column;
  overflow: hidden;
  padding: 0;
  border-radius: 14px;
}

.category-card img {
  display: block;
  width: 100%;
  height: 220px;
  object-fit: cover;
  transition: transform 0.5s ease;
}

.category-card:hover img {
  transform: scale(1.035);
}

.category-card-body {
  padding: 30px;
  flex-grow: 1;
  display: flex;
  flex-direction: column;
}

.category-card-body h3 {
  font-size: 20px;
  margin-bottom: 10px;
  transition: var(--transition);
}

.category-card:hover h3 {
  color: var(--primary-dark);
}

/* Category Hero Layout */
.category-hero-grid {
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  align-items: center;
  gap: 56px;
}

.form-layout-grid {
  align-items: start;
}

.editorial-grid {
  align-items: start;
}

.category-hero-image {
  width: 100%;
  height: auto;
  border-radius: 14px;
  box-shadow: 0 20px 48px rgba(24, 36, 46, 0.09);
}

.category-hero-grid > div > img {
  display: block;
  width: 100%;
  aspect-ratio: 3 / 2;
  object-fit: cover;
  border-radius: 14px;
  box-shadow: 0 20px 48px rgba(24, 36, 46, 0.09);
}

.product-list {
  margin-top: 20px;
  padding-left: 20px;
  color: var(--muted);
}

.product-list li {
  margin-bottom: 10px;
  font-size: 16px;
}

.product-list a {
  color: var(--primary-dark);
  font-weight: 600;
}

.product-list a:hover {
  color: var(--primary);
  text-decoration: underline;
}

.product-list.columns {
  columns: 2;
  column-gap: 40px;
}

/* Stats Section */
.stats {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 30px;
}

.stat {
  text-align: center;
  padding: 40px 20px;
  border-radius: 12px;
  background: white;
  border: 1px solid var(--border);
  box-shadow: 0 12px 30px rgba(24, 36, 46, 0.03);
}

.stat strong {
  display: block;
  font-size: 48px;
  font-weight: 800;
  color: var(--primary-dark);
  margin-bottom: 8px;
}

.stat span {
  color: var(--muted);
  font-size: 15px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 1px;
}

/* Footer styling */
.footer {
  background: linear-gradient(145deg, #173247, #0f1e2a);
  color: white;
  padding: 80px 0 30px;
  border-top: 1px solid var(--accent);
}

.footer p {
  color: #bdc3c7;
  margin-top: 10px;
  font-size: 15px;
}

.footer-grid {
  display: grid;
  grid-template-columns: 1.5fr 1fr 1.2fr;
  gap: 50px;
  margin-bottom: 50px;
}

.footer h3,
.footer h4 {
  color: white;
  margin-bottom: 20px;
  font-weight: 600;
  letter-spacing: 0.02em;
}

.footer-logo {
  display: inline-block;
  margin-bottom: 16px;
  transition: opacity 0.2s ease;
}

.footer-logo img {
  display: block;
  width: auto;
  height: 84px;
}

.footer .footer-logo:hover {
  padding: 0;
  opacity: 0.88;
}

.footer-logo-subtext {
  max-width: 360px;
  line-height: 1.8;
}

.footer-links {
  display: grid;
  gap: 12px;
}

.footer a {
  color: #d5dbdb;
  font-size: 15px;
}

.footer a:hover {
  color: var(--accent);
  padding-left: 5px;
}

.footer-contact-info p {
  margin-bottom: 12px;
  display: flex;
  align-items: flex-start;
  gap: 10px;
}

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

.footer-contact-info a:hover {
  color: var(--accent);
}

.footer-bottom {
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  padding-top: 30px;
  text-align: center;
  color: #89939a;
  font-size: 14px;
}

/* Page Hero */
.page-hero {
  min-height: 390px;
  display: grid;
  align-items: center;
  background: 
    linear-gradient(90deg, rgba(252, 251, 248, 0.99) 4%, rgba(252, 251, 248, 0.96) 48%, rgba(252, 251, 248, 0.76) 76%, rgba(252, 251, 248, 0.34)),
    var(--page-hero-image);
  background-size: cover;
  background-position: center;
  border-bottom: 1px solid var(--border);
  padding: 60px 0;
}

.page-hero > .container {
  width: 100%;
  position: relative;
  z-index: 1;
}

.page-hero h1 {
  font-size: clamp(36px, 4.6vw, 52px);
  font-weight: 800;
  color: var(--dark-slate);
  margin-bottom: 12px;
  letter-spacing: -0.04em;
  line-height: 1.14;
  text-shadow: 0 1px 0 rgba(255, 255, 255, 0.9);
}

.page-hero h1 span {
  color: var(--primary-dark);
}

.page-hero p {
  max-width: 680px;
  font-size: 18px;
  color: #334654;
  font-weight: 500;
  line-height: 1.8;
  padding: 15px 18px;
  background: rgba(252, 251, 248, 0.82);
  border: 1px solid rgba(23, 50, 71, 0.1);
  border-inline-start: 4px solid var(--primary);
  border-radius: 10px;
  box-shadow: 0 12px 32px rgba(15, 38, 54, 0.08);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
}

/* Forms */
.form {
  display: grid;
  gap: 20px;
  max-width: 700px;
  background: var(--soft);
  padding: 36px;
  border-radius: 14px;
  border: 1px solid var(--border);
  box-shadow: 0 14px 36px rgba(24, 36, 46, 0.045);
}

.form-group {
  display: grid;
  gap: 8px;
}

.form-group label {
  font-weight: 600;
  font-size: 14px;
  color: var(--dark-slate);
}

.form input,
.form textarea,
.form select {
  width: 100%;
  padding: 14px 18px;
  border: 1px solid var(--border);
  border-radius: 8px;
  font-family: inherit;
  font-size: 15px;
  background: white;
  outline: none;
  transition: var(--transition);
}

.form input:focus,
.form textarea:focus,
.form select:focus {
  border-color: var(--primary);
  box-shadow: 0 0 0 3px var(--primary-light);
}

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

.form-message {
  display: none;
  padding: 16px;
  border-radius: 12px;
  font-weight: 600;
  font-size: 15px;
}

.form-message.success,
.form-message.error {
  display: block;
}

.form-message.success {
  color: #196f3d;
  background: #e8f8f5;
  border: 1px solid #a3e4d7;
}

.form-message.error {
  color: #943126;
  background: #fdf2e9;
  border: 1px solid #f5cba7;
}

/* Arabic RTL Styles overrides */
[dir="rtl"] body {
  font-family: 'Noto Sans Arabic', 'Manrope', sans-serif;
  text-align: right;
}

[dir="rtl"] .section-title,
[dir="rtl"] .card,
[dir="rtl"] .form,
[dir="rtl"] .form-group,
[dir="rtl"] .category-card-body {
  text-align: right;
}

[dir="rtl"] .section-title {
  margin-right: 0;
  margin-left: auto;
}

[dir="rtl"] .card-icon {
  align-self: flex-start;
}

[dir="rtl"] .menu {
  flex-direction: row;
}

[dir="rtl"] .menu a::after {
  right: 0;
  left: auto;
}

[dir="rtl"] .hero-slide,
[dir="rtl"] .page-hero {
  background: 
    linear-gradient(270deg, rgba(12, 27, 39, 0.97) 8%, rgba(12, 27, 39, 0.84) 58%, rgba(12, 27, 39, 0.46)),
    var(--slide-image);
  background-size: cover;
  background-position: center;
}

[dir="rtl"] .page-hero {
  background: 
    linear-gradient(270deg, rgba(252, 251, 248, 0.99) 4%, rgba(252, 251, 248, 0.96) 48%, rgba(252, 251, 248, 0.76) 76%, rgba(252, 251, 248, 0.34)),
    var(--page-hero-image);
  background-size: cover;
  background-position: center;
}

[dir="rtl"] .hero h1,
[dir="rtl"] .hero h2,
[dir="rtl"] .hero p,
[dir="rtl"] .page-hero p {
  margin-right: 0;
  margin-left: auto;
}

[dir="rtl"] .product-list {
  padding-left: 0;
  padding-right: 20px;
}

[dir="rtl"] .footer-contact-info p {
  gap: 10px;
}

[dir="rtl"] .footer a:hover {
  padding-left: 0;
  padding-right: 5px;
}

[dir="rtl"] input,
[dir="rtl"] textarea,
[dir="rtl"] select {
  direction: rtl;
  text-align: right;
}

[dir="rtl"] input[type="email"],
[dir="rtl"] input[type="tel"] {
  direction: ltr;
  text-align: right;
}

[dir="rtl"] a[href^="tel:"] {
  direction: ltr;
  unicode-bidi: isolate;
  display: inline-block;
  text-align: left;
}

/* Responsive Styles */
@media (max-width: 992px) {
  .nav {
    min-height: 92px;
  }

  .logo img {
    height: 68px;
  }

  .footer-logo img {
    height: 76px;
  }
  
  .mobile-btn {
    display: block;
  }
  
  .menu {
    display: none;
    position: absolute;
    left: 24px;
    right: 24px;
    top: 97px;
    flex-direction: column;
    align-items: stretch;
    background: white;
    border: 1px solid var(--border);
    border-radius: 10px;
    padding: 24px;
    box-shadow: 0 16px 36px rgba(24, 36, 46, 0.1);
    gap: 16px;
    margin-inline-start: 0;
  }

  .nav-actions {
    margin-inline-start: auto;
  }
  
  .menu.open {
    display: flex;
  }

  [dir="rtl"] .menu {
    flex-direction: column;
    align-items: stretch;
    text-align: right;
  }
  
  .menu a::after {
    display: none;
  }
  
  .menu a {
    padding: 8px 0;
    border-bottom: 1px solid var(--border);
  }
  
  .menu a:last-child {
    border-bottom: none;
  }
  
  .grid.cards-2,
  .grid.cards-3,
  .grid.cards-4,
  .stats,
  .footer-grid {
    grid-template-columns: 1fr;
    gap: 24px;
  }
  
  .category-hero-grid {
    grid-template-columns: 1fr;
    gap: 30px;
  }
  
  .product-list.columns {
    columns: 1;
  }

  .hero-slide {
    background:
      linear-gradient(90deg, rgba(12, 27, 39, 0.97), rgba(12, 27, 39, 0.88) 72%, rgba(12, 27, 39, 0.68)),
      var(--slide-image);
    background-size: cover;
    background-position: center;
  }

  [dir="rtl"] .hero-slide {
    background:
      linear-gradient(270deg, rgba(12, 27, 39, 0.97), rgba(12, 27, 39, 0.88) 72%, rgba(12, 27, 39, 0.68)),
      var(--slide-image);
    background-size: cover;
    background-position: center;
  }

  .page-hero {
    min-height: 340px;
    padding: 48px 0;
    background:
      linear-gradient(90deg, rgba(252, 251, 248, 0.98), rgba(252, 251, 248, 0.88)),
      var(--page-hero-image);
    background-size: cover;
    background-position: center;
  }

  [dir="rtl"] .page-hero {
    background:
      linear-gradient(270deg, rgba(252, 251, 248, 0.98), rgba(252, 251, 248, 0.88)),
      var(--page-hero-image);
    background-size: cover;
    background-position: center;
  }

  .page-hero p {
    max-width: 620px;
    font-size: 17px;
    padding: 14px 16px;
  }
}

@media (max-width: 600px) {
  .hero {
    min-height: 560px;
  }

  .hero h1,
  .hero h2 {
    font-size: 38px;
    line-height: 1.14;
  }

  .hero p {
    font-size: 16px;
    line-height: 1.7;
  }

  .page-hero {
    min-height: 320px;
  }

  .page-hero h1 {
    font-size: 36px;
  }

  .page-hero p {
    font-size: 16px;
    line-height: 1.75;
  }
}
