:root {
  /* Education palette: navy (trust), royal blue (knowledge), golden yellow (optimism).
     Logo green is kept for the brand name and tick marks. */
  --bg: #f8faff;
  --bg-alt: #edf2fc;
  --ink: #1b2540;
  --muted: #56607a;
  --brand: #1f3a7a;      /* navy */
  --brand-dark: #152a5c;
  --highlight: #2563c9;  /* royal blue */
  --gold: #f5b82e;       /* golden yellow */
  --gold-soft: #fff6dd;
  --logo-green: #3b5441;
  --leaf: #2cb978;
  --card: #ffffff;
  --line: #d9e2f3;
  /* Latin fonts first; Tamil/Telugu/Hindi letters fall back to the Noto font loaded on that page */
  --font-body: "Nunito Sans", "Mukta Malar", "Noto Sans Telugu", "Noto Sans Devanagari", system-ui, sans-serif;
  --font-head: "Fraunces", "Mukta Malar", "Noto Sans Telugu", "Noto Sans Devanagari", Georgia, serif;
  --radius: 18px;
  --shadow: 0 8px 30px rgba(25, 45, 100, .08);
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: 112px; }
html, body { overflow-x: clip; } /* 'clip' (not 'hidden') keeps the pinned header working */
body {
  margin: 0;
  font-family: var(--font-body);
  font-size: 18px;
  line-height: 1.6;
  color: var(--ink);
  background: var(--bg);
}
h1, h2, h3 { font-family: var(--font-head); line-height: 1.2; margin: 0 0 .5em; overflow-wrap: break-word; }
h1 { font-size: clamp(2.1rem, 5vw, 3.4rem); }
h1 em { color: var(--highlight); font-style: normal; }
h2 { font-size: clamp(1.7rem, 3.5vw, 2.4rem); text-align: center; margin-bottom: 1em; }
h3 { font-size: 1.25rem; }
a { color: var(--brand); }
img { max-width: 100%; display: block; }

.wrap { max-width: 1120px; margin: 0 auto; padding: 0 16px; }
.narrow { max-width: 760px; }
.center { text-align: center; }
.sub { color: var(--muted); margin-top: -1.5em; margin-bottom: 2em; }
.big { font-size: 1.2rem; margin-top: 2em; }
.small { font-size: .9rem; color: var(--muted); }

/* Buttons */
.btn {
  display: inline-block; text-align: center;
  background: var(--brand); color: #fff; text-decoration: none; font-weight: 700;
  padding: .85em 1.5em; border-radius: 999px; border: 2px solid var(--brand);
  font-size: 1rem; cursor: pointer; transition: background .2s, transform .2s;
}
.btn:hover { background: var(--brand-dark); border-color: var(--brand-dark); transform: translateY(-1px); }
.btn-ghost { background: transparent; color: var(--brand); }
.btn-ghost:hover { background: var(--brand); color: #fff; }
.btn-small { padding: .5em 1.1em; font-size: .9rem; }
.btn.full { width: 100%; }

/* Header */
.site-header {
  position: sticky; top: 0; z-index: 10;
  background: rgba(248, 250, 255, .95); backdrop-filter: blur(8px); -webkit-backdrop-filter: blur(8px);
  border-bottom: 1px solid var(--line);
}
.nav { display: flex; align-items: center; justify-content: space-between; height: 68px; }
.brand { display: flex; align-items: center; gap: 10px; text-decoration: none; }
.brand img { width: 40px; height: 40px; }
.brand-text { font-family: "Montserrat", sans-serif; font-weight: 600; font-size: 1.3rem; color: var(--logo-green); line-height: 1.1; display: flex; flex-direction: column; }
.brand-text small { font-weight: 400; font-size: .68rem; letter-spacing: .04em; color: var(--muted); }
.menu { display: flex; gap: 1.5rem; align-items: center; }
.menu a:not(.btn) { color: var(--ink); text-decoration: none; font-weight: 600; font-size: .95rem; }
.menu a:not(.btn):hover { color: var(--brand); }
.menu-toggle, .menu-icon { display: none; }
.menu a { white-space: nowrap; }
.menu a[aria-current="page"]:not(.btn) { color: var(--brand); text-decoration: underline; text-decoration-color: var(--gold); text-decoration-thickness: 2px; text-underline-offset: 6px; }
.mini-nav { display: flex; align-items: center; gap: 16px; }
.mini-nav a:not(.btn) { color: var(--ink); text-decoration: none; font-weight: 600; font-size: .95rem; white-space: nowrap; }
.mini-nav a:not(.btn):hover { color: var(--brand); }
.mini-nav .btn { white-space: nowrap; }
@media (min-width: 961px) and (max-width: 1150px) {
  .menu { gap: 1rem; }
  .menu a:not(.btn) { font-size: .88rem; }
  .brand-text { font-size: 1.15rem; }
}

/* Language switcher (top strip of the header) */
.lang-bar { border-bottom: 1px solid var(--line); font-size: .85rem; }
.lang-bar .wrap { display: flex; justify-content: flex-end; align-items: center; flex-wrap: wrap; gap: 4px 16px; padding-top: 6px; padding-bottom: 6px; }
.lang-bar a { color: var(--muted); text-decoration: none; font-weight: 600; font-family: var(--font-body); }
.lang-bar a:hover { color: var(--brand); }
.lang-bar a[aria-current="page"] { color: var(--brand); text-decoration: underline; text-decoration-color: var(--gold); text-decoration-thickness: 2px; text-underline-offset: 4px; }
.lang-globe { font-size: .9rem; }

/* Notice shown on the Hindi page */
.lang-notice { background: var(--gold-soft); border: 1px solid #f6dd9a; border-radius: 12px; padding: 10px 14px; font-size: .95rem; margin: 0 0 1.2em; max-width: 34em; }

/* Tamil, Telugu, Hindi: longer words and taller letters need a little more room */
:lang(ta), :lang(te), :lang(hi) { line-height: 1.75; }
:lang(ta) h1, :lang(te) h1 { font-size: clamp(1.7rem, 4.2vw, 2.7rem); line-height: 1.35; }
:lang(hi) h1 { font-size: clamp(1.9rem, 4.6vw, 3rem); line-height: 1.35; }
:lang(ta) h2, :lang(te) h2, :lang(hi) h2 { font-size: clamp(1.45rem, 3vw, 2.1rem); line-height: 1.35; }
:lang(ta) h3, :lang(te) h3, :lang(hi) h3 { font-size: 1.12rem; line-height: 1.4; }
:lang(ta) .eyebrow, :lang(te) .eyebrow, :lang(hi) .eyebrow { letter-spacing: 0; text-transform: none; font-size: .9rem; }
:lang(ta) .about-quote, :lang(te) .about-quote, :lang(hi) .about-quote { font-size: 1.05rem; line-height: 1.7; }
.hero-card [lang="en"] { line-height: 1.6; }

/* Hero */
.hero { padding: 72px 0 80px; background: radial-gradient(circle at 85% 20%, #dfe9fb 0, transparent 45%), radial-gradient(circle at 10% 90%, #fff3d1 0, transparent 35%); }
.hero-grid { display: grid; grid-template-columns: 1.15fr .85fr; gap: 48px; align-items: center; }
.eyebrow { text-transform: uppercase; letter-spacing: .12em; font-size: .8rem; font-weight: 700; color: var(--highlight); margin: 0 0 1em; }
.lead { font-size: 1.15rem; color: var(--muted); max-width: 34em; }
.cta-row { display: flex; flex-wrap: wrap; gap: 12px; margin: 1.8em 0 1.4em; }
.trust { list-style: none; padding: 0; margin: 0; display: flex; flex-wrap: wrap; gap: 8px 20px; font-size: .9rem; color: var(--muted); }
.trust li::before { content: "✓ "; color: var(--leaf); font-weight: 700; }
.hero-card {
  background: var(--card); border-radius: 28px; padding: 32px 24px; box-shadow: var(--shadow);
  display: flex; flex-direction: column; gap: 14px;
}
.bubble { padding: 12px 16px; border-radius: 18px; max-width: 88%; font-size: .98rem; }
.b1 { background: var(--bg-alt); border-bottom-left-radius: 4px; }
.b2 { background: var(--brand); color: #fff; align-self: flex-end; border-bottom-right-radius: 4px; }
.b3 { background: var(--gold-soft); border: 1px solid #f6dd9a; border-bottom-left-radius: 4px; }
.b4 { background: var(--card); border: 1.5px solid var(--brand); color: var(--brand); align-self: flex-end; border-bottom-right-radius: 4px; }
.hero-note { font-size: .85rem; color: var(--muted); text-align: center; margin: 8px 0 0; }

/* Sections */
.section { padding: 80px 0; }
.alt { background: var(--bg-alt); }
.cards { display: grid; gap: 24px; }
.cards.three { grid-template-columns: repeat(3, 1fr); }
.cards.four { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.pricing-grid { display: flex; flex-wrap: wrap; justify-content: center; gap: 24px; }
.pricing-grid .card { flex: 0 1 calc((100% - 48px) / 3); }
.pricing .price-note { margin: -.6em 0 1em !important; font-size: .85rem; font-weight: 700; color: var(--highlight) !important; }
.tag-alt { background: var(--gold) !important; color: var(--ink) !important; }
.card { background: var(--card); border-radius: var(--radius); padding: 28px; box-shadow: var(--shadow); border: 1px solid var(--line); }
.card p { margin: 0; color: var(--muted); }

/* Steps */
.steps { list-style: none; padding: 0; margin: 0; display: grid; grid-template-columns: repeat(4, 1fr); gap: 24px; }
.steps li { position: relative; padding-top: 8px; }
.steps span {
  display: grid; place-items: center; width: 44px; height: 44px; border-radius: 50%;
  background: var(--gold); color: var(--ink); font-weight: 700; margin-bottom: 14px;
}
.steps p { color: var(--muted); margin: 0; font-size: .98rem; }

/* Pricing */
.pricing .card { display: flex; flex-direction: column; }
.pricing ul { padding-left: 1.1em; margin: 0 0 1.5em; flex: 1; color: var(--muted); font-size: .98rem; }
.pricing li { margin-bottom: .4em; }
.price { font-family: var(--font-head); font-size: 2rem; color: var(--ink) !important; margin: 0 0 .6em !important; }
.price small { font-family: var(--font-body); font-size: .9rem; color: var(--muted); }
.featured { border: 2px solid var(--brand); transform: scale(1.03); }
.tag { display: inline-block; align-self: flex-start; background: var(--brand); color: #fff !important; font-size: .75rem; font-weight: 700; padding: 3px 10px; border-radius: 999px; margin-bottom: 10px !important; }

/* About */
.about { display: grid; grid-template-columns: 280px 1fr; gap: 48px; align-items: center; }
.about h2 { text-align: left; }
.photo {
  width: 280px; height: 280px; border-radius: 50%; overflow: hidden;
  background: #fff; border: 6px solid var(--bg-alt); box-shadow: var(--shadow);
  display: grid; place-items: center; color: #fff; font-family: "Fraunces", serif; font-size: 6rem;
}
.photo img { width: 100%; height: 100%; object-fit: cover; }
.photo .photo-logo { width: 62%; height: auto; object-fit: contain; }

.about-quote { margin: 1.4em 0 0; padding: 18px 22px; border-radius: 14px; background: var(--brand); border-left: 6px solid var(--gold); color: #fff; font-family: var(--font-head); font-size: 1.15rem; line-height: 1.5; text-align: left; }

.creds { list-style: none; padding: 0; margin: 1.2em 0 0; display: grid; gap: 10px; text-align: left; }
.creds li { background: var(--bg-alt); border-left: 4px solid var(--gold); border-radius: 10px; padding: 10px 14px; font-size: .97rem; }

/* Legal pages (privacy, terms) */
.legal h1 { font-size: clamp(1.9rem, 4vw, 2.6rem); }
.legal h2 { text-align: left; font-size: 1.3rem; margin: 1.8em 0 .5em; }
.legal p, .legal li { color: var(--ink); }
.legal ul { padding-left: 1.2em; }
.legal li { margin-bottom: .45em; }
.legal-updated { color: var(--muted) !important; font-size: .9rem; margin-top: -.6em; }
.legal-note { margin-top: 2.5em; padding: 14px 18px; background: var(--bg-alt); border-left: 4px solid var(--gold); border-radius: 10px; font-size: .92rem; }
.legal-links a { font-weight: 600; }

/* Free English lessons */
.lesson-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 300px), 1fr)); gap: 20px; margin: 0 0 28px; }
.lesson-card { display: flex; flex-direction: column; text-decoration: none; color: var(--ink); transition: transform .15s, box-shadow .15s; }
.lesson-card:hover { transform: translateY(-3px); box-shadow: 0 12px 34px rgba(25, 45, 100, .14); }
.lesson-card h3 { font-size: 1.08rem; line-height: 1.35; color: var(--brand); }
.lesson-card p { flex: 1; margin-bottom: 14px !important; font-size: .95rem; }
.lesson-read { font-weight: 700; color: var(--highlight); font-size: .92rem; }
.byline { display: flex; align-items: center; gap: 10px; }
.byline img { width: 40px; height: 40px; border-radius: 50%; object-fit: cover; flex: none; border: 2px solid var(--gold); }
.crumbs { font-size: .85rem; color: var(--muted); margin-bottom: 1.2em; }
.crumbs a { color: var(--highlight); font-weight: 700; text-decoration: none; }
.crumbs a:hover { text-decoration: underline; }
.lesson h1 { font-size: clamp(1.7rem, 4vw, 2.4rem); line-height: 1.25; }
.lesson-intro { font-size: 1.12rem; }
.phrases { width: 100%; border-collapse: collapse; margin: .4em 0 1.4em; font-size: .98rem; background: var(--card); border-radius: 12px; overflow: hidden; box-shadow: var(--shadow); }
.phrases th { text-align: left; background: var(--brand); color: #fff; padding: 10px 14px; font-size: .88rem; }
.phrases td { padding: 10px 14px; border-top: 1px solid var(--line); vertical-align: top; overflow-wrap: break-word; }
.phrases td:first-child { font-weight: 600; color: var(--brand); width: 50%; }
.lesson .sample { margin: .6em 0 1.4em; padding: 18px 22px; background: var(--card); border-left: 5px solid var(--leaf); border-radius: 12px; box-shadow: var(--shadow); font-size: 1.02rem; line-height: 1.7; }
.note-ta { background: var(--gold-soft); border-radius: 10px; padding: 10px 14px; font-size: .95rem; }
.quiz li { margin-bottom: .4em; }
.answers { margin: 1em 0 1.4em; }
.lesson-cta { margin: 2.6em 0 2em; padding: 26px 24px; border-radius: 16px; background: var(--brand); color: #fff; }
.lesson-cta h2 { color: #fff; margin-top: 0 !important; }
.lesson-cta p { color: #e6ecfa !important; }
.lesson-cta .cta-row { display: flex; flex-wrap: wrap; gap: 12px; margin: 1em 0 0; }
.lesson-cta .btn { background: var(--gold); border-color: var(--gold); color: var(--ink); }
.lesson-cta .btn-ghost { background: transparent; color: #fff; border-color: #fff; }
/* phone: stack phrase tables so nothing is cramped */
@media (max-width: 560px) {
  .phrases thead { display: none; }
  .phrases tr { display: block; border-top: 1px solid var(--line); padding: 8px 0; }
  .phrases tr:first-child { border-top: 0; }
  .phrases td { display: block; width: auto !important; border-top: 0; padding: 3px 16px; }
}
/* Meanings language switch (Tamil / Telugu / Hindi) */
.ml > [lang="te"], .ml > [lang="hi"] { display: none; }
html[data-ml="te"] .ml > [lang="ta"], html[data-ml="hi"] .ml > [lang="ta"] { display: none; }
html[data-ml="te"] .ml > [lang="te"], html[data-ml="hi"] .ml > [lang="hi"] { display: inline; }
.ml-switch { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; margin: 0 0 1.6em; padding: 10px 14px; background: var(--card); border: 1px solid var(--line); border-radius: 14px; box-shadow: var(--shadow); font-size: .92rem; }
.ml-switch span { font-weight: 700; color: var(--muted); margin-right: 4px; }
.ml-switch button { font: inherit; font-weight: 700; cursor: pointer; border: 2px solid var(--line); background: var(--bg); color: var(--ink); border-radius: 999px; padding: 4px 16px; }
.ml-switch button[aria-pressed="true"] { background: var(--brand); border-color: var(--brand); color: #fff; }
/* switch on phones */
@media (max-width: 560px) {
  .ml-switch { gap: 6px; padding: 8px 10px; font-size: .86rem; }
  .ml-switch span { margin-right: 0; flex-basis: 100%; }
  .ml-switch button { padding: 3px 11px; }
}
.more-lessons ul { padding-left: 1.2em; }
.more-lessons li { margin-bottom: .5em; }

/* About photo: gold ring, decorative shapes, name card */
.about { align-items: start; }
.photo-wrap { position: relative; display: flex; flex-direction: column; align-items: center; gap: 22px; padding-top: 10px; }
@media (min-width: 961px) { .photo-wrap { position: sticky; top: 130px; } }
.photo-wrap .photo { position: relative; z-index: 1; border: 6px solid #fff; box-shadow: 0 0 0 4px var(--gold), 0 18px 40px rgba(25, 45, 100, .18); }
.photo-wrap::before { content: ""; position: absolute; z-index: 0; width: 230px; height: 230px; border-radius: 50%; background: #dfe9fb; top: -18px; left: -26px; }
.photo-wrap::after { content: ""; position: absolute; z-index: 0; width: 120px; height: 120px; right: -14px; top: 190px;
  background-image: radial-gradient(var(--gold) 2.2px, transparent 2.6px); background-size: 16px 16px; opacity: .85; }
.photo-card { position: relative; z-index: 2; background: var(--card); border-radius: 14px; padding: 12px 18px; box-shadow: var(--shadow); text-align: center; border-top: 4px solid var(--gold); max-width: 280px; }
.photo-card strong { display: block; font-family: var(--font-head); font-size: 1.15rem; color: var(--brand); }
.photo-card span { display: block; font-size: .85rem; color: var(--muted); line-height: 1.4; margin-top: 2px; }
.photo-card em { display: inline-block; margin-top: 8px; font-style: normal; font-size: .8rem; font-weight: 700; color: var(--ink); background: var(--gold-soft); border-radius: 999px; padding: 3px 12px; }
@media (max-width: 960px) {
  .photo-wrap::before { width: 170px; height: 170px; top: -10px; left: calc(50% - 130px); }
  .photo-wrap::after { width: 90px; height: 90px; top: 130px; right: calc(50% - 125px); }
}

/* FAQ */
details { background: var(--card); border: 1px solid var(--line); border-radius: 14px; padding: 18px 22px; margin-bottom: 12px; }
summary { cursor: pointer; font-weight: 700; list-style: none; position: relative; padding-right: 28px; }
summary::-webkit-details-marker { display: none; }
summary::after { content: "+"; position: absolute; right: 0; top: -2px; font-size: 1.4rem; color: var(--brand); }
details[open] summary::after { content: "–"; }
details p { margin: .8em 0 0; color: var(--muted); }

/* Form */
.form { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 18px; background: var(--card); padding: 32px; border-radius: var(--radius); box-shadow: var(--shadow); }
.form label { display: flex; flex-direction: column; gap: 6px; font-weight: 600; font-size: .95rem; min-width: 0; }
.form .full { grid-column: 1 / -1; }
.form input, .form select, .form textarea {
  font: inherit; font-weight: 400; padding: 12px 14px; border: 1px solid var(--line); border-radius: 10px; background: var(--bg);
  width: 100%; min-width: 0; max-width: 100%; box-sizing: border-box;
}
.form input:focus, .form select:focus, .form textarea:focus { outline: 2px solid var(--brand); border-color: transparent; }

/* Footer */
.site-footer { background: var(--bg-alt); color: var(--ink); padding: 40px 0; border-top: 1px solid var(--line); }
.foot-logo { margin: 0 auto 12px; height: auto; }
.site-footer a { color: var(--brand); font-weight: 600; }
.foot { text-align: center; }
.foot p { margin: .3em 0; }
.site-footer .small { color: var(--muted); }
.privacy-note { max-width: 46em; margin: .8em auto .3em !important; font-size: .8rem; line-height: 1.5; }

/* WhatsApp floating button */
.wa-float {
  position: fixed; right: 18px; bottom: 18px; z-index: 20;
  width: 58px; height: 58px; border-radius: 50%; background: #25d366; color: #fff;
  display: grid; place-items: center; box-shadow: 0 6px 20px rgba(0,0,0,.2);
}

/* ---------- Mobile ---------- */
@media (max-width: 960px) {
  .hero-grid, .about { grid-template-columns: 1fr; }
  .cards.three { grid-template-columns: 1fr; }
  .pricing-grid .card { flex-basis: calc((100% - 24px) / 2); }
  .steps { grid-template-columns: 1fr 1fr; }
  .featured { transform: none; }
  .about { text-align: center; }
  .about h2 { text-align: center; }
  .photo { margin: 0 auto; width: 200px; height: 200px; font-size: 4.5rem; }

  .menu-icon { display: block; width: 32px; height: 24px; position: relative; cursor: pointer; }
  .menu-icon span, .menu-icon span::before, .menu-icon span::after {
    position: absolute; left: 0; width: 100%; height: 3px; background: var(--ink); border-radius: 3px; content: "";
  }
  .menu-icon span { top: 10px; }
  .menu-icon span::before { top: -9px; }
  .menu-icon span::after { top: 9px; }
  .menu {
    display: none; position: absolute; top: 100%; left: 0; right: 0;
    flex-direction: column; gap: 0; background: var(--bg); border-bottom: 1px solid var(--line); padding: 8px 16px 16px;
  }
  .menu a:not(.btn) { padding: 12px 0; width: 100%; border-bottom: 1px solid var(--line); }
  .menu .btn { margin-top: 12px; }
  .menu-toggle:checked ~ .menu { display: flex; }
}
@media (max-width: 560px) {
  .cards.four { grid-template-columns: 1fr; }
  body { font-size: 17px; }
  .section { padding: 56px 0; }
  .hero { padding: 40px 0 56px; }
  .steps { grid-template-columns: 1fr; }
  .pricing-grid .card { flex-basis: 100%; }
  .form { grid-template-columns: minmax(0, 1fr); padding: 20px 16px; }
  .cta-row .btn { width: 100%; }
}

/* ---------- Google reviews ---------- */
.rating-badge { display: flex; width: fit-content; margin: 0 auto 28px; align-items: center; gap: 10px; flex-wrap: wrap; justify-content: center; padding: 10px 18px; border-radius: 999px; background: var(--card); border: 1px solid var(--line); box-shadow: var(--shadow); text-decoration: none; color: var(--ink); font-size: .95rem; }
.rating-badge strong { font-size: 1.3rem; color: var(--brand); }
.stars { color: var(--gold); letter-spacing: 2px; }
.review-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 320px), 1fr)); gap: 22px; margin-bottom: 26px; }
.review { margin: 0; display: flex; flex-direction: column; gap: 12px; }
.review blockquote { margin: 0; flex: 1; font-size: 1rem; line-height: 1.6; }
.review figcaption { font-weight: 700; color: var(--brand); }
.review figcaption span { font-weight: 400; color: var(--muted, #667); font-size: .9rem; }
.review-write { font-size: .95rem; }
