/* AythurOS Packages — shares the AythurOS website's tokens, type and brand mark.
 * Light, dark and automatic appearance; no external fonts or requests.
 */
:root {
  color-scheme: light;
  --paper: #f4f2ed; --paper-rgb: 244, 242, 237; --ink: #18212a; --ink-soft: #323e49;
  --muted: #58656f; --line: #d7d9d7; --panel: #ebe9e4; --card: #faf9f6;
  --accent: #a67c00; --accent-text: #5c4500; --focus: #8a6500; --button-ink: #ffffff;
  --notice: #fff4d6; --shadow: 0 24px 60px rgba(19, 28, 45, 0.08);
  --sans: Inter, ui-sans-serif, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  --site-width: 1180px;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    color-scheme: dark;
    --paper: #0e151e; --paper-rgb: 14, 21, 30; --ink: #f6f4f0; --ink-soft: #d6dce2;
    --muted: #abb5c1; --line: #344352; --panel: #172330; --card: #192633;
    --accent: #e0b84a; --accent-text: #e0b84a; --focus: #e0b84a; --button-ink: #0e151e;
    --notice: #2a2410; --shadow: 0 24px 60px rgba(0, 0, 0, 0.25);
  }
}
:root[data-theme="dark"] {
  color-scheme: dark;
  --paper: #0e151e; --paper-rgb: 14, 21, 30; --ink: #f6f4f0; --ink-soft: #d6dce2;
  --muted: #abb5c1; --line: #344352; --panel: #172330; --card: #192633;
  --accent: #e0b84a; --accent-text: #e0b84a; --focus: #e0b84a; --button-ink: #0e151e;
  --notice: #2a2410; --shadow: 0 24px 60px rgba(0, 0, 0, 0.25);
}
:root[data-theme="light"] { color-scheme: light; }

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
body {
  margin: 0; min-height: 100vh; display: flex; flex-direction: column;
  background: var(--paper); color: var(--ink); font: 1rem/1.6 var(--sans);
  text-rendering: optimizeLegibility; -webkit-font-smoothing: antialiased;
}
body > * { min-width: 0; }
main { flex: 1; padding-bottom: clamp(48px, 7vw, 96px); }
::selection { background: rgba(201, 162, 61, 0.35); }
a { color: var(--ink); text-underline-offset: .18em; text-decoration-color: var(--accent); }
a:hover { text-decoration-thickness: 2px; }
:focus-visible { outline: 3px solid var(--focus); outline-offset: 4px; border-radius: 3px; }
h1, h2, h3, p { margin-top: 0; }
h1, h2, h3 { line-height: 1.1; letter-spacing: -0.04em; font-weight: 550; }
p { color: var(--ink-soft); }
.muted { color: var(--muted); }
.wrap { width: 100%; max-width: var(--site-width); margin-inline: auto; padding-inline: clamp(20px, 5vw, 72px); }
.skip {
  position: fixed; z-index: 1000; left: 16px; top: 12px; transform: translateY(-200%);
  background: var(--ink); color: var(--paper); padding: 10px 18px; border-radius: 6px; font-weight: 650;
}
.skip:focus { transform: translateY(0); }

/* Header */
header.site {
  position: sticky; top: 0; z-index: 50; border-bottom: 1px solid var(--line);
  background: rgba(var(--paper-rgb), 0.92); backdrop-filter: blur(18px);
}
.header-inner { display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: 12px 28px; min-height: 76px; }
.brand { display: flex; align-items: center; gap: .6rem; text-decoration: none; line-height: 1.1; }
.brand-mark {
  display: inline-block; flex: none; width: 1.55rem; height: 1.9rem; background-color: var(--accent);
  -webkit-mask: url(brand/aythuros-glyph.svg) center / contain no-repeat; mask: url(brand/aythuros-glyph.svg) center / contain no-repeat;
}
.brand-text { display: flex; flex-direction: column; }
.brand-word { font-size: 1.35rem; letter-spacing: -0.075em; font-weight: 750; color: var(--ink); }
.brand-sub { font-size: .62rem; text-transform: uppercase; letter-spacing: .2em; color: var(--muted); margin-top: 4px; }
header.site nav { margin-left: auto; }
nav ul { display: flex; align-items: center; gap: clamp(14px, 2vw, 30px); list-style: none; margin: 0; padding: 0; flex-wrap: wrap; }
nav a { text-decoration: none; color: var(--muted); font-size: .84rem; font-weight: 550; transition: color 180ms ease; }
nav a:hover, nav a[aria-current="page"] { color: var(--ink); }
nav a[aria-current="page"] { text-decoration: underline; text-decoration-color: var(--accent); text-underline-offset: 10px; text-decoration-thickness: 2px; }
.theme-toggle {
  display: inline-flex; align-items: center; gap: 8px; width: auto; min-height: 0; min-width: 82px;
  border: 1px solid var(--line); border-radius: 100px; background: transparent; color: var(--ink);
  padding: 8px 14px; font-size: .76rem; font-weight: 500; cursor: pointer; transition: background-color 180ms ease;
}
.theme-toggle:hover { background: var(--panel); }
.theme-toggle[hidden] { display: none; }
.theme-symbol { font-size: 1.05rem; line-height: 1; }

/* Hero */
.hero { padding-block: clamp(48px, 8vw, 104px) clamp(20px, 3vw, 36px); }
.eyebrow { display: flex; align-items: center; gap: 12px; font-size: .68rem; font-weight: 740; letter-spacing: .22em; text-transform: uppercase; color: var(--muted); margin-bottom: 26px; }
.status-spark { width: 8px; height: 8px; border-radius: 50%; background: var(--accent); box-shadow: 0 0 0 6px rgba(201, 162, 61, .16); }
h1 { font-size: clamp(2rem, 5vw, 3rem); margin: 1.5rem 0 .75rem; overflow-wrap: anywhere; }
.hero h1 { font-size: clamp(2.8rem, 8vw, 5.6rem); letter-spacing: -0.07em; line-height: 1; margin: 0 0 24px; }
.lead { font-size: clamp(1.05rem, 1.6vw, 1.28rem); max-width: 40rem; line-height: 1.7; }
h2 { font-size: 1.35rem; margin: 2.4rem 0 .6rem; }
.notice { background: var(--notice); border: 1px solid var(--line); border-left: 4px solid var(--accent); border-radius: 6px; padding: .8rem 1.1rem; margin: 1.4rem 0; color: var(--ink); font-size: .92rem; }

/* Filters */
form.filters {
  display: grid; grid-template-columns: repeat(auto-fit, minmax(10rem, 1fr)); gap: .85rem 1rem;
  margin: 1.6rem 0; padding: 1.25rem; background: var(--card); border: 1px solid var(--line); border-radius: 14px; box-shadow: var(--shadow);
}
form.filters .search { grid-column: 1 / -1; }
form.filters label { display: block; font-size: .78rem; font-weight: 650; letter-spacing: .02em; margin-bottom: .3rem; color: var(--ink); }
input, select, button { font: inherit; color: var(--ink); background: var(--paper); border: 1px solid var(--muted); border-radius: 8px; padding: .6rem .8rem; min-height: 2.75rem; width: 100%; }
button { cursor: pointer; width: auto; font-weight: 650; border-color: var(--ink); background: var(--ink); color: var(--paper); transition: background 180ms ease, color 180ms ease; }
button:hover { background: var(--accent-text); border-color: var(--accent-text); color: var(--button-ink); }
.status-line { display: flex; flex-wrap: wrap; gap: .5rem 1rem; align-items: center; justify-content: space-between; }
#count { color: var(--muted); font-size: .88rem; margin: 0; }

/* Cards */
#packages { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 22rem), 1fr)); gap: 18px; margin-top: 18px; }
.pkg { background: var(--card); border: 1px solid var(--line); border-radius: 14px; padding: 1.4rem 1.5rem; transition: transform 180ms ease, box-shadow 180ms ease, border-color 180ms ease; }
.pkg:hover { transform: translateY(-2px); box-shadow: var(--shadow); border-color: var(--accent); }
.pkg h2 { margin: 0 0 .4rem; font-size: 1.45rem; overflow-wrap: anywhere; }
.pkg h2 a { text-decoration: none; }
.pkg h2 a:hover { text-decoration: underline; }
.meta { display: flex; flex-wrap: wrap; gap: .2rem 1rem; margin: 0 0 .8rem; padding: 0; list-style: none; font-size: .8rem; }
.rows { list-style: none; margin: .8rem 0 0; padding: 0; font-size: .88rem; }
.rows li { padding: .5rem 0; border-top: 1px solid var(--line); overflow-wrap: anywhere; color: var(--ink-soft); }
.chip { display: inline-block; border: 1px solid var(--accent); border-radius: 999px; padding: 0 .65rem; font-size: .78rem; font-weight: 600; color: var(--ink); margin-right: .25rem; }
#empty { margin-top: 1.5rem; }

/* Detail */
nav[aria-label="Breadcrumb"] { padding-top: 2rem; }
nav[aria-label="Breadcrumb"] a { color: var(--muted); font-size: .84rem; }
dl.facts { display: grid; grid-template-columns: max-content 1fr; gap: .45rem 1.5rem; background: var(--card); border: 1px solid var(--line); border-radius: 14px; padding: 1.25rem 1.5rem; }
dl.facts dt { font-weight: 650; color: var(--muted); font-size: .85rem; }
dl.facts dd { margin: 0; overflow-wrap: anywhere; }
.table-wrap { overflow-x: auto; background: var(--card); border: 1px solid var(--line); border-radius: 14px; }
table { border-collapse: collapse; width: 100%; min-width: 34rem; }
th, td { text-align: left; padding: .7rem 1rem; border-bottom: 1px solid var(--line); vertical-align: top; }
tbody tr:last-child th, tbody tr:last-child td { border-bottom: 0; }
thead th { font-size: .74rem; letter-spacing: .08em; text-transform: uppercase; color: var(--muted); }
caption { text-align: left; font-weight: 650; padding: .8rem 1rem .2rem; color: var(--ink); }
[hidden] { display: none !important; }

/* Footer */
.site-footer { border-top: 1px solid var(--line); background: var(--panel); padding-block: 44px 28px; }
.site-footer .wrap { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 28px 40px; }
.footer-brand .brand-mark { display: block; width: 2rem; height: 2.4rem; margin-bottom: .6rem; }
.footer-brand .brand-word { display: block; font-size: 1.5rem; }
.footer-brand p { font-size: 1.15rem; letter-spacing: -.05em; margin: .8rem 0 0; color: var(--ink); }
.footer-links { display: flex; flex-direction: column; gap: 10px; }
.footer-links a { font-size: .9rem; color: var(--ink); }
.footer-note { flex-basis: 100%; border-top: 1px solid var(--line); padding-top: 20px; margin: 0; font-size: .76rem; color: var(--muted); }

@media (max-width: 40rem) {
  dl.facts { grid-template-columns: 1fr; }
  dl.facts dt { margin-top: .5rem; }
  button { width: 100%; }
  .theme-toggle { width: auto; }
  header.site { position: static; }
}
@media (prefers-reduced-motion: reduce) { *, *::before, *::after { scroll-behavior: auto !important; transition: none !important; } .pkg:hover { transform: none; } }
@media print { header.site, .site-footer, .theme-toggle, form.filters { display: none !important; } }
