/* Shared geometry, four materials. Effects live outside the readable content. */
.plans-section { background: radial-gradient(ellipse at 50% 45%, #14371d22, transparent 65%), #090b0d; }
.plans-section .section-heading { margin-bottom: 30px; }
.plans-section .accent-text { color: #b8ff74; }
.plan-selectors { gap: 8px; margin-bottom: 20px; }
.plan-selectors button { border-radius: 8px; padding: 10px 18px; min-height: 57px; text-align: left; background: #101316; }
.plan-selectors button span { display: block; font-size: 12px; font-weight: 750; letter-spacing: .045em; }
.plan-selectors button small { display: block; font-size: 13px; color: #a4abb4; margin-top: 2px; }
.plan-selectors button[aria-pressed=true] { border-color: #a7e37c; background: #25341d; box-shadow: none; }
.plan-selectors button[aria-pressed=true] small { color: #d3efbf; }
.plans-toolbar { max-width: 700px; margin: auto; }
.plans-toolbar p { color: #a4abb4; }
.plans-grid {
  display: flex;
  position: relative;
  align-items: flex-start;
  gap: 54px;
  padding: 42px 34px 48px;
  margin: 0 -4px;
  overflow: auto hidden;
  scroll-snap-type: x mandatory;
  scrollbar-width: none;
  scroll-padding-inline: 34px;
  overscroll-behavior-x: contain;
}
.plans-grid::-webkit-scrollbar { display: none; }
.rarity-card {
  --plan-accent: #d3d9e3;
  --plan-rgb: 211, 217, 227;
  --plan-base: #16191e;
  position: relative;
  isolation: isolate;
  overflow: visible;
  flex: 0 0 360px;
  width: 360px;
  max-width: none;
  padding: 0;
  border: 0;
  border-radius: 16px;
  background: none;
  transform: none;
  box-shadow: none;
  scroll-snap-align: center;
  scroll-snap-stop: always;
  transition: filter .3s;
  cursor: pointer;
}
.rarity-card.is-selected, .rarity-card.plan-featured.is-selected, .rarity-card:not(.plan-featured).is-selected {
  border: 0;
  transform: none;
  box-shadow: none;
}
.rarity-card::before, .rarity-card::after { content: none; }
.rarity-volt { --plan-accent: #63c8ff; --plan-rgb: 99, 200, 255; --plan-base: #0b1823; }
.rarity-inferno { --plan-accent: #ff9a37; --plan-rgb: 255, 143, 40; --plan-base: #21100b; }
.rarity-legendary { --plan-accent: #a6ff36; --plan-rgb: 166, 255, 54; --plan-base: #09140c; }
.rarity-surface {
  position: absolute;
  inset: 0;
  z-index: -2;
  border-radius: inherit;
  background: linear-gradient(140deg, var(--plan-base), #080b0ecf 75%);
  clip-path: polygon(18px 0, calc(100% - 18px) 0, 100% 18px, 100% calc(100% - 18px), calc(100% - 18px) 100%, 18px 100%, 0 calc(100% - 18px), 0 18px);
}
.rarity-surface::after {
  content: '';
  position: absolute;
  inset: 0;
  opacity: .3;
  background: repeating-linear-gradient(130deg, transparent 0 3px, #b3c2d107 3px 4px);
}
.rarity-inferno .rarity-surface::after { background: repeating-linear-gradient(24deg, transparent 0 14px, #fa663509 14px 15px); }
.rarity-legendary .rarity-surface::after { opacity: .45; background: repeating-linear-gradient(0deg, #a6ff3606 0 1px, transparent 1px 4px), repeating-linear-gradient(90deg, #a6ff3604 0 1px, transparent 1px 4px); }
.rarity-frame { position: absolute; z-index: -1; inset: 0; width: 100%; height: 100%; max-width: none; overflow: visible; pointer-events: none; color: var(--plan-accent); }
.rarity-frame path { fill: none; stroke: currentColor; vector-effect: non-scaling-stroke; }
.frame-base { stroke-width: 1.2; opacity: .45; }
.frame-energy { stroke-width: 2; stroke-dasharray: 52 1750; opacity: .75; filter: drop-shadow(0 0 4px currentColor); animation: frame-travel 14s linear infinite; }
.rarity-core .frame-energy { opacity: .3; animation-duration: 22s; }
.rarity-volt .frame-energy { stroke-dasharray: 18 1784; animation-duration: 11s; }
.rarity-inferno .frame-energy { stroke-dasharray: 60 340 30 380 20 970; animation-duration: 8s; }
.rarity-legendary .frame-base { stroke-width: 2; opacity: .85; filter: drop-shadow(0 0 5px #8dff3740); }
.rarity-legendary .frame-energy { stroke-dasharray: 90 280 30 340 50 1010; animation-duration: 6s; }
.rarity-corners { position: absolute; inset: 8px; z-index: -1; opacity: .5; pointer-events: none; background: linear-gradient(var(--plan-accent),var(--plan-accent)) 14px 3px / 8px 8px no-repeat, linear-gradient(var(--plan-accent),var(--plan-accent)) 3px 14px / 8px 8px no-repeat, linear-gradient(var(--plan-accent),var(--plan-accent)) calc(100% - 14px) calc(100% - 3px) / 8px 8px no-repeat, linear-gradient(var(--plan-accent),var(--plan-accent)) calc(100% - 3px) calc(100% - 14px) / 8px 8px no-repeat; }
.plan-particles { position: absolute; z-index: 0; top: -34px; left: -34px; width: calc(100% + 68px); height: calc(100% + 68px); max-width: none; pointer-events: none; }
.rarity-content { position: relative; z-index: 1; padding: 25px 26px 18px; }
.rarity-topline { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin-bottom: 21px; font-size: 11px; }
.rarity-brand { font-size: 14px; font-weight: 750; letter-spacing: -.5px; color: #e5e9ef; }
.rarity-label { color: var(--plan-accent); text-align: right; }
.rarity-reveal { display: block; width: 100%; padding: 0; border: 0; background: none; color: inherit; text-align: center; }
.rarity-name { display: flex; align-items: center; justify-content: center; gap: 8px; color: var(--plan-accent); font-size: 15px; letter-spacing: .09em; font-weight: 750; }
.rarity-name svg { width: 21px; height: 21px; }
.rarity-card h3 { margin: 13px 0 18px; font-size: 31px; letter-spacing: -.035em; font-weight: 700; }
.rarity-price-box { display: flex; align-items: center; justify-content: center; gap: 12px; padding: 13px 8px; border-block: 1px solid rgba(var(--plan-rgb), .35); background: linear-gradient(115deg, rgba(var(--plan-rgb), .04), rgba(var(--plan-rgb), .1), rgba(var(--plan-rgb), .02)); }
.rarity-card .price { color: #f0f3f6; font-size: 44px; line-height: 1.1; font-weight: 800; letter-spacing: -.05em; font-variant-numeric: tabular-nums; white-space: nowrap; }
.rarity-legendary .price { color: #d2ffb6; text-shadow: 0 0 18px #a6ff3633; }
.rarity-card .discount-chip { color: var(--plan-accent); font-size: 14px; border: 1px solid rgba(var(--plan-rgb), .55); border-radius: 3px; background: rgba(var(--plan-rgb), .07); padding: 4px 6px; }
.rarity-card .plan-duration { margin: 11px 0 14px; font-size: 13px; color: #b3bac1; text-align: center; }
.rarity-economy { text-align: center; }
.rarity-economy .plan-reference { font-size: 12px; color: #828c97; }
.rarity-economy strong { display: block; color: var(--plan-accent); font-size: 16px; margin-top: 3px; }
.rarity-card .plan-rate { margin: 10px 0 15px; font-size: 13px; text-align: center; color: #a2abb4; line-height: 1.7; }
.rarity-card .plan-rate strong { font-size: 15px; color: #d8dfe6; font-weight: 600; }
.rarity-card .plan-rate span { display: inline-block; font-size: 12px; }
.rarity-facts { display: flex; justify-content: space-between; gap: 7px; padding: 12px 0; border-block: 1px solid #ffffff12; color: #d2d7de; font-size: 12px; }
.rarity-facts span { display: flex; align-items: center; gap: 5px; }
.rarity-facts svg { width: 15px; height: 15px; color: var(--plan-accent); }
.legendary-advantage { margin: 13px 0 4px; padding-left: 11px; border-left: 2px solid #99ed45; color: #bcc7b8; font-size: 12px; line-height: 1.7; }
.legendary-advantage strong { color: #d1ffb1; }
.rarity-details { max-height: 210px; overflow-y: auto; overscroll-behavior: contain; scrollbar-width: thin; scrollbar-color: var(--plan-accent) transparent; }
.rarity-details[hidden] { display: none; }
.rarity-card .plan-features { padding: 8px 0 0; margin: 0; font-size: 14px; color: #d0d5da; }
.rarity-card .plan-features li { display: flex; align-items: center; gap: 10px; padding: 9px 0; border-bottom: 1px solid #ffffff09; line-height: 1.5; }
.rarity-card .plan-features li::before { content: none; }
.rarity-card .plan-features svg { width: 18px; height: 18px; flex: none; color: var(--plan-accent); }
.rarity-detail-toggle { display: flex; justify-content: center; align-items: center; gap: 7px; margin: 10px auto 12px; padding: 4px 10px; border: 0; background: none; color: #b7c0c9; font-size: 13px; }
.rarity-detail-toggle svg { width: 14px; height: 14px; fill: none; stroke: currentColor; stroke-width: 1.5; transition: transform .3s; }
.rarity-detail-toggle[aria-expanded=true] svg { transform: rotate(180deg); }
.rarity-card .rarity-buy { display: flex; width: 100%; min-height: 49px; padding: 12px 10px; font-size: 16px; font-weight: 750; color: #171c23; background: linear-gradient(120deg, #e0e5ed, #a6afbd); border: 1px solid #ffffff75; border-radius: 7px; box-shadow: inset 0 1px 0 #ffffff75, 0 5px 16px #0005; }
.rarity-buy svg { width: 21px; height: 21px; flex: none; }
.rarity-volt .rarity-buy { background: linear-gradient(120deg, #9bdeff, #3eacee); border-color: #b0e5ff; color: #06253c; }
.rarity-inferno .rarity-buy { background: linear-gradient(120deg, #ffbd62, #ff7e2c); border-color: #ffd08a; color: #371202; box-shadow: inset 0 1px 0 #ffe7b0, 0 3px 20px #ff6d2219; }
.rarity-legendary .rarity-buy { background: linear-gradient(120deg, #baff5a, #80e629); border-color: #ceff9a; color: #102600; box-shadow: inset 0 1px 0 #eeffc9, 0 3px 22px #8dff3829; }
.rarity-card .rarity-buy:hover { box-shadow: inset 0 1px 0 #ffffff85, 0 6px 26px rgba(var(--plan-rgb), .2); transform: translateY(-2px); }
.rarity-upgrade { display: flex; flex-direction: column; align-items: center; gap: 3px; margin-top: 12px; font-size: 12px; color: #a1af9b; }
.rarity-upgrade button { padding: 2px 6px; border: 0; background: none; color: #b5f178; font-size: 12px; text-decoration: underline; text-underline-offset: 3px; }
.rarity-card .plan-foot { display: flex; align-items: center; justify-content: center; gap: 6px; margin: 13px 0 0; color: #8d979f; font-size: 11px; }
.rarity-card .plan-foot svg { width: 14px; height: 14px; color: var(--plan-accent); }
.plan-position { margin: -20px 0 20px; text-align: center; color: #a9b5a3; font-size: 13px; }
.rarity-card.is-bursting .frame-energy { animation: selection-charge .85s ease-out; stroke-dasharray: none; }
.rarity-card.is-bursting .rarity-surface { animation: selection-reveal .7s ease-out; }
@keyframes frame-travel { to { stroke-dashoffset: -1802; } }
@keyframes selection-charge { 0% { opacity: .2; stroke-width: 1; } 30% { opacity: 1; stroke-width: 3; } 100% { opacity: .5; stroke-width: 1.5; } }
@keyframes selection-reveal { 0% { filter: brightness(1); } 25% { filter: brightness(1.35); } 100% { filter: brightness(1); } }
@media (max-width: 650px) {
  .plans-section { padding-block: 65px; }
  .plans-section > .container { width: 100%; padding-inline: 0; }
  .plans-section .section-heading, .plans-toolbar, .plans-info, .plans-legal, .savings-note, .payment-notice { margin-inline: 20px; }
  .plans-section .section-heading h2 { font-size: 35px; }
  .plans-section .section-heading p { font-size: 15px; }
  .plan-selectors { margin-inline: 20px; gap: 6px; display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); overflow: visible; }
  .plan-selectors button { min-width: 0; padding: 8px 4px; text-align: center; min-height: 55px; }
  .plan-selectors button span { font-size: 10px; letter-spacing: 0; overflow-wrap: anywhere; }
  .plan-selectors button small { font-size: 11px; }
  .plans-grid { gap: 24px; margin-inline: 0; padding: 37px max(36px, calc((100% - 330px) / 2)) 40px; scroll-padding-inline: 36px; }
  .rarity-card { flex-basis: min(330px, calc(100vw - 72px)); width: min(330px, calc(100vw - 72px)); }
  .rarity-content { padding: 20px 19px 16px; }
  .rarity-topline { margin-bottom: 17px; }
  .rarity-label { font-size: 10px; }
  .rarity-name { font-size: 13px; letter-spacing: .05em; }
  .rarity-name svg { width: 18px; height: 18px; }
  .rarity-card h3 { margin: 11px 0 14px; font-size: 27px; }
  .rarity-card .price { font-size: 38px; }
  .rarity-price-box { padding-block: 12px; gap: 10px; }
  .rarity-card .plan-duration { margin: 9px 0 10px; font-size: 12px; }
  .rarity-card .plan-rate { margin: 8px 0 11px; }
  .rarity-economy strong { font-size: 15px; }
  .rarity-facts { padding-block: 10px; font-size: 11px; }
  .rarity-card .rarity-buy { font-size: 15px; min-height: 47px; }
  .legendary-advantage { font-size: 12px; }
  .rarity-card .plan-features { font-size: 13px; }
  .rarity-details { max-height: 180px; }
  .plans-toolbar p { font-size: 12px; }
}
@media (max-width: 350px) {
  .rarity-content { padding-inline: 17px; }
  .rarity-card .price { font-size: 33px; }
  .rarity-topline { gap: 5px; }
  .rarity-brand { font-size: 12px; }
  .rarity-label { font-size: 9px; }
  .rarity-card .discount-chip { font-size: 12px; }
  .rarity-card .rarity-name { font-size: 12px; }
  .rarity-facts { flex-wrap: wrap; gap: 7px; }
}
@media (prefers-reduced-motion: reduce) {
  .rarity-card *, .rarity-card.is-bursting .rarity-surface { animation: none !important; transition: none !important; }
  .rarity-card .rarity-buy:hover { transform: none; }
  .plan-particles { display: none; }
}
.effects-paused .frame-energy { animation-play-state: paused; }
/* Native subscription tab reuses the live cards without duplicating page navigation. */
.store-embedded .header, .store-embedded .footer, .store-embedded main > section:not(#plans), .store-embedded .skip-link { display: none; }
.store-embedded .plans-section { border: 0; padding-block: 22px 40px; }
.store-embedded .plans-section .section-heading { margin-bottom: 20px; }
.store-embedded .plans-section .section-heading h2 { font-size: 27px; }
.store-embedded .plans-section .section-heading p, .store-embedded .plans-section .section-heading .eyebrow { display: none; }
.store-embedded .plans-toolbar { display: none; }
.store-embedded .plan-selectors { margin-bottom: 0; }

.plan-selectors button[data-plan-theme=core][aria-pressed=true] { border-color: #b6becb; background: #282d35; }
.plan-selectors button[data-plan-theme=volt][aria-pressed=true] { border-color: #63c8ff; background: #132d41; }
.plan-selectors button[data-plan-theme=inferno][aria-pressed=true] { border-color: #ff9a37; background: #3a2013; }
.plan-selectors button[aria-pressed=true] small { color: #d3dae0; }
.rarity-legendary .rarity-price-box { background: repeating-linear-gradient(90deg, #a6ff3606 0 2px, transparent 2px 4px), linear-gradient(110deg, #a6ff3608, #a6ff3619, #a6ff3608); }
.rarity-legendary .price { font-family: ui-monospace, SFMono-Regular, Menlo, monospace; letter-spacing: -.075em; }
.store-embedded .plans-section .section-heading, .store-embedded .rarity-topline { display: none; }
.store-embedded .rarity-content { padding: 18px 18px 14px; }
.store-embedded .rarity-card h3 { font-size: 25px; line-height: 1.25; margin: 8px 0 13px; }
.store-embedded .rarity-price-box { padding-block: 10px; }
.store-embedded .rarity-card .price { font-size: 36px; }
.store-embedded .rarity-card .plan-duration { margin: 8px 0; }
.store-embedded .rarity-card .plan-rate { margin: 7px 0 9px; }
.store-embedded .rarity-facts { padding-block: 8px; }
.store-embedded .legendary-advantage { margin: 9px 0 3px; line-height: 1.5; }
.store-embedded .rarity-detail-toggle { margin-block: 6px 9px; padding-block: 2px; }
.store-embedded .rarity-card .plan-foot { margin-top: 9px; }
@media (max-width: 650px) {
  .plan-selectors button span { overflow-wrap: normal; }
  .plan-selectors button small { white-space: nowrap; }
}
@media (max-width: 350px) {
  .plan-selectors button span { font-size: 9px; letter-spacing: -.025em; }
  .plan-selectors button small { font-size: 10px; }
  .store-embedded .rarity-card .price { font-size: 32px; }
}
