/* ============================================================
   HealthcareTwin Demo — Global Stylesheet
   Static demo (Phase 1). English-only. No build tools.
   Palette per final review: navy #0B2D4A / blue #0077B6 /
   teal #2EC4B6 / light #E6F4FB + page main blue #2563EB.
   ============================================================ */

:root {
  /* Brand */
  --navy: #0B2D4A;
  --navy-deep: #0B1E3A;
  --navy-heading: #0B2545;
  --blue: #0077B6;
  --teal: #2EC4B6;
  --teal-dark: #0E7C86;
  --light-blue: #E6F4FB;
  --primary: #2563EB;
  --primary-dark: #1D4ED8;
  --nhs: #005EB8;

  /* Text */
  --heading: #0F172A;
  --text: #475569;
  --text-muted: #64748B;
  --muted: #94A3B8;

  /* Backgrounds */
  --bg-page: #F9FAFB;
  --bg-light: #F5F8FC;
  --bg-tint: #EFF6FF;
  --bg-section: #F5F9FF;
  --white: #FFFFFF;

  /* layered hero decoration: brand glows (append base gradient after) */
  --hct-hero-net:
    radial-gradient(760px 360px at 86% 12%, rgba(46,196,182,0.16), transparent 62%),
    radial-gradient(680px 400px at 8% 88%, rgba(37,99,235,0.11), transparent 66%),
    radial-gradient(420px 260px at 55% 45%, rgba(0,119,182,0.06), transparent 70%);
  /* soft variant for white-based sub-page heroes */
  --hct-hero-soft:
    radial-gradient(640px 320px at 88% 8%, rgba(46,196,182,0.10), transparent 62%),
    radial-gradient(560px 320px at 6% 90%, rgba(37,99,235,0.07), transparent 66%);

  /* Accents (platform components & workflows) */
  --sky: #0EA5E9;
  --green: #22C55E;
  --purple: #8B5CF6;
  --orange: #F97316;
  --mint: #14B8A6;
  --sky-bg: #DBEAFE;
  --green-bg: #DCFCE7;
  --purple-bg: #EDE9FE;
  --orange-bg: #FFEDD5;
  --mint-bg: #CCFBF1;

  /* Lines */
  --border: #E2E8F0;
  --border-light: #E5EAF0;

  /* Shape */
  --r-sm: 8px;
  --r-md: 10px;
  --r-lg: 12px;
  --r-xl: 16px;
  --r-pill: 999px;

  /* Shadows */
  --shadow-sm: 0 1px 3px rgba(15, 23, 42, 0.06);
  --shadow-md: 0 4px 12px rgba(15, 23, 42, 0.08);
  --shadow-lg: 0 8px 24px rgba(15, 23, 42, 0.10);
  --shadow-xl: 0 12px 32px rgba(15, 23, 42, 0.16);
  --glow-blue: 0 2px 8px rgba(37, 99, 235, 0.15);

  /* Layout */
  --container: 1200px;
  --nav-h: 64px;
  --font: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto,
    'Helvetica Neue', Arial, sans-serif;
}

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

html { scroll-behavior: smooth; }

body {
  font-family: var(--font);
  font-size: 17.5px;
  line-height: 1.65;
  color: var(--text);
  /* 全站统一页面级背景渐变：白→浅蓝→浅青→浅蓝（贯穿整个页面文档高度） */
  background-color: #F4F9FD;
  background-image: linear-gradient(180deg, #FBFDFF 0%, #EDF4FC 22%, #E8F5F1 45%, #EDF3FC 68%, #E6F2FB 88%, #F2F7FD 100%);
  background-repeat: no-repeat;
  -webkit-font-smoothing: antialiased;
}

img { max-width: 100%; display: block; }
a { color: var(--primary); text-decoration: none; }
a:hover { color: var(--primary-dark); }
ul { list-style: none; }

/* ---------- Layout helpers ---------- */

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

.section { padding: 72px 0; }
.section-sm { padding: 48px 0; }
/* 区块不再单独铺底色，整页背景渐变贯穿显示；深色CTA横带保留自身底色 */
.section-tint { background: transparent; }
.section-tint-blue { background: transparent; }
.section-dark { background: linear-gradient(160deg, var(--navy-heading) 0%, var(--navy) 60%, #0D3860 100%); color: #C9D6E4; }

/* ---------- Typography ---------- */

h1, h2, h3, h4 { color: var(--heading); line-height: 1.25; font-weight: 700; }

.eyebrow {
  display: inline-block;
  font-size: 12.5px;
  font-weight: 700;
  letter-spacing: 1.5px;
  text-transform: uppercase;
  color: var(--primary);
  margin-bottom: 12px;
}

.eyebrow-teal { color: var(--teal-dark); }

.section-head { max-width: 720px; margin-bottom: 40px; }
.section-head.center { margin-left: auto; margin-right: auto; text-align: center; }
.section-head h2 { font-size: 37px; margin-bottom: 12px; }
.section-head p { font-size: 18.5px; color: var(--text-muted); }

.page-hero h1 { font-size: 46px; margin-bottom: 14px; }
.page-hero p.lead { font-size: 16px; max-width: 640px; }

.note-tbc {
  display: inline-block;
  font-size: 12.5px;
  font-weight: 600;
  color: var(--muted);
  background: var(--bg-light);
  border: 1px dashed var(--border);
  border-radius: var(--r-sm);
  padding: 1px 8px;
  vertical-align: middle;
  margin-left: 6px;
}

/* ---------- Buttons ---------- */

.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-family: var(--font);
  font-size: 16px;
  font-weight: 600;
  padding: 11px 22px;
  border-radius: var(--r-sm);
  border: 1px solid transparent;
  cursor: pointer;
  transition: all 0.18s ease;
  white-space: nowrap;
}

.btn-primary { background: var(--primary); color: #fff; }
.btn-primary:hover { background: var(--primary-dark); color: #fff; transform: translateY(-1px); }

.btn-ghost { background: transparent; color: var(--primary); border-color: var(--primary); }
.btn-ghost:hover { background: var(--bg-tint); }

.btn-white { background: #fff; color: var(--navy-heading); }
.btn-white:hover { color: var(--primary); transform: translateY(-1px); }

.btn-teal { background: var(--teal-dark); color: #fff; }
.btn-teal:hover { background: #0B626B; color: #fff; }

.btn-sm { padding: 8px 16px; font-size: 15px; }

.arrow-link {
  font-size: 16px;
  font-weight: 600;
  color: var(--primary);
  display: inline-flex;
  align-items: center;
  gap: 6px;
}
.arrow-link:hover { gap: 10px; }
.arrow-link::after { content: '\2192'; transition: inherit; }

/* ---------- Header / Nav ---------- */

.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  height: var(--nav-h);
  background: rgba(255, 255, 255, 0.96);
  backdrop-filter: blur(8px);
  border-bottom: 1px solid var(--border-light);
}

.nav-wrap {
  height: var(--nav-h);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
}

.logo {
  display: inline-flex;
  align-items: baseline;
  font-size: 25.5px;
  font-weight: 800;
  letter-spacing: -0.3px;
}
.logo .lg-a { color: var(--navy); }
.logo .lg-b { color: var(--teal); }
.logo .logo-img { display: block; height: 38px; width: auto; }
.footer-brand .logo .logo-img { height: 42px; }

.main-nav { display: flex; align-items: center; gap: 4px; }
.main-nav a {
  font-size: 20.5px;
  font-weight: 600;
  color: var(--text);
  padding: 8px 14px;
  border-radius: var(--r-sm);
  transition: all 0.15s ease;
}
.main-nav a:hover { color: var(--primary); background: var(--bg-tint); }
.main-nav a.active { color: var(--primary); font-weight: 600; }
.main-nav a.dropdown::after { content: ' \203E'; display: inline-block; transform: translateY(2px); font-size: 11.5px; }
.main-nav a .chev { font-size: 11.5px; margin-left: 4px; }

.nav-cta { display: flex; align-items: center; gap: 12px; }

.nav-toggle {
  display: none;
  background: none;
  border: none;
  font-size: 25.5px;
  color: var(--navy);
  cursor: pointer;
  padding: 6px;
}

/* Platform dropdown (plain CSS) */
.nav-item-has-dd { position: relative; }
.dd-menu {
  position: absolute;
  top: calc(100% + 6px);
  left: 0;
  background: #fff;
  border: 1px solid var(--border-light);
  border-radius: var(--r-lg);
  box-shadow: var(--shadow-lg);
  min-width: 260px;
  padding: 8px;
  opacity: 0;
  visibility: hidden;
  transform: translateY(6px);
  transition: all 0.18s ease;
}
.nav-item-has-dd:hover .dd-menu { opacity: 1; visibility: visible; transform: translateY(0); }
.dd-menu a {
  display: flex;
  flex-direction: column;
  gap: 2px;
  padding: 10px 12px;
  border-radius: var(--r-sm);
}
.dd-menu a:hover { background: var(--bg-tint); }
.dd-menu .dd-t { font-size: 16px; font-weight: 600; color: var(--heading); }
.dd-menu .dd-d { font-size: 14px; color: var(--muted); }

/* ---------- Footer (full-bleed navy background, per design) ---------- */

.site-footer {
  background: var(--navy-deep);
  color: #9FB2C8;
  font-size: 16px;
  padding: 56px 24px 0;
}

.footer-grid {
  display: grid;
  grid-template-columns: 1.4fr 1.3fr 1.4fr;
  gap: 40px;
  padding-bottom: 28px;
}

.footer-brand .logo { font-size: 27.5px; margin-bottom: 14px; }
.footer-brand p { font-size: 15px; line-height: 1.7; max-width: 320px; }

.footer-col h4 {
  color: #fff;
  font-size: 15px;
  font-weight: 600;
  letter-spacing: 0.8px;
  text-transform: uppercase;
  margin-bottom: 16px;
}

.footer-col ul li { margin-bottom: 10px; }
.footer-col ul a { color: #9FB2C8; font-size: 16px; }
.footer-col ul a:hover { color: #fff; }

.footer-contact li {
  display: flex;
  gap: 10px;
  margin-bottom: 12px;
  font-size: 15px;
  line-height: 1.6;
}
.footer-contact .ic { color: var(--teal); flex-shrink: 0; }

.footer-map {
  border-radius: var(--r-lg);
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.12);
  height: 150px;
  position: relative;
  /* 加载兜底/Google 不可达地区的风格化底纹 */
  background:
    repeating-linear-gradient(0deg, transparent 0 34px, rgba(46, 196, 182, 0.10) 34px 35px),
    repeating-linear-gradient(90deg, transparent 0 34px, rgba(46, 196, 182, 0.10) 34px 35px),
    linear-gradient(135deg, #10294A 0%, #0C2038 100%);
}
.footer-map iframe { display: block; width: 100%; height: 100%; border: 0; }
.footer-map-link { color: var(--teal); font-size: 13.5px; font-weight: 600; text-align: right; }
.footer-map-link:hover { color: #fff; }

.map-col { display: flex; flex-direction: column; gap: 10px; }
.map-col .footer-map { flex: 1; }

.footer-social {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 24px 0 18px;
}
.fs-circle {
  width: 34px; height: 34px; border-radius: 50%;
  border: 1px solid rgba(255, 255, 255, 0.22);
  color: #9FB2C8; background: transparent;
  display: flex; align-items: center; justify-content: center;
  font-size: 14px; font-weight: 700; cursor: default;
}
.footer-social .footer-nav { order: -1; margin-right: auto; display: flex; flex-wrap: wrap; gap: 8px 24px; justify-content: flex-start; }
.footer-social .footer-nav a { color: #C7D5E5; font-size: 15px; font-weight: 500; white-space: nowrap; }
.footer-social .footer-nav a:hover { color: #fff; }

.footer-bottom {
  padding: 0 0 20px;
  display: flex;
  justify-content: center;
  font-size: 14.5px;
  color: #7E93AB;
}

/* ---------- Cards ---------- */

.card {
  background: #fff;
  border: 1px solid var(--border-light);
  border-radius: var(--r-lg);
  padding: 28px;
  transition: all 0.2s ease;
}
.card:hover { transform: translateY(-4px); box-shadow: var(--shadow-lg); border-color: var(--sky-bg); }

.card .icon-chip {
  width: 48px;
  height: 48px;
  border-radius: var(--r-md);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 25.5px;
  margin-bottom: 16px;
}
.card h3 { font-size: 19.5px; margin-bottom: 8px; }
.card p { font-size: 16px; color: var(--text-muted); }
.card .learn { margin-top: 16px; display: inline-flex; }

.grid-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px; }
.grid-4 { display: grid; grid-template-columns: repeat(4, 1fr); gap: 24px; }
.grid-2 { display: grid; grid-template-columns: repeat(2, 1fr); gap: 32px; }

/* Small feature card (Key Features grids) */
.feat-card { padding: 22px; }
.feat-card h3 { font-size: 16.5px; display: flex; align-items: center; gap: 10px; }
.feat-card .icon-chip { width: 40px; height: 40px; font-size: 20.5px; margin: 0; border-radius: var(--r-sm); }

/* Sub-page hero (Platform children / other inner pages) */
.sub-hero { background: transparent; padding: 48px 0 40px; }
.sub-hero h1 { font-size: 41.5px; }
.sub-hero .lead { font-size: 16px; color: var(--text-muted); max-width: 620px; }

/* ---------- Pills / Tabs ---------- */

.pill-row { display: flex; flex-wrap: wrap; gap: 10px; }

.pill {
  font-size: 15px;
  font-weight: 500;
  color: var(--text);
  background: #fff;
  border: 1px solid var(--border);
  border-radius: var(--r-pill);
  padding: 8px 16px;
  cursor: pointer;
  transition: all 0.15s ease;
}
.pill:hover { border-color: var(--primary); color: var(--primary); }
.pill.active { background: var(--primary); border-color: var(--primary); color: #fff; }

/* Use-case tabs */
.tabs-bar {
  display: flex;
  gap: 8px;
  background: #fff;
  border: 1px solid var(--border-light);
  border-radius: var(--r-lg);
  padding: 8px;
  margin-bottom: 40px;
  overflow-x: auto;
}
.tab-btn {
  flex: 1;
  min-width: 140px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  font-family: var(--font);
  font-size: 16px;
  font-weight: 500;
  color: var(--text);
  background: transparent;
  border: 1px solid transparent;
  border-radius: var(--r-md);
  padding: 12px 16px;
  cursor: pointer;
  transition: all 0.15s ease;
}
.tab-btn:hover { color: var(--primary); }
.tab-btn.active {
  background: #fff;
  border-color: var(--primary);
  color: var(--primary);
  font-weight: 600;
  box-shadow: var(--glow-blue);
}
.tab-panel { display: none; }
.tab-panel.active { display: block; animation: fadeIn 0.25s ease; }

@keyframes fadeIn { from { opacity: 0; transform: translateY(6px); } to { opacity: 1; transform: none; } }

/* ---------- Metrics ---------- */

.metric-card {
  background: #fff;
  border: 1px solid var(--border-light);
  border-radius: var(--r-lg);
  padding: 24px;
  text-align: center;
}
.metric-card .m-icon {
  width: 48px;
  height: 48px;
  margin: 0 auto 12px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 23px;
}
.metric-card .m-val { font-size: 34.5px; font-weight: 800; color: var(--navy-heading); line-height: 1.1; }
.metric-card .m-val .delta { font-size: 18.5px; vertical-align: top; }
.metric-card .m-label { font-size: 15px; color: var(--text-muted); margin-top: 6px; }

/* ---------- Forms ---------- */

.form-card {
  background: #fff;
  border: 1px solid var(--border-light);
  border-radius: var(--r-xl);
  box-shadow: var(--shadow-md);
  padding: 40px;
}

.form-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; }
.form-field { display: flex; flex-direction: column; gap: 6px; }
.form-field.full { grid-column: 1 / -1; }
.form-field label { font-size: 15px; font-weight: 600; color: var(--heading); }
.form-field label .req { color: #DC2626; }
.form-field input,
.form-field select,
.form-field textarea {
  font-family: var(--font);
  font-size: 16px;
  color: var(--heading);
  background: #fff;
  border: 1px solid var(--border);
  border-radius: var(--r-sm);
  padding: 11px 14px;
  transition: border-color 0.15s ease, box-shadow 0.15s ease;
}
.form-field textarea { min-height: 130px; resize: vertical; }
.form-field input:focus,
.form-field select:focus,
.form-field textarea:focus {
  outline: none;
  border-color: var(--primary);
  box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.12);
}
.form-field input::placeholder, .form-field textarea::placeholder { color: var(--muted); }

.form-note { font-size: 14px; color: var(--muted); line-height: 1.6; }
.form-actions { display: flex; align-items: center; gap: 16px; margin-top: 8px; }

.form-success {
  display: none;
  background: #F0FDF4;
  border: 1px solid #BBF7D0;
  color: #15803D;
  border-radius: var(--r-sm);
  padding: 14px 18px;
  font-size: 16px;
  margin-bottom: 18px;
}
.form-success.show { display: block; }

/* ---------- Placeholders (photo slots) ---------- */

.ph {
  background:
    repeating-linear-gradient(45deg, transparent 0 12px, rgba(37, 99, 235, 0.04) 12px 24px),
    linear-gradient(135deg, #DBEAFE 0%, #E6F4FB 60%, #D5F3EF 100%);
  border-radius: var(--r-xl);
  border: 1px dashed #A8C6E8;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  color: #6B8DB5;
  font-size: 14.5px;
  font-weight: 600;
  letter-spacing: 0.5px;
  text-transform: uppercase;
  text-align: center;
  padding: 20px;
}
.ph .ph-ic { font-size: 32px; margin-bottom: 8px; opacity: 0.7; }

.ph-dark {
  background:
    repeating-linear-gradient(45deg, transparent 0 12px, rgba(255, 255, 255, 0.04) 12px 24px),
    linear-gradient(135deg, #10304F 0%, #0B1E3A 100%);
  border-color: #24476B;
  color: #7E9CBF;
}

.ph.tall { min-height: 320px; }
.ph.wide { min-height: 220px; }
.ph.small { min-height: 140px; border-radius: var(--r-md); }

/* ---------- Breadcrumb ---------- */

.breadcrumb {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 15px;
  color: var(--muted);
  margin-bottom: 18px;
}
.breadcrumb a { color: var(--text-muted); }
.breadcrumb a:hover { color: var(--primary); }
.breadcrumb .sep { color: var(--border); }

/* ---------- Utility ---------- */

.text-center { text-align: center; }
.mt-16 { margin-top: 16px; }
.mt-24 { margin-top: 24px; }
.mt-40 { margin-top: 40px; }
.mb-24 { margin-bottom: 24px; }
.mb-40 { margin-bottom: 40px; }

.badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 12.5px;
  font-weight: 700;
  letter-spacing: 0.8px;
  text-transform: uppercase;
  border-radius: var(--r-pill);
  padding: 4px 12px;
}
.badge-blue { background: var(--sky-bg); color: var(--primary); }
.badge-green { background: var(--green-bg); color: #16A34A; }
.badge-purple { background: var(--purple-bg); color: #7C3AED; }
.badge-orange { background: var(--orange-bg); color: #EA580C; }
.badge-mint { background: var(--mint-bg); color: #0D9488; }
.badge-navy { background: var(--light-blue); color: var(--navy); }

/* ---------- Responsive ---------- */

@media (max-width: 1024px) {
  .grid-4 { grid-template-columns: repeat(2, 1fr); }
  .grid-3 { grid-template-columns: repeat(2, 1fr); }
  .footer-grid { grid-template-columns: 1fr 1fr; }
}

@media (max-width: 768px) {
  .section { padding: 48px 0; }
  .site-footer { padding: 40px 16px 0; }
  .page-hero h1 { font-size: 34.5px; }
  .section-head h2 { font-size: 30px; }
  .grid-2, .grid-3 { grid-template-columns: 1fr; }
  .grid-4 { grid-template-columns: repeat(2, 1fr); }
  .form-grid { grid-template-columns: 1fr; }
  .footer-grid { grid-template-columns: 1fr; gap: 32px; }
  .footer-social { flex-wrap: wrap; row-gap: 14px; }
  .footer-social .footer-nav { width: 100%; gap: 8px 18px; }
  .footer-social .footer-nav a { font-size: 14px; }

  .nav-toggle { display: block; }
  .main-nav {
    display: none;
    position: absolute;
    top: var(--nav-h);
    left: 0;
    right: 0;
    background: #fff;
    border-bottom: 1px solid var(--border-light);
    box-shadow: var(--shadow-lg);
    flex-direction: column;
    align-items: stretch;
    padding: 12px 20px 20px;
    gap: 2px;
  }
  .main-nav.open { display: flex; }
  .main-nav a { padding: 12px 10px; }
  .dd-menu {
    position: static;
    opacity: 1;
    visibility: visible;
    transform: none;
    box-shadow: none;
    border: none;
    padding: 0 0 0 16px;
  }
  .nav-cta .btn { display: none; }
  .nav-cta .btn.btn-mobile-show { display: inline-flex; }
}

@media (max-width: 480px) {
  .grid-4 { grid-template-columns: 1fr; }
  .footer-social .footer-nav { gap: 8px 14px; }
}
