:root {
  color-scheme: light;
  --bg: #f4f1ea;
  --surface: #ffffff;
  --surface-strong: #111827;
  --text: #172033;
  --muted: #647084;
  --line: #d9dfeb;
  --accent: #0f766e;
  --accent-dark: #134e4a;
  --coral: #ef6f5e;
  --gold: #f6b84b;
  --shadow: 0 20px 55px rgba(31, 41, 55, 0.12);
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  min-height: 100vh;
  font-family: Inter, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  background:
    linear-gradient(135deg, rgba(15, 118, 110, 0.11), transparent 34%),
    linear-gradient(315deg, rgba(239, 111, 94, 0.13), transparent 36%),
    var(--bg);
  color: var(--text);
}

button {
  font: inherit;
}

.pricing-shell {
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto;
  padding: 54px 0;
}

.pricing-header {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: end;
  gap: 28px;
  margin-bottom: 28px;
}

.eyebrow {
  margin: 0 0 10px;
  color: var(--accent-dark);
  font-size: 0.78rem;
  font-weight: 800;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

h1,
h2,
p {
  margin-top: 0;
}

h1 {
  max-width: 760px;
  margin-bottom: 14px;
  font-size: clamp(2.25rem, 6vw, 4.8rem);
  line-height: 0.98;
  letter-spacing: 0;
}

.intro {
  max-width: 650px;
  margin-bottom: 0;
  color: var(--muted);
  font-size: 1.08rem;
  line-height: 1.65;
}

.billing-control {
  display: inline-grid;
  grid-template-columns: 1fr 1fr;
  gap: 4px;
  min-width: 286px;
  padding: 5px;
  border: 1px solid rgba(23, 32, 51, 0.12);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.72);
  box-shadow: 0 12px 28px rgba(31, 41, 55, 0.08);
}

.billing-option {
  min-height: 44px;
  border: 0;
  border-radius: 6px;
  background: transparent;
  color: var(--muted);
  cursor: pointer;
  font-weight: 800;
  transition: background 180ms ease, color 180ms ease, transform 180ms ease;
}

.billing-option span {
  display: block;
  font-size: 0.68rem;
  font-weight: 700;
}

.billing-option.active {
  background: var(--surface-strong);
  color: #fff;
}

.billing-option:focus-visible,
.plan-cta:focus-visible {
  outline: 3px solid rgba(15, 118, 110, 0.32);
  outline-offset: 3px;
}

.pricing-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 18px;
  align-items: stretch;
}

.plan {
  position: relative;
  display: flex;
  min-height: 560px;
  flex-direction: column;
  padding: 28px;
  border: 1px solid rgba(23, 32, 51, 0.11);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.84);
  box-shadow: 0 14px 36px rgba(31, 41, 55, 0.08);
}

.plan.featured {
  background: var(--surface-strong);
  color: #fff;
  box-shadow: var(--shadow);
  transform: translateY(-10px);
}

.badge {
  position: absolute;
  right: 20px;
  top: 18px;
  padding: 7px 10px;
  border-radius: 999px;
  background: var(--gold);
  color: #2b2110;
  font-size: 0.72rem;
  font-weight: 900;
}

.plan-top {
  min-height: 158px;
}

.plan-icon {
  display: grid;
  width: 44px;
  height: 44px;
  margin-bottom: 22px;
  place-items: center;
  border-radius: 8px;
  background: rgba(15, 118, 110, 0.12);
  color: var(--accent-dark);
}

.featured .plan-icon {
  background: rgba(255, 255, 255, 0.12);
  color: var(--gold);
}

.plan h2 {
  margin-bottom: 10px;
  font-size: 1.45rem;
}

.plan p {
  margin-bottom: 0;
  color: var(--muted);
  line-height: 1.55;
}

.featured p,
.featured .period {
  color: #b9c3d5;
}

.price {
  display: flex;
  align-items: baseline;
  gap: 4px;
  margin: 24px 0 22px;
}

.currency {
  font-size: 1.5rem;
  font-weight: 800;
}

.amount {
  min-width: 2ch;
  font-size: 4.2rem;
  font-weight: 900;
  line-height: 1;
}

.period {
  color: var(--muted);
  font-weight: 700;
}

.plan-cta {
  width: 100%;
  min-height: 48px;
  border: 1px solid rgba(23, 32, 51, 0.14);
  border-radius: 8px;
  background: #fff;
  color: var(--text);
  cursor: pointer;
  font-weight: 900;
  transition: transform 180ms ease, box-shadow 180ms ease, background 180ms ease;
}

.plan-cta.primary {
  border-color: var(--coral);
  background: var(--coral);
  color: #fff;
}

.plan-cta:hover {
  transform: translateY(-2px);
  box-shadow: 0 12px 26px rgba(31, 41, 55, 0.16);
}

.features {
  display: grid;
  gap: 14px;
  margin: 26px 0 0;
  padding: 0;
  list-style: none;
}

.features li {
  display: grid;
  grid-template-columns: 20px 1fr;
  gap: 10px;
  align-items: start;
  color: #293548;
  line-height: 1.45;
}

.featured .features li {
  color: #eef3fb;
}

.features svg {
  margin-top: 1px;
  color: var(--accent);
}

.featured .features svg {
  color: var(--gold);
}

.comparison {
  margin-top: 24px;
  padding: 28px;
  border: 1px solid rgba(23, 32, 51, 0.11);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.78);
}

.comparison-heading {
  display: flex;
  justify-content: space-between;
  gap: 18px;
  margin-bottom: 18px;
}

.comparison-heading h2 {
  margin-bottom: 0;
  font-size: 1.25rem;
}

.comparison-heading p {
  margin-bottom: 0;
  color: var(--muted);
}

.comparison-table {
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 8px;
}

.comparison-row {
  display: grid;
  grid-template-columns: 1.4fr repeat(3, 1fr);
}

.comparison-row > div {
  min-width: 0;
  padding: 16px;
  border-top: 1px solid var(--line);
  color: #344054;
  overflow-wrap: anywhere;
}

.comparison-row.header > div {
  border-top: 0;
  background: #eef3f1;
  color: #162236;
  font-weight: 900;
}

.comparison-row > div:not(:first-child) {
  border-left: 1px solid var(--line);
}

.site-footer {
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto;
  padding: 0 0 34px;
  color: var(--muted);
  text-align: center;
}

.site-footer p {
  margin: 0;
  font-size: 0.92rem;
  font-weight: 600;
}

@media (max-width: 940px) {
  .pricing-header {
    grid-template-columns: 1fr;
  }

  .billing-control {
    width: min(100%, 340px);
  }

  .pricing-grid {
    grid-template-columns: 1fr;
  }

  .plan,
  .plan.featured {
    min-height: auto;
    transform: none;
  }

  .plan-top {
    min-height: auto;
  }
}

@media (max-width: 640px) {
  .pricing-shell {
    width: min(100% - 24px, 1180px);
    padding: 32px 0;
  }

  h1 {
    font-size: 2.45rem;
  }

  .intro {
    font-size: 1rem;
  }

  .billing-control {
    min-width: 0;
  }

  .plan,
  .comparison {
    padding: 20px;
  }

  .amount {
    font-size: 3.4rem;
  }

  .comparison-heading {
    display: block;
  }

  .comparison-heading h2 {
    margin-bottom: 6px;
  }

  .comparison-table {
    border: 0;
    border-radius: 0;
  }

  .comparison-row {
    grid-template-columns: 1fr;
    margin-bottom: 12px;
    overflow: hidden;
    border: 1px solid var(--line);
    border-radius: 8px;
    background: #fff;
  }

  .comparison-row.header {
    display: none;
  }

  .comparison-row > div {
    display: flex;
    justify-content: space-between;
    gap: 14px;
    border-top: 1px solid var(--line);
  }

  .comparison-row > div:first-child {
    border-top: 0;
    background: #eef3f1;
    font-weight: 900;
  }

  .comparison-row > div:not(:first-child) {
    border-left: 0;
  }

  .comparison-row > div:nth-child(2)::before {
    content: "Starter";
    color: var(--muted);
    font-weight: 700;
  }

  .comparison-row > div:nth-child(3)::before {
    content: "Growth";
    color: var(--muted);
    font-weight: 700;
  }

  .comparison-row > div:nth-child(4)::before {
    content: "Scale";
    color: var(--muted);
    font-weight: 700;
  }

  .site-footer {
    width: min(100% - 24px, 1180px);
    padding-bottom: 26px;
  }
}
