/* =========================================================
   SRIJAN SIR — Teacher's Day Tribute
   Design concept: "Ledger of Gratitude" — warm ivory paper,
   antique gold foil, deep ledger-green ink, fine rule lines.
   ========================================================= */

:root{
  --bg:#FBF7EE;
  --surface:#FFFFFF;
  --surface-alt:#F5EFDD;
  --ink:#241F17;
  --ink-soft:#6B6255;
  --gold:#AD8025;
  --gold-deep:#8A6318;
  --gold-pale:#F0E2B4;
  --green:#2F4A3C;
  --green-pale:#E4ECE6;
  --rule: rgba(47,74,60,0.16);
  --shadow: 0 24px 60px -30px rgba(36,31,23,0.4);
  --shadow-soft: 0 12px 30px -18px rgba(36,31,23,0.3);
  --radius-lg: 28px;
  --radius-md: 18px;
  --radius-sm: 10px;
  --maxw: 1180px;
}

*{ box-sizing:border-box; margin:0; padding:0; }
html{ scroll-behavior:smooth; }
body{
  background:var(--bg);
  color:var(--ink);
  font-family:'Manrope', sans-serif;
  overflow-x:hidden;
  -webkit-font-smoothing:antialiased;
  line-height:1.6;
}
h1,h2,h3,.display{ font-family:'Cormorant Garamond', serif; font-weight:600; color:var(--ink); }
a{ color:inherit; }
img{ max-width:100%; display:block; }
button{ font-family:inherit; }
::selection{ background:var(--gold-pale); color:var(--ink); }

.sr-only{
  position:absolute; width:1px; height:1px; padding:0; margin:-1px;
  overflow:hidden; clip:rect(0,0,0,0); white-space:nowrap; border:0;
}

.skip-link{
  position:absolute; left:-999px; top:0; background:var(--ink); color:#fff;
  padding:12px 20px; border-radius:0 0 10px 0; z-index:999;
}
.skip-link:focus{ left:0; }

:focus-visible{ outline:2.5px solid var(--gold); outline-offset:3px; }

@media (prefers-reduced-motion: reduce){
  *{ animation-duration:0.001ms !important; animation-iteration-count:1 !important; transition-duration:0.001ms !important; scroll-behavior:auto !important; }
}

/* ---------- ledger paper texture ---------- */
.ledger-texture{
  position:fixed; inset:0; z-index:0; pointer-events:none;
  background-image: repeating-linear-gradient(
    to bottom, rgba(47,74,60,0.05) 0px, rgba(47,74,60,0.05) 1px,
    transparent 1px, transparent 38px
  );
  opacity:0.6;
}

.ambient-field{
  position:fixed; inset:0; z-index:0; pointer-events:none; overflow:hidden;
}
.ambient-field span{
  position:absolute; border-radius:50%; filter:blur(2px);
  opacity:0.55; animation: drift linear infinite;
}
.blob{
  filter:blur(50px) !important; opacity:0.35 !important;
}
@keyframes drift{
  from{ transform: translateY(0) rotate(0deg); }
  to{ transform: translateY(-140px) rotate(20deg); }
}

section, footer, main{ position:relative; z-index:1; }
header{ position:relative; z-index:200; }

/* ---------- animated canvas + custom cursor (bg-fx.js) ---------- */
#bgCanvas{ position:fixed; inset:0; width:100%; height:100%; z-index:0; pointer-events:none; }

.cursor-dot, .cursor-ring{
  display:none; position:fixed; top:0; left:0; border-radius:50%;
  pointer-events:none; z-index:9999; transform:translate(-50%,-50%);
}
.cursor-dot{ width:7px; height:7px; background:var(--gold-deep); }
.cursor-ring{
  width:32px; height:32px; border:1.5px solid var(--gold); opacity:0.55;
  transition:width .2s ease, height .2s ease, background .2s ease, opacity .2s ease;
}
.cursor-ring.grow{ width:54px; height:54px; background:rgba(173,128,37,0.12); border-color:var(--green); }
@media (hover:hover) and (pointer:fine){
  body:not(.reduced-motion){ cursor:none; }
  body:not(.reduced-motion) .cursor-dot,
  body:not(.reduced-motion) .cursor-ring{ display:block; }
}

/* ---------- ornament divider (between sections) ---------- */
.ornament-divider{
  display:flex; align-items:center; justify-content:center; gap:14px;
  max-width:240px; margin:0 auto; position:relative; z-index:2; height:1px;
}
.ornament-divider::before, .ornament-divider::after{
  content:''; flex:1; height:1px; background:var(--rule);
  transform:scaleX(0); transition:transform 1s ease;
}
.ornament-divider.in-view::before, .ornament-divider.in-view::after{ transform:scaleX(1); }
.ornament-divider span{
  width:7px; height:7px; background:var(--gold); flex:none;
  transform:rotate(45deg) scale(0); transition:transform .6s ease .35s;
}
.ornament-divider.in-view span{ transform:rotate(45deg) scale(1); }

/* ---------- animated underline under section headings ---------- */
.underline-heading{ position:relative; display:inline-block; padding-bottom:16px; }
.underline-draw{
  position:absolute; left:50%; bottom:0; height:2px; width:0;
  background:linear-gradient(90deg, transparent, var(--gold), transparent);
  transform:translateX(-50%); transition:width 1s ease .2s;
}
.reveal.in-view .underline-draw{ width:130px; }

/* ---------- tilt-enabled photo frames ---------- */
.hero-photo, .about-photo{ perspective:1100px; }
[data-tilt]{ transform-style:preserve-3d; transition:transform .5s cubic-bezier(.2,.8,.2,1); will-change:transform; }

/* ---------- loader ---------- */
.loader{
  position:fixed; inset:0; z-index:1000; background:var(--bg);
  display:flex; flex-direction:column; align-items:center; justify-content:center; gap:18px;
  transition: opacity .6s ease, visibility .6s ease;
}
.loader.hide{ opacity:0; visibility:hidden; }
.loader-seal{ position:relative; width:78px; height:78px; display:flex; align-items:center; justify-content:center; }
.loader-seal-ring{ position:absolute; inset:0; width:100%; height:100%; }
.loader-seal-ring circle{ fill:none; stroke:var(--gold); stroke-width:2; stroke-dasharray:276; stroke-dashoffset:276; animation: sealDraw 1.4s ease forwards infinite; }
@keyframes sealDraw{ to{ stroke-dashoffset:0; } }
.loader-mark{ font-family:'Cormorant Garamond', serif; font-size:1.5rem; color:var(--gold-deep); font-weight:700; }
.loader-title{ font-family:'Cormorant Garamond', serif; font-size:1.5rem; letter-spacing:0.04em; }
.loader-bar{ width:160px; height:3px; background:var(--rule); border-radius:2px; overflow:hidden; }
.loader-bar span{ display:block; height:100%; width:0%; background:var(--gold); transition:width 1.1s ease; }

/* ---------- nav ---------- */
.topnav{
  position:fixed; top:16px; left:50%; transform:translateX(-50%); z-index:100;
  display:flex; align-items:center; justify-content:space-between; gap:20px;
  width:min(920px, 92vw);
  background:rgba(255,255,255,0.72); backdrop-filter:blur(14px); -webkit-backdrop-filter:blur(14px);
  border:1px solid var(--rule); border-radius:999px;
  padding:10px 10px 10px 18px; box-shadow:var(--shadow-soft);
}
.brand{ display:flex; align-items:center; gap:10px; font-weight:700; white-space:nowrap; }
.brand-seal{
  width:30px; height:30px; border-radius:50%; background:var(--green); color:#F3E9C8;
  display:flex; align-items:center; justify-content:center; font-family:'Cormorant Garamond',serif;
  font-size:0.85rem; font-weight:700; flex:none; position:relative; box-shadow:0 0 0 0 rgba(47,74,60,0.4);
  animation:sealGlow 3.2s ease-in-out infinite;
}
@keyframes sealGlow{
  0%,100%{ box-shadow:0 0 0 0 rgba(47,74,60,0.35); }
  50%{ box-shadow:0 0 0 6px rgba(47,74,60,0); }
}
.brand-text{ font-family:'Cormorant Garamond', serif; font-size:1.25rem; }

.nav-links{ list-style:none; display:flex; align-items:center; gap:2px; }
.nav-links a{
  display:inline-block; font-size:0.88rem; font-weight:600; padding:9px 15px; border-radius:999px;
  text-decoration:none; color:var(--ink-soft); transition:all .25s ease; position:relative;
}
.nav-links a:hover{ color:var(--ink); background:var(--gold-pale); }
.nav-links a.active{ color:var(--surface); background:var(--green); }

.nav-toggle{
  display:none; flex-direction:column; gap:4px; background:none; border:none; cursor:pointer;
  padding:8px; border-radius:8px;
}
.nav-toggle span{ width:20px; height:2px; background:var(--ink); border-radius:2px; transition:transform .3s ease, opacity .3s ease; }

@media (max-width: 760px){
  .nav-toggle{ display:flex; }
  .nav-links{
    position:absolute; top:calc(100% + 10px); right:0; left:auto;
    flex-direction:column; align-items:stretch; gap:2px;
    background:var(--surface); border:1px solid var(--rule); border-radius:16px;
    padding:10px; box-shadow:var(--shadow); width:220px;
    opacity:0; visibility:hidden; transform:translateY(-8px);
    transition:opacity .25s ease, transform .25s ease, visibility .25s ease;
  }
  .nav-links.open{ opacity:1; visibility:visible; transform:translateY(0); }
  .nav-links a{ display:block; text-align:left; }
}

/* ---------- section defaults ---------- */
.section{ padding:110px 6vw; max-width:var(--maxw); margin:0 auto; }
.section-alt{ background:var(--surface-alt); max-width:none; border-radius:0; padding-left:6vw; padding-right:6vw; }
.section-alt > *{ max-width:var(--maxw); margin-left:auto; margin-right:auto; }
.section-head{ text-align:center; max-width:640px; margin:0 auto 56px; }
.section-head h2{ font-size:clamp(2.1rem, 4.5vw, 3rem); margin-bottom:14px; }
.section-lede{ color:var(--ink-soft); font-size:1.08rem; }

.reveal{ opacity:0; transform:translateY(26px); transition:opacity .8s ease, transform .8s ease; }
.reveal.in-view{ opacity:1; transform:translateY(0); }

/* ---------- hero ---------- */
.hero{
  min-height:100svh; display:flex; align-items:center; justify-content:center;
  padding:150px 6vw 90px; position:relative;
}
.hero-inner{
  display:flex; align-items:center; justify-content:center; gap:70px;
  max-width:var(--maxw); width:100%; flex-wrap:wrap;
}
.hero-text{ flex:1 1 440px; }
.hero-stamp{
  display:inline-flex; align-items:center; gap:10px; font-size:0.92rem; font-weight:600;
  color:var(--green); background:var(--green-pale); padding:9px 18px 9px 10px; border-radius:999px;
  margin-bottom:26px;
}
.stamp-circle{ font-size:1.05rem; }
.hero-title{
  font-size:clamp(2.9rem, 7vw, 4.6rem); line-height:1.04; letter-spacing:-0.01em;
}
.hero-title-sub{
  display:block; font-size:clamp(1.05rem, 2vw, 1.35rem); font-style:italic; font-weight:500;
  margin-top:10px; letter-spacing:0;
  background:linear-gradient(100deg, var(--gold-deep) 30%, var(--gold) 45%, #E7C878 50%, var(--gold) 55%, var(--gold-deep) 70%);
  background-size:250% 100%; -webkit-background-clip:text; background-clip:text; color:transparent;
  animation:shimmerText 5s ease-in-out infinite;
}
@keyframes shimmerText{ 0%{ background-position:0% 50%; } 50%{ background-position:100% 50%; } 100%{ background-position:0% 50%; } }
.hero-name{ font-family:'Cormorant Garamond', serif; font-size:clamp(1.5rem,2.6vw,1.9rem); margin-top:26px; }
.hero-subjects{ color:var(--ink-soft); margin-top:6px; font-weight:600; }
.hero-subjects .dot{ color:var(--gold); margin:0 4px; }

.cta-row{ display:flex; gap:14px; margin-top:36px; flex-wrap:wrap; }
.btn{
  position:relative; overflow:hidden;
  display:inline-flex; align-items:center; gap:8px; padding:15px 28px; border-radius:999px;
  font-weight:700; font-size:0.95rem; text-decoration:none; border:1.5px solid transparent;
  transition:transform .25s ease, box-shadow .25s ease, background .25s ease, color .25s ease;
}
.btn::after{
  content:''; position:absolute; top:0; left:-60%; width:40%; height:100%;
  background:linear-gradient(115deg, transparent, rgba(255,255,255,0.4), transparent);
  transform:skewX(-20deg); transition:left .65s ease;
}
.btn:hover::after{ left:130%; }
.btn-primary{ background:var(--green); color:#F6EFD9; box-shadow:0 16px 34px -14px rgba(47,74,60,0.55); }
.btn-primary:hover{ transform:translateY(-2px); box-shadow:0 20px 38px -12px rgba(47,74,60,0.6); }
.btn-ghost{ background:var(--surface); color:var(--ink); border-color:var(--rule); }
.btn-ghost:hover{ border-color:var(--gold); color:var(--gold-deep); transform:translateY(-2px); }

.hero-photo{ flex:none; position:relative; animation: floatPhoto 7s ease-in-out infinite; }
.hero-photo-frame{
  width:min(340px, 76vw); aspect-ratio:4/5; border-radius:var(--radius-lg);
  overflow:hidden; border:8px solid var(--surface); box-shadow:var(--shadow);
}
.hero-photo-frame img{ width:100%; height:100%; object-fit:cover; transition:transform .5s ease; }
.hero-photo:hover .hero-photo-frame img{ transform:scale(1.05); }
@keyframes floatPhoto{ 0%,100%{ transform:translateY(0); } 50%{ transform:translateY(-12px); } }

.corner{ position:absolute; width:34px; height:34px; border:2px solid var(--gold); opacity:0.7; }
.corner-tl{ top:-14px; left:-14px; border-right:none; border-bottom:none; border-radius:8px 0 0 0; }
.corner-br{ bottom:-14px; right:-14px; border-left:none; border-top:none; border-radius:0 0 8px 0; }

.scroll-cue{
  position:absolute; bottom:26px; left:50%; transform:translateX(-50%);
  width:26px; height:42px; border:2px solid var(--rule); border-radius:14px;
}
.scroll-cue span{
  position:absolute; top:6px; left:50%; transform:translateX(-50%); width:4px; height:8px;
  background:var(--gold); border-radius:2px; animation: scrollDot 1.8s ease infinite;
}
@keyframes scrollDot{ 0%{ opacity:1; top:6px; } 70%{ opacity:0; top:22px; } 100%{ opacity:0; top:6px; } }

/* ---------- about ---------- */
.about-grid{
  display:grid; grid-template-columns:280px 1fr; gap:56px; align-items:center;
  max-width:900px; margin:0 auto;
}
.about-photo-frame{
  border-radius:var(--radius-lg); overflow:hidden; border:8px solid var(--surface-alt);
  box-shadow:var(--shadow-soft); aspect-ratio:2/3;
}
.about-photo-frame img{ width:100%; height:100%; object-fit:cover; transition:transform .5s ease; }
.about-photo-frame:hover img{ transform:scale(1.06); }

.fact-ledger{ list-style:none; border-top:1px solid var(--rule); }
.fact-ledger li{
  display:flex; justify-content:space-between; gap:20px; padding:16px 4px;
  border-bottom:1px solid var(--rule); position:relative; transition:padding-left .3s ease, background .3s ease;
}
.fact-ledger li:hover{ padding-left:14px; background:linear-gradient(90deg, var(--gold-pale), transparent 70%); }
.fact-label{ color:var(--ink-soft); font-weight:600; }
.fact-value{ font-weight:700; text-align:right; }
.about-note{ margin-top:22px; color:var(--ink-soft); font-size:0.95rem; font-style:italic; }

@media (max-width: 620px){
  .about-grid{ grid-template-columns:1fr; }
  .about-photo-frame{ max-width:220px; margin:0 auto; }
}

/* ---------- subjects ---------- */
.subject-grid{ display:grid; grid-template-columns:1fr 1fr; gap:28px; max-width:900px; margin:0 auto; }
.subject-card{
  position:relative; overflow:hidden;
  background:var(--surface); border:1px solid var(--rule); border-radius:var(--radius-lg);
  padding:38px 32px; box-shadow:var(--shadow-soft); transition:transform .35s ease, box-shadow .35s ease, border-color .35s ease;
}
.subject-card::before{
  content:''; position:absolute; inset:0; opacity:0; transition:opacity .4s ease;
  background:radial-gradient(circle at 85% -10%, var(--gold-pale), transparent 60%);
}
.subject-card:hover{ transform:translateY(-6px); box-shadow:var(--shadow); border-color:var(--gold); }
.subject-card:hover::before{ opacity:1; }
.subject-card > *{ position:relative; z-index:1; }
.subject-icon{
  width:52px; height:52px; border-radius:50%; background:var(--gold-pale); display:flex; align-items:center; justify-content:center;
  margin-bottom:20px; transition:transform .35s ease;
}
.subject-card:hover .subject-icon{ transform:rotate(-8deg) scale(1.08); }
.subject-icon svg{ width:26px; height:26px; fill:none; stroke:var(--gold-deep); stroke-width:2.4; stroke-linecap:round; stroke-linejoin:round; }
.subject-card h3{ font-size:1.6rem; margin-bottom:12px; }
.subject-card p{ color:var(--ink-soft); }

@media (max-width: 640px){ .subject-grid{ grid-template-columns:1fr; } }

/* ---------- AI section ---------- */
.ai-orb{
  width:56px; height:56px; border-radius:50%; margin:0 auto 18px;
  background:radial-gradient(circle at 35% 30%, var(--gold-pale), var(--green) 75%);
  position:relative; box-shadow:0 0 0 6px var(--green-pale);
}
.ai-orb span{
  position:absolute; inset:0; border-radius:50%; border:2px solid var(--gold); opacity:0.6;
  animation:pulseOrb 2.4s ease-in-out infinite;
}
@keyframes pulseOrb{ 0%,100%{ transform:scale(1); opacity:0.6;} 50%{ transform:scale(1.35); opacity:0;} }

.ai-shell{
  max-width:760px; margin:0 auto; background:var(--surface); border:1px solid var(--rule);
  border-radius:var(--radius-lg); box-shadow:var(--shadow); overflow:hidden;
  animation:shellGlow 5s ease-in-out infinite;
}
@keyframes shellGlow{
  0%,100%{ box-shadow:var(--shadow), 0 0 0 0 rgba(173,128,37,0); }
  50%{ box-shadow:var(--shadow), 0 0 0 5px rgba(173,128,37,0.08); }
}
.ai-shell-head{
  display:flex; align-items:center; justify-content:space-between; padding:18px 22px;
  border-bottom:1px solid var(--rule); background:var(--surface-alt);
}
.ai-shell-id{ display:flex; align-items:center; gap:12px; }
.ai-mini-orb{
  width:34px; height:34px; border-radius:50%; flex:none;
  background:radial-gradient(circle at 35% 30%, var(--gold-pale), var(--green) 75%);
}
.ai-shell-name{ font-weight:700; }
.ai-shell-status{ font-size:0.82rem; color:var(--ink-soft); }
.ai-clear{
  border:1px solid var(--rule); background:var(--surface); color:var(--ink-soft); font-size:0.82rem;
  font-weight:600; padding:8px 14px; border-radius:999px; cursor:pointer; transition:all .2s ease;
}
.ai-clear:hover{ border-color:var(--gold); color:var(--gold-deep); }

.ai-shell-actions{ display:flex; align-items:center; gap:8px; }
.ai-voice-toggle{
  display:flex; align-items:center; gap:7px; border:1px solid var(--rule); background:var(--surface);
  color:var(--ink-soft); font-size:0.82rem; font-weight:600; padding:8px 14px; border-radius:999px;
  cursor:pointer; transition:all .2s ease;
}
.ai-voice-toggle svg{ width:15px; height:15px; fill:none; stroke:currentColor; stroke-width:1.6; }
.ai-voice-toggle svg path:first-child{ fill:currentColor; stroke:none; }
.ai-voice-toggle:hover{ border-color:var(--gold); color:var(--gold-deep); }
.ai-voice-toggle[aria-pressed="true"]{ background:var(--green); border-color:var(--green); color:#F6EFD9; }
.ai-voice-toggle[aria-pressed="true"]:hover{ color:#F6EFD9; }
.ai-voice-toggle.is-speaking svg{ animation:pulseOrb 1s ease-in-out infinite; }

.ai-quick-actions{ display:flex; gap:8px; padding:14px 22px 0; flex-wrap:wrap; }
.quick-chip{
  border:1px solid var(--rule); background:var(--surface); color:var(--ink); font-size:0.82rem; font-weight:600;
  padding:8px 14px; border-radius:999px; cursor:pointer; transition:all .2s ease;
}
.quick-chip:hover{ background:var(--gold-pale); border-color:var(--gold); }

.ai-log{
  min-height:280px; max-height:420px; overflow-y:auto; padding:22px; display:flex; flex-direction:column; gap:14px;
}
.ai-empty{ margin:auto; text-align:center; color:var(--ink-soft); max-width:440px; }
.ai-empty p{ margin-bottom:18px; }
.prompt-chips{ display:flex; flex-wrap:wrap; gap:8px; justify-content:center; }
.prompt-chip{
  border:1px solid var(--rule); background:var(--surface-alt); color:var(--ink); font-size:0.82rem;
  padding:9px 14px; border-radius:14px; cursor:pointer; transition:all .2s ease; text-align:left;
}
.prompt-chip:hover{ border-color:var(--gold); background:var(--gold-pale); }

.msg{ max-width:80%; padding:13px 17px; border-radius:16px; font-size:0.95rem; line-height:1.55; animation:msgIn .35s ease both; }
@keyframes msgIn{ from{ opacity:0; transform:translateY(8px);} to{ opacity:1; transform:translateY(0);} }
.msg-user{ align-self:flex-end; background:var(--green); color:#F6EFD9; border-bottom-right-radius:4px; }
.msg-ai{ align-self:flex-start; background:var(--surface-alt); color:var(--ink); border-bottom-left-radius:4px; }
.msg-ai.msg-error{ background:#F6E4DD; color:#7A3A22; }

.typing{ align-self:flex-start; display:flex; gap:5px; padding:14px 17px; background:var(--surface-alt); border-radius:16px; border-bottom-left-radius:4px; }
.typing span{ width:7px; height:7px; border-radius:50%; background:var(--ink-soft); animation:typingDot 1.2s infinite ease-in-out; }
.typing span:nth-child(2){ animation-delay:0.15s; }
.typing span:nth-child(3){ animation-delay:0.3s; }
@keyframes typingDot{ 0%,60%,100%{ transform:translateY(0); opacity:0.5;} 30%{ transform:translateY(-5px); opacity:1;} }

.ai-input-row{ display:flex; gap:10px; padding:16px 22px 22px; border-top:1px solid var(--rule); }
.ai-input-row input{
  flex:1; padding:13px 18px; border-radius:999px; border:1.5px solid var(--rule); background:var(--bg);
  font-family:inherit; font-size:0.95rem; color:var(--ink); transition:border-color .2s ease;
}
.ai-input-row input:focus{ border-color:var(--gold); outline:none; }
.ai-send{
  width:46px; height:46px; border-radius:50%; background:var(--green); border:none; cursor:pointer;
  display:flex; align-items:center; justify-content:center; flex:none; transition:transform .2s ease;
}
.ai-send:hover{ transform:scale(1.06); }
.ai-send svg{ width:18px; height:18px; fill:#F6EFD9; }

.ai-mic{
  width:46px; height:46px; border-radius:50%; background:var(--surface-alt); border:1.5px solid var(--rule);
  cursor:pointer; display:flex; align-items:center; justify-content:center; flex:none; transition:all .2s ease;
}
.ai-mic:hover{ border-color:var(--gold); }
.ai-mic svg{ width:18px; height:18px; fill:none; stroke:var(--ink-soft); stroke-width:1.6; }
.ai-mic svg path:first-child{ fill:var(--ink-soft); stroke:none; }
.ai-mic[aria-pressed="true"]{
  background:#C0392B; border-color:#C0392B; animation:micPulse 1.2s ease-in-out infinite;
}
.ai-mic[aria-pressed="true"] svg{ stroke:#F6EFD9; }
.ai-mic[aria-pressed="true"] svg path:first-child{ fill:#F6EFD9; }
.ai-mic:disabled{ opacity:0.4; cursor:not-allowed; }
@keyframes micPulse{
  0%,100%{ box-shadow:0 0 0 0 rgba(192,57,43,0.35); }
  50%{ box-shadow:0 0 0 8px rgba(192,57,43,0); }
}
.ai-voice-hint{
  text-align:center; font-size:0.78rem; color:var(--ink-soft); padding:0 22px 16px; margin-top:-8px;
}

/* ---------- message + instagram ---------- */
.message-inner{ max-width:720px; margin:0 auto; text-align:center; }
.message-inner h2{ font-size:clamp(2rem,4.5vw,2.8rem); margin-bottom:22px; }
.message-inner p{ color:var(--ink-soft); font-size:1.08rem; }
.instagram-link{
  margin-top:34px; display:inline-flex; align-items:center; gap:10px; text-decoration:none;
  color:var(--ink); font-weight:600; padding:13px 22px; border-radius:999px; border:1.5px solid var(--rule);
  transition:all .25s ease;
}
.instagram-link:hover{ border-color:var(--gold); background:var(--gold-pale); transform:translateY(-2px); }
.instagram-link svg{ width:22px; height:22px; fill:none; stroke:var(--green); stroke-width:1.6; transition:transform .4s ease; }
.instagram-link:hover svg{ transform:rotate(14deg) scale(1.1); }
.instagram-link strong{ color:var(--gold-deep); }

/* ---------- gallery ---------- */
.gallery-wrap{ max-width:var(--maxw); margin:80px auto 0; }
.gallery-title{ text-align:center; font-size:clamp(1.7rem,3.5vw,2.2rem); margin-bottom:36px; }
.gallery-grid{ display:grid; grid-template-columns:repeat(3, 1fr); gap:18px; }
.gallery-item{
  border:none; padding:0; background:none; cursor:pointer; border-radius:var(--radius-md); overflow:hidden;
  aspect-ratio:3/4; box-shadow:var(--shadow-soft); position:relative; border:1px solid var(--rule);
}
.gallery-item img{ width:100%; height:100%; object-fit:cover; transition:transform .5s ease; }
.gallery-item:hover img{ transform:scale(1.08); }
.gallery-item::after{
  content:''; position:absolute; inset:0; background:linear-gradient(to top, rgba(36,31,23,0.28), transparent 45%);
  opacity:0; transition:opacity .3s ease;
}
.gallery-item:hover::after{ opacity:1; }
.gallery-item::before{
  content:'View'; position:absolute; left:50%; bottom:14px; transform:translate(-50%,10px);
  color:#F6EFD9; font-size:0.78rem; font-weight:700; letter-spacing:0.06em; z-index:1;
  opacity:0; transition:opacity .3s ease, transform .3s ease;
}
.gallery-item:hover::before{ opacity:1; transform:translate(-50%,0); }

@media (max-width: 700px){ .gallery-grid{ grid-template-columns:repeat(2, 1fr); } }
@media (max-width: 420px){ .gallery-grid{ grid-template-columns:1fr 1fr; gap:12px; } }

/* ---------- lightbox ---------- */
.lightbox{
  position:fixed; inset:0; z-index:500; background:rgba(20,17,12,0.92);
  display:flex; align-items:center; justify-content:center;
}
.lightbox[hidden]{ display:none; }
.lightbox img{ max-width:88vw; max-height:82vh; border-radius:14px; box-shadow:0 30px 80px rgba(0,0,0,0.5); }
.lightbox-close{
  position:absolute; top:22px; right:26px; background:none; border:none; color:#F6EFD9; font-size:2.2rem;
  cursor:pointer; line-height:1;
}
.lightbox-nav{
  position:absolute; top:50%; transform:translateY(-50%); background:rgba(255,255,255,0.12); border:none;
  color:#F6EFD9; width:52px; height:52px; border-radius:50%; font-size:1.8rem; cursor:pointer; transition:background .2s ease;
}
.lightbox-nav:hover{ background:rgba(255,255,255,0.22); }
.lightbox-prev{ left:20px; }
.lightbox-next{ right:20px; }

/* ---------- finale ---------- */
.finale{
  position:relative; min-height:80vh; display:flex; align-items:center; justify-content:center;
  padding:110px 6vw; text-align:center; background:var(--green); color:#F6EFD9; overflow:hidden;
}
.finale h2{ color:#F6EFD9; font-size:clamp(2.2rem,5vw,3.4rem); }
.finale-line{ margin-top:20px; font-size:1.15rem; color:#DCE7DE; max-width:520px; margin-left:auto; margin-right:auto; }
.finale-class{ margin-top:26px; font-weight:700; letter-spacing:0.03em; color:var(--gold-pale); }
.finale-credit{ margin-top:30px; font-size:0.82rem; color:#B9C7BC; }
.finale-inner{ position:relative; z-index:2; }

.petal-field{ position:absolute; inset:0; z-index:1; pointer-events:none; overflow:hidden; }
.petal-field span{
  position:absolute; top:-10%; width:10px; height:10px; border-radius:50% 0 50% 50%;
  background:var(--gold-pale); opacity:0.75; animation:fall linear infinite;
}
@keyframes fall{
  to{ transform: translateY(120vh) rotate(220deg); opacity:0.2; }
}

/* ---------- footer ---------- */
.site-footer{
  text-align:center; padding:50px 6vw 40px; color:var(--ink-soft); font-size:0.92rem;
  border-top:1px solid var(--rule);
}
.footer-brand{ font-family:'Cormorant Garamond', serif; font-size:1.4rem; color:var(--ink); margin-bottom:8px; }
.footer-credit{ margin-top:14px; font-size:0.78rem; color:var(--ink-soft); }

/* ---------- to top ---------- */
.to-top{
  position:fixed; bottom:26px; right:26px; width:46px; height:46px; border-radius:50%;
  background:var(--green); color:#F6EFD9; border:none; font-size:1.2rem; cursor:pointer; z-index:80;
  opacity:0; visibility:hidden; transform:translateY(10px); transition:all .3s ease; box-shadow:var(--shadow-soft);
}
.to-top.show{ opacity:1; visibility:visible; transform:translateY(0); }
.to-top:hover{ transform:translateY(-3px); }

/* ---------- extra hover polish ---------- */
.nav-links a{ overflow:hidden; }
.nav-links a::before{
  content:''; position:absolute; left:16px; right:16px; bottom:6px; height:2px;
  background:var(--gold); transform:scaleX(0); transform-origin:left; transition:transform .3s ease;
}
.nav-links a:hover::before{ transform:scaleX(1); }
.nav-links a.active::before{ display:none; }

.quick-chip:hover, .prompt-chip:hover{ transform:translateY(-2px); box-shadow:var(--shadow-soft); }

.ai-mini-orb{ position:relative; }
.ai-mini-orb::after{
  content:''; position:absolute; inset:-4px; border-radius:50%; border:1.5px solid var(--gold);
  opacity:0.5; animation:pulseOrb 2.4s ease-in-out infinite;
}

.about-photo-frame, .hero-photo-frame{ transition:transform .4s ease, box-shadow .4s ease; }

/* reduced-motion escape hatch set by bg-fx.js/animations.js */
body.reduced-motion .ai-shell,
body.reduced-motion .brand-seal{ animation:none; }

/* ---------- responsive tightening ---------- */
@media (max-width: 500px){
  .section{ padding:80px 6vw; }
  .hero{ padding-top:130px; }
  .ai-shell-head{ flex-wrap:wrap; gap:10px; }
  .ai-quick-actions{ padding-left:16px; padding-right:16px; }
  .ai-log{ padding:16px; }
  .ai-input-row{ padding:14px 16px 18px; }
}
