/* Caspelo marketing site. Tokens mirror the live dashboard (app.caspelo.eu). */
:root {
  --bg: #f4f5f7;
  --card: #ffffff;
  --line: #e6e8ec;
  --line-strong: #d5d9e0;
  --text: #0a0a0a;
  --text-2: #2e3138;
  --muted: #5b606b;
  --faint: #8a8f99;
  --brand: #0038ff;
  --brand-2: #2b5bff;
  --brand-hover: #002fd6;
  --tint: #eef2ff;
  --tint-2: #e6ecff;
  --radius: 12px;
  --radius-sm: 8px;
  --shadow: 0 1px 2px rgba(16, 24, 40, 0.04);
  --font: "Inter Tight", ui-sans-serif, system-ui, -apple-system, "Segoe UI", Roboto, Arial, sans-serif;
  --wrap: 1120px;
}

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

html {
  scroll-behavior: smooth;
  scroll-padding-top: 76px;
  -webkit-text-size-adjust: 100%;
}
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--text-2);
  font-family: var(--font);
  font-size: 16px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-x: hidden;
}

h1, h2, h3 { color: var(--text); margin: 0; line-height: 1.15; }
p { margin: 0; }
a { color: var(--brand); text-decoration: none; }
a:hover { text-decoration: underline; }

:focus-visible {
  outline: 2px solid var(--brand);
  outline-offset: 2px;
  border-radius: 6px;
}

.skip {
  position: absolute;
  left: 16px;
  top: -48px;
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  padding: 8px 12px;
  z-index: 100;
}
.skip:focus { top: 12px; }

.wrap {
  width: 100%;
  max-width: var(--wrap);
  margin: 0 auto;
  padding: 0 24px;
}

/* Wordmark */
.wordmark {
  font-size: 21px;
  font-weight: 700;
  letter-spacing: -0.03em;
  color: var(--text);
  line-height: 1;
}
a.wordmark:hover { text-decoration: none; }
.wordmark--sm { font-size: 17px; }

/* Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  height: 36px;
  padding: 0 14px;
  border-radius: var(--radius-sm);
  border: 1px solid transparent;
  font: inherit;
  font-size: 14px;
  font-weight: 600;
  line-height: 1;
  white-space: nowrap;
  cursor: pointer;
  transition: background-color .15s ease, border-color .15s ease, color .15s ease;
}
.btn:hover { text-decoration: none; }
.btn--primary { background: var(--brand); color: #fff; }
.btn--primary:hover { background: var(--brand-hover); }
.btn--secondary {
  background: var(--card);
  color: var(--text);
  border-color: var(--line-strong);
  box-shadow: var(--shadow);
}
.btn--secondary:hover { border-color: var(--faint); }
.btn--ghost { background: transparent; color: var(--text-2); }
.btn--ghost:hover { background: var(--card); border-color: var(--line); color: var(--text); }
.btn--lg { height: 44px; padding: 0 18px; font-size: 15px; }
.btn--block { width: 100%; }

/* Top bar */
.topbar {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(244, 245, 247, 0.88);
  backdrop-filter: saturate(180%) blur(10px);
  -webkit-backdrop-filter: saturate(180%) blur(10px);
  border-bottom: 1px solid var(--line);
}
.topbar__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 60px;
  gap: 12px;
}
.topbar__actions { display: flex; align-items: center; gap: 6px; }

/* Shared bits */
.card {
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
}

.eyebrow {
  display: inline-block;
  font-size: 13px;
  font-weight: 600;
  color: var(--brand);
  background: var(--tint);
  border: 1px solid var(--tint-2);
  border-radius: 999px;
  padding: 4px 10px;
  margin-bottom: 16px;
  line-height: 1.3;
}

.tag {
  font-size: 12px;
  font-weight: 600;
  color: var(--muted);
  background: var(--bg);
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 2px 9px;
  line-height: 1.5;
}

.chip {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  font-size: 13px;
  font-weight: 600;
  color: var(--text);
}
.dot { width: 8px; height: 8px; border-radius: 50%; background: var(--brand); }

/* Hero */
.hero { padding: 72px 0 80px; }
.hero__grid {
  display: grid;
  grid-template-columns: minmax(0, 1.15fr) minmax(0, 0.85fr);
  gap: 56px;
  align-items: center;
}
.hero h1 {
  font-size: clamp(36px, 5.4vw, 56px);
  font-weight: 700;
  letter-spacing: -0.035em;
  line-height: 1.05;
}
.lead {
  margin-top: 20px;
  font-size: clamp(17px, 1.6vw, 19px);
  color: var(--muted);
  max-width: 34em;
}
.hero__ctas { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 32px; }
.hero__note { margin-top: 14px; font-size: 14px; color: var(--muted); }

/* Hero chat card */
.chat { margin: 0; padding: 20px; }
.chat__head { display: flex; justify-content: space-between; align-items: center; }
.chat__q {
  margin: 18px 0 0 auto;
  width: fit-content;
  max-width: 90%;
  background: var(--bg);
  border: 1px solid var(--line);
  border-radius: 12px 12px 4px 12px;
  padding: 10px 14px;
  font-size: 15px;
  color: var(--text);
}
.chat__a { margin-top: 14px; font-size: 15px; color: var(--text-2); }
.chat__a ol { margin: 8px 0 0; padding-left: 22px; }
.chat__a li { padding: 2px 0; }
.chat__foot {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-top: 18px;
  padding-top: 14px;
  border-top: 1px solid var(--line);
}
.chat__label { font-size: 14px; font-weight: 600; color: var(--text); }
.status {
  font-size: 13px;
  font-weight: 600;
  border-radius: 999px;
  padding: 3px 10px;
}
.status--off { color: #b42318; background: #fef3f2; border: 1px solid #fee4e2; }
.chat__cap { margin-top: 12px; font-size: 13px; color: var(--muted); }

/* Sections */
.section { padding: 88px 0; }
.section--alt {
  background: var(--card);
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
}
.section--alt .card { background: var(--card); }
.section__head { max-width: 680px; margin-bottom: 40px; }
.section h2 {
  font-size: clamp(28px, 3.6vw, 38px);
  font-weight: 700;
  letter-spacing: -0.03em;
}
.section__lead { margin-top: 14px; font-size: 17px; color: var(--muted); }

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

.card h3 { font-size: 18px; font-weight: 600; letter-spacing: -0.015em; }
:is(.feature, .step, .audience, .owner) p { margin-top: 8px; color: var(--muted); font-size: 15px; }
.cta__copy > p:not(.eyebrow) { color: var(--muted); }

.feature { padding: 24px; }
.feature__icon {
  width: 40px;
  height: 40px;
  border-radius: 10px;
  display: grid;
  place-items: center;
  background: var(--tint);
  color: var(--brand);
  margin-bottom: 18px;
}

/* Steps */
.steps {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 16px;
}
.section--alt .step { background: var(--bg); box-shadow: none; }
.step { padding: 22px; }
.step__n {
  display: inline-grid;
  place-items: center;
  width: 28px;
  height: 28px;
  border-radius: 8px;
  background: var(--brand);
  color: #fff;
  font-size: 14px;
  font-weight: 700;
  margin-bottom: 16px;
}

/* Audience */
.audience { padding: 24px; border-top: 3px solid var(--brand); }
.owner {
  margin-top: 16px;
  padding: 24px;
  background: var(--tint);
  border-color: var(--tint-2);
  box-shadow: none;
}
.owner p { color: var(--text-2); max-width: 46em; }

/* Dashboard preview */
.disclaimer {
  margin-top: 16px;
  font-size: 14px;
  color: var(--text-2);
  background: var(--bg);
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  padding: 10px 14px;
  display: inline-block;
}
.disclaimer strong { color: var(--text); }

.preview {
  background: var(--bg);
  border: 1px solid var(--line-strong);
  border-radius: 16px;
  overflow: hidden;
  box-shadow: 0 12px 32px rgba(16, 24, 40, 0.06), var(--shadow);
}
.preview__bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 14px 20px;
  background: var(--card);
  border-bottom: 1px solid var(--line);
}
.preview__body { padding: 20px; display: grid; gap: 16px; }
.preview .card { background: var(--card); }

.kpis { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; }
.kpi { padding: 18px 20px; display: flex; flex-direction: column; gap: 4px; }
.kpi__label { font-size: 13px; font-weight: 500; color: var(--muted); }
.kpi__value {
  font-size: 34px;
  font-weight: 700;
  letter-spacing: -0.03em;
  color: var(--text);
  line-height: 1.1;
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
}
.kpi__of { font-size: 18px; font-weight: 600; color: var(--faint); letter-spacing: 0; }
.kpi__delta { font-size: 13px; font-weight: 600; color: var(--brand); }
.kpi__sub { font-size: 13px; color: var(--muted); }

.preview__row { display: grid; grid-template-columns: minmax(0, 1.2fr) minmax(0, 1fr); gap: 16px; }
.panel { padding: 20px; }
.card .panel__title, .panel__title { font-size: 14px; font-weight: 600; color: var(--text); letter-spacing: 0; }
.panel__title--spaced { margin-top: 24px; }

.hbars { list-style: none; margin: 14px 0 0; padding: 0; display: grid; gap: 12px; }
.hbars li {
  display: grid;
  grid-template-columns: 76px minmax(0, 1fr) 40px;
  align-items: center;
  gap: 12px;
  font-size: 14px;
}
.hbars__name { color: var(--text-2); font-weight: 500; }
.hbars__track { height: 10px; background: var(--tint); border-radius: 999px; overflow: hidden; }
.hbars__fill { display: block; height: 100%; width: var(--v); background: var(--brand); border-radius: 999px; }
.hbars__val { text-align: right; font-weight: 600; color: var(--text); font-variant-numeric: tabular-nums; }

.vbars {
  margin-top: 14px;
  height: 120px;
  display: grid;
  grid-template-columns: repeat(8, minmax(0, 1fr));
  gap: 10px;
  align-items: end;
  padding-bottom: 22px;
  border-bottom: 1px solid var(--line);
  position: relative;
}
.vbars span {
  position: relative;
  height: var(--v);
  background: var(--tint-2);
  border-radius: 6px 6px 2px 2px;
}
.vbars span.is-now { background: var(--brand); }
.vbars span:nth-child(6), .vbars span:nth-child(7) { background: #95adff; }
.vbars i {
  position: absolute;
  bottom: -22px;
  left: 0;
  right: 0;
  text-align: center;
  font-style: normal;
  font-size: 12px;
  color: var(--faint);
}

.rank { list-style: none; margin: 14px 0 0; padding: 0; }
.rank li {
  display: grid;
  grid-template-columns: 28px minmax(0, 1fr) auto;
  align-items: center;
  gap: 10px;
  padding: 10px 10px;
  border-radius: var(--radius-sm);
  font-size: 14px;
}
.rank li + li { margin-top: 2px; }
.rank__n {
  width: 24px;
  height: 24px;
  display: grid;
  place-items: center;
  border-radius: 6px;
  background: var(--bg);
  border: 1px solid var(--line);
  font-size: 12px;
  font-weight: 600;
  color: var(--muted);
}
.rank__name { color: var(--text-2); font-weight: 500; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.rank__val { font-weight: 600; color: var(--text); font-variant-numeric: tabular-nums; }
.rank li.is-you { background: var(--tint); }
.rank li.is-you .rank__n { background: var(--brand); border-color: var(--brand); color: #fff; }
.rank li.is-you .rank__name { color: var(--brand); font-weight: 600; }

/* CTA */
.cta {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  gap: 48px;
  padding: 40px;
}
.cta h2 { font-size: clamp(28px, 3.4vw, 36px); }
.cta__copy > p { margin-top: 14px; font-size: 16px; }
.checks { list-style: none; margin: 20px 0 0; padding: 0; display: grid; gap: 10px; }
.checks li {
  position: relative;
  padding-left: 28px;
  color: var(--text-2);
  font-size: 15px;
}
.checks li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 3px;
  width: 18px;
  height: 18px;
  border-radius: 50%;
  background: var(--tint) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%230038ff' stroke-width='3' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M5 12.5l4.5 4.5L19 7.5'/%3E%3C/svg%3E") center / 11px no-repeat;
}
.card .cta__mail { margin-top: 22px; font-size: 14px; color: var(--muted); }

.cta__box {
  display: grid;
  gap: 14px;
  align-self: center;
  background: var(--bg);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 24px;
}
.cta__box p { font-size: 15px; color: var(--muted); }
.cta__box .btn { margin-top: 6px; }
.cta__box .cta__hint { font-size: 13px; text-align: center; }

/* Contact */
.contact {
  display: grid;
  grid-template-columns: minmax(0, 0.9fr) minmax(0, 1.1fr);
  gap: 48px;
  align-items: start;
}
.contact__mail { margin-top: 20px; font-size: 15px; color: var(--muted); }

.form {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
  padding: 24px;
}
.section--alt .form { background: var(--bg); box-shadow: none; }
.field { display: grid; gap: 6px; }
.field--full, .form .btn, .form__status { grid-column: 1 / -1; }
.field label { font-size: 13px; font-weight: 600; color: var(--text); }
.field__opt { font-weight: 500; color: var(--muted); }
.field input, .field textarea {
  width: 100%;
  padding: 0 12px;
  font: inherit;
  font-size: 15px;
  color: var(--text);
  background: var(--card);
  border: 1px solid var(--line-strong);
  border-radius: var(--radius-sm);
  box-shadow: var(--shadow);
}
.field input { height: 40px; }
.field textarea { padding: 10px 12px; min-height: 128px; resize: vertical; line-height: 1.5; }
.field input::placeholder { color: var(--faint); }
.field input:focus, .field textarea:focus {
  outline: none;
  border-color: var(--brand);
  box-shadow: 0 0 0 3px var(--tint-2);
}
.field [aria-invalid="true"] { border-color: #d92d20; }
.form .btn { margin-top: 4px; }
.form .btn[disabled] { opacity: .7; cursor: not-allowed; }
.form .btn[aria-disabled="true"] { opacity: .7; cursor: progress; }
.form__trap { position: absolute; left: -10000px; width: 1px; height: 1px; overflow: hidden; }
.form__status {
  font-size: 14px;
  border-radius: var(--radius-sm);
  padding: 10px 14px;
  color: var(--text-2);
  background: var(--card);
  border: 1px solid var(--line);
}
.form__status--ok { color: #067647; background: #ecfdf3; border-color: #abefc6; }
.form__status--error { color: #b42318; background: #fef3f2; border-color: #fee4e2; }
.form__status a { color: inherit; text-decoration: underline; }

/* Footer */
.footer { border-top: 1px solid var(--line); background: var(--card); padding: 32px 0; }
.footer__inner {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 24px;
  flex-wrap: wrap;
}
.footer__tag { margin-top: 6px; font-size: 14px; color: var(--muted); }
.footer__links {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-wrap: wrap;
  gap: 8px 24px;
  font-size: 14px;
}
.footer__links a { color: var(--text-2); font-weight: 500; }
.footer__links a:hover { color: var(--brand); }
.footer__copy { color: var(--muted); }

/* Responsive */
@media (max-width: 960px) {
  .hero__grid { grid-template-columns: minmax(0, 1fr); gap: 40px; }
  .chat { max-width: 520px; }
  .steps { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .preview__row { grid-template-columns: minmax(0, 1fr); }
  .cta { grid-template-columns: minmax(0, 1fr); gap: 32px; padding: 32px; }
  .contact { grid-template-columns: minmax(0, 1fr); gap: 28px; }
}

@media (max-width: 720px) {
  .grid--3 { grid-template-columns: minmax(0, 1fr); }
  .section { padding: 64px 0; }
  .hero { padding: 48px 0 64px; }
}

@media (max-width: 560px) {
  .wrap { padding: 0 16px; }
  .steps { grid-template-columns: minmax(0, 1fr); }
  .hero__ctas .btn { width: 100%; }
  .preview__body { padding: 12px; gap: 12px; }
  .kpis { gap: 8px; }
  .kpi { padding: 12px; }
  .kpi__value { font-size: 24px; }
  .kpi__of { font-size: 14px; }
  .kpi__label, .kpi__sub, .kpi__delta { font-size: 12px; line-height: 1.35; }
  .preview__bar { padding: 12px 14px; }
  .panel { padding: 16px; }
  .vbars { gap: 6px; }
  .cta { padding: 20px; }
  .cta__box { padding: 16px; }
  .form { grid-template-columns: minmax(0, 1fr); padding: 16px; }
  .footer__inner { flex-direction: column; align-items: flex-start; }
}

@media (max-width: 400px) {
  .kpis { grid-template-columns: minmax(0, 1fr); }
  .topbar__actions .btn--ghost { padding: 0 8px; }
  .topbar__actions .btn--primary { padding: 0 10px; }
}
@media (max-width: 350px) {
  .topbar__actions .btn--ghost { display: none; }
}
