/* ============================================================
  FinPak Tampere
   Shared stylesheet — Scandinavian clarity, Pakistani warmth
   ============================================================ */

:root {
  --emerald: #0B6E4F;
  --emerald-dark: #08523B;
  --emerald-deep: #063D2C;
  --emerald-tint: #E9F4EF;
  --gold: #D4AF37;
  --gold-soft: #F7EFD6;
  --bg: #F8F9FA;
  --white: #FFFFFF;
  --ink: #1F2937;
  --muted: #5B6672;
  --line: #E5E8EB;
  --radius: 18px;
  --radius-sm: 12px;
  --shadow: 0 6px 24px rgba(8, 82, 59, 0.08);
  --shadow-lift: 0 14px 36px rgba(8, 82, 59, 0.14);
  --shadow-float: 0 20px 44px rgba(8, 82, 59, .22), 0 6px 16px rgba(8, 82, 59, .12), 0 0 0 1px rgba(11, 110, 79, .07);
  --ease-premium: cubic-bezier(0.22, 1, 0.36, 1);
  --font-display: "Sora", "Segoe UI", sans-serif;
  --font-body: "Karla", "Segoe UI", sans-serif;
  --font-urdu: "Noto Nastaliq Urdu", serif;
  --wrap: 100%;
}

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

html { scroll-behavior: smooth; }

body {
  font-family: var(--font-body);
  font-size: 17px;
  line-height: 1.65;
  color: var(--ink);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
}

html[lang="ur"] body { font-family: var(--font-urdu), var(--font-body); line-height: 2; }
html[dir="rtl"] .nav-links, html[dir="rtl"] .footer-grid { direction: rtl; }

img { max-width: 100%; display: block; }
a { color: var(--emerald); text-decoration: none; }
a:hover { color: var(--emerald-dark); }

h1, h2, h3, h4 {
  font-family: var(--font-display);
  line-height: 1.18;
  color: var(--ink);
  font-weight: 700;
  letter-spacing: -0.01em;
}

h1 { font-size: clamp(2.1rem, 5vw, 3.4rem); }
h2 { font-size: clamp(1.6rem, 3.4vw, 2.3rem); }
h3 { font-size: 1.22rem; }

.wrap { max-width: var(--wrap); margin: 0 auto; padding: 0 clamp(22px, 4vw, 64px); }
.site-header .wrap, .site-footer .wrap { padding-left: clamp(24px, 3vw, 40px); padding-right: clamp(24px, 3vw, 40px); }
section { padding: 72px 0; }

.eyebrow {
  display: inline-flex; align-items: center; gap: 10px;
  font-family: var(--font-display);
  font-size: 0.78rem; font-weight: 600;
  letter-spacing: 0.14em; text-transform: uppercase;
  color: var(--emerald);
  margin-bottom: 14px;
}
.eyebrow::before {
  content: ""; width: 22px; height: 22px; flex: none;
  background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 40 40'%3E%3Cpath d='M20 2 L25 15 L38 20 L25 25 L20 38 L15 25 L2 20 L15 15 Z' fill='none' stroke='%23D4AF37' stroke-width='2.4'/%3E%3C/svg%3E") center/contain no-repeat;
}

.section-head { max-width: 640px; margin-bottom: 42px; }
.section-head p { color: var(--muted); margin-top: 12px; }
.section-head.center { margin-left: auto; margin-right: auto; text-align: center; }
.section-head.center .eyebrow { justify-content: center; }

/* ---------- Khatam lattice (signature pattern) ---------- */
.lattice {
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='96' height='96' viewBox='0 0 96 96'%3E%3Cg fill='none' stroke='%23FFFFFF' stroke-opacity='0.10' stroke-width='1.4'%3E%3Cpath d='M48 8 L58 38 L88 48 L58 58 L48 88 L38 58 L8 48 L38 38 Z'/%3E%3Ccircle cx='48' cy='48' r='10'/%3E%3Cpath d='M0 0 L16 16 M96 0 L80 16 M0 96 L16 80 M96 96 L80 80'/%3E%3C/g%3E%3C/svg%3E");
}
.divider {
  height: 46px;
  background:
    url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='72' height='46' viewBox='0 0 72 46'%3E%3Cpath d='M36 6 L43 19 L58 23 L43 27 L36 40 L29 27 L14 23 L29 19 Z' fill='none' stroke='%230B6E4F' stroke-opacity='0.18' stroke-width='1.6'/%3E%3C/svg%3E") center repeat-x;
}

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  font-family: var(--font-display); font-weight: 600; font-size: 0.95rem;
  padding: 13px 26px; border-radius: 999px; border: 2px solid transparent;
  cursor: pointer; transition: transform .18s ease, box-shadow .18s ease, background .18s ease;
}
.btn:active { transform: translateY(1px); }
.btn-primary { background: var(--emerald); color: #fff; }
.btn-primary:hover { background: var(--emerald-dark); color: #fff; box-shadow: var(--shadow-lift); transform: translateY(-2px); }
.btn-gold { background: var(--gold); color: var(--emerald-deep); }
.btn-gold:hover { background: #C7A02C; box-shadow: var(--shadow-lift); transform: translateY(-2px); }
.btn-ghost { background: transparent; color: #fff; border-color: rgba(255,255,255,.55); }
.btn-ghost:hover { background: rgba(255,255,255,.12); color: #fff; }
.btn-outline { background: #fff; color: var(--emerald); border-color: var(--emerald); }
.btn-outline:hover { background: var(--emerald-tint); }

/* ---------- Header ---------- */
.site-header {
  position: sticky; top: 0; z-index: 100;
  background: rgba(255,255,255,.94);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--line);
}
.header-inner { display: flex; align-items: center; gap: 24px; height: 74px; }
.header-inner { position: relative; }
.brand { display: flex; align-items: center; gap: 12px; font-family: var(--font-display); }
.brand-mark {
  width: 44px; height: 44px; flex: none; border-radius: 12px;
  background: var(--emerald);
  display: grid; place-items: center;
}
.brand-mark svg { width: 26px; height: 26px; }
.brand-name { font-weight: 700; font-size: 0.98rem; color: var(--ink); line-height: 1.2; }
.brand-name small { display: block; font-weight: 500; font-size: 0.68rem; color: var(--gold); letter-spacing: .02em; }

.nav-links { display: flex; gap: 4px; margin-left: auto; list-style: none; }
.nav-links a {
  display: block; padding: 9px 14px; border-radius: 999px;
  font-family: var(--font-display); font-size: 0.88rem; font-weight: 600; color: var(--ink);
}
.nav-links a:hover { background: var(--emerald-tint); color: var(--emerald-dark); }
.nav-links a.active { background: var(--emerald); color: #fff; }

.lang-toggle { display: flex; gap: 2px; background: var(--bg); border: 1px solid var(--line); border-radius: 999px; padding: 3px; }
.lang-toggle button {
  border: 0; background: transparent; cursor: pointer;
  font-family: var(--font-display); font-size: 0.78rem; font-weight: 700;
  padding: 6px 12px; border-radius: 999px; color: var(--muted);
}
.lang-toggle button.active { background: var(--emerald); color: #fff; }

.lang-switch {
  display: none;
  appearance: none;
  background: var(--bg) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='14' height='14' viewBox='0 0 20 20'%3E%3Cpath d='M5 7l5 6 5-6' fill='none' stroke='%235B6672' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E") no-repeat right 12px center;
  border: 1px solid var(--line); border-radius: 999px; color: var(--muted);
  font-family: var(--font-display); font-size: 0.78rem; font-weight: 700;
  padding: 6px 34px 6px 12px; cursor: pointer; line-height: 1;
}
.lang-switch:focus { outline: none; border-color: var(--emerald); box-shadow: 0 0 0 3px rgba(11,110,79,.12); }

.nav-toggle { display: none; margin-left: auto; background: none; border: 0; cursor: pointer; padding: 8px; }
.nav-toggle span { display: block; width: 24px; height: 2.5px; background: var(--ink); margin: 5px 0; border-radius: 2px; transition: .2s; }

/* ---------- Hero ---------- */
.hero {
  background: linear-gradient(150deg, var(--emerald-deep) 0%, var(--emerald) 62%, #0E8560 100%);
  color: #fff; padding: 96px 0 110px; position: relative; overflow: hidden;
}
.hero .wrap { position: relative; z-index: 1; display: grid; grid-template-columns: 1.15fr .85fr; gap: 56px; align-items: center; }
.hero h1 { color: #fff; }
.hero h1 em { font-style: normal; color: var(--gold); }
.hero p.lead { font-size: 1.15rem; color: rgba(255,255,255,.88); margin: 20px 0 30px; max-width: 34em; }
.hero-cta { display: flex; flex-wrap: wrap; gap: 12px; }
.hero-visual { position: relative; }
.hero-visual .photo-frame { border-radius: 26px; overflow: hidden; box-shadow: 0 24px 60px rgba(0,0,0,.28); transform: rotate(1.5deg); }
.hero-badge {
  position: absolute; bottom: -18px; left: -14px;
  background: #fff; color: var(--ink); border-radius: 16px; box-shadow: var(--shadow-lift);
  padding: 14px 18px; display: flex; gap: 12px; align-items: center;
  font-family: var(--font-display); font-size: .85rem; font-weight: 600;
}
.hero-badge .dot { width: 10px; height: 10px; border-radius: 50%; background: var(--gold); }

/* Page hero (inner pages) */
.page-hero {
  background: linear-gradient(140deg, var(--emerald-deep), var(--emerald));
  color: #fff; padding: 64px 0; position: relative;
}
.page-hero h1 { color: #fff; }
.page-hero p { color: rgba(255,255,255,.85); margin-top: 12px; max-width: 42em; }
.breadcrumb { font-size: .82rem; color: rgba(255,255,255,.65); margin-bottom: 14px; font-family: var(--font-display); }
.breadcrumb a { color: rgba(255,255,255,.85); }

/* ---------- Stats ---------- */
.stats { background: #fff; border-bottom: 1px solid var(--line); padding: 54px 0; }
.stats-grid { display: grid; grid-template-columns: repeat(5, 1fr); gap: 18px; text-align: center; }
.stat b { display: block; font-family: var(--font-display); font-size: clamp(1.7rem, 3.4vw, 2.5rem); color: var(--emerald); }
.stat b .plus {
  display: inline-block; color: var(--gold);
  opacity: 0; transform: scale(.5);
  transition: opacity .4s var(--ease-premium), transform .4s var(--ease-premium);
}
.stat b.counted .plus { opacity: 1; transform: scale(1); }
.stat span { font-size: .86rem; color: var(--muted); }

@media (prefers-reduced-motion: reduce) {
  .stat b .plus { opacity: 1; transform: none; transition: none; }
}

/* ---------- Cards ---------- */
.grid { display: grid; gap: 24px; }
.grid.cols-3 { grid-template-columns: repeat(3, 1fr); }
.grid.cols-4 { grid-template-columns: repeat(4, 1fr); }
.grid.cols-2 { grid-template-columns: repeat(2, 1fr); }

.card {
  background: #fff; border: 1px solid var(--line); border-radius: var(--radius);
  box-shadow: var(--shadow); overflow: hidden;
  transition: transform .2s ease, box-shadow .2s ease;
}
.card:hover { transform: translateY(-5px); box-shadow: var(--shadow-lift); }
.card-body { padding: 24px; }
.card-body p { color: var(--muted); font-size: .95rem; margin-top: 8px; }

.event-card .event-date {
  display: inline-flex; flex-direction: column; align-items: center;
  background: var(--emerald-tint); color: var(--emerald-dark);
  border-radius: var(--radius-sm); padding: 10px 16px;
  font-family: var(--font-display); font-weight: 700; line-height: 1.1;
}
.event-card .event-date b { font-size: 1.5rem; }
.event-card .event-date span { font-size: .72rem; letter-spacing: .1em; text-transform: uppercase; }
.event-meta { display: flex; flex-wrap: wrap; gap: 14px; color: var(--muted); font-size: .85rem; margin: 12px 0 16px; }
.event-meta span { display: inline-flex; align-items: center; gap: 6px; }
.event-banner { height: 150px; }

.service-card { padding: 26px; text-align: left; }
.service-icon {
  width: 52px; height: 52px; border-radius: 14px; margin-bottom: 16px;
  background: var(--emerald-tint); color: var(--emerald);
  display: grid; place-items: center; font-size: 1.4rem;
}
.card:hover .service-icon { background: var(--gold-soft); color: var(--emerald-dark); }

/* ---------- Photo placeholders (replace with real photos) ---------- */
.ph {
  position: relative; display: grid; place-items: center;
  color: rgba(255,255,255,.92); text-align: center;
  font-family: var(--font-display); font-size: .82rem; font-weight: 600; letter-spacing: .04em;
  min-height: 160px;
  background:
    url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='72' height='72' viewBox='0 0 72 72'%3E%3Cpath d='M36 6 L43.5 28.5 L66 36 L43.5 43.5 L36 66 L28.5 43.5 L6 36 L28.5 28.5 Z' fill='none' stroke='%23FFFFFF' stroke-opacity='0.14' stroke-width='1.4'/%3E%3C/svg%3E"),
    linear-gradient(140deg, var(--emerald-dark), var(--emerald) 70%, #0E8560);
}
.ph.gold { background:
    url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='72' height='72' viewBox='0 0 72 72'%3E%3Cpath d='M36 6 L43.5 28.5 L66 36 L43.5 43.5 L36 66 L28.5 43.5 L6 36 L28.5 28.5 Z' fill='none' stroke='%23FFFFFF' stroke-opacity='0.22' stroke-width='1.4'/%3E%3C/svg%3E"),
    linear-gradient(140deg, #B8952C, var(--gold)); color: var(--emerald-deep); }
.ph small { display: block; font-weight: 400; opacity: .75; margin-top: 4px; }

/* ---------- Gallery ---------- */
.masonry { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; }
.masonry .g-item { border-radius: var(--radius-sm); overflow: hidden; box-shadow: var(--shadow); }
.masonry .ph { min-height: 220px; }
.ph.photo-center {
  color: #fff;
  text-shadow: 0 1px 2px rgba(0,0,0,.4);
  background:
    linear-gradient(rgba(0,0,0,.28), rgba(0,0,0,.28)),
    var(--photo) center/cover no-repeat;
}

/* ---------- Testimonials ---------- */
.quote-card { padding: 28px; position: relative; }
.quote-card::before {
  content: "\201C"; font-family: Georgia, serif; font-size: 4rem; line-height: 1;
  color: var(--gold); position: absolute; top: 14px; right: 22px; opacity: .5;
}
.quote-card blockquote { font-size: 1rem; color: var(--ink); }
.quote-who { display: flex; align-items: center; gap: 12px; margin-top: 18px; }
.avatar {
  width: 44px; height: 44px; border-radius: 50%; flex: none;
  background: var(--emerald); color: #fff; display: grid; place-items: center;
  font-family: var(--font-display); font-weight: 700;
}
.avatar.gold { color: var(--gold); }
.quote-who b { display: block; font-size: .92rem; }
.quote-who span { font-size: .8rem; color: var(--muted); }

/* ---------- CTA band ---------- */
.cta-band {
  background: linear-gradient(140deg, var(--emerald-deep), var(--emerald));
  color: #fff; border-radius: 26px; padding: 56px 48px;
  display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 26px;
  position: relative; overflow: hidden;
}
.cta-band h2 { color: #fff; }
.cta-band p { color: rgba(255,255,255,.85); margin-top: 10px; max-width: 34em; }

/* ---------- News ---------- */
.news-card .ph { height: 170px; }
.news-date { font-size: .78rem; color: var(--gold); font-weight: 700; letter-spacing: .08em; text-transform: uppercase; font-family: var(--font-display); }

/* ---------- Forms ---------- */
.form-card { background: #fff; border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow); padding: 34px; }
.form-note { font-size: .82rem; color: var(--muted); }

/* ---------- Filters / chips ---------- */
.chips { display: flex; flex-wrap: wrap; gap: 10px; margin-bottom: 34px; }
.chip {
  font-family: var(--font-display); font-size: .82rem; font-weight: 600;
  padding: 8px 16px; border-radius: 999px; border: 1.5px solid var(--line);
  background: #fff; color: var(--muted); cursor: pointer; transition: .15s;
}
.chip:hover { border-color: var(--emerald); color: var(--emerald); }
.chip.active { background: var(--emerald); border-color: var(--emerald); color: #fff; }

/* ---------- FAQ ---------- */
details.faq { background: #fff; border: 1px solid var(--line); border-radius: var(--radius-sm); padding: 18px 22px; margin-bottom: 12px; }
details.faq summary { font-family: var(--font-display); font-weight: 600; cursor: pointer; list-style: none; display: flex; justify-content: space-between; align-items: center; }
details.faq summary::after { content: "+"; color: var(--gold); font-size: 1.4rem; font-weight: 400; }
details.faq[open] summary::after { content: "\2212"; }
details.faq p { margin-top: 12px; color: var(--muted); font-size: .95rem; }

/* ---------- Footer ---------- */
.site-footer { background: var(--emerald-deep); color: rgba(255,255,255,.8); margin-top: 40px; }
.footer-top { padding: 60px 0 40px; }
.footer-grid { display: grid; grid-template-columns: 1.4fr 1fr 1fr 1.4fr; gap: 32px 40px; }
.site-footer h4 { color: #fff; font-size: .95rem; margin-bottom: 16px; }
.site-footer ul { list-style: none; }
.site-footer li { margin-bottom: 9px; }
.site-footer a { color: rgba(255,255,255,.8); font-size: .92rem; }
.site-footer a:hover { color: var(--gold); }
.footer-brand p { font-size: .9rem; margin-top: 14px; max-width: 30em; }
.social-row { display: flex; gap: 10px; margin-top: 18px; }
.social-row a {
  width: 40px; height: 40px; border-radius: 50%; display: grid; place-items: center;
  background: rgba(255,255,255,.1); color: #fff; transition: .15s;
}
.social-row a:hover { background: var(--gold); color: var(--emerald-deep); }
.footer-bottom { border-top: 1px solid rgba(255,255,255,.14); padding: 20px 0; font-size: .82rem; display: flex; flex-wrap: wrap; gap: 10px; justify-content: space-between; }

/* ---------- Floating buttons ---------- */
.fab-whatsapp {
  position: fixed; bottom: 24px; right: 24px; z-index: 90;
  width: 56px; height: 56px; border-radius: 50%;
  background: #25D366; color: #fff; display: grid; place-items: center;
  box-shadow: 0 10px 26px rgba(0,0,0,.25); transition: transform .15s;
}
.fab-whatsapp:hover { transform: scale(1.08); color: #fff; }
.back-top {
  position: fixed; bottom: 92px; right: 24px; z-index: 90;
  width: 44px; height: 44px; border-radius: 50%; border: 0; cursor: pointer;
  background: var(--emerald); color: #fff; font-size: 1.1rem;
  box-shadow: var(--shadow-lift); opacity: 0; pointer-events: none; transition: opacity .25s;
}
.back-top.show { opacity: 1; pointer-events: auto; }

/* ---------- Reveal on scroll ---------- */
.reveal { opacity: 0; transform: translateY(22px); transition: opacity .6s ease, transform .6s ease; }
.reveal.in { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .reveal { opacity: 1; transform: none; transition: none; }
  .card, .btn { transition: none; }
}

/* ---------- Utility ---------- */
.center { text-align: center; }
.mt-40 { margin-top: 40px; }
.alt-bg { background: #fff; }
.tag { display: inline-block; font-size: .72rem; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; font-family: var(--font-display); background: var(--gold-soft); color: #8A6D1B; border-radius: 999px; padding: 4px 12px; }
.tag.green { background: var(--emerald-tint); color: var(--emerald-dark); }

/* ---------- Responsive ---------- */
@media (max-width: 980px) {
  .header-inner { min-height: 74px; height: auto; padding: 10px 0; flex-wrap: nowrap; gap: 12px; }
  .brand { min-width: 0; flex: 1 1 auto; }
  .brand-name { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
  .brand-name small { display: none; }
  .lang-toggle { display: none; }
  .lang-switch { display: block; flex: none; margin-left: auto; max-width: 92px; padding-right: 30px; }
  .hero .wrap { grid-template-columns: 1fr; }
  .hero-visual { display: none; }
  .grid.cols-3, .grid.cols-4 { grid-template-columns: repeat(2, 1fr); }
  .masonry { grid-template-columns: repeat(2, 1fr); }
  .footer-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 28px 32px; }
  .nav-links {
    display: none; position: absolute; top: calc(100% + 12px); left: 0; right: 0;
    flex-direction: column; background: #fff; border-bottom: 1px solid var(--line);
    padding: 14px 22px 22px; gap: 6px; box-shadow: var(--shadow-lift);
  }
  .nav-links.open { display: flex; }
  .nav-toggle { display: block; }
  .nav-toggle { margin-left: 8px; }
}
@media (max-width: 620px) {
  section { padding: 52px 0; }
  .grid.cols-3, .grid.cols-4, .grid.cols-2 { grid-template-columns: 1fr; }
  .stats-grid { gap: 8px; }
  .stat b { font-size: 1.3rem; }
  .stat span { font-size: .62rem; }
  .masonry { grid-template-columns: 1fr; }
  .footer-grid { grid-template-columns: 1fr; }
  .footer-top { padding: 48px 0 32px; }
  .cta-band { padding: 40px 28px; }
  .hero { padding: 64px 0 72px; }
  .hero-cta { flex-direction: column; align-items: stretch; }
  .hero-cta .btn { width: 100%; }
  .cta-band .btn { width: 100%; }
  .site-header .wrap, .site-footer .wrap { padding-left: 18px; padding-right: 18px; }
  .header-inner { gap: 10px; }
  .brand-name { font-size: .88rem; }
  .lang-switch { max-width: 84px; font-size: .72rem; padding: 5px 28px 5px 10px; }
  .social-row { flex-wrap: wrap; }
  .footer-bottom { flex-direction: column; align-items: flex-start; }
  .event-card .card-body > div:first-child,
  .news-card .card-body > div:first-child,
  .form-card > div[style*="display:flex"] { flex-direction: column; align-items: flex-start; }
  .event-card .card-body > div:first-child { gap: 10px !important; }
}


/* ---- Expandable news articles ---- */
.news-full { display: none; margin-top: 12px; padding-top: 12px; border-top: 1px dashed rgba(11,110,79,.2); }
.news-full p + p { margin-top: 10px; }
.news-card.expanded .news-full { display: block; }
.news-card .rm-less { display: none; }
.news-card.expanded .rm-more { display: none; }

/* ============================================================
   Loading screen — night sky over Tampere
   ============================================================ */
html.is-loading, html.is-loading body { overflow: hidden; height: 100%; }
html.skip-loading, html.skip-loading body { overflow: visible !important; height: auto !important; }
html.skip-loading .loading-screen { display: none !important; }

.loading-screen {
  position: fixed; inset: 0; z-index: 99999;
  display: flex; align-items: center; justify-content: center;
  background:
    radial-gradient(ellipse 60% 46% at 50% 38%, rgba(120,145,210,.14), rgba(120,145,210,0) 70%),
    linear-gradient(160deg, #090B12 0%, #111827 100%);
  opacity: 1; visibility: visible;
  transition: opacity .5s ease, visibility 0s linear 0s;
}
.loading-screen.is-hidden {
  opacity: 0; visibility: hidden; pointer-events: none;
  transition: opacity .5s ease, visibility 0s linear .5s;
}

.loading-content {
  display: flex; flex-direction: column; align-items: center; gap: 18px;
  animation: loading-fade-up .7s ease both;
}

.loading-moon-wrap {
  position: relative; width: 148px; height: 148px;
  display: flex; align-items: center; justify-content: center;
}
.loading-moon {
  position: relative; z-index: 2; font-size: 46px; line-height: 1;
  filter: drop-shadow(0 0 14px rgba(198, 214, 255, .5)) drop-shadow(0 0 30px rgba(198, 214, 255, .28));
  animation: loading-moon-glow 4.5s ease-in-out infinite;
  transform: translateY(-1px);
}

.loading-orbit {
  position: absolute; inset: 0;
  animation: loading-orbit-spin 22s linear infinite;
}
.loading-star {
  position: absolute; top: 50%; left: 50%; width: 0; height: 0;
  transform: rotate(var(--angle, 0deg)) translateX(var(--radius, 60px));
}
.loading-star b {
  display: block; width: var(--size, 3px); height: var(--size, 3px);
  margin: calc(var(--size, 3px) / -2) 0 0 calc(var(--size, 3px) / -2);
  border-radius: 50%;
  background: #fff;
  box-shadow: 0 0 6px 1px rgba(255, 255, 255, .75);
  animation: loading-twinkle var(--dur, 2.6s) ease-in-out infinite;
  animation-delay: var(--delay, 0s);
}
.loading-star.gold b {
  background: #F3E3AE;
  box-shadow: 0 0 7px 1.5px rgba(212, 175, 55, .8);
}

.loading-title {
  font-family: var(--font-display); font-weight: 700;
  font-size: 1.3rem; letter-spacing: .01em; color: #fff;
}
.loading-subtitle {
  font-family: var(--font-body); font-size: .85rem;
  letter-spacing: .08em; text-transform: uppercase;
  color: #8992A6;
  display: inline-flex; align-items: baseline; gap: 2px;
}
.loading-subtitle .dot { animation: loading-dot 1.4s ease-in-out infinite; }
.loading-subtitle .dot:nth-child(2) { animation-delay: .2s; }
.loading-subtitle .dot:nth-child(3) { animation-delay: .4s; }

@keyframes loading-fade-up {
  from { opacity: 0; transform: translateY(10px); }
  to   { opacity: 1; transform: translateY(0); }
}
@keyframes loading-moon-glow {
  0%, 100% { filter: drop-shadow(0 0 12px rgba(198, 214, 255, .42)) drop-shadow(0 0 26px rgba(198, 214, 255, .22)); transform: scale(1) translateY(-1px); }
  50%      { filter: drop-shadow(0 0 20px rgba(198, 214, 255, .62)) drop-shadow(0 0 40px rgba(198, 214, 255, .36)); transform: scale(1.05) translateY(-1px); }
}
@keyframes loading-orbit-spin {
  from { transform: rotate(0deg); }
  to   { transform: rotate(360deg); }
}
@keyframes loading-twinkle {
  0%, 100% { opacity: .25; transform: scale(.75); }
  50%      { opacity: 1;   transform: scale(1.25); }
}
@keyframes loading-dot {
  0%, 80%, 100% { opacity: .25; }
  40%           { opacity: 1; }
}

@media (max-width: 560px) {
  .loading-moon-wrap { width: 120px; height: 120px; }
  .loading-moon { font-size: 38px; }
  .loading-title { font-size: 1.12rem; }
}

@media (prefers-reduced-motion: reduce) {
  .loading-content { animation: none; }
  .loading-moon { animation: none; filter: drop-shadow(0 0 16px rgba(198, 214, 255, .5)) drop-shadow(0 0 32px rgba(198, 214, 255, .28)); }
  .loading-orbit { animation: none; }
  .loading-star b { animation: none; opacity: .8; }
  .loading-subtitle .dot { animation: none; opacity: .7; }
  .loading-screen { transition: opacity .3s ease, visibility 0s linear 0s; }
  .loading-screen.is-hidden { transition: opacity .3s ease, visibility 0s linear .3s; }
}
.news-card.expanded .rm-less { display: inline; }

/* ============================================================
   Welcome toast — first-visit greeting
   ============================================================ */
.welcome-toast {
  position: fixed; z-index: 10000;
  left: 50%; bottom: 24px;
  display: flex; align-items: flex-start; gap: 12px;
  max-width: min(360px, calc(100vw - 32px));
  padding: 16px 20px;
  border-radius: var(--radius);
  background: rgba(255, 255, 255, .92);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border: 1px solid var(--line);
  box-shadow: var(--shadow-lift);
  opacity: 0; pointer-events: none;
  transform: translate(-50%, 14px) scale(.94);
  transition: opacity .3s ease, transform .3s ease;
}
.welcome-toast.is-visible { opacity: 1; transform: translate(-50%, 0) scale(1); }
.welcome-toast.is-leaving { opacity: 0; transform: translate(-50%, 8px) scale(.96); }

.welcome-toast-icon {
  font-size: 1.5rem; line-height: 1; flex: none;
  transform-origin: 70% 70%;
  display: inline-block;
  animation: welcome-wave 1.6s ease-in-out .35s 2;
}
.welcome-toast-body { min-width: 0; }
.welcome-toast-title {
  font-family: var(--font-display); font-weight: 700; font-size: 1rem;
  color: var(--ink); margin-bottom: 2px;
}
.welcome-toast-text {
  font-family: var(--font-body); font-size: .88rem; line-height: 1.45;
  color: var(--muted);
}
.welcome-toast-text strong { color: var(--emerald); font-weight: 700; }

@keyframes welcome-wave {
  0%, 100% { transform: rotate(0deg); }
  15%  { transform: rotate(14deg); }
  30%  { transform: rotate(-8deg); }
  45%  { transform: rotate(14deg); }
  60%  { transform: rotate(-4deg); }
  75%  { transform: rotate(6deg); }
}

@media (max-width: 480px) {
  .welcome-toast { bottom: 16px; padding: 14px 16px; gap: 10px; }
  .welcome-toast-title { font-size: .95rem; }
  .welcome-toast-text { font-size: .84rem; }
}

@media (prefers-reduced-motion: reduce) {
  .welcome-toast { transition: opacity .2s ease; transform: translate(-50%, 0) scale(1); }
  .welcome-toast.is-visible { transform: translate(-50%, 0) scale(1); }
  .welcome-toast.is-leaving { transform: translate(-50%, 0) scale(1); }
  .welcome-toast-icon { animation: none; }
}

/* ============================================================
   Premium image-card hover — event, news, gallery & photo cards
   (any .card that contains a .ph photo/placeholder, plus gallery
   items and the hero photo frame). Scoped to real hover-capable
   pointers so touch devices never get a "stuck" hover state.
   ============================================================ */
@media (hover: hover) and (pointer: fine) {
  .card:has(.ph),
  .masonry .g-item,
  .hero-visual .photo-frame {
    transition: transform .3s var(--ease-premium),
                box-shadow .3s var(--ease-premium),
                border-color .3s var(--ease-premium);
    will-change: transform;
  }
  .card:has(.ph) .ph,
  .masonry .g-item .ph,
  .hero-visual .photo-frame img {
    transition: transform .35s var(--ease-premium);
  }

  .card:has(.ph):hover,
  .masonry .g-item:hover {
    transform: translateY(-8px) scale(1.025);
    box-shadow: var(--shadow-float);
    border-color: rgba(11, 110, 79, .35);
  }
  .card:has(.ph):hover .ph,
  .masonry .g-item:hover .ph {
    transform: scale(1.05);
  }

  .hero-visual .photo-frame:hover {
    box-shadow: 0 28px 64px rgba(0, 0, 0, .34), 0 0 0 1px rgba(212, 175, 55, .22);
  }
  .hero-visual .photo-frame:hover img {
    transform: scale(1.05);
  }
}

@media (prefers-reduced-motion: reduce) {
  .card:has(.ph),
  .masonry .g-item,
  .hero-visual .photo-frame,
  .card:has(.ph) .ph,
  .masonry .g-item .ph,
  .hero-visual .photo-frame img {
    transition: box-shadow .2s ease, border-color .2s ease;
  }
  .card:has(.ph):hover,
  .masonry .g-item:hover {
    transform: none;
    box-shadow: var(--shadow-lift);
  }
  .card:has(.ph):hover .ph,
  .masonry .g-item:hover .ph,
  .hero-visual .photo-frame:hover img {
    transform: none;
  }
}
