:root {
  --navy: #100a26;
  --navy-2: #1c1444;
  --violet: #6c5ce7;
  --violet-soft: #a29bfe;
  --teal: #17c3b2;
  --teal-dark: #0f9c8f;
  --ink: #1c1730;
  --muted: #5c5a75;
  --bg: #f7f6fb;
  --card: #ffffff;
  --border: #e7e4f2;
  --danger: #b3261e;
  --success: #1e7a4a;
  --radius: 14px;
  --radius-sm: 10px;
  --shadow-sm: 0 2px 10px rgba(16, 10, 38, 0.06);
  --shadow-md: 0 12px 32px rgba(16, 10, 38, 0.14);
  --shadow-glow: 0 8px 28px rgba(108, 92, 231, 0.35);
  --font-heading: "Sora", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  --font-body: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  font-size: 16px;
}

* { box-sizing: border-box; }

body {
  margin: 0;
  font-family: var(--font-body);
  color: var(--ink);
  background: var(--bg);
  line-height: 1.65;
}

h1, h2, h3, h4 { font-family: var(--font-heading); letter-spacing: -0.01em; }

.container {
  max-width: 1120px;
  margin: 0 auto;
  padding: 0 24px;
}

.container-narrow {
  max-width: 720px;
}

/* Header */
.site-header {
  background: rgba(78, 66, 120, 0.75);
  backdrop-filter: blur(14px) saturate(140%);
  -webkit-backdrop-filter: blur(14px) saturate(140%);
  color: #fff;
  position: sticky;
  top: 0;
  z-index: 50;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.nav-wrap {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px 24px;
}

.brand {
  color: #fff;
  text-decoration: none;
  font-family: var(--font-heading);
  font-weight: 700;
  font-size: 1.2rem;
  display: flex;
  align-items: center;
  gap: 10px;
}

.brand-logo { height: 102px; display: block; }

.brand-mark {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 30px;
  height: 30px;
  background: linear-gradient(135deg, var(--violet), var(--teal));
  border-radius: 9px;
  font-weight: 800;
  box-shadow: var(--shadow-glow);
}

.site-nav { display: flex; align-items: center; }

.site-nav a {
  color: #cbc7e8;
  text-decoration: none;
  margin-left: 26px;
  font-weight: 500;
  font-size: 0.95rem;
  transition: color 0.15s ease;
}

.site-nav a:hover { color: #fff; }

.nav-cta {
  background: linear-gradient(135deg, var(--violet), var(--teal));
  color: #fff !important;
  padding: 9px 20px;
  border-radius: 999px;
  box-shadow: var(--shadow-glow);
}

.nav-toggle {
  display: none;
  background: none;
  border: none;
  cursor: pointer;
  padding: 6px;
  margin-left: 12px;
}
.nav-toggle span {
  display: block;
  width: 22px;
  height: 2px;
  background: #fff;
  margin: 4px 0;
  border-radius: 2px;
  transition: transform 0.2s ease, opacity 0.2s ease;
}
.nav-toggle.is-open span:nth-child(1) { transform: translateY(6px) rotate(45deg); }
.nav-toggle.is-open span:nth-child(2) { opacity: 0; }
.nav-toggle.is-open span:nth-child(3) { transform: translateY(-6px) rotate(-45deg); }

@media (max-width: 760px) {
  .nav-toggle { display: block; }
  .site-nav {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    flex-direction: column;
    align-items: flex-start;
    background: rgba(16, 10, 38, 0.97);
    padding: 12px 24px 20px;
    display: none;
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
  }
  .site-nav.is-open { display: flex; }
  .site-nav a { margin-left: 0; padding: 10px 0; width: 100%; }
  .nav-cta { margin-top: 8px; text-align: center; }
  .brand-logo { height: 56px; }
}

@media (max-width: 480px) {
  .hero-gallery {
    height: 42vh;
    min-height: 260px;
    max-height: 360px;
  }
}

/* Rotating homepage gallery */
.hero-gallery {
  position: relative;
  width: 100%;
  height: 92vh;
  min-height: 560px;
  max-height: 960px;
  overflow: hidden;
  background: var(--navy);
}

.hero-gallery-track { position: relative; width: 100%; height: 100%; }

.hero-gallery-slide {
  position: absolute;
  inset: 0;
  margin: 0;
  opacity: 0;
  transition: opacity 0.9s ease;
}

.hero-gallery-slide.is-active { opacity: 1; }

.hero-gallery-slide img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center 30%;
  display: block;
}

.hero-gallery-slide figcaption {
  position: absolute;
  left: 24px;
  bottom: 20px;
  color: #fff;
  background: rgba(18, 12, 43, 0.55);
  backdrop-filter: blur(6px);
  padding: 6px 14px;
  border-radius: 999px;
  font-size: 0.85rem;
}

.hero-gallery-dots {
  position: absolute;
  bottom: 16px;
  right: 24px;
  display: flex;
  gap: 8px;
}

.hero-gallery-dot {
  width: 9px;
  height: 9px;
  border-radius: 50%;
  border: none;
  background: rgba(255, 255, 255, 0.45);
  cursor: pointer;
  padding: 0;
}

.hero-gallery-dot.is-active { background: #fff; }

/* Hero */
.hero {
  position: relative;
  background: linear-gradient(160deg, var(--navy), var(--navy-2));
  color: #fff;
  padding: 100px 0;
  overflow: hidden;
  isolation: isolate;
}

.hero::before,
.hero::after {
  content: "";
  position: absolute;
  border-radius: 50%;
  filter: blur(70px);
  z-index: -1;
}
.hero::before {
  width: 480px;
  height: 480px;
  background: radial-gradient(circle, rgba(108, 92, 231, 0.55), transparent 70%);
  top: -180px;
  left: -120px;
}
.hero::after {
  width: 420px;
  height: 420px;
  background: radial-gradient(circle, rgba(23, 195, 178, 0.35), transparent 70%);
  bottom: -200px;
  right: -100px;
}

.hero-inner { max-width: 680px; position: relative; }

.hero h1 { font-size: 2.6rem; margin: 0 0 16px; line-height: 1.15; }
.hero p { font-size: 1.1rem; color: #cfc9ea; margin: 0 0 28px; }

.btn {
  display: inline-block;
  padding: 13px 28px;
  border-radius: 999px;
  text-decoration: none;
  font-weight: 600;
  border: none;
  cursor: pointer;
  font-size: 1rem;
  font-family: var(--font-body);
  transition: transform 0.15s ease, box-shadow 0.15s ease, filter 0.15s ease;
}

.btn-primary {
  background: linear-gradient(135deg, var(--violet), var(--teal));
  color: #fff;
  box-shadow: var(--shadow-glow);
}

.btn-primary:hover { filter: brightness(1.08); transform: translateY(-2px); }

/* Sections */
.section { padding: 72px 0; }
.section-alt { background: #f0eefb; }
.section-title { font-size: 1.8rem; margin: 0 0 36px; text-align: center; }
.section-cta { text-align: center; margin-top: 28px; }
.section-cta a { color: var(--teal-dark); text-decoration: none; font-weight: 600; }

.page-header {
  background: linear-gradient(160deg, var(--navy), var(--navy-2));
  color: #fff;
  padding: 56px 0;
}
.page-header h1 { margin: 0; font-size: 2rem; }

.body-text { font-size: 1.05rem; color: var(--ink); }

/* Scroll reveal */
.reveal {
  opacity: 0;
  transform: translateY(22px);
  transition: opacity 0.7s ease, transform 0.7s ease;
}
.reveal.is-visible { opacity: 1; transform: translateY(0); }

/* Grid / Cards */
.grid { display: grid; gap: 24px; }
.grid-3 { grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); }

.card {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 30px;
  box-shadow: var(--shadow-sm);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}
.card:hover { transform: translateY(-4px); box-shadow: var(--shadow-md); }

.card-icon {
  width: 48px;
  height: 48px;
  border-radius: 12px;
  background: linear-gradient(135deg, #ece9fb, #e2f6f4);
  color: var(--violet);
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 18px;
}
.card-icon svg { width: 24px; height: 24px; }

.card h3 { margin: 0 0 10px; font-size: 1.1rem; }
.card p { margin: 0; color: var(--muted); }

/* Healthcare AI section */
.section-ai {
  position: relative;
  background: linear-gradient(160deg, var(--navy), var(--navy-2));
  color: #fff;
  overflow: hidden;
  isolation: isolate;
}
.section-ai::before {
  content: "";
  position: absolute;
  width: 500px;
  height: 500px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(108, 92, 231, 0.3), transparent 70%);
  filter: blur(80px);
  top: -220px;
  right: -160px;
  z-index: -1;
}
.ai-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 48px;
  align-items: center;
}
.eyebrow {
  display: inline-block;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  font-size: 0.75rem;
  font-weight: 700;
  color: var(--violet-soft);
  margin-bottom: 10px;
}
.ai-copy h2 { font-size: 2rem; margin: 0 0 12px; }
.ai-subheading { color: var(--teal); font-weight: 600; font-size: 1.05rem; margin: 0 0 14px; }
.ai-copy p { color: #cfc9ea; }
.ai-copy p.ai-subheading { color: var(--teal); }

.ai-video-frame {
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.15);
  border-radius: var(--radius);
  padding: 12px;
  backdrop-filter: blur(10px);
}
.ai-video-frame video {
  width: 100%;
  display: block;
  border-radius: 8px;
  background: #000;
}
.ai-video-placeholder {
  width: 100%;
  aspect-ratio: 16 / 9;
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.08);
  display: flex;
  align-items: center;
  justify-content: center;
  color: rgba(255, 255, 255, 0.6);
}
.ai-video-placeholder svg { width: 46px; height: 46px; }

@media (max-width: 800px) {
  .ai-grid { grid-template-columns: 1fr; }
}

.ai-feature-card {
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.15);
  border-radius: var(--radius);
  overflow: hidden;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}
.ai-feature-card:hover { transform: translateY(-4px); box-shadow: var(--shadow-glow); }
.ai-feature-image {
  width: 100%;
  aspect-ratio: 4 / 3;
  overflow: hidden;
  background: rgba(255, 255, 255, 0.08);
}
.ai-feature-image img { width: 100%; height: 100%; object-fit: cover; display: block; }
.ai-feature-image-empty {
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: rgba(255, 255, 255, 0.45);
}
.ai-feature-image-empty svg { width: 40px; height: 40px; }
.ai-feature-body { padding: 24px; }
.ai-feature-card h3 { color: #fff; margin: 0 0 10px; font-size: 1.05rem; }
.ai-feature-card p { color: #cfc9ea; margin: 0; }

/* Forms */
.form { display: flex; flex-direction: column; gap: 16px; margin-bottom: 32px; }
.form label { font-weight: 600; font-size: 0.95rem; display: flex; flex-direction: column; gap: 6px; }
.form input, .form textarea, .form select {
  font: inherit;
  padding: 11px 14px;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  background: #fff;
  transition: border-color 0.15s ease, box-shadow 0.15s ease;
}
.form input:focus, .form textarea:focus, .form select:focus {
  outline: none;
  border-color: var(--violet);
  box-shadow: 0 0 0 3px rgba(108, 92, 231, 0.15);
}

.alert { padding: 14px 18px; border-radius: var(--radius-sm); margin-bottom: 20px; }
.alert-success { background: #e5f4ea; color: var(--success); }
.alert-error { background: #fbe9e7; color: var(--danger); }
.alert ul { margin: 0; padding-left: 20px; }

.contact-info { margin-top: 24px; color: var(--muted); }
.contact-info p { margin: 4px 0; }

/* Footer */
.site-footer { background: var(--navy); color: #cbc7e8; padding: 44px 0 18px; margin-top: 40px; }
.footer-wrap { display: flex; justify-content: space-between; gap: 24px; flex-wrap: wrap; }
.site-footer strong { color: #fff; font-family: var(--font-heading); }
.site-footer p { margin: 4px 0; }
.footer-note { color: #8b87ab; font-size: 0.85rem; margin-top: 24px; }

/* ---------- Admin ---------- */
.admin-body { background: #f3f2f9; min-height: 100vh; font-family: var(--font-body); }
.admin-shell { display: flex; min-height: 100vh; }
.admin-sidebar {
  width: 220px;
  background: var(--navy);
  color: #fff;
  padding: 24px 0;
  flex-shrink: 0;
}
.admin-sidebar .brand { padding: 0 24px 24px; }
.admin-sidebar a {
  display: block;
  color: #cbc7e8;
  text-decoration: none;
  padding: 12px 24px;
  font-weight: 500;
}
.admin-sidebar a:hover, .admin-sidebar a.active { background: rgba(255,255,255,0.08); color: #fff; }
.admin-main { flex: 1; padding: 32px; }
.admin-topbar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 28px;
}
.admin-topbar h1 { margin: 0; font-size: 1.5rem; }
.btn-secondary {
  background: #fff;
  border: 1px solid var(--border);
  color: var(--ink);
  padding: 8px 16px;
  border-radius: var(--radius-sm);
  font-weight: 600;
  cursor: pointer;
  text-decoration: none;
  display: inline-block;
  transition: box-shadow 0.15s ease, transform 0.15s ease;
}
.btn-secondary:hover { box-shadow: var(--shadow-sm); transform: translateY(-1px); }
.btn-secondary:disabled { opacity: 0.45; cursor: not-allowed; transform: none; box-shadow: none; }
.btn-danger { background: var(--danger); color: #fff; border-color: transparent; }
.btn-small { padding: 6px 12px; font-size: 0.85rem; }

.stat-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(180px, 1fr)); gap: 20px; margin-bottom: 32px; }
.stat-card { background: #fff; border: 1px solid var(--border); border-radius: var(--radius); padding: 20px; box-shadow: var(--shadow-sm); }
.stat-card .stat-value { font-size: 2rem; font-weight: 700; color: var(--navy); font-family: var(--font-heading); }
.stat-card .stat-label { color: var(--muted); }

.admin-card { background: #fff; border: 1px solid var(--border); border-radius: var(--radius); padding: 24px; margin-bottom: 24px; box-shadow: var(--shadow-sm); }

table { width: 100%; border-collapse: collapse; }
table th, table td { text-align: left; padding: 10px 12px; border-bottom: 1px solid var(--border); vertical-align: top; }
table th { color: var(--muted); font-size: 0.85rem; text-transform: uppercase; letter-spacing: 0.02em; }
.row-actions { display: flex; gap: 8px; flex-wrap: wrap; }
.badge { display: inline-block; padding: 2px 10px; border-radius: 999px; font-size: 0.75rem; font-weight: 600; }
.badge-active { background: #e5f4ea; color: var(--success); }
.badge-inactive { background: #f1f1f1; color: var(--muted); }

.login-shell {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  background: linear-gradient(160deg, var(--navy), var(--navy-2));
  padding: 24px;
}
.login-card {
  background: #fff;
  border-radius: var(--radius);
  padding: 40px;
  width: 100%;
  max-width: 380px;
  box-shadow: var(--shadow-md);
}
.login-card h1 { margin: 0 0 24px; font-size: 1.4rem; text-align: center; }

@media (max-width: 720px) {
  .admin-shell { flex-direction: column; }
  .admin-sidebar { width: 100%; display: flex; overflow-x: auto; padding: 12px 0; }
  .admin-sidebar .brand { display: none; }
  .admin-sidebar a { padding: 10px 16px; white-space: nowrap; }
}
@media (max-width: 760px) {
  .hero-gallery {
    height: 46vh;
    min-height: 300px;
    max-height: 420px;
  }
}

@media (max-width: 480px) {
  .hero-gallery {
    height: 42vh;
    min-height: 260px;
    max-height: 360px;
  }
}