/* policity.net. The game's own colours and its interface font, DM Sans, throughout. Gradients carry the light: the
   town's evening over the hero, warm glows on the dark sections, and the logo's red and blue for left and right. */

@font-face { font-family: 'DM Sans'; src: url('/fonts/dmsans.woff2') format('woff2'); font-weight: 400 800; font-style: normal; font-display: swap; }

:root {
  --paper: #f1e9d8;
  --paper-2: #e8dec8;
  --ink: #221f1a;
  --muted: #5d5447;
  --night: #15130f;
  --cream: #f6efe0;
  --cream-muted: #cbc1b0;
  --accent: #e88a63;
  --accent-2: #d9714d;
  --red: #e0584a;
  --gold: #e9b768;
  --blue: #6f9fe8;
  --sans: 'DM Sans', system-ui, -apple-system, 'Segoe UI', sans-serif;
  --wrap: 1160px;
  --gutter: clamp(18px, 4vw, 44px);
  --r: 6px;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; background: var(--paper); color: var(--ink); font: 400 18px/1.65 var(--sans); -webkit-font-smoothing: antialiased; }
img, video { display: block; max-width: 100%; height: auto; }
a { color: inherit; text-underline-offset: 0.2em; text-decoration-thickness: 1.5px; }
:focus-visible { outline: 3px solid var(--accent); outline-offset: 3px; }
.skip { position: absolute; left: 12px; top: -60px; z-index: 30; background: var(--cream); color: var(--ink); padding: 8px 14px; font-weight: 600; }
.skip:focus { top: 12px; }
.wrap { max-width: var(--wrap); margin: 0 auto; padding-inline: var(--gutter); }

h1, h2, h3 { font-weight: 800; line-height: 1.1; margin: 0; }
h2 { font-size: clamp(30px, 3.8vw, 44px); margin-bottom: 16px; }
h3 { font-size: 22px; }
p { margin: 0 0 14px; }

/* the logo's red and blue, through the evening's gold */
.grad-text {
  background: linear-gradient(90deg, var(--red), var(--gold) 52%, var(--blue));
  -webkit-background-clip: text; background-clip: text; color: transparent;
}

.btn {
  display: inline-block; font: 700 16px/1 var(--sans); padding: 16px 24px; border-radius: var(--r); text-decoration: none;
  color: #1d1a16; background: linear-gradient(180deg, #f0a07d, var(--accent) 55%, var(--accent-2));
  box-shadow: 0 8px 22px -10px rgba(232, 138, 99, 0.8);
  transition: transform 0.15s ease, box-shadow 0.15s ease;
}
.btn:hover { transform: translateY(-1px); box-shadow: 0 12px 26px -10px rgba(232, 138, 99, 0.9); }
.btn-small { padding: 10px 15px; font-size: 14px; box-shadow: none; }
.textlink { font-weight: 700; }

/* the top bar: over the hero on the home page, on paper elsewhere */
.top { display: flex; align-items: center; gap: 28px; padding: 18px var(--gutter); background: var(--night); color: var(--cream); }
.top.over { position: absolute; inset: 0 0 auto 0; z-index: 5; background: transparent; }
.top .brand img { width: 132px; height: auto; }
.top nav { display: flex; gap: 26px; margin-left: auto; font-size: 15px; font-weight: 600; }
.top nav a { text-decoration: none; opacity: 0.92; }
.top nav a:hover { opacity: 1; text-decoration: underline; }
.top.on-paper { background: var(--paper); color: var(--ink); }
@media (max-width: 720px) {
  .top nav { display: none; }
  .top .btn-small { margin-left: auto; }
  .top .brand img { width: 108px; }
}

/* the hero: the town in the afternoon, the evening coming up from below */
.hero { position: relative; min-height: min(94vh, 920px); display: grid; align-items: end; background: var(--night); color: var(--cream); overflow: hidden; }
.hero > img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; object-position: 60% 42%; }
.hero::after {
  content: ''; position: absolute; inset: 0;
  background:
    linear-gradient(180deg, rgba(21, 19, 15, 0.62) 0%, rgba(21, 19, 15, 0) 18%),
    linear-gradient(90deg, rgba(21, 19, 15, 0.72) 0%, rgba(21, 19, 15, 0.25) 45%, rgba(21, 19, 15, 0) 70%),
    linear-gradient(0deg, #15130f 0%, rgba(21, 19, 15, 0.86) 22%, rgba(21, 19, 15, 0) 58%);
}
.hero-text { position: relative; z-index: 2; width: 100%; padding-block: 0 clamp(44px, 8vh, 88px); }
.hero h1 { margin: 0 0 22px; }
.hero h1 img { width: min(540px, 80vw); filter: drop-shadow(0 12px 24px rgba(0, 0, 0, 0.5)); }
.hero-tag { font-size: clamp(28px, 3.6vw, 42px); font-weight: 800; line-height: 1.1; margin: 0 0 10px; }
.hero-sub { font-size: clamp(19px, 2vw, 23px); font-weight: 700; margin: 0 0 6px; display: inline-block; }
.hero-note { color: var(--cream-muted); margin: 0 0 30px; }
.cta { display: flex; flex-wrap: wrap; align-items: center; gap: 14px 28px; }
.hero .textlink { color: var(--cream); }
@media (max-width: 720px) { .hero { min-height: 700px; } }

/* paper sections: a soft fall of light down the page */
.paper { background: linear-gradient(180deg, var(--paper) 0%, var(--paper-2) 100%); }
.intro { padding-block: clamp(56px, 8vw, 104px); }
.intro p { font-size: clamp(22px, 2.4vw, 28px); font-weight: 500; line-height: 1.45; max-width: 34em; margin: 0; }

/* dark sections: the game's own ground, with a warm glow like its title screen */
.dark { color: var(--cream); background: radial-gradient(120% 90% at 50% 0%, #2e271f 0%, var(--night) 62%); }
.band { padding-block: clamp(56px, 8vw, 104px); }

/* the trailer */
.trailer-wrap h2 { text-align: center; margin-bottom: 26px; }
.trailer { position: relative; aspect-ratio: 16 / 9; background: #000; border-radius: 10px; overflow: hidden; box-shadow: 0 40px 80px -40px rgba(0, 0, 0, 0.9); }
.trailer .poster { position: absolute; inset: 0; display: block; }
.trailer .poster img { width: 100%; height: 100%; object-fit: cover; transition: transform 0.6s ease; }
.trailer .poster::after { content: ''; position: absolute; inset: 0; background: radial-gradient(circle at 50% 50%, rgba(21, 19, 15, 0) 0%, rgba(21, 19, 15, 0.45) 100%); }
.trailer .poster:hover img { transform: scale(1.02); }
.trailer .poster .play {
  position: absolute; z-index: 2; left: 50%; top: 50%; width: 92px; height: 92px; margin: -46px 0 0 -46px;
  border-radius: 50%; display: grid; place-items: center;
  background: linear-gradient(180deg, #f0a07d, var(--accent-2)); box-shadow: 0 14px 34px -10px rgba(0, 0, 0, 0.7);
  transition: transform 0.2s ease;
}
.trailer .poster:hover .play { transform: scale(1.06); }
.trailer .poster .play::after { content: ''; margin-left: 6px; border-left: 24px solid #1d1a16; border-top: 15px solid transparent; border-bottom: 15px solid transparent; }
.trailer iframe, .trailer video { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; }

/* features: big pictures, short text */
.features { padding-block: clamp(48px, 7vw, 96px); }
.feature { display: grid; grid-template-columns: minmax(0, 1.55fr) minmax(0, 1fr); gap: 28px clamp(32px, 5vw, 72px); align-items: center; padding-block: clamp(26px, 4vw, 52px); }
.feature:nth-child(even) { grid-template-columns: minmax(0, 1fr) minmax(0, 1.55fr); }
.feature:nth-child(even) .shot { order: 2; }
.feature p { color: var(--muted); font-size: 18.5px; }
@media (max-width: 860px) {
  .feature, .feature:nth-child(even) { grid-template-columns: 1fr; }
  .feature:nth-child(even) .shot { order: 0; }
}
.shot { margin: 0; }
.shot img { border-radius: var(--r); box-shadow: 0 30px 60px -32px rgba(34, 31, 26, 0.6), 0 2px 6px rgba(34, 31, 26, 0.08); }
.shot figcaption { font-size: 14.5px; line-height: 1.45; color: var(--muted); margin-top: 12px; }
.dark .shot figcaption, .politics .shot figcaption { color: var(--cream-muted); }
.politics .shot img { box-shadow: 0 40px 80px -40px rgba(0, 0, 0, 0.95); }

/* left and right: the band tinted red on one side and blue on the other */
.politics { background: linear-gradient(90deg, rgba(207, 69, 53, 0.26) 0%, rgba(21, 19, 15, 0) 42%, rgba(21, 19, 15, 0) 58%, rgba(59, 111, 181, 0.3) 100%), var(--night); color: var(--cream); }
.sides { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.7fr); gap: 28px clamp(32px, 5vw, 72px); align-items: center; }
.sides p { color: var(--cream-muted); }
@media (max-width: 860px) { .sides { grid-template-columns: 1fr; } }

/* the dev blog */
.section-head { display: flex; align-items: baseline; justify-content: space-between; gap: 16px; flex-wrap: wrap; margin-bottom: 22px; }
.section-head a { font-weight: 700; font-size: 15px; }
.stories { display: grid; grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); gap: 36px 44px; }
.story { text-decoration: none; display: block; }
.story img { aspect-ratio: 16 / 9; object-fit: cover; border-radius: var(--r); margin-bottom: 16px; box-shadow: 0 24px 44px -28px rgba(34, 31, 26, 0.55); transition: transform 0.3s ease; }
.story:hover img { transform: translateY(-3px); }
.story time { display: block; font-size: 14px; font-weight: 600; color: var(--muted); margin-bottom: 6px; }
.story h3 { margin-bottom: 8px; }
.story p { color: var(--muted); font-size: 17px; margin: 0; }
.story:hover h3 { text-decoration: underline; text-underline-offset: 0.15em; }

/* contact */
.contact-band { color: var(--cream); background: radial-gradient(90% 120% at 100% 0%, #33291f 0%, var(--night) 60%); }
.contact { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 28px clamp(32px, 5vw, 72px); align-items: start; }
.contact p { color: var(--cream-muted); }
.contact ul { list-style: none; margin: 0; padding: 0; }
.contact li { margin-bottom: 16px; }
.contact li a { font-weight: 800; font-size: 20px; }
.contact li span { color: var(--cream-muted); margin-left: 10px; }
@media (max-width: 860px) { .contact { grid-template-columns: 1fr; } }

.foot { background: var(--night); color: var(--cream-muted); font-size: 14.5px; }
.foot .wrap { display: flex; flex-wrap: wrap; gap: 10px 28px; align-items: center; padding-block: 24px 30px; }
.foot nav { display: flex; flex-wrap: wrap; gap: 20px; margin-left: auto; }
.foot p { margin: 0; }
.foot .tm { flex-basis: 100%; font-size: 13px; opacity: 0.8; }

/* blog pages */
.blog-head { padding-block: clamp(44px, 6vw, 72px) 28px; }
.blog-head h1 { font-size: clamp(40px, 5.4vw, 60px); margin-bottom: 12px; }
.blog-head p { color: var(--muted); margin: 0; font-size: 20px; }
.blog-list { padding-bottom: 88px; }

.post { max-width: 720px; margin: 0 auto; padding: clamp(40px, 6vw, 72px) var(--gutter) 24px; }
.post h1 { font-size: clamp(38px, 5.2vw, 56px); margin-bottom: 14px; }
.post .meta { font-size: 15px; font-weight: 600; color: var(--muted); margin-bottom: 18px; }
.standfirst { font-size: 22px; font-weight: 500; line-height: 1.45; color: var(--muted); margin-bottom: 30px; }
.post .shot { margin: 32px 0; }
.post-body { font-size: 18.5px; line-height: 1.7; }
.post-body h2 { font-size: 27px; margin: 1.7em 0 0.5em; }
.post-body p, .post-body li { margin: 0 0 1em; }
.post-body ul { padding-left: 1.2em; }
.signoff { font-weight: 800; font-size: 18px; margin: 2em 0 0; }
.refs { max-width: 720px; margin: 0 auto; padding: 8px var(--gutter) 64px; }
.refs h2 { font-size: 20px; margin-bottom: 10px; }
.refs ol { margin: 0; padding-left: 1.3em; font-size: 15.5px; line-height: 1.55; color: var(--muted); }
.refs li { margin-bottom: 8px; }
.more-posts { padding-block: 36px 80px; }

.lost { min-height: 60vh; display: grid; place-items: center; text-align: center; padding: 64px var(--gutter); }
.lost p { color: var(--muted); }

/* the wiki */
.wiki { display: grid; grid-template-columns: 220px minmax(0, 1fr); gap: 32px clamp(32px, 5vw, 64px); padding-block: clamp(36px, 5vw, 64px) 88px; }
.wiki-nav ul { list-style: none; margin: 0; padding: 0; position: sticky; top: 20px; }
.wiki-nav li { margin: 0 0 4px; }
.wiki-nav a { display: block; padding: 7px 12px; border-radius: var(--r); text-decoration: none; font-size: 15.5px; font-weight: 600; color: var(--muted); }
.wiki-nav a:hover { color: var(--ink); background: rgba(34, 31, 26, 0.06); }
.wiki-nav a[aria-current] { color: var(--ink); background: linear-gradient(90deg, rgba(224, 88, 74, 0.18), rgba(111, 159, 232, 0.18)); }
.wiki-body { max-width: 780px; min-width: 0; }
.wiki-body h1 { font-size: clamp(36px, 4.6vw, 52px); margin-bottom: 18px; }
.wiki-body h2 { font-size: 26px; margin: 1.6em 0 0.5em; }
.wiki-body h3 { font-size: 20px; margin: 1.4em 0 0.4em; }
.wiki-body p, .wiki-body li { margin: 0 0 0.9em; }
.wiki-body ul, .wiki-body ol { padding-left: 1.3em; margin: 0 0 1em; }
.wiki-body code { font-size: 0.9em; background: rgba(34, 31, 26, 0.07); padding: 1px 6px; border-radius: 4px; overflow-wrap: anywhere; }
.wiki-body .table { overflow-x: auto; margin: 0 0 1.4em; }
.wiki-body table { width: 100%; border-collapse: collapse; font-size: 16px; line-height: 1.45; }
.wiki-body th { text-align: left; font-weight: 800; padding: 10px 12px; background: rgba(34, 31, 26, 0.07); }
.wiki-body td { padding: 9px 12px; vertical-align: top; border-top: 1px solid rgba(34, 31, 26, 0.1); }
.wiki-body tbody tr:nth-child(even) td { background: rgba(255, 255, 255, 0.3); }
.spoiler { background: var(--ink); color: transparent; border-radius: 3px; cursor: pointer; transition: background 0.2s ease, color 0.2s ease; }
.spoiler * { color: transparent; }
.spoiler:hover, .spoiler:focus { background: rgba(34, 31, 26, 0.08); color: inherit; outline: none; }
.spoiler:hover *, .spoiler:focus * { color: inherit; }
@media (max-width: 860px) {
  .wiki { grid-template-columns: 1fr; }
  .wiki-nav ul { position: static; display: flex; flex-wrap: wrap; gap: 6px; }
  .wiki-nav li { margin: 0; }
  .wiki-nav a { padding: 6px 10px; font-size: 14px; background: rgba(34, 31, 26, 0.05); }
}

/* Reddit and Discord, beside the hero's buttons (icons: Simple Icons, CC0) */
.social { display: inline-flex; gap: 10px; }
.social a { display: grid; place-items: center; width: 44px; height: 44px; border-radius: 50%; color: var(--cream); background: rgba(246, 239, 224, 0.12); transition: background 0.15s ease, color 0.15s ease, transform 0.15s ease; }
.social a:hover { background: var(--accent); color: #1d1a16; transform: translateY(-1px); }
