/* ==========================================================================
   Pricing page (/site/pricing) — Pen redesign. Loaded after editorial.css and
   only on this page; every rule is scoped to .ed-pricing so shared styles stay
   untouched.
   Contrast: brand red is 3.4:1 on paper, so small red text from the design is
   set in ink, and white-on-red labels use 19px bold (WCAG "large text").
   ========================================================================== */

.ed-pricing ul { list-style: none; margin: 0; padding: 0; }
.ed-pricing__band { background: var(--ed-paper-2); padding-block: 112px 120px; }
.ed-pricing__section { padding-block: 140px; }
.ed-pricing__red { color: var(--ed-red); }

/* ── Hero ────────────────────────────────────────────────────────────────── */
.ed-pricing__hero { padding-bottom: 120px; }
.ed-pricing__head { display: flex; justify-content: space-between; align-items: flex-end; gap: 48px; margin: 56px 0; }
.ed-pricing__headline { min-width: 0; }
.ed-pricing__l1, .ed-pricing__l3 { font-size: clamp(48px, 9.7vw, 140px); }
.ed-pricing__l23 { margin: 0; }
.ed-pricing__l2 { font-size: clamp(44px, 9.7vw, 140px); letter-spacing: -0.06em; color: var(--ed-red); padding-bottom: 0.04em; }
.ed-pricing__side { display: flex; flex-direction: column; gap: 28px; width: 340px; flex-shrink: 0; padding-bottom: 16px; }
.ed-pricing__intro { margin: 0; font-size: 20px; font-weight: 500; line-height: 1.45; }
.ed-pricing__toggle { display: inline-flex; align-self: flex-start; padding: 5px; border: 1px solid var(--ed-ink); border-radius: 100px; }
.ed-pricing__toggle button { display: inline-flex; align-items: center; gap: 8px; padding: 10px 20px; border: 0; border-radius: 100px; background: transparent; color: var(--ed-ink); font-family: var(--ed-sans); font-size: 14px; font-weight: 500; cursor: pointer; transition: background-color .2s var(--ed-ease), color .2s var(--ed-ease); }
.ed-pricing__toggle button.is-active { background: var(--ed-ink); color: var(--ed-paper); font-weight: 700; }
.ed-pricing__save { font-size: 12px; letter-spacing: 0.04em; }

/* ── Plans ───────────────────────────────────────────────────────────────── */
.ed-pricing__plans { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); border-block: 1.5px solid var(--ed-ink); }
.ed-pricing__plan { display: flex; flex-direction: column; gap: 28px; padding: 36px 28px 32px; border-right: 1px solid var(--ed-line); min-width: 0; }
.ed-pricing__plan:last-child { border-right: 0; }
.ed-pricing__plan.is-featured { position: relative; background: #fff; border: 2px solid var(--ed-red); margin-block: -1.5px; }
.ed-pricing__plan-name { display: flex; flex-direction: column; gap: 6px; }
.ed-pricing__plan-top { display: flex; justify-content: space-between; align-items: center; gap: 12px; }
.ed-pricing__plan-title { margin: 0; font-family: var(--ed-display-text); font-weight: 700; font-size: clamp(32px, 2.7vw, 44px); line-height: 0.95; text-transform: uppercase; }
.ed-pricing__badge { padding: 6px 12px; border-radius: 100px; background: var(--ed-red); color: var(--ed-ink); font-size: 11px; line-height: 1; white-space: nowrap; }
.ed-pricing__kicker { margin: 0; color: #4F4F4F; font-size: 20px; font-weight: 500; line-height: 1.25; }
.ed-pricing__price { display: flex; align-items: flex-end; gap: 6px; margin: 0; min-height: 58px; }
.ed-pricing__amount { font-family: var(--ed-display-text); font-weight: 700; font-size: 64px; line-height: 0.9; }
.ed-pricing__plan.is-featured .ed-pricing__amount { color: var(--ed-red); }
.ed-pricing__price .price-period { padding-bottom: 6px; color: var(--ed-muted); font-size: 14px; }
.ed-pricing__price--talk .ed-pricing__amount { font-size: clamp(36px, 3.2vw, 52px); }
.ed-pricing__features { display: flex; flex-direction: column; gap: 12px; flex: 1; padding-top: 24px; border-top: 1px solid var(--ed-line); }
.ed-pricing__features li { display: flex; align-items: flex-start; gap: 10px; font-size: 15px; line-height: 1.3; }
.ed-pricing__features svg { flex-shrink: 0; margin-top: 1px; }
.ed-pricing__plan.is-featured .ed-pricing__features { border-top-color: rgba(12, 12, 14, 0.2); }
.ed-pricing__plan.is-featured .ed-pricing__features svg { color: var(--ed-red); }
.ed-pricing__btn { display: flex; justify-content: space-between; align-items: center; gap: 12px; margin-top: 8px; padding: 14px 20px; border: 1px solid var(--ed-ink); border-radius: 100px; font-size: 19px; font-weight: 700; line-height: 1.2; transition: background-color .2s var(--ed-ease), color .2s var(--ed-ease); }
.ed-pricing__btn svg { flex-shrink: 0; transition: transform .25s var(--ed-ease); }
.ed .ed-pricing__btn:hover { background: var(--ed-ink); color: var(--ed-paper); }
.ed .ed-pricing__btn:hover svg { transform: translateX(3px); }
.ed .ed-pricing__btn--red { background: var(--ed-red); border-color: var(--ed-red); color: #fff; }
.ed .ed-pricing__btn--red:hover { background: #E5203F; border-color: #E5203F; color: #fff; }

/* ── Compare ─────────────────────────────────────────────────────────────── */
.ed-pricing__title { display: flex; flex-wrap: wrap; align-items: baseline; column-gap: 24px; margin: 56px 0; }
.ed-pricing__title .ed-display, .ed-pricing__title .ed-contrast { font-size: clamp(48px, 7.2vw, 104px); }
.ed-pricing__title .ed-contrast { letter-spacing: -0.06em; }
/* position: relative keeps the sticky column from widening the mobile layout viewport. */
.ed-pricing__table-wrap { position: relative; overflow-x: auto; }
.ed-pricing__table-wrap:focus-visible { outline: 2px solid var(--ed-ink); outline-offset: 4px; }
.ed-pricing__table { width: 100%; min-width: 760px; border-collapse: collapse; font-size: 15px; }
.ed-pricing__table th, .ed-pricing__table td { padding: 0; text-align: center; font-weight: 500; }
.ed-pricing__table thead tr { border-bottom: 1.5px solid var(--ed-ink); }
.ed-pricing__table thead th { padding: 24px 8px 20px; width: 15.625%; vertical-align: bottom; }
.ed-pricing__th-name { display: block; font-family: var(--ed-display-text); font-weight: 700; font-size: 28px; line-height: 0.95; text-transform: uppercase; }
.ed-pricing__th-price { display: block; margin-top: 6px; color: var(--ed-muted); font-size: 14px; font-weight: 400; }
.ed-pricing__th-price .ed-pricing__amount { font-family: inherit; font-size: inherit; font-weight: inherit; line-height: inherit; }
.ed-pricing__table .is-featured { background: var(--ed-paper); }
.ed-pricing__table tbody th[scope="row"] { padding: 18px 0; text-align: left; font-size: 16px; }
.ed-pricing__table tbody tr:not(.ed-pricing__group) { border-bottom: 1px solid var(--ed-line); }
.ed-pricing__table tbody td { height: 58px; }
.ed-pricing__group th { padding: 32px 0 12px; text-align: left; font-weight: 400; }
.ed-pricing__yes { display: inline-flex; color: var(--ed-ink); }
.ed-pricing__table td.is-featured .ed-pricing__yes { color: var(--ed-red); }
.ed-pricing__no { display: inline-flex; color: rgba(12, 12, 14, 0.4); }

/* ── FAQ ─────────────────────────────────────────────────────────────────── */
.ed-pricing__faq { display: grid; grid-template-columns: minmax(0, 460px) minmax(0, 1fr); gap: 96px; margin-top: 72px; align-items: start; }
.ed-pricing__faq-side { display: flex; flex-direction: column; gap: 48px; }
.ed-pricing__faq-title { margin: 0; }
.ed-pricing__faq-title .ed-display, .ed-pricing__faq-title .ed-contrast { font-size: clamp(56px, 6.67vw, 96px); line-height: 0.9; }
.ed-pricing__faq-title .ed-contrast { letter-spacing: -0.06em; }
.ed-pricing__card { display: flex; flex-direction: column; align-items: flex-start; gap: 20px; padding: 32px; border-radius: 4px; background: var(--ed-paper-2); }
.ed-pricing__card-kicker { color: var(--ed-muted); font-size: 11px; }
.ed-pricing__card-title { margin: 0; font-size: clamp(28px, 2.5vw, 36px); font-weight: 500; line-height: 1.05; letter-spacing: -0.03em; }
.ed-pricing__card-body { margin: 0; color: var(--ed-muted); font-size: 15px; line-height: 1.55; }
.ed-pricing__card-btn { padding: 14px 24px; font-size: 19px; }
.ed-pricing__accordion { border-top: 1.5px solid var(--ed-ink); }
.ed-pricing__faq-item { border-bottom: 1px solid var(--ed-line); }
.ed-pricing__q { margin: 0; }
.ed-pricing__q button { display: grid; grid-template-columns: 24px minmax(0, 1fr) 44px; align-items: center; gap: 28px; width: 100%; padding: 32px 0; border: 0; background: none; color: var(--ed-ink); font-family: var(--ed-sans); text-align: left; cursor: pointer; }
.ed-pricing__q-num { color: var(--ed-muted); }
.ed-pricing__q button[aria-expanded="true"] .ed-pricing__q-num { color: var(--ed-ink); }
.ed-pricing__q-text { font-size: clamp(20px, 1.8vw, 26px); font-weight: 500; line-height: 1.25; letter-spacing: -0.015em; }
.ed-pricing__q-toggle { display: grid; place-items: center; width: 44px; height: 44px; border: 1px solid var(--ed-line); border-radius: 50%; transition: background-color .2s var(--ed-ease), color .2s var(--ed-ease); }
.ed-pricing__q button:hover .ed-pricing__q-toggle { border-color: var(--ed-ink); }
.ed-pricing__q button[aria-expanded="true"] .ed-pricing__q-toggle { background: var(--ed-ink); border-color: var(--ed-ink); color: var(--ed-paper); }
.ed-pricing__q button[aria-expanded="true"] .ed-pricing__q-plus { display: none; }
.ed-pricing__a { padding: 0 72px 32px 52px; }
.ed-pricing__a p { margin: 0; color: var(--ed-muted); font-size: 17px; line-height: 1.6; }

/* ── Plans: 2 × 2 below 1280px ───────────────────────────────────────────── */
@media (max-width: 1279px) {
    .ed-pricing__plans { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .ed-pricing__plan:nth-child(2) { border-right: 0; }
    .ed-pricing__plan:nth-child(-n+2) { border-bottom: 1px solid var(--ed-line); }
    .ed-pricing__plan.is-featured { margin: 0; }
    .ed-pricing__plan-title { font-size: 44px; }
}

/* ── Tablet ──────────────────────────────────────────────────────────────── */
@media (max-width: 1023px) {
    .ed-pricing__head { flex-direction: column; align-items: flex-start; gap: 32px; }
    .ed-pricing__side { width: 100%; max-width: 480px; padding-bottom: 0; }
    .ed-pricing__faq { grid-template-columns: minmax(0, 1fr); gap: 56px; }
    .ed-pricing__card { max-width: 560px; }
}

/* ── Mobile ──────────────────────────────────────────────────────────────── */
.ed-pricing__pager, .ed-pricing__switch { display: none; }

/* ── Phones (Pen "Pricing — Mobile (390)") ────────────────────────────────── */
@media (max-width: 760px) {
    .ed-pricing__hero { padding-bottom: 56px; }
    .ed-pricing__band, .ed-pricing__section { padding-block: 56px; }
    .ed-pricing__head { margin: 24px 0 28px; gap: 20px; }
    .ed-pricing__l1, .ed-pricing__l3 { font-size: 13.3vw; }
    .ed-pricing__l2 { font-size: 13.3vw; }
    .ed-pricing__intro { font-size: 18px; }

    /* Plans: swipeable carousel of equal-height cards with a pager. */
    .ed-pricing__plans { position: relative; display: flex; gap: 12px; margin-inline: calc(var(--bk-edge, 20px) * -1); padding-inline: var(--bk-edge, 20px); scroll-padding-inline: var(--bk-edge, 20px); border: 0; overflow-x: auto; scroll-snap-type: x mandatory; overscroll-behavior-x: contain; scrollbar-width: none; }
    .ed-pricing__plans::-webkit-scrollbar { display: none; }
    .ed-pricing__plan, .ed-pricing__plan:nth-child(-n+2), .ed-pricing__plan:last-child { flex: 0 0 min(300px, 80vw); gap: 22px; margin: 0; padding: 28px 24px 24px; border: 0; border-radius: 4px; background: var(--ed-paper-2); scroll-snap-align: start; }
    .ed-pricing__plan.is-featured { padding-inline: 24px; border: 2px solid var(--ed-red); background: #fff; }
    .ed .ed-pricing__plan-title { font-size: 38px; }
    .ed-pricing__kicker { font-size: 17px; }
    .ed-pricing__amount { font-size: 56px; }
    .ed-pricing__features { gap: 10px; padding-top: 18px; }
    .ed-pricing__btn { min-height: 52px; margin-top: 0; font-size: 17px; }
    .ed .ed-pricing__btn--red { font-size: 19px; } /* 19px bold: white on brand red meets AA */
    .ed-pricing__pager { display: flex; justify-content: space-between; align-items: center; margin-top: 24px; color: var(--ed-muted); }
    .ed-pricing__dots { display: flex; gap: 6px; }
    .ed-pricing__dots > span { width: 8px; height: 4px; border-radius: 2px; background: rgba(12, 12, 14, 0.2); transition: width .3s var(--ed-ease), background-color .3s var(--ed-ease); }
    .ed-pricing__dots > span.is-active { width: 24px; background: var(--ed-ink); }

    /* Compare: a plan switcher shows one plan column next to the features. */
    .ed-pricing__title { margin: 24px 0; }
    .ed-pricing__title .ed-display, .ed-pricing__title .ed-contrast { font-size: 13.3vw; }
    .ed-pricing__switch:not([hidden]) { display: flex; gap: 0; margin-bottom: 20px; padding: 4px; border: 1px solid var(--ed-ink); border-radius: 100px; }
    .ed-pricing__switch button { flex: 1; min-height: 40px; padding: 0 6px; border: 0; border-radius: 100px; background: transparent; color: var(--ed-ink); font-family: var(--ed-sans); font-size: 14px; font-weight: 500; cursor: pointer; }
    .ed-pricing__switch button[aria-pressed="true"] { background: var(--ed-ink); color: var(--ed-paper); font-weight: 700; }
    .ed-pricing__table { min-width: 620px; font-size: 14px; }
    .ed-pricing__table thead th { width: auto; padding-inline: 4px; }
    .ed-pricing__th-name { font-size: 22px; }
    .ed-pricing__table thead td, .ed-pricing__table tbody th { position: sticky; left: 0; z-index: 1; width: 140px; min-width: 140px; padding-right: 12px; background: var(--ed-paper-2); }
    .ed-pricing__table tbody th[scope="row"] { font-size: 14px; line-height: 1.3; box-shadow: 1px 0 0 var(--ed-line); }
    /* With a plan picked (JavaScript on), only that column shows and the table fits the screen. */
    .ed-pricing__table[data-col] { min-width: 0; table-layout: auto; }
    .ed-pricing__table[data-col] thead td, .ed-pricing__table[data-col] tbody th { position: static; width: auto; min-width: 0; box-shadow: none; }
    .ed-pricing__table[data-col="2"] tr > :nth-child(n+2):not(:nth-child(2)),
    .ed-pricing__table[data-col="3"] tr > :nth-child(n+2):not(:nth-child(3)),
    .ed-pricing__table[data-col="4"] tr > :nth-child(n+2):not(:nth-child(4)),
    .ed-pricing__table[data-col="5"] tr > :nth-child(n+2):not(:nth-child(5)) { display: none; }
    .ed-pricing__table[data-col] thead th { padding: 0 0 14px; text-align: right; }
    .ed-pricing__table[data-col] thead tr { display: table-row; }
    .ed-pricing__table[data-col] .ed-pricing__th-name { font-size: 36px; }
    .ed-pricing__table[data-col] td { padding-left: 12px; text-align: right; white-space: nowrap; }
    .ed-pricing__table[data-col] .is-featured { background: transparent; }
    .ed-pricing__table[data-col] tbody th[scope="row"] { padding: 14px 0; font-size: 15px; }
    .ed-pricing__table[data-col] tbody td { height: auto; }

    /* FAQ: title, questions, then the contact card. */
    .ed-pricing__faq { display: flex; flex-direction: column; gap: 28px; margin-top: 24px; }
    .ed-pricing__faq-side { display: contents; }
    .ed-pricing__faq-title { order: 0; }
    .ed-pricing__faq-title .ed-display, .ed-pricing__faq-title .ed-contrast { font-size: 14.4vw; }
    .ed-pricing__accordion { order: 1; }
    .ed-pricing__card { order: 2; gap: 16px; padding: 24px; }
    .ed-pricing__card-title { font-size: 28px; }
    .ed-pricing .ed-pricing__faq-item { padding: 0; } /* main.css pads every .faq-item */
    .ed-pricing__q button { grid-template-columns: 22px minmax(0, 1fr) 36px; gap: 14px; padding: 18px 0; }
    .ed-pricing__q-num { grid-column: auto; }
    .ed-pricing__q-text { font-size: 18px; }
    .ed-pricing__q-toggle { width: 36px; height: 36px; }
    .ed-pricing__a { padding: 0 50px 18px 36px; }
    .ed-pricing__a p { font-size: 15px; }
}
