/* AERODOCK project site. Plain CSS, no build step. */
:root {
	--ink: #0d1b24;
	--ink-soft: #2c3f4b;
	--paper: #ffffff;
	--paper-alt: #f1f5f6;
	--line: #d3dde1;
	--accent: #0b7a75;
	--accent-ink: #075a56;
	--accent-soft: #dff1ef;
	--warn: #b4552d;
	--night: #071218;
	--sans: 'Inter', system-ui, -apple-system, 'Segoe UI', Roboto, sans-serif;
	--mono: 'JetBrains Mono', ui-monospace, Menlo, Consolas, monospace;
	--wrap: 1160px;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: 72px; }
body {
	margin: 0;
	font: 400 18px/1.6 var(--sans);
	color: var(--ink);
	background: var(--paper);
	-webkit-font-smoothing: antialiased;
}
img, video { display: block; max-width: 100%; }
a { color: var(--accent-ink); text-underline-offset: 3px; }
h1, h2, h3 { margin: 0; line-height: 1.12; letter-spacing: -0.02em; font-weight: 700; }
h1 { font-size: clamp(2.4rem, 5.4vw, 4.4rem); }
h2 { font-size: clamp(1.9rem, 3.4vw, 2.8rem); }
h3 { font-size: 1.3rem; letter-spacing: -0.01em; }
p { margin: 0; }
.wrap { width: min(var(--wrap), 100% - 48px); margin-inline: auto; }
.lead { font-size: clamp(1.15rem, 1.6vw, 1.35rem); line-height: 1.55; color: var(--ink-soft); margin-top: 18px; }
.narrow { max-width: 780px; }
.two { display: grid; grid-template-columns: 1fr 1fr; gap: clamp(28px, 5vw, 72px); align-items: start; }

/* ---- navigation */
.nav {
	position: fixed; inset: 0 0 auto 0; z-index: 20;
	display: flex; align-items: center; gap: 28px;
	height: 64px; padding: 0 clamp(20px, 3vw, 40px);
	color: #fff;
	transition: background .25s ease, color .25s ease, box-shadow .25s ease;
}
.nav.solid { background: rgba(255, 255, 255, .94); color: var(--ink); box-shadow: 0 1px 0 var(--line); backdrop-filter: blur(10px); }
.nav .brand { font-weight: 700; letter-spacing: .14em; color: inherit; text-decoration: none; }
.nav nav { display: flex; gap: 26px; margin-left: auto; }
.nav nav a { color: inherit; text-decoration: none; font-size: 1rem; font-weight: 500; white-space: nowrap; }
.nav nav a:hover { text-decoration: underline; }

.button {
	display: inline-flex; align-items: center; justify-content: center;
	min-height: 48px; padding: 0 24px; border-radius: 10px;
	font: 600 1.05rem var(--sans); text-decoration: none;
	border: 2px solid transparent; transition: transform .15s ease, background .15s ease;
}
.button:hover { transform: translateY(-1px); }
.button.primary { background: #fff; color: var(--ink); }
.button.ghost { border-color: rgba(255, 255, 255, .8); color: #fff; }
.button.small { min-height: 38px; padding: 0 16px; font-size: .95rem; border-color: currentColor; color: inherit; }

/* ---- hero */
.hero {
	position: relative; min-height: 100vh; min-height: 100svh;
	display: grid; grid-template-rows: 1fr auto; color: #fff; background: var(--night); overflow: hidden;
}
.hero-media { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.hero-shade { position: absolute; inset: 0; background: linear-gradient(180deg, rgba(4, 12, 16, .55) 0%, rgba(4, 12, 16, .15) 35%, rgba(4, 12, 16, .82) 100%); }
.hero-facts {
	grid-row: 2; position: relative; margin: 0; width: min(var(--wrap), 100% - 48px); margin-inline: auto;
	display: grid; grid-template-columns: repeat(3, 1fr); gap: 0;
	border-top: 1px solid rgba(255, 255, 255, .35);
}
.hero-facts div { padding: 22px 24px 30px 0; }
.hero-facts dt { font-size: clamp(1.5rem, 2.6vw, 2.2rem); font-weight: 700; letter-spacing: -0.02em; }
.hero-facts dd { margin: 4px 0 0; font-size: 1.05rem; }

/* ---- sections */
.band { padding: clamp(72px, 9vw, 128px) 0; }
.band.alt { background: var(--paper-alt); }
.points { list-style: none; margin: 0; padding: 0; display: grid; gap: 22px; }
.points li { padding-left: 22px; border-left: 3px solid var(--accent); }
.points b { display: block; font-size: 1.15rem; }

/* ---- architecture diagram */
.arch { margin-top: 44px; }
.arch-svg { width: 100%; height: auto; color: var(--ink-soft); overflow: visible; }
.arch-svg .node { cursor: pointer; outline: none; }
.arch-svg .node rect { fill: var(--paper); stroke: var(--line); stroke-width: 2; transition: fill .2s ease, stroke .2s ease; }
.arch-svg .node .t { font: 700 26px var(--sans); fill: var(--ink); }
.arch-svg .node .s { font: 500 17px var(--sans); fill: var(--ink-soft); }
.arch-svg .node:hover rect, .arch-svg .node:focus-visible rect { stroke: var(--accent); }
.arch-svg .node.on rect { fill: var(--accent); stroke: var(--accent); }
.arch-svg .node.on .t, .arch-svg .node.on .s { fill: #fff; }
.arch-svg .loop-label { font: 500 17px var(--sans); fill: var(--ink-soft); }
.arch-svg .loop { animation: dash 1.2s linear infinite; }
@keyframes dash { to { stroke-dashoffset: -28; } }
.arch-detail {
	margin-top: 8px; padding: 26px 30px; background: var(--paper); border: 2px solid var(--accent); border-radius: 14px;
	display: grid; grid-template-columns: minmax(0, 1.1fr) minmax(0, 1fr); gap: 32px; min-height: 170px;
}
.arch-detail h3 { margin-bottom: 8px; }
.arch-detail ul { margin: 0; padding: 0; list-style: none; display: grid; gap: 10px; align-content: start; }
.arch-detail li { display: grid; grid-template-columns: 96px 1fr; gap: 12px; font-size: 1rem; }
.arch-detail li b { font: 500 .9rem var(--mono); color: var(--accent-ink); padding-top: 3px; }

.band h3 { margin-top: 0; }
#how h3 { margin-top: 64px; }
#how .arch-detail h3 { margin-top: 0; }
.phases { list-style: none; margin: 24px 0 0; padding: 0; display: grid; grid-template-columns: repeat(6, 1fr); gap: 0; counter-reset: phase; }
.phases li { position: relative; padding: 46px 18px 0 0; counter-increment: phase; }
.phases li::before {
	content: counter(phase); position: absolute; top: 0; left: 0; width: 32px; height: 32px; border-radius: 50%;
	display: grid; place-items: center; background: var(--accent); color: #fff; font: 600 1rem var(--sans); z-index: 1;
}
.phases li::after { content: ''; position: absolute; top: 15px; left: 32px; right: 0; height: 2px; background: var(--line); }
.phases li:last-child::after { display: none; }
.phases b { display: block; font-size: 1.1rem; }
.phases span { display: block; margin-top: 4px; font-size: 1rem; color: var(--ink-soft); line-height: 1.45; }

/* ---- cards */
.cards { display: grid; gap: 28px; margin-top: 44px; }
.cards.two { grid-template-columns: 1fr 1fr; }
.card { margin: 0; background: var(--paper); border: 1px solid var(--line); border-radius: 16px; overflow: hidden; display: flex; flex-direction: column; }
.card-media { position: relative; width: 100%; aspect-ratio: 16 / 10; object-fit: cover; background: #e6ecee; }
.worlds .card-media { aspect-ratio: 16 / 9; }
.card-body { padding: 26px 28px 30px; display: grid; gap: 12px; }
.card-body p { color: var(--ink-soft); }
.specs { margin: 6px 0 0; display: grid; grid-template-columns: 1fr 1fr; gap: 14px 24px; }
.specs div { border-top: 1px solid var(--line); padding-top: 10px; }
.specs dt { font-size: .95rem; color: var(--ink-soft); }
.specs dd { margin: 2px 0 0; font-weight: 600; font-size: 1.1rem; }
.more { font-weight: 600; margin-top: 6px; }
.more::after { content: ' →'; }
.swap img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; transition: opacity .35s ease; }
.swap img + img { opacity: 0; }
.swap.inside img + img { opacity: 1; }
.swap-btn {
	position: absolute; left: 16px; bottom: 16px; min-height: 42px; padding: 0 18px; border-radius: 9px; cursor: pointer;
	font: 600 1rem var(--sans); color: #fff; background: var(--ink); border: 0;
}
.tag { justify-self: start; padding: 4px 12px; border-radius: 99px; font-size: .95rem; font-weight: 600; background: var(--accent-soft); color: var(--accent-ink); }
.tag.test { background: #fdebd9; color: #8a3d18; }

.rates { margin-top: 36px; display: grid; grid-template-columns: repeat(3, 1fr); border: 1px solid var(--line); border-radius: 16px; background: var(--paper); }
.rates div { padding: 22px 28px; border-left: 1px solid var(--line); }
.rates div:first-child { border-left: 0; }
.rates b { display: block; font-size: 1.7rem; letter-spacing: -0.02em; }
.rates span { color: var(--ink-soft); }

/* ---- results chart */
.chart { margin-top: 44px; display: grid; gap: 18px; }
.bar-row { display: grid; grid-template-columns: 250px 1fr 150px; gap: 20px; align-items: center; }
.bar-name b { display: block; font-size: 1.1rem; }
.bar-name span { color: var(--ink-soft); font-size: 1rem; }
.bar-track { height: 44px; background: var(--paper-alt); border-radius: 8px; overflow: hidden; }
.bar-fill { height: 100%; width: 0; border-radius: 8px; background: #9db3bb; transition: width 1.1s cubic-bezier(.2, .8, .2, 1); }
.bar-row.current .bar-fill { background: var(--accent); }
.bar-row.nov .bar-fill { background: #8fbcb9; }
.bar-row.teacher .bar-fill { background: repeating-linear-gradient(135deg, #5f7a84 0 10px, #6c8892 10px 20px); }
.bar-value { text-align: right; }
.bar-value b { display: block; font-size: 1.5rem; letter-spacing: -0.02em; }
.bar-value span { color: var(--ink-soft); font-size: 1rem; }
.bar-row.current .bar-name b::after { content: 'current'; margin-left: 10px; padding: 2px 10px; border-radius: 99px; background: var(--accent-soft); color: var(--accent-ink); font-size: .85rem; font-weight: 600; vertical-align: 2px; }

.results-notes { margin-top: 44px; }
.results-notes h3 { margin-bottom: 8px; }
.results-notes p { color: var(--ink-soft); }
.foot-note { margin-top: 36px; padding-top: 22px; border-top: 1px solid var(--line); max-width: 860px; }

/* ---- story */
.story { list-style: none; margin: 44px 0 0; padding: 0; display: grid; grid-template-columns: repeat(3, 1fr); gap: 18px; }
.story li { background: var(--paper); border: 1px solid var(--line); border-radius: 16px; padding: 24px 22px 26px; }
.story .when { font: 500 .95rem var(--mono); color: var(--accent-ink); }
.story h3 { margin: 10px 0 8px; font-size: 1.2rem; }
.story p { font-size: 1rem; color: var(--ink-soft); line-height: 1.5; }

/* ---- end */
.end { background: var(--night); color: #fff; }
.links-grid { margin-top: 36px; display: grid; grid-template-columns: repeat(4, 1fr); gap: 16px; }
.links-grid a { display: grid; gap: 6px; padding: 24px 22px; border: 1px solid rgba(255, 255, 255, .28); border-radius: 14px; color: #fff; text-decoration: none; transition: background .15s ease, border-color .15s ease; }
.links-grid a:hover { background: rgba(255, 255, 255, .08); border-color: #fff; }
.links-grid b { font-size: 1.15rem; }
.links-grid b::after { content: ' →'; }
.links-grid span { color: rgba(255, 255, 255, .86); font-size: 1rem; line-height: 1.4; }
.footer { background: var(--night); color: #fff; border-top: 1px solid rgba(255, 255, 255, .2); padding: 26px 0; font-size: 1rem; }
.footer .wrap { display: flex; flex-wrap: wrap; gap: 12px 32px; justify-content: space-between; }
.footer a { color: #fff; }

/* ---- reveal */
.reveal { opacity: 0; transform: translateY(18px); transition: opacity .6s ease, transform .6s ease; }
.reveal.in { opacity: 1; transform: none; }

/* ---- responsive */
@media (max-width: 1000px) {
	.phases { grid-template-columns: repeat(3, 1fr); row-gap: 28px; }
	.phases li:nth-child(3)::after { display: none; }
	.story { grid-template-columns: repeat(2, 1fr); }
	.links-grid { grid-template-columns: repeat(2, 1fr); }
	.arch-detail { grid-template-columns: 1fr; gap: 18px; }
}
@media (max-width: 900px) { .nav nav { gap: 18px; } .nav nav a { font-size: .95rem; } }
@media (max-width: 820px) { .nav nav { display: none; } .nav .button { margin-left: auto; } }
@media (max-width: 760px) {
	body { font-size: 17px; }
	.nav nav { display: none; }
	.nav .button { margin-left: auto; }
	.two, .cards.two { grid-template-columns: 1fr; }
	.hero-facts { grid-template-columns: 1fr; }
	.hero-facts div { padding: 14px 0; border-top: 1px solid rgba(255, 255, 255, .2); }
	.hero-facts div:first-child { border-top: 0; }
	.phases { grid-template-columns: 1fr 1fr; }
	.phases li::after { display: none; }
	.rates { grid-template-columns: 1fr; }
	.rates div { border-left: 0; border-top: 1px solid var(--line); }
	.rates div:first-child { border-top: 0; }
	.bar-row { grid-template-columns: 1fr auto; }
	.bar-track { grid-column: 1 / -1; grid-row: 2; height: 30px; }
	.story, .links-grid { grid-template-columns: 1fr; }
	.arch-svg { min-width: 760px; }
	.arch { overflow-x: auto; }
	.arch-detail li { grid-template-columns: 1fr; gap: 2px; }
}
@media (prefers-reduced-motion: reduce) {
	html { scroll-behavior: auto; }
	.reveal { opacity: 1; transform: none; transition: none; }
	.arch-svg .loop { animation: none; }
	.bar-fill { transition: none; }
}

/* ---- play: system check and video ---- */
.band.play { background: var(--ink); color: #e8f1f3; }
.band.play h2 { color: #fff; }
.band.play .lead { color: #c3d3d8; }
.band.play .lead b { color: #fff; }
.play-actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 28px; }
.play-actions button.button { font: inherit; cursor: pointer; }
.play-actions button.button:disabled { opacity: .6; cursor: progress; }
.play-result { margin-top: 26px; padding: 18px 20px; border-radius: 10px; background: rgba(255, 255, 255, .06); border-left: 4px solid #8fa7b0; }
.play-result.good { border-left-color: #3cc7b4; }
.play-result.slow { border-left-color: #f0b44c; }
.play-result.no { border-left-color: #e8746a; }
.play-result .play-title { margin: 0; font-weight: 600; font-size: 1.1rem; color: #fff; }
.play-result ul { margin: 10px 0 0; padding-left: 20px; color: #c3d3d8; }
.play-result .play-note { margin: 10px 0 0; color: #c3d3d8; font-size: .95rem; }
.play-result .play-actions { margin-top: 16px; }
.play-video { margin: 0; }
.play-video video { width: 100%; aspect-ratio: 16 / 9; display: block; border-radius: 10px; background: #000; }
.play-video figcaption { margin-top: 10px; color: #a9bcc2; font-size: .95rem; }
@media (max-width: 860px) { .band.play .two { grid-template-columns: 1fr; } }
