/* NexoJuris public site: the beta's palette (frontend/src/styles.css), no
   external fonts or scripts. */

:root {
  --bg: #f6f3ec;
  --surface: #ffffff;
  --cream: #fbf7ee;
  --sand: #eee8dc;
  --border: #e4ddd0;
  --text: #1e2422;
  --muted: #5d6763;
  --accent: #1f5c57;
  --accent-hover: #184a46;
  --accent-deep: #163f3b;
  --accent-tint: #e9f2ef;
  --gold: #b9975b;
  --gold-soft: #ead9b4;
  --serif: 'Iowan Old Style', 'Palatino Linotype', Palatino, 'Book Antiqua', Georgia, serif;
  --sans: system-ui, -apple-system, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
  --radius: 16px;
  color-scheme: light;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: var(--sans);
  font-size: 17px;
  line-height: 1.6;
  overflow-wrap: break-word;
  -webkit-font-smoothing: antialiased;
}

h1,
h2,
h3 {
  font-family: var(--serif);
  font-weight: 600;
  line-height: 1.15;
  margin: 0;
  text-wrap: balance;
}

p {
  margin: 0;
}

a {
  color: inherit;
}

svg {
  fill: none;
  stroke: currentColor;
  stroke-width: 1.8;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.wrap {
  width: min(1160px, 100%);
  margin: 0 auto;
  padding: 0 24px;
}

.skip-link {
  position: absolute;
  left: 16px;
  top: -60px;
  padding: 8px 14px;
  background: var(--accent);
  color: #fff;
  border-radius: 8px;
  z-index: 10;
}

.skip-link:focus {
  top: 12px;
}

:focus-visible {
  outline: 3px solid var(--gold);
  outline-offset: 3px;
}

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

.site-header {
  position: sticky;
  top: 0;
  z-index: 5;
  background: rgb(246 243 236 / 88%);
  backdrop-filter: saturate(1.4) blur(10px);
  border-bottom: 1px solid rgb(228 221 208 / 70%);
}

.header-inner {
  display: flex;
  align-items: center;
  gap: 32px;
  height: 68px;
}

.wordmark {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-family: var(--serif);
  font-size: 23px;
  font-weight: 600;
  letter-spacing: 0.01em;
  color: var(--accent-deep);
  text-decoration: none;
}

.wordmark-mark {
  width: 32px;
  height: 32px;
  color: var(--accent);
  stroke-width: 1.6;
}

.wordmark-mark circle {
  fill: var(--accent-tint);
  stroke: var(--gold);
}

.header-nav {
  display: flex;
  gap: 28px;
  margin-left: auto;
  font-size: 15px;
}

.header-nav a {
  color: var(--muted);
  text-decoration: none;
}

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

/* -- buttons ------------------------------------------------------------------ */

.button {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 14px 24px;
  border-radius: 999px;
  background: var(--accent);
  color: #fff;
  font-weight: 600;
  font-size: 16px;
  white-space: nowrap;
  text-decoration: none;
  box-shadow: 0 10px 24px -12px rgb(31 92 87 / 70%);
  transition:
    background 0.2s,
    transform 0.2s;
}

.button:hover {
  background: var(--accent-hover);
  transform: translateY(-1px);
}

.button-small {
  padding: 9px 18px;
  font-size: 15px;
  box-shadow: none;
}

.button-ghost {
  background: transparent;
  color: var(--accent);
  border: 1.5px solid var(--accent);
  box-shadow: none;
}

.button-ghost:hover {
  background: var(--accent-tint);
}

.button-arrow {
  width: 18px;
  height: 18px;
  stroke-width: 2;
}

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

.hero {
  position: relative;
  overflow: hidden;
  background:
    radial-gradient(900px 480px at 85% 10%, rgb(234 217 180 / 55%), transparent 70%),
    radial-gradient(700px 520px at 0% 100%, rgb(213 230 225 / 70%), transparent 70%),
    linear-gradient(180deg, var(--cream), var(--bg));
}

.hero-inner {
  display: grid;
  grid-template-columns: minmax(0, 1.05fr) minmax(0, 1fr);
  gap: 56px;
  align-items: center;
  padding-top: 88px;
  padding-bottom: 96px;
}

.eyebrow {
  text-wrap: balance;
  margin-bottom: 18px;
  font-size: 13px;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--gold);
}

.hero h1 {
  font-size: clamp(38px, 5.2vw, 60px);
  letter-spacing: -0.01em;
  color: var(--accent-deep);
}

.hero h1 em {
  font-style: normal;
  color: var(--accent);
  background: linear-gradient(transparent 72%, rgb(234 217 180 / 85%) 72%, rgb(234 217 180 / 85%) 92%, transparent 92%);
}

@media (min-width: 400px) {
  .hero h1 em {
    white-space: nowrap;
  }
}

.lead {
  margin-top: 24px;
  max-width: 34em;
  font-size: 19px;
  color: var(--muted);
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
  margin-top: 34px;
}

.hero-note {
  margin-top: 18px;
  font-size: 14px;
  color: var(--muted);
}

/* the illustration: a stylised search, no real case data */

.preview {
  position: relative;
  margin: 0;
}

.preview::before {
  content: '';
  position: absolute;
  inset: 8% -6% -8% 10%;
  border-radius: 28px;
  background: linear-gradient(135deg, var(--gold-soft), rgb(213 230 225 / 80%));
  transform: rotate(3deg);
}

.preview-window {
  position: relative;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 20px;
  box-shadow: 0 30px 60px -30px rgb(22 63 59 / 45%);
  overflow: hidden;
}

.preview-bar {
  display: flex;
  gap: 6px;
  padding: 12px 16px;
  background: var(--cream);
  border-bottom: 1px solid var(--border);
}

.preview-bar span {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: var(--sand);
}

.preview-body {
  padding: 22px;
}

.preview-label {
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--muted);
}

.preview-query {
  margin-top: 8px;
  padding: 14px 16px;
  border: 1.5px solid var(--accent-tint);
  border-radius: 12px;
  background: #fdfcf9;
  font-size: 15px;
  line-height: 1.5;
}

.preview-result {
  margin-top: 16px;
  padding: 16px;
  border: 1px solid var(--border);
  border-left: 4px solid var(--accent);
  border-radius: 12px;
}

.preview-result-faded {
  opacity: 0.55;
  border-left-color: var(--gold);
}

.preview-result-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
}

.preview-court {
  font-family: var(--serif);
  font-weight: 600;
  font-size: 15px;
  color: var(--accent-deep);
}

.preview-relevance {
  display: inline-flex;
  gap: 3px;
}

.preview-relevance i {
  width: 18px;
  height: 6px;
  border-radius: 3px;
  background: var(--accent);
}

.preview-relevance i.off {
  background: var(--sand);
}

.preview-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin: 12px 0;
}

.preview-chips span {
  padding: 3px 10px;
  border-radius: 999px;
  background: var(--accent-tint);
  color: var(--accent);
  font-size: 12px;
  font-weight: 600;
}

.preview-line {
  display: block;
  height: 8px;
  margin-top: 8px;
  border-radius: 4px;
  background: var(--sand);
}

.preview-line-short {
  width: 64%;
}

.preview-source {
  display: inline-block;
  margin-top: 14px;
  font-size: 13px;
  font-weight: 600;
  color: var(--gold);
}

.preview figcaption {
  position: relative;
  margin-top: 10px;
  text-align: right;
  font-size: 12px;
  color: var(--muted);
}

/* -- facts strip ---------------------------------------------------------------- */

.facts {
  background: var(--surface);
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
}

.facts-inner {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 24px;
  padding-top: 34px;
  padding-bottom: 34px;
}

.fact {
  display: flex;
  flex-direction: column;
  gap: 4px;
  text-align: center;
}

.fact strong {
  font-family: var(--serif);
  font-size: 34px;
  font-weight: 600;
  color: var(--accent);
}

.fact span {
  font-size: 15px;
  color: var(--muted);
}

/* -- sections ------------------------------------------------------------------- */

.section {
  padding: 104px 0;
}

.section h2 {
  max-width: 22em;
  font-size: clamp(30px, 3.6vw, 42px);
  color: var(--accent-deep);
}

.steps {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 24px;
  margin: 56px 0 0;
  padding: 0;
  list-style: none;
  counter-reset: none;
}

.step {
  position: relative;
  padding: 32px 28px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
}

.step-number {
  display: inline-grid;
  place-items: center;
  width: 44px;
  height: 44px;
  margin-bottom: 20px;
  border-radius: 50%;
  background: var(--cream);
  border: 1.5px solid var(--gold);
  font-family: var(--serif);
  font-size: 20px;
  font-weight: 600;
  color: var(--gold);
}

.step h3,
.feature h3 {
  font-size: 22px;
  color: var(--accent-deep);
}

.step p,
.feature p {
  margin-top: 10px;
  color: var(--muted);
}

/* trust: the dark band */

.section-trust {
  background:
    radial-gradient(800px 400px at 100% 0%, rgb(185 151 91 / 22%), transparent 70%),
    linear-gradient(160deg, var(--accent-deep), var(--accent));
  color: #eef4f2;
}

.trust-inner {
  display: grid;
  grid-template-columns: minmax(0, 0.9fr) minmax(0, 1.1fr);
  gap: 64px;
  align-items: start;
}

.section-trust h2 {
  color: #fff;
}

.trust-intro > p:last-child {
  margin-top: 22px;
  color: rgb(238 244 242 / 82%);
  font-size: 18px;
}

.eyebrow-light {
  color: var(--gold-soft);
}

.principles {
  display: grid;
  gap: 16px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.principles li {
  display: flex;
  gap: 18px;
  padding: 22px 24px;
  border: 1px solid rgb(255 255 255 / 14%);
  border-radius: var(--radius);
  background: rgb(255 255 255 / 6%);
}

.principles svg {
  flex: none;
  width: 26px;
  height: 26px;
  margin-top: 2px;
  color: var(--gold-soft);
}

.principles h3 {
  font-size: 20px;
  color: #fff;
}

.principles p {
  margin-top: 6px;
  color: rgb(238 244 242 / 80%);
  font-size: 16px;
}

/* features */

.features {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 20px;
  margin-top: 56px;
}

.feature {
  padding: 28px 24px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  transition:
    border-color 0.2s,
    transform 0.2s;
}

.feature:hover {
  border-color: var(--gold-soft);
  transform: translateY(-2px);
}

.feature svg {
  width: 30px;
  height: 30px;
  margin-bottom: 18px;
  color: var(--accent);
}

/* call to action */

.section-cta {
  padding-top: 0;
}

.cta-inner {
  display: flex;
  align-items: center;
  gap: 48px;
}

.cta-inner > * {
  position: relative;
}

.cta-art {
  flex: none;
  width: 200px;
  height: auto;
  color: var(--gold);
  stroke-width: 2;
}

.cta-copy {
  flex: 1;
  padding: 44px 48px;
  border-radius: 24px;
  background:
    radial-gradient(500px 260px at 100% 100%, rgb(213 230 225 / 80%), transparent 70%),
    var(--cream);
  border: 1px solid var(--border);
}

.cta-copy h2 {
  font-size: clamp(28px, 3vw, 36px);
}

.cta-copy p {
  margin: 14px 0 26px;
  max-width: 36em;
  color: var(--muted);
}

.cta-copy .cta-contact {
  margin: 20px 0 0;
  font-size: 15px;
}

.cta-contact a,
.footer-contact a {
  color: var(--accent);
  font-weight: 600;
  text-decoration-color: var(--gold-soft);
  text-underline-offset: 3px;
}

.footer-contact {
  margin-top: 8px;
}

.nowrap {
  white-space: nowrap;
}

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

.site-footer {
  background: var(--sand);
  border-top: 1px solid var(--border);
  font-size: 14px;
  color: var(--muted);
}

.footer-inner {
  display: flex;
  justify-content: space-between;
  gap: 40px;
  padding-top: 40px;
  padding-bottom: 40px;
}

.footer-brand {
  margin-bottom: 4px;
  font-family: var(--serif);
  font-size: 20px;
  font-weight: 600;
  color: var(--accent-deep);
}

.footer-notes {
  max-width: 34em;
  text-align: right;
}

.footer-notes p + p {
  margin-top: 8px;
}

/* -- smaller screens ---------------------------------------------------------- */

@media (max-width: 1000px) {
  .hero-inner,
  .trust-inner {
    grid-template-columns: minmax(0, 1fr);
    gap: 48px;
  }

  .features {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .cta-art {
    display: none;
  }
}

@media (max-width: 760px) {
  body {
    font-size: 16px;
  }

  .wrap {
    padding-left: 16px;
    padding-right: 16px;
  }

  .header-inner {
    height: 60px;
    gap: 12px;
  }

  .header-nav {
    display: none;
  }

  .button-small {
    margin-left: auto;
  }

  .hero-inner {
    padding-top: 44px;
    padding-bottom: 64px;
  }

  .hero h1 {
    font-size: clamp(30px, 8.4vw, 40px);
  }

  .eyebrow {
    font-size: 12px;
    letter-spacing: 0.09em;
  }

  .hero-actions {
    gap: 12px;
  }

  .hero-actions .button,
  .cta-copy .button {
    flex: 1 1 100%;
    justify-content: center;
  }

  .fact + .fact {
    padding-top: 20px;
    border-top: 1px solid var(--border);
  }

  .lead {
    font-size: 17px;
  }

  .preview::before {
    inset: 6% -3% -5% 6%;
  }

  .facts-inner,
  .steps,
  .features {
    grid-template-columns: minmax(0, 1fr);
  }

  .facts-inner {
    gap: 20px;
  }

  .section {
    padding: 72px 0;
  }

  .section-cta {
    padding-top: 0;
  }

  .cta-copy {
    padding: 30px 22px;
  }

  .cta-copy .button {
    display: flex;
  }

  .footer-inner {
    flex-direction: column;
    gap: 16px;
  }

  .footer-notes {
    text-align: left;
  }
}

@media (max-width: 420px) {
  .wordmark {
    font-size: 20px;
    gap: 8px;
  }

  .wordmark-mark {
    width: 28px;
    height: 28px;
  }

  .preview-body {
    padding: 16px;
  }

  .preview-court {
    font-size: 14px;
  }
}

@media (max-width: 380px) {
  .hide-narrow {
    display: none;
  }

  .preview-relevance {
    display: none;
  }
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  .button,
  .feature {
    transition: none;
  }

  .button:hover,
  .feature:hover {
    transform: none;
  }
}
