.tacad-pricing {
--background: oklch(12% .01 270);
--foreground: oklch(98% 0 0);
--card: oklch(18% .02 270);
--primary: oklch(65% .22 210);
--secondary: oklch(60% .25 315);
--muted: oklch(22% .02 270);
--muted-foreground: oklch(65% .02 270);
--accent: oklch(65% .26 305);
--border: oklch(28% .03 270);
--input: oklch(22% .02 270);
--gradient-cyan: oklch(70% .2 195);
--gradient-blue: oklch(62% .23 230);
--gradient-purple: oklch(58% .26 280);
--gradient-pink: oklch(65% .26 305);
--radius: 0.5rem;
--gradient-main: linear-gradient(135deg, var(--gradient-cyan), var(--gradient-blue), var(--gradient-purple), var(--gradient-pink));
--gradient-short: linear-gradient(135deg, var(--gradient-cyan), var(--gradient-purple));
--glow-primary: oklch(65% .22 210 / .25);
--surface-hover: oklch(24% .03 270);
/* section-local */
--ac-font-display: inherit;
--ac-font-body: inherit;
--ac-num: ui-monospace, "SF Mono", "Roboto Mono", Menlo, monospace;
--ac-max: 1340px;
--ac-gutter: 24px;
--ac-inherited-opacity: .8;
/* rows carried up from a lower tier */
}

/* hex fallback for browsers without oklch */
@supports not (color: oklch(0% 0 0)) {
.tacad-pricing {
--background:#0a0a0f;
--foreground: #fafafa;
--card: #14141c;
--primary: #00a3e0;
--secondary: #c13cd8;
--muted: #1a1a22;
--muted-foreground: #9c9ca8;
--accent: #c93ff0;
--border: #23232e;
--gradient-cyan: #22bce0;
--gradient-blue: #2f7ff0;
--gradient-purple: #7c4ff0;
--gradient-pink: #c93ff0;
--glow-primary: rgba(0,163,224,.25);
--surface-hover: #1e1e29;
}
}

/* ---------- shell ---------- */
.tacad-pricing, .tacad-pricing * {
box-sizing: border-box;
}

.tacad-pricing {
background: transparent;
color: var(--foreground);
font-family: var(--ac-font-body);
padding: 96px 24px 72px;
position: relative;
overflow: hidden;
}

.tacad-pricing::before {
/* single ambient light source, top centre */
content: "";
position: absolute;
inset: -45% 0 auto 0;
height: 80%;
background: radial-gradient(46% 100% at 42% 0%, var(--glow-primary), transparent 68%), radial-gradient(38% 90% at 66% 4%, oklch(65% .26 305 / .16), transparent 70%);
pointer-events: none;
}

.tacad-inner {
max-width: var(--ac-max);
margin: 0 auto;
position: relative;
}

/* ---------- header ---------- */
.tacad-eyebrow {
font-size: 11px;
letter-spacing: .28em;
text-transform: uppercase;
font-weight: 600;
margin: 0 0 18px;
background: var(--gradient-short);
-webkit-background-clip: text;
background-clip: text;
color: transparent;
width: max-content;
}

.tacad-h2 {
font-family: var(--ac-font-display);
font-size: clamp(34px,5.4vw,60px);
line-height: 1.02;
letter-spacing: -.02em;
text-transform: uppercase;
font-weight: 800;
margin: 0 0 16px;
max-width: 16ch;
}

.tacad-h2 em {
font-style: italic;
font-weight: 400;
text-transform: none;
background: var(--gradient-main);
-webkit-background-clip: text;
background-clip: text;
color: transparent;
}

.tacad-sub {
color: var(--muted-foreground);
font-size: 17px;
line-height: 1.6;
max-width: 56ch;
margin: 0 0 40px;
}

/* ---------- single price block (desktop / tablet only) ---------- */
.tacad-price {
border-top: 1px solid var(--border);
padding-top: 20px;
margin-bottom: 22px;
}

.tacad-amount {
font-family: var(--ac-num);
font-size: clamp(30px,3vw,38px);
font-weight: 700;
letter-spacing: -.03em;
font-variant-numeric: tabular-nums;
line-height: 1;
display: block;
}

.tacad-billed {
font-size: 12.5px;
color: var(--muted-foreground);
margin-top: 9px;
display: block;
}

.tacad-rate {
margin-top: 14px;
display: flex;
flex-direction: column;
align-items: flex-start;
gap: 9px;
min-height: 18px;
}

/* ---------- grid ---------- */
.tacad-grid {
display: flex;
gap: 18px;
align-items: stretch;
overflow-x: auto;
scroll-snap-type: x mandatory;
margin: 0 calc(-1 * var(--ac-gutter));
padding: 18px var(--ac-gutter) 10px;
scrollbar-width: none;
-webkit-overflow-scrolling: touch;
}

.tacad-grid::-webkit-scrollbar {
display: none;
}

.tacad-card {
flex: 0 0 calc((100% - 36px) / 3);
scroll-snap-align: start;
}

@media(max-width: 1100px) {
.tacad-card {
flex-basis:calc((100% - 18px) / 2);
}
}

@media(max-width: 760px) {
.tacad-card {
flex-basis:86%;
}
}

/* ---------- carousel arrows ---------- */
.tacad-arrows {
display: flex;
justify-content: flex-end;
gap: 8px;
margin: 0 0 2px;
}

.tacad-arrow {
appearance: none;
cursor: pointer;
font: inherit;
line-height: 1;
width: 42px;
height: 42px;
border-radius: 999px;
display: inline-flex;
align-items: center;
justify-content: center;
font-size: 20px;
padding-bottom: 2px;
background: var(--muted);
color: var(--foreground);
border: 1px solid var(--border);
transition: background .18s ease, border-color .18s ease, opacity .18s ease;
}

.tacad-arrow:hover:not(:disabled) {
background: var(--gradient-short);
color: var(--background);
border-color: transparent;
}

.tacad-arrow:focus-visible {
outline: 2px solid var(--primary);
outline-offset: 3px;
}

.tacad-arrow:disabled {
opacity: .3;
cursor: default;
}

/* ---------- card ---------- */
.tacad-card {
display: flex;
flex-direction: column;
background: var(--card);
border: 1px solid var(--border);
border-radius: var(--radius);
padding: 30px 26px 26px;
position: relative;
transition: background .2s ease, border-color .2s ease, transform .2s ease, box-shadow .2s ease;
}

.tacad-card:hover {
background: var(--surface-hover);
border-color: var(--primary);
transform: translateY(-3px);
box-shadow: 0 18px 44px -22px var(--glow-primary);
}

/* featured: gradient hairline border via double background */
.tacad-card[data-featured="true"] {
border-color: transparent;
background: linear-gradient(var(--card), var(--card)) padding-box, var(--gradient-main) border-box;
box-shadow: 0 24px 60px -30px var(--glow-primary);
}

.tacad-card[data-featured="true"]:hover {
background: linear-gradient(var(--surface-hover), var(--surface-hover)) padding-box, var(--gradient-main) border-box;
}

.tacad-flag {
position: absolute;
top: -11px;
left: 26px;
background: var(--gradient-short);
color: var(--background);
font-size: 10px;
font-weight: 700;
letter-spacing: .16em;
text-transform: uppercase;
padding: 5px 11px;
border-radius: 999px;
}

.tacad-rank {
font-family: var(--ac-num);
font-size: 11px;
color: var(--muted-foreground);
opacity: .55;
letter-spacing: .1em;
margin: 0 0 12px;
}

.tacad-name {
font-family: var(--ac-font-display);
font-size: 19px;
font-weight: 700;
letter-spacing: .02em;
text-transform: uppercase;
margin: 0 0 6px;
}

.tacad-for {
font-size: 10.5px;
font-weight: 700;
letter-spacing: .14em;
text-transform: uppercase;
color: var(--foreground);
opacity: .85;
line-height: 1.5;
margin: 0 0 22px;
}

/* five across needs a little less of everything */
@media(min-width: 1281px) {
.tacad-card {
padding:26px 20px 22px;
}

.tacad-name {
font-size: 17px;
}

.tacad-amount {
font-size: clamp(26px,2vw,32px);
}
}

/* ---------- term rows: every price this tier sells, all on screen ---------- */
.tacad-terms {
display: flex;
flex-direction: column;
gap: 8px;
border-top: 1px solid var(--border);
padding-top: 20px;
margin: 0 0 22px;
}

.tacad-term {
appearance: none;
font: inherit;
text-align: left;
cursor: pointer;
width: 100%;
display: flex;
flex-direction: column;
gap: 7px;
background: var(--muted);
border: 1px solid var(--border);
border-radius: var(--radius);
padding: 12px 14px;
transition: border-color .18s ease, background .18s ease, box-shadow .18s ease;
}

.tacad-term:hover {
border-color: var(--primary);
}

.tacad-term:focus-visible {
outline: 2px solid var(--primary);
outline-offset: 2px;
}

.tacad-term[aria-checked="true"] {
border-color: transparent;
background: linear-gradient(var(--muted), var(--muted)) padding-box, var(--gradient-main) border-box;
box-shadow: 0 0 22px var(--glow-primary);
}

.tacad-term-name {
font-size: 10.5px;
font-weight: 700;
letter-spacing: .14em;
text-transform: uppercase;
color: var(--muted-foreground);
}

.tacad-term[aria-checked="true"] .tacad-term-name {
color: var(--foreground);
}

.tacad-term-price {
font-family: var(--ac-num);
font-size: 12px;
color: var(--muted-foreground);
font-variant-numeric: tabular-nums;
}

.tacad-term-price b {
font-size: 21px;
font-weight: 700;
letter-spacing: -.02em;
color: var(--foreground);
}

.tacad-term-sub {
display: block;
margin-top: 5px;
font-family: var(--ac-font-body);
font-size: 11.5px;
color: var(--muted-foreground);
}

.tacad-save {
font-size: 10px;
font-weight: 700;
letter-spacing: .04em;
background: var(--gradient-short);
color: var(--background);
border-radius: 999px;
padding: 4px 9px;
white-space: nowrap;
}

/* badges sit on the same baseline across a row, even when one cell has none */
.tacad-term .tacad-save {
align-self: flex-start;
margin-top: auto;
}

.tacad-card[hidden] {
display: none;
}

/* ---------- features ---------- */
.tacad-feats {
list-style: none;
margin: 0 0 28px;
padding: 0;
flex: 1 1 auto;
}

.tacad-feats li {
font-size: 14px;
line-height: 1.45;
color: var(--foreground);
padding: 9px 0 9px 24px;
position: relative;
border-bottom: 1px solid var(--border);
}

.tacad-feats li:last-child {
border-bottom: 0;
}

.tacad-feats li::before {
content: "\2713";
position: absolute;
left: 1px;
top: 9px;
font-size: 11px;
font-weight: 700;
color: var(--gradient-cyan);
}

/* rows this tier adds itself */
.tacad-feats li.tacad-own {
opacity: 1;
}

/* rows carried up from a lower tier — also tagged data-from="academy" etc.
so you can target a single tier's items if you ever need to */
.tacad-feats li.tacad-inherited {
opacity: var(--ac-inherited-opacity);
}

/* extra muting, only when the "Everything in X" dividers are switched on */
.tacad-pricing[data-grouped="true"] .tacad-feats li.tacad-inherited {
color: var(--muted-foreground);
}

.tacad-pricing[data-grouped="true"] .tacad-feats li.tacad-inherited::before {
background: var(--muted-foreground);
opacity: .5;
width: 6px;
}

/* "Everything in X" divider inside the list */
.tacad-feats li.tacad-fgroup {
border-bottom: 0;
padding: 20px 0 8px;
font-size: 10.5px;
font-weight: 700;
letter-spacing: .14em;
text-transform: uppercase;
color: var(--muted-foreground);
opacity: .75;
}

.tacad-feats li.tacad-fgroup::before {
display: none;
}

.tacad-feats li.tacad-fgroup span {
display: block;
border-top: 1px solid var(--border);
padding-top: 16px;
}

/* as the lead-in line it needs no rule above it */
.tacad-feats li.tacad-fgroup:first-child {
padding: 0 0 12px;
opacity: .9;
}

.tacad-feats li.tacad-fgroup:first-child span {
border-top: 0;
padding-top: 0;
}

/* ---------- highlight strip + button footnote ---------- */
.tacad-highlight {
margin: 0 0 14px;
padding: 10px 12px;
border-radius: var(--radius);
background: var(--muted);
border: 1px solid var(--border);
font-size: 11.5px;
font-weight: 600;
letter-spacing: .04em;
color: var(--foreground);
text-align: center;
}

.tacad-ctanote {
margin: 11px 0 0;
text-align: center;
font-size: 10.5px;
letter-spacing: .03em;
color: var(--muted-foreground);
opacity: .75;
}

/* ---------- plan-length popup ---------- */
.tacad-modal[hidden] {
display: none;
}

.tacad-modal {
position: fixed;
inset: 0;
z-index: 9999;
display: flex;
align-items: center;
justify-content: center;
padding: 24px;
}

.tacad-modal-bg {
position: absolute;
inset: 0;
background: rgba(0,0,0,.72);
backdrop-filter: blur(3px);
}

.tacad-modal-card {
position: relative;
width: 100%;
max-width: 520px;
max-height: calc(100vh - 48px);
overflow-y: auto;
background: var(--card);
border: 1px solid var(--border);
border-radius: calc(var(--radius) + 4px);
padding: 32px 30px 26px;
box-shadow: 0 40px 90px -30px rgba(0,0,0,.8);
}

.tacad-modal-x {
position: absolute;
top: 14px;
right: 14px;
appearance: none;
cursor: pointer;
width: 34px;
height: 34px;
border-radius: 999px;
font-size: 20px;
line-height: 1;
background: var(--muted);
color: var(--muted-foreground);
border: 1px solid var(--border);
}

.tacad-modal-x:hover {
color: var(--foreground);
}

.tacad-modal-eyebrow {
margin: 0 0 8px;
font-size: 10.5px;
font-weight: 700;
letter-spacing: .2em;
text-transform: uppercase;
color: var(--muted-foreground);
}

.tacad-modal-title {
margin: 0 0 22px;
font-family: var(--ac-font-display);
font-size: 26px;
font-weight: 800;
letter-spacing: -.01em;
text-transform: uppercase;
}

.tacad-modal-opts {
display: grid;
grid-template-columns: 1fr 1fr;
gap: 10px;
}

.tacad-modal-opts > .tacad-term:last-child:nth-child(odd) {
grid-column: 1 / -1;
}

.tacad-modal-note {
margin: 20px 0 0;
font-size: 11.5px;
line-height: 1.6;
color: var(--muted-foreground);
opacity: .75;
}

.tacad-term-head {
display: flex;
align-items: center;
justify-content: space-between;
gap: 10px;
}

.tacad-term {
text-decoration: none;
}

.tacad-term .tacad-save {
margin-top: 0;
align-self: auto;
}

.tacad-hint {
font-size: 11.5px;
font-weight: 600;
letter-spacing: .02em;
background: var(--gradient-short);
-webkit-background-clip: text;
background-clip: text;
color: transparent;
}

/* ---------- cta ---------- */
.tacad-cta {
display: block;
text-align: center;
text-decoration: none;
font-size: 14px;
font-weight: 700;
letter-spacing: .08em;
text-transform: uppercase;
padding: 16px 18px;
border-radius: 999px;
border: 1px solid var(--border);
color: var(--foreground);
background: transparent;
transition: background .2s ease, color .2s ease, border-color .2s ease, box-shadow .2s ease;
}

.tacad-cta:hover {
background: var(--gradient-short);
border-color: transparent;
color: var(--background);
box-shadow: 0 0 26px var(--glow-primary);
}

.tacad-card[data-featured="true"] .tacad-cta {
background: var(--gradient-main);
border-color: transparent;
color: var(--background);
box-shadow: 0 0 26px var(--glow-primary);
}

.tacad-card[data-featured="true"] .tacad-cta:hover {
filter: brightness(1.12);
}

/* ---------- standalone course library ---------- */
.tacad-library {
margin-top: 56px;
background: var(--card);
border: 1px solid var(--border);
border-radius: var(--radius);
padding: 40px 36px 34px;
}

.tacad-library[hidden] {
display: none;
}

.tacad-library-eyebrow {
font-size: 10.5px;
letter-spacing: .2em;
text-transform: uppercase;
font-weight: 700;
color: var(--muted-foreground);
opacity: .7;
margin: 0 0 10px;
}

.tacad-library-title {
font-family: var(--ac-font-display);
font-size: clamp(20px,2.4vw,27px);
font-weight: 700;
letter-spacing: -.01em;
margin: 0 0 26px;
}

.tacad-library ul {
list-style: none;
margin: 0;
padding: 0;
columns: 4;
column-gap: 32px;
}

@media(max-width: 1120px) {
.tacad-library ul {
columns:3;
}
}

@media(max-width: 760px) {
.tacad-library ul {
columns:2;
}
}

@media(max-width: 480px) {
.tacad-library ul {
columns:1;
}
}

.tacad-library li {
font-size: 14px;
line-height: 1.45;
color: var(--foreground);
padding: 10px 0 10px 18px;
position: relative;
break-inside: avoid;
border-bottom: 1px solid var(--border);
}

.tacad-library li::before {
content: "";
position: absolute;
left: 0;
top: 17px;
width: 5px;
height: 5px;
border-radius: 50%;
background: var(--gradient-short);
}

/* ---------- footer note ---------- */
.tacad-fine {
margin: 40px auto 0;
max-width: 70ch;
text-align: center;
font-size: 13px;
line-height: 1.7;
color: var(--muted-foreground);
opacity: .8;
}

.tacad-fine a {
color: var(--primary);
}

/* ---------- shared course library (identical on every tier) ---------- */
.tacad-courses {
border-top: 1px solid var(--border);
margin-top: 26px;
padding-top: 20px;
}

.tacad-courses summary {
list-style: none;
cursor: default;
display: flex;
align-items: center;
justify-content: space-between;
gap: 12px;
}

.tacad-courses summary::-webkit-details-marker {
display: none;
}

.tacad-courses-h {
font-size: 11px;
letter-spacing: .14em;
text-transform: uppercase;
font-weight: 700;
color: var(--muted-foreground);
line-height: 1.55;
}

.tacad-count {
display: none;
}

.tacad-courses ul {
list-style: none;
margin: 14px 0 0;
padding: 0;
}

@media(max-width: 1120px) {
.tacad-courses ul {
columns:2;
column-gap: 24px;
}
}

@media(max-width: 480px) {
.tacad-courses ul {
columns:1;
}
}

.tacad-courses li {
font-size: 12.5px;
line-height: 1.5;
color: var(--muted-foreground);
padding: 5px 0 5px 15px;
position: relative;
break-inside: avoid;
}

.tacad-courses li::before {
content: "";
position: absolute;
left: 0;
top: 11px;
width: 4px;
height: 4px;
border-radius: 50%;
background: var(--primary);
opacity: .55;
}

/* ---------- mobile ---------- */
@media(max-width: 767px) {
/* course list collapses behind a tap target so cards stay scrollable */ .tacad-courses summary {
cursor:pointer;
padding: 4px 0;
}

.tacad-count {
display: inline-flex;
flex: 0 0 auto;
font-family: var(--ac-num);
font-size: 11px;
font-weight: 700;
color: var(--background);
background: var(--gradient-short);
border-radius: 999px;
padding: 4px 10px;
}

.tacad-count::after {
content: " \25BE";
}

.tacad-courses details[open] .tacad-count::after, details[open] > summary .tacad-count::after {
content: " \25B4";
}

.tacad-courses summary:focus-visible {
outline: 2px solid var(--primary);
outline-offset: 4px;
}
}

@media(max-width: 640px) {
.tacad-pricing {
padding:60px 16px 56px;
--ac-gutter: 16px;
}

.tacad-grid {
gap: 14px;
}

.tacad-card {
padding: 24px 20px 22px;
}

.tacad-for {
min-height: 0;
margin-bottom: 18px;
}

.tacad-sub {
font-size: 15.5px;
margin-bottom: 30px;
}

.tacad-feats {
margin-bottom: 22px;
}

.tacad-courses {
margin-top: 20px;
padding-top: 16px;
}

.tacad-library {
padding: 28px 20px 22px;
}

.tacad-fine {
margin-top: 30px;
}
}

@media(max-width: 640px) {
.tacad-cta {
padding:17px 18px;
}

.tacad-modal {
padding: 16px;
}

.tacad-modal-card {
padding: 26px 20px 22px;
}

.tacad-modal-opts {
grid-template-columns: 1fr;
}

.tacad-modal-title {
font-size: 22px;
}
}

@media(prefers-reduced-motion:reduce) {
.tacad-pricing * {
animation: none !important;
transition: none !important;
}

.tacad-card:hover {
transform: none;
}
}