/* ============================================================
   SMB Trust — Unified Stylesheet
   Design System: "The Digital Sanctuary"
   ============================================================ */

/* --- CSS Custom Properties (Design Tokens) --- */
:root {
  /* Primary palette */
  --primary: #894c2d;
  --primary-container: #a66443;
  --on-primary: #ffffff;
  --on-primary-container: #fffbff;
  --primary-fixed: #ffdbcc;
  --primary-fixed-dim: #ffb693;
  --on-primary-fixed: #351000;
  --on-primary-fixed-variant: #6f381a;

  /* Secondary palette */
  --secondary: #735c00;
  --secondary-container: #fed65b;
  --on-secondary: #ffffff;
  --on-secondary-container: #745c00;
  --secondary-fixed: #ffe088;
  --secondary-fixed-dim: #e9c349;

  /* Tertiary palette */
  --tertiary: #0058bc;
  --tertiary-container: #0070eb;
  --on-tertiary: #ffffff;
  --on-tertiary-container: #fefcff;
  --tertiary-fixed: #d8e2ff;
  --tertiary-fixed-dim: #adc6ff;

  /* Neutral / Surface palette */
  --surface: #fcf8fb;
  --surface-dim: #dcd9dc;
  --surface-bright: #fcf8fb;
  --surface-container-lowest: #ffffff;
  --surface-container-low: #f6f3f5;
  --surface-container: #f0edef;
  --surface-container-high: #eae7ea;
  --surface-container-highest: #e4e2e4;
  --surface-variant: #e4e2e4;
  --on-surface: #1b1b1d;
  --on-surface-variant: #53433d;
  --on-background: #1b1b1d;
  --background: #fcf8fb;
  --inverse-surface: #303032;
  --inverse-on-surface: #f3f0f2;
  --inverse-primary: #ffb693;
  --surface-tint: #8c4e2f;

  /* Outline */
  --outline: #85736c;
  --outline-variant: #d8c2b9;

  /* Error */
  --error: #ba1a1a;
  --error-container: #ffdad6;
  --on-error: #ffffff;
  --on-error-container: #93000a;

  /* Typography */
  --font-headline: 'Inter', 'Noto Sans Tamil', sans-serif;
  --font-body: 'Inter', 'Noto Sans Tamil', sans-serif;
  --font-label: 'Inter', sans-serif;
  --font-tamil: 'Noto Sans Tamil', sans-serif;

  /* Spacing scale */
  --space-1: 0.25rem;
  --space-2: 0.5rem;
  --space-3: 0.75rem;
  --space-4: 1rem;
  --space-5: 1.25rem;
  --space-6: 1.5rem;
  --space-8: 2rem;
  --space-10: 2.5rem;
  --space-12: 3rem;
  --space-16: 4rem;
  --space-20: 5rem;
  --space-24: 6rem;
  --space-32: 8rem;

  /* Border radius */
  --radius-sm: 0.25rem;
  --radius-md: 0.5rem;
  --radius-lg: 0.75rem;
  --radius-xl: 1rem;
  --radius-2xl: 1.5rem;
  --radius-3xl: 2rem;
  --radius-4xl: 2.5rem;
  --radius-5xl: 3rem;
  --radius-full: 9999px;

  /* Shadows */
  --shadow-sm: 0 1px 2px rgba(27,27,29,0.05);
  --shadow-md: 0 4px 12px rgba(27,27,29,0.08);
  --shadow-lg: 0 8px 24px rgba(27,27,29,0.1);
  --shadow-xl: 0 16px 40px rgba(27,27,29,0.12);
  --shadow-2xl: 0 24px 60px rgba(27,27,29,0.15);

  /* Transitions */
  --transition-fast: 200ms ease;
  --transition-base: 300ms ease;
  --transition-slow: 500ms ease;
  --transition-slower: 700ms ease;

  /* Container */
  --container-max: 80rem; /* 1280px */
}

/* --- Reset & Base --- */
*,
*::before,
*::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  scroll-behavior: smooth;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

body {
  font-family: var(--font-body);
  background-color: var(--surface);
  color: var(--on-surface);
  line-height: 1.6;
  overflow-x: hidden;
}

::selection {
  background-color: rgba(137, 76, 45, 0.2);
}

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

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

button {
  cursor: pointer;
  border: none;
  font-family: inherit;
  font-size: inherit;
}

input, select, textarea {
  font-family: inherit;
  font-size: inherit;
}

ul, ol {
  list-style: none;
}

/* --- Typography --- */
.tamil-text {
  font-family: var(--font-tamil);
  line-height: 1.8;
}

h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-headline);
  line-height: 1.1;
}

.text-display {
  font-size: clamp(2.5rem, 6vw, 3.5rem);
  font-weight: 700;
  letter-spacing: -0.03em;
}

.text-headline-lg {
  font-size: clamp(2rem, 4vw, 3rem);
  font-weight: 700;
  letter-spacing: -0.02em;
}

.text-headline {
  font-size: clamp(1.5rem, 3vw, 2.5rem);
  font-weight: 700;
  letter-spacing: -0.02em;
}

.text-title-lg {
  font-size: 1.375rem;
  font-weight: 700;
}

.text-title {
  font-size: 1.125rem;
  font-weight: 700;
}

.text-body-lg {
  font-size: 1.125rem;
  font-weight: 300;
  line-height: 1.7;
}

.text-body {
  font-size: 1rem;
  font-weight: 300;
  line-height: 1.7;
}

.text-label {
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  font-family: var(--font-label);
}

.font-light { font-weight: 300; }
.font-normal { font-weight: 400; }
.font-medium { font-weight: 500; }
.font-semibold { font-weight: 600; }
.font-bold { font-weight: 700; }
.italic { font-style: italic; }
.uppercase { text-transform: uppercase; }
.tracking-tight { letter-spacing: -0.02em; }
.tracking-tighter { letter-spacing: -0.03em; }
.tracking-widest { letter-spacing: 0.15em; }
.leading-tight { line-height: 1.1; }
.leading-relaxed { line-height: 1.7; }

/* --- Layout --- */
.container {
  width: 100%;
  max-width: var(--container-max);
  margin-left: auto;
  margin-right: auto;
  padding-left: var(--space-8);
  padding-right: var(--space-8);
}

.breathing-room {
  padding-top: clamp(3rem, 8vw, 8rem);
  padding-bottom: clamp(3rem, 8vw, 8rem);
}

.section-padding {
  padding-top: var(--space-24);
  padding-bottom: var(--space-24);
}

/* Flexbox utilities */
.flex { display: flex; }
.flex-col { flex-direction: column; }
.flex-row { flex-direction: row; }
.flex-wrap { flex-wrap: wrap; }
.items-center { align-items: center; }
.items-start { align-items: start; }
.items-end { align-items: end; }
.justify-center { justify-content: center; }
.justify-between { justify-content: space-between; }
.justify-end { justify-content: flex-end; }
.gap-2 { gap: var(--space-2); }
.gap-3 { gap: var(--space-3); }
.gap-4 { gap: var(--space-4); }
.gap-6 { gap: var(--space-6); }
.gap-8 { gap: var(--space-8); }
.gap-12 { gap: var(--space-12); }
.gap-16 { gap: var(--space-16); }
.flex-1 { flex: 1; }
.shrink-0 { flex-shrink: 0; }

/* Grid */
.grid { display: grid; }
.grid-cols-1 { grid-template-columns: repeat(1, 1fr); }
.grid-cols-2 { grid-template-columns: repeat(2, 1fr); }
.col-span-2 { grid-column: span 2; }

/* Text alignment */
.text-center { text-align: center; }
.text-right { text-align: right; }

/* Width & Height */
.w-full { width: 100%; }
.h-full { height: 100%; }
.max-w-3xl { max-width: 48rem; }
.max-w-4xl { max-width: 56rem; }
.max-w-5xl { max-width: 64rem; }
.mx-auto { margin-left: auto; margin-right: auto; }

/* Position */
.relative { position: relative; }
.absolute { position: absolute; }
.fixed { position: fixed; }
.sticky { position: sticky; }
.inset-0 { top: 0; right: 0; bottom: 0; left: 0; }
.z-10 { z-index: 10; }
.z-20 { z-index: 20; }
.z-50 { z-index: 50; }

/* Overflow */
.overflow-hidden { overflow: hidden; }
.overflow-x-auto { overflow-x: auto; }

/* Display */
.hidden { display: none; }
.block { display: block; }
.inline-flex { display: inline-flex; }
.inline-block { display: inline-block; }

/* --- Navbar --- */
.navbar {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 100;
  background: rgba(252, 248, 251, 0.7);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  transition: background var(--transition-base), box-shadow var(--transition-base);
}

.navbar.scrolled {
  background: rgba(252, 248, 251, 0.95);
  box-shadow: 0 1px 8px rgba(27, 27, 29, 0.06);
}

.navbar-inner {
  display: flex;
  justify-content: space-between;
  align-items: center;
  max-width: var(--container-max);
  margin: 0 auto;
  padding: var(--space-4) var(--space-8);
  width: 100%;
}

.navbar-logo {
  font-size: 1.25rem;
  font-weight: 700;
  letter-spacing: -0.03em;
  color: var(--on-surface);
  font-family: var(--font-headline);
}

.navbar-links {
  display: none;
  align-items: center;
  gap: var(--space-8);
}

.navbar-link {
  font-family: var(--font-body);
  font-weight: 300;
  font-size: 0.9375rem;
  letter-spacing: -0.01em;
  color: rgba(27, 27, 29, 0.8);
  transition: color var(--transition-base);
  line-height: 1.7;
  padding-bottom: 2px;
}

.navbar-link:hover,
.navbar-link.active {
  color: var(--primary);
}

.navbar-link.active {
  font-weight: 500;
  border-bottom: 2px solid var(--primary);
}

.lang-toggle {
  font-weight: 500;
  color: var(--primary);
  cursor: pointer;
  font-size: 0.9375rem;
  background: none;
  transition: transform var(--transition-fast);
  white-space: nowrap;
}

.lang-toggle:hover {
  transform: scale(0.95);
}

/* Hamburger */
.hamburger {
  display: flex;
  flex-direction: column;
  gap: 5px;
  cursor: pointer;
  background: none;
  padding: 4px;
  z-index: 110;
}

.hamburger span {
  display: block;
  width: 24px;
  height: 2px;
  background: var(--on-surface);
  transition: all var(--transition-base);
  border-radius: 2px;
}

.hamburger.open span:nth-child(1) {
  transform: rotate(45deg) translate(5px, 5px);
}

.hamburger.open span:nth-child(2) {
  opacity: 0;
}

.hamburger.open span:nth-child(3) {
  transform: rotate(-45deg) translate(5px, -5px);
}

/* Mobile menu */
.mobile-menu {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: var(--surface);
  z-index: 105;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: var(--space-8);
  opacity: 0;
  pointer-events: none;
  transition: opacity var(--transition-base);
}

.mobile-menu.open {
  opacity: 1;
  pointer-events: all;
}

.mobile-menu a {
  font-size: 1.5rem;
  font-weight: 300;
  color: var(--on-surface);
  transition: color var(--transition-base);
}

.mobile-menu a:hover,
.mobile-menu a.active {
  color: var(--primary);
}

/* --- Buttons --- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: var(--space-3);
  padding: var(--space-4) var(--space-8);
  border-radius: var(--radius-2xl);
  font-weight: 500;
  font-size: 1rem;
  transition: all var(--transition-base);
  line-height: 1;
  white-space: nowrap;
}

.btn:active {
  transform: scale(0.95);
}

.btn-primary {
  background: var(--primary);
  color: var(--on-primary);
}

.btn-primary:hover {
  background: var(--primary-container);
}

.btn-secondary {
  background: transparent;
  color: var(--on-surface);
  border: 1px solid rgba(216, 194, 185, 0.3);
}

.btn-secondary:hover {
  background: var(--surface-container);
}

.btn-surface {
  background: var(--surface);
  color: var(--primary);
  font-weight: 700;
}

.btn-surface:hover {
  background: var(--primary-fixed);
}

.btn-pill {
  border-radius: var(--radius-full);
}

.btn-lg {
  padding: var(--space-5) var(--space-10);
  font-size: 1.125rem;
  font-weight: 700;
}

.btn-full {
  width: 100%;
}

/* --- Cards --- */
.card {
  background: var(--surface-container-low);
  border-radius: var(--radius-3xl);
  overflow: hidden;
  transition: all var(--transition-slow);
}

.card:hover {
  box-shadow: var(--shadow-xl);
}

.card-body {
  padding: var(--space-8);
}

.card-rounded {
  border-radius: var(--radius-4xl);
}

.card-surface {
  background: var(--surface);
}

.card-elevated {
  background: var(--surface-container-lowest);
  box-shadow: var(--shadow-sm);
}

.card-primary {
  background: var(--primary);
  color: var(--on-primary);
}

.card-tertiary {
  background: var(--tertiary-container);
  color: var(--on-tertiary-container);
}

.card-dark {
  background: var(--on-surface);
  color: var(--surface);
}

.card-bordered {
  border: 1px solid rgba(216, 194, 185, 0.15);
}

/* --- Icon containers --- */
.icon-circle {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 3.5rem;
  height: 3.5rem;
  border-radius: var(--radius-2xl);
  background: rgba(137, 76, 45, 0.1);
  color: var(--primary);
  transition: transform var(--transition-base);
}

.icon-circle-lg {
  width: 6rem;
  height: 6rem;
  border-radius: var(--radius-full);
}

.group:hover .icon-circle {
  transform: scale(1.1);
}

/* --- Hero sections --- */
.hero {
  position: relative;
  width: 100%;
  display: flex;
  align-items: center;
  overflow: hidden;
}

.hero-full {
  min-height: 100vh;
  justify-content: center;
}

.hero-tall {
  height: clamp(500px, 70vh, 921px);
}

/* Background image: works on a child <div> wrapper OR handles direct <img> in hero */
.hero > img,
.hero-image img,
.hero > .hero-image {
  position: absolute;
  inset: 0;
  z-index: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

/* When hero-image is used as a class on the section itself, don't make section absolute */
section.hero-image,
section.hero.hero-image {
  position: relative;
}

/* Dim filter — applies to the section's direct img child */
.hero-image-dim > img,
.hero-image-dim .hero-image img {
  filter: brightness(0.75) contrast(0.9) grayscale(0.1);
}

.hero-gradient-bottom::after {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(to bottom, transparent 50%, var(--surface));
  z-index: 1;
  pointer-events: none;
}

.hero-gradient-right::after {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(to right, var(--surface), rgba(252,248,251,0.8) 40%, transparent);
  z-index: 1;
  pointer-events: none;
}

.hero-overlay::after {
  content: '';
  position: absolute;
  inset: 0;
  background: rgba(27, 27, 29, 0.4);
  z-index: 1;
  pointer-events: none;
}

.hero-overlay-strong::after {
  background: rgba(27, 27, 29, 0.5);
}

.hero-overlay-gradient-left::after {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(to right, rgba(27,27,29,0.8), transparent);
  z-index: 1;
  pointer-events: none;
}

.hero-content {
  position: relative;
  z-index: 10;
  padding: var(--space-8);
  width: 100%;
  text-align: center;
}

/* --- Impact counter --- */
.counter-section {
  background: rgba(234, 231, 234, 0.5);
}

.counter-value {
  font-size: clamp(2.5rem, 5vw, 3.75rem);
  font-weight: 700;
  color: var(--primary);
  letter-spacing: -0.03em;
  line-height: 1;
}

.counter-label {
  font-size: 0.75rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.15em;
  color: rgba(27, 27, 29, 0.5);
  margin-top: var(--space-2);
}

.counter-tamil {
  font-family: var(--font-tamil);
  color: rgba(27, 27, 29, 0.4);
  font-size: 0.8125rem;
  margin-top: var(--space-2);
  line-height: 1.8;
}

/* --- Bento grid --- */
.bento-grid {
  display: grid;
  grid-template-columns: repeat(12, 1fr);
  gap: var(--space-6);
}

.bento-7 { grid-column: span 12; }
.bento-5 { grid-column: span 12; }
.bento-8 { grid-column: span 12; }
.bento-4 { grid-column: span 12; }

/* --- Timeline --- */
.timeline-scroll {
  display: flex;
  overflow-x: auto;
  gap: var(--space-8);
  padding-bottom: var(--space-8);
  scroll-snap-type: x mandatory;
  -ms-overflow-style: none;
  scrollbar-width: none;
}

.timeline-scroll::-webkit-scrollbar {
  display: none;
}

.timeline-item {
  min-width: 280px;
  scroll-snap-align: start;
  flex-shrink: 0;
}

.timeline-year {
  font-size: 3rem;
  font-weight: 700;
  color: rgba(137, 76, 45, 0.2);
  margin-bottom: var(--space-4);
}

.timeline-divider {
  width: 100%;
  height: 1px;
  background: rgba(216, 194, 185, 0.2);
  margin-bottom: var(--space-6);
}

/* --- Team --- */
.team-avatar {
  width: 10rem;
  height: 10rem;
  border-radius: var(--radius-full);
  overflow: hidden;
  margin: 0 auto var(--space-6);
  filter: grayscale(1);
  transition: filter var(--transition-slow);
}

.group:hover .team-avatar,
.team-avatar:hover {
  filter: grayscale(0);
}

.team-avatar img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

/* --- Testimonials --- */
.testimonial-card {
  background: var(--surface);
  padding: var(--space-12);
  border-radius: var(--radius-4xl);
  border: 1px solid rgba(216, 194, 185, 0.15);
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  height: 100%;
}

.testimonial-text {
  font-size: 1.375rem;
  font-weight: 300;
  font-style: italic;
  line-height: 1.6;
  margin-bottom: var(--space-8);
}

.testimonial-avatar {
  width: 3rem;
  height: 3rem;
  border-radius: var(--radius-full);
  overflow: hidden;
}

.testimonial-avatar img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

/* --- Photo gallery masonry --- */
.masonry-grid {
  columns: 1;
  gap: var(--space-8);
}

.masonry-grid img {
  width: 100%;
  border-radius: var(--radius-3xl);
  margin-bottom: var(--space-8);
  box-shadow: var(--shadow-sm);
  transition: box-shadow var(--transition-base);
}

.masonry-grid img:hover {
  box-shadow: var(--shadow-xl);
}

/* --- Form styles --- */
.form-group {
  margin-bottom: var(--space-8);
}

.form-label {
  display: block;
  font-size: 0.75rem;
  font-weight: 500;
  color: rgba(27, 27, 29, 0.6);
  text-transform: uppercase;
  letter-spacing: 0.15em;
  margin-bottom: var(--space-2);
}

.form-input,
.form-select,
.form-textarea {
  width: 100%;
  background: var(--surface-container-low);
  border: none;
  border-bottom: 2px solid rgba(216, 194, 185, 0.15);
  padding: var(--space-4);
  font-size: 1.125rem;
  color: var(--on-surface);
  transition: border-color var(--transition-base);
  outline: none;
  border-radius: 0;
  appearance: none;
}

.form-input:focus,
.form-select:focus,
.form-textarea:focus {
  border-bottom-color: var(--primary);
}

.form-textarea {
  resize: none;
  min-height: 120px;
}

.form-select {
  cursor: pointer;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12'%3E%3Cpath fill='%2353433d' d='M6 8L1 3h10z'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 1rem center;
  padding-right: 2.5rem;
}

/* --- Footer --- */
.footer {
  background: var(--surface-container-low);
  padding: var(--space-16) var(--space-8);
  margin-top: var(--space-20);
}

.footer-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--space-12);
  max-width: var(--container-max);
  margin: 0 auto;
  font-family: var(--font-body);
  font-size: 0.875rem;
  line-height: 1.8;
}

.footer-brand {
  font-size: 1.125rem;
  font-weight: 700;
  color: var(--on-surface);
  margin-bottom: var(--space-6);
}

.footer-text {
  color: rgba(27, 27, 29, 0.6);
  max-width: 20rem;
}

.footer-heading {
  font-weight: 700;
  color: var(--on-surface);
  margin-bottom: var(--space-6);
  font-size: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 0.15em;
}

.footer-link {
  display: block;
  color: rgba(27, 27, 29, 0.6);
  transition: color var(--transition-base);
  padding: var(--space-1) 0;
}

.footer-link:hover {
  color: var(--primary);
}

.footer-social {
  display: flex;
  gap: var(--space-4);
}

.footer-social a {
  color: rgba(27, 27, 29, 0.4);
  transition: color var(--transition-base);
}

.footer-social a:hover {
  color: var(--primary);
}

.footer-bottom {
  max-width: var(--container-max);
  margin: var(--space-16) auto 0;
  padding-top: var(--space-8);
  border-top: 1px solid rgba(216, 194, 185, 0.1);
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 0.75rem;
  color: rgba(27, 27, 29, 0.4);
  flex-wrap: wrap;
  gap: var(--space-4);
}

.footer-bottom a {
  transition: color var(--transition-base);
}

.footer-bottom a:hover {
  color: var(--primary);
}

/* --- Newsletter input --- */
.newsletter-wrap {
  display: flex;
  background: var(--surface);
  border-radius: var(--radius-full);
  padding: 4px;
  border: 1px solid rgba(216, 194, 185, 0.2);
}

.newsletter-wrap input {
  flex: 1;
  background: transparent;
  border: none;
  padding: var(--space-2) var(--space-4);
  font-size: 0.875rem;
  outline: none;
  min-width: 0;
}

.newsletter-wrap button {
  background: var(--primary);
  color: var(--on-primary);
  border-radius: var(--radius-full);
  padding: var(--space-2);
  display: flex;
  align-items: center;
  justify-content: center;
}

/* --- WhatsApp floating button --- */
.whatsapp-fab {
  position: fixed;
  bottom: var(--space-8);
  right: var(--space-8);
  z-index: 90;
  background: #25D366;
  color: white;
  border-radius: var(--radius-full);
  padding: var(--space-4);
  box-shadow: var(--shadow-2xl);
  display: flex;
  align-items: center;
  gap: 0;
  transition: all var(--transition-base);
  text-decoration: none;
  overflow: hidden;
}

.whatsapp-fab:hover {
  gap: var(--space-2);
  padding-left: var(--space-6);
}

.whatsapp-fab:active {
  transform: scale(0.95);
}

.whatsapp-fab-label {
  max-width: 0;
  overflow: hidden;
  white-space: nowrap;
  transition: max-width var(--transition-slow), padding var(--transition-slow);
  font-weight: 700;
  font-size: 0.875rem;
  padding: 0;
}

.whatsapp-fab:hover .whatsapp-fab-label {
  max-width: 10rem;
  padding-right: var(--space-2);
}

.whatsapp-fab svg {
  width: 2rem;
  height: 2rem;
  fill: currentColor;
  flex-shrink: 0;
}

/* --- Pill / Badge --- */
.badge {
  display: inline-flex;
  align-items: center;
  gap: var(--space-2);
  padding: var(--space-1) var(--space-3);
  border-radius: var(--radius-full);
  font-size: 0.75rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.1em;
}

.badge-primary {
  background: var(--primary);
  color: var(--on-primary);
}

.badge-primary-soft {
  background: rgba(137, 76, 45, 0.1);
  color: var(--primary);
}

.badge-secondary-soft {
  background: rgba(115, 92, 0, 0.1);
  color: var(--secondary);
}

/* --- Quote block --- */
.quote-section .quote-icon {
  font-size: 4.5rem;
  color: rgba(137, 76, 45, 0.2);
}

.quote-text {
  font-size: clamp(1.5rem, 3vw, 2.5rem);
  font-weight: 300;
  line-height: 1.3;
  font-style: italic;
  margin-bottom: var(--space-12);
}

.quote-avatar {
  width: 4rem;
  height: 4rem;
  border-radius: var(--radius-full);
  overflow: hidden;
  margin-bottom: var(--space-4);
}

.quote-avatar img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

/* --- Dark section --- */
.section-dark {
  background: var(--on-surface);
  color: var(--surface);
}

.section-dark .text-muted {
  color: var(--surface-dim);
}

/* --- Partners --- */
.partners-grid {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  align-items: center;
  gap: var(--space-12);
  opacity: 0.6;
  filter: grayscale(1);
  transition: all var(--transition-slow);
}

.partners-grid:hover {
  filter: grayscale(0);
  opacity: 0.8;
}

.partners-grid img {
  height: 2.5rem;
  object-fit: contain;
}

.partners-grid span {
  font-size: 1.25rem;
  font-weight: 700;
}

/* --- Scroll animations --- */
.fade-in {
  opacity: 0;
  transform: translateY(30px);
  transition: opacity 0.8s ease, transform 0.8s ease;
}

.fade-in.visible {
  opacity: 1;
  transform: translateY(0);
}

.fade-in-left {
  opacity: 0;
  transform: translateX(-30px);
  transition: opacity 0.8s ease, transform 0.8s ease;
}

.fade-in-left.visible {
  opacity: 1;
  transform: translateX(0);
}

.fade-in-right {
  opacity: 0;
  transform: translateX(30px);
  transition: opacity 0.8s ease, transform 0.8s ease;
}

.fade-in-right.visible {
  opacity: 1;
  transform: translateX(0);
}

/* --- Color utilities --- */
.text-primary { color: var(--primary); }
.text-on-surface { color: var(--on-surface); }
.text-on-surface-variant { color: var(--on-surface-variant); }
.text-on-primary { color: var(--on-primary); }
.text-white { color: #ffffff; }
.text-muted { color: rgba(27, 27, 29, 0.6); }
.text-muted-more { color: rgba(27, 27, 29, 0.4); }

.bg-surface { background: var(--surface); }
.bg-surface-low { background: var(--surface-container-low); }
.bg-surface-container { background: var(--surface-container); }
.bg-surface-high { background: var(--surface-container-high); }
.bg-surface-highest { background: var(--surface-container-highest); }
.bg-surface-lowest { background: var(--surface-container-lowest); }
.bg-primary { background: var(--primary); }
.bg-on-surface { background: var(--on-surface); }
.bg-tertiary-container { background: var(--tertiary-container); }

/* --- Aspect ratios --- */
.aspect-16-10 { aspect-ratio: 16 / 10; }
.aspect-square { aspect-ratio: 1; }
.aspect-4-5 { aspect-ratio: 4 / 5; }

/* --- Object fit --- */
.object-cover { object-fit: cover; }
.object-contain { object-fit: contain; }

/* --- Line clamp --- */
.line-clamp-2 {
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

/* --- Misc utilities --- */
.rounded-full { border-radius: var(--radius-full); }
.rounded-3xl { border-radius: var(--radius-3xl); }
.rounded-2xl { border-radius: var(--radius-2xl); }
.rounded-xl { border-radius: var(--radius-xl); }

.shadow-sm { box-shadow: var(--shadow-sm); }
.shadow-lg { box-shadow: var(--shadow-lg); }
.shadow-xl { box-shadow: var(--shadow-xl); }
.shadow-2xl { box-shadow: var(--shadow-2xl); }

.opacity-90 { opacity: 0.9; }
.opacity-80 { opacity: 0.8; }
.opacity-70 { opacity: 0.7; }
.opacity-60 { opacity: 0.6; }
.opacity-50 { opacity: 0.5; }
.opacity-40 { opacity: 0.4; }
.opacity-20 { opacity: 0.2; }
.opacity-10 { opacity: 0.1; }

.grayscale { filter: grayscale(1); }
.grayscale-light { filter: grayscale(0.2); }

.transition-all { transition: all var(--transition-base); }
.transition-transform { transition: transform var(--transition-base); }

.hover-scale:hover { transform: scale(1.05); }
.hover-lift:hover { transform: translateY(-4px); }
.group:hover .group-hover-scale { transform: scale(1.05); }
.group:hover .group-hover-arrow { transform: translateX(4px); }

.pointer { cursor: pointer; }

/* Bilingual toggle - hide inactive language */
/* Bilingual toggle: hide Tamil by default, swap on body.lang-ta */
[data-lang-ta] { display: none !important; }
body.lang-ta [data-lang-en] { display: none !important; }
body.lang-ta [data-lang-ta] { display: inline !important; }
body.lang-ta p[data-lang-ta],
body.lang-ta div[data-lang-ta],
body.lang-ta h1[data-lang-ta],
body.lang-ta h2[data-lang-ta],
body.lang-ta h3[data-lang-ta],
body.lang-ta li[data-lang-ta],
body.lang-ta blockquote[data-lang-ta] { display: block !important; }

/* --- Material Symbols --- */
.material-symbols-outlined {
  font-variation-settings: 'FILL' 0, 'wght' 300, 'GRAD' 0, 'opsz' 24;
  display: inline-block;
  line-height: 1;
  vertical-align: middle;
}

.icon-filled {
  font-variation-settings: 'FILL' 1, 'wght' 400, 'GRAD' 0, 'opsz' 24;
}

/* --- Success message (contact form) --- */
.form-success {
  display: none;
  text-align: center;
  padding: var(--space-16) var(--space-8);
}

.form-success.show {
  display: block;
}

.form-success .material-symbols-outlined {
  font-size: 4rem;
  color: #25D366;
  margin-bottom: var(--space-4);
}

/* ============================================================
   RESPONSIVE BREAKPOINTS
   ============================================================ */

/* Tablet: 768px+ */
@media (min-width: 768px) {
  .navbar-links {
    display: flex;
  }

  .hamburger {
    display: none;
  }

  .md-flex { display: flex; }
  .md-grid-cols-2 { grid-template-columns: repeat(2, 1fr); }
  .md-grid-cols-3 { grid-template-columns: repeat(3, 1fr); }
  .md-grid-cols-4 { grid-template-columns: repeat(4, 1fr); }
  .md-grid-cols-5 { grid-template-columns: repeat(5, 1fr); }
  .md-col-span-2 { grid-column: span 2; }
  .md-col-span-4 { grid-column: span 4; }
  .md-col-span-5 { grid-column: span 5; }
  .md-col-span-7 { grid-column: span 7; }
  .md-col-span-8 { grid-column: span 8; }
  .md-col-span-12 { grid-column: span 12; }
  .md-flex-row { flex-direction: row; }
  .md-hidden { display: none; }
  .md-block { display: block; }
  .md-w-half { width: 50%; }
  .md-w-3-5 { width: 60%; }
  .md-w-2-5 { width: 40%; }
  .md-order-1 { order: 1; }
  .md-order-2 { order: 2; }
  .md-items-center { align-items: center; }
  .md-text-left { text-align: left; }
  .md-p-24 { padding: var(--space-24); }

  .bento-7 { grid-column: span 7; }
  .bento-5 { grid-column: span 5; }
  .bento-8 { grid-column: span 8; }
  .bento-4 { grid-column: span 4; }

  .footer-grid {
    grid-template-columns: repeat(3, 1fr);
  }

  .masonry-grid {
    columns: 3;
  }
}

/* Desktop: 1024px+ */
@media (min-width: 1024px) {
  .lg-grid-cols-4 { grid-template-columns: repeat(4, 1fr); }
  .lg-grid-cols-5 { grid-template-columns: repeat(5, 1fr); }
  .lg-grid-cols-12 { grid-template-columns: repeat(12, 1fr); }
  .lg-col-span-5 { grid-column: span 5; }
  .lg-col-span-7 { grid-column: span 7; }
  .lg-col-span-8 { grid-column: span 8; }
  .lg-col-span-12 { grid-column: span 12; }
}

/* Wide: 1440px+ */
@media (min-width: 1440px) {
  .container {
    padding-left: var(--space-12);
    padding-right: var(--space-12);
  }
}

/* Mobile-only: <768px */
@media (max-width: 767px) {
  .container {
    padding-left: var(--space-4);
    padding-right: var(--space-4);
  }

  .navbar-inner {
    padding-left: var(--space-4);
    padding-right: var(--space-4);
  }

  .hero-tall {
    height: clamp(400px, 80vh, 600px);
  }

  .card-body {
    padding: var(--space-6);
  }

  .testimonial-card {
    padding: var(--space-8);
  }

  .testimonial-text {
    font-size: 1.125rem;
  }

  .footer {
    padding: var(--space-12) var(--space-4);
  }

  .quote-text {
    font-size: 1.25rem;
  }

  .section-padding {
    padding-top: var(--space-16);
    padding-bottom: var(--space-16);
  }

  .get-involved-section {
    height: clamp(400px, 70vh, 600px);
  }
}

/* Touch targets */
@media (pointer: coarse) {
  .btn {
    min-height: 44px;
    min-width: 44px;
  }

  .navbar-link {
    padding: var(--space-2);
  }

  .footer-link {
    padding: var(--space-2) 0;
  }
}

/* ============================================================
   AGENT-GENERATED CLASS PATCHES
   Additional classes used by page HTML that weren't in base
   ============================================================ */

/* --- Hero subtitle --- */
.hero-subtitle {
  font-family: var(--font-tamil);
  font-size: clamp(1.5rem, 3vw, 2.5rem);
  font-weight: 300;
  color: rgba(255,255,255,0.9);
  line-height: 1.8;
  margin-top: var(--space-4);
}

.hero h1 {
  color: #fff;
  font-size: clamp(2.5rem, 6vw, 4.5rem);
  font-weight: 700;
  letter-spacing: -0.03em;
  line-height: 1.1;
  margin-bottom: var(--space-4);
}

.hero .btn {
  margin-top: var(--space-8);
}

/* --- Section wrapper --- */
.section {
  padding: clamp(3rem, 8vw, 6rem) 0;
}

/* --- Section header --- */
.section-header {
  text-align: center;
  margin-bottom: var(--space-16);
}

.section-header h2 {
  font-size: clamp(1.75rem, 4vw, 2.5rem);
  font-weight: 600;
  letter-spacing: -0.02em;
  color: var(--on-surface);
  margin-bottom: var(--space-4);
}

.section-line {
  height: 4px;
  width: 6rem;
  background: var(--primary);
  margin: 0 auto;
  border-radius: var(--radius-full);
  opacity: 0.3;
}

/* --- Card grid --- */
.card-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--space-8);
}

.card-grid-4 {
  grid-template-columns: 1fr;
}

/* --- Card icon --- */
.card-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: var(--space-4);
  border-radius: var(--radius-2xl);
  background: rgba(137, 76, 45, 0.1);
  color: var(--primary);
  margin-bottom: var(--space-6);
  transition: transform var(--transition-base);
}

.card-icon .material-symbols-outlined {
  font-size: 1.875rem;
}

.card:hover .card-icon {
  transform: scale(1.1);
}

/* --- Card text --- */
.card-tamil {
  color: rgba(27, 27, 29, 0.7);
  margin-bottom: var(--space-4);
  font-size: 0.9375rem;
}

.card-description {
  color: rgba(27, 27, 29, 0.6);
  font-weight: 300;
  line-height: 1.7;
  font-size: 0.9375rem;
}

/* --- Counter grid --- */
.counter-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: var(--space-12);
  text-align: center;
  padding: clamp(3rem, 8vw, 6rem) 0;
}

.counter-item {
  display: flex;
  flex-direction: column;
  align-items: center;
}

/* --- Quote block --- */
.quote-block {
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
}

.quote-block blockquote {
  font-size: clamp(1.25rem, 3vw, 2.25rem);
  font-weight: 300;
  line-height: 1.35;
  font-style: italic;
  color: var(--on-surface);
  margin-bottom: var(--space-12);
}

.quote-author {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: var(--space-4);
}

.quote-author img {
  width: 4rem;
  height: 4rem;
  border-radius: var(--radius-full);
  object-fit: cover;
}

.quote-author strong {
  font-size: 1.125rem;
  display: block;
}

.quote-author span {
  font-size: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 0.15em;
  color: rgba(27, 27, 29, 0.6);
}

/* --- Programs grid (heritage-tech) --- */
.programs-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--space-8);
}

/* --- Responsive patches for agent classes --- */
@media (min-width: 768px) {
  .card-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .counter-grid {
    grid-template-columns: repeat(4, 1fr);
  }

  .programs-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (min-width: 1024px) {
  .card-grid-4 {
    grid-template-columns: repeat(4, 1fr);
  }
}

/* --- Print --- */
@media print {
  .navbar, .whatsapp-fab, .mobile-menu {
    display: none;
  }

  body {
    background: white;
    color: black;
  }
}
