/* Better Security · Compass
   Calm, boutique-consultancy aesthetic. Restraint is the brand. */

:root {
  --navy: #1F2A44;
  --blue: #2E5E8C;
  --grey-bg: #F3F4F6;
  --grey-text: #6B7280;
  --white: #FFFFFF;
  --border: #E2E5EA;
  --navy-soft: rgba(31, 42, 68, 0.06);

  --maxw: 1080px;
  --radius: 8px;
  --shadow: 0 1px 3px rgba(31, 42, 68, 0.08), 0 1px 2px rgba(31, 42, 68, 0.04);
  --shadow-lift: 0 6px 20px rgba(31, 42, 68, 0.10);

  --font: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  font-family: var(--font);
  color: var(--navy);
  background: var(--white);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

h1, h2, h3 { line-height: 1.2; letter-spacing: -0.01em; font-weight: 650; }
h2 { font-size: clamp(1.6rem, 3vw, 2.1rem); margin: 0 0 0.5rem; }
p { margin: 0 0 1rem; }
a { color: var(--blue); text-decoration: none; }
a:hover { text-decoration: underline; }

.container { max-width: var(--maxw); margin: 0 auto; padding: 0 24px; }

.section { padding: 88px 0; }
.section--alt { background: var(--grey-bg); }
.section__sub { color: var(--grey-text); font-size: 1.05rem; margin: 0 0 0.25rem; }
.eyebrow { color: var(--blue); font-size: 0.78rem; font-weight: 650;
  letter-spacing: 0.08em; text-transform: uppercase; margin: 0 0 0.75rem; }

/* Buttons */
.btn {
  display: inline-block; border: none; cursor: pointer;
  font-family: var(--font); font-size: 1rem; font-weight: 600;
  padding: 0.8rem 1.5rem; border-radius: var(--radius);
  transition: background 0.15s ease, transform 0.05s ease, box-shadow 0.15s ease;
  text-decoration: none;
}
.btn:hover { text-decoration: none; }
.btn:active { transform: translateY(1px); }
.btn--primary { background: var(--blue); color: #fff; }
.btn--primary:hover { background: #27517a; }
.btn--ghost { background: transparent; color: var(--navy); border: 1px solid var(--border); }
.btn--ghost:hover { border-color: var(--blue); color: var(--blue); }
.btn--block { display: block; width: 100%; text-align: center; }
.btn:focus-visible, a:focus-visible, .chip:focus-visible, select:focus-visible,
input:focus-visible, .tool-card__toggle:focus-visible {
  outline: 2px solid var(--blue); outline-offset: 2px;
}

.link-quiet { color: var(--grey-text); font-weight: 500; }
.link-quiet:hover { color: var(--blue); }

/* ---------- Nav ---------- */
.nav {
  position: sticky; top: 0; z-index: 50;
  background: rgba(255, 255, 255, 0.92);
  backdrop-filter: saturate(180%) blur(8px);
  border-bottom: 1px solid var(--border);
}
.nav__inner { display: flex; align-items: center; justify-content: space-between;
  height: 64px; }
.nav__brand { font-weight: 650; color: var(--navy); font-size: 1.02rem;
  letter-spacing: -0.01em; }
.nav__brand .sep { color: var(--grey-text); font-weight: 400; margin: 0 0.35rem; }
.nav__links { display: flex; gap: 1.5rem; align-items: center; }
.nav__links a { color: var(--navy); font-weight: 500; font-size: 0.95rem; }
.nav__links a:hover { color: var(--blue); text-decoration: none; }
.nav__toggle { display: none; }

/* ---------- Hero ---------- */
.hero { padding: 96px 0 72px; }
.hero h1 { font-size: clamp(2rem, 4.5vw, 3rem); max-width: 18ch; margin: 0 0 1rem; }
.hero__sub { font-size: 1.25rem; color: var(--grey-text); max-width: 40ch; margin: 0 0 2rem; }
.hero__cta { display: flex; gap: 1.25rem; align-items: center; flex-wrap: wrap; }
.hero__thesis-wrap { margin-top: 56px; }
.hero__divider { border: none; border-top: 1px solid var(--border); margin: 0 0 1.25rem; }
.hero__thesis { font-size: 1.05rem; color: var(--navy); font-style: italic; max-width: 52ch; margin: 0; }

/* ---------- Tool landscape ---------- */
.freshness { color: var(--grey-text); font-size: 0.9rem; margin: 0.75rem 0 0; }
.filters { display: flex; gap: 2rem; flex-wrap: wrap; margin: 32px 0 8px;
  align-items: flex-end; }
.filter-group { display: flex; flex-direction: column; gap: 0.4rem; }
.filter-group label { font-size: 0.8rem; font-weight: 600; color: var(--grey-text);
  text-transform: uppercase; letter-spacing: 0.05em; }
select {
  font-family: var(--font); font-size: 0.95rem; color: var(--navy);
  background: #fff; border: 1px solid var(--border); border-radius: var(--radius);
  padding: 0.55rem 0.75rem; min-width: 220px; cursor: pointer;
}
.results-count { color: var(--grey-text); font-size: 0.9rem; margin-left: auto; }

.tool-grid {
  display: grid; gap: 20px; margin-top: 28px;
  grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
}
.tool-card {
  background: #fff; border: 1px solid var(--border); border-radius: var(--radius);
  padding: 22px; box-shadow: var(--shadow); display: flex; flex-direction: column;
  transition: box-shadow 0.15s ease, border-color 0.15s ease;
}
.tool-card:hover { box-shadow: var(--shadow-lift); border-color: #d5dae2; }
.tool-card__cat { display: inline-block; font-size: 0.72rem; font-weight: 650;
  letter-spacing: 0.04em; text-transform: uppercase; color: var(--blue);
  background: var(--navy-soft); padding: 0.2rem 0.55rem; border-radius: 100px;
  margin-bottom: 0.75rem; align-self: flex-start; }
.tool-card__name { font-size: 1.15rem; font-weight: 650; margin: 0 0 0.5rem; }
.tool-card__buyer { font-size: 0.85rem; color: var(--grey-text); margin: 0 0 0.75rem; }
.tool-card__buyer strong { color: var(--navy); font-weight: 600; }
.tool-card__oneliner { font-size: 0.97rem; margin: 0 0 1rem; }
.tool-card__reviewed { font-size: 0.8rem; color: var(--grey-text); margin: auto 0 0; }
.tool-card__toggle { background: none; border: none; color: var(--blue);
  font-family: var(--font); font-size: 0.9rem; font-weight: 600; cursor: pointer;
  padding: 0; margin-top: 0.9rem; align-self: flex-start; }
.tool-card__toggle:hover { text-decoration: underline; }
.tool-card__detail { display: none; margin-top: 1rem; padding-top: 1rem;
  border-top: 1px solid var(--border); }
.tool-card.is-open .tool-card__detail { display: block; }
.tool-card__detail p { font-size: 0.92rem; }
.tool-card__detail dt { font-size: 0.74rem; font-weight: 650; text-transform: uppercase;
  letter-spacing: 0.05em; color: var(--grey-text); margin-top: 0.6rem; }
.tool-card__detail dd { margin: 0.15rem 0 0; font-size: 0.92rem; }

.refunnel {
  margin-top: 48px; background: var(--navy); color: #fff; border-radius: var(--radius);
  padding: 32px; display: flex; align-items: center; justify-content: space-between;
  gap: 24px; flex-wrap: wrap;
}
.refunnel p { margin: 0; font-size: 1.1rem; max-width: 46ch; }
.refunnel .btn--primary { background: #fff; color: var(--navy); white-space: nowrap; }
.refunnel .btn--primary:hover { background: #eef1f5; }

/* ---------- Assessment ---------- */
.assessment-shell {
  max-width: 720px; margin: 0 auto; background: #fff;
  border: 1px solid var(--border); border-radius: 12px; box-shadow: var(--shadow);
  padding: 40px;
}
.screen { display: none; }
.screen.is-active { display: block; animation: fade 0.25s ease; }
@keyframes fade { from { opacity: 0; transform: translateY(6px); } to { opacity: 1; transform: none; } }

.field { margin-bottom: 1.1rem; }
.field label { display: block; font-weight: 600; margin-bottom: 0.4rem; font-size: 0.95rem; }
.field input {
  width: 100%; font-family: var(--font); font-size: 1rem; color: var(--navy);
  border: 1px solid var(--border); border-radius: var(--radius); padding: 0.7rem 0.85rem;
}
.field .optional { color: var(--grey-text); font-weight: 400; }
.smallprint { font-size: 0.82rem; color: var(--grey-text); margin: 1rem 0 0; }
.form-error { color: #b42318; font-size: 0.88rem; margin: 0.5rem 0 0; min-height: 1.2em; }

/* progress */
.progress-head { display: flex; align-items: center; justify-content: space-between;
  margin-bottom: 0.5rem; }
.progress-head .qcount { font-size: 0.85rem; color: var(--grey-text); font-weight: 600; }
.progress-head .dim { font-size: 0.78rem; font-weight: 650; text-transform: uppercase;
  letter-spacing: 0.06em; color: var(--blue); }
.progress-bar { height: 6px; background: var(--grey-bg); border-radius: 100px; overflow: hidden;
  margin-bottom: 0.75rem; }
.progress-bar__fill { height: 100%; background: var(--blue); width: 0; transition: width 0.3s ease; }
.dots { display: flex; gap: 6px; flex-wrap: wrap; margin-bottom: 1.5rem; }
.dot { width: 8px; height: 8px; border-radius: 50%; background: var(--border); }
.dot.is-done { background: var(--blue); }
.dot.is-current { background: var(--navy); }

.q-text { font-size: 1.3rem; font-weight: 650; margin: 0.5rem 0 1.5rem; }
.options { display: flex; flex-direction: column; gap: 12px; }
.option {
  text-align: left; background: #fff; border: 1px solid var(--border);
  border-radius: var(--radius); padding: 1rem 1.1rem; font-family: var(--font);
  font-size: 1rem; color: var(--navy); cursor: pointer;
  transition: border-color 0.12s ease, background 0.12s ease;
}
.option:hover { border-color: var(--blue); background: #f8fafc; }
.option.is-selected { border-color: var(--blue); background: rgba(46, 94, 140, 0.07); }
.q-nav { margin-top: 1.5rem; }
.btn-back { background: none; border: none; color: var(--grey-text);
  font-family: var(--font); font-size: 0.95rem; font-weight: 600; cursor: pointer; padding: 0.4rem 0; }
.btn-back:hover { color: var(--navy); }
.btn-back[hidden] { display: none; }

/* results */
.result-tier { font-size: clamp(1.6rem, 3.5vw, 2.2rem); margin: 0.25rem 0 0.25rem; }
.result-score { color: var(--grey-text); font-weight: 600; margin-bottom: 1rem; }
.score-bar { height: 12px; background: var(--grey-bg); border-radius: 100px; overflow: hidden; margin-bottom: 1.5rem; }
.score-bar__fill { height: 100%; background: var(--blue); width: 0; transition: width 0.6s ease; }
.result-message { font-size: 1.1rem; margin-bottom: 1.5rem; }
.dim-cols { display: grid; grid-template-columns: 1fr 1fr; gap: 24px; margin-bottom: 1.5rem; }
.dim-cols h4 { margin: 0 0 0.5rem; font-size: 0.8rem; text-transform: uppercase;
  letter-spacing: 0.06em; color: var(--grey-text); }
.dim-cols ul { margin: 0; padding-left: 1.1rem; }
.dim-cols li { margin-bottom: 0.35rem; }
.dim-cols .strong-col li::marker { color: #2e7d32; }
.dim-cols .weak-col li::marker { color: #b42318; }
.wedge-restate { background: var(--grey-bg); border-left: 3px solid var(--blue);
  padding: 1rem 1.25rem; border-radius: 4px; font-style: italic; margin: 1.5rem 0; }
.result-ctas { display: flex; flex-direction: column; gap: 0.85rem; margin-top: 1.5rem; }
.result-ctas .btn { width: 100%; text-align: center; }
.confirm-note { background: rgba(46, 125, 50, 0.08); border: 1px solid rgba(46, 125, 50, 0.25);
  color: #1e5e22; padding: 0.85rem 1rem; border-radius: var(--radius); font-size: 0.95rem;
  margin-top: 1rem; }
.confirm-note[hidden] { display: none; }

/* ---------- About ---------- */
.about-card { max-width: 760px; }
.about-card .name { font-weight: 650; font-size: 1.1rem; margin-bottom: 0.75rem; }
.about__ctas { display: flex; gap: 1.25rem; align-items: center; flex-wrap: wrap; margin-top: 0.5rem; }

/* ---------- Footer ---------- */
.footer { background: var(--navy); color: #cbd2de; padding: 56px 0 40px; }
.footer h3 { color: #fff; font-size: 1.1rem; margin: 0 0 0.75rem; }
.footer a { color: #fff; }
.footer__signup { display: flex; gap: 10px; max-width: 460px; margin: 0 0 2rem; flex-wrap: wrap; }
.footer__signup input { flex: 1 1 220px; font-family: var(--font); font-size: 0.95rem;
  border: 1px solid rgba(255,255,255,0.25); background: rgba(255,255,255,0.06); color: #fff;
  border-radius: var(--radius); padding: 0.65rem 0.85rem; }
.footer__signup input::placeholder { color: #9aa6ba; }
.footer__signup .btn--primary { white-space: nowrap; }
.footer__msg { font-size: 0.85rem; margin-top: -1.25rem; margin-bottom: 2rem; min-height: 1.1em; }
.footer__bottom { border-top: 1px solid rgba(255,255,255,0.12); padding-top: 1.5rem;
  display: flex; justify-content: space-between; gap: 16px; flex-wrap: wrap;
  font-size: 0.88rem; }
.footer__bottom .brand { color: #fff; font-weight: 650; }

/* ---------- Responsive ---------- */
@media (max-width: 720px) {
  .section { padding: 56px 0; }
  .hero { padding: 56px 0 48px; }
  .assessment-shell { padding: 26px 20px; }
  .dim-cols { grid-template-columns: 1fr; }
  .nav__links { gap: 1rem; }
  .nav__links a { font-size: 0.9rem; }
  .results-count { margin-left: 0; width: 100%; }
  .refunnel { padding: 24px; }
}

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