/* Layout: photo-first. Quiet serif header (Cassandra Ladru), then an edge-to-edge collage of
   colour and black & white frames (Bottega 53), with MENU / ENQUIRE running down the screen edges.
   Clean white ground, ink type; the photographs carry all the colour. */
:root {
  --paper: #ffffff;      /* page ground */
  --paper-deep: #f2f1ee; /* placeholders, photo loading */
  --card: #f7f6f4;       /* form fields */
  --ink: #1d1b19;        /* the logo's ink */
  --ink-soft: #6a655d;
  --line: rgba(29, 27, 25, .14);
  --night: #1d1b19;
  --night-fg: #f4f2ee;

  --display: "Bodoni Moda", "Didot", "Bodoni 72", Georgia, serif;
  --body: "Jost", "Futura", "Avenir Next", "Segoe UI", sans-serif;
  --mono: "IBM Plex Mono", ui-monospace, "SF Mono", Menlo, monospace;

  --step-0: 1.0625rem;
  --step-1: 1.375rem;
  --step-2: clamp(1.75rem, 1.2rem + 2vw, 2.6rem);
  --step-3: clamp(2.4rem, 1.4rem + 4vw, 4.5rem);
  --step-4: clamp(2.8rem, 1rem + 7vw, 7rem);

  --gap: clamp(4px, .5vw, 8px);
  --edge: 56px;          /* width of the vertical edge rails on desktop */
  --wrap: 1180px;
  color-scheme: light;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font: 300 var(--step-0)/1.65 var(--body);
  -webkit-font-smoothing: antialiased;
}
img { max-width: 100%; height: auto; display: block; }
a { color: inherit; text-decoration-thickness: 1px; text-underline-offset: .22em; }
:focus-visible { outline: 2px solid var(--ink); outline-offset: 3px; }
h1, h2, h3 { font-family: var(--display); font-weight: 400; line-height: 1.05; margin: 0; text-wrap: balance; letter-spacing: -.01em; }
p { margin: 0; }
.wrap {
  max-width: var(--wrap); margin: 0 auto;
  padding-left: max(16px, env(safe-area-inset-left, 0px));
  padding-right: max(16px, env(safe-area-inset-right, 0px));
}
.caps { font: 500 .75rem/1.3 var(--body); letter-spacing: .3em; text-transform: uppercase; }
.screen-reader-text { position: absolute !important; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.skip-link:focus { position: fixed; top: 8px; left: 8px; z-index: 300; width: auto; height: auto; clip: auto; background: var(--ink); color: var(--paper); padding: 8px 14px; }

/* ---------- Edge rails (desktop): MENU on the left, ENQUIRE on the right ---------- */
.rail {
  position: fixed; top: 0; bottom: 0; z-index: 60; width: var(--edge);
  display: flex; align-items: center; justify-content: center;
  pointer-events: none;
}
.rail--left { left: 0; padding-left: env(safe-area-inset-left, 0px); }
.rail--right { right: 0; padding-right: env(safe-area-inset-right, 0px); }
.rail a, .rail button {
  pointer-events: auto; writing-mode: vertical-rl; transform: rotate(180deg);
  font: 500 .8rem/1 var(--body); letter-spacing: .38em; text-transform: uppercase; text-decoration: none;
  background: none; border: 0; color: var(--ink); cursor: pointer; padding: 18px 10px;
}
.rail--right a { transform: none; }
.rail a:hover, .rail button:hover { text-decoration: underline; }
@media (max-width: 900px) { .rail { display: none; } }

/* ---------- Notice bar (e.g. "under construction") ---------- */
.notice-bar {
  position: relative; z-index: 70; background: var(--ink); color: var(--night-fg); text-align: center;
  font: 400 .8rem/1.4 var(--body); letter-spacing: .04em;
  padding-block: 10px; padding-left: max(16px, env(safe-area-inset-left, 0px)); padding-right: max(16px, env(safe-area-inset-right, 0px));
}

/* ---------- Header ---------- */
.site-header { padding-block: 28px 20px; text-align: center; }
.site-header .wrap { display: grid; justify-items: center; gap: 22px; }
.brand { display: inline-block; }
.brand img, .brand .custom-logo { width: clamp(150px, 16vw, 210px); height: auto; }
.nav ul { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; justify-content: center; gap: 6px clamp(20px, 4vw, 56px); }
.nav a { font: 500 .74rem/1 var(--body); letter-spacing: .3em; text-transform: uppercase; text-decoration: none; padding: 8px 0; display: inline-block; }
.nav a:hover, .nav .current-menu-item > a, .nav .current-page-ancestor > a { text-decoration: underline; }
.menu-toggle { display: none; }

/* Full-screen menu (opened from the MENU rail, or the button on phones) */
.overlay-menu {
  position: fixed; inset: 0; z-index: 200; background: var(--ink); color: var(--night-fg);
  display: grid; align-content: center;
  padding: max(24px, env(safe-area-inset-top, 0px)) max(16px, env(safe-area-inset-right, 0px)) max(24px, env(safe-area-inset-bottom, 0px)) max(16px, env(safe-area-inset-left, 0px));
}
.overlay-menu[hidden] { display: none; }
.overlay-menu ul { list-style: none; margin: 0; padding: 0; display: grid; gap: 4px; justify-items: center; }
.overlay-menu a { font: italic 400 var(--step-3)/1.15 var(--display); text-decoration: none; }
.overlay-menu a:hover { text-decoration: underline; }
.overlay-menu .close {
  position: absolute; top: max(20px, env(safe-area-inset-top, 0px)); right: max(20px, env(safe-area-inset-right, 0px));
  background: none; border: 0; color: inherit; font: 500 .78rem/1 var(--body); letter-spacing: .3em; text-transform: uppercase; cursor: pointer; padding: 12px;
}
.overlay-menu .sub { margin-top: 40px; text-align: center; opacity: .7; }

@media (max-width: 900px) {
  .site-header { padding-block: 16px 12px; }
  .site-header .wrap { grid-template-columns: 1fr auto; justify-items: start; align-items: center; }
  .brand img, .brand .custom-logo { width: 128px; }
  .nav { display: none; }
  .menu-toggle {
    display: inline-block; background: none; border: 0; color: var(--ink); cursor: pointer; padding: 12px 0 12px 12px;
    font: 500 .75rem/1 var(--body); letter-spacing: .3em; text-transform: uppercase;
  }
}

/* ---------- Intro line ---------- */
.intro { padding-block: 8px clamp(28px, 4vw, 48px); text-align: center; }
.intro h1, .intro p { font: italic 400 var(--step-1)/1.45 var(--display); letter-spacing: 0; max-width: 46ch; margin: 0 auto; text-wrap: balance; }

/* ---------- The collage ---------- */
/* Photos keep the order set in WordPress (left to right). Each tile's height comes from its own
   shape: portraits run tall, squares medium, and wide photos span two columns. Rows are a quarter
   of a column wide, so a 4:5 portrait is 5 rows tall. */
.collage {
  --cols: 3;
  --pad: var(--edge);
  --col: calc((100vw - 2 * var(--pad) - (var(--cols) - 1) * var(--gap)) / var(--cols));
  display: grid; grid-template-columns: repeat(var(--cols), minmax(0, 1fr));
  grid-auto-rows: calc(var(--col) / 4 - var(--gap) * .75);
  grid-auto-flow: row dense; gap: var(--gap);
  padding-left: max(var(--pad), env(safe-area-inset-left, 0px));
  padding-right: max(var(--pad), env(safe-area-inset-right, 0px));
}
.collage .tile { position: relative; display: block; overflow: hidden; cursor: zoom-in; background: var(--paper-deep); grid-row: span var(--rows, 5); min-width: 0; }
.collage .tile.is-wide { grid-column: span 2; }
.collage .tile img { width: 100%; height: 100%; object-fit: cover; }
.collage .tile.ph--empty { cursor: default; aspect-ratio: auto; }
@media (max-width: 900px) { .collage { --cols: 2; --pad: var(--gap); } }
@media (max-width: 380px) { .collage .tile.is-wide { grid-column: span 2; } }

/* Placeholder frames: say which photo goes where */
.ph--empty {
  display: grid; align-content: end; padding: 14px; aspect-ratio: var(--ar, 4 / 5); max-width: 100%;
  background:
    repeating-linear-gradient(135deg, transparent 0 14px, rgba(29,27,25,.05) 14px 15px),
    var(--paper-deep);
  outline: 1px solid var(--line); outline-offset: -1px;
}
.ph--empty span { font: 400 .72rem/1.45 var(--mono); color: var(--ink-soft); max-width: 30ch; }
.ph--empty b { display: block; font-weight: 500; color: var(--ink); margin-bottom: 2px; }

/* ---------- Category index (typographic) ---------- */
.index { padding-block: clamp(64px, 10vw, 140px); text-align: center; }
.index .caps { color: var(--ink-soft); margin-bottom: 28px; display: block; }
.index ul { list-style: none; margin: 0 auto; padding: 0; display: flex; flex-wrap: wrap; justify-content: center; gap: .05em .28em; max-width: 1000px; font: 400 clamp(2.2rem, 1rem + 4.6vw, 5.4rem)/1.08 var(--display); letter-spacing: -.02em; }
.index li { white-space: nowrap; }
.index li:nth-child(even) a { font-style: italic; }
.index a { text-decoration: none; }
.index a:hover { text-decoration: underline; text-decoration-thickness: 2px; }
.index li:not(:last-child)::after { content: ","; }

/* ---------- Closing call to action ---------- */
.cta { padding-block: clamp(56px, 8vw, 110px); border-top: 1px solid var(--line); text-align: center; }
.cta .wrap { display: grid; gap: 24px; justify-items: center; }
.cta h2 { font-size: var(--step-3); }
.cta p { color: var(--ink-soft); max-width: 44ch; }

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: .6em; min-height: 50px; padding: 0 1.8em;
  font: 500 .78rem/1 var(--body); letter-spacing: .28em; text-transform: uppercase; text-decoration: none;
  border: 1px solid var(--ink); background: var(--ink); color: var(--paper); cursor: pointer; transition: background .2s, color .2s;
}
.btn:hover { background: transparent; color: var(--ink); }
.btn--ghost { background: transparent; color: var(--ink); }
.btn--ghost:hover { background: var(--ink); color: var(--paper); }

/* ---------- Inner pages ---------- */
.page-head { padding-block: clamp(24px, 5vw, 64px) clamp(28px, 4vw, 48px); text-align: center; }
.page-head .caps { color: var(--ink-soft); display: block; margin-bottom: 16px; }
.page-head h1 { font-size: var(--step-4); line-height: .98; }
.page-head h1 em { font-style: italic; }
.page-head p { margin: 20px auto 0; max-width: 52ch; color: var(--ink-soft); }
.prose { max-width: 66ch; margin: 0 auto; padding-bottom: clamp(56px, 8vw, 100px); }
.prose > * + * { margin-top: 1.1em; }
.prose h2 { font-size: var(--step-2); margin-top: 1.8em; }
.prose h3 { font-size: var(--step-1); margin-top: 1.6em; }
.prose strong { font-weight: 500; }
.prose details { border-top: 1px solid var(--line); padding-block: 18px; }
.prose details:last-of-type { border-bottom: 1px solid var(--line); }
.prose summary { font: 400 var(--step-1)/1.3 var(--display); cursor: pointer; list-style: none; }
.prose summary::-webkit-details-marker { display: none; }
.prose summary::after { content: "+"; float: right; font-family: var(--body); }
.prose details[open] summary::after { content: "–"; }
.prose details > *:not(summary) { margin-top: 12px; color: var(--ink-soft); }

/* Portfolio index: one cover per collection */
.covers { --per: 4; display: flex; flex-wrap: wrap; justify-content: center; gap: var(--gap); padding-inline: max(var(--gap), env(safe-area-inset-left, 0px)) max(var(--gap), env(safe-area-inset-right, 0px)); }
.covers .cover { flex: 0 0 calc((100% - (var(--per) - 1) * var(--gap)) / var(--per)); }
@media (min-width: 901px) { .covers { padding-left: var(--edge); padding-right: var(--edge); } }
.cover { position: relative; display: block; text-decoration: none; color: #fff; aspect-ratio: 4 / 5; overflow: hidden; background: var(--paper-deep); }
.cover img, .cover .ph--empty { width: 100%; height: 100%; object-fit: cover; aspect-ratio: auto; transition: transform .9s cubic-bezier(.2,.7,.1,1); }
.cover:hover img { transform: scale(1.03); }
.cover .name {
  position: absolute; left: 0; right: 0; bottom: 0; padding: 18px; font: italic 400 var(--step-2)/1 var(--display);
  background: linear-gradient(to top, rgba(0,0,0,.45), transparent);
}
.cover .ph--empty { align-content: start; }
.cover .ph--empty + .name { color: var(--ink); background: none; }
@media (max-width: 900px) { .covers { --per: 2; } }
@media (max-width: 520px) { .covers { --per: 1; } .cover { aspect-ratio: 4 / 3; } }

.next-collection { text-align: center; padding-block: clamp(56px, 8vw, 100px); }
.next-collection .caps { color: var(--ink-soft); display: block; margin-bottom: 12px; }
.next-collection a { font: italic 400 var(--step-3)/1 var(--display); text-decoration: none; }
.next-collection a:hover { text-decoration: underline; }

/* How we work */
.process { list-style: none; margin: 0 auto; padding: 0 0 clamp(40px, 6vw, 80px); max-width: 900px; display: grid; }
.process li { display: grid; grid-template-columns: 64px minmax(0, 1fr) minmax(0, 1.4fr); gap: 8px 32px; padding-block: 28px; border-top: 1px solid var(--line); align-items: baseline; }
.process li:last-child { border-bottom: 1px solid var(--line); }
.process .n { font: 400 .8rem/1 var(--mono); color: var(--ink-soft); }
.process h3 { font-size: var(--step-1); }
.process p { color: var(--ink-soft); max-width: 52ch; }
@media (max-width: 700px) { .process li { grid-template-columns: 44px minmax(0, 1fr); } .process p { grid-column: 2; } }

/* Enquiry */
.enquire { display: grid; grid-template-columns: minmax(0, .8fr) minmax(0, 1.2fr); gap: clamp(32px, 6vw, 88px); padding-bottom: clamp(56px, 8vw, 110px); }
.enquire aside { display: grid; gap: 20px; align-content: start; }
.enquire aside p { color: var(--ink-soft); max-width: 40ch; }
.contact-list { list-style: none; margin: 0; padding: 0; display: grid; gap: 14px; }
.contact-list li { display: grid; grid-template-columns: 100px minmax(0, 1fr); gap: 12px; align-items: baseline; border-top: 1px solid var(--line); padding-top: 14px; }
.contact-list .k { font: 500 .7rem/1 var(--body); letter-spacing: .26em; text-transform: uppercase; color: var(--ink-soft); }
.contact-list .v { word-break: break-word; }
.form { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 22px 20px; position: relative; }
.form .full { grid-column: 1 / -1; }
.field { display: grid; gap: 8px; min-width: 0; }
.field label { font: 500 .7rem/1 var(--body); letter-spacing: .26em; text-transform: uppercase; }
.field input, .field textarea, .field select {
  width: 100%; font: 400 1rem/1.4 var(--body); color: var(--ink); background: var(--card);
  border: 1px solid var(--line); border-radius: 0; padding: 14px; min-height: 50px;
}
.field textarea { min-height: 140px; resize: vertical; }
.field input:focus, .field textarea:focus, .field select:focus { border-color: var(--ink); }
.form .hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }
.form-note { font-size: .9rem; color: var(--ink-soft); }
.notice { grid-column: 1 / -1; padding: 16px 18px; border: 1px solid var(--ink); background: var(--card); }
@media (max-width: 860px) { .enquire { grid-template-columns: 1fr; } }
@media (max-width: 520px) { .form { grid-template-columns: 1fr; } }

/* Lightbox */
.lightbox { position: fixed; inset: 0; z-index: 250; background: rgba(20,19,17,.96); display: grid; place-items: center; padding: max(16px, env(safe-area-inset-top, 0px)) max(16px, env(safe-area-inset-right, 0px)) max(16px, env(safe-area-inset-bottom, 0px)) max(16px, env(safe-area-inset-left, 0px)); }
.lightbox[hidden] { display: none; }
.lightbox img { max-height: 92vh; max-width: 100%; width: auto; object-fit: contain; }
.lightbox button { position: absolute; background: none; border: 0; color: #ece5d7; cursor: pointer; font: 500 .75rem/1 var(--body); letter-spacing: .3em; text-transform: uppercase; padding: 16px; }
.lightbox .lb-close { top: max(8px, env(safe-area-inset-top, 0px)); right: max(8px, env(safe-area-inset-right, 0px)); }
.lightbox .lb-prev { left: max(4px, env(safe-area-inset-left, 0px)); top: 50%; transform: translateY(-50%); }
.lightbox .lb-next { right: max(4px, env(safe-area-inset-right, 0px)); top: 50%; transform: translateY(-50%); }

/* Footer */
.site-footer { background: var(--night); color: var(--night-fg); padding-block: 56px 32px; }
.site-footer .wrap { display: grid; gap: 36px; }
.site-footer .top { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 28px; align-items: end; }
.site-footer .brand img { width: 170px; }
.site-footer ul { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: 12px 28px; }
.site-footer a { font: 500 .72rem/1 var(--body); letter-spacing: .28em; text-transform: uppercase; text-decoration: none; }
.site-footer a:hover { text-decoration: underline; }
.site-footer .bottom { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 12px; border-top: 1px solid rgba(236,229,215,.2); padding-top: 18px; font-size: .85rem; opacity: .7; }

/* Reveal: tiles are visible at rest; this only adds a gentle lift when supported. */
@media (prefers-reduced-motion: no-preference) {
  .js .collage .tile.is-pending { opacity: .001; transform: translateY(16px); }
  .js .collage .tile { transition: opacity .7s ease, transform .7s cubic-bezier(.2,.7,.1,1); }
}

/* WordPress button blocks inside page content: match the theme's buttons */
.prose .wp-block-buttons { margin-top: 2em; }
.prose .wp-block-button__link {
  display: inline-flex; align-items: center; min-height: 50px; padding: 0 1.8em; border-radius: 0;
  font: 500 .78rem/1 var(--body); letter-spacing: .28em; text-transform: uppercase; text-decoration: none;
  border: 1px solid var(--ink); background: var(--ink); color: var(--paper);
}
.prose .wp-block-button__link:hover { background: transparent; color: var(--ink); }
.prose ul { padding-left: 1.2em; }
.prose li + li { margin-top: .5em; }
