/*
Theme Name: Learn With Yuna
Theme URI: https://learnwithyuna.com
Author: Learn With Yuna
Author URI: https://learnwithyuna.com
Description: Parent-guided communication tools, practice sounds, picture stories, printables, and parent resources.
Version: 8.10.73
License: GNU General Public License v2 or later
License URI: http://www.gnu.org/licenses/gpl-2.0.html
Tags: accessibility, education, responsive, aac, speech-practice, autism
Text Domain: learnwithyuna
*/


:root{
  /* ---- Typography: one family everywhere ---- */
  --font-sans: "Inter", "Helvetica Neue", Helvetica, Arial, system-ui, -apple-system, "Segoe UI", sans-serif;
  --font-head: "Inter", "Helvetica Neue", Helvetica, Arial, system-ui, -apple-system, "Segoe UI", sans-serif;
  --font-serif: ui-serif, Georgia, "Times New Roman", serif;

  --ink:#0b1220;
  --muted:#475569;
  --muted2:#64748b;

  --bg:#ffffff;
  --bg-soft:#f8fafc;

  --line:rgba(15,23,42,.10);
  --line2:rgba(15,23,42,.07);

  --accent:#6d28d9;
  --accent-ink:#2e1065;

  --theme-primary:#d8b4fe;
  --theme-secondary:#f3e8ff;
  --theme-accent:#c084fc;
  --theme-text:#6b21a8;
  --theme-text-rgb:107,33,168;

  /* ---- Spacing scale (4px base) — use everywhere instead of one-off values ---- */
  --space-1:.25rem;   /* 4px  */
  --space-2:.5rem;    /* 8px  */
  --space-3:.75rem;   /* 12px */
  --space-4:1rem;     /* 16px */
  --space-5:1.5rem;   /* 24px */
  --space-6:2rem;     /* 32px */
  --space-7:3rem;     /* 48px */
  --space-8:4rem;     /* 64px */
  --space-9:6rem;     /* 96px */

  /* ---- Radius scale ---- */
  --radius-sm:10px;
  --radius:14px;
  --radius-lg:20px;
  --radius-xl:28px;
  --radius-full:999px;

  /* ---- Soft, low-contrast shadows (Apple/Headspace style — diffuse, not harsh) ---- */
  --shadow-xs:0 1px 2px rgba(15,23,42,.05);
  --shadow-sm:0 2px 8px rgba(15,23,42,.06), 0 1px 2px rgba(15,23,42,.04);
  --shadow-md:0 8px 24px rgba(15,23,42,.08), 0 2px 6px rgba(15,23,42,.05);
  --shadow-lg:0 16px 40px rgba(15,23,42,.10), 0 4px 10px rgba(15,23,42,.05);
  --shadow-focus:0 0 0 3px rgba(109,40,217,.22);

  /* ---- Motion — calmer, shorter, no bounce ---- */
  --ease:cubic-bezier(.4,0,.2,1);
  --ease-out:cubic-bezier(.16,1,.3,1);
  --dur-fast:.15s;
  --dur:.25s;
  --dur-slow:.4s;

  --container:80rem;
}

html{
  -webkit-text-size-adjust:100%;
  text-size-adjust:100%;
}

body{
  margin:0;
  background:var(--bg);
  color:var(--ink);
  font-family:var(--font-sans);
  -webkit-font-smoothing:antialiased;
  -moz-osx-font-smoothing:grayscale;
  line-height:1.58;
  font-size:16px;
}

button,input,select,textarea{font:inherit;}
p,li{line-height:1.62;}
@media (max-width:680px){body{font-size:16px;} p,li{line-height:1.64;}}

a{color:inherit}
img{max-width:100%; height:auto}
*, *::before, *::after{box-sizing:border-box}

.container{
  max-width:var(--container);
  margin-left:auto;
  margin-right:auto;
}

/* =============================================================
   GLOBAL DESIGN SYSTEM
   One button system, one card system, one motion language.
   Use these classes instead of ad-hoc inline styles on new work.
   ============================================================= */

/* ---- Buttons ---- */
.btn{
  display:inline-flex;
  align-items:center;
  justify-content:center;
  gap:.5rem;
  font-family:var(--font-sans);
  font-weight:700;
  font-size:.95rem;
  line-height:1.2;
  padding:.85rem 1.5rem;
  border-radius:var(--radius-full);
  border:1px solid transparent;
  cursor:pointer;
  text-decoration:none;
  white-space:nowrap;
  transition:transform var(--dur-fast) var(--ease-out),
             box-shadow var(--dur) var(--ease),
             background-color var(--dur) var(--ease),
             border-color var(--dur) var(--ease),
             color var(--dur) var(--ease);
}
.btn:active{transform:translateY(1px) scale(.99)}
.btn:focus-visible{outline:none; box-shadow:var(--shadow-focus)}

.btn-primary{
  background:var(--accent);
  color:#fff;
  box-shadow:var(--shadow-sm);
}
.btn-primary:hover{
  background:var(--accent-ink);
  box-shadow:var(--shadow-md);
  transform:translateY(-1px);
}

.btn-secondary{
  background:#fff;
  color:var(--ink);
  border-color:var(--line);
  box-shadow:var(--shadow-xs);
}
.btn-secondary:hover{
  border-color:var(--accent);
  color:var(--accent-ink);
  transform:translateY(-1px);
}

.btn-ghost{
  background:transparent;
  color:var(--ink);
  border-color:transparent;
}
.btn-ghost:hover{
  background:rgba(15,23,42,.04);
}

.btn-sm{padding:.6rem 1.1rem; font-size:.85rem}
.btn-lg{padding:1rem 2rem; font-size:1.05rem}

/* ---- Cards ---- */
.card{
  background:#fff;
  border:1px solid var(--line2);
  border-radius:var(--radius-lg);
  box-shadow:var(--shadow-sm);
  padding:var(--space-5);
  transition:transform var(--dur) var(--ease-out), box-shadow var(--dur) var(--ease);
}
.card-hover:hover{
  transform:translateY(-4px);
  box-shadow:var(--shadow-lg);
}

/* ---- Calm motion utilities (replaces bounce/scale-heavy animations) ---- */
@keyframes yuna-fade-up{
  from{opacity:0; transform:translateY(12px);}
  to{opacity:1; transform:translateY(0);}
}
.animate-fade-up{
  animation:yuna-fade-up var(--dur-slow) var(--ease-out) both;
}
.animate-fade-up:nth-child(2){animation-delay:.05s}
.animate-fade-up:nth-child(3){animation-delay:.1s}
.animate-fade-up:nth-child(4){animation-delay:.15s}
.animate-fade-up:nth-child(5){animation-delay:.2s}
.animate-fade-up:nth-child(6){animation-delay:.25s}

@media (prefers-reduced-motion: reduce){
  .animate-fade-up, .card, .btn{animation:none!important; transition:none!important;}
}


.flex{display:flex!important}
.items-center{align-items:center!important}
.justify-between{justify-content:space-between!important}
.gap-3{gap:.75rem!important}
.gap-4{gap:1rem!important}
.p-2{padding:.5rem!important}
.px-4{padding-left:1rem!important;padding-right:1rem!important}
.px-6{padding-left:1.5rem!important;padding-right:1.5rem!important}
.py-4{padding-top:1rem!important;padding-bottom:1rem!important}
.-mr-2{margin-right:-.5rem!important}
.hidden{display:none!important}

.w-12{width:3rem!important}.h-12{height:3rem!important}
.w-14{width:3.5rem!important}.h-14{height:3.5rem!important}

@media (min-width:768px){
  .md\:block{display:block!important}
  .md\:hidden{display:none!important}
  .md\:w-14{width:3.5rem!important}
  .md\:h-14{height:3.5rem!important}
}

.space-x-2 > :not([hidden]) ~ :not([hidden]){margin-left:.5rem}


#site-header{
  background:var(--bg);
  border-bottom:1px solid var(--line2);
}

.header-wrap{
  width:100%;
}

.primary-menu{
  display:flex;
  align-items:center;
  gap:.5rem;
  margin:0;
  padding:0;
}

.primary-menu>li{
  position:relative;
  list-style:none;
}

.primary-menu>li>a{
  display:inline-flex;
  align-items:center;
  gap:.35rem;
  font-weight:700;
  color:var(--ink);
  text-decoration:none;
  padding:.55rem .85rem;
  border-radius:999px;
  background:transparent;
  border:1px solid transparent;
  transition:background .15s ease, border-color .15s ease, color .15s ease;
  white-space:nowrap;
}

.primary-menu>li>a:hover{
  background:rgba(15,23,42,.04);
  border-color:rgba(15,23,42,.08);
}

.primary-menu .current-menu-item>a,
.primary-menu .current_page_item>a,
.primary-menu .current-menu-ancestor>a{
  background:rgba(109,40,217,.10)!important;
  border-color:rgba(109,40,217,.22)!important;
  color:var(--accent-ink)!important;
}

.primary-menu .sub-menu{
  position:absolute;
  top:100%;
  left:0;
  margin-top:10px;
  width:230px;
  background:#fff;
  border:1px solid var(--line2);
  border-radius:12px;
  padding:8px;
  z-index:100;
  opacity:0;
  visibility:hidden;
  transform:translateY(10px);
  transition:opacity .15s ease, transform .15s ease, visibility .15s ease;
}

.primary-menu li:hover>.sub-menu{
  opacity:1;
  visibility:visible;
  transform:translateY(0);
}

.primary-menu .sub-menu a{
  display:block;
  padding:10px 12px;
  border-radius:10px;
  text-decoration:none;
  font-weight:650;
  color:var(--ink)!important;
  transition:background .12s ease;
}

.primary-menu .sub-menu a:hover{
  background:rgba(15,23,42,.04);
}

/* =============== Mobile overlay menu (if your header uses it) =============== */

.mobile-overlay{
  position:fixed;
  inset:0;
  background:rgba(2,6,23,.45);
  opacity:0;
  transition:opacity .18s ease;
  z-index:50;
}
.mobile-overlay.open{opacity:1}

.mobile-menu-panel{
  position:fixed;
  top:0;
  right:0;
  height:100vh;
  width:min(360px, 92vw);
  background:#fff;
  border-left:1px solid var(--line2);
  transform:translateX(100%);
  transition:transform .18s ease;
  z-index:60;
}
.mobile-menu-panel.open{transform:translateX(0)}

.mobile-menu-inner{
  padding:18px;
}

.mobile-close{
  appearance:none;
  border:1px solid var(--line2);
  background:#fff;
  color:var(--ink);
  width:40px;height:40px;
  border-radius:12px;
  display:inline-flex;
  align-items:center;
  justify-content:center;
  font-weight:800;
  cursor:pointer;
}

.mobile-pill{
  display:block;
  padding:12px 14px;
  border:1px solid var(--line2);
  border-radius:14px;
  background:#fff;
}


.site-footer{
  font-family:var(--font-sans);
}


:root{
  --read-bg:#0e0f13;
  --read-panel:#111317;
  --read-text:#e7e3dd;
  --read-muted:#b5b0a7;
  --read-accent:#ffc27a;
}

body.story-reading .site-header,
body.story-reading header.site-header,
body.story-reading .site-footer,
body.story-reading footer.site-footer{display:none!important}

body.story-reading{
  background:var(--read-bg)!important;
  overflow-y:auto;
}

body.story-reading #single-story-view{
  position:relative;
  max-width:880px;
  margin:0 auto;
  padding:clamp(16px,4vw,28px);
}

body.story-reading .story-frame{
  background:var(--read-panel);
  border-radius:16px;
  overflow:hidden;
}

body.story-reading .story-stage{
  background:#0a0e1f;
  display:grid;
  place-items:center;
  padding:10px;
}

body.story-reading .story-stage img{
  width:100%;
  height:auto;
  border-radius:12px;
}

body.story-reading .story-box{
  background:transparent;
  padding:clamp(16px,3.6vw,28px);
}

body.story-reading .story-text{
  color:var(--read-text);
  font-family:"Source Serif 4", ui-serif, Georgia, "Times New Roman", serif;
  font-size:clamp(18px,2.1vw,20px);
  line-height:1.65;
  letter-spacing:.01em;
  max-width:64ch;
  margin:0 auto;
  text-rendering:optimizeLegibility;
  -webkit-font-smoothing:antialiased;
  hyphens:auto;
}

body.story-reading .story-text p{margin:0 0 .9em}
body.story-reading .story-text p:last-child{margin-bottom:0}

body.story-reading #extraContent{
  color:var(--read-muted);
  max-width:64ch;
  margin:0 auto 8px;
}


body h1, body h2, body h3, body h4, body h5, body h6{font-family:var(--font-head);letter-spacing:-.025em;}

/* =============================================================
   6.2 RESPONSIVE / ACCESSIBILITY HARDENING
   ============================================================= */
html,body{width:100%;max-width:100%;background:#fff!important}
body{min-height:100svh;min-height:100dvh;overflow-x:clip}
#page,.site,.site-main,main{max-width:100%;overflow-x:clip}
img,svg,video,canvas,iframe{max-width:100%}
button,a,input,select,textarea{-webkit-tap-highlight-color:transparent}
a,button{touch-action:manipulation}
:focus-visible{outline:3px solid rgba(109,40,217,.32);outline-offset:3px}
.y-skip-link{position:fixed;left:12px;top:12px;z-index:9999;transform:translateY(-160%);padding:10px 14px;border-radius:10px;background:#111827;color:#fff;font-weight:800;text-decoration:none}
.y-skip-link:focus{transform:none}

@media(max-width:1179px){
  .y-header-inner{min-height:64px}
  .y-brand{min-width:0}
  .y-brand>div{min-width:0}
  .y-title{white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
}
@media(max-width:420px){
  .y-header-inner{padding-left:max(10px,env(safe-area-inset-left));padding-right:max(10px,env(safe-area-inset-right));gap:8px}
  .y-logo{width:38px;height:38px}
  .y-title{font-size:15px}
  .y-hamburger{width:42px;height:42px;flex:0 0 42px}
  #y-drawer{width:min(92vw,360px);padding:24px max(18px,env(safe-area-inset-right)) calc(24px + env(safe-area-inset-bottom)) 20px}
}

/* Keep all page edges flush with browser chrome and safe areas. */
.site-footer{margin:0!important;padding-bottom:max(26px,env(safe-area-inset-bottom))!important}
body.admin-bar .y-header{top:32px}
@media(max-width:782px){body.admin-bar .y-header{top:46px}}

/* Minimum readable/tappable controls across educational activities. */
button,[role="button"],input[type="button"],input[type="submit"],.btn,.y-btn{min-height:44px}
input,select,textarea{max-width:100%;font-size:16px}

/* Prevent long educational labels from forcing horizontal scroll. */
h1,h2,h3,h4,p,li,a,button{overflow-wrap:anywhere}

@media(prefers-reduced-motion:reduce){
  html{scroll-behavior:auto}
  *,*::before,*::after{animation-duration:.01ms!important;animation-iteration-count:1!important;transition-duration:.01ms!important;scroll-behavior:auto!important}
}

/* 6.4 touch guard */
html{touch-action:manipulation;-webkit-text-size-adjust:100%;}
button,a,input,select,textarea{touch-action:manipulation;}

/* 6.5 Our Story */
.our-story-page{background:#f6f7f9;padding:clamp(34px,6vw,76px) 16px}
.our-story-wrap{width:min(820px,100%);margin:0 auto}
.our-story-card{padding:clamp(26px,5vw,58px);border:1px solid #e4e6ec;border-radius:28px;background:#fff;box-shadow:0 18px 48px rgba(31,36,56,.07);color:#2a3040}
.our-story-kicker{margin:0 0 10px;color:#9a7720;font-size:13px;letter-spacing:.08em;text-transform:uppercase}
.our-story-card h1{max-width:680px;margin:0 0 22px;font-size:clamp(34px,5vw,52px);line-height:1.08;letter-spacing:-.04em;font-weight:650;color:#202536}
.our-story-card h2{margin:34px 0 12px;font-size:clamp(24px,3vw,30px);line-height:1.2;font-weight:650;color:#202536}
.our-story-card p{margin:0 0 17px;font-size:17px;line-height:1.72;color:#555e70}
.our-story-card .our-story-intro{font-size:20px;color:#202536}
.our-story-card blockquote{margin:28px 0;padding:18px 20px;border-left:4px solid #c6a44b;border-radius:0 16px 16px 0;background:#fbf8ee;color:#34394a;font-size:clamp(20px,3vw,25px);line-height:1.45}
.our-story-points{display:grid;gap:10px;margin:18px 0 28px}
.our-story-points div{display:grid;grid-template-columns:34px 1fr;gap:11px;align-items:start;padding:14px;border:1px solid #e7e8ee;border-radius:16px;background:#fafafd}
.our-story-points span{width:30px;height:30px;display:grid;place-items:center;border-radius:10px;background:#fbf6e7;color:#9a7720;font-size:14px}
.our-story-points p{margin:2px 0 0;font-size:16px;line-height:1.5;color:#454d5f}
.our-story-signoff{color:#2f3748!important}
.our-story-note{margin-top:28px!important;padding-top:20px;border-top:1px solid #e7e8ee;font-size:13px!important;line-height:1.55!important;color:#777f8e!important}
@media(max-width:600px){.our-story-page{padding:20px 10px}.our-story-card{padding:24px 20px;border-radius:22px}.our-story-card p{font-size:16px}.our-story-card h1{font-size:35px}}


/* 6.6 global device orientation and stable story reader */
.yuna-orientation-gate{display:none;position:fixed;inset:0;z-index:2147483647;background:#fff;padding:24px;place-items:center;text-align:center}
.yuna-wrong-orientation .yuna-orientation-gate{display:grid}
.yuna-wrong-orientation body{overflow:hidden!important}
.yuna-orientation-card{width:min(340px,100%);padding:28px 22px;border:1px solid #e3e6ec;border-radius:22px;background:#fff;box-shadow:0 18px 50px rgba(31,36,56,.12)}
.yuna-orientation-icon{width:56px;height:56px;display:grid;place-items:center;margin:0 auto 12px;border-radius:17px;background:#f4f1fb;color:#6756ad;font-size:30px}
.yuna-orientation-card h2{margin:0 0 7px;font-size:22px;line-height:1.2;color:#202536}
.yuna-orientation-card p{margin:0;color:#687083;font-size:14px;line-height:1.5}


/* 8.2 Learn With Yuna Plus — quiet, family-friendly membership identity */
.y-plus-badge{display:inline-flex;align-items:center;margin-left:7px;padding:3px 7px;border:1px solid #d8c8ff;border-radius:999px;background:#f6f1ff;color:#6a49bf;font-size:9px;font-weight:900;letter-spacing:.06em;text-transform:uppercase;vertical-align:2px}
.y-plus-welcome[hidden]{display:none!important}.y-plus-welcome{position:fixed;inset:0;z-index:2147483646;display:grid;place-items:center;padding:20px;background:rgba(19,24,35,.45);backdrop-filter:blur(8px)}.y-plus-modal-open{overflow:hidden}.y-plus-welcome-card{width:min(430px,100%);padding:34px 28px;border:1px solid #e6dcff;border-radius:26px;background:linear-gradient(160deg,#fffafd,#fff);box-shadow:0 28px 80px rgba(22,28,43,.22);text-align:center}.y-plus-welcome-mark{width:54px;height:54px;display:grid;place-items:center;margin:0 auto 13px;border-radius:17px;background:#f6efff;color:#6a49bf;font-size:25px}.y-plus-welcome-kicker{margin:0 0 7px;color:#8a69c5;font-size:12px;font-weight:850;letter-spacing:.09em;text-transform:uppercase}.y-plus-welcome-card h2{margin:0 0 10px;font-size:30px;color:#1f2937}.y-plus-welcome-card p:not(.y-plus-welcome-kicker){margin:0 auto 20px;max-width:340px;color:#5d6677;line-height:1.6}.y-plus-welcome-card button{min-width:150px;border:0;border-radius:13px;background:#7c3aed;color:#fff;padding:0 20px;font-weight:800;cursor:pointer}
@media(max-width:420px){.y-plus-badge{margin-left:4px;padding:2px 5px;font-size:8px}.y-sub{display:none}.y-plus-welcome-card{padding:28px 20px;border-radius:22px}}

/* 8.3 complete Plus experience */
.lwy8-favorite-routine{border-color:#e5c96e!important;background:#fffaf0!important}.yp-plus-library{padding:52px 0;background:linear-gradient(180deg,#fffaf0,#fff)}.yp-plus-head{text-align:center;max-width:720px;margin:0 auto 24px}.yp-plus-head span,.yp-plus-card-label{color:#886500;font-weight:900}.yp-plus-head h2{font-size:clamp(30px,4vw,48px);margin:8px 0}.yp-plus-head p{color:#667085}.yp-plus-choice{position:relative;border-color:#eadfb9!important}.yp-plus-card-label{position:absolute;right:18px;top:16px;font-size:12px;background:#fff6d4;border:1px solid #ead27a;border-radius:999px;padding:5px 9px}.yp-plus-choice.is-locked .yp-preview{filter:saturate(.7);opacity:.72}.yp-plus-choice h3{font-size:21px;margin:0 0 8px}.yp-plus-choice p{margin:0 0 18px;color:#667085}
