/* styles.css */

/* -----------------------------
   Base + tokens
------------------------------ */
:root{
  --bg: #fbfaf7;
  --panel: #ffffff;
  --panel-2: #f7f4ef;

  --ink: #1f2937;
  --muted: rgba(31,41,55,.72);
  --faint: rgba(31,41,55,.10);
  --border: #d6d3cc;

  --teal: #2a9d8f;
  --coral: #e76f51;
  --mustard: #f4a261;
  --periwinkle: #6d77d8;

  --radius-lg: 22px;
  --radius-md: 16px;
  --radius-sm: 12px;

  --shadow: 0 14px 34px rgba(31,41,55,.10);
  --shadow-soft: 0 10px 24px rgba(31,41,55,.08);

  --max: 1120px;

  --step--1: clamp(.90rem, .86rem + .2vw, .98rem);
  --step-0: clamp(1.00rem, .95rem + .25vw, 1.10rem);
  --step-1: clamp(1.15rem, 1.05rem + .55vw, 1.45rem);
  --step-2: clamp(1.45rem, 1.25rem + .9vw, 2.05rem);
  --step-3: clamp(1.85rem, 1.55rem + 1.35vw, 2.75rem);

  --lh: 1.55;
}

*,
*::before,
*::after{ box-sizing: border-box; }

html, body{ height: 100%; }

body{
  margin: 0;
  font-family: ui-sans-serif, system-ui, -apple-system, Segoe UI, Roboto, Helvetica, Arial, "Apple Color Emoji", "Segoe UI Emoji";
  color: var(--ink);
  background: radial-gradient(1200px 600px at 20% 0%, rgba(42,157,143,.08), transparent 55%),
              radial-gradient(900px 540px at 90% 10%, rgba(109,119,216,.08), transparent 50%),
              radial-gradient(1000px 700px at 50% 80%, rgba(231,111,81,.07), transparent 55%),
              var(--bg);
  line-height: var(--lh);
}

img{
  max-width: 100%;
  height: auto;
  display: block;
}

a{ color: inherit; }

/* -----------------------------
   Accessibility
------------------------------ */
.skip-link{
  position: absolute;
  top: 12px;
  left: 12px;
  background: var(--panel);
  color: var(--ink);
  border: 2px solid var(--border);
  padding: 10px 12px;
  border-radius: 12px;
  transform: translateY(-160%);
  transition: transform .2s ease;
  z-index: 50;
  box-shadow: var(--shadow-soft);
}
.skip-link:focus{
  transform: translateY(0);
  outline: none;
}

/* -----------------------------
   Layout primitives
------------------------------ */
.page-header,
.page-main,
.page-footer{
  width: min(var(--max), calc(100% - 32px));
  margin-inline: auto;
}

.page-header{
  padding: 28px 0 10px;
}

.page-main{
  padding: 18px 0 42px;
}

.section{
  margin-top: 26px;
}

.section-head{
  margin-bottom: 14px;
}

.section-head h2{
  margin: 0 0 6px;
  font-size: var(--step-2);
  letter-spacing: -0.015em;
}
.section-kicker{
  margin: 0;
  color: var(--muted);
  font-size: var(--step-0);
}

/* -----------------------------
   Header / Hook
------------------------------ */
.header-inner{
  display: grid;
  grid-template-columns: 1fr;
  gap: 16px;
  align-items: start;
  padding: 18px;
  border-radius: var(--radius-lg);
  border: 1.6px solid var(--border);
  background:
    linear-gradient(180deg, rgba(255,255,255,.92), rgba(247,244,239,.92));
  box-shadow: var(--shadow);
}

.headline h1{
  margin: 0 0 10px;
  font-size: var(--step-3);
  line-height: 1.12;
  letter-spacing: -0.02em;
}
.subhead{
  margin: 0 0 12px;
  font-size: var(--step-1);
  color: var(--muted);
}
.deck{
  margin: 0;
  padding: 12px 14px;
  border-radius: var(--radius-md);
  border: 1px solid var(--border);
  background: rgba(255,255,255,.70);
  color: rgba(31,41,55,.88);
  font-size: var(--step-0);
}

.hero{
  margin: 0;
  border-radius: var(--radius-lg);
  overflow: hidden;
  border: 1.6px solid var(--border);
  background: var(--panel);
  box-shadow: var(--shadow-soft);
}
.hero img{
  aspect-ratio: 16 / 9;
  object-fit: cover;
}

/* Invoice hook card */
.invoice-hook{
  margin-top: 14px;
}
.invoice-card{
  border-radius: var(--radius-lg);
  border: 1.6px solid var(--border);
  background: linear-gradient(180deg, rgba(255,255,255,.94), rgba(247,244,239,.94));
  box-shadow: var(--shadow-soft);
  overflow: hidden;
}
.invoice-meta{
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
  padding: 14px 14px 10px;
}
.meta-block{
  padding: 10px 12px;
  border-radius: var(--radius-md);
  border: 1px solid var(--border);
  background: rgba(255,255,255,.70);
}
.meta-label{
  font-size: .80rem;
  color: rgba(31,41,55,.62);
  letter-spacing: .02em;
  text-transform: uppercase;
}
.meta-value{
  font-size: var(--step-0);
  font-weight: 650;
}
.invoice-visual{
  padding: 10px 12px 14px;
}

/* -----------------------------
   Pricing table (plans)
------------------------------ */
.pricing-grid{
  display: grid;
  grid-template-columns: 1fr;
  gap: 14px;
}

.plan{
  position: relative;
  border-radius: var(--radius-lg);
  border: 1.6px solid var(--border);
  background: linear-gradient(180deg, rgba(255,255,255,.92), rgba(247,244,239,.92));
  box-shadow: var(--shadow-soft);
  overflow: hidden;
  padding: 16px;
}

.plan-head h3{
  margin: 6px 0 6px;
  font-size: var(--step-1);
  letter-spacing: -0.01em;
}
.plan-desc{
  margin: 0 0 12px;
  color: var(--muted);
  font-size: var(--step--1);
}

.plan-badge{
  width: 40px;
  height: 40px;
  display: grid;
  place-items: center;
  border-radius: 14px;
  border: 1px solid var(--border);
  background: rgba(255,255,255,.70);
  box-shadow: 0 6px 14px rgba(31,41,55,.08);
}

.price{
  display: flex;
  align-items: baseline;
  gap: 10px;
  margin: 10px 0 12px;
  padding: 12px 12px;
  border-radius: var(--radius-md);
  border: 1px solid var(--border);
  background: rgba(255,255,255,.72);
}
.price-amount{
  font-size: clamp(1.65rem, 1.45rem + 1vw, 2.15rem);
  font-weight: 800;
  letter-spacing: -0.02em;
}
.currency{
  font-size: .95em;
  margin-right: 2px;
  opacity: .9;
}
.price-unit{
  font-size: var(--step--1);
  color: rgba(31,41,55,.75);
}
.muted{ color: rgba(31,41,55,.62); }

.features{
  list-style: none;
  padding: 0;
  margin: 0;
  display: grid;
  gap: 10px;
}
.features li{
  padding: 10px 12px;
  border-radius: var(--radius-md);
  border: 1px solid var(--border);
  background: rgba(255,255,255,.64);
  color: rgba(31,41,55,.90);
}
.features strong{
  font-weight: 800;
}

.fineprint{
  margin: 12px 0 0;
  padding-top: 10px;
  border-top: 1px dashed rgba(31,41,55,.18);
  color: rgba(31,41,55,.72);
  font-size: var(--step--1);
}

/* Plan accents */
.plan-basic{
  background:
    radial-gradient(760px 240px at 30% 0%, rgba(42,157,143,.10), transparent 60%),
    linear-gradient(180deg, rgba(255,255,255,.92), rgba(247,244,239,.92));
}
.plan-pro{
  background:
    radial-gradient(760px 240px at 30% 0%, rgba(244,162,97,.16), transparent 60%),
    linear-gradient(180deg, rgba(255,255,255,.92), rgba(247,244,239,.92));
}
.plan-enterprise{
  background:
    radial-gradient(760px 240px at 30% 0%, rgba(231,111,81,.14), transparent 60%),
    linear-gradient(180deg, rgba(255,255,255,.92), rgba(247,244,239,.92));
}

/* Featured column */
.featured{
  border-color: rgba(244,162,97,.80);
  box-shadow: 0 18px 44px rgba(31,41,55,.14);
  transform: translateY(-2px);
}
.top-ribbon{
  position: absolute;
  top: 12px;
  right: 12px;
  background: rgba(244,162,97,.18);
  border: 1px solid rgba(244,162,97,.70);
  color: rgba(31,41,55,.85);
  padding: 8px 10px;
  border-radius: 999px;
  font-size: .82rem;
  font-weight: 750;
}

/* -----------------------------
   Real costs section
------------------------------ */
.cost-grid{
  display: grid;
  grid-template-columns: 1fr;
  gap: 14px;
}
.cost-card{
  border-radius: var(--radius-lg);
  border: 1.6px solid var(--border);
  background: linear-gradient(180deg, rgba(255,255,255,.92), rgba(247,244,239,.92));
  box-shadow: var(--shadow-soft);
  overflow: hidden;
  padding: 16px;
}
.cost-head h3{
  margin: 0 0 8px;
  font-size: var(--step-1);
  letter-spacing: -0.01em;
}
.cost-summary{
  margin: 0 0 12px;
  color: rgba(31,41,55,.84);
  font-size: var(--step-0);
}
.cost-visual{
  border-radius: var(--radius-md);
  border: 1px solid var(--border);
  background: rgba(255,255,255,.72);
  padding: 10px;
}
.takeaway{
  margin: 12px 0 0;
  color: rgba(31,41,55,.80);
  font-size: var(--step--1);
}

/* -----------------------------
   Cancel section
------------------------------ */
.cancel-grid{
  display: grid;
  grid-template-columns: 1fr;
  gap: 14px;
  align-items: start;
}

.cancel-steps{
  border-radius: var(--radius-lg);
  border: 1.6px solid var(--border);
  background: linear-gradient(180deg, rgba(255,255,255,.92), rgba(247,244,239,.92));
  box-shadow: var(--shadow-soft);
  padding: 16px;
}

.steps{
  margin: 0;
  padding-left: 18px;
  display: grid;
  gap: 10px;
  color: rgba(31,41,55,.90);
}
.steps li strong{ font-weight: 850; }

.cancel-cta{
  margin-top: 14px;
  border-radius: var(--radius-lg);
  overflow: hidden;
  border: 1.6px solid var(--border);
  background: rgba(255,255,255,.72);
  box-shadow: 0 12px 26px rgba(31,41,55,.10);
}

.cancel-figure{
  margin: 0;
  border-radius: var(--radius-lg);
  overflow: hidden;
  border: 1.6px solid var(--border);
  background: var(--panel);
  box-shadow: var(--shadow-soft);
}
.cancel-figure img{
  aspect-ratio: 4 / 5;
  object-fit: cover;
}

/* -----------------------------
   Snippet panels
------------------------------ */
.snippet-grid{
  display: grid;
  grid-template-columns: 1fr;
  gap: 14px;
}
.snippet{
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 12px;
  align-items: start;
  padding: 16px;
  border-radius: var(--radius-lg);
  border: 1.6px solid var(--border);
  background: linear-gradient(180deg, rgba(255,255,255,.92), rgba(247,244,239,.92));
  box-shadow: var(--shadow-soft);
}
.snippet-icon{
  width: 64px;
  height: 64px;
  border-radius: 18px;
  display: grid;
  place-items: center;
  border: 1px solid var(--border);
  background: rgba(255,255,255,.75);
}
.snippet blockquote{
  margin: 0;
  font-size: var(--step-1);
  line-height: 1.25;
  letter-spacing: -0.01em;
}
.snippet blockquote::before{
  content: "“";
  color: rgba(31,41,55,.35);
  font-size: 1.6em;
  line-height: 0;
  margin-right: 2px;
}
.snippet blockquote::after{
  content: "”";
  color: rgba(31,41,55,.35);
  font-size: 1.6em;
  line-height: 0;
  margin-left: 2px;
}

/* -----------------------------
   Footer
------------------------------ */
.page-footer{
  padding: 10px 0 34px;
}
.footer-line{
  margin: 0;
  padding: 14px 16px;
  border-radius: var(--radius-lg);
  border: 1.6px solid var(--border);
  background: rgba(255,255,255,.72);
  color: rgba(31,41,55,.78);
  box-shadow: var(--shadow-soft);
}

/* -----------------------------
   Desktop enhancements (still vertical)
------------------------------ */
@media (min-width: 880px){
  .header-inner{
    grid-template-columns: 1.12fr .88fr;
    gap: 18px;
    align-items: stretch;
  }

  .invoice-meta{
    grid-template-columns: repeat(4, minmax(0, 1fr));
  }

  .pricing-grid{
    grid-template-columns: repeat(3, minmax(0, 1fr));
    align-items: stretch;
    gap: 16px;
  }
  .plan{ padding: 18px; }
  .featured{ transform: translateY(-10px); }

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

  .cancel-grid{
    grid-template-columns: 1.2fr .8fr;
    gap: 16px;
  }

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

/* -----------------------------
   Print friendliness
------------------------------ */
@media print{
  body{
    background: #ffffff;
  }
  .page-header,
  .page-main,
  .page-footer{
    width: 100%;
    margin: 0;
  }
  .header-inner,
  .invoice-card,
  .plan,
  .cost-card,
  .cancel-steps,
  .cancel-figure,
  .snippet,
  .footer-line{
    box-shadow: none !important;
  }
  .featured{
    transform: none !important;
  }
  .skip-link{ display: none; }
}