/*
 Theme Name: Atlas Learn
 Theme URI: https://atlaslearn.co.uk
 Author: Yasindu
 Description: Custom theme for Atlas Learn tutoring website.
 Version: 1.0
*/



/*==== BASE STYLES ====*/

* {
    box-sizing: border-box;
}

:root {
  --bg: radial-gradient(1200px 800px at 10% 10%, #eef2ff 0%, #e0e7ff 20%, #c7d2fe 40%, #a5b4fc 60%, #818cf8 80%, #6366f1 100%);
  --text: #0b1021;
  --muted: #444b6a;
  --brand: #4f46e5;
  --brand-dark: #3730a3;
  --shadow: 0 6px 16px rgba(0,0,0,.08);
}


body {
    margin: 0;
    font-family: system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, 'Open Sans', 'Helvetica Neue', sans-serif;
    color: #0b1021;
}

.section {
    max-width: 1100px;
    margin: 0 auto;
    padding: 4rem 1.5rem; 
    border-bottom: 1px solid #e5e7eb;
}

.section h1, 
.section h2 {
    margin-top: 0;
}

/*==== NAVBAR ====*/

.site-header {
  position: -webkit-sticky;
  position: sticky;
  top: 0;
  z-index: 9999;
  background-color: #fff;
  background-image: var(--bg);
  box-shadow: var(--shadow);
}

.navbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  max-width: 1100px;
  margin: 0 auto;
  padding: 12px 20px;
  gap: 16px;
}

.logo {
  font-weight: 800;
  font-size: 1.25rem;
  color: var(--text);
  text-decoration: none;
  letter-spacing: .2px;
}

/* Toggle (mobile) */
.nav-toggle {
  display: inline-flex;
  flex-direction: column;
  gap: 4px;
  padding: 10px;
  border: 0;
  background: none;
  cursor: pointer;
}

.nav-toggle:focus-visible {
  outline: 3px solid var(--brand);
  border-radius: 10px;
}

.nav-toggle .bar {
  width: 24px;
  height: 2px;
  background: var(--text);
  display: block;
  transition: transform .25s ease, opacity .2s ease;
}

/* Menu (mobile default) */
.nav-links {
  list-style: none;
  margin: 0;
  padding: 0;
  position: fixed;
  inset: 60px 0 0 0; /* below header */
  transform: translateY(-8px);
  opacity: 0;
  pointer-events: none;
  background: var(--bg);
  display: flex;
  flex-direction: column;
  gap: 10px;
  padding: 14px 20px 24px;
  transition: opacity .2s ease, transform .2s ease;
}

.nav-links a {
  display: block;
  padding: 12px 10px;
  border-radius: 12px;
  color: var(--text);
  text-decoration: none;
  font-weight: 600;
}

.nav-links a:hover {
  background: rgba(0,0,0,.04);
}

.book-btn {
  background: var(--brand);
  color: #fff !important;
  padding: 10px 16px;
  border-radius: 999px;
}

.book-btn:hover {
  background: var(--brand-dark);
}

/* Open state (used by your JS) */
.nav-links.open {
  opacity: 1;
  transform: translateY(0);
  pointer-events: auto;
}

.nav-toggle[aria-expanded="true"] .bar:nth-child(1) {
  transform: translateY(6px) rotate(45deg);
}
.nav-toggle[aria-expanded="true"] .bar:nth-child(2) {
  opacity: 0;
}
.nav-toggle[aria-expanded="true"] .bar:nth-child(3) {
  transform: translateY(-6px) rotate(-45deg);
}

/* Active link styling */
.nav-links a.active {
  color: var(--brand);
  text-decoration: underline;
  text-underline-offset: 6px;
}

/* Keep Book button readable when active */
.nav-links .book-btn.active {
  text-decoration: none;
  box-shadow: 0 0 0 3px rgba(0,123,255,.15);
}

/* Desktop ≥ 900px */
@media (min-width: 900px) {
  .nav-toggle {
    display: none;
  }
  .nav-links {
    position: static;
    inset: auto;
    transform: none;
    opacity: 1;
    pointer-events: auto;
    flex-direction: row;
    align-items: center;
    gap: 22px;
    padding: 0;
    background: transparent;
  }
  .nav-links a {
    padding: 8px 6px;
  }
}

/* Respect reduced motion */
@media (prefers-reduced-motion: reduce) {
  .nav-links,
  .nav-toggle .bar {
    transition: none;
  }
}

/*==== HERO SECTION ====*/
.hero {
    min-height: 80vh;
    display: grid;
    place-items: center;
    position: relative;
    overflow: hidden;
    padding: 2rem 1.5rem;
    background: var(#fff);
}

.grain {
  position: absolute;
  inset: 0;
  pointer-events: none;
  opacity: .04;
  background-image: url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" width="160" height="160" viewBox="0 0 160 160"><filter id="n"><feTurbulence type="fractalNoise" baseFrequency="0.8" numOctaves="2" stitchTiles="stitch"/></filter><rect width="100%" height="100%" filter="url(%23n)" opacity="0.8"/></svg>');
}

/* Inner layout (two columns) */
.shell {
  position: relative;
  width: min(1100px, 100%);
  display: grid;
  grid-template-columns: 1.2fr 1fr;
  align-items: center;
  gap: clamp(1.25rem, 4vw, 3rem);
}

.hero-text {
  position: relative;
  z-index: 1;
}

@media (max-width: 900px) {
  .shell {
    grid-template-columns: 1fr;
    text-align: center;
  }
  .hero-text {
    order: 2;
  }
  .logo-box {
    order: 1;
    justify-content: center;
  }
}

/* Badge, heading, sub */
.badge {
  display: inline-flex;
  align-items: center;
  gap: .5rem;
  padding: .375rem .625rem;
  border-radius: 999px;
  background: rgba(255,255,255,.7);
  backdrop-filter: blur(6px);
  border: 1px solid rgba(99,102,241,.25);
  font-size: .875rem;
  letter-spacing: .02em;
  color: var(--muted);
}
.badge b { color: var(--brand); }

.heading {
  font-size: clamp(2.2rem, 5vw, 4rem);
  line-height: 1.05;
  margin: .75rem 0 .5rem;
  font-weight: 800;
}

.sub {
  margin: 0 0 1.25rem;
  color: var(--muted);
  font-size: clamp(1.05rem, 1.6vw, 1.25rem);
}

/* Hide hero text until WordPress content is loaded */
.hero.hero-loading .heading,
.hero.hero-loading .sub {
  opacity: 0;
}
.hero:not(.hero-loading) .heading,
.hero:not(.hero-loading) .sub {
  opacity: 1;
  transition: opacity .3s ease;
}

/* Typing caret */
.typing {
  display: inline-block;
  position: relative;
  white-space: nowrap;
}
.typing::after {
  content: "";
  position: absolute;
  right: -2px; top: 0; bottom: 0;
  width: 2px;
  background: currentColor;
  animation: caret 1s steps(1) infinite;
}
@keyframes caret { 50% { opacity: 0; } }

.typing {
  white-space: nowrap;
  display: inline-block;
}

@media (max-width: 480px) {
  .typing {
    white-space: pre-line;
  }
}
/* CTAs & trust cards */
.hero-ctas {
  display: flex;
  flex-wrap: wrap;
  gap: .75rem;
  margin: 0 0 1rem;
}
@media (max-width: 900px) {
  .hero-ctas {
    justify-content: center;
  }
}

.cta {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: .4rem;
  padding: .9rem 1.1rem;
  border-radius: 14px;
  border: 0;
  font-weight: 700;
  text-decoration: none;
  font-size: .95rem;
  background: linear-gradient(90deg, var(--brand), #06b6d4);
  color: #fff;
  box-shadow: 0 10px 22px rgba(79,70,229,.25);
  transition: transform .2s ease, box-shadow .2s ease;
}
.cta:hover {
  transform: translateY(-2px);
  box-shadow: 0 16px 28px rgba(79,70,229,.3);
}
.cta.secondary {
  background: #fff;
  color: var(--text);
  box-shadow: none;
  border: 1px solid rgba(15,23,42,.08);
}

.trust {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: .5rem;
  opacity: .9;
  font-size: .85rem;
  color: var(--muted);
}
.trust .card {
  background: rgba(255,255,255,.7);
  border: 1px solid rgba(15,23,42,.08);
  border-radius: 20px;
  padding: .75rem;
}
@media (max-width: 900px) {
  .trust {
    grid-template-columns: 1fr 1fr 1fr;
  }
}

/* Logo ring */
.logo-box {
  display: flex;
  justify-content: center;
  align-items: center;
  z-index: 1;
}

.logo-ring {
  --ring-size: clamp(140px, 22vw, 260px);
  --ring-width: 6px;
  --ring-color: #ea738d;

  position: relative;
  width: var(--ring-size);
  aspect-ratio: 1 / 1;
  border-radius: 50%;
  display: grid;
  place-items: center;
  transform: scale(1.12);
  transform-origin: center;
  transition: transform 0.9s ease;
}

/* Shrink state after typing */
.logo-box.shrink .logo-ring {
  transform: scale(1);
}

/* Gradient ring using mask */
.logo-ring::before {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: 50%;
  background: conic-gradient(from 200deg,
    #ea738d 0%,
    #f4a3b8 40%,
    #ea738d 100%);
  -webkit-mask: radial-gradient(closest-side,
                    transparent calc(100% - var(--ring-width)),
                    #000 0);
          mask: radial-gradient(closest-side,
                    transparent calc(100% - var(--ring-width)),
                    #000 0);
  z-index: 2;
  pointer-events: none;
}

/* Inner glow */
.logo-ring::after {
  content: "";
  position: absolute;
  inset: var(--ring-width);
  border-radius: 50%;
  background: radial-gradient(closest-side,
              rgba(234,115,141,0.45) 98%,
              rgba(234,115,141,0.18) 75%,
              rgba(234,115,141,0.00) 55%);
  filter: blur(10px);
  z-index: 0;
}

/* Logo image */
.logo-ring > img {
  position: relative;
  z-index: 1;
  width: calc(100% - var(--ring-width) * 2);
  height: calc(100% - var(--ring-width) * 2);
  border-radius: 50%;
  object-fit: cover;
}

@media (prefers-reduced-motion: reduce) {
  .logo-ring {
    transition: none;
    transform: none;
  }
}

/* ===== Mobile tweaks: HERO ===== */
@media (max-width: 768px) {
  .hero {
    padding: 1.75rem 1.25rem 2.5rem;
  }

  .shell {
    grid-template-columns: 1fr;
    text-align: center;
    gap: 1.75rem;
  }

  .hero .badge {
    margin-inline: auto;
  }

  .hero-ctas {
    display: flex;
    flex-direction: column;
    align-items: stretch;
    gap: 0.75rem;
    margin-top: 1.25rem;
  }

  .hero-ctas .cta {
    width: 100%;
    justify-content: center;
  }

  .trust {
    grid-template-columns: 1fr;
  }

  .logo-box {
    display: flex;
    justify-content: center;
  }
}


/*==== STATS BAR ====*/
.stats {
  background: #f3f4f6;
  border-top: 1px solid #e5e7eb;
}

.stats-shell {
  width: min(1100px, 100%);
  margin: 0 auto;
  padding: 1.1rem clamp(1rem, 4vw, 2rem);
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: clamp(.5rem, 2vw, 1rem);
}

@media (max-width: 900px) {
  .stats-shell {
    grid-template-columns: 1fr 1fr;
  }
}

.metric {
  background: #f9fafb;
  border: 1px solid #e5e7eb;
  border-radius: 14px;
  padding: .9rem;
  text-align: center;
}

.metric .num {
  font-weight: 800;
  font-size: clamp(1.5rem, 4vw, 2.2rem);
  line-height: 1;
}

.metric .label {
  color: #6b7280;
  font-size: .95rem;
  margin-top: .25rem;
}

/*==== ABOUT PAGE ====*/

.about-section {
  width: 100%;
  display: flex;
  justify-content: center;
  padding: clamp(3rem, 8vw, 5.5rem) 0;
  background: #ffffff;
}

.about-container {
  width: min(1100px, 100%);
  padding: 0 1.5rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: clamp(2.5rem, 5vw, 4rem);
}

/* ===== Left Column: Text ===== */

.about-text {
  flex: 1.2;
  display: flex;
  flex-direction: column;
  gap: 1.2rem;
}

.about-text h2 {
  font-size: clamp(2.2rem, 3.8vw, 3rem);
  font-weight: 800;
  line-height: 1.15;
  margin: 0;
  color: #111827; /* slightly softer than pure black */
}

.about-text p {
  font-size: clamp(1rem, 1.25vw, 1.12rem);
  line-height: 1.7;
  margin: 0;
  color: #374151;
}

/* Button */
.booking-button {
  margin-top: .8rem;
}

.booking-button a {
  display: inline-block;
  padding: .7rem 1.4rem;
  border-radius: 999px;
  background: #000;
  color: #fff;
  font-weight: 700;
  text-decoration: none;
  font-size: 1rem;
  transition: background .2s ease;
}

.booking-button a:hover {
  background: #2c3e50;
}

/* ===== Right Column: Image ===== */

.about-image {
  flex: 1;
  display: flex;
  justify-content: center;
}

.about-image img {
  width: 100%;
  max-width: 460px;
}

/* ===== Responsive ===== */

@media (max-width: 900px) {
  .about-container {
    flex-direction: column-reverse;
    text-align: center;
  }

  .about-text {
    align-items: center;
  }

  .about-text p {
    text-align: left; /* keeps long text readable */
    max-width: 90%;
  }

  .about-image img {
    max-width: 85%;
  }
}

@media (max-width: 480px) {
  .about-image img {
    max-width: 95%;
  }
  .about-text p {
    font-size: .96rem;
    text-align: center;
  }
}



/*==== HOW IT WORKS ====*/
.hiw {
  --hiw-maxw: min(1100px, 100%);
  --hiw-gap: clamp(.75rem, 2.5vw, 1.25rem);
  --hiw-card-bg: #f9fafb;
  --hiw-card-bd: #e5e7eb;
  --hiw-muted: #6b7280;
  --hiw-brand: var(--brand, #4f46e5);
  --hiw-brand-2: var(--brand-2, #06b6d4);
}

/* Spacer controls the total scroll distance for the pinned effect */
.hiw-spacer {
  height: 250svh; /* JS will override this; this is a safe fallback */
}

/* The pinned inner area */
.hiw-pin {
  position: sticky;
  top: 0;
  height: 100svh;
  display: grid;
  align-content: center;
  justify-items: center;
  padding: clamp(1rem, 4vw, 2rem);
  background: #fff;
  z-index: 0;
}

/* Title */
.hiw-title {
  font-size: clamp(1.6rem, 3.6vw, 2.2rem);
  line-height: 1.1;
  margin: 0 0 clamp(1rem, 2.5vw, 1.5rem);
  font-weight: 800;
  margin-bottom: 5%;
}

/* Grid of cards */
.hiw-grid {
  list-style: none;
  margin: 0;
  padding: 0;
  width: var(--hiw-maxw);
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: var(--hiw-gap);
}

@media (max-width: 980px) {
  .hiw-grid { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 560px) {
  .hiw-grid { grid-template-columns: 1fr; }
}

/* Cards */
.hiw-card {
  background: var(--hiw-card-bg);
  border: 1px solid var(--hiw-card-bd);
  border-radius: 16px;
  padding: clamp(1rem, 2.5vw, 1.25rem);
  text-align: left;

  opacity: 0;
  transform: translateY(18px) scale(0.98);
  transition:
    opacity .5s ease,
    transform .55s cubic-bezier(.22,1,.36,1);
  will-change: transform, opacity;
}

.hiw-card.is-active {
  opacity: 1;
  transform: none;
}

/* Step number circle */
.hiw-num {
  display: inline-grid;
  place-items: center;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: linear-gradient(90deg, var(--hiw-brand), var(--hiw-brand-2));
  color: #fff;
  font-weight: 800;
  font-size: 1rem;
  margin-bottom: .5rem;
}

/* Titles and text inside cards */
.hiw-h3 {
  margin: 0 0 .25rem;
  font-weight: 750;
  font-size: clamp(1.05rem, 2.6vw, 1.2rem);
}

.hiw-p {
  margin: 0;
  color: var(--hiw-muted);
  font-size: .98rem;
}

/* Progress bar */
.hiw-progress {
  margin-top: clamp(1rem, 3vw, 1.5rem);
  width: var(--hiw-maxw);
  height: 6px;
  background: #eef2f7;
  border-radius: 999px;
  overflow: hidden;
}

.hiw-progress-bar {
  display: block;
  height: 100%;
  width: 0%;
  background: linear-gradient(90deg, var(--hiw-brand), var(--hiw-brand-2));
  border-radius: inherit;
  transition: width .25s linear;
}

/* Reduced motion: no pinning or sequencing */
@media (prefers-reduced-motion: reduce) {
  .hiw-pin {
    position: static;
    height: auto;
  }
  .hiw-spacer {
    height: auto;
  }
  .hiw-card {
    opacity: 1;
    transform: none;
    transition: none;
  }
  .hiw-progress {
    display: none;
  }
}

/*==== SUBJECTS ====*/
.subjects-section {
  display: flex;
  flex-direction: column;
  align-items: center;
  margin: 5% 0;
  width: 100%;
}

.subjects-section h3 {
  font-size: clamp(2rem, 4vw, 3rem);
  font-weight: bold;
  color: #111827;
  text-align: center;
}

.subjects-container {
  display: flex;
  flex-direction: row;
  width: min(1100px, 100%);
  margin: 3% auto;
  justify-content: space-between;
  gap: 2rem;
}

/* Left: subjects list */
.subjects-list {
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  width: 30%;
  align-items: center;
}

.subjects-list h4 {
  text-align: center;
  border-radius: 25px;
  font-size: 1.4rem;
  padding: 8px 16px;
  margin: 10px 0;
  font-weight: bold;
  color: white;
  box-shadow: 0 4px 8px rgba(0,0,0,0.15);
}

/* Individual colours per subject */
.subject-1 { background-color: #89abe3; } /* Maths */
.subject-2 { background-color: #ea738d; } /* English */
.subject-3 { background-color: #f39c12; } /* Physics */
.subject-4 { background-color: #2ecc71; } /* Chemistry */
.subject-5 { background-color: #8e44ad; } /* Biology */
.subject-6 { background-color: #e74c3c; } /* Computing */

/* Right: text box */
.subjects-text {
  width: 100%;
  padding: 2% 3%;
  box-sizing: border-box;
  background: #f9fafb;
  border-radius: 30px;
  box-shadow: 0 4px 8px rgba(0,0,0,.12);
}

.subjects-text p {
  font-size: 1.1rem;
  color: #2c3e50;
  text-align: center;
  margin-bottom: 1rem;
}

/* Subjects slide-in animation */

.subject {
  transform: translateX(-100%);
  opacity: 0;
  transition: transform 0.9s ease-out, opacity 0.7s ease-out;
}

.subject-active {
  transform: translateX(0);
  opacity: 1;
}

/* If user prefers reduced motion, don't animate */
@media (prefers-reduced-motion: reduce) {
  .subject {
    transform: none;
    opacity: 1;
    transition: none;
  }
}


/* Responsive */
@media (max-width: 900px) {
  .subjects-container {
    flex-direction: column;
    align-items: center;
  }
  .subjects-list {
    width: 100%;
    display: flex;
    flex-direction: column;
    align-items: center;    /* center the pills */
    gap: 0.75rem;
    }

    .subjects-list h4 {
    width: min(260px, 80%); /* keeps pills nicely sized */
    margin: 0.5rem auto;
    }

  .subjects-text {
    width: 100%;
    margin-top: 1.5rem;
    padding: 1.75rem 1.25rem;   /* more internal spacing */
    margin-inline: 1rem;        /* NEW: left/right breathing room */
  }
  .subjects-text p {
    font-size: 1rem;
    text-align: left;
  }
}

@media (max-width: 480px) {
  .subjects-text {
    border-radius: 20px;
  }
  .subjects-text p {
    font-size: 0.95rem;
    line-height: 1.45;
  }
}


/*==== FAQ Section ====*/

.faq-section {
  width: 100%;
  padding: clamp(3rem, 7vw, 5rem) 0;
  background: #ffffff;
}

.faq-inner {
  width: min(1100px, 100%);
  margin: 0 auto;
  padding: 0 1.5rem;
  display: flex;
  gap: clamp(2rem, 4vw, 3rem);
  align-items: flex-start;
}

/* Left side: title + button */
.faq-left {
  flex: 0.9;
}

.faq-left h2 {
  font-size: clamp(2rem, 3.2vw, 2.6rem);
  font-weight: 800;
  margin: 0 0 .75rem;
  color: #111827;
}

.faq-left p {
  margin: 0 0 1.25rem;
  color: #4b5563;
  font-size: 1rem;
  line-height: 1.6;
}

.faq-more-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: .65rem 1.3rem;
  border-radius: 999px;
  border: 1px solid #d1d5db;
  text-decoration: none;
  font-weight: 600;
  font-size: .95rem;
  color: #111827;
  background: #f9fafb;
}

.faq-more-btn:hover {
  background: #eef2ff;
  border-color: #c7d2fe;
}

/* Right side: mini accordion */
.faq-right {
  flex: 1.1;
}

/*==== FAQ PAGE ====*/

.faq-page {
  width: 100%;
  padding: clamp(3rem, 7vw, 5rem) 0;
  background: #ffffff;
}

.faq-page-inner {
  width: min(900px, 100%);
  margin: 0 auto;
  padding: 0 1.5rem;
}

.faq-page-header h1 {
  font-size: clamp(2.2rem, 3.5vw, 2.8rem);
  font-weight: 800;
  margin: 0 0 .75rem;
  color: #111827;
}

.faq-page-header p {
  margin: 0 0 1.5rem;
  color: #4b5563;
  line-height: 1.6;
}

/* =========================================
   FAQ Accordion (shared)
========================================= */

.faq-accordion {
  display: flex;
  flex-direction: column;
  gap: .75rem;
}

/* Each item */
.faq-item {
  border-radius: 14px;
  border: 1px solid #e5e7eb;
  background: #f9fafb;
  overflow: hidden;
}

/* Question button */
.faq-question {
  margin: 0;
}

.faq-question-btn {
  all: unset;
  width: 100%;
  box-sizing: border-box;
  padding: .8rem 1rem;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: .75rem;
}

.faq-question-text {
  font-weight: 600;
  color: #111827;
  font-size: .98rem;
}

.faq-icon {
  font-size: 1.1rem;
  line-height: 1;
  color: #6b7280;
}

/* Answer panel */
.faq-answer {
  max-height: 0;
  overflow: hidden;
  padding: 0 1rem;
  transition: max-height .25s ease, padding .25s ease;
}

.faq-answer p {
  margin: .75rem 0 1rem;
  font-size: .95rem;
  color: #4b5563;
  line-height: 1.6;
}

/* Open state */
.faq-item.is-open .faq-answer {
  padding: 0 1rem .9rem;
}

.faq-item.is-open .faq-question-btn {
  background: #eef2ff;
}

.faq-item.is-open .faq-icon {
  transform: rotate(45deg); /* plus turns into an x-ish */
}

/* Responsive */
@media (max-width: 900px) {
  .faq-inner {
    flex-direction: column;
  }

  .faq-left,
  .faq-right {
    width: 100%;
  }
}

/*==== CONTACT US SECTION ====*/

.contact-section {
  width: 100%;
  padding: clamp(3rem, 7vw, 5rem) 0;
  background: #ffffff;
}

.contact-inner {
  width: min(1100px, 100%);
  margin: 0 auto;
  padding: 0 1.5rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: clamp(2rem, 5vw, 4rem);
}

/* LEFT SIDE: logo + pills */

.contact-left {
  position: relative;
  flex: 0 0 auto;
  /* this keeps logo & pills as one “cluster” on the left */
}

.contact-logo-wrap {
  display: flex;
  justify-content: center;
}

.contact-logo-circle {
  width: clamp(140px, 22vw, 220px);
  aspect-ratio: 1 / 1;
  border-radius: 50%;
  border: 6px solid #e58ca4; /* pink ring */
  display: flex;
  align-items: center;
  justify-content: center;
  background: #fff;
  overflow: hidden;
}

.contact-logo-circle img {
  width: 100%;
  height: 100%;
  object-fit: contain;
}

/* Pill group, overlapping the bottom-right of the circle */

.contact-pill-group {
  position: absolute;
  left: 60%;    /* horizontal offset relative to logo */
  top: 70%;     /* vertical offset */
  transform: translateY(5%); /* slight downward nudge */
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

/* Pills themselves */

.contact-pill {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 1rem 1.8rem;
  min-width: 260px;
  border-radius: 999px;
  background: #89abe3;
  color: #021b4a;
  font-weight: 700;
  font-size: 1.05rem;
  text-decoration: none;
  box-shadow:
    0 12px 25px rgba(0,0,0,0.18),
    0 3px 6px rgba(0,0,0,0.12);
  overflow: hidden;
}

/* white inner stroke */
.contact-pill::before {
  content: "";
  position: absolute;
  inset: 8px;
  border-radius: 999px;
  border: 2px solid rgba(255,255,255,0.9);
  opacity: 0.9;
  pointer-events: none;
}

/* Base transform holder */
.contact-pill {
  --base-transform: rotate(0deg);
  transform: var(--base-transform);
  transition: transform .25s ease;
}

/* Each pill gets its own offset + rotation */
.contact-pill-email {
  --base-transform: rotate(8deg) translateY(-60%) translateX(20%);
}

.contact-pill-phone {
  --base-transform: rotate(-10deg) translateY(-60%) translateX(-50%);
}

/* Hover: add scale but keep original transform */
.contact-pill:hover {
  transform: var(--base-transform) scale(1.05);
}

.contact-pill-email { --pill-rotate: 8deg; }
.contact-pill-phone { --pill-rotate: -6deg; }

/* RIGHT SIDE: text */

.contact-details {
  flex: 1 1 auto;
  padding-left: 20%;
  align-self: flex-start;
}

.contact-details h2 {
  font-size: clamp(2rem, 3vw, 2.6rem);
  font-weight: 800;
  margin: 0 0 .75rem;
  color: #111827;
}

.contact-text {
  margin: 0;
  color: #4b5563;
  font-size: 1rem;
  line-height: 1.6;
  text-align: justify;
}

.contact-details a {
  color: #021b4a;        /* choose your brand text colour */
  text-decoration: none; /* remove underline */
  font-weight: 700;      /* optional: make bold like the rest */
}

.contact-details a:hover {
  color: #4f46e5;        /* your brand purple on hover */
  text-decoration: underline;
}


/* Responsive: stack on mobile */

@media (max-width: 900px) {
  .contact-inner {
    flex-direction: column;
    align-items: center;
    text-align: center;
  }

  .contact-left {
    margin-bottom: 1.5rem;
  }

  .contact-pill-group {
    position: static;
    transform: none;
    align-items: center;
  }
}

/* ===== Mobile tweaks: CONTACT ===== */
@media (max-width: 768px) {
  .contact-inner {
    flex-direction: column;
    align-items: center;
    text-align: center;
    padding: 0 1.25rem;
    gap: 1.75rem;
  }

  .contact-left {
    position: relative;
    margin-bottom: 0.5rem;
  }

  /* Stop overlapping layout on mobile */
  .contact-pill-group {
    position: static;
    transform: none;
    left: auto;
    top: auto;
    align-items: center;
  }

  .contact-pill {
    width: min(100%, 320px);
    min-width: 0;
  }
  .contact-pill-email {
    --base-transform: rotate(8deg) translateY(-20%) translateX(20%);
    }
  .contact-pill-phone {
    --base-transform: rotate(-10deg) translateY(0%) translateX(-10%);
    }

  .contact-details {
    padding-left: 0;      /* remove that 20% indent on small screens */
    align-self: stretch;
  }

  .contact-text {
    max-width: 32rem;
    margin-inline: auto;
    text-align: center;
  }
}





/*==== FLOATING WHATSAPP ICON ====*/

.whatsapp-float {
    position: fixed;
    right: 20px;
    bottom: 20px;
    width: 56px;
    height: 56px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 9999px;
    background: #25D366;              /* WhatsApp green */
    box-shadow: 0 8px 20px rgba(0,0,0,.18), 0 3px 6px rgba(0,0,0,.12);
    z-index: 9999;
    text-decoration: none;
    transition: transform .15s ease, box-shadow .15s ease, opacity .2s ease;
}
.whatsapp-float:hover { transform: translateY(-2px); }
.whatsapp-float:active { transform: translateY(0); }
.whatsapp-float:focus { outline: 3px solid #e0e4cc; outline-offset: 3px; }
.whatsapp-float svg { width: 28px; height: 28px; fill: white; }

/* Optional: hide on very small screens if it overlaps your UI */
@media (max-width: 360px) {
    .whatsapp-float { width: 48px; height: 48px; right: 14px; bottom: 14px; }
    .whatsapp-float svg { width: 24px; height: 24px; }
}



/*==== BOOK LESSON MODAL ====*/

.modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(15, 23, 42, 0.45);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1.5rem;
  z-index: 9999;
  opacity: 0;
  pointer-events: none;
  transition: opacity .2s ease;

  /* IMPORTANT: overlay itself should NOT scroll */
  overflow: hidden;
}

.modal-overlay.is-open {
  opacity: 1;
  pointer-events: auto;
}

.modal {
  width: min(480px, 100%);
  background: #ffffff;
  border-radius: 11px;
  box-shadow: 0 24px 60px rgba(15, 23, 42, 0.35);
  padding: 1.8rem 1.6rem 1.6rem;
  position: relative;

  /* Keep height inside viewport + scroll INSIDE the box */
  max-height: calc(100vh - 3rem);
  overflow-y: auto;

  /* keep scrollbar inside the rounded corners */
  scrollbar-gutter: stable both-edges;

}

/* Small / short screens: start near top but still only modal scrolls */
@media (max-height: 700px) {
  .modal-overlay {
    align-items: flex-start;
    padding-top: 1.5rem;
    /* still no overlay scroll */
    overflow: hidden;
  }

  .modal {
    max-height: calc(100vh - 3rem);
  }
}

.modal-close {
  position: absolute;
  top: .6rem;
  right: .8rem;
  border: none;
  background: transparent;
  font-size: 1.4rem;
  cursor: pointer;
  line-height: 1;
}

/* Scrollbar styling (WebKit browsers) */
.modal::-webkit-scrollbar {
  width: 8px;
}

.modal::-webkit-scrollbar-track {
  background: transparent;
  border-radius: 8px;
}

.modal::-webkit-scrollbar-thumb {
  background: rgba(79,70,229,0.5); /* your brand purple */
  border-radius: 8px;
}

.modal::-webkit-scrollbar-thumb:hover {
  background: rgba(79,70,229,0.7);
}

/* Firefox scrollbar styling */
.modal {
  scrollbar-width: thin;
  scrollbar-color: rgba(79,70,229,0.5) transparent;
}


.modal h2 {
  margin: 0 0 .5rem;
  font-size: 1.4rem;
  font-weight: 700;
}

.modal-intro {
  margin: 0 0 1.2rem;
  font-size: .95rem;
  color: #4b5563;
}

/* @media (max-height: 700px) {
  .modal-overlay {
    align-items: flex-start;   /* stick modal near the top */
   /* padding-top: 1.5rem;
  /*}

  .modal {
    margin-bottom: 1.5rem;     /* bit of breathing room at bottom */
   /* max-height: calc(100vh - 3rem);
  }
} */

/* Form styles */

#book-form {
  display: flex;
  flex-direction: column;
  gap: .9rem;
}

.form-row label {
  display: flex;
  flex-direction: column;
  gap: .25rem;
  font-size: .9rem;
  color: #374151;
}

.form-row input,
.form-row textarea {
  padding: .55rem .7rem;
  border-radius: 10px;
  border: 1px solid #d1d5db;
  font: inherit;
  resize: vertical;
}

.form-row input:focus,
.form-row textarea:focus {
  outline: 2px solid #4f46e5;
  outline-offset: 1px;
}

/* Submit button */

.modal-submit {
  margin-top: .4rem;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: .6rem 1.2rem;
  border-radius: 999px;
  border: none;
  background: linear-gradient(90deg, #4f46e5, #06b6d4);
  color: #fff;
  font-weight: 600;
  cursor: pointer;
}

.modal-submit:hover {
  filter: brightness(1.05);
}

.modal-feedback {
  margin-top: .4rem;
  font-size: .85rem;
  color: #059669; /* green-ish */
}

/* Small screens */
@media (max-width: 480px) {
  .modal {
    padding: 1.5rem 1.1rem 1.2rem;
  }
}


/*==== FOOTER ====*/
footer {
  text-align: center;
  padding: 2rem 1rem;
  font-size: 0.85rem;
  color: #6b7280;
}

footer a {
  color: #021b4a;        /* choose your brand text colour */
  text-decoration: none; /* remove underline */
  font-weight: 700;      /* optional: make bold like the rest */
}

footer a:hover {
  color: #4f46e5;        /* your brand purple on hover */
  text-decoration: underline;
}



/*==== PRIVACY POLICY ====*/

/* ==== PRIVACY POLICY & TERMS PAGES ==== */

.legal-section {
  width: 100%;
  display: flex;
  justify-content: center;
  padding: clamp(3rem, 8vw, 5.5rem) 0;
  background: #ffffff;
}

.legal-container {
  width: min(1100px, 100%);
  padding: 0 1.5rem;
  display: flex;
  flex-direction: column;
  gap: 1.2rem;
}

/* Headings */
.legal-container h1 {
  font-size: clamp(2.2rem, 3.8vw, 3rem);
  font-weight: 800;
  line-height: 1.15;
  margin: 0 0 1rem 0;
  color: #1f2937;
}

.legal-container h2 {
  font-size: clamp(1.5rem, 2.3vw, 2rem);
  font-weight: 700;
  margin-top: 2.2rem;
  margin-bottom: 0.8rem;
  color: #1f2937;
}

/* Body text */
.legal-container p,
.legal-container li {
  font-size: clamp(1rem, 1.25vw, 1.12rem);
  line-height: 1.7;
  margin: 0.4rem 0 0.8rem;
  color: #374151;
}

.legal-container ul {
  padding-left: 1.2rem;
}

/* Make spacing consistent with About page on mobile */
@media (max-width: 900px) {
  .legal-container {
    text-align: left;
    max-width: 90%;
  }
}

@media (max-width: 480px) {
  .legal-container p,
  .legal-container li {
    font-size: .96rem;
  }
}
