:root {
  color-scheme: light;
  --navy: #071b32;
  --navy-soft: #0d2949;
  --blue: #1766a8;
  --cyan: #54c7df;
  --signal: #f0a44b;
  --ink: #0b2138;
  --muted: #647386;
  --paper: #edf2f3;
  --surface: #f9fbfa;
  --line: #bfcbd0;
  --radius: 0;
  --shadow: 0 1.5rem 4rem rgb(1 20 39 / 18%);
  font-family: "IBM Plex Sans", Inter, "Noto Sans SC", "PingFang SC", system-ui, sans-serif;
  background: var(--paper);
  color: var(--ink);
}

* { box-sizing: border-box; }
html { min-width: 20rem; scroll-behavior: smooth; }
body { margin: 0; min-height: 100vh; overflow-x: hidden; background-color: var(--paper); background-image: linear-gradient(rgb(11 72 114 / 6%) 1px, transparent 1px), linear-gradient(90deg, rgb(11 72 114 / 6%) 1px, transparent 1px); background-size: 2rem 2rem; line-height: 1.7; }
body, button { font: inherit; }
a { color: inherit; text-decoration: none; }
a:hover { color: var(--blue); }
a:focus-visible, button:focus-visible { outline: 3px solid var(--signal); outline-offset: 3px; }
img { display: block; max-width: 100%; }

.site-container { width: min(100% - 3rem, 80rem); margin-inline: auto; }
.narrow-container { width: min(100% - 3rem, 60rem); }
.visually-hidden { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0; }
.eyebrow, .page-code, .section-code { margin: 0; color: var(--cyan); font-family: ui-monospace, SFMono-Regular, Menlo, monospace; font-size: .7rem; font-weight: 750; letter-spacing: .14em; text-transform: uppercase; }

.site-header { position: sticky; z-index: 30; top: 0; border-bottom: 1px solid rgb(84 199 223 / 55%); background: rgb(7 27 50 / 96%); color: #fff; backdrop-filter: blur(12px); }
.header-inner { display: flex; min-height: 4.75rem; align-items: center; justify-content: space-between; gap: 2rem; }
.site-brand { display: inline-flex; min-width: 0; align-items: center; gap: .9rem; font-weight: 760; letter-spacing: .01em; }
.brand-name { overflow: hidden; max-width: 21rem; text-overflow: ellipsis; white-space: nowrap; }
.brand-symbol { display: grid; width: 2.1rem; height: 2.1rem; grid-template-columns: repeat(3, 1fr); gap: 3px; padding: .35rem; border: 1px solid var(--cyan); transform: rotate(-3deg); }
.brand-symbol i { background: var(--cyan); }
.brand-symbol i:nth-child(2) { height: 70%; align-self: end; }
.brand-symbol i:nth-child(3) { height: 42%; align-self: end; }
.site-nav { display: flex; align-items: center; gap: .4rem; }
.site-nav a { padding: .65rem 1rem; border: 1px solid transparent; color: #d6e5ed; font-size: .88rem; font-weight: 650; }
.site-nav a:hover, .site-nav a.is-active { border-color: var(--cyan); background: rgb(84 199 223 / 10%); color: #fff; }
.nav-toggle { display: none; width: 2.75rem; height: 2.75rem; padding: .65rem; border: 1px solid var(--cyan); background: transparent; color: #fff; }
.nav-toggle > span:not(.visually-hidden) { display: block; height: 1px; margin: .27rem 0; background: currentColor; }

.hero-section { position: relative; overflow: hidden; padding: clamp(4rem, 8vw, 8rem) 0; background-color: var(--navy); background-image: linear-gradient(rgb(84 199 223 / 10%) 1px, transparent 1px), linear-gradient(90deg, rgb(84 199 223 / 10%) 1px, transparent 1px); background-size: 3rem 3rem; color: #fff; }
.hero-section::after { position: absolute; right: -8rem; bottom: -13rem; width: 28rem; height: 28rem; content: ""; border: 1px solid rgb(84 199 223 / 40%); border-radius: 50%; box-shadow: 0 0 0 4rem rgb(84 199 223 / 4%), 0 0 0 8rem rgb(84 199 223 / 3%); }
.hero-grid { position: relative; z-index: 2; display: grid; grid-template-columns: minmax(0, 1fr) minmax(22rem, .95fr); align-items: center; gap: clamp(3rem, 8vw, 7rem); }
.hero-copy h1 { max-width: 11ch; margin: 1.25rem 0 0; font-size: clamp(3rem, 7vw, 6.6rem); font-weight: 760; letter-spacing: -.065em; line-height: .98; }
.hero-description { max-width: 36rem; margin: 1.75rem 0 0; color: #afc4d1; font-size: clamp(1rem, 1.7vw, 1.18rem); }
.hero-coordinate { display: flex; width: min(100%, 18rem); align-items: center; gap: .75rem; margin-top: 2.5rem; color: var(--cyan); font-family: ui-monospace, SFMono-Regular, Menlo, monospace; font-size: .68rem; }
.hero-coordinate i { height: 1px; flex: 1; background: var(--cyan); }
.cover-slot { position: relative; display: block; overflow: hidden; aspect-ratio: 16 / 10; border: 1px solid var(--cyan); background: var(--navy-soft); }
.cover-slot img { position: absolute; z-index: 2; inset: 0; width: 100%; height: 100%; object-fit: cover; filter: saturate(.85) contrast(1.03); transition: transform .45s ease; }
.cover-slot:hover img { transform: scale(1.025); }
.cover-slot img.is-broken { display: none; }
.cover-fallback { position: absolute; inset: 0; background-color: var(--navy-soft); background-image: linear-gradient(rgb(84 199 223 / 13%) 1px, transparent 1px), linear-gradient(90deg, rgb(84 199 223 / 13%) 1px, transparent 1px); background-size: 2rem 2rem; }
.cover-fallback::before, .cover-fallback::after, .cover-fallback i, .cover-fallback b { position: absolute; content: ""; border: 1px solid rgb(84 199 223 / 65%); }
.cover-fallback::before { inset: 11%; clip-path: polygon(0 75%, 26% 30%, 48% 54%, 72% 8%, 100% 43%, 100% 100%, 0 100%); background: rgb(84 199 223 / 12%); }
.cover-fallback::after { top: 9%; left: 9%; width: 1rem; height: 1rem; border-right: 0; border-bottom: 0; }
.cover-fallback i { right: 9%; bottom: 9%; width: 1rem; height: 1rem; border-top: 0; border-left: 0; }
.cover-fallback b { top: 50%; left: 7%; width: 86%; height: 1px; border: 0; background: rgb(84 199 223 / 35%); }
.hero-visual { box-shadow: 1.25rem 1.25rem 0 rgb(84 199 223 / 10%); }
.hero-feature { position: absolute; z-index: 3; inset: 0; display: flex; align-items: end; color: #fff; }
.hero-feature::after { position: absolute; z-index: 3; inset: 42% 0 0; content: ""; background: linear-gradient(transparent, rgb(4 20 37 / 94%)); }
.hero-caption { position: relative; z-index: 4; display: grid; gap: .35rem; width: 100%; padding: clamp(1.1rem, 3vw, 2rem); }
.hero-caption small { color: var(--cyan); font-family: ui-monospace, SFMono-Regular, Menlo, monospace; font-size: .7rem; letter-spacing: .1em; }
.hero-caption strong { max-width: 30rem; font-size: clamp(1.25rem, 2.3vw, 1.9rem); line-height: 1.3; }

.home-sections { padding: clamp(4rem, 9vw, 9rem) 0; }
.home-section + .home-section { margin-top: clamp(5rem, 10vw, 10rem); }
.section-heading { display: grid; grid-template-columns: auto minmax(0, 1fr) auto; align-items: end; gap: 2rem; margin-bottom: 1.5rem; padding: 1.25rem; border: 1px solid var(--line); background: var(--surface); }
.section-code { align-self: start; color: var(--blue); writing-mode: vertical-rl; }
.section-heading h2, .page-heading h1, .article-heading h1 { margin: 0; font-weight: 760; letter-spacing: -.045em; line-height: 1.08; }
.section-heading h2 { font-size: clamp(2rem, 4.5vw, 4.2rem); }
.section-heading p { max-width: 42rem; margin: .8rem 0 0; color: var(--muted); }
.section-link { display: grid; width: 3.25rem; height: 3.25rem; place-items: center; border: 1px solid var(--ink); font-size: 1.35rem; }
.section-link:hover { border-color: var(--blue); background: var(--blue); color: #fff; }
.card-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); border-top: 1px solid var(--line); border-left: 1px solid var(--line); }
.content-card { min-width: 0; border-right: 1px solid var(--line); border-bottom: 1px solid var(--line); background: var(--surface); }
.card-cover { aspect-ratio: 4 / 3; border: 0; border-bottom: 1px solid var(--line); }
.card-body { padding: 1.35rem; }
.card-meta { display: flex; align-items: center; gap: .75rem; margin: 0 0 .75rem; color: var(--blue); font-family: ui-monospace, SFMono-Regular, Menlo, monospace; font-size: .68rem; }
.card-meta i { height: 1px; flex: 1; background: var(--line); }
.card-body h3, .list-card-body h2 { margin: 0; font-size: 1.26rem; line-height: 1.35; }
.card-body > p:last-child, .list-card-body > p { margin: .8rem 0 0; color: var(--muted); font-size: .92rem; }

.page-main { padding: 1.25rem 0 clamp(5rem, 10vw, 9rem); }
.breadcrumbs { margin-bottom: 2rem; color: var(--muted); font-size: .8rem; }
.breadcrumbs a { color: var(--blue); }
.page-heading { position: relative; margin: clamp(3rem, 7vw, 7rem) 0 2.5rem; padding: clamp(2rem, 5vw, 4rem); overflow: hidden; border: 1px solid var(--line); background: var(--surface); }
.page-heading::after { position: absolute; top: 0; right: 0; width: 28%; height: 100%; content: ""; border-left: 1px solid var(--line); background-image: linear-gradient(rgb(11 72 114 / 8%) 1px, transparent 1px), linear-gradient(90deg, rgb(11 72 114 / 8%) 1px, transparent 1px); background-size: 1.5rem 1.5rem; }
.page-code { position: relative; z-index: 2; color: var(--blue); }
.page-heading h1 { position: relative; z-index: 2; max-width: 11ch; margin-top: 1rem; font-size: clamp(3rem, 7vw, 6.8rem); }
.page-heading > p:last-child { position: relative; z-index: 2; max-width: 40rem; margin: 1.25rem 0 0; color: var(--muted); }
.list-grid { border-top: 1px solid var(--ink); }
.list-card { display: grid; grid-template-columns: 3rem minmax(16rem, .4fr) minmax(0, .6fr); gap: 1.5rem; padding: 1.5rem 0; border-bottom: 1px solid var(--line); }
.list-number { padding-top: .4rem; color: var(--blue); font-family: ui-monospace, SFMono-Regular, Menlo, monospace; font-size: .72rem; }
.list-cover { aspect-ratio: 16 / 10; border-color: var(--line); }
.list-card-body { align-self: center; }
.list-card-body h2 { font-size: clamp(1.5rem, 3vw, 2.4rem); }
.read-link { display: inline-flex; gap: .75rem; margin-top: 1.25rem; color: var(--blue); font-family: ui-monospace, SFMono-Regular, Menlo, monospace; font-size: .72rem; font-weight: 750; letter-spacing: .08em; }
.pagination { display: flex; flex-wrap: wrap; justify-content: center; gap: .35rem; margin-top: 3rem; }
.pagination a, .pagination span { display: inline-grid; min-width: 2.7rem; min-height: 2.7rem; padding: .25rem .6rem; place-items: center; border: 1px solid var(--line); background: var(--surface); font-family: ui-monospace, SFMono-Regular, Menlo, monospace; font-size: .78rem; }
.pagination a:hover, .pagination .active { border-color: var(--blue); background: var(--blue); color: #fff; }

.article-panel { border: 1px solid var(--line); background: var(--surface); }
.article-heading { position: relative; padding: clamp(2rem, 6vw, 5rem); overflow: hidden; border-bottom: 1px solid var(--line); }
.article-heading::after { position: absolute; top: -5rem; right: -5rem; width: 15rem; height: 15rem; content: ""; border: 1px solid var(--line); border-radius: 50%; box-shadow: 0 0 0 2.5rem rgb(23 102 168 / 4%); }
.article-heading h1 { position: relative; z-index: 2; max-width: 18ch; margin-top: 1rem; font-size: clamp(2.4rem, 6vw, 5.2rem); }
.article-heading > p:last-child, .article-meta { position: relative; z-index: 2; color: var(--muted); }
.article-cover { width: calc(100% - clamp(2rem, 8vw, 7rem)); margin: clamp(1rem, 4vw, 3.5rem) auto 0; aspect-ratio: 16 / 9; border-color: var(--line); }
.article-body { padding: clamp(2rem, 6vw, 5rem); color: #334a5d; font-size: clamp(1rem, 1.6vw, 1.08rem); }
.article-body > :first-child { margin-top: 0; }
.article-body h2, .article-body h3 { margin: 2.2em 0 .8em; color: var(--ink); line-height: 1.35; }
.article-body p { margin: 1.2em 0; }
.article-body a { color: var(--blue); text-decoration: underline; text-underline-offset: .2em; }
.article-body img, .article-inline-cover { width: 100%; aspect-ratio: 16 / 9; margin: 2rem 0; border: 1px solid var(--line); object-fit: cover; background: var(--navy-soft); }
.article-adjacent { display: grid; grid-template-columns: 1fr 1fr; border-top: 1px solid var(--line); }
.article-adjacent > * { display: grid; gap: .4rem; min-width: 0; padding: 1.5rem clamp(1.5rem, 4vw, 3rem); }
.article-adjacent > :last-child { border-left: 1px solid var(--line); text-align: right; }
.article-adjacent small { color: var(--blue); font-family: ui-monospace, SFMono-Regular, Menlo, monospace; font-size: .66rem; letter-spacing: .08em; }
.article-adjacent strong { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

.site-footer { padding-top: clamp(4rem, 8vw, 7rem); background-color: var(--navy); background-image: linear-gradient(rgb(84 199 223 / 8%) 1px, transparent 1px), linear-gradient(90deg, rgb(84 199 223 / 8%) 1px, transparent 1px); background-size: 2rem 2rem; color: #b7cad5; }
.footer-head { display: flex; align-items: center; gap: 1.5rem; padding-bottom: 2rem; border-bottom: 1px solid rgb(84 199 223 / 35%); }
.footer-head p { margin: 0; color: #fff; font-size: clamp(2rem, 5vw, 4.8rem); font-weight: 760; letter-spacing: -.05em; line-height: 1; }
.footer-cross { position: relative; width: 2.6rem; height: 2.6rem; flex: 0 0 auto; border: 1px solid var(--cyan); }
.footer-cross::before, .footer-cross::after { position: absolute; top: 50%; left: 50%; content: ""; background: var(--cyan); transform: translate(-50%, -50%); }
.footer-cross::before { width: 1.5rem; height: 1px; }
.footer-cross::after { width: 1px; height: 1.5rem; }
.footer-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 2rem; padding-top: 3rem; }
.footer-group h2 { margin: 0 0 1rem; color: var(--cyan); font-family: ui-monospace, SFMono-Regular, Menlo, monospace; font-size: .68rem; letter-spacing: .1em; }
.footer-group ul { display: grid; gap: .65rem; margin: 0; padding: 0; list-style: none; }
.footer-group li, .footer-group a { color: #b7cad5; }
.footer-group a:hover { color: #fff; }
.footer-bottom { margin-top: 3rem; padding: 1.35rem 0; border-top: 1px solid rgb(84 199 223 / 35%); font-size: .78rem; }
.footer-bottom p { margin: 0; }

@media (max-width: 64rem) {
  .card-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .footer-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

@media (max-width: 48rem) {
  .site-container, .narrow-container { width: min(100% - 1.25rem, 80rem); }
  .header-inner { min-height: 4.2rem; }
  .brand-name { max-width: 13rem; }
  .nav-toggle { display: block; }
  .site-nav { position: absolute; top: calc(100% + 1px); right: .625rem; left: .625rem; display: none; gap: .25rem; padding: .6rem; border: 1px solid var(--cyan); background: var(--navy); box-shadow: var(--shadow); }
  .site-nav.is-open { display: grid; }
  .site-nav a { display: block; }
  .hero-grid { grid-template-columns: 1fr; }
  .hero-copy h1 { font-size: clamp(2.8rem, 15vw, 5rem); }
  .hero-visual { width: calc(100% - 1rem); box-shadow: .65rem .65rem 0 rgb(84 199 223 / 12%); }
  .section-heading { grid-template-columns: 1fr auto; }
  .section-code { grid-column: 1 / -1; writing-mode: horizontal-tb; }
  .card-grid, .footer-grid { grid-template-columns: 1fr; }
  .page-heading::after { width: 35%; opacity: .55; }
  .list-card { grid-template-columns: 2rem minmax(0, 1fr); gap: 1rem; }
  .list-cover, .list-card-body { grid-column: 2; }
  .list-number { grid-row: 1 / 3; }
  .article-heading h1 { font-size: clamp(2.3rem, 12vw, 4rem); }
  .article-adjacent { grid-template-columns: 1fr; }
  .article-adjacent > :last-child { border-top: 1px solid var(--line); border-left: 0; text-align: left; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { transition-duration: .01ms !important; }
}
