:root {
  color-scheme: light;
  --bg: #ffffff;
  --surface: #ffffff;
  --surface2: #f8fafc;
  --text: #0b1220;
  --muted: #475569;
  --border: #e2e8f0;
  --border2: #cbd5e1;
  --link: #0f172a;
  --primary: #4f46e5;
  --primaryHover: #4338ca;
  --danger: #e11d48;
  --shadow: 0 1px 2px rgba(2, 6, 23, 0.06), 0 8px 30px rgba(2, 6, 23, 0.06);
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  font-family: ui-sans-serif, system-ui, -apple-system, Segoe UI, Roboto, Arial, sans-serif;
  background: radial-gradient(900px 460px at 15% 0%, rgba(79, 70, 229, 0.07), transparent 65%),
    radial-gradient(900px 520px at 85% 5%, rgba(2, 132, 199, 0.06), transparent 60%), var(--bg);
  color: var(--text);
}

body[data-page="landing"] {
  background:
    radial-gradient(1100px 620px at 8% 2%, rgba(197, 112, 36, 0.12), transparent 58%),
    radial-gradient(960px 600px at 88% 0%, rgba(27, 64, 95, 0.12), transparent 52%),
    linear-gradient(180deg, #fcfaf6 0%, #f6f0e7 46%, #f8f5ef 100%);
  color: #1c1917;
  font-family: "Aptos", "Segoe UI", "Helvetica Neue", sans-serif;
}

a {
  color: var(--link);
  text-decoration: none;
}
a:hover {
  text-decoration: underline;
}

.wrap {
  max-width: 1040px;
  margin: 0 auto;
  padding: 28px 18px 56px;
}

.top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 22px;
}

.brand {
  display: inline-flex;
  align-items: center;
  font-weight: 700;
  letter-spacing: -0.2px;
  color: var(--text);
}

body[data-page="landing"] .brand {
  font-family: "Iowan Old Style", "Palatino Linotype", "Book Antiqua", Georgia, serif;
  font-size: 28px;
  letter-spacing: -0.6px;
  color: #221c15;
}

.pill {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 8px 12px;
  border: 1px solid var(--border);
  background: rgba(255, 255, 255, 0.72);
  border-radius: 999px;
  font-size: 13px;
  color: var(--muted);
}

body[data-page="landing"] .pill {
  border-color: rgba(28, 25, 23, 0.12);
  background: rgba(255, 250, 241, 0.76);
  backdrop-filter: blur(10px);
}

.grid {
  display: grid;
  grid-template-columns: repeat(12, 1fr);
  gap: 12px;
}

.card {
  grid-column: span 12;
  border: 1px solid var(--border);
  background: var(--surface);
  border-radius: 16px;
  padding: 16px;
  box-shadow: var(--shadow);
}

.card h2 {
  margin: 0 0 10px;
  font-size: 16px;
  letter-spacing: -0.2px;
}

.muted {
  color: var(--muted);
}
.small {
  font-size: 12.5px;
}

.row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding: 10px 0;
  border-top: 1px solid var(--border);
}
.row:first-of-type {
  border-top: 0;
}

.btns {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}

button {
  appearance: none;
  border: 1px solid var(--border);
  background: rgba(255, 255, 255, 0.9);
  color: var(--text);
  padding: 9px 12px;
  border-radius: 12px;
  cursor: pointer;
  font-size: 13px;
  line-height: 1.1;
}

button:hover {
  background: var(--surface2);
  border-color: var(--border2);
}

button.primary {
  border-color: rgba(79, 70, 229, 0.2);
  background: var(--primary);
  color: #fff;
}
button.primary:hover {
  background: var(--primaryHover);
  border-color: rgba(79, 70, 229, 0.35);
}

button.danger {
  border-color: rgba(225, 29, 72, 0.25);
  background: rgba(225, 29, 72, 0.08);
  color: var(--danger);
}
button:disabled {
  cursor: not-allowed;
  opacity: 0.55;
}
.full {
  width: 100%;
  justify-content: center;
}

.status {
  margin-top: 10px;
  font-size: 13px;
  color: var(--muted);
}
.status[data-kind="ok"] {
  color: #15803d;
}
.status[data-kind="error"] {
  color: #e11d48;
}

@media (min-width: 820px) {
  .card.span6 {
    grid-column: span 6;
  }
}

/* Landing */
body[data-page="landing"] .wrap {
  max-width: 1180px;
  padding-top: 24px;
}

body[data-page="landing"] .top {
  margin-bottom: 28px;
}

.landing-hero {
  display: grid;
  grid-template-columns: 1fr;
  gap: 24px;
  align-items: center;
  padding: 24px 0 8px;
}

.hero-copy {
  max-width: 640px;
}

.hero-kicker,
.section-kicker {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  text-transform: uppercase;
  letter-spacing: 0.16em;
  font-size: 11px;
  color: rgba(73, 58, 39, 0.84);
}

.hero-kicker::before,
.section-kicker::before {
  content: "";
  width: 24px;
  height: 1px;
  background: currentColor;
}

.landing-hero h1 {
  margin: 12px 0 0;
  font-family: "Iowan Old Style", "Palatino Linotype", "Book Antiqua", Georgia, serif;
  font-size: clamp(48px, 7vw, 84px);
  line-height: 0.96;
  letter-spacing: -0.05em;
  color: #221c15;
  text-wrap: balance;
}

.hero-subtitle {
  margin: 18px 0 0;
  max-width: 600px;
  color: rgba(60, 49, 35, 0.82);
  font-size: 18px;
  line-height: 1.7;
}

body[data-page="landing"] .hero-cta {
  margin-top: 22px;
}

body[data-page="landing"] button {
  border-radius: 999px;
  padding: 11px 16px;
  font-size: 13px;
}

body[data-page="landing"] button.primary {
  border-color: rgba(140, 66, 22, 0.2);
  background: #8b4520;
}

body[data-page="landing"] button.primary:hover {
  background: #733918;
  border-color: rgba(115, 57, 24, 0.32);
}

.hero-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 18px;
  color: rgba(73, 58, 39, 0.82);
  font-size: 12px;
}

.hero-meta span {
  display: inline-flex;
  align-items: center;
  min-height: 32px;
  padding: 0 12px;
  border: 1px solid rgba(34, 28, 21, 0.1);
  border-radius: 999px;
  background: rgba(255, 249, 239, 0.76);
}

.hero-stage {
  position: relative;
}

.transform-frame {
  position: relative;
  border: 1px solid rgba(34, 28, 21, 0.1);
  border-radius: 30px;
  padding: 28px 18px 18px;
  background:
    linear-gradient(145deg, rgba(255, 251, 245, 0.94), rgba(248, 242, 233, 0.96)),
    rgba(255, 255, 255, 0.7);
  box-shadow:
    0 1px 2px rgba(28, 25, 23, 0.06),
    0 18px 60px rgba(77, 53, 23, 0.12);
}

.transform-label {
  margin-bottom: 10px;
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.18em;
  color: rgba(101, 79, 50, 0.86);
}

.transform-label.right {
  margin-top: 14px;
}

.caption-paper {
  position: relative;
  padding: 18px;
  border-radius: 22px;
  border: 1px solid rgba(34, 28, 21, 0.1);
}

.caption-paper.is-raw {
  background:
    linear-gradient(180deg, rgba(255, 249, 238, 0.92), rgba(247, 240, 230, 0.96));
}

.caption-paper.is-clean {
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.92), rgba(247, 245, 241, 0.96));
}

.paper-title {
  margin-bottom: 12px;
  font-size: 12px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: rgba(79, 62, 39, 0.84);
}

.paper-line,
.caption-paper.is-clean p {
  font-family: "Iowan Old Style", "Palatino Linotype", "Book Antiqua", Georgia, serif;
  font-size: 18px;
  line-height: 1.55;
  color: rgba(40, 34, 27, 0.92);
}

.paper-line + .paper-line {
  margin-top: 6px;
}

.caption-paper.is-clean p {
  margin: 0;
}

.caption-paper.is-clean p + p {
  margin-top: 10px;
}

.transform-arrow {
  display: grid;
  place-items: center;
  width: 56px;
  height: 56px;
  margin: 14px auto;
  border-radius: 999px;
  border: 1px solid rgba(34, 28, 21, 0.1);
  background: rgba(255, 251, 244, 0.94);
  font-size: 24px;
  color: #8b4520;
}

.transform-notes {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 16px;
}

.transform-notes span {
  display: inline-flex;
  align-items: center;
  min-height: 34px;
  padding: 0 12px;
  border-radius: 999px;
  background: rgba(139, 69, 32, 0.08);
  color: #6a3319;
  font-size: 12px;
  border: 1px solid rgba(139, 69, 32, 0.12);
}

.landing-strip {
  display: grid;
  grid-template-columns: 1fr;
  gap: 12px;
  margin-top: 18px;
}

.strip-item {
  padding: 18px;
  border-radius: 20px;
  border: 1px solid rgba(34, 28, 21, 0.1);
  background: rgba(255, 251, 245, 0.8);
}

.strip-value {
  font-family: "Iowan Old Style", "Palatino Linotype", "Book Antiqua", Georgia, serif;
  font-size: 22px;
  letter-spacing: -0.03em;
  color: #231a12;
}

.strip-copy {
  margin-top: 8px;
  color: rgba(73, 58, 39, 0.86);
  line-height: 1.6;
  font-size: 14px;
}

.landing-section {
  margin-top: 44px;
}

.section-head {
  max-width: 760px;
  margin-bottom: 18px;
}

.section-head h2 {
  margin: 10px 0 0;
  font-family: "Iowan Old Style", "Palatino Linotype", "Book Antiqua", Georgia, serif;
  font-size: clamp(34px, 4vw, 56px);
  line-height: 1.02;
  letter-spacing: -0.04em;
  color: #221c15;
}

.section-head p {
  margin: 14px 0 0;
  color: rgba(60, 49, 35, 0.82);
  line-height: 1.7;
  font-size: 17px;
}

.section {
  margin-top: 26px;
}
.section h2 {
  margin: 0 0 12px;
  font-size: 16px;
  letter-spacing: -0.2px;
}
.feature-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 12px;
}
.feature {
  border: 1px solid var(--border);
  background: rgba(255, 255, 255, 0.72);
  border-radius: 16px;
  padding: 14px;
}
.feature-editorial {
  border-color: rgba(34, 28, 21, 0.08);
  background:
    linear-gradient(180deg, rgba(255, 252, 247, 0.84), rgba(246, 239, 229, 0.74));
  border-radius: 22px;
  padding: 18px;
}
.feature-index {
  font-size: 12px;
  letter-spacing: 0.18em;
  color: rgba(106, 71, 31, 0.8);
  text-transform: uppercase;
}
.feature-title {
  font-weight: 700;
  letter-spacing: -0.2px;
  margin-bottom: 6px;
}
.feature-editorial .feature-title {
  margin-top: 20px;
  font-family: "Iowan Old Style", "Palatino Linotype", "Book Antiqua", Georgia, serif;
  font-size: 28px;
  font-weight: 600;
  letter-spacing: -0.03em;
  color: #231a12;
}

.workflow-grid,
.detail-grid,
.faq-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 12px;
}

.workflow-step,
.detail-card,
.faq-card {
  border-radius: 22px;
  border: 1px solid rgba(34, 28, 21, 0.09);
  background: rgba(255, 252, 247, 0.8);
  padding: 18px;
}

.workflow-no {
  font-size: 13px;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: rgba(106, 71, 31, 0.8);
}

.workflow-title,
.detail-title,
.faq-q {
  margin-top: 18px;
  font-family: "Iowan Old Style", "Palatino Linotype", "Book Antiqua", Georgia, serif;
  font-size: 28px;
  letter-spacing: -0.03em;
  color: #231a12;
}

.workflow-step p,
.detail-card p,
.faq-a {
  margin: 10px 0 0;
  color: rgba(60, 49, 35, 0.84);
  line-height: 1.65;
  font-size: 15px;
}

.cta-card {
  border: 1px solid var(--border);
  background: var(--surface);
  border-radius: 16px;
  padding: 16px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  box-shadow: var(--shadow);
}
.cta-title {
  font-weight: 700;
  letter-spacing: -0.2px;
}

.cta-card-landing {
  border-color: rgba(34, 28, 21, 0.1);
  border-radius: 28px;
  padding: 20px;
  background:
    linear-gradient(145deg, rgba(255, 251, 245, 0.94), rgba(246, 238, 227, 0.98));
}

body[data-page="landing"] .cta-card-landing .cta-title {
  font-family: "Iowan Old Style", "Palatino Linotype", "Book Antiqua", Georgia, serif;
  font-size: 34px;
  line-height: 1.08;
  letter-spacing: -0.04em;
  color: #221c15;
}

body[data-page="landing"] .footer {
  margin-top: 48px;
  border-top-color: rgba(34, 28, 21, 0.1);
}

body[data-page="landing"] .footer-links a {
  color: rgba(54, 44, 32, 0.84);
}

.footer {
  margin-top: 34px;
  padding-top: 18px;
  border-top: 1px solid var(--border);
}
.footer-links {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
  margin-top: 8px;
}

.legal-card {
  max-width: 820px;
  border: 1px solid var(--border);
  background: var(--surface);
  border-radius: 18px;
  padding: 18px;
  box-shadow: var(--shadow);
}
.legal-card h1 {
  margin: 0 0 10px;
  font-size: 28px;
  letter-spacing: -0.5px;
}
.legal-card h2 {
  margin: 18px 0 8px;
  font-size: 17px;
  letter-spacing: -0.2px;
}
.legal-card p,
.legal-card li {
  color: var(--muted);
  line-height: 1.7;
  font-size: 14px;
}
.legal-card ul {
  margin: 8px 0 0;
  padding-left: 18px;
}
.legal-note {
  margin-top: 12px;
  padding: 12px 14px;
  border-radius: 14px;
  border: 1px solid rgba(2, 132, 199, 0.2);
  background: rgba(2, 132, 199, 0.06);
  color: #0f172a;
}

/* Pricing */
.page-head {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 12px;
  margin: 10px 0 18px;
}
.page-head h1 {
  margin: 0;
  font-size: 26px;
  letter-spacing: -0.4px;
}
body[data-page="pricing"] {
  background:
    radial-gradient(1200px 680px at 12% 0%, rgba(197, 112, 36, 0.1), transparent 56%),
    radial-gradient(900px 520px at 88% 0%, rgba(27, 64, 95, 0.1), transparent 52%),
    linear-gradient(180deg, #fcfaf6 0%, #f7f2ea 48%, #faf8f3 100%);
}
body[data-page="pricing"] .brand {
  font-family: "Iowan Old Style", "Palatino Linotype", "Book Antiqua", Georgia, serif;
  font-size: 28px;
  letter-spacing: -0.6px;
  color: #221c15;
}
body[data-page="pricing"] .pill {
  border-color: rgba(28, 25, 23, 0.12);
  background: rgba(255, 250, 241, 0.76);
  backdrop-filter: blur(10px);
}
.page-head-pricing {
  align-items: flex-start;
  margin-top: 20px;
  margin-bottom: 22px;
}
.pricing-intro {
  max-width: 720px;
}
body[data-page="pricing"] .page-head h1 {
  margin-top: 10px;
  font-family: "Iowan Old Style", "Palatino Linotype", "Book Antiqua", Georgia, serif;
  font-size: clamp(38px, 5vw, 62px);
  line-height: 1.02;
  letter-spacing: -0.04em;
  color: #221c15;
}
.pricing-copy {
  margin-top: 14px;
  line-height: 1.7;
  font-size: 17px;
  max-width: 640px;
}
.segmented {
  display: inline-flex;
  border: 1px solid var(--border);
  background: rgba(255, 255, 255, 0.72);
  border-radius: 999px;
  padding: 3px;
  gap: 3px;
}
.segmented-btn {
  border: 0;
  background: transparent;
  padding: 8px 12px;
  border-radius: 999px;
  font-size: 13px;
}
.segmented-btn.is-active {
  background: var(--surface);
  box-shadow: 0 1px 2px rgba(2, 6, 23, 0.08);
  border: 1px solid var(--border);
}
body[data-page="pricing"] .segmented {
  border-color: rgba(34, 28, 21, 0.12);
  background: rgba(255, 250, 241, 0.82);
}
body[data-page="pricing"] .segmented-btn {
  color: rgba(54, 44, 32, 0.88);
}
body[data-page="pricing"] .segmented-btn.is-active {
  background: rgba(255, 255, 255, 0.9);
  border-color: rgba(34, 28, 21, 0.1);
  box-shadow: 0 1px 2px rgba(28, 25, 23, 0.08);
}
.pricing-layout {
  display: grid;
  grid-template-columns: 1fr;
  gap: 16px;
}
.pricing-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 14px;
}
.plan-card {
  border: 1px solid rgba(34, 28, 21, 0.1);
  background:
    linear-gradient(180deg, rgba(255, 252, 247, 0.92), rgba(247, 242, 234, 0.96));
  border-radius: 24px;
  padding: 18px;
  box-shadow:
    0 1px 2px rgba(28, 25, 23, 0.06),
    0 16px 48px rgba(77, 53, 23, 0.08);
}
.plan-card.is-recommended {
  border-color: rgba(139, 69, 32, 0.34);
  box-shadow:
    0 0 0 2px rgba(139, 69, 32, 0.12),
    0 16px 48px rgba(77, 53, 23, 0.12);
}
.plan-card.is-disabled {
  opacity: 0.65;
}
.plan-tag {
  display: inline-flex;
  align-items: center;
  min-height: 24px;
  padding: 0 10px;
  border-radius: 999px;
  background: rgba(139, 69, 32, 0.08);
  border: 1px solid rgba(139, 69, 32, 0.14);
  color: #6a3319;
  font-size: 12px;
}
.plan-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}
.plan-name {
  font-family: "Iowan Old Style", "Palatino Linotype", "Book Antiqua", Georgia, serif;
  font-weight: 600;
  font-size: 30px;
  letter-spacing: -0.04em;
  color: #231a12;
}
.badge {
  display: inline-flex;
  align-items: center;
  height: 24px;
  padding: 0 10px;
  border-radius: 999px;
  border: 1px solid rgba(139, 69, 32, 0.2);
  background: rgba(139, 69, 32, 0.08);
  color: #8b4520;
  font-size: 12px;
}
.plan-price {
  margin-top: 10px;
  font-size: 42px;
  letter-spacing: -0.04em;
  display: flex;
  align-items: baseline;
  gap: 6px;
}
.plan-price .currency {
  font-size: 18px;
  color: var(--muted);
  letter-spacing: 0;
}
.plan-price .amount {
  font-weight: 800;
}
.plan-subcopy {
  margin-top: 2px;
  color: rgba(60, 49, 35, 0.82);
  font-size: 14px;
}
.plan-features {
  margin: 12px 0 14px;
  padding-left: 18px;
  color: rgba(60, 49, 35, 0.84);
  line-height: 1.7;
  font-size: 14px;
}
.plan-foot {
  margin-top: 10px;
  min-height: 16px;
}
.pricing-status {
  margin-top: 0;
}
.pricing-sidebar {
  display: grid;
  gap: 12px;
}
.pricing-note-card {
  border-radius: 22px;
  border: 1px solid rgba(34, 28, 21, 0.09);
  background: rgba(255, 252, 247, 0.8);
  padding: 18px;
}
.pricing-note-card-soft {
  background:
    linear-gradient(180deg, rgba(255, 249, 240, 0.9), rgba(247, 241, 232, 0.96));
}
.pricing-note-title {
  font-family: "Iowan Old Style", "Palatino Linotype", "Book Antiqua", Georgia, serif;
  font-size: 28px;
  letter-spacing: -0.03em;
  color: #231a12;
}
.pricing-note-list {
  margin: 12px 0 0;
  padding-left: 18px;
  color: rgba(60, 49, 35, 0.84);
  line-height: 1.7;
  font-size: 14px;
}
.pricing-cta-band {
  margin-top: 22px;
}
.cta-card-pricing {
  border-color: rgba(34, 28, 21, 0.1);
  border-radius: 28px;
  padding: 20px;
  background:
    linear-gradient(145deg, rgba(255, 251, 245, 0.94), rgba(246, 238, 227, 0.98));
}
body[data-page="pricing"] .cta-card-pricing .cta-title {
  font-family: "Iowan Old Style", "Palatino Linotype", "Book Antiqua", Georgia, serif;
  font-size: 32px;
  line-height: 1.08;
  letter-spacing: -0.04em;
  color: #221c15;
}
body[data-page="pricing"] button.primary {
  border-color: rgba(140, 66, 22, 0.2);
  background: #8b4520;
}
body[data-page="pricing"] button.primary:hover {
  background: #733918;
  border-color: rgba(115, 57, 24, 0.32);
}

@media (min-width: 860px) {
  .landing-hero {
    grid-template-columns: minmax(0, 1.02fr) minmax(0, 0.98fr);
    gap: 28px;
  }
  .landing-strip {
    grid-template-columns: repeat(3, 1fr);
  }
  .feature-grid {
    grid-template-columns: repeat(3, 1fr);
  }
  .workflow-grid {
    grid-template-columns: repeat(3, 1fr);
  }
  .detail-grid {
    grid-template-columns: repeat(3, 1fr);
  }
  .faq-grid {
    grid-template-columns: repeat(2, 1fr);
  }
  .pricing-layout {
    grid-template-columns: minmax(0, 1.2fr) minmax(300px, 0.8fr);
    align-items: start;
  }
  body[data-page="pricing"] .pricing-grid {
    grid-template-columns: repeat(2, 1fr);
  }
  .pricing-grid {
    grid-template-columns: repeat(3, 1fr);
  }
}
