/* =========================================================
   STAR ENTERPRISES — Global Stylesheet
   ========================================================= */

/* ---------- Google Fonts ---------- */
@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700;800&display=swap');

/* ---------- CSS Variables ---------- */
:root {
  --navy:      #0d1f3c;
  --navy-dark: #091528;
  --blue:      #1a3a6b;
  --blue-mid:  #1e4d8c;
  --blue-acc:  #2563eb;
  --slate:     #64748b;
  --slate-lt:  #94a3b8;
  --white:     #ffffff;
  --off-white: #f8fafc;
  --grey-lt:   #f1f5f9;
  --grey-mid:  #e2e8f0;
  --grey-dark: #334155;
  --text-body: #374151;
  --transition: 0.3s ease;
  --radius: 8px;
  --shadow: 0 4px 24px rgba(13,31,60,0.10);
  --shadow-lg: 0 8px 40px rgba(13,31,60,0.18);
}

/* ---------- Reset ---------- */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }
body { font-family: 'Inter', sans-serif; color: var(--text-body); background: var(--white); line-height: 1.7; }
img { max-width: 100%; display: block; }
a { text-decoration: none; color: inherit; }
ul { list-style: none; }

/* ---------- Utility ---------- */
.container { max-width: 1200px; margin: 0 auto; padding: 0 24px; }
.section-pad { padding: 80px 0; }
.section-pad-sm { padding: 56px 0; }
.bg-offwhite { background: var(--off-white); }
.bg-grey { background: var(--grey-lt); }
.bg-navy { background: var(--navy); }
.text-center { text-align: center; }

/* ---------- Section Headings ---------- */
.section-label {
  display: inline-block;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 3px;
  text-transform: uppercase;
  color: var(--blue-acc);
  margin-bottom: 12px;
}
.section-title {
  font-size: clamp(26px, 4vw, 40px);
  font-weight: 800;
  color: var(--navy);
  line-height: 1.2;
  margin-bottom: 16px;
}
.section-sub {
  font-size: 16px;
  color: var(--slate);
  max-width: 600px;
  line-height: 1.8;
}

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 14px 32px;
  border-radius: var(--radius);
  font-size: 14px;
  font-weight: 700;
  letter-spacing: 0.5px;
  cursor: pointer;
  border: none;
  transition: all var(--transition);
}
.btn-primary {
  background: var(--blue-acc);
  color: var(--white);
}
.btn-primary:hover { background: var(--blue-mid); transform: translateY(-2px); box-shadow: 0 8px 24px rgba(37,99,235,0.35); }
.btn-outline {
  background: transparent;
  color: var(--white);
  border: 2px solid var(--white);
}
.btn-outline:hover { background: var(--white); color: var(--navy); transform: translateY(-2px); }
.btn-navy {
  background: var(--navy);
  color: var(--white);
}
.btn-navy:hover { background: var(--blue-mid); transform: translateY(-2px); box-shadow: var(--shadow); }
.btn-sm { padding: 10px 22px; font-size: 13px; }

/* =========================================================
   HEADER
   ========================================================= */
#site-header {
  position: sticky;
  top: 0;
  z-index: 1000;
  background: var(--navy);
  box-shadow: 0 2px 20px rgba(0,0,0,0.25);
  transition: background var(--transition);
}
.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 75px;
}
/* Logo */
.header-logo {
  display: flex;
  align-items: center;
  gap: 12px;
}
.header-logo-img {
  height: auto;
  width: 185px;
  display: block;
  object-fit: contain;
}

/* Nav */
.main-nav { display: flex; align-items: center; gap: 36px; }
.main-nav a {
  font-size: 13px; font-weight: 700;
  color: var(--slate-lt);
  letter-spacing: 1px;
  text-transform: uppercase;
  position: relative;
  padding-bottom: 4px;
  transition: color var(--transition);
}
.main-nav a::after {
  content: '';
  position: absolute; bottom: 0; left: 0;
  width: 0; height: 2px;
  background: var(--blue-acc);
  transition: width var(--transition);
}
.main-nav a:hover, .main-nav a.active { color: var(--white); }
.main-nav a:hover::after, .main-nav a.active::after { width: 100%; }

/* Hamburger */
.nav-toggle {
  display: none;
  flex-direction: column;
  gap: 5px;
  cursor: pointer;
  padding: 6px;
  background: none; border: none;
}
.nav-toggle span {
  display: block; width: 24px; height: 2px;
  background: var(--white);
  transition: all var(--transition);
}
.nav-toggle.open span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.nav-toggle.open span:nth-child(2) { opacity: 0; }
.nav-toggle.open span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

/* Mobile Nav */
.mobile-nav {
  display: none;
  background: var(--navy-dark);
  border-top: 1px solid rgba(255,255,255,0.08);
}
.mobile-nav a {
  display: block;
  padding: 14px 24px;
  color: var(--slate-lt);
  font-size: 14px;
  font-weight: 700;
  letter-spacing: 1px;
  text-transform: uppercase;
  border-bottom: 1px solid rgba(255,255,255,0.05);
  transition: all var(--transition);
}
.mobile-nav a:hover { color: var(--white); background: rgba(37,99,235,0.15); padding-left: 32px; }
.mobile-nav.open { display: block; }

/* =========================================================
   HERO SECTION — White Trapezoid / Diagonal Split Layout
   =========================================================

   Z-index stack:
     Layer 1 (.hero-bg)          → Full-width background slideshow
     Layer 2 (.hero-trapezoid)   → Static white clipped panel (left)
     Layer 3 (.hero-content-wrap)→ Static text content (above panel)
   ========================================================= */

.hero {
  position: relative;
  width: 100%;
  min-height: 641px;
  max-height: 844px;
  height: 87.5vh;
  overflow: hidden;
  background: #e8ecf0; /* fallback while images load */
}

/* ── Layer 1: Background Slideshow ── */
.hero-bg {
  position: absolute;
  top: 0; left: 0; right: 0; bottom: 0;
  width: 100%;
  height: 100%;
  z-index: 1;
}
.hero-carousel {
  position: relative;
  width: 100%;
  height: 100%;
}
.hero-slide {
  position: absolute;
  top: 0; left: 0;
  width: 100%;
  height: 100%;
  opacity: 0;
  transition: opacity 1.2s ease;
}
.hero-slide.active { opacity: 1; }
.hero-slide img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  /* Shift focal point to the right so machinery/main subject
     stays visible beyond the trapezoid edge (~45% from left) */
  object-position: 82% center;
  display: block;
  image-rendering: -webkit-optimize-contrast;
  image-rendering: crisp-edges;
}

/* ── Layer 2: Navy Blue Trapezoid ── */
.hero-trapezoid {
  position: absolute;
  inset: 0;
  z-index: 2;
  background: linear-gradient(135deg, #071325 0%, #0d1f3c 65%, #183867 100%);
  clip-path: polygon(0 0, 58% 0, 45% 100%, 0 100%);
  pointer-events: none;
}

/* Plus/cross grid texture over the navy panel */
.hero-trapezoid::before {
  content: '';
  position: absolute;
  inset: 0;
  background-image: url("data:image/svg+xml,%3Csvg width='18' height='18' viewBox='0 0 18 18' xmlns='http://www.w3.org/2000/svg'%3E%3Cg fill='%23ffffff' fill-opacity='0.07'%3E%3Crect x='8' y='3' width='2' height='12'/%3E%3Crect x='3' y='8' width='12' height='2'/%3E%3C/g%3E%3C/svg%3E");
  background-repeat: repeat;
  background-size: 18px 18px;
  pointer-events: none;
}

/* Blue accent line on the diagonal edge */
.hero-trapezoid::after {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, #60a5fa 0%, #2563eb 100%);
  clip-path: polygon(57.3% 0, 58% 0, 45% 100%, 44.3% 100%);
}

/* ── Layer 3: Static Text Content ── */
.hero-content-wrap {
  position: absolute;
  inset: 0;
  z-index: 3;
  display: flex;
  align-items: center;
  /* Constrain text to the left ~50% so it always sits inside the white panel */
  padding: 0 5vw;
  pointer-events: none;
}
.hero-content {
  max-width: 500px;
  width: 100%;
  pointer-events: auto;
}

/* Eyebrow / Tagline */
.hero-eyebrow {
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 1.5px;
  text-transform: uppercase;
  color: #93c5fd;
  margin-bottom: 18px;
}

/* Main headline */
.hero-title {
  font-size: clamp(28px, 4vw, 50px);
  font-weight: 900;
  color: #ffffff;
  line-height: 1.18;
  margin-bottom: 18px;
  letter-spacing: -0.5px;
  text-shadow: 0 2px 12px rgba(0,0,0,0.35);
}
.hero-title .accent { color: #60a5fa; }

/* Subtext */
.hero-desc {
  font-size: 16px;
  color: #cbd5e1;
  line-height: 1.8;
  margin-bottom: 32px;
  max-width: 420px;
}

/* CTA buttons — dark theme to contrast the white panel */
.hero-ctas { display: flex; gap: 14px; flex-wrap: wrap; }

.btn-hero-primary {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 13px 28px;
  background: #2563eb;
  color: #fff;
  border-radius: 6px;
  font-size: 13px; font-weight: 700;
  letter-spacing: 0.8px;
  border: 2px solid #2563eb;
  cursor: pointer;
  transition: all 0.25s ease;
  text-decoration: none;
}
.btn-hero-primary:hover {
  background: #1d4ed8;
  border-color: #1d4ed8;
  transform: translateY(-2px);
  box-shadow: 0 8px 24px rgba(37,99,235,0.45);
}

.btn-hero-outline {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 13px 28px;
  background: transparent;
  color: #fff;
  border-radius: 6px;
  font-size: 13px; font-weight: 700;
  letter-spacing: 0.8px;
  border: 2px solid rgba(255,255,255,0.55);
  cursor: pointer;
  transition: all 0.25s ease;
  text-decoration: none;
}
.btn-hero-outline:hover {
  background: rgba(255,255,255,0.12);
  border-color: #fff;
  transform: translateY(-2px);
}

/* ── Carousel Dots ── */
.hero-dots {
  display: none; /* carousel indicator hidden per design */
}
.hero-dot {
  width: 6px; height: 6px; border-radius: 50%;
  background: rgba(255,255,255,0.35);
  cursor: pointer;
  transition: all 0.35s cubic-bezier(0.4,0,0.2,1);
  border: none;
  box-shadow: none;
}
.hero-dot:hover { background: rgba(255,255,255,0.65); }
.hero-dot.active {
  background: #fff;
  width: 22px;
  border-radius: 3px;
  box-shadow: 0 1px 6px rgba(0,0,0,0.3);
}

/* =========================================================
   WHY US SECTION
   ========================================================= */
.why-us { padding: 90px 0; background: var(--white); }
.why-us-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 80px; align-items: center; }
.why-us-img { position: relative; }
.why-us-img img { border-radius: 12px; box-shadow: var(--shadow-lg); width: 100%; height: 480px; object-fit: cover; }
.why-us-img-badge {
  position: absolute; bottom: -20px; right: -20px;
  background: var(--navy); color: var(--white);
  padding: 20px 28px; border-radius: 12px;
  text-align: center; box-shadow: var(--shadow-lg);
}
.why-us-img-badge .num { font-size: 26px; font-weight: 900; color: #60a5fa; line-height: 1; white-space: nowrap; }
.why-us-img-badge .lbl { font-size: 11px; color: var(--slate-lt); margin-top: 4px; text-transform: uppercase; letter-spacing: 1px; }
.why-list { display: flex; flex-direction: column; gap: 24px; margin-top: 32px; }
.why-item { display: flex; gap: 18px; align-items: flex-start; animation: fadeInUp 0.5s ease both; }
.why-icon {
  width: 48px; height: 48px; flex-shrink: 0;
  background: linear-gradient(135deg, var(--blue-acc), var(--blue-mid));
  border-radius: 10px;
  display: flex; align-items: center; justify-content: center;
  font-size: 20px;
}
.why-item h4 { font-size: 15px; font-weight: 700; color: var(--navy); margin-bottom: 4px; }
.why-item p  { font-size: 14px; color: var(--slate); line-height: 1.6; }

/* =========================================================
   SERVICES GRID
   ========================================================= */
.services { padding: 90px 0; background: var(--grey-lt); }
.services-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 28px; margin-top: 48px; }
.service-card {
  background: var(--white);
  border-radius: 12px;
  overflow: hidden;
  box-shadow: var(--shadow);
  transition: transform var(--transition), box-shadow var(--transition);
  display: flex; flex-direction: column;
}
.service-card:hover { transform: translateY(-8px); box-shadow: var(--shadow-lg); }
.service-img { height: 220px; overflow: hidden; }
.service-img img { width: 100%; height: 100%; object-fit: cover; transition: transform 0.5s ease; }
.service-card:hover .service-img img { transform: scale(1.06); }
.service-body { padding: 28px; flex: 1; display: flex; flex-direction: column; }
.service-body h3 { font-size: 20px; font-weight: 800; color: var(--navy); margin-bottom: 12px; }
.service-body p  { font-size: 14px; color: var(--slate); line-height: 1.7; flex: 1; }
.service-body .btn { margin-top: 24px; align-self: flex-start; }

/* =========================================================
   CLIENTELE INFINITE SLIDER
   ========================================================= */
.clients {
  padding: 100px 0;
  background: var(--white);
  border-top: 2px solid var(--grey-mid);
  border-bottom: 2px solid var(--grey-mid);
  overflow: hidden;
}
.clients-label {
  text-align: center;
  font-size: 14px;
  font-weight: 700;
  letter-spacing: 4px;
  text-transform: uppercase;
  color: var(--slate);
  margin-bottom: 64px;
}
.logo-track { display: flex; gap: 0; }
.logo-slider {
  display: flex;
  gap: 0;
  animation: scrollLogos 25s linear infinite;
  width: max-content;
}
.logo-slider:hover { animation-play-state: paused; }
.logo-item {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 340px;
  height: 180px;
  padding: 24px 44px;
  border-right: 1px solid var(--grey-mid);
  flex-shrink: 0;
}
.logo-item img {
  max-width: 240px;
  max-height: 110px;
  width: auto;
  height: auto;
  object-fit: contain;
  filter: none;
  opacity: 1;
  transition: transform var(--transition);
}
.logo-item:hover img {
  transform: scale(1.08);
}
.logo-placeholder {
  width: 100px; height: 36px;
  background: var(--grey-mid);
  border-radius: 4px;
  display: flex; align-items: center; justify-content: center;
  font-size: 10px; font-weight: 700; color: var(--slate);
  letter-spacing: 1px;
  transition: background var(--transition);
}
.logo-item:hover .logo-placeholder { background: var(--grey-dark); color: var(--white); }

@keyframes scrollLogos {
  0%   { transform: translateX(0); }
  100% { transform: translateX(-50%); }
}

/* =========================================================
   CAPABILITIES PAGE
   ========================================================= */
.page-hero {
  background: linear-gradient(135deg, var(--navy-dark), var(--navy));
  padding: 80px 0;
  text-align: center;
  position: relative;
  overflow: hidden;
}
.page-hero::after {
  content: '';
  position: absolute; bottom: 0; left: 0; right: 0;
  height: 4px;
  background: linear-gradient(to right, var(--blue-acc), #60a5fa, var(--blue-acc));
}
.page-hero h1 { font-size: clamp(32px, 5vw, 52px); font-weight: 900; color: var(--white); margin-bottom: 16px; }
.page-hero p  { font-size: 17px; color: var(--slate-lt); max-width: 560px; margin: 0 auto; }
.breadcrumb { text-align: center; margin-bottom: 24px; line-height: 1; }
.breadcrumb-inner { display: inline; white-space: nowrap; font-size: 13px; }
.breadcrumb-inner a { display: inline; color: #60a5fa; font-size: 13px; white-space: nowrap; }
.breadcrumb-sep { display: inline; color: var(--slate-lt); font-size: 13px; }
.breadcrumb-cur { display: inline; color: var(--slate-lt); font-size: 13px; white-space: nowrap; }

/* Capability Section Zig-Zag */
.cap-section { padding: 90px 0; }
.cap-section:nth-child(even) { background: var(--grey-lt); }
.cap-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 70px; align-items: center; }
.cap-grid.reverse { direction: rtl; }
.cap-grid.reverse > * { direction: ltr; }
.cap-img { border-radius: 12px; overflow: hidden; box-shadow: var(--shadow-lg); }
.cap-img img { width: 100%; height: 460px; object-fit: cover; transition: transform 0.6s ease; display: block; }
.cap-img:hover img { transform: scale(1.04); }
.cap-content { }
.cap-content .section-title { margin-bottom: 24px; }
.cap-content p { font-size: 15px; color: var(--slate); line-height: 1.85; margin-bottom: 20px; }
.cap-tags { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 28px; }
.cap-tag {
  background: rgba(37,99,235,0.08);
  color: var(--blue-acc);
  border: 1px solid rgba(37,99,235,0.2);
  border-radius: 50px;
  padding: 5px 14px;
  font-size: 12px; font-weight: 600;
}

/* =========================================================
   PRODUCTS PAGE
   ========================================================= */
.products-nav {
  background: var(--white);
  border-bottom: 2px solid var(--grey-mid);
  position: sticky; top: 70px; z-index: 99;
}
.products-nav-inner {
  display: flex; gap: 0;
}
.prod-tab {
  padding: 18px 36px;
  font-size: 14px; font-weight: 700;
  color: var(--slate);
  border-bottom: 3px solid transparent;
  margin-bottom: -2px;
  cursor: pointer;
  transition: all var(--transition);
  background: none; border-top: none; border-left: none; border-right: none;
  letter-spacing: 0.5px;
}
.prod-tab:hover, .prod-tab.active { color: var(--navy); border-bottom-color: var(--blue-acc); }

.product-section { padding: 90px 0; }
.product-section:nth-child(even) { background: var(--grey-lt); }
.product-section-header { margin-bottom: 48px; }
.product-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; }

/* Lightbox Card */
.product-card {
  border-radius: 10px;
  overflow: hidden;
  cursor: pointer;
  position: relative;
  box-shadow: var(--shadow);
  aspect-ratio: 4/3;
  background: var(--grey-mid);
}
.product-card img { width: 100%; height: 100%; object-fit: cover; transition: transform 0.5s ease; }
.product-card:hover img { transform: scale(1.08); }
.product-card-overlay {
  position: absolute; inset: 0;
  background: rgba(13,31,60,0.6);
  opacity: 0; display: flex; align-items: center; justify-content: center;
  transition: opacity var(--transition);
}
.product-card:hover .product-card-overlay { opacity: 1; }
.product-card-overlay span {
  color: var(--white); font-size: 14px; font-weight: 600;
  display: flex; align-items: center; gap: 6px;
}

/* Lightbox Modal */
.lightbox-overlay {
  display: none;
  position: fixed; inset: 0; z-index: 9999;
  background: rgba(0,0,0,0.92);
  align-items: center; justify-content: center;
  padding: 24px;
}
.lightbox-overlay.open { display: flex; animation: fadeIn 0.25s ease; }
.lightbox-inner { position: relative; max-width: 900px; width: 100%; }
.lightbox-inner img { width: 100%; border-radius: 8px; max-height: 85vh; object-fit: contain; }
.lightbox-close {
  position: absolute; top: -48px; right: 0;
  background: none; border: none; color: var(--white);
  font-size: 32px; cursor: pointer; line-height: 1;
  transition: transform var(--transition);
}
.lightbox-close:hover { transform: rotate(90deg); }
.lightbox-caption {
  text-align: center; color: var(--slate-lt);
  font-size: 14px; margin-top: 16px;
}

/* =========================================================
   FOOTER
   ========================================================= */
.site-footer {
  background: var(--navy-dark);
  padding: 70px 0 0;
  color: #94a3b8;
}
.footer-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 48px; }
.footer-col h4 {
  font-size: 12px; font-weight: 700;
  letter-spacing: 3px; text-transform: uppercase;
  color: var(--white); margin-bottom: 24px;
  padding-bottom: 12px;
  border-bottom: 2px solid var(--blue-acc);
  display: inline-block;
}
.footer-logo-area { margin-bottom: 20px; }
.footer-logo-area .logo-name { font-size: 22px; font-weight: 800; color: var(--white); }
.footer-logo-area .logo-tag  { font-size: 10px; color: var(--slate-lt); letter-spacing: 2px; text-transform: uppercase; margin-top: 4px; }
.footer-info-links { display: flex; flex-direction: column; gap: 12px; }
.footer-info-links a { font-size: 14px; color: #94a3b8; transition: all var(--transition); display: flex; align-items: center; gap: 8px; }
.footer-info-links a::before { content: '→'; font-size: 12px; color: var(--blue-acc); }
.footer-info-links a:hover { color: var(--white); padding-left: 6px; }
.footer-contact-item { display: flex; gap: 14px; align-items: flex-start; margin-bottom: 20px; }
.fc-icon {
  width: 36px; height: 36px; flex-shrink: 0;
  background: rgba(37,99,235,0.15);
  border-radius: 8px;
  display: flex; align-items: center; justify-content: center;
  font-size: 16px;
}
.fc-text { font-size: 14px; color: #94a3b8; line-height: 1.5; }
.fc-text strong { display: block; color: var(--white); font-size: 13px; margin-bottom: 2px; }
.footer-map { border-radius: 10px; overflow: hidden; border: 2px solid rgba(255,255,255,0.08); }
.footer-map iframe { width: 100%; height: 220px; border: 0; display: block; filter: grayscale(0.4) contrast(1.1); border-radius: 6px; }
.map-open-link {
  display: inline-flex; align-items: center; gap: 6px;
  margin-top: 10px;
  font-size: 12px; font-weight: 600;
  color: #60a5fa;
  letter-spacing: 0.3px;
  text-decoration: none;
  transition: color 0.2s ease;
  min-height: auto;
}
.map-open-link:hover { color: #93c5fd; }
.footer-bottom {
  margin-top: 60px;
  padding: 20px 0;
  border-top: 1px solid rgba(255,255,255,0.07);
  display: flex; justify-content: space-between; align-items: center;
  flex-wrap: wrap; gap: 12px;
}
.footer-bottom p { font-size: 13px; color: var(--slate-lt); }
.footer-bottom a { color: var(--blue-acc); }

/* =========================================================
   ANIMATIONS
   ========================================================= */
@keyframes fadeInUp {
  from { opacity: 0; transform: translateY(30px); }
  to   { opacity: 1; transform: translateY(0); }
}
@keyframes fadeIn {
  from { opacity: 0; }
  to   { opacity: 1; }
}
.fade-in-up {
  opacity: 0; transform: translateY(30px);
  transition: opacity 0.6s ease, transform 0.6s ease;
}
.fade-in-up.visible { opacity: 1; transform: translateY(0); }

/* Stagger delays */
.delay-1 { transition-delay: 0.1s; }
.delay-2 { transition-delay: 0.2s; }
.delay-3 { transition-delay: 0.3s; }
.delay-4 { transition-delay: 0.4s; }
.delay-5 { transition-delay: 0.5s; }

/* =========================================================
   RESPONSIVE
   ========================================================= */

/* --- Tablet landscape (≤1100px) --- */

/* ==========================================================================
   RESPONSIVE SYSTEM — Star Enterprises
   Breakpoints:
     1440px+ → Large desktop
     1200px  → Desktop (base layout)
     1024px  → Tablet landscape
     768px   → Tablet portrait / large mobile
     480px   → Mobile
     360px   → Small mobile
   ========================================================================== */

/* --- Large desktop (≥1440px) — scale up gracefully --- */
@media (min-width: 1440px) {
  .container { max-width: 1320px; }
  .hero-title { font-size: 58px; }
  .hero-desc { font-size: 18px; }
  .hero { max-height: 820px; height: 70vh; }
}

/* --- Tablet landscape (≤1100px) --- */
@media (max-width: 1100px) {
  .container { padding: 0 28px; }
  .hero-title { font-size: clamp(28px, 3.5vw, 46px); }
}

/* --- Tablet portrait (≤992px) --- */
@media (max-width: 992px) {
  /* Header */
  .header-logo-img { width: 150px; }
  .main-nav { gap: 24px; }
  .main-nav a { font-size: 12px; }

  /* Hero */
  .hero { min-height: 440px; max-height: 600px; height: 65vw; }
  .hero-trapezoid { clip-path: polygon(0 0, 62% 0, 48% 100%, 0 100%); }
  .hero-trapezoid::before { clip-path: polygon(0 0, 62% 0, 48% 100%, 0 100%); }
  .hero-trapezoid::after  { clip-path: polygon(61.3% 0, 62% 0, 48% 100%, 47.3% 100%); }
  .hero-content-wrap { padding: 0 4vw; }
  .hero-content { max-width: 420px; }
  .hero-title { font-size: clamp(24px, 3.8vw, 40px); }

  /* Why Us */
  .why-us-grid { grid-template-columns: 1fr; gap: 40px; }
  .why-us-img { order: -1; }
  .why-us-img img { height: 320px; }

  /* Services */
  .services-grid { grid-template-columns: 1fr 1fr; gap: 20px; }

  /* Capabilities */
  .cap-grid,
  .cap-grid.reverse { grid-template-columns: 1fr; direction: ltr; gap: 40px; }
  .cap-img img { height: 300px; }

  /* Products */
  .product-grid { grid-template-columns: 1fr 1fr; gap: 18px; }

  /* Footer */
  .footer-grid { grid-template-columns: 1fr 1fr; gap: 40px; }
}

/* --- Tablet / Large mobile (≤768px) --- */
@media (max-width: 768px) {
  /* Header */
  .main-nav { display: none; }
  .nav-toggle { display: flex; }
  .header-logo-img { width: 130px; }
  .header-inner { height: 64px; }

  /* Products sticky nav offset */
  .products-nav { top: 64px; }

  /* Hero — stacked layout on mobile */
  .hero {
    min-height: auto;
    max-height: none;
    height: auto;
    display: flex;
    flex-direction: column;
  }
  .hero-bg {
    position: relative;
    height: 55vw;
    min-height: 220px;
    max-height: 340px;
    width: 100%;
  }
  /* On mobile: hide the empty trapezoid div, give content-wrap the navy bg */
  .hero-trapezoid { display: none; }
  .hero-content-wrap {
    position: relative;
    background: linear-gradient(135deg, #071325 0%, #0d1f3c 65%, #183867 100%);
    background-image:
      url("data:image/svg+xml,%3Csvg width='28' height='28' viewBox='0 0 28 28' xmlns='http://www.w3.org/2000/svg'%3E%3Cg fill='%23ffffff' fill-opacity='0.055'%3E%3Crect x='13' y='4' width='2' height='20'/%3E%3Crect x='4' y='13' width='20' height='2'/%3E%3C/g%3E%3C/svg%3E"),
      linear-gradient(135deg, #071325 0%, #0d1f3c 65%, #183867 100%);
    background-blend-mode: normal;
    padding: 32px 24px 40px;
    z-index: 3;
  }
  .hero-content { max-width: 100%; }
  .hero-title { font-size: clamp(24px, 5.5vw, 34px); line-height: 1.2; }
  .hero-desc { font-size: 15px; margin-bottom: 28px; }
  .hero-ctas { flex-direction: row; flex-wrap: wrap; gap: 12px; }
  /* .hero-dots hidden globally */

  /* Sections */
  .section-pad { padding: 56px 0; }
  .section-sub { font-size: 15px; max-width: 100%; }

  /* Services */
  .services-grid { grid-template-columns: 1fr; }

  /* Why Us */
  .why-us-img img { height: 260px; }
  .why-us-img-badge { bottom: 10px; right: 10px; padding: 10px 14px; }

  /* Capabilities */
  .cap-img img { height: 240px; }
  .cap-content { padding: 0; }
  .cap-section { padding: 56px 0; }

  /* Products */
  .product-grid { grid-template-columns: 1fr 1fr; gap: 14px; }
  .product-section { padding: 56px 0; }

  /* Products tab bar — horizontal scroll */
  .products-nav-inner {
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    white-space: nowrap;
    scrollbar-width: none;
  }
  .products-nav-inner::-webkit-scrollbar { display: none; }
  .prod-tab { padding: 14px 20px; font-size: 13px; }

  /* Footer */
  .footer-grid { grid-template-columns: 1fr; gap: 32px; }
  .footer-bottom { flex-direction: column; text-align: center; gap: 6px; }
  .footer-map iframe { height: 180px; }

  /* Clients */
  .clients-label { font-size: 12px; }

  /* Lightbox */
  .lightbox-overlay { padding: 12px; }
  .lightbox-inner img { max-height: 75vh; border-radius: 6px; }
  .lightbox-close { top: -40px; font-size: 28px; }
}

/* --- Mobile (≤480px) --- */
@media (max-width: 480px) {
  /* Container */
  .container { padding: 0 16px; }

  /* Header */
  .header-logo-img { width: 110px; }

  /* Hero */
  .hero-bg { height: 58vw; min-height: 200px; max-height: 280px; }
  .hero-content-wrap { padding: 28px 16px 36px; }
  .hero-title { font-size: clamp(20px, 6vw, 28px); }
  .hero-eyebrow { font-size: 11px; }
  .hero-desc { font-size: 14px; margin-bottom: 22px; }
  .hero-ctas { flex-direction: column; gap: 10px; }
  .btn-hero-primary,
  .btn-hero-outline { width: 100%; justify-content: center; }

  /* Sections */
  .section-pad { padding: 44px 0; }
  .section-sub { font-size: 14px; }
  .section-title { font-size: clamp(22px, 6vw, 32px); }

  /* Services */
  .service-card { border-radius: 10px; }
  .service-img img { height: 180px; }

  /* Why Us badges */
  .why-us-img-badge { display: none; }

  /* Capabilities */
  .cap-img img { height: 200px; }
  .cap-section { padding: 44px 0; }
  .cap-tags { gap: 8px; }
  .cap-tag { font-size: 11px; padding: 4px 12px; }

  /* Products */
  .product-grid { grid-template-columns: 1fr; gap: 14px; }
  .product-section { padding: 44px 0; }

  /* Footer */
  .footer-grid { grid-template-columns: 1fr; gap: 28px; }
  .footer-col h4 { margin-bottom: 16px; }
  .footer-bottom { flex-direction: column; text-align: center; gap: 6px; font-size: 12px; }
  .footer-map iframe { height: 160px; }

  /* Page hero (capabilities / products pages) */
  .page-hero { padding: 44px 0; }
  .page-hero h1 { font-size: clamp(22px, 7vw, 34px); }
  .page-hero p { font-size: 14px; }

  /* Logo carousel */
  .logo-slider { animation-duration: 18s; }

  /* Buttons */
  .btn { padding: 12px 20px; font-size: 13px; }
}

/* --- Small mobile (≤360px) --- */
@media (max-width: 360px) {
  .container { padding: 0 12px; }
  .hero-title { font-size: clamp(18px, 6vw, 24px); }
  .section-title { font-size: clamp(20px, 6vw, 26px); }
  .prod-tab { padding: 12px 14px; font-size: 12px; }
  .btn-hero-primary,
  .btn-hero-outline { padding: 11px 18px; font-size: 12px; }
}

/* ==========================================================================
   GLOBAL FIXES — Prevent horizontal overflow & improve 1:1 zoom rendering
   ========================================================================== */

html, body {
  overflow-x: hidden;
  width: 100%;
  /* Force consistent text rendering at 100% zoom across all browsers */
  -webkit-text-size-adjust: 100%;
  -moz-text-size-adjust: 100%;
  text-size-adjust: 100%;
}

/* Remove tap highlight on mobile */
* { -webkit-tap-highlight-color: transparent; }

/* Improve touch targets (minimum 44px per Apple/Google guidelines) */
a, button, .nav-toggle, .prod-tab { min-height: 44px; }
.nav-toggle { min-height: unset; } /* hamburger is compact */

/* Safe area insets for notched phones (iPhone X+) */
@supports (padding: max(0px)) {
  #site-header .header-inner {
    padding-left:  max(24px, env(safe-area-inset-left));
    padding-right: max(24px, env(safe-area-inset-right));
  }
  .site-footer .container {
    padding-left:  max(24px, env(safe-area-inset-left));
    padding-right: max(24px, env(safe-area-inset-right));
  }
}
