/* ==========================================================================
   EyeFind — stylesheet
   ========================================================================== */

/* ---------- Tokens ------------------------------------------------------ */
:root {
  color-scheme: light;

  /* Brand colours taken from assets/eyefind-logo.png */
  --ef-teal: #1d7983;
  --ef-teal-strong: #135a62;
  --ef-teal-soft: #e3f2f3;
  --ef-yellow: #f8bc14;
  --ef-yellow-soft: #fef3d0;

  --bg: #ffffff;
  --surface: #f5f7fa;
  --surface-2: #eef1f5;
  --text: #16191d;
  --text-2: #545d69;
  --text-3: #626b77;
  --border: #dde2e8;
  --border-strong: #c3cad3;
  --link: #1d7983;
  --link-visited: #6b3fa0;
  --mark-bg: #feefc0;
  --focus: #1d7983;
  --shadow-pop: 0 6px 20px rgba(20, 30, 50, 0.12), 0 1px 3px rgba(20, 30, 50, 0.08);

  --font: "Segoe UI", system-ui, -apple-system, "Helvetica Neue", Roboto, Arial, sans-serif;
  --fs-xs: 0.8125rem;
  --fs-sm: 0.875rem;
  --fs-md: 1rem;
  --fs-lg: 1.125rem;
  --fs-xl: 1.375rem;
  --fs-2xl: 1.75rem;
  --lh: 1.55;

  --sp-1: 0.25rem;
  --sp-2: 0.5rem;
  --sp-3: 0.75rem;
  --sp-4: 1rem;
  --sp-5: 1.5rem;
  --sp-6: 2rem;
  --sp-7: 3rem;
  --sp-8: 4.5rem;

  --r-sm: 6px;
  --r-md: 10px;
  --r-pill: 999px;

  --page-max: 72rem;
  --measure: 40rem;
  --gutter: 1rem;
  --tap: 44px;
}

@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    color-scheme: dark;
    --ef-teal: #5fc3cc;
    --ef-teal-strong: #9fe0e6;
    --ef-teal-soft: #16302f;
    --ef-yellow: #f8bc14;
    --ef-yellow-soft: #3b3112;
    --bg: #121418;
    --surface: #1a1d23;
    --surface-2: #22262d;
    --text: #e8eaed;
    --text-2: #b0b7c0;
    --text-3: #959da8;
    --border: #2e333b;
    --border-strong: #444b55;
    --link: #5fc3cc;
    --link-visited: #c2a6ff;
    --mark-bg: rgba(248, 188, 20, 0.24);
    --focus: #5fc3cc;
    --shadow-pop: 0 8px 24px rgba(0, 0, 0, 0.5);
  }
}
:root[data-theme="dark"] {
  color-scheme: dark;
  --ef-teal: #5fc3cc;
  --ef-teal-strong: #9fe0e6;
  --ef-teal-soft: #16302f;
  --ef-yellow: #f8bc14;
  --ef-yellow-soft: #3b3112;
  --bg: #121418;
  --surface: #1a1d23;
  --surface-2: #22262d;
  --text: #e8eaed;
  --text-2: #b0b7c0;
  --text-3: #959da8;
  --border: #2e333b;
  --border-strong: #444b55;
  --link: #5fc3cc;
  --link-visited: #c2a6ff;
  --mark-bg: rgba(248, 188, 20, 0.24);
  --focus: #5fc3cc;
  --shadow-pop: 0 8px 24px rgba(0, 0, 0, 0.5);
}

@media (min-width: 48rem) {
  :root { --gutter: 1.5rem; }
}

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

html { -webkit-text-size-adjust: 100%; text-size-adjust: 100%; }

body {
  margin: 0;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  background: var(--bg);
  color: var(--text);
  font-family: var(--font);
  font-size: var(--fs-md);
  line-height: var(--lh);
  overflow-wrap: break-word;
}

main { flex: 1 0 auto; }

h1, h2, h3 { line-height: 1.25; margin: 0 0 var(--sp-3); font-weight: 650; }
h1 { font-size: var(--fs-2xl); letter-spacing: -0.01em; }
h2 { font-size: var(--fs-xl); }
h3 { font-size: var(--fs-lg); }
p { margin: 0 0 var(--sp-4); }

a { color: var(--link); text-underline-offset: 0.15em; }
a:hover { text-decoration-thickness: 2px; }

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

mark {
  background: var(--mark-bg);
  color: inherit;
  border-radius: 2px;
  padding: 0 1px;
}

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

.visually-hidden {
  position: absolute !important;
  width: 1px; height: 1px;
  margin: -1px; padding: 0;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
  border: 0;
}

.skip-link {
  position: absolute;
  left: var(--sp-3);
  top: -100px;
  z-index: 100;
  padding: var(--sp-2) var(--sp-4);
  background: var(--bg);
  color: var(--link);
  border: 2px solid var(--focus);
  border-radius: var(--r-sm);
}
.skip-link:focus { top: var(--sp-3); }

.container {
  width: 100%;
  max-width: var(--page-max);
  margin: 0 auto;
  padding: 0 var(--gutter);
}

/* ---------- Logo -------------------------------------------------------- */
.logo {
  display: inline-flex;
  align-items: center;
  text-decoration: none;
  color: var(--ef-teal);
  border-radius: var(--r-sm);
  flex-shrink: 0;
}
/* assets/eyefind-logo.png is 1366x400; size by height, width follows. */
.logo__img {
  display: block;
  height: 1.75rem;
  width: auto;
}
.logo--hero .logo__img { height: clamp(3.5rem, 15vw, 5.5rem); }

/* ---------- Header ------------------------------------------------------ */
.site-header {
  border-bottom: 1px solid var(--border);
  background: var(--bg);
}
.site-header--home { border-bottom-color: transparent; }

.site-header__inner {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: var(--sp-2) var(--sp-5);
  min-height: 3.5rem;
  padding-top: var(--sp-2);
  padding-bottom: var(--sp-2);
}
.site-header--home .site-header__inner { justify-content: flex-end; }

.site-header__search {
  order: 3;
  flex: 1 1 100%;
  padding-bottom: var(--sp-1);
}

.site-nav { margin-left: auto; }
.site-nav ul {
  display: flex;
  gap: var(--sp-1);
  list-style: none;
  margin: 0;
  padding: 0;
}
.site-nav a {
  display: inline-flex;
  align-items: center;
  min-height: var(--tap);
  padding: 0 var(--sp-3);
  border-radius: var(--r-sm);
  color: var(--text-2);
  font-size: var(--fs-sm);
  font-weight: 550;
  text-decoration: none;
}
.site-nav a:hover { color: var(--text); background: var(--surface); }
.site-nav a[aria-current="page"] {
  color: var(--ef-teal);
  box-shadow: inset 0 -2px 0 var(--ef-yellow);
  border-radius: 0;
}

.site-nav li { display: flex; }

.theme-toggle {
  display: inline-grid;
  place-items: center;
  width: var(--tap);
  height: var(--tap);
  margin-left: var(--sp-1);
  padding: 0;
  border: 1px solid transparent;
  border-radius: 50%;
  background: transparent;
  color: var(--text-2);
  cursor: pointer;
}
.theme-toggle[hidden] { display: none; }
.theme-toggle:hover { color: var(--text); background: var(--surface); border-color: var(--border); }
.theme-toggle svg { width: 1.25rem; height: 1.25rem; }
.theme-toggle__sun,
.theme-toggle[aria-pressed="true"] .theme-toggle__moon { display: none; }
.theme-toggle[aria-pressed="true"] .theme-toggle__sun { display: block; color: var(--ef-yellow); }

/* Phones: keep logo, nav and toggle on one row above the search box. */
@media (max-width: 47.99rem) {
  .site-header__inner { column-gap: var(--sp-3); }
  .site-nav ul { gap: 0; }
  .site-nav a { padding: 0 0.5rem; }
  .theme-toggle { margin-left: 0; }
}
@media (max-width: 23.99rem) {
  .site-header__inner { column-gap: var(--sp-2); }
  .site-nav a { padding: 0 0.35rem; font-size: var(--fs-xs); }
  .theme-toggle { width: 2.5rem; }
  .logo__img { height: 1.375rem; }
}

@media (min-width: 48rem) {
  .site-header__search {
    order: 0;
    flex: 1 1 14rem;
    max-width: 40rem;
    padding-bottom: 0;
  }
}

/* ---------- Search form ------------------------------------------------- */
.search { width: 100%; }

.search__field {
  position: relative;
  display: flex;
  align-items: center;
  background: var(--bg);
  border: 1px solid var(--border-strong);
  border-radius: var(--r-pill);
  transition: border-color 0.15s, box-shadow 0.15s;
}
.search__field:hover { border-color: var(--text-3); }
.search__field:focus-within {
  border-color: var(--ef-teal);
  box-shadow: 0 0 0 3px var(--ef-teal-soft);
}

.search__icon {
  flex: none;
  width: 1.25rem;
  height: 1.25rem;
  margin-left: var(--sp-4);
  color: var(--text-3);
}

.search__input {
  flex: 1 1 auto;
  width: 0; /* ignore the browser's built-in input width so the box can shrink */
  min-width: 0;
  height: 3.25rem;
  padding: 0 var(--sp-3);
  border: 0;
  background: transparent;
  color: var(--text);
  font: inherit;
  font-size: var(--fs-lg);
}
.search__input:focus { outline: none; }
.search__input::placeholder { color: var(--text-3); opacity: 1; }
.search__input::-webkit-search-cancel-button,
.search__input::-webkit-search-decoration { -webkit-appearance: none; appearance: none; }

.search__clear,
.search__go {
  flex: none;
  display: inline-grid;
  place-items: center;
  width: var(--tap);
  height: var(--tap);
  margin-right: var(--sp-1);
  border: 0;
  border-radius: 50%;
  background: transparent;
  color: var(--text-2);
  cursor: pointer;
}
.search__clear:hover,
.search__go:hover { background: var(--surface-2); color: var(--text); }
.search__clear svg,
.search__go svg { width: 1.25rem; height: 1.25rem; }
.search__clear[hidden] { display: none; }
.search__go { color: var(--ef-teal); }

/* Compact variant in the header */
.search--compact .search__input { height: 2.75rem; font-size: var(--fs-md); }
.search--compact .search__icon { display: none; }
.search--compact .search__input { padding-left: var(--sp-4); }

.search__actions {
  display: flex;
  justify-content: center;
  flex-wrap: wrap;
  gap: var(--sp-3);
  margin-top: var(--sp-5);
}

.search__status {
  min-height: 1.5em;
  margin: var(--sp-3) 0 0;
  color: var(--text-2);
  font-size: var(--fs-sm);
  text-align: center;
}
.search__status:empty { min-height: 0; margin: 0; }

.search__noscript {
  margin: var(--sp-4) auto 0;
  max-width: var(--measure);
  padding: var(--sp-3) var(--sp-4);
  border-left: 3px solid var(--ef-yellow);
  background: var(--surface);
  color: var(--text-2);
  font-size: var(--fs-sm);
}

/* Suggestions */
.search__suggestions {
  position: absolute;
  z-index: 20;
  top: calc(100% + 6px);
  left: 0;
  right: 0;
  max-height: min(20rem, 60vh);
  overflow-y: auto;
  margin: 0;
  padding: var(--sp-1) 0;
  list-style: none;
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: var(--r-md);
  box-shadow: var(--shadow-pop);
}
.search__suggestions[hidden] { display: none; }
.suggestion {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 0 var(--sp-3);
  min-height: var(--tap);
  padding: var(--sp-2) var(--sp-4);
  cursor: pointer;
}
.suggestion:hover,
.suggestion[aria-selected="true"] { background: var(--surface-2); }
.suggestion[aria-selected="true"] { box-shadow: inset 3px 0 0 var(--ef-teal); }
.suggestion__name { color: var(--text); }
.suggestion__name mark { background: none; font-weight: 700; padding: 0; }
.suggestion__domain { color: var(--text-3); font-size: var(--fs-sm); }

/* ---------- Buttons ----------------------------------------------------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: var(--sp-2);
  min-height: var(--tap);
  padding: 0 var(--sp-5);
  border: 1px solid transparent;
  border-radius: var(--r-pill);
  font: inherit;
  font-size: var(--fs-sm);
  font-weight: 600;
  text-decoration: none;
  cursor: pointer;
  transition: background-color 0.15s, border-color 0.15s;
}
.btn--primary { background: var(--ef-teal); color: #fff; }
.btn--primary:hover { background: var(--ef-teal-strong); }
:root[data-theme="dark"] .btn--primary { color: #0a2a2e; }
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) .btn--primary { color: #0a2a2e; }
}
.btn--secondary {
  background: var(--surface);
  border-color: var(--border);
  color: var(--text);
}
.btn--secondary:hover { border-color: var(--border-strong); background: var(--surface-2); }
.btn--lucky::before {
  content: "";
  width: 0.55em;
  height: 0.55em;
  border-radius: 50%;
  background: var(--ef-yellow);
  box-shadow: 0 0 0 1px rgba(0, 0, 0, 0.15);
}
.btn--quiet {
  min-height: 2.25rem;
  padding: 0 var(--sp-3);
  background: transparent;
  color: var(--link);
  border-color: transparent;
}
.btn--quiet:hover { background: var(--surface); }

/* ---------- Home -------------------------------------------------------- */
.home-hero {
  padding-top: var(--sp-5);
  padding-bottom: var(--sp-6);
  text-align: center;
}
.home-hero .logo { margin-bottom: var(--sp-4); }
.home-hero__tagline {
  margin: 0 0 var(--sp-5);
  color: var(--text-2);
  font-size: var(--fs-md);
}
.home-hero .search { max-width: 40rem; margin: 0 auto; }

@media (min-width: 48rem) {
  .home-hero { padding-top: 9vh; padding-bottom: var(--sp-7); }
  .home-hero__tagline { margin-bottom: var(--sp-6); }
}
@media (max-height: 34rem) {
  .home-hero { padding-top: var(--sp-3); }
}

.recent {
  max-width: 40rem;
  margin: var(--sp-5) auto 0;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: var(--sp-2);
  font-size: var(--fs-sm);
}
.recent[hidden] { display: none; }
.recent__label { color: var(--text-3); margin-right: var(--sp-1); }
.recent ul { display: contents; list-style: none; }
.recent li { display: contents; }

.chip {
  display: inline-flex;
  align-items: center;
  gap: var(--sp-2);
  min-height: 2.25rem;
  max-width: 100%;
  padding: 0 var(--sp-4);
  border: 1px solid var(--border);
  border-radius: var(--r-pill);
  background: var(--bg);
  color: var(--text);
  font-size: var(--fs-sm);
  text-decoration: none;
  overflow-wrap: anywhere;
}
.chip:hover { border-color: var(--border-strong); background: var(--surface); }
.chip[aria-current="true"],
.chip[aria-current="page"] {
  background: var(--ef-teal-soft);
  border-color: var(--ef-teal);
  color: var(--ef-teal-strong);
  font-weight: 600;
}
.chip__count { color: var(--text-3); font-variant-numeric: tabular-nums; }
.chip[aria-current] .chip__count { color: inherit; }

/* Discovery */
.discover {
  border-top: 1px solid var(--border);
  padding: var(--sp-6) 0 var(--sp-7);
}
.discover__inner { max-width: 56rem; margin: 0 auto; }
.discover h2 {
  font-size: var(--fs-sm);
  font-weight: 650;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--text-2);
  margin-bottom: var(--sp-4);
}
.discover__block + .discover__block { margin-top: var(--sp-6); }
.chip-list {
  display: flex;
  flex-wrap: wrap;
  gap: var(--sp-2);
  margin: 0;
  padding: 0;
  list-style: none;
}

.featured-list {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(15rem, 1fr));
  gap: var(--sp-4) var(--sp-6);
  margin: 0;
  padding: 0;
  list-style: none;
}

.note {
  max-width: var(--measure);
  margin: 0 auto;
  padding: var(--sp-4) var(--sp-5);
  border-left: 3px solid var(--ef-yellow);
  background: var(--surface);
  border-radius: 0 var(--r-sm) var(--r-sm) 0;
  color: var(--text-2);
}
.note p:last-child { margin-bottom: 0; }
.note strong { color: var(--text); }

/* ---------- Listings (search results, Explore, featured) ---------------- */
.listing-list { margin: 0; padding: 0; list-style: none; }
.listing-list > .listing + .listing { margin-top: var(--sp-6); }

.listing { min-width: 0; }
.listing__site {
  display: flex;
  align-items: center;
  gap: var(--sp-3);
  margin-bottom: var(--sp-1);
  min-width: 0;
}
.listing__source { display: flex; flex-direction: column; min-width: 0; line-height: 1.3; }
.listing__name { font-size: var(--fs-sm); color: var(--text); }
.listing__domain {
  font-size: var(--fs-xs);
  color: var(--text-3);
  overflow-wrap: anywhere;
}
.listing__title {
  margin: 0 0 var(--sp-1);
  font-size: var(--fs-lg);
  font-weight: 550;
  line-height: 1.3;
}
.listing__title a { text-decoration: none; }
.listing__title a:hover { text-decoration: underline; }
.listing__title a:visited { color: var(--link-visited); }
.listing__desc { margin: 0; color: var(--text-2); max-width: var(--measure); }
.listing__meta {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: var(--sp-1) var(--sp-2);
  margin: var(--sp-2) 0 0;
  color: var(--text-3);
  font-size: var(--fs-xs);
}
.listing--compact .listing__title { font-size: var(--fs-md); }

.site-icon {
  position: relative;
  flex: none;
  display: inline-grid;
  place-items: center;
  width: 2rem;
  height: 2rem;
  overflow: hidden;
  border-radius: 50%;
  background: var(--ef-teal-soft);
  color: var(--ef-teal-strong);
  font-size: var(--fs-sm);
  font-weight: 700;
  border: 1px solid var(--border);
}
.site-icon img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  background: var(--bg);
}

.badge {
  display: inline-block;
  padding: 0.05rem 0.45rem;
  border-radius: var(--r-sm);
  font-size: 0.75rem;
  font-weight: 650;
  line-height: 1.5;
}
.badge--sponsored { background: var(--surface-2); color: var(--text); border: 1px solid var(--border-strong); }
.badge--featured { background: var(--ef-yellow-soft); color: var(--text); }

/* ---------- Results page ------------------------------------------------ */
.results {
  padding-top: var(--sp-5);
  padding-bottom: var(--sp-7);
}
.results__inner { max-width: 45rem; }

.results__status {
  margin: 0 0 var(--sp-4);
  color: var(--text-2);
  font-size: var(--fs-sm);
  overflow-wrap: anywhere;
}
.results__notice {
  margin: 0 0 var(--sp-5);
  font-size: var(--fs-sm);
  color: var(--text-2);
}

.results__notice--end { margin: var(--sp-7) 0 0; }

.filters {
  margin: 0 0 var(--sp-5);
  padding-bottom: var(--sp-4);
  border-bottom: 1px solid var(--border);
}
.filters__active {
  margin: var(--sp-3) 0 0;
  font-size: var(--fs-sm);
  color: var(--text-2);
}

.sponsored-slot {
  margin: 0 0 var(--sp-6);
  padding: var(--sp-4);
  border: 1px solid var(--border);
  border-radius: var(--r-md);
  background: var(--surface);
}
.sponsored-slot__label {
  margin: 0 0 var(--sp-3);
  font-size: var(--fs-xs);
  font-weight: 650;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--text-2);
}

.empty-state { max-width: var(--measure); padding: var(--sp-4) 0; }
.empty-state h1, .empty-state h2 { font-size: var(--fs-xl); overflow-wrap: anywhere; }
.empty-state p { color: var(--text-2); }
.empty-state__aside { font-size: var(--fs-sm); color: var(--text-3); }
.empty-state__actions {
  display: flex;
  flex-wrap: wrap;
  gap: var(--sp-2);
  margin-top: var(--sp-4);
}

/* ---------- Content pages (About, Privacy, Settings, Explore) ----------- */
.page {
  padding-top: var(--sp-6);
  padding-bottom: var(--sp-7);
}
.page__header { max-width: var(--measure); margin-bottom: var(--sp-6); }
.page__lede { font-size: var(--fs-lg); color: var(--text-2); }

.prose { max-width: var(--measure); }
.prose h2 { margin-top: var(--sp-6); }
.prose ul { padding-left: 1.25rem; margin: 0 0 var(--sp-4); }
.prose li + li { margin-top: var(--sp-2); }

/* Explore */
.explore-nav { margin-bottom: var(--sp-6); }
.explore-section + .explore-section {
  margin-top: var(--sp-7);
}
.explore-section__header {
  margin-bottom: var(--sp-5);
  padding-bottom: var(--sp-3);
  border-bottom: 1px solid var(--border);
}
.explore-section__header p { margin: 0; color: var(--text-2); font-size: var(--fs-sm); }
.explore-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(17rem, 1fr));
  gap: var(--sp-6);
  margin: 0;
  padding: 0;
  list-style: none;
}

/* Settings */
.settings { max-width: var(--measure); }
.setting {
  padding: var(--sp-5) 0;
  border-top: 1px solid var(--border);
}
.setting legend, .setting__label {
  padding: 0;
  margin-bottom: var(--sp-2);
  font-weight: 650;
  font-size: var(--fs-md);
}
fieldset.setting { margin: 0; border: 0; border-top: 1px solid var(--border); min-width: 0; }
fieldset.setting:last-of-type { border-bottom: 1px solid var(--border); }
/* A floated legend sits inside the padding instead of cutting the border. */
fieldset.setting > legend { float: left; width: 100%; }
fieldset.setting > legend + * { clear: both; }
.setting__help { margin: 0 0 var(--sp-3); color: var(--text-2); font-size: var(--fs-sm); }

.choice-row { display: flex; flex-wrap: wrap; gap: var(--sp-2); }
.choice {
  position: relative;
  display: inline-flex;
}
.choice input {
  position: absolute;
  opacity: 0;
  inset: 0;
  margin: 0;
  cursor: pointer;
}
.choice span {
  display: inline-flex;
  align-items: center;
  gap: var(--sp-2);
  min-height: var(--tap);
  padding: 0 var(--sp-4);
  border: 1px solid var(--border-strong);
  border-radius: var(--r-pill);
  font-size: var(--fs-sm);
}
.choice span::before {
  content: "";
  width: 0.9rem;
  height: 0.9rem;
  border: 2px solid var(--border-strong);
  border-radius: 50%;
  flex: none;
}
.choice input:checked + span {
  border-color: var(--ef-teal);
  background: var(--ef-teal-soft);
  font-weight: 600;
}
.choice input:checked + span::before {
  border-color: var(--ef-teal);
  background: radial-gradient(circle, var(--ef-teal) 0 45%, transparent 50%);
}
.choice input:focus-visible + span { outline: 3px solid var(--focus); outline-offset: 2px; }

.select {
  min-height: var(--tap);
  min-width: min(100%, 16rem);
  padding: 0 var(--sp-4);
  border: 1px solid var(--border-strong);
  border-radius: var(--r-sm);
  background: var(--bg);
  color: var(--text);
  font: inherit;
}

.check {
  display: flex;
  align-items: flex-start;
  gap: var(--sp-3);
  min-height: var(--tap);
  cursor: pointer;
}
.check input { width: 1.25rem; height: 1.25rem; margin: 0.15rem 0 0; accent-color: var(--ef-teal); flex: none; }

.setting__status {
  min-height: 1.5em;
  margin: var(--sp-4) 0 0;
  font-size: var(--fs-sm);
  color: var(--text-2);
}
.history-list {
  margin: var(--sp-3) 0;
  padding: 0;
  list-style: none;
  display: flex;
  flex-wrap: wrap;
  gap: var(--sp-2);
}

/* ---------- Footer ------------------------------------------------------ */
.site-footer {
  border-top: 1px solid var(--border);
  background: var(--surface);
  color: var(--text-2);
  font-size: var(--fs-sm);
}
.site-footer__inner {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: var(--sp-2) var(--sp-5);
  padding-top: var(--sp-4);
  padding-bottom: var(--sp-4);
}
.site-footer p { margin: 0; }
.site-footer ul {
  display: flex;
  flex-wrap: wrap;
  gap: 0 var(--sp-1);
  margin: 0;
  padding: 0;
  list-style: none;
}
.site-footer a {
  display: inline-flex;
  align-items: center;
  min-height: var(--tap);
  padding: 0 var(--sp-2);
  color: var(--text-2);
  text-decoration: none;
}
.site-footer a:hover { color: var(--text); text-decoration: underline; }

/* ---------- Motion ------------------------------------------------------ */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    transition-duration: 0.01ms !important;
    animation-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }
}
