/* Linebreakers site. No frameworks, no scripts, no third-party requests.
   Drawn the way the game is: flat colour, a black line round every shape and
   a hard block shadow under it. No soft shadows, glows or glass. The colours
   and typefaces are the game's own (src/ui/ui.gd, assets/fonts/). */

@font-face {
	font-family: "Barlow Condensed";
	src: url("/fonts/display.ttf") format("truetype");
	font-weight: 900;
	font-style: italic;
	font-display: swap;
}
@font-face {
	font-family: "Barlow";
	src: url("/fonts/text.ttf") format("truetype");
	font-weight: 600;
	font-display: swap;
}
@font-face {
	font-family: "Barlow";
	src: url("/fonts/text_bold.ttf") format("truetype");
	font-weight: 700;
	font-display: swap;
}

:root {
	--ink: #0b0c12;
	--night: #161d3a;
	--indigo: #232d63;
	--paper: #f6efe2;
	--dim: #b7bfdb;
	--bolt: #9be4ff;
	--brass: #eeb944;
	--vermilion: #e8573f;
	--teal: #35b8a8;
	--gold: #e9c046;
	--display: "Barlow Condensed", "Arial Narrow", "Helvetica Neue", sans-serif;
	--text: "Barlow", "Avenir Next", "Segoe UI", system-ui, sans-serif;
	--line: 3px solid var(--ink);
	--drop: 6px 7px 0 var(--ink);
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
	margin: 0;
	font-family: var(--text);
	font-weight: 600;
	font-size: 18px;
	line-height: 1.5;
	color: var(--paper);
	background: var(--indigo);
	-webkit-font-smoothing: antialiased;
	overflow-x: hidden;
}

img { max-width: 100%; height: auto; display: block; }
main { overflow-x: clip; }

a { color: var(--bolt); text-underline-offset: 3px; }
a:hover { color: #fff; }
:focus-visible { outline: 4px solid var(--brass); outline-offset: 3px; }

.wrap { width: min(1120px, 100% - 40px); margin-inline: auto; }

h1, h2, h3, .display {
	font-family: var(--display);
	font-weight: 900;
	font-style: italic;
	text-transform: uppercase;
	line-height: 0.95;
	margin: 0;
}

/* lettering on a picture: ivory, an ink line round it, a block shadow */
.inked {
	color: var(--paper);
	-webkit-text-stroke: 0.16em var(--ink);
	paint-order: stroke fill;
	text-shadow: 0.05em 0.07em 0 var(--ink);
}

/* a flat shape with a black line and a block shadow: the game's panel */
.panel {
	background: var(--night);
	border: var(--line);
	border-radius: 8px;
	box-shadow: var(--drop);
}

/* a leaning label, black lettering on colour: the game's banner */
.tag {
	display: inline-block;
	padding: 5px 18px 4px;
	background: var(--brass);
	color: var(--ink);
	border: var(--line);
	box-shadow: 4px 5px 0 var(--ink);
	transform: skewX(-8deg);
	font-family: var(--display);
	font-weight: 900;
	font-style: italic;
	font-size: 20px;
	letter-spacing: 0.04em;
	text-transform: uppercase;
}

/* ------------------------------------------------------------ top bar */

.bar {
	display: flex;
	align-items: center;
	justify-content: space-between;
	padding: 16px 0;
	position: relative;
	z-index: 3;
}
.brand {
	display: inline-flex;
	align-items: center;
	gap: 12px;
	font-family: var(--display);
	font-weight: 900;
	font-style: italic;
	font-size: 26px;
	letter-spacing: 0.03em;
	color: var(--paper);
	text-decoration: none;
}
.brand img { width: 42px; height: 42px; border: var(--line); border-radius: 10px; box-shadow: 3px 4px 0 var(--ink); }
.bar nav { display: flex; gap: 22px; font-weight: 700; font-size: 16px; }
.bar nav a { color: var(--paper); text-decoration: none; }
.bar nav a:hover { color: var(--brass); }

/* ------------------------------------------------------------ opening */

.top {
	position: relative;
	background: var(--ink) url("/img/stormline.webp") center 18% / cover no-repeat;
	border-bottom: var(--line);
}
.top::before {  /* an even darkening, so the name and the words stand out */
	content: "";
	position: absolute;
	inset: 0;
	background: rgba(11, 12, 18, 0.42);
}
.opening {
	position: relative;
	display: grid;
	grid-template-columns: 1.1fr 0.9fr;
	align-items: center;
	gap: 28px;
	padding: 26px 0 64px;
}
.opening h1 { font-size: 0; }  /* the name is the picture; the words stay for readers */
.opening h1 img { width: min(640px, 100%); }
.pitch { margin: 22px 0 0; font-size: clamp(34px, 5vw, 58px); }
.soon { margin-top: 26px; }
/* Apple's and Google's badges, as they are given: no border, shadow or change of colour.
   Google's picture carries its own clear space, so it is drawn larger and pulled in. */
.stores { display: flex; flex-wrap: wrap; align-items: center; gap: 0 16px; margin-top: 22px; }
.store { flex: none; border-radius: 10px; }
.store[hidden] { display: none; }
.store img { display: block; height: 54px; width: auto; max-width: none; }
.store.play img { height: 80px; margin: -13px; }

.phones { position: relative; height: 620px; }
.phone {
	width: 262px;
	aspect-ratio: 660 / 1434;
	border: 4px solid var(--ink);
	border-radius: 30px;
	background: var(--ink);
	overflow: hidden;
	box-shadow: 9px 10px 0 var(--ink);
}
.phone img { width: 100%; height: 100%; object-fit: cover; }
.phones .phone { position: absolute; }
.phones .phone:nth-child(1) { right: 190px; top: 46px; transform: rotate(-5deg); }
.phones .phone:nth-child(2) { right: 0; top: 0; transform: rotate(4deg); }

/* ------------------------------------------------------------ sections */

section { position: relative; padding: 78px 0; }
h2 { margin-top: 18px; font-size: clamp(40px, 6vw, 72px); max-width: 13em; }
.lede { max-width: 34em; margin: 18px 0 0; font-size: 20px; }

/* a band of one of the game's colours with rays turning out of it, as behind
   anything the game announces. Lettering on colour is black. */
.band {
	--c: var(--teal);
	color: var(--ink);
	border-top: var(--line);
	border-bottom: var(--line);
	background: repeating-conic-gradient(from 8deg at 50% 22%,
		var(--c) 0 12.857deg, color-mix(in srgb, var(--c) 89%, #000) 12.857deg 25.714deg);
}
.band .tag { background: var(--paper); }
.band .panel { color: var(--paper); }

.steps { display: grid; grid-template-columns: repeat(3, 1fr); gap: 22px; margin-top: 40px; }
.step { padding: 22px 22px 26px; }
.step h3 { font-size: 34px; color: var(--brass); }
.step p { margin: 8px 0 0; }

/* a few pieces from the game, set out as a small field. Each column is a file,
   and its front is at the top, as your own files are in a battle. */
.demo { display: flex; align-items: flex-start; justify-content: center; gap: 6px; height: 196px; margin-bottom: 14px; }
.demo .file { display: flex; flex-direction: column; gap: 2px; width: 60px; }
.demo img { width: 60px; height: 60px; object-fit: contain; }
.demo .gap { width: 60px; height: 60px; border: 3px dashed var(--brass); border-radius: 6px; }
.demo .lift { animation: lift 2.6s ease-in-out infinite; }
.demo .hot { filter: drop-shadow(0 0 0 var(--bolt)) drop-shadow(0 5px 0 var(--bolt)); }
.plate {
	align-self: center;
	margin-top: 4px;
	padding: 1px 9px 0 3px;
	background: var(--ink);
	border-radius: 16px;
	font-family: var(--display);
	font-weight: 900;
	font-style: italic;
	font-size: 20px;
	white-space: nowrap;
}
.plate i { display: inline-block; width: 24px; margin-right: 5px; border-radius: 50%; background: var(--bolt); color: var(--ink); text-align: center; }

.armies { display: grid; grid-template-columns: repeat(4, 1fr); gap: 22px; margin-top: 44px; }
.army { position: relative; padding: 0 16px 20px; text-align: center; overflow: hidden; }
.army .who { height: 300px; margin: 0 -16px; overflow: hidden; background: var(--c); border-bottom: var(--line); }
.army .who img { width: 100%; height: 100%; object-fit: cover; object-position: 50% 6%; }
.army .crest { width: 54px; height: 62px; object-fit: contain; margin: -34px auto 0; position: relative; filter: drop-shadow(3px 4px 0 var(--ink)); }
.army h3 { margin-top: 8px; font-size: 32px; color: var(--brass); }
.army .lead { margin: 2px 0 10px; color: var(--dim); font-size: 15px; font-weight: 700; letter-spacing: 0.04em; text-transform: uppercase; }
.army p { margin: 0; font-size: 17px; }

.split { display: grid; grid-template-columns: 1.1fr 0.9fr; gap: 44px; align-items: center; }
.facts { list-style: none; margin: 26px 0 0; padding: 0; display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.facts li { padding: 14px 16px 12px; }
.facts b { display: block; font-family: var(--display); font-weight: 900; font-style: italic; font-size: 44px; line-height: 1; color: var(--brass); }
.split .phone { margin-inline: auto; transform: rotate(3deg); width: min(300px, 80%); }

.rows { margin-top: 40px; padding: 6px 24px; }
.row { display: grid; grid-template-columns: 150px 1fr; gap: 18px; align-items: baseline; padding: 16px 0; border-bottom: 2px solid rgba(246, 239, 226, 0.14); }
.row:last-child { border-bottom: 0; }
.row b { font-family: var(--display); font-weight: 900; font-style: italic; font-size: 28px; text-transform: uppercase; color: var(--brass); }

.gallery { display: flex; justify-content: center; gap: 26px; margin-top: 46px; }
.gallery .phone { width: 22%; min-width: 150px; border-radius: 9% / 4.2%; }
.gallery .phone:nth-child(odd) { transform: translateY(18px) rotate(-2deg); }
.gallery .phone:nth-child(even) { transform: translateY(-12px) rotate(2deg); }
.gallery + .lede { margin-top: 52px; }

.price { --c: var(--gold); }
.price .wrap { display: grid; grid-template-columns: 0.9fr 1.1fr; gap: 20px 44px; align-items: center; }
.price h2 { margin-top: 14px; }
.bigline { margin: 0; font-size: clamp(22px, 2.6vw, 30px); font-weight: 700; line-height: 1.3; }

/* ------------------------------------------------------------ documents */

.doc { padding: 34px 0 90px; }
.doc .panel { padding: clamp(22px, 5vw, 50px); max-width: 800px; margin-inline: auto; }
.doc h1 { font-size: clamp(44px, 7vw, 68px); color: var(--brass); }
.doc h2 { font-size: 30px; margin: 36px 0 8px; max-width: none; color: var(--paper); }
.doc ul { padding-left: 22px; }
.doc li { margin: 6px 0; }
.doc .meta { color: var(--dim); font-size: 16px; }
.short {
	margin: 22px 0 6px;
	padding: 16px 20px;
	border: var(--line);
	border-radius: 8px;
	background: var(--teal);
	color: var(--ink);
	font-weight: 700;
}
.contact {
	display: inline-block;
	margin-top: 6px;
	padding: 10px 22px 9px;
	background: var(--brass);
	color: var(--ink);
	border: var(--line);
	box-shadow: 4px 5px 0 var(--ink);
	transform: skewX(-8deg);
	font-weight: 700;
	text-decoration: none;
}
.contact:hover { color: var(--ink); background: var(--paper); }

/* ------------------------------------------------------------ footer */

footer { padding: 30px 0 50px; background: var(--ink); border-top: var(--line); color: var(--dim); font-size: 15px; }
footer .wrap { display: flex; flex-wrap: wrap; gap: 14px 28px; justify-content: space-between; }
footer a { color: var(--dim); margin-left: 20px; }
footer a:first-child { margin-left: 0; }
footer .marks { flex-basis: 100%; font-size: 12px; line-height: 1.5; opacity: 0.8; }

/* ------------------------------------------------------------ motion */

@keyframes lift { 0%, 25%, 100% { translate: 0 0; } 55%, 80% { translate: 0 -16px; } }

@media (prefers-reduced-motion: reduce) {
	* { animation: none !important; scroll-behavior: auto !important; }
}

@media (max-width: 900px) {
	.opening { grid-template-columns: 1fr; padding-bottom: 40px; }
	.phones { height: 470px; }
	.phones .phone { width: 200px; border-radius: 24px; }
	.phones .phone:nth-child(1) { right: auto; left: 2%; top: 34px; }
	.phones .phone:nth-child(2) { right: 2%; }
	.steps, .split, .price .wrap { grid-template-columns: 1fr; }
	.armies { grid-template-columns: 1fr 1fr; }
	.gallery { flex-wrap: wrap; }
	.gallery .phone { width: 42%; }
	section { padding: 56px 0; }
	.bar nav { gap: 16px; }
	.bar nav a { white-space: nowrap; }
}

@media (max-width: 520px) {
	.bar nav .opt, .bar nav a[href="/"] { display: none; }  /* the name itself goes home */
	.brand { font-size: 22px; gap: 9px; }
	.brand img { width: 36px; height: 36px; }
	.tag { font-size: 17px; }
	.armies { grid-template-columns: 1fr; }
	.army .who { height: 340px; }
	.facts { grid-template-columns: 1fr; }
	.row { grid-template-columns: 1fr; gap: 0; }
}
