/* Shared styles for unhingedredflags.com (v2, Nov 20 2026). Page-specific rules stay inline in each page.
   Palette: crimson is the brand (flat bands, never a glow), white reading pages, wine-black ink, amber =
   flags you can live with (the app's own two flag colours). Type (v3, Nov 20): Anybody for display (variable width 50-150%: headlines are set condensed and
   stretch as they move), Familjen Grotesk for text. Both OFL, self-hosted in /fonts.
   Rules from the redesign review: real product UI instead of drawings, one idea per screen, no fade-in
   on scroll, motion staggered (never everything at once), no violet. */
@font-face {
  font-family: "Anybody";
  src: url("/fonts/anybody.woff2") format("woff2");
  font-weight: 100 900;
  font-stretch: 50% 150%;
  font-display: swap;
}
@font-face {
  font-family: "Familjen Grotesk";
  src: url("/fonts/familjen-grotesk.woff2") format("woff2");
  font-weight: 400 700;
  font-display: swap;
}
:root {
  --paper: #ffffff;
  --blush: #fdecef;
  --ink: #1a1215;
  --ink-2: #4a3d42;
  --muted: #6e6166;
  --line: #ecdfe2;
  --crimson: #c8102e;
  --crimson-deep: #9b0c24;
  --on-crimson: #fff4f6;
  --amber: #e9a23b;
  --amber-ink: #7a4e00;
  --night: #1a1215;
  --app: #121012;
  --app-2: #1d191b;
  --app-line: #2c2629;
  --display: "Anybody", "Arial Narrow", system-ui, sans-serif;
  --body: "Familjen Grotesk", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Arial, sans-serif;
  --ease: cubic-bezier(.2, .8, .2, 1);
}
* { box-sizing: border-box; }
html { background: var(--paper); color: var(--ink); -webkit-text-size-adjust: 100%; }
body { margin: 0; font-family: var(--body); font-size: 17px; line-height: 1.6; -webkit-font-smoothing: antialiased; }
a { color: var(--crimson-deep); text-underline-offset: 3px; text-decoration-thickness: 1.5px; }
a:hover { color: var(--crimson); }
:focus-visible { outline: 3px solid var(--amber); outline-offset: 3px; border-radius: 6px; }
.wrap { max-width: 1160px; margin: 0 auto; padding: 0 24px; }
.prose { max-width: 720px; }
.skip { position: absolute; left: 12px; top: -60px; z-index: 50; background: var(--ink); color: #fff; padding: 10px 16px; border-radius: 10px; }
.skip:focus { top: 12px; color: #fff; }

/* Header */
.site-head { position: sticky; top: 0; z-index: 20; background: rgba(255, 255, 255, .92); backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px); border-bottom: 1px solid var(--line); }
.site-head .wrap { display: flex; align-items: center; gap: 12px 28px; min-height: 68px; flex-wrap: wrap; padding-top: 8px; padding-bottom: 8px; }
.brand { display: flex; align-items: center; gap: 10px; color: var(--ink); text-decoration: none; font-family: var(--display); font-stretch: 85%; font-weight: 800; font-size: 20px; letter-spacing: -.015em; margin-right: auto; }
.brand:hover { color: var(--ink); }
.brand .mark { flex: none; width: 34px; height: 34px; border-radius: 10px; background: url(/icons/icon-192.png) center / cover no-repeat; } /* a CSS background, not an <img>: it sits next to the word RedFlags, so it adds nothing for screen readers, and an <img> with empty alt was flagged as missing alt text */
.brand small { font-weight: 480; color: var(--muted); font-size: 15px; }
.site-head ul { display: flex; flex-wrap: wrap; gap: 2px 22px; list-style: none; margin: 0; padding: 0; }
.site-head nav a { color: var(--ink-2); text-decoration: none; font-size: 15px; font-weight: 550; padding: 10px 0; display: inline-block; background: linear-gradient(var(--crimson), var(--crimson)) left calc(100% - 4px) / 0 2px no-repeat; transition: background-size .25s var(--ease), color .15s; }
.site-head nav a:hover, .site-head nav a[aria-current] { color: var(--ink); background-size: 100% 2px; }

/* Buttons: one solid style, one quiet style */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 52px; padding: 0 26px; border-radius: 14px; font-weight: 700; font-size: 17px; text-decoration: none; background: var(--crimson); color: #fff; box-shadow: 0 2px 0 var(--crimson-deep); transition: transform .15s var(--ease), box-shadow .15s var(--ease), background .15s; }
.btn:hover { color: #fff; background: #d61f3f; transform: translateY(-2px); box-shadow: 0 4px 0 var(--crimson-deep); }
.btn:active { transform: translateY(1px); box-shadow: 0 1px 0 var(--crimson-deep); }
.btn.small { min-height: 42px; padding: 0 18px; font-size: 15px; border-radius: 12px; }
.btn.light { background: #fff; color: var(--crimson-deep); box-shadow: 0 2px 0 rgba(80, 0, 15, .35); }
.btn.light:hover { background: #fff; color: var(--crimson); box-shadow: 0 4px 0 rgba(80, 0, 15, .35); }
.btn.ghost { background: transparent; color: var(--ink); box-shadow: inset 0 0 0 1.5px var(--line); }
.btn.ghost:hover { color: var(--ink); box-shadow: inset 0 0 0 1.5px var(--ink); transform: translateY(-2px); }
.btn.outline-light { background: transparent; color: #fff; box-shadow: inset 0 0 0 1.5px rgba(255, 255, 255, .75); }
.btn.outline-light:hover { background: rgba(255, 255, 255, .1); color: #fff; box-shadow: inset 0 0 0 1.5px #fff; }
.btn-row { display: flex; flex-wrap: wrap; gap: 12px; align-items: center; }

/* Text pages */
main.page { padding: 56px 0 88px; }
h1, h2, h3 { font-family: var(--display); font-stretch: 78%; letter-spacing: -.015em; color: var(--ink); }
main.page h1 { font-size: clamp(40px, 6.4vw, 68px); line-height: .98; font-weight: 850; font-stretch: 70%; animation: title-in .45s var(--ease) both; margin: 0 0 20px; }
main.page h2 { font-size: clamp(25px, 3.4vw, 34px); line-height: 1.12; font-weight: 750; margin: 52px 0 12px; }
main.page h3 { font-size: 21px; font-weight: 700; margin: 30px 0 6px; }
p, li { color: var(--ink-2); }
strong { color: var(--ink); }
.lede { font-size: clamp(18px, 2.3vw, 21px); color: var(--ink); margin: 0 0 28px; }
.answer { background: var(--blush); border-radius: 18px; padding: 20px 24px; margin: 0 0 32px; }
.answer p { margin: 0; color: var(--ink); }
.tablebox { overflow-x: auto; margin: 14px 0 10px; border: 1px solid var(--line); border-radius: 16px; }
table { width: 100%; border-collapse: collapse; font-size: 15px; }
th, td { text-align: left; padding: 12px 14px; border-bottom: 1px solid var(--line); vertical-align: top; }
tr:last-child td { border-bottom: 0; }
th { color: var(--ink); font-weight: 700; background: #fbf5f6; }
td { color: var(--ink-2); }
details { border: 1px solid var(--line); border-radius: 16px; padding: 16px 20px; margin: 0 0 10px; background: #fff; transition: border-color .15s; }
details:hover { border-color: #d9c4c9; }
details[open] { border-color: var(--ink); }
summary { cursor: pointer; font-weight: 700; color: var(--ink); list-style: none; display: flex; justify-content: space-between; gap: 16px; }
summary::-webkit-details-marker { display: none; }
summary::after { content: "+"; color: var(--crimson); font-size: 22px; line-height: 1; transition: transform .2s var(--ease); }
details[open] summary::after { transform: rotate(45deg); }
details p { margin: 10px 0 0; }
.tag { display: inline-block; font-size: 13px; font-weight: 700; padding: 3px 10px; border-radius: 999px; margin-left: 6px; vertical-align: middle; }
.ok { background: #fdf1dc; color: var(--amber-ink); }
.no { background: var(--blush); color: var(--crimson-deep); }
.updated { font-size: 14px; color: var(--muted); margin-top: 40px; }

/* Footer */
.site-foot { background: var(--night); padding: 48px 0 60px; font-size: 14px; }
.site-foot p { color: #bfb1b5; }
.site-foot strong { color: #fff; }
.site-foot a { color: #fff; }
.site-foot .links { display: flex; flex-wrap: wrap; gap: 6px 20px; margin: 0 0 16px; padding: 0; list-style: none; }
.site-foot .links a { color: #e8dde0; text-decoration: none; display: inline-block; padding: 6px 0; }
.site-foot .links a:hover { color: #fff; text-decoration: underline; }

/* Page titles fade up into place. Not font-stretch: animating the width re-wrapped a 2–3 line title on
   every frame, so moving between pages looked like a flicker (Nov 29 recording). The homepage hero keeps
   stretch-in on its one-line spans, which can't re-wrap. */
@keyframes title-in { from { opacity: 0; transform: translateY(10px); } }
@keyframes stretch-in { from { opacity: 0; font-stretch: 130%; transform: translateY(14px); } }

@media (max-width: 680px) {
  .brand small { display: none; }
  .site-head { position: static; }
  .site-head .wrap { gap: 4px 12px; }
  .site-head nav { order: 3; width: 100%; overflow-x: auto; scrollbar-width: none; margin: 0 -24px; padding: 0 24px; }
  .site-head nav::-webkit-scrollbar { display: none; }
  .site-head ul { flex-wrap: nowrap; gap: 20px; white-space: nowrap; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; }
}
