/* =========================================================
   YourKalinga — site styles
   Brand: Deep teal #134E48 · Warm coral #E07A55 · Cream #FAF5E8
   Type:  Poppins
   ========================================================= */

/* ---------- Tokens ---------- */
:root {
  --teal:        #134E48;
  --teal-deep:   #0E3A35;
  --teal-700:    #1B5C55;
  --teal-tint:   #E4ECEA;
  --coral:       #E07A55;
  --coral-deep:  #CC6843;
  --coral-tint:  #F7DDD0;
  --cream:       #FAF5E8;
  --cream-deep:  #F1E8D4;
  --paper:       #FFFDF8;

  --text:        #243531;
  --muted:       #5A6A65;
  --line:        rgba(19, 78, 72, 0.14);
  --line-strong: rgba(19, 78, 72, 0.24);

  --shadow-sm: 0 1px 2px rgba(19,78,72,.06), 0 2px 8px rgba(19,78,72,.05);
  --shadow-md: 0 8px 24px rgba(19,78,72,.10), 0 2px 6px rgba(19,78,72,.06);
  --shadow-lg: 0 24px 60px rgba(19,78,72,.16), 0 8px 20px rgba(19,78,72,.08);

  --radius:    18px;
  --radius-lg: 28px;
  --radius-sm: 12px;

  --container: 1160px;
  --gutter: clamp(1.25rem, 4vw, 3rem);

  --ease: cubic-bezier(.22,.61,.36,1);

  --font: "Poppins", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
}

/* ---------- Reset ---------- */
*, *::before, *::after { box-sizing: border-box; }
* { margin: 0; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation-duration: .001ms !important; transition-duration: .001ms !important; }
}

body {
  font-family: var(--font);
  color: var(--text);
  background: var(--cream);
  line-height: 1.65;
  font-weight: 400;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  overflow-x: hidden;
}

img, svg { display: block; max-width: 100%; }
a { color: inherit; text-decoration: none; }
button { font: inherit; cursor: pointer; }
:focus-visible {
  outline: 3px solid var(--coral);
  outline-offset: 3px;
  border-radius: 4px;
}

/* ---------- Typography ---------- */
h1, h2, h3, h4 { font-weight: 600; line-height: 1.12; color: var(--teal); letter-spacing: -0.015em; overflow-wrap: break-word; }
h1 { font-size: clamp(2.35rem, 5.2vw, 3.85rem); }
h2 { font-size: clamp(1.85rem, 3.8vw, 2.7rem); }
h3 { font-size: clamp(1.25rem, 2.2vw, 1.5rem); }
p  { color: var(--muted); }
.lead { font-size: clamp(1.15rem, 1.9vw, 1.4rem); color: var(--text); font-weight: 500; line-height: 1.45; }

.eyebrow {
  display: inline-flex; align-items: center; gap: .55rem;
  font-size: .8rem; font-weight: 600; letter-spacing: .14em; text-transform: uppercase;
  color: var(--coral-deep);
}
.eyebrow::before {
  content: ""; width: 26px; height: 2px; background: var(--coral); border-radius: 2px;
}
.eyebrow.center { justify-content: center; }

/* ---------- Layout ---------- */
.container { width: 100%; max-width: var(--container); margin-inline: auto; padding-inline: var(--gutter); }
.narrow { max-width: 760px; }
section { padding-block: clamp(3.5rem, 8vw, 7rem); }
.section-head { max-width: 640px; margin-bottom: clamp(2rem, 4vw, 3rem); }
.section-head.center { margin-inline: auto; text-align: center; }
.section-head p { margin-top: .9rem; font-size: 1.05rem; }

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: .6rem;
  padding: .95rem 1.7rem; border-radius: 999px; font-weight: 600; font-size: 1rem;
  border: 2px solid transparent; transition: transform .25s var(--ease), box-shadow .25s var(--ease), background .25s var(--ease), color .25s var(--ease);
  white-space: nowrap;
}
.btn svg { width: 1.05em; height: 1.05em; }
.btn-primary { background: var(--coral); color: #fff; box-shadow: 0 10px 22px rgba(224,122,85,.32); }
.btn-primary:hover { background: var(--coral-deep); transform: translateY(-2px); box-shadow: 0 16px 30px rgba(224,122,85,.38); }
.btn-ghost { background: transparent; color: var(--teal); border-color: var(--line-strong); }
.btn-ghost:hover { background: var(--teal); color: #fff; border-color: var(--teal); transform: translateY(-2px); }
.btn-light { background: #fff; color: var(--teal); }
.btn-light:hover { background: var(--cream); transform: translateY(-2px); }
.btn-block { width: 100%; }

/* ---------- Header ---------- */
.site-header {
  position: sticky; top: 0; z-index: 100;
  background: rgba(250, 245, 232, 0.82);
  backdrop-filter: saturate(150%) blur(12px);
  -webkit-backdrop-filter: saturate(150%) blur(12px);
  border-bottom: 1px solid transparent;
  transition: border-color .3s var(--ease), background .3s var(--ease), box-shadow .3s var(--ease);
}
.site-header.scrolled { border-bottom-color: var(--line); box-shadow: var(--shadow-sm); }
.nav { display: flex; align-items: center; justify-content: space-between; gap: 1.5rem; padding-block: .85rem; }
.brand { display: inline-flex; align-items: center; }
.brand img { height: 62px; width: auto; }
.nav-links { display: flex; align-items: center; gap: clamp(1.25rem, 2.5vw, 2.25rem); }
.nav-links a.link {
  font-weight: 500; color: var(--teal); position: relative; padding: .35rem 0; font-size: 1rem;
}
.nav-links a.link::after {
  content: ""; position: absolute; left: 0; bottom: -2px; height: 2px; width: 0; background: var(--coral);
  transition: width .3s var(--ease);
}
.nav-links a.link:hover::after, .nav-links a.link[aria-current="page"]::after { width: 100%; }
.nav-links a.link[aria-current="page"] { color: var(--teal); }

.nav-toggle {
  display: none; width: 46px; height: 46px; border-radius: 12px; border: 1px solid var(--line-strong);
  background: transparent; position: relative; align-items: center; justify-content: center;
}
.nav-toggle span, .nav-toggle span::before, .nav-toggle span::after {
  content: ""; position: absolute; width: 22px; height: 2px; background: var(--teal); border-radius: 2px;
  transition: transform .3s var(--ease), opacity .2s var(--ease);
}
.nav-toggle span::before { transform: translateY(-7px); }
.nav-toggle span::after  { transform: translateY(7px); }
.nav-open .nav-toggle span { background: transparent; }
.nav-open .nav-toggle span::before { transform: rotate(45deg); }
.nav-open .nav-toggle span::after  { transform: rotate(-45deg); }

@media (max-width: 820px) {
  .nav-toggle { display: inline-flex; }
  .brand img { height: 52px; }
  .strip .container { grid-template-columns: repeat(2, auto); column-gap: clamp(1.25rem, 4vw, 3rem); }
  .nav-links {
    position: absolute; top: 100%; left: 0; right: 0; flex-direction: column; align-items: stretch; gap: 0;
    background: var(--cream); padding: .5rem var(--gutter) 1.5rem; border-bottom: 1px solid var(--line);
    box-shadow: var(--shadow-md);
    transform: translateY(-12px); opacity: 0; pointer-events: none; transition: opacity .25s var(--ease), transform .25s var(--ease);
  }
  .nav-open .nav-links { transform: translateY(0); opacity: 1; pointer-events: auto; }
  .nav-links a.link { padding: .9rem .25rem; border-bottom: 1px solid var(--line); }
  .nav-links a.link::after { display: none; }
  .nav-links .btn { margin-top: 1rem; }
}

/* ---------- Hero (Home) ---------- */
.hero { position: relative; padding-top: clamp(2.5rem, 5vw, 4.5rem); padding-bottom: clamp(3rem, 7vw, 6rem); }
.hero::before {
  content: ""; position: absolute; inset: 0; z-index: -1;
  background:
    radial-gradient(60% 70% at 12% 8%, rgba(224,122,85,.10), transparent 60%),
    radial-gradient(55% 60% at 92% 30%, rgba(19,78,72,.08), transparent 60%);
}
.hero-grid { display: grid; grid-template-columns: 1.05fr .95fr; gap: clamp(2rem, 5vw, 4.5rem); align-items: center; }
.hero h1 { margin-bottom: 1.1rem; }
.hero .lead { margin-bottom: 1rem; }
.hero p.body { margin-bottom: 1.9rem; max-width: 46ch; }
.hero-cta { display: flex; flex-wrap: wrap; gap: .9rem; align-items: center; }
.hero-note { display: inline-flex; align-items: center; gap: .5rem; font-size: .92rem; color: var(--muted); }
.hero-note svg { width: 18px; height: 18px; color: var(--teal); }

/* Hero visual: photo + floating definition card */
.hero-visual { position: relative; }
.hero-photo {
  border-radius: var(--radius-lg); overflow: hidden; box-shadow: var(--shadow-lg);
  aspect-ratio: 4 / 5; position: relative;
}
.hero-photo img { width: 100%; height: 100%; object-fit: cover; }
.hero-photo::after {
  content: ""; position: absolute; inset: 0;
  background: linear-gradient(180deg, transparent 40%, rgba(14,58,53,.45));
}

/* Definition card (Kalinga pronunciation) */
.def-card {
  position: absolute; left: -8%; bottom: -7%; width: min(330px, 82%);
  background: var(--paper); border-radius: var(--radius); padding: 1.3rem 1.4rem;
  box-shadow: var(--shadow-lg); border: 1px solid var(--line);
}
.def-top { display: flex; align-items: baseline; justify-content: space-between; gap: .5rem; }
.def-word { font-size: 1.6rem; font-weight: 600; color: var(--teal); letter-spacing: -.02em; }
.def-pos { font-size: .8rem; color: var(--muted); font-style: italic; }
.def-pron { display: flex; align-items: center; gap: .6rem; margin: .35rem 0 .55rem; }
.def-pron code {
  font-family: var(--font); font-size: .98rem; color: var(--coral-deep); font-weight: 500; letter-spacing: .01em;
}
.audio-btn {
  flex: none; width: 34px; height: 34px; border-radius: 50%; border: none; background: var(--coral); color: #fff;
  display: inline-flex; align-items: center; justify-content: center; box-shadow: 0 4px 10px rgba(224,122,85,.4);
  transition: transform .2s var(--ease), background .2s var(--ease);
}
.audio-btn:hover { background: var(--coral-deep); transform: scale(1.06); }
.audio-btn svg { width: 15px; height: 15px; }
.audio-btn.is-playing { animation: pulse 1.2s var(--ease) infinite; }
@keyframes pulse { 0%,100%{ box-shadow:0 4px 10px rgba(224,122,85,.4);} 50%{ box-shadow:0 4px 18px rgba(224,122,85,.7);} }
.def-meaning { font-size: .95rem; color: var(--text); line-height: 1.45; }

/* ---------- Trust strip ---------- */
.strip { background: var(--teal); color: #fff; }
.strip .container { display: grid; grid-template-columns: repeat(4, auto); justify-content: space-between; column-gap: clamp(.9rem,2.2vw,2rem); row-gap: 1rem; align-items: center; padding-block: 1.4rem; }
.strip-item { display: flex; align-items: center; gap: .7rem; font-weight: 500; font-size: .98rem; }
.strip-item svg { width: 22px; height: 22px; color: var(--coral); flex: none; }

/* ---------- Pillars ---------- */
.pillars { background: var(--paper); }
.pillar-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: clamp(1.2rem, 2.5vw, 2rem); }
.pillar {
  background: var(--cream); border: 1px solid var(--line); border-radius: var(--radius-lg);
  padding: 2rem 1.7rem; transition: transform .35s var(--ease), box-shadow .35s var(--ease), border-color .35s var(--ease);
}
.pillar:hover { transform: translateY(-6px); box-shadow: var(--shadow-md); border-color: var(--coral-tint); }
.pillar-icon {
  width: 76px; height: 76px; border-radius: 20px; background: var(--paper); border: 1px solid var(--line);
  display: grid; place-items: center; margin-bottom: 1.3rem; box-shadow: var(--shadow-sm);
}
.pillar-icon img { width: 44px; height: 44px; }
.pillar h3 { margin-bottom: .6rem; }
.pillar p { font-size: .98rem; }

/* ---------- Connection / one point of contact ---------- */
.connection { background: var(--cream); }
.connection-inner { text-align: center; }
.connection .section-head { margin-inline: auto; }
.map-frame {
  margin-top: clamp(1.5rem,4vw,3rem); background: var(--paper); border: 1px solid var(--line);
  border-radius: var(--radius-lg); padding: clamp(1.5rem, 4vw, 3rem); box-shadow: var(--shadow-md);
}
.map-frame img { width: 100%; max-width: 760px; margin-inline: auto; height: auto; }

/* ---------- Disclaimer band (quiet fine print) ---------- */
.note-band { background: var(--teal-deep); color: rgba(255,255,255,.78); padding-block: clamp(1.75rem, 3.5vw, 2.75rem); }
.note-band .container { max-width: 860px; }
.note-band h2 { color: rgba(255,255,255,.9); font-size: .95rem; font-weight: 600; letter-spacing: .02em; margin-bottom: .4rem; }
.note-band p { color: rgba(255,255,255,.62); font-size: .85rem; line-height: 1.6; max-width: 80ch; }

/* ---------- CTA band ---------- */
.cta-band { background: linear-gradient(135deg, var(--teal) 0%, var(--teal-deep) 100%); color: #fff; text-align: center; position: relative; overflow: hidden; }
.cta-band::before {
  content:""; position:absolute; width: 420px; height: 420px; border-radius: 50%;
  background: radial-gradient(circle, rgba(224,122,85,.28), transparent 70%); top: -160px; right: -100px;
}
.cta-band h2 { color: #fff; max-width: 20ch; margin-inline: auto; }
.cta-band p { color: rgba(255,255,255,.82); margin: 1rem auto 1.9rem; max-width: 52ch; }

/* ---------- Footer ---------- */
.site-footer { background: var(--teal-deep); color: rgba(255,255,255,.8); padding-block: clamp(2.5rem,5vw,3.5rem) 1.5rem; }
.footer-top { display: grid; grid-template-columns: 1.4fr 1fr 1fr; gap: 2rem; padding-bottom: 2rem; border-bottom: 1px solid rgba(255,255,255,.12); }
.footer-brand img { height: 38px; margin-bottom: 1rem; }
.footer-brand p { color: rgba(255,255,255,.7); font-size: .95rem; max-width: 34ch; }
.footer-col h4 { color: #fff; font-size: .85rem; letter-spacing: .12em; text-transform: uppercase; margin-bottom: 1rem; font-weight: 600; }
.footer-col a, .footer-col p { color: rgba(255,255,255,.78); font-size: .96rem; display: block; padding: .25rem 0; transition: color .2s var(--ease); }
.footer-col a:hover { color: var(--coral); }
.footer-legal { padding-top: 1.4rem; font-size: .85rem; color: rgba(255,255,255,.6); text-align: center; }

/* ---------- Page hero (Heritage / Contact) ---------- */
.page-hero { background: linear-gradient(135deg, var(--teal) 0%, var(--teal-deep) 100%); color: #fff; position: relative; overflow: hidden; padding-block: clamp(3rem,7vw,5.5rem); }
.page-hero::after {
  content:""; position:absolute; inset:0; opacity:.5;
  background:
    radial-gradient(40% 60% at 88% 10%, rgba(224,122,85,.22), transparent 60%),
    radial-gradient(40% 50% at 5% 100%, rgba(255,255,255,.06), transparent 60%);
}
.page-hero .container { position: relative; z-index: 1; max-width: 820px; }
.page-hero .eyebrow { color: var(--coral-tint); }
.page-hero .eyebrow::before { background: var(--coral-tint); }
.page-hero h1 { color: #fff; margin-top: .8rem; }
.page-hero p { color: rgba(255,255,255,.85); margin-top: 1.1rem; font-size: 1.1rem; max-width: 60ch; }

/* ---------- Prose ---------- */
.prose p { font-size: 1.08rem; line-height: 1.8; color: var(--text); }
.prose p + p { margin-top: 1.2rem; }
.prose em { color: var(--teal); font-style: italic; }

/* ---------- Team / people rows ---------- */
.person { display: grid; grid-template-columns: 360px 1fr; gap: clamp(1.5rem, 4vw, 3.5rem); align-items: center; }
.person + .person { margin-top: clamp(3rem, 6vw, 5rem); }
.person.reverse { grid-template-columns: 1fr 360px; }
.person.reverse .person-photo { order: 2; }
.person-photo {
  border-radius: var(--radius-lg); overflow: hidden; box-shadow: var(--shadow-md); border: 1px solid var(--line);
  background: var(--cream-deep); position: relative;
}
.person-photo img { width: 100%; aspect-ratio: 1/1; object-fit: cover; }
/* "Coming Soon" placeholder — matches the photo's 1:1 dimensions */
.person-photo.coming-soon {
  aspect-ratio: 1 / 1; display: grid; place-items: center; text-align: center;
  border-color: transparent;
  background:
    radial-gradient(130% 120% at 0% 0%, rgba(224,122,85,.26), transparent 55%),
    linear-gradient(135deg, var(--teal) 0%, var(--teal-deep) 100%);
}
.coming-soon .cs-label {
  position: relative; color: var(--cream); font-weight: 600;
  font-size: clamp(1.4rem, 3vw, 2rem); letter-spacing: .01em; padding-bottom: .55rem;
}
.coming-soon .cs-label::after {
  content: ""; position: absolute; left: 50%; bottom: 0; transform: translateX(-50%);
  width: 40px; height: 3px; border-radius: 3px; background: var(--coral);
}
.role-tag {
  display: inline-block; font-size: .78rem; font-weight: 600; letter-spacing: .12em; text-transform: uppercase;
  color: var(--coral-deep); background: var(--coral-tint); padding: .35rem .8rem; border-radius: 999px; margin-bottom: .8rem;
}
.person h3 { font-size: clamp(1.5rem, 2.6vw, 1.9rem); margin-bottom: .9rem; }
.person p { font-size: 1.03rem; line-height: 1.75; }
.person p + p { margin-top: .9rem; }
.badge-soft { display:inline-block; margin-top:1rem; font-size:.85rem; color:var(--muted); background:var(--cream-deep); border:1px dashed var(--line-strong); padding:.5rem .9rem; border-radius:10px; }

.heritage-figure { margin-top: clamp(2rem,5vw,3rem); border-radius: var(--radius-lg); overflow: hidden; box-shadow: var(--shadow-md); position: relative; }
.heritage-figure img { width: 100%; height: clamp(220px, 38vw, 420px); object-fit: cover; }
.heritage-figure figcaption {
  position: absolute; left: 0; right: 0; bottom: 0; padding: 2rem 1.5rem 1.2rem; color: #fff; font-size: .9rem;
  background: linear-gradient(180deg, transparent, rgba(14,58,53,.75));
}

/* ---------- Contact ---------- */
.contact-grid { display: grid; grid-template-columns: 1.15fr .85fr; gap: clamp(2rem, 5vw, 4rem); align-items: start; }
.form-card { background: var(--paper); border: 1px solid var(--line); border-radius: var(--radius-lg); padding: clamp(1.6rem, 4vw, 2.6rem); box-shadow: var(--shadow-md); }
.field { margin-bottom: 1.25rem; }
.field label { display: block; font-weight: 500; color: var(--teal); margin-bottom: .45rem; font-size: .96rem; }
.field label .req { color: var(--coral-deep); }
.field input, .field textarea {
  width: 100%; font: inherit; color: var(--text); background: var(--cream); border: 1px solid var(--line-strong);
  border-radius: var(--radius-sm); padding: .85rem 1rem; transition: border-color .2s var(--ease), box-shadow .2s var(--ease), background .2s var(--ease);
}
.field input:focus, .field textarea:focus { outline: none; border-color: var(--coral); background: var(--paper); box-shadow: 0 0 0 4px rgba(224,122,85,.15); }
.field textarea { resize: vertical; min-height: 140px; }
.form-error {
  display: none; margin-top: 1rem; padding: .8rem 1rem; border-radius: var(--radius-sm);
  background: #FBE3DA; color: #A23B22; border: 1px solid #F0C3B3; font-size: .95rem;
}
.form-error.show { display: block; animation: fadeUp .3s var(--ease); }
.form-confirm {
  display: none; text-align: center; padding: clamp(2rem,5vw,3rem) 1rem;
}
.form-confirm.show { display: block; animation: fadeUp .5s var(--ease); }
.form-confirm .check {
  width: 64px; height: 64px; border-radius: 50%; background: var(--teal-tint); color: var(--teal);
  display: grid; place-items: center; margin: 0 auto 1.2rem;
}
.form-confirm .check svg { width: 32px; height: 32px; }
.form-confirm h3 { margin-bottom: .6rem; }

.contact-side { position: sticky; top: 90px; }
.info-card { background: var(--teal); color: #fff; border-radius: var(--radius-lg); padding: clamp(1.6rem,4vw,2.4rem); box-shadow: var(--shadow-md); }
.info-card h3 { color: #fff; margin-bottom: 1.2rem; }
.info-item { display: flex; gap: .85rem; align-items: flex-start; padding: .8rem 0; border-top: 1px solid rgba(255,255,255,.14); }
.info-item:first-of-type { border-top: none; }
.info-item .ic { flex: none; width: 38px; height: 38px; border-radius: 11px; background: rgba(255,255,255,.1); display: grid; place-items: center; }
.info-item .ic svg { width: 18px; height: 18px; color: var(--coral); }
.info-item .label { font-size: .78rem; text-transform: uppercase; letter-spacing: .1em; color: rgba(255,255,255,.6); }
.info-item .value { color: #fff; font-weight: 500; }
.info-item a.value:hover { color: var(--coral-tint); }

/* ---------- Reveal animation ---------- */
/* Reveal animation degrades safely: content is visible by default, and only
   starts hidden when JS is active (html.js). If JS never runs, nothing is hidden. */
.reveal { transition: opacity .7s var(--ease), transform .7s var(--ease); }
.js .reveal { opacity: 0; transform: translateY(24px); }
.reveal.in { opacity: 1; transform: none; }
.reveal.d1 { transition-delay: .08s; }
.reveal.d2 { transition-delay: .16s; }
.reveal.d3 { transition-delay: .24s; }
@keyframes fadeUp { from { opacity: 0; transform: translateY(16px);} to { opacity:1; transform:none; } }

/* ---------- Responsive ---------- */
@media (max-width: 960px) {
  .hero-grid { grid-template-columns: 1fr; gap: 3.5rem; }
  .hero-visual { max-width: 440px; margin-inline: auto; width: 100%; }
  .pillar-grid { grid-template-columns: 1fr; max-width: 480px; margin-inline: auto; }
  .person, .person.reverse { grid-template-columns: 1fr; }
  .person.reverse .person-photo { order: 0; }
  .person-photo { max-width: 360px; }
  .contact-grid { grid-template-columns: 1fr; }
  .contact-side { position: static; }
  .footer-top { grid-template-columns: 1fr 1fr; }
  .footer-brand { grid-column: 1 / -1; }
}
@media (max-width: 540px) {
  .footer-top { grid-template-columns: 1fr; }
  .def-card { position: static; width: 100%; margin-top: 1.25rem; left: 0; }
  .hero-photo { aspect-ratio: 3/4; }
  .strip .container { grid-template-columns: 1fr; justify-content: start; row-gap: .9rem; }
}
