/* Caretly marketing site. Rebuilt from the Claude Design files Main.dc.html and
   Pricing.dc.html; every inline style there is a class here, because the
   Content-Security-Policy allows no inline styles. */

@font-face {
  font-family: "IBM Plex Sans";
  src: url("/fonts/ibm-plex-5.3.0/IBMPlexSans-400.woff2") format("woff2");
  font-weight: 400; font-style: normal; font-display: swap;
}
@font-face {
  font-family: "IBM Plex Sans";
  src: url("/fonts/ibm-plex-5.3.0/IBMPlexSans-500.woff2") format("woff2");
  font-weight: 500; font-style: normal; font-display: swap;
}
@font-face {
  font-family: "IBM Plex Sans";
  src: url("/fonts/ibm-plex-5.3.0/IBMPlexSans-600.woff2") format("woff2");
  font-weight: 600; font-style: normal; font-display: swap;
}
@font-face {
  font-family: "IBM Plex Mono";
  src: url("/fonts/ibm-plex-5.3.0/IBMPlexMono-400.woff2") format("woff2");
  font-weight: 400; font-style: normal; font-display: swap;
}
@font-face {
  font-family: "IBM Plex Mono";
  src: url("/fonts/ibm-plex-5.3.0/IBMPlexMono-500.woff2") format("woff2");
  font-weight: 500; font-style: normal; font-display: swap;
}

/* ---------- Tokens (light, dark by system preference, dark by toggle) ---------- */

:root {
  color-scheme: light;
  --bg: #ffffff; --bg2: #f3f4f2; --liner: #eceeea; --line: #dcdfdb;
  --ink: #151916; --ink2: #3b433d; --muted: #5a645d;
  --brand: #15803d; --brand-hover: #116a32; --brand-ink: #ffffff; --brand-tint: #f1f7f2;
  --code: #111512; --code2: #181d19; --code-line: #272e29; --code-ink: #dfe6e0; --code-muted: #869189;
  --sans: "IBM Plex Sans", ui-sans-serif, system-ui, sans-serif;
  --mono: "IBM Plex Mono", ui-monospace, monospace;
  --gutter: clamp(16px, 4vw, 40px);
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    color-scheme: dark;
    --bg: #0c0f0d; --bg2: #121613; --liner: #1a1f1b; --line: #272e29;
    --ink: #e6ebe7; --ink2: #bcc5bf; --muted: #98a39b;
    --brand: #22a356; --brand-hover: #2bb862; --brand-ink: #03140a; --brand-tint: #111a14;
    --code: #080a09; --code2: #0f1310; --code-line: #232a25; --code-ink: #dfe6e0; --code-muted: #869189;
  }
  :root:not([data-theme="light"]) .i-sun { display: block; }
  :root:not([data-theme="light"]) .i-moon { display: none; }
}
:root[data-theme="dark"] {
  color-scheme: dark;
  --bg: #0c0f0d; --bg2: #121613; --liner: #1a1f1b; --line: #272e29;
  --ink: #e6ebe7; --ink2: #bcc5bf; --muted: #98a39b;
  --brand: #22a356; --brand-hover: #2bb862; --brand-ink: #03140a; --brand-tint: #111a14;
  --code: #080a09; --code2: #0f1310; --code-line: #232a25; --code-ink: #dfe6e0; --code-muted: #869189;
}
:root[data-theme="dark"] .i-sun { display: block; }
:root[data-theme="dark"] .i-moon { display: none; }

/* ---------- Base ---------- */

body {
  margin: 0;
  min-height: 100vh;
  background: var(--bg);
  color: var(--ink);
  font-family: var(--sans);
  font-size: 16px;
  line-height: 1.6;
  -webkit-text-size-adjust: 100%;
}
a { color: var(--brand); }
a:hover { color: var(--brand-hover); }
:focus-visible { outline: 2px solid var(--brand); outline-offset: 3px; }
pre { margin: 0; }
code { font-family: var(--mono); }
.sr-only {
  position: absolute; width: 1px; height: 1px; overflow: hidden;
  clip: rect(0 0 0 0); white-space: nowrap;
}
.skip-link {
  position: absolute; left: 16px; top: -100px; z-index: 10;
  padding: 10px 16px; border-radius: 4px;
  background: var(--brand); color: var(--brand-ink); text-decoration: none; font-weight: 500;
}
.skip-link:focus { top: 12px; color: var(--brand-ink); }

.wrap { max-width: 1180px; margin: 0 auto; padding-left: var(--gutter); padding-right: var(--gutter); }

/* ---------- Buttons and links ---------- */

.nav-link { color: var(--ink2); text-decoration: none; }
.nav-link:hover { color: var(--ink); text-decoration: underline; text-underline-offset: 4px; }
.nav-on { color: var(--ink); text-decoration: underline; text-underline-offset: 4px; text-decoration-color: var(--brand); }

.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  min-height: 44px; padding: 0 18px; border-radius: 4px;
  font-family: inherit; font-weight: 500; font-size: 15px; text-decoration: none; box-sizing: border-box;
}
.btn-primary { background: var(--brand); color: var(--brand-ink); border: 1px solid var(--brand); }
.btn-primary:hover { background: var(--brand-hover); color: var(--brand-ink); }
.btn-ghost { background: transparent; color: var(--ink); border: 1px solid var(--line); }
.btn-ghost:hover { border-color: var(--ink); color: var(--ink); }
.icon-btn {
  width: 44px; height: 44px; display: inline-flex; align-items: center; justify-content: center;
  padding: 0; border-radius: 4px; border: 1px solid transparent; background: transparent;
  color: var(--ink2); cursor: pointer;
}
.icon-btn:hover { color: var(--ink); border-color: var(--line); }
.i-sun { display: none; }
.i-moon { display: block; }
.js-only { display: none; }
.js .js-only { display: inline-flex; }

.actions { display: flex; flex-wrap: wrap; gap: 10px; }

/* ---------- Header ---------- */

.site-header { border-bottom: 1px solid var(--line); }
.header-inner {
  padding-top: 10px; padding-bottom: 10px;
  display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 8px 32px;
}
.header-left { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 40px; }
.brand {
  display: flex; align-items: center; gap: 10px; min-height: 44px;
  color: var(--ink); text-decoration: none; font-weight: 600; font-size: 18px;
}
.brand:hover { color: var(--ink); }
.logo { color: var(--brand); flex: 0 0 auto; }
.main-nav { display: flex; flex-wrap: wrap; align-items: center; gap: 4px 24px; font-size: 15px; }
.header-actions { display: flex; align-items: center; gap: 8px; font-size: 15px; }
.login { padding: 0 12px; min-height: 44px; display: inline-flex; align-items: center; }

/* ---------- Code ---------- */

.k { color: #7ee2a0; } .s { color: #e8c67f; } .f { color: #93bbf7; } .v { color: #f2a9c9; } .c { color: #6f7a72; }
.code {
  padding: 24px; background: var(--code); font-family: var(--mono); font-size: 14px; line-height: 1.8;
  color: var(--code-ink); overflow-x: auto; white-space: pre;
}
.code-box { margin-top: 32px; background: var(--code); border-radius: 6px; overflow: hidden; }
.tabs { display: flex; flex-wrap: wrap; padding: 0 20px; border-bottom: 1px solid var(--code-line); background: var(--code2); }
.tab {
  min-height: 44px; padding: 0 4px; margin-right: 20px; border: 0; border-bottom: 2px solid transparent;
  border-radius: 0; background: transparent; color: var(--code-muted); font: 500 13px var(--mono); cursor: pointer;
}
.tab:hover { color: var(--code-ink); }
.tab[aria-pressed="true"] { color: #ffffff; border-bottom-color: #22a356; }

.bars {
  background: repeating-linear-gradient(90deg,#000 0 3px,transparent 3px 5px,#000 5px 6px,transparent 6px 9px,#000 9px 13px,transparent 13px 14px,#000 14px 15px,transparent 15px 18px,#000 18px 20px,transparent 20px 23px,#000 23px 27px,transparent 27px 28px,#000 28px 29px,transparent 29px 31px);
}
.grow { flex: 1 1 auto; }

/* ---------- Page heads (landing hero, pricing, 404) ---------- */

.hero { padding-top: clamp(56px, 8vw, 96px); padding-bottom: 64px; }
.hero-row { display: flex; flex-wrap: wrap; align-items: flex-end; justify-content: space-between; gap: 32px 64px; }
.hero-copy { flex: 1 1 520px; min-width: 0; max-width: 700px; }
.hero-title { margin: 0; font-size: clamp(40px, 5.6vw, 66px); line-height: 1.04; letter-spacing: -0.025em; font-weight: 500; }
.lead { margin: 20px 0 0; font-size: clamp(18px, 2vw, 21px); line-height: 1.45; color: var(--ink2); }
.hero-side { flex: 0 1 auto; display: flex; flex-direction: column; gap: 14px; }
.fineprint { margin: 0; font-size: 14px; color: var(--muted); }

.nf { padding-top: clamp(56px, 8vw, 96px); padding-bottom: 104px; }
.nf .actions { margin-top: 32px; }

/* ---------- Landing: hero demo ---------- */

.demo { margin: 56px 0 0; border: 1px solid var(--line); border-radius: 6px; overflow: hidden; }
.demo-cap {
  display: flex; flex-wrap: wrap; justify-content: space-between; gap: 4px 24px;
  padding: 10px 16px; border-bottom: 1px solid var(--line); background: var(--bg2);
  font-family: var(--mono); font-size: 12.5px; color: var(--ink2); white-space: pre-wrap;
}
.ok { color: var(--brand); }
.demo-body { display: flex; flex-wrap: wrap; }
.demo-code { flex: 1 1 480px; min-width: 0; font-size: 13px; line-height: 1.75; }
.demo-stage {
  flex: 1 1 380px; min-width: 0; background: var(--liner); padding: 32px clamp(16px, 4vw, 48px);
  display: flex; justify-content: center; align-items: center;
}
.label {
  width: 100%; max-width: 320px; aspect-ratio: 2 / 3; background: #ffffff; color: #000000;
  border-radius: 8px; box-shadow: 0 0 0 1px rgba(0,0,0,0.08); padding: 20px; box-sizing: border-box;
  display: flex; flex-direction: column; font-family: var(--sans);
}
.label-from { font-size: 10.5px; line-height: 1.4; }
.rule { border-top: 2px solid #000; margin: 14px 0 12px; }
.rule-2 { margin: 16px 0; }
.label-addr { display: flex; justify-content: space-between; align-items: flex-start; gap: 10px; }
.label-addr > div { line-height: 1.25; }
.label-name { font-size: 20px; font-weight: 600; }
.label-street { font-size: 14.5px; font-weight: 500; }
.label-street-1 { margin-top: 6px; }
.label-qr { flex: 0 0 auto; }
.label-meta { display: flex; justify-content: space-between; font-size: 10.5px; font-weight: 600; letter-spacing: 0.04em; }
.label-bars { height: 100px; margin-top: 14px; }
.label-code { text-align: center; font-family: var(--mono); font-size: 12px; letter-spacing: 0.16em; margin-top: 6px; }

/* ---------- Rows: a small heading on the left, content on the right ---------- */

.row { border-top: 1px solid var(--line); }
.row-inner { padding-top: 72px; padding-bottom: 72px; display: flex; flex-wrap: wrap; gap: 16px 48px; }
.row-h { flex: 1 1 200px; max-width: 260px; margin: 0; font-size: 15px; font-weight: 600; line-height: 1.6; }
.row-body { flex: 999 1 560px; min-width: 0; }
.say { margin: 0; max-width: 680px; font-size: clamp(22px, 2.4vw, 27px); line-height: 1.35; letter-spacing: -0.01em; }
.note { margin: 14px 0 0; color: var(--ink2); max-width: 640px; }

/* Specifications */
.specs { margin: 0; border-top: 1px solid var(--line); }
.specs > div { display: flex; flex-wrap: wrap; gap: 4px 32px; padding: 22px 0; border-bottom: 1px solid var(--line); }
.specs dt { flex: 0 0 180px; font-weight: 500; }
.specs dd { flex: 1 1 320px; min-width: 0; margin: 0; color: var(--ink2); }
.specs code, .lines code { font-size: 14px; }

/* Getting started */
.steps {
  margin: 0; padding: 0; list-style: none; display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 220px), 1fr)); gap: 32px;
}
.step-n { font-family: var(--mono); font-size: 13px; color: var(--muted); }
.steps p { margin: 6px 0 0; }
.steps strong { font-weight: 600; }
.steps p span { color: var(--ink2); }

/* Embedded playground (served by the renderer at /playground/, same origin) */
.pg {
  display: block; width: 100%; height: 640px; margin-top: 32px;
  border: 1px solid var(--line); border-radius: 6px; background: var(--bg2);
}
/* The playground stacks editor over preview below 760px wide. */
@media (max-width: 760px) { .pg { height: 760px; } }

/* For developers */
.dev { display: flex; flex-wrap: wrap; gap: 24px 40px; margin-top: 32px; align-items: flex-start; }
.dev-hdrs { flex: 1 1 340px; min-width: 0; padding: 20px 24px; border-radius: 6px; }
.hdrs { flex: 1 1 280px; min-width: 0; margin: 0; display: flex; flex-direction: column; gap: 14px; font-size: 15px; }
.hdrs code { font-size: 13.5px; }
.hdrs dd { margin: 2px 0 0; color: var(--ink2); }

/* Pricing teaser */
.price-big { margin: 0; font-size: clamp(30px, 3.6vw, 42px); line-height: 1.15; letter-spacing: -0.02em; font-weight: 500; }
.price-big span { color: var(--muted); }
.price-sub { margin: 16px 0 0; color: var(--ink2); }

/* Closing call to action */
.cta { border-top: 1px solid var(--line); }
.cta-inner {
  padding-top: 72px; padding-bottom: 88px;
  display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 24px 48px;
}
.cta h2 { margin: 0; font-size: clamp(26px, 3vw, 34px); line-height: 1.2; letter-spacing: -0.015em; font-weight: 500; }

/* ---------- Footer ---------- */

.site-footer { border-top: 1px solid var(--line); background: var(--bg2); }
.footer-inner { padding-top: 40px; padding-bottom: 32px; }
.footer-nav { display: flex; flex-wrap: wrap; gap: 4px 28px; font-size: 14px; }
.footer-nav .nav-link { min-height: 32px; display: inline-flex; align-items: center; }
.footer-bottom {
  margin-top: 28px; display: flex; flex-wrap: wrap; justify-content: space-between; gap: 8px 24px;
  font-size: 13px; color: var(--muted);
}

/* ---------- Pricing page ---------- */

.p-hero { padding-top: clamp(56px, 8vw, 88px); padding-bottom: 48px; }
.p-title { margin: 0; max-width: 760px; font-size: clamp(38px, 5vw, 58px); line-height: 1.06; letter-spacing: -0.025em; font-weight: 500; }
.p-lead { margin: 18px 0 0; max-width: 560px; font-size: clamp(18px, 2vw, 20px); line-height: 1.45; color: var(--ink2); }

.plans-sec { padding-bottom: 80px; }
.plans {
  display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 250px), 1fr)); gap: 1px;
  background: var(--line); border: 1px solid var(--line); border-radius: 6px; overflow: hidden;
}
.plan { display: flex; flex-direction: column; background: var(--bg); padding: 28px 24px; }
.plan-live { background: var(--brand-tint); box-shadow: inset 0 3px 0 var(--brand); }
.plan h2 { margin: 0; font-size: 16px; font-weight: 600; }
.plan-live h2 { color: var(--brand); }
.plan-price { margin: 14px 0 0; font-size: 34px; line-height: 1.1; letter-spacing: -0.02em; font-weight: 500; }
.plan-price-row { margin: 14px 0 0; display: flex; align-items: baseline; gap: 8px; flex-wrap: wrap; }
.plan-price-row .amt { font-size: 34px; line-height: 1.1; letter-spacing: -0.02em; font-weight: 500; }
.plan-price-row .per { font-size: 15px; color: var(--muted); }
.plan-price-sm { font-size: 22px; line-height: 1.3; letter-spacing: -0.01em; }
.plan-note { margin: 4px 0 0; font-size: 14px; color: var(--muted); }
.plan ul { margin: 22px 0 0; padding-left: 18px; display: flex; flex-direction: column; gap: 8px; font-size: 15px; color: var(--ink2); }
.plan li::marker { color: var(--muted); }
.plan-spacer { flex: 1 1 auto; min-height: 28px; }

.calc { display: flex; flex-wrap: wrap; gap: 32px 56px; align-items: flex-start; }
.calc-in { flex: 1 1 340px; min-width: 0; }
.calc-label { display: block; font-size: 15px; font-weight: 500; }
.calc-num {
  display: block; width: 100%; box-sizing: border-box; margin-top: 8px; min-height: 52px; padding: 0 14px;
  border: 1px solid var(--line); border-radius: 4px; background: var(--bg); color: var(--ink);
  font: 400 22px var(--mono);
}
.calc-range { display: block; width: 100%; accent-color: var(--brand); height: 44px; margin: 14px 0 0; cursor: pointer; }
.ticks { display: flex; justify-content: space-between; font-family: var(--mono); font-size: 12px; color: var(--muted); }
.presets { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 24px; }
.preset {
  min-height: 44px; padding: 0 14px; border-radius: 4px; border: 1px solid var(--line);
  background: transparent; color: var(--ink2); font: 400 14px var(--mono); cursor: pointer;
}
.preset:hover, .preset[aria-pressed="true"] { border-color: var(--ink); color: var(--ink); }
.calc-out { flex: 1 1 240px; min-width: 0; padding-top: 30px; }
.calc-cap { display: block; font-size: 14px; color: var(--muted); }
.calc-cost { display: block; margin-top: 4px; font-size: clamp(40px, 4.6vw, 54px); line-height: 1.05; letter-spacing: -0.025em; font-weight: 500; }
.calc-formula { display: block; margin-top: 10px; font-family: var(--mono); font-size: 13px; color: var(--ink2); }
.calc-more { margin: 20px 0 0; font-size: 14px; color: var(--ink2); }

.lines { margin: 0; padding: 0; list-style: none; border-top: 1px solid var(--line); }
.lines li { padding: 16px 0; border-bottom: 1px solid var(--line); }

/* Info icon with a tooltip: shown on hover and keyboard focus, toggled by tap (site.js). */
.has-tip { position: relative; }
.tip { display: inline; }
.tip-btn {
  display: inline-flex; align-items: center; justify-content: center; vertical-align: middle;
  width: 32px; height: 32px; margin: -8px 0 -8px 2px; padding: 0; border: 0; border-radius: 4px;
  background: transparent; color: var(--muted); cursor: help;
}
.tip-btn:hover, .tip-btn[aria-expanded="true"] { color: var(--brand); }
.tip-body {
  display: none; position: absolute; left: 0; top: calc(100% - 8px); z-index: 5;
  max-width: min(380px, 100%); padding: 12px 14px; box-sizing: border-box;
  background: var(--ink); color: var(--bg); border-radius: 4px;
  font-size: 14px; line-height: 1.5; box-shadow: 0 8px 24px rgba(0,0,0,0.18);
}
.tip:hover .tip-body, .tip-btn:focus-visible + .tip-body, .tip-btn[aria-expanded="true"] + .tip-body { display: block; }

.faq { border-top: 1px solid var(--line); }
.faq details { border-bottom: 1px solid var(--line); }
.faq summary {
  display: flex; justify-content: space-between; align-items: center; gap: 16px; min-height: 56px;
  font-weight: 500; cursor: pointer; list-style: none;
}
.faq summary::-webkit-details-marker { display: none; }
.chev { color: var(--muted); font-size: 20px; line-height: 1; transition: transform .15s; }
.faq details[open] .chev { transform: rotate(45deg); }
.faq p { margin: 0 0 18px; color: var(--ink2); max-width: 620px; }

@media (prefers-reduced-motion: reduce) {
  .chev { transition: none; }
}

/* Legal pages (privacy, terms): a readable text column. */
.legal { max-width: 760px; padding-top: 64px; padding-bottom: 96px; line-height: 1.65; }
.legal h1 { margin: 0 0 8px; font-size: clamp(32px, 5vw, 44px); letter-spacing: -0.02em; line-height: 1.15; font-weight: 500; }
.legal h2 { margin: 40px 0 12px; font-size: 22px; letter-spacing: -0.01em; font-weight: 600; }
.legal h3 { margin: 28px 0 8px; font-size: 17px; font-weight: 600; }
.legal p, .legal li { color: var(--ink2); }
.legal ul { padding-left: 1.25em; }
.legal li { margin: 6px 0; }
.legal a { color: var(--brand); }
.legal code { font-size: 0.9em; }
.legal .legal-meta { color: var(--muted); font-size: 14px; margin: 0 0 32px; }
