/* Juan F. Bastos — site styles
   Museum palette, classical serif body, clean sans headers.
   Breakpoints: phone < 768, tablet 768–1024, desktop > 1024. */

:root {
  --paper: #f6f3ed;
  --paper-2: #eee9df;
  --ink: #242220;
  --ink-2: #333333;
  --muted: #5e5a54;
  --line: #ddd6ca;
  --charcoal: #1c1b19;
  --charcoal-2: #2a2825;
  --accent: #8b6c43;
  --on-dark: #f3efe7;
  --on-dark-muted: #b9b2a6;

  --sans: "Roboto", "Helvetica Neue", Arial, sans-serif;
  --serif: "EB Garamond", "Garamond", "Times New Roman", serif;

  --header-h: 68px;
  --gutter: 16px;
  --max: 1280px;
  --radius: 2px;
  --ease: cubic-bezier(.2, .7, .2, 1);
}
@media (min-width: 768px) { :root { --gutter: 32px; --header-h: 76px; } }
@media (min-width: 1025px) { :root { --gutter: 48px; } }

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }

body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--serif);
  /* rem, not px, so a reader's larger browser font setting still applies */
  font-size: 1.1875rem;
  line-height: 1.65;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}
@media (min-width: 768px) { body { font-size: 1.375rem; } }
body.no-scroll { overflow: hidden; }

img { max-width: 100%; height: auto; display: block; }
a { color: inherit; text-decoration-color: color-mix(in srgb, currentColor 35%, transparent); text-underline-offset: 3px; }
a:hover { color: var(--accent); }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; }

h1, h2, h3, h4 { font-family: var(--sans); font-weight: 300; line-height: 1.2; margin: 0 0 .6em; letter-spacing: .01em; }
h1 { font-size: clamp(2rem, 4.5vw, 3.25rem); }
h2 { font-size: clamp(1.5rem, 3vw, 2.1rem); }
h3 { font-size: 1.15rem; font-weight: 400; }
p { margin: 0 0 1.1em; }

.eyebrow {
  font-family: var(--sans);
  font-size: .72rem;
  font-weight: 500;
  letter-spacing: .22em;
  text-transform: uppercase;
  color: var(--muted);
  margin: 0 0 1rem;
}

.skip { position: absolute; left: -9999px; top: 0; }
.skip:focus { left: 16px; top: 16px; z-index: 200; background: var(--ink); color: var(--paper); padding: 10px 14px; }

.wrap { width: 100%; max-width: var(--max); margin: 0 auto; padding: 0 var(--gutter); }
.narrow { max-width: 760px; }

/* ---------- Header ---------- */
.site-header {
  position: fixed; inset: 0 0 auto 0; z-index: 50;
  height: var(--header-h);
  display: flex; align-items: center;
  background: color-mix(in srgb, var(--paper) 92%, transparent);
  backdrop-filter: saturate(1.2) blur(10px);
  -webkit-backdrop-filter: saturate(1.2) blur(10px);
  border-bottom: 1px solid transparent;
  transition: background .35s var(--ease), color .35s var(--ease), border-color .35s var(--ease);
}
.site-header.scrolled { border-bottom-color: var(--line); }
.site-header .wrap { display: flex; align-items: center; justify-content: space-between; max-width: none; }
.brand {
  font-family: var(--sans); font-weight: 500; font-size: 1.3rem; letter-spacing: .05em;
  text-transform: uppercase; text-decoration: none; white-space: nowrap;
}
@media (min-width: 768px) { .brand { font-size: 1.75rem; } }
.brand:hover { color: inherit; opacity: .75; }
.brand-block { display: flex; flex-direction: column; align-items: flex-start; gap: 2px; min-width: 0; }
.brand-tagline {
  margin: 0; font-family: var(--sans); font-weight: 300; font-size: .9rem; line-height: 1;
  letter-spacing: .09em; opacity: .8; white-space: nowrap;
}
@media (min-width: 768px) { .brand-tagline { font-size: 1.5rem; } }

/* header over the dark home hero */
/* light home page: the header looks the same over the hero as on inner pages */

.menu-toggle {
  width: 48px; height: 48px; margin-right: -12px;
  display: grid; place-items: center;
  background: none; border: 0; color: inherit; cursor: pointer;
}
.menu-toggle span, .menu-toggle span::before, .menu-toggle span::after {
  display: block; width: 26px; height: 1.5px; background: currentColor; position: relative;
  transition: transform .3s var(--ease), background .2s;
}
.menu-toggle span::before, .menu-toggle span::after { content: ""; position: absolute; left: 0; }
.menu-toggle span::before { top: -8px; }
.menu-toggle span::after { top: 8px; }

/* ---------- Menu: right drawer on desktop, translucent full-width overlay on phone/tablet ---------- */
.menu {
  position: fixed; inset: 0; z-index: 100;
  visibility: hidden; pointer-events: none;
}
.menu.open { visibility: visible; pointer-events: auto; }
.menu-backdrop {
  position: absolute; inset: 0; background: rgba(20, 19, 17, .45);
  opacity: 0; transition: opacity .35s var(--ease);
}
.menu.open .menu-backdrop { opacity: 1; }
.menu-panel {
  position: absolute; top: 0; right: 0; bottom: 0;
  width: min(440px, 100%);
  background: var(--paper);
  color: var(--ink);
  display: flex; flex-direction: column;
  transform: translateX(100%);
  transition: transform .45s var(--ease);
  overflow-y: auto; overscroll-behavior: contain;
}
.menu.open .menu-panel { transform: none; }
.menu-top { display: flex; align-items: center; justify-content: space-between; height: var(--header-h); padding: 0 var(--gutter); flex: none; }
.menu-close { width: 48px; height: 48px; margin-right: -12px; background: none; border: 0; color: inherit; cursor: pointer; display: grid; place-items: center; }
.menu-close svg { width: 22px; height: 22px; }
.menu nav { padding: 8px var(--gutter) 24px; }
.menu-group { margin-bottom: 18px; }
.menu-group .eyebrow { margin-bottom: 6px; }
.menu nav a {
  display: flex; align-items: center; min-height: 44px;
  font-family: var(--sans); font-weight: 300; font-size: 1.2rem; letter-spacing: .02em;
  text-decoration: none; border-bottom: 1px solid transparent;
}
.menu nav a[aria-current="page"] { color: var(--accent); }
.menu nav a:hover { color: var(--accent); }
.menu-foot { margin-top: auto; padding: 20px var(--gutter) 32px; border-top: 1px solid var(--line); font-family: var(--sans); font-size: .9rem; color: var(--ink-2); line-height: 1.7; }
.menu-foot a { text-decoration: none; }
.menu-foot .socials { margin-top: 12px; }

@media (max-width: 1024px) {
  .menu-panel {
    width: 100%;
    background: color-mix(in srgb, var(--charcoal) 86%, transparent);
    color: var(--on-dark);
    backdrop-filter: blur(16px); -webkit-backdrop-filter: blur(16px);
    transform: none; opacity: 0;
    transition: opacity .35s var(--ease);
  }
  .menu.open .menu-panel { opacity: 1; }
  .menu-backdrop { display: none; }
  .menu .eyebrow { color: var(--on-dark-muted); }
  .menu-foot { border-top-color: rgba(255,255,255,.15); color: var(--on-dark-muted); }
  .menu nav { columns: 1; }
  .menu nav a { font-size: 1.35rem; min-height: 48px; }
}
@media (min-width: 768px) and (max-width: 1024px) {
  .menu nav { display: grid; grid-template-columns: 1fr 1fr; gap: 0 48px; padding-top: 24px; }
}

/* ---------- Main ---------- */
main { display: block; }
.page { padding-top: calc(var(--header-h) + 40px); padding-bottom: 80px; }
@media (min-width: 768px) { .page { padding-top: calc(var(--header-h) + 64px); } }
.page-head { margin-bottom: 32px; }
.page-head p { color: var(--ink-2); max-width: 640px; }

/* ---------- Hero slider ---------- */
.hero {
  position: relative; height: 100vh; height: 100svh; min-height: 520px;
  background: var(--paper); color: var(--ink); overflow: hidden;
  touch-action: pan-y;
}
.hero-slide {
  position: absolute; inset: 0; opacity: 0; visibility: hidden;
  transition: opacity 1.1s var(--ease), visibility 1.1s;
  display: grid; place-items: center;
  /* fixed row height, so large image files can't stretch .hero-art */
  grid-template-rows: minmax(0, 1fr);
}
.hero-slide.active { opacity: 1; visibility: visible; }
.hero-bg { display: none;
  position: absolute; inset: -40px; background-size: cover; background-position: center;
  filter: blur(36px) brightness(.38) saturate(1.1); transform: scale(1.1);
}
.hero-art {
  position: relative; z-index: 1;
  height: calc(100% - var(--header-h) - 150px); max-width: calc(100% - 2 * var(--gutter));
  margin-top: calc(var(--header-h) - 30px);
  display: flex; align-items: center; justify-content: center;
}
.hero-art img {
  /* cap at 500px so high-res files show at the same size as the rest */
  max-height: min(100%, 500px); width: auto; max-width: 100%; object-fit: contain;
  box-shadow: 0 14px 40px rgba(0,0,0,.16);
}
.hero-caption {
  position: absolute; z-index: 2; left: var(--gutter); bottom: 30px; right: var(--gutter);
  font-family: var(--sans); font-size: .85rem; line-height: 1.4rem; color: var(--ink-2);
}
/* every caption line shares one line-height, no extra gap between lines */
.hero-title { margin: 0; color: var(--ink); }
.hero-title strong { font-weight: 400; font-size: 1rem; line-height: inherit; letter-spacing: .02em; }
.hero-medium { white-space: nowrap; margin-left: .6em; color: var(--muted); }
.hero-caption a { color: inherit; }
.hero-caption a:hover { color: var(--accent); }
/* controls sit above the painting, leaving the bottom for the description */
.hero-controls { position: absolute; z-index: 3; right: var(--gutter); top: var(--header-h); display: flex; align-items: center; gap: 4px; margin-right: -12px; }
.hero-controls button {
  width: 44px; height: 44px; border: 0; background: none; color: var(--ink); cursor: pointer;
  display: grid; place-items: center; opacity: .8;
}
.hero-controls button:hover { opacity: 1; }
.hero-controls svg { width: 20px; height: 20px; }
.hero-count { font-family: var(--sans); font-size: .78rem; letter-spacing: .12em; color: var(--muted); min-width: 44px; text-align: center; }
@media (max-width: 767px) {
  /* phones: stack painting, caption and controls so they never overlap */
  .hero-slide {
    display: flex; flex-direction: column; align-items: stretch;
    justify-content: flex-start;
    padding: calc(var(--header-h) + 44px) var(--gutter) 16px;
  }
  .hero-art { flex: 0 1 auto; min-height: 0; height: auto; max-width: 100%; margin: 0; }
  .hero-caption { position: relative; left: auto; right: auto; bottom: auto; padding-top: 12px; flex: none; }
  .hero-controls { left: var(--gutter); right: auto; top: calc(var(--header-h) - 6px); margin: 0 0 0 -12px; }
}
@media (min-width: 768px) {
  /* tablet and desktop: caption flows under the painting with one line of space,
     however many lines it has (the painting shrinks to make room) */
  .hero-slide {
    display: flex; flex-direction: column; align-items: center; justify-content: flex-start;
    padding: calc(var(--header-h) + 64px) var(--gutter) 30px;
  }
  .hero-art { flex: 1 1 0; min-height: 0; height: auto; max-width: 100%; margin: 0; align-items: flex-end; }
  .hero-caption { position: relative; left: auto; right: auto; bottom: auto; flex: none; align-self: stretch; padding-top: 1.4rem; }
}
@media (min-width: 768px) and (max-width: 1024px) { .hero-caption { text-align: center; } }

/* ---------- Home sections ---------- */
.section { padding: 80px 0; }
@media (min-width: 768px) { .section { padding: 112px 0; } }
.section + .section { padding-top: 0; }
.ethos { text-align: center; }
.ethos h2 { font-family: var(--serif); font-weight: 400; font-style: italic; font-size: clamp(1.9rem, 4.6vw, 3.2rem); letter-spacing: 0; margin-bottom: .4em; }
.ethos p { color: var(--ink-2); max-width: 640px; margin: 0 auto 1.4em; }

.quotes { display: grid; gap: 40px; grid-template-columns: 1fr; }
@media (min-width: 768px) { .quotes { grid-template-columns: repeat(3, 1fr); gap: 36px; } }
.quote { margin: 0; padding-top: 24px; border-top: 1px solid var(--line); }
.quote p { font-size: 1.5rem; line-height: 1.45; margin-bottom: .8em; }
.quote footer { font-family: var(--sans); font-size: .95rem; color: var(--muted); line-height: 1.5; }
.quote footer a { color: var(--ink-2); }
.quote footer a:hover { color: var(--accent); }

/* the sections that follow the intro keep the same spacing as before */
.home-intro + .section { padding-top: 0; }
/* desktop: carousel pinned on the left, ethos and quotes scroll on the right */
@media (min-width: 1025px) {
  .home-intro { display: grid; grid-template-columns: minmax(0, 1.4fr) minmax(0, 1fr); align-items: start; }
  .home-intro .hero { position: sticky; top: 0; }
  /* painting on the same left line as the logo and caption */
  .home-intro .hero-slide { align-items: flex-start; }
  .home-intro .hero-art {
    width: 100%; max-width: none; margin-left: 0;
    justify-content: flex-start; container-type: size;
  }
  /* size from each painting's ratio (--ar, inline on the img) so the box,
     shadow and controls always match the painting, portrait or landscape */
  .home-intro .hero-art img { height: min(100cqh, 650px, 100cqw / var(--ar, 1)); max-height: none; max-width: none; }
  /* controls above the painting, first arrow on the same left line (the
     -12px offsets the button padding); site.js sets top per painting */
  .home-intro .hero-controls { left: calc(var(--gutter) - 12px); right: auto; margin: 0; transition: top .6s var(--ease); }
  .home-intro-side .ethos { text-align: left; }
  .home-intro-side .ethos p { margin-left: 0; }
  .home-intro-side { padding: calc(var(--header-h) + 64px) 0 112px; }
  .home-intro-side .section { padding: 0; }
  .home-intro-side .section + .section { padding-top: 72px; }
  .home-intro-side .wrap { max-width: none; margin: 0; padding: 0 var(--gutter) 0 0; }
  .home-intro-side .ethos h2 { font-size: clamp(1.9rem, 2.6vw, 2.8rem); }
  .home-intro-side .quotes { grid-template-columns: 1fr; gap: 32px; }
  .home-intro + .section { padding-top: 112px; }
}

.cat-grid { display: grid; gap: 28px 20px; grid-template-columns: repeat(2, 1fr); }
@media (min-width: 768px) and (orientation: landscape), (min-width: 1025px) { .cat-grid { grid-template-columns: repeat(3, 1fr); } }
.cat { text-decoration: none; display: block; }
.cat-img { aspect-ratio: 4 / 5; overflow: hidden; background: var(--paper-2); }
.cat-img img { width: 100%; height: 100%; object-fit: cover; object-position: center 25%; transition: transform .8s var(--ease); }
.cat:hover .cat-img img { transform: scale(1.04); }
.cat h3 { font-size: 1.25rem; font-weight: 500; margin: 12px 0 2px; }

.feature { display: grid; gap: 32px; align-items: center; }
@media (min-width: 768px) { .feature { grid-template-columns: 1fr 1fr; gap: 64px; } }
.feature-media { background: var(--charcoal); }
.feature-media video, .feature-media img { width: 100%; display: block; }

.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 10px;
  min-height: 48px; padding: 0 24px;
  font-family: var(--sans); font-size: .8rem; font-weight: 500; letter-spacing: .16em; text-transform: uppercase;
  text-decoration: none; color: var(--ink); background: transparent;
  border: 1px solid var(--ink); border-radius: var(--radius); cursor: pointer;
  transition: background .25s, color .25s;
}
.btn:hover { background: var(--ink); color: var(--paper); }
.btn.solid { background: var(--ink); color: var(--paper); }
.btn.solid:hover { background: var(--accent); border-color: var(--accent); }

/* ---------- Gallery section strip: two rows of tabs that stretch to the full width ---------- */
.strip { display: grid; gap: 6px; margin: 0 0 36px; }
.strip-row { display: flex; flex-wrap: wrap; gap: 6px; }
.strip a {
  flex: 1 1 auto;
  min-height: 40px; padding: 0 8px; display: inline-flex; align-items: center; justify-content: center;
  font-family: var(--sans); font-size: .8rem; letter-spacing: .04em; text-decoration: none; text-align: center;
  border: 2px solid #cfc6b8; border-radius: 0; color: var(--ink-2); white-space: nowrap;
}
@media (max-width: 767px) {
  /* even grid on phones: 3 × 2 for the first row, 2 × 2 for the second */
  .strip-row { display: grid; grid-template-columns: repeat(3, 1fr); }
  .strip-row + .strip-row { grid-template-columns: repeat(2, 1fr); }
  .strip a { font-size: .74rem; letter-spacing: .02em; padding: 4px 6px; white-space: normal; line-height: 1.2; }
}
.strip a:hover { border-color: var(--ink-2); color: var(--accent); }
.strip a[aria-current="page"] { background: var(--ink); border-color: var(--ink); color: var(--paper); }

/* ---------- Masonry grid: 1 col phone, 2 col portrait tablet, 3 col landscape tablet / desktop ---------- */
.masonry { columns: 1; column-gap: 24px; }
@media (min-width: 560px) { .masonry { columns: 2; } }
@media (min-width: 768px) and (orientation: landscape), (min-width: 1025px) { .masonry { columns: 3; column-gap: 32px; } }
.work { break-inside: avoid; margin: 0 0 40px; }
.work-btn {
  display: block; width: 100%; padding: 0; border: 0; background: var(--paper-2); cursor: pointer;
  position: relative; overflow: hidden;
}
.work-btn img { width: 100%; transition: transform .8s var(--ease), opacity .6s; }
.work-btn:hover img { transform: scale(1.025); }
.work figcaption { padding-top: 12px; font-family: var(--sans); font-size: .85rem; line-height: 1.5; color: var(--muted); }
.work figcaption strong { display: block; font-weight: 400; color: var(--ink); font-size: .98rem; }
.work figcaption a { color: inherit; }
.work figcaption a:hover { color: var(--accent); }

.gallery-nav { display: flex; justify-content: space-between; gap: 16px; border-top: 1px solid var(--line); padding-top: 24px; margin-top: 24px; font-family: var(--sans); }
.gallery-nav a { text-decoration: none; display: flex; flex-direction: column; min-height: 48px; }
.gallery-nav small { font-size: .7rem; letter-spacing: .2em; text-transform: uppercase; color: var(--muted); }
.gallery-nav span { font-size: 1.1rem; font-weight: 300; }
.gallery-nav .next { text-align: right; margin-left: auto; }

.note { font-family: var(--sans); font-size: .88rem; color: var(--muted); }

.videos { display: grid; gap: 28px; }
@media (min-width: 768px) { .videos { grid-template-columns: 1fr 1fr; } }
.video-card { margin: 0; }
.video-frame { position: relative; aspect-ratio: 16 / 9; background: var(--charcoal); }
.video-frame video, .video-frame iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; }
.video-card figcaption { font-family: var(--sans); font-size: .88rem; color: var(--muted); padding-top: 10px; }
.video-card figcaption strong { color: var(--ink); font-weight: 400; }

/* ---------- Text pages ---------- */
.split { display: grid; gap: 40px; }
.section-title { margin: 72px 0 28px; }
@media (min-width: 900px) { .split { grid-template-columns: minmax(0, 1.25fr) minmax(0, 1fr); gap: 72px; align-items: start; } .split .aside { position: sticky; top: calc(var(--header-h) + 32px); } }
.prose p, .prose li { color: var(--ink-2); }
.prose h2 { margin-top: 1.6em; }
.prose h3 { margin-top: 1.6em; margin-bottom: .4em; }
.prose ul { padding-left: 1.2em; }
.prose li { margin-bottom: .6em; }
.aside figcaption { font-family: var(--sans); font-size: .82rem; color: var(--muted); padding-top: 10px; }
.list-plain { list-style: none; padding: 0; margin: 0; font-family: var(--sans); font-size: .9rem; color: var(--ink-2); }
.list-plain li { padding: 10px 0; border-bottom: 1px solid var(--line); line-height: 1.45; }
.list-plain li span { color: var(--muted); }

/* About: book button with the process / contact links underneath */
.about-actions { margin-top: 32px; display: grid; justify-items: start; gap: 20px; }
.about-links { display: flex; flex-wrap: wrap; gap: 12px 48px; margin: 0; font-family: var(--sans); font-size: .95rem; }

/* Institutional gallery: box under the portraits linking to the full list */
.link-box {
  display: grid; gap: 6px; margin-top: 48px; padding: 28px 32px; text-decoration: none;
  border: 2px solid #cfc6b8; color: var(--ink); transition: border-color .25s;
}
.link-box span { font-family: var(--sans); font-size: 1.15rem; letter-spacing: .04em; }
.link-box small { font-family: var(--sans); font-size: .88rem; color: var(--muted); }
.link-box:hover { border-color: var(--ink-2); color: var(--accent); }

/* Selected Institutional Portraits: name / institution / year / place, stacked on phones */
.inst-list { list-style: none; padding: 0; margin: 0 0 32px; font-family: var(--sans); font-size: .92rem; color: var(--ink-2); border-top: 1px solid var(--line); }
.inst-list li { display: grid; gap: 2px; padding: 14px 0; border-bottom: 1px solid var(--line); line-height: 1.45; }
.inst-list p { margin: 0; }
.il-name { color: var(--ink); }
.il-name span { display: block; padding-left: 1.5em; color: var(--muted); }
.il-year, .il-place { color: var(--muted); }
@media (min-width: 768px) {
  .inst-list li { grid-template-columns: minmax(0, 1.3fr) minmax(0, 1.3fr) 4em minmax(0, .9fr); gap: 24px; }
  .il-year, .il-place { color: var(--ink-2); }
}

.steps { counter-reset: step; list-style: none; padding: 0; margin: 0; }
.steps > li { counter-increment: step; position: relative; padding: 0 0 32px 64px; margin: 0; }
.steps > li::before {
  content: counter(step, decimal-leading-zero); position: absolute; left: 0; top: 2px;
  font-family: var(--sans); font-weight: 300; font-size: 1.6rem; color: var(--accent);
}
.steps h3 { margin: 0 0 .4em; font-size: 1.25rem; font-weight: 300; }

/* ---------- Contact ---------- */
.contact-details { font-family: var(--sans); font-size: 1rem; line-height: 1.7; }
.contact-details dt { font-size: .7rem; letter-spacing: .2em; text-transform: uppercase; color: var(--muted); margin-top: 18px; }
.contact-details dd { margin: 2px 0 0; }
.contact-details a { text-decoration: none; }
.form { display: grid; gap: 18px; margin-top: 8px; }
@media (min-width: 768px) { .form { grid-template-columns: 1fr 1fr; gap: 20px 24px; } .form .full { grid-column: 1 / -1; } }
.field label { display: block; font-family: var(--sans); font-size: .74rem; letter-spacing: .14em; text-transform: uppercase; color: var(--ink-2); margin-bottom: 6px; }
.field input, .field select, .field textarea {
  width: 100%; min-height: 52px; padding: 12px 14px;
  font: 400 1.05rem/1.4 var(--sans); color: var(--ink);
  background: #fff; border: 1px solid var(--line); border-radius: var(--radius);
  -webkit-appearance: none; appearance: none;
}
.field select { background-image: linear-gradient(45deg, transparent 50%, var(--ink-2) 50%), linear-gradient(135deg, var(--ink-2) 50%, transparent 50%); background-position: calc(100% - 20px) 50%, calc(100% - 14px) 50%; background-size: 6px 6px; background-repeat: no-repeat; padding-right: 40px; }
.field textarea { min-height: 150px; resize: vertical; }
.field option.opt-book { font-weight: 700; font-style: italic; }
.field input:focus, .field select:focus, .field textarea:focus { outline: none; border-color: var(--ink-2); box-shadow: 0 0 0 3px color-mix(in srgb, var(--accent) 20%, transparent); }
.form-actions { display: flex; flex-wrap: wrap; gap: 12px; align-items: center; }
.form-actions .note { flex: 1 1 240px; margin: 0; }

/* ---------- Social icons ---------- */
.socials { display: flex; gap: 6px; margin-left: -10px; }
.socials a { width: 44px; height: 44px; display: grid; place-items: center; }
.socials svg { width: 19px; height: 19px; fill: currentColor; }

/* ---------- Footer ---------- */
.site-footer { background: var(--paper); color: var(--muted); border-top: 1px solid var(--line); font-family: var(--sans); font-size: .9rem; padding: 56px 0 40px; }
.site-footer .wrap { display: grid; gap: 28px; }
@media (min-width: 768px) { .site-footer .wrap { grid-template-columns: 1.4fr 1fr 1fr; } }
.site-footer .brand { color: var(--ink); font-size: 1.2rem; display: inline-block; margin-bottom: 10px; }
.site-footer a { text-decoration: none; }
.site-footer a:hover { color: var(--accent); }
.site-footer .tagline { font-family: var(--sans); font-weight: 300; font-size: 1rem; line-height: 1; letter-spacing: .09em; color: var(--ink); opacity: .8; }
.site-footer .legal { grid-column: 1 / -1; border-top: 1px solid var(--line); padding-top: 20px; font-size: .78rem; }

/* ---------- Sticky quick actions (phone + tablet) ---------- */
.quick-actions { display: none; }
@media (max-width: 1024px) {
  .quick-actions {
    position: fixed; z-index: 40; left: 0; right: 0; bottom: 0;
    display: grid; grid-template-columns: repeat(3, 1fr);
    background: #333333;
    backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px);
    padding-bottom: env(safe-area-inset-bottom);
    transform: translateY(0); transition: transform .35s var(--ease);
  }
  .quick-actions.hidden { transform: translateY(110%); }
  .quick-actions a {
    min-height: 56px; display: flex; align-items: center; justify-content: center; gap: 8px;
    color: var(--on-dark); text-decoration: none;
    font-family: var(--sans); font-size: .74rem; font-weight: 500; letter-spacing: .14em; text-transform: uppercase;
  }
  .quick-actions a + a { border-left: 1px solid rgba(255,255,255,.12); }
  .quick-actions svg { width: 17px; height: 17px; fill: none; stroke: currentColor; stroke-width: 1.6; }
  body { padding-bottom: calc(56px + env(safe-area-inset-bottom)); }
}

/* ---------- Lightbox ---------- */
.lightbox {
  position: fixed; inset: 0; z-index: 150; background: rgba(18, 17, 15, .97); color: var(--on-dark);
  display: none; grid-template-rows: auto 1fr auto;
}
.lightbox.open { display: grid; }
.lb-top { display: flex; align-items: center; justify-content: space-between; height: 60px; padding: 0 8px 0 var(--gutter); font-family: var(--sans); font-size: .8rem; letter-spacing: .12em; color: var(--on-dark-muted); }
.lb-top button, .lb-nav { width: 48px; height: 48px; border: 0; background: none; color: var(--on-dark); cursor: pointer; display: grid; place-items: center; }
.lb-top svg, .lb-nav svg { width: 22px; height: 22px; }
.lb-stage { position: relative; overflow: hidden; touch-action: none; user-select: none; -webkit-user-select: none; }
.lb-img {
  position: absolute; left: 50%; top: 50%;
  max-width: calc(100% - 32px); max-height: calc(100% - 16px);
  transform-origin: 0 0; will-change: transform;
  cursor: zoom-in; -webkit-user-drag: none;
}
.lb-img.zoomed { cursor: grab; }
.lb-img.zoomed.dragging { cursor: grabbing; }
.lb-nav { position: absolute; top: 50%; transform: translateY(-50%); z-index: 2; background: rgba(0,0,0,.25); border-radius: 50%; }
.lb-prev { left: 12px; }
.lb-next { right: 12px; }
@media (hover: none) { .lb-nav { display: none; } }
.lb-meta { padding: 14px var(--gutter) calc(20px + env(safe-area-inset-bottom)); font-family: var(--sans); font-size: .88rem; line-height: 1.55; color: var(--on-dark-muted); text-align: center; min-height: 96px; }
.lb-meta strong { display: block; color: var(--on-dark); font-weight: 400; font-size: 1.05rem; letter-spacing: .02em; }
.lb-meta a { color: inherit; }
.lb-meta a:hover { color: #c9a77a; }
.lb-hint { font-size: .72rem; letter-spacing: .1em; text-transform: uppercase; opacity: .55; margin-top: 6px; }

/* ---------- Reveal on scroll ---------- */
.reveal { opacity: 0; transform: translateY(24px); transition: opacity .9s var(--ease), transform .9s var(--ease); }
.reveal.in { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) {
  .reveal { opacity: 1; transform: none; transition: none; }
  .hero-slide, .hero-art img, .hero-controls { transition: none !important; }
}

/* ---------- Press article ---------- */
.article-img { background: #fff; border: 1px solid var(--line); padding: 12px; }
.article-body p { color: var(--ink-2); }

/* keep hero controls clear of the sticky quick-action bar */
@media (max-width: 1024px) {
  .hero { height: calc(100vh - 56px - env(safe-area-inset-bottom)); height: calc(100svh - 56px - env(safe-area-inset-bottom)); }
}
body.no-scroll .quick-actions { visibility: hidden; }
