/* =============================================================================
   IDEAMI 2026 — THEME  (variant: "atelier-dark")
   -----------------------------------------------------------------------------
   Quiet-luxury / poetic editorial, DARK palette.
   Fonts: Playfair Display (elegant serif) + Inter (clean sans, Apple-like).
   Light sibling: theme-light.css (swap the <link> in the .html to compare).
   Only the :root block below differs between the dark and light versions.
   ========================================================================== */

:root {
  /* ---- palette (dark) ---- */
  --bg:        #0a0a0c;
  --ink:       #f2efe9;   /* main text — high contrast */
  --ink-soft:  #c3bdb2;   /* secondary — still clearly readable on dark */
  --ink-dim:   #8b857a;   /* tertiary  — never below this on dark */
  --line:      rgba(242,239,233,0.14);
  --line-soft: rgba(242,239,233,0.08);
  --accent:    #d9b877;   /* champagne gold — the ONLY accent */
  --accent-hi: #f0dcac;
  --verse:     #c3b2d8;   /* muted mauve for poetic lines */
  --white:     #ffffff;
  --glow-a:    rgba(217,184,119,0.12);
  --glow-b:    rgba(195,178,216,0.08);

  /* ---- Loss Landscape editable content colors -------------------------------
     Tweak these three to recolor the home / page copy. They are used by the
     generated content (inline via var(...)) and by links inside .block.
       --ll-orange : the leading LABELS (RosettaMind, NEW paper, …)  [orig #c8450c]
       --ll-link   : body links (Featured articles, Explore, Watch)  [orig #545a7f]
       --ll-text   : body copy that the original set to black         */
  --ll-orange: #caa66f;   /* label accent (a touch brighter than the print #c8450c) */
  --ll-link:   #8b93d6;   /* link blue-grey, brightened for the dark bg (orig #545a7f) */
  --ll-text:   #ece7dd;   /* readable body copy on dark */

  /* ---- type & metrics (shared with light) ---- */
  --maxw:      760px;
  --ff-display:'Inter', system-ui, sans-serif;   /* all-sans, Apple-clean */
  --ff-ui:     'Inter', system-ui, sans-serif;
  --ff-body:   'Inter', system-ui, sans-serif;
}

/* ===========================================================================
   The rest of the file is palette-agnostic: it reads the variables above,
   so theme-light.css only needs to redefine :root.
   ======================================================================== */

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }

body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: var(--ff-body);
  font-size: 17px;
  line-height: 1.72;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

/* one quiet warm glow, static */
body::before {
  content: ""; position: fixed; inset: 0; z-index: -1; pointer-events: none;
  background:
    radial-gradient(60vmax 40vmax at 50% -10%, var(--glow-a), transparent 60%),
    radial-gradient(50vmax 50vmax at 85% 8%, var(--glow-b), transparent 62%);
}

a { color: var(--accent); text-decoration: none; transition: color .2s ease; }
a:hover { color: var(--accent-hi); }

/* ---- scroll progress -------------------------------------------------- */
.progress {
  position: fixed; top: 0; left: 0; height: 2px; width: 0;
  background: var(--accent); z-index: 60; transition: width .1s linear;
}

/* ---- sticky nav ------------------------------------------------------- */
.nav {
  position: sticky; top: 0; z-index: 50;
  backdrop-filter: blur(18px);
  background: color-mix(in srgb, var(--bg) 78%, transparent);
  border-bottom: 1px solid var(--line-soft);
}
.nav-inner {
  max-width: var(--maxw); margin: 0 auto; padding: 16px 28px;
  display: flex; align-items: center; gap: 22px;
  position: relative;
}
.nav-brand {
  font-family: var(--ff-ui); font-weight: 600; letter-spacing: 3px;
  text-transform: uppercase; color: var(--ink); font-size: 13px; flex: none;
}
.nav-brand:hover { color: var(--accent); }
.nav-links {
  display: flex; gap: 0; margin-left: auto; flex-wrap: wrap; justify-content: flex-end;
}
.nav-link {
  font-family: var(--ff-ui); font-weight: 500; font-size: 12px;
  letter-spacing: .3px; color: var(--ink-soft); white-space: nowrap; padding: 6px 12px;
}
.nav-link:hover { color: var(--ink); }
.nav-link.active { color: var(--accent); }

/* hamburger button — hidden on desktop, shown on mobile */
.nav-burger {
  display: none; flex: none; margin-left: auto;
  width: 34px; height: 30px; padding: 6px; background: none; border: 0; cursor: pointer;
}
.nav-burger span {
  display: block; height: 2px; width: 100%; margin: 4px 0;
  background: var(--ink); border-radius: 2px; transition: transform .25s ease, opacity .2s ease;
}

@media (max-width: 720px) {
  .nav-burger { display: block; }
  /* links become a vertical dropdown panel under the bar, hidden until .open */
  .nav-links {
    display: none; position: absolute; left: 0; right: 0; top: 100%;
    flex-direction: column; align-items: stretch; gap: 0; margin: 0;
    background: color-mix(in srgb, var(--bg) 96%, transparent);
    backdrop-filter: blur(18px);
    border-bottom: 1px solid var(--line-soft);
    padding: 6px 0;
  }
  .nav.open .nav-links { display: flex; }
  .nav-link { font-size: 15px; padding: 13px 28px; letter-spacing: .5px; }
  .nav-link:not(:last-child) { border-bottom: 1px solid var(--line-soft); }
  /* animate burger → X when open */
  .nav.open .nav-burger span:nth-child(1) { transform: translateY(6px) rotate(45deg); }
  .nav.open .nav-burger span:nth-child(2) { opacity: 0; }
  .nav.open .nav-burger span:nth-child(3) { transform: translateY(-6px) rotate(-45deg); }
}

/* ---- hero ------------------------------------------------------------- */
.hero { position: relative; }

/* full-bleed image hero — image COVERS the hero (cropped), centered, like the
   original. Tall on both desktop and mobile so the landscape reads vertically. */
.hero.has-img {
  min-height: 92vh; display: flex; align-items: flex-end; overflow: hidden;
}
.hero-media { position: absolute; inset: 0; z-index: 0; background: var(--bg); }
.hero-media img {
  width: 100%; height: 100%; object-fit: cover; object-position: center 50%;
  opacity: 0.95;                 /* vivid image, like the original hero */
  filter: saturate(1.05) brightness(0.82);   /* tame the bright center so text reads */
}
/* Scrim replicates the original's technique in the DARK palette: a soft veil at
   the very top (keeps nav + title legible) and a fade to the page background at
   the bottom, so the image's pale/misty base melts into --bg with NO hard edge
   and NO mid-image gradient. */
.hero-scrim {
  position: absolute; inset: 0; z-index: 1; pointer-events: none;
  background:
    linear-gradient(180deg,
      rgba(10,10,12,0.30) 0%,
      rgba(10,10,12,0.10) 14%,
      rgba(10,10,12,0.45) 40%,
      rgba(10,10,12,0.72) 62%,
      rgba(10,10,12,0.90) 82%,
      var(--bg) 100%);
}
/* torn brush-stroke bottom edge (like the original). The brush PNG is white
   strokes on transparent; we use it as a MASK over a --bg-coloured layer so the
   ragged edge is painted in OUR dark page colour (melts image into the page,
   works on any background — not tied to white). */
.hero.has-img .hero-scrim::after {
  content: ""; position: absolute; left: -1px; right: -1px; bottom: -2px;
  height: clamp(60px, 14vw, 180px); pointer-events: none; z-index: 3;
  background: var(--bg);   /* the cut is painted in OUR page colour */
  /* 100% auto keeps the brush's NATURAL aspect so the torn curve keeps its full
     vertical range (100% 100% squashed it flat). */
  -webkit-mask: url(/assets/ll/deco/calligraphy_54.png) bottom center / 100% auto no-repeat;
          mask: url(/assets/ll/deco/calligraphy_54.png) bottom center / 100% auto no-repeat;
}
/* title/body overlaid over the lower part of the image (content anchored bottom) */
.hero.has-img .hero-body {
  position: relative; z-index: 2; margin: 0 auto;
  padding: clamp(30px, 2vh, 30px) 28px clamp(140px, 20vh, 240px);
}

/* Sub-page heroes (page-hero): a shorter cover banner than the home hero, same
   on desktop and mobile. The image (which has a light/snow ragged bottom like the
   original) shows through — only a soft TOP veil for nav legibility, NO heavy
   bottom fade — and the torn mask edge (.hero-scrim::after) cuts it into the page. */
.page-hero.has-img { min-height: 58vh; align-items: center; }
.page-hero.has-img .hero-scrim {
  background: linear-gradient(180deg,
    rgba(10,10,12,0.55) 0%, rgba(10,10,12,0.18) 18%,
    rgba(10,10,12,0) 42%, rgba(10,10,12,0) 100%);
}
.page-hero.has-img .hero-body { padding: 38px 28px; }
@media (max-width: 720px) {
  .page-hero.has-img { min-height: 42vh; }
  .page-hero.has-img .hero-body { padding: 26px 22px; }
}

.hero-body {
  max-width: 680px; margin: 0 auto; position: relative;
  padding: clamp(70px, 15vh, 150px) 28px clamp(40px, 8vh, 80px);
  text-align: center;
}
.hero.no-img .hero-body { padding-top: clamp(90px, 18vh, 180px); }
.hero.has-img .hero-name,
.hero.has-img .hero-tagline,
.hero.has-img .hero-roles,
.hero.has-img .hero-bio { text-shadow: 0 2px 10px rgba(0,0,0,0.85), 0 1px 30px rgba(0,0,0,0.6); }

.hero-name {
  font-family: var(--ff-ui); font-weight: 600; letter-spacing: 6px;
  text-transform: uppercase; font-size: 13px; color: var(--accent);
  margin: 0 0 24px;
}
.hero-tagline {
  font-family: var(--ff-display); font-weight: 300;
  color: var(--white); font-size: clamp(29px, 5.4vw, 52px); line-height: 1.14;
  letter-spacing: -0.02em; margin: 0 0 30px;
}
.hero-roles {
  font-family: var(--ff-ui); font-weight: 400; font-size: 14px;
  color: var(--ink-soft); line-height: 1.85; margin: 0 auto 22px; max-width: 580px;
}
.hero-bio {
  color: var(--ink-soft); max-width: 580px; margin: 0 auto 30px; font-size: 16px;
}
.hero-links { display: flex; flex-wrap: wrap; gap: 10px; justify-content: center; }
.pill {
  font-family: var(--ff-ui); font-weight: 500; font-size: 13px;
  color: var(--ink); padding: 9px 18px; border-radius: 999px;
  border: 1px solid var(--line); transition: all .2s ease;
}
.pill:hover { color: var(--white); border-color: var(--accent); }
.pill-short { display: none; }   /* desktop shows full label; mobile swaps */

/* social icons under the hero buttons */
.hero-social { display: flex; gap: 14px; justify-content: center; margin-top: 20px; }
.social-ico {
  width: 40px; height: 40px; display: inline-flex; align-items: center; justify-content: center;
  border: 1px solid var(--line); border-radius: 999px; color: var(--ink-soft);
  transition: color .2s ease, border-color .2s ease, transform .2s ease;
}
.social-ico svg { width: 20px; height: 20px; display: block; }
.social-ico:hover { color: var(--accent); border-color: var(--accent); transform: translateY(-2px); }
.hero.has-img .social-ico { color: var(--ink); }

/* ---- main wrap -------------------------------------------------------- */
.wrap { max-width: var(--maxw); margin: 0 auto; padding: 20px 28px 90px; }

/* ---- intro video ------------------------------------------------------ */
.video {
  position: relative; width: 100%; aspect-ratio: 16/9;
  margin: 14px 0 28px; overflow: hidden;
}
.video iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; }

/* ---- collapsible sections -------------------------------------------- */
.card {
  position: relative; margin: 0;
  border-top: 1px solid var(--line-soft);
  opacity: 0; transform: translateY(12px);
  transition: opacity .8s ease, transform .8s ease;
  scroll-margin-top: 64px;
}
.card:last-of-type { border-bottom: 1px solid var(--line-soft); }
.card.in { opacity: 1; transform: none; }

.card-head {
  width: 100%; display: flex; align-items: baseline; gap: 22px;
  padding: 34px 4px; background: none; border: 0; cursor: pointer;
  text-align: left; color: inherit; font: inherit;
}
.card-num {
  font-family: var(--ff-ui); font-weight: 500; font-size: 12px;
  color: var(--ink-dim); flex: none; width: 26px; letter-spacing: .5px; padding-top: 12px;
}
.card-htext { flex: 1; min-width: 0; }
.card-titlerow { display: flex; align-items: baseline; gap: 12px; }
.card-title {
  font-family: var(--ff-display); font-weight: 600; font-size: clamp(20px, 3vw, 26px);
  line-height: 1.2; letter-spacing: -0.015em; color: var(--ink); transition: color .2s ease;
}
.card-head:hover .card-title { color: var(--accent); }
.card-verse {
  display: block; font-family: var(--ff-display); font-weight: 400;
  color: var(--verse); font-size: 14.5px; line-height: 1.55; margin-top: 8px;
  letter-spacing: .1px;
}
.card-caret {
  font-family: var(--ff-ui); font-weight: 300; font-size: 24px; line-height: 1;
  color: var(--ink-dim); flex: none; padding-top: 10px;
  transition: transform .35s ease, color .2s ease;
}
.card.open .card-caret { transform: rotate(45deg); color: var(--accent); }
.card-head:hover .card-caret { color: var(--ink-soft); }

.card-body {
  display: grid; grid-template-rows: 0fr;
  transition: grid-template-rows .45s cubic-bezier(.4,0,.2,1);
}
.card.open .card-body { grid-template-rows: 1fr; }
.card-body-inner { overflow: hidden; min-height: 0; padding-left: 4px; }
.card-body-inner > *:first-child { margin-top: 0; }
.card.open .card-body-inner { padding-bottom: 36px; }

.intro { color: var(--ink-soft); font-size: 15px; margin: 2px 0 12px; }

.list { list-style: none; margin: 8px 0 0; padding: 0; }
.list li {
  position: relative; padding: 10px 0 10px 20px;
  border-bottom: 1px solid var(--line-soft); font-size: 16px; line-height: 1.65;
}
.list li:last-child { border-bottom: none; }
.list li::before {
  content: ""; position: absolute; left: 0; top: 18px;
  width: 5px; height: 5px; border-radius: 50%; background: var(--accent); opacity: .8;
}
.list strong { font-weight: 700; }   /* colour comes from .lbl (var --ll-orange) */

.tag {
  display: inline-block; font-family: var(--ff-ui); font-weight: 600;
  font-size: 11px; letter-spacing: .8px; text-transform: uppercase;
  color: var(--verse); margin-right: 8px;
}

.expand {
  display: inline-block; margin-top: 22px;
  font-family: var(--ff-ui); font-weight: 500; font-size: 12.5px; letter-spacing: .3px;
  color: var(--accent); padding: 9px 18px; border-radius: 999px; border: 1px solid var(--line);
}
.expand:hover { border-color: var(--accent); }

/* ---- testimonials ----------------------------------------------------- */
.tq {
  margin: 0 0 4px; padding: 20px 0;
  border-bottom: 1px solid var(--line-soft);
}
.tq:last-child { border-bottom: none; }
.tq-quote {
  margin: 0 0 12px; color: var(--ink); font-size: 16px; line-height: 1.7;
}
.tq-by { display: flex; flex-direction: column; gap: 1px; }
.tq-name {
  font-family: var(--ff-ui); font-weight: 600; font-size: 14px; color: var(--accent);
  letter-spacing: .2px;
}
.tq-role {
  font-family: var(--ff-ui); font-weight: 400; font-size: 12.5px; color: var(--ink-dim);
}
.card-head.static { cursor: default; }

/* ---- rosettamind feature blocks --------------------------------------- */
.feat {
  padding: 28px 0; border-top: 1px solid var(--line-soft);
  opacity: 0; transform: translateY(12px);
  transition: opacity .7s ease, transform .7s ease;
}
.feat.in { opacity: 1; transform: none; }
.feat:first-of-type { border-top: none; }
.feat-title {
  font-family: var(--ff-display); font-weight: 600; font-size: clamp(22px, 3.2vw, 28px);
  letter-spacing: -0.015em; color: var(--ink); margin: 0 0 8px;
}
.feat-desc { color: var(--ink-soft); font-size: 16px; margin: 0 0 16px; max-width: 560px; }
.feat-links { display: flex; gap: 10px; }

/* ---- exhibits page ---------------------------------------------------- */
.exhibits-hero .hero-body { margin-top: 0; padding-top: clamp(80px, 14vh, 150px); }
.wrap-back { margin-top: 50px; text-align: center; }

/* ---- footer ----------------------------------------------------------- */
.foot {
  max-width: var(--maxw); margin: 60px auto 0; padding: 56px 28px 90px;
  border-top: 1px solid var(--line-soft);
  display: grid; grid-template-columns: 1fr 1fr; gap: 34px 46px;
}
.foot-title {
  font-family: var(--ff-ui); font-weight: 600; letter-spacing: .2px;
  font-size: 15px; color: var(--ink); margin: 0 0 16px;
}
.foot-list { list-style: none; margin: 0; padding: 0; }
.foot-list li { padding: 5px 0; }
.foot-list a { color: var(--ink-soft); font-family: var(--ff-ui); font-weight: 400; font-size: 14.5px; }
.foot-list a:hover { color: var(--accent); }
.foot-meta {
  grid-column: 1 / -1; margin-top: 16px; padding-top: 22px;
  border-top: 1px solid var(--line-soft);
  color: var(--ink-dim); font-family: var(--ff-ui); font-weight: 400; font-size: 12.5px;
}
.foot-copy { margin-top: 6px; font-family: var(--ff-ui); }

/* ---- theme toggle (floating, dev convenience) ------------------------ */
.theme-toggle {
  position: fixed; bottom: 18px; right: 18px; z-index: 70;
  font-family: var(--ff-ui); font-weight: 500; font-size: 12px; letter-spacing: .4px;
  color: var(--ink); background: color-mix(in srgb, var(--bg) 82%, transparent);
  border: 1px solid var(--line); border-radius: 999px; padding: 8px 14px;
  cursor: pointer; backdrop-filter: blur(12px); transition: border-color .2s ease;
}
.theme-toggle:hover { border-color: var(--accent); color: var(--accent); }

/* ---- responsive ------------------------------------------------------- */
@media (max-width: 620px) {
  body { font-size: 16px; }
  .wrap { padding: 16px 20px 70px; }
  .hero-body { padding-left: 22px; padding-right: 22px; }
  .card-head { gap: 14px; padding: 28px 2px; }
  .card-body-inner { padding-left: 2px; }
  .foot { grid-template-columns: 1fr; }

  /* phones: keep the 3 CTAs on a single row using shorter labels */
  .hero-links { flex-wrap: nowrap; gap: 8px; }
  .hero-links .pill { padding: 9px 12px; font-size: 12px; white-space: nowrap; }
  .pill-full { display: none; }
  .pill-short { display: inline; }
}

/* ---- portfolio gallery + lightbox ------------------------------------ */
/* IN-PROJECT gallery thumb size (the images you click to enlarge). Tweak these
   two numbers to taste — bigger value = bigger thumbnails. */
:root { --gallery-thumb: 300px; --gallery-thumb-mobile: 150px; }
.gallery { display:grid; grid-template-columns:repeat(auto-fill,minmax(var(--gallery-thumb),1fr));
  gap:.6rem; margin:1rem 0; }
.gallery-img { width:100%; aspect-ratio:4/3; object-fit:cover; border-radius:6px;
  cursor:zoom-in; background:#111; transition:opacity .2s; }
.gallery-img:hover { opacity:.85; }
.lightbox { position:fixed; inset:0; background:rgba(0,0,0,.9); display:none;
  align-items:center; justify-content:center; z-index:1000; cursor:zoom-out; padding:2rem; }
.lightbox.open { display:flex; }
.lightbox-img { max-width:92vw; max-height:90vh; object-fit:contain; border-radius:6px; }
.lightbox-nav {
  position:absolute; top:50%; transform:translateY(-50%);
  background:rgba(0,0,0,.35); color:#fff; border:0; cursor:pointer;
  width:52px; height:72px; font-size:30px; line-height:1; border-radius:8px;
  display:flex; align-items:center; justify-content:center; transition:background .2s; }
.lightbox-nav:hover { background:rgba(0,0,0,.6); }
.lightbox-prev { left:2.5vw; }
.lightbox-next { right:2.5vw; }
.lightbox-close {
  position:absolute; top:2.2vh; right:2.5vw; background:none; border:0; color:#fff;
  font-size:38px; line-height:1; cursor:pointer; opacity:.8; }
.lightbox-close:hover { opacity:1; }
.lightbox-count {
  position:absolute; bottom:2.4vh; left:0; right:0; text-align:center;
  color:#fff; font-size:14px; letter-spacing:.05em; opacity:.85; pointer-events:none; }
@media (max-width:640px){
  .lightbox-nav { width:40px; height:60px; font-size:24px; }
  .lightbox-prev { left:1vw; } .lightbox-next { right:1vw; }
}
@media (max-width:640px){ .gallery{ grid-template-columns:repeat(auto-fill,minmax(var(--gallery-thumb-mobile),1fr)); } }

/* ---- portfolio hub tile grid ----------------------------------------- */
.ptiles { display:grid; grid-template-columns:repeat(auto-fill,minmax(240px,1fr));
  gap:1.25rem 1rem; margin:1.5rem 0 2.5rem; }
.ptile { display:flex; flex-direction:column; text-decoration:none; color:inherit;
  border-radius:8px; overflow:hidden; }
.ptile-media { position:relative; width:100%; aspect-ratio:16/10; background:#111;
  border-radius:8px; overflow:hidden; }
.ptile-img { width:100%; height:100%; object-fit:cover; display:block;
  transition:transform .4s ease, opacity .3s ease; }
.ptile:hover .ptile-img { transform:scale(1.05); opacity:.9; }
.ptile-title { margin-top:.6rem; font-size:15px; font-weight:500; line-height:1.3;
  color:var(--ink,#e8e6e1); }
.ptile:hover .ptile-title { color:var(--accent,#c9a24a); }
@media (max-width:640px){
  .ptiles{ grid-template-columns:repeat(2,1fr); gap:.9rem .6rem; }
  .ptile-title{ font-size:13px; }
}

/* ---- hub sub-section heading ----------------------------------------- */
.hub-sub { font-size:14px; font-weight:600; letter-spacing:.12em; text-transform:uppercase;
  color:var(--accent,#c9a24a); margin:2.2rem 0 .2rem; padding-bottom:.5rem;
  border-bottom:1px solid var(--line-soft,#26262b); }
.hub-sub:first-child { margin-top:.5rem; }
.ptiles + .hub-sub { margin-top:2.6rem; }

/* ---- hub filter tabs (Art, Film & Media) ----------------------------- */
.hub-tabs { display:flex; flex-wrap:wrap; gap:.5rem; margin:.5rem 0 1.6rem; }
.hub-tab {
  font-family:var(--ff-ui); font-size:13px; font-weight:500; letter-spacing:.02em;
  color:var(--ink-soft,#c3bdb2); background:transparent; cursor:pointer;
  padding:8px 16px; border-radius:999px; border:1px solid var(--line,#2a2a30);
  transition:all .2s ease; white-space:nowrap; }
.hub-tab:hover { color:var(--ink,#f2efe9); border-color:var(--accent,#d9b877); }
.hub-tab.active {
  color:var(--bg,#0a0a0c); background:var(--accent,#d9b877);
  border-color:var(--accent,#d9b877); font-weight:600; }
@media (max-width:640px){ .hub-tab { font-size:12px; padding:7px 13px; } }

/* ---- standalone-page section heading (e.g. Press bios/visuals) -------- */
.page-heading {
  font-family:var(--ff-ui); font-size:13px; font-weight:600; letter-spacing:.18em;
  text-transform:uppercase; color:var(--accent,#d9b877);
  margin:2.6rem 0 1rem; padding-top:1.4rem; border-top:1px solid var(--line,#2a2a30); }
.page-heading:first-child { margin-top:.4rem; padding-top:0; border-top:0; }

/* ===========================================================================
   LOSS LANDSCAPE — integrated full-bleed section backgrounds
   Replicates the losslandscape.com home look (beautiful background images
   woven between sections) in the dark 2026 palette. A section with a `bg`
   field in content.js gets class .has-bg; --sec-bg carries the image URL.
   The image is full-viewport-width, dark-overlaid and soft-faded top+bottom
   so it melts into --bg and the text stays fully legible.
   ======================================================================== */
.card.has-bg { position: relative; }
.card.has-bg::before {
  content: ""; position: absolute; z-index: -1; pointer-events: none;
  top: -6%; bottom: -6%;
  left: 50%; width: 100vw; margin-left: -50vw;   /* break out of the text column */
  background-image: var(--sec-bg);
  background-size: cover; background-position: center;
  opacity: 0.30; filter: saturate(1.05);
  -webkit-mask-image: linear-gradient(180deg, transparent 0%, #000 24%, #000 74%, transparent 100%);
          mask-image: linear-gradient(180deg, transparent 0%, #000 24%, #000 74%, transparent 100%);
}
.card.has-bg::after {
  content: ""; position: absolute; z-index: -1; pointer-events: none;
  inset: 0;
  left: 50%; width: 100vw; margin-left: -50vw;
  background: linear-gradient(180deg, var(--bg) 0%, rgba(10,10,12,0.55) 40%, rgba(10,10,12,0.55) 60%, var(--bg) 100%);
}
.card.has-bg .card-title { text-shadow: 0 2px 20px rgba(0,0,0,0.7); }

/* ===========================================================================
   LOSS LANDSCAPE — ordered content blocks (home + all pages)
   Faithful to the original DIVI flow: wide media, natural (uncropped) image
   aspect ratios, and a caption under each video / gallery thumbnail.
   ======================================================================== */
/* Single centered content column, exactly like the original DIVI pages:
   everything shares ONE width and is LEFT-aligned. Blocks are direct children
   of main.wrap; the engine builds them from PURE DATA (no HTML in content). */
.wrap { max-width: 1080px; text-align: left; }

/* section headings: ~24px, sans, normal case, editable accent */
.sec-h {
  font-family: var(--ff-display); font-weight: 700; letter-spacing: 0;
  line-height: 1.3; color: var(--accent); margin: 48px 0 14px; font-size: 24px;
}
/* a paragraph line: [formula][orange label][text][links] */
.line { margin: 14px 0; font-size: 16px; line-height: 1.7; color: var(--ink); }
.lbl { color: var(--ll-orange); font-weight: 700; }   /* editable orange label */
.lk {                                                   /* editable link colour */
  color: var(--ll-link);
  text-decoration: underline;
  text-decoration-thickness: 1px;
  text-underline-offset: 2px;
  text-decoration-color: rgba(139,147,214,0.45);        /* faint underline = "tap me" */
}

/* bulleted lists (Latest update, Featured …), sized/styled like the ideami home */
.list { list-style: none; margin: 8px 0 18px; padding: 0; }
.list li {
  position: relative; padding: 10px 0 10px 20px;
  border-bottom: 1px solid var(--line-soft); font-size: 16px; line-height: 1.65; color: var(--ink);
}
.list li:last-child { border-bottom: none; }
.list li::before {
  content: ""; position: absolute; left: 0; top: 17px;
  width: 5px; height: 5px; border-radius: 50%; background: var(--accent); opacity: .8;
}
/* inline rendered-LaTeX formula (kept as an image; recoloured for the dark bg) */
.formula { max-width: 100%; height: auto; vertical-align: middle; margin-right: 6px;
  filter: invert(1) hue-rotate(180deg); }

/* inline single image — NATURAL aspect ratio, full column width, not cropped */
.block-fig { margin: 26px 0; text-align: left; }
.block-img { width: 100%; height: auto; display: block; border-radius: 8px; cursor: zoom-in;
  box-shadow: 0 10px 40px rgba(0,0,0,0.4); }
.cgallery-cap {
  font-size: 15px; line-height: 1.6; color: var(--ink-soft); margin-top: 10px; text-align: left;
}
.cg-title { color: var(--ink); }

/* caption gallery — 2 columns, each thumb natural aspect (uncropped) + caption below, left */
.cgallery { display: grid; grid-template-columns: 1fr 1fr; gap: 40px 30px; margin: 30px 0; }
.cgallery-cell { margin: 0; text-align: left; }
.cgallery-img { width: 100%; height: auto; display: block; border-radius: 8px; cursor: zoom-in;
  box-shadow: 0 8px 30px rgba(0,0,0,0.4); transition: opacity .2s ease; }
.cgallery-img:hover { opacity: .88; }

/* Fine Art America shop widget */
/* FAA shop widget breaks out of the 1080px column to full viewport width
   (desktop shows the left category menu, like the original site). */
.faa { margin: 30px 0; width: 100vw; margin-left: calc(50% - 50vw); }
.faa iframe { width: 100%; border: 0; }

@media (max-width: 720px) {
  .cgallery { grid-template-columns: 1fr; gap: 26px; }
  .wrap { padding-left: 18px; padding-right: 18px; }
}
