/* Modern main action button style */
/* ميجا منيو للجوال */
.mega-mobile {
  display: none;
}

@media (max-width: 860px) {
  .mega-mobile {
    display: none !important;
    opacity: 0;
    visibility: hidden;
    pointer-events: none !important;
  }
  .mega-mobile.active {
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
  }
  .nav-list {
    display: none !important;
  }
  .nav-list.active {
    display: flex !important;
    flex-direction: column;
    width: 100%;
    padding: 0;
    margin: 0;
    gap: 0;
  }
}
.btn,
.btn.btn-primary {
  background: #1176e7;
  color: #fff;
  border: none;
  border-radius: 18px;
  padding: 0.7em 2.2em;
  font-size: 1.25em;
  font-weight: 800;
  box-shadow: 0 2px 16px 0 rgba(17, 118, 231, 0.18);
  cursor: pointer;
  transition: background 0.18s, box-shadow 0.18s;
  display: inline-block;
  text-align: center;
  margin: 0 auto;
}
.btn:hover,
.btn.btn-primary:hover {
  background: #0d5fc4;
  color: #fff;
  box-shadow: 0 4px 24px 0 rgba(17, 118, 231, 0.22);
}
/* About section card modern style */
.about-flex{
  display: flex;
  gap: 60px;
  align-items: center;
  flex-wrap: wrap;
  margin-top: 60px;
}

/* RTL / LTR */
.about-flex.rtl{ flex-direction: row-reverse; }
.about-flex.ltr{ flex-direction: row; }


/* TEXT CARD */
.about-card{
  max-width: 460px;
  background: linear-gradient(160deg, rgba(255,255,255,.08), rgba(255,255,255,.02));
  border: 1px solid rgba(255,255,255,.12);
  border-radius: 26px;
  padding: 36px 32px;
  color: #e6eef8;
  box-shadow: 0 20px 60px rgba(0,0,0,.45);
  backdrop-filter: blur(10px);
}

/* TITLE */
.about-card h2{
  font-size: 1.9rem;
  font-weight: 800;
  margin-bottom: 16px;
  color: #fff;
}

/* TEXT */
.about-card p{
  font-size: 1.05rem;
  line-height: 1.8;
  color: #cfd9e6;
  margin-bottom: 18px;
}

/* BUTTON */
.about-btn{
  display: inline-block;
  margin-top: 10px;
  padding: 14px 26px;
  border-radius: 16px;
  background: linear-gradient(135deg, #0b6bd6, #12b3c7);
  color: #fff;
  font-weight: 800;
  text-decoration: none;
  box-shadow: 0 18px 40px rgba(11,107,214,.35);
  transition: transform .25s ease, box-shadow .25s ease;
}

.about-btn:hover{
  transform: translateY(-3px);
  box-shadow: 0 26px 55px rgba(11,107,214,.45);
}

/* About section flex layout improvements */

/* Modern Contact Details Card */
.card.contact-details {
  background: var(--contact-card-bg, #fff);
  border: 1.5px solid var(--contact-card-border, #e0e0e0);
  border-radius: 18px;
  box-shadow: 0 2px 12px 0 rgba(25, 118, 210, 0.07);
  padding: 1.7em 1.3em 1.3em 1.3em;
  margin-top: 0.5em;
  margin-bottom: 0.5em;
  color: var(--contact-card-text, #222);
}

:root {
  --contact-card-bg: #fff;
  --contact-card-border: #e0e0e0;
  --contact-card-text: #222;
  --contact-card-muted: #3a4a5d;
  --contact-card-label: #1a2233;
  --contact-card-sep: #e0e0e0;
}

[data-theme="dark"] .card.contact-details,
.dark-mode .card.contact-details {
  --contact-card-bg: rgba(18, 32, 47, 0.97);
  --contact-card-border: #23344a;
  --contact-card-text: #fff;
  --contact-card-muted: #c3d0e6;
  --contact-card-label: #c3d0e6;
  --contact-card-sep: #23344a;
}

.card.contact-details h3 {
  font-size: 1.13em;
  font-weight: 700;
  color: var(--contact-card-text);
  margin-bottom: 0.5em;
  display: flex;
  align-items: center;
  gap: 0.5em;
}
.card.contact-details .muted {
  color: var(--contact-card-muted);
  font-size: 1em;
  margin-bottom: 0.7em;
}
.contact-info-row {
  display: flex;
  align-items: center;
  gap: 0.7em;
  margin-bottom: 0.5em;
  color: var(--contact-card-text);
}
.contact-info-row .icon {
  font-size: 1.25em;
  color: #1976d2;
  min-width: 1.5em;
  text-align: center;
}
.contact-info-row a {
  color: #1976d2;
  font-weight: 600;
  text-decoration: none;
  transition: color 0.2s;
}
.contact-info-row a:hover {
  color: #0d47a1;
}
.contact-info-label {
  font-weight: 500;
  min-width: 4.5em;
  color: var(--contact-card-label);
}
.contact-info-value {
  font-family: 'Tajawal', Arial, sans-serif;
  font-size: 1.08em;
  color: var(--contact-card-text);
}
.contact-info-value .whatsapp {
  color: #19c37d;
  font-weight: bold;
  font-size: 1.09em;
}
.contact-info-value a {
  color: #19c37d;
  font-weight: bold;
  text-decoration: none;
  font-size: 1.09em;
}
.contact-info-value a:hover {
  text-decoration: underline;
}
.section-sep {
  border: none;
  border-top: 1px solid var(--contact-card-sep);
  margin: 1.1em 0 1em 0;
}
/* Shake animation for Contact card */
.card.shake {
  animation: shakeCard 0.5s cubic-bezier(.36,.07,.19,.97) both;
}
@keyframes shakeCard {
  10%, 90% { transform: translateX(-2px); }
  20%, 80% { transform: translateX(4px); }
  30%, 50%, 70% { transform: translateX(-8px); }
  40%, 60% { transform: translateX(8px); }
}
.card#quote select, #quote.card select, .card#contact select, #contact.card select {
  height: 40px !important;
  min-height: 40px !important;
  padding: 7px 8px;
  font-size: 0.97rem;
  border-radius: 8px;
}
.card#quote textarea, #quote.card textarea, .card#contact textarea, #contact.card textarea {
  min-height: 48px !important;
  max-height: 80px !important;
  font-size: 0.97rem;
  padding: 7px 8px;
  border-radius: 8px;
}
.card#quote input, #quote.card input, .card#contact input, #contact.card input {
  height: 38px !important;
  min-height: 32px !important;
  max-height: 42px !important;
}


/* ===================== RESPONSIVE FIXES ===================== */
@media (max-width: 900px) {
  .container {
    width: 98%;
    padding: 0 6px;
  }
  .nav-wrap {
    padding: 0 10px;
    gap: 10px;
  }
  .brand {
    font-size: 1.1rem;
    gap: 6px;
  }
  .site-header {
    min-height: 64px;
  }
}

@media (max-width: 700px) {
  .site-header {
    min-height: 54px;
    padding: 0;
  }
  .nav-wrap {
    flex-direction: column;
    height: auto;
    gap: 0;
    padding: 0 2px;
  }
  .brand {
    font-size: 1rem;
    margin: 0;
    gap: 4px;
  }
  .nav {
    flex-direction: column;
    gap: 0;
    width: 100%;
    align-items: flex-start;
  }
  .nav-list {
    flex-direction: column;
    gap: 0;
    width: 100%;
    align-items: flex-start;
    background: none;
    padding: 0;
  }
  .nav-link, .icon-btn {
    width: 100%;
    text-align: right;
    padding: 10px 8px;
    font-size: 1rem;
    border-radius: 0;
  }
  .nav-actions {
    margin: 0;
    gap: 6px;
  }
  .tools-cards {
    flex-direction: column;
    gap: 18px;
    align-items: stretch;
  }
  .tool-card {
    min-width: 0;
    max-width: 100%;
    width: 100%;
    padding: 18px 8px 16px 8px;
    font-size: 0.98rem;
  }
  .card#calculator, #calculator.card {
    max-width: 100%;
    padding: 18px 8px 16px 8px;
  }
  .gallery-grid {
    grid-template-columns: 1fr;
    gap: 10px;
  }
  .footer-grid {
    grid-template-columns: 1fr;
    text-align: center;
    gap: 10px;
  }
}

@media (max-width: 480px) {
  .site-header {
    min-height: 44px;
  }
  .brand {
    font-size: 0.92rem;
  }
  .tool-card, .card#calculator, #calculator.card {
    font-size: 0.93rem;
    padding: 10px 2px 10px 2px;
  }
}
/* شريط Call To Action عصري */
.contact-strip, .cta-strip, .quote-strip {
  background: linear-gradient(90deg, #0b2239 60%, #0b6bd6 100%);
  border-radius: 32px;
  box-shadow: 0 4px 24px 0 rgba(11, 34, 57, 0.13);
  border: none;
  padding: 32px 38px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 32px;
  margin: 32px 0;
  color: #fff;
  position: relative;
}
.contact-strip .left, .cta-strip .left, .quote-strip .left {
  display: flex;
  flex-direction: column;
  gap: 8px;
  align-items: flex-end;
}
.contact-strip .right, .cta-strip .right, .quote-strip .right {
  display: flex;
  gap: 18px;
  align-items: center;
}
.contact-strip h2, .cta-strip h2, .quote-strip h2 {
  font-size: 1.45rem;
  font-weight: 900;
  margin-bottom: 6px;
  color: #fff;
  letter-spacing: 0.5px;
}
.contact-strip p, .cta-strip p, .quote-strip p {
  color: #e0f6ff;
  font-size: 1.08rem;
  margin-bottom: 0;
}
.contact-strip .btn, .cta-strip .btn, .quote-strip .btn {
  background: linear-gradient(90deg, #2196f3 60%, #0b6bd6 100%);
  color: #fff;
  border: none;
  border-radius: 14px;
  font-size: 1.08rem;
  font-weight: 800;
  padding: 14px 32px;
  box-shadow: 0 2px 12px rgba(11,107,214,.13);
  transition: background 0.18s, box-shadow 0.18s;
}
.contact-strip .btn:hover, .cta-strip .btn:hover, .quote-strip .btn:hover {
  background: linear-gradient(90deg, #0b6bd6 60%, #2196f3 100%);
  box-shadow: 0 8px 32px 0 rgba(25, 118, 210, 0.18);
}
@media (max-width: 700px) {
  .contact-strip, .cta-strip, .quote-strip {
    flex-direction: column;
    align-items: stretch;
    padding: 18px 8px;
    gap: 16px;
    border-radius: 18px;
  }
  .contact-strip .left, .cta-strip .left, .quote-strip .left {
    align-items: flex-start;
    text-align: right;
  }
  .contact-strip .right, .cta-strip .right, .quote-strip .right {
    justify-content: flex-end;
  }
}


/* حقل رقم التتبع داخل كارت تتبع الشحنة: input صغير سطر واحد فقط */
.card#tracking input,
#tracking.card input {
  margin: 40px auto 12px auto !important;
  display: block;
  width: 80% !important;
  min-width: 120px !important;
  max-width: 100% !important;
  height: 38px !important;
  min-height: 28px !important;
  max-height: 42px !important;
  resize: none !important;
  padding: 6px 12px !important;
  font-size: 1.18rem !important;
  font-weight: 700 !important;
  box-sizing: border-box;
  margin: 0 auto 12px auto;
  border-radius: 8px;
  line-height: 1.2 !important;
  overflow-y: hidden !important;
}
/* منع تمدد أي textarea داخل كارت التتبع (لو وُجد) */
.card#tracking textarea,
#tracking.card textarea {
  height: 38px !important;
  min-height: 28px !important;
  max-height: 42px !important;
  resize: none !important;
  overflow-y: hidden !important;
  font-size: 1.18rem !important;
  font-weight: 700 !important;
  border-radius: 8px;
  line-height: 1.2 !important;
}


/* Move services section lower below hero */
#services {
  margin-top: 40px;
}
.site-header {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  z-index: 1000;
  background: transparent;
  box-shadow: none;
  backdrop-filter: none;
  -webkit-backdrop-filter: none;
  border-bottom: none;
  min-height: 90px;
  transition: background .25s ease, box-shadow .25s ease, backdrop-filter .25s ease;
}

header.scrolled {
  background: rgba(255,255,255,.85) !important;
  backdrop-filter: blur(10px);
  box-shadow: 0 6px 18px rgba(0,0,0,.08);
}

body, .main-bg {
  background: var(--bg);
  background-color: var(--bg);
  color: var(--text);
  min-height: 72px;
}

.nav-wrap {
  height: 72px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 32px;
  padding: 0 48px;
}
.brand {
  display: flex;
  align-items: center;
  gap: 8px;
  font-weight: 700;
  font-size: 1.15rem;
  color: #fff;
  text-shadow: 0 2px 8px rgba(0,0,0,0.18);
  text-decoration: none;
  margin-left: 0;
}
.brand-mark {
  margin-right: 8px;
  color: #12b3c7;
  font-size: 1.3rem;
}
.brand-text {
  font-weight: 700;
  letter-spacing: 0.2px;
  font-size: 1em;
  color: #fff;
  text-shadow: 0 1px 4px rgba(0,0,0,0.10);
}
.nav {
  display: flex;
  align-items: center;
  flex: 1;
  justify-content: center;
}
.nav-wrap {
  height: 90px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 32px;
  background: none !important;
  box-shadow: none !important;
  border: none !important;
  flex-direction: row-reverse;
}
.brand {
  display: flex;
  align-items: center;
  gap: 14px;
  font-weight: 900;
  font-size: 2.1rem;
  color: #fff;
  text-decoration: none;
  margin-left: 18px;
}
.brand-mark {
  margin-left: 8px;
  color: #12b3c7;
}
.brand-text {
  font-weight: 900;
  letter-spacing: 1px;
}
.nav {
  display: flex;
  align-items: center;
  flex: 1;
  justify-content: center;
}
.nav-list {
  display: flex;
  align-items: center;
  gap: 18px;
  list-style: none;
  margin: 0;
  padding: 0;
}
.nav-actions {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-right: 12px;
}
.nav-link, .icon-btn {
  font-size: 1.15rem;
  color: #fff;
  font-weight: 700;
  background: none;
  border: none;
  padding: 0.28rem 0.8rem;
  border-radius: 8px;
  transition: background 0.2s;
  text-shadow: 0 2px 8px rgba(0,0,0,0.18);
}
.icon-btn:hover, .nav-link:hover {
  background: rgba(255,255,255,0.08);
}

.icon-btn {
  background: none;
  border: none;
  font-size: 1.1rem;
  cursor: pointer;
  color: #0b2239;
  padding: 0.3rem 0.7rem;
  border-radius: 6px;
  transition: background 0.2s;
}
.icon-btn:hover {
  background: #e9f2ff;
}
/* --- Modern Hero Section Inspired by swiftexpressly.com --- */
.hero-bg-modern {
  width: 100vw;
  height: 100vh;
  min-height: 520px;
  background: url('../hero.jpg') center center/cover no-repeat;
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: none;
  margin-top: -90px;
  padding-top: 90px;
  border-radius: 0;
}
.hero-bg-modern::before {
  content: "";
  position: absolute;
  inset: 0;
  background:
    linear-gradient(180deg, rgba(0,0,0,0.55), rgba(0,0,0,0.28));
  pointer-events: none;
}
.hero-content-modern {
  position: relative;
  z-index: 2;
}
.site-header {
  position: sticky;
  top: 0;
  z-index: 60;
  background: transparent !important;
  border-bottom: none !important;
  box-shadow: none !important;
  backdrop-filter: none !important;
}
.nav-wrap {
  background: transparent !important;
  box-shadow: none !important;
  border: none !important;
}
.nav-list, .brand, .nav-actions, .nav-link, .icon-btn {
  text-shadow: 0 2px 12px rgba(0,0,0,0.18);
}
.hero-content-modern {
  text-align: center;
  color: #0b2239;
  padding: 64px 0 48px 0;
  position: relative;
  z-index: 2;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  width: 100%;
  max-width: 700px;
}
.hero-title-modern {
  font-size: 2.8rem;
  font-weight: 900;
  margin-bottom: 18px;
  letter-spacing: 0.5px;
  line-height: 1.15;
  color: #fcfcfc;
  text-shadow: 0 10px 28px rgba(0,0,0,0.55);
}
.hero-desc-modern {
  font-size: 1.25rem;
  margin-bottom: 28px;
  color: rgba(255,255,255,0.92);
  opacity: 1;
  text-shadow: 0 6px 18px rgba(0,0,0,0.45);
}
.hero-cta-modern {
  margin-bottom: 22px;
  font-size: 1.12rem;
  padding: 14px 38px;
  border-radius: 12px;
  font-weight: 700;
  background: var(--primary);
  color: #fff;
  box-shadow: 0 2px 12px rgba(11,34,57,0.08);
  transition: background 0.2s, color 0.2s;
}
.hero-cta-modern:hover {
  background: var(--primary2);
  color: #fff;
}
.hero-features-modern {
  margin-top: 14px;
  margin-bottom: 0;
  color: rgba(255,255,255,0.92);
  font-size: 1.08rem;
  font-weight: 600;
  opacity: 0.92;
  display: flex;
  justify-content: center;
  gap: 12px;
}
/* --- Hero Section Professional Design --- */
.hero-content {
  text-align: center;
  color: #fff;
  padding: 48px 0 32px 0;
  position: relative;
  z-index: 2;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  height: 700px;
  width: 100%;
  background: rgba(0,0,0,0.18);
}
.hero h1 {
  font-size: 2.2rem;
  font-weight: 900;
  margin-bottom: 12px;
  letter-spacing: 0.5px;
  line-height: 1.2;
  text-shadow: 0 2px 16px rgba(0,0,0,0.18);
}
.hero-desc {
  font-size: 1.15rem;
  margin-bottom: 22px;
  opacity: 0.95;
  color: #f2f2f2;
  text-shadow: 0 1px 8px rgba(0,0,0,0.13);
}
.hero-cta {
  margin-bottom: 18px;
  font-size: 1.08rem;
  padding: 12px 32px;
}
.hero-features {
  margin-bottom: 18px;
  color: #e9f2ff;
  font-size: 1rem;
  font-weight: 600;
  opacity: 0.92;
  display: flex;
  justify-content: center;
  gap: 8px;
}
.scroll-indicator {
  font-size: 2rem;
  opacity: 0.85;
  margin-top: 18px;
  animation: bob 1.6s ease-in-out infinite;
}
@keyframes bob {
  0%,100%{transform:translateY(0)}
  50%{transform:translateY(8px)}
}
/* Hero fallback background if no image */
.hero-bg.noimg {
  background: linear-gradient(120deg, #e9f2ff 60%, #cbe6fa 100%);
  min-height: 320px;
  border-radius: 0 0 32px 32px;
}


/* --- Tools Cards Modern Design --- */
/* ===========================
   TOOLS SECTION
=========================== */

.tools-section{
  padding: 80px 0;
}

.tools-title{
  font-size: 2rem;
  font-weight: 800;
  color: #ffffff;
  margin-bottom: 10px;
}

.tools-desc{
  color: #b7d6f7;
  font-size: 1rem;
  margin-bottom: 40px;
}

/* Cards Container */
.tools-cards{
  display: flex;
  flex-wrap: wrap;
  gap: 32px;
  justify-content: center;
  margin: 32px 0 0 0;
  align-items: flex-start;
}

.tool-card{
  background: rgba(16, 32, 48, 0.92);
  border-radius: 18px;
  box-shadow: 0 4px 32px rgba(11,34,57,0.13);
  padding: 32px 28px 28px 28px;

  /* ✅ أهم تعديل: أحجام الكروت */
  flex: 0 1 360px;
  max-width: 420px;
  min-width: 280px;
  max-height: 420px;
  overflow: auto;

  color: #e9f2ff;
  border: 1.5px solid rgba(255,255,255,0.06);
  position: relative;
  transition: box-shadow 0.18s, transform 0.18s;
}

.tool-card:hover{
  box-shadow: 0 8px 40px 0 rgba(18,179,199,0.18);
  transform: translateY(-4px) scale(1.012);
}

/* Card Title */
.tool-card h3{
  font-size: 1.22rem;
  font-weight: 800;
  color: #fff;
  margin-bottom: 14px;
  display: flex;
  align-items: center;
  gap: 10px;
  letter-spacing: 0.5px;
}


.tool-card .card-desc{
  font-size: 1.05rem;
  line-height: 1.6;
  color: #e0f6ff;
  margin-bottom: 14px;
}

/* Divider */
.tool-card hr{
  border: none;
  border-top: 1px solid rgba(255,255,255,0.08);
  margin: 18px 0;
}

/* Labels */
.tool-card label{
  font-size: 1rem;
  font-weight: 700;
  color: #9ecbff;
  margin-bottom: 8px;
  display: block;
  letter-spacing: 0.2px;
}

/* Inputs */
.tool-card input,
.tool-card select{
  width: 100%;
  padding: 12px 16px;
  border-radius: 12px;
  border: 1px solid rgba(255,255,255,0.18);
  background: rgba(255,255,255,0.13);
  color: #fff;
  font-size: 1.05rem;
  margin-bottom: 16px;
  transition: border .18s, background .18s;
  outline: none;
}

.tool-card input::placeholder{
  color: #b7d6f7;
}

.tool-card input:focus,
.tool-card select:focus{
  outline: none;
  border-color: #12b3c7;
  background: rgba(18,179,199,0.12);
}

/* Button */
.tool-card button{
  width: 100%;
  padding: 14px 0;
  border-radius: 14px;
  border: none;
  cursor: pointer;
  background: linear-gradient(90deg, #0b6bd6, #12b3c7);
  color: #fff;
  font-weight: 800;
  font-size: 1.08rem;
  box-shadow: 0 10px 28px rgba(11,107,214,.35);
  transition: box-shadow .18s, transform .18s;
  margin-top: 8px;
}

.tool-card button:hover{
  transform: translateY(-2px);
  box-shadow: 0 18px 45px rgba(18,179,199,.45);
}

/* Lists (Document Status) */
.tool-card ul{
  padding-left: 18px;
  margin: 0;
  font-size: 1rem;
  color: #b7d6f7;
}

.tool-card ul li{
  margin-bottom: 6px;
}

/* Footer text */
.tool-card .card-footer{
  margin-top: 14px;
  font-size: 0.97rem;
  color: #b7d6f7;
  opacity: .92;
  color: #9fbfe6;
  opacity: .9;
}

/* Responsive */
@media (max-width: 800px){
  .tools-title{
    font-size: 1.6rem;
  }
}


:root {
  --bg: #f7fbff;
  --card: #ffffff;
  --text: #0b2239;
  --muted: #5b6b7b;
  --line: rgba(11,34,57,.10);
  --primary: #0b6bd6;
  --primary2: #12b3c7;
  --shadow: 0 18px 45px rgba(11,34,57,.12);
  --radius: 18px;
  --radius2: 26px;
  --navH: 76px;
}

[data-theme="dark"], .dark {
  --bg: #08131f;
  --card: #0c1c2e;
  --text: #e9f2ff;
  --muted: #a9b7c6;
  --line: rgba(255,255,255,.08);
  --primary: #12b3c7;
  --primary2: #0b6bd6;
  --shadow: 0 18px 45px rgba(0,0,0,.35);
}

/* Dark mode (optional toggle) */
[data-theme="dark"], .dark{
  --bg:#08131f;
  --card:#0c1c2e;
  --text:#e9f2ff;
  --muted:#a9b7c6;
  --line:rgba(255,255,255,.08);
  --shadow: 0 18px 45px rgba(0,0,0,.35);
}

*{box-sizing:border-box}
html,body{height:100%}
body {
  margin: 0;
  font-family: system-ui, -apple-system, Segoe UI, Roboto, Arial, sans-serif;
  font-size: 15px;
  line-height: 1.45;
  background: var(--bg);
  color: var(--text);
}

/* RTL support */
body.rtl{direction:rtl}
body.ltr{direction:ltr}

a{color:inherit;text-decoration:none}
.container{width:min(1150px, 92%); margin:0 auto}

.muted{color:var(--muted)}
hr.sep{border:0; border-top:1px solid var(--line); margin:22px 0}

/* Header */
.site-header{
  position:sticky; top:0; z-index:60;
  backdrop-filter: blur(14px);
  background: transparent !important;
  border: none !important;
}
.nav-wrap{
  height:var(--navH);
  display:flex; align-items:center; justify-content:space-between;
  gap:16px;
}
.brand{display:flex; align-items:center; gap:10px; font-weight:800}
.brand-mark{color:var(--primary)}
.brand-text{letter-spacing:.2px}

.nav{display:flex; align-items:center; gap:14px}
.nav-toggle{
  display:none;
  width:44px; height:44px;
  border:1px solid var(--line);
  background:var(--card);
  border-radius:1px;
  cursor:pointer;
  box-shadow: 0 10px 25px rgba(0,0,0,.06);
}
.nav-toggle span{
  display:block; height:2px; width:18px;
  background:var(--text); margin:4px auto;
  opacity:.9;
}

.nav-list{
  display:flex; align-items:center; gap:8px;
  list-style:none; padding:0; margin:0;
}
.nav-item{position:relative}
.nav-link{
  display:flex; align-items:center; gap:8px;
  padding:8px 10px;
  border-radius:14px;
  font-weight:650;
  font-size:.95rem;
  color:color-mix(in oklab, var(--text) 92%, var(--muted));
  transition:.18s ease;
}
/* Restored original style.css content */
:root{
  --bg:#f7fbff;
  --card:#ffffff;
  --text:#0b2239;
  --muted:#5b6b7b;
  --line:rgba(11,34,57,.10);

  --primary:#0b6bd6;
  --primary2:#12b3c7;
  --shadow: 0 18px 45px rgba(11,34,57,.12);

  --radius:18px;
  --radius2:26px;

  --navH: 76px;
}

/* Dark mode (optional toggle) */
[data-theme="dark"]{
  --bg:#08131f;
  --card:#0c1c2e;
  --text:#e9f2ff;
  --muted:#a9b7c6;
  --line:rgba(255,255,255,.08);
  --shadow: 0 18px 45px rgba(0,0,0,.35);
}

*{box-sizing:border-box}
html,body{height:100%}
body{
  margin:0;
  font-family: system-ui, -apple-system, Segoe UI, Roboto, Arial, sans-serif;
  background: radial-gradient(1200px 600px at 20% 0%, rgba(18,179,199,.18), transparent 60%),
              radial-gradient(900px 550px at 80% 10%, rgba(11,107,214,.16), transparent 55%),
              var(--bg);
  color:var(--text);
}

/* RTL support */
body.rtl{direction:rtl}
body.ltr{direction:ltr}


.container{width:min(1150px, 92%); margin:0 auto}

.muted{color:var(--muted)}
hr.sep{border:0; border-top:1px solid var(--line); margin:22px 0}

/* Header */
.site-header{
  position:sticky; top:0; z-index:60;
  backdrop-filter: blur(14px);
  background: rgba(255,255,255,0.9);
  border-bottom:1px solid var(--line);
}

[data-theme="dark"] .site-header,
body.dark .site-header {
  background: rgba(8,19,31,0.9);
  border-bottom: 1px solid rgba(255,255,255,0.08);
}

.site-header.scrolled {
  background: rgba(255,255,255,0.9);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid rgba(0,0,0,0.08);
  box-shadow: 0 10px 26px rgba(0,0,0,0.08);
}
.nav-wrap{
  height:var(--navH);
  display:flex; align-items:center; justify-content:space-between;
  gap:16px;
}
.brand{display:flex; align-items:center; gap:10px; font-weight:800}
.brand-mark{color:var(--primary)}
.brand-text{letter-spacing:.2px}

.nav{display:flex; align-items:center; gap:14px}
.nav-toggle{
  display:none;
  width:44px; height:44px;
  border:1px solid var(--line);
  background:var(--card);
  border-radius:14px;
  cursor:pointer;
  box-shadow: 0 10px 25px rgba(0,0,0,.06);
}
.nav-toggle span{
  display:block; height:2px; width:18px;
  background:var(--text); margin:4px auto;
  opacity:.9;
}

.nav-list{
  display:flex; align-items:center; gap:8px;
  list-style:none; padding:0; margin:0;
}
.nav-item{position:relative}
.nav-link{
  display:flex; align-items:center; gap:8px;
  padding:10px 12px;
  border-radius:14px;
  font-weight:650;
  color:color-mix(in oklab, var(--text) 92%, var(--muted));
  transition:.18s ease;
}
.nav-link:hover{
  background: color-mix(in oklab, var(--primary) 10%, transparent);
  color: var(--text);
}
.caret{font-size:12px; opacity:.7}
.nav-cta{
  background: linear-gradient(135deg, var(--primary), var(--primary2));
  color:#fff !important;
  box-shadow: 0 18px 35px rgba(11,107,214,.24);
}
.nav-cta:hover{filter:brightness(1.03)}

/* Actions right */
.nav-actions{display:flex; align-items:center; gap:10px}
.icon-btn{
  border:1px solid var(--line);
  background:var(--card);
  border-radius:14px;
  padding:10px 12px;
  cursor:pointer;
  font-weight:800;
  color:var(--text);
}

/* Mega Menu */
/* ===== MEGA MENU – CLEAN & CLEAR DESIGN ===== */

.mega {
  position: absolute;
  top: 100%;
  right: 0;
  margin-top: 18px;
  width: 480px;
  max-width: calc(100vw - 24px);
  background: rgba(24,32,44,0.96);
  border-radius: 18px;
  box-shadow: 0 18px 55px rgba(0,0,0,0.35);
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transform: translateY(12px);
  transition: .25s ease;
  z-index: 9999;
  max-height: calc(100vh - var(--navH) - 24px);
  overflow-y: auto;
  overflow-x: hidden;
}
.nav-item:hover > .mega,
.mega:hover {
  opacity: 1;
  visibility: visible;
  pointer-events: auto;

  transform: translateY(0);

  transition-delay: 0s; /* تظهر فورًا */
}

/* ===== INNER LAYOUT ===== */
.mega-inner{
  display: flex;
  flex-direction: column;
  gap: 0;
  padding: 22px 16px 12px 16px;
}


/* ===== COLUMNS ===== */
.mega-cols {
  display: flex;
  flex-direction: row;
  gap: 14px;
  align-items: flex-start;
  margin-bottom: 10px;
}
.mega-col{
  background: rgba(18,24,34,0.92);
  border-radius: 18px;
  padding: 10px 10px 10px 10px;
  min-width: 120px;
  flex: 1 1 0;
  box-shadow: 0 2px 12px rgba(0,0,0,.10);
  border: none !important;
}

body.rtl .mega-col{
  border-right: none;
  border-left: 1px solid #e6eaf0;
  padding-right: 0;
  padding-left: 20px;
}

.mega-col:last-child{
  border: none;
}

/* ===== TITLES ===== */
.mega-title{
  font-size: 1.05rem;
  font-weight: 800;
  color: var(--primary);
  margin-bottom: 12px;
}

/* ===== LINKS ===== */
.mega-links{
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 10px;
}

.mega-links a{
  display: flex;
  align-items: center;
  padding: 10px 12px;
  border-radius: 10px;
  color: #eff3f7;
  font-size: .95rem;
  transition: background .15s ease, color .15s ease;
}

.mega-links a:hover{
  background: #f2f6ff;
  color: var(--primary);
  font-weight: 600;
}

/* ===== HIGHLIGHT BOX ===== */
.mega-highlight{
  background: linear-gradient(160deg,#1a2330,#232d3c);
  border-radius: 18px;
  padding: 16px 12px 12px 12px;
  margin-top: 10px;
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 10px;
  box-shadow: 0 2px 12px rgba(161, 158, 158, 0.1);
  width: 100%;
  border: none;
}

/* Fix contrast inside the featured/highlight box */
.mega-highlight .mh-title{
  color: rgba(255,255,255,0.98);
}
.mega-highlight .mh-desc{
  color: rgba(255,255,255,0.80);
}

/* Home mega menu only: keep same layout (featured under), but make it shorter to avoid clipping */
.mega.mega-home .mega-inner{
  padding: 16px 14px 10px 14px;
}
.mega.mega-home .mega-cols{
  gap: 10px;
  margin-bottom: 8px;
}
.mega.mega-home .mega-title{
  margin-bottom: 10px;
  font-size: 1rem;
}
.mega.mega-home .mega-links{
  gap: 8px;
}
.mega.mega-home .mega-links a{
  padding: 8px 10px;
  font-size: .92rem;
}
.mega.mega-home .mega-highlight{
  margin-top: 8px;
  padding: 12px 12px 10px 12px;
  gap: 8px;
}
.mega.mega-home .mh-title{
  font-size: 1.05rem;
}
.mega.mega-home .mh-desc{
  font-size: .88rem;
  line-height: 1.45;
}
.mega.mega-home .btn{
  padding: 10px 14px;
}

.mh-badge{
  background: #e8f0ff;
  color: var(--primary);
  font-weight: 300;
  font-size: .8rem;
  padding: 6px 12px;
  border-radius: 300px;
  width: max-content;
}

.mh-title{
  font-size: 1.2rem;
  font-weight: 900;
  color: #0b2239;
}

.mh-desc{
  font-size: .95rem;
  color: #5b6b7b;
  line-height: 1.6;
}

/* ===== BUTTON ===== */
.btn{
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 12px 16px;
  border-radius: 12px;
  font-weight: 800;
  cursor: pointer;
  width: max-content;
}

.card#contact .btn-primary, #contact.card .btn-primary, .card#contact button[type="submit"] {
  background: linear-gradient(90deg, #0b6bd6 60%, #12b3c7 100%);
  color: #fff;
  padding: 16px 0;
  border-radius: 16px;
  font-weight: 900;
  font-size: 1.13rem;
  text-decoration: none;
  width: 48%;
  min-width: 160px;
  box-shadow: 0 10px 28px rgba(11,107,214,.18);
  border: none;
  margin: 0 8px;
  transition: background 0.18s, box-shadow 0.18s, transform 0.18s;
  display: inline-block;
}
.card#contact .btn-primary:hover, #contact.card .btn-primary:hover, .card#contact button[type="submit"]:hover {
  background: linear-gradient(90deg, #12b3c7 60%, #0b6bd6 100%);
  box-shadow: 0 18px 45px rgba(18,179,199,.22);
  transform: translateY(-2px) scale(1.03);
}
.contact-form .form-actions, .card#contact .form-actions, #contact.card .form-actions {
  display: flex;
  flex-direction: row;
  gap: 18px;
  justify-content: center;
  margin-top: 18px;
}
.card#contact .btn-secondary, #contact.card .btn-secondary {
  background: #f2f6ff;
  color: #0b6bd6;
  padding: 16px 0;
  border-radius: 16px;
  font-weight: 900;
  font-size: 1.13rem;
  width: 48%;
  min-width: 160px;
  border: none;
  box-shadow: 0 2px 8px rgba(11,107,214,.08);
  margin: 0 8px;
  transition: background 0.18s, color 0.18s, box-shadow 0.18s, transform 0.18s;
  display: inline-block;
}
.card#contact .btn-secondary:hover, #contact.card .btn-secondary:hover {
  background: #e0eaff;
  color: #0b2239;
  box-shadow: 0 8px 24px rgba(11,107,214,.10);
  transform: translateY(-2px) scale(1.03);
}

.btn-primary:hover{
  filter: brightness(1.05);
}

/* Responsive */
@media (max-width: 980px){
  .mega-inner{grid-template-columns: 1fr}
  .mega-cols{grid-template-columns: 1fr}
}
/* Smaller login cards and shift right */
.grid-3{
  display:grid;
  grid-template-columns: repeat(3, 1fr);
  gap:14px;
}
.card{
  background: color-mix(in oklab, var(--card) 94%, transparent);
  border:1px solid var(--line);
  border-radius: var(--radius);
  padding:12px 14px;
  box-shadow: 0 12px 30px rgba(0,0,0,.05);
  max-width: 320px;
  font-size: 0.97rem;
  height: 420;
  max-height: 420px;
  overflow: visible;
}
.login-page .grid-3{
  justify-content: flex-end;
  display: flex;
  gap: 18px;
}
.login-page .card{
  margin-right: 32px;
  min-width: 220px;
  max-width: 270px;
  font-size: 0.93rem;
}
.card h3{margin:0 0 8px; font-weight:900; font-size:1rem}
.card p{margin:0; color:var(--muted); line-height:1.7}
.kv{
  display:flex; gap:12px; align-items:flex-start;
}
.kv .ic{
  width:44px; height:44px;
  border-radius:14px;
  display:grid; place-items:center;
  background: color-mix(in oklab, var(--primary) 12%, transparent);
  border:1px solid var(--line);
  color:color-mix(in oklab, var(--text) 85%, var(--primary));
  font-weight:950;
}

/* Contact strip */
.contact-strip{
  background: linear-gradient(135deg, color-mix(in oklab, var(--primary) 22%, transparent),
                                     color-mix(in oklab, var(--primary2) 20%, transparent));
  border:1px solid var(--line);
  border-radius: var(--radius2);
  padding:18px;
  display:flex; align-items:center; justify-content:space-between;
  gap:14px;
}
.contact-strip .left{
  display:flex; flex-direction:column; gap:6px;
}
.contact-strip .right{display:flex; gap:10px; flex-wrap:wrap}

/* Footer */
.site-footer{
  border-top:1px solid var(--line);
  background: color-mix(in oklab, var(--card) 92%, transparent);
  padding: 26px 0;
}
.footer-grid{
  display:grid;
  grid-template-columns: 1.2fr 1fr 1fr;
  gap:16px;
  align-items:center;
}
.footer-brand{font-weight:950; font-size:18px}
.footer-links{display:flex; gap:12px; justify-content:center; flex-wrap:wrap}
.footer-links a{color:var(--muted)}
.footer-links a:hover{color:var(--text)}
.footer-right{display:flex; justify-content:flex-end}

/* Forms */
.input, .select {
  width: 100%;
  max-width: 100%;
  height: auto;
  min-height: 38px;
  background: var(--card);
  display: block;
  align-items: unset;
  justify-content: unset;
  box-shadow: none;
  margin: 0 0 10px 0;
  border-radius: 10px;
  padding: 10px 12px;
  border: 1px solid var(--line);
  color: var(--text);
  box-sizing: border-box;
}
.faq-note{
  font-size: .82rem;
  line-height:1.4;
  color:var(--muted);
  margin:6px 0 0;
}
.form-grid{
  display:grid;
  grid-template-columns: repeat(2, 1fr);
  gap:12px;
}
.form-actions{margin-top:12px; display:flex; gap:10px; flex-wrap:wrap}
textarea.input{min-height:120px; resize:vertical}

/* Gallery section */
.gallery-section {
  padding-top: 32px;
  padding-bottom: 48px;
}
.gallery-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 18px;
  margin-top: 18px;
}
.gallery-img{
  width: 100%;
  height: 170px; /* شوية أطول يعطي فخامة */
  object-fit: cover;

  border-radius: 20px;
  overflow: hidden;

  background: linear-gradient(135deg, #eef4ff, #dbe9ff);

  border: 1px solid rgba(11,34,57,.08);

  box-shadow:
    0 10px 30px rgba(11,34,57,.10),
    inset 0 0 0 1px rgba(255,255,255,.35);

  transition:
    transform .35s ease,
    box-shadow .35s ease;
}

@media (max-width: 700px) {
  .gallery-img { height: 120px; }
}

/* Responsive */
@media (max-width: 980px){
  .grid-3{grid-template-columns: 1fr}
  .footer-grid{grid-template-columns: 1fr; text-align:center}
  .footer-right{justify-content:center}
  .mega-inner{grid-template-columns: 1fr}
  .mega-cols{grid-template-columns: 1fr}
}

/* الحل النهائي لمنع الـ overflow الأفقي وتصحيح العرض */
html, body {
  max-width: 100%;
  overflow-x: hidden !important;
}

/* تصحيح عرض العناصر التي كانت تستخدم 100vw */
.hero-bg-modern,
.input,
.select {
  width: 100%;
  max-width: 100%;
}

.card#calculator, #calculator.card {
  max-height: 520px;
  overflow: visible;
  background: var(--card) !important;
  border-radius: var(--radius);
  padding: 32px 28px 28px 28px;
  max-width: 360px;
  margin: 0 auto;
  color: var(--text) !important;
  border: 1.5px solid var(--line);
  position: relative;
  transition: box-shadow 0.18s, transform 0.18s, background 0.18s;
}
.card#calculator h3, #calculator.card h3 {
  font-size: 1.18rem;
  font-weight: 800;
  color: var(--primary);
  margin-bottom: 10px;
  text-align: right;
  letter-spacing: 0.5px;
}
.card#calculator p, #calculator.card p {
  font-size: 1rem;
  color: var(--muted);
  margin-bottom: 14px;
  text-align: right;
}
.card#calculator hr, #calculator.card hr {
  border: none;
  border-top: 1px solid var(--line);
  margin: 18px 0;
}
.card#calculator .form-grid, #calculator.card .form-grid {
  display: flex;
  gap: 12px;
  margin-bottom: 10px;
}
.card#calculator label, #calculator.card label {
  font-size: 0.97rem;
  font-weight: 700;
  color: var(--primary);
  margin-bottom: 6px;
  display: block;
  letter-spacing: 0.2px;
}
.card#calculator input,
.card#calculator select,
#calculator.card input,
#calculator.card select {
  height: auto;
  min-height: 38px;
  max-height: none;
  padding: 12px 16px;
  width: 100%;
  border-radius: 12px;
  border: 1px solid var(--line);
  background: color-mix(in oklab, var(--card) 98%, #f7fbff 70%);
  color: var(--text);
  font-size: 1.05rem;
  margin-bottom: 10px;
  transition: border .18s, background .18s;
  outline: none;
}
.card#calculator input::placeholder, #calculator.card input::placeholder {
  color: var(--muted);
}
.card#calculator button, #calculator.card button {
  width: 100%;
  padding: 12px 0;
  border-radius: 14px;
  border: none;
  cursor: pointer;
  background: linear-gradient(90deg, var(--primary), var(--primary2));
  color: #fff;
  font-weight: 800;
  font-size: 1.08rem;
  box-shadow: 0 10px 28px rgba(11,107,214,.18);
  transition: box-shadow .18s, transform .18s, background 0.18s;
  margin-top: 8px;
}
.about-img-wrap{
  display: flex;
  margin-bottom: 18px;
}

/* حجم الصورة */


/* ===== Mobile Nav Fix ===== */
@media (max-width: 860px) {
  .site-header {
    position: sticky;
    top: 0;
    background: rgba(255,255,255,0.82);
    backdrop-filter: blur(12px);
    border-bottom: 1px solid rgba(0,0,0,0.06);
    box-shadow: 0 8px 20px rgba(0,0,0,0.05);
  }
  .nav-wrap {
    height: auto;
    padding: 10px 12px;
    gap: 10px;
    align-items: center;
    justify-content: space-between;
  }
  .nav {
    position: relative;
    width: 100%;
    justify-content: flex-end;
  }
  .nav-toggle {
    display: block;
    width: 36px;
    height: 36px;
    border-radius: 10px;
    background: rgba(0,0,0,0.05);
  }
  .nav-list {
    position: absolute;
    top: calc(var(--navH) + 6px);
    right: 0;
    left: 0;
    background: rgba(255,255,255,0.95);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(0,0,0,0.06);
    border-radius: 16px 16px 12px 12px;
    box-shadow: 0 16px 32px rgba(0,0,0,0.14);
    padding: 12px 14px;
    display: none !important;
    pointer-events: none;
    flex-direction: column;
    gap: 8px;
    z-index: 150;
    max-height: none;
    overflow: visible;
  }
  .nav-list.active {
    display: flex !important;
    pointer-events: auto;
  }
  .nav-link {
    width: 100%;
    justify-content: space-between;
    padding: 10px 12px;
    border-radius: 12px;
    font-size: 1rem;
    background: rgba(0,0,0,0.04);
  }
  .nav-actions {
    order: 3;
    width: 100%;
    justify-content: flex-end;
    gap: 6px;
  }
  .nav-actions .icon-btn {
    padding: 5px 6px;
    font-size: 0.88rem;
    border-radius: 8px;
    min-width: 28px;
    background: transparent;
    border: 1px solid rgba(0,0,0,0.12);
    box-shadow: none;
  }
  .logo img {
    height: 34px;
  }
  .brand {
    font-size: 1.05rem;
    gap: 8px;
    font-weight: 800;
  }

  /* تعطيل أي طبقة ميجا للجوال نهائياً لمنع حجب اللمس */
  .mega-mobile,
  .mega-mobile.active,
  .nav-list .mega,
  .nav-list .mega.open {
    display: none !important;
    opacity: 0 !important;
    visibility: hidden !important;
    pointer-events: none !important;
    height: 0 !important;
    width: 0 !important;
    padding: 0 !important;
    margin: 0 !important;
    border: none !important;
    box-shadow: none !important;
  }

  /* ميجا منيو داخل قائمة الجوال */
}

/* ===== Mobile Layout Refinements ===== */
@media (max-width: 700px) {
  body { font-size: 14px; line-height: 1.55; }
  .container { width: 94%; }
  .hero-bg-modern, .hero { min-height: 78vh; padding: 34px 0 28px; }
  .hero-title-modern { font-size: 1.92rem; line-height: 1.16; }
  .hero-cta-modern, .btn { width: 100%; max-width: 340px; }
  .hero-features-modern { flex-wrap: wrap; gap: 10px; font-size: 0.98rem; }
  .nav-wrap { padding: 8px 10px; }
  .logo img { height: 30px; }
  .brand { font-size: 1rem; gap: 6px; }
  .nav-actions { gap: 5px; }
  .nav-link { font-size: 1rem; padding: 10px 12px; }
  .grid-3 { grid-template-columns: 1fr; }
  .card, .tool-card { max-width: 100%; width: 100%; }
  .contact-strip, .cta-strip, .quote-strip { padding: 18px 14px; gap: 14px; border-radius: 18px; }
  .gallery-grid { grid-template-columns: 1fr; }
  .gallery-img { height: 130px; }
  .footer-grid { grid-template-columns: 1fr; gap: 10px; text-align: center; }

  /* Contact page: keep action buttons side-by-side on mobile */
  #quote .form-actions {
    flex-direction: row;
    flex-wrap: wrap;
    justify-content: center;
    gap: 10px;
  }
  #quote .form-actions .btn {
    width: auto;
    max-width: none;
    flex: 1 1 calc(50% - 10px);
    min-width: 140px;
    margin: 0;
  }
}

@media (max-width: 480px) {
  .hero-title-modern { font-size: 1.85rem; }
  .hero-cta-modern { font-size: 1.02rem; padding: 12px 24px; }
  .nav-link, .icon-btn { font-size: 0.98rem; }
  .contact-strip h2, .cta-strip h2, .quote-strip h2 { font-size: 1.25rem; }
}

/* خلفية الهيدر حسب الثيم */
:root:not([data-theme="dark"]) .site-header,
body:not(.dark) .site-header {
  background: rgba(255,255,255,0.9);
}

[data-theme="dark"] .site-header,
body.dark .site-header {
  background: rgba(8,19,31,0.9);
}

.site-header.scrolled {
  background: rgba(255,255,255,0.9);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid rgba(0,0,0,0.08);
  box-shadow: 0 10px 26px rgba(0,0,0,0.08);
}

[data-theme="dark"] .site-header.scrolled,
body.dark .site-header.scrolled {
  background: rgba(8,19,31,0.9);
  border-bottom: 1px solid rgba(255,255,255,0.06);
  box-shadow: 0 10px 26px rgba(0,0,0,0.14);
}

/* ==========================
   HEADER / NAV (FINAL OVERRIDE)
   - Transparent over hero
   - Solid when scrolled
   ========================== */
.site-header {
  position: sticky;
  top: 0;
  z-index: 200;
  border-bottom: 1px solid rgba(255,255,255,0.00);
  background: transparent !important;
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  box-shadow: none;
}

/* when scrolling (or on pages without hero) */
.site-header.scrolled {
  background: rgba(255,255,255,0.92) !important;
  border-bottom: 1px solid rgba(0,0,0,0.08);
  box-shadow: 0 10px 26px rgba(0,0,0,0.10);
}
[data-theme="dark"] .site-header.scrolled,
body.dark .site-header.scrolled {
  background: rgba(8, 19, 31, 0.92) !important;
  border-bottom: 1px solid rgba(255,255,255,0.10);
  box-shadow: 0 10px 26px rgba(0,0,0,0.22);
}

.site-header .nav-wrap {
  height: 74px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  padding: 0 18px;
}

/* left icons */
.site-header .nav-actions {
  display: flex;
  align-items: center;
  gap: 10px;
  flex: 0 0 auto;
}

.site-header .icon-btn {
  width: 32px;
  height: 32px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 10px;
  border: 1px solid rgba(255,255,255,0.14);
  background: rgba(8, 19, 31, 0.35);
  color: #fff;
  box-shadow: 0 8px 18px rgba(0,0,0,0.16);
  font-size: 0.88rem;
}
.site-header.scrolled .icon-btn {
  background: var(--card);
  color: var(--text);
  border: 1px solid var(--line);
  box-shadow: 0 10px 22px rgba(0,0,0,0.08);
}

/* center menu */
.site-header .nav {
  display: flex;
  align-items: center;
  justify-content: center;
  flex: 1 1 auto;
}

.site-header .nav-list {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
}

.site-header .nav-link {
  color: #fff !important;
  font-weight: 800;
  padding: 10px 14px;
  border-radius: 14px;
  background: transparent;
  transition: background .18s ease, color .18s ease;
}
.site-header.scrolled .nav-link {
  color: var(--text) !important;
}

.site-header .nav-link:hover {
  background: rgba(255,255,255,0.10);
}
.site-header.scrolled .nav-link:hover {
  background: color-mix(in srgb, var(--primary) 10%, transparent);
  color: var(--primary) !important;
}

/* CTA link */
.site-header .nav-cta {
  background: linear-gradient(135deg, var(--primary), var(--primary2));
  color: #fff !important;
  box-shadow: 0 16px 34px rgba(11,107,214,0.22);
}

/* right brand */
.site-header .brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  flex: 0 0 auto;
  text-decoration: none;
}
.site-header .brand-text {
  color: #fff;
  font-weight: 950;
  letter-spacing: 0.2px;
  font-size: clamp(1.25rem, 2.2vw, 2.2rem);
  text-shadow: 0 8px 28px rgba(0,0,0,0.35);
}
.site-header.scrolled .brand-text {
  color: var(--text);
  text-shadow: none;
}

/* hamburger button colors over hero */
.site-header:not(.scrolled) #navToggle span { background: #fff !important; }

@media (max-width: 860px) {
  .site-header .nav-wrap {
    height: auto;
    padding: 10px 12px;
    flex-direction: row;
    align-items: center;
    justify-content: space-between;
  }
  /* Mobile header layout: menu button on the left */
  .site-header .nav {
    order: 0;
    justify-content: flex-start;
  }
  .site-header .nav-actions {
    order: 1;
    margin-inline-start: auto;
  }
  .site-header .brand {
    order: 2;
  }
  .site-header .nav {
    width: auto;
    flex: 0 0 auto;
  }
  .site-header .nav-actions {
    width: auto;
    justify-content: flex-end;
  }

  .site-header .nav-toggle {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 48px;
    height: 48px;
    border-radius: 12px;
    border: 1px solid rgba(255,255,255,0.14);
    background: rgba(8, 19, 31, 0.35);
  }

  .site-header .icon-btn {
    width: 40px;
    height: 40px;
    border-radius: 10px;
    font-size: 1rem;
  }
  .site-header.scrolled .nav-toggle {
    background: var(--card);
    border: 1px solid var(--line);
  }

  .site-header .nav-list {
    position: fixed;
    top: 76px;
    right: 12px;
    left: 12px;
    flex-direction: column;
    align-items: stretch;
    padding: 16px;
    gap: 12px;
    border-radius: 18px;
    background: rgba(8, 19, 31, 0.92);
    border: 1px solid rgba(255,255,255,0.10);
    box-shadow: 0 18px 46px rgba(0,0,0,0.25);

    display: none;
    pointer-events: none;
    max-height: calc(100vh - 88px);
    overflow: auto;
    z-index: 1000;
  }
  .site-header .nav-list.active {
    display: flex;
    pointer-events: auto;
  }
  .site-header.scrolled .nav-list {
    background: rgba(255,255,255,0.98);
    border: 1px solid rgba(0,0,0,0.08);
  }

  .site-header .nav-link {
    display: flex;
    align-items: center;
    width: 100%;
    justify-content: space-between;
    background: rgba(255,255,255,0.06);
    font-size: 1.08rem;
    padding: 12px 14px;
    border-radius: 14px;
  }
  .site-header.scrolled .nav-link {
    background: color-mix(in srgb, var(--primary) 6%, transparent);
  }

  /* Mobile: no mega-panels inside the dropdown */
  .site-header .nav-list .mega {
    display: none !important;
  }
  .site-header .nav-list .caret {
    display: none;
  }
}

/* Hamburger icon bars (now that header.php removed inline styles) */
.site-header .nav-toggle span {
  display: block;
  width: 18px;
  height: 2px;
  margin: 4px 0;
  border-radius: 2px;
  background: currentColor;
  opacity: 0.92;
}
.site-header:not(.scrolled) .nav-toggle { color: #fff; }
.site-header.scrolled .nav-toggle { color: var(--text); }
