/* ================================
   Tiptur Roots — Cooperative Theme
   ================================ */

:root {
  --green-dark: #1b4d2e;
  --green: #2e7d42;
  --green-light: #e9f3ec;
  --brown: #7a4a24;
  --brown-light: #b98452;
  --cream: #fbf7ef;
  --cream-dark: #f2ead9;
  --ink: #22301f;
  --muted: #5c6b56;
  --white: #ffffff;
  --gold: #c9962c;
  --shadow: 0 10px 30px rgba(27, 77, 46, 0.12);
  --radius: 14px;
  --max-width: 1180px;
  --font-head: "Georgia", "Times New Roman", serif;
  --font-body: "Segoe UI", "Helvetica Neue", Arial, sans-serif;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  font-family: var(--font-body);
  color: var(--ink);
  background: var(--cream);
  line-height: 1.65;
  overflow-x: hidden;
}

img { max-width: 100%; display: block; }

a { color: inherit; text-decoration: none; }

.container {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 24px;
}

h1, h2, h3, h4 {
  font-family: var(--font-head);
  color: var(--green-dark);
  line-height: 1.25;
  margin: 0 0 16px;
}

p { margin: 0 0 16px; color: var(--muted); }

.eyebrow {
  display: inline-block;
  font-size: 0.78rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--brown);
  font-weight: 700;
  margin-bottom: 10px;
}
.eyebrow-kn {
  display: block;
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--brown);
  margin: -6px 0 10px;
}
.hero .eyebrow-kn { color: var(--gold); }
.eyebrow-kn-sub {
  font-size: 0.66rem;
  font-weight: 700;
  margin: -2px 0 10px;
}
.h2-kn {
  color: var(--brown);
  font-weight: 600;
  font-size: 1.05rem;
  margin: -10px 0 16px;
}

.kannada {
  font-family: "Noto Sans Kannada", "Tunga", var(--font-body);
}

/* Headings/buttons pin their own font-family (Georgia has no Kannada
   glyphs), which otherwise wins over the inherited Kannada font and forces
   an inconsistent per-glyph fallback — causing overlapping/garbled text.
   Force every descendant back to the Kannada font once Kannada is active. */
body.kannada * {
  font-family: "Noto Sans Kannada", "Tunga", var(--font-body);
}

/* letter-spacing and uppercase are styling choices for English all-caps
   labels — Kannada has no letter case, and added letter-spacing visually
   breaks conjunct consonant/vowel-sign clusters, making words look spaced
   out and garbled. Neutralize both once Kannada is active. */
body.kannada .eyebrow,
body.kannada .eyebrow-kn,
body.kannada .tag,
body.kannada .stat .label,
body.kannada .member-card .role,
body.kannada .date-badge .mon {
  letter-spacing: normal;
  text-transform: none;
}

/* ---------- Buttons ---------- */
.btn {
  display: inline-block;
  padding: 13px 28px;
  border-radius: 999px;
  font-weight: 600;
  font-size: 0.95rem;
  border: 2px solid transparent;
  cursor: pointer;
  transition: transform 0.15s ease, box-shadow 0.15s ease, background 0.2s ease;
}
.btn:hover { transform: translateY(-2px); }

.btn-primary {
  background: var(--green);
  color: var(--white);
  box-shadow: var(--shadow);
}
.btn-primary:hover { background: var(--green-dark); }

.btn-outline {
  background: transparent;
  border-color: var(--white);
  color: var(--white);
}
.btn-outline:hover { background: rgba(255,255,255,0.15); }

.btn-brown {
  background: var(--brown);
  color: var(--white);
}
.btn-brown:hover { background: #5e3a1c; }

.btn-block { width: 100%; text-align: center; }

/* ---------- Top bar ---------- */
.topbar {
  background: var(--green-dark);
  color: var(--cream);
  font-size: 0.82rem;
}
.topbar .container {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding-top: 8px;
  padding-bottom: 8px;
  flex-wrap: wrap;
  gap: 6px;
}
.topbar-links a { margin-right: 18px; opacity: 0.92; }
.topbar-links a:hover { opacity: 1; text-decoration: underline; }
.topbar-social a {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 26px; height: 26px;
  border-radius: 50%;
  background: rgba(255,255,255,0.12);
  margin-left: 6px;
  font-size: 0.85rem;
}
.topbar-social a:hover { background: var(--gold); color: var(--green-dark); }
.topbar-social a svg { width: 14px; height: 14px; }

/* ---------- Header / Nav ---------- */
.site-header {
  background: var(--white);
  box-shadow: 0 2px 10px rgba(0,0,0,0.06);
  position: sticky;
  top: 0;
  z-index: 100;
}
.nav-wrap {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 7px 0;
}
.brand {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-shrink: 0;
}
.brand-text { min-width: 0; }
.brand img.logo {
    width: 72px;
    height: 72px;
    object-fit: contain;
    border-radius: 50%;
}
.brand-text .name {
  font-family: var(--font-head);
  font-weight: 700;
  font-size: 1.35rem;
  color: var(--green-dark);
  display: block;
  line-height: 1.1;
}
.brand-text .tagline {
  font-size: 0.72rem;
  color: var(--brown);
  letter-spacing: 0.04em;
  white-space: nowrap;
}

.nav-toggle {
  display: none;
  flex-direction: column;
  gap: 5px;
  background: none;
  border: none;
  cursor: pointer;
  padding: 6px;
}
.nav-toggle span {
  width: 26px; height: 3px;
  background: var(--green-dark);
  border-radius: 2px;
}

.main-nav ul {
  list-style: none;
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 6px;
  row-gap: 6px;
  margin: 0; padding: 0;
  align-items: center;
}
.main-nav a {
  display: block;
  padding: 10px 14px;
  font-weight: 600;
  font-size: 0.92rem;
  color: var(--ink);
  border-radius: 8px;
  transition: background 0.15s, color 0.15s;
}
.main-nav a:hover,
.main-nav a.active {
  background: var(--green-light);
  color: var(--green-dark);
}
.main-nav .btn { margin-left: 6px; }
.main-nav a.btn-primary,
.main-nav a.btn-primary:hover,
.main-nav a.btn-primary.active { background: var(--green); color: var(--white); }
.main-nav a.btn-primary:hover,
.main-nav a.btn-primary.active:hover { background: var(--green-dark); }
.main-nav form.nav-logout { margin: 0; }
.main-nav form.nav-logout button { font-family: inherit; }
.nav-actions {
  display: flex;
  align-items: center;
  gap: 6px;
  flex-wrap: nowrap;
}

/* Admins see extra nav items (Dashboard, language, Join Us, Logout) — tighten
   spacing/sizing so everything fits on one line at normal desktop widths
   instead of wrapping. Join Us + Logout are grouped in .nav-actions so that
   if it ever does wrap (very narrow windows), they wrap together as a pair
   instead of splitting apart. */
body.admin-nav .main-nav ul {
  gap: 0;
  flex-wrap: wrap;
  justify-content: flex-end;
  row-gap: 6px;
}
body.admin-nav .main-nav a {
  padding: 7px 9px;
  font-size: 0.88rem;
  white-space: nowrap;
}
body.admin-nav .main-nav a.btn-primary,
body.admin-nav .main-nav form.nav-logout button {
  padding: 7px 12px;
}
body.admin-nav .main-nav .btn { margin-left: 4px; }
body.admin-nav .nav-actions { gap: 4px; }
body.admin-nav .lang-toggle-select {
  padding: 5px 22px 5px 8px;
  font-size: 0.78rem;
}

/* ---------- Hero ---------- */
.hero {
  position: relative;
  color: var(--white);
  overflow: hidden;
}
.hero .eyebrow { color: var(--gold); text-shadow: 0 2px 12px rgba(0,0,0,0.4); }
.hero h1 { color: var(--white); font-size: 2.6rem; text-shadow: 0 2px 16px rgba(0,0,0,0.4); }
.hero p.lead { color: rgba(255,255,255,0.95); font-size: 1.08rem; max-width: 560px; text-shadow: 0 2px 12px rgba(0,0,0,0.35); }
.hero-cta { display: flex; gap: 14px; flex-wrap: wrap; margin-top: 24px; }
.hero-motto { color: var(--gold); font-weight: 700; font-size: 0.95rem; margin: 0 0 20px; text-shadow: 0 2px 12px rgba(0,0,0,0.4); }
.hero-badge {
  background: rgba(255,255,255,0.95);
  border-radius: var(--radius);
  padding: 26px;
  text-align: center;
  box-shadow: var(--shadow);
}
.hero-badge img { width: 190px; margin: 0 auto 14px; }
.hero-badge .motto { color: var(--brown); font-weight: 700; font-size: 0.95rem; }
.hero-slide-single { grid-template-columns: minmax(0, 1fr) !important; }
.hero-slide-single .hero-copy { max-width: 640px; }

/* ---------- Hero slider ---------- */
.hero-track {
  position: relative;
  z-index: 2;
  touch-action: pan-y;
  display: grid;
}
.hero-slide {
  grid-area: 1 / 1 / 2 / 2;
  position: relative;
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transition: opacity 0.6s ease;
}
.hero-slide::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  background-size: cover;
  background-position: center;
}
.hero-slide--bengaluru::before {
  background-image:
    linear-gradient(rgba(0,0,0,0.35), rgba(0,0,0,0.35)),
    url("../img/tiptur-bengaluru.jpg");
  background-position: center 40%;
}
.hero-slide--copra::before {
  background-image:
    linear-gradient(rgba(0,0,0,0.35), rgba(0,0,0,0.35)),
    url("../img/tiptur-copra.jpg");
  background-position: center 25%;
}
.hero-slide.is-active {
  opacity: 1;
  visibility: visible;
  pointer-events: auto;
  z-index: 1;
  animation: heroFade 0.6s ease;
}
.hero-slide .container {
  display: grid;
  grid-template-columns: minmax(0, 1.15fr) minmax(0, 0.85fr);
  align-items: center;
  gap: 40px;
  padding-top: 52px;
  padding-bottom: 52px;
  /* Fixed regardless of language — otherwise the shared slider height (all
     slides stack in one grid cell) shrinks or grows depending on which
     language's text is shorter/longer, cropping the background image. */
  min-height: 480px;
}
@keyframes heroFade { from { opacity: 0; } to { opacity: 1; } }

.hero-slide.is-active .eyebrow,
.hero-slide.is-active h1,
.hero-slide.is-active p.lead,
.hero-slide.is-active .hero-cta,
.hero-slide.is-active .hero-motto,
.hero-slide.is-active .hero-badge {
  animation-duration: 0.7s;
  animation-timing-function: ease;
  animation-fill-mode: both;
}
.hero-slide.is-active .eyebrow { animation-name: heroFadeUp; animation-delay: 0.05s; }
.hero-slide.is-active h1 { animation-name: heroFadeUp; animation-delay: 0.12s; }
.hero-slide.is-active p.lead { animation-name: heroFadeUp; animation-delay: 0.28s; }
.hero-slide.is-active .hero-motto { animation-name: heroFadeUp; animation-delay: 0.36s; }
.hero-slide.is-active .hero-cta { animation-name: heroScaleIn; animation-delay: 0.48s; }
.hero-slide.is-active .hero-badge { animation-name: heroSlideInRight; animation-delay: 0.15s; }

@keyframes heroFadeUp {
  from { opacity: 0; transform: translateY(18px); }
  to { opacity: 1; transform: translateY(0); }
}
@keyframes heroScaleIn {
  from { opacity: 0; transform: scale(0.85); }
  to { opacity: 1; transform: scale(1); }
}
@keyframes heroSlideInRight {
  from { opacity: 0; transform: translateX(50px); }
  to { opacity: 1; transform: translateX(0); }
}

.hero-arrow {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  z-index: 3;
  width: 44px;
  height: 44px;
  border-radius: 50%;
  border: 1.5px solid rgba(255,255,255,0.4);
  background: rgba(255,255,255,0.12);
  color: var(--white);
  font-size: 0.95rem;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background 0.2s ease, transform 0.2s ease;
}
.hero-arrow:hover { background: rgba(255,255,255,0.25); transform: translateY(-50%) scale(1.06); }
.hero-arrow-prev { left: 18px; }
.hero-arrow-next { right: 18px; }

.hero-dots {
  position: relative;
  z-index: 3;
  display: flex;
  justify-content: center;
  gap: 10px;
  padding-bottom: 22px;
}
.hero-dot {
  width: 10px;
  height: 10px;
  border-radius: 999px;
  border: none;
  background: rgba(255,255,255,0.35);
  cursor: pointer;
  padding: 0;
  transition: width 0.25s ease, background 0.25s ease;
}
.hero-dot:hover { background: rgba(255,255,255,0.6); }
.hero-dot.is-active { width: 28px; background: var(--gold); }

/* ---------- Stats ---------- */
.stats {
  background: var(--cream-dark);
  border-top: 4px solid var(--brown-light);
  border-bottom: 4px solid var(--brown-light);
}
.stats .container {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 20px;
  padding: 34px 24px;
  text-align: center;
}
.stat .num {
  font-family: var(--font-head);
  font-size: 2.1rem;
  color: var(--green-dark);
  font-weight: 700;
}
.stat .label { color: var(--brown); font-size: 0.85rem; font-weight: 600; text-transform: uppercase; letter-spacing: 0.05em; }

/* ---------- Sections ---------- */
.section { padding: 48px 0; }
.section-alt { background: var(--green-light); }
.section-head { max-width: 680px; margin: 0 auto 32px; text-align: center; }
.section-head.left { margin: 0 0 32px; text-align: left; }

.grid {
  display: grid;
  gap: 26px;
}
.grid-3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.grid-4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.grid-2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }

.card {
  background: var(--white);
  border-radius: var(--radius);
  padding: 22px;
  box-shadow: var(--shadow);
  border: 1px solid rgba(27,77,46,0.06);
}
.card .icon {
  width: 52px; height: 52px;
  border-radius: 12px;
  background: var(--green-light);
  color: var(--green-dark);
  display: flex; align-items: center; justify-content: center;
  font-size: 1.5rem;
  margin-bottom: 16px;
}
.card h3 { margin-bottom: 8px; font-size: 1.1rem; }
.card p { margin-bottom: 0; font-size: 0.92rem; }
.card-kn {
  display: block;
  font-size: 0.85rem;
  font-weight: 700;
  color: var(--brown);
  line-height: 1.3;
}
.icon-card .card-kn { margin: 6px 0 10px; }
.photo-card .card-kn { padding: 6px 20px 8px; font-size: 0.82rem; }

.card-title-underline {
  display: inline-block;
  position: relative;
}
.card-title-underline::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  width: 100%;
  height: 1px;
  border-radius: 2px;
  background: var(--brown);
}
.card h3.card-title-underline { padding-bottom: 10px; }

.icon-card {
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}
.icon-card:hover {
  transform: translateY(-6px);
  box-shadow: 0 20px 36px rgba(27,77,46,0.16);
}
.icon-card .icon {
  width: 64px; height: 64px;
  border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  font-size: 1.7rem;
  color: var(--white);
  box-shadow: 0 8px 18px rgba(0,0,0,0.15);
}
.grid .icon-card:nth-of-type(5n+1) .icon { background: linear-gradient(135deg, var(--green), var(--green-dark)); }
.grid .icon-card:nth-of-type(5n+2) .icon { background: linear-gradient(135deg, var(--gold), #a9781f); }
.grid .icon-card:nth-of-type(5n+3) .icon { background: linear-gradient(135deg, var(--brown-light), var(--brown)); }
.grid .icon-card:nth-of-type(5n+4) .icon { background: linear-gradient(135deg, var(--green-dark), var(--brown)); }
.grid .icon-card:nth-of-type(5n+5) .icon { background: linear-gradient(135deg, var(--brown), var(--gold)); }

.photo-card {
  padding: 0;
  overflow: hidden;
  display: block;
  cursor: pointer;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}
.photo-card:hover { transform: translateY(-4px); box-shadow: 0 16px 34px rgba(27,77,46,0.18); }
.photo-card .card-photo { aspect-ratio: 4/3; overflow: hidden; }
.photo-card .card-photo img { width: 100%; height: 100%; object-fit: cover; display: block; }
.photo-card h3 { margin: 0 20px; padding: 18px 0 4px; font-size: 1.05rem; }
.photo-card p { padding: 0 20px 20px; }

.testimonial-card { text-align: left; }
.testimonial-card .quote-mark {
  font-family: var(--font-head);
  font-size: 3.2rem;
  line-height: 1;
  color: var(--gold);
  margin-bottom: 4px;
}
.testimonial-card p { font-style: italic; color: var(--ink); font-size: 0.95rem; margin-bottom: 20px; }
.testimonial-author { display: flex; flex-direction: column; border-top: 1px solid rgba(27,77,46,0.1); padding-top: 12px; }
.testimonial-author strong { color: var(--green-dark); font-size: 0.95rem; }
.testimonial-author span { color: var(--muted); font-size: 0.8rem; }

/* About split */
.split {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  gap: 50px;
  align-items: center;
}
.split img { border-radius: var(--radius); box-shadow: var(--shadow); }
.about-emblem { width: 320px; max-width: 60%; }
.tick-list { list-style: none; padding: 0; margin: 0; }
.tick-list li {
  position: relative;
  padding-left: 30px;
  margin-bottom: 12px;
  color: var(--ink);
  font-weight: 500;
}
.tick-list li::before {
  content: "✓";
  position: absolute; left: 0; top: 0;
  width: 20px; height: 20px;
  background: var(--green);
  color: var(--white);
  border-radius: 50%;
  font-size: 0.72rem;
  display: flex; align-items: center; justify-content: center;
}

/* Committee */
.member-card { text-align: center; }
.member-card .avatar {
  width: 110px; height: 110px;
  border-radius: 50%;
  margin: 0 auto 16px;
  background: var(--green-light);
  display: flex; align-items: center; justify-content: center;
  font-size: 2.3rem;
  color: var(--green-dark);
  border: 4px solid var(--cream-dark);
}
.member-card h3 { margin-bottom: 2px; font-size: 1.02rem; }
.member-card .role { color: var(--brown); font-weight: 700; font-size: 0.82rem; text-transform: uppercase; letter-spacing: 0.04em; margin-bottom: 10px; display: block;}

/* Events / News */
.event-card, .news-card {
  display: flex;
  gap: 18px;
  background: var(--white);
  border-radius: var(--radius);
  padding: 20px;
  box-shadow: var(--shadow);
  margin-bottom: 20px;
  align-items: flex-start;
}
.date-badge {
  flex: 0 0 74px;
  background: var(--green-dark);
  color: var(--white);
  border-radius: 10px;
  text-align: center;
  padding: 10px 6px;
}
.date-badge .day { font-size: 1.5rem; font-weight: 700; line-height: 1; font-family: var(--font-head); }
.date-badge .mon { font-size: 0.72rem; text-transform: uppercase; letter-spacing: 0.05em; }
.tag {
  display: inline-block;
  background: var(--gold);
  color: #3a2c05;
  font-size: 0.7rem;
  font-weight: 700;
  padding: 3px 10px;
  border-radius: 999px;
  margin-bottom: 8px;
  text-transform: uppercase;
}
.tag.past { background: var(--cream-dark); color: var(--muted); }

/* Gallery */
.gallery-item {
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: var(--shadow);
  position: relative;
  aspect-ratio: 4/3;
  background: linear-gradient(135deg, var(--green), var(--brown-light));
  display: flex; align-items: center; justify-content: center;
  color: rgba(255,255,255,0.85);
  font-size: 2rem;
}
.gallery-single { max-width: 420px; margin: 0 auto; }
.gallery-single .gallery-item { aspect-ratio: auto; }
.gallery-photo { padding: 0; background: var(--cream-dark); }
.gallery-photo img { width: 100%; height: auto; object-fit: contain; display: block; }
.gallery-photo .caption {
  position: absolute;
  left: 0; right: 0; bottom: 0;
  padding: 14px 16px;
  background: linear-gradient(transparent, rgba(0,0,0,0.65));
  color: var(--white);
  font-size: 1rem;
  text-align: left;
}

/* Forms */
.form-card {
  background: var(--white);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: 26px;
}
.form-row { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 18px; }
.field { margin-bottom: 18px; }
.field label { display: block; font-weight: 600; margin-bottom: 6px; font-size: 0.9rem; color: var(--green-dark); }
.field input, .field select, .field textarea {
  width: 100%;
  padding: 12px 14px;
  border: 1.5px solid #dce4dc;
  border-radius: 8px;
  font-size: 0.95rem;
  font-family: inherit;
  background: var(--cream);
  transition: border-color 0.15s;
}
.field input:focus, .field select:focus, .field textarea:focus {
  outline: none;
  border-color: var(--green);
  background: var(--white);
}
.field textarea { resize: vertical; min-height: 110px; }
.field select:disabled { opacity: 0.6; cursor: not-allowed; background: #eee7da; }
.field input.input-invalid { border-color: #b3261e; }

/* ---------- Village dropdown with inline search ---------- */
.village-select { position: relative; }
.village-select-native { display: none; }
.village-select-trigger {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  padding: 12px 14px;
  border: 1.5px solid #dce4dc;
  border-radius: 8px;
  font-size: 0.95rem;
  font-family: inherit;
  background: var(--cream);
  color: var(--ink);
  text-align: left;
  cursor: pointer;
  transition: border-color 0.15s;
}
.village-select-trigger:focus { outline: none; border-color: var(--green); background: var(--white); }
.village-select-trigger:disabled { opacity: 0.6; cursor: not-allowed; background: #eee7da; }
.village-select-trigger-text { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.village-select-trigger-text.placeholder { color: var(--muted); }
.village-select-trigger-caret { flex-shrink: 0; color: var(--muted); font-size: 0.75rem; transition: transform 0.15s; }
.village-select.open .village-select-trigger-caret { transform: rotate(180deg); }

.village-select-panel {
  position: absolute;
  top: calc(100% + 4px);
  left: 0;
  right: 0;
  background: var(--white);
  border: 1.5px solid #dce4dc;
  border-radius: 8px;
  box-shadow: var(--shadow);
  z-index: 30;
  overflow: hidden;
}
.village-select-search-wrap { padding: 8px; border-bottom: 1px solid var(--cream-dark); }
.village-select-search-input {
  width: 100%;
  padding: 8px 10px;
  border: 1.5px solid #dce4dc;
  border-radius: 6px;
  font-size: 0.9rem;
  font-family: inherit;
  background: var(--cream);
}
.village-select-search-input:focus { outline: none; border-color: var(--green); background: var(--white); }
.village-select-options { max-height: 220px; overflow-y: auto; }
.village-select-option {
  padding: 10px 14px;
  font-size: 0.92rem;
  color: var(--ink);
  cursor: pointer;
}
.village-select-option:hover,
.village-select-option.highlighted { background: var(--green-light); color: var(--green-dark); }
.village-select-empty { padding: 10px 14px; font-size: 0.88rem; color: var(--muted); }

@media (max-width: 480px) {
  .village-select-panel { max-height: 60vh; }
  .village-select-options { max-height: 45vh; }
}
.age-hint {
  display: inline-block;
  margin-left: 6px;
  padding: 1px 8px;
  border-radius: 999px;
  background: var(--gold, #d6a54c);
  color: var(--green-dark);
  font-size: 0.72rem;
  font-weight: 700;
  vertical-align: middle;
}
.form-note { font-size: 0.82rem; color: var(--muted); }
.form-error { display: block; color: #b3261e; font-size: 0.82rem; margin-top: 6px; font-weight: 600; }
#formSuccess {
  display: none;
  background: var(--green-light);
  border: 1.5px solid var(--green);
  color: var(--green-dark);
  padding: 16px 18px;
  border-radius: 10px;
  margin-bottom: 20px;
  font-weight: 600;
}

.membership-intro { max-width: 720px; margin: 0 auto 40px; }
.gform-card {
  max-width: 760px;
  margin: 0 auto;
  position: relative;
  overflow: hidden;
  padding-top: 32px;
}
.gform-card::before {
  content: '';
  position: absolute;
  top: 0; left: 0; right: 0;
  height: 6px;
  background: linear-gradient(90deg, var(--green), var(--gold));
}
.form-card-header {
  display: flex;
  align-items: center;
  gap: 16px;
  margin-bottom: 20px;
}
.form-card-header .icon {
  width: 52px; height: 52px;
  flex-shrink: 0;
  border-radius: 14px;
  background: var(--green-light);
  color: var(--green-dark);
  display: flex; align-items: center; justify-content: center;
  font-size: 1.5rem;
}
.form-card-header h3 { margin: 0; }
.gform-frame {
  border-radius: 12px;
  overflow: hidden;
  background: var(--cream);
  border: 1.5px solid #dce4dc;
}
.gform-frame iframe { width: 100%; height: 380px; border: 0; display: block; }
.gform-note { display: flex; align-items: center; gap: 8px; }

.radio-field { border: 0; padding: 0; }
.radio-field legend { display: block; font-weight: 600; margin-bottom: 8px; font-size: 0.9rem; color: var(--green-dark); padding: 0; }
.radio-group { display: flex; flex-direction: column; gap: 10px; }
.radio-option {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 11px 14px;
  border: 1.5px solid #dce4dc;
  border-radius: 8px;
  background: var(--cream);
  font-size: 0.95rem;
  cursor: pointer;
  transition: border-color 0.15s, background 0.15s;
}
.radio-option:hover { border-color: var(--green); }
.radio-option input[type="radio"],
.radio-option input[type="checkbox"] { width: 18px; height: 18px; accent-color: var(--green); flex-shrink: 0; margin: 0; }
.radio-option .other-input {
  flex: 1;
  padding: 7px 10px;
  border: 1px solid #dce4dc;
  border-radius: 6px;
  background: var(--white);
  font-size: 0.9rem;
  font-family: inherit;
}
.radio-option .other-input:focus { outline: none; border-color: var(--green); }

/* CTA band */
.cta-band {
  background: var(--brown);
  color: var(--white);
  text-align: center;
  padding: 56px 0;
}
.cta-band h2 { color: var(--white); }
.cta-band p { color: rgba(255,255,255,0.85); }

/* Contact page */
.contact-info-card {
  background: var(--white);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: 26px;
  display: flex;
  gap: 16px;
  align-items: flex-start;
  margin-bottom: 18px;
}
.contact-info-card .icon {
  width: 44px; height: 44px; flex-shrink: 0;
  border-radius: 10px;
  background: var(--green-light);
  color: var(--green-dark);
  display: flex; align-items: center; justify-content: center;
  font-size: 1.2rem;
}
.map-frame {
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: var(--shadow);
  height: 100%;
  min-height: 320px;
}
.map-frame iframe { width: 100%; height: 100%; min-height: 320px; border: 0; }

/* Page hero (inner pages) */
.page-hero {
  background: linear-gradient(120deg, var(--green-dark), var(--green));
  color: var(--white);
  padding: 24px 0;
  text-align: center;
}
.page-hero h1 { color: var(--white); margin-bottom: 8px; }
.kn-tagline { color: var(--gold); font-size: 1.05rem; font-weight: 600; margin: 0 0 10px; }
.footer-kannada { color: rgba(255,255,255,0.75); font-size: 0.9rem; margin-top: 10px; }
.breadcrumb { font-size: 0.85rem; opacity: 0.85; }


/* Footer */
.site-footer {
  background: var(--green-dark);
  color: rgba(255,255,255,0.85);
  padding-top: 56px;
}
.footer-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.4fr) minmax(0, 1fr) minmax(0, 1fr) minmax(0, 1.2fr);
  gap: 34px;
  padding-bottom: 40px;
  border-bottom: 1px solid rgba(255,255,255,0.15);
}
.footer-grid h4 { color: var(--white); font-size: 1rem; margin-bottom: 18px; }
.footer-brand { display: flex; gap: 12px; align-items: center; margin-bottom: 14px; }
.footer-brand img { width: 48px; border-radius: 50%; object-fit: cover; }
.footer-brand .name { font-family: var(--font-head); font-size: 1.15rem; color: var(--white); font-weight: 700; }
.footer-links { list-style: none; padding: 0; margin: 0; }
.footer-links li { margin-bottom: 10px; }
.footer-links a:hover { color: var(--gold); }
.footer-social { display: flex; gap: 10px; margin-top: 16px; }
.footer-social a {
  width: 34px; height: 34px;
  border-radius: 50%;
  background: rgba(255,255,255,0.12);
  display: flex; align-items: center; justify-content: center;
}
.footer-social a:hover { background: var(--gold); color: var(--green-dark); }
.footer-social a svg { width: 17px; height: 17px; }
.footer-bottom {
  text-align: center;
  padding: 20px 0;
  font-size: 0.82rem;
  color: rgba(255,255,255,0.6);
}
.footer-bottom a { text-decoration: underline; }

/* Utility */
.text-center { text-align: center; }
.mt-0 { margin-top: 0; }

/* ---------- Responsive ---------- */
@media (max-width: 960px) {
  .hero-slide .container { grid-template-columns: minmax(0, 1fr); }
  .hero-badge { max-width: 320px; margin: 0 auto; }
  .split { grid-template-columns: minmax(0, 1fr); }
  .footer-grid { grid-template-columns: 1fr 1fr; }
  .grid-4 { grid-template-columns: repeat(2, 1fr); }
  .grid-3 { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 760px) {
  .topbar { display: none; }
  .nav-toggle { display: flex; }
  .main-nav {
    position: absolute;
    top: 100%; left: 0; right: 0;
    background: var(--white);
    box-shadow: 0 10px 20px rgba(0,0,0,0.08);
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.25s ease;
  }
  .main-nav.open { max-height: 480px; }
  .main-nav ul { flex-direction: column; align-items: stretch; padding: 10px 20px 20px; gap: 2px; }
  .main-nav .btn { margin: 10px 0 0; text-align: center; }
  .stats .container { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .grid-4, .grid-3, .grid-2 { grid-template-columns: minmax(0, 1fr); }
  .form-row { grid-template-columns: minmax(0, 1fr); }
  .footer-grid { grid-template-columns: minmax(0, 1fr); }
  .hero h1 { font-size: 1.65rem; }
  .hero-slide .container { padding-top: 22px; padding-bottom: 22px; gap: 20px; min-height: 420px; }
  .hero p.lead { font-size: 0.95rem; }
  .hero-motto { margin-bottom: 12px; }
  .hero-cta { flex-direction: column; align-items: stretch; margin-top: 14px; }
  .hero-cta .btn { width: 100%; text-align: center; }
  .hero-arrow { width: 36px; height: 36px; font-size: 0.8rem; }
  .hero-arrow-prev { left: 8px; }
  .hero-arrow-next { right: 8px; }
  .section { padding: 30px 0; }
  .section-head { margin: 0 auto 18px; }
  .section-head h2 { font-size: 1.4rem; margin-bottom: 10px; }
  .section-head p { margin-bottom: 0; }
  .page-hero { padding: 18px 0; }
  .page-hero h1 { font-size: 1.6rem; }
  .card { padding: 18px; }
  .grid { gap: 14px; }
  .form-card { padding: 10px; }
  .gform-card { padding-top: 22px; }
  .gform-frame iframe { height: 520px; }
  .container { padding: 0 16px; }
  h1, h2, h3, h4 { margin-bottom: 10px; }
  p { margin-bottom: 10px; }
}


.section-title-underline {
    position: relative;
    display: inline-block;
    margin-bottom: 25px;
}

.section-title-underline::after {
    content: "";
    position: absolute;
    left: 0;
    bottom: -8px;
    width: 80px;              /* Adjust underline length */
    height: 4px;              /* Underline thickness */
    background: #8B5A2B;      /* Brown color */
    border-radius: 2px;
}

/* ---------- Language toggle (English / Kannada) ---------- */
.lang-toggle-item { display: flex; align-items: center; }
.lang-toggle-select {
  padding: 8px 14px;
  border-radius: 8px;
  border: 1.5px solid #dce4dc;
  background: var(--cream) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20' fill='%231b4d2e'%3E%3Cpath fill-rule='evenodd' d='M5.23 7.21a.75.75 0 011.06.02L10 11.168l3.71-3.938a.75.75 0 111.08 1.04l-4.25 4.5a.75.75 0 01-1.08 0l-4.25-4.5a.75.75 0 01.02-1.06z' clip-rule='evenodd'/%3E%3C/svg%3E") no-repeat right 10px center/12px;
  color: var(--green-dark);
  font-weight: 600;
  font-size: 0.85rem;
  font-family: inherit;
  cursor: pointer;
  appearance: none;
  -webkit-appearance: none;
  padding-right: 30px;
  transition: border-color 0.15s;
}
.lang-toggle-select:hover,
.lang-toggle-select:focus {
  border-color: var(--green);
  outline: none;
}
@media (max-width: 760px) {
  .lang-toggle-item { margin-top: 6px; }
  .lang-toggle-select { width: 100%; }
}

/* ---------- Digital membership card ---------- */
.membership-card-wrap {
  max-width: 460px;
  margin: 0 auto 32px;
}
.membership-card {
  background: var(--white);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  overflow: hidden;
}
.membership-card-header {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 14px 16px;
  background: linear-gradient(120deg, var(--green-dark), var(--green));
  color: var(--white);
}
.membership-card-logo {
  width: 42px; height: 42px;
  flex-shrink: 0;
  border-radius: 50%;
  background: var(--white);
  padding: 3px;
  object-fit: contain;
}
.membership-card-header-text { flex: 1; min-width: 0; }
.membership-card-org {
  font-family: var(--font-head);
  font-size: 1.1rem;
  font-weight: 800;
  letter-spacing: 0.02em;
  line-height: 1.2;
}
.membership-card-org-address {
  font-size: 0.68rem;
  color: rgba(255, 255, 255, 0.85);
  margin-top: 2px;
  line-height: 1.3;
}
.membership-card-body {
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 18px;
}
.membership-card-photo-col { flex-shrink: 0; }
.membership-card-details-col { flex: 1; min-width: 0; }
.membership-card-photo,
.membership-card-photo-placeholder {
  width: 110px; height: 140px;
  flex-shrink: 0;
  border-radius: 10px;
  border: 2px solid var(--cream-dark);
  object-fit: cover;
  background: var(--cream);
}
.membership-card-photo-placeholder {
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 2.4rem;
  font-weight: 700;
  font-family: var(--font-head);
  color: var(--green-dark);
  background: var(--green-light);
}
.detail-row {
  display: flex;
  gap: 8px;
  margin-bottom: 6px;
  font-size: 0.88rem;
}
.detail-label {
  min-width: 112px;
  font-weight: 600;
  color: var(--green-dark);
}
.detail-sep { color: var(--muted); }
.detail-value { color: var(--ink); font-weight: 500; }

.membership-card-share {
  text-align: center;
  margin-top: 20px;
}
.share-buttons {
  display: flex;
  justify-content: center;
  gap: 10px;
  flex-wrap: wrap;
}
.share-btn { color: var(--white); border: none; font-family: inherit; }
.share-btn-whatsapp { background: #25945a; }
.share-btn-whatsapp:hover { background: #1e7a48; }
.share-btn-facebook { background: #1877f2; }
.share-btn-instagram { background: linear-gradient(45deg, #f58529, #dd2a7b, #8134af, #515bd4); }

/* ---------- Referral card ---------- */
.referral-card {
  max-width: 640px;
  margin: 0 auto;
  background: var(--white);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: 26px;
}
.referral-link-row {
  display: flex;
  gap: 10px;
}
.referral-link-row input {
  flex: 1;
  padding: 12px 14px;
  border: 1.5px solid #dce4dc;
  border-radius: 8px;
  background: var(--cream);
  font-size: 0.9rem;
}
.referral-link-row .btn { flex-shrink: 0; }

@media (max-width: 480px) {
  .membership-card-org { font-size: 1rem; }
  .membership-card-photo,
  .membership-card-photo-placeholder { width: 78px; height: 100px; font-size: 1.7rem; }
  .detail-label { min-width: 92px; }
  .referral-link-row { flex-direction: column; }
}