/* BIRD IS THE WORD LEFT BY THE WINDOW (Wave 110o).
 * He can't roost and won't land, so the world is the room he has just left: one pale plaster wall from top to
 * foot (no banner band), the name going up the wall the way he went, and the tall casement he opened, standing
 * off-centre: the lower sash raised, a muslin curtain lifting in the draught, one feather on the sill, nobody
 * in it. The sky outside is the reader's own hour (scripts/bird-window.js). Type is Avenir, light and quick,
 * with an italic for his log. No web fonts. */

body[data-world="bird"] {
  --bg: #e9e8e2; --surface: #e1e0d8; --surface2: #f4f3ee; --text: #24272b; --muted: #6c7076; --dim: #c9c8bf;
  --amber: #3f6f9c; --amber2: #3f6f9c; --ember: #3f6f9c; --glow: rgba(63, 111, 156, .06);
  --w-accent: #3f6f9c; --w-accent2: #24272b;
  --paint: #fbfbf7; --sky-a: #dfe6ec; --sky-b: #eef1f3;
  --nav-bg: rgba(233, 232, 226, .95);
  --f-display: 'Avenir Next', Avenir, 'Segoe UI', 'Helvetica Neue', sans-serif;
  --f-label: 'Avenir Next', Avenir, 'Segoe UI', 'Helvetica Neue', sans-serif;
  --f-body: 'Iowan Old Style', 'Palatino Linotype', Palatino, Georgia, serif;
  --f-num: ui-monospace, 'SF Mono', Menlo, Consolas, monospace;
  font-family: var(--f-body); font-size: 16px; color: var(--text);
  background-color: var(--bg);
  background-image: radial-gradient(rgb(0 0 0 / .018) 1px, transparent 1.4px), radial-gradient(rgb(255 255 255 / .35) 1px, transparent 1.4px);
  background-size: 7px 7px, 11px 11px; background-position: 0 0, 3px 5px;
}
body[data-world="bird"]::before { opacity: .2; mix-blend-mode: multiply; }
html[data-bird-sky="night"] body[data-world="bird"] { --sky-a: #18203a; --sky-b: #3a4670; }
html[data-bird-sky="first"] body[data-world="bird"] { --sky-a: #9fb8d8; --sky-b: #f3c9a8; }
html[data-bird-sky="day"] body[data-world="bird"] { --sky-a: #7fb6e4; --sky-b: #d9ecf8; }
html[data-bird-sky="last"] body[data-world="bird"] { --sky-a: #6f6a9a; --sky-b: #f0a878; }

body[data-world="bird"] .banner-block {
  background: none; border-bottom: 0; min-height: 0; height: min(640px, calc(100vh - 70px)); padding: 3.4rem 3rem 2.6rem;
  display: grid; grid-template-columns: auto minmax(0, 1fr) minmax(0, 420px); grid-template-rows: 1fr auto; column-gap: 3rem;
}
body[data-world="bird"] .banner-block::after { background: none; }
/* the name, going up the wall */
/* in vertical writing the flex row runs up the wall, so the eyebrow and the name stand side by side as columns */
.wall-name { grid-column: 1; grid-row: 1 / span 2; display: flex; flex-direction: column; gap: .9rem; writing-mode: vertical-rl; transform: rotate(180deg); align-self: stretch; align-items: flex-start; overflow: hidden; }
body[data-world="bird"] .banner-eyebrow { color: var(--amber); font-family: var(--f-label); letter-spacing: .42em; font-weight: 500; margin: 0; white-space: nowrap; font-size: .62rem; }
body[data-world="bird"] .banner-eyebrow::before { display: none; }
body[data-world="bird"] .banner-title { font-family: var(--f-display); font-weight: 200; color: var(--text); letter-spacing: .04em; font-size: clamp(2.4rem, 4.2vw, 3.8rem); line-height: 1; white-space: nowrap; }
body[data-world="bird"] .banner-title em { font-style: italic; font-weight: 300; color: var(--amber); }
/* the casement */
.casement { grid-column: 3; grid-row: 1 / span 2; position: relative; aspect-ratio: 3 / 5; height: calc(100% - 34px); width: auto; max-width: 100%; justify-self: end;
  border: 16px solid var(--paint); box-shadow: 0 0 0 1px #d6d5cc, inset 0 0 0 1px #d6d5cc, 0 24px 30px -22px rgb(0 0 0 / .35); background: var(--paint); }
.sky { position: absolute; inset: 0; background: linear-gradient(180deg, var(--sky-a), var(--sky-b)); overflow: hidden; }
body[data-world="bird"] .sky .banner-wind { position: absolute; inset: 20% -10% auto; width: 120%; height: 50%; opacity: .5; }
body[data-world="bird"] .sky .banner-wind path { stroke: #fff; }
.sash { position: absolute; left: 0; right: 0; display: grid; border: 10px solid var(--paint); box-shadow: 0 2px 4px rgb(0 0 0 / .12); }
.sash i { border: 5px solid var(--paint); background: linear-gradient(135deg, rgb(255 255 255 / .18), transparent 45%); }
.sash-upper { top: 0; height: 50%; grid-template-columns: 1fr 1fr; grid-template-rows: 1fr 1fr; border-bottom-width: 12px; }
/* the lower sash is raised, so it sits behind the upper and the bottom half of the window is open air */
.sash-lower { top: 18%; height: 50%; grid-template-columns: 1fr 1fr; z-index: 0; opacity: .9; }
.sash-upper { z-index: 1; }
.curtain { position: absolute; z-index: 2; top: -4px; left: -4px; width: 34%; height: 104%;
  background: repeating-linear-gradient(90deg, rgb(255 255 255 / .72) 0 9px, rgb(240 240 234 / .55) 9px 16px);
  clip-path: polygon(0 0, 100% 0, 78% 30%, 92% 62%, 60% 100%, 0 100%); transform-origin: top left; animation: draught 7s ease-in-out infinite; }
@keyframes draught { 0%, 100% { transform: skewX(0deg); } 50% { transform: skewX(-5deg) scaleX(1.08); } }
.sill { position: absolute; z-index: 3; left: -28px; right: -28px; bottom: -34px; height: 22px; background: var(--paint); box-shadow: 0 6px 10px -6px rgb(0 0 0 / .3); }
.feather { position: absolute; right: 22%; top: -14px; width: 74px; transform: rotate(-7deg); }
.feather path { fill: #8a9198; opacity: .8; }
.feather .rachis { fill: none; stroke: #4f565d; stroke-width: 1.2; }
.wall-note { grid-column: 2; grid-row: 2; align-self: end; max-width: 30rem; padding-bottom: 2rem; }
body[data-world="bird"] .banner-tagline { font-family: var(--f-label); color: var(--muted); letter-spacing: .22em; font-size: .76rem; margin-top: 0; }
body[data-world="bird"] .banner-tagline strong { color: var(--text); }
.window-line { margin-top: .8rem; font: italic .95rem/1.6 var(--f-body); color: var(--muted); }
@media (prefers-reduced-motion: reduce) { .curtain { animation: none; transform: skewX(-3deg); } }

/* the rest of the room */
body[data-world="bird"] .relic-glyph { color: var(--amber); background: var(--surface2); border: 1px solid var(--dim); border-radius: 50%; box-shadow: none; }
body[data-world="bird"] .badge { font-family: var(--f-label); color: var(--text); font-weight: 500; }
body[data-world="bird"] .relic-description { font-style: normal; color: var(--text); border-left-color: var(--amber); }
body[data-world="bird"] .portrait-frame { box-shadow: 0 18px 36px -18px rgb(0 0 0 / .45); }
body[data-world="bird"] .cert-doc { background: var(--surface2); border-color: var(--text); color: var(--text); }
body[data-world="bird"] .cert-name, body[data-world="bird"] .stat-value, body[data-world="bird"] .section-title, body[data-world="bird"] .link-card-name { font-family: var(--f-display); font-weight: 300; color: var(--text); }
body[data-world="bird"] .cert-val, body[data-world="bird"] .cert-prov-val, body[data-world="bird"] .cert-mint-addr { color: var(--text); }
body[data-world="bird"] .cert-eyebrow, body[data-world="bird"] .cert-sub, body[data-world="bird"] .cert-key, body[data-world="bird"] .cert-copy-note, body[data-world="bird"] .cert-calib, body[data-world="bird"] .cert-prov-label, body[data-world="bird"] .cert-mint-label { color: var(--muted); }
body[data-world="bird"] .cert-witnesses { white-space: normal; overflow-wrap: anywhere; }
body[data-world="bird"] .cert-witnesses a { color: var(--amber); }
body[data-world="bird"] .stats-grid { background: var(--text); }
body[data-world="bird"] .stat-cell, body[data-world="bird"] .mint-address-block, body[data-world="bird"] .link-card, body[data-world="bird"] .pack-link, body[data-world="bird"] .copy-btn, body[data-world="bird"] .cert-copy-btn { background: var(--surface2); color: var(--text); border-color: var(--dim); }
body[data-world="bird"] .btn-primary { color: var(--surface2); background: var(--text); }
body[data-world="bird"] .btn-primary:hover { background: var(--amber); }
body[data-world="bird"] .back-strip, body[data-world="bird"] .relic-web { background: var(--surface); }
body[data-world="bird"] .vt-pull, body[data-world="bird"] [data-world-steps] .vt-pull { background: var(--surface2); color: var(--text); border-color: var(--text); font-family: var(--f-label); }
body[data-world="bird"] [data-world-steps] .vt-eq { font-family: var(--f-display); font-weight: 200; color: var(--text); }
body[data-world="bird"] [data-world-steps] .vt-note { color: var(--text); }
body[data-world="bird"] .entrance .en-scene { color: var(--text); font-family: var(--f-body); }
body[data-world="bird"] .entrance .en-scene::first-letter { color: var(--amber); font-family: var(--f-display); font-weight: 200; }
body[data-world="bird"] .entrance .en-arrive, body[data-world="bird"] .entrance .en-tuned { color: var(--muted); font-family: var(--f-label); }
body[data-world="bird"] .en-tuned b { color: var(--amber); font-family: var(--f-display); }
body[data-world="bird"] .en-ways button, body[data-world="bird"] .entrance .en-ways a { color: var(--text); font-family: var(--f-label); background: var(--surface2); border-color: var(--text); }
body[data-world="bird"] .en-ways button:hover, body[data-world="bird"] .entrance .en-ways a:hover { color: var(--amber); border-color: var(--amber); }
body[data-world="bird"] .entrance .en-ways .en-next { color: var(--muted); border-color: var(--dim); }
body[data-world="bird"] .walk-card { background: var(--surface2); border-color: var(--text); color: var(--text); }
body[data-world="bird"] .walk-card .wk-line { color: var(--text); }
body[data-world="bird"] nav:first-of-type, body[data-world="bird"] .world-nav { background: var(--nav-bg); border-bottom-color: var(--dim); }
body[data-world="bird"] .world-nav { font-family: var(--f-label); --w-accent: var(--amber) !important; --w-accent2: var(--text) !important; }
body[data-world="bird"] .world-nav a, body[data-world="bird"] .nav-back { color: var(--muted); }
body[data-world="bird"] .nav-brand, body[data-world="bird"] .footer-brand { color: var(--text); font-family: var(--f-display); font-weight: 300; letter-spacing: .2em; }
body[data-world="bird"] .nav-ticker { color: var(--amber); font-family: var(--f-label); }
body[data-world="bird"] .world-room-head .wr-no, body[data-world="bird"] .world-room-head h2, body[data-world="bird"] .ws-no { font-family: var(--f-display); font-weight: 200; }
body[data-world="bird"] .world-room-head .wr-no { color: var(--dim); }
body[data-world="bird"] .world-room-head p, body[data-world="bird"] .ws-no small, body[data-world="bird"] .ws-empty, body[data-world="bird"] .ws-count,
body[data-world="bird"] .world-record-head, body[data-world="bird"] .wl-head, body[data-world="bird"] .world-lede, body[data-world="bird"] .wl-row { color: var(--muted); }
body[data-world="bird"] .ws-body { color: var(--text); }
body[data-world="bird"] .ws-chapter, body[data-world="bird"] .wl-row { border-top-color: var(--dim); }
body[data-world="bird"] .wl-row, body[data-world="bird"] .world-record-head { font-family: var(--f-num); }
body[data-world="bird"] .wl-track { background: linear-gradient(90deg, transparent calc(50% - .5px), var(--dim) calc(50% - .5px), var(--dim) calc(50% + .5px), transparent calc(50% + .5px)); }
body[data-world="bird"] .wl-bar { background: rgb(63 111 156 / .4); }
body[data-world="bird"] .surface-dust, body[data-world="bird"] .street-chalk { max-width: 100%; overflow-wrap: anywhere; }

@media (max-width: 860px) {
  body[data-world="bird"] .banner-block { grid-template-columns: auto minmax(0, 1fr); grid-template-rows: 430px auto; padding: 3.4rem 16px 2.6rem; column-gap: 1rem; height: auto; }
  .casement { grid-column: 2; grid-row: 1; height: 400px; width: auto; max-width: 100%; }
  .wall-note { grid-column: 1 / -1; grid-row: 2; margin-top: 3rem; }
  .wall-name { grid-row: 1; }
  body[data-world="bird"] .banner-title { font-size: 2.3rem; }
}
@media (max-width: 560px) {
  body[data-world="bird"] nav:first-of-type { padding: 1rem 16px; gap: 10px; }
  body[data-world="bird"] nav:first-of-type .nav-brand { display: none; }
  body[data-world="bird"] .nav-ticker { font-size: .74rem; letter-spacing: .12em; }
}
