/* AIWA pricing v3 — QuillBot-inspired clean layout. Layered on aiwa-core.css. */
.pricing-page { min-height: 100vh; display: flex; flex-direction: column; background: #fff; }
.pricing-page main { flex: 1; }
.pricing-page h1, .pricing-page h2 { font-family: "Poppins", var(--aiwa-font, system-ui), sans-serif; }

/* ---- hero ---- */
.pricing-hero { padding: clamp(44px, 6vw, 72px) 0 34px; text-align: center; }
.pricing-hero-inner { width: min(860px, calc(100% - 32px)); margin: 0 auto; }
.pricing-hero-inner > * { animation: pr-rise 560ms cubic-bezier(0.22, 0.8, 0.3, 1) both; }
.pricing-hero-inner > *:nth-child(2) { animation-delay: 80ms; }
.pricing-hero-inner > *:nth-child(3) { animation-delay: 160ms; }
@keyframes pr-rise { from { opacity: 0; transform: translateY(14px); } to { opacity: 1; transform: none; } }
.pricing-hero h1 { margin: 0 0 12px; font-size: clamp(2rem, 4.6vw, 3.1rem); font-weight: 700; line-height: 1.1; letter-spacing: -0.03em; color: var(--aiwa-ink); }
.pricing-hero h1 em { font-style: normal; color: var(--aiwa-brand-dark); }
.pricing-hero > .pricing-hero-inner > p { max-width: 560px; margin: 0 auto; color: var(--aiwa-muted); font-size: 16.5px; line-height: 1.65; }

.ph-includes { margin-top: 30px; }
.ph-includes-label { display: block; margin-bottom: 14px; color: var(--aiwa-muted); font-size: 13px; font-weight: 650; }
.ph-tools { display: flex; justify-content: center; align-items: flex-start; flex-wrap: wrap; gap: 18px 22px; max-width: 620px; margin: 0 auto; padding: 0; list-style: none; }
.ph-tools li { display: flex; flex-direction: column; align-items: center; gap: 7px; width: 72px; color: var(--aiwa-text); font-size: 11px; font-weight: 650; line-height: 1.25; text-align: center; }
.ph-tools li i { display: grid; place-items: center; width: 40px; height: 40px; border-radius: 12px; background: var(--aiwa-brand-soft); transition: transform 160ms; }
.ph-tools li:hover i { transform: translateY(-2px); }
.ph-tools li img { width: 19px; height: 19px; filter: invert(35%) sepia(70%) saturate(680%) hue-rotate(97deg) brightness(91%); }

/* the "every new tool" tile that closes the hero strip — dashed, so it reads as
   a placeholder for something not built yet rather than another shipped tool */
.ph-tools li.ph-next { color: var(--aiwa-brand-dark); }
.ph-tools li.ph-next i { background: transparent; box-shadow: inset 0 0 0 1.5px var(--aiwa-brand); }
.ph-tools li.ph-next img { width: 15px; height: 15px; }

/* ---- plan cards ---- */
.plans { width: var(--aiwa-page); max-width: 1060px; margin: 18px auto 0; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 18px; align-items: stretch; }
.plan-card { position: relative; display: flex; flex-direction: column; padding: 26px 26px 24px; border: 1px solid #e2e8e3; border-radius: 16px; background: #fff; animation: pr-rise 600ms cubic-bezier(0.22, 0.8, 0.3, 1) both; transition: box-shadow 200ms, transform 200ms; }
.plan-card:nth-child(1) { animation-delay: 120ms; }
.plan-card:nth-child(2) { animation-delay: 190ms; }
.plan-card:nth-child(3) { animation-delay: 260ms; }
.plan-card:hover { box-shadow: 0 12px 32px rgba(15, 42, 26, 0.1); transform: translateY(-3px); }
.plan-card h2 { margin: 0 0 8px; font-size: 22px; font-weight: 700; letter-spacing: -0.015em; text-align: center; color: var(--aiwa-ink); }
.plan-sub { min-height: 40px; margin: 0 0 8px; color: var(--aiwa-muted); font-size: 13px; line-height: 1.55; text-align: center; }
.plan-price { display: flex; flex-direction: column; align-items: center; gap: 2px; margin: 6px 0 4px; text-align: center; }
.plan-price .pp-amount { display: flex; align-items: baseline; gap: 6px; }
.plan-price strong { font-size: 40px; font-weight: 780; letter-spacing: -0.04em; color: var(--aiwa-ink); }
.plan-price .pp-cur { color: var(--aiwa-muted); font-size: 13px; font-weight: 700; }
.plan-price .pp-was { color: var(--aiwa-muted); font-size: 15px; font-weight: 650; text-decoration: line-through; }
.plan-price .pp-per { color: var(--aiwa-muted); font-size: 12.5px; }
.plan-save { align-self: center; margin: 6px 0 2px; padding: 3px 10px; border-radius: 999px; background: var(--aiwa-brand-soft); color: var(--aiwa-brand-dark); font-size: 11.5px; font-weight: 800; letter-spacing: 0.02em; }

.plan-action { min-height: 46px; margin: 14px 0 4px; display: inline-flex; align-items: center; justify-content: center; gap: 8px; padding: 10px 16px; border: 1px solid #d6ded8; border-radius: 999px; background: #fff; color: var(--aiwa-ink); font: inherit; font-size: 14px; font-weight: 700; text-decoration: none; cursor: pointer; transition: border-color 150ms, background-color 150ms, box-shadow 150ms, transform 150ms; }
.plan-action:hover { border-color: #9bc7aa; background: var(--aiwa-brand-soft); transform: translateY(-1px); }
.plan-action.primary { border-color: var(--aiwa-brand); background: var(--aiwa-brand); color: #fff; }
.plan-action.primary:hover { border-color: var(--aiwa-brand-dark); background: var(--aiwa-brand-dark); box-shadow: 0 8px 22px rgba(19, 122, 61, 0.28); }
.plan-action:disabled { opacity: 0.7; cursor: wait; transform: none; }
.plan-alt { margin: 2px 0 0; border: 0; padding: 6px; background: transparent; color: var(--aiwa-muted); font: inherit; font-size: 12.5px; font-weight: 650; text-align: center; cursor: pointer; }
.plan-alt:hover { color: var(--aiwa-brand-dark); text-decoration: underline; text-underline-offset: 3px; }
.plan-alt:disabled { opacity: 0.7; cursor: wait; }

.plan-feat-label { margin: 16px 0 0; padding-top: 16px; border-top: 1px solid #edf1ee; color: var(--aiwa-ink); font-size: 13px; font-weight: 700; }
.plan-features { display: grid; gap: 10px; margin: 12px 0 0; padding: 0; list-style: none; }
.plan-features li { position: relative; padding-left: 26px; color: var(--aiwa-text); font-size: 13.5px; line-height: 1.5; }
.plan-features li::before { content: ""; position: absolute; left: 0; top: 1px; width: 18px; height: 18px; background: url("/assets/icons/bootstrap/check2.svg") center / 15px no-repeat; filter: invert(35%) sepia(70%) saturate(680%) hue-rotate(97deg) brightness(91%); }
.plan-features li b { font-weight: 700; }

/* pro card */
.plan-card.pro { border: 2px solid var(--aiwa-brand); padding-top: 56px; box-shadow: 0 10px 30px rgba(19, 122, 61, 0.12); }
.plan-card.pro:hover { box-shadow: 0 16px 40px rgba(19, 122, 61, 0.18); }
.plan-top { position: absolute; top: -2px; left: -2px; right: -2px; padding: 8px 10px; border-radius: 16px 16px 0 0; background: var(--aiwa-brand); color: #fff; font-size: 12.5px; font-weight: 750; letter-spacing: 0.03em; text-align: center; }
.plan-card.pro h2 { color: var(--aiwa-brand-dark); }

.plans-note { width: var(--aiwa-page); max-width: 1060px; margin: 14px auto 0; color: var(--aiwa-muted); font-size: 12px; text-align: center; }

.pricing-status { width: var(--aiwa-page); max-width: 640px; display: none; margin: 22px auto 0; padding: 13px 15px; border: 1px solid #e2e8e3; border-radius: 12px; background: #fff; color: var(--aiwa-text); font-size: 13px; text-align: center; box-shadow: 0 6px 18px rgba(15, 42, 26, 0.08); }
.pricing-status.show { display: block; animation: pr-rise 240ms ease both; }
.pricing-status.error { border-color: #efb8b4; background: #fff1f0; color: #8c1d18; }

/* ---- comparison table ---- */
.compare { width: var(--aiwa-page); max-width: 960px; margin: clamp(48px, 7vw, 76px) auto 0; }
.compare h2 { margin: 0 0 22px; font-size: clamp(1.5rem, 3vw, 2rem); font-weight: 700; letter-spacing: -0.02em; text-align: center; }
.compare-scroll { overflow-x: auto; border: 1px solid #e2e8e3; border-radius: 16px; }
.compare table { width: 100%; min-width: 640px; border-collapse: collapse; font-size: 13.5px; }
.compare th, .compare td { padding: 12px 16px; text-align: center; border-top: 1px solid #edf1ee; }
.compare thead th { border-top: 0; padding: 16px; background: #fafcfa; color: var(--aiwa-ink); font-size: 14px; font-weight: 750; }
.compare thead th:first-child { text-align: left; }
.compare th.pro-col, .compare td.pro-col { background: #f0f9f3; }
.compare thead th.pro-col { color: var(--aiwa-brand-dark); }
.compare tbody th { text-align: left; color: var(--aiwa-text); font-weight: 600; font-size: 13.5px; }
.compare tbody td { color: var(--aiwa-text); }
.compare tbody td b { font-weight: 750; color: var(--aiwa-ink); }
.compare .sec th { padding: 14px 16px 8px; background: #fff; color: var(--aiwa-brand-dark); font-size: 11.5px; font-weight: 800; letter-spacing: 0.06em; text-transform: uppercase; }
.compare .yes, .compare .no { display: inline-block; width: 18px; height: 18px; vertical-align: -4px; }
.compare .yes { background: url("/assets/icons/bootstrap/check2.svg") center / 16px no-repeat; filter: invert(35%) sepia(70%) saturate(680%) hue-rotate(97deg) brightness(91%); }
.compare .no { position: relative; }
.compare .no::before { content: "—"; color: #b9c4bc; font-weight: 600; }

/* ---- future-tools promise band -------------------------------------------
   Built entirely from theme tokens, so it needs no rules in aiwa-dark.css:
   --aiwa-brand-soft is mint on white in light and a green wash on #0f1512 in
   dark, and the point cards sit on --aiwa-card either way.
   The icon background lives on the <i> wrapper, never on the <img> — a filter
   on an img would repaint its own background too (the d16 trap).             */
.future-promise { width: var(--aiwa-page); max-width: 1060px; margin: clamp(46px, 7vw, 74px) auto 0; }
.fp-inner { padding: clamp(26px, 4vw, 42px) clamp(20px, 4vw, 42px); border-radius: 20px; background: var(--aiwa-brand-soft); text-align: center; }
.fp-kicker { display: inline-flex; align-items: center; gap: 7px; margin-bottom: 14px; padding: 5px 13px 5px 10px; border-radius: 999px; background: var(--aiwa-card); color: var(--aiwa-brand-dark); font-size: 11.5px; font-weight: 800; letter-spacing: 0.06em; text-transform: uppercase; }
.fp-kicker img { width: 14px; height: 14px; filter: invert(35%) sepia(70%) saturate(680%) hue-rotate(97deg) brightness(91%); }
.future-promise h2 { margin: 0 0 12px; font-size: clamp(1.45rem, 3vw, 2rem); font-weight: 700; line-height: 1.2; letter-spacing: -0.02em; color: var(--aiwa-ink); }
.fp-lead { max-width: 640px; margin: 0 auto; color: var(--aiwa-text); font-size: 15px; line-height: 1.7; }

.fp-points { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 14px; margin: clamp(22px, 3vw, 32px) 0 0; padding: 0; list-style: none; text-align: left; }
.fp-points li { display: grid; gap: 8px; padding: 20px 18px; border: 1px solid var(--aiwa-line); border-radius: 14px; background: var(--aiwa-card); }
.fp-points li i { display: grid; place-items: center; width: 38px; height: 38px; border-radius: 11px; background: var(--aiwa-brand-soft); }
.fp-points li img { width: 18px; height: 18px; filter: invert(35%) sepia(70%) saturate(680%) hue-rotate(97deg) brightness(91%); }
.fp-points li b { min-height: 39px; color: var(--aiwa-ink); font-size: 14.5px; font-weight: 700; line-height: 1.35; }
.fp-points li span { color: var(--aiwa-muted); font-size: 13px; line-height: 1.65; }

.fp-foot { max-width: 620px; margin: clamp(20px, 3vw, 28px) auto 0; color: var(--aiwa-muted); font-size: 13px; line-height: 1.65; }

html[data-theme="dark"] .fp-kicker img,
html[data-theme="dark"] .fp-points li img { filter: invert(72%) sepia(35%) saturate(620%) hue-rotate(93deg) brightness(98%); }
html[data-theme="dark"] .ph-tools li.ph-next img { filter: invert(72%) sepia(35%) saturate(620%) hue-rotate(93deg) brightness(98%); }

/* ---- faq ---- */
.pricing-faq { width: min(760px, calc(100% - 32px)); margin: clamp(48px, 7vw, 76px) auto 0; }
.pricing-faq h2 { margin: 0 0 20px; font-size: clamp(1.5rem, 3vw, 2rem); font-weight: 700; letter-spacing: -0.02em; text-align: center; }
.pricing-faq details { border: 1px solid #e2e8e3; border-radius: 14px; background: #fff; margin-bottom: 10px; overflow: hidden; transition: border-color 160ms, box-shadow 160ms; }
.pricing-faq details:hover { border-color: #c4d8ca; }
.pricing-faq details[open] { border-color: #9bc7aa; box-shadow: 0 6px 18px rgba(15, 42, 26, 0.06); }
.pricing-faq summary { display: flex; justify-content: space-between; align-items: center; gap: 12px; padding: 15px 17px; color: var(--aiwa-ink); font-size: 14.5px; font-weight: 700; cursor: pointer; list-style: none; }
.pricing-faq summary::-webkit-details-marker { display: none; }
.pricing-faq summary::after { content: ""; flex: 0 0 18px; width: 18px; height: 18px; background: url("/assets/icons/bootstrap/chevron-down.svg") center / 14px no-repeat; opacity: 0.55; transition: transform 220ms ease; }
.pricing-faq details[open] summary::after { transform: rotate(180deg); }
.pricing-faq details p { margin: 0; padding: 0 17px 15px; color: var(--aiwa-muted); font-size: 13.5px; line-height: 1.7; }

/* ---- cta band ---- */
.pricing-cta { margin: clamp(48px, 7vw, 76px) 0 0; padding: clamp(40px, 6vw, 60px) 16px; background: linear-gradient(150deg, #0d4527 0%, #137a3d 70%, #1a9b50 100%); text-align: center; }
.pricing-cta h2 { margin: 0 0 10px; color: #fff; font-size: clamp(1.6rem, 3.4vw, 2.3rem); font-weight: 700; letter-spacing: -0.02em; }
.pricing-cta p { max-width: 480px; margin: 0 auto 22px; color: rgba(255, 255, 255, 0.82); font-size: 15px; line-height: 1.6; }
.pricing-cta button { min-height: 48px; padding: 12px 30px; border: 0; border-radius: 999px; background: #fff; color: var(--aiwa-brand-dark); font: inherit; font-size: 15px; font-weight: 750; cursor: pointer; transition: transform 150ms, box-shadow 150ms; }
.pricing-cta button:hover { transform: translateY(-2px); box-shadow: 0 12px 30px rgba(0, 0, 0, 0.25); }
.pricing-cta button:disabled { opacity: 0.8; cursor: wait; transform: none; }

@media (max-width: 940px) {
  .plans { max-width: 560px; grid-template-columns: 1fr; }
  .fp-points { grid-template-columns: 1fr; }
  .fp-points li b { min-height: 0; }
  .plan-sub { min-height: 0; }
  .plan-card.pro { order: -1; }
}
@media (max-width: 480px) {
  .plan-card { padding: 22px 18px 20px; }
  .plan-card.pro { padding-top: 52px; }
  .ph-tools { gap: 14px 12px; }
  .ph-tools li { width: 64px; }
  .fp-inner { border-radius: 16px; }
  .fp-points li { padding: 16px 15px; }
}
@media (prefers-reduced-motion: reduce) {
  .pricing-hero-inner > *, .plan-card, .pricing-status.show { animation: none !important; }
  .plan-card, .plan-action, .ph-tools li i, .pricing-faq summary::after, .pricing-cta button { transition: none !important; }
}
