/* Pricing page. Loaded after home.css. New rules use the pr- prefix. */

:root,
[data-theme="dark"] {
  --pr-bar-muted: #5E7369;
}

[data-theme="light"] {
  --pr-bar-muted: #7A8B84;
}

.pr-sr {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  clip-path: inset(50%);
  white-space: nowrap;
  border: 0;
}

.nav-links a[aria-current="page"] {
  color: var(--text);
}

/* Hero. Stays dark via .theme-dark. Pulled under the nav by .hero. */

.pr-hero {
  background: var(--bg);
}

.pr-hero .hero-inner {
  align-items: flex-start;
  padding-bottom: 72px;
}

.pr-hero .hero-copy {
  flex: 1 1 100%;
  max-width: 760px;
  min-width: 0;
}

.pr-hero .hero-lead {
  max-width: 40em;
}

.pr-promises {
  display: flex;
  flex-wrap: wrap;
  gap: 12px 22px;
  list-style: none;
  margin: 32px 0 0;
  padding: 0;
}

.pr-promises li,
.pr-plan-list li,
.pr-included-list li {
  display: flex;
  align-items: flex-start;
  gap: 10px;
}

.pr-promises li {
  align-items: center;
  font-size: 15px;
  line-height: 1.4;
}

.pr-icon {
  color: var(--icon);
  flex: none;
}

.pr-plan-list .pr-icon,
.pr-included-list .pr-icon {
  margin-top: 3px;
}

.pr-plan-wrap {
  position: relative;
  flex: 0 1 420px;
  width: min(100%, 420px);
  max-width: 420px;
  min-width: 0;
}

.pr-plan-glow {
  position: absolute;
  z-index: 0;
  inset: 8% -6% -6%;
  background: radial-gradient(closest-side, rgba(var(--accent-rgb), 0.34), rgba(var(--accent-rgb), 0) 72%);
  filter: blur(22px);
  pointer-events: none;
}

.pr-plan {
  position: relative;
  z-index: 1;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 22px;
  box-shadow: 0 32px 70px -34px rgba(var(--shadow-rgb), 0.7);
  padding: 26px;
}

.pr-plan-top {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 10px 12px;
}

.pr-plan-name {
  margin: 0;
  font-family: var(--display);
  font-size: 20px;
  font-weight: 600;
  letter-spacing: -0.01em;
  line-height: 1.2;
}

.pr-plan-top .tag {
  align-self: center;
}

.pr-switch {
  display: flex;
  align-items: stretch;
  gap: 4px;
  width: 100%;
  margin: 22px 0 0;
  padding: 4px;
  border-radius: 14px;
  background: var(--inset);
  border: 1px solid var(--line);
}

.pr-opt {
  position: relative;
  flex: 1 1 0;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-wrap: wrap;
  gap: 8px;
  min-height: 44px;
  min-width: 0;
  padding: 6px 10px;
  border-radius: 10px;
  color: var(--text);
  font-size: 15px;
  font-weight: 500;
  line-height: 1.2;
  text-align: center;
  cursor: pointer;
  user-select: none;
}

.pr-opt input {
  accent-color: var(--jade);
  margin: 0;
}

.pr-switch-tag {
  align-self: center;
  padding: 2px 8px;
  font-size: 12px;
  line-height: 1.3;
}

.pr-price {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 4px 10px;
  margin: 20px 0 0;
  max-width: 100%;
}

.pr-amount {
  font-family: var(--display);
  font-weight: 600;
  font-size: 72px;
  letter-spacing: -0.03em;
  line-height: 0.95;
}

.pr-per {
  font-size: 16px;
  font-weight: 500;
  color: var(--muted);
}

.pr-save {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px;
  margin: 14px 0 0;
}

.pr-save .tag {
  align-self: center;
}

.pr-was {
  color: var(--muted);
  font-size: 18px;
  text-decoration: line-through;
}

.pr-bill {
  margin: 12px 0 0;
  font-size: 15px;
  line-height: 1.5;
  color: var(--muted);
}

.pr-plan .pr-btn {
  width: 100%;
  justify-content: center;
  text-align: center;
}

.pr-offer .pr-btn {
  margin-top: 18px;
}

.pr-avail {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  width: 100%;
  margin: 18px 0 0;
  min-height: 48px;
  padding: 14px 22px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: var(--surface);
  color: var(--text);
  font-size: 16px;
  font-weight: 500;
  line-height: 1.2;
  text-align: center;
}

.pr-fine {
  margin: 12px 0 0;
  font-size: 13px;
  line-height: 1.5;
  color: var(--muted);
}

.pr-divider {
  border: 0;
  height: 0;
  border-top: 1px solid var(--line);
  margin: 22px 0;
}

.pr-plan-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 12px;
}

.pr-plan-list li {
  font-size: 15px;
  line-height: 1.45;
}

@supports selector(:has(*)) {
  .pr-opt input {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    margin: 0;
    opacity: 0;
    cursor: pointer;
  }

  .pr-opt:has(input:checked) {
    background: var(--jade);
    color: var(--on-jade);
  }

  .pr-opt:has(input:checked):hover {
    background: var(--primary-hover);
  }

  .pr-opt:has(input:checked) .tag {
    background: var(--on-jade);
    color: var(--jade);
  }

  .pr-opt:has(input:focus-visible) {
    outline: 2px solid var(--focus);
    outline-offset: 2px;
    z-index: 1;
  }
}

.pr-yearly {
  display: none;
}

.pr-plans:has(input[value="yearly"]:checked) .pr-monthly {
  display: none;
}

.pr-plans:has(input[value="yearly"]:checked) .pr-yearly {
  display: block;
}

.pr-plans {
  padding: 56px 24px 80px;
}

.pr-plans .pr-switch {
  width: min(100%, 460px);
  margin-top: 28px;
}

.pr-plan-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 16px;
  margin-top: 28px;
  align-items: stretch;
}

.pr-plans .pr-plan-wrap {
  flex: none;
  width: auto;
  max-width: none;
  min-width: 0;
  height: 100%;
}

.pr-plan-featured {
  z-index: 1;
}

.pr-plans .pr-plan {
  height: 100%;
  min-width: 0;
}

.pr-limit {
  margin: 16px 0 0;
  font-family: var(--display);
  font-size: 28px;
  font-weight: 600;
  letter-spacing: -0.02em;
  line-height: 1.15;
}

.pr-blurb {
  margin: 8px 0 0;
  min-height: 2.9em;
  font-size: 15px;
  line-height: 1.45;
  color: var(--muted);
}

.pr-plans .pr-amount {
  font-size: 44px;
}

.pr-includes {
  margin-top: 36px;
}

.pr-includes-title {
  margin: 0;
  font-family: var(--display);
  font-size: 20px;
  font-weight: 600;
  letter-spacing: -0.01em;
  line-height: 1.25;
}

.pr-includes .pr-plan-list {
  display: flex;
  flex-wrap: wrap;
  gap: 12px 22px;
  margin-top: 16px;
}

.pr-quote {
  margin: 22px 0 0;
  max-width: 46em;
  font-size: 16px;
  line-height: 1.55;
}

/* Compare and fair billing follow the page theme. */

.pr-compare {
  padding: 112px 24px 56px;
}

.pr-billing {
  padding: 56px 24px 112px;
}

.pr-lead {
  margin: 16px 0 0;
  font-size: 17px;
  line-height: 1.6;
  color: var(--muted);
}

.pr-chart-card {
  margin-top: 36px;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 22px;
  padding: 28px;
}

.pr-bars {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 18px;
}

.pr-bar-row {
  display: grid;
  grid-template-columns: minmax(180px, 250px) minmax(0, 1fr) auto;
  gap: 8px 16px;
  align-items: center;
}

.pr-bar-meta {
  min-width: 0;
}

.pr-bar-name {
  display: block;
  font-size: 15px;
  font-weight: 600;
  line-height: 1.3;
}

.pr-bar-note {
  display: block;
  margin-top: 2px;
  font-size: 13px;
  line-height: 1.35;
  color: var(--muted);
}

.pr-bar-track {
  min-width: 0;
  height: 14px;
  border-radius: 999px;
  background: var(--inset);
  overflow: hidden;
}

.pr-bar {
  display: block;
  height: 100%;
  border-radius: 999px;
  background: var(--pr-bar-muted);
}

.pr-w-fr {
  width: 24.4%;
  background: var(--jade);
}

.pr-w-sc {
  width: 52.5%;
}

.pr-w-ad {
  width: 56.8%;
}

.pr-w-tv {
  width: 100%;
}

.pr-bar-price {
  font-family: var(--mono);
  font-size: 15px;
  font-weight: 500;
  line-height: 1.2;
  text-align: right;
  white-space: nowrap;
  font-variant-numeric: tabular-nums;
}

.pr-from {
  font-family: var(--sans);
  font-size: 12px;
  font-weight: 500;
  color: var(--muted);
  margin-right: 0.3em;
}

.pr-chart-foot {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  align-items: flex-start;
  gap: 18px 32px;
  margin-top: 28px;
  padding-top: 20px;
  border-top: 1px solid var(--line);
}

.pr-chart-caption {
  margin: 0;
  flex: 1 1 220px;
  max-width: 320px;
  font-size: 13px;
  line-height: 1.5;
  color: var(--muted);
}

.pr-chart-aside {
  flex: 1 1 260px;
  max-width: 480px;
  margin-left: auto;
  text-align: right;
}

.pr-chart-keep {
  margin: 0;
  font-size: 17px;
  font-weight: 500;
  line-height: 1.45;
}

.pr-chart-sub {
  margin: 8px 0 0;
  font-size: 14px;
  line-height: 1.5;
  color: var(--muted);
}

.pr-table-scroll {
  margin-top: 28px;
  max-width: 100%;
  overflow-x: auto;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 16px;
  -webkit-overflow-scrolling: touch;
}

.pr-table {
  position: relative;
  width: 100%;
  min-width: 760px;
  border-collapse: separate;
  border-spacing: 0;
}

.pr-table caption {
  caption-side: top;
}

.pr-table th,
.pr-table td {
  padding: 14px 16px;
  border-bottom: 1px solid var(--line);
  text-align: left;
  vertical-align: top;
  font-size: 15px;
  font-weight: 400;
  line-height: 1.45;
}

.pr-table thead th {
  font-weight: 600;
  font-size: 14px;
}

.pr-table tbody th {
  font-weight: 600;
}

.pr-table tr:last-child th,
.pr-table tr:last-child td {
  border-bottom: 0;
}

.pr-table th:nth-child(2),
.pr-table td:nth-child(2) {
  background: rgba(var(--accent-rgb), 0.06);
}

.pr-table th:first-child,
.pr-table td:first-child {
  position: sticky;
  left: 0;
  z-index: 1;
  min-width: 200px;
  background: var(--surface);
  border-right: 1px solid var(--line);
}

.pr-source {
  margin: 14px 0 0;
  font-size: 13px;
  line-height: 1.55;
  color: var(--muted);
}

.pr-fair-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 16px;
  margin-top: 40px;
}

.pr-fair-card {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 20px;
  padding: 24px;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 12px;
  min-width: 0;
}

.pr-fair-icon {
  width: 26px;
  height: 26px;
}

.pr-fair-title {
  margin: 0;
  font-size: 18px;
  line-height: 1.25;
  letter-spacing: -0.01em;
}

.pr-fair-text {
  margin: 0;
  font-size: 15px;
  line-height: 1.6;
  color: var(--muted);
}

/* Everything included. Dark band, same shell as Security. */

.pr-included .security-inner {
  align-items: flex-start;
}

.pr-soon {
  margin: 14px 0 0;
  font-size: 14px;
  line-height: 1.5;
  color: var(--muted);
}

.pr-included-list {
  flex: 1 1 480px;
  min-width: 0;
  margin: 0;
  padding: 0;
  list-style: none;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(220px, 100%), 1fr));
  gap: 16px 28px;
}

.pr-included-list li {
  font-size: 15px;
  line-height: 1.55;
  color: var(--muted);
}

.pr-included-list strong {
  color: var(--text);
  font-weight: 600;
}

/* Final call to action. One centered button. */

.pr-cta-actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 12px;
  max-width: 100%;
}

@media (min-width: 768px) {
  .pr-plan-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (min-width: 1100px) {
  .pr-plan-grid {
    grid-template-columns: repeat(4, minmax(0, 1fr));
  }

  .pr-plans .pr-plan {
    padding: 20px 16px;
  }

  .pr-plans .pr-amount {
    font-size: 32px;
  }

  .pr-plans .pr-price {
    flex-wrap: nowrap;
    gap: 4px 8px;
  }

  .pr-limit {
    font-size: 22px;
  }
}

@media (max-width: 1100px) {
  .pr-fair-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 900px) {
  .pr-hero .hero-inner {
    flex-direction: column;
    align-items: stretch;
    gap: 36px;
  }

  .pr-plan-wrap {
    width: 100%;
    max-width: none;
  }
}

@media (max-width: 720px) {
  .pr-bar-row {
    grid-template-columns: minmax(0, 1fr) auto;
    grid-template-areas:
      "meta meta"
      "track price";
  }

  .pr-bar-meta {
    grid-area: meta;
  }

  .pr-bar-track {
    grid-area: track;
  }

  .pr-bar-price {
    grid-area: price;
    align-self: center;
  }

  .pr-chart-aside,
  .pr-chart-caption {
    max-width: none;
  }

  .pr-chart-aside {
    margin-left: 0;
    text-align: left;
  }
}

@media (max-width: 700px) {
  .pr-cta .cta-lines {
    display: none;
  }
}

@media (max-width: 640px) {
  .pr-plans {
    padding: 40px 16px 56px;
  }

  .pr-compare {
    padding: 72px 16px 36px;
  }

  .pr-billing {
    padding: 36px 16px 72px;
  }

  .pr-fair-grid {
    grid-template-columns: minmax(0, 1fr);
  }

  .pr-chart-card {
    padding: 18px 16px;
  }

  .pr-included .security-inner {
    padding: 72px 16px;
    gap: 32px;
  }
}

@media (max-width: 480px) {
  .pr-hero .hero-inner {
    padding: 148px 16px 64px;
  }

  .pr-plan {
    padding: 20px 16px;
  }

  .pr-amount {
    font-size: 60px;
  }
}
