/* The Ben Calf Robe Society design preview, in the Society's own look: the
   deck's navy, slate, red, tan and cream, Oswald over Inter, the beadwork.
   Every piece is a draft, and the page says so at every turn. */
@font-face { font-family: 'Inter'; font-weight: 300 700; font-display: swap; src: url('fonts/Inter-400.woff2') format('woff2'); }
@font-face { font-family: 'Oswald'; font-weight: 400; font-display: swap; src: url('fonts/Oswald-400.woff2') format('woff2'); }
@font-face { font-family: 'Oswald'; font-weight: 500; font-display: swap; src: url('fonts/Oswald-500.woff2') format('woff2'); }
@font-face { font-family: 'Oswald'; font-weight: 600; font-display: swap; src: url('fonts/Oswald-600.woff2') format('woff2'); }
@font-face { font-family: 'Oswald'; font-weight: 700; font-display: swap; src: url('fonts/Oswald-700.woff2') format('woff2'); }

:root {
  --navy: #0E243C;
  --slate: #24415F;
  --red: #C43131;
  --red-dark: #A52A2A;
  --tan: #D9C0A2;
  --cream: #FFFAEC;
  --card: #FFFDF6;
  --ink: #17242F;
  --muted: #5B6470;
  --line: #E4DCCF;
  --well: #F3EBDC;
  --head: 'Oswald', 'Arial Narrow', Arial, sans-serif;
  --body: 'Inter', 'Segoe UI', Arial, sans-serif;
}

* { box-sizing: border-box; }
html { scroll-padding-top: 96px; }
body { margin: 0; background: var(--cream); color: var(--ink); font-family: var(--body); font-size: 15px; line-height: 1.55; -webkit-text-size-adjust: 100%; }
img { max-width: 100%; }
button { font: inherit; }
a:focus-visible, button:focus-visible { outline: 2px solid var(--red); outline-offset: 2px; }
h1, h2, h3, h4 { font-family: var(--head); text-transform: uppercase; color: var(--navy); margin: 0; }
.bead { height: 16px; background: url('img/beadwork.png') repeat-x center / auto 100%; }

/* pictures are for looking: no dragging, no saving from the menu */
.pv img, .stage img, .stage video, .pv video { -webkit-user-drag: none; user-select: none; -webkit-touch-callout: none; }

/* masthead */
.mast { background: var(--navy); color: var(--cream); }
.mast-in { max-width: 1240px; margin: 0 auto; padding: 44px 24px 40px; display: grid; grid-template-columns: auto minmax(0, 1fr); gap: 32px; align-items: center; }
.mast-logo { width: 150px; height: auto; display: block; }
.mast .org { font-family: var(--head); font-weight: 500; letter-spacing: .32em; font-size: .86rem; color: var(--tan); text-transform: uppercase; margin: 0 0 6px; }
.mast h1 { color: #fff; font-size: clamp(2.4rem, 6vw, 4.2rem); font-weight: 700; letter-spacing: .04em; line-height: 1; }
.mast h1::after { content: ""; display: block; width: 64px; height: 4px; background: var(--red); margin-top: 16px; }
.mast .wip { max-width: 46rem; margin: 22px 0 0; padding: 14px 18px; border-left: 4px solid var(--red); background: rgba(196, 49, 49, .16); border-radius: 0 6px 6px 0; }
.mast .wip strong { display: block; font-family: var(--head); font-weight: 600; font-size: 1.3rem; letter-spacing: .06em; text-transform: uppercase; color: #fff; line-height: 1.2; }
.mast .wip span { display: block; margin-top: 4px; color: #F1E6D4; font-size: .95rem; }
.mast .wip.paid { margin-top: 10px; border-left-color: var(--tan); background: rgba(217, 192, 162, .14); }
.mast .lede { max-width: 46rem; margin: 18px 0 0; color: #E9DDCB; font-size: 1.02rem; }
.mast .meta { margin: 12px 0 0; color: var(--tan); font-size: .86rem; }
@media (max-width: 640px) {
  .mast-in { grid-template-columns: minmax(0, 1fr); gap: 18px; padding: 32px 16px 30px; }
  .mast-logo { width: 110px; }
  .mast .wip { padding: 12px 14px; }
}

/* the body of work, counted */
.since { background: var(--card); border-bottom: 1px solid var(--line); }
.since-in { max-width: 1240px; margin: 0 auto; padding: 26px 24px 28px; }
.since h2 { font-size: .9rem; font-weight: 500; letter-spacing: .18em; color: var(--slate); }
.counts { list-style: none; margin: 14px 0 0; padding: 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(104px, 1fr)); gap: 14px 12px; }
.counts li { display: flex; flex-direction: column; border-left: 3px solid var(--tan); padding-left: 10px; }
.counts b { font-family: var(--head); font-size: 2rem; font-weight: 600; color: var(--navy); line-height: 1.05; }
.counts span { font-size: .84rem; color: var(--muted); }
@media (max-width: 640px) { .since-in { padding: 22px 16px 24px; } }

/* the bar that stays on screen: the draft line over the jump links */
.bar { position: sticky; top: 0; z-index: 5; }
.flagline { margin: 0; background: var(--red); color: #fff; text-align: center; font-family: var(--head); font-weight: 500; font-size: .78rem; letter-spacing: .16em; text-transform: uppercase; padding: 6px 12px; line-height: 1.4; }
@media (max-width: 640px) { .flagline { font-size: .7rem; letter-spacing: .1em; } }

/* jump bar */
.jump { background: var(--cream); border-bottom: 1px solid var(--line); }
.jump ul { list-style: none; margin: 0 auto; padding: 0 24px; max-width: 1240px; display: flex; gap: 4px; overflow-x: auto; scrollbar-width: thin; }
.jump a { display: block; padding: 14px 10px 12px; font-family: var(--head); font-size: .82rem; letter-spacing: .1em; text-transform: uppercase; color: var(--navy); text-decoration: none; white-space: nowrap; border-bottom: 3px solid transparent; }
.jump a:hover { border-bottom-color: var(--tan); }
.jump a.here { border-bottom-color: var(--red); }
@media (max-width: 640px) { .jump ul { padding: 0 8px; } }

/* sections */
main { max-width: 1240px; margin: 0 auto; padding: 8px 24px 40px; }
@media (max-width: 640px) { main { padding: 4px 16px 32px; } }
.sec { padding: 56px 0 8px; }
.sec > h2 { font-size: clamp(1.7rem, 3.4vw, 2.3rem); font-weight: 600; letter-spacing: .06em; }
.sec > h2::after { content: ""; display: block; width: 48px; height: 3px; background: var(--red); margin-top: 10px; }
.sec > .lede { max-width: 48rem; color: var(--muted); margin: 14px 0 0; }
.group { margin-top: 40px; }
.group > h3 { font-size: 1.12rem; font-weight: 500; letter-spacing: .12em; color: var(--slate); border-bottom: 1px solid var(--line); padding-bottom: 8px; }

/* cards */
.grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 22px; margin-top: 20px; }
.grid.narrow { grid-template-columns: repeat(auto-fill, minmax(210px, 1fr)); }
.piece { background: var(--card); border: 1px solid var(--line); border-radius: 10px; overflow: hidden; display: flex; flex-direction: column; min-width: 0; box-shadow: 0 1px 2px rgba(14, 36, 60, .04), 0 6px 18px rgba(14, 36, 60, .06); }
.piece.wide { grid-column: span 2; }
@media (max-width: 620px) { .piece.wide { grid-column: auto; } }
.pv { position: relative; display: block; width: 100%; padding: 0; border: 0; background: var(--well); overflow: hidden; cursor: zoom-in; aspect-ratio: 4 / 3; }
.pv img { display: block; width: 100%; height: 100%; object-fit: contain; }
.pv.cover img { object-fit: cover; object-position: top center; }
.pv.paper { padding: 14px; }
.pv.paper img { background: #fff; box-shadow: 0 2px 10px rgba(14, 36, 60, .16); }
.pv.tall { aspect-ratio: 9 / 16; background: var(--navy); }
.pv.tall img { object-fit: cover; }
.pv .more { position: absolute; right: 8px; bottom: 8px; font-family: var(--head); font-size: .7rem; letter-spacing: .12em; text-transform: uppercase; background: rgba(14, 36, 60, .86); color: #fff; padding: 4px 8px; border-radius: 3px; }
.pv .play { position: absolute; left: 50%; top: 50%; width: 58px; height: 58px; margin: -29px 0 0 -29px; border-radius: 50%; background: rgba(14, 36, 60, .78); box-shadow: 0 0 0 2px rgba(255, 255, 255, .7); }
.pv .play::after { content: ""; position: absolute; left: 23px; top: 18px; border-left: 17px solid #fff; border-top: 11px solid transparent; border-bottom: 11px solid transparent; }
.pv:hover .more, .pv:focus-visible .more { background: var(--red); }
.pv .draft { position: absolute; left: 0; top: 12px; z-index: 1; font-family: var(--head); font-weight: 600; font-size: .72rem; letter-spacing: .16em; text-transform: uppercase; background: var(--red); color: #fff; padding: 4px 10px 4px 12px; border-radius: 0 3px 3px 0; box-shadow: 0 2px 6px rgba(14, 36, 60, .25); pointer-events: none; }
.pv .draft.use { background: var(--navy); }
.pv .tile { position: absolute; inset: 0; display: flex; flex-direction: column; align-items: center; justify-content: center; text-align: center; padding: 16px; cursor: default; }
.pv .tile b { font-family: var(--head); font-size: 2rem; letter-spacing: .08em; color: var(--navy); }
.pv .tile span { color: var(--muted); font-size: .86rem; margin-top: 4px; }
.pv.still { cursor: default; }

.body { padding: 14px 16px 16px; display: flex; flex-direction: column; gap: 8px; flex: 1; }
.body h4 { font-size: 1.02rem; font-weight: 500; letter-spacing: .05em; line-height: 1.25; }
.st { margin: 0; font-size: .8rem; color: var(--muted); display: flex; flex-wrap: wrap; gap: 6px 8px; align-items: center; }
.tag { font-family: var(--head); font-size: .66rem; letter-spacing: .12em; text-transform: uppercase; padding: 2px 7px; border-radius: 3px; border: 1px solid var(--tan); line-height: 1.5; color: #7A5B33; background: #FBF3E6; }
.tag.use { background: var(--navy); border-color: var(--navy); color: #fff; }
.note { margin: 0; font-size: .87rem; color: var(--ink); }

.opts { display: flex; flex-wrap: wrap; gap: 6px; }
.opts button { font-size: .78rem; color: var(--navy); background: #fff; border: 1px solid var(--tan); border-radius: 999px; padding: 4px 10px; cursor: pointer; line-height: 1.4; }
.opts button:hover { border-color: var(--navy); }
.opts button[aria-pressed="true"] { background: var(--navy); border-color: var(--navy); color: #fff; }

/* the closer look */
dialog { border: 0; padding: 0; color: var(--ink); background: var(--cream); }
dialog::backdrop { background: rgba(8, 20, 34, .72); }
.viewer { width: min(1180px, calc(100vw - 32px)); max-height: calc(100vh - 32px); border-radius: 12px; overflow: hidden; }
.viewer[open] { display: flex; flex-direction: column; }
.vhead { display: flex; align-items: flex-start; justify-content: space-between; gap: 16px; padding: 16px 20px 12px; border-bottom: 1px solid var(--line); }
.vhead h3 { font-size: 1.25rem; font-weight: 500; letter-spacing: .05em; }
.vhead p { margin: 2px 0 0; font-size: .85rem; color: var(--muted); }
.x { flex: none; width: 40px; height: 40px; border-radius: 50%; border: 1px solid var(--line); background: #fff; color: var(--navy); font-size: 1.4rem; line-height: 1; cursor: pointer; }
.x:hover { border-color: var(--navy); }
.stage { position: relative; flex: 1; min-height: 0; background: #E9E1D2; display: flex; align-items: center; justify-content: center; overflow: auto; }
.stage img { display: block; max-width: 100%; max-height: calc(100vh - 230px); width: auto; height: auto; margin: 0 auto; box-shadow: 0 4px 24px rgba(14, 36, 60, .25); background: #fff; }
.stage img.long { max-height: none; }
.stage video { display: block; max-height: calc(100vh - 230px); max-width: 100%; aspect-ratio: 9 / 16; background: #000; }
.nav { position: absolute; top: 50%; margin-top: -24px; width: 48px; height: 48px; border-radius: 50%; border: 0; background: rgba(14, 36, 60, .82); color: #fff; font-size: 1.5rem; cursor: pointer; }
.nav:hover { background: var(--red); }
.nav.prev { left: 14px; }
.nav.next { right: 14px; }
.vfoot { display: flex; align-items: center; justify-content: space-between; gap: 12px 20px; flex-wrap: wrap; padding: 12px 20px 16px; border-top: 1px solid var(--line); }
.vfoot .count { font-size: .82rem; color: var(--muted); }
.vnote { margin: 0 0 0 auto; display: flex; align-items: center; gap: 10px; font-size: .85rem; color: var(--ink); }
.vnote .tag { flex: none; background: var(--red); border-color: var(--red); color: #fff; }
.vnote .tag.use { background: var(--navy); border-color: var(--navy); }
@media (max-width: 640px) {
  .viewer { width: 100vw; max-width: 100vw; height: 100%; max-height: 100%; border-radius: 0; }
  .stage img, .stage video { max-height: calc(100vh - 260px); }
  .nav { width: 40px; height: 40px; margin-top: -20px; }
  .nav.prev { left: 6px; }
  .nav.next { right: 6px; }
}

/* footer */
.foot { background: var(--navy); color: var(--tan); margin-top: 56px; }
.foot-in { max-width: 1240px; margin: 0 auto; padding: 26px 24px 32px; font-size: .86rem; display: flex; flex-wrap: wrap; gap: 8px 24px; justify-content: space-between; }
.foot .treaty { font-family: var(--head); letter-spacing: .18em; text-transform: uppercase; color: #fff; }
.foot p { margin: 0; flex-basis: 100%; color: #C9BBA6; }
@media (max-width: 640px) { .foot-in { padding: 22px 16px 28px; } }
