/* ════════ Carole Guthrie — global day-side styles ════════ */

/* ── Reset + base ── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }
body {
  background: #F3EDE2;
  color: #181512;
  font-family: 'Space Grotesk', sans-serif;
  -webkit-font-smoothing: antialiased;
}
img { display: block; max-width: 100%; height: auto; }
a { color: inherit; text-decoration: none; }
button { font-family: inherit; cursor: pointer; }

/* ── CSS custom properties (mirror theme.json for non-block CSS) ── */
:root {
  --cream:       #F3EDE2;
  --ink:         #181512;
  --blue:        #2447A8;
  --red:         #D03B22;
  --yellow:      #E8A91D;
  --wall:        #1B130C;
  --bone:        #EDE8DF;
  --room-dim:    #8E8780;
  --black-type: 'Archivo Black', sans-serif;
  --sans:        'Space Grotesk', sans-serif;
  --mid:         'Archivo', sans-serif;
  --placard:     'Marcellus', serif;
}

/* Push content below fixed header */
body > *:not(.cg-header) { padding-top: 0; }
.hero { padding-top: 120px !important; }

/* ════════ Header ════════ */
.cg-header {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 50;
  display: flex;
  align-items: stretch;
  border-bottom: 2px solid var(--ink);
  background: var(--cream);
  height: 58px;
}
.cg-brand {
  font-family: var(--black-type);
  font-size: 17px;
  text-transform: uppercase;
  letter-spacing: .02em;
  padding: 0 24px;
  border-right: 2px solid var(--ink);
  display: flex;
  align-items: center;
  white-space: nowrap;
}
.cg-nav {
  display: flex;
  flex: 1;
}
.cg-nav a,
.cg-navlink {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: var(--mid);
  font-weight: 600;
  font-size: 12px;
  letter-spacing: .18em;
  text-transform: uppercase;
  border: 0;
  border-right: 2px solid var(--ink);
  background: transparent;
  color: var(--ink);
  transition: background .2s, color .2s;
}
.cg-nav a:nth-of-type(1):hover { background: var(--blue);   color: var(--cream); }
.cg-nav a:nth-of-type(2):hover { background: var(--yellow); color: var(--ink); }
.cg-nav a:nth-of-type(3):hover { background: var(--red);    color: var(--cream); }
.cg-nav a:nth-of-type(4):hover { background: var(--ink);    color: var(--cream); }
.cg-navlink {
  flex: 1.2;
  background: var(--ink);
  color: var(--cream);
  border-right: 0;
  gap: 8px;
}
.cg-navlink:hover { background: var(--red); }
.cg-navlink i {
  font-style: normal;
  width: 7px; height: 7px;
  border-radius: 50%;
  background: var(--yellow);
  display: inline-block;
  flex-shrink: 0;
}
@media (max-width: 800px) {
  .cg-nav a { display: none; }
  .cg-brand { flex: 1; border-right: 0; }
}

/* ════════ Hero ════════ */
.hero {
  min-height: 100svh;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  position: relative;
  overflow: hidden;
}
.hero-blocks {
  position: absolute;
  inset: 0;
  pointer-events: none;
}
.hero-blocks span {
  position: absolute;
  pointer-events: auto;
  transform: translate(var(--px, 0px), var(--py, 0px)) scale(var(--s, 1)) rotate(var(--r, 0deg));
}
.hb1 { width: 26vw; height: 38vh; background: var(--yellow); right: 8vw;  top: 14vh; }
.hb2 { width: 14vw; height: 14vw; background: var(--blue);   right: 26vw; top: 38vh; border-radius: 50%; mix-blend-mode: multiply; }
.hb3 { width: 9vw;  height: 52vh; background: var(--red);    right: 13vw; top: 26vh; mix-blend-mode: multiply; }

/* Hover states — registered properties so --s/--r transition smoothly;
   parallax (--py) is driven per-frame by JS and stays out of the transition */
@property --s { syntax: '<number>'; inherits: false; initial-value: 1; }
@property --r { syntax: '<angle>'; inherits: false; initial-value: 0deg; }
@media (prefers-reduced-motion: no-preference) {
  .hero-blocks span { transition: --s .4s ease, --r .4s ease, filter .4s ease; }
  .hb1:hover { --s: 1.07; filter: brightness(1.08); }
  .hb2:hover { --s: 1.12; filter: saturate(1.4) brightness(1.06); }
  .hb3:hover { --s: 1.10; filter: brightness(1.12); }
}

.hero h1 {
  font-family: var(--black-type);
  text-transform: uppercase;
  font-size: clamp(64px, 12.5vw, 210px);
  line-height: .88;
  letter-spacing: -.01em;
  padding: 0 32px;
  position: relative;
}
.hero h1 span       { display: block; }
.hero h1 .outline   { color: transparent; -webkit-text-stroke: 2.5px var(--ink); }

.hero-sub {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 24px;
  padding: 28px 32px;
  flex-wrap: wrap;
  position: relative;
}
.hero-sub p { font-weight: 500; font-size: 15px; max-width: 46ch; }
.hero-ctas  { display: flex; gap: 12px; flex-wrap: wrap; }

/* Buttons */
.btn {
  font-family: var(--mid);
  font-weight: 600;
  font-size: 12px;
  letter-spacing: .18em;
  text-transform: uppercase;
  padding: 16px 28px;
  border: 2px solid var(--ink);
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  transition: background .2s, color .2s, transform .15s, box-shadow .15s;
}
.btn-dark {
  background: var(--ink);
  color: var(--cream);
  box-shadow: 6px 6px 0 var(--red);
}
.btn-dark:hover  { transform: translate(2px,2px); box-shadow: 2px 2px 0 var(--red); }
.btn-ghost { background: transparent; color: var(--ink); }
.btn-ghost:hover { background: var(--yellow); }

/* ════════ Marquee ════════ */
.marquee {
  border-top: 2px solid var(--ink);
  border-bottom: 2px solid var(--ink);
  background: var(--blue);
  color: var(--cream);
  overflow: hidden;
  white-space: nowrap;
}
.marquee-track {
  display: inline-block;
  padding: 14px 0;
  font-family: var(--mid);
  font-weight: 600;
  font-size: 13px;
  letter-spacing: .22em;
  text-transform: uppercase;
}
@media (prefers-reduced-motion: no-preference) {
  .marquee-track { animation: cg-scroll 36s linear infinite; }
}
@keyframes cg-scroll { to { transform: translateX(-50%); } }
.marquee b { color: var(--yellow); font-weight: 600; margin: 0 18px; }

/* ════════ Work section ════════ */
.cg-section { padding: 110px 32px; }
.cg-work { padding: 110px 32px; }

.sect-head {
  display: flex;
  align-items: baseline;
  gap: 24px;
  margin-bottom: 64px;
  flex-wrap: wrap;
}
.sect-head h2 {
  font-family: var(--black-type);
  text-transform: uppercase;
  font-size: clamp(40px, 6vw, 84px);
  line-height: 1;
}
.tag {
  font-family: var(--mid);
  font-weight: 600;
  font-size: 11px;
  letter-spacing: .22em;
  text-transform: uppercase;
  padding: 8px 14px;
  border: 2px solid var(--ink);
}
.hint-room {
  margin-left: auto;
  font-size: 13px;
  font-weight: 500;
  color: #6B645A;
}

/* ── Collage grid ── */
.collage {
  display: grid;
  grid-template-columns: repeat(6, 1fr);
  gap: 28px;
  align-items: start;
}
.collage figure { cursor: zoom-in; position: relative; }

/* 6-item rhythm */
.collage figure:nth-child(6n+1) { grid-column: span 3; }
.collage figure:nth-child(6n+2) { grid-column: span 2; margin-top: 72px; }
.collage figure:nth-child(6n+3) { grid-column: span 1; margin-top: 28px; }
.collage figure:nth-child(6n+4) { grid-column: span 2; }
.collage figure:nth-child(6n+5) { grid-column: span 2; margin-top: 56px; }
.collage figure:nth-child(6n+6) { grid-column: span 2; margin-top: -24px; }

/* Tablet */
@media (max-width: 900px) {
  .collage { grid-template-columns: repeat(2, 1fr); }
  .collage figure { grid-column: span 1 !important; margin-top: 0 !important; }
  .collage figure:nth-child(4n+1) { grid-column: span 2 !important; }
}

/* Card mat + hover */
.collage .mat {
  border: 2px solid var(--ink);
  background: #fff;
  overflow: hidden;
  box-shadow: 8px 8px 0 transparent;
  transition: box-shadow .25s, transform .25s;
}
.collage figure:hover .mat { box-shadow: 8px 8px 0 var(--ink); transform: translate(-4px,-4px); }
.collage figure:nth-child(4n+1):hover .mat { box-shadow: 8px 8px 0 var(--red); }
.collage figure:nth-child(4n+2):hover .mat { box-shadow: 8px 8px 0 var(--blue); }
.collage figure:nth-child(4n+3):hover .mat { box-shadow: 8px 8px 0 var(--yellow); }

.collage img { width: 100%; height: auto; display: block; }

.collage figcaption {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  margin-top: 10px;
  font-family: var(--mid);
  font-weight: 600;
  font-size: 11px;
  letter-spacing: .14em;
  text-transform: uppercase;
}
.collage figcaption span:last-child { color: var(--red); }

/* ════════ About ════════ */
.about {
  background: var(--ink);
  color: var(--cream);
  padding: 110px 32px;
}
.about-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 64px;
  align-items: start;
}
@media (max-width: 900px) { .about-grid { grid-template-columns: 1fr; } }
.about h2 {
  font-family: var(--black-type);
  text-transform: uppercase;
  font-size: clamp(40px, 6vw, 84px);
  line-height: .95;
}
.about h2 em { font-style: normal; color: var(--yellow); }
.about p { font-size: 17px; line-height: 1.7; margin-bottom: 1.1em; color: #D8D2C6; }
.badges {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 28px;
}
.badges span {
  font-family: var(--mid);
  font-weight: 600;
  font-size: 11px;
  letter-spacing: .18em;
  text-transform: uppercase;
  padding: 9px 14px;
  border: 1px solid #4A453E;
  color: var(--cream);
}
.badges span.hot { background: var(--red); border-color: var(--red); }

/* ════════ Words ════════ */
.words {
  background: var(--yellow);
  border-top: 2px solid var(--ink);
  border-bottom: 2px solid var(--ink);
  padding: 110px 32px;
}
.words-inner {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 56px;
  align-items: center;
}
@media (max-width: 800px) { .words-inner { grid-template-columns: 1fr; } }
.words h2 {
  font-family: var(--black-type);
  text-transform: uppercase;
  font-size: clamp(40px, 5vw, 72px);
  writing-mode: vertical-rl;
  rotate: 180deg;
  line-height: 1;
}
@media (max-width: 800px) {
  .words h2 { writing-mode: horizontal-tb; rotate: none; }
}
.words blockquote {
  font-size: clamp(20px, 2.4vw, 30px);
  font-weight: 500;
  line-height: 1.5;
  max-width: 30ch;
}
.words cite {
  display: block;
  font-style: normal;
  font-family: var(--mid);
  font-weight: 600;
  font-size: 11px;
  letter-spacing: .22em;
  text-transform: uppercase;
  margin-top: 20px;
}

/* ════════ Contact ════════ */
.contact-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 64px;
}
@media (max-width: 900px) { .contact-grid { grid-template-columns: 1fr; } }
.contact h2 {
  font-family: var(--black-type);
  text-transform: uppercase;
  font-size: clamp(40px, 6vw, 84px);
  line-height: .95;
}
.contact h2 em {
  font-style: normal;
  color: transparent;
  -webkit-text-stroke: 2px var(--ink);
}
.contact p { margin-top: 20px; font-size: 16px; max-width: 42ch; }
form { display: grid; }
.field {
  border: 2px solid var(--ink);
  border-bottom: 0;
  padding: 14px 18px;
  display: grid;
  gap: 4px;
  background: #fff;
}
.field:last-of-type { border-bottom: 2px solid var(--ink); }
.field label {
  font-family: var(--mid);
  font-weight: 600;
  font-size: 10px;
  letter-spacing: .22em;
  text-transform: uppercase;
  color: #8A8276;
}
.field input,
.field textarea {
  border: 0;
  outline: none;
  background: transparent;
  font-family: var(--sans);
  font-size: 17px;
  color: var(--ink);
  resize: vertical;
}
.send {
  justify-self: start;
  margin-top: 24px;
  font-family: var(--mid);
  font-weight: 600;
  font-size: 12px;
  letter-spacing: .22em;
  text-transform: uppercase;
  background: var(--red);
  color: var(--cream);
  border: 2px solid var(--ink);
  padding: 18px 36px;
  cursor: pointer;
  box-shadow: 6px 6px 0 var(--ink);
  transition: transform .15s, box-shadow .15s;
}
.send:hover { transform: translate(2px,2px); box-shadow: 2px 2px 0 var(--ink); }

/* ════════ Footer ════════ */
.cg-footer {
  border-top: 2px solid var(--ink);
  display: flex;
  justify-content: space-between;
  gap: 16px;
  padding: 22px 32px;
  font-family: var(--mid);
  font-weight: 600;
  font-size: 11px;
  letter-spacing: .18em;
  text-transform: uppercase;
  flex-wrap: wrap;
}
.cg-footer-links { display: flex; gap: 24px; }

/* ════════ Scroll reveal (day side) ════════ */
@media (prefers-reduced-motion: no-preference) {
  .reveal {
    opacity: 0;
    transform: translateY(28px);
    transition: opacity .8s ease, transform .8s cubic-bezier(.2,.7,.2,1);
  }
  .reveal.in {
    opacity: 1;
    transform: none;
  }
}

/* ════════ Mobile padding ════════ */
@media (max-width: 620px) {
  .cg-section,
  .cg-work,
  .about,
  .words,
  .cg-footer     { padding-left: 18px; padding-right: 18px; }
  .hero h1       { padding: 0 18px; }
  .hero-sub      { padding: 24px 18px; }
}

/* WordPress admin bar offset */
.admin-bar .cg-header { top: 32px; }
@media (max-width: 782px) { .admin-bar .cg-header { top: 46px; } }
