/* IELTS X — Price page (assets/css/pricing.css). Cards, compare table and the order dialog are drawn by assets/js/pricing.js
   from /api/plans, so what you set in the admin panel (Price control) is what the page shows.
   Colours come from the site tokens, so light and dark mode (html.dark-mode) follow the rest of the site. */
.ixp-section { padding: 0 16px 56px; }
.ixp-wrap { max-width: 1120px; margin: 0 auto; }
.ixp-bar { max-width: 760px; margin: 0 auto 18px; padding: 12px 16px; border-radius: 12px; text-align: center; background: #fef3c7; color: #78350f; font: 500 14px/1.4 system-ui, sans-serif; }
html.dark-mode .ixp-bar { background: #3b2f0b; color: #fde68a; }

/* current plan strip */
.ixp-me { display: flex; flex-wrap: wrap; align-items: center; justify-content: center; gap: 8px 14px; margin: 0 auto 22px; max-width: 640px; padding: 10px 16px; border-radius: 12px; border: 1px solid hsl(var(--border)); background: hsl(var(--muted)); font-size: 14px; }
.ixp-me b { font-weight: 650; }

/* toggles */
.ixp-controls { display: flex; flex-wrap: wrap; align-items: center; justify-content: center; gap: 14px; margin-bottom: 30px; }
.ixp-seg { display: inline-flex; gap: 4px; padding: 4px; border-radius: 14px; border: 1px solid hsl(var(--border)); background: hsl(var(--muted));; max-width: 100%; overflow-x: auto; scrollbar-width: none; }
.ixp-seg::-webkit-scrollbar { display: none; }
.ixp-seg button { display: inline-flex; align-items: center; gap: 8px; padding: 8px 16px; border: 0; border-radius: 10px; background: transparent; color: hsl(var(--muted-foreground)); font: 600 14px/1 system-ui, sans-serif; cursor: pointer; transition: background .15s, color .15s, box-shadow .15s; }
.ixp-seg button:hover { color: hsl(var(--foreground)); }
.ixp-seg button[aria-pressed="true"] { background: hsl(var(--background)); color: hsl(var(--foreground)); box-shadow: 0 1px 3px rgba(0, 0, 0, .18); }
.ixp-seg button:focus-visible, .ixp-cta:focus-visible, .ixp-opt:focus-visible { outline: 2px solid hsl(var(--primary)); outline-offset: 2px; }
.ixp-seg .ixp-off { padding: 2px 7px; border-radius: 999px; background: #dcfce7; color: #166534; font-size: 11px; font-weight: 700; }
html.dark-mode .ixp-seg .ixp-off { background: rgba(34, 197, 94, .18); color: #86efac; }

/* cards */
.ixp-grid { display: grid; gap: 22px; grid-template-columns: repeat(auto-fit, minmax(290px, 1fr)); align-items: stretch; }
.ixp-grid.n1 { max-width: 420px; margin: 0 auto; }
.ixp-grid.n2 { max-width: 800px; margin: 0 auto; }
.ixp-card { position: relative; display: flex; flex-direction: column; padding: 26px 24px 22px; border-radius: 20px; border: 2px solid hsl(var(--border)); background: hsl(var(--card)); color: hsl(var(--card-foreground)); box-shadow: 0 1px 3px rgba(0, 0, 0, .06); transition: transform .18s, box-shadow .18s; }
.ixp-card:hover { transform: translateY(-3px); box-shadow: 0 14px 32px rgba(0, 0, 0, .12); }
.ixp-card.rec { border-color: hsl(var(--primary)); box-shadow: 0 10px 30px hsl(var(--primary) / .18); }
.ixp-pills { display: flex; flex-wrap: wrap; gap: 6px; min-height: 26px; margin-bottom: 12px; }
.ixp-pill { display: inline-flex; align-items: center; padding: 3px 10px; border-radius: 8px; font-size: 11px; font-weight: 700; letter-spacing: .03em; text-transform: uppercase; background: hsl(var(--muted)); color: hsl(var(--muted-foreground)); }
.ixp-pill.hot { background: #fee2e2; color: #b91c1c; text-transform: none; letter-spacing: 0; }
html.dark-mode .ixp-pill.hot { background: rgba(239, 68, 68, .18); color: #fca5a5; }
.ixp-pill.rec { background: hsl(var(--primary)); color: hsl(var(--primary-foreground)); }
.ixp-name { margin: 0; font-size: 24px; font-weight: 750; letter-spacing: -.01em; }
.ixp-price { display: flex; align-items: baseline; gap: 6px; margin-top: 14px; }
.ixp-price strong { font-size: 36px; line-height: 1.1; font-weight: 800; font-variant-numeric: tabular-nums; }
.ixp-price span { color: hsl(var(--muted-foreground)); font-size: 14px; font-weight: 500; }
.ixp-sub { margin-top: 6px; min-height: 22px; display: flex; flex-wrap: wrap; align-items: center; gap: 4px 8px; font-size: 13px; color: hsl(var(--muted-foreground)); }
.ixp-sub s { opacity: .8; }
.ixp-sub b { color: hsl(var(--foreground)); font-weight: 650; }
.ixp-tests { margin-top: 14px; padding: 9px 12px; border-radius: 10px; background: hsl(var(--muted)); font-size: 13px; font-weight: 600; text-align: center; }
.ixp-cta { display: block; width: 100%; margin-top: 16px; padding: 12px 16px; border: 0; border-radius: 12px; background: hsl(var(--foreground)); color: hsl(var(--background)); font: 650 15px/1.2 system-ui, sans-serif; text-align: center; text-decoration: none; cursor: pointer; transition: opacity .15s, transform .1s; }
.ixp-card.rec .ixp-cta { background: hsl(var(--primary)); color: hsl(var(--primary-foreground)); }
.ixp-cta:hover { opacity: .9; } .ixp-cta:active { transform: scale(.99); }
.ixp-hr { height: 1px; margin: 20px 0 16px; background: hsl(var(--border)); }
.ixp-inc { margin: 0 0 10px; font-size: 13px; font-weight: 600; color: hsl(var(--muted-foreground)); }
.ixp-list { margin: 0; padding: 0; list-style: none; display: grid; gap: 9px; font-size: 14px; }
.ixp-list li { display: flex; gap: 10px; align-items: flex-start; line-height: 1.4; }
.ixp-list li::before { content: "✓"; flex: none; display: grid; place-items: center; width: 18px; height: 18px; margin-top: 1px; border-radius: 50%; background: hsl(var(--primary) / .14); color: hsl(var(--primary)); font-size: 11px; font-weight: 800; }

/* payment note */
.ixp-note { display: flex; align-items: center; gap: 12px; max-width: 760px; margin: 34px auto 0; padding: 14px 18px; border-radius: 14px; border: 1px solid hsl(var(--primary) / .3); background: hsl(var(--primary) / .08); font-size: 14px; }
.ixp-note a { font-weight: 650; color: hsl(var(--primary)); text-decoration: underline; }

/* compare */
.ixp-compare-h { margin: 0 0 6px; text-align: center; font-size: 30px; font-weight: 800; }
.ixp-compare-p { margin: 0 0 24px; text-align: center; color: hsl(var(--muted-foreground)); }
.ixp-table-wrap { overflow-x: auto; border-radius: 16px; border: 1px solid hsl(var(--border)); background: hsl(var(--card)); }
.ixp-table { width: 100%; min-width: 560px; border-collapse: collapse; font-size: 14px; }
.ixp-table th, .ixp-table td { padding: 12px 16px; text-align: center; border-bottom: 1px solid hsl(var(--border)); }
.ixp-table th:first-child, .ixp-table td:first-child { text-align: left; width: 38%; }
.ixp-table thead th { background: hsl(var(--muted)); font-size: 15px; }
.ixp-table tbody tr:last-child td { border-bottom: 0; }
.ixp-table tr.grp td { background: hsl(var(--muted) / .6); font-size: 12px; font-weight: 700; letter-spacing: .05em; text-transform: uppercase; color: hsl(var(--muted-foreground)); text-align: left; }
.ixp-yes { color: #16a34a; font-weight: 800; } .ixp-no { color: hsl(var(--muted-foreground)); opacity: .55; }
html.dark-mode .ixp-yes { color: #4ade80; }

/* loading / error */
.ixp-skel { display: grid; gap: 22px; grid-template-columns: repeat(auto-fit, minmax(290px, 1fr)); }
.ixp-skel i { display: block; height: 420px; border-radius: 20px; background: linear-gradient(90deg, hsl(var(--muted)) 25%, hsl(var(--muted) / .5) 50%, hsl(var(--muted)) 75%); background-size: 200% 100%; animation: ixp-sh 1.3s infinite; }
@keyframes ixp-sh { to { background-position: -200% 0; } }
.ixp-fail { padding: 40px 16px; text-align: center; color: hsl(var(--muted-foreground)); }
.ixp-fail button { margin-top: 12px; }
@media (prefers-reduced-motion: reduce) { .ixp-card, .ixp-cta { transition: none; } .ixp-skel i { animation: none; } }
@media (max-width: 520px) { .ixp-seg button { padding: 8px 11px; } .ixp-price strong { font-size: 32px; } .ixp-compare-h { font-size: 24px; } }

/* order dialog */
.ixp-ov { position: fixed; inset: 0; z-index: 99990; display: grid; place-items: center; padding: 16px; background: rgba(15, 23, 42, .6); backdrop-filter: blur(2px); }
.ixp-dlg { width: 100%; max-width: 440px; max-height: 92vh; overflow: auto; padding: 24px; border-radius: 18px; background: hsl(var(--card)); color: hsl(var(--card-foreground)); box-shadow: 0 25px 60px rgba(0, 0, 0, .35); font: 14px/1.5 system-ui, -apple-system, "Segoe UI", Roboto, sans-serif; }
.ixp-dlg h2 { margin: 0 0 4px; font-size: 20px; } .ixp-dlg p { margin: 0 0 14px; color: hsl(var(--muted-foreground)); }
.ixp-x { float: right; border: 0; background: none; color: inherit; font-size: 24px; line-height: 1; cursor: pointer; }
.ixp-row { display: grid; gap: 8px; margin-bottom: 14px; } .ixp-row.cols { grid-template-columns: repeat(auto-fit, minmax(110px, 1fr)); }
.ixp-opt { padding: 10px 12px; border: 1px solid hsl(var(--border)); border-radius: 12px; background: transparent; color: inherit; font: inherit; text-align: left; cursor: pointer; }
.ixp-opt[aria-pressed="true"] { border-color: hsl(var(--primary)); box-shadow: 0 0 0 2px hsl(var(--primary) / .25); }
.ixp-opt b { display: block; } .ixp-opt small { color: hsl(var(--muted-foreground)); }
.ixp-total { display: flex; justify-content: space-between; margin: 4px 0 6px; font-weight: 700; }
.ixp-facts { margin: 0 0 14px; font-size: 13px; color: hsl(var(--muted-foreground)); }
.ixp-btn { display: block; width: 100%; padding: 11px 14px; border: 0; border-radius: 12px; background: hsl(var(--foreground)); color: hsl(var(--background)); font: 600 14px system-ui, sans-serif; text-align: center; text-decoration: none; cursor: pointer; }
.ixp-btn.alt { margin-top: 8px; background: transparent; color: inherit; border: 1px solid hsl(var(--border)); }
.ixp-btn:disabled { opacity: .6; cursor: wait; }
.ixp-code { margin: 0 0 12px; padding: 12px; border-radius: 12px; background: hsl(var(--muted)); font: 700 24px ui-monospace, Menlo, Consolas, monospace; letter-spacing: .06em; text-align: center; }
.ixp-err { min-height: 0; margin: 0 0 10px; color: #dc2626; }

/* promo code (order window + the note above the plans) */
.ixp-promo { display: flex; gap: 8px; margin: 2px 0 6px; }
.ixp-promo-in { flex: 1; min-width: 0; height: 40px; padding: 0 12px; border-radius: 10px; border: 1px solid hsl(var(--border)); background: hsl(var(--background)); color: hsl(var(--foreground));
  font: 600 14px ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; letter-spacing: .04em; text-transform: uppercase; outline: none; }
.ixp-promo-in::placeholder { text-transform: none; letter-spacing: 0; font-family: system-ui, sans-serif; font-weight: 400; }
.ixp-promo-in:focus { border-color: hsl(var(--primary, 221 83% 53%)); box-shadow: 0 0 0 3px hsl(var(--primary, 221 83% 53%) / .18); }
.ixp-promo-in[readonly] { background: hsl(var(--muted)); }
.ixp-dlg .ixp-promo-btn { width: auto; margin: 0; padding: 0 16px; height: 40px; flex: none; }
.ixp-dlg .ixp-promo-msg { min-height: 18px; margin: 0 0 10px; font-size: 13px; font-weight: 600; color: #16a34a; }
.ixp-dlg .ixp-promo-msg.bad { color: #dc2626; }
.ixp-was { font-weight: 500; color: hsl(var(--muted-foreground)); }
.ixp-dlg .ixp-save { margin: -2px 0 6px; color: #16a34a; font-weight: 600; }
.ixp-promo-bar { background: linear-gradient(90deg, rgba(124, 58, 237, .12), rgba(37, 99, 235, .12)); color: hsl(var(--foreground)); border: 1px solid rgba(99, 102, 241, .3); }
.ixp-promo-code { font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; letter-spacing: .04em; padding: 1px 7px; border-radius: 6px; background: rgba(99, 102, 241, .16); }
