/* MediFast landing page. Colours come from the logo (deep blue, light blue,
   red) and match the web app and console. */
:root {
  --brand-50: #eef6fd;
  --brand-100: #d5e9f8;
  --brand-500: #1e8acc;
  --brand-600: #0a62bd;
  --brand-700: #0451a8;
  --brand-800: #03428a;
  --brand-900: #06306a;
  --red-50: #fdf1f1;
  --red-600: #c41f26;
  --red-700: #a3191f;
  --ink: #0f172a;
  --body: #334155;
  --muted: #64748b;
  --line: #e2e8f0;
  --tint: #f8fafc;
  --radius: 14px;
  --shadow: 0 1px 2px rgb(15 23 42 / 0.06), 0 8px 24px rgb(15 23 42 / 0.06);
  font-family: 'Inter', ui-sans-serif, system-ui, -apple-system, 'Segoe UI', Roboto, sans-serif;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

[hidden] {
  display: none !important;
}

html {
  scroll-behavior: smooth;
  scroll-padding-top: 80px;
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }
  *,
  *::before,
  *::after {
    animation: none !important;
    transition: none !important;
  }
}

body {
  margin: 0;
  background: #fff;
  color: var(--body);
  font-size: 16px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

h1,
h2,
h3 {
  color: var(--ink);
  line-height: 1.2;
  margin: 0;
  letter-spacing: -0.015em;
}

p {
  margin: 0;
}

a {
  color: var(--brand-700);
}

img,
svg {
  display: block;
}

.container {
  width: 100%;
  max-width: 1120px;
  margin: 0 auto;
  padding: 0 20px;
}

.skip-link {
  position: absolute;
  left: -9999px;
  top: 8px;
  z-index: 100;
  background: var(--ink);
  color: #fff;
  padding: 8px 12px;
  border-radius: 8px;
}
.skip-link:focus {
  left: 8px;
}

:focus-visible {
  outline: 3px solid var(--brand-600);
  outline-offset: 2px;
}

/* Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 12px 20px;
  border-radius: 10px;
  font-weight: 600;
  font-size: 15px;
  text-decoration: none;
  white-space: nowrap;
  transition:
    background-color 0.15s,
    box-shadow 0.15s,
    transform 0.15s;
}
.btn:active {
  transform: translateY(1px);
}
.btn svg {
  width: 20px;
  height: 20px;
  fill: none;
  stroke: currentColor;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
}
.btn-sm {
  padding: 8px 14px;
  font-size: 14px;
}
.btn-primary {
  background: var(--brand-700);
  color: #fff;
}
.btn-primary:hover {
  background: var(--brand-800);
}
.btn-secondary {
  background: #fff;
  color: var(--ink);
  box-shadow: inset 0 0 0 1px var(--line);
}
.btn-secondary:hover {
  background: var(--tint);
}
.btn-sos {
  background: var(--red-600);
  color: #fff;
  box-shadow: 0 6px 20px rgb(196 31 38 / 0.3);
}
.btn-sos:hover {
  background: var(--red-700);
}
.btn-light {
  background: #fff;
  color: var(--brand-900);
}
.btn-light:hover {
  background: var(--brand-50);
}

/* Header */
.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgb(255 255 255 / 0.9);
  backdrop-filter: saturate(180%) blur(10px);
  border-bottom: 1px solid var(--line);
}
.header-inner {
  display: flex;
  align-items: center;
  gap: 24px;
  height: 64px;
}
.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  color: var(--ink);
  font-weight: 700;
  font-size: 18px;
  text-decoration: none;
}
/* Wordmark like the logo's: MEDI in blue, FAST in red. */
.wordmark {
  font-style: italic;
  font-weight: 800;
  letter-spacing: -0.02em;
}
.wordmark .medi {
  color: var(--brand-700);
}
.wordmark .fast {
  color: var(--red-600);
}

.nav {
  display: flex;
  gap: 4px;
  margin-left: auto;
}
.nav a {
  padding: 6px 12px;
  border-radius: 8px;
  color: var(--body);
  font-size: 15px;
  font-weight: 500;
  text-decoration: none;
}
.nav a:hover {
  background: var(--tint);
  color: var(--ink);
}

/* Hero */
.hero {
  background:
    radial-gradient(900px 400px at 85% 10%, var(--brand-50), transparent 70%),
    radial-gradient(600px 300px at 0% 100%, var(--red-50), transparent 70%);
  padding: 72px 0 80px;
}
.hero-inner {
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  gap: 56px;
  align-items: center;
}
.eyebrow {
  display: inline-block;
  margin-bottom: 16px;
  padding: 4px 12px;
  border-radius: 999px;
  background: var(--brand-100);
  color: var(--brand-800);
  font-size: 13px;
  font-weight: 600;
}
.hero h1 {
  font-size: clamp(34px, 5vw, 54px);
  letter-spacing: -0.03em;
}
.lead {
  margin-top: 20px;
  font-size: 18px;
  max-width: 34em;
}
.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 32px;
}
.hero-note {
  margin-top: 16px;
  color: var(--muted);
  font-size: 14px;
}

.preview-card {
  max-width: 380px;
  margin-left: auto;
  background: #fff;
  border-radius: 20px;
  box-shadow: 0 24px 60px rgb(15 23 42 / 0.14);
  padding: 18px;
  border: 1px solid var(--line);
}
.preview-status {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 12px 14px;
  border-radius: 12px;
  background: var(--brand-50);
}
.preview-title {
  color: var(--brand-900);
  font-weight: 700;
}
.preview-sub {
  color: var(--brand-800);
  font-size: 13px;
}
.pulse {
  position: relative;
  flex: none;
  width: 14px;
  height: 14px;
  border-radius: 999px;
  background: var(--brand-600);
}
.pulse::after {
  content: '';
  position: absolute;
  inset: -6px;
  border-radius: 999px;
  border: 2px solid var(--brand-600);
  animation: pulse 1.8s ease-out infinite;
}
@keyframes pulse {
  from {
    opacity: 0.8;
    transform: scale(0.6);
  }
  to {
    opacity: 0;
    transform: scale(1.6);
  }
}
.preview-map {
  margin-top: 14px;
  border-radius: 12px;
  overflow: hidden;
}
.preview-map svg {
  width: 100%;
  height: auto;
}
.preview-steps {
  list-style: none;
  margin: 14px 0 0;
  padding: 0;
  display: grid;
  gap: 8px;
}
.preview-steps li {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 14px;
  color: var(--muted);
}
.preview-steps li::before {
  content: '';
  width: 16px;
  height: 16px;
  border-radius: 999px;
  border: 2px solid #cbd5e1;
}
.preview-steps li.done {
  color: var(--ink);
  font-weight: 600;
}
.preview-steps li.done::before {
  border-color: var(--brand-700);
  background: var(--brand-700)
    url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='white' stroke-width='3.5' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M20 6 9 17l-5-5'/%3E%3C/svg%3E")
    center / 10px no-repeat;
}

/* Sections */
.section {
  padding: 88px 0;
}
.section-tint {
  background: var(--tint);
  border-block: 1px solid var(--line);
}
.section-head {
  max-width: 640px;
  margin-bottom: 40px;
}
.section-head h2 {
  font-size: clamp(26px, 3.4vw, 36px);
}
.section-head p {
  margin-top: 10px;
  font-size: 17px;
  color: var(--muted);
}

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

.card {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 24px;
  box-shadow: var(--shadow);
}
.card h3 {
  margin-top: 16px;
  font-size: 18px;
}
.card p {
  margin-top: 8px;
  font-size: 15px;
}
.card-feature {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
}
.card-feature .btn,
.card-feature .store-links {
  margin-top: 20px;
}
.store-links {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  border-radius: 12px;
  background: var(--brand-50);
  color: var(--brand-700);
}
.icon svg {
  width: 22px;
  height: 22px;
  fill: none;
  stroke: currentColor;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
}
.icon-red {
  background: var(--red-50);
  color: var(--red-600);
}

.steps {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
  counter-reset: step;
}
.steps li {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 24px;
}
.step-num {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 32px;
  height: 32px;
  border-radius: 999px;
  background: var(--brand-700);
  color: #fff;
  font-weight: 700;
  font-size: 15px;
}
.steps h3 {
  margin-top: 14px;
  font-size: 18px;
}
.steps p {
  margin-top: 6px;
  font-size: 15px;
}

.callout {
  margin-top: 28px;
  padding: 14px 18px;
  border-radius: 12px;
  background: var(--red-50);
  color: var(--red-700);
  font-size: 15px;
}
.callout a {
  color: inherit;
  font-weight: 700;
}

.section-dark {
  background: linear-gradient(135deg, var(--brand-900), var(--brand-700));
  color: var(--brand-100);
}
.section-dark h2 {
  color: #fff;
  font-size: clamp(24px, 3vw, 32px);
}
.partners {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 32px;
}
.partners p {
  margin-top: 12px;
  max-width: 40em;
}
.muted-light a {
  color: #fff;
}

.contact-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 8px;
  font-size: 17px;
}

.muted {
  color: var(--muted);
  font-size: 14px;
}

/* Footer */
.site-footer {
  border-top: 1px solid var(--line);
  padding: 32px 0;
}
.footer-inner {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 16px 32px;
}
.footer-nav {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 20px;
  margin-right: auto;
}
.footer-nav a {
  color: var(--body);
  font-size: 14px;
  text-decoration: none;
}
.footer-nav a:hover {
  color: var(--ink);
  text-decoration: underline;
}

/* 404 */
.not-found {
  min-height: 60vh;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  justify-content: center;
  gap: 16px;
  padding: 80px 0;
}

/* Responsive */
@media (max-width: 960px) {
  .grid-4 {
    grid-template-columns: repeat(2, 1fr);
  }
  .hero-inner {
    grid-template-columns: 1fr;
    gap: 40px;
  }
  .preview-card {
    margin: 0 auto;
  }
}

@media (max-width: 760px) {
  .nav {
    display: none;
  }
  .header-inner {
    justify-content: space-between;
  }
  .hero {
    padding: 48px 0 56px;
  }
  .section {
    padding: 64px 0;
  }
  .grid-2,
  .steps {
    grid-template-columns: 1fr;
  }
  .partners {
    flex-direction: column;
    align-items: flex-start;
  }
}

@media (max-width: 520px) {
  .container {
    padding: 0 16px;
  }
  .grid-4 {
    grid-template-columns: 1fr;
  }
  .hero-actions .btn {
    flex: 1 1 100%;
  }
}
