/* ══════════════════════════════════════════════════════════
   NICOLAS ROBEL — main.css
   Sections:
     RESET · TOKENS · HSIK · NAV · BARS · COMPACT-BAR
     PROJ-NAV · FOOTER · MAIN · MASONRY · CARDS · NEWS-CARD
     HOVER-PANEL · PROJECT-VIEW · BIO-CONTACT · CREDITS
   ══════════════════════════════════════════════════════════ */


/* ══ RESET ═════════════════════════════════════════════════ */

*,
*::before,
*::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  -webkit-font-smoothing: antialiased;
}

body {
  font-family: var(--fi);
  font-variation-settings: 'wght' 700;
  font-size: 23px;
  color: #fff;
  background: var(--bg);
  min-height: 100vh;
  line-height: 1.3;
}

a     { color: inherit; text-decoration: none; }
button{ font-family: var(--fi); border: none; background: none; cursor: pointer; color: inherit; }


/* ══ TOKENS ════════════════════════════════════════════════ */

:root {
  --fi:     'Inter var', 'Inter', sans-serif;
  --fd:     'Bebas Neue', sans-serif;
  --y:      #FFFE03;
  --ink:    #0C0C0A;
  --ease:   cubic-bezier(.4, 0, .2, 1);
  --bg:     #0C0C0A;

  /* Layout heights */
  --top-h:  48px;
  --bar-h:  38px;
  --foot-h: 42px;
  --gap:    4px;
  --grid-gap: 3px;

  /* Category accent colours */
  --c-ill:   #8B3A2A;
  --c-ill-p: #A84E3A;
  --c-ill-c: #6A2418;
  --c-sto:   #2B4A7A;
  --c-sto-b: #3D5E8E;
  --c-sto-s: #1A3360;
  --c-exh:   #2A5C3F;
  --c-exp:   #7A4E20;
  --c-goo:   #4A3268;
  --c-tod:   #1E5A60;
}


/* ══ HSIK (intro overlay) ══════════════════════════════════ */

#hsik {
  position: fixed;
  inset: 0;
  z-index: 1000;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  pointer-events: all;
  cursor: none;
  user-select: none;
  transition: opacity 1.3s ease;
  background: rgba(12,12,10,.82);
}

#hsik span {
  font-family: var(--fd);
  font-size: clamp(60px, 36vw, 390px);
  line-height: .82;
  color: var(--y);
  display: block;
  text-align: center;
  text-shadow: 0 0 180px rgba(255,254,3,.4);
  pointer-events: none;
  position: relative;
  z-index: 1;
}

#hsik.gone {
  opacity: 0;
  pointer-events: none;
}

/* "clic clic clic" custom cursor inside HSIK */
#hsik-clic {
  position: fixed;
  z-index: 1001;
  pointer-events: none;
  font-family: var(--fi);
  font-variation-settings: 'wght' 700;
  font-size: 15px;
  color: var(--y);
  white-space: nowrap;
  transform: translate(12px, 16px); /* below and right of cursor */
  opacity: 0;
  transition: opacity .15s;
  letter-spacing: .04em;
  text-transform: lowercase;
}

#hsik-clic.show { opacity: 1; }

/* Pixel storm canvas (inside #hsik) */
#pixelStorm {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  opacity: 0;
  transition: opacity 1.2s ease;
  pointer-events: none;
  z-index: 0;
}

#pixelStorm.active { opacity: 1; }


/* ══ NAV ═══════════════════════════════════════════════════ */

#nav-shield {
  position: fixed;
  top: 0; left: 0; right: 0;
  height: var(--top-h);
  background: var(--ink);
  z-index: 898;
}

#nav {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 900;
  transition: transform .36s var(--ease);
}

#nav.hidden { transform: translateY(-100%); }

.topbar {
  height: var(--top-h);
  background: var(--ink);
  display: flex;
  align-items: center;
  padding: 0 16px;
  gap: 0;
}

/* Logo */
.logo-wrap {
  position: relative;
  display: inline-flex;
  align-items: center;
  margin-right: auto;
}

.logo {
  font-family: var(--fi);
  font-variation-settings: 'wght' 700;
  font-size: 18px;
  color: var(--y);
  transition: color .15s;
  cursor: pointer;
  line-height: 1;
  position: relative;
  z-index: 1;
  border: none;
  background: none;
  padding: 0;
}

/* "reload" text swap — CSS only, no DOM mutation */
.logo::after {
  content: attr(data-hover);  /* set to 'accueil' or 'home' via nav.php */
  position: absolute;
  left: 0; top: 50%;
  transform: translateY(-50%);
  opacity: 0;
  transition: opacity .12s;
  pointer-events: none;
  white-space: nowrap;
  color: var(--y);             /* always yellow, never black */
}

.logo.hovered .logo-text { opacity: 0; transition: opacity .12s; }
.logo.hovered::after     { opacity: 1; }
.logo:hover              { color: var(--y); } /* keep yellow during transition */

/* Hover invitation hint */
#logo-hint {
  position: absolute;
  left: calc(100% + 10px);
  top: 50%;
  transform: translateY(-50%);
  font-family: var(--fi);
  font-variation-settings: 'wght' 500;
  font-size: 11px;
  color: rgba(255,254,3,.4);
  letter-spacing: .06em;
  text-transform: lowercase;
  white-space: nowrap;
  pointer-events: none;
  opacity: 0;
  animation: hint-pulse 2.8s ease-in-out 3s infinite;
}

@keyframes hint-pulse {
  0%, 100% { opacity: 0; }
  40%, 60%  { opacity: 1; }
}

/* Bio/contact button */
.tnav-btn {
  font-family: var(--fi);
  font-variation-settings: 'wght' 700;
  font-size: 18px;
  color: var(--y);
  transition: color .15s;
  position: relative;
  background: none;
  border: none;
  cursor: pointer;
  padding: 0 0 0 20px;
}

.tnav-btn:hover    { color: rgba(255,254,3,.35); }
.tnav-btn.on::after {
  content: '';
  position: absolute;
  left: 20px; right: 0; bottom: -2px;
  height: 2px;
  background: var(--y);
}

/* Language switcher */
.lang {
  margin-left: 16px;
  display: flex;
  align-items: center;
}

.lang-active {
  font-family: var(--fi);
  font-variation-settings: 'wght' 700;
  font-size: 18px;
  color: var(--y);
  cursor: default;
  transition: opacity .18s;
}

.lang:hover .lang-active { opacity: .28; }

.lang-other {
  font-family: var(--fi);
  font-variation-settings: 'wght' 700;
  font-size: 18px;
  color: rgba(255,254,3,.35);
  margin-left: 8px;
  opacity: 0;
  pointer-events: none;
  transition: opacity .18s;
  cursor: pointer;
  text-decoration: none;
}

.lang:hover .lang-other { opacity: 1; pointer-events: auto; }
.lang-other:hover        { color: var(--y); }


/* ══ SECTION BARS (home) ═══════════════════════════════════ */

#bars {
  display: flex;
  flex-wrap: wrap;
  align-items: stretch;
  background: var(--y);
  overflow: visible;
  padding: 0 0 4px;
  gap: 0;
}

#bars.peek {
  opacity: 0;
  pointer-events: none;
  transition: opacity .2s;
}

/* Non-home: bars hidden by default, reveal on nav hover */
#bars.bars-offpage {
  max-height: 0;
  overflow: hidden;
  opacity: 0;
  pointer-events: none;
  transition: max-height .28s var(--ease), opacity .22s;
}

#nav:hover #bars.bars-offpage,
#nav.nav-reveal #bars.bars-offpage {
  max-height: 200px;
  opacity: 1;
  pointer-events: auto;
}

.sbar {
  position: relative;
  height: var(--bar-h);
  display: inline-flex;
  align-items: center;
  padding: 0 16px;
  cursor: pointer;
  flex: 0 0 auto;
  background: transparent;
  box-sizing: border-box;
}

.sbar-lbl {
  font-family: var(--fi);
  font-variation-settings: 'wght' 700;
  font-size: 18px;
  color: var(--ink);
  text-transform: lowercase;
  user-select: none;
  white-space: nowrap;
  border-bottom: 2px solid transparent;
  transition: border-bottom-color .18s;
}

.sbar:hover .sbar-lbl  { border-bottom-color: rgba(12,12,10,.35); }
.sbar.active .sbar-lbl { border-bottom-color: var(--ink); }


/* ══ COMPACT BAR (scrolled / project pages) ════════════════ */

#compact-bar {
  position: fixed;
  left: 0; top: calc(var(--top-h) + var(--bf-h));
  z-index: 901;
  background: var(--ink);
  height: auto;
  display: flex;
  flex-wrap: wrap;
  align-items: stretch;
  padding: 0 0 4px;
  gap: 0;
  width: 100%;
  opacity: 0;
  pointer-events: none;
  transition: top .34s var(--ease), opacity .2s;
}

#compact-bar.show   { opacity: 1; pointer-events: auto; }
#compact-bar.pinned { top: var(--bf-h); }
#compact-nav        { display: contents; }

.cbar-item {
  height: var(--bar-h);
  display: inline-flex;
  align-items: center;
  font-family: var(--fi);
  font-variation-settings: 'wght' 700;
  font-size: 18px;
  color: var(--y);
  text-transform: lowercase;
  white-space: nowrap;
  background: none;
  border: none;
  cursor: pointer;
  padding: 0 16px;
  flex: 0 0 auto;
  opacity: 0;
  pointer-events: none;
  transition: opacity .2s;
}

.cbar-item.active {
  opacity: 1;
  pointer-events: auto;
  cursor: default;
}

.cbar-lbl { border-bottom: 2px solid transparent; transition: border-bottom-color .18s; }
.cbar-item.active .cbar-lbl { border-bottom-color: var(--y); }

/* Project pages: compact-bar always visible, nav on top */
body[data-page="project"] #compact-bar { opacity: 1; pointer-events: auto; }
body[data-page="project"] #nav         { z-index: 902; }


/* ══ PREV / NEXT PROJECT NAV (bottom of project page) ══════ */

#proj-nav {
  display: ruby;
  /*! align-items: ; */
  justify-content: space-between;
  width: 100%;
  /*! border-top: 1px solid rgba(255,255,255,.1); */
  margin-top: clamp(48px, 8vw, 96px);
  margin-left: clamp(28px, 8vw, 16px);
}

.proj-nav-link {
  font-family: var(--fi);
  font-variation-settings: 'wght' 700;
  font-size: clamp(13px, 1.6vw, 17px);
  color: var(--y);
  text-decoration: none;
  letter-spacing: 0;
  text-transform: lowercase;
  transition: opacity .15s;
  white-space: nowrap;
  opacity: .55;
  display: flex;
  flex-direction: column;
  gap: 4px;
  padding: clamp(20px, 3vw, 36px) clamp(16px, 3vw, 32px);
}

.proj-nav-link:hover   { opacity: 1; }
.proj-nav-link.disabled{ pointer-events: none; opacity: 0; }

.proj-nav-link.proj-nav-prev { text-align: left; }
.proj-nav-link.proj-nav-next { text-align: right; margin-left: auto; }

.pnl-dir {
  font-size: clamp(11px, 1.2vw, 13px);
  opacity: .5;
  letter-spacing: .06em;
  text-transform: uppercase;
  font-variation-settings: 'wght' 500;
}

.pnl-title {
  font-size: clamp(14px, 1.8vw, 20px);
  font-variation-settings: 'wght' 800;
  opacity: 1;
  color: var(--y);
}


/* ══ SHUFFLE OVERLAY ═══════════════════════════════════════ */

#shuffle-overlay {
  position: fixed;
  inset: 0;
  z-index: 950;
  display: flex;
  align-items: center;
  justify-content: center;
  pointer-events: none;
  background: rgba(12,12,10,.85);
}

#shuffle-overlay.off { display: none; }

#shuffle-img {
  max-width: min(60vw, 700px);
  max-height: 64vh;
  object-fit: contain;
  filter: brightness(0) saturate(100%) invert(99%) sepia(100%) saturate(1000%) hue-rotate(0deg) brightness(103%);
}


/* ══ FOOTER ════════════════════════════════════════════════ */

footer {
  position: fixed;
  bottom: 0; left: 0; right: 0;
  z-index: 800;
  height: var(--foot-h);
  background: var(--y);
  display: flex;
  align-items: center;
  padding: 0 16px;
  transition: transform .36s var(--ease);
}

footer.hidden { transform: translateY(100%); }

.fcopy {
  font-family: var(--fi);
  font-variation-settings: 'wght' 600;
  font-size: 12px;
  color: rgba(12,12,10,0);
  transition: color .3s;
  user-select: none;
  letter-spacing: .01em;
}

footer:hover .fcopy { color: rgba(12,12,10,.55); }

.footer-credits {
  margin-left: auto;
  font-family: var(--fi);
  font-variation-settings: 'wght' 600;
  font-size: 12px;
  color: rgba(12,12,10,.45);
  letter-spacing: .01em;
  text-decoration: none;
  border-bottom: 1px solid transparent;
  transition: color .18s, border-bottom-color .18s;
}

.footer-credits:hover { color: var(--ink); border-bottom-color: var(--ink); }
.footer-credits.on    { color: var(--ink); border-bottom-color: var(--ink); }

/* Sound control */
.sound-ctrl {
  margin-left: 16px;
  display: flex;
  align-items: center;
  gap: 8px;
  cursor: pointer;
  color: rgba(12,12,10,.6);
  transition: color .2s;
}

.sound-ctrl:hover { color: var(--ink); }

.sico {
  display: flex;
  align-items: center;
  gap: 2px;
  height: 13px;
}

.sb {
  width: 2px;
  background: currentColor;
  border-radius: 1px;
}

#sbtn.off .sico { opacity: .38; }
#sbtn.off .sb   { height: 2px !important; animation: none !important; }

.sb:nth-child(1) { height: 5px;  animation: sba 1.1s ease-in-out 0s   infinite; }
.sb:nth-child(2) { height: 10px; animation: sba 1.1s ease-in-out .2s  infinite; }
.sb:nth-child(3) { height: 7px;  animation: sba 1.1s ease-in-out .4s  infinite; }
.sb:nth-child(4) { height: 4px;  animation: sba 1.1s ease-in-out .6s  infinite; }

@keyframes sba {
  0%, 100% { transform: scaleY(1);   }
  50%       { transform: scaleY(.25); }
}

.slbl {
  font-family: var(--fi);
  font-variation-settings: 'wght' 700;
  font-size: 11px;
  letter-spacing: .08em;
  text-transform: uppercase;
}


/* ══ MAIN ══════════════════════════════════════════════════ */

main { position: relative; }


/* ══ MASONRY GRID ══════════════════════════════════════════ */

#grid-outer { position: relative; }

.masonry {
  display: flex;
  gap: var(--grid-gap);
  align-items: flex-start;
  padding-top: 28px;
}

.mc {
  flex: 1 1 0;
  display: flex;
  flex-direction: column;
  gap: var(--grid-gap);
  min-width: 0;
}


/* ══ STANDARD CARD ═════════════════════════════════════════ */

@keyframes cin {
  from { opacity: 0; transform: translateY(12px); }
  to   { opacity: 1; transform: none; }
}

.card {
  cursor: default;
  display: block;
  position: relative;
  overflow: hidden;
  animation: cin .3s var(--ease) both;
  flex-shrink: 0;
}

.card.has-page { cursor: pointer; }

.card img.cimg {
  display: block;
  width: 100%;
  height: auto;
  vertical-align: top;
}

div.cimg {
  display: block;
  width: 100%;
  background: rgba(255,255,255,.05);
}

div.cimg.portrait  { aspect-ratio: 3/4; }
div.cimg.square    { aspect-ratio: 1;   }
div.cimg.landscape { aspect-ratio: 4/3; }
div.cimg.wide      { aspect-ratio: 16/9;}

/* Grid focus — dim all cards except hovered one */
#grid-outer.grid-focus .card {
  opacity: 0.32;
  filter: brightness(0.6);
  transition: opacity .2s var(--ease), filter .2s var(--ease);
  will-change: opacity, filter;
}

#grid-outer.grid-focus .card.card-focus {
  opacity: 1;
  filter: none;
}

/* Remove will-change when grid is not focused (save GPU) */
#grid-outer:not(.grid-focus) .card {
  will-change: auto;
}

/* Video indicator triangle */
.vdot {
  position: absolute;
  top: 0; right: 0;
  width: 0; height: 0;
  border-style: solid;
  border-width: 0 20px 20px 0;
  border-color: transparent rgba(0,0,0,.5) transparent transparent;
  pointer-events: none;
}

.vdot::after {
  content: '▶';
  position: absolute;
  top: 2px; right: -17px;
  font-size: 6px;
  color: rgba(255,255,255,.9);
}


/* ══ NEWS / TODAY CARD ══════════════════════════════════════ */

.card-news {
  break-inside: avoid;
  -webkit-column-break-inside: avoid;
  display: block;
  margin-bottom: 3px;
  animation: cin .3s var(--ease) both;
  cursor: default;
  background: #fbffde;
}

.card-news.has-page { cursor: pointer; }

.card-news img.cimg {
  display: block;
  width: 100%;
  height: auto;
  vertical-align: top;
}

.card-news-body     { padding: 14px 16px 18px; }
.card-news-date     { font-family: var(--fi); font-variation-settings: 'wght' 400; font-size: 13px; color: rgba(12,12,10,.4); letter-spacing: .02em; margin-bottom: 10px; display: block; }
.card-news-title    { font-family: var(--fi); font-variation-settings: 'wght' 700; font-size: 19px; line-height: 1.25; color: var(--ink); margin-bottom: 7px; }
.card-news-desc     { font-family: var(--fi); font-variation-settings: 'wght' 400; font-size: 19px; line-height: 1.72; color: rgba(12,12,10,.62); margin-bottom: 12px; line-height: 1.3;}
.card-news-link     { font-family: var(--fi); font-variation-settings: 'wght' 400; font-size: 19px; color: #1A1A1A75; text-decoration: underline; text-underline-offset: 3px; text-decoration-thickness: 1px; letter-spacing: .01em; display: inline-block; }
.card-news-link:hover { text-decoration-thickness: 2px; }


/* ══ HOVER PANEL ═══════════════════════════════════════════ */

#hp {
  position: absolute;
  z-index: 60;
  pointer-events: auto;
  display: none;
  flex-direction: column;
  background: var(--bg);
}

#hp.show { display: flex; }

.hp-img {
  display: block;
  width: 100%;
  height: auto;
  flex-shrink: 0;
  object-fit: cover;
}

.hp-img.portrait  { aspect-ratio: 3/4; }
.hp-img.square    { aspect-ratio: 1/1; }
.hp-img.landscape { aspect-ratio: 4/3; }
.hp-img.wide      { aspect-ratio: 16/9;}

.hp-img-bg { display: block; width: 100%; flex-shrink: 0; background: rgba(255,255,255,.04); }
.hp-img-bg.portrait  { aspect-ratio: 3/4; }
.hp-img-bg.square    { aspect-ratio: 1;   }
.hp-img-bg.landscape { aspect-ratio: 4/3; }
.hp-img-bg.wide      { aspect-ratio: 16/9;}

.hp-cap {
  background: rgba(12,12,10,.92);
  padding: 10px 14px 12px;
  display: flex;
  align-items: baseline;
  flex-wrap: wrap;
}

.hp-title {
  font-family: var(--fi);
  font-variation-settings: 'wght' 800;
  font-size: 16px;
  line-height: 1.1;
  margin-right: 10px;
  flex-shrink: 0;
  color: #fff;
  letter-spacing: -.02em;
}

.hp-meta {
  font-size: 12px;
  font-variation-settings: 'wght' 700;
  color: rgba(255,255,0,1);
  line-height: 1.5;
}

.hp-meta span + span::before { content: ' · '; }

/* Eye cursor (SVG object) */
#vp-cursor {
  position: fixed;
  pointer-events: none;
  z-index: 999;
  opacity: 0;
  transition: opacity .18s;
  will-change: left, top;
}

#vp-cursor.show { opacity: 1; }

#vp-cursor object {
  display: block;
  width: 116px;
  height: auto;
  pointer-events: none;
}

/* Hide system cursor on clickable cards */
.card.has-page,
#hp.has-page       { cursor: none; }
body.vp-active,
body.vp-active *   { cursor: none !important; }
#hp.has-page       { cursor: pointer; }


/* ══ PROJECT VIEW ══════════════════════════════════════════ */

.proj-wrap { padding-bottom: 60px; }

/* Swiper */
.swiper       { position: relative; width: 100%; overflow: hidden; background: rgba(255,255,255,.03); }
.sw-track     { display: flex; transition: transform .42s cubic-bezier(.4,0,.2,1); }
.slide        { flex: 0 0 100%; margin-top: 0px;}

.slide-img    { display: block; width: 100%; aspect-ratio: unset; object-fit: contain; max-height: 55vh; }
.slide-img-bg { display: block; width: 100%; aspect-ratio: 16/9; background: rgba(255,255,255,.04); }
.slide-cap    { padding: 13px 22px 16px; background: rgba(0,0,0,.5); }
.slide-cap-txt{ font-variation-settings: 'wght' 400; font-size: 14px; color: rgba(255,255,255,.4); line-height: 1.7; }

.sw-btn {
  position: absolute;
  top: 0; bottom: 0;
  z-index: 10;
  width: 40px;
  color: var(--y);
  display: flex;
  align-items: center;
  justify-content: center;
  font-variation-settings: 'wght' 700;
  font-size: 18px;
  transition: background .15s;
}

.sw-btn:hover { background: rgba(0,0,0,.7); }
.sw-prev      { left: 0; }
.sw-next      { right: 0; }

.sw-dots { display: flex; justify-content: center; gap: 5px; padding: 10px 0 0; }
.sw-dot  { width: 5px; height: 5px; border-radius: 50%; background: rgba(255,255,255,.18); transition: background .2s, transform .2s; }
.sw-dot.on { background: var(--y); transform: scale(1.3); }

/* Project header */
.proj-hd {
  padding: clamp(20px, 4vw, 16px) clamp(18px, 5vw, 64px) 0;
}

.proj-title {
  font-family: var(--fi);
  font-variation-settings: 'wght' 400;
  font-size: clamp(35px, 6vw, 55px);
  line-height: .92;
  letter-spacing: .01em;
  margin-bottom: 15px;
  color: #f3f202;
  margin-left: -4px;
}

.proj-subtitle {
  font-variation-settings: 'wght' 400;
  font-size: clamp(14px, 2vw, 18px);
  color: rgb(112, 115, 117);
  margin-bottom: 22px;
  line-height: 1.3;
}

.proj-meta    { display: flex; flex-wrap: wrap; gap: 18px 40px;/*! grid-row-end: 20px; */}
.pmi-l        { font-size: 11px; font-variation-settings: 'wght' 500; color: rgba(255,255,255,.28); margin-bottom: -6px; display: block; letter-spacing: .06em; text-transform: uppercase; }
.pmi-v        { font-variation-settings: 'wght' 600; font-size: 16px; color: #fff; }

/* Content blocks */
.blocks       { padding: clamp(22px, 4vw, 48px) clamp(18px, 5vw, 64px); }
.block        { margin-bottom: clamp(20px, 3vw, 25px); width: auto;max-width: 700px;}
.block-text   { font-variation-settings: 'wght' 400; font-size: 16px; line-height: 1.9; color: rgba(255,255,255,.55); max-width: 580px; }
.block a {
  color: yellow;
  text-decoration: underline;
}
.block a:hover {
  color: yellow;
  text-decoration: none;
}
.block a:visited {
  color: grey;
  text-decoration: underline;
}
.block-text strong { font-variation-settings: 'wght' 600; color: #fff; }
.block-text p + p  { margin-top: .9em; }
.block-hd     { font-family: var(--fi); font-variation-settings: 'wght' 800; font-size: clamp(20px, 3.2vw, 38px); line-height: 1; letter-spacing: -.025em; margin-bottom: 10px; color: #fff; }
.bimg         { display: block; width: 100%; max-width: 840px; }
.bimg img,
.bimg-ph      { display: block; width: 100%; height: auto;}
.bimg-ph      { aspect-ratio: 3/2; background: rgba(255,255,255,.04); }
.bcap         { font-size: 14px; font-variation-settings: 'wght' 600; color: rgb(110, 110, 110); margin-top: 7px; margin-left: 4px;}

.b2col { display: grid; grid-template-columns: 1fr 1fr; gap: 4px; max-width: 840px; }
@media(max-width:600px){ .b2col{ grid-template-columns: 1fr; } }
.b2col-item img,
.b2col-ph { display: block; width: 100%; aspect-ratio: 4/3; object-fit: cover; }
.b2col-ph { background: rgba(255,255,255,.04); }

/* Goods block */
.bgoods     { /*! color: #fff; */ /*! padding: clamp(18px,3vw,32px) clamp(18px,5vw,64px) clamp(22px,4vw,42px); */ /*! background: rgba(255,255,255,.04); */ }
.bgoods-h   { font-family: var(--fi); font-variation-settings: 'wght' 800; font-size: clamp(18px,3vw,32px); letter-spacing: -.02em; color: var(--y); margin-bottom: 14px; }
.bgoods-g   { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 6px; }
.bgoods-i   { padding: 12px 0px 15px; /*! border: 1px solid rgba(255,255,255,.06); */ transition: border-color .2s; }
.bgoods-i:hover { border-color: rgba(255,254,3,.3); }
.bgoods-n   { font-variation-settings: 'wght' 600; font-size: 14px; color: rgba(255,255,255,.85); margin-bottom: 3px; }
.bgoods-f   { font-variation-settings: 'wght' 600; font-size: 14px; color: rgba(255, 255, 255, 0.4); margin-bottom: 7px; }
.bgoods-p   { font-family: var(--fi); font-variation-settings: 'wght' 700; font-size: 16px; color: var(--y); margin-bottom: 8px; }
.bgoods-btn { font-family: var(--fi); font-variation-settings: 'wght' 600; font-size: 11px; background: var(--y); color: var(--ink); padding: 7px 13px; transition: opacity .2s; cursor: pointer; border: none; }
.bgoods-btn:hover { opacity: .8; }

.bgoods-thumb { display: block; width: 100%; height: auto; object-fit: contain; margin-bottom: 10px; background: rgba(255,255,255,.02); }
.bgoods-ed    { font-variation-settings: 'wght' 500; font-size: 11px; color: rgba(255,255,255,.3); margin-bottom: 4px; letter-spacing: .03em; }
.bgoods-desc  { font-variation-settings: 'wght' 400; font-size: 12px; color: rgba(255,255,255,.35); line-height: 1.5; margin-bottom: 8px; }

/* Payment link — real <a> styled as button */
a.bgoods-btn  { display: inline-block; text-decoration: none; text-align: center; }

/* Disabled (no payment link yet) */
.bgoods-btn--disabled { opacity: .35; cursor: default; pointer-events: none; }

/* Sold out */
.bgoods-i--sold { opacity: .45; }
.bgoods-btn--sold { background: transparent; color: rgba(255,255,255,.3); border: 1px solid rgba(255,255,255,.1); cursor: default; pointer-events: none; }

/* Quote block */
.block-quote { border-left: 3px solid var(--y); padding: 2px 0 2px 20px; max-width: 540px; }
.bq-text     { font-variation-settings: 'wght' 500; font-size: clamp(16px, 2.2vw, 22px); line-height: 1.55; color: rgba(255,255,255,.7); font-style: italic; }
.bq-cite     { font-variation-settings: 'wght' 400; font-size: 12px; color: rgba(255,255,255,.3); margin-top: 8px; display: block; font-style: normal; letter-spacing: .04em; }
.block-line  { border: none; border-top: 1px solid rgba(255,255,255,.08); margin: 0; }


/* ══ BIO / CONTACT ═════════════════════════════════════════ */

#view-biocont {
  background: var(--y);
  min-height: 100vh;
  padding: 0 0 80px;
}

/* Full-width page header */
.bio-header {
  padding: clamp(40px, 6vw, 80px) clamp(16px, 5vw, 42px) 0;
  max-width: 1400px;
  margin-top: 20px;
}

.bio-name {
  font-family: var(--fi);
  font-variation-settings: 'wght' 500;
  font-size: clamp(38px, 7vw, 90px);
  line-height: .9;
  letter-spacing: 0.0001em;
  color: var(--ink);
  margin-bottom: clamp(14px, 2vw, 22px);
  padding-left: -0.5px;
}

.bio-tagline {
  font-family: var(--fi);
  font-variation-settings: 'wght' 400;
  font-size: clamp(15px, 2vw, 30px);
  line-height: 1.4;
  color: rgba(12,12,10,.62);
  margin-bottom: clamp(28px, 4vw, 48px);
  margin-left: 5px;
}


/* Two-column body — bio left, facts right */
.bio-body {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: clamp(32px, 5vw, 80px);
  padding: clamp(32px, 4vw, 56px) clamp(16px, 5vw, 48px) 0;
  max-width: 1400px;
  align-items: start;
}

.bio-left  { max-width: 600px; }
.bio-right { padding-top: 4px; }

@media(max-width:820px) {
  .bio-body  { grid-template-columns: 1fr; }
  .bio-left,
  .bio-right { max-width: 600px; }
}

/* Bio block text (Kirby blocks) */
.bio-block {
  font-family: var(--fi);
  font-variation-settings: 'wght' 700;
  font-size: clamp(14px, 1.6vw, 17px);
  line-height: 1.3;
  color: var(--ink);
  margin-bottom: clamp(18px, 3vw, 30px);
}

.bio-block *        { color: var(--ink); }
.bio-block p        { margin-bottom: .8em; }
.bio-block p:last-child { margin-bottom: 0; }
.bio-block strong   { font-variation-settings: 'wght' 700; color: var(--ink); }
.bio-block a        { color: var(--ink); text-decoration: underline; text-underline-offset: 3px; text-decoration-color: rgba(12,12,10,.35); }
.bio-block a:hover  { text-decoration-color: var(--ink); }
.bio-block ul,
.bio-block ol       { padding-left: 1.4em; }
.bio-block li       { margin-bottom: .3em; }

/* Bio heading hierarchy */
.bio-hd       { font-family: var(--fi); color: var(--ink); /*! margin-top: clamp(28px,4vw,48px); */ margin-bottom: .45em; line-height: 1.05; letter-spacing: -.02em; }
.bio-hd--h2   { font-variation-settings: 'wght' 800; font-size: clamp(22px,3.5vw,38px); letter-spacing: -.03em; }
.bio-hd--h3   { font-variation-settings: 'wght' 700; font-size: clamp(17px,2.4vw,26px); letter-spacing: -.02em; }
.bio-hd--h4   { font-variation-settings: 'wght' 600; font-size: clamp(26px,1.8vw,20px); letter-spacing: .04em; /*! text-transform: uppercase; */ color: var(--y); background: var(--ink); /*! display: inline-block; */ /*! padding: 2px 7px; */ /*! margin-bottom: 0; */}


/* Bio photos */
.bio-photo {
  display: block;
  width: 100%;
  height: auto;
  margin-bottom: clamp(4px, 1vw, 8px);
}

/* Contact strip */
.bio-contact-strip {
  margin-top: clamp(32px, 5vw, 56px);
  padding-top: clamp(20px, 3vw, 28px);
  border-top: 1px solid rgba(12,12,10,.2);
  display: flex;
  align-items: baseline;
  flex-wrap: wrap;
  gap: 12px 32px;
}

.bio-contact-lbl {
  font-family: var(--fi);
  font-variation-settings: 'wght' 700;
  font-size: 11px;
  letter-spacing: .08em;
  text-transform: uppercase;
  color: rgba(12,12,10,.35);
}

.bio-contact-email {
  font-family: var(--fi);
  font-variation-settings: 'wght' 500;
  font-size: 16px;
  color: var(--ink);
  border-bottom: 1px solid rgba(12,12,10,.3);
  transition: border-color .2s;
}

.bio-contact-email:hover { border-color: var(--ink); }

/* Biblio / Expo facts lists */
.facts-section { margin-bottom: clamp(40px, 6vw, 72px); }

.facts-title {
  font-family: var(--fi);
  font-variation-settings: 'wght' 600;
  font-size: clamp(20px, 2.8vw, 22px);
  line-height: 1;
  letter-spacing: 0.01em;
  color: var(--ink);
  margin-bottom: clamp(16px, 2.5vw, 28px);
}

.facts-list { list-style: none; padding: 0; margin: 0; }

.fact-item {
  display: grid;
  grid-template-columns: 48px 1fr;
  gap: 0 12px;
  padding: 6px 0;
  border-top: 1px solid rgba(12,12,10,.15);
  align-items: baseline;
}

.fact-item:last-child { border-bottom: 1px solid rgba(12,12,10,.15); }

.fact-year {
  font-family: var(--fi);
  font-variation-settings: 'wght' 700;
  font-size: clamp(12px, 1.3vw, 14px);
  color: var(--ink);
  white-space: nowrap;
  padding-top: .15em;
}

.fact-text {
  font-family: var(--fi);
  font-variation-settings: 'wght' 400;
  font-size: clamp(13px, 1.4vw, 15px);
  line-height: 1.5;
  color: var(--ink);
}

.fact-text p       { display: inline; margin: 0; }
.fact-text em      { font-style: italic; }
.fact-text strong  { font-variation-settings: 'wght' 700; }
.fact-text a,
.fact-link         { color: var(--ink); text-decoration: underline; text-underline-offset: 4px; text-decoration-color: rgba(12,12,10,.3); }
.fact-text a:hover,
.fact-link:hover   { text-decoration-color: var(--ink); }


/* ══ CREDITS ═══════════════════════════════════════════════ */

.credits-page  { background: var(--y); min-height: 100vh; padding: 0 0 80px; }
.credits-inner { padding: clamp(30px,5vw,60px) clamp(18px,6vw,44px); max-width: 680px; }

.credits-back  { display: inline-block; font-family: var(--fi); font-variation-settings: 'wght' 500; font-size: 12px; color: rgba(12,12,10,.45); margin-bottom: 32px; transition: color .2s; }
.credits-back:hover  { color: var(--ink); }
.credits-title { font-family: var(--fi); font-variation-settings: 'wght' 500; font-size: clamp(28px,5vw,60px); line-height: .92; letter-spacing: 0.000000001em; color: var(--ink); margin-bottom: 32px; margin-top: 60px;}

.credits-body  { font-family: var(--fi); font-variation-settings: 'wght' 700; font-size: 24px; line-height: 1.5; color: rgba(12,12,10,.65); margin-left: 4px;}

.credits-body a{ color: var(--ink); text-decoration: underline; text-underline-offset: 3px; }


/* ══ LAYOUT GRID (Kirby layout field) ═════════════════════ */

.layout-row {
  display: grid;
  gap: var(--grid-gap);
  margin-bottom: clamp(4px, 0.5vw, 8px);
}

/* Column widths — Kirby fractions mapped to grid */
.layout-row[data-cols="1"]   { grid-template-columns: 1fr; }
.layout-row[data-cols="1/2,1/2"]   { grid-template-columns: 1fr 1fr; }
.layout-row[data-cols="1/3,2/3"]   { grid-template-columns: 1fr 2fr; }
.layout-row[data-cols="2/3,1/3"]   { grid-template-columns: 2fr 1fr; }
.layout-row[data-cols="1/3,1/3,1/3"] { grid-template-columns: 1fr 1fr 1fr; }
.layout-row[data-cols="1/4,3/4"]   { grid-template-columns: 1fr 3fr; }
.layout-row[data-cols="3/4,1/4"]   { grid-template-columns: 3fr 1fr; }
.layout-row[data-cols="1/4,1/4,1/2"] { grid-template-columns: 1fr 1fr 2fr; }
.layout-row[data-cols="1/2,1/4,1/4"] { grid-template-columns: 2fr 1fr 1fr; }

.layout-col {
  min-width: 0;
}

/* Blocks inside layout columns inherit spacing */
.layout-col .block        { margin-bottom: clamp(12px, 2vw, 20px); }
.layout-col .block:last-child { margin-bottom: 0; }

@media(max-width:680px) {
  .layout-row[data-cols] { grid-template-columns: 1fr; }
}


/* ══ ENHANCED IMAGE BLOCK ═════════════════════════════════ */

.bimg--small  { max-width: 480px; }
.bimg--medium { max-width: 700px; }
.bimg--large  { max-width: 840px; }
.bimg--full   { max-width: 100%; }
.bimg--center { margin-left: auto; margin-right: auto; }


/* ══ ENHANCED GALLERY BLOCK ═══════════════════════════════ */

.bgallery {
  display: grid;
  gap: var(--grid-gap);
  max-width: 840px;
}

.bgallery--cols-2 { grid-template-columns: repeat(2, 1fr); }
.bgallery--cols-3 { grid-template-columns: repeat(3, 1fr); }
.bgallery--cols-4 { grid-template-columns: repeat(4, 1fr); }

.bgallery-item {
  position: relative;
  overflow: hidden;
}

.bgallery-item img {
  display: block;
  width: 100%;
  height: auto;
  object-fit: cover;
}

/* Ratio overrides on gallery images */
.bgallery--ratio-square img    { aspect-ratio: 1; }
.bgallery--ratio-43 img        { aspect-ratio: 4/3; }
.bgallery--ratio-169 img       { aspect-ratio: 16/9; }
.bgallery--ratio-original img  { aspect-ratio: auto; }

.bgallery-cap {
  font-family: var(--fi);
  font-variation-settings: 'wght' 400;
  font-size: 12px;
  color: rgba(255,255,255,.3);
  margin-top: 6px;
}

/* Mobile: 2-col max, then stack */
@media(max-width:680px) {
  .bgallery--cols-3,
  .bgallery--cols-4 { grid-template-columns: repeat(2, 1fr); }
}
@media(max-width:420px) {
  .bgallery[class*="bgallery--cols"] { grid-template-columns: 1fr; }
}


/* ══ VIDEO BLOCK ══════════════════════════════════════════ */

.bvideo {
  position: relative;
  max-width: 840px;
  background: var(--ink);
}

.bvideo-wrap {
  position: relative;
  width: 100%;
  aspect-ratio: 16/9;
  overflow: hidden;
  background: #000;
}

.bvideo-wrap iframe,
.bvideo-wrap video {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  border: none;
}

.bvideo-wrap video {
  object-fit: contain;
  background: #000;
}

.bvideo-cap {
  font-family: var(--fi);
  font-variation-settings: 'wght' 400;
  font-size: 12px;
  color: rgba(255,255,255,.3);
  padding: 8px 0 0;
}


/* ══ SOUND BLOCK ══════════════════════════════════════════ */

.bsound {
  max-width: 700px;
  background: rgba(255,255,255,.04);
  padding: 16px 20px;
}

.bsound-row {
  display: flex;
  align-items: center;
  gap: 14px;
}

.bsound-play {
  flex-shrink: 0;
  width: 36px;
  height: 36px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--y);
  color: var(--ink);
  border: none;
  cursor: pointer;
  font-size: 14px;
  transition: opacity .15s;
}

.bsound-play:hover { opacity: .8; }

.bsound-info {
  flex: 1;
  min-width: 0;
}

.bsound-title {
  font-family: var(--fi);
  font-variation-settings: 'wght' 700;
  font-size: 14px;
  color: #fff;
  margin-bottom: 2px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.bsound-progress {
  position: relative;
  width: 100%;
  height: 3px;
  background: rgba(255,255,255,.1);
  cursor: pointer;
  margin-top: 6px;
}

.bsound-bar {
  position: absolute;
  left: 0; top: 0;
  height: 100%;
  background: var(--y);
  width: 0%;
  transition: width .1s linear;
}

.bsound-time {
  flex-shrink: 0;
  font-family: var(--fi);
  font-variation-settings: 'wght' 500;
  font-size: 11px;
  color: rgba(255,255,255,.35);
  letter-spacing: .04em;
  min-width: 36px;
  text-align: right;
}

.bsound-cap {
  font-family: var(--fi);
  font-variation-settings: 'wght' 400;
  font-size: 12px;
  color: rgba(255,255,255,.3);
  margin-top: 8px;
}


/* ══ BF PORTAL BAR (Bulbfactory) ══════════════════════════ */

:root { --bf-h: 28px; }

.bf-portal-container {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 999;
  height: var(--bf-h);
}

.bf-portal {
  height: var(--bf-h);
  background: #fff;
  display: flex;
  align-items: center;
  padding: 0 16px;
  position: relative;
}

#bf-background {
  position: absolute;
  inset: 0;
  background: #FFFFE3;
  z-index: 0;
}

.bf-logo {
  position: relative;
  z-index: 1;
  display: inline-flex;
  align-items: center;
  gap: 7px;
  font-family: var(--fi);
  font-variation-settings: 'wght' 700;
  font-size: 12.2px;
  color: var(--ink);
  text-decoration: none;
  letter-spacing: .03em;
  transition: opacity .15s;
  text-transform: uppercase;
  color: red;
}

.bf-logo:hover { opacity: .55; }

.bf-logo svg {
  display: block;
  flex-shrink: 0;
}

.bf-portal-content {
  display: inline-flex;
  align-items: center;
  gap: 13px;
  /*! background: #FFFFE3; */
}

#bf-close {
  position: absolute;
  right: 12px; top: 50%;
  transform: translateY(-50%);
  z-index: 1;
  width: 18px; height: 18px;
  background: none;
  border: none;
  cursor: pointer;
  opacity: .3;
  transition: opacity .15s;
}

#bf-close:hover { opacity: .8; }

#bf-close::before,
#bf-close::after {
  content: '';
  position: absolute;
  left: 50%; top: 50%;
  width: 12px; height: 1px;
  background: var(--ink);
}

#bf-close::before { transform: translate(-50%, -50%) rotate(45deg); }
#bf-close::after  { transform: translate(-50%, -50%) rotate(-45deg); }

/* Push nav + nav-shield down by bf-bar height */
#nav-shield { top: var(--bf-h); }
#nav        { top: var(--bf-h); }

/* When bf-portal is closed */
.bf-portal-container.closed {
  display: none;
}

.bf-portal-container.closed ~ #nav-shield,
.bf-portal-container.closed ~ #nav {
  top: 0;
}


/* ══ RESPONSIVE ════════════════════════════════════════════ */

/* Grid gap scale-up on large screens */
@media(min-width:1100px) {
  :root { --grid-gap: 4px; }
}

/* Mobile nav alignment — bars align with logo padding */
@media(max-width:560px) {
  .topbar     { padding: 0 16px; }
  #bars       { padding-left: 0; }
  .sbar       { padding: 0 10px; }
  .sbar:first-child { padding-left: 16px; }
  .sbar-lbl   { font-size: 15px; }

  #compact-bar          { padding-left: 0; }
  .cbar-item            { padding: 0 10px; font-size: 15px; }
  .cbar-item:first-child { padding-left: 16px; }
}

@media(max-width:380px) {
  .sbar       { padding: 0 7px; }
  .sbar:first-child { padding-left: 16px; }
  .sbar-lbl   { font-size: 13px; }

  .cbar-item  { padding: 0 7px; font-size: 13px; }
  .cbar-item:first-child { padding-left: 16px; }
}
