/* ===========================
   RESET & BASE
=========================== */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }
body {
  font-family: 'Kumbh Sans', sans-serif;
  color: #1a1a1a;
  font-size: 16px;
  line-height: 1.65;
  background: #fff;
}
a { text-decoration: none; color: inherit; }
ul { list-style: none; }
img { max-width: 100%; display: block; }

/* ===========================
   TOKENS
=========================== */
:root {
  --red: #E31C21;
  --blue: #0170B9;
  --dark: #111827;
  --muted: #6b7280;
  --light: #f9fafb;
  --border: #e5e7eb;
  --white: #ffffff;
  --radius: 12px;
  --shadow: 0 4px 24px rgba(0,0,0,0.07);
}

/* ===========================
   LAYOUT
=========================== */
.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 2rem;
}
.section { padding: 6rem 0; }

/* ===========================
   TYPOGRAPHY
=========================== */
h1 { font-size: clamp(2.4rem, 5vw, 3.8rem); font-weight: 800; line-height: 1.1; color: var(--dark); }
h2 { font-size: clamp(1.8rem, 3vw, 2.6rem); font-weight: 800; color: var(--dark); line-height: 1.2; }
h4 { font-size: 1.05rem; font-weight: 700; color: var(--dark); margin-bottom: 0.4rem; }
h5 { font-size: 0.8rem; font-weight: 700; letter-spacing: 0.06em; text-transform: uppercase; color: var(--dark); margin-bottom: 1rem; }

.eyebrow {
  display: inline-block;
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--red);
  margin-bottom: 0.75rem;
}

/* Large hero eyebrow */
.hero-eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 1rem;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--red);
  margin-bottom: 1rem;
  padding: 0.45rem 1.1rem;
  background: #fff0f0;
  border-radius: 30px;
  border: 1.5px solid rgba(227,28,33,0.2);
}
.hero-eyebrow::before {
  content: "✦";
  font-size: 0.7rem;
}

/* AI tag on product cards */
.sol-ai-tag {
  display: inline-block;
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--red);
  background: #fff0f0;
  border-radius: 20px;
  padding: 0.2rem 0.6rem;
  margin-bottom: 0.25rem;
}

.section-header {
  text-align: center;
  max-width: 620px;
  margin: 0 auto 3.5rem;
}
.section-header p {
  color: var(--muted);
  margin-top: 0.75rem;
  font-size: 1.05rem;
}

/* ===========================
   BUTTONS
=========================== */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  padding: 0.75rem 1.75rem;
  font-family: inherit;
  font-size: 0.92rem;
  font-weight: 700;
  border: none;
  cursor: pointer;
  border-radius: 6px;
  transition: all 0.2s;
  white-space: nowrap;
}
.btn-primary {
  background: var(--red);
  color: #fff;
}
.btn-primary:hover { background: #c0161b; transform: translateY(-1px); box-shadow: 0 4px 16px rgba(227,28,33,0.3); }

.btn-ghost {
  background: transparent;
  color: var(--dark);
  border: 2px solid var(--border);
}
.btn-ghost:hover { border-color: var(--dark); background: var(--light); }

.btn-full { width: 100%; justify-content: center; border-radius: 6px; }

/* ===========================
   HEADER
=========================== */
.site-header {
  position: sticky;
  top: 0;
  z-index: 300;
  background: rgba(255,255,255,0.95);
  backdrop-filter: blur(8px);
  border-bottom: 1px solid var(--border);
}
.header-inner {
  display: flex;
  align-items: center;
  gap: 2rem;
  height: 68px;
}

/* Logo */
.logo {
  display: flex;
  align-items: center;
  flex-shrink: 0;
}
.logo-img { height: 44px; width: auto; display: block; }
.footer-logo-img { height: 38px; width: auto; display: block; margin-bottom: 1rem; filter: brightness(0) invert(1); }

/* Nav */
.main-nav { flex: 1; }
.nav-list {
  display: flex;
  align-items: center;
  gap: 0.1rem;
}
.nav-list > li { position: relative; }
.has-dropdown { padding-bottom: 2px; } /* extra hover zone at bottom */
.nav-list > li > a {
  display: flex;
  align-items: center;
  gap: 0.3rem;
  padding: 0.5rem 1rem;
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--muted);
  border-radius: 6px;
  transition: color 0.15s, background 0.15s;
}
.nav-list > li > a:hover,
.nav-list > li > a.active { color: var(--dark); background: var(--light); }
.nav-list > li > a.active { color: var(--red); }

/* Dropdown */
.dropdown {
  display: none;
  position: absolute;
  top: 100%;          /* flush — no gap */
  left: 0;
  background: #fff;
  min-width: 210px;
  border-radius: 0 0 12px 12px;
  box-shadow: 0 12px 32px rgba(0,0,0,0.13);
  border: 1px solid var(--border);
  border-top: none;
  overflow: hidden;
  z-index: 200;
  padding-top: 4px;   /* small visual breath at top */
}

/* Invisible bridge fills the gap between nav link and dropdown */
.has-dropdown::after {
  content: '';
  position: absolute;
  top: 100%;
  left: 0;
  width: 100%;
  height: 12px;
  background: transparent;
}

.has-dropdown:hover .dropdown,
.has-dropdown.open .dropdown { display: block; }

/* Bigger click targets */
.dropdown li a {
  display: block;
  padding: 0.8rem 1.3rem;
  font-size: 0.9rem;
  font-weight: 500;
  color: #333;
  transition: color 0.15s;
}

/* Hover */
.dropdown li a:hover { color: var(--red); background: #fafafa; }

/* Header actions */
.header-actions {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  margin-left: auto;
}
.hamburger {
  display: none;
  flex-direction: column;
  gap: 5px;
  background: none;
  border: none;
  cursor: pointer;
  padding: 4px;
}
.hamburger span { display: block; width: 22px; height: 2px; background: var(--dark); border-radius: 2px; transition: all 0.3s; }

/* ===========================
   LANGUAGE SWITCHER
=========================== */
.lang-switcher {
  position: relative;
}
.lang-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  padding: 0.45rem 0.9rem;
  font-family: inherit;
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--dark);
  background: var(--light);
  border: 1px solid var(--border);
  border-radius: 6px;
  cursor: pointer;
  transition: all 0.2s;
  white-space: nowrap;
}
.lang-btn:hover { border-color: var(--dark); background: #fff; }
.lang-btn .fa-globe { color: var(--blue); font-size: 0.85rem; }
.lang-arrow { opacity: 0.5; transition: transform 0.2s; }
.lang-switcher.open .lang-arrow { transform: rotate(180deg); }

.lang-dropdown {
  display: none;
  position: absolute;
  top: calc(100% + 6px);
  right: 0;
  background: #fff;
  min-width: 160px;
  border-radius: 10px;
  box-shadow: 0 8px 28px rgba(0,0,0,0.12);
  border: 1px solid var(--border);
  overflow: hidden;
  z-index: 200;
  padding: 0.4rem 0;
}
.lang-switcher.open .lang-dropdown { display: block; }

.lang-option {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  padding: 0.65rem 1.1rem;
  font-size: 0.88rem;
  font-weight: 500;
  color: #333;
  transition: background 0.15s, color 0.15s;
}
.lang-option:hover { background: var(--light); color: var(--dark); }
.lang-option.active { color: var(--blue); font-weight: 700; }

/* ===========================
   HERO
=========================== */
.hero {
  padding: 5.5rem 0 4.5rem;
  overflow: hidden;
  position: relative;
  background-color: #080f1e;
  background-image:
    radial-gradient(ellipse 60% 80% at 10% 50%, rgba(227,28,33,0.13) 0%, transparent 65%),
    radial-gradient(ellipse 55% 70% at 90% 20%, rgba(1,112,185,0.16) 0%, transparent 60%),
    radial-gradient(ellipse 40% 50% at 75% 85%, rgba(1,112,185,0.10) 0%, transparent 55%);
}
/* Dot grid texture */
.hero::before {
  content: '';
  position: absolute;
  inset: 0;
  background-image: radial-gradient(circle, rgba(255,255,255,0.07) 1px, transparent 1px);
  background-size: 32px 32px;
  pointer-events: none;
  z-index: 0;
}
/* Red accent line left edge */
.hero::after {
  content: '';
  position: absolute;
  left: 0; top: 0; bottom: 0;
  width: 4px;
  background: linear-gradient(to bottom, transparent, var(--red) 30%, var(--red) 70%, transparent);
  z-index: 1;
}
.hero-inner {
  display: grid;
  grid-template-columns: 1fr 1.35fr;
  gap: 0;
  align-items: center;
  position: relative;
  z-index: 2;
}
.hero-text { max-width: 520px; }
.hero-text h1 { margin: 0.5rem 0 1.25rem; color: #fff; }
.hero-text p { color: rgba(255,255,255,0.58); font-size: 1.05rem; margin-bottom: 2rem; max-width: 440px; }
.hero-ctas { display: flex; gap: 1rem; flex-wrap: wrap; }

/* Override eyebrow + ghost btn for dark hero */
.hero .hero-eyebrow {
  color: #f87171;
  background: rgba(227,28,33,0.14);
  border-color: rgba(227,28,33,0.28);
}
.hero .hero-eyebrow::before { color: #f87171; }
.hero .btn-ghost {
  color: rgba(255,255,255,0.88);
  border-color: rgba(255,255,255,0.22);
  background: rgba(255,255,255,0.04);
}
.hero .btn-ghost:hover {
  background: rgba(255,255,255,0.10);
  border-color: rgba(255,255,255,0.45);
}

.hero-visual {
  display: flex;
  align-items: stretch;
  justify-content: flex-end;
  position: relative;
  margin-right: calc(-2rem);
  align-self: stretch;
  overflow: hidden;
}
/* Ambient glow behind image */
.hero-visual::before {
  content: '';
  position: absolute;
  inset: -10%;
  background:
    radial-gradient(ellipse 70% 60% at 55% 45%, rgba(1,112,185,0.22) 0%, transparent 65%),
    radial-gradient(ellipse 50% 50% at 30% 65%, rgba(227,28,33,0.12) 0%, transparent 60%);
  filter: blur(28px);
  z-index: 0;
  pointer-events: none;
}
.hero-visual img {
  position: relative;
  z-index: 1;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
  -webkit-mask-image: radial-gradient(ellipse 78% 75% at 55% 50%, black 25%, rgba(0,0,0,0.85) 46%, rgba(0,0,0,0.4) 62%, transparent 76%);
  mask-image: radial-gradient(ellipse 78% 75% at 55% 50%, black 25%, rgba(0,0,0,0.85) 46%, rgba(0,0,0,0.4) 62%, transparent 76%);
}
.hero-visual svg { width: 100%; max-width: 520px; height: auto; }

/* ===========================
   STATS BAR
=========================== */
.stats-bar {
  background: #080f1e;
  padding: 2.5rem 0 0;
  position: relative;
}
.stats-bar::after {
  content: '';
  display: block;
  width: 100%;
  height: 90px;
  margin-top: 2.5rem;
  background: linear-gradient(to bottom, #080f1e, #ffffff);
  pointer-events: none;
}
.stats-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  flex-wrap: wrap;
}
.stat {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  color: #fff;
  flex: 1;
  min-width: 120px;
}
.stat-num { font-size: 2.2rem; font-weight: 800; line-height: 1; }
.stat-label { font-size: 0.78rem; opacity: 0.85; margin-top: 0.35rem; font-weight: 500; letter-spacing: 0.02em; }
.stat-divider { width: 1px; height: 40px; background: rgba(255,255,255,0.25); flex-shrink: 0; }

/* ===========================
   SOLUTIONS
=========================== */
.solutions-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.5rem;
}
.sol-card {
  display: flex;
  flex-direction: column;
  gap: 0.6rem;
  padding: 2rem;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  transition: border-color 0.2s, box-shadow 0.2s, transform 0.2s;
  background: #fff;
  color: inherit;
}
.sol-card:hover {
  border-color: transparent;
  box-shadow: var(--shadow);
  transform: translateY(-3px);
}
.sol-icon {
  width: 48px;
  height: 48px;
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.2rem;
  margin-bottom: 0.4rem;
}
.sol-card p { color: var(--muted); font-size: 0.92rem; flex: 1; }
.sol-link {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  font-size: 0.85rem;
  font-weight: 700;
  color: var(--red);
  margin-top: 0.5rem;
}

/* Image-based product cards grid */
.sol-img-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1.25rem;
}
.sol-img-card {
  display: flex;
  flex-direction: column;
  background: #fff;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
  color: inherit;
  transition: border-color 0.2s, box-shadow 0.2s, transform 0.2s;
  cursor: pointer;
}
.sol-img-card:hover {
  border-color: transparent;
  box-shadow: 0 8px 32px rgba(0,0,0,0.10);
  transform: translateY(-4px);
}
.sol-img-wrap {
  width: 100%;
  aspect-ratio: 4/3;
  overflow: hidden;
  background: var(--light);
  display: flex;
  align-items: center;
  justify-content: center;
}
.sol-img-wrap img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.35s ease;
}
.sol-img-card:hover .sol-img-wrap img { transform: scale(1.05); }
.sol-img-body {
  padding: 1.25rem 1.3rem 1.4rem;
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
  flex: 1;
}
.sol-img-body h4 { margin-bottom: 0.1rem; }
.sol-img-body p { color: var(--muted); font-size: 0.88rem; line-height: 1.55; flex: 1; }
.sol-img-body .sol-link { margin-top: 0.6rem; }

/* Solutions groups */
.solutions-group { margin-bottom: 0; }

.solutions-group-header {
  display: flex;
  align-items: center;
  gap: 2rem;
  margin-bottom: 1.75rem;
  flex-wrap: wrap;
}
.solutions-group-header p { color: var(--muted); font-size: 0.95rem; margin: 0; }

.solutions-group-label {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.8rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  padding: 0.4rem 1rem;
  border-radius: 20px;
  white-space: nowrap;
}
.rapidx-label { background: #fff0f0; color: var(--red); }
.docscribe-label { background: #eef3ff; color: var(--blue); }

/* Dropdown group labels */
.dropdown-group-label {
  padding: 0.55rem 1.3rem;
  font-size: 0.72rem;
  font-weight: 800;
  letter-spacing: 0.07em;
  text-transform: uppercase;
  color: #fff;
  background: #4b5563;
}
.dropdown-divider {
  height: 1px;
  background: rgba(0,0,0,0.08);
  margin: 0;
}

/* ── Mega Menu (Solutions) ── */
.mega-menu {
  display: none;
  position: absolute;
  top: 100%;
  left: 0;
  background: #fff;
  width: 600px;
  border-radius: 0 0 16px 16px;
  box-shadow: 0 20px 52px rgba(0,0,0,0.13);
  border: 1px solid var(--border);
  border-top: 3px solid var(--red);
  padding: 1.25rem 1.5rem 1.5rem;
  z-index: 200;
  flex-direction: row;
  gap: 0;
}
.has-dropdown:hover .mega-menu,
.has-dropdown.open .mega-menu { display: flex; }

.mega-col { flex: 1; min-width: 0; }
.mega-col-ai { flex: 0 0 195px; }

.mega-col-label {
  font-size: 0.69rem;
  font-weight: 800;
  letter-spacing: 0.09em;
  text-transform: uppercase;
  color: #9ca3af;
  padding: 0 0.5rem 0.7rem;
  border-bottom: 1px solid var(--border);
  margin-bottom: 0.4rem;
}

.mega-sep {
  width: 1px;
  background: var(--border);
  margin: 0 1.25rem;
  align-self: stretch;
}

.mega-item {
  display: flex;
  align-items: center;
  gap: 0.8rem;
  padding: 0.6rem 0.5rem;
  border-radius: 10px;
  border: 1px solid transparent;
  transition: background 0.15s, border-color 0.15s;
  text-decoration: none;
  color: inherit;
}
.mega-item:hover { background: var(--light); border-color: var(--blue); }

.mega-icon-wrap {
  width: 38px;
  height: 38px;
  border-radius: 9px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1rem;
  flex-shrink: 0;
}
.mi-red    { background: #fff0f0; color: var(--red); }
.mi-blue   { background: #eff6ff; color: var(--blue); }
.mi-green  { background: #f0fdf4; color: #0e9f6e; }
.mi-purple { background: #f5f3ff; color: #7c3aed; }
.mi-ai     { background: linear-gradient(135deg, #eff6ff, #f5f3ff); color: var(--blue); }

.mega-item-body { display: flex; flex-direction: column; gap: 0.12rem; min-width: 0; }
.mega-item-body strong {
  font-size: 0.88rem; font-weight: 700; color: var(--dark);
  display: flex; align-items: center; gap: 0.4rem;
}
.mega-item-body > span { font-size: 0.77rem; color: var(--muted); line-height: 1.35; }

.mega-new-badge {
  font-size: 0.6rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  background: var(--red);
  color: #fff;
  padding: 0.1rem 0.45rem;
  border-radius: 20px;
}

.mega-item-featured {
  background: #f9fafb;
  border: 1px solid var(--border);
  border-radius: 12px;
  margin-top: 0.25rem;
}
.mega-item-featured:hover { background: #eff6ff; border-color: var(--blue); }

/* Mobile: mega menu collapses to stacked list */
@media (max-width: 768px) {
  .mega-menu {
    position: static;
    width: 100%;
    box-shadow: none;
    border: none;
    border-top: none;
    padding: 0 0 0 1rem;
    flex-direction: column;
    gap: 0;
  }
  .mega-sep { display: none; }
  .mega-col-ai { flex: unset; }
  .mega-col-label { display: none; }
  .mega-item-featured { background: none; border: none; margin-top: 0; }
}

/* Doc-Scribe — full-width dark band */
.solutions.section { padding-bottom: 0; }

.docscribe-fullband {
  background: #080f1e;
  position: relative;
  overflow: hidden;
  padding: 0 0 6rem;
  margin-top: 4rem;
}

/* Blue ambient glow on the image side */
.docscribe-fullband::after {
  content: '';
  position: absolute;
  right: 0; top: 0;
  width: 55%; height: 100%;
  background: radial-gradient(ellipse at 70% 50%, rgba(1,112,185,0.18) 0%, rgba(103,78,234,0.10) 50%, transparent 75%);
  pointer-events: none;
  z-index: 0;
}

/* Ensure content sits above the glow */
.docscribe-fullband .container {
  position: relative;
  z-index: 1;
  padding-top: 3rem;
}

/* ── Doc-Scribe launch — two-column layout ── */
.ds-layout {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 3rem;
  align-items: start;
}

/* LEFT column */
.ds-left {
  display: flex;
  flex-direction: column;
  gap: 0;
}

.ds-new-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  background: rgba(227,28,33,0.18);
  border: 1px solid rgba(227,28,33,0.4);
  color: #f87171;
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  padding: 0.35rem 1rem;
  border-radius: 30px;
  margin-bottom: 1rem;
  align-self: flex-start;
}

.ds-introducing {
  font-size: 0.95rem;
  font-weight: 600;
  color: rgba(255,255,255,0.4);
  letter-spacing: 0.18em;
  text-transform: uppercase;
  margin-bottom: 0.3rem;
}

.ds-title {
  font-size: clamp(2.8rem, 5vw, 4.5rem);
  font-weight: 800;
  color: #fff;
  line-height: 1;
  margin-bottom: 1rem;
  letter-spacing: -0.02em;
}
.ds-title span { color: var(--red); }

.ds-tagline {
  font-size: 1.1rem;
  color: rgba(255,255,255,0.7);
  line-height: 1.6;
  margin-bottom: 1.25rem;
}

.ds-body {
  font-size: 0.93rem;
  color: rgba(255,255,255,0.48);
  line-height: 1.7;
  margin-bottom: 1.25rem;
}

/* RIGHT column — blended image, bottom-aligned to text */
.ds-right {
  position: relative;
  display: flex;
  align-items: flex-end;
  justify-content: center;
  align-self: end;
}
.ds-right img {
  width: 100%;
  height: auto;
  display: block;
  -webkit-mask-image: radial-gradient(ellipse 80% 78% at 52% 50%, black 25%, rgba(0,0,0,0.85) 46%, rgba(0,0,0,0.4) 63%, transparent 78%);
  mask-image: radial-gradient(ellipse 80% 78% at 52% 50%, black 25%, rgba(0,0,0,0.85) 46%, rgba(0,0,0,0.4) 63%, transparent 78%);
}

/* CTAs */
.ds-ctas {
  display: flex;
  gap: 1rem;
  flex-wrap: wrap;
  margin-top: 1.75rem;
}
.ds-ghost {
  color: rgba(255,255,255,0.8) !important;
  border-color: rgba(255,255,255,0.22) !important;
  background: rgba(255,255,255,0.04) !important;
}
.ds-ghost:hover {
  background: rgba(255,255,255,0.1) !important;
  border-color: rgba(255,255,255,0.4) !important;
}

/* Responsive */
@media (max-width: 900px) {
  .ds-layout { grid-template-columns: 1fr; }
  .ds-right { display: none; }
  .ds-title { font-size: clamp(2.4rem, 6vw, 3.5rem); }
}

.docscribe-card {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 3rem;
  align-items: center;
  position: relative;
  z-index: 1;
}
.docscribe-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  background: rgba(103,126,234,0.2);
  border: 1px solid rgba(103,126,234,0.35);
  color: #a5b4fc;
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  padding: 0.3rem 0.85rem;
  border-radius: 20px;
  margin-bottom: 0.75rem;
}
.docscribe-left h3 { font-size: 1.8rem; font-weight: 800; margin-bottom: 0.75rem; color: #fff; }
.docscribe-left > p { color: rgba(255,255,255,0.58); line-height: 1.7; margin-bottom: 1.25rem; }

.docscribe-features {
  display: flex;
  flex-direction: column;
  gap: 0.55rem;
}
.docscribe-features li {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  font-size: 0.9rem;
  color: rgba(255,255,255,0.72);
}
.docscribe-features li i { color: #4ade80; font-size: 0.75rem; flex-shrink: 0; }

.docscribe-right { position: relative; }
.docscribe-right img {
  width: 100%;
  height: auto;
  border-radius: 0;
  display: block;
  -webkit-mask-image: radial-gradient(ellipse 85% 82% at 52% 50%, black 28%, rgba(0,0,0,0.85) 48%, rgba(0,0,0,0.4) 63%, transparent 78%);
  mask-image: radial-gradient(ellipse 85% 82% at 52% 50%, black 28%, rgba(0,0,0,0.85) 48%, rgba(0,0,0,0.4) 63%, transparent 78%);
}
.docscribe-right svg { width: 100%; height: auto; border-radius: 12px; }

/* ===========================
   WHY AMBERSOFT
=========================== */
.why { background: var(--light); }
.why-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1.5rem;
}
.why-card {
  background: #fff;
  border-radius: var(--radius);
  padding: 2rem 1.5rem;
  text-align: center;
}
.why-icon {
  width: 56px;
  height: 56px;
  background: #fff0f0;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.3rem;
  color: var(--red);
  margin: 0 auto 1rem;
}
.why-card p { color: var(--muted); font-size: 0.92rem; margin-top: 0.4rem; }

/* ===========================
   TESTIMONIALS
=========================== */
.testi-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.5rem;
}
.testi-card {
  background: #fff;
  border-radius: var(--radius);
  padding: 2rem;
  display: flex;
  flex-direction: column;
  gap: 1rem;
  box-shadow: var(--shadow);
}
.testi-quote { color: var(--red); font-size: 1.4rem; opacity: 0.3; }
.testi-card > p { color: var(--muted); font-size: 0.95rem; line-height: 1.7; font-style: italic; flex: 1; }
.testi-author {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  margin-top: auto;
}
.testi-avatar {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: var(--red);
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.8rem;
  font-weight: 700;
  flex-shrink: 0;
}
.testi-author strong { display: block; font-size: 0.92rem; color: var(--dark); }
.testi-author span { font-size: 0.8rem; color: var(--muted); }

/* ===========================
   CLIENTS
=========================== */
.clients-strip {
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
  justify-content: center;
}
.client-logo-wrap {
  padding: 1rem 2rem;
  display: flex;
  align-items: center;
  justify-content: center;
  min-width: 160px;
}
.client-logo-img {
  height: 70px;
  width: auto;
  max-width: 180px;
  object-fit: contain;
  transition: opacity 0.2s;
}
.client-logo-wrap:hover .client-logo-img {
  opacity: 0.85;
}

/* ===========================
   CONTACT
=========================== */
.contact { background: var(--dark); }
.contact-inner {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 5rem;
  align-items: start;
}
.contact-text .eyebrow { color: #f87171; }
.contact-text h2 { color: #fff; margin-bottom: 1rem; }
.contact-text > p { color: #9ca3af; margin-bottom: 2rem; }
.contact-details { display: flex; flex-direction: column; gap: 0.6rem; }
.contact-details p { color: #9ca3af; font-size: 0.92rem; display: flex; align-items: flex-start; gap: 0.6rem; }
.contact-details i { color: var(--red); margin-top: 0.2rem; flex-shrink: 0; }
.contact-details a { color: #9ca3af; }
.contact-details a:hover { color: #fff; }

.contact-form { display: flex; flex-direction: column; gap: 1.1rem; }
.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 1rem; }
.cf-group { display: flex; flex-direction: column; gap: 0.4rem; }
.cf-group label {
  font-size: 0.8rem;
  font-weight: 600;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  color: rgba(255,255,255,0.6);
}
.cf-req { color: var(--red); }
.contact-form input,
.contact-form select,
.contact-form textarea {
  width: 100%;
  padding: 0.85rem 1rem;
  background: rgba(255,255,255,0.06);
  border: 1px solid rgba(255,255,255,0.12);
  border-radius: 8px;
  color: #fff;
  font-family: inherit;
  font-size: 0.95rem;
  outline: none;
  transition: border-color 0.2s;
}
.contact-form select { cursor: pointer; }
.contact-form select option { background: #1a2340; color: #fff; }
.contact-form input::placeholder,
.contact-form textarea::placeholder { color: #6b7280; }
.contact-form input:focus,
.contact-form select:focus,
.contact-form textarea:focus { border-color: var(--red); }
.contact-form textarea { resize: vertical; }
.cf-success {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  background: rgba(34,197,94,0.12);
  border: 1px solid rgba(34,197,94,0.3);
  border-radius: 8px;
  color: #4ade80;
  font-size: 0.92rem;
  padding: 0.75rem 1rem;
  font-weight: 600;
}

/* ===========================
   FOOTER
=========================== */
.site-footer { background: #0f172a; }
.footer-inner {
  display: grid;
  grid-template-columns: 1.8fr 1fr 1fr 1.3fr;
  gap: 3rem;
  padding: 4rem 0 3rem;
}
.footer-brand .logo { margin-bottom: 1rem; }
.footer-brand .logo-text { color: #fff; }
.footer-brand p { color: #6b7280; font-size: 0.9rem; line-height: 1.7; margin-bottom: 1.5rem; }
.footer-social { display: flex; gap: 0.6rem; }
.footer-social a {
  width: 34px; height: 34px;
  border-radius: 50%;
  border: 1px solid #374151;
  display: flex; align-items: center; justify-content: center;
  color: #6b7280;
  font-size: 0.78rem;
  transition: all 0.2s;
}
.footer-social a:hover { background: var(--red); border-color: var(--red); color: #fff; }

.footer-col h5 { color: #9ca3af; }
.footer-col ul { display: flex; flex-direction: column; gap: 0.6rem; }
.footer-col ul li { font-size: 0.88rem; color: #6b7280; line-height: 1.5; }
.footer-col ul li a { color: #6b7280; transition: color 0.15s; }
.footer-col ul li a:hover { color: #fff; }

.footer-bottom {
  border-top: 1px solid #1f2937;
  padding: 1.25rem 0;
}
.footer-bottom p { color: #4b5563; font-size: 0.85rem; text-align: center; }

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

/* ── Large tablet / small laptop ── */
@media (max-width: 1024px) {
  .hero-inner { grid-template-columns: 1fr 1fr; gap: 1rem; }
  .hero-visual { margin-right: -1rem; }
  .why-grid { grid-template-columns: repeat(2, 1fr); }
  .testi-grid { grid-template-columns: repeat(2, 1fr); }
  .footer-inner { grid-template-columns: 1fr 1fr; }
}

/* ── Tablet portrait ── */
@media (max-width: 900px) {
  .hero-inner { grid-template-columns: 1fr 1fr; gap: 0; }
  .hero-visual { margin-right: 0; }
  .docscribe-card { grid-template-columns: 1fr; }
  .docscribe-right { display: none; }
  .sol-img-grid { grid-template-columns: repeat(2, 1fr); }
  .solutions-group-header { flex-direction: column; align-items: flex-start; gap: 0.5rem; }
  .docscribe-fullband { padding-bottom: 4rem; }
  .docscribe-fullband .container { padding-top: 3rem; }
}

/* ── Mobile landscape / small tablet ── */
@media (max-width: 768px) {
  .section { padding: 4rem 0; }

  /* Hero */
  .hero { padding: 4rem 0 0; }
  .hero::after { display: none; } /* hide red side bar */
  .hero-inner { grid-template-columns: 1fr; gap: 0; }
  .hero-visual { display: none; }
  .hero-text { text-align: center; max-width: 100%; }
  .hero-text p { max-width: 100%; }
  .hero-ctas { justify-content: center; }
  .hero-eyebrow { display: inline-flex; }

  /* Stats */
  .stat-divider { display: none; }
  .stats-inner { gap: 1.5rem; justify-content: center; flex-wrap: wrap; }
  .stat { min-width: 120px; }

  /* Solutions */
  .solutions-grid { grid-template-columns: 1fr 1fr; }
  .sol-img-grid { grid-template-columns: repeat(2, 1fr); }

  /* Testimonials */
  .testi-grid { grid-template-columns: 1fr; }

  /* Contact */
  .contact-inner { grid-template-columns: 1fr; gap: 3rem; }
  .contact-text { text-align: center; }
  .form-row { grid-template-columns: 1fr; }

  /* Nav */
  .main-nav { display: none; }
  .hamburger { display: flex; }
  .main-nav.open {
    display: block;
    position: absolute;
    top: 68px; left: 0; right: 0;
    background: #fff;
    border-bottom: 1px solid var(--border);
    padding: 1rem 2rem;
    z-index: 99;
  }
  .main-nav.open .nav-list { flex-direction: column; align-items: flex-start; }
  .main-nav.open .dropdown { position: static; box-shadow: none; border: none; padding-left: 1rem; }

  /* Footer */
  .footer-inner { grid-template-columns: 1fr 1fr; gap: 2rem; }
  .footer-brand { grid-column: 1 / -1; }
}

/* ── Mobile portrait ── */
@media (max-width: 540px) {
  .section { padding: 3rem 0; }
  .hero { padding: 3rem 0 0; }

  /* Solutions */
  .solutions-grid { grid-template-columns: 1fr; }
  .sol-img-grid { grid-template-columns: 1fr; }

  /* Why grid */
  .why-grid { grid-template-columns: 1fr; }

  /* Buttons */
  .hero-ctas { flex-direction: column; align-items: center; }
  .hero-ctas .btn { width: 100%; max-width: 320px; justify-content: center; }

  /* Clients */
  .clients-strip { gap: 0.75rem; }
  .client-logo-wrap { min-width: 130px; padding: 0.75rem 1rem; }

  /* Footer */
  .footer-inner { grid-template-columns: 1fr; gap: 2rem; }

  /* Stats */
  .stats-inner { gap: 1.5rem; }
  .stat-num { font-size: 1.8rem; }
}
