/* Tattoo Unicorn - section layouts. Tokens and components live in base.css. */

/* -------------------------------------------------------------- header --- */

.site-head {
  position: sticky;
  top: 0;
  z-index: 50;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  background: var(--paper);
  border-bottom: 4px solid var(--ink);
  /* full-bleed bar, content still capped at --max */
  padding: 12px max(var(--pad), calc((100% - var(--max)) / 2));
}

.brand {
  display: flex;
  align-items: center;
  gap: 15px;
  color: inherit;
}
.brand img {
  width: 62px;
  height: 62px;
  transform: rotate(calc(var(--chaos) * -5deg));
}
.brand span {
  font-family: var(--font-label);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.24em;
  text-transform: uppercase;
  line-height: 1.7;
}

.nav {
  display: flex;
  align-items: center;
  gap: clamp(14px, 2vw, 30px);
  font-family: var(--font-label);
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.2em;
  text-transform: uppercase;
}
.nav a:not(.btn) {
  color: inherit;
  padding-bottom: 3px;
  border-bottom: 3px solid transparent;
}
.nav a:not(.btn):hover,
.nav a:not(.btn)[aria-current="page"] {
  color: var(--candy);
  border-bottom-color: var(--candy);
}

.nav-toggle {
  display: none;
  background: var(--candy);
  color: var(--ink);
  border: 3px solid var(--ink);
  box-shadow: 4px 4px 0 var(--ink);
  padding: 11px 16px;
  font-family: var(--font-label);
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  cursor: pointer;
}

/* ---------------------------------------------------------------- hero --- */

.hero {
  position: relative;
  /* the sticky bar sits above the hero now, so take its height off the fold */
  min-height: calc(100svh - 90px);
  display: flex;
  flex-direction: column;
  padding: clamp(18px, 3vh, 40px) var(--pad) 0;
  overflow: hidden;
}

.hero-ring {
  right: -18vw;
  top: -16vh;
  width: 60vw;
  height: 60vw;
  color: var(--ink);
}
.hero-diamond {
  position: absolute;
  left: -9vw;
  bottom: -10vw;
  width: 30vw;
  height: 30vw;
  background: var(--candy);
  transform: rotate(45deg);
  pointer-events: none;
}
.hero-dots {
  right: 6vw;
  bottom: 18vh;
  width: 22vw;
  height: 22vw;
  color: var(--grape);
}

.hero-type {
  position: relative;
  z-index: 3;
  margin-top: clamp(20px, 4vh, 52px);
}
.hero-type h1 span {
  display: block;
}
.hero-type h1 span:nth-child(2) {
  margin-left: clamp(0px, 2.2vw, 38px);
}
.eyebrow {
  display: flex;
  align-items: center;
  gap: 14px;
  flex-wrap: wrap;
  margin-bottom: clamp(16px, 2vh, 26px);
}
.eyebrow .bar {
  width: clamp(30px, 8vw, 120px);
  height: 3px;
  background: currentColor;
}

.hero-notes {
  position: relative;
  z-index: 4;
  margin-top: auto;
  align-items: end;
  padding-top: clamp(14px, 3vh, 36px);
}
.hero-notes > * {
  min-width: 0;
}
.hn-1 { grid-column: 1 / span 3; transform: rotate(calc(var(--chaos) * -5deg)); }
.hn-2 { grid-column: 4 / span 3; transform: rotate(calc(var(--chaos) * 3deg)); padding-bottom: 4px; }
.hn-3 { grid-column: 7 / span 3; text-align: right; transform: rotate(calc(var(--chaos) * 3.5deg)); }
.hn-3 img {
  width: 92px;
  margin-left: auto;
  margin-top: 6px;
}
.hn-4 {
  grid-column: 10 / span 3;
  transform: rotate(calc(var(--chaos) * 4.5deg));
  margin-top: clamp(-150px, -11vh, -30px);
}
.hn-4 .shot {
  box-shadow: 12px 12px 0 var(--candy);
  aspect-ratio: 3 / 4;
}

.hero-foot {
  position: relative;
  z-index: 2;
  margin: clamp(12px, 2vh, 24px) calc(-1 * var(--pad)) 0;
}
.hero-foot .row {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 20px;
  padding: 0 var(--pad) 14px;
}
.hero-foot .row span:last-child {
  text-align: right;
}
.rainbow--flush {
  margin-inline: 0;
}

/* ------------------------------------------------------------- marquee --- */

.marquee {
  background: var(--ink);
  padding: 18px 0;
  overflow: hidden;
  white-space: nowrap;
}
.marquee-track {
  display: inline-flex;
  gap: 42px;
  align-items: center;
  font-family: var(--font-display);
  font-size: clamp(20px, 2.6vw, 40px);
  text-transform: uppercase;
  letter-spacing: -0.02em;
  color: var(--candy);
  animation: marquee 32s linear infinite;
  will-change: transform;
}
.marquee-track .o {
  color: transparent;
  -webkit-text-stroke: 2px var(--paper);
}
.marquee-track .d {
  color: var(--paper);
}
@keyframes marquee {
  from { transform: translate3d(0, 0, 0); }
  to { transform: translate3d(-50%, 0, 0); }
}
@media (prefers-reduced-motion: reduce) {
  .marquee-track { animation: none; }
}

/* ------------------------------------------------------------ approach --- */

.approach .lead {
  grid-column: 1 / span 7;
}
.approach .plate {
  grid-column: 9 / span 4;
  align-self: end;
  transform: rotate(calc(var(--chaos) * 2.5deg));
}
.approach h2 {
  grid-column: 1 / -1;
}
.approach .rule4 {
  grid-column: 1 / -1;
  height: 4px;
  background: var(--ink);
  margin-top: clamp(10px, 2vw, 26px);
}
.approach .col {
  grid-column: span 3;
  font-family: var(--font-label);
}
.approach .col .label {
  display: flex;
  justify-content: space-between;
  margin-bottom: 12px;
}
.approach .col p:last-child {
  font-size: 13px;
  line-height: 1.65;
}

/* -------------------------------------------------------------- styles --- */

.style-row {
  display: grid;
  grid-template-columns: clamp(70px, 9vw, 150px) 1fr clamp(90px, 13vw, 190px);
  gap: clamp(16px, 3vw, 42px);
  align-items: center;
  border-top: 4px solid var(--ink);
  padding: clamp(20px, 2.6vw, 34px) clamp(8px, 1vw, 16px);
  margin-inline: clamp(-8px, -1vw, -16px);
}
.style-list .style-row:last-child {
  border-bottom: 4px solid var(--ink);
}
.style-row:hover {
  background: var(--candy);
}
.style-row .num {
  display: block;
  font-family: var(--font-display);
  font-size: clamp(38px, 6vw, 96px);
  line-height: 0.8;
  color: transparent;
  -webkit-text-stroke: 2px var(--ink);
}
/* one sketch mark per technique, sitting under its number like a margin note */
.style-row .icon {
  width: clamp(34px, 4.2vw, 60px);
  margin-top: 16px;
  opacity: 0.8;
}
.style-row:hover .icon {
  opacity: 1;
}
.style-row p {
  margin-top: 8px;
  max-width: 62ch;
}
.style-row .thumb {
  border: 3px solid var(--ink);
  aspect-ratio: 1 / 1;
  overflow: hidden;
  background: var(--ink);
}
.style-row .thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

/* ----------------------------------------------------------- portfolio --- */

.works {
  align-items: start;
  gap: clamp(18px, 2.4vw, 40px);
}
.works figure .shot {
  border-width: 4px;
}
.works figure:nth-child(6n + 1) { transform: rotate(calc(var(--chaos) * -1.4deg)); }
.works figure:nth-child(6n + 2) { transform: rotate(calc(var(--chaos) * 2deg)); }
.works figure:nth-child(6n + 3) { transform: rotate(calc(var(--chaos) * -2deg)); }
.works figure:nth-child(6n + 4) { transform: rotate(calc(var(--chaos) * 1deg)); }
.works figure:nth-child(6n + 5) { transform: rotate(calc(var(--chaos) * -1deg)); }
.works figure:nth-child(6n) { transform: rotate(calc(var(--chaos) * 2.4deg)); }

.w7 { grid-column: span 7; }
.w5 { grid-column: span 5; }
.w4 { grid-column: span 4; }
.w3 { grid-column: span 3; }
.ar-43 { aspect-ratio: 4 / 3; }
.ar-34 { aspect-ratio: 3 / 4; }
.ar-23 { aspect-ratio: 2 / 3; }
.ar-11 { aspect-ratio: 1 / 1; }

.works-cta {
  grid-column: span 3;
  align-self: center;
  padding: 8px;
}
.works-cta a {
  display: block;
  background: var(--candy);
  color: var(--ink);
  border: 4px solid var(--paper);
  box-shadow: 11px 11px 0 var(--paper);
  padding: 26px 20px;
  font-family: var(--font-display);
  text-transform: uppercase;
  font-size: clamp(15px, 1.5vw, 24px);
  line-height: 1.1;
  text-align: center;
  transform: rotate(calc(var(--chaos) * -3deg));
}
.works-cta a:hover {
  background: var(--paper);
}

/* ------------------------------------------------------------- process --- */

.steps {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: clamp(20px, 3vw, 44px);
}
.step {
  position: relative;
  padding-top: 12px;
  display: flex;
}
.step .scrap {
  position: relative;
  /* the torn edges of the scrap PNG eat ~10% of the box, so pad generously */
  padding: clamp(30px, 3vw, 42px) clamp(26px, 2.6vw, 34px) clamp(44px, 4vw, 56px);
  background: center / 100% 100% no-repeat;
  min-height: 250px;
  width: 100%;
}
.step .scrap > * {
  position: relative;
}
.step:nth-child(1) .scrap { background-image: url("../assets/marks/scrap-01.webp"); transform: rotate(calc(var(--chaos) * -3deg)); }
.step:nth-child(2) .scrap { background-image: url("../assets/marks/scrap-02.webp"); transform: rotate(calc(var(--chaos) * 2.4deg)); }
.step:nth-child(3) .scrap { background-image: url("../assets/marks/scrap-03.webp"); transform: rotate(calc(var(--chaos) * -1.8deg)); }
.step:nth-child(4) .scrap { background-image: url("../assets/marks/scrap-04.webp"); transform: rotate(calc(var(--chaos) * 3.2deg)); }
.step .n {
  font-family: var(--font-display);
  font-size: 30px;
  line-height: 1;
  color: var(--candy);
  -webkit-text-stroke: 1.5px var(--ink);
}
.step h3 {
  font-size: clamp(18px, 1.7vw, 26px);
  margin: 10px 0 8px;
}
.step p {
  font-family: var(--font-label);
  font-size: 11.5px;
  line-height: 1.6;
}
/* Marginalia only earns its place when it comments on something (design.md §1),
   so the process cards carry no free-floating doodles. */

/* ---------------------------------------------------------------- crew --- */

.crew {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: clamp(20px, 3vw, 48px);
}
.crew article:nth-child(1) { transform: rotate(calc(var(--chaos) * -1.5deg)); }
.crew article:nth-child(2) { transform: rotate(calc(var(--chaos) * 1.8deg)); }
.crew article:nth-child(3) { transform: rotate(calc(var(--chaos) * -2.2deg)); }
.crew .shot {
  aspect-ratio: 4 / 5;
  box-shadow: none;
}
.crew h3 {
  margin: 18px 0 6px;
  font-size: clamp(24px, 2.4vw, 38px);
  line-height: 0.9;
}
.crew .role {
  color: var(--candy-deep);
  letter-spacing: 0.18em;
  margin-bottom: 12px;
}
.crew p.bio {
  font-size: 14px;
  line-height: 1.55;
  margin-bottom: 16px;
}
.crew .ig {
  font-family: var(--font-label);
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  border-bottom: 3px solid var(--candy);
  color: var(--ink);
}
.crew .ig:hover {
  color: var(--candy-deep);
}

/* -------------------------------------------------------------- studio --- */

.studio {
  align-items: start;
  gap: clamp(22px, 3vw, 50px);
}
.studio h2 {
  grid-column: 1 / -1;
  font-size: clamp(34px, 6.6vw, 108px);
}
.studio figure {
  grid-column: 1 / span 7;
  transform: rotate(calc(var(--chaos) * -1.5deg));
}
.studio figure .shot {
  aspect-ratio: 16 / 10;
}
.studio .aside {
  grid-column: 9 / span 4;
}
.hours {
  transform: rotate(calc(var(--chaos) * 2deg));
  background: var(--paper);
  box-shadow: 12px 12px 0 var(--candy);
  padding: clamp(20px, 2vw, 30px);
}
.hours h3 {
  font-size: clamp(17px, 1.5vw, 24px);
  line-height: 1;
}
.hours .rule3 {
  height: 3px;
  background: var(--ink);
  margin: 15px 0;
}
.hours p {
  font-family: var(--font-label);
  font-size: 12px;
  line-height: 1.85;
}
.hours .aside-note {
  margin-top: 15px;
  font-family: var(--font-marker);
  font-weight: 700;
  font-size: clamp(19px, 1.7vw, 27px);
  line-height: 1.05;
  color: var(--candy-deep);
}

/* ----------------------------------------------------------------- faq --- */

.faq-item {
  border-top: 4px solid var(--ink);
}
.faq-list {
  border-bottom: 4px solid var(--ink);
}
.faq-q {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 22px;
  background: none;
  border: 0;
  padding: clamp(18px, 2.2vw, 30px) 2px;
  cursor: pointer;
  text-align: left;
  font-family: var(--font-display);
  text-transform: uppercase;
  font-size: clamp(17px, 2.3vw, 34px);
  line-height: 1.05;
  letter-spacing: -0.025em;
  color: var(--ink);
}
.faq-q:hover {
  color: var(--candy-deep);
}
.faq-q .sign {
  font-family: var(--font-label);
  font-size: clamp(20px, 2vw, 30px);
  color: var(--candy);
  flex: 0 0 auto;
}
.faq-a {
  display: none;
}
.faq-item.is-open .faq-a {
  display: block;
}
.faq-a p {
  padding: 0 clamp(40px, 6vw, 110px) clamp(22px, 2.4vw, 32px) 2px;
  font-size: clamp(15px, 1.15vw, 19px);
  line-height: 1.6;
}

/* ------------------------------------------------------------- contact --- */

.contact {
  align-items: center;
  gap: clamp(22px, 3vw, 48px);
}
.contact .copy {
  grid-column: 1 / span 7;
}
.contact h2 {
  font-size: clamp(46px, 9vw, 150px);
  line-height: 0.8;
  margin-bottom: clamp(20px, 2.4vw, 32px);
}
.contact .copy p.lead {
  max-width: 56ch;
  margin-bottom: clamp(26px, 3vw, 40px);
}
.contact .actions {
  display: flex;
  gap: clamp(12px, 1.6vw, 22px);
  flex-wrap: wrap;
  align-items: center;
}
.contact .actions .marker {
  max-width: 230px;
  transform: rotate(calc(var(--chaos) * -4deg));
}
.contact .card {
  grid-column: 9 / span 4;
  transform: rotate(calc(var(--chaos) * 3deg));
}
.contact .card dl {
  margin: 0;
  font-family: var(--font-label);
  font-size: 12px;
  line-height: 1.7;
}
.contact .card dt {
  font-weight: 700;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--candy-deep);
  margin-top: 14px;
}
.contact .card dt:first-child {
  margin-top: 0;
}
.contact .card dd {
  margin: 2px 0 0;
}
.contact .card img.mascot {
  width: 120px;
  margin: 0 auto 14px;
}

/* -------------------------------------------------------------- footer --- */

.site-foot {
  background: var(--paper);
  padding: clamp(34px, 4vw, 60px) var(--pad) 0;
}
.site-foot .inner {
  max-width: var(--max);
  margin-inline: auto;
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 30px;
  flex-wrap: wrap;
  padding-bottom: clamp(28px, 3vw, 44px);
}
.site-foot .brand img {
  width: 70px;
  height: 70px;
  transform: rotate(calc(var(--chaos) * 4deg));
}
.site-foot .brand span {
  font-family: var(--font-display);
  font-size: clamp(17px, 1.7vw, 26px);
  line-height: 0.95;
  letter-spacing: -0.03em;
  text-transform: uppercase;
}
.site-foot nav {
  display: flex;
  gap: clamp(14px, 2.2vw, 34px);
  flex-wrap: wrap;
  font-family: var(--font-label);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.18em;
  text-transform: uppercase;
}
.site-foot nav a {
  color: var(--ink);
  padding-bottom: 3px;
  border-bottom: 3px solid transparent;
}
.site-foot nav a:hover {
  color: var(--candy-deep);
  border-bottom-color: var(--candy);
}
.site-foot address {
  font-style: normal;
  font-family: var(--font-label);
  font-size: 11px;
  line-height: 1.9;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  max-width: 280px;
}
.legal {
  background: var(--ink);
  color: var(--paper);
  padding: 15px var(--pad);
  margin-inline: calc(-1 * var(--pad));
  display: flex;
  justify-content: space-between;
  gap: 18px;
  flex-wrap: wrap;
  font-family: var(--font-label);
  font-size: 10px;
  letter-spacing: 0.16em;
  text-transform: uppercase;
}

/* ---------------------------------------------------------- page intro --- */

.page-hero {
  padding: clamp(34px, 5vw, 74px) var(--pad) clamp(40px, 5vw, 80px);
  position: relative;
  overflow: hidden;
}
.page-hero .wrap {
  display: grid;
  grid-template-columns: repeat(12, 1fr);
  gap: var(--gap);
  align-items: end;
}
.page-hero h1 {
  grid-column: 1 / span 8;
  font-size: clamp(40px, 8vw, 132px);
}
.page-hero .lead {
  grid-column: 1 / span 7;
  margin-top: clamp(18px, 2vw, 28px);
}
.page-hero .side {
  grid-column: 9 / span 4;
  align-self: end;
}
.crumbs {
  grid-column: 1 / -1;
  display: flex;
  gap: 10px;
  align-items: center;
  margin-bottom: clamp(16px, 2vw, 26px);
}
.crumbs a {
  color: inherit;
}
.crumbs a:hover {
  color: var(--candy-deep);
}

/* --------------------------------------------------------------- misc --- */

.pair {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: clamp(22px, 3vw, 46px);
}
.stack > * + * {
  margin-top: clamp(14px, 1.6vw, 22px);
}
/* long dry-brush swipe used as a divider between two galleries */
.brush-divider {
  width: min(100%, 620px);
  margin: clamp(46px, 6vw, 86px) auto clamp(30px, 4vw, 56px);
  opacity: 0.85;
}
.tag-row {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 18px;
}
.tag {
  font-family: var(--font-label);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  border: 3px solid currentColor;
  padding: 7px 12px;
}

/* --------------------------------------------------------- responsive --- */

@media (max-width: 1000px) {
  .hn-1 { grid-column: 1 / span 6; }
  .hn-2 { grid-column: 7 / span 6; }
  .hn-3 { grid-column: 1 / span 6; text-align: left; }
  .hn-3 img { margin-left: 0; }
  .hn-4 { grid-column: 8 / span 5; margin-top: 0; }
  .approach .lead,
  .approach .plate { grid-column: 1 / -1; }
  .approach .col { grid-column: span 6; }
  .studio figure,
  .studio .aside,
  .contact .copy,
  .contact .card { grid-column: 1 / -1; }
  /* full-bleed the card would read as an empty slab; keep it card-sized */
  .contact .card { max-width: 460px; }
  .page-hero h1,
  .page-hero .lead,
  .page-hero .side { grid-column: 1 / -1; }
  .w7, .w5, .w4, .w3, .works-cta { grid-column: span 6; }
}

@media (max-width: 760px) {
  /* Tame every rotation at once: at phone widths a 4.5deg card pushes its own
     shadow past the viewport edge. --chaos is the one knob for all of them. */
  :root { --chaos: 0.5; }

  .nav-toggle { display: block; }
  .nav {
    display: none;
    position: absolute;
    top: calc(100% + 10px);
    right: var(--pad);
    left: var(--pad);
    flex-direction: column;
    align-items: stretch;
    gap: 0;
    background: var(--paper-pure);
    border: 4px solid var(--ink);
    box-shadow: 10px 10px 0 var(--candy);
    padding: 8px;
    z-index: 20;
  }
  .nav.is-open { display: flex; }
  .nav a:not(.btn) {
    padding: 14px 12px;
    border-bottom: 3px solid var(--ink);
    color: var(--ink);
  }
  .nav .btn { margin: 10px 12px 6px; text-align: center; }
  /* no `position: relative` here: sticky already positions the bar, and
     overriding it would drop the header out of the viewport on scroll. */

  .brand img { width: 64px; height: 64px; }
  .hero { min-height: auto; padding-bottom: 8px; }
  .hero-type { margin-top: 34px; }
  .hn-1, .hn-2, .hn-3 { grid-column: 1 / -1; }
  .hn-3 img { width: 74px; }
  .hn-4 { grid-column: 1 / -1; margin-top: 8px; }
  .hero-notes { gap: 20px; margin-top: 40px; }
  .hero-foot .row { flex-direction: column; align-items: flex-start; gap: 8px; }
  .hero-foot .row span:last-child { text-align: left; }

  .style-row {
    grid-template-columns: 64px 1fr;
    gap: 14px 18px;
  }
  .style-row .thumb { grid-column: 1 / -1; aspect-ratio: 16 / 9; }
  .approach .col { grid-column: 1 / -1; }
  .w7, .w5, .w4, .w3, .works-cta { grid-column: 1 / -1; }
  .sticker, .hours { box-shadow: 8px 8px 0 var(--candy); }
  .sh-candy, .sh-grape, .sh-sour, .sh-ink { box-shadow: 8px 8px 0 currentColor; }
  .sh-candy { box-shadow: 8px 8px 0 var(--candy); }
  .sh-grape { box-shadow: 8px 8px 0 var(--grape); }
  .sh-sour { box-shadow: 8px 8px 0 var(--sour); }
  .sh-ink { box-shadow: 8px 8px 0 var(--ink); }
  .hero-dots, .hero-ring { display: none; }
  .contact .card img.mascot { width: 96px; }
}
