/*
  MASABA × FLYINGMINDS — Homepage
  Cream canvas · hot magenta · turmeric gold · forest teal · poppy red
*/

:root {
  --cream:    #fdf6e8;
  --cream-2:  #f5ead0;
  --magenta:  #e8195a;
  --magenta-l:#ff4d7e;
  --gold:     #fcc162;
  --gold-l:   #ffc444;
  --teal:     #1a7a6e;
  --teal-l:   #2aaa98;
  --ink:      #1a1208;
  --ink-2:    #3a2e1a;
  --body:     #4a3e28;
  --quiet:    #8a7a5a;
  --rule:     #d4c4a0;
  --white:    #ffffff;
}

.landing-masaba *,
.landing-masaba *::before,
.landing-masaba *::after { margin: 0; padding: 0; box-sizing: border-box; }
.landing-masaba { -webkit-font-smoothing: antialiased; scroll-behavior: smooth; }

.landing-masaba body {
  font-family: 'DM Sans', sans-serif;
  background: var(--cream);
  color: var(--body);
  overflow-x: hidden;
}

.landing-masaba .m-pattern {
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='120' height='120'%3E%3Crect width='120' height='120' fill='%23fdf6e8'/%3E%3Cellipse cx='30' cy='32' rx='14' ry='16' fill='%23f5a623' stroke='%231a1208' stroke-width='1.8'/%3E%3Cellipse cx='25' cy='28' rx='5' ry='6' fill='white' stroke='%231a1208' stroke-width='1.2'/%3E%3Cellipse cx='35' cy='28' rx='5' ry='6' fill='white' stroke='%231a1208' stroke-width='1.2'/%3E%3Ccircle cx='25' cy='29' r='2.5' fill='%231a1208'/%3E%3Ccircle cx='35' cy='29' r='2.5' fill='%231a1208'/%3E%3Cellipse cx='30' cy='40' rx='8' ry='5' fill='%23e8195a' stroke='%231a1208' stroke-width='1.2'/%3E%3Cpolygon points='27,22 30,16 33,22' fill='%231a1208'/%3E%3Cpolygon points='85,15 87,21 93,21 88,25 90,31 85,27 80,31 82,25 77,21 83,21' fill='%231a7a6e' stroke='%231a1208' stroke-width='1'/%3E%3Cpath d='M15 85 Q8 78 15 70 Q5 75 8 85 Q5 95 15 100 Q8 95 15 85Z' fill='%23e8195a' stroke='%231a1208' stroke-width='1.2'/%3E%3Ccircle cx='90' cy='75' r='6' fill='%23f5a623' stroke='%231a1208' stroke-width='1.2'/%3E%3Ccircle cx='60' cy='55' r='3' fill='%231a7a6e' opacity='0.4'/%3E%3Ccircle cx='50' cy='100' r='4' fill='%23e8195a' opacity='0.3'/%3E%3Ccircle cx='100' cy='45' r='3' fill='%23f5a623' opacity='0.4'/%3E%3Crect x='65' y='88' width='18' height='14' rx='2' fill='%231a7a6e' stroke='%231a1208' stroke-width='1.2'/%3E%3Cline x1='74' y1='88' x2='74' y2='102' stroke='%231a1208' stroke-width='1.2'/%3E%3C/svg%3E");
  background-size: 120px 120px;
}

/* Nav */
.landing-masaba .landing-nav {
  position: fixed; top: 0; left: 0; right: 0; z-index: 400;
  height: 60px; padding: 0 40px;
  display: flex; align-items: center; justify-content: space-between;
  background: var(--ink);
  border-bottom: 3px solid var(--magenta);
}

.landing-masaba .logo {
  display: flex; align-items: center; gap: 10px; text-decoration: none;
}
.landing-masaba .logo-mark {
  width: 34px; height: 34px; border-radius: 50%;
  background: var(--gold);
  border: 2.5px solid var(--white);
  display: flex; align-items: center; justify-content: center;
  overflow: hidden;
  transition: transform .2s;
}
.landing-masaba .logo-mark .logo-img {
  width: 100%; height: 100%; object-fit: cover;
}
.landing-masaba .logo:hover .logo-mark { transform: rotate(-15deg) scale(1.1); }
.landing-masaba .logo-name {
  font-family: 'Fraunces', serif;
  font-size: 20px; font-weight: 700;
  color: var(--white); letter-spacing: -0.01em;
}
.landing-masaba .logo-name span { color: var(--gold); }

.landing-masaba .nav-links { display: flex; gap: 2px; list-style: none; }
.landing-masaba .ni { position: relative; }
.landing-masaba .nl {
  font-size: 13px; font-weight: 500;
  color: rgba(255,255,255,.65);
  text-decoration: none; padding: 6px 13px; border-radius: 4px;
  transition: all .15s; display: flex; align-items: center; gap: 4px;
}
.landing-masaba .nl:hover { color: #fff; background: rgba(255,255,255,.1); }
.landing-masaba .v { font-size: 7px; transition: transform .18s; }
.landing-masaba .ni:hover .v { transform: rotate(180deg); }

.landing-masaba .dd {
  position: absolute; top: 100%; left: 50%;
  transform: translateX(-50%) translateY(-2px);
  background: var(--ink);
  border: 2px solid var(--gold);
  border-radius: 12px; padding: 14px 10px 10px;
  opacity: 0; pointer-events: none;
  transition: opacity .2s cubic-bezier(.16,1,.3,1), transform .2s cubic-bezier(.16,1,.3,1);
  min-width: 300px;
  box-shadow: 4px 4px 0 var(--magenta);
}
.landing-masaba .dd-sm { min-width: 230px; }
.landing-masaba .ni:hover .dd { opacity: 1; pointer-events: all; transform: translateX(-50%) translateY(0); }

.landing-masaba .dd-label {
  font-size: 9px; font-weight: 600; letter-spacing: .16em; text-transform: uppercase;
  color: var(--gold); padding: 2px 8px 8px;
  border-bottom: 1px solid rgba(245,166,35,.2); margin-bottom: 4px;
}
.landing-masaba .dd-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 3px; }
.landing-masaba .dd-1 { grid-template-columns: 1fr; }

.landing-masaba .di {
  display: block; text-decoration: none;
  padding: 7px 9px; border-radius: 7px;
  transition: background .12s;
}
.landing-masaba .di:hover { background: rgba(255,255,255,.07); }
.landing-masaba .di-t { font-size: 12.5px; font-weight: 400; color: rgba(255,255,255,.85); }
.landing-masaba .di-s { font-size: 10.5px; color: rgba(255,255,255,.35); font-style: italic; margin-top: 1px; }

.landing-masaba .dd-teacher {
  grid-column: 1/-1; margin-top: 5px;
  padding: 9px 12px; border-radius: 8px;
  background: var(--magenta);
  text-decoration: none; display: flex; align-items: center; justify-content: space-between;
  transition: opacity .14s;
}
.landing-masaba .dd-teacher:hover { opacity: .88; }
.landing-masaba .dd-teacher-t { font-size: 12.5px; font-weight: 600; color: #fff; }
.landing-masaba .dd-teacher-s { font-size: 10.5px; color: rgba(255,255,255,.7); margin-top: 1px; }
.landing-masaba .dd-teacher-arr { color: #fff; font-size: 16px; }

.landing-masaba .nav-cta-wrap { display: flex; align-items: center; gap: 10px; }
.landing-masaba .nav-cta-link {
  font-size: 12.5px; font-weight: 600;
  color: rgba(255,255,255,.85);
  text-decoration: none; padding: 6px 12px; border-radius: 5px;
  transition: background .15s;
}
.landing-masaba .nav-cta-link:hover { color: #fff; background: rgba(255,255,255,.1); }
.landing-masaba .nav-cta {
  font-family: 'DM Sans', sans-serif;
  font-size: 12.5px; font-weight: 600;
  color: var(--ink); background: var(--gold);
  border: none; padding: 9px 20px; border-radius: 5px; cursor: pointer;
  text-decoration: none; display: inline-block;
  border-bottom: 3px solid #c07800;
  transition: all .18s; letter-spacing: .02em;
}
.landing-masaba .nav-cta:hover { background: var(--gold-l); transform: translateY(-1px); }
.landing-masaba .nav-cta:active { transform: translateY(1px); border-bottom-width: 1px; }

/* Hero */
.landing-masaba .hero {
  min-height: 100vh;
  padding-top: 60px;
  display: grid; grid-template-columns: 1fr 1fr;
  position: relative;
}

.landing-masaba .hero-l {
  display: flex; flex-direction: column; justify-content: center;
  padding: 72px 60px 72px 68px;
  position: relative; z-index: 1;
  border-right: 3px solid var(--ink);
}

.landing-masaba .hero-l::before {
  content: '';
  position: absolute; top: 0; left: 0; right: 0; height: 6px;
  background: linear-gradient(90deg,
    var(--magenta) 0% 25%,
    var(--gold) 25% 50%,
    var(--teal) 50% 75%,
    var(--ink) 75% 100%);
}

.landing-masaba .eyebrow {
  display: inline-flex; align-items: center; gap: 8px;
  font-size: 11px; font-weight: 600; letter-spacing: .14em; text-transform: uppercase;
  color: var(--magenta);
  margin-bottom: 22px;
  opacity: 0; animation: landing-up .7s .05s forwards;
}
.landing-masaba .eyebrow-dot { width: 8px; height: 8px; border-radius: 50%; background: var(--magenta); }

.landing-masaba .hero h1 {
  font-family: 'Fraunces', serif;
  font-size: clamp(48px, 5.5vw, 80px);
  font-weight: 900; line-height: 1;
  letter-spacing: -0.02em; color: var(--ink);
  margin-bottom: 6px;
  opacity: 0; animation: landing-up .75s .12s forwards;
}
.landing-masaba .hero h1 em {
  font-style: italic; font-weight: 300;
  color: var(--magenta);
}
.landing-masaba .h1-sub {
  font-family: 'Fraunces', serif;
  font-size: clamp(34px, 3.8vw, 56px);
  font-weight: 300; font-style: italic;
  color: var(--teal); line-height: 1.1;
  display: block; margin-bottom: 28px;
  opacity: 0; animation: landing-up .75s .18s forwards;
}

.landing-masaba .hero-p {
  font-size: 15.5px; line-height: 1.78;
  color: var(--body); max-width: 420px;
  margin-bottom: 40px; letter-spacing: .01em;
  opacity: 0; animation: landing-up .75s .26s forwards;
}

.landing-masaba .hero-btns {
  display: flex; gap: 12px; flex-wrap: wrap;
  opacity: 0; animation: landing-up .75s .34s forwards;
}

.landing-masaba .btn-ink {
  font-size: 13px; font-weight: 600; letter-spacing: .04em;
  color: #fff; background: var(--ink);
  border: none; padding: 13px 26px; border-radius: 6px; cursor: pointer;
  text-decoration: none; display: inline-block;
  border-bottom: 4px solid #000;
  transition: all .18s;
}
.landing-masaba .btn-ink:hover { background: var(--ink-2); transform: translateY(-2px); }
.landing-masaba .btn-ink:active { transform: translateY(1px); border-bottom-width: 1px; }

.landing-masaba .btn-outline {
  font-size: 13px; font-weight: 600; letter-spacing: .04em;
  color: var(--teal); background: transparent;
  border: 2px solid var(--teal); padding: 11px 24px; border-radius: 6px; cursor: pointer;
  text-decoration: none; display: inline-block;
  transition: all .18s;
}
.landing-masaba .btn-outline:hover { background: var(--teal); color: #fff; }

/* Fred panel */
.landing-masaba .hero-r {
  position: relative; overflow: hidden;
  display: flex; align-items: center; justify-content: center;
  padding: 52px;
  border-left: 3px solid var(--ink);
}

.landing-masaba .hero-r .m-pattern {
  position: absolute; inset: 0;
  opacity: .55;
}

.landing-masaba .fred-bg-motif {
  position: absolute;
  font-size: 280px; line-height: 1;
  opacity: .08; z-index: 0;
  top: 50%; left: 50%; transform: translate(-50%, -52%);
  pointer-events: none; user-select: none;
  filter: grayscale(1);
}

.landing-masaba .fred-stage {
  position: relative; z-index: 2; width: 100%; max-width: 420px;
  opacity: 0; animation: landing-up .75s .28s forwards;
}

.landing-masaba .fred-card {
  background: var(--white);
  border: 3px solid var(--ink);
  border-radius: 18px;
  overflow: hidden;
  box-shadow: 8px 8px 0 var(--ink);
  position: relative;
}

.landing-masaba .fred-stripe {
  height: 8px;
  background: linear-gradient(90deg,
    var(--magenta) 0% 20%,
    var(--gold) 20% 40%,
    var(--teal) 40% 60%,
    var(--magenta) 60% 80%,
    var(--gold) 80% 100%);
}

.landing-masaba .fred-head {
  background: var(--cream-2);
  border-bottom: 2.5px solid var(--ink);
  padding: 18px 20px;
  display: flex; align-items: center; gap: 14px;
  position: relative; overflow: hidden;
}

.landing-masaba .fred-head::before {
  content: '';
  position: absolute; inset: 0;
  background-image: radial-gradient(circle, rgba(26,122,110,.15) 2px, transparent 2px);
  background-size: 18px 18px;
  pointer-events: none;
}

.landing-masaba .fred-av {
  width: 52px; height: 52px; border-radius: 50%;
  background: var(--gold);
  border: 3px solid var(--ink);
  display: flex; align-items: center; justify-content: center;
  flex-shrink: 0; position: relative; z-index: 1;
  box-shadow: 3px 3px 0 var(--ink);
  overflow: hidden;
}
.landing-masaba .fred-av .fred-av-img {
  width: 100%; height: 100%; object-fit: cover;
}

.landing-masaba .fred-info { position: relative; z-index: 1; flex: 1; }
.landing-masaba .fred-name {
  font-family: 'Fraunces', serif;
  font-size: 22px; font-weight: 900;
  color: var(--ink); letter-spacing: -0.01em;
}
.landing-masaba .fred-role {
  font-size: 11.5px; color: var(--body); margin-top: 2px;
  font-style: italic;
}
.landing-masaba .fred-badge {
  position: relative; z-index: 1;
  display: flex; align-items: center; gap: 5px;
  background: var(--teal); color: #fff;
  font-size: 10px; font-weight: 600; letter-spacing: .04em;
  padding: 5px 10px; border-radius: 20px;
  border: 2px solid var(--ink);
}
.landing-masaba .live-dot { width: 5px; height: 5px; border-radius: 50%; background: #6ee7b7; animation: landing-blink 2s infinite; }
@keyframes landing-blink { 0%, 100% { opacity: 1; } 50% { opacity: .2; } }

/* Chat bubbles — single font size for consistency */
.landing-masaba .fred-body { padding: 20px; }
.landing-masaba .chat { display: flex; flex-direction: column; gap: 10px; margin-bottom: 20px; }

.landing-masaba .b {
  max-width: 82%;
  padding: 11px 15px;
  font-size: 13.5px;
  line-height: 1.5;
  color: var(--ink);
  border: 2px solid var(--ink);
  position: relative;
}
.landing-masaba .b-fred {
  background: var(--cream);
  border-radius: 14px 14px 14px 3px;
  align-self: flex-start;
  box-shadow: 2px 2px 0 var(--ink);
}
.landing-masaba .b-student {
  background: var(--magenta);
  border-radius: 14px 14px 3px 14px;
  align-self: flex-end;
  color: #fff; border-color: var(--ink);
  box-shadow: 2px 2px 0 var(--ink);
}
.landing-masaba .b-student2 {
  background: var(--teal);
  border-radius: 14px 14px 14px 3px;
  align-self: flex-start;
  color: #fff;
  box-shadow: 2px 2px 0 var(--ink);
}

.landing-masaba .fchips {
  display: flex;
  gap: 8px;
  flex-wrap: nowrap;
  padding-top: 16px;
  border-top: 2px solid var(--ink);
}
.landing-masaba .fchip {
  flex: 1 1 0;
  min-width: 0;
  height: 40px;
  min-height: 40px;
  font-size: 11px; font-weight: 600;
  line-height: 1;
  padding: 0 8px; border-radius: 20px;
  border: 2px solid var(--ink);
  background: var(--cream-2); color: var(--ink);
  cursor: pointer; transition: all .15s;
  text-decoration: none;
  box-sizing: border-box;
  text-align: center;
  white-space: nowrap;
  letter-spacing: 0.02em;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 4px;
}
.landing-masaba .fchip,
.landing-masaba .fchip.c-m,
.landing-masaba .fchip.c-t,
.landing-masaba .fchip.c-g {
  font-size: 11px;
}
/* Normalize emoji size so SAT (🎯) doesn’t sit on a different line than others */
.landing-masaba .fchip .fchip-emoji {
  font-size: 14px;
  line-height: 1;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 1.25em;
  flex-shrink: 0;
}
.landing-masaba .fchip:hover { background: var(--ink); color: #fff; transform: translateY(-2px); box-shadow: 2px 2px 0 var(--magenta); }
.landing-masaba .fchip.c-m { background: var(--magenta); color: #fff; }
.landing-masaba .fchip.c-m:hover { background: var(--ink); }
.landing-masaba .fchip.c-g { background: var(--gold); }
.landing-masaba .fchip.c-t { background: var(--teal); color: #fff; }
.landing-masaba .fchip.fchip-astro {
  min-width: 110px;
  padding-left: 14px;
  padding-right: 14px;
  margin-left: 8px;
  margin-right: 8px;
}

.landing-masaba .fred-label {
  text-align: center; margin-top: 16px;
  font-family: 'Fraunces', serif;
  font-size: 13px; font-style: italic; font-weight: 300;
  color: var(--ink); letter-spacing: .04em;
  padding: 10px 16px;
  background: rgba(253, 246, 232, 0.95);
  border: 2px solid var(--ink);
  border-radius: 10px;
  box-shadow: 3px 3px 0 var(--ink);
  position: relative; z-index: 1;
}
.landing-masaba .fred-label strong { font-weight: 700; color: var(--magenta); }
.landing-masaba .fred-gold {
  color: var(--gold);
  text-shadow: 1px 0 0 var(--ink), -1px 0 0 var(--ink), 0 1px 0 var(--ink), 0 -1px 0 var(--ink), 1px 1px 0 var(--ink), 1px -1px 0 var(--ink), -1px 1px 0 var(--ink), -1px -1px 0 var(--ink), 2px 0 0 var(--ink), -2px 0 0 var(--ink), 0 2px 0 var(--ink), 0 -2px 0 var(--ink), 2px 2px 0 var(--ink), 2px -2px 0 var(--ink), -2px 2px 0 var(--ink), -2px -2px 0 var(--ink);
}
/* No outline for "Fred" in the label — gold only */
.landing-masaba .fred-label .fred-gold {
  text-shadow: none;
}

/* In-card demo (hero Fred card) */
.landing-masaba .fred-demo-mastery-wrap {
  display: flex; align-items: center; gap: 6px; margin-left: auto;
}
.landing-masaba .fred-demo-mastery-wrap.hidden { display: none; }
.landing-masaba .fred-demo-mastery-lbl { font-size: 9px; font-weight: 600; letter-spacing: .08em; text-transform: uppercase; color: var(--body); }
.landing-masaba .fred-demo-mastery-bar { width: 56px; height: 6px; background: var(--cream-2); border: 1px solid var(--ink); border-radius: 999px; overflow: hidden; }
.landing-masaba .fred-demo-mastery-fill { height: 100%; background: var(--teal); border-radius: 999px; transition: width 0.5s ease; }
.landing-masaba .fred-demo-mastery-pct { font-size: 11px; font-weight: 700; color: var(--ink); min-width: 24px; }

.landing-masaba .fred-demo-messages {
  min-height: 200px; max-height: 280px; overflow-y: auto;
  display: flex; flex-direction: column; gap: 10px;
  margin-bottom: 12px;
}
.landing-masaba .fred-demo-welcome {
  text-align: center; padding: 16px 0 20px;
}
.landing-masaba .fred-demo-welcome p { font-size: 12px; line-height: 1.5; color: var(--body); margin-bottom: 14px; }
.landing-masaba .fred-demo-welcome.hidden { display: none; }
.landing-masaba .fred-demo-start-btn {
  font-size: 12px; font-weight: 600; color: #fff; background: var(--ink);
  border: none; padding: 10px 20px; border-radius: 6px; cursor: pointer;
  border-bottom: 3px solid #000; transition: all .18s;
}
.landing-masaba .fred-demo-start-btn:hover { background: var(--ink-2); }
.landing-masaba .fred-demo-start-btn:disabled { opacity: 0.7; cursor: not-allowed; }

.landing-masaba .fred-demo-annotation { padding: 8px 12px; margin-bottom: 10px; border-radius: 8px; border-left: 4px solid var(--gold); background: rgba(245, 166, 35, 0.15); font-size: 11px; color: var(--ink); }
.landing-masaba .fred-demo-annotation.hidden { display: none; }
.landing-masaba .fred-demo-annotation-label { font-weight: 700; }
.landing-masaba .fred-demo-insight-bar { padding: 8px 0; border-top: 2px solid var(--rule); font-size: 11px; color: var(--body); margin-bottom: 8px; }
.landing-masaba .fred-demo-insight-bar.hidden { display: none; }
.landing-masaba .fred-demo-insight-label { font-weight: 700; }
.landing-masaba .fred-demo-report-cta { text-align: center; padding-top: 10px; padding-bottom: 12px; border-top: 2px solid var(--rule); }
.landing-masaba .fred-demo-report-cta.hidden { display: none; }
.landing-masaba .fred-demo-report-btn { font-size: 12px; font-weight: 600; color: #fff; background: var(--ink); border: none; padding: 10px 20px; border-radius: 6px; cursor: pointer; border-bottom: 3px solid #000; }
.landing-masaba .fred-demo-report-btn:hover { background: var(--ink-2); }

/* Demo modal */
.landing-masaba .fred-demo-modal {
  position: fixed; inset: 0; z-index: 500;
  background: rgba(0,0,0,0.6); display: flex; align-items: center; justify-content: center; padding: 20px;
}
.landing-masaba .fred-demo-modal-inner {
  background: var(--white); border: 3px solid var(--ink); border-radius: 18px; padding: 24px; max-width: 360px; width: 100%;
  box-shadow: 8px 8px 0 var(--ink);
}
.landing-masaba .fred-demo-modal-icon { text-align: center; font-size: 32px; margin-bottom: 8px; }
.landing-masaba .fred-demo-modal-title { font-family: 'Fraunces', serif; font-size: 20px; font-weight: 900; color: var(--ink); text-align: center; margin-bottom: 16px; }
.landing-masaba .fred-demo-modal-row { display: flex; justify-content: space-between; font-size: 13px; margin-bottom: 8px; }
.landing-masaba .fred-demo-modal-row span:first-child { color: var(--body); }
.landing-masaba .fred-demo-modal-row span:last-child { font-weight: 700; color: var(--ink); }
.landing-masaba .fred-demo-modal-insight { font-size: 12px; margin-bottom: 20px; }
.landing-masaba .fred-demo-modal-insight span { font-weight: 700; color: var(--body); display: block; margin-bottom: 4px; }
.landing-masaba .fred-demo-modal-insight p { color: var(--ink); line-height: 1.5; }
.landing-masaba .fred-demo-modal-actions { display: flex; gap: 10px; }
.landing-masaba .fred-demo-btn { font-size: 12px; font-weight: 600; padding: 10px 16px; border-radius: 6px; text-align: center; text-decoration: none; border: none; cursor: pointer; flex: 1; }
.landing-masaba .fred-demo-btn-secondary { background: var(--cream-2); color: var(--ink); border: 2px solid var(--ink); }
.landing-masaba .fred-demo-btn-primary { background: var(--teal); color: #fff; border-bottom: 3px solid #0d5c52; }

/* Injected demo messages (script adds .fred-msg) */
.landing-masaba .fred-demo-messages .fred-msg {
  display: flex; align-items: flex-start; gap: 8px; animation: fred-demo-msg-in 0.35s ease-out;
}
.landing-masaba .fred-demo-messages .fred-msg.user { flex-direction: row-reverse; }
.landing-masaba .fred-demo-messages .fred-msg .avatar {
  width: 28px; height: 28px; border-radius: 50%; flex-shrink: 0; display: flex; align-items: center; justify-content: center;
  font-size: 12px; font-weight: 700; border: 2px solid var(--ink);
}
.landing-masaba .fred-demo-messages .fred-msg .avatar.fred { background: var(--gold); color: var(--ink); }
.landing-masaba .fred-demo-messages .fred-msg .avatar.user { background: var(--magenta); color: #fff; }
.landing-masaba .fred-demo-messages .fred-msg .bubble {
  max-width: 85%; padding: 10px 12px; font-size: 12.5px; line-height: 1.5; border: 2px solid var(--ink);
}
.landing-masaba .fred-demo-messages .fred-msg .bubble.fred {
  background: var(--cream); color: var(--ink); border-radius: 12px 12px 12px 4px; box-shadow: 2px 2px 0 var(--ink);
}
.landing-masaba .fred-demo-messages .fred-msg .bubble.user {
  background: var(--magenta); color: #fff; border-radius: 12px 12px 4px 12px; box-shadow: 2px 2px 0 var(--ink);
}
@keyframes fred-demo-msg-in { from { opacity: 0; transform: translateY(6px); } to { opacity: 1; transform: translateY(0); } }

.landing-masaba .hidden { display: none !important; }

/* Stripe */
.landing-masaba .stripe {
  background: var(--ink);
  padding: 32px 68px;
  display: flex; align-items: center; justify-content: space-between; gap: 24px;
  flex-wrap: wrap; border-top: 3px solid var(--magenta); border-bottom: 3px solid var(--gold);
}
.landing-masaba .stat { text-align: center; }
.landing-masaba .stat-n {
  font-family: 'Fraunces', serif;
  font-size: 36px; font-weight: 900; color: var(--gold); line-height: 1;
}
.landing-masaba .stat-l { font-size: 12px; color: rgba(255,255,255,.5); margin-top: 3px; letter-spacing: .04em; text-transform: uppercase; }
.landing-masaba .stripe-mid {
  font-family: 'Fraunces', serif;
  font-size: 18px; font-style: italic; font-weight: 300; color: rgba(255,255,255,.6);
  text-align: center;
}
.landing-masaba .stripe-mid em { color: var(--gold); font-style: normal; font-weight: 700; }

/* Programs */
.landing-masaba .programs {
  padding: 90px 60px;
  max-width: 1200px; margin: 0 auto;
}

.landing-masaba .sec-eyebrow {
  font-size: 10px; font-weight: 600; letter-spacing: .18em; text-transform: uppercase;
  color: var(--magenta); margin-bottom: 14px; display: block;
}
.landing-masaba .sec-h2 {
  font-family: 'Fraunces', serif;
  font-size: clamp(38px, 5vw, 64px); font-weight: 900;
  letter-spacing: -0.02em; color: var(--ink); line-height: 1;
  margin-bottom: 52px;
}
.landing-masaba .sec-h2 em { font-style: italic; font-weight: 300; color: var(--teal); }

.landing-masaba .grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; }

.landing-masaba .card {
  background: var(--white);
  border: 3px solid var(--ink);
  border-radius: 14px; overflow: hidden;
  text-decoration: none; display: block;
  position: relative; cursor: pointer;
  transition: transform .2s, box-shadow .2s;
  opacity: 0; transform: translateY(20px);
  transition: opacity .5s ease, transform .5s ease, box-shadow .2s;
  box-shadow: 4px 4px 0 var(--rule);
  color: inherit;
}
.landing-masaba .card.in { opacity: 1; transform: none; }
.landing-masaba .card:hover { transform: translateY(-5px) rotate(-0.5deg); box-shadow: 8px 8px 0 var(--ink); }

.landing-masaba .card-bar { height: 10px; }
.landing-masaba .c-ela   .card-bar { background: linear-gradient(90deg, var(--magenta), var(--gold)); }
.landing-masaba .c-sat   .card-bar { background: var(--teal); }
.landing-masaba .c-astro .card-bar { background: linear-gradient(90deg, var(--ink), var(--magenta)); }
.landing-masaba .c-games .card-bar { background: linear-gradient(90deg, var(--gold), var(--teal)); }

.landing-masaba .card-body { padding: 26px 26px 32px; }
.landing-masaba .c-icon { font-size: 32px; margin-bottom: 14px; display: block; }
.landing-masaba .c-tag {
  font-size: 9.5px; font-weight: 700; letter-spacing: .14em; text-transform: uppercase;
  color: #fff; border-radius: 4px;
  padding: 3px 8px; display: inline-block; margin-bottom: 12px;
}
.landing-masaba .c-ela   .c-tag { background: var(--magenta); }
.landing-masaba .c-sat   .c-tag { background: var(--teal); }
.landing-masaba .c-astro .c-tag { background: var(--ink); }
.landing-masaba .c-games .c-tag { background: var(--gold); color: var(--ink); }

.landing-masaba .c-t {
  font-family: 'Fraunces', serif;
  font-size: 24px; font-weight: 900; color: var(--ink);
  letter-spacing: -0.01em; margin-bottom: 8px;
}
.landing-masaba .c-d { font-size: 13.5px; line-height: 1.7; color: var(--body); margin-bottom: 18px; }
.landing-masaba .card-desc-wrap { min-height: 4.2em; margin-bottom: 2px; }
.landing-masaba .card-desc-wrap .card-desc { margin-bottom: 18px; }
.landing-masaba .card-desc-wrap .card-desc.hidden { display: none; }
.landing-masaba .card-desc a { color: var(--teal); font-weight: 600; }
.landing-masaba .card-desc a:hover { text-decoration: underline; }

.landing-masaba .grade-row { display: flex; gap: 4px; flex-wrap: wrap; }
.landing-masaba .gp {
  font-size: 10.5px; font-weight: 600;
  padding: 3px 8px; border-radius: 20px;
  border: 2px solid var(--ink);
  background: var(--cream-2); color: var(--ink);
  cursor: pointer; transition: all .12s;
}
.landing-masaba .gp:hover, .landing-masaba .gp.on { background: var(--ink); color: #fff; }

/* Program card: grade-band tabs + topic list (ELA) */
.landing-masaba .band-row { display: flex; gap: 6px; flex-wrap: wrap; margin-bottom: 12px; }
.landing-masaba .band-tab {
  font-size: 11px; font-weight: 600;
  padding: 4px 10px; border-radius: 20px;
  border: 2px solid var(--ink);
  background: var(--cream-2); color: var(--ink);
  cursor: pointer; transition: all .12s;
}
.landing-masaba .band-tab:hover,
.landing-masaba .band-tab.on { background: var(--ink); color: #fff; }
.landing-masaba .card-cta {
  display: inline-block;
  font-weight: 600; font-size: 13px; color: var(--ink);
  border: 2px solid var(--ink); border-radius: 8px;
  padding: 8px 14px; text-decoration: none;
  transition: all .12s;
}
.landing-masaba .card-cta:hover { background: var(--ink); color: #fff; }

.landing-masaba .pill-tab {
  font-family: 'Fraunces', serif;
  font-size: 14px; font-weight: 700; font-style: italic;
  padding: 8px 18px; border-radius: 40px;
  border: 2.5px solid var(--ink);
  background: var(--cream-2); color: var(--ink);
  transition: all .18s; cursor: pointer;
}
.landing-masaba .pill-tab:hover,
.landing-masaba .pill-tab.on { background: var(--ink); color: #fff; }
.landing-masaba .pill-tab:nth-child(1).on { background: var(--ink); }
.landing-masaba .pill-tab:nth-child(2).on { background: var(--magenta); border-color: var(--magenta); }
.landing-masaba .pill-tab:nth-child(3).on { background: var(--teal); border-color: var(--teal); }

.landing-masaba .tags { display: flex; gap: 5px; flex-wrap: wrap; }
.landing-masaba .tag {
  font-size: 11px; font-weight: 500;
  padding: 3px 9px; border-radius: 20px;
  border: 1.5px solid var(--rule); color: var(--quiet); background: var(--cream-2);
  transition: all .12s;
}
.landing-masaba .card:hover .tag { border-color: var(--ink); color: var(--ink); }

.landing-masaba .card-wide { grid-column: 1/-1; }
.landing-masaba .card-wide .card-inner {
  display: grid; grid-template-columns: 1fr 1fr; gap: 32px; align-items: center;
  padding: 36px 32px;
}
.landing-masaba .card-wide .card-bar { grid-column: 1/-1; height: 10px; margin: -36px -32px 32px; width: calc(100% + 64px); }
.landing-masaba .coming-illo {
  display: flex; align-items: center; justify-content: center; gap: 16px; flex-wrap: wrap;
}
.landing-masaba .pill {
  font-family: 'Fraunces', serif;
  font-size: 14px; font-weight: 700; font-style: italic;
  padding: 8px 18px; border-radius: 40px;
  border: 2.5px solid var(--ink);
  transition: all .18s; cursor: pointer;
}
.landing-masaba .pill:nth-child(1) { background: var(--cream-2); color: var(--ink); transform: rotate(-3deg); }
.landing-masaba .pill:nth-child(2) { background: var(--magenta); color: #fff; transform: rotate(2deg); }
.landing-masaba .pill:nth-child(3) { background: var(--teal); color: #fff; transform: rotate(-1deg); }
.landing-masaba .pill:hover { transform: rotate(0deg) scale(1.05) !important; box-shadow: 4px 4px 0 var(--ink); }
.landing-masaba .c-next .card-bar { background: linear-gradient(90deg, var(--teal), var(--magenta), var(--gold)); }

/* Quote */
.landing-masaba .quote-band {
  background: var(--magenta);
  border-top: 3px solid var(--ink);
  border-bottom: 3px solid var(--ink);
  padding: 64px 68px;
  text-align: center; position: relative; overflow: hidden;
}
.landing-masaba .quote-band::before {
  content: '';
  position: absolute; inset: 0;
  background-image: radial-gradient(circle, rgba(255,255,255,.15) 2px, transparent 2px);
  background-size: 24px 24px;
  pointer-events: none;
}
.landing-masaba .q-mark {
  font-family: 'Fraunces', serif;
  font-size: 80px; font-weight: 900; color: rgba(255,255,255,.25);
  line-height: .7; margin-bottom: 16px; display: block; position: relative;
}
.landing-masaba .q-text {
  font-family: 'Fraunces', serif;
  font-size: clamp(18px, 2.4vw, 28px);
  font-weight: 300; font-style: italic;
  color: #fff; max-width: 680px; margin: 0 auto 16px;
  line-height: 1.55; position: relative; z-index: 1;
}
.landing-masaba .q-text strong { font-weight: 900; font-style: normal; }
.landing-masaba .q-attr {
  font-size: 11px; font-weight: 600; letter-spacing: .2em; text-transform: uppercase;
  color: rgba(255,255,255,.6); position: relative; z-index: 1;
}

/* Teachers */
.landing-masaba .teachers {
  background: var(--cream-2);
  border-top: 3px solid var(--ink); border-bottom: 3px solid var(--ink);
  padding: 90px 68px;
  position: relative; overflow: hidden;
}
.landing-masaba .teachers .m-pattern {
  position: absolute; inset: 0; opacity: .12;
}
.landing-masaba .t-inner {
  max-width: 1060px; margin: 0 auto;
  display: grid; grid-template-columns: 1fr 1fr; gap: 80px; align-items: center;
  position: relative; z-index: 1;
}
/* Left column: solid panel so "For educators" copy reads clearly */
.landing-masaba .t-inner > div:first-child {
  background: rgba(255, 255, 255, 0.92);
  padding: 32px 36px;
  border-radius: 14px;
  border: 2px solid var(--ink);
  box-shadow: 4px 4px 0 var(--ink);
}
.landing-masaba .t-h2 {
  font-family: 'Fraunces', serif;
  font-size: clamp(34px, 4.5vw, 56px); font-weight: 900;
  letter-spacing: -0.02em; color: var(--ink); line-height: 1;
  margin-bottom: 14px;
}
.landing-masaba .t-h2 em { font-style: italic; font-weight: 300; color: var(--magenta); }
.landing-masaba .t-p { font-size: 15px; line-height: 1.78; color: var(--body); margin-bottom: 30px; }

.landing-masaba .teachers .feat {
  list-style: none; display: flex; flex-direction: column; gap: 11px;
  background: rgba(255, 255, 255, 0.92);
  padding: 28px 32px;
  border-radius: 14px;
  border: 2px solid var(--ink);
  box-shadow: 4px 4px 0 var(--ink);
}
.landing-masaba .feat li {
  display: flex; align-items: flex-start; gap: 12px;
  font-size: 14px; line-height: 1.55; color: var(--ink);
  padding: 10px 14px; border-radius: 9px;
  background: var(--white); border: 2px solid var(--ink);
  box-shadow: 2px 2px 0 var(--rule);
}
.landing-masaba .f-em { font-size: 18px; flex-shrink: 0; }

/* Footer */
.landing-masaba .landing-footer {
  background: var(--ink);
  border-top: 6px solid transparent;
  border-image: linear-gradient(90deg, var(--magenta), var(--gold), var(--teal)) 1;
  padding: 40px 68px;
  display: flex; justify-content: space-between; align-items: center; flex-wrap: wrap; gap: 20px;
}
.landing-masaba .f-logo { display: flex; align-items: center; gap: 10px; text-decoration: none; color: inherit; }
.landing-masaba .f-mark {
  width: 28px; height: 28px; border-radius: 50%;
  background: var(--gold); border: 2px solid var(--white);
  display: flex; align-items: center; justify-content: center;
  overflow: hidden;
}
.landing-masaba .f-mark .f-mark-img {
  width: 100%; height: 100%; object-fit: cover;
}
.landing-masaba .f-name {
  font-family: 'Fraunces', serif;
  font-size: 18px; font-weight: 700; color: var(--white);
}
.landing-masaba .f-name span { color: var(--gold); }
.landing-masaba .f-nav { display: flex; gap: 20px; list-style: none; }
.landing-masaba .f-nav a {
  font-size: 12px; font-weight: 500; letter-spacing: .04em; text-transform: uppercase;
  color: rgba(255,255,255,.3); text-decoration: none; transition: color .14s;
}
.landing-masaba .f-nav a:hover { color: var(--gold); }
.landing-masaba .f-copy {
  font-family: 'Fraunces', serif;
  font-size: 12px; font-style: italic; color: rgba(255,255,255,.2);
}

@keyframes landing-up {
  from { opacity: 0; transform: translateY(16px); }
  to   { opacity: 1; transform: none; }
}

@media (max-width: 940px) {
  .landing-masaba .landing-nav { padding: 0 20px; }
  .landing-masaba .nav-links { display: none; }
  .landing-masaba .hero { grid-template-columns: 1fr; }
  .landing-masaba .hero-l { padding: 56px 24px 36px; border-right: none; border-bottom: 3px solid var(--ink); }
  .landing-masaba .hero-r { padding: 40px 24px 56px; min-height: auto; border-left: none; }
  .landing-masaba .stripe { padding: 28px 24px; }
  .landing-masaba .programs { padding: 64px 24px; }
  .landing-masaba .grid { grid-template-columns: 1fr; }
  .landing-masaba .card-wide .card-inner { grid-template-columns: 1fr; }
  .landing-masaba .teachers { padding: 64px 24px; }
  .landing-masaba .t-inner { grid-template-columns: 1fr; gap: 40px; }
  .landing-masaba .landing-footer { padding: 32px 24px; flex-direction: column; align-items: flex-start; }
}
