/* ==========================================================
   Tibetan cloud theme + scroll effects
   ========================================================== */
:root {
  --flag-blue: #1f5fa8; --flag-white: #f6f1e4; --flag-red: #c4161c; --flag-green: #2e8b57; --flag-yellow: #f2b705;
  --tib: "Noto Serif Tibetan", serif;
}

/* ---------- Tibetan type ---------- */
[lang="bo"] { font-family: var(--tib); font-weight: 500; letter-spacing: 0; }
.hero__tib { display: block; font: 500 clamp(1.3rem, 2.4vw, 1.8rem)/1.6 var(--tib); color: var(--gold-soft); margin-bottom: 4px; text-shadow: 0 2px 12px rgba(0,0,0,.4); }

/* ---------- Header ---------- */
.header { border-bottom: 3px solid var(--red-dark); }

/* ---------- Clouds ---------- */
.cloud { display: block; height: auto; }

/* Drifting clouds in the banners */
.sky { position: absolute; inset: 0; z-index: 1; pointer-events: none; overflow: hidden; }
.sky .cloud { position: absolute; color: #fff; opacity: .22; will-change: transform; filter: drop-shadow(0 4px 10px rgba(0,0,0,.15)); }
.sky .cloud--a { width: 360px; right: 6%; top: 22%; }
.sky .cloud--b { width: 300px; right: 28%; bottom: 12%; opacity: .14; }
.sky .cloud--c { width: 240px; left: 52%; top: 8%; opacity: .16; }
.page-hero .sky .cloud--a { width: 300px; right: 4%; top: 18%; }
.page-hero .sky .cloud--b { width: 220px; right: 30%; bottom: 8%; }
.hero .hero__content { padding-top: 130px; }
.page-hero { overflow: hidden; }
.page-hero .wrap { z-index: 2; }

/* Section divider: a cloud scroll between two gold lines */
.ornament { position: relative; display: flex; align-items: center; gap: 12px; width: max-content; height: auto; margin: 6px 0 22px; background: none; }
.ornament::before, .ornament::after { content: ""; position: static; width: 48px; height: 1.5px; background: var(--gold); transform: none; margin: 0; }
.ornament .cloud { width: 78px; color: var(--red); }
.section--maroon .ornament .cloud { color: var(--gold); }
.head--center .ornament { margin-inline: auto; }

/* Eyebrow: plain, with a short gold rule */
.eyebrow { display: inline-flex; align-items: center; gap: 10px; }
.eyebrow::before { content: none; }

/* ---------- A few clouds per section (no repeating pattern) ---------- */
.section--clouds, .section--clouds-dark { position: relative; overflow: hidden; }
.section--clouds > .wrap, .section--clouds-dark > .wrap { position: relative; z-index: 2; }
.sky--section .cloud { position: absolute; color: var(--gold); opacity: .22; filter: none; }
.section--clouds-dark .sky--section .cloud { color: var(--gold); opacity: .16; }
.sky--section .cloud--s1 { width: 300px; left: -70px; top: 40px; }
.sky--section .cloud--s2 { width: 260px; right: -60px; bottom: 50px; }
.sky--section .cloud--s3 { width: 180px; right: 12%; top: 26px; opacity: .14; }
.sky--flip .cloud--s1 { left: auto; right: -70px; }
.sky--flip .cloud--s2 { right: auto; left: -60px; }
.sky--flip .cloud--s3 { right: auto; left: 14%; }
.cta--clouds { background-color: var(--maroon); }
.cta--clouds::before { display: none; }
.page-hero--clouds { background-color: var(--maroon); }
.page-hero--clouds::before { background: linear-gradient(90deg, rgba(40,6,8,.55), transparent); }
.section--maroon, .cta { position: relative; overflow: hidden; }
.section--maroon > .wrap, .cta > .wrap { position: relative; z-index: 2; }

/* Images: soft shadow, no outline */
.frame img { box-shadow: 0 24px 50px -24px rgba(74, 10, 14, .45); }
.frame--arch img { border-radius: 999px 999px var(--radius) var(--radius); }
.frame--tall img { object-position: top; background: #fff; }

.pull { margin: 0 0 20px; font: italic 500 1.5rem/1.45 var(--serif); color: #fff; padding-left: 22px; border-left: 3px solid var(--gold); }
.center { text-align: center; margin-top: 36px; }

/* Cards get a five-colour edge on hover */
.card { position: relative; }
.card::after { content: ""; position: absolute; left: 0; right: 0; top: 0; height: 5px; background: linear-gradient(90deg, var(--flag-blue) 0 20%, var(--flag-white) 20% 40%, var(--flag-red) 40% 60%, var(--flag-green) 60% 80%, var(--flag-yellow) 80%); transform: scaleX(0); transform-origin: left; transition: transform .45s; }
.card:hover::after { transform: scaleX(1); }
.pillar { position: relative; overflow: hidden; }
.merit { text-decoration: none; }
.stats { border: 2px solid var(--gold); }

/* Hero scroll cue */
.hero__scroll { position: absolute; z-index: 3; left: 50%; bottom: 76px; width: 26px; height: 42px; margin-left: -13px; border: 2px solid rgba(255,255,255,.7); border-radius: 14px; }
.hero__scroll span { position: absolute; left: 50%; top: 8px; width: 4px; height: 8px; margin-left: -2px; border-radius: 2px; background: var(--gold); animation: cue 1.8s infinite; }
@keyframes cue { 0% { transform: translateY(0); opacity: 1; } 80% { transform: translateY(14px); opacity: 0; } 100% { opacity: 0; } }

/* ---------- Scroll effects ---------- */
.progress { position: fixed; z-index: 120; left: 0; top: 0; height: 3px; width: 100%; transform-origin: 0 50%; transform: scaleX(0); background: linear-gradient(90deg, var(--red), var(--gold)); }

.reveal { opacity: 0; transform: translateY(36px); transition: opacity .9s cubic-bezier(.2,.7,.2,1), transform .9s cubic-bezier(.2,.7,.2,1), clip-path 1.1s cubic-bezier(.7,0,.2,1); }
.reveal[data-reveal="left"] { transform: translateX(-60px); }
.reveal[data-reveal="right"] { transform: translateX(60px); }
.reveal[data-reveal="zoom"] { transform: scale(.88); }
.reveal.in { opacity: 1; transform: none; }
/* Images unveil like a curtain being drawn */
.frame.reveal img, .program__img.reveal > img { clip-path: inset(0 0 100% 0); transition: clip-path 1.2s cubic-bezier(.7,0,.2,1) .15s, transform 1.2s; transform: scale(1.12); }
.frame.reveal.in img, .program__img.reveal.in > img { clip-path: inset(0 0 0 0); transform: none; }
/* Divider clouds float in from the side */
.ornament .cloud { transition: transform 1s cubic-bezier(.2,.7,.2,1) .25s, opacity 1s .25s; }
.reveal:not(.in) .ornament .cloud { opacity: 0; transform: translateX(-28px); }

/* Headline words rise one by one */
.split-in .w { display: inline-block; overflow: hidden; vertical-align: top; padding-bottom: .18em; margin-bottom: -.18em; }
.split-in .w > span { display: inline-block; transform: translateY(105%); transition: transform .9s cubic-bezier(.2,.7,.2,1); transition-delay: calc(var(--d) * 90ms + 150ms); }
.split-in.in .w > span { transform: none; }

[data-parallax] { will-change: transform; }

.totop { position: fixed; z-index: 90; right: 18px; bottom: 18px; width: 48px; height: 48px; border-radius: 50%; background: var(--red); color: #fff; display: grid; place-items: center; font: 700 1.3rem var(--sans); box-shadow: 0 10px 24px -8px rgba(74,10,14,.6); opacity: 0; transform: translateY(20px); pointer-events: none; transition: .3s; border: 2px solid var(--gold); }
.totop.on { opacity: 1; transform: none; pointer-events: auto; }
.totop:hover { background: var(--red-dark); color: #fff; }

/* Hero slides container (parallax) and text contrast */
.hero__slides { position: absolute; inset: -12% 0 0; }
.hero__slides img { height: 100%; }
.hero::after { background: linear-gradient(90deg, rgba(40,6,8,.82) 0%, rgba(40,6,8,.5) 45%, rgba(40,6,8,.1) 75%), linear-gradient(180deg, rgba(40,6,8,.35) 0%, transparent 30%, transparent 60%, rgba(40,6,8,.85) 100%); }
.hero__eyebrow { text-shadow: 0 1px 8px rgba(0,0,0,.5); }

@media (max-width: 720px) {
  .hero .hero__content { padding-top: 100px; }
  .sky .cloud--a { width: 220px; right: -40px; }
  .sky .cloud--b, .sky .cloud--c { display: none; }
  .page-hero .sky .cloud--a { width: 200px; right: -30px; }
  .hero__scroll { display: none; }
  .frame--arch img { border-radius: 200px 200px var(--radius) var(--radius); }
  .totop { width: 44px; height: 44px; right: 12px; bottom: 12px; }
  .sky--section .cloud--s1 { width: 190px; }
  .sky--section .cloud--s2 { width: 170px; }
  .sky--section .cloud--s3 { display: none; }
}

@media (prefers-reduced-motion: reduce) {
  .hero__scroll span { animation: none; }
  .reveal, .reveal[data-reveal], .frame.reveal img, .program__img.reveal > img, .split-in .w > span, .ornament .cloud { opacity: 1 !important; transform: none !important; clip-path: none; transition: none; }
}
.hero__eyebrow::before { content: none; }

/* Clouds float slowly left and right. Uses the separate `translate` property so it
   combines with the scroll-linked `transform` set by main.js. */
@keyframes float-right { 0%, 100% { translate: 0 0; } 50% { translate: 70px -6px; } }
@keyframes float-left  { 0%, 100% { translate: 0 0; } 50% { translate: -70px 6px; } }
.sky .cloud { animation: float-right 26s ease-in-out infinite; }
.sky .cloud--b, .sky .cloud--s2 { animation-name: float-left; animation-duration: 32s; animation-delay: -8s; }
.sky .cloud--c, .sky .cloud--s3 { animation-duration: 22s; animation-delay: -14s; }
.sky--flip .cloud--s1 { animation-name: float-left; }
.sky--flip .cloud--s2 { animation-name: float-right; }
@keyframes float-small { 0%, 100% { translate: 0 0; } 50% { translate: 24px 0; } }
@media (prefers-reduced-motion: reduce) { .sky .cloud, .support__cloud { animation: none; } }

/* Title font: Prata (single weight, regular numerals). No faux bold or italic. */
h1, h2, h3, h4, .brand strong, .stats strong, .merit__num, .tier strong, .footer h3, .founder__card strong,
.prose blockquote, .pull, .quote-band blockquote, .support__title, .lightbox figcaption { font-weight: 400; font-style: normal; font-variant-numeric: lining-nums; }
h1 { font-size: clamp(2rem, 4.2vw, 3.3rem); line-height: 1.18; }
h2 { font-size: clamp(1.6rem, 2.9vw, 2.3rem); line-height: 1.22; }
h3 { font-size: 1.26rem; }
.brand strong { font-size: 1.2rem; }
.stats strong { font-size: 2rem; }
.card__body h3 { font-size: 1.2rem; }
.tier strong { font-size: 1.5rem; }
.footer h3 { font-size: 1.1rem; }
.prose blockquote, .pull { font-size: 1.15rem; line-height: 1.55; }
.quote-band blockquote { font-size: clamp(1.25rem, 2.4vw, 1.7rem); line-height: 1.5; }
.support__title { font-size: clamp(1.55rem, 3vw, 2.3rem); line-height: 1.35; }
@media (max-width: 720px) { .brand strong { font-size: 1rem; } }

/* Keep hero buttons clear of the stats strip that overlaps the bottom of the banner */
.hero .hero__content { padding-bottom: 130px; }
.hero__dots { bottom: 84px; }
.hero__scroll { bottom: 96px; }
@media (max-width: 720px) {
  .hero .hero__content { padding-bottom: 120px; }
  .hero__dots { bottom: 74px; }
}

/* ---------- Support the Monastery (above the footer) ---------- */
.support { position: relative; overflow: hidden; text-align: center; color: #f3e2c8; padding: 84px 0 90px;
  background: radial-gradient(ellipse 70% 90% at 50% 0%, rgba(242,169,31,.22), transparent 60%), linear-gradient(180deg, #7a1016 0%, #4a0a0e 100%); }
.support::before, .support::after { content: ""; position: absolute; left: 50%; width: min(1100px, 92%); height: 1px; transform: translateX(-50%); background: linear-gradient(90deg, transparent, rgba(242,169,31,.7), transparent); }
.support::before { top: 22px; }
.support::after { bottom: 22px; }
.support__in { position: relative; z-index: 2; max-width: 760px; }
.support__emblem { display: inline-grid; place-items: center; width: 88px; height: 88px; border-radius: 50%; margin-bottom: 18px; color: var(--gold);
  border: 1px solid rgba(242,169,31,.55); box-shadow: 0 0 0 7px rgba(242,169,31,.08), inset 0 0 22px rgba(242,169,31,.15); }
.support__emblem .lotus { width: 52px; height: 40px; }
.support__kicker { margin: 0 0 10px; font: 700 .8rem var(--sans); letter-spacing: .32em; text-transform: uppercase; color: var(--gold); }
.support__title { margin: 0 0 16px; color: #fff; font-family: var(--serif); font-style: normal; font-weight: 400; font-size: clamp(1.55rem, 3vw, 2.3rem); line-height: 1.35; }
.support__text { margin: 0 auto 30px; max-width: 560px; font-size: 1.08rem; color: #ead2b4; }
.support__actions { display: flex; align-items: center; justify-content: center; gap: 26px; flex-wrap: wrap; }
.btn-offer { position: relative; overflow: hidden; display: inline-flex; align-items: center; justify-content: center; padding: 16px 34px; border-radius: 6px;
  font: 700 .9rem var(--sans); letter-spacing: .16em; text-transform: uppercase; color: var(--maroon);
  background: linear-gradient(180deg, #f8d47a 0%, #f2a91f 100%); border: 1px solid #f8d47a;
  box-shadow: 0 10px 26px -10px rgba(0,0,0,.6), inset 0 1px 0 rgba(255,255,255,.6); transition: transform .25s, box-shadow .25s; }
.btn-offer::before { content: ""; position: absolute; top: 0; left: -60%; width: 40%; height: 100%; background: linear-gradient(100deg, transparent, rgba(255,255,255,.65), transparent); transform: skewX(-20deg); transition: left .7s; }
.btn-offer:hover { color: var(--maroon); transform: translateY(-2px); box-shadow: 0 16px 30px -12px rgba(0,0,0,.7), inset 0 1px 0 rgba(255,255,255,.6); }
.btn-offer:hover::before { left: 120%; }
.btn-offer span { position: relative; }
.support__link { color: #f8d47a; font-weight: 600; letter-spacing: .04em; border-bottom: 1px solid rgba(248,212,122,.5); padding-bottom: 2px; }
.support__link:hover { color: #fff; border-color: #fff; }
.support__cloud { position: absolute; z-index: 1; color: var(--gold); opacity: .18; pointer-events: none; animation: float-right 28s ease-in-out infinite; }
.support__cloud--l { width: 340px; left: -60px; top: 40px; }
.support__cloud--r { width: 300px; right: -50px; bottom: 30px; animation-name: float-left; animation-duration: 34s; }
@media (max-width: 720px) {
  .support { padding: 64px 0 70px; }
  .support__cloud--l { width: 200px; left: -70px; top: 20px; }
  .support__cloud--r { width: 180px; right: -60px; }
  .support__title br { display: none; }
  .btn-offer { width: 100%; }
}

/* Footer link colours must not override the support button/link */
.footer .btn-offer, .footer .btn-offer:hover { color: var(--maroon); }
.footer .support__link { color: #f8d47a; }
.footer .support__link:hover { color: #fff; }

/* Donate page: bank accounts */
.banks { display: grid; gap: 18px; }
.banks .bank h3 { margin-bottom: 14px; }
.bank--alt { border-top-color: var(--gold); }
.banks__note { margin: 0; color: var(--muted); font-size: .95rem; }
.btn-offer { gap: 10px; }
.btn-offer .namaste { position: relative; width: 22px; height: 22px; flex: none; transition: transform .35s; }
.btn-offer:hover .namaste { transform: translateY(-2px) scale(1.08); }
.nav__donate .heart { width: 17px; height: 17px; fill: currentColor; stroke-width: 1.4; }
.nav__donate:hover .heart { animation: beat .9s ease-in-out; }
@keyframes beat { 0%, 100% { transform: scale(1); } 30% { transform: scale(1.25); } 60% { transform: scale(.95); } }
/* Namaste: true 1px line regardless of icon size */
.btn-offer .namaste path { vector-effect: non-scaling-stroke; }
.btn-offer .namaste { width: 24px; height: 24px; }
/* Heart on the Donate button: red, not dark */
.nav__donate .heart { color: #c4161c; fill: #c4161c; stroke: #c4161c; }
.nav__donate:hover .heart { color: #a30f15; fill: #a30f15; stroke: #a30f15; }

/* ---------- Vision & Mission ---------- */
.purpose { display: grid; grid-template-columns: 1fr 1fr; gap: 28px; align-items: stretch; }
.purpose__card { position: relative; overflow: hidden; border-radius: 20px; padding: 46px 44px 40px; display: flex; flex-direction: column;
  transition: transform .4s, box-shadow .4s; }
.purpose__card:hover { transform: translateY(-6px); }
.purpose__card + .purpose__card { transition-delay: .12s; }
.purpose__card--vision { color: #f3e2c8;
  background: radial-gradient(ellipse 80% 60% at 100% 0%, rgba(242,169,31,.22), transparent 60%), linear-gradient(160deg, #8a1219 0%, #4a0a0e 100%);
  box-shadow: 0 30px 60px -30px rgba(74,10,14,.7); }
.purpose__card--mission { background: #fff; border: 1px solid var(--line); box-shadow: 0 30px 60px -36px rgba(74,10,14,.35); }
.purpose__card--mission::before { content: ""; position: absolute; inset: 0 0 auto; height: 5px; background: linear-gradient(90deg, var(--red), var(--gold)); }

.purpose__num { position: absolute; top: 18px; right: 30px; font: 400 5.5rem/1 var(--serif); font-variant-numeric: lining-nums; color: transparent;
  -webkit-text-stroke: 1px rgba(242,169,31,.55); letter-spacing: -.02em; pointer-events: none; }
.purpose__card--mission .purpose__num { -webkit-text-stroke-color: rgba(181,22,29,.28); }
.purpose__tag { margin: 0 0 6px; font: 700 .76rem var(--sans); letter-spacing: .26em; text-transform: uppercase; color: var(--gold); }
.purpose__card--mission .purpose__tag { color: var(--red); }
.purpose__title { margin: 0; font-size: clamp(1.8rem, 2.6vw, 2.3rem) !important; color: #fff; position: relative; z-index: 1; }
.purpose__card--mission .purpose__title { color: var(--maroon); }
.purpose__rule { display: block; width: 56px; height: 2px; margin: 18px 0 22px; background: var(--gold); }
.purpose__lead { margin: 0 0 18px; font-size: 1.05rem; }

.purpose__list { list-style: none; margin: 0; padding: 0; position: relative; z-index: 1; }
.purpose__list li { display: grid; grid-template-columns: 44px 1fr; gap: 6px; align-items: baseline; padding: 15px 0; border-top: 1px solid rgba(243,226,200,.16); font-size: 1.02rem; line-height: 1.55; }
.purpose__card--mission .purpose__list li { border-top-color: var(--line); color: #3e2c24; }
.purpose__list li:last-child { padding-bottom: 0; }
.purpose__i { font: 400 1.05rem var(--serif); font-variant-numeric: lining-nums; color: var(--gold); }
.purpose__card--mission .purpose__i { color: var(--red); }

/* points slide in one after another when the card appears */
.purpose__card .purpose__list li { opacity: 0; transform: translateX(-14px); transition: opacity .6s, transform .6s; }
.purpose__card.in .purpose__list li { opacity: 1; transform: none; }
.purpose__card.in .purpose__list li:nth-child(1) { transition-delay: .25s; }
.purpose__card.in .purpose__list li:nth-child(2) { transition-delay: .35s; }
.purpose__card.in .purpose__list li:nth-child(3) { transition-delay: .45s; }
.purpose__card.in .purpose__list li:nth-child(4) { transition-delay: .55s; }
.purpose__card.in .purpose__list li:nth-child(n+5) { transition-delay: .65s; }

.purpose__cloud { position: absolute; right: -50px; bottom: -18px; width: 260px; opacity: .12; color: var(--gold); pointer-events: none; animation: float-left 30s ease-in-out infinite; }
.purpose__card--mission .purpose__cloud { color: var(--red); opacity: .07; animation-name: float-right; }

@media (max-width: 860px) {
  .purpose { grid-template-columns: 1fr; gap: 20px; }
  .purpose__card { padding: 36px 26px 30px; }
  .purpose__num { font-size: 4.2rem; right: 20px; }
}
@media (prefers-reduced-motion: reduce) {
  .purpose__card .purpose__list li { opacity: 1; transform: none; }
  .purpose__cloud { animation: none; }
}

/* Vision & Mission: icons instead of numbers */
.purpose__num { display: none; }
.purpose__mark { position: absolute; top: 26px; right: 30px; width: 86px; height: 86px; color: rgba(242,169,31,.5); pointer-events: none; }
.purpose__mark .icon { width: 100%; height: 100%; stroke-width: 1; }
.purpose__card--mission .purpose__mark { color: rgba(181,22,29,.22); }
.purpose__list li { grid-template-columns: 50px 1fr; align-items: center; }
.purpose__i { display: grid; place-items: center; width: 38px; height: 38px; border-radius: 50%; border: 1px solid rgba(242,169,31,.55); color: var(--gold); background: rgba(242,169,31,.08); }
.purpose__i .icon { width: 19px; height: 19px; stroke-width: 1.4; }
.purpose__card--mission .purpose__i { border-color: rgba(181,22,29,.3); color: var(--red); background: #fbf2ec; }
@media (max-width: 860px) { .purpose__mark { width: 64px; height: 64px; right: 22px; } }
