@import url('https://fonts.googleapis.com/css2?family=DM+Sans:wght@400;500;600&family=Manrope:wght@500;600;700;800&display=swap');

:root {
  color-scheme: light;
  --paper: #f5f5ee;
  --surface: #fcfcf7;
  --ink: #233b30;
  --muted: #657168;
  --line: #d6ddd2;
  --live: #54805a;
  --restricted: #a17b36;
  --playtest: #8872a5;
  --upcoming: #90958a;
  --focus: #a65b20;
  --icon-bg: #e4e9dc;
  --icon-ink: #527044;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: 2rem; }
body { margin: 0; background: var(--paper); color: var(--ink); font: 16px/1.6 'DM Sans', sans-serif; -webkit-font-smoothing: antialiased; }
a { color: inherit; text-decoration: none; -webkit-tap-highlight-color: transparent; }
a:focus-visible { outline: 3px solid var(--focus); outline-offset: 5px; border-radius: 3px; }
::selection { background: #c4dba9; color: #17331f; }
.wrap { width: min(1280px, calc(100% - 80px)); margin-inline: auto; }
.site-header { display: flex; align-items: center; justify-content: space-between; gap: 20px; min-height: 90px; border-bottom: 1px solid var(--line); }
.wordmark { display: inline-flex; align-items: center; gap: 10px; font: 800 34px/1 'Manrope', sans-serif; letter-spacing: -2px; }
.wordmark svg { width: 28px; height: 28px; }
.header-label { font-size: 14px; color: var(--muted); }
.page-heading { display: flex; justify-content: space-between; align-items: center; flex-wrap: wrap; gap: 20px; padding-block: 32px 25px; }
h1 { display: flex; align-items: center; gap: 12px; margin: 0; font: 600 30px/1.3 'Manrope', sans-serif; letter-spacing: -.04em; }
.project-count { font: 500 14px/1 'DM Sans', sans-serif; letter-spacing: 0; color: var(--muted); border: 1px solid var(--line); border-radius: 6px; padding: 6px 8px; }
.legend { display: flex; flex-wrap: wrap; gap: 12px 22px; list-style: none; padding: 0; margin: 0; color: var(--muted); font-size: 14px; }
.legend li { display: inline-flex; align-items: center; gap: 8px; }
.legend-swatch { width: 25px; height: 18px; border-radius: 3px; display: inline-block; }
.project-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 20px; }
.project-card { display: flex; flex-direction: column; min-width: 0; background: var(--surface); border-radius: 9px; padding: 23px; }
.project-preview { position: relative; margin: -23px -23px 22px; aspect-ratio: 3 / 2; overflow: hidden; border-radius: 6px 6px 0 0; border-bottom: 1px solid var(--line); background: #18221e; }
.project-preview > img { width: 100%; height: 100%; display: block; object-fit: cover; object-position: top; }
.portrait-preview { padding: 12px; background: var(--paper); }
.portrait-preview > img { object-fit: contain; object-position: center; }
.project-preview figcaption { position: absolute; bottom: 9px; left: 9px; padding: 3px 7px; border-radius: 4px; font-size: 12px; color: #f5f5ee; background: #17251ee6; }
.without-logo { min-height: 56px; justify-content: flex-start; }
.without-logo .category { text-align: left; }
.border-live { border: 2px solid var(--live); }
.border-restricted { border: 3px double var(--restricted); }
.border-playtest { border: 2px dotted var(--playtest); }
.border-coming-soon { border: 2px dashed var(--upcoming); }
.card-top { display: flex; align-items: center; justify-content: space-between; gap: 18px; margin-bottom: 19px; }
.project-icon { width: 56px; height: 56px; flex-shrink: 0; display: grid; place-items: center; border-radius: 12px; overflow: hidden; background: var(--icon-bg); color: var(--icon-ink); }
.project-icon img { width: 100%; height: 100%; object-fit: contain; }
.category { font-size: 12px; color: var(--muted); text-align: right; }
h2 { margin: 0; font: 600 22px/1.3 'Manrope', sans-serif; letter-spacing: -.035em; overflow-wrap: anywhere; }
.description { margin: 10px 0 22px; color: var(--muted); font-size: 16px; line-height: 1.6; }
.card-bottom { display: flex; justify-content: space-between; align-items: center; gap: 12px; margin-top: auto; min-height: 44px; }
.status { font-size: 14px; color: var(--muted); }
.project-link { display: inline-flex; align-items: center; justify-content: center; gap: 13px; min-height: 44px; padding: 7px 12px; border-radius: 5px; font-size: 14px; font-weight: 600; background: var(--paper); }
.project-link span { font-size: 19px; }
.project-link:hover { text-decoration: underline; text-underline-offset: 4px; background: var(--icon-bg); }
footer { display: flex; justify-content: space-between; align-items: center; gap: 20px; padding-block: 30px; margin-top: 30px; border-top: 1px solid var(--line); color: var(--muted); font-size: 14px; }
footer a { padding-block: 8px; }
footer a:hover { text-decoration: underline; text-underline-offset: 4px; }
.skip-link { position: fixed; top: -80px; left: 15px; padding: 12px 20px; background: var(--ink); color: var(--paper); z-index: 10; }
.skip-link:focus { top: 15px; }

@media (max-width: 1050px) {
  .project-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .page-heading { align-items: flex-start; flex-direction: column; }
}
@media (max-width: 600px) {
  .wrap { width: calc(100% - 32px); }
  .site-header { min-height: 76px; }
  .wordmark { font-size: 30px; }
  .header-label { font-size: 12px; }
  .page-heading { padding-block: 24px 20px; gap: 16px; }
  h1 { font-size: 27px; }
  .legend { gap: 10px 18px; }
  .project-grid { grid-template-columns: 1fr; gap: 16px; }
  .project-card { padding: 21px; }
  .project-preview { margin: -21px -21px 20px; }
}
@media (prefers-color-scheme: dark) {
  :root {
    color-scheme: dark;
    --paper: #121b17;
    --surface: #1d2921;
    --ink: #e4ecdf;
    --muted: #a5b4a7;
    --line: #35453b;
    --live: #7ba983;
    --restricted: #c5a365;
    --playtest: #b19bce;
    --upcoming: #788376;
    --focus: #e0b87f;
    --icon-bg: #31432d;
    --icon-ink: #b6cd9d;
  }
}
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }
