/*
Theme Name: TOTM Media
Theme URI: https://totmmedia.com
Author: TOTM Media
Author URI: https://totmmedia.com
Description: TOTM Media homepage — a cinematic full-screen video hero followed by a scrolling dark one-page site (Featured Work, Originals/TFMV, Publishing, Services, About, Contact). Fraunces + Hanken Grotesk on a black / steel-blue / gold palette. Upload via Appearance > Themes > Add New > Upload Theme.
Version: 4.8
Requires at least: 5.5
Tested up to: 6.6
Requires PHP: 7.2
License: GNU General Public License v2 or later
License URI: http://www.gnu.org/licenses/gpl-2.0.html
Text Domain: totm-media
*/

:root {
  --bg: #000000;          /* page black */
  --bg-alt: #0e0e11;      /* elevated band */
  --bg-ink: #0a1017;      /* blue-tinted near-black accent band */
  --panel: #141418;       /* cards */
  --ivory: #F5EEDD;       /* headings / high-emphasis */
  --sand: #EDE2CC;        /* light neutral (button text/borders) */
  --text: rgba(245, 238, 221, 0.74);
  --text-dim: rgba(245, 238, 221, 0.5);
  --ink: #14140f;         /* dark text for light hover fills */
  --blue: #3E7B9C;        /* lifted steel blue for black bg */
  --blue-deep: #12283c;
  --gold: #C79A3A;
  --foil: #E0C173;
  --hair: rgba(245, 238, 221, 0.12);
  --display: "Fraunces", Georgia, "Times New Roman", serif;
  --body: "Hanken Grotesk", -apple-system, system-ui, "Segoe UI", sans-serif;
  --mx: clamp(1.5rem, 6vw, 7rem);
  --maxw: 1180px;
  --scrim: 8, 12, 18;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

html, body {
  margin: 0;
  padding: 0;
  width: 100%;
  background: var(--bg);
}

body {
  font-family: var(--body);
  color: var(--text);
  font-size: 17px;
  line-height: 1.7;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  overflow-x: hidden;
}

a { color: inherit; text-decoration: none; }
img { max-width: 100%; display: block; }

/* ---------- Shared type helpers ---------- */
.eyebrow {
  font-family: var(--body);
  font-size: 0.72rem;
  letter-spacing: 0.3em;
  text-transform: uppercase;
  font-weight: 600;
  color: var(--foil);
  margin: 0 0 1rem;
}
.eyebrow.gold { color: var(--foil); }
.rule-gold {
  width: 52px;
  height: 2px;
  background: var(--gold);
}
.sec-title {
  font-family: var(--display);
  font-weight: 500;
  font-size: clamp(2rem, 4vw, 3.1rem);
  line-height: 1.08;
  letter-spacing: -0.01em;
  margin: 0;
  color: var(--ivory);
}
.sec-lead {
  font-size: clamp(1rem, 1.3vw, 1.15rem);
  color: var(--text);
  max-width: 52ch;
  margin: 1.2rem 0 0;
}

/* ---------- Buttons ---------- */
.btn {
  font-family: var(--body);
  font-size: 0.8rem;
  font-weight: 600;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  padding: 1rem 1.9rem;
  cursor: pointer;
  display: inline-block;
  border: none;
  transition: transform 0.3s ease, background 0.3s ease, color 0.3s ease, border-color 0.3s ease;
}
.btn--ghost {
  background: transparent;
  color: var(--sand);
  border: 1px solid rgba(237, 226, 204, 0.55);
  padding: calc(1rem - 1px) calc(1.9rem - 1px);
}
.btn--ghost:hover, .btn--ghost:focus-visible {
  transform: translateY(-2px);
  background: var(--sand);
  color: var(--ink);
  border-color: var(--sand);
}
.btn--solid {
  background: var(--blue);
  color: #04121b;
}
.btn--solid:hover, .btn--solid:focus-visible {
  transform: translateY(-2px);
  background: #5A97B8;
}
.btn--line {
  background: transparent;
  color: var(--ivory);
  border: 1px solid rgba(245, 238, 221, 0.4);
  padding: calc(1rem - 1px) calc(1.9rem - 1px);
}
.btn--line:hover, .btn--line:focus-visible {
  transform: translateY(-2px);
  background: var(--ivory);
  color: var(--ink);
  border-color: var(--ivory);
}
a:focus-visible, .btn:focus-visible {
  outline: 2px solid var(--foil);
  outline-offset: 4px;
}

/* ---------- Navigation (fixed, frosts on scroll) ---------- */
.nav {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 60;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1.4rem var(--mx);
  transition: background 0.35s ease, padding 0.35s ease, border-color 0.35s ease;
  border-bottom: 1px solid transparent;
  opacity: 0;
  animation: fadeIn 1s ease-out 0.15s forwards;
}
.nav.scrolled {
  background: rgba(0, 0, 0, 0.82);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  border-bottom-color: var(--hair);
  padding: 0.9rem var(--mx);
}
.nav__brand {
  font-family: var(--display);
  color: var(--ivory);
  font-weight: 500;
  font-size: 1.4rem;
  letter-spacing: 0.005em;
  white-space: nowrap;
}
.nav__brand .dot { color: var(--foil); }

.nav__links { display: flex; align-items: center; gap: 2.4rem; }
.nav__links a {
  color: rgba(237, 226, 204, 0.82);
  font-family: var(--body);
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  position: relative;
  transition: color 0.3s ease;
}
.nav__links a::after {
  content: "";
  position: absolute;
  left: 0; bottom: -6px;
  width: 100%; height: 1.5px;
  background: var(--foil);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 0.35s ease;
}
.nav__links a:hover, .nav__links a:focus-visible { color: var(--ivory); }
.nav__links a:hover::after, .nav__links a:focus-visible::after { transform: scaleX(1); }

.nav__toggle {
  display: none;
  background: none; border: none;
  color: var(--ivory);
  font-family: var(--body);
  font-size: 0.72rem;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  font-weight: 600;
  padding: 6px 0;
  cursor: pointer;
  z-index: 80;
}

/* ---------- Hero ---------- */
.hero {
  position: relative;
  width: 100%;
  min-height: 100vh;
  overflow: hidden;
  background: #000;
}
@supports (height: 100dvh) { .hero { min-height: 100dvh; } }

.hero__video {
  position: absolute;
  inset: 0;
  width: 100%; height: 100%;
  object-fit: cover;
  object-position: center center;
  z-index: 1;
  pointer-events: none;
}
.hero__scrim {
  position: absolute;
  inset: 0;
  z-index: 2;
  pointer-events: none;
  background: linear-gradient(100deg,
    rgba(var(--scrim), 0) 42%,
    rgba(var(--scrim), 0.32) 66%,
    rgba(var(--scrim), 0.66) 100%);
}
.hero__content {
  position: absolute;
  z-index: 3;
  top: 50%;
  right: var(--mx);
  transform: translateY(-50%);
  width: min(47%, 580px);
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  text-align: left;
}
.hero .rule-gold {
  margin: 0 0 1.9rem;
  opacity: 0;
  animation: fadeIn 1s ease-out 0.55s forwards;
}
.headline {
  font-family: var(--display);
  color: var(--ivory);
  font-weight: 500;
  font-size: clamp(2.7rem, 5.2vw, 4.6rem);
  line-height: 1.04;
  letter-spacing: -0.012em;
  margin: 0;
  opacity: 0;
  transform: translateY(20px);
  animation: riseIn 1.1s cubic-bezier(0.22, 1, 0.36, 1) 0.7s forwards;
}
.subline {
  color: rgba(245, 238, 221, 0.9);
  font-size: clamp(1rem, 1.3vw, 1.15rem);
  font-weight: 400;
  line-height: 1.6;
  margin: 1.6rem 0 0;
  align-self: stretch;
  text-align: center;
  opacity: 0;
  transform: translateY(18px);
  animation: riseIn 1.1s cubic-bezier(0.22, 1, 0.36, 1) 0.95s forwards;
}
.hero .actions {
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
  margin-top: 2.6rem;
  opacity: 0;
  animation: fadeIn 1s ease-out 1.35s forwards;
}
/* Centered CTA — floats above the TOTM monument base */
.hero__cta {
  position: absolute;
  z-index: 3;
  left: 50%;
  bottom: 31%;
  transform: translateX(-50%);
  opacity: 0;
  animation: fadeIn 1s ease-out 1.35s forwards;
}
.hero__cta:hover, .hero__cta:focus-visible {
  transform: translateX(-50%) translateY(-2px);
}

/* ---------- Generic section ---------- */
.section {
  padding: clamp(4.5rem, 9vw, 8rem) var(--mx);
}
.section.alt { background: var(--bg-alt); }
.section.ink { background: var(--bg-ink); color: var(--ivory); }
.container { max-width: var(--maxw); margin: 0 auto; }
.section-head { max-width: 60ch; }
.section-head .rule-gold { margin-bottom: 1.4rem; }

/* ---------- Intro strip ---------- */
.intro .intro-lead {
  font-family: var(--display);
  font-weight: 400;
  font-size: clamp(1.5rem, 2.6vw, 2.25rem);
  line-height: 1.3;
  letter-spacing: -0.01em;
  color: var(--ivory);
  max-width: 24ch;
}
.intro-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: clamp(2rem, 6vw, 5rem);
  align-items: start;
}
.intro-copy { color: var(--text); }
.intro-copy p { margin: 0 0 1rem; }
.stat-row {
  display: flex;
  flex-wrap: wrap;
  gap: 2.4rem;
  margin-top: 2rem;
  padding-top: 2rem;
  border-top: 1px solid var(--hair);
}
.stat b {
  display: block;
  font-family: var(--display);
  font-weight: 500;
  font-size: 1.6rem;
  color: var(--foil);
  line-height: 1;
}
.stat span {
  font-size: 0.72rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--text-dim);
}

/* ---------- Work grid ---------- */
.work-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.6rem;
  margin-top: 3rem;
}
.card {
  display: flex;
  flex-direction: column;
  background: var(--panel);
  border: 1px solid var(--hair);
  overflow: hidden;
  transition: transform 0.35s ease, border-color 0.35s ease;
}
.card:hover { transform: translateY(-4px); border-color: rgba(224, 193, 115, 0.5); }
.ph {
  position: relative;
  aspect-ratio: 3 / 2;
  background: linear-gradient(135deg, #1c1c22, #0b0b0e);
  display: flex;
  align-items: center;
  justify-content: center;
}
.ph span {
  font-family: var(--display);
  color: rgba(245, 238, 221, 0.4);
  font-size: 1.4rem;
  letter-spacing: 0.02em;
}
.ph img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center center;
}
.ph--top img { object-position: center 22%; }   /* keep a portrait subject's face in frame */
.ph--contain { background: #000; }
.ph--contain img { object-fit: contain; padding: 1.2rem; }
.ph--natural { aspect-ratio: auto; background: transparent; }
.ph--natural img { position: static; inset: auto; width: 100%; height: auto; display: block; }
/* Click-to-play YouTube facade */
.ph--video { aspect-ratio: auto; position: relative; background: #000; overflow: hidden; }
.video-play { display: block; width: 100%; padding: 0; margin: 0; border: none; background: none; cursor: pointer; position: relative; line-height: 0; }
.video-play img { position: static; inset: auto; width: 100%; height: auto; display: block; transition: transform 0.5s ease, filter 0.4s ease; }
.video-play__btn { position: absolute; inset: 0; display: flex; align-items: center; justify-content: center; transition: transform 0.3s ease; }
.video-play__btn svg { filter: drop-shadow(0 6px 18px rgba(0,0,0,0.5)); }
.video-play:hover img, .video-play:focus-visible img { transform: scale(1.02); filter: brightness(1.05); }
.video-play:hover .video-play__btn, .video-play:focus-visible .video-play__btn { transform: scale(1.08); }
.video-play:focus-visible { outline: 2px solid var(--foil); outline-offset: 4px; }
.ph--video.is-playing { aspect-ratio: 16 / 9; }
.ph--video.is-playing iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; }
.card-body { padding: 1.4rem 1.5rem 1.7rem; }
.tag {
  font-size: 0.64rem;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  font-weight: 600;
  color: var(--foil);
}
.card h3 {
  font-family: var(--display);
  font-weight: 500;
  font-size: 1.3rem;
  margin: 0.5rem 0 0.4rem;
  color: var(--ivory);
}
.card p { margin: 0; font-size: 0.92rem; color: var(--text); }

/* ---------- Feature (Originals) ---------- */
.feature {
  display: grid;
  grid-template-columns: 1.05fr 1fr;
  gap: clamp(2rem, 5vw, 4.5rem);
  align-items: center;
}
.feature.ink .eyebrow { color: var(--foil); }
.feature.ink .sec-title { color: var(--ivory); }
.feature.ink .sec-lead { color: rgba(245, 238, 221, 0.82); }
.feature .ph { aspect-ratio: 4 / 3; border: 1px solid var(--hair); }
.feature .ph--video { aspect-ratio: auto; }
.feature .ph--video.is-playing { aspect-ratio: 16 / 9; }
.feature .ph--natural { aspect-ratio: auto; }
.feature .actions { display: flex; flex-wrap: wrap; gap: 1rem; margin-top: 2rem; }
.dev-note {
  margin-top: 1.6rem;
  font-size: 0.8rem;
  letter-spacing: 0.02em;
  color: rgba(245, 238, 221, 0.55);
}
.dev-note b { color: var(--foil); font-weight: 600; }
.ep-meta {
  margin: 1.3rem 0 0;
  font-size: 0.72rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  font-weight: 600;
  color: var(--foil);
}

/* ---------- Publishing split ---------- */
.split {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1.6rem;
  margin-top: 3rem;
}
.pub-card {
  background: var(--panel);
  border: 1px solid var(--hair);
  padding: 2.2rem 2rem;
}
.pub-card .tag { color: var(--foil); }
.pub-card h3 {
  font-family: var(--display);
  font-weight: 500;
  font-size: 1.5rem;
  margin: 0.6rem 0 0.6rem;
  color: var(--ivory);
}
.pub-card p { color: var(--text); margin: 0 0 1.4rem; font-size: 0.95rem; }

/* ---------- Services ---------- */
.svc-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: clamp(1.6rem, 4vw, 3rem);
  margin-top: 3rem;
}
.svc .num {
  font-family: var(--display);
  font-size: 1rem;
  color: var(--foil);
  letter-spacing: 0.1em;
}
.svc h3 {
  font-family: var(--display);
  font-weight: 500;
  font-size: 1.45rem;
  margin: 0.8rem 0 0.6rem;
  padding-top: 0.9rem;
  border-top: 1px solid var(--hair);
  color: var(--ivory);
}
.svc p { color: var(--text); margin: 0; font-size: 0.95rem; }

/* ---------- About ---------- */
.about-grid {
  display: grid;
  grid-template-columns: 0.8fr 1.2fr;
  gap: clamp(2rem, 6vw, 4.5rem);
  align-items: center;
}
.about-grid .ph { aspect-ratio: 4 / 5; }
.about-grid .ph--logo { aspect-ratio: 1 / 1; background: #000; }
.about-copy p { color: var(--text); margin: 0 0 1.1rem; }
.about-copy .lead {
  font-family: var(--display);
  font-size: clamp(1.4rem, 2.4vw, 1.9rem);
  line-height: 1.32;
  color: var(--ivory);
}

/* ---------- Contact / CTA ---------- */
.cta { text-align: center; }
.cta .container { max-width: 780px; }
.cta .sec-title { font-size: clamp(2.2rem, 4.4vw, 3.4rem); color: var(--ivory); }
.cta .eyebrow { color: var(--foil); }
.cta .sec-lead { color: rgba(245, 238, 221, 0.82); margin-left: auto; margin-right: auto; }
.cta .rule-gold { margin: 0 auto 1.4rem; }
.cta .actions { display: flex; justify-content: center; flex-wrap: wrap; gap: 1rem; margin-top: 2.4rem; }

/* ---------- Footer ---------- */
.footer {
  background: #000;
  color: var(--text);
  padding: clamp(3rem, 6vw, 4.5rem) var(--mx) 2.5rem;
  border-top: 1px solid var(--hair);
}
.footer .container {
  display: flex;
  justify-content: space-between;
  gap: 2.5rem;
  flex-wrap: wrap;
  padding-bottom: 2.5rem;
  border-bottom: 1px solid var(--hair);
}
.foot-brand { max-width: 34ch; }
.foot-brand .wm {
  font-family: var(--display);
  color: var(--ivory);
  font-size: 1.5rem;
}
.foot-brand .wm .dot { color: var(--foil); }
.foot-brand p { font-size: 0.88rem; margin: 0.6rem 0 0; line-height: 1.6; }
.foot-cols { display: flex; gap: clamp(2rem, 6vw, 4.5rem); flex-wrap: wrap; }
.foot-col h5 {
  font-size: 0.66rem;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--foil);
  margin: 0 0 1rem;
}
.foot-col a {
  display: block;
  font-size: 0.9rem;
  margin-bottom: 0.6rem;
  color: var(--text);
  transition: color 0.2s ease;
}
.foot-col a:hover { color: var(--ivory); }
.colophon {
  max-width: var(--maxw);
  margin: 1.8rem auto 0;
  font-size: 0.72rem;
  letter-spacing: 0.04em;
  color: var(--text-dim);
}

/* ---------- Reveal on scroll ---------- */
.reveal { opacity: 0; transform: translateY(22px); transition: opacity 0.8s ease, transform 0.8s ease; }
.reveal.in { opacity: 1; transform: none; }

/* ---------- WP admin bar offset ---------- */
body.admin-bar .nav { top: 32px; }
@media screen and (max-width: 782px) { body.admin-bar .nav { top: 46px; } }

/* ---------- Animations ---------- */
@keyframes fadeIn { to { opacity: 1; } }
@keyframes riseIn { to { opacity: 1; transform: translateY(0); } }

/* ---------- Responsive ---------- */
@media (max-width: 1024px) {
  .nav__links { gap: 1.7rem; }
  .hero__content { width: min(58%, 540px); }
  .work-grid { grid-template-columns: repeat(2, 1fr); }
  .svc-grid { grid-template-columns: 1fr; }
  .intro-grid, .feature, .about-grid, .split { grid-template-columns: 1fr; }
  .feature .ph, .about-grid .ph { order: -1; }
}

@media (max-width: 680px) {
  .nav { padding: 1.1rem var(--mx); }
  .nav__brand { font-size: 1.25rem; }
  .nav__links {
    position: fixed;
    inset: 0;
    background: var(--bg);
    flex-direction: column;
    justify-content: center;
    align-items: center;
    gap: 2rem;
    transform: translateX(100%);
    transition: transform 0.4s ease;
    z-index: 70;
  }
  .nav__links.open { transform: none; }
  .nav__links a { color: var(--ivory); font-size: 1rem; }
  .nav__toggle { display: block; }

  .hero__scrim {
    background: linear-gradient(to top,
      rgba(var(--scrim), 0.78) 0%,
      rgba(var(--scrim), 0.36) 34%,
      rgba(var(--scrim), 0) 62%);
  }
  .hero__content {
    top: auto; bottom: 3rem;
    right: var(--mx); left: var(--mx);
    transform: none; width: auto;
  }
  .headline { font-size: clamp(2.2rem, 9vw, 3rem); }
  .work-grid { grid-template-columns: 1fr; }
  .footer .container { flex-direction: column; gap: 2rem; }
}

@media (max-width: 680px) and (min-height: 620px) {
  .hero__content { bottom: 8vh; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .nav, .hero .rule-gold, .headline, .subline, .hero .actions, .hero__cta, .reveal {
    animation: none !important;
    opacity: 1 !important;
    transform: none !important;
    transition: none !important;
  }
  .hero__cta { transform: translateX(-50%) !important; }
}

/* ---------- Interior pages (page / single / archive / 404) ---------- */
.page-wrap {
  padding-top: clamp(7rem, 12vw, 10rem);
  min-height: 70vh;
}
.page-head { max-width: 60ch; margin-bottom: 2.5rem; }
.page-head .rule-gold { margin-bottom: 1.4rem; }
.page-head .actions { margin-top: 2rem; }

.entry { max-width: 70ch; color: var(--text); }
.entry > * { margin: 0 0 1.2rem; }
.entry h2, .entry h3, .entry h4 {
  font-family: var(--display);
  font-weight: 500;
  color: var(--ivory);
  line-height: 1.2;
  margin: 2.2rem 0 0.8rem;
}
.entry h2 { font-size: 1.9rem; }
.entry h3 { font-size: 1.5rem; }
.entry h4 { font-size: 1.25rem; }
.entry a { color: var(--foil); text-decoration: underline; text-underline-offset: 3px; }
.entry a:hover { color: var(--ivory); }
.entry img { height: auto; margin: 1.6rem 0; }
.entry ul, .entry ol { padding-left: 1.3rem; }
.entry li { margin-bottom: 0.5rem; }
.entry blockquote {
  border-left: 2px solid var(--gold);
  padding-left: 1.4rem;
  margin: 1.8rem 0;
  font-family: var(--display);
  font-size: 1.25rem;
  color: var(--ivory);
}
.entry code, .entry pre {
  background: var(--panel);
  border: 1px solid var(--hair);
  font-size: 0.9rem;
}
.entry code { padding: 0.15em 0.4em; }
.entry pre { padding: 1rem; overflow-x: auto; }
.entry table { width: 100%; border-collapse: collapse; }
.entry th, .entry td { border: 1px solid var(--hair); padding: 0.6rem 0.8rem; text-align: left; }

/* Blog listing */
.post-list { display: grid; gap: 2.2rem; max-width: 70ch; }
.post-item { padding-bottom: 2rem; border-bottom: 1px solid var(--hair); }
.post-item h2 {
  font-family: var(--display);
  font-weight: 500;
  font-size: 1.7rem;
  margin: 0.5rem 0 0.6rem;
  color: var(--ivory);
}
.post-item h2 a:hover { color: var(--foil); }
.post-item p { color: var(--text); margin: 0; }
.entry-pages { margin-top: 2.5rem; }
.entry-pages a { color: var(--foil); margin-right: 0.8rem; }

/* ---------- Contact page ---------- */
.contact-grid {
  display: grid;
  grid-template-columns: 0.85fr 1.15fr;
  gap: clamp(2rem, 5vw, 4rem);
  align-items: start;
  margin-top: 1rem;
}
.contact-photo { aspect-ratio: 4 / 5; }
.contact-form { display: flex; flex-direction: column; gap: 1.2rem; }
.contact-form .field { display: flex; flex-direction: column; gap: 0.5rem; }
.contact-form label {
  font-size: 0.72rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--foil);
  font-weight: 600;
}
.contact-form input,
.contact-form textarea {
  background: var(--panel);
  border: 1px solid var(--hair);
  color: var(--ivory);
  font-family: var(--body);
  font-size: 1rem;
  padding: 0.85rem 1rem;
  width: 100%;
  border-radius: 0;
  transition: border-color 0.25s ease;
}
.contact-form input:focus,
.contact-form textarea:focus {
  outline: none;
  border-color: var(--foil);
}
.contact-form textarea { resize: vertical; min-height: 140px; }
.contact-form .btn { align-self: flex-start; margin-top: 0.4rem; cursor: pointer; }

/* ---------- Publishing page ---------- */
.pub-intro { max-width: 70ch; margin-top: 1.5rem; }
.pub-intro p { color: var(--text); font-size: 1.08rem; }
.tier-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1.4rem;
  margin-top: 2.5rem;
}
.tier {
  position: relative;
  background: var(--panel);
  border: 1px solid var(--hair);
  padding: 2rem 1.6rem;
  display: flex;
  flex-direction: column;
}
.tier h3 {
  font-family: var(--display);
  font-weight: 500;
  font-size: 1.4rem;
  color: var(--ivory);
  margin: 0 0 0.7rem;
}
.tier p { color: var(--text); font-size: 0.95rem; margin: 0; }
.tier--feature { border-color: var(--gold); }
.tier-flag {
  position: absolute;
  top: -0.7rem; left: 1.6rem;
  background: var(--gold);
  color: #04121b;
  font-size: 0.62rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  font-weight: 700;
  padding: 0.3rem 0.7rem;
}
.tier-note {
  max-width: 70ch;
  margin: 2rem 0 0;
  color: var(--text-dim);
  font-size: 0.92rem;
}
.consult-cta { margin-top: 2.4rem; }

@media (max-width: 1024px) {
  .tier-grid { grid-template-columns: repeat(2, 1fr); }
  .contact-grid { grid-template-columns: 1fr; }
  .contact-photo { aspect-ratio: 16 / 9; order: -1; }
}
@media (max-width: 680px) {
  .tier-grid { grid-template-columns: 1fr; }
}

/* ---------- Publishing page blocks ---------- */
.pub-block { margin-top: clamp(3.5rem, 7vw, 6rem); }
.pub-showcase { margin-top: 2.5rem; }
.pub-showcase .card { background: var(--panel); }

/* ---------- Work page — website gallery ---------- */
.web-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 1.6rem;
  margin-top: 2.5rem;
}
.web-grid > .web-card:last-child:nth-child(odd) {
  grid-column: 1 / -1;
  width: calc(50% - 0.8rem);
  justify-self: center;
  max-width: none;
}
.web-card {
  display: block;
  background: var(--panel);
  border: 1px solid var(--hair);
  overflow: hidden;
  transition: transform 0.35s ease, border-color 0.35s ease;
}
.web-card:hover { transform: translateY(-4px); border-color: rgba(224, 193, 115, 0.5); }
.ph--wide { aspect-ratio: 16 / 9; }
.ph--wide img { object-position: top center; }
.web-body {
  padding: 1.2rem 1.5rem 1.4rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
}
.web-body h3 {
  font-family: var(--display);
  font-weight: 500;
  font-size: 1.3rem;
  color: var(--ivory);
  margin: 0.35rem 0 0;
  line-height: 1.2;
}
.web-body .tag { color: var(--foil); }
.web-body .visit {
  font-family: var(--body);
  font-size: 0.75rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  font-weight: 600;
  color: var(--foil);
  white-space: nowrap;
  flex-shrink: 0;
}
@media (max-width: 680px) {
  .web-grid { grid-template-columns: 1fr; }
  .web-grid > .web-card:last-child:nth-child(odd) { max-width: none; }
}

/* Contact logo treatment — show the full square logo on black in the photo slot */
.contact-photo.ph--logo { background: #000; }
.contact-photo.ph--logo img { object-fit: contain; padding: 1.6rem; }
