/* MiCal Landing Page Styles */
/* Brand colors defined in BRANDING.md */

@font-face {
  font-family: "Inter Variable";
  font-style: normal;
  font-weight: 100 900;
  font-display: swap;
  src: url("/fonts/InterVariable.woff2") format("woff2");
}
@font-face {
  font-family: "Inter Variable";
  font-style: italic;
  font-weight: 100 900;
  font-display: swap;
  src: url("/fonts/InterVariable-Italic.woff2") format("woff2");
}

:root {
  --flow-teal: #00c2a8;
  --teal-dark: #009e88;
  --ink-blue: #0f4c81;
  --bridge-blue: var(--ink-blue); /* legacy alias */
  --blue-dark: #0a3a63; /* still used by the .cta-section gradient */
  --cloud: #f5f7fa;
  --surface-1: #fafbfc;
  --charcoal: #1a202c;
  --stone: #718096;
  --white: #ffffff;
}

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

html {
  scroll-behavior: smooth;
}

body {
  font-family:
    "Inter Variable", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto,
    "Helvetica Neue", Arial, sans-serif;
  font-feature-settings:
    "cv11",
    "ss01",
    "cv02";
  font-variant-numeric: tabular-nums;
  color: var(--charcoal);
  line-height: 1.55;
  background: var(--white);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 24px;
}

/* Navigation */
nav {
  background: var(--white);
  border-bottom: 1px solid rgba(0, 0, 0, 0.06);
  position: sticky;
  top: 0;
  z-index: 100;
}

.nav-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 64px;
}

.logo {
  font-size: 1.5rem;
  font-weight: 650;
  color: var(--charcoal);
  text-decoration: none;
  letter-spacing: -0.02em;
}

.logo span {
  color: inherit;
}

.nav-links {
  display: flex;
  gap: 32px;
  align-items: center;
}

.nav-toggle {
  display: none;
  background: none;
  border: none;
  color: var(--charcoal);
  cursor: pointer;
  padding: 8px;
  border-radius: 6px;
}

.nav-toggle:hover {
  background: rgba(0, 0, 0, 0.04);
}

.nav-links a {
  text-decoration: none;
  color: var(--stone);
  font-size: 0.95rem;
  font-weight: 500;
  transition: color 0.2s;
}

.nav-links a:hover {
  color: var(--charcoal);
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 12px 24px;
  border-radius: 8px;
  font-size: 0.95rem;
  font-weight: 600;
  text-decoration: none;
  transition: all 0.2s;
  cursor: pointer;
  border: none;
}

.btn-primary {
  background: var(--flow-teal);
  color: var(--white);
}

.btn-primary:hover {
  background: var(--teal-dark);
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(0, 194, 168, 0.3);
}

.btn-secondary {
  background: transparent;
  color: var(--bridge-blue);
  border: 1px solid var(--bridge-blue);
}

.btn-secondary:hover {
  background: var(--bridge-blue);
  color: var(--white);
}

.btn-large {
  padding: 14px 32px;
  font-size: 1.05rem;
}

/* Hero */
.hero {
  background: linear-gradient(180deg, var(--cloud) 0%, var(--white) 100%);
  padding: 100px 0 80px;
  text-align: center;
}

.hero h1 {
  font-size: clamp(2.5rem, 5vw, 4rem);
  font-weight: 650;
  line-height: 1.1;
  letter-spacing: -0.03em;
  margin-bottom: 24px;
  max-width: 800px;
  margin-left: auto;
  margin-right: auto;
}

.hero h1 em {
  color: var(--bridge-blue);
  font-style: normal;
}

.hero-sub {
  font-size: clamp(1.1rem, 2vw, 1.35rem);
  color: var(--stone);
  max-width: 600px;
  margin: 0 auto 40px;
  line-height: 1.5;
}

.hero-ctas {
  display: flex;
  gap: 16px;
  justify-content: center;
  flex-wrap: wrap;
}

.hero-note {
  margin-top: 20px;
  font-size: 0.85rem;
  color: var(--stone);
}

.hero-link {
  margin-left: 12px;
  color: var(--bridge-blue);
  text-decoration: none;
  font-weight: 600;
  border-bottom: 1px solid rgba(15, 76, 129, 0.2);
}

.hero-link:hover {
  border-bottom-color: var(--bridge-blue);
}

/* Section spacing */
.section {
  padding: 80px 0;
}

.section-title {
  font-size: clamp(1.8rem, 3vw, 2.5rem);
  font-weight: 700;
  text-align: center;
  margin-bottom: 16px;
  letter-spacing: -0.02em;
}

.section-subtitle {
  text-align: center;
  color: var(--stone);
  font-size: 1.1rem;
  max-width: 600px;
  margin: 0 auto 60px;
}

/* Problem */
.problem {
  background: var(--white);
}

.problem-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 24px;
  max-width: 900px;
  margin: 0 auto;
}

.problem-card {
  background: var(--cloud);
  padding: 32px;
  border-radius: 12px;
  text-align: center;
}

.problem-card .icon {
  margin-bottom: 16px;
  color: var(--bridge-blue);
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.problem-card .icon svg {
  width: 36px;
  height: 36px;
}

.problem-card h3 {
  font-size: 1.1rem;
  font-weight: 600;
  margin-bottom: 8px;
}

.problem-card p {
  color: var(--stone);
  font-size: 0.95rem;
}

/* Features */
.features {
  background: var(--cloud);
}

.features-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 24px;
}

.feature-card {
  background: var(--white);
  padding: 40px 32px;
  border-radius: 12px;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.04);
  transition:
    transform 0.2s,
    box-shadow 0.2s;
}

.feature-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 12px 24px rgba(0, 0, 0, 0.06);
}

.feature-card .icon {
  margin-bottom: 20px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 12px;
  background: var(--cloud);
  border-radius: 12px;
  color: var(--flow-teal);
}

.feature-card .icon svg {
  width: 32px;
  height: 32px;
}

.feature-card h3 {
  font-size: 1.2rem;
  font-weight: 700;
  margin-bottom: 12px;
}

.feature-card p {
  color: var(--stone);
  font-size: 0.95rem;
  line-height: 1.6;
}

/* Families & Teams */
.families {
  background: var(--white);
}

.scenario-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(360px, 1fr));
  gap: 32px;
  max-width: 1080px;
  margin: 0 auto;
}

.scenario-card {
  background: var(--cloud);
  border-radius: 16px;
  padding: 40px 36px;
  border: 1px solid rgba(0, 0, 0, 0.04);
  position: relative;
}

.scenario-family {
  border-top: 4px solid var(--bridge-blue);
}

.scenario-team {
  border-top: 4px solid var(--flow-teal);
}

.scenario-tag {
  display: inline-block;
  font-size: 0.75rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--stone);
  margin-bottom: 12px;
}

.scenario-card h3 {
  font-size: 1.45rem;
  font-weight: 700;
  letter-spacing: -0.01em;
  margin-bottom: 16px;
  color: var(--charcoal);
}

.scenario-lead {
  color: var(--stone);
  font-size: 1rem;
  line-height: 1.55;
  margin-bottom: 16px;
  font-style: italic;
}

.scenario-card p {
  color: var(--charcoal);
  font-size: 0.98rem;
  line-height: 1.55;
  margin-bottom: 20px;
}

.scenario-bullets {
  list-style: none;
  padding: 0;
  margin: 0;
}

.scenario-bullets li {
  color: var(--charcoal);
  font-size: 0.95rem;
  line-height: 1.5;
  padding: 6px 0 6px 24px;
  position: relative;
}

.scenario-bullets li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 14px;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--flow-teal);
}

.scenario-family .scenario-bullets li::before {
  background: var(--bridge-blue);
}

.scenario-footer {
  text-align: center;
  margin-top: 32px;
  color: var(--stone);
  font-size: 0.95rem;
  max-width: 640px;
  margin-left: auto;
  margin-right: auto;
}

/* Comparison table */
.comparison {
  background: var(--white);
}

.comparison-wrap {
  overflow-x: auto;
  border-radius: 12px;
  border: 1px solid rgba(0, 0, 0, 0.06);
  background: var(--white);
  margin: 0 auto;
  max-width: 960px;
}

.comparison-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.95rem;
}

.comparison-table th,
.comparison-table td {
  padding: 12px 10px;
  text-align: center;
  border-bottom: 1px solid rgba(0, 0, 0, 0.04);
  font-size: 0.9rem;
}

.comparison-table tbody th[scope="row"] {
  font-size: 0.92rem;
  padding: 12px 16px;
  min-width: 220px;
}

.comparison-table thead th {
  font-size: 0.85rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: var(--stone);
  background: var(--cloud);
  border-bottom: 1px solid rgba(0, 0, 0, 0.08);
}

.comparison-table thead th.us {
  color: var(--bridge-blue);
  background: rgba(0, 194, 168, 0.08);
}

.comparison-table tbody th {
  text-align: left;
  font-weight: 500;
  color: var(--charcoal);
  background: var(--white);
}

.comparison-table tbody td {
  font-weight: 600;
  color: var(--stone);
}

.comparison-table tbody td.us {
  background: rgba(0, 194, 168, 0.04);
  color: var(--bridge-blue);
}

.comparison-table .yes {
  color: var(--success);
}

.comparison-table .partial {
  color: var(--warning);
}

.comparison-table .no {
  color: var(--stone);
  opacity: 0.5;
}

.comparison-table tbody tr:last-child th,
.comparison-table tbody tr:last-child td {
  border-bottom: none;
}

.comparison-footer {
  text-align: center;
  margin: 32px auto 0;
  color: var(--stone);
  font-size: 0.95rem;
  max-width: 760px;
  line-height: 1.6;
}

.comparison-footer strong {
  color: var(--charcoal);
}

.comparison-aside {
  display: block;
  margin-top: 16px;
  font-size: 0.85rem;
  color: var(--stone);
  font-style: italic;
}

/* Pricing */
.pricing {
  background: var(--cloud);
}

.pricing-beta-pill {
  display: inline-block;
  margin-left: 8px;
  background: rgba(0, 194, 168, 0.12);
  color: var(--bridge-blue);
  font-size: 0.78rem;
  font-weight: 700;
  padding: 4px 12px;
  border-radius: 999px;
  letter-spacing: 0.02em;
  vertical-align: middle;
}

.pricing-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 20px;
  max-width: 1100px;
  margin: 0 auto;
}

.price-card {
  position: relative;
  background: var(--white);
  border: 1px solid rgba(0, 0, 0, 0.06);
  border-radius: 14px;
  padding: 28px 24px;
  display: flex;
  flex-direction: column;
}

.price-card-featured {
  border: 2px solid var(--flow-teal);
  box-shadow: 0 8px 24px rgba(0, 194, 168, 0.12);
  transform: translateY(-4px);
}

.price-badge {
  position: absolute;
  top: -12px;
  left: 50%;
  transform: translateX(-50%);
  background: var(--flow-teal);
  color: var(--white);
  font-size: 0.72rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  padding: 4px 12px;
  border-radius: 999px;
}

.price-tier {
  font-size: 0.85rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--stone);
  margin-bottom: 8px;
}

.price-amount {
  font-size: 2.6rem;
  font-weight: 650;
  line-height: 1;
  color: var(--charcoal);
  letter-spacing: -0.02em;
}

.price-currency {
  font-size: 1.4rem;
  vertical-align: top;
  margin-right: 2px;
  color: var(--stone);
}

.price-period {
  font-size: 0.85rem;
  color: var(--stone);
  margin-top: 6px;
  min-height: 1.2em;
}

.price-monthly {
  font-size: 0.78rem;
  color: var(--stone);
  margin-top: 2px;
  min-height: 1.1em;
}

.price-features {
  list-style: none;
  padding: 0;
  margin: 20px 0 24px;
  flex: 1;
}

.price-features li {
  font-size: 0.9rem;
  color: var(--charcoal);
  padding: 8px 0 8px 24px;
  position: relative;
  line-height: 1.4;
  border-bottom: 1px solid rgba(0, 0, 0, 0.04);
}

.price-features li:last-child {
  border-bottom: none;
}

.price-features li::before {
  content: "";
  position: absolute;
  left: 4px;
  top: 14px;
  width: 8px;
  height: 4px;
  border-left: 2px solid var(--flow-teal);
  border-bottom: 2px solid var(--flow-teal);
  transform: rotate(-45deg);
}

.btn-block {
  width: 100%;
  display: block;
  text-align: center;
}

.pricing-footer {
  text-align: center;
  margin: 32px auto 0;
  color: var(--stone);
  font-size: 0.9rem;
  max-width: 640px;
  line-height: 1.6;
}

/* Mobile: comparison table → stacked cards. The 7-column matrix is
   unreadable on phones; transpose into one block per competitor with
   our row marked as the win. */
@media (max-width: 720px) {
  .comparison-table {
    display: block;
  }
  .comparison-table thead {
    display: none;
  }
  .comparison-table tbody,
  .comparison-table tr {
    display: block;
  }
  .comparison-table tbody tr {
    border-bottom: 1px solid rgba(0, 0, 0, 0.06);
    padding: 12px 0;
  }
  .comparison-table tbody th[scope="row"] {
    display: block;
    padding: 8px 16px;
    font-size: 0.95rem;
    font-weight: 700;
    color: var(--charcoal);
    background: var(--cloud);
    min-width: 0;
    text-align: left;
  }
  .comparison-table tbody td {
    display: flex;
    justify-content: space-between;
    padding: 6px 16px;
    border: none;
    text-align: right;
    font-size: 0.85rem;
  }
  .comparison-table tbody td::before {
    content: attr(data-col);
    font-weight: 600;
    color: var(--stone);
    text-transform: uppercase;
    letter-spacing: 0.04em;
    font-size: 0.75rem;
  }
  .comparison-table tbody td.us {
    background: rgba(0, 194, 168, 0.06);
    border-radius: 6px;
    margin: 4px 8px;
    padding-left: 12px;
    padding-right: 12px;
  }
}

/* Featured card lift only makes sense on multi-column desktop. */
@media (max-width: 540px) {
  .price-card-featured {
    transform: none;
  }
}

/* How it works */
.how-it-works {
  background: var(--cloud);
}

.steps {
  display: flex;
  flex-direction: column;
  gap: 40px;
  max-width: 800px;
  margin: 0 auto;
}

.step {
  display: flex;
  gap: 32px;
  align-items: flex-start;
}

.step-number {
  flex-shrink: 0;
  width: 56px;
  height: 56px;
  background: var(--bridge-blue);
  color: var(--white);
  border-radius: 16px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.5rem;
  font-weight: 650;
}

.step-content h3 {
  font-size: 1.25rem;
  font-weight: 700;
  margin-bottom: 8px;
}

.step-content p {
  color: var(--stone);
  font-size: 1rem;
}

/* CTA Section */
.cta-section {
  background: linear-gradient(
    135deg,
    var(--bridge-blue) 0%,
    var(--blue-dark) 100%
  );
  color: var(--white);
  text-align: center;
  padding: 100px 0;
}

.cta-section h2 {
  font-size: clamp(2rem, 4vw, 3rem);
  font-weight: 650;
  margin-bottom: 20px;
  letter-spacing: -0.02em;
}

.cta-section p {
  font-size: 1.2rem;
  opacity: 0.85;
  max-width: 500px;
  margin: 0 auto 40px;
}

.cta-section .btn-primary {
  background: var(--flow-teal);
  color: var(--white);
  font-size: 1.1rem;
  padding: 16px 40px;
}

.cta-section .btn-primary:hover {
  background: var(--teal-dark);
}

/* Footer */
footer {
  background: var(--charcoal);
  color: rgba(255, 255, 255, 0.6);
  padding: 48px 0;
  text-align: center;
  font-size: 0.9rem;
}

footer a {
  color: rgba(255, 255, 255, 0.8);
  text-decoration: none;
}

footer a:hover {
  color: var(--white);
}

/* Mobile */
@media (max-width: 640px) {
  .nav-toggle {
    display: inline-flex;
    align-items: center;
    justify-content: center;
  }

  .nav-links {
    display: none;
    position: absolute;
    top: 64px;
    right: 0;
    left: 0;
    background: var(--white);
    border-bottom: 1px solid rgba(0, 0, 0, 0.06);
    flex-direction: column;
    gap: 0;
    padding: 8px 0;
    box-shadow: 0 8px 16px rgba(0, 0, 0, 0.04);
  }

  .nav-links.open {
    display: flex;
  }

  .nav-links a {
    padding: 12px 24px;
    width: 100%;
  }

  .nav-links a.btn {
    margin: 8px 24px;
    width: calc(100% - 48px);
    text-align: center;
  }

  .hero {
    padding: 60px 0 50px;
  }

  .step {
    flex-direction: column;
    align-items: center;
    text-align: center;
  }

  .section {
    padding: 60px 0;
  }
}
