/* ============================================
   BEIT KAVKAZ — TRADITIONAL EXPERIENCE
   Design System & Styles (Enhanced)
   ============================================ */

/* --- Custom Properties --- */
:root {
  /* Backgrounds */
  --bg-cream: #FAFAF7;
  --bg-warm: #F5F0E8;
  --bg-navy: #1a2744;
  --bg-navy-deep: #0d1b2a;

  /* Accents */
  --clr-burgundy: #8B1A2B;
  --clr-burgundy-light: #a82240;
  --clr-gold: #C5A55A;
  --clr-gold-light: #d4b96e;
  --clr-gold-dark: #a8893d;

  /* Text */
  --clr-text: #2a2a2a;
  --clr-text-muted: #5a5a5a;
  --clr-text-light: #f0ece4;
  --clr-text-gold: #C5A55A;

  /* Borders */
  --border-gold: 2px solid #C5A55A;
  --border-gold-thin: 1px solid #C5A55A;
  --border-subtle: 1px solid #e0dbd0;

  /* Shadows */
  --shadow-sm: 0 2px 8px rgba(26, 39, 68, .06);
  --shadow-md: 0 4px 20px rgba(26, 39, 68, .1);
  --shadow-lg: 0 8px 40px rgba(26, 39, 68, .14);
  --shadow-card: 0 2px 8px rgba(0,0,0,.06), 0 8px 24px rgba(26,39,68,.08);

  /* Typography */
  --font-heading: 'Roboto Slab', Georgia, serif;
  --font-body: 'Roboto', -apple-system, sans-serif;

  /* Spacing */
  --space-xs: .5rem;
  --space-sm: 1rem;
  --space-md: 1.5rem;
  --space-lg: 2.5rem;
  --space-xl: 4rem;
  --space-2xl: 6rem;
  --space-3xl: 8rem;

  /* Layout */
  --container-max: 1200px;
  --container-narrow: 900px;
  --nav-height: 72px;
  --radius: 4px;
  --radius-md: 6px;

  /* Transitions */
  --ease: cubic-bezier(.25, .46, .45, .94);
  --duration: 300ms;
}

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

html {
  scroll-behavior: smooth;
  scroll-padding-top: var(--nav-height);
}

body {
  font: 400 1rem/1.7 var(--font-body);
  color: var(--clr-text);
  background: var(--bg-cream);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

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

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

ul { list-style: none; }

button {
  font: inherit;
  cursor: pointer;
  border: none;
  background: none;
}

h1, h2, h3, h4 {
  font-family: var(--font-heading);
  line-height: 1.25;
}

/* --- Utility --- */
.container {
  max-width: var(--container-max);
  margin: 0 auto;
  padding: 0 var(--space-md);
}

.section {
  padding: var(--space-3xl) 0;
}

.section--dark {
  background: var(--bg-navy);
  color: var(--clr-text-light);
}

.section--warm {
  background: var(--bg-warm);
  background-image:
    repeating-linear-gradient(
      90deg,
      transparent,
      transparent 40px,
      rgba(197,165,90,.015) 40px,
      rgba(197,165,90,.015) 41px
    );
}

.section__header {
  text-align: center;
  margin-bottom: var(--space-xl);
  position: relative;
}

/* Gold corner ornaments on section headers */
.section__header::before,
.section__header::after {
  content: '';
  position: absolute;
  width: 28px;
  height: 28px;
  border-color: var(--clr-gold);
  border-style: solid;
  opacity: .45;
  pointer-events: none;
}

.section__header::before {
  top: -12px;
  left: 0;
  border-width: 2px 0 0 2px;
}

.section__header::after {
  top: -12px;
  right: 0;
  border-width: 2px 2px 0 0;
}

.section__title {
  font-size: clamp(2rem, 4.5vw, 2.75rem);
  font-weight: 700;
  margin-bottom: var(--space-sm);
  letter-spacing: .01em;
  border-bottom: 1px solid rgba(197,165,90,.3);
  display: inline-block;
  padding-bottom: .3rem;
}

.section__divider {
  width: 80px;
  height: 3px;
  background: var(--clr-gold);
  margin: var(--space-sm) auto;
}

.section__subtitle {
  font-size: 1.1rem;
  color: var(--clr-text-muted);
  max-width: 600px;
  margin: var(--space-sm) auto 0;
  font-weight: 300;
}

.section--dark .section__subtitle {
  color: rgba(240, 236, 228, .7);
}

/* Subtle texture background — diagonal stripes + radial glows */
.texture-bg {
  background-image:
    repeating-linear-gradient(
      45deg,
      transparent,
      transparent 10px,
      rgba(197,165,90,.02) 10px,
      rgba(197,165,90,.02) 11px
    ),
    radial-gradient(circle at 20% 50%, rgba(197, 165, 90, .03) 0%, transparent 50%),
    radial-gradient(circle at 80% 20%, rgba(139, 26, 43, .02) 0%, transparent 50%),
    linear-gradient(180deg, transparent 0%, rgba(197, 165, 90, .02) 100%);
}

/* --- Navigation --- */
.site-header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 1000;
  background: var(--bg-navy-deep);
  border-bottom: var(--border-gold);
  height: var(--nav-height);
  transition: box-shadow var(--duration) var(--ease);
}

.site-header--scrolled {
  box-shadow: 0 4px 20px rgba(0, 0, 0, .3);
}

.nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: var(--nav-height);
}

.nav__brand {
  display: flex;
  align-items: center;
  gap: var(--space-xs);
  color: var(--clr-text-gold);
  font-family: var(--font-heading);
  font-size: 1.35rem;
  font-weight: 700;
  letter-spacing: .02em;
}

.nav__brand svg {
  flex-shrink: 0;
}

.nav__menu {
  display: flex;
  align-items: center;
  gap: var(--space-lg);
}

.nav__link {
  color: var(--clr-text-light);
  font-size: .9rem;
  font-weight: 400;
  letter-spacing: .03em;
  text-transform: uppercase;
  padding: var(--space-xs) 0;
  position: relative;
  transition: color var(--duration) var(--ease);
}

.nav__link::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  width: 0;
  height: 2px;
  background: var(--clr-gold);
  transition: width var(--duration) var(--ease);
}

.nav__link:hover,
.nav__link:focus-visible {
  color: var(--clr-gold);
}

.nav__link:hover::after,
.nav__link:focus-visible::after {
  width: 100%;
}

.nav__link--gateway {
  color: var(--clr-gold);
  font-weight: 500;
  display: flex;
  align-items: center;
  gap: .3rem;
}

.nav__link--gateway:hover {
  color: var(--clr-gold-light);
}

.nav__toggle {
  display: none;
  flex-direction: column;
  gap: 5px;
  padding: var(--space-xs);
  z-index: 1001;
}

.nav__toggle span {
  display: block;
  width: 24px;
  height: 2px;
  background: var(--clr-gold);
  transition: transform var(--duration) var(--ease), opacity var(--duration) var(--ease);
}

.nav__toggle--active span:nth-child(1) {
  transform: translateY(7px) rotate(45deg);
}

.nav__toggle--active span:nth-child(2) {
  opacity: 0;
}

.nav__toggle--active span:nth-child(3) {
  transform: translateY(-7px) rotate(-45deg);
}

/* --- Hero --- */
.hero {
  position: relative;
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  background: url('../../assets/images/synagogue_interior.png') center/cover no-repeat;
  margin-top: var(--nav-height);
  overflow: hidden;
}

.hero__overlay {
  position: absolute;
  inset: 0;
  background:
    radial-gradient(ellipse at center, transparent 30%, rgba(13,27,42,.4) 100%),
    linear-gradient(
      180deg,
      rgba(13, 27, 42, .75) 0%,
      rgba(26, 39, 68, .8) 50%,
      rgba(13, 27, 42, .85) 100%
    );
}

.hero__content {
  position: relative;
  z-index: 1;
  padding: var(--space-xl) var(--space-md);
  max-width: 800px;
}

.hero__star {
  margin-bottom: var(--space-md);
  opacity: .8;
}

.hero__title {
  font-size: clamp(2.5rem, 7vw, 4.5rem);
  font-weight: 700;
  color: #fff;
  letter-spacing: .04em;
  margin-bottom: var(--space-sm);
  text-shadow: 0 2px 30px rgba(0,0,0,.45), 0 4px 60px rgba(0,0,0,.2);
}

.hero__title-divider {
  width: 120px;
  height: 3px;
  background: var(--clr-gold);
  margin: var(--space-md) auto;
}

.hero__subtitle-wrapper {
  height: 3.5rem;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: var(--space-lg);
  overflow: hidden;
}

.hero__subtitle {
  font-family: var(--font-heading);
  font-size: clamp(1rem, 2.5vw, 1.4rem);
  font-weight: 400;
  color: var(--clr-gold-light);
  letter-spacing: .06em;
  text-shadow: 0 1px 12px rgba(0,0,0,.3);
  transition: opacity 600ms var(--ease), transform 600ms var(--ease);
}

.hero__subtitle--hidden {
  opacity: 0;
  transform: translateY(12px);
}

.hero__cta {
  display: inline-block;
  padding: .9rem 2.5rem;
  background: var(--clr-burgundy);
  color: #fff;
  font-family: var(--font-heading);
  font-size: 1rem;
  font-weight: 600;
  letter-spacing: .06em;
  text-transform: uppercase;
  border: 2px solid var(--clr-burgundy);
  transition: background var(--duration) var(--ease), border-color var(--duration) var(--ease);
}

.hero__cta:hover,
.hero__cta:focus-visible {
  background: var(--clr-burgundy-light);
  border-color: var(--clr-gold);
}

/* --- Leadership --- */
.leadership {
  background:
    linear-gradient(135deg, rgba(197, 165, 90, .04) 0%, transparent 40%),
    var(--bg-warm);
}

.leadership__grid {
  display: grid;
  grid-template-columns: 280px 1fr;
  gap: var(--space-xl);
  align-items: start;
  margin-bottom: var(--space-xl);
}

/* Double-border portrait frame: 3px gold + 6px gap + 1px gold */
.leadership__portrait {
  aspect-ratio: 3/4;
  background: linear-gradient(135deg, var(--bg-navy) 0%, #2a3a5c 100%);
  border: 3px solid var(--clr-gold);
  outline: 1px solid var(--clr-gold);
  outline-offset: 6px;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: var(--shadow-md);
}

.leadership__initials {
  font-family: var(--font-heading);
  font-size: 4rem;
  font-weight: 700;
  color: var(--clr-gold);
  letter-spacing: .1em;
  opacity: .6;
}

.leadership__info h3 {
  font-size: 1.8rem;
  font-weight: 700;
  color: var(--clr-text);
  margin-bottom: var(--space-xs);
}

.leadership__role {
  font-family: var(--font-heading);
  font-size: 1.1rem;
  font-weight: 400;
  color: var(--clr-burgundy);
  margin-bottom: var(--space-md);
  letter-spacing: .02em;
}

/* Mission text gold left border accent */
.leadership__info p {
  font-size: 1.05rem;
  line-height: 1.8;
  color: var(--clr-text-muted);
  padding-left: var(--space-sm);
  border-left: 2px solid rgba(197,165,90,.3);
}

.leadership__info p + p {
  margin-top: var(--space-sm);
}

.leadership__secondary {
  border-top: var(--border-gold);
  padding-top: var(--space-lg);
  max-width: var(--container-narrow);
  margin: 0 auto;
  text-align: center;
}

.leadership__secondary h4 {
  font-size: 1.3rem;
  font-weight: 600;
  margin-bottom: var(--space-xs);
}

.leadership__secondary p {
  font-size: 1.05rem;
  color: var(--clr-text-muted);
  line-height: 1.8;
}

/* --- Heritage --- */
.heritage__grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: var(--space-xl);
  align-items: start;
}

.heritage__image {
  position: relative;
  border: 3px solid var(--clr-gold);
  box-shadow: var(--shadow-md);
  overflow: hidden;
}

.heritage__image img {
  width: 100%;
  aspect-ratio: 4/3;
  object-fit: cover;
}

.heritage__narrative h3 {
  font-size: 1.4rem;
  font-weight: 600;
  color: var(--clr-gold);
  margin-bottom: var(--space-sm);
}

.heritage__narrative p {
  font-size: 1.05rem;
  line-height: 1.8;
  margin-bottom: var(--space-md);
}

.heritage__phrases {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: var(--space-md);
  margin-top: var(--space-lg);
}

.heritage__phrase-box {
  padding: var(--space-md);
  border: var(--border-gold);
  text-align: center;
  background: rgba(197, 165, 90, .05);
}

.heritage__phrase-lang {
  font-size: .75rem;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: .1em;
  color: var(--clr-gold-dark);
  margin-bottom: var(--space-xs);
}

.heritage__phrase-text {
  font-family: var(--font-heading);
  font-size: 1.2rem;
  font-weight: 600;
  color: var(--clr-text);
}

.heritage__phrase-meaning {
  font-size: .85rem;
  color: var(--clr-text-muted);
  margin-top: 4px;
}

.section--dark .heritage__phrase-box {
  background: rgba(197, 165, 90, .08);
  border-color: rgba(197, 165, 90, .4);
}

.section--dark .heritage__phrase-text {
  color: var(--clr-text-light);
}

.section--dark .heritage__phrase-meaning {
  color: rgba(240, 236, 228, .6);
}

/* --- Traditions & Values --- */
.values__grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: var(--space-lg);
}

.value-card {
  background: linear-gradient(180deg, #fff 0%, #faf8f2 100%);
  padding: var(--space-lg) var(--space-md);
  border-top: 5px solid var(--clr-gold);
  box-shadow: 0 2px 8px rgba(0,0,0,.06), 0 8px 24px rgba(26,39,68,.08);
  text-align: center;
  position: relative;
  transition: transform var(--duration) var(--ease), box-shadow var(--duration) var(--ease);
}

.value-card::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 50%;
  width: 0;
  height: 3px;
  background: var(--clr-gold);
  transition: width var(--duration) var(--ease), left var(--duration) var(--ease);
}

.value-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 4px 12px rgba(0,0,0,.08), 0 12px 36px rgba(26,39,68,.12), 0 0 0 1px rgba(197,165,90,.2);
}

.value-card:hover::after {
  width: 60%;
  left: 20%;
}

.value-card__icon {
  width: 56px;
  height: 56px;
  margin: 0 auto var(--space-md);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--clr-burgundy);
}

.value-card__icon svg {
  width: 40px;
  height: 40px;
}

.value-card__title {
  font-size: 1.15rem;
  font-weight: 600;
  margin-bottom: var(--space-xs);
}

.value-card__subtitle {
  font-size: .85rem;
  color: var(--clr-gold-dark);
  font-weight: 500;
  margin-bottom: var(--space-sm);
  letter-spacing: .03em;
}

.value-card__desc {
  font-size: .95rem;
  color: var(--clr-text-muted);
  line-height: 1.7;
}

/* --- Learn Juhuri --- */
.learn-juhuri {
  background:
    linear-gradient(135deg, rgba(13, 27, 42, .02) 0%, transparent 50%),
    var(--bg-warm);
}

.learn__controls {
  display: flex;
  gap: var(--space-md);
  margin-bottom: var(--space-lg);
  flex-wrap: wrap;
  align-items: center;
}

.learn__search {
  flex: 1;
  min-width: 250px;
  padding: .75rem 1rem .75rem 2.5rem;
  font: 400 .95rem var(--font-body);
  border: var(--border-gold-thin);
  background: #fff url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' viewBox='0 0 24 24' fill='none' stroke='%23a8893d' stroke-width='2'%3E%3Ccircle cx='11' cy='11' r='8'/%3E%3Cpath d='M21 21l-4.35-4.35'/%3E%3C/svg%3E") 12px center no-repeat;
  color: var(--clr-text);
  outline: none;
  transition: border-color var(--duration) var(--ease), box-shadow var(--duration) var(--ease);
}

.learn__search:focus {
  border-color: var(--clr-gold);
  box-shadow: 0 0 0 3px rgba(197, 165, 90, .15);
}

.learn__filter-btns {
  display: flex;
  gap: var(--space-xs);
  flex-wrap: wrap;
}

.learn__filter-btn {
  padding: .5rem 1.2rem;
  font-size: .85rem;
  font-weight: 500;
  letter-spacing: .03em;
  border: var(--border-gold-thin);
  color: var(--clr-text-muted);
  background: #fff;
  transition: all var(--duration) var(--ease);
}

.learn__filter-btn:hover,
.learn__filter-btn--active {
  background: var(--clr-gold);
  color: #fff;
  border-color: var(--clr-gold);
}

.vocab-table {
  width: 100%;
  border-collapse: collapse;
  background: #fff;
  box-shadow: var(--shadow-card);
}

/* Header row subtle gold gradient */
.vocab-table thead {
  background: linear-gradient(135deg, var(--bg-navy) 0%, #1e3050 60%, var(--bg-navy) 100%);
  color: var(--clr-text-gold);
}

.vocab-table th {
  font-family: var(--font-heading);
  font-size: .85rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: .08em;
  padding: var(--space-sm) var(--space-md);
  text-align: left;
}

.vocab-table td {
  padding: .75rem var(--space-md);
  font-size: .95rem;
  border-bottom: var(--border-subtle);
}

/* Alternating row tints */
.vocab-table tbody tr:nth-child(even) td {
  background: rgba(245,240,232,.5);
}

.vocab-table tr:hover td {
  background: rgba(197, 165, 90, .04);
}

.vocab-table .category-header td {
  background: var(--bg-warm);
  font-family: var(--font-heading);
  font-weight: 600;
  font-size: .9rem;
  color: var(--clr-burgundy);
  letter-spacing: .04em;
  border-bottom: var(--border-gold);
  padding: .6rem var(--space-md);
}

/* Better RTL column padding */
.vocab-table .rtl {
  direction: rtl;
  font-size: 1.05rem;
  padding-inline: var(--space-lg);
}

.vocab-table tr.hidden {
  display: none;
}

.proverbs {
  margin-top: var(--space-xl);
}

.proverbs__title {
  font-size: 1.3rem;
  font-weight: 600;
  margin-bottom: var(--space-md);
  text-align: center;
}

.proverbs__grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: var(--space-md);
}

.proverb-card {
  padding: var(--space-md);
  border-left: 4px solid var(--clr-gold);
  background: #fff;
  box-shadow: var(--shadow-sm);
}

.proverb-card__juhuri {
  font-family: var(--font-heading);
  font-size: 1.05rem;
  font-weight: 600;
  color: var(--clr-text);
  margin-bottom: var(--space-xs);
}

.proverb-card__english {
  font-size: .9rem;
  color: var(--clr-text-muted);
  font-style: italic;
}

/* --- Programs --- */
.programs__grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: var(--space-lg);
}

.program-card {
  background: rgba(240, 236, 228, .3);
  padding: var(--space-lg) var(--space-md);
  border: 1px solid rgba(197, 165, 90, .2);
  text-align: center;
  transition: transform var(--duration) var(--ease), border-color var(--duration) var(--ease);
}

.program-card:hover {
  transform: translateY(-4px);
  border-color: var(--clr-gold);
}

.program-card__icon {
  width: 48px;
  height: 48px;
  margin: 0 auto var(--space-md);
  color: var(--clr-burgundy);
  display: flex;
  align-items: center;
  justify-content: center;
}

.program-card__icon svg {
  width: 36px;
  height: 36px;
}

.section--dark .program-card__icon {
  color: var(--clr-gold);
}

.program-card__title {
  font-size: 1.1rem;
  font-weight: 600;
  margin-bottom: var(--space-xs);
}

.program-card__desc {
  font-size: .9rem;
  color: rgba(240, 236, 228, .7);
  line-height: 1.7;
}

/* --- Gallery --- */
.gallery__grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: var(--space-md);
}

.gallery__item {
  position: relative;
  overflow: hidden;
  border: 3px solid var(--clr-gold);
  cursor: pointer;
  transition: transform var(--duration) var(--ease), box-shadow var(--duration) var(--ease);
}

/* Gold corner bracket accents — top-left and bottom-right */
.gallery__item::before,
.gallery__item::after {
  content: '';
  position: absolute;
  width: 20px;
  height: 20px;
  border-color: rgba(197,165,90,.7);
  border-style: solid;
  z-index: 2;
  pointer-events: none;
  transition: opacity var(--duration) var(--ease);
  opacity: 0;
}

.gallery__item::before {
  top: 8px;
  left: 8px;
  border-width: 2px 0 0 2px;
}

.gallery__item::after {
  bottom: 8px;
  right: 8px;
  border-width: 0 2px 2px 0;
}

.gallery__item:hover::before,
.gallery__item:hover::after {
  opacity: 1;
}

.gallery__item:hover {
  transform: scale(1.02);
  box-shadow: var(--shadow-lg);
}

.gallery__item img {
  width: 100%;
  aspect-ratio: 1;
  object-fit: cover;
  transition: transform 500ms var(--ease);
}

.gallery__item:hover img {
  transform: scale(1.08);
}

.gallery__caption {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  padding: var(--space-sm) var(--space-sm);
  background: linear-gradient(transparent, rgba(13, 27, 42, .85));
  font-family: var(--font-heading);
  font-size: .85rem;
  font-weight: 400;
  color: var(--clr-text-light);
  letter-spacing: .02em;
  transform: translateY(100%);
  transition: transform var(--duration) var(--ease);
}

.gallery__item:hover .gallery__caption {
  transform: translateY(0);
}

/* Lightbox — smoother transition */
.lightbox {
  position: fixed;
  inset: 0;
  z-index: 2000;
  background: rgba(13, 27, 42, .95);
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  visibility: hidden;
  transition: opacity 400ms var(--ease), visibility 400ms var(--ease);
}

.lightbox--active {
  opacity: 1;
  visibility: visible;
}

.lightbox__img {
  max-width: 90vw;
  max-height: 85vh;
  object-fit: contain;
  border: 3px solid var(--clr-gold);
  box-shadow: 0 0 60px rgba(0, 0, 0, .5);
  transition: transform 400ms var(--ease);
  transform: scale(.92);
}

.lightbox--active .lightbox__img {
  transform: scale(1);
}

.lightbox__close {
  position: absolute;
  top: var(--space-md);
  right: var(--space-md);
  width: 48px;
  height: 48px;
  color: var(--clr-gold);
  font-size: 2rem;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: color var(--duration) var(--ease);
}

.lightbox__close:hover {
  color: #fff;
}

/* --- Contact --- */
.contact__grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: var(--space-xl);
  align-items: start;
}

.contact__info h3 {
  font-size: 1.4rem;
  font-weight: 600;
  margin-bottom: var(--space-md);
}

.contact__detail {
  display: flex;
  align-items: center;
  gap: var(--space-sm);
  padding: var(--space-sm) 0;
  border-bottom: var(--border-subtle);
  font-size: 1rem;
}

.contact__detail-icon {
  color: var(--clr-burgundy);
  flex-shrink: 0;
}

.contact__detail a {
  color: var(--clr-burgundy);
  font-weight: 500;
  transition: color var(--duration) var(--ease);
}

.contact__detail a:hover {
  color: var(--clr-burgundy-light);
}

.contact__form {
  background: #fff;
  padding: var(--space-lg);
  border: var(--border-gold-thin);
  box-shadow: var(--shadow-card);
}

.contact__form h3 {
  font-size: 1.2rem;
  font-weight: 600;
  margin-bottom: var(--space-md);
}

.form__group {
  margin-bottom: var(--space-md);
}

.form__label {
  display: block;
  font-size: .85rem;
  font-weight: 500;
  letter-spacing: .03em;
  margin-bottom: var(--space-xs);
  color: var(--clr-text);
}

.form__input,
.form__textarea {
  width: 100%;
  padding: .7rem 1rem;
  font: 400 .95rem var(--font-body);
  color: var(--clr-text);
  border: var(--border-subtle);
  background: var(--bg-cream);
  outline: none;
  transition: border-color var(--duration) var(--ease);
}

.form__input:focus,
.form__textarea:focus {
  border-color: var(--clr-gold);
}

.form__textarea {
  min-height: 120px;
  resize: vertical;
}

.form__submit {
  padding: .75rem 2rem;
  background: var(--clr-burgundy);
  color: #fff;
  font-family: var(--font-heading);
  font-size: .95rem;
  font-weight: 600;
  letter-spacing: .05em;
  text-transform: uppercase;
  border: 2px solid var(--clr-burgundy);
  transition: background var(--duration) var(--ease), border-color var(--duration) var(--ease);
}

.form__submit:hover {
  background: var(--clr-burgundy-light);
  border-color: var(--clr-gold);
}

/* --- Footer --- */
.footer {
  background: var(--bg-navy-deep);
  color: var(--clr-text-light);
  padding: var(--space-xl) 0 var(--space-md);
  /* Carpet-pattern geometric stripe border-top */
  border-top: none;
  border-image:
    repeating-linear-gradient(
      90deg,
      var(--clr-gold) 0px,
      var(--clr-gold) 8px,
      var(--bg-navy-deep) 8px,
      var(--bg-navy-deep) 12px,
      var(--clr-burgundy) 12px,
      var(--clr-burgundy) 16px,
      var(--bg-navy-deep) 16px,
      var(--bg-navy-deep) 20px
    ) 4;
  border-top-width: 4px;
  border-top-style: solid;
}

.footer__grid {
  display: grid;
  grid-template-columns: 1.5fr 1fr 1fr;
  gap: var(--space-xl);
  padding-bottom: var(--space-lg);
  border-bottom: 1px solid rgba(197, 165, 90, .2);
  margin-bottom: var(--space-md);
}

.footer__brand-name {
  font-family: var(--font-heading);
  font-size: 1.4rem;
  font-weight: 700;
  color: var(--clr-gold);
  margin-bottom: var(--space-xs);
}

.footer__brand-tagline {
  font-size: .9rem;
  color: rgba(240, 236, 228, .6);
  line-height: 1.6;
}

.footer__heading {
  font-size: .8rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: .1em;
  color: var(--clr-gold);
  margin-bottom: var(--space-sm);
}

.footer__links {
  display: flex;
  flex-direction: column;
  gap: var(--space-xs);
}

.footer__link {
  font-size: .9rem;
  color: rgba(240, 236, 228, .6);
  transition: color var(--duration) var(--ease);
}

.footer__link:hover {
  color: var(--clr-gold);
}

.footer__social-links {
  display: flex;
  gap: var(--space-sm);
}

.footer__social-link {
  width: 40px;
  height: 40px;
  border: 1px solid rgba(197, 165, 90, .3);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--clr-gold);
  transition: background var(--duration) var(--ease), color var(--duration) var(--ease);
}

.footer__social-link:hover {
  background: var(--clr-gold);
  color: var(--bg-navy-deep);
}

.footer__bottom {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding-top: var(--space-md);
  font-size: .8rem;
  color: rgba(240, 236, 228, .4);
}

.footer__bilingual {
  font-style: italic;
}

/* --- Scroll Animations --- */
.reveal {
  opacity: 0;
  transform: translateY(30px);
  transition: opacity 700ms var(--ease), transform 700ms var(--ease);
}

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

/* --- Responsive --- */
@media (max-width: 1024px) {
  .values__grid,
  .programs__grid {
    grid-template-columns: repeat(2, 1fr);
  }

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

  .heritage__grid {
    grid-template-columns: 1fr;
  }

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

@media (max-width: 768px) {
  :root {
    --space-3xl: 5rem;
    --space-xl: 3rem;
    --space-lg: 2rem;
    --nav-height: 60px;
  }

  .nav__toggle {
    display: flex;
  }

  .nav__menu {
    position: fixed;
    top: 0;
    right: 0;
    width: 280px;
    height: 100vh;
    background: var(--bg-navy-deep);
    flex-direction: column;
    justify-content: center;
    gap: var(--space-md);
    padding: var(--space-xl);
    transform: translateX(100%);
    transition: transform var(--duration) var(--ease);
    border-left: var(--border-gold);
    z-index: 1000;
  }

  .nav__menu--open {
    transform: translateX(0);
  }

  .nav__link {
    font-size: 1rem;
  }

  .leadership__grid {
    grid-template-columns: 1fr;
    text-align: center;
  }

  .leadership__portrait {
    max-width: 220px;
    margin: 0 auto;
  }

  /* Center-aligned mission text drops left border on mobile */
  .leadership__info p {
    border-left: none;
    padding-left: 0;
  }

  .values__grid,
  .programs__grid {
    grid-template-columns: 1fr;
  }

  .gallery__grid {
    grid-template-columns: 1fr 1fr;
  }

  .contact__grid {
    grid-template-columns: 1fr;
  }

  .heritage__phrases {
    grid-template-columns: 1fr;
  }

  .proverbs__grid {
    grid-template-columns: 1fr;
  }

  .footer__grid {
    grid-template-columns: 1fr;
    gap: var(--space-lg);
  }

  .footer__bottom {
    flex-direction: column;
    gap: var(--space-xs);
    text-align: center;
  }

  .vocab-table {
    font-size: .85rem;
  }

  .vocab-table th,
  .vocab-table td {
    padding: .5rem .6rem;
  }

  .learn__controls {
    flex-direction: column;
    align-items: stretch;
  }

  .learn__search {
    min-width: unset;
  }

  /* Hide corner ornaments on smaller screens */
  .section__header::before,
  .section__header::after {
    display: none;
  }
}

@media (max-width: 480px) {
  .hero__title {
    font-size: 2.2rem;
  }

  .gallery__grid {
    grid-template-columns: 1fr;
  }

  .hero__subtitle-wrapper {
    height: 4.5rem;
  }

  .vocab-table th:nth-child(4),
  .vocab-table td:nth-child(4),
  .vocab-table th:nth-child(5),
  .vocab-table td:nth-child(5) {
    display: none;
  }
}
