/* betterwoot.com. Follows the brand guide's Web section: tokens from
   /betterwoot.css, one centered column (--bw-page) with 16 px side margins on
   phones, sections alternating Paper and Paper Dark under a 2 px Ink rule, one
   filled button ("Add to Chrome"), everything else a plain Cap Blue link. Text
   on Paper Dark is Ink or Cap Blue; Red Text only on Paper. */

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  background: var(--bw-paper);
  color: var(--bw-ink);
  -webkit-text-size-adjust: 100%;
}

body {
  margin: 0;
  font: var(--bw-text-body) / var(--bw-leading-body) var(--bw-font-body);
  background: var(--bw-paper);
}

[hidden] {
  display: none !important;
}

img {
  max-width: 100%;
  height: auto;
}

a {
  color: var(--bw-blue);
  text-underline-offset: 0.15em;
}

a:hover {
  text-decoration-thickness: 2px;
}

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

.skip {
  position: absolute;
  left: 8px;
  top: -60px;
  z-index: 30;
  padding: 8px 12px;
  border: var(--bw-border);
  background: var(--bw-yellow);
  color: var(--bw-ink);
  font: 700 14px/1 var(--bw-font-mono);
  text-decoration: none;
}

.skip:focus {
  top: 8px;
}

.wrap {
  width: 100%;
  max-width: calc(var(--bw-page) + 2 * var(--bw-space-4));
  margin: 0 auto;
  padding: 0 var(--bw-space-4);
}

.band {
  border-top: 2px solid var(--bw-ink);
  padding: var(--bw-space-8) 0;
}

.band.alt {
  background: var(--bw-paper-dark);
}

.band.tight {
  padding: var(--bw-space-6) 0;
}

/* ---------- type ---------- */

h1,
h2,
h3 {
  margin: 0;
  font-family: var(--bw-font-display);
  font-weight: 400;
  letter-spacing: -0.01em;
}

h1 {
  font-size: var(--bw-text-hero);
  line-height: var(--bw-leading-hero);
}

h2 {
  font-size: var(--bw-text-h2);
  line-height: var(--bw-leading-h2);
}

h3 {
  font-size: var(--bw-text-h3);
  line-height: var(--bw-leading-h3);
}

p {
  margin: 0;
}

.lede {
  font-size: var(--bw-text-lede);
  line-height: var(--bw-leading-lede);
}

.small {
  font-size: var(--bw-text-small);
  line-height: var(--bw-leading-small);
}

.muted {
  color: var(--bw-muted-on-paper);
}

.mono {
  font-family: var(--bw-font-mono);
  font-size: var(--bw-text-data);
  line-height: var(--bw-leading-data);
}

.eyebrow {
  display: block;
  margin-bottom: var(--bw-space-3);
  font: 700 var(--bw-text-eyebrow) / var(--bw-leading-eyebrow) var(--bw-font-mono);
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

/* A highlight block: one per headline, never with another accent. */
.hi {
  display: inline-block;
  line-height: 1;
  padding: 0 0.18em 0.19em;
  margin-block: 0.04em;
  border: max(2px, 0.05em) solid var(--bw-ink);
  background: var(--bw-yellow);
  color: var(--bw-ink);
  box-shadow: 0.07em 0.07em 0 var(--bw-ink);
}

/* ---------- the one button (brand guide, Web) ---------- */

.bw-button {
  display: inline-block;
  font: 400 20px/1 var(--bw-font-display);
  color: var(--bw-ink);
  background: var(--bw-yellow);
  padding: 16px 24px;
  border: var(--bw-border);
  border-radius: var(--bw-radius);
  box-shadow: var(--bw-shadow);
  text-decoration: none;
  cursor: pointer;
  transition: transform 80ms, box-shadow 80ms;
}

.bw-button:hover {
  background: var(--bw-yellow-hover);
}

.bw-button:active {
  transform: translate(3px, 3px);
  box-shadow: var(--bw-shadow-pressed);
}

.bw-button:focus-visible {
  outline: 3px solid var(--bw-blue);
  outline-offset: 3px;
}

@media (prefers-reduced-motion: reduce) {
  .bw-button {
    transition: none;
  }
}

/* ---------- masthead and footer ---------- */

.masthead {
  padding: var(--bw-space-4) 0;
}

.masthead .wrap {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--bw-space-4);
}

.masthead .lockup {
  display: block;
  height: 40px;
  width: auto;
}

.masthead nav {
  display: flex;
  gap: var(--bw-space-5);
  font-weight: 600;
}

.masthead nav a[aria-current='page'] {
  color: var(--bw-ink);
  text-decoration: none;
}

.site-footer {
  border-top: 2px solid var(--bw-ink);
  padding: var(--bw-space-7) 0;
  background: var(--bw-ink);
  color: var(--bw-paper);
}

/* Lockup, links and disclaimer on the left; the C.S. Assets monogram on the
   right, as on the other C.S. Assets projects (xnnoying.com). */
.site-footer .wrap {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  grid-template-areas: "brand mark" "nav mark" "legal mark";
  column-gap: var(--bw-space-6);
  align-items: start;
}

.site-footer .lockup {
  grid-area: brand;
  display: block;
  height: 36px;
  width: auto;
  margin-bottom: var(--bw-space-4);
}

/* The C.S. Assets monogram (C.S. Assets Identity Standards, unframed, in
   Paper) as a faint watermark. Fully drawn while focused, so the focus ring
   isn't faint too. */
.foot-mark {
  grid-area: mark;
  justify-self: end;
  align-self: start;
  display: block;
  height: 72px;
  opacity: 0.14;
  transition: opacity 0.15s;
}

.foot-mark:hover {
  opacity: 0.32;
}

.foot-mark:focus-visible {
  opacity: 1;
  outline-color: var(--bw-yellow);
}

.foot-mark img {
  display: block;
  width: auto;
  height: 100%;
}

@media (prefers-reduced-motion: reduce) {
  .foot-mark {
    transition: none;
  }
}

@media (max-width: 640px) {
  .site-footer .wrap {
    grid-template-columns: minmax(0, 1fr);
    grid-template-areas: "brand" "nav" "legal" "mark";
  }

  .foot-mark {
    justify-self: start;
    height: 56px;
    margin-top: var(--bw-space-5);
  }
}

.site-footer a {
  color: var(--bw-paper);
}

.site-footer nav {
  grid-area: nav;
  display: flex;
  flex-wrap: wrap;
  gap: var(--bw-space-5);
  margin-bottom: var(--bw-space-4);
  font-weight: 600;
}

.site-footer .disclaimer {
  grid-area: legal;
  color: var(--bw-muted-on-ink);
}

/* ---------- landing ---------- */

.hero {
  padding: var(--bw-space-7) 0 0;
}

.hero .wrap {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: var(--bw-space-6);
  align-items: end;
}

.hero-copy {
  padding-bottom: var(--bw-space-8);
}

.hero-copy .lede {
  margin: var(--bw-space-4) 0 var(--bw-space-6);
}

.hero-cta {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: var(--bw-space-4);
}

/* Rotor's flat-cut bust stands on the section's bottom rule. */
.hero-rotor {
  display: block;
  justify-self: center;
  width: min(100%, 320px);
  height: auto;
  margin-bottom: -2px;
}

@media (min-width: 760px) {
  .hero .wrap {
    grid-template-columns: minmax(0, 1.4fr) minmax(0, 1fr);
  }
}

.search-teaser h2 {
  margin-bottom: var(--bw-space-4);
}

.search-teaser p {
  max-width: 40em;
  margin-bottom: var(--bw-space-5);
}

.quick-search {
  display: flex;
  gap: var(--bw-space-3);
  max-width: 640px;
}

.features {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: var(--bw-space-6) var(--bw-space-5);
  margin-top: var(--bw-space-6);
}

@media (min-width: 640px) {
  .features {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (min-width: 900px) {
  .features {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}

.feature h3 {
  margin: var(--bw-space-4) 0 var(--bw-space-2);
}

/* Feature icons sit on a Beanie Yellow keycap with an Ink border and a hard
   shadow (brand guide, Icons). */
.keycap {
  display: inline-grid;
  place-items: center;
  width: 56px;
  height: 56px;
  border: var(--bw-border);
  border-radius: var(--bw-radius);
  background: var(--bw-yellow);
  box-shadow: var(--bw-shadow);
}

.keycap img {
  width: 32px;
  height: 32px;
}

.plain-list {
  margin: var(--bw-space-4) 0 0;
  padding: 0;
  list-style: none;
}

.plain-list li {
  padding: var(--bw-space-2) 0;
  border-bottom: 1px solid color-mix(in srgb, var(--bw-ink) 25%, transparent);
}

.plain-list li:last-child {
  border-bottom: 0;
}

/* ---------- fields ---------- */

.field-input,
.field-select {
  height: 48px;
  min-width: 0;
  padding: 0 var(--bw-space-3);
  border: var(--bw-border);
  border-radius: var(--bw-radius);
  background: var(--bw-paper);
  color: var(--bw-ink);
  font: inherit;
}

.field-input::placeholder {
  color: var(--bw-muted-on-paper);
  opacity: 1;
}

.field-select {
  appearance: none;
  padding-right: 32px;
  background: var(--bw-paper) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath d='M1 1.5l5 5 5-5' fill='none' stroke='%231E1B18' stroke-width='2' stroke-linecap='square'/%3E%3C/svg%3E") no-repeat right 12px center;
  cursor: pointer;
}

.search-box {
  position: relative;
  flex: 1;
  display: flex;
}

.search-box .field-input {
  flex: 1;
  padding-left: 44px;
  font-size: 19px;
  box-shadow: var(--bw-shadow);
}

.search-box::before {
  content: '';
  position: absolute;
  left: 12px;
  top: 50%;
  width: 22px;
  height: 22px;
  transform: translateY(-50%);
  background: url('/img/icons/search.svg') center / contain no-repeat;
  pointer-events: none;
}

/* ---------- search page ---------- */

.search-head {
  padding: var(--bw-space-6) 0 var(--bw-space-5);
}

.search-head h1 {
  font-size: var(--bw-text-h2);
  line-height: var(--bw-leading-h2);
  margin-bottom: var(--bw-space-4);
}

.filters {
  display: flex;
  flex-wrap: wrap;
  align-items: end;
  gap: var(--bw-space-3) var(--bw-space-4);
  margin-top: var(--bw-space-4);
}

.filters label {
  display: grid;
  gap: var(--bw-space-1);
  font: 700 var(--bw-text-eyebrow) / 1 var(--bw-font-mono);
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.filters .field-input,
.filters .field-select {
  height: 40px;
  font: 400 15px var(--bw-font-body);
  letter-spacing: 0;
  text-transform: none;
}

.filters .price {
  width: 96px;
  font-family: var(--bw-font-mono);
}

.filters .words {
  width: 180px;
}

.filters .check {
  display: flex;
  align-items: center;
  gap: var(--bw-space-2);
  height: 40px;
  font: 600 15px var(--bw-font-body);
  letter-spacing: 0;
  text-transform: none;
  cursor: pointer;
}

.check input {
  appearance: none;
  width: 22px;
  height: 22px;
  margin: 0;
  border: var(--bw-border);
  border-radius: var(--bw-radius);
  background: var(--bw-paper);
  cursor: pointer;
}

.check input:checked {
  background: var(--bw-yellow) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='14' height='14' viewBox='0 0 14 14'%3E%3Cpath d='M2.5 7.5l3 3 6-6.5' fill='none' stroke='%231E1B18' stroke-width='2.2' stroke-linecap='square'/%3E%3C/svg%3E") center / 14px no-repeat;
}

.results-status {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: var(--bw-space-2);
  margin-bottom: var(--bw-space-5);
}

.results {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: var(--bw-space-5) var(--bw-space-4);
  margin: 0;
  padding: 0;
  list-style: none;
}

@media (min-width: 640px) {
  .results {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}

@media (min-width: 900px) {
  .results {
    grid-template-columns: repeat(4, minmax(0, 1fr));
  }
}

.card {
  position: relative;
  display: flex;
  flex-direction: column;
  height: 100%;
  border: var(--bw-border);
  border-radius: var(--bw-radius);
  background: var(--bw-paper);
  box-shadow: var(--bw-shadow);
}

.card:focus-within {
  outline: 3px solid var(--bw-blue);
  outline-offset: 3px;
}

/* Product photos come on white; they keep it, inside the Ink frame. */
.card .photo {
  display: block;
  aspect-ratio: 4 / 3;
  border-bottom: var(--bw-border);
  background: #fff;
}

.card .photo img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: contain;
}

.card .body {
  display: flex;
  flex-direction: column;
  gap: var(--bw-space-2);
  flex: 1;
  padding: var(--bw-space-3);
}

.card .title {
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
  color: var(--bw-ink);
  font-weight: 600;
  font-size: var(--bw-text-small);
  line-height: 1.35;
  text-decoration: none;
}

.card .title::after {
  content: '';
  position: absolute;
  inset: 0;
}

.card .title:hover {
  text-decoration: underline;
}

.card .title:focus-visible {
  outline: none;
}

.prices {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: var(--bw-space-1) var(--bw-space-2);
  margin-top: auto;
  font-family: var(--bw-font-mono);
}

.prices .price {
  font-weight: 700;
  font-size: 17px;
}

.prices .list {
  color: var(--bw-muted-on-paper);
  font-size: 13px;
  text-decoration: line-through;
}

.prices .off {
  padding: 1px 5px;
  border: 2px solid var(--bw-ink);
  background: var(--bw-yellow);
  font-weight: 700;
  font-size: 13px;
}

.card .meta {
  font: 400 12px/1.3 var(--bw-font-mono);
  color: var(--bw-muted-on-paper);
}

.card.sold-out .photo img {
  opacity: 0.45;
}

.card .sold {
  color: var(--bw-red-text);
  font-weight: 700;
}

.more {
  display: flex;
  justify-content: center;
  margin-top: var(--bw-space-6);
}

.link-button {
  padding: 0;
  border: 0;
  background: none;
  color: var(--bw-blue);
  font: 600 var(--bw-text-body) var(--bw-font-body);
  text-decoration: underline;
  text-underline-offset: 0.15em;
  cursor: pointer;
}

.empty {
  display: grid;
  justify-items: center;
  gap: var(--bw-space-4);
  padding: var(--bw-space-6) 0 0;
  text-align: center;
}

.empty img {
  width: 220px;
  margin-bottom: -2px;
}

.notice {
  padding: var(--bw-space-4);
  border: var(--bw-border);
  background: var(--bw-paper-dark);
}

.visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
}

@media (max-width: 520px) {
  .masthead .lockup {
    height: 32px;
  }

  .band {
    padding: var(--bw-space-7) 0;
  }

  .filters label,
  .filters .words,
  .filters .field-select {
    width: 100%;
  }

  .filters .price-wrap {
    width: calc(50% - var(--bw-space-2));
  }

  .filters .price-wrap .price {
    width: 100%;
  }
}

/* Rotor's shrug is a flat-cut bust: it stands on the footer's rule. */
.band.flush-bottom {
  padding-bottom: 0;
}

.prose h2 {
  margin: var(--bw-space-7) 0 var(--bw-space-2);
  font-size: var(--bw-text-h3);
  line-height: var(--bw-leading-h3);
}

.prose .lede,
.prose p,
.prose ul {
  max-width: 42em;
}

.notice.wootoff {
  margin-bottom: var(--bw-space-5);
}
