/* ==========================================================================
   styles.css — one stylesheet for every page on the site.
   No framework, no build step, no webfont requests (uses system fonts so
   pages stay fast and free to host).
   ========================================================================== */

:root {
  --bg: #0b0f14;
  --bg-soft: #111823;
  --panel: #151d2a;
  --panel-2: #1b2534;
  --line: #26313f;
  --line-strong: #35455a;
  --text: #e8eef6;
  --text-dim: #9db0c6;
  --text-faint: #6d8199;
  --accent: #34d399;
  --accent-dim: #1f9c72;
  --accent-glow: rgba(52, 211, 153, 0.14);
  --danger: #f87171;
  --warn: #fbbf24;
  --radius: 14px;
  --radius-sm: 10px;
  --shadow: 0 1px 2px rgba(0, 0, 0, 0.3), 0 12px 32px -12px rgba(0, 0, 0, 0.6);
  --max: 1100px;
  --font: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica,
    Arial, sans-serif;
  --mono: ui-monospace, SFMono-Regular, "SF Mono", Menlo, Consolas, monospace;
}

* {
  box-sizing: border-box;
}

html {
  -webkit-text-size-adjust: 100%;
  scroll-behavior: smooth;
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: var(--font);
  font-size: 16px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

/* subtle top glow so the page doesn't read as a flat black slab */
body::before {
  content: "";
  position: fixed;
  inset: 0 0 auto 0;
  height: 420px;
  background: radial-gradient(
    900px 320px at 50% -80px,
    rgba(52, 211, 153, 0.1),
    transparent 70%
  );
  pointer-events: none;
  z-index: 0;
}

.wrap {
  width: 100%;
  max-width: var(--max);
  margin: 0 auto;
  padding: 0 20px;
  position: relative;
  z-index: 1;
}

/* ---------- header ---------- */

.site-header {
  border-bottom: 1px solid var(--line);
  background: rgba(11, 15, 20, 0.8);
  backdrop-filter: blur(12px);
  position: sticky;
  top: 0;
  z-index: 20;
}

.site-header .wrap {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  min-height: 62px;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  font-weight: 700;
  letter-spacing: -0.02em;
  color: var(--text);
  text-decoration: none;
  font-size: 17px;
  white-space: nowrap;
}

.brand-mark {
  width: 26px;
  height: 26px;
  border-radius: 8px;
  background: linear-gradient(140deg, var(--accent), #0ea5e9);
  display: grid;
  place-items: center;
  color: #04140f;
  font-size: 14px;
  font-weight: 800;
  flex: none;
}

.site-nav {
  display: flex;
  gap: 4px;
  flex-wrap: wrap;
  justify-content: flex-end;
}

.site-nav a {
  color: var(--text-dim);
  text-decoration: none;
  font-size: 13.5px;
  font-weight: 500;
  padding: 7px 11px;
  border-radius: 8px;
  transition: color 0.15s, background 0.15s;
}

.site-nav a:hover,
.site-nav a[aria-current="page"] {
  color: var(--text);
  background: var(--panel);
}

/* ---------- hero / typography ---------- */

.hero {
  padding: 56px 0 36px;
}

.kicker {
  display: inline-block;
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--accent);
  background: var(--accent-glow);
  border: 1px solid rgba(52, 211, 153, 0.25);
  padding: 4px 10px;
  border-radius: 999px;
  margin-bottom: 18px;
}

h1 {
  font-size: clamp(30px, 5vw, 46px);
  line-height: 1.1;
  letter-spacing: -0.03em;
  margin: 0 0 16px;
  font-weight: 700;
}

h2 {
  font-size: clamp(22px, 3vw, 28px);
  line-height: 1.2;
  letter-spacing: -0.02em;
  margin: 0 0 14px;
  font-weight: 650;
}

h3 {
  font-size: 17px;
  letter-spacing: -0.01em;
  margin: 0 0 8px;
  font-weight: 650;
}

p {
  margin: 0 0 14px;
}

.lede {
  font-size: 17.5px;
  color: var(--text-dim);
  max-width: 62ch;
}

.muted {
  color: var(--text-dim);
}

.faint {
  color: var(--text-faint);
  font-size: 13px;
}

a {
  color: var(--accent);
}

/* ---------- layout helpers ---------- */

.section {
  padding: 28px 0;
}

.grid-2 {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 20px;
}

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

.calc-layout {
  display: grid;
  grid-template-columns: minmax(0, 1.1fr) minmax(0, 0.9fr);
  gap: 22px;
  align-items: start;
}

/* ---------- cards & panels ---------- */

.card {
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 22px;
  box-shadow: var(--shadow);
}

.panel {
  background: linear-gradient(180deg, var(--panel-2), var(--panel));
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 22px;
}

.platform-card {
  display: block;
  text-decoration: none;
  color: inherit;
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 18px 20px;
  transition: border-color 0.16s, transform 0.16s, background 0.16s;
}

.platform-card:hover {
  border-color: var(--line-strong);
  background: var(--panel-2);
  transform: translateY(-2px);
}

.platform-card .pc-top {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 6px;
}

.platform-card strong {
  font-size: 16.5px;
  letter-spacing: -0.01em;
}

.platform-card .pc-rate {
  font-family: var(--mono);
  font-size: 12.5px;
  color: var(--accent);
  white-space: nowrap;
}

.platform-card p {
  margin: 0;
  font-size: 13.5px;
  color: var(--text-dim);
  line-height: 1.5;
}

/* ---------- form controls ---------- */

.field {
  margin-bottom: 16px;
}

.field:last-child {
  margin-bottom: 0;
}

.field label,
.field .field-label {
  display: block;
  font-size: 13px;
  font-weight: 600;
  color: var(--text-dim);
  margin-bottom: 6px;
  letter-spacing: 0.01em;
}

.input-wrap {
  position: relative;
  display: flex;
  align-items: center;
}

.input-wrap .prefix,
.input-wrap .suffix {
  position: absolute;
  color: var(--text-faint);
  font-size: 14px;
  pointer-events: none;
}

.input-wrap .prefix {
  left: 12px;
}

.input-wrap .suffix {
  right: 12px;
}

input[type="number"],
input[type="text"],
select {
  width: 100%;
  background: var(--bg-soft);
  border: 1px solid var(--line);
  color: var(--text);
  border-radius: var(--radius-sm);
  padding: 11px 12px;
  font-size: 15px;
  font-family: inherit;
  transition: border-color 0.15s, box-shadow 0.15s;
  -moz-appearance: textfield;
  appearance: none;
}

input[type="number"]::-webkit-outer-spin-button,
input[type="number"]::-webkit-inner-spin-button {
  -webkit-appearance: none;
  margin: 0;
}

.input-wrap.has-prefix input {
  padding-left: 26px;
}

.input-wrap.has-suffix input {
  padding-right: 34px;
}

input:focus,
select:focus {
  outline: none;
  border-color: var(--accent-dim);
  box-shadow: 0 0 0 3px var(--accent-glow);
}

select {
  background-image: linear-gradient(45deg, transparent 50%, var(--text-faint) 50%),
    linear-gradient(135deg, var(--text-faint) 50%, transparent 50%);
  background-position: calc(100% - 18px) 50%, calc(100% - 13px) 50%;
  background-size: 5px 5px, 5px 5px;
  background-repeat: no-repeat;
  padding-right: 34px;
  cursor: pointer;
}

.check {
  display: flex;
  align-items: flex-start;
  gap: 9px;
  cursor: pointer;
}

.check input {
  width: 17px;
  height: 17px;
  margin: 2px 0 0;
  accent-color: var(--accent);
  flex: none;
  cursor: pointer;
}

.check span {
  font-size: 13.5px;
  color: var(--text-dim);
  line-height: 1.45;
}

.help {
  font-size: 12.5px;
  color: var(--text-faint);
  margin: 6px 0 0;
  line-height: 1.45;
}

/* ---------- results ---------- */

.result-headline {
  text-align: center;
  padding: 6px 0 18px;
  border-bottom: 1px solid var(--line);
  margin-bottom: 16px;
}

.result-label {
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 0.09em;
  color: var(--text-faint);
  font-weight: 600;
  margin-bottom: 6px;
}

.result-value {
  font-size: clamp(34px, 6vw, 46px);
  font-weight: 700;
  letter-spacing: -0.035em;
  line-height: 1;
  font-variant-numeric: tabular-nums;
  color: var(--accent);
}

.result-value.is-negative {
  color: var(--danger);
}

.result-sub {
  margin-top: 8px;
  font-size: 13.5px;
  color: var(--text-dim);
}

.breakdown {
  list-style: none;
  margin: 0;
  padding: 0;
}

.breakdown li {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 14px;
  padding: 9px 0;
  border-bottom: 1px solid rgba(38, 49, 63, 0.6);
  font-size: 14px;
}

.breakdown li:last-child {
  border-bottom: none;
}

.breakdown .b-label {
  color: var(--text-dim);
}

.breakdown .b-detail {
  display: block;
  font-size: 11.5px;
  color: var(--text-faint);
  margin-top: 2px;
  line-height: 1.4;
}

.breakdown .b-amount {
  font-family: var(--mono);
  font-size: 13.5px;
  color: var(--text);
  white-space: nowrap;
  font-variant-numeric: tabular-nums;
}

.breakdown .total-row {
  border-top: 1px solid var(--line-strong);
  border-bottom: none;
  margin-top: 6px;
  padding-top: 12px;
  font-weight: 650;
  font-size: 15px;
}

.breakdown .total-row .b-label {
  color: var(--text);
}

/* rate bar: shows how much of the sale the platform keeps */
.rate-bar {
  height: 8px;
  border-radius: 999px;
  background: var(--bg-soft);
  overflow: hidden;
  margin: 16px 0 8px;
  border: 1px solid var(--line);
}

.rate-bar span {
  display: block;
  height: 100%;
  background: linear-gradient(90deg, var(--accent), #60a5fa);
  transition: width 0.25s ease;
  border-radius: 999px;
}

.rate-caption {
  display: flex;
  justify-content: space-between;
  font-size: 12px;
  color: var(--text-faint);
  font-family: var(--mono);
}

/* ---------- tables ---------- */

.table-scroll {
  overflow-x: auto;
  border: 1px solid var(--line);
  border-radius: var(--radius);
}

table {
  width: 100%;
  border-collapse: collapse;
  font-size: 14px;
  min-width: 520px;
}

th,
td {
  text-align: left;
  padding: 11px 14px;
  border-bottom: 1px solid var(--line);
  vertical-align: top;
}

th {
  background: var(--bg-soft);
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--text-faint);
  font-weight: 600;
  white-space: nowrap;
}

tbody tr:last-child td {
  border-bottom: none;
}

td.amount {
  font-family: var(--mono);
  font-size: 13px;
  white-space: nowrap;
  color: var(--accent);
}

/* ---------- misc blocks ---------- */

.note {
  border-left: 3px solid var(--warn);
  background: rgba(251, 191, 36, 0.06);
  padding: 12px 16px;
  border-radius: 0 var(--radius-sm) var(--radius-sm) 0;
  font-size: 13.5px;
  color: var(--text-dim);
  margin: 18px 0;
}

.note strong {
  color: var(--text);
}

.cta {
  background: linear-gradient(
    140deg,
    rgba(52, 211, 153, 0.09),
    rgba(96, 165, 250, 0.06)
  );
  border: 1px solid rgba(52, 211, 153, 0.24);
  border-radius: var(--radius);
  padding: 22px;
  margin: 26px 0;
}

.btn {
  display: inline-block;
  background: var(--accent);
  color: #04140f;
  font-weight: 700;
  font-size: 14.5px;
  text-decoration: none;
  padding: 11px 20px;
  border-radius: var(--radius-sm);
  border: none;
  cursor: pointer;
  transition: filter 0.15s, transform 0.15s;
}

.btn:hover {
  filter: brightness(1.08);
  transform: translateY(-1px);
}

.btn-ghost {
  background: transparent;
  color: var(--text);
  border: 1px solid var(--line-strong);
}

.faq details {
  border-bottom: 1px solid var(--line);
  padding: 14px 0;
}

.faq details:last-child {
  border-bottom: none;
}

.faq summary {
  cursor: pointer;
  font-weight: 600;
  font-size: 15px;
  list-style: none;
  display: flex;
  justify-content: space-between;
  gap: 14px;
}

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

.faq summary::after {
  content: "+";
  color: var(--accent);
  font-size: 19px;
  line-height: 1;
  flex: none;
}

.faq details[open] summary::after {
  content: "−";
}

.faq details p {
  margin: 10px 0 0;
  color: var(--text-dim);
  font-size: 14.5px;
}

.breadcrumb {
  font-size: 13px;
  color: var(--text-faint);
  padding: 18px 0 0;
}

.breadcrumb a {
  color: var(--text-faint);
  text-decoration: none;
}

.breadcrumb a:hover {
  color: var(--accent);
}

/* ---------- footer ---------- */

.site-footer {
  border-top: 1px solid var(--line);
  margin-top: 56px;
  padding: 32px 0 44px;
  color: var(--text-faint);
  font-size: 13px;
}

.site-footer .wrap {
  display: flex;
  flex-wrap: wrap;
  gap: 18px 32px;
  justify-content: space-between;
  align-items: flex-start;
}

.footer-links {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
}

.footer-links a {
  color: var(--text-dim);
  text-decoration: none;
}

.footer-links a:hover {
  color: var(--accent);
}

/* ---------- responsive ---------- */

@media (max-width: 860px) {
  .calc-layout,
  .grid-2,
  .grid-3 {
    grid-template-columns: 1fr;
  }

  .hero {
    padding: 36px 0 24px;
  }

  .site-header .wrap {
    min-height: 56px;
    flex-wrap: wrap;
    padding-top: 8px;
    padding-bottom: 8px;
  }

  .site-nav a {
    padding: 6px 8px;
    font-size: 12.5px;
  }

  .card,
  .panel {
    padding: 18px;
  }
}

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

  html {
    scroll-behavior: auto;
  }
}
