/*
Theme Name: Bobbe Group
Theme URI: https://bobbe.com
Description: Letterhead theme for bobbe.com — group gateway plus the "Bobbes of the World" archive. Standalone (no parent theme). Pairs with the bobbe-archive plugin.
Author: Bobbe GmbH
Version: 1.1.2
Requires at least: 6.4
Requires PHP: 7.4
Text Domain: bobbe-com
*/

/* =============================================================
   Base — ported 1:1 from the static site (assets/css/group.css)
   System fonts only: no font requests, nothing to host.
   ============================================================= */
:root {
  --paper: #f6f3ee;
  --card:  #fbf9f5;
  --ink:   #1c1b19;
  --soft:  #6f6b64;
  --faint: rgba(111,107,100,.75);
  --rule:  rgba(28,27,25,.14);
  --gold:  #a8833a;
  --text:  "Iowan Old Style", "Charter", "Bitstream Charter", Georgia, serif;
  --small: "Helvetica Neue", Helvetica, Arial, sans-serif;
}
* { box-sizing: border-box; margin: 0; padding: 0; }
body {
  background: var(--paper); color: var(--ink);
  font-family: var(--text); -webkit-font-smoothing: antialiased;
  min-height: 100svh; display: flex; flex-direction: column;
}
a { color: inherit; }
img { max-width: 100%; height: auto; display: block; }
.screen-reader-text { position: absolute !important; width: 1px; height: 1px; overflow: hidden; clip: rect(1px,1px,1px,1px); }

.page {
  flex: 1; width: 100%; max-width: 760px; margin: 0 auto;
  padding: 48px 24px 40px; display: flex; flex-direction: column;
}
.page.wide { max-width: 1080px; }

/* ───── Header: mark + language toggle ───── */
.top { display: flex; justify-content: space-between; align-items: center; gap: 16px; }
.mark { display: block; width: var(--w, 104px); overflow: hidden; }
.logo {
  display: block; width: calc(var(--w, 104px) / .46); max-width: none;
  margin-left: calc(var(--w, 104px) * -.27 / .46);
  aspect-ratio: 1028 / 290; object-fit: cover;
}
.top-right { display: flex; align-items: center; gap: 22px; }
.lang, .back { font-family: var(--small); font-size: .78rem; color: var(--faint); display: flex; gap: 6px; }
.lang a, .back { text-decoration: none; color: var(--soft); }
.lang a:hover, .back:hover { color: var(--ink); }
.lang [aria-current] { color: var(--ink); }

/* ───── Body copy (gateway) ───── */
.body { margin: auto 0; padding: 64px 0; }
.body p {
  font-size: clamp(1.25rem, 3.4vw, 1.6rem); line-height: 1.5; max-width: 30em;
  text-wrap: pretty;
}
.body p + p { margin-top: 1.1em; color: var(--soft); }
.body a { text-decoration: underline; text-decoration-thickness: 1px; text-underline-offset: .18em;
  text-decoration-color: var(--rule); transition: text-decoration-color .2s; }
.body a:hover { text-decoration-color: var(--ink); }
.body p + p a { text-decoration-color: rgba(111,107,100,.5); }
.body p + p a:hover { color: var(--ink); }
.body p.aside {
  margin-top: 2.6em; font-family: var(--small); font-size: .9rem; line-height: 1.6;
  color: var(--soft); max-width: none;
}

/* ───── Footer ───── */
.foot {
  border-top: 1px solid var(--rule); padding-top: 22px;
  display: grid; gap: 24px;
  font-family: var(--small); font-size: .78rem; line-height: 1.7; color: var(--soft);
}
.foot .col { display: flex; flex-direction: column; }
.foot .lead { color: var(--ink); }
.foot .reg { color: var(--faint); margin-top: 6px; }
.foot a { text-decoration: none; }
.foot a:hover { color: var(--ink); }
.contact { display: grid; grid-template-columns: 5.5em 1fr; align-content: start; }
.contact dt { color: var(--faint); }
.contact dd a { color: var(--ink); }
.contact dd a:hover { color: var(--soft); }
.foot .legal {
  margin-top: 12px; display: flex; flex-wrap: wrap; gap: 4px 18px;
  font-size: .7rem; color: var(--faint);
}
@media (min-width: 720px) {
  .page { padding: 64px 48px 48px; --w: 120px; }
  .body { padding: 96px 0; }
  .foot { grid-template-columns: 1fr 2fr; }
  .foot .legal { grid-column: 1 / -1; }
}

/* ───── Legal pages ───── */
.legal-body { padding: 56px 0 72px; max-width: 38em; }
.legal-body h1 { font-weight: normal; font-size: clamp(1.6rem, 4vw, 2rem); line-height: 1.25; margin-bottom: 8px; }
.legal-body .intro { font-family: var(--small); font-size: .85rem; color: var(--soft); margin-bottom: 40px; }
.legal-body h2 { font-weight: normal; font-size: 1.15rem; margin: 52px 0 12px; }
.legal-body h3 { font-family: var(--small); font-size: .85rem; font-weight: 600; margin: 30px 0 6px; }
.legal-body p, .legal-body li { font-family: var(--small); font-size: .9rem; line-height: 1.7; color: #3d3b37; }
.legal-body p + p { margin-top: .8em; }
.legal-body ul { margin: .6em 0 .8em 1.2em; }
.legal-body a { text-decoration: underline; text-decoration-color: var(--rule); text-underline-offset: .18em; }
.legal-body a:hover { text-decoration-color: var(--ink); }
@media (min-width: 720px) { .legal-body { padding: 80px 0 96px; } }

/* =============================================================
   Bobbes of the World
   ============================================================= */
.eyebrow { font-family: var(--small); font-size: .72rem; letter-spacing: .14em; text-transform: uppercase; color: var(--gold); }
.btn {
  display: inline-block; font-family: var(--small); font-size: .82rem; letter-spacing: .04em;
  padding: 12px 22px; border: 1px solid var(--ink); color: var(--ink); text-decoration: none;
  border-radius: 999px; transition: background .2s, color .2s;
}
.btn:hover { background: var(--ink); color: var(--paper); }
.btn.solid { background: var(--ink); color: var(--paper); }
.btn.solid:hover { background: transparent; color: var(--ink); }

/* Portrait card (teaser + archive grid) */
.cards { display: grid; gap: 28px 20px; grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); }
.card { text-decoration: none; display: flex; flex-direction: column; gap: 10px; }
.card .ph { aspect-ratio: 4 / 5; overflow: hidden; background: #e9e4db; border-radius: 2px; }
.card .ph img { width: 100%; height: 100%; object-fit: cover; filter: saturate(.92); transition: transform .6s ease, filter .6s; }
.card:hover .ph img { transform: scale(1.03); filter: saturate(1); }
.card .called { font-size: 1.35rem; line-height: 1.2; }
.card .who { font-family: var(--small); font-size: .78rem; color: var(--soft); }
.card .line { font-style: italic; color: var(--soft); font-size: 1rem; line-height: 1.45; }
.card.is-hidden { display: none; }

/* Homepage teaser */
.teaser { border-top: 1px solid var(--rule); padding: 56px 0 64px; }
.teaser h2 { font-weight: normal; font-size: clamp(1.5rem, 4vw, 2rem); margin: 10px 0 8px; }
.teaser .sub { color: var(--soft); max-width: 32em; line-height: 1.55; margin-bottom: 32px; }
.teaser .cards { grid-template-columns: repeat(2, 1fr); }
.teaser .actions { margin-top: 36px; display: flex; flex-wrap: wrap; gap: 14px 22px; align-items: center; }
.teaser .note { font-family: var(--small); font-size: .82rem; color: var(--soft); }
.teaser .note a { color: var(--ink); }
@media (min-width: 720px) { .teaser .cards { grid-template-columns: repeat(4, 1fr); } }

/* Archive */
.archive-head { padding: 64px 0 28px; max-width: 40em; }
.archive-head h1 { font-weight: normal; font-size: clamp(2rem, 6vw, 3.2rem); line-height: 1.1; margin: 12px 0 18px; }
.archive-head p { color: var(--soft); font-size: 1.15rem; line-height: 1.55; }
.names { display: flex; flex-wrap: wrap; gap: 6px 4px; margin: 8px 0 40px; font-size: clamp(1.1rem, 3vw, 1.4rem); }
.names button {
  font: inherit; background: none; border: 0; cursor: pointer; color: var(--soft);
  padding: 2px 4px; border-bottom: 1px solid transparent;
}
.names button:hover { color: var(--ink); }
.names button[aria-pressed="true"] { color: var(--ink); border-bottom-color: var(--gold); }
.names .sep { color: var(--rule); }
.archive-grid { padding-bottom: 72px; }
.empty { color: var(--soft); padding: 40px 0 80px; }

/* Single Bobbe */
.preview-bar {
  background: #2b2a27; color: #f6f3ee; font-family: var(--small); font-size: .82rem;
  text-align: center; padding: 10px 16px; line-height: 1.5;
}
.bobbe { padding: 48px 0 64px; }
.bobbe-hero { display: grid; gap: 28px; align-items: end; }
.bobbe-hero .portrait { aspect-ratio: 4 / 5; overflow: hidden; background: #e9e4db; border-radius: 2px; }
.bobbe-hero .portrait img { width: 100%; height: 100%; object-fit: cover; }
.bobbe-hero .they-called { font-family: var(--small); font-size: .8rem; letter-spacing: .12em; text-transform: uppercase; color: var(--gold); }
.bobbe-hero h1 { font-weight: normal; font-size: clamp(2.6rem, 9vw, 4.4rem); line-height: 1; margin: 10px 0 14px; }
.bobbe-hero .name { font-size: 1.25rem; }
.bobbe-hero .years { color: var(--soft); }
.bobbe-hero .memory-note { font-family: var(--small); font-size: .78rem; color: var(--soft); margin-top: 8px; }
.journey { display: flex; flex-wrap: wrap; align-items: center; gap: 4px 10px; margin-top: 22px; font-family: var(--small); font-size: .86rem; color: var(--soft); }
.journey .arrow { color: var(--gold); }
@media (min-width: 760px) { .bobbe-hero { grid-template-columns: 5fr 6fr; gap: 48px; } }

.wisdom { margin: 64px 0 8px; padding: 40px 0; border-top: 1px solid var(--rule); border-bottom: 1px solid var(--rule); text-align: center; }
.wisdom blockquote { font-size: clamp(1.6rem, 5vw, 2.4rem); line-height: 1.3; font-style: italic; max-width: 22em; margin: 0 auto; text-wrap: balance; }
.wisdom blockquote[dir="rtl"] { font-style: normal; }
.wisdom .translation { margin: 18px auto 0; color: var(--soft); font-size: 1.1rem; max-width: 30em; line-height: 1.5; }
.wisdom .lang-note { margin-top: 12px; font-family: var(--small); font-size: .74rem; color: var(--faint); letter-spacing: .06em; }

.bobbe-section { margin-top: 56px; max-width: 36em; }
.bobbe-section h2 { font-family: var(--small); font-weight: 600; font-size: .76rem; letter-spacing: .14em; text-transform: uppercase; color: var(--gold); margin-bottom: 14px; }
.bobbe-section .prose { font-size: 1.15rem; line-height: 1.65; }
.bobbe-section .prose p + p { margin-top: .9em; }
.dish-name { font-size: 1.6rem; margin-bottom: 10px; }
.dish-note { font-style: italic; color: var(--soft); margin-bottom: 18px; }
.recipe { font-family: var(--small); font-size: .95rem; line-height: 1.75; color: #3d3b37; white-space: pre-line; }
.figs { display: grid; gap: 18px; margin-top: 56px; }
.figs figure img { border-radius: 2px; width: 100%; }
.figs figcaption { font-family: var(--small); font-size: .74rem; color: var(--faint); margin-top: 6px; }
@media (min-width: 720px) { .figs { grid-template-columns: 1fr 1fr; } .figs.one { grid-template-columns: 1fr; max-width: 36em; } }

.credit { margin-top: 56px; font-family: var(--small); font-size: .84rem; color: var(--soft); }
.share { margin-top: 28px; display: flex; flex-wrap: wrap; gap: 10px; }
.share .btn { font-size: .78rem; padding: 9px 16px; }
.removal { margin-top: 28px; font-family: var(--small); font-size: .72rem; color: var(--faint); }
.removal a { color: var(--soft); }
.prevnext { display: flex; justify-content: space-between; gap: 20px; border-top: 1px solid var(--rule); margin-top: 56px; padding-top: 20px; font-family: var(--small); font-size: .82rem; }
.prevnext a { text-decoration: none; color: var(--soft); }
.prevnext a:hover { color: var(--ink); }

/* Card hover: her saying over the portrait (devices with a mouse).
   Touch devices keep the line under the card instead. */
.card .ph { position: relative; }
.card .say {
  position: absolute; inset: 0; display: flex; flex-direction: column; justify-content: flex-end; gap: 8px;
  padding: 18px; color: #fbf9f5; text-align: left;
  background: linear-gradient(to top, rgba(28,27,25,.88) 0%, rgba(28,27,25,.55) 55%, rgba(28,27,25,0) 100%);
  opacity: 0; transition: opacity .35s ease;
}
.card .say-orig { font-size: 1.25rem; line-height: 1.3; font-style: italic; }
.card .say-orig[dir="rtl"], .card .say-orig:dir(rtl) { font-style: normal; text-align: right; }
.card .say-tr { font-family: var(--small); font-size: .78rem; line-height: 1.45; opacity: .85; }
@media (hover: hover) {
  .card:hover .say, .card:focus-visible .say { opacity: 1; }
  .card .line { display: none; }
}
@media (hover: none) { .card .say { display: none; } }
@media (prefers-reduced-motion: reduce) { .card .say { transition: none; } }

/* No portrait yet: a quiet initial instead of an empty box */
.card .ph { display: grid; }
.card .ph-empty, .portrait-empty span { place-self: center; font-size: 4rem; color: rgba(28,27,25,.18); font-style: italic; }
.portrait-empty { display: grid; }
