/* Egidia shared base styles for sub-pages (category, access, blog, compare).
   index.html and pricing.html keep their inline styles for now to avoid
   regressions; new pages link this file. */

:root {
  --paper: #F4EFE6;
  --paper-deep: #EAE3D2;
  --ink: #141210;
  --ink-muted: #6B6862;
  --ink-subtle: rgba(31,30,27,0.15);
  --ink-faint: rgba(31,30,27,0.06);
  --orange: #E2581F;
  --orange-deep: #B8431A;

  --serif: "Source Serif 4", Charter, "Iowan Old Style", Georgia, serif;
  --sans: "Inter", ui-sans-serif, -apple-system, system-ui, sans-serif;
  --mono: "JetBrains Mono", ui-monospace, Menlo, Consolas, monospace;

  --container: 1240px;
  --eyebrow-tracking: 0.10em;
}

* { box-sizing: border-box; }
html, body { margin: 0; padding: 0; }
html { background: var(--paper); scroll-behavior: smooth; }
body {
  background: var(--paper);
  color: var(--ink);
  font-family: var(--serif);
  font-size: 17px;
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  font-variant-numeric: tabular-nums;
}
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
}
:focus-visible {
  outline: 2px solid var(--orange);
  outline-offset: 3px;
  border-radius: 3px;
}

.page { max-width: var(--container); margin: 0 auto; padding: 0 56px; }
@media (max-width: 900px) { .page { padding: 0 24px; } }

.eyebrow {
  font-family: var(--sans);
  font-size: 12px;
  font-weight: 500;
  letter-spacing: var(--eyebrow-tracking);
  text-transform: uppercase;
  color: var(--ink-muted);
}

h1, h2, h3, h4 { font-family: var(--serif); font-weight: 400; margin: 0; letter-spacing: -0.012em; }

/* HEADER */
header.nav { position: sticky; top: 0; z-index: 50; background: color-mix(in oklab, var(--paper) 92%, transparent); backdrop-filter: saturate(140%); border-bottom: 1px solid transparent; transition: border-color 200ms, height 200ms; }
header.nav.scrolled { border-bottom-color: var(--ink-subtle); }
.nav-row { display: flex; align-items: center; justify-content: space-between; height: 72px; transition: height 200ms; }
header.nav.scrolled .nav-row { height: 56px; }
.brand { display: flex; align-items: center; gap: 12px; font-family: var(--serif); font-size: 22px; font-weight: 500; letter-spacing: -0.01em; text-decoration: none; color: var(--ink); }
.brand .nm { width: 30px; height: 30px; display: inline-grid; place-items: center; }
.brand .nm svg { width: 100%; height: 100%; display: block; }
.nav-items { display: flex; gap: 32px; font-family: var(--sans); font-size: 13px; }
.nav-items a { color: var(--ink-muted); text-decoration: none; transition: color 120ms; }
.nav-items a:hover { color: var(--ink); }
.nav-items a.is-active { color: var(--ink); }
@media (max-width: 900px) { .nav-items { display: none; } }

/* BUTTONS */
.btn { font-family: var(--sans); font-size: 14px; font-weight: 500; padding: 11px 20px; border-radius: 4px; cursor: pointer; transition: background 120ms, color 120ms, border-color 120ms; line-height: 1; display: inline-flex; align-items: center; gap: 8px; border: 1px solid transparent; text-decoration: none; }
.btn-primary { background: var(--orange); color: var(--paper); border-color: var(--orange); }
.btn-primary:hover { background: var(--orange-deep); border-color: var(--orange-deep); }
.btn-secondary { background: transparent; color: var(--ink); border-color: var(--ink); }
.btn-secondary:hover { background: var(--paper-deep); }
.btn-ghost { background: transparent; color: var(--ink); border-color: transparent; padding-left: 0; padding-right: 0; }
.btn-ghost:hover { color: var(--orange-deep); }
.btn .arrow { font-family: var(--serif); font-style: italic; transition: transform 160ms; }
.btn:hover .arrow { transform: translateX(2px); }

/* FOOTER */
footer.foot { background: var(--paper); padding: 72px 0 32px; border-top: 1px solid var(--ink-subtle); }
.foot-cols { display: grid; grid-template-columns: 1.6fr repeat(3, 1fr); gap: 32px; }
@media (max-width: 900px) { .foot-cols { grid-template-columns: 1fr 1fr; } }
.foot-cols h5 { font-family: var(--sans); font-size: 11px; font-weight: 500; letter-spacing: var(--eyebrow-tracking); text-transform: uppercase; color: var(--ink-muted); margin: 0 0 14px; }
.foot-cols ul { list-style: none; padding: 0; margin: 0; display: grid; gap: 10px; font-family: var(--serif); font-size: 15px; }
.foot-cols ul a { color: var(--ink); text-decoration: none; }
.foot-cols ul a:hover { color: var(--orange-deep); }
.foot-brand-blurb { font-family: var(--serif); font-size: 15px; color: var(--ink-muted); max-width: 280px; margin-top: 18px; }
.foot-rule {
  height: 0; border: 0; border-top: 2px dotted var(--orange);
  margin: 48px 0 18px; opacity: 0.55;
}
.foot-bottom { display: flex; justify-content: space-between; flex-wrap: wrap; gap: 16px; font-family: var(--sans); font-size: 12px; color: var(--ink-muted); }
.foot-bottom a { color: var(--ink-muted); text-decoration: none; }
.foot-bottom a:hover { color: var(--ink); }
.foot-bottom .made { display: flex; gap: 16px; align-items: center; }
.foot-bottom .made .pill { padding: 3px 8px; border: 1px solid var(--ink-subtle); border-radius: 2px; }

/* SECTION SHELL (re-usable on sub-pages) */
section.s { padding: 80px 0; border-top: 1px solid var(--ink-subtle); }
section.s.alt { background: var(--paper-deep); }
.s-head { margin-bottom: 48px; }
.s-head--centered { text-align: center; max-width: 880px; margin-left: auto; margin-right: auto; }
.s-num { font-family: var(--sans); font-size: 11px; color: var(--ink-muted); letter-spacing: var(--eyebrow-tracking); text-transform: uppercase; }
.s-num .num { font-family: var(--mono); font-size: 14px; font-weight: 500; color: var(--ink); margin-right: 12px; }
.s-head--centered .s-num { display: block; margin-bottom: 18px; }
.s-title { font-size: clamp(30px, 3.4vw, 46px); font-weight: 400; letter-spacing: -0.018em; line-height: 1.1; max-width: 720px; }
.s-title em { font-style: italic; color: var(--orange); }
.s-head--centered .s-title { max-width: 760px; margin: 0 auto; }
.s-lede { font-family: var(--serif); color: var(--ink-muted); font-size: 17px; line-height: 1.5; max-width: 540px; margin-top: 16px; }
.s-head--centered .s-lede { max-width: 560px; margin: 16px auto 0; }
