/* brucesvenson.com.au — V3 homepage: one cinematic world.
   Modes on <html>: .m3d (desktop WebGL world) · .mfilm (cinematic stills) · none (static reading version).
   Tokens from 04_VISUAL_AND_MOTION_SPEC.md. */

:root {
  --charcoal: #101617;
  --ink: #111719;
  --warm-white: #F5F1E9;
  --muted: #C4CAC5;
  --gold: #E3BD7F;
  --cream: #F2EEE5;
  --forest: #254742;
  --sage: #89B99F;
  --ink-soft: #3d4644;
  --gold-deep: #7a5a24;
  --line-dark: rgba(245, 241, 233, .12);
  --line-cream: rgba(17, 23, 25, .14);
  --sans: Arial, Helvetica, sans-serif;
  --serif: Georgia, "Times New Roman", serif;
  --ease: cubic-bezier(.22, .61, .36, 1);
  --header-h: 76px;
  --gutter: 48px;
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-padding-top: calc(var(--header-h) + 12px); -webkit-text-size-adjust: 100%; }
body {
  margin: 0; background: var(--charcoal); color: var(--warm-white);
  font-family: var(--sans); font-size: 18px; line-height: 1.6;
  -webkit-font-smoothing: antialiased; overflow-x: hidden;
}
img, svg, video, canvas { display: block; max-width: 100%; }
img { height: auto; }
h1, h2, h3 { margin: 0 0 .55em; font-weight: 700; letter-spacing: -0.015em; }
p { margin: 0 0 1em; }
a { color: inherit; }
figure { margin: 0; }

:focus-visible { outline: 3px solid var(--gold); outline-offset: 3px; border-radius: 2px; }
.beat--life :focus-visible, .beat--final :focus-visible { outline-color: var(--ink); }

.skip-link { position: absolute; left: 16px; top: -100px; z-index: 300; background: var(--gold); color: var(--ink); padding: .8rem 1.2rem; border-radius: 6px; font-weight: 700; text-decoration: none; }
.skip-link:focus { top: 12px; }

.wrap { width: 100%; max-width: calc(1240px + 2 * var(--gutter)); margin: 0 auto; padding: 0 var(--gutter); }
.eyebrow { font-size: 14px; font-weight: 700; letter-spacing: .14em; color: var(--gold); margin: 0 0 1rem; }

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; text-align: center;
  min-height: 48px; padding: .75rem 1.4rem; border-radius: 6px; border: 2px solid transparent;
  font: 700 15px/1.25 var(--sans); letter-spacing: .04em; text-decoration: none; cursor: pointer;
  transition: transform .18s var(--ease), background-color .18s var(--ease), box-shadow .18s var(--ease);
}
.btn:hover { transform: translateY(-1px); }
.btn-lg { min-height: 52px; padding: .9rem 1.6rem; font-size: 16px; }
.btn-gold { background: var(--gold); color: var(--ink); box-shadow: 0 10px 30px -12px rgba(227, 189, 127, .6); }
.btn-gold:hover { background: #ebc98f; }
.btn-ink { background: var(--ink); color: var(--warm-white); }
.btn-ink:hover { background: #22302f; }
.btn-outline { border-color: var(--ink); color: var(--ink); background: transparent; }
.btn-outline:hover { background: rgba(17, 23, 25, .06); }
.text-link { display: inline-block; color: var(--warm-white); font-weight: 700; text-decoration: none; border-bottom: 2px solid rgba(227, 189, 127, .6); padding: .35rem 0 .15rem; margin-top: .4rem; }
.text-link:hover { border-bottom-color: var(--gold); }

/* ---------- Header ---------- */
.site-header {
  position: sticky; top: 0; z-index: 100; height: var(--header-h);
  background: rgba(16, 22, 23, .9); border-bottom: 1px solid var(--line-dark);
}
@supports (backdrop-filter: blur(8px)) { .site-header { background: rgba(16, 22, 23, .62); backdrop-filter: blur(14px) saturate(140%); } }
.header-inner { height: 100%; display: flex; align-items: center; justify-content: space-between; gap: 1.5rem; }
.wordmark { font-weight: 700; font-size: 17px; letter-spacing: .16em; text-decoration: none; color: var(--warm-white); white-space: nowrap; }
.nav { display: flex; align-items: center; }
.nav-panel { display: flex; align-items: center; gap: 2rem; }
.nav-links { display: flex; gap: 1.6rem; list-style: none; margin: 0; padding: 0; }
.nav-links a { display: inline-block; padding: .6rem 0; font-size: 15px; text-decoration: none; color: var(--muted); border-bottom: 2px solid transparent; }
.nav-links a:hover { color: var(--warm-white); border-bottom-color: var(--gold); }
.btn-nav { min-height: 48px; font-size: 14px; padding: .65rem 1.1rem; }
.menu-btn { display: none; min-height: 48px; min-width: 48px; padding: .6rem 1rem; background: transparent; color: var(--warm-white); border: 1px solid rgba(245, 241, 233, .35); border-radius: 6px; font: 700 15px var(--sans); cursor: pointer; }
@media (max-width: 1180px) { .nav-links { gap: 1.1rem; } .nav-panel { gap: 1.2rem; } }
@media (max-width: 1080px) {
  :root { --header-h: 64px; }
  .menu-btn { display: inline-flex; align-items: center; }
  .nav-panel {
    display: none; position: fixed; left: 0; right: 0; top: var(--header-h);
    flex-direction: column; align-items: stretch; gap: 1rem; padding: 1rem var(--gutter) 1.6rem;
    background: var(--charcoal); border-bottom: 1px solid var(--line-dark); max-height: calc(100vh - var(--header-h)); overflow-y: auto;
  }
  .nav-panel.open { display: flex; }
  .nav-links { flex-direction: column; gap: 0; }
  .nav-links a { display: block; padding: .9rem 0; font-size: 17px; color: var(--warm-white); border-bottom: 1px solid var(--line-dark); }
  .btn-nav { width: 100%; font-size: 15px; }
}

/* ---------- Copy styles (all modes) ---------- */
main { position: relative; z-index: 2; }
.beat h2 { font-size: clamp(29px, 3.2vw, 44px); line-height: 1.14; }
.beat h3 { font-size: clamp(21px, 1.8vw, 24px); line-height: 1.25; }
.panel p { color: var(--muted); }
.closing-line { color: var(--warm-white) !important; font-size: clamp(19px, 1.6vw, 21px); line-height: 1.5; font-weight: 700; margin-top: 1.4rem; }
.factors { list-style: none; padding: 0; margin: 1.4rem 0 0; display: flex; flex-wrap: wrap; gap: 8px; }
.factors li { font-size: 15px; line-height: 1.4; padding: .5rem .8rem; border-radius: 6px; border: 1px solid rgba(137, 185, 159, .35); background: rgba(37, 71, 66, .32); color: var(--warm-white); }
.path-icon { width: 44px; height: 44px; margin-bottom: 14px; }
.path-icon * { fill: none; stroke: var(--gold); stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.path-num, .step-num { color: var(--gold); }
.suited { padding-top: 1rem; border-top: 1px solid var(--line-dark); font-size: 15px; line-height: 1.5; }
.suited strong { color: var(--warm-white); }
.ticks { list-style: none; padding: 0; margin: 0 0 1.2rem; }
.ticks li { position: relative; padding: .3rem 0 .3rem 1.8rem; color: var(--warm-white); font-size: 17px; }
.ticks li::before { content: ''; position: absolute; left: 2px; top: .8rem; width: 12px; height: 7px; border-left: 2px solid var(--sage); border-bottom: 2px solid var(--sage); transform: rotate(-45deg); }
.epiphany { margin: 1.4rem 0 0; padding: .2rem 0 .2rem 1.3rem; border-left: 3px solid var(--gold); }
.epiphany p { font-family: var(--serif); font-style: italic; font-size: clamp(22px, 2.1vw, 28px); line-height: 1.42; color: var(--warm-white) !important; margin: 0; }
.callout-line { font-size: clamp(19px, 2vw, 24px); font-weight: 700; letter-spacing: .08em; color: var(--gold) !important; margin: 1.6rem 0 .8rem; }
.qualification { font-size: 15px; line-height: 1.5; border-left: 3px solid rgba(137, 185, 159, .6); padding-left: 1rem; margin-top: 1.2rem; }
.cta-support { font-size: 15px; line-height: 1.5; color: var(--muted); max-width: 46ch; margin: .9rem 0 0; }
figcaption { font-size: 14px; line-height: 1.5; color: var(--muted); margin-top: .6rem; }
.scroll-cue { display: none; }

/* Hero */
.beat--hero { padding: 64px 0 88px; }
.hero-grid { display: grid; grid-template-columns: minmax(0, 7fr) minmax(0, 4fr); gap: 48px; align-items: center; }
.beat--hero h1 { font-size: clamp(36px, 4.9vw, 66px); line-height: 1.07; margin-bottom: .45em; max-width: 16ch; }
.lede { color: var(--muted); max-width: 56ch; }
.cta-block { margin: 1.8rem 0 1.1rem; }
.portrait { border-radius: 10px; overflow: hidden; aspect-ratio: 949 / 913; background: #2b2f31; box-shadow: 0 40px 80px -30px rgba(0, 0, 0, .85); }
.portrait img { width: 100%; height: 100%; object-fit: cover; object-position: 50% 30%; }

/* Life + final (cream) */
.beat--life, .beat--final { color: var(--ink); }
.beat--life h2, .beat--final h2 { color: var(--ink); }
.beat--life .eyebrow, .beat--final .eyebrow { color: var(--gold-deep); }
.life-grid { display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); gap: 32px; align-items: start; }
.life-lead { grid-column: 1 / span 6; }
.life-lead img { width: 100%; aspect-ratio: 4 / 3; object-fit: cover; object-position: 50% 45%; }
.life-text { grid-column: 7 / span 6; }
.life-text p:not(.eyebrow) { color: var(--ink-soft); }
.life-support { grid-column: 7 / span 6; display: grid; grid-template-columns: 3fr 4fr; gap: 20px; align-items: end; }
.life-support img:first-child { aspect-ratio: 3 / 4; object-fit: cover; }
.life-support img:last-child { aspect-ratio: 4 / 3; object-fit: cover; }
.life-grid img { border-radius: 6px; }
.final-inner { max-width: 680px; margin: 0 auto; padding: 0 var(--gutter); text-align: center; }
.beat--final p { color: var(--ink-soft); }
.beat--final .cta-support { color: var(--ink-soft); margin: 1rem auto 0; }
.btn-final { margin-top: .6rem; }
.final-path { width: 40px; height: 120px; margin: 0 auto 1.4rem; overflow: visible; }
.final-path path { fill: none; stroke: #b08a4b; stroke-width: 2.5; stroke-linecap: round; vector-effect: non-scaling-stroke; }
.ask-ai { margin: 4rem auto 0; padding: 28px 24px; border: 1px solid var(--line-cream); border-radius: 8px; background: rgba(255, 255, 255, .5); text-align: left; }
.ask-ai h3 { font-size: 22px; color: var(--ink); }
.ai-disclose { font-size: 15px; line-height: 1.5; }

/* Footer */
.site-footer { position: relative; z-index: 2; background: var(--charcoal); color: var(--muted); padding: 56px 0 40px; }
.footer-grid { display: grid; grid-template-columns: 1fr 2fr; gap: 24px 48px; }
.footer-brand .wordmark { color: var(--warm-white); margin-bottom: .3rem; }
.footer-brand p:last-child { font-size: 15px; }
.footer-links { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: .2rem 1.6rem; }
.footer-links a { display: inline-block; padding: .55rem 0; font-size: 15px; color: var(--warm-white); text-decoration: none; border-bottom: 1px solid transparent; }
.footer-links a:hover { border-bottom-color: var(--gold); }
.disclaimer, .copyright { grid-column: 1 / -1; font-size: 14px; line-height: 1.5; margin: 0; max-width: 90ch; }
.disclaimer { border-top: 1px solid var(--line-dark); padding-top: 20px; }
.motion-toggle { margin-left: .8rem; min-height: 44px; padding: .4rem .8rem; background: transparent; color: var(--warm-white); border: 1px solid rgba(245, 241, 233, .3); border-radius: 6px; font: 14px var(--sans); cursor: pointer; }

/* ======================================================================
   STATIC READING VERSION (default: reduced motion, motion off, no JS)
   ====================================================================== */
.world, .film, .strike { display: none; }
.beat { padding: 72px 0; }
.beat .panel { max-width: 680px; }
.chapter > .beat + .beat { padding-top: 0; }
.sv { max-width: 760px; margin-top: 28px; }
.sv img { width: 100%; border-radius: 8px; }
#business-paths .beat, #how-i-help .beat { padding-bottom: 36px; }
.beat--life { background: var(--cream); }
.beat--final { background: var(--cream); padding-top: 24px; padding-bottom: 96px; }

/* ======================================================================
   CINEMATIC MODES (shared by m3d + mfilm)
   ====================================================================== */
.m3d body, .mfilm body { background: #0b1011; }
.m3d .site-header, .mfilm .site-header { position: fixed; left: 0; right: 0; top: 0; }
.m3d main, .mfilm main { padding-top: var(--header-h); }
.m3d .sv, .mfilm .sv { display: none; }

.m3d .beat, .mfilm .beat { min-height: 100vh; min-height: 100svh; display: flex; align-items: center; padding: 12vh 0; }
.m3d .beat--tall, .mfilm .beat--tall { min-height: 135vh; }
.m3d .beat--strike, .mfilm .beat--strike { min-height: 170vh; }
.m3d .beat > .wrap, .mfilm .beat > .wrap { width: 100%; }

/* Readable surfaces floating in the world */
.m3d .panel, .mfilm .panel {
  width: min(540px, 44vw); padding: clamp(24px, 2.6vw, 40px);
  background: rgba(9, 13, 14, .72); border: 1px solid rgba(227, 189, 127, .16); border-radius: 12px;
  box-shadow: 0 30px 80px -30px rgba(0, 0, 0, .8);
  opacity: 0; transform: translateY(28px);
  transition: opacity .7s var(--ease), transform .7s var(--ease);
}
@supports (backdrop-filter: blur(8px)) {
  .m3d .panel, .mfilm .panel { background: rgba(9, 13, 14, .56); backdrop-filter: blur(16px) saturate(125%); }
}
.m3d .beat.is-live .panel, .mfilm .beat.is-live .panel,
.m3d .beat:focus-within .panel, .mfilm .beat:focus-within .panel { opacity: 1; transform: none; }
.m3d [data-side="right"] .panel, .mfilm [data-side="right"] .panel { margin-left: auto; }
.m3d .panel--center, .mfilm .panel--center { margin: 0 auto; text-align: center; }
.m3d .panel--quote, .mfilm .panel--quote { width: min(620px, 50vw); background: rgba(9, 13, 14, .62); }
.m3d .beat .panel h3:not(:first-child), .mfilm .beat .panel h3:not(:first-child) { margin-top: 1.4rem; }

/* Hero sits directly in the world */
.m3d .beat--hero, .mfilm .beat--hero { padding-top: 6vh; padding-bottom: 12vh; }
.m3d .hero-copy, .mfilm .hero-copy { position: relative; }
.m3d .hero-copy::before {
  content: ''; position: absolute; inset: -12% -18% -12% -40%; z-index: -1; pointer-events: none;
  background: radial-gradient(closest-side, rgba(8, 12, 13, .78), rgba(8, 12, 13, 0));
}
@media (min-width: 1024px) {
  .m3d .hero-grid { grid-template-columns: minmax(0, 7fr) minmax(0, 3fr); align-items: end; }
  .m3d .portrait { max-width: 300px; margin-left: auto; transform: translateY(-4vh); }
}
.m3d .portrait { box-shadow: 0 40px 90px -30px rgba(0, 0, 0, .9), 0 0 0 1px rgba(227, 189, 127, .25); }
.m3d .scroll-cue, .mfilm .scroll-cue {
  display: block; position: absolute; left: 50%; bottom: 28px; transform: translateX(-50%); margin: 0;
  font-size: 13px; letter-spacing: .2em; text-transform: uppercase; color: rgba(245, 241, 233, .7);
}
.m3d .scroll-cue::after, .mfilm .scroll-cue::after { content: ''; display: block; width: 1px; height: 34px; margin: 10px auto 0; background: linear-gradient(var(--gold), transparent); }
.m3d .beat--hero, .mfilm .beat--hero { position: relative; }

/* Warm chapter: cream reading surfaces, the world behind has warmed */
.m3d .beat--life, .mfilm .beat--life { background: transparent; padding: 18vh 0 10vh; }
.m3d .life-text, .mfilm .life-text {
  background: rgba(242, 238, 229, .9); border-radius: 12px; padding: clamp(24px, 2.6vw, 40px);
  box-shadow: 0 30px 80px -40px rgba(60, 44, 20, .45);
}
.m3d .life-grid img, .mfilm .life-grid img {
  border-radius: 4px; border: 10px solid #fbf9f4; box-shadow: 0 30px 60px -28px rgba(60, 44, 20, .55);
}
.m3d .life-lead, .mfilm .life-lead { transform: rotate(-1.2deg); }
.m3d .life-support img:last-child, .mfilm .life-support img:last-child { transform: rotate(1.4deg); }
.m3d .beat--final, .mfilm .beat--final { background: transparent; min-height: 0; padding: 4vh 0 16vh; display: block; }
.m3d .final-inner, .mfilm .final-inner { background: rgba(242, 238, 229, .86); border-radius: 14px; padding: 44px clamp(20px, 4vw, 48px) 40px; }
.m3d .final-path, .mfilm .final-path { margin-top: -44px; height: 150px; }
.m3d .final-path path, .mfilm .final-path path { stroke-dasharray: 1; stroke-dashoffset: var(--final-draw, 1); vector-effect: none; }

/* Header warms with the world */
.site-header { transition: background-color .8s var(--ease), border-color .8s var(--ease); }
.is-warm .site-header { background: rgba(242, 238, 229, .82); border-bottom-color: var(--line-cream); }
.is-warm .wordmark, .is-warm .nav-links a, .is-warm .menu-btn { color: var(--ink); }
.is-warm .menu-btn { border-color: rgba(17, 23, 25, .35); }
.is-warm .nav-links a:hover { color: var(--ink); }
@media (max-width: 1080px) {
  .is-warm .nav-panel { background: var(--cream); border-bottom-color: var(--line-cream); }
  .is-warm .nav-links a { border-bottom-color: var(--line-cream); }
}

/* ---------- Desktop 3D world ---------- */
.m3d .world { display: block; position: fixed; inset: 0; z-index: 0; background: #0b1011; }
.m3d .world canvas { width: 100%; height: 100%; opacity: 0; transition: opacity 1.2s var(--ease); }
.m3d .world.is-ready canvas { opacity: 1; }
.world-veil {
  position: absolute; inset: 0; pointer-events: none;
  background: radial-gradient(120% 90% at 50% 45%, transparent 55%, rgba(4, 7, 8, .55) 100%);
  transition: opacity 1s var(--ease);
}
.world.is-warm .world-veil { opacity: 0; }

/* The strike: the lane hands over to real footage */
.m3d .strike, .mfilm .strike { display: block; position: fixed; inset: 0; z-index: 1; opacity: 0; pointer-events: none; background: #050708; }
.strike video { width: 100%; height: 100%; object-fit: cover; }
.strike::after { content: ''; position: absolute; inset: 0; background: linear-gradient(90deg, rgba(5, 7, 8, .55), transparent 55%), linear-gradient(0deg, rgba(5, 7, 8, .5), transparent 40%); }
.strike-label { position: absolute; right: 24px; bottom: 18px; z-index: 1; margin: 0; font-size: 13px; letter-spacing: .12em; text-transform: uppercase; color: rgba(245, 241, 233, .75); }

/* ---------- Cinematic stills (phones, low-power, WebGL fallback) ---------- */
.mfilm .film { display: block; position: fixed; inset: 0; z-index: 0; overflow: hidden; background: #0b1011; }
.shot { position: absolute; inset: 0; opacity: 0; transition: opacity 1s var(--ease); }
.shot.is-on { opacity: 1; }
.shot img, .shot picture { display: block; width: 100%; height: 100%; }
.shot img { object-fit: cover; transform: scale(1.08); transition: transform 2.4s var(--ease); }
.shot.is-on img { transform: scale(1); }
.shot--pan img { transform: scale(1.18) translate(var(--pan-x, 6%), 0); transition: transform 1.4s var(--ease); }
.shot--pan.is-on img { transform: scale(1.18) translate(var(--pan-x, 6%), 0); }
.shot--hero { background: radial-gradient(70% 55% at 70% 30%, rgba(37, 71, 66, .75), transparent 70%), radial-gradient(60% 40% at 20% 90%, rgba(227, 189, 127, .12), transparent 70%), #0b1011; }
.shot--paths { display: flex; align-items: center; justify-content: center; background: radial-gradient(60% 50% at 50% 50%, rgba(37, 71, 66, .6), transparent 75%), #0b1011; }
.shot--paths svg { width: min(92vw, 520px); height: auto; }
.shot--paths path { fill: none; stroke: rgba(227, 189, 127, .35); stroke-width: 3; stroke-linecap: round; transition: stroke .6s var(--ease), stroke-width .6s var(--ease); }
.shot--paths .br-trunk { stroke: var(--gold); }
.shot--paths .hub { fill: var(--gold); }
.shot--paths .end { fill: #0b1011; stroke: rgba(137, 185, 159, .5); stroke-width: 3; transition: stroke .6s var(--ease), fill .6s var(--ease); }
.shot--paths [data-b].on { stroke: var(--gold); stroke-width: 5; }
.shot--paths .end.on { fill: var(--gold); stroke: var(--gold); }
.shot--warm { background: radial-gradient(80% 60% at 60% 20%, #fff7e6, var(--cream) 70%); }
.film-grade { position: absolute; inset: 0; pointer-events: none; background: linear-gradient(180deg, rgba(8, 12, 13, .35), rgba(8, 12, 13, .15) 30%, rgba(8, 12, 13, .55)); transition: opacity 1s var(--ease); }
.film.is-warm .film-grade { opacity: 0; }

/* ---------- Tablet / phone ---------- */
@media (max-width: 1023px) {
  :root { --gutter: 32px; }
  .hero-grid { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); }
  .life-lead, .life-text, .life-support { grid-column: 1 / -1; }
  .life-lead, .life-support { max-width: 720px; }
  .m3d .panel, .mfilm .panel, .mfilm .panel--quote { width: min(560px, 100%); }
}
@media (max-width: 767px) {
  :root { --gutter: 20px; }
  body { font-size: 17px; }
  .hero-grid, .life-grid { grid-template-columns: minmax(0, 1fr); gap: 28px; }
  .hero-grid > *, .life-grid > * { grid-column: 1 / -1 !important; }
  .portrait { max-width: 420px; }
  .beat--hero h1 { font-size: clamp(34px, 9.6vw, 42px); max-width: none; }
  .btn-lg { width: 100%; }
  .beat h2 { font-size: clamp(28px, 8vw, 34px); }
  .life-support { grid-template-columns: 1fr 1fr; gap: 14px; }
  .footer-grid { grid-template-columns: 1fr; }
  /* Each scene opens on its picture, then the words rise over the lower screen */
  .mfilm .beat { min-height: 150svh; align-items: flex-end; padding: 62svh 0 10svh; }
  .mfilm .beat--strike { min-height: 190svh; }
  .mfilm .beat--hero { min-height: 100svh; align-items: center; padding: 4vh 0 10vh; }
  .mfilm .panel { padding: 22px 20px; background: rgba(9, 13, 14, .78); }
  .mfilm .shot img { object-position: 50% 30%; }
  .mfilm .shot--paths { align-items: flex-start; padding-top: calc(var(--header-h) + 4svh); }
  .mfilm .shot--paths svg { width: 92vw; }
  .mfilm .strike-label { left: 20px; right: auto; }
  .mfilm .beat--life { min-height: 0; align-items: flex-start; padding: 40svh 0 6svh; }
  .mfilm .beat--final { min-height: 0; padding: 4svh 0 12svh; }
  .mfilm .life-grid img { border-width: 6px; }
  .mfilm .life-lead { transform: rotate(-1deg); }
  .mfilm .scroll-cue { display: none; }
  .mfilm .strike video { object-position: 60% 50%; }
}
@media (max-width: 360px) {
  :root { --gutter: 16px; }
  .wordmark { font-size: 15px; letter-spacing: .12em; }
  .btn { padding-left: 1rem; padding-right: 1rem; }
}

/* ---------- AI bubble / panel (restyled for this page) ---------- */
.ai-bubble {
  position: fixed; right: 20px; bottom: 20px; z-index: 80; display: flex; align-items: center; gap: .7rem;
  padding: .45rem 1.1rem .45rem .45rem; border-radius: 999px; text-decoration: none; background: var(--charcoal);
  border: 1px solid rgba(227, 189, 127, .55); box-shadow: 0 10px 30px -12px rgba(0, 0, 0, .7); transition: transform .2s var(--ease);
}
.ai-bubble:hover { transform: translateY(-2px); }
.ai-bubble-face { width: 40px; height: 40px; flex: none; }
.ai-bubble-face img { width: 100%; height: 100%; border-radius: 50%; object-fit: cover; }
.ai-bubble-dot { display: none; }
.ai-bubble-text { display: flex; flex-direction: column; line-height: 1.25; }
.ai-bubble-text strong { font-size: 15px; color: var(--warm-white); }
.ai-bubble-text em { font-style: normal; font-size: 12px; color: var(--muted); }
.ai-panel {
  position: fixed; right: 20px; bottom: 20px; z-index: 110; width: min(392px, calc(100vw - 28px)); height: min(620px, calc(100vh - 40px));
  display: none; flex-direction: column; overflow: hidden; background: var(--charcoal); border: 1px solid rgba(227, 189, 127, .45); border-radius: 8px;
  box-shadow: 0 30px 60px -20px rgba(0, 0, 0, .8); opacity: 0; transform: translateY(14px); transition: opacity .25s var(--ease), transform .25s var(--ease);
}
.ai-panel.open { display: flex; }
.ai-panel.in { opacity: 1; transform: none; }
.ai-panel-head { display: flex; align-items: center; gap: .7rem; padding: .7rem .8rem; background: #172122; border-bottom: 1px solid var(--line-dark); }
.ai-panel-head img { width: 34px; height: 34px; border-radius: 50%; }
.ai-panel-title { display: flex; flex-direction: column; line-height: 1.2; min-width: 0; }
.ai-panel-title strong { font-size: 15px; color: var(--warm-white); }
.ai-panel-title em { font-style: normal; font-size: 12px; color: var(--muted); }
.ai-panel-full { margin-left: auto; font-size: 13px; color: var(--muted); text-decoration: none; padding: .4rem .5rem; white-space: nowrap; }
.ai-panel-close { flex: none; width: 44px; height: 44px; border-radius: 50%; cursor: pointer; background: transparent; border: 1px solid rgba(227, 189, 127, .55); color: var(--warm-white); font-size: 20px; line-height: 1; }
.ai-panel-body { flex: 1; position: relative; background: #121a1b; }
.ai-panel-body iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; }
.ai-panel-loading { position: absolute; inset: 0; display: flex; align-items: center; justify-content: center; font-size: 14px; color: var(--muted); }
@media (max-width: 767px) {
  .ai-bubble { right: 14px; bottom: 14px; padding: .4rem; }
  .ai-bubble-text { display: none; }
  .ai-bubble-face { width: 48px; height: 48px; }
  .ai-panel { right: 0; bottom: 0; width: 100vw; height: 100dvh; border-radius: 0; border: 0; }
  body.ai-panel-open { overflow: hidden; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .001ms !important; transition-duration: .001ms !important; }
  .btn:hover, .ai-bubble:hover { transform: none; }
}
