/* Adlegiant: self-contained styles. No external requests. */

@font-face {
  font-family: "Lora";
  src: url("/fonts/lora-var.woff") format("woff");
  font-weight: 400 700;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "Lora";
  src: url("/fonts/lora-italic-var.woff") format("woff");
  font-weight: 400 700;
  font-style: italic;
  font-display: swap;
}

:root {
  --sky: #52A8DC;      /* logo blue: marks and large accents only */
  --harbor: #1C6696;   /* readable blue for links and small accents */
  --ink: #14243D;      /* headings, body, dark band */
  --slate: #4E5B6E;    /* secondary text */
  --mist: #F3F7FA;     /* page background */
  --paper: #FFFFFF;
  --rule: #D5DEE6;

  --serif: "Lora", "Iowan Old Style", "Palatino Linotype", Georgia, serif;
  --sans: system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;

  --step--1: 0.875rem;
  --step-0: 1.0625rem;
  --step-1: 1.25rem;
  --step-2: 1.6rem;
  --step-3: clamp(1.9rem, 1.4rem + 2vw, 2.6rem);
  --headword: clamp(3.4rem, 1.6rem + 8.5vw, 8.5rem);

  --wrap: 1120px;
  --gutter: 24px;
  --section: clamp(4rem, 3rem + 4vw, 7rem);
}

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

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

body {
  margin: 0;
  background: var(--mist);
  color: var(--ink);
  font-family: var(--sans);
  font-size: var(--step-0);
  line-height: 1.6;
  text-rendering: optimizeLegibility;
}

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

a { color: var(--harbor); text-underline-offset: 0.18em; text-decoration-thickness: 1px; }
a:hover { color: var(--ink); }

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

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

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

.skip {
  position: absolute; left: -9999px; top: 0;
  background: var(--ink); color: var(--paper); padding: 0.6rem 1rem; z-index: 10;
}
.skip:focus { left: 1rem; top: 1rem; }

/* Header */
.site-header {
  position: sticky; top: 0; z-index: 5;
  background: rgba(243, 247, 250, 0.92);
  backdrop-filter: saturate(1.4) blur(8px);
  -webkit-backdrop-filter: saturate(1.4) blur(8px);
  border-bottom: 1px solid var(--rule);
}
.header-row { display: flex; align-items: center; gap: 1.5rem; height: 64px; }
.brand {
  display: flex; align-items: center; gap: 0.6rem;
  color: var(--ink); text-decoration: none;
  font-family: var(--serif); font-weight: 600; font-size: 1.2rem;
}
.brand img { width: 34px; height: 34px; }
.header-row nav { margin-left: auto; }
.nav { display: flex; gap: 1.6rem; list-style: none; margin: 0; padding: 0; }
.nav a { color: var(--slate); text-decoration: none; font-size: 0.95rem; }
.nav a:hover { color: var(--ink); }

/* Buttons */
.btn {
  display: inline-block;
  background: var(--ink); color: var(--paper);
  padding: 0.85rem 1.4rem; border-radius: 999px;
  text-decoration: none; font-weight: 600; font-size: 1rem; line-height: 1.2;
  transition: background-color 0.15s ease;
}
.btn:hover { background: var(--harbor); color: var(--paper); }
.btn-small { padding: 0.55rem 1rem; font-size: 0.9rem; }
.link-quiet { color: var(--ink); font-weight: 500; }

/* Hero: a dictionary entry */
.hero { padding: clamp(3rem, 2rem + 5vw, 6.5rem) 0 var(--section); }
.hero-grid {
  display: grid; grid-template-columns: minmax(0, 1fr) clamp(140px, 22vw, 260px);
  gap: clamp(1.5rem, 4vw, 4rem); align-items: start;
}
.headword {
  font-size: var(--headword);
  font-weight: 600;
  letter-spacing: -0.035em;
  line-height: 0.95;
  margin-left: -0.04em;
}
.pron {
  margin: 1rem 0 2rem;
  font-family: var(--serif); font-size: var(--step-1); color: var(--slate);
}
.pron span { margin-right: 0.5rem; }
.senses {
  margin: 0; padding: 0 0 0 1.8rem;
  max-width: 40rem;
  font-family: var(--serif); font-size: var(--step-1); line-height: 1.6;
}
.senses li { padding-left: 0.35rem; margin-bottom: 0.9rem; }
.senses li::marker { font-weight: 700; color: var(--harbor); }
.senses li:last-child { color: var(--slate); font-style: italic; }
.senses em { font-style: italic; color: var(--slate); }

.hero-mark { margin: 0.6rem 0 0; }
.hero-mark img { width: 100%; }

.hero-lede {
  margin-top: clamp(2.5rem, 5vw, 4rem);
  display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 2rem; align-items: end;
  border-top: 1px solid var(--rule); padding-top: 2rem;
}
.lede { margin: 0; max-width: 38rem; font-size: var(--step-0); color: var(--slate); }
.actions { display: flex; align-items: center; gap: 1.4rem; flex-wrap: wrap; }

/* One page-load moment: the senses arrive in order. */
@media (prefers-reduced-motion: no-preference) {
  .senses li { opacity: 0; transform: translateY(6px); animation: arrive 0.6s ease forwards; }
  .senses li:nth-child(1) { animation-delay: 0.15s; }
  .senses li:nth-child(2) { animation-delay: 0.45s; }
  .senses li:nth-child(3) { animation-delay: 0.75s; }
}
@keyframes arrive { to { opacity: 1; transform: none; } }

/* Sections */
.section { padding: var(--section) 0; }
section[id] { scroll-margin-top: 64px; }
.section-title { font-size: var(--step-3); letter-spacing: -0.015em; max-width: 22ch; }
.section-intro { margin: 0.9rem 0 0; max-width: 36rem; color: var(--slate); font-size: var(--step-0); }

/* Services: label column + list column */
#services { background: var(--paper); border-top: 1px solid var(--rule); border-bottom: 1px solid var(--rule); }
#services .section-intro { margin-bottom: 3rem; }
.service {
  display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); gap: 2rem;
  padding: 2rem 0; border-top: 1px solid var(--rule);
}
.service:last-child { border-bottom: 1px solid var(--rule); }
.service-head h3 { font-size: var(--step-2); }
.service-head p { margin: 0.4rem 0 0; color: var(--slate); max-width: 26ch; }
.service-list { margin: 0; padding: 0; list-style: none; columns: 1; }
.service-list li { padding: 0.45rem 0 0.45rem 1.3rem; position: relative; }
.service-list li::before {
  content: ""; position: absolute; left: 0; top: 1.05em;
  width: 0.5rem; height: 2px; background: var(--sky);
}

/* Specialty */
.specialty-grid { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); gap: 2rem; }
.specialty-body > p:first-child { margin-top: 0; font-size: var(--step-1); font-family: var(--serif); line-height: 1.55; }
.checks { margin: 1.5rem 0; padding: 0; list-style: none; }
.checks li { padding: 0.5rem 0 0.5rem 1.9rem; position: relative; border-top: 1px solid var(--rule); }
.checks li:last-child { border-bottom: 1px solid var(--rule); }
.checks li::before {
  content: ""; position: absolute; left: 0.2rem; top: 0.95em;
  width: 0.7rem; height: 0.38rem;
  border-left: 2px solid var(--harbor); border-bottom: 2px solid var(--harbor);
  transform: rotate(-45deg);
}
.note { font-size: var(--step--1); color: var(--slate); }

/* Standard */
.standard {
  margin: 3rem 0 0; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 2.5rem 3.5rem;
}
.standard div { border-left: 3px solid var(--sky); padding-left: 1.25rem; }
.standard dt { font-family: var(--serif); font-weight: 600; font-size: var(--step-1); }
.standard dd { margin: 0.4rem 0 0; color: var(--slate); max-width: 34rem; }

/* Background */
.background { background: var(--paper); border-top: 1px solid var(--rule); border-bottom: 1px solid var(--rule); }
.bg-grid { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); gap: 2rem; }
.results { margin: 0; padding: 0; list-style: none; }
.results li { padding: 1rem 0; border-top: 1px solid var(--rule); color: var(--slate); }
.results li:last-child { border-bottom: 1px solid var(--rule); }
.results strong {
  display: block; margin-bottom: 0.2rem;
  font-family: var(--serif); font-weight: 600; font-size: var(--step-1); color: var(--ink);
}

/* Process: a real sequence, so it is numbered */
.steps {
  counter-reset: step; list-style: none; margin: 3rem 0 0; padding: 0;
  display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 2rem;
}
.steps li { counter-increment: step; padding-top: 1rem; border-top: 2px solid var(--ink); }
.steps li::before {
  content: counter(step);
  display: block; font-family: var(--serif); font-weight: 600; font-size: var(--step-2);
  color: var(--harbor); margin-bottom: 0.6rem;
}
.steps h3 { font-size: var(--step-1); }
.steps p { margin: 0.5rem 0 0; color: var(--slate); font-size: 0.98rem; }

/* Contact band */
.contact { background: var(--ink); color: #E6EEF5; padding: var(--section) 0; }
.contact-grid { display: grid; grid-template-columns: minmax(0, 7fr) minmax(0, 5fr); gap: 3rem; align-items: start; }
.contact h2 { color: var(--paper); font-size: var(--step-3); max-width: 18ch; }
.contact p { max-width: 34rem; color: #C3D1DE; }
.contact .address { margin-top: 1.8rem; }
.contact .address a {
  font-family: var(--serif); font-size: var(--step-2); color: var(--paper);
  text-decoration-color: var(--sky); text-decoration-thickness: 2px; word-break: break-word;
}
.contact .address a:hover { color: var(--sky); }
.contact :focus-visible { outline-color: var(--sky); }
.topics { list-style: none; margin: 0; padding: 0; }
.topic {
  display: block; padding: 1rem 0.25rem;
  border-top: 1px solid rgba(255, 255, 255, 0.18);
  color: var(--paper); text-decoration: none; font-weight: 500;
  transition: color 0.15s ease, padding-left 0.15s ease;
}
.topics li:last-child .topic { border-bottom: 1px solid rgba(255, 255, 255, 0.18); }
.topic:hover { color: var(--sky); padding-left: 0.6rem; }

/* Footer */
.site-footer { background: var(--ink); color: #9FB1C2; border-top: 1px solid rgba(255, 255, 255, 0.12); font-size: var(--step--1); }
.footer-row { display: flex; justify-content: space-between; gap: 1rem; flex-wrap: wrap; padding-top: 1.4rem; padding-bottom: 1.4rem; }
.footer-row p { margin: 0; }

/* 404 */
.notfound { min-height: 70vh; display: grid; align-content: center; padding: 4rem 0; }
.notfound h1 { font-size: var(--step-3); margin: 1.5rem 0 0.8rem; }
.notfound p { color: var(--slate); max-width: 34rem; }

/* Responsive */
@media (max-width: 900px) {
  .steps { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .standard { grid-template-columns: minmax(0, 1fr); }
}
@media (max-width: 760px) {
  :root { --gutter: 16px; }
  .nav { display: none; }
  .header-row { justify-content: space-between; }
  .hero-grid { grid-template-columns: minmax(0, 1fr) 96px; gap: 1rem; }
  .hero-mark { margin-top: 0.2rem; }
  .hero-lede { grid-template-columns: minmax(0, 1fr); }
  .service, .specialty-grid, .bg-grid, .contact-grid { grid-template-columns: minmax(0, 1fr); gap: 1rem; }
  .service-head p { max-width: none; }
  .contact-grid { gap: 2.5rem; }
}
@media (max-width: 520px) {
  .steps { grid-template-columns: minmax(0, 1fr); }
  .hero-grid { grid-template-columns: minmax(0, 1fr); }
  .hero-mark { display: none; }
  .senses { padding-left: 1.9rem; }
}
