/* The site's whole look, in one file.

   A near black page, soft gray writing, gold for the marks a visitor follows
   and blue for every way to book, a serif face for headings and a sans serif
   face for everything else. The name is the owner's own logo. Every piece of
   art on a page of work is shown as a square tile of the same size in a grid,
   so no one picture takes over the screen, and opening a tile shows the whole
   piece, uncropped, as large as the window allows.

   Nothing in this file holds a sentence, and nothing in it fetches a picture:
   every mark it draws is a border, a gradient or a shape, and every face it
   names is one the machine already has, so it names no file at all. */

:root {
  color-scheme: dark;

  --bg: #0a0a0a;
  --bar: #111111;
  --strip: #0d0d0d;
  --band: #121212;
  --panel: #151515;
  --tile: #171717;
  --cell: #1b1b1b;
  --line: #2a2a2a;
  --line-soft: #1e1e1e;
  --rule-gold: rgba(220, 185, 106, 0.26);
  --text: #bababa;
  --muted: #8f8f8f;
  --faint: #5c5c5c;
  --heading: #cccccc;
  --bright: #e6e6e6;
  --gold: #dcb96a;
  --gold-strong: #ebcd86;
  --gold-wash: rgba(220, 185, 106, 0.14);
  --frame: #6e5d36;
  --on-gold: #141414;
  --alert: #f0a483;
  --focus: #f3d88f;
  --book: #2f62d6;
  --book-strong: #4475ea;
  --on-book: #ffffff;

  --wide: 83rem;
  --gallery: 67.5rem;
  --column: 48rem;
  --measure: 38rem;
  --gutter: clamp(1.5rem, 4vw, 3.5rem);
  --tile-gap: clamp(0.625rem, 1.2vw, 0.875rem);
  --overlay-gutter: clamp(0.75rem, 3vw, 2rem);
  --overlay-control: 2.75rem;
  --radius: 4px;

  --display: Baskerville, "Baskerville Old Face", "Libre Baskerville",
    "Big Caslon", "Book Antiqua", Georgia, serif;
  --body: "Open Sans", system-ui, -apple-system, "Segoe UI", Roboto,
    "Helvetica Neue", Arial, sans-serif;
}

* {
  box-sizing: border-box;
}

/* hidden means hidden

   A browser hides an element carrying the hidden attribute with a rule of its
   own, and any rule here that gives that element a display of its own beats
   it. That is how the two forms once stayed on the screen under their own
   confirmation and under the review. This one rule settles it for every block
   on the site, so a block put away by a script is gone from the page whatever
   else is said about it. */

[hidden] {
  display: none !important;
}

html {
  background: var(--bg);
}

body {
  display: flex;
  flex-direction: column;
  margin: 0;
  min-height: 100vh;
  background: var(--bg);
  color: var(--text);
  font-family: var(--body);
  font-size: 1rem;
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
}

/* list markers */

ul,
ol,
menu {
  margin: 0;
  padding: 0;
  list-style: none;
}

/* links: gold, and underlined only where they sit inside a run of writing */

a {
  color: var(--gold);
  text-decoration-color: rgba(220, 185, 106, 0.45);
  text-underline-offset: 0.22em;
}

a:hover {
  color: var(--gold-strong);
  text-decoration-color: currentColor;
}

/* focus ring */

:focus-visible {
  outline: 2px solid var(--focus);
  outline-offset: 3px;
}

@supports not selector(:focus-visible) {
  :focus {
    outline: 2px solid var(--focus);
    outline-offset: 3px;
  }
}

/* media bounds */

img,
video,
svg,
canvas,
iframe {
  max-width: 100%;
}

h1,
h2,
h3,
h4,
h5,
h6 {
  font-family: var(--display);
  font-weight: 700;
  color: var(--heading);
}

/* the one measure the bars, the pages and the footer share */

.wrap {
  display: block;
  width: min(var(--wide), 100% - 2 * var(--gutter));
  margin-inline: auto;
}

/* masthead: a slim strip, then one bar with the name and the navigation */

.masthead {
  position: relative;
  z-index: 20;
  background: var(--bar);
  border-bottom: 1px solid var(--line-soft);
}

.masthead-strip {
  margin: 0;
  background: var(--strip);
  border-bottom: 1px solid var(--line-soft);
  color: var(--muted);
  font-size: 0.75rem;
  line-height: 1;
}

.masthead-strip .wrap {
  padding: 0.85rem 0;
}

.masthead-bar {
  display: flex;
  align-items: center;
  gap: 1rem 1.5rem;
  min-height: 5.5rem;
}

/* the owner's logo stands for the name; the name itself is written beside it
   as text and drawn away from the eye, so it is read and not seen twice */

.masthead-name {
  display: block;
  flex: none;
  margin-right: auto;
  line-height: 0;
}

.site-logo {
  display: block;
  width: 11rem;
  max-width: 100%;
  height: auto;
}

.masthead-name:hover .site-logo {
  opacity: 0.8;
}

.name-text {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip-path: inset(50%);
  white-space: nowrap;
}

/* the navigation on a wide screen: one line of small capitals */

.nav-list {
  display: flex;
  align-items: center;
  gap: 0 1.75rem;
}

.nav-item {
  position: relative;
}

.nav-item > a {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  padding: 1.6rem 0;
  color: var(--text);
  font-size: 0.75rem;
  letter-spacing: 0.08em;
  line-height: 1;
  text-decoration: none;
  text-transform: uppercase;
}

.nav-item > a:hover {
  color: var(--gold);
}

/* current place: the page being read, and the section it sits in */

.nav-current > a,
.nav-ancestor > a,
.nav-tab.nav-current > a {
  color: var(--gold);
}

/* the small chevron after Tattoos and Illustration, saying a list opens under it */

.nav-has-tabs > a::after {
  content: "";
  width: 0.32rem;
  height: 0.32rem;
  margin-top: -0.2rem;
  border-right: 1px solid currentColor;
  border-bottom: 1px solid currentColor;
  transform: rotate(45deg);
}

/* the tabs under Tattoos and Illustration, opened by the pointer or the keyboard */

.nav-tabs {
  display: none;
  position: absolute;
  top: 100%;
  left: -1.15rem;
  z-index: 30;
  min-width: 13rem;
  border: 1px solid var(--line);
  background: #141414;
  padding: 0.35rem 0;
}

.nav-has-tabs:hover .nav-tabs,
.nav-has-tabs:focus-within .nav-tabs {
  display: block;
}

.nav-tab > a {
  display: block;
  padding: 0.75rem 1.15rem;
  color: var(--text);
  font-size: 0.75rem;
  letter-spacing: 0.08em;
  text-decoration: none;
  text-transform: uppercase;
}

.nav-tab > a:hover {
  background: #1b1b1b;
  color: var(--gold);
}

/* the booking page, drawn as the one blue button at the end of the bar */

.nav-book > a,
.nav-current.nav-book > a {
  padding: 0.75rem 1.2rem;
  border: 1px solid var(--book);
  border-radius: 2px;
  background: var(--book);
  color: var(--on-book);
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.18em;
}

.nav-book > a:hover {
  border-color: var(--book-strong);
  background: var(--book-strong);
  color: var(--on-book);
}

/* the control that opens the navigation, drawn only on a narrow screen and
   only once assets/nav.js is there to work it: three gold rules that turn
   into a cross while the navigation is open */

.nav-toggle {
  display: none;
  position: relative;
  flex: none;
  width: 2.75rem;
  height: 2.75rem;
  margin: 0 -0.5rem 0 0;
  border: 0;
  background: transparent;
  padding: 0;
  color: var(--gold);
  cursor: pointer;
}

.nav-toggle::before,
.nav-toggle::after {
  content: "";
  position: absolute;
  left: 0.6rem;
  right: 0.6rem;
  height: 2px;
  background: currentColor;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.nav-toggle::before {
  top: calc(50% - 7px);
  box-shadow: 0 7px 0 currentColor;
}

.nav-toggle::after {
  top: calc(50% + 6px);
}

.menu-open .nav-toggle::before {
  top: calc(50% - 1px);
  box-shadow: none;
  transform: rotate(45deg);
}

.menu-open .nav-toggle::after {
  top: calc(50% - 1px);
  transform: rotate(-45deg);
}

/* the navigation on a narrow screen

   With no script the whole list is drawn under the name and wraps, so every
   page is still reached. With the script, the list folds behind the control
   and only the boxed booking button stays in the bar; opening it lays the
   whole list out under the bar, the three tabs under Tattoos. */

@media (max-width: 63.99rem) {
  .masthead-bar {
    flex-wrap: wrap;
    min-height: 4.5rem;
    padding: 0.6rem 0;
  }

  .site-logo {
    width: 9.5rem;
  }

  .site-nav {
    flex: 1 1 100%;
  }

  .nav-list {
    flex-wrap: wrap;
    gap: 0.25rem 1.25rem;
  }

  .nav-item > a {
    padding: 0.6rem 0;
  }

  .nav-tabs {
    display: flex;
    flex-wrap: wrap;
    gap: 0 1rem;
    position: static;
    min-width: 0;
    border: 0;
    background: transparent;
    padding: 0;
  }

  .nav-tab > a {
    padding: 0.4rem 0;
    color: var(--muted);
  }

  :root.nav-ready .masthead-bar {
    flex-wrap: nowrap;
  }

  :root.nav-ready .nav-toggle {
    display: inline-block;
    order: 2;
  }

  :root.nav-ready .site-nav {
    flex: none;
    order: 1;
  }

  :root.nav-ready .nav-item {
    display: none;
  }

  /* the booking page, drawn as one blue bar along the foot of the screen,
     there whatever is scrolled and whether the menu is open or not */

  .nav-book,
  :root.nav-ready .nav-book {
    display: block;
    position: fixed;
    left: 0.75rem;
    right: 0.75rem;
    bottom: 0.75rem;
    z-index: 40;
  }

  .nav-book > a,
  .nav-current.nav-book > a {
    display: block;
    padding: 1.05rem 1rem;
    box-shadow: 0 0.4rem 1.5rem rgba(0, 0, 0, 0.55);
    font-size: 0.8rem;
    letter-spacing: 0.22em;
    text-align: center;
  }

  body {
    padding-bottom: 5rem;
  }

  :root.nav-ready .menu-open .site-nav {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    max-height: calc(100vh - 12rem);
    overflow-y: auto;
    border-bottom: 1px solid var(--line);
    background: var(--bar);
    padding: 0.5rem var(--gutter) 1.75rem;
  }

  :root.nav-ready .menu-open .nav-list {
    display: block;
  }

  :root.nav-ready .menu-open .nav-item {
    display: block;
    border-bottom: 1px solid var(--line-soft);
  }

  :root.nav-ready .menu-open .nav-item > a {
    display: flex;
    padding: 1rem 0;
    color: var(--heading);
    font-size: 0.95rem;
    font-weight: 600;
    letter-spacing: 0.14em;
  }

  :root.nav-ready .menu-open .nav-current > a,
  :root.nav-ready .menu-open .nav-ancestor > a {
    color: var(--gold);
  }

  :root.nav-ready .menu-open .nav-has-tabs > a::after {
    content: none;
  }

  :root.nav-ready .menu-open .nav-tabs {
    display: block;
    padding: 0 0 0.9rem 1rem;
  }

  :root.nav-ready .menu-open .nav-tab > a {
    padding: 0.45rem 0;
    font-size: 0.8rem;
  }

  :root.nav-ready .menu-open .nav-book {
    border-bottom: 0;
  }

  :root.nav-ready .menu-open .nav-book > a {
    display: block;
    padding: 1.05rem 1rem;
    color: var(--on-book);
    font-size: 0.8rem;
    letter-spacing: 0.22em;
  }
}

/* the page: every block of it on one measure, the home page's opening band
   and its band of work running the full width behind theirs */

main {
  display: block;
  flex: 1 0 auto;
  width: 100%;
  padding-bottom: clamp(4rem, 9vw, 7rem);
}

main > * {
  width: min(var(--wide), 100% - 2 * var(--gutter));
  margin-inline: auto;
}

.page-gallery > *,
.page-pixel > * {
  width: min(var(--gallery), 100% - 2 * var(--gutter));
}

.page-text > *,
.page-form > * {
  width: min(var(--column), 100% - 2 * var(--gutter));
}

.page-bio > * {
  width: min(62rem, 100% - 2 * var(--gutter));
}

/* the head of every page: a small gold line, the heading, one line under it */

.page-head {
  padding-top: clamp(2.5rem, 6vw, 4.5rem);
}

.eyebrow {
  margin: 0 0 0.9rem;
  color: var(--gold);
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.24em;
  line-height: 1.4;
  text-transform: uppercase;
}

.eyebrow a {
  color: inherit;
  text-decoration: none;
}

.eyebrow a:hover {
  text-decoration: underline;
}

h1 {
  margin: 0;
  font-size: clamp(2.4rem, 2.6vw + 1.6rem, 3.6rem);
  letter-spacing: 0;
  line-height: 1.05;
  overflow-wrap: break-word;
  hyphens: none;
}

.intro {
  max-width: 40rem;
  margin: 1rem 0 0;
  color: var(--muted);
  font-size: 1.05rem;
  line-height: 1.6;
}

/* the home page's opening band: the name large, in its own lettering, over a
   dark ground with a little warmth in one corner */

.page-home > .hero {
  position: relative;
  isolation: isolate;
  width: 100%;
  margin: 0;
  overflow: hidden;
  padding: clamp(5rem, 13vw, 9.5rem) 0 clamp(3.5rem, 8vw, 6rem);
  border-bottom: 1px solid var(--line-soft);
  background: linear-gradient(180deg, #171717 0%, #0b0b0b 100%);
}

/* the picture behind the name: one of the owner's pieces, filling the band,
   cropped to the point content/home.json names under hero_focus and darkened
   most where the writing stands, so every word stays readable */

.hero-photo {
  position: absolute;
  inset: 0;
  z-index: -2;
  width: 100%;
  height: 100%;
  max-width: none;
  object-fit: cover;
  object-position: var(--hero-focus, center 35%);
}

/* a wide band holds the picture to its right, away from the writing, with
   its far edge run off the band, and fades its near edge into the dark, so
   the piece stands clear of the name */

@media (min-width: 48rem) {
  .hero-photo {
    left: auto;
    right: -12%;
    width: 72%;
    -webkit-mask-image: linear-gradient(90deg, transparent 0%, #000 22%);
    mask-image: linear-gradient(90deg, transparent 0%, #000 22%);
  }
}

/* a narrow band, a phone, holds the picture to its right the same way, run
   further off the band, with the name and the writing kept to the left so
   the face stands clear of them; it can be zoomed in on the focus point, as
   far as content/home.json asks under hero_zoom */

@media (max-width: 47.99rem) {
  .hero-photo {
    left: auto;
    right: -30%;
    width: 100%;
    transform: scale(var(--hero-zoom, 1));
    transform-origin: var(--hero-focus, center 35%);
    -webkit-mask-image: linear-gradient(90deg, transparent 0%, #000 30%);
    mask-image: linear-gradient(90deg, transparent 0%, #000 30%);
  }
}

.page-home > .hero::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  background:
    linear-gradient(90deg, rgba(10, 10, 10, 0.94) 0%, rgba(10, 10, 10, 0.78) 42%, rgba(10, 10, 10, 0.45) 100%),
    linear-gradient(0deg, rgba(10, 10, 10, 0.9) 0%, transparent 35%);
}

/* on a phone the face is lit more, because the writing keeps to the left */

@media (max-width: 47.99rem) {
  .page-home > .hero::before {
    background:
      linear-gradient(90deg, rgba(10, 10, 10, 0.92) 0%, rgba(10, 10, 10, 0.6) 45%, rgba(10, 10, 10, 0.15) 100%),
      linear-gradient(0deg, rgba(10, 10, 10, 0.9) 0%, transparent 30%);
  }
}

.hero .eyebrow {
  margin-bottom: 1.5rem;
  letter-spacing: 0.28em;
}

.hero h1 {
  line-height: 0;
}

/* the owner's handwritten @TORTUGA.tattooer, kept to a modest size */

.hero-logo {
  width: min(26rem, 100%);
  height: auto;
}

.hero .intro {
  max-width: 34rem;
  margin-top: 1.75rem;
  color: #b4b4b4;
  font-size: clamp(1.05rem, 0.5vw + 0.95rem, 1.3rem);
}

/* on a phone, and on a tablet or a laptop narrower than the band's widest,
   the name and the line under it end before the face begins */

@media (max-width: 47.99rem) {
  .hero-logo {
    width: 74%;
  }

  .hero .intro {
    max-width: 58%;
  }
}

@media (min-width: 48rem) and (max-width: 74.99rem) {
  .hero-logo {
    width: min(26rem, 52%);
  }

  .hero .intro {
    max-width: 50%;
  }
}

.hero-actions {
  margin: 2.25rem 0 0;
}

/* a way on, boxed in gold, with a chevron of plain borders after its words */

.button {
  display: inline-flex;
  align-items: center;
  gap: 0.85rem;
  border: 1px solid var(--gold);
  padding: 1rem 1.6rem;
  color: var(--gold);
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.18em;
  line-height: 1.2;
  text-decoration: none;
  text-transform: uppercase;
}

.button::after,
.more-link::after {
  content: "";
  flex: none;
  width: 0.4rem;
  height: 0.4rem;
  border-top: 1px solid currentColor;
  border-right: 1px solid currentColor;
  transform: rotate(45deg);
}

.button:hover {
  background: var(--gold);
  color: var(--on-gold);
}

/* the way to book from the top of the home page, blue like every way to book */

.hero-actions .button {
  border-color: var(--book);
  border-radius: 2px;
  background: var(--book);
  color: var(--on-book);
  font-weight: 700;
}

.hero-actions .button:hover {
  border-color: var(--book-strong);
  background: var(--book-strong);
  color: var(--on-book);
}

.more-link {
  display: inline-flex;
  align-items: center;
  gap: 0.6rem;
  color: var(--gold);
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.16em;
  text-decoration: none;
  text-transform: uppercase;
}

.more-link:hover {
  color: var(--gold-strong);
}

/* the home page's band of work: square tiles, three across */

.page-home > .home-work {
  width: 100%;
  margin: 0;
  padding: clamp(3rem, 7vw, 5.5rem) max(var(--gutter), (100% - var(--wide)) / 2);
  background: var(--band);
  grid-template-columns: minmax(0, 1fr);
  gap: var(--tile-gap);
}

.home-work > h2 {
  margin: 0 0 clamp(1rem, 2.5vw, 1.75rem);
  font-size: clamp(1.75rem, 1.6vw + 1.2rem, 2.25rem);
  line-height: 1.1;
}

.home-more {
  margin: clamp(1.5rem, 3vw, 2.5rem) 0 0;
  text-align: center;
}

@media (min-width: 36rem) {
  .page-home > .home-work {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (min-width: 48rem) {
  .page-home > .home-work {
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 1rem;
  }
}

/* small rows of links: the six tattoo types under a type page's heading, and
   the ways down from a page, each as a rounded chip */

.chips-nav {
  margin-top: 1.5rem;
}

.chips,
.section-list {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
}

.chip > a,
.section-list a {
  display: inline-block;
  border: 1px solid #3a3a3a;
  border-radius: 999px;
  padding: 0.3rem 0.85rem;
  color: var(--text);
  font-size: 0.85rem;
  line-height: 1.5;
  text-decoration: none;
}

.chip > a:hover,
.section-list a:hover {
  border-color: var(--gold);
  color: var(--gold);
}

.chip > a[aria-current="page"] {
  border-color: var(--gold);
  background: var(--gold);
  color: var(--on-gold);
}

.sections {
  margin-top: clamp(2rem, 5vw, 3rem);
}

.sections h2 {
  margin: 0 0 0.9rem;
  color: var(--gold);
  font-family: var(--body);
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.24em;
  text-transform: uppercase;
}

.page-home > .sections {
  margin-top: clamp(3rem, 7vw, 5rem);
  text-align: center;
}

.page-home .section-list {
  justify-content: center;
}

.page-home .section-list a {
  padding: 0.55rem 1.15rem;
  font-size: 0.75rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

/* every grid of pieces: square tiles of one size, a few across */

.catalog {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: var(--tile-gap);
  align-items: start;
  margin-top: clamp(2rem, 4vw, 2.75rem);
}

.catalog > h2,
.catalog > p {
  grid-column: 1 / -1;
}

@media (min-width: 36rem) {
  .catalog.catalog-column {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (min-width: 48rem) {
  .catalog.catalog-column {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}

@media (min-width: 64rem) {
  .catalog.catalog-column {
    grid-template-columns: repeat(4, minmax(0, 1fr));
  }
}

@media (min-width: 75rem) {
  .catalog.catalog-column {
    grid-template-columns: repeat(5, minmax(0, 1fr));
  }
}

/* one piece: a square tile, the picture filling it, and the whole picture
   one click away in the larger view */

.piece,
.piece-frame {
  display: block;
  position: relative;
  width: 100%;
  min-width: 0;
  max-width: 100%;
  aspect-ratio: 1;
  margin: 0;
  border: 1px solid var(--line-soft);
  border-radius: var(--radius);
  background: var(--tile);
  padding: 0;
  overflow: hidden;
}

.piece {
  color: inherit;
  font: inherit;
  text-align: left;
  cursor: zoom-in;
}

.piece > img,
.piece-frame > video {
  display: block;
  width: 100%;
  height: 100%;
  max-width: 100%;
  object-fit: cover;
  background: var(--tile);
  transition: transform 0.35s ease, opacity 0.35s ease;
}

.piece:hover {
  border-color: var(--gold);
}

.piece:hover > img {
  transform: scale(1.03);
}

/* a sprite sheet on the home page is drawn with its pixels hard, from its
   first frames */

.piece > img[src*="pixel%20art"] {
  object-position: left center;
  image-rendering: pixelated;
}

/* the control that opens a moving piece larger: small, over the top corner of
   the tile, beside the video and never around it, so the browser's own
   controls along the bottom keep every click and keystroke they want. It is
   drawn with two corner marks of plain borders, so it holds no character. */

.piece-frame > .piece {
  position: absolute;
  inset-block-start: 0.45rem;
  inset-inline-end: 0.45rem;
  z-index: 1;
  width: 2.25rem;
  height: 2.25rem;
  aspect-ratio: auto;
  border: 1px solid #3a3a3a;
  border-radius: var(--radius);
  background: rgba(14, 14, 14, 0.85);
  color: var(--bright);
}

.piece-frame > .piece::before,
.piece-frame > .piece::after {
  content: "";
  position: absolute;
  width: 0.5rem;
  height: 0.5rem;
  border: 0 solid currentColor;
}

.piece-frame > .piece::before {
  inset-block-start: 0.45rem;
  inset-inline-start: 0.45rem;
  border-block-start-width: 2px;
  border-inline-start-width: 2px;
}

.piece-frame > .piece::after {
  inset-block-end: 0.45rem;
  inset-inline-end: 0.45rem;
  border-block-end-width: 2px;
  border-inline-end-width: 2px;
}

.piece-frame > .piece:hover {
  border-color: var(--gold);
  color: var(--gold);
}

/* the six doors on the tattoos page: a square sample, the type's name under
   it, and the count in the corner of the sample */

.catalog.catalog-doors {
  display: block;
}

.catalog-doors > h2 {
  margin: 0 0 1.25rem;
  font-size: clamp(1.5rem, 1vw + 1.2rem, 2rem);
}

.doors {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: clamp(1.25rem, 2vw, 1.5rem) clamp(0.75rem, 2vw, 1.25rem);
  align-items: start;
}

@media (min-width: 36rem) {
  .doors {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (min-width: 48rem) {
  .doors {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}

.door {
  min-width: 0;
}

.door-link {
  display: grid;
  gap: 0.7rem;
  position: relative;
  color: var(--heading);
  text-decoration: none;
}

.door-sample {
  display: block;
  width: 100%;
  height: auto;
  max-width: 100%;
  aspect-ratio: 1;
  object-fit: cover;
  border: 1px solid var(--line-soft);
  border-radius: var(--radius);
  background: var(--tile);
}

/* the door of a type with nothing in it yet keeps the same square, empty */

.door-link:not(:has(.door-sample))::before {
  content: "";
  display: block;
  aspect-ratio: 1;
  border: 1px dashed #333333;
  border-radius: var(--radius);
  background: var(--band);
}

.door-link:hover .door-sample {
  border-color: var(--gold);
}

.door-name {
  font-family: var(--display);
  font-size: clamp(1.1rem, 0.8vw + 0.9rem, 1.4rem);
  font-weight: 700;
  line-height: 1.15;
}

.door-link:hover .door-name {
  color: var(--gold);
}

.door-count {
  position: absolute;
  top: 0.6rem;
  right: 0.6rem;
  min-width: 2rem;
  border-radius: var(--radius);
  background: rgba(10, 10, 10, 0.82);
  padding: 0.2rem 0.55rem;
  color: var(--gold);
  font-size: 0.8rem;
  font-weight: 600;
  line-height: 1.4;
  text-align: center;
  font-variant-numeric: tabular-nums;
}

/* the word saying what a count counts: heard, not seen */

.door-count-word {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip-path: inset(50%);
  white-space: nowrap;
}

/* pixel art

   Every piece is drawn at its size in drawn pixels times a whole number of
   screen pixels, so a drawn pixel is always a square block and the edges stay
   hard. The build hands each frame its drawn size as two plain numbers and the
   multiplying happens here, once. The number is the largest whole one that
   fits the frame, never under one and never over three for an animation, so
   a small sprite is shown large enough to read and no larger. Where a browser does not know
   round() the plain width above it stands, which is one screen pixel per
   drawn pixel.

   A frame scrolls sideways, so a sheet wider than its frame at one screen
   pixel per drawn pixel is shown whole at that size and reached by scrolling
   rather than squeezed. Each animation stands over its whole sheet, and each
   pair has a row of the page to itself, the way a sprite pack lays out one
   animation to a line. */

.pixel-art {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: var(--tile-gap);
  margin-top: clamp(2rem, 4vw, 2.75rem);
}

.pixel-pair {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  grid-template-rows: auto auto;
  align-items: start;
  min-width: 0;
  border: 1px solid var(--line-soft);
  border-radius: var(--radius);
  background: var(--tile);
  overflow: hidden;
}

.pixel-frame {
  min-width: 0;
  overflow-x: auto;
  overflow-y: hidden;
  overscroll-behavior-x: contain;
  scrollbar-color: #3a3a3a transparent;
}

.pixel-animation,
.pixel-alone {
  display: flex;
  align-items: center;
  min-height: 17rem;
  padding: 1.25rem;
}

/* A sheet stands whole on the line under its animation. */

.pixel-sheet {
  display: flex;
  border-top: 1px solid var(--line-soft);
  background: #121212;
  padding: 1.25rem;
}

/* Each picture is centred by its own margins, which give way to nothing when
   it is wider than its frame, so a wide one starts at the left edge and is
   scrolled to rather than cut off on both sides. */

.pixel-frame img {
  display: block;
  flex: none;
  margin-inline: auto;
  max-width: none;
  height: auto;
  image-rendering: -webkit-optimize-contrast;
  image-rendering: crisp-edges;
  image-rendering: pixelated;
  width: calc(var(--drawn-width) * 1px);
  width: min(
    calc(var(--drawn-width) * 3px),
    max(
      calc(var(--drawn-width) * 1px),
      round(down, 100%, calc(var(--drawn-width) * 1px))
    )
  );
}

/* A sheet is drawn at no more than two screen pixels per drawn pixel, so a
   square one does not fill the screen, and the palette, a set of colour
   swatches rather than a drawing, at one. */

.pixel-sheet img {
  width: min(
    calc(var(--drawn-width) * 2px),
    max(
      calc(var(--drawn-width) * 1px),
      round(down, 100%, calc(var(--drawn-width) * 1px))
    )
  );
}

.pixel-alone img {
  width: calc(var(--drawn-width) * 1px);
}

/* the line an empty type page holds while it shows no piece */

.catalog-empty {
  margin: 0;
  max-width: var(--measure);
  color: var(--muted);
}

/* questions and answers, and after care: one column of prose, a heading in
   the slab face over each answer, a fine gold rule between them */

.answers {
  margin-top: clamp(2rem, 5vw, 3rem);
  border-top: 1px solid var(--rule-gold);
}

.answer {
  padding: 1.75rem 0;
  border-bottom: 1px solid var(--rule-gold);
}

.answer h2 {
  margin: 0 0 0.7rem;
  font-size: clamp(1.25rem, 0.8vw + 1rem, 1.6rem);
  font-style: italic;
  line-height: 1.25;
  overflow-wrap: break-word;
}

.answer p {
  margin: 0;
  color: #a2a2a2;
}

.answers-contact {
  margin: 2rem 0 0;
  color: var(--muted);
}

/* the bio: prose, and one piece of work beside it in place of a portrait */

.bio {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: clamp(2rem, 5vw, 3.5rem);
  align-items: start;
  margin-top: clamp(2rem, 5vw, 3rem);
}

.bio-prose {
  max-width: var(--measure);
  min-width: 0;
}

.bio-prose p {
  margin: 0;
  color: #a8a8a8;
  font-size: 1.075rem;
  line-height: 1.8;
}

.bio-piece {
  min-width: 0;
  max-width: 24rem;
}

.bio-piece .piece {
  aspect-ratio: auto;
}

.bio-piece .piece > img {
  height: auto;
}

@media (min-width: 48rem) {
  .bio {
    grid-template-columns: minmax(0, 1fr) minmax(0, 22rem);
  }
}

/* the larger view: one piece over the page, whole and uncropped

   It starts hidden, and the display below has to be turned off for the hidden
   attribute, which a flex box would otherwise ignore. Nothing in it holds a
   character a person reads: the close mark and the two chevrons are drawn with
   plain borders, like the control that opens a moving piece. */

.overlay {
  position: fixed;
  inset: 0;
  z-index: 50;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: var(--overlay-gutter);
  background: rgba(6, 6, 6, 0.95);
}

.overlay[hidden] {
  display: none;
}

/* the page behind holds still while the view is open */

.gallery-open,
.gallery-open body {
  overflow: hidden;
}

.overlay-sheet,
.overlay-stage {
  display: flex;
  align-items: center;
  justify-content: center;
  max-width: 100%;
  max-height: 100%;
  min-width: 0;
}

.overlay-stage {
  overflow: auto;
}

/* the piece itself, never wider than the window has room for and never taller
   than it

   The width the script works out arrives as a custom property and is read here
   as one more cap beside the window's own, never as a width set on the piece.
   A piece given a width and a capped height keeps the width and loses the
   shape: that is what drew every tall picture stretched sideways on a wide
   screen. Two caps leave the browser to scale the piece inside both of them
   and keep its own shape, whichever cap it meets first. */

.overlay-media {
  display: block;
  width: auto;
  height: auto;
  max-width: min(100%, var(--view-width, 100%));
  max-height: calc(100vh - 2 * var(--overlay-gutter));
  border-radius: var(--radius);
  background: var(--tile);
}

/* the controls */

.overlay-close,
.overlay-previous,
.overlay-next {
  position: absolute;
  z-index: 1;
  width: var(--overlay-control);
  height: var(--overlay-control);
  margin: 0;
  border: 1px solid #3a3a3a;
  border-radius: 50%;
  background: rgba(17, 17, 17, 0.9);
  padding: 0;
  color: var(--bright);
  font: inherit;
  cursor: pointer;
}

.overlay-close {
  inset-block-start: var(--overlay-gutter);
  inset-inline-end: var(--overlay-gutter);
}

.overlay-previous,
.overlay-next {
  inset-block-start: 50%;
  transform: translateY(-50%);
}

.overlay-previous {
  inset-inline-start: var(--overlay-gutter);
}

.overlay-next {
  inset-inline-end: var(--overlay-gutter);
}

/* the close mark: two rules crossing, and no character */

.overlay-close::before,
.overlay-close::after {
  content: "";
  position: absolute;
  inset-block-start: 50%;
  inset-inline-start: 28%;
  width: 44%;
  border-block-start: 2px solid currentColor;
}

.overlay-close::before {
  transform: rotate(45deg);
}

.overlay-close::after {
  transform: rotate(-45deg);
}

/* the two chevrons: a corner of plain borders, turned */

.overlay-previous::before,
.overlay-next::before {
  content: "";
  position: absolute;
  inset-block-start: 50%;
  inset-inline-start: 50%;
  width: 0.65rem;
  height: 0.65rem;
  border-block-start: 2px solid currentColor;
  border-inline-start: 2px solid currentColor;
}

.overlay-previous::before {
  transform: translate(-30%, -50%) rotate(-45deg);
}

.overlay-next::before {
  transform: translate(-70%, -50%) rotate(135deg);
}

.overlay-close:hover,
.overlay-previous:hover,
.overlay-next:hover {
  border-color: var(--gold);
  color: var(--gold);
}

/* a control with nowhere left to go: dimmed, and no longer a pointer */

.overlay-previous:disabled,
.overlay-next:disabled {
  opacity: 0.3;
  cursor: default;
}

.overlay-previous:disabled:hover,
.overlay-next:disabled:hover {
  border-color: #3a3a3a;
  color: var(--bright);
}

/* reduced motion */

@media (prefers-reduced-motion: reduce) {
  * {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }
}

/* the two forms: one panel, one column at every width, small capital labels
   over fields drawn as a single line, and a visible ring on every control

   The opening line of the page sits right above the panel, so the panel
   stands off from it rather than beginning against it. */

.contact-form,
.book-form {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 2rem;
  margin-top: clamp(2rem, 4vw, 2.75rem);
  border: 1px solid var(--line-soft);
  background: var(--panel);
  padding: clamp(1.5rem, 5vw, 3.25rem);
}

.form-row {
  display: grid;
  gap: 0.55rem;
  min-width: 0;
  margin: 0;
  border: 0;
  padding: 0;
}

.form-label {
  padding: 0;
  color: #a0a0a0;
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

legend.form-label {
  margin-bottom: 0.6rem;
}

/* an answer that must be given: a small gold dot after its name, and no
   character */

.form-row:has(> [data-required]) > .form-label::after,
.form-choices[data-required] > legend::after {
  content: "";
  display: inline-block;
  width: 0.32rem;
  height: 0.32rem;
  margin: 0 0 0.15rem 0.5rem;
  border-radius: 50%;
  background: var(--gold);
  vertical-align: middle;
}

.form-field {
  display: block;
  width: 100%;
  max-width: 100%;
  border: 0;
  border-bottom: 1px solid #3b3b3b;
  border-radius: 0;
  background: transparent;
  padding: 0.55rem 0;
  color: var(--bright);
  font: inherit;
}

.form-field:hover {
  border-bottom-color: #5a5a5a;
}

.form-field:focus {
  border-bottom-color: var(--gold);
}

.form-message {
  min-height: 8rem;
  resize: vertical;
  line-height: 1.6;
}

.form-field[aria-invalid="true"],
.form-choices[aria-invalid="true"] {
  border-bottom-color: var(--alert);
}

.form-choice {
  display: flex;
  align-items: center;
  gap: 0.7rem;
  min-height: 2.75rem;
}

.form-choice .form-label,
.form-check-row .form-label {
  color: var(--text);
  font-size: 1rem;
  font-weight: 400;
  letter-spacing: 0;
  text-transform: none;
}

.form-radio,
.form-check {
  flex: none;
  width: 1.25rem;
  height: 1.25rem;
  margin: 0;
  accent-color: var(--gold);
}

/* one checkbox with what it confirms read after it, and its refusal under
   both, which is the one row of a form that is not a column */

.form-check-row {
  grid-template-columns: auto minmax(0, 1fr);
  align-items: center;
  column-gap: 0.7rem;
  min-height: 2.75rem;
}

.form-check-row .form-refusal {
  grid-column: 1 / -1;
}

.form-field:focus-visible,
.form-radio:focus-visible,
.form-check:focus-visible,
.form-send:focus-visible,
.attach-remove:focus-visible {
  outline: 2px solid var(--focus);
  outline-offset: 3px;
}

/* the control that sends: gold, filled */

.form-send {
  justify-self: start;
  min-height: 3.25rem;
  border: 1px solid var(--gold);
  border-radius: 0;
  background: var(--gold);
  padding: 0.9rem 2.1rem;
  color: var(--on-gold);
  font: inherit;
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  cursor: pointer;
}

.form-send:hover {
  border-color: var(--gold-strong);
  background: var(--gold-strong);
}

/* attaching pictures */

.attach-field {
  border-bottom: 0;
  color: var(--muted);
  font-size: 0.9rem;
}

.attach-field::file-selector-button {
  margin-right: 1rem;
  border: 1px solid var(--gold);
  border-radius: 0;
  background: transparent;
  padding: 0.65rem 1.1rem;
  color: var(--gold);
  font: inherit;
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  cursor: pointer;
}

.attach-field::file-selector-button:hover {
  background: var(--gold);
  color: var(--on-gold);
}

.attach-list {
  display: grid;
  gap: 0.5rem;
}

.attach-item {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  min-width: 0;
  border: 1px solid var(--line-soft);
  border-radius: var(--radius);
  background: #111111;
  padding: 0.4rem;
}

.attach-thumb {
  flex: none;
  width: 3.5rem;
  height: 3.5rem;
  object-fit: cover;
  border-radius: 2px;
}

.attach-name {
  flex: 1 1 auto;
  min-width: 0;
  overflow-wrap: anywhere;
}

.attach-remove {
  position: relative;
  flex: none;
  width: 2.75rem;
  height: 2.75rem;
  border: 1px solid #3a3a3a;
  border-radius: 50%;
  background: transparent;
  color: var(--bright);
  cursor: pointer;
}

.attach-remove:hover {
  border-color: var(--gold);
  color: var(--gold);
}

.attach-remove::before,
.attach-remove::after {
  content: "";
  position: absolute;
  inset-block-start: 50%;
  inset-inline-start: 50%;
  width: 1rem;
  height: 2px;
  margin-inline-start: -0.5rem;
  background: currentColor;
}

.attach-remove::before {
  transform: rotate(45deg);
}

.attach-remove::after {
  transform: rotate(-45deg);
}

.attach-refusal {
  margin: 0;
  color: var(--alert);
  font-weight: 600;
}

/* what one answer left empty is refused with, and what the form says back */

.form-refusal {
  margin: 0;
  color: var(--alert);
  font-weight: 600;
}

.form-confirmation,
.book-review {
  margin-top: clamp(2rem, 4vw, 2.75rem);
  border: 1px solid var(--line-soft);
  background: var(--panel);
  padding: clamp(1.5rem, 5vw, 3.25rem);
}

.form-confirmation > :first-child,
.book-review > :first-child {
  margin-top: 0;
}

.form-confirmation-heading,
.book-review-heading {
  margin: 0 0 1rem;
  font-size: clamp(1.5rem, 1vw + 1.2rem, 2rem);
  font-style: italic;
}

.form-confirmation-lead {
  color: var(--heading);
  font-size: 1.1rem;
}

.form-confirmation:focus-visible,
.book-review:focus-visible,
.calendar:focus-visible {
  outline: 2px solid var(--focus);
  outline-offset: 4px;
}

.form-answers,
.book-review-answers {
  display: grid;
  gap: 0.25rem;
  margin: 1.5rem 0;
}

.form-answers dt,
.book-review-name {
  color: #a0a0a0;
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

.form-answers dd {
  margin: 0 0 1rem;
  color: var(--bright);
  white-space: pre-wrap;
  overflow-wrap: anywhere;
}

/* the review step: everything filled in, shown back before anything is sent.
   Every picture of the review stands under one heading, so each one is given
   a row of its own inside it rather than a heading of its own. */

.book-review-picture {
  display: flex;
  flex-wrap: wrap;
  gap: 0.6rem;
  align-items: center;
  margin: 0 0 0.4rem;
}

.book-review-given {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  flex-wrap: wrap;
  margin: 0 0 1.25rem;
  color: var(--bright);
}

.book-review-words {
  flex: 1 1 12rem;
  min-width: 0;
  white-space: pre-wrap;
  overflow-wrap: anywhere;
}

.book-review-thumb {
  flex: none;
  width: 3.5rem;
  height: 3.5rem;
  object-fit: cover;
  border-radius: 2px;
}

.book-review-change,
.book-review-back {
  flex: none;
  min-height: 2.5rem;
  border: 1px solid #3a3a3a;
  border-radius: 0;
  background: transparent;
  padding: 0.5rem 1rem;
  color: var(--text);
  font: inherit;
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  cursor: pointer;
}

.book-review-change:hover,
.book-review-back:hover {
  border-color: var(--gold);
  color: var(--gold);
}

.book-review-change:focus-visible,
.book-review-back:focus-visible {
  outline: 2px solid var(--focus);
  outline-offset: 3px;
}

.book-review-controls {
  display: flex;
  gap: 0.75rem;
  flex-wrap: wrap;
  align-items: center;
}

.contact-reach {
  margin-top: 1.75rem;
  margin-bottom: 0;
}

/* the month grids: seven named columns and a row to a week, one month shown */

.calendar {
  display: grid;
  gap: 1rem;
  border-top: 1px solid var(--line);
  padding-top: 1.75rem;
}

.calendar-month {
  width: 100%;
  border-collapse: separate;
  border-spacing: 0.25rem;
  table-layout: fixed;
}

.calendar-month[hidden] {
  display: none;
}

.calendar-month-name {
  padding: 0 0.25rem 0.75rem;
  color: var(--heading);
  font-family: var(--display);
  font-size: 1.45rem;
  font-weight: 700;
  line-height: 1.2;
  text-align: left;
}

/* The head of each column, which is the short spelling of the weekday the
   build writes there, with the long one in the label it is read out under.
   The long one does not fit in a seventh of a narrow screen and was broken
   across two lines in the middle of the word, so nothing here is allowed to
   break a word: the word that is drawn is short enough to stand. */

.calendar-weekday {
  padding: 0.3rem 0;
  color: var(--muted);
  font-size: 0.7rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-align: center;
  text-transform: uppercase;
  vertical-align: bottom;
  overflow-wrap: normal;
  word-break: normal;
  hyphens: none;
  white-space: nowrap;
}

.calendar-cell,
.calendar-blank {
  padding: 0;
  text-align: center;
}

.calendar-day {
  display: block;
  position: relative;
  width: 100%;
  min-height: 3.4rem;
  border: 1px solid #2f2f2f;
  border-radius: var(--radius);
  background: var(--cell);
  padding: 0.35rem 0;
  color: var(--bright);
  font: inherit;
  font-size: 0.95rem;
  line-height: 1.2;
  cursor: pointer;
}

/* A day says its number and, where it cannot be picked, why not, in small
   capitals under the number. A day that can be picked holds no room for a
   reason, so it looks as it did. */

.calendar-day-number {
  display: block;
}

.calendar-day-reason {
  display: block;
  margin-top: 0.15rem;
  font-size: 0.58rem;
  letter-spacing: 0.04em;
  line-height: 1.1;
  text-transform: uppercase;
  white-space: nowrap;
  overflow-wrap: normal;
}

.calendar-day-reason:empty {
  display: none;
}

.calendar-day:hover {
  border-color: var(--gold);
  color: var(--gold);
}

/* a day that is picked: outlined in gold, its number in gold, with a small
   gold mark under it for each time asked for on it */

.calendar-day-picked,
.calendar-day[aria-pressed="true"] {
  border-color: var(--gold);
  box-shadow: inset 0 0 0 1px var(--gold);
  background: var(--gold-wash);
  color: var(--gold);
}

.calendar-day-picked::after {
  content: "";
  position: absolute;
  left: 50%;
  bottom: 0.3rem;
  width: 0.3rem;
  height: 0.3rem;
  margin-left: -0.15rem;
  border-radius: 50%;
  background: var(--gold);
}

/* The day whose times stand open, outlined while they do, so a clicked day is
   marked the moment it is clicked, before a time has been chosen on it. */

.calendar-day-opened {
  border-color: var(--gold);
  box-shadow: inset 0 0 0 2px var(--gold);
  background: var(--gold);
  color: var(--on-gold);
}

.calendar-day-opened:hover {
  color: var(--on-gold);
}

.calendar-day-opened.calendar-day-picked::after {
  background: var(--on-gold);
}

.calendar-day:focus-visible {
  outline: 2px solid var(--focus);
  outline-offset: 2px;
}

.calendar-day-unavailable,
.calendar-day:disabled {
  border-color: transparent;
  background: transparent;
  box-shadow: none;
  color: var(--faint);
  cursor: default;
}

.calendar-day-unavailable:hover,
.calendar-day:disabled:hover {
  border-color: transparent;
  color: var(--faint);
}

/* the way back and the way on: chevrons of plain borders, and no character */

.calendar-months {
  display: flex;
  gap: 0.5rem;
  justify-content: flex-end;
  margin-bottom: -3.25rem;
}

.calendar-previous,
.calendar-next {
  position: relative;
  z-index: 1;
  width: var(--overlay-control);
  height: var(--overlay-control);
  margin: 0;
  border: 1px solid #3a3a3a;
  border-radius: 50%;
  background: transparent;
  padding: 0;
  color: var(--bright);
  font: inherit;
  cursor: pointer;
}

.calendar-previous::before,
.calendar-next::before {
  content: "";
  position: absolute;
  inset-block-start: 50%;
  inset-inline-start: 50%;
  width: 0.55rem;
  height: 0.55rem;
  border-block-start: 2px solid currentColor;
  border-inline-start: 2px solid currentColor;
}

.calendar-previous::before {
  transform: translate(-30%, -50%) rotate(-45deg);
}

.calendar-next::before {
  transform: translate(-70%, -50%) rotate(135deg);
}

.calendar-previous:hover,
.calendar-next:hover {
  border-color: var(--gold);
  color: var(--gold);
}

.calendar-previous:focus-visible,
.calendar-next:focus-visible {
  outline: 2px solid var(--focus);
  outline-offset: 2px;
}

.calendar-previous:disabled,
.calendar-next:disabled {
  opacity: 0.3;
  cursor: default;
}

.calendar-previous:disabled:hover,
.calendar-next:disabled:hover {
  border-color: #3a3a3a;
  color: var(--bright);
}

/* the three times a day can be asked for, shown below the grid when a day is
   chosen and hidden the rest of the time, with the line naming the day above
   them on a row of its own */

.calendar-times {
  display: flex;
  gap: 0.5rem;
  flex-wrap: wrap;
  border: 1px solid var(--rule-gold);
  border-radius: var(--radius);
  background: #111111;
  padding: 1rem;
}

.calendar-times-heading {
  flex: 1 1 100%;
  margin: 0 0 0.25rem;
  color: var(--gold);
  font-weight: 600;
}

.calendar-times[hidden] {
  display: none;
}

.calendar-time {
  flex: 1 1 5rem;
  min-height: 2.75rem;
  border: 1px solid #3a3a3a;
  border-radius: var(--radius);
  background: var(--cell);
  padding: 0.35rem 0.5rem;
  color: var(--bright);
  font: inherit;
  cursor: pointer;
}

.calendar-time:hover {
  border-color: var(--gold);
  color: var(--gold);
}

.calendar-time[aria-pressed="true"] {
  border-color: var(--gold);
  background: var(--gold);
  color: var(--on-gold);
}

.calendar-time:focus-visible {
  outline: 2px solid var(--focus);
  outline-offset: 2px;
}

/* the dates picked, listed under the grid the whole time, each line with the
   control that takes it off again, and below them the sentence that says why
   no further day is offered, which the script shows at the fourth pick */

.calendar-picks {
  display: grid;
  gap: 0.6rem;
}

.calendar-picks[hidden] {
  display: none;
}

.calendar-picks-heading {
  margin: 0;
  color: #a0a0a0;
  font-family: var(--body);
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

.calendar-picks-list {
  display: grid;
  gap: 0.4rem;
}

.calendar-pick {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  border: 1px solid var(--rule-gold);
  border-radius: var(--radius);
  background: #111111;
  padding: 0.45rem 0.5rem 0.45rem 0.85rem;
  color: var(--bright);
}

.calendar-pick-date {
  flex: 1 1 auto;
}

.calendar-pick-remove {
  position: relative;
  flex: 0 0 auto;
  width: 2.25rem;
  height: 2.25rem;
  margin: 0;
  border: 1px solid #3a3a3a;
  border-radius: 50%;
  background: transparent;
  padding: 0;
  color: var(--bright);
  font: inherit;
  cursor: pointer;
}

.calendar-pick-remove::before,
.calendar-pick-remove::after {
  content: "";
  position: absolute;
  inset-block-start: 50%;
  inset-inline-start: 50%;
  width: 0.75rem;
  border-block-start: 2px solid currentColor;
}

.calendar-pick-remove::before {
  transform: translate(-50%, -50%) rotate(45deg);
}

.calendar-pick-remove::after {
  transform: translate(-50%, -50%) rotate(-45deg);
}

.calendar-pick-remove:hover {
  border-color: var(--gold);
  color: var(--gold);
}

.calendar-pick-remove:focus-visible {
  outline: 2px solid var(--focus);
  outline-offset: 2px;
}

.calendar-limit {
  margin: 0;
  color: var(--gold);
}

.calendar-limit[hidden] {
  display: none;
}

/* a narrow grid: a little less room between the days, and a smaller reason */

@media (max-width: 29.99rem) {
  .calendar-month {
    border-spacing: 0.15rem;
  }

  .calendar-weekday {
    font-size: 0.62rem;
    letter-spacing: 0.02em;
  }

  .calendar-day {
    min-height: 3.1rem;
    font-size: 0.9rem;
  }

  .calendar-day-reason {
    font-size: 0.5rem;
    letter-spacing: 0;
  }
}

/* footer: three columns, then a row of plain links to every section */

.site-footer {
  margin-top: auto;
  border-top: 1px solid var(--line-soft);
  background: var(--bg);
  padding: clamp(2.5rem, 6vw, 4rem) 0 2.5rem;
  color: var(--muted);
  font-size: 0.9rem;
}

.footer-columns {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 1.5rem;
}

@media (min-width: 48rem) {
  .footer-columns {
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 2.5rem;
  }
}

.site-footer p {
  margin: 0 0 0.45rem;
  line-height: 1.6;
}

.footer-offer {
  max-width: 22rem;
}

.site-footer a {
  text-decoration: none;
}

.site-footer a:hover {
  text-decoration: underline;
}

/* the way to Instagram is the logo, in the footer and on Contact */

.instagram-logo {
  width: 10rem;
}

.footer-instagram,
.contact-instagram {
  display: inline-block;
  padding: 0.35rem 0;
}

.footer-instagram:hover .instagram-logo,
.contact-instagram:hover .instagram-logo {
  opacity: 0.8;
}

.footer-links {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 0.5rem 1.75rem;
  margin-top: clamp(2rem, 5vw, 3rem);
  border-top: 1px solid var(--line-soft);
  padding-top: 1.75rem;
}

.footer-links a {
  color: #8a8a8a;
  font-size: 0.72rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.footer-links a:hover {
  color: var(--gold);
  text-decoration: none;
}

/* the two views: one page, written whole, with one set of blocks shown
   ----------------------------------------------------------------------
   Every page carries both the blocks only the owner sees and the blocks only
   a visitor sees, and these four rules decide which set is drawn. The owner
   view class is put on the root element by assets/view.js when the address
   carries view=owner, and by nothing else: with no query in the address no
   class is there, every owner block is hidden and every visitor block shows,
   so the site is a visitor's site until the owner asks for their own view.

   Hiding is done with a rule naming the view that must not be drawn, never by
   stripping the block out of the markup, so a check can find both blocks on
   every page and read the view each one belongs to off its data-view
   attribute. The block that is drawn keeps whatever display its own rules give
   it, because only the hidden one is named here.

   This is a mockup control and not a lock. Nothing on this site has a
   password, and anyone who edits the address reaches the owner's view; what
   keeps it to the owner is that scripts/preview.py answers on the loopback
   interface only, so the preview is reachable from this machine alone. */

:root:not(.owner-view) .owner-only,
:root:not(.owner-view) [data-view="owner"] {
  display: none;
}

:root.owner-view .visitor-only,
:root.owner-view [data-view="visitor"] {
  display: none;
}

.footer-view {
  margin-top: 0.45rem;
}

/* The label on each half of the switch.

   The build carries it in an attribute and it is written out here, because the
   footer stands on every page alike and the two pages of writing under
   /tattoos/ are held to the writing content/wording.json gives them and
   nothing else. The words are still the value of the wording key: this rule
   prints whatever that attribute holds and has no words of its own. Only the
   half belonging to the view being read is drawn at all, because the rules
   above hide the other one outright. */

.footer-view a[data-view-label]::before {
  content: attr(data-view-label);
}

/* The marker beside writing that is still a stand in.

   It is drawn only in the owner's view, because the rules above hide every
   owner block until the address asks for that view, and it is set apart from
   the words it is about by size, colour and a rule down its side rather than
   by any character, so nothing in it is a mark a person has to read. */

.owner-placeholder {
  margin-top: 0.5rem;
  margin-bottom: 0;
  border-left: 2px solid var(--gold);
  padding-left: 0.7rem;
  color: #c8b27e;
  font-size: 0.8rem;
}

/* The same marker where it cannot be a block of its own: on the questions and
   answers page and the after care page, where each block is one heading and
   one paragraph and nothing besides, the build puts the note in an attribute
   on the writing it is about and it is drawn here.

   It is drawn in the owner's view and in no other: the note has no content
   outside this rule, so with no query in the address there is nothing to draw
   and nothing is added to the page a visitor reads. It is set apart from the
   words above it the way .owner-placeholder is, and by the same means. */

:root.owner-view [data-placeholder-note]::after {
  content: attr(data-placeholder-note);
  display: block;
  margin: 0.5rem 0 0;
  border-left: 2px solid var(--gold);
  padding-left: 0.7rem;
  color: #c8b27e;
  /* The note is a note wherever it is drawn, so on a heading it drops the
     heading's display face, its slant and its letter spacing. Set in those it
     was hard to read, and the key it names is spelled the way the file the
     owner has to find it in spells it. */
  font-family: var(--body);
  font-size: 0.8rem;
  font-style: normal;
  font-weight: normal;
  letter-spacing: normal;
  line-height: 1.5;
  text-transform: none;
}

/* The note saying where a page reads what it shows.

   It is drawn like the marker above it, for the same reason: both are the
   build telling the owner where to go and neither is wording a visitor meets.
   It sits outside the block the pieces of a page sit in, so no piece ever has
   anything written under it. */

.owner-source {
  margin-top: 1.25rem;
  margin-bottom: 0;
  border-left: 2px solid var(--gold);
  padding-left: 0.7rem;
  color: #c8b27e;
  font-size: 0.8rem;
}

.page-home > .owner-source {
  margin-top: 1.5rem;
}

/* The path inside such a note.

   A path is a filename and not wording: the tattoo folder carries a hyphen,
   which nothing a person reads on this site may, so the build leaves the path
   in a data attribute and these rules draw it. The span itself is empty, so
   no text node of any page holds the path, and a check can still read it off
   the one attribute it sits in. */

.owner-path {
  color: var(--bright);
  font-family: ui-monospace, Menlo, Consolas, monospace;
  overflow-wrap: anywhere;
}

.owner-path[data-art-folder]::before {
  content: attr(data-art-folder);
}

.owner-path[data-content-file]::before {
  content: attr(data-content-file);
}

.owner-path[data-content-field]::before {
  content: attr(data-content-field);
}

.owner-path[data-type-word]::before {
  content: attr(data-type-word);
}

.owner-path[data-placeholder-key]::before {
  content: attr(data-placeholder-key);
}

/* The request as it would reach the owner, on the booking page.

   One block only the owner sees, so the rules of the two views above are what
   keeps it from a visitor: no script shows it and no script hides it. It is
   set apart from the visitor's own review the way the notes above are set
   apart from the writing they are about, by colour and a rule down its side
   rather than by any character.

   Nothing here gives the block a display of its own, so the rule that hides
   every owner block until the address asks for the owner's view goes on
   winning. */

.book-request {
  margin-top: 2rem;
  border-left: 2px solid var(--gold);
  padding-left: 0.9rem;
  font-size: 0.9rem;
}

.book-request-note {
  margin: 0;
  color: #c8b27e;
  font-size: 0.8rem;
}

.book-request-answers {
  margin: 0.9rem 0 0;
}

.book-request-name {
  color: #a0a0a0;
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.book-request-given {
  margin: 0 0 0.6rem;
  color: var(--bright);
  overflow-wrap: anywhere;
}

.book-request-dates {
  margin: 0.9rem 0 0;
}

.book-request-date {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  align-items: baseline;
  margin: 0 0 0.5rem;
}

.book-request-date[hidden] {
  display: none;
}

.book-request-line {
  color: var(--bright);
  overflow-wrap: anywhere;
}

.book-request-state {
  color: var(--gold);
  font-weight: 700;
}

/* The owner's own controls in this panel and in the schedule beside it.

   The one that has been pressed is filled in, so which of them it was is
   plain at a glance, and the rest are outlined like every other control on
   the site. */

.book-request-accept,
.book-request-whole-accept,
.calendar-owner-flip {
  min-height: 2.25rem;
  border: 1px solid #3a3a3a;
  border-radius: 0;
  background: transparent;
  padding: 0.25rem 0.8rem;
  color: var(--text);
  font: inherit;
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  cursor: pointer;
}

.book-request-accept:hover,
.book-request-whole-accept:hover,
.calendar-owner-flip:hover {
  border-color: var(--gold);
  color: var(--gold);
}

.book-request-accept:focus-visible,
.book-request-whole-accept:focus-visible,
.calendar-owner-flip:focus-visible {
  outline: 2px solid var(--focus);
  outline-offset: 2px;
}

/* An item of the schedule that is switched on, which is how the build draws
   every one of them, against one flipped off for this page only. */

.calendar-owner-flip[aria-pressed="true"] {
  border-color: var(--gold);
  background: var(--gold);
  color: var(--on-gold);
}

.calendar-owner-flip[aria-pressed="true"]:hover {
  color: var(--on-gold);
}

.calendar-owner-flip[aria-pressed="false"] {
  border-color: #3a3a3a;
  background: transparent;
  color: var(--muted);
}

/* The accept control that has been pressed: filled in and no longer offering
   the press again. */

.book-request-accept-taken,
.book-request-accept:disabled,
.book-request-whole-accept:disabled {
  border-color: var(--gold);
  background: var(--gold);
  color: var(--on-gold);
  cursor: default;
}

.book-request-accept-taken:hover,
.book-request-accept:disabled:hover,
.book-request-whole-accept:disabled:hover {
  border-color: var(--gold);
  color: var(--on-gold);
}

/* The heading over the dates of the request, and the way to accept the whole
   of it under them. */

.book-request-dates-heading {
  margin: 1.2rem 0 0.5rem;
  font-size: 1.1rem;
  line-height: 1.2;
}

.book-request-whole {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  align-items: baseline;
  margin: 0.8rem 0 0;
}

/* The owner's own view of the schedule, beside the grids on the booking page.

   One block only the owner sees, so the rules of the two views above are the
   whole of what keeps it from a visitor: no script shows it and no script
   hides it. Nothing here gives the block a display of its own, so the rule
   that hides every owner block until the address asks for the owner's view
   goes on winning.

   Every control in it is here, in the panel, and not one of them is inside a
   day cell: a cell is what a visitor picks, and it is left exactly as the
   build decided it. */

.calendar-owner {
  margin-top: 1rem;
  border-left: 2px solid var(--gold);
  padding-left: 0.9rem;
  font-size: 0.9rem;
}

.calendar-owner-heading {
  margin: 0;
  font-size: 1.1rem;
}

.calendar-owner-group {
  margin: 0.9rem 0 0;
}

.calendar-owner-group-heading {
  margin: 0;
  color: #a0a0a0;
  font-family: var(--body);
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.calendar-owner-list {
  margin: 0.4rem 0 0;
}

.calendar-owner-item {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  align-items: baseline;
  margin: 0 0 0.35rem;
}

.calendar-owner-name {
  color: var(--bright);
  overflow-wrap: anywhere;
}

/* An item flipped off for this page only. It stays on the list, so the same
   flip puts it back, and it is drawn faded rather than struck through, because
   a line through it is a mark a person has to read. */

.calendar-owner-item-off .calendar-owner-name {
  color: var(--muted);
  opacity: 0.5;
}

.calendar-owner-empty {
  margin: 0.3rem 0 0;
  color: var(--muted);
  font-size: 0.8rem;
}

.calendar-owner-empty[hidden] {
  display: none;
}

/* The one line of content/schedule.json that would make a change last.

   It is drawn from a data attribute and the element itself is empty, the way
   a path is: the line holds ISO dates, and an ISO date carries a hyphen, which
   nothing a person reads on this site may. So no text node of the page holds
   it, and a check can still read it off the one attribute it sits in. */

.calendar-owner-line {
  margin: 0.35rem 0 0;
  border-radius: 2px;
  background: #0d0d0d;
  padding: 0.35rem 0.5rem;
  color: var(--bright);
  font-family: ui-monospace, Menlo, Consolas, monospace;
  font-size: 0.8rem;
  white-space: pre-wrap;
  overflow-wrap: anywhere;
}

.calendar-owner-line[data-schedule-paste]::before {
  content: attr(data-schedule-paste);
}

.calendar-owner-note {
  margin: 0.9rem 0 0;
  color: #c8b27e;
  font-size: 0.8rem;
}

/* The page that lists every difference between the two views.

   It is drawn in both views, because the list is what the page is for and not
   something the owner is shown in a visitor's place: nothing here names
   .owner-only, so the rules of the two views leave the whole list alone.

   One group to a page, in the order routes.py gives, each named by a heading
   that links into the owner's view of that page. A group with nothing in it
   says so in one line instead of an empty list. Nothing is set apart by a
   character: size, colour and a rule down the side do all of it. */

.owner-differences {
  margin-top: 2.5rem;
}

.owner-differences > h2 {
  margin: 0;
  font-size: clamp(1.3rem, 1vw + 1rem, 1.7rem);
  font-style: italic;
  line-height: 1.25;
}

.owner-ways {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin: 0 0 2rem;
}

.owner-ways a {
  border: 1px solid #3a3a3a;
  border-radius: 999px;
  padding: 0.3rem 0.85rem;
  font-size: 0.85rem;
  text-decoration: none;
}

.owner-ways a:hover {
  border-color: var(--gold);
}

.owner-page {
  margin: 1.5rem 0 0;
  border-left: 2px solid var(--line);
  padding-left: 0.9rem;
}

.owner-page-name {
  margin: 0;
  font-size: 1.05rem;
}

.owner-page-name a {
  color: var(--heading);
  text-decoration: none;
}

.owner-page-name a:hover {
  color: var(--gold);
}

.owner-difference-list {
  margin: 0.5rem 0 0;
}

.owner-difference {
  margin: 0 0 0.6rem;
  font-size: 0.9rem;
}

.owner-difference-name {
  display: block;
}

.owner-difference .owner-path {
  display: block;
  color: var(--muted);
  font-size: 0.8rem;
}

.owner-same {
  margin: 0.5rem 0 0;
  color: var(--muted);
  font-size: 0.9rem;
}

/* the Reviews page: the articles that name the owner, then what clients
   wrote, each review a quote under five gold stars */

.mentions,
.reviews {
  margin-top: clamp(2rem, 5vw, 3rem);
}

.mentions h2,
.reviews h2 {
  margin: 0 0 1rem;
  color: var(--gold);
  font-family: var(--body);
  font-size: 0.8rem;
  font-weight: 600;
  letter-spacing: 0.24em;
  text-transform: uppercase;
}

.mention,
.review {
  margin: 0 0 1.25rem;
  padding: 1.5rem 1.6rem;
  border: 1px solid var(--rule-gold);
  background: rgba(255, 255, 255, 0.02);
}

.mention-outlet {
  margin: 0;
  font-family: var(--display);
  font-size: clamp(1.4rem, 1vw + 1.1rem, 1.8rem);
  font-style: italic;
}

.mention-title {
  margin: 0.35rem 0 0;
  color: var(--muted);
}

.mention-title a {
  color: #d8d8d8;
}

.mention-date {
  margin-left: 0.5rem;
  color: var(--muted);
}

.mention-quote,
.review-text {
  margin: 1rem 0 0;
  padding: 0;
  color: #d0d0d0;
  font-size: clamp(1.05rem, 0.4vw + 0.95rem, 1.2rem);
  line-height: 1.6;
}

.mention-quote p,
.review-text p {
  margin: 0;
}

.mention-read {
  margin: 1rem 0 0;
  font-size: 0.9rem;
}

.mention-read a,
.reviews-google a {
  color: var(--gold);
}

.review-stars {
  margin: 0;
  color: var(--gold);
  font-size: 1.05rem;
  letter-spacing: 0.15em;
}

.review .review-text {
  margin-top: 0.6rem;
}

.review-by {
  margin: 0.9rem 0 0;
  color: var(--muted);
  font-size: 0.9rem;
}

.reviews-empty {
  color: var(--muted);
}

.reviews-google {
  margin-top: 1.5rem;
  margin-bottom: 0;
}

.reviews-count {
  margin: 0 0 1.4rem;
  font-size: clamp(1.1rem, 0.5vw + 1rem, 1.35rem);
}

.reviews-count a {
  color: #e6e6e6;
  text-decoration: none;
}

.reviews-count a:hover,
.reviews-count a:focus-visible {
  text-decoration: underline;
}

.reviews-count-stars {
  color: var(--gold);
  letter-spacing: 0.12em;
}

.reviews-more {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 1.25rem;
  margin: 1.5rem 0 0;
}

.reviews-more[hidden] {
  display: none;
}

.reviews-more .button {
  background: transparent;
  cursor: pointer;
  font-family: inherit;
}

.reviews-more .button:hover,
.reviews-more .button:focus-visible {
  background: rgba(220, 185, 106, 0.12);
}

.reviews-all {
  appearance: none;
  border: 0;
  padding: 0;
  background: none;
  color: var(--gold);
  font: inherit;
  text-decoration: underline;
  cursor: pointer;
}

.review:focus {
  outline: 2px solid var(--gold);
  outline-offset: 3px;
}
