/* ==========================================================================
   MASTER STYLESHEET
   Japanese Language School Website
   --------------------------------------------------------------------------
   Table of Contents:
   1.  CSS Variables (Design Tokens)
   2.  Base & Reset
   3.  Typography
   4.  Utility Classes
   5.  Buttons
   6.  Animations & Transitions
   7.  Notice Bar
   8.  Navbar
   9.  Hero Section
   10. Services Section
   11. Courses Section
   12. Teachers Section
   13. Testimonials Section
   14. Exams Ticker
   15. Success Stories Section
   16. Activity / Gallery Grid
   17. Package Cards
   18. FAQ Section
   19. Branches Section
   20. Contact Section
   21. Footer
   22. Floating Buttons
   23. Language Utilities
   24. Responsive — Tablet (≤ 991px)
   25. Responsive — Mobile (≤ 767px)
   26. Responsive — Mid Tablet (768–991px)
   27. Responsive — Desktop (≥ 992px)
   ========================================================================== */


/* ==========================================================================
   1. CSS VARIABLES (Design Tokens)
   ========================================================================== */
:root {
  /* --- Brand Colors --- */
  /* THEME UPDATE: Primary shifted to deeper navy; red replaces cherry as accent */
  --primary:        #1a2a5e;   /* deep navy (was #243e7f) */
  --primary-dark:   #0f1e45;   /* darkest navy (was #0a2560) */
  --primary-light:  #243e7f;   /* mid navy (was #1a4fa0) */
  --secondary:      #6782a2;
  --secondary-light:#8ab0dc;
  --cherry:         #D2042D;
  --cherry-light:   #CF0234;
  --gold:           #c9a84c;
  --gold-light:     #e8c97a;
  --facebook:       #1877F2;

  /* --- Neutrals --- */
  --white:          #ffffff;
  --off-white:      #f8f9fc;
  --light-gray:     #eef1f8;
  --washi:          #f7f4ef;
  --sumi:           #2d2d2d;

  /* --- Text --- */
  --text-dark:      #1a2340;
  --text-muted:     #5a6480;

  /* --- Decorative --- */
  --noren:          rgba(26,42,94,0.06);
  --cherry-thin:      rgba(192,57,43,0.35);   /* red tint (was cherry tint) */

  /* --- Shadows --- */
  --shadow:         0 8px 40px rgba(26,42,94,0.10);
  --shadow-hover:   0 16px 60px rgba(26,42,94,0.18);

  /* --- Spacing & Shape --- */
  --section-pad:    100px 0;
  --radius:         4px;
  --radius-sm:      8px;

  /* --- Typography Scale (based on FAQ section standard) --- */
  --fs-body:        1rem;
  --fs-secondary:   0.95rem;
  --fs-small:       0.88rem;
  --fs-xsmall:      0.78rem;
  --lh-body:        1.85;
  --lh-tight:       1.7;

  /* --- Motion --- */
  --transition:     all 0.35s cubic-bezier(0.4,0,0.2,1);
}


/* ==========================================================================
   2. BASE & RESET
   ========================================================================== */
*, *::before, *::after { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  font-family: 'DM Sans', sans-serif;
  font-size: var(--fs-body);
  line-height: var(--lh-body);
  color: var(--text-dark);
  background: var(--white);
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
}

a {
  text-decoration: none;
  transition: var(--transition);
}

img { max-width: 100%; }

.section-pad { padding: 100px 0; }


/* ==========================================================================
   3. TYPOGRAPHY
   ========================================================================== */
h1, h2, h3, h4, h5 {
  font-family: 'Cormorant Garamond', serif;
  font-weight: 700;
  line-height: 1.2;
}

/* --- Section Eyebrow Label --- */
.section-eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 16px;
  font-size: 0.82rem;
  font-weight: 600;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--secondary);
  margin-bottom: 16px;
}
.section-eyebrow::before,
.section-eyebrow::after {
  content: '';
  display: block;
  width: 36px;
  height: 1px;
  background: var(--cherry);   /* red line */
}
.text-center .section-eyebrow { justify-content: center; }

/* --- Section Title --- */
.section-title {
  font-size: clamp(2.2rem, 4vw, 3.2rem);
  line-height: 1.15;
  letter-spacing: -0.01em;
  color: var(--primary);
  margin-bottom: 16px;
}

/* --- Section Subtitle --- */
.section-subtitle {
  font-size: var(--fs-body);
  line-height: var(--lh-body);
  color: var(--text-muted);
  max-width: 680px;
  margin: 0 auto;
}

/* --- Decorative Kanji Watermark --- */
.kanji-deco {
  position: absolute;
  font-family: 'Noto Serif JP', serif;
  font-size: clamp(80px, 14vw, 180px);
  font-weight: 700;
  color: rgba(26,42,94,0.04);
  line-height: 1;
  pointer-events: none;
  user-select: none;
  z-index: 0;
}


/* ==========================================================================
   4. UTILITY CLASSES
   ========================================================================== */
.text-cherry           { color: var(--cherry) !important; }
.text-primary-custom { color: var(--primary) !important; }
.bg-primary-custom   { background: var(--primary) !important; }

.divider-line {
  width: 40px;
  height: 1px;
  background: var(--cherry);   /* red divider */
  border-radius: 0;
  margin: 14px auto 0;
}
.divider-line.left { margin-left: 0; }


/* ==========================================================================
   5. BUTTONS
   ========================================================================== */
.btn-primary-custom,
.btn-outline-custom,
.btn-facebook,
.btn-cherry {
  font-size: 0.96rem;
  font-weight: 600;
  padding: 14px 38px;
  border-radius: var(--radius);
  letter-spacing: 0.05em;
  transition: var(--transition);
  display: inline-flex;
  align-items: center;
  gap: 8px;
  border: 2px solid transparent;
}


.btn-primary-custom {
  background: var(--primary);
  color: var(--white);
  border-color: var(--primary);
}
.btn-primary-custom:hover {
  background: var(--primary);
  color: var(--white);
  transform: translateY(-2px);
  box-shadow: 0 8px 30px var(--primary-light);
}

.btn-facebook {
  background: var(--facebook);
  color: var(--white);
  border-color: var(--facebook);
}
.btn-facebook:hover {
  background: var(--facebook);
  color: var(--white);
  transform: translateY(-2px);
  box-shadow: 0 4px 15px var(--facebook);
}

/* Outline button — white border (hero) */
.btn-outline-custom {
  background: var(--primary);
  color: var(--white);
  border-color: rgba(255,255,255,0.7);
}
.btn-outline-custom:hover {
  background: var(--primary-dark);
  border-color: var(--white);
  color: var(--white);
  transform: translateY(-2px);
}

.btn-cherry {
  background: var(--cherry);
  color: var(--white);
  border-color: var(--cherry);
}
.btn-cherry:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 30px var(--cherry-light);
}


/* ==========================================================================
   6. ANIMATIONS & TRANSITIONS
   ========================================================================== */
@keyframes pulse {
  0%, 100% { opacity: 1; transform: scale(1); }
  50%       { opacity: 0.5; transform: scale(1.4); }
}

@keyframes scroll-down {
  0%   { opacity: 1; transform: translateX(-50%) translateY(0); }
  100% { opacity: 0; transform: translateX(-50%) translateY(12px); }
}

@keyframes scroll-loop {
  0%   { transform: translateX(0); }
  100% { transform: translateX(-50%); }
}

@keyframes ticker {
  0%   { transform: translateX(100vw); }
  100% { transform: translateX(-100%); }
}

.fade-up {
  opacity: 0;
  transform: translateY(30px);
  transition: opacity 0.7s ease, transform 0.7s ease;
}
.fade-up.visible {
  opacity: 1;
  transform: translateY(0);
}


/* ==========================================================================
   7. NOTICE BAR
   ========================================================================== */
/* THEME: Red gradient (was cherry) */
.notice-bar {
  background: linear-gradient(90deg, var(--primary-light), var(--primary), var(--primary-dark));
  /* background-color: var(--primary-light); */
  color: var(--white);
  text-align: center;
  font-size: 0.78rem;
  font-weight: 600;
  padding: 8px 20px;
  letter-spacing: 0.06em;
  overflow: hidden;
}
.notice-bar:hover .notice-inner { animation-play-state: paused; }
.notice-bar .notice-inner {
  display: inline-block;
  white-space: nowrap;
  animation: ticker 30s linear infinite;
}


/* ==========================================================================
   8. NAVBAR
   ========================================================================== */
/* THEME: White background navbar (was dark navy) */
#mainNav {
  background: rgba(255,255,255,0.97);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  padding: 0;
  border-bottom: 1px solid rgba(26,42,94,0.10);
  transition: all 0.4s ease;
  z-index: 1050;
}
#mainNav.scrolled {
  background: rgba(255,255,255,0.99);
  box-shadow: 0 4px 30px rgba(0,0,0,0.08);
}

/* Brand */
.navbar-brand {
  padding: 18px 0;
  display: flex;
  align-items: center;
  gap: 12px;
}
.brand-logo-icon {
  width: 40px;
  height: 40px;
  padding: 0px;
  /* background-color: var(--primary); */
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: 'Noto Serif JP', serif;
  font-size: 20px;
  font-weight: 700;
  color: var(--white);
  flex-shrink: 0;
}
.brand-text {
  display: flex;
  flex-direction: column;
  line-height: 1.2;
}
.brand-name {
  font-family: 'Cormorant Garamond', serif;
  font-size: 1.05rem;
  font-weight: 700;
  color: var(--primary);       /* dark navy text on white bar */
  letter-spacing: 0.02em;
  margin-bottom: 5px;
  text-transform: uppercase;
}
.brand-sub {
  font-size: 0.7rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  font-weight: 500;
  color: var(--secondary);     /* muted navy (was secondary-light on dark bg) */
}

/* Nav links — dark text on white bar */
.navbar-nav .nav-link {
  color: var(--text-dark) !important;
  font-size: 0.82rem;
  font-weight: 500;
  padding: 26px 12px !important;
  letter-spacing: 0.06em;
  position: relative;
}
.navbar-nav .nav-link::after {
  content: '';
  position: absolute;
  bottom: 20px;
  left: 12px;
  right: 12px;
  height: 2px;
  background: var(--cherry);     /* red underline */
  border-radius: 2px;
  transform: scaleX(0);
  transition: var(--transition);
}
.navbar-nav .nav-link:hover              { color: var(--primary) !important; }
.navbar-nav .nav-link:hover::after,
.navbar-nav .nav-link.active::after      { transform: scaleX(1); }
.navbar-nav .nav-link.active             { color: var(--primary) !important; }

/* Language switcher — navy tones on white bg */
.lang-switcher {
  display: flex;
  align-items: center;
  gap: 2px;
  background: rgba(26,42,94,0.06);
  border: 1px solid rgba(26,42,94,0.14);
  border-radius: 50px;
  padding: 4px 6px;
  margin-left: 12px;
}
.lang-btn {
  background: none;
  border: none;
  color: rgba(26,42,94,0.55);
  font-size: 0.75rem;
  font-weight: 600;
  padding: 4px 10px;
  border-radius: 50px;
  cursor: pointer;
  transition: var(--transition);
  letter-spacing: 0.06em;
}
.lang-btn:hover  { color: var(--primary); }
.lang-btn.active { background: var(--primary); color: var(--white); }  /* red active */

.navbar-toggler {
  border-color: #fff;
  padding: 6px 10px;
}
.navbar-toggler:focus { box-shadow: none;}

/* Navbar toggler icon — dark on white */
.navbar-toggler-icon {
  filter: invert(1) sepia(1) saturate(3) hue-rotate(190deg) brightness(0.3);
}


/* ==========================================================================
   9. HERO SECTION
   ========================================================================== */
#hero {
  min-height: 100vh;
  position: relative;
  overflow: hidden;
  display: flex;
  align-items: center;
  background: linear-gradient(135deg, #0a1e50 0%, #0f3882 45%, #1a4a99 75%, #0f3882 100%);
}

.hero-bg-pattern {
  position: absolute;
  inset: 0;
  background-image:
    radial-gradient(circle at 20% 50%, rgba(96,146,204,0.18) 0%, transparent 50%),
    radial-gradient(circle at 80% 20%, rgba(192,57,43,0.08) 0%, transparent 40%),
    radial-gradient(circle at 60% 80%, rgba(96,146,204,0.10) 0%, transparent 40%);
  z-index: 0;
}

.hero-content {
  position: relative;
  z-index: 2;
  padding-top: 100px;
  padding-bottom: 80px;
}

/* Badge */
.hero-badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: rgba(255,255,255,0.10);
  border: 1px solid rgba(255,255,255,0.20);
  border-radius: 50px;
  padding: 7px 18px;
  font-size: 1rem;
  font-weight: 600;
  color: rgba(255,255,255,0.90);
  letter-spacing: 0.14em;
  text-transform: uppercase;
  margin-bottom: 28px;
  backdrop-filter: blur(8px);
}
.hero-badge .dot {
  width: 7px;
  height: 7px;
  background: var(--cherry);    /* red dot */
  border-radius: 50%;
  animation: pulse 2s infinite;
}

/* Headline */
.hero-headline {
  font-family: 'Playfair Display', 'Cormorant Garamond', serif;
  font-size: clamp(2.6rem, 6vw, 5rem);
  font-weight: 800;
  color: var(--white);
  line-height: 1.05;
  letter-spacing: -0.02em;
  margin-bottom: 24px;
}

/* Body text */
.hero-desc {
  color: var(--white);
  font-size: var(--fs-body);
  font-family:'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
  max-width: 520px;
  margin-top: 20px;
  margin-bottom: 40px;
  line-height: var(--lh-body);
  letter-spacing: 0.001em;
}

/* CTA row */
.hero-cta {
  display: flex;
  gap: 16px;
  flex-wrap: wrap;
  margin-bottom: 56px;
}

/* Stats row */
.hero-stats {
  display: flex;
  gap: 40px;
  flex-wrap: wrap;
}
.hero-stat {
  position: relative;
  padding-left: 16px;
}
.hero-stat::before {
  content: '';
  position: absolute;
  left: 0;
  top: 6px;
  bottom: 6px;
  width: 2px;
  background: var(--cherry);    /* red stat bar */
}
.hero-stat-num {
  font-family: 'Cormorant Garamond', serif;
  font-size: 2rem;
  font-weight: 700;
  color: var(--white);
  line-height: 1;
  letter-spacing: -0.02em;
}
.hero-stat-label {
  font-size: 0.76rem;
  color: rgba(255,255,255,0.6);
  font-weight: 500;
  letter-spacing: 0.05em;
  margin-top: 5px;
}

/* Visual / image side */
.hero-visual {
  position: relative;
  z-index: 2;
  padding-top: 80px;
}
.hero-image-wrap {
  position: relative;
  border-radius: 24px;
  overflow: hidden;
  box-shadow: 0 32px 80px rgba(0,0,0,0.4);
}
.hero-image-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(to top, rgba(15,56,130,0.6) 0%, transparent 60%);
}
.hero-image-card {
  position: absolute;
  bottom: 5px;
  left: 5px;
  right: 5px;
  background: rgba(255,255,255,0.12);
  backdrop-filter: blur(16px);
  border: 1px solid rgba(255,255,255,0.2);
  border-radius: 16px;
  padding: 10px 12px;
}
.hero-card-title {
  font-family: 'Cormorant Garamond', serif;
  font-size: 1.3rem;
  font-weight: 700;
  color: var(--white);
}
.hero-card-meta {
  font-size: 0.82rem;
  color: rgba(255,255,255,0.75);
  margin-top: 5px;
  display: flex;
  align-items: center;
  gap: 5px;
}

/* Floating badge */
.hero-floating-badge {
  position: absolute;
  top: 32px;
  right: -16px;
  background: var(--cherry);     /* red badge */
  color: var(--white);
  border-radius: 14px;
  padding: 14px 20px;
  text-align: center;
  box-shadow: 0 8px 30px rgba(192,57,43,0.45);
}
.hero-floating-badge .num {
  font-family: 'Cormorant Garamond', serif;
  font-size: 2rem;
  font-weight: 700;
  line-height: 1;
}
.hero-floating-badge .txt {
  font-size: 0.7rem;
  font-weight: 600;
  letter-spacing: 0.08em;
}

.hero-gradient {
  position: absolute;
  inset: 0;
  background: linear-gradient(100deg,
    rgba(10,30,80,0.85) 0%,
    rgba(10,30,80,0.75) 25%,
    rgba(10,30,80,0.4) 45%,
    rgba(10,30,80,0.1) 55%,
    rgba(10,30,80,0) 65%
  );
}

/* ===== HERO TEXT ANIMATION ===== */
.hero-animate-line {
  /* display: block; */
  opacity: 0;
  transform: translateY(40px);
  animation: heroLineIn 0.85s cubic-bezier(0.22, 1, 0.36, 1) forwards;
}

.hero-headline .hero-animate-line:nth-child(1) { animation-delay: 0.3s; }
.hero-headline .hero-animate-line:nth-child(2) { animation-delay: 0.55s; }
.hero-headline .hero-animate-line:nth-child(3) { animation-delay: 0.75s; }

.hero-animate-fade {
  opacity: 0;
  transform: translateY(20px);
  animation: heroFadeIn 0.8s cubic-bezier(0.22, 1, 0.36, 1) forwards;
}

@keyframes heroLineIn {
  0%   { opacity: 0; transform: translateY(40px); }
  100% { opacity: 1; transform: translateY(0); }
}

@keyframes heroFadeIn {
  0%   { opacity: 0; transform: translateY(20px); }
  100% { opacity: 1; transform: translateY(0); }
}

#pageLoader:not([style*="opacity: 0"]) ~ * .hero-animate-line,
#pageLoader:not([style*="opacity: 0"]) ~ * .hero-animate-fade {
  animation-play-state: paused;
}

/* ==========================================================================
   10. SERVICES SECTION
   ========================================================================== */
.lined-bg {
  background-image:
    repeating-linear-gradient(
      0deg,
      transparent,
      transparent 39px,
      rgba(26,42,94,0.025) 39px,
      rgba(26,42,94,0.025) 40px
    );
}

#services {
  background: var(--washi);
  padding: var(--section-pad);
  position: relative;
  overflow: hidden;
}

#services::before {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-image: url('../images/backgrounds/sakura.svg');
  background-size: contain;
  background-repeat: no-repeat;
  opacity: 0.125;
  pointer-events: none;
  z-index: 0;
  -webkit-mask-image: linear-gradient(to right, black 0%, transparent 80%);
  mask-image: linear-gradient(to right, black 0%, transparent 80%);
}

#services .container { position: relative; z-index: 1; }

/* Service card */
.service-card {
  background: var(--white);
  border-radius: var(--radius);
  padding: 36px 28px;
  border: 1px solid rgba(26,42,94,0.08);
  border-top: 3px solid transparent;
  transition: var(--transition);
  height: 100%;
  position: relative;
  overflow: hidden;
}
.service-card:hover {
  border-top-color: var(--cherry);   /* red top border */
  transform: translateY(-6px);
  box-shadow: 0 12px 40px rgba(26,42,94,0.10);
}

.service-icon {
  width: 52px;
  height: 52px;
  background: linear-gradient(135deg, rgba(26,42,94,0.08), rgba(96,146,204,0.12));
  border-radius: var(--radius);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 22px;
  color: var(--primary);
  margin-bottom: 20px;
  transition: var(--transition);
}
.service-card:hover .service-icon {
  background: linear-gradient(135deg, var(--cherry), #a93226);  /* red gradient */
  color: var(--white);
}

.service-title {
  font-family: 'Cormorant Garamond', serif;
  font-size: 1.4rem;
  font-weight: 700;
  color: var(--primary);
  margin-bottom: 14px;
}
.service-desc {
  font-size: var(--fs-body);
  color: var(--text-muted);
  line-height: var(--lh-body);
  margin-bottom: 22px;
}
.service-list {
  list-style: none;
  padding: 0;
  margin: 0;
}
.service-list li {
  font-size: var(--fs-secondary);
  color: var(--text-muted);
  padding: 7px 0 7px 22px;
  position: relative;
  line-height: var(--lh-body);
}
.service-list li::before {
  content: '—';
  position: absolute;
  left: 0;
  top: 9px;
  color: var(--cherry);   /* red dash */
  font-size: 0.75rem;
}

/* ===== FEATURED SERVICE CARDS ===== */
.fsc-card {
  background: var(--white);
  border-radius: 4px;
  overflow: hidden;
  border: 1px solid rgba(15,56,130,0.09);
  height: 100%;
  display: flex;
  flex-direction: column;
  transition: var(--transition);
}
.fsc-card:hover {
  transform: translateY(-6px);
  box-shadow: 0 20px 50px rgba(15,56,130,0.14);
}

/* Image area */
.fsc-img-wrap {
  position: relative;
  height: 220px;
  overflow: hidden;
  background: var(--primary-dark);
}
.fsc-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center top;
  display: block;
  transition: transform 0.6s ease;
}
.fsc-card:hover .fsc-img { transform: scale(1.06); }

.fsc-img-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(
    to bottom,
    rgba(10,30,80,0.25) 0%,
    rgba(10,30,80,0.55) 100%
  );
}

/* Icon badge on image */
.fsc-img-icon {
  position: absolute;
  top: 20px;
  left: 20px;
  width: 52px;
  height: 52px;
  background: rgba(255,255,255,0.12);
  border: 1.5px solid rgba(255,255,255,0.35);
  border-radius: 4px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--white);
  backdrop-filter: blur(6px);
}

/* Body */
.fsc-body {
  padding: 28px 26px 26px;
  display: flex;
  flex-direction: column;
  flex: 1;
}

.fsc-title {
  font-size: 1.35rem;
  font-weight: 700;
  color: var(--primary);
  line-height: 1.25;
  margin-bottom: 4px;
}

.fsc-subtitle {
  font-size: 0.82rem;
  color: var(--text-muted);
  font-weight: 500;
  margin-bottom: 14px;
  font-style: italic;
}

.fsc-desc {
  font-size: 0.9rem;
  color: var(--text-muted);
  line-height: 1.82;
  margin-bottom: 18px;
}

/* Checklist */
.fsc-list {
  list-style: none;
  padding: 0;
  margin: 0 0 24px;
  flex: 1;
}
.fsc-list li {
  font-size: 0.88rem;
  color: var(--text-dark);
  padding: 6px 0 6px 24px;
  position: relative;
  border-bottom: 1px solid var(--light-gray);
  line-height: 1.55;
}
.fsc-list li:last-child { border-bottom: none; }
.fsc-list li::before {
  content: '✓';
  position: absolute;
  left: 0;
  color: var(--cherry);
  font-weight: 700;
}


/* ==========================================================================
   11. COURSES SECTION
   ========================================================================== */
#courses {
  background: var(--white);
  padding: var(--section-pad);
  position: relative;
  overflow: hidden;
}

.course-card {
  border-radius: var(--radius);
  overflow: hidden;
  border: 1px solid rgba(26,42,94,0.10);
  transition: var(--transition);
  height: 100%;
}
.course-card:hover {
  transform: translateY(-6px);
  box-shadow: 0 12px 40px rgba(26,42,94,0.12);
}

/* Card header colour variants */
.course-header {
  padding: 24px 24px 18px;
  position: relative;
}
.course-header.beginner     { background: var(--light-gray); }
.course-header.intermediate { background: linear-gradient(135deg, var(--primary), var(--primary-light)); }
.course-header.jlpt         { background: linear-gradient(135deg, var(--cherry), var(--cherry-light)); }

/* Level badge */
.course-level-badge {
  display: inline-block;
  font-size: 0.76rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  padding: 4px 14px;
  border-radius: 50px;
  margin-bottom: 12px;
}

.beginner     .course-level-badge { background: var(--secondary);             color: var(--white); }
.intermediate .course-level-badge { background: rgba(255,255,255,0.2);      color: var(--white); border: 1px solid rgba(255,255,255,0.4); }
.jlpt         .course-level-badge { background: rgba(255,255,255,0.3);      color: var(--white); border: 1px solid rgba(255,255,255,0.5); }

.course-title-card {
  font-family: 'Cormorant Garamond', serif;
  font-size: 1.5rem;
  font-weight: 700;
  margin-bottom: 6px;
}
.beginner .course-title-card     { color: var(--primary); }
.intermediate .course-title-card,
.jlpt     .course-title-card     { color: var(--white); }

.course-jp { font-family: 'Noto Serif JP', serif; font-size: 0.9rem; opacity: 0.7; }
.beginner .course-jp             { color: var(--secondary); }
.intermediate .course-jp,
.jlpt .course-jp                 { color: rgba(255,255,255,0.7); }

.course-body { padding: 20px 24px 24px; background: var(--white); }

.course-meta {
  display: flex;
  gap: 20px;
  flex-wrap: wrap;
  margin-bottom: 16px;
}
.course-meta-item {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: var(--fs-small);
  color: var(--text-muted);
  font-weight: 500;
}
.course-meta-item i { color: var(--secondary); }

.course-desc-text {
  font-size: var(--fs-body);
  color: var(--text-muted);
  line-height: var(--lh-body);
  margin-bottom: 20px;
}

.course-features {
  list-style: none;
  padding: 0;
  margin: 0 0 22px;
}
.course-features li {
  font-size: var(--fs-secondary);
  color: var(--text-dark);
  padding: 5px 0 5px 22px;
  position: relative;
  border-bottom: 1px solid var(--light-gray);
}
.course-features li:last-child { border-bottom: none; }
.course-features li::before {
  content: '✓';
  position: absolute;
  left: 0;
  color: var(--cherry);   /* red checkmark */
  font-weight: 700;
}

.course-price {
  display: flex;
  align-items: baseline;
  gap: 4px;
  margin-bottom: 18px;
}
.course-price .amount {
  font-family: 'Cormorant Garamond', serif;
  font-size: 2.1rem;
  font-weight: 700;
  color: var(--primary);
}
.course-price .period {
  font-size: 0.88rem;
  color: var(--text-muted);
}


/* ==========================================================================
   12. TEACHERS SECTION
   ========================================================================== */
#teachers {
  background: var(--washi);
  padding: var(--section-pad);
  overflow: hidden;
  position: relative;
}

#teachers::before {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-image: url('../images/backgrounds/lantern.webp');
  background-size: contain;
  background-repeat: no-repeat;
  opacity: 0.150;
  pointer-events: none;
  z-index: 0;
  -webkit-mask-image: linear-gradient(to right, black 0%, transparent 80%);
  mask-image: linear-gradient(to right, black 0%, transparent 80%);
}

#teachers .container { position: relative; z-index: 1; }

#teachers .row > [class*="col"] {
  display: flex;
}

.teacher-card, .admin-card {
  background: var(--white);
  border-radius: var(--radius);
  overflow: hidden;
  border: 1px solid rgba(26,42,94,0.08);
  transition: var(--transition);
  text-align: center;
  height: 100%;
  display: flex;
  flex-direction: column;
}
.teacher-card:hover, .admin-card:hover {
  transform: translateY(-6px);
  box-shadow: 0 12px 40px rgba(26,42,94,0.12);
}

.teacher-img-wrap, .admin-img-wrap {
  position: relative;
  height: 220px;
  overflow: hidden;
}
.teacher-img-wrap img, .admin-img-wrap img {
  width: 180px;
  height: 180px;
  border-radius: 50%;
  background: var(--white);
  transition: transform 0.6s ease;
}
.teacher-card:hover .teacher-img-wrap img { transform: scale(1.07); }
.admin-card:hover .admin-img-wrap img { transform: scale(1.07); }

.teacher-body, .admin-body { 
  flex: 1;
  display: flex;
  flex-direction: column;
  padding: 24px 20px;
 }
.teacher-name, .admin-name {
  font-family: 'Cormorant Garamond', serif;
  font-size: 1.45rem;
  font-weight: 700;
  color: var(--primary);
  margin-bottom: 4px;
}
.teacher-title, .admin-title {
  font-size: 0.84rem;
  color: var(--secondary);
  font-weight: 600;
  letter-spacing: 0.07em;
  text-transform: uppercase;
  margin-bottom: 12px;
}
.teacher-bio, .admin-bio {
  font-size: var(--fs-body);
  color: var(--text-muted);
  line-height: var(--lh-body);
  margin-bottom: 18px;
  text-align: center;
}
.teacher-cert {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  background: var(--light-gray);
  border-radius: 50px;
  padding: 6px 16px;
  font-size: 0.82rem;
  font-weight: 600;
  color: var(--primary);
  margin: 0 auto;
}


/* ==========================================================================
   13. TESTIMONIALS SECTION
   ========================================================================== */
#testimonials {
  background: var(--primary-dark);
  padding: var(--section-pad);
  position: relative;
  overflow: hidden;
}
#testimonials::after {
  content: '声';
  position: absolute;
  font-family: 'Noto Serif JP', serif;
  font-size: 320px;
  font-weight: 700;
  color: rgba(255,255,255,0.02);
  right: -30px;
  bottom: -60px;
  line-height: 1;
  pointer-events: none;
}

.testimonial-card {
  background: rgba(255,255,255,0.05);
  border: 1px solid rgba(255,255,255,0.08);
  border-radius: var(--radius);
  padding: 32px 28px;
  backdrop-filter: blur(8px);
  height: 100%;
  transition: var(--transition);
}
.testimonial-card:hover {
  background: rgba(255,255,255,0.09);
  transform: translateY(-4px);
}

.testimonial-quote-icon {
  font-size: 3.2rem;
  color: var(--washi);
  opacity: 0.7;
  line-height: 1;
  margin-bottom: 16px;
  font-family: Georgia, serif;
}

.testimonial-text {
  font-size: var(--fs-body);
  color: rgba(255,255,255,0.85);
  line-height: var(--lh-body);
  font-style: italic;
  margin-bottom: 24px;
}

.testimonial-author {
  display: flex;
  align-items: center;
  gap: 14px;
}
.testimonial-avatar {
  width: 52px;
  height: 52px;
  border-radius: 50%;
  object-fit: cover;
  border: 3px solid var(--cherry);
  flex-shrink: 0;
}
.testimonial-stars { color: var(--gold); font-size: 0.92rem; margin-bottom: 4px; }
.testimonial-name  { font-weight: 700; color: var(--white); font-size: 1rem; }
.testimonial-meta  { font-size: 0.82rem; color: rgba(255,255,255,0.6); }


/* ==========================================================================
   14. EXAMS TICKER
   ========================================================================== */
#exams {
  background: var(--white);
  padding: 80px 0;
}

.exam-track {
  overflow: hidden;
  position: relative;
}
.exam-track::before,
.exam-track::after {
  content: '';
  position: absolute;
  top: 0;
  bottom: 0;
  width: 100px;
  z-index: 2;
}
.exam-track::before { left: 0;  background: linear-gradient(to right, var(--white), transparent); }
.exam-track::after  { right: 0; background: linear-gradient(to left,  var(--white), transparent); }

.exam-cards {
  display: flex;
  gap: 24px;
  animation: scroll-loop 28s linear infinite;
  width: max-content;
}
.exam-cards:hover { animation-play-state: paused; }

.exam-item {
  padding: 20px 40px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 8px;
  max-width: 400px;
  transition: var(--transition);
}
.exam-item:hover        { transform: scale(1.03); }
.exam-item .exam-logo   { font-size: 2rem; }
.exam-item .exam-name   { font-size: 0.8rem; font-weight: 700; color: var(--primary); text-align: center; letter-spacing: 0.03em; }
.exam-item .exam-level  { font-size: 0.7rem; color: var(--text-muted); }


/* ==========================================================================
   15. SUCCESS STORIES SECTION
   ========================================================================== */
#success {
  background: var(--off-white);
  padding: var(--section-pad);
  position: relative;
  overflow: hidden;
}

.success-card {
  background: var(--white);
  border-radius: var(--radius);
  overflow: hidden;
  border: 1px solid rgba(26,42,94,0.10);
  transition: var(--transition);
}
.success-card:hover {
  transform: translateY(-6px);
  box-shadow: 0 12px 40px rgba(26,42,94,0.12);
}

.success-header {
  position: relative;
  padding: 24px 28px;
  overflow: hidden;
  z-index: 1;
}

.success-header > img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
  z-index: -2;
  transition: transform 0.5s ease;
}

.success-header::after {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(to top, rgba(10,30,80,0.85) 0%, rgba(10,30,80,0.35) 100%);
  z-index: -1;
}
.success-avatar { max-width: 100px; }

.success-jlpt-badge {
  position: absolute;
  top: 20px;
  right: 20px;
  background: var(--cherry);   /* red badge */
  color: var(--white);
  border-radius: var(--radius);
  padding: 8px 14px;
  font-family: 'Cormorant Garamond', serif;
  font-size: 1.6rem;
  font-weight: 700;
  text-align: center;
  line-height: 1;
}
.success-jlpt-badge span {
  display: block;
  font-family: 'DM Sans', sans-serif;
  font-size: 0.6rem;
  font-weight: 600;
  letter-spacing: 0.08em;
}
.success-name { font-family: 'Cormorant Garamond', serif; font-size: 1.5rem; font-weight: 700; color: var(--white); }
.success-from { font-size: 0.88rem; color: rgba(255,255,255,0.72); }

.success-body { padding: 24px 28px; }
.success-text {
  font-size: var(--fs-body);
  color: var(--text-muted);
  line-height: var(--lh-body);
  margin-bottom: 16px;
  font-style: italic;
}
.success-details { display: flex; flex-direction: column; gap: 8px; }
.success-detail {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: var(--fs-secondary);
  color: var(--text-dark);
}
.success-detail i { color: var(--secondary); font-size: 0.9rem; width: 16px; }


/* ==========================================================================
   16. ACTIVITY / GALLERY GRID
   ========================================================================== */
.activity-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 16px;
}
.ac-wide { grid-column: span 2; }

.activity-card {
  border-radius: var(--radius);
  padding: 0;
  display: flex;
  flex-direction: column;
  transition: transform 0.28s ease;
  overflow: hidden;
  position: relative;
  min-height: 220px;
  cursor: default;
  background: #0a1e50;
}
.activity-card:hover { transform: translateY(-5px); }

.activity-card::before {
  content: '';
  position: absolute;
  inset: 0;
  background-size: cover;
  background-position: center;
  transition: transform 0.5s ease;
  z-index: 0;
}
.activity-card:hover::before { transform: scale(1.07); }

.activity-card::after {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(to top, rgba(10,30,80,0.88) 0%, rgba(10,30,80,0.45) 60%, rgba(10,30,80,0.2) 100%);
  z-index: 1;
  transition: background 0.3s ease;
}
.activity-card:hover::after {
  background: linear-gradient(to top, rgba(10,30,80,0.94) 0%, rgba(10,30,80,0.6) 60%, rgba(10,30,80,0.3) 100%);
}

.activity-card-inner {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  padding: 24px 22px;
  z-index: 2;
}

.ac-icon  { font-size: 1.6rem; line-height: 1; margin-bottom: 8px; }
.ac-tag   {
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--gold);
  margin-bottom: 5px;
}
.ac-title {
  font-family: 'Playfair Display', 'Cormorant Garamond', serif;
  font-size: 1.15rem;
  font-weight: 700;
  line-height: 1.25;
  margin: 0 0 6px;
  color: var(--white);
}
.ac-wide .ac-title { font-size: 1.45rem; }
.ac-desc  {
  font-size: var(--fs-secondary);
  line-height: var(--lh-body);
  margin: 0;
  color: rgba(255,255,255,0.85);
}

.ac-bg-1 { background-image: url('../images/gallery/gallery-1.jpg'); }
.ac-bg-2 { background-image: url('../images/gallery/gallery-2.jpg'); }
.ac-bg-3 { background-image: url('../images/gallery/gallery-3.jpg'); }
.ac-bg-4 { background-image: url('../images/gallery/gallery-4.jpg'); }
.ac-bg-5 { background-image: url('../images/gallery/gallery-5.jpg'); }
.ac-bg-6 { background-image: url('../images/gallery/gallery-6.jpg?v=3'); }
.ac-bg-7 { background-image: url('../images/gallery/gallery-7.jpg'); }

.ac-dark, .ac-darkest, .ac-mid, .ac-cherry, .ac-light {
  color: var(--white);
}


/* ==========================================================================
   17. PACKAGE CARDS
   ========================================================================== */
.pkg-card {
  background: var(--white);
  border-radius: var(--radius);
  border: 1px solid rgba(26,42,94,0.08);
  overflow: hidden;
  height: 100%;
  display: flex;
  flex-direction: column;
  position: relative;
  transition: var(--transition);
}
.pkg-card:hover {
  transform: translateY(-6px);
  box-shadow: 0 12px 40px rgba(26,42,94,0.12);
}

.pkg-popular-badge {
  position: absolute;
  top: 18px;
  right: 18px;
  background: var(--white);
  color: var(--cherry);
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  padding: 5px 14px;
  border-radius: 50px;
  z-index: 2;
}

/* Header colour variants */
.pkg-header { padding: 26px 26px 22px; }
.pkg-regular  { background: var(--light-gray); }
.pkg-standard { background: linear-gradient(135deg, var(--primary), var(--primary-light)); }
.pkg-premium  { background: linear-gradient(135deg, var(--cherry), var(--cherry-light)); }

.pkg-label {
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  margin-bottom: 6px;
}
.pkg-regular .pkg-label           { color: var(--secondary); }
.pkg-standard .pkg-label,
.pkg-premium  .pkg-label          { color: var(--white); } 

.pkg-name {
  font-family: 'Cormorant Garamond', serif;
  font-size: 1.65rem;
  font-weight: 700;
  line-height: 1.15;
  margin-bottom: 6px;
}
.pkg-regular .pkg-name            { color: var(--primary); }
.pkg-standard .pkg-name,
.pkg-premium  .pkg-name           { color: var(--white); }

.pkg-tagline { font-size: 0.88rem; }
.pkg-regular .pkg-tagline         { color: var(--text-muted); }
.pkg-standard .pkg-tagline,
.pkg-premium  .pkg-tagline        { color: rgba(255,255,255,0.7); }

.pkg-body {
  padding: 22px 26px 26px;
  flex: 1;
  display: flex;
  flex-direction: column;
}

.pkg-steps  { display: flex; flex-direction: column; gap: 0; margin-bottom: 20px; }
.pkg-step   { display: flex; gap: 14px; padding: 14px 0; border-bottom: 1px solid var(--light-gray); }
.pkg-step:last-child { border-bottom: none; }

.pkg-step-num {
  width: 20px;
  height: 20px;
  background: var(--primary);
  color: var(--white);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.68rem;
  font-weight: 700;
  flex-shrink: 0;
  margin-top: 2px;
}
.pkg-step-title  { font-size: var(--fs-body); font-weight: 600; color: var(--primary); margin-bottom: 4px; }
.pkg-step-amount { font-family: 'Cormorant Garamond', serif; font-size: 1.35rem; font-weight: 700; color: var(--primary-dark); margin-bottom: 4px; }
.pkg-step-note   { font-size: var(--fs-secondary); color: var(--text-muted); line-height: var(--lh-body); }

.pkg-total {
  display: flex;
  align-items: center;
  justify-content: space-between;
  background: var(--light-gray);
  border-radius: 10px;
  padding: 12px 16px;
  margin-top: 4px;
  font-size: 0.88rem;
  font-weight: 600;
  color: var(--text-muted);
}
.pkg-total-amount {
  font-family: 'Cormorant Garamond', serif;
  font-size: 1.55rem;
  font-weight: 700;
  color: var(--primary);
}

.pkg-arrival       { margin: 16px 0; }
.pkg-arrival-title {
  font-size: 0.8rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--secondary);
  margin-bottom: 10px;
}
.pkg-arrival-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 6px 12px;
}
.pkg-arrival-item {
  display: flex;
  align-items: center;
  gap: 7px;
  font-size: var(--fs-secondary);
  color: var(--text-muted);
}
.pkg-arrival-item i { color: var(--secondary); font-size: 0.8rem; flex-shrink: 0; }

.pkg-note-box {
  display: flex;
  align-items: flex-start;
  gap: 8px;
  background: var(--light-gray);
  border-radius: var(--radius);
  padding: 12px 14px;
  font-size: var(--fs-secondary);
  color: var(--text-muted);
  line-height: var(--lh-body);
  margin-top: 16px;
}
.pkg-note-box i { color: var(--secondary); flex-shrink: 0; margin-top: 2px; }

/* note box — now red tones */
.pkg-note-cherry {
  background: rgba(192,57,43,0.08);
  border: 1px solid rgba(192,57,43,0.28);
}
.pkg-note-cherry i    { color: var(--cherry); }
.pkg-note-cherry span { color: var(--primary-dark); font-weight: 600; }

.pkg-extra-note {
  display: flex;
  align-items: center;
  gap: 10px;
  background: rgba(26,42,94,0.05);
  border: 1px solid rgba(26,42,94,0.1);
  border-radius: var(--radius);
  padding: 14px 20px;
  font-size: var(--fs-body);
  color: var(--text-muted);
  line-height: var(--lh-body);
}
.pkg-extra-note i { color: var(--secondary); flex-shrink: 0; }

/* ===== JOURNEY FLOW ===== */
.journey-flow {
  display: flex;
  align-items: flex-start;
  justify-content: center;
  gap: 0;
  flex-wrap: nowrap;
  overflow-x: auto;
  padding-bottom: 8px;
}

.jf-step {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
  min-width: 100px;
  max-width: 120px;
  flex: 1;
}

.jf-num {
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  color: var(--secondary);
  text-transform: uppercase;
}

.jf-circle, .jf-mobile-circle {
  width: 56px;
  height: 56px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.4rem;
  flex-shrink: 0;
  position: relative;
  z-index: 1;
  background-color: var(--primary);
  box-shadow: 0 6px 18px rgba(26,42,94,0.08);
  transition: all 0.3s ease;
}

.jf-circle i, .jf-mobile-circle i {
  color: var(--white);
}

.jf-name {
  font-family: 'Playfair Display', 'Cormorant Garamond', serif;
  font-size: 0.88rem;
  font-weight: 700;
  color: var(--primary);
  text-align: center;
  line-height: 1.3;
}

.jf-desc {
  font-size: 0.74rem;
  color: var(--text-muted);
  text-align: center;
  line-height: 1.55;
}

.jf-arrow {
  color: var(--cherry);   /* red arrow */
  font-size: 1.85rem;
  padding-top: 30px;
  flex-shrink: 0;
  margin: 0 -2px;
  align-self: flex-start;
}

/* Mobile vertical */
.jf-mobile-flow {
  display: flex;
  flex-direction: column;
  gap: 0;
  max-width: 400px;
  margin: 0 auto;
}

.jf-mobile-step {
  display: flex;
  gap: 20px;
  align-items: flex-start;
}

.jf-mobile-left {
  display: flex;
  flex-direction: column;
  align-items: center;
  flex-shrink: 0;
}

.jf-mobile-vline {
  width: 2px;
  flex: 1;
  min-height: 32px;
  background: var(--cherry);   /* red line */
  margin: 10px 0;
}

.jf-mobile-content {
  padding: 8px 0 24px;
  flex: 1;
}

.jf-mobile-num {
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  color: var(--secondary);
  text-transform: uppercase;
  margin-bottom: 3px;
}

.jf-mobile-name {
  font-family: 'Playfair Display', 'Cormorant Garamond', serif;
  font-size: 1rem;
  font-weight: 700;
  color: var(--primary);
  margin-bottom: 4px;
}

.jf-mobile-desc {
  font-size: 0.84rem;
  color: var(--text-muted);
  line-height: 1.65;
}


/* ==========================================================================
   18. FAQ SECTION
   ========================================================================== */
#faq {
  background: var(--washi);
  padding: var(--section-pad);
  position: relative;
}
#faq::before {
  content: '';
  position: absolute;
  inset: 0;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 200 200'%3E%3Ccircle cx='100' cy='100' r='8' fill='%23e8a0b4'/%3E%3Cellipse cx='100' cy='72' rx='12' ry='22' fill='%23f4b8cc' transform='rotate(0,100,100)'/%3E%3Cellipse cx='100' cy='72' rx='12' ry='22' fill='%23f4b8cc' transform='rotate(72,100,100)'/%3E%3Cellipse cx='100' cy='72' rx='12' ry='22' fill='%23f4b8cc' transform='rotate(144,100,100)'/%3E%3Cellipse cx='100' cy='72' rx='12' ry='22' fill='%23f4b8cc' transform='rotate(216,100,100)'/%3E%3Cellipse cx='100' cy='72' rx='12' ry='22' fill='%23f4b8cc' transform='rotate(288,100,100)'/%3E%3C/svg%3E");
  background-size: 320px;
  background-repeat: repeat;
  opacity: 0.125;
  pointer-events: none;
  z-index: 0;
}
#faq .container { position: relative; z-index: 1; }

.faq-item {
  background: var(--white);
  border-radius: var(--radius);
  border: 1px solid rgba(26,42,94,0.08);
  margin-bottom: 12px;
  overflow: hidden;
  transition: var(--transition);
}
.faq-item:hover       { box-shadow: var(--shadow); }
.faq-item.open        { border-color: rgba(26,42,94,0.15); box-shadow: var(--shadow); }

.faq-question {
  padding: 22px 24px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  font-weight: 600;
  color: var(--primary);
  font-size: var(--fs-body);
  transition: var(--transition);
}
.faq-question:hover { color: var(--primary-dark); }
.faq-question .faq-icon {
  width: 28px;
  height: 28px;
  background: var(--light-gray);
  border-radius: 2px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.75rem;
  flex-shrink: 0;
  transition: var(--transition);
  color: var(--primary);
}
.faq-item.open .faq-question .faq-icon {
  background: var(--primary);
  color: var(--white);
  transform: rotate(45deg);
}

.faq-answer {
  display: none;
  padding: 16px 24px 22px;
  font-size: var(--fs-secondary);
  color: var(--text-muted);
  line-height: var(--lh-body);
  border-top: 1px solid var(--light-gray);
}
.faq-item.open .faq-answer { display: block; }


/* ==========================================================================
   19. BRANCHES SECTION
   ========================================================================== */
#branches {
  background: var(--white);
  padding: var(--section-pad);
  position: relative;
}
#branches::before {
  content: '';
  position: absolute;
  inset: 0;
  background-image:
    repeating-linear-gradient(
      0deg,
      transparent, transparent 39px,
      rgba(26,42,94,0.025) 39px, rgba(26,42,94,0.025) 40px
    );
  pointer-events: none;
  z-index: 0;
}
#branches .container { position: relative; z-index: 1; }

.branch-card {
  background: var(--white);
  border: 1px solid rgba(26,42,94,0.08);
  border-radius: var(--radius);
  overflow: hidden;
  transition: var(--transition);
  height: 100%;
}
.branch-card:hover {
  box-shadow: var(--shadow-hover);
  transform: translateY(-4px);
}

.branch-banner {
  position: relative;
  height: 140px;
  overflow: hidden;
  background: var(--primary);
}
.branch-banner img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
  display: block;
  transition: transform 0.5s ease;
}
.branch-card:hover .branch-banner img { transform: scale(1.06); }

.branch-banner-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(to top, rgba(10,30,80,0.85) 0%, rgba(10,30,80,0.35) 100%);
}

.branch-banner-content {
  position: absolute;
  bottom: 16px;
  left: 20px;
}
.branch-flag    { font-size: 1.8rem; line-height: 1; margin-bottom: 4px; }
.branch-country {
  font-size: 0.8rem;
  font-weight: 700;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--washi);
  margin-bottom: 2px;
}
.branch-city {
  font-family: 'Playfair Display', 'Cormorant Garamond', serif;
  font-size: 1.3rem;
  font-weight: 700;
  color: var(--white);
  line-height: 1.2;
}

.branch-body { padding: 20px 22px 24px; }
.branch-info { list-style: none; padding: 0; margin: 0; }
.branch-info li {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  font-size: var(--fs-body);
  color: var(--text-muted);
  padding: 7px 0;
  border-bottom: 1px solid rgba(26,42,94,0.05);
  line-height: var(--lh-body);
}
.branch-info li:last-child { border-bottom: none; }
.branch-info i   { color: var(--secondary); font-size: 0.88rem; margin-top: 3px; flex-shrink: 0; }
.branch-info a   { color: var(--text-muted); text-decoration: underline; }


/* ==========================================================================
   20. CONTACT SECTION
   ========================================================================== */
#contact {
  background: linear-gradient(135deg, var(--primary-dark) 0%, var(--primary) 100%);
  padding: var(--section-pad);
  position: relative;
  overflow: hidden;
}

.map-wrap {
  background: var(--white);
  border-radius: var(--radius);
  padding: 15px;
  box-shadow: 0 32px 80px rgba(0,0,0,0.2);
}

.contact-info-block { padding-left: 20px; }

.contact-info-item {
  display: flex;
  align-items: flex-start;
  gap: 18px;
  padding: 24px 0;
  border-bottom: 1px solid rgba(255,255,255,0.12);
}
.contact-info-item:last-child { border-bottom: none; }

.contact-info-icon {
  width: 52px;
  height: 52px;
  background: rgba(255,255,255,0.12);
  border: 1px solid rgba(255,255,255,0.2);
  border-radius: var(--radius);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.3rem;
  color: var(--white);
  flex-shrink: 0;
}
.contact-info-label {
  font-size: 0.78rem;
  font-weight: 600;
  letter-spacing: 0.11em;
  text-transform: uppercase;
  color: rgba(255,255,255,0.55);
  margin-bottom: 5px;
}
.contact-info-value       { color: var(--white); font-size: var(--fs-body); font-weight: 500; }
.contact-info-value a     { color: var(--white); text-decoration: underline; }

.form-label-custom {
  font-size: var(--fs-small);
  font-weight: 600;
  letter-spacing: 0.07em;
  margin-bottom: 9px;
}
.form-input {
  font-size: var(--fs-body);
  padding: 15px 18px;
}


/* ==========================================================================
   21. FOOTER
   ========================================================================== */
footer {
  background: var(--primary-dark);
  padding: 60px 0 0;
  position: relative;
  overflow: hidden;
}

.footer-brand-name {
  font-family: 'Cormorant Garamond', serif;
  font-size: 1.45rem;
  font-weight: 700;
  color: var(--white);
  text-transform: uppercase;
}
.footer-desc {
  font-size: var(--fs-body);
  color: rgba(255,255,255,0.45);
  line-height: var(--lh-body);
  margin-bottom: 24px;
}

.footer-social {
  display: flex;
  gap: 10px;
  margin-bottom: 32px;
}
.social-btn {
  width: 40px;
  height: 40px;
  background: rgba(255,255,255,0.08);
  border: 1px solid rgba(255,255,255,0.12);
  border-radius: var(--radius);
  display: flex;
  align-items: center;
  justify-content: center;
  color: rgba(255,255,255,0.65);
  font-size: 1rem;
  transition: var(--transition);
}
.social-btn:hover {
  background: var(--cherry);      /* red hover */
  border-color: var(--cherry);
  color: var(--white);
  transform: translateY(-3px);
}

.footer-heading {
  font-size: 0.8rem;
  font-weight: 700;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--washi);           /* red heading */
  margin-bottom: 22px;
}
.footer-links { list-style: none; padding: 0; margin: 0; }
.footer-links li { margin-bottom: 10px; }
.footer-links a {
  font-size: var(--fs-body);
  color: rgba(255,255,255,0.55);
  display: flex;
  align-items: center;
  gap: 6px;
  transition: var(--transition);
}
.footer-links a::before { content: '→'; font-size: 0.7rem; transition: var(--transition); }
.footer-links a:hover   { color: var(--white); padding-left: 4px; }

.footer-bottom {
  border-top: 1px solid rgba(255,255,255,0.08);
  padding: 22px 0;
  margin-top: 48px;
  text-align: center;
}
.footer-copy     { font-size: 0.84rem; color: rgba(255,255,255,0.4); }
.footer-copy a   { color: rgba(255,255,255,0.4); text-decoration: underline; }
.footer-jp       { font-size: 0.8rem; }


/* ===== CHAT FLOAT ===== */
.chat-float-wrap {
  position: fixed;
  bottom: 28px;
  right: 28px;
  z-index: 9999;
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 10px;
}

/* Main toggle button */
.chat-toggle {
  width: 56px;
  height: 56px;
  border-radius: 50%;
  background: var(--cherry);
  border: none;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  transition: transform 0.25s ease, background 0.25s ease;
  position: relative;
  z-index: 2;
  flex-shrink: 0;
}
.chat-toggle:hover {
  transform: scale(1.08);
}
.chat-toggle.open {
  transform: rotate(0deg);
}

/* Chat option buttons */
.chat-option {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 18px 10px 14px;
  border-radius: 50px;
  color: #fff;
  font-size: 0.85rem;
  font-weight: 600;
  text-decoration: none;
  letter-spacing: 0.03em;
  box-shadow: 0 4px 18px rgba(0,0,0,0.2);
  white-space: nowrap;
  transform: translateY(16px) scale(0.9);
  opacity: 0;
  pointer-events: none;
  transition: transform 0.3s cubic-bezier(0.34,1.56,0.64,1),
              opacity 0.25s ease,
              box-shadow 0.2s ease;
}
.chat-option:hover {
  box-shadow: 0 8px 28px rgba(0,0,0,0.3);
  transform: translateY(0) scale(1.04) !important;
  color: #fff;
}

.chat-wa  { background: #25D366; }
.chat-fb  { background: linear-gradient(120deg, #168AFF, #9F33FF, #FF6070); }

/* Visible state — set by JS */
.chat-float-wrap.open .chat-option {
  opacity: 1;
  pointer-events: auto;
  transform: translateY(0) scale(1);
}
.chat-float-wrap.open .chat-wa { transition-delay: 0.08s; }
.chat-float-wrap.open .chat-fb { transition-delay: 0.0s;  }

/* Tooltip */
.chat-tooltip {
  position: absolute;
  bottom: 64px;
  right: 0;
  background: var(--primary-dark);
  color: #fff;
  font-size: 0.78rem;
  font-weight: 600;
  padding: 7px 14px;
  border-radius: 8px;
  white-space: nowrap;
  opacity: 0;
  transition: opacity 0.25s ease;
  pointer-events: none;
}
.chat-tooltip::after {
  content: '';
  position: absolute;
  bottom: -5px;
  right: 18px;
  width: 10px;
  height: 10px;
  background: var(--primary-dark);
  transform: rotate(45deg);
  border-radius: 2px;
}
/* .chat-tooltip.hidden { opacity: 0; } */
.chat-toggle:hover ~ .chat-tooltip { opacity: 1; }
.chat-tooltip.hidden { display: none; }

/* ==========================================================================
   23. LANGUAGE UTILITIES
   ========================================================================== */
[lang="ja"] h1,
[lang="ja"] h2,
[lang="ja"] h3,
[lang="ja"] h4,
[lang="ja"] h5,
[lang="ja"] .section-title,
[lang="ja"] .section-eyebrow,
[lang="ja"] .hero-headline,
[lang="ja"] .brand-name,
[lang="ja"] .service-title,
[lang="ja"] .course-title-card,
[lang="ja"] .teacher-name,
[lang="ja"] .admin-name,
[lang="ja"] .branch-city,
[lang="ja"] .footer-brand-name,
.ja-text h1,
.ja-text h2,
.ja-text h3,
.ja-text h4,
.ja-text h5,
.ja-text .section-title,
.ja-text .service-title,
.ja-text .course-title-card,
.ja-text .teacher-name,
.ja-text .admin-name,
.ja-text .branch-city {
  font-family: 'Noto Serif JP', serif;
}

[lang="ja"] body,
[lang="ja"] p,
[lang="ja"] li,
[lang="ja"] .section-subtitle,
[lang="ja"] .service-desc,
[lang="ja"] .service-list li,
[lang="ja"] .course-desc-text,
[lang="ja"] .course-features li,
[lang="ja"] .teacher-bio,
[lang="ja"] .admin-bio,
[lang="ja"] .testimonial-text,
[lang="ja"] .success-text,
[lang="ja"] .success-detail,
[lang="ja"] .faq-question,
[lang="ja"] .faq-answer,
[lang="ja"] .branch-info li,
[lang="ja"] .pkg-step-note,
[lang="ja"] .pkg-note-box,
[lang="ja"] .pkg-extra-note,
[lang="ja"] .footer-desc,
[lang="ja"] .footer-links a,
[lang="ja"] .ac-desc,
.ja-text p,
.ja-text li,
.ja-text .section-subtitle,
.ja-text .service-desc,
.ja-text .faq-question,
.ja-text .faq-answer {
  font-family: 'Noto Sans JP', sans-serif;
}

[lang="bn"] h1,
[lang="bn"] h2,
[lang="bn"] h3,
[lang="bn"] h4,
[lang="bn"] h5,
[lang="bn"] .section-title,
[lang="bn"] .section-eyebrow,
[lang="bn"] .hero-headline,
[lang="bn"] .brand-name,
[lang="bn"] .service-title,
[lang="bn"] .course-title-card,
[lang="bn"] .teacher-name,
[lang="bn"] .admin-name,
[lang="bn"] .branch-city,
[lang="bn"] .footer-brand-name,
.bn-text h1,
.bn-text h2,
.bn-text h3,
.bn-text h4,
.bn-text h5,
.bn-text .section-title,
.bn-text .service-title,
.bn-text .course-title-card,
.bn-text .teacher-name,
.bn-text .admin-name,
.bn-text .branch-city {
  font-family: 'Noto Serif Bengali', serif;
}

[lang="bn"] body,
[lang="bn"] p,
[lang="bn"] li,
[lang="bn"] .section-subtitle,
[lang="bn"] .service-desc,
[lang="bn"] .service-list li,
[lang="bn"] .course-desc-text,
[lang="bn"] .course-features li,
[lang="bn"] .teacher-bio,
[lang="bn"] .admin-bio,
[lang="bn"] .testimonial-text,
[lang="bn"] .success-text,
[lang="bn"] .success-detail,
[lang="bn"] .faq-question,
[lang="bn"] .faq-answer,
[lang="bn"] .branch-info li,
[lang="bn"] .pkg-step-note,
[lang="bn"] .pkg-note-box,
[lang="bn"] .pkg-extra-note,
[lang="bn"] .footer-desc,
[lang="bn"] .footer-links a,
[lang="bn"] .ac-desc,
.bn-text,
.bn-text p,
.bn-text li,
.bn-text .section-subtitle,
.bn-text .service-desc,
.bn-text .faq-question,
.bn-text .faq-answer {
  font-family: 'Noto Sans Bengali', sans-serif;
}

.lang-content        { display: none; }
.lang-content.active { display: block; }
.lang-inline         { display: none; }
.lang-inline.active  { display: inline; }


/* ==========================================================================
   24. RESPONSIVE — Tablet (≤ 991px)
   ========================================================================== */
@media (max-width: 991px) {
  :root { --section-pad: 70px 0; }

  .navbar-nav .nav-link          { padding: 10px 5px !important; }
  .navbar-nav .nav-link::after   { bottom: 5px; left: 5px; right: 5px; }
  .lang-switcher                 { margin: 20px; }
  .lang-btn                      { flex: 1; }

  .hero-visual  { display: none; }
  .hero-content { padding: 0px 25px; }

  .contact-info-block { margin-top: 40px; }
  .map-wrap           { padding: 36px 28px; }

  footer { padding: 50px 20px 0; }
}


/* ==========================================================================
   25. RESPONSIVE — Mobile (≤ 767px)
   ========================================================================== */
@media (max-width: 767px) {
  :root {
    --fs-body:      0.96rem;
    --fs-secondary: 0.92rem;
    --fs-small:     0.84rem;
    --fs-xsmall:    0.75rem;
  }

  .section-pad   { padding: 70px 0; }

  .section-title    { font-size: clamp(1.9rem, 8vw, 2.4rem); }
  .section-subtitle { font-size: var(--fs-body); }

  .hero-headline    { font-size: clamp(2.2rem, 10vw, 3.2rem); }
  .hero-stats       { gap: 24px; }
  .hero-stat-num    { font-size: 1.8rem; }

  .brand-name       { font-size: 1rem; }

  .course-meta      { gap: 12px; }

  #faq              { text-align: center !important; }

  .map-wrap         { padding: 28px 22px; }

  .pkg-header       { padding: 22px 20px 18px; }
  .pkg-body         { padding: 18px 20px 22px; }
  .pkg-name         { font-size: 1.45rem; }

  .service-card     { padding: 28px 22px; }

  .activity-grid    { grid-template-columns: 1fr; }
  .ac-wide          { grid-column: span 1; }
  .ac-title         { font-size: 1.15rem; }
  .ac-wide .ac-title{ font-size: 1.35rem; }

  .faq-question     { padding: 18px 20px; }
}


/* ==========================================================================
   26. RESPONSIVE — Mid Tablet (768–991px)
   ========================================================================== */
@media (min-width: 768px) and (max-width: 991px) {
  .activity-grid { grid-template-columns: repeat(2, 1fr); }
  .ac-wide       { grid-column: span 2; }
}

@media (min-width: 767px) {
  #faq .divider-line { margin-left: 0 !important; }
}

@media (max-width: 768px) {
  .hero-gradient {
    background: linear-gradient(100deg,
      rgba(10,30,80,0.95) 0%,
      rgba(10,30,80,0.9) 30%,
      rgba(10,30,80,0.8) 60%,
      rgba(10,30,80,0.7) 100%
    );
  }

  .hero-badge {
    font-size: 0.75rem;
  }
}


/* ==========================================================================
   27. RESPONSIVE — Desktop (≥ 992px)
   ========================================================================== */
@media (min-width: 992px) {
  .navbar-nav .nav-item + .nav-item .nav-link::before {
    content: '';
    position: absolute;
    left: 0;
    top: 30%;
    height: 40%;
    width: 1px;
    background: rgba(26,42,94,0.12);   /* navy separator (was white) */
  }
}