:root {
  --navy: #10155f;
  --navy-2: #17196e;
  --violet: #6d35df;
  --violet-2: #8c45f2;
  --blue: #2672ef;
  --green: #39a846;
  --orange: #ff8a16;
  --pink: #ec3f87;
  --red: #ea3e34;
  --ink: #11174f;
  --muted: #62658a;
  --line: #e3e5f4;
  --soft: #f8f7ff;
  --card: rgba(255, 255, 255, .96);
  --shadow: 0 14px 40px rgba(51, 45, 120, .09);
  font-family: Inter, ui-rounded, "SF Pro Rounded", "Segoe UI", Arial, sans-serif;
  color: var(--ink);
  background: #fbfcff;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body { margin: 0; min-width: 320px; overflow-x: hidden; background: linear-gradient(180deg, #fff, #fafbff); }
button, input, select, textarea { font: inherit; }
button, a { -webkit-tap-highlight-color: transparent; }
a { color: inherit; text-decoration: none; }
button { color: inherit; }
img { max-width: 100%; }

.embedded-studio{
  width:100%;
  min-width:0;
  overflow:hidden;
  border:1px solid var(--line);
  border-radius:18px;
  background:#f4f5fb;
  box-shadow:var(--shadow);
}
.embedded-studio iframe{
  display:block;
  width:100%;
  height:max(940px,calc(100vh - 42px));
  border:0;
  background:#f4f5fb;
}
@media(max-width:900px){
  .embedded-studio{border-radius:12px}
  .embedded-studio iframe{height:calc(100vh - 88px);min-height:720px}
}

.pe-topbar {
  position: sticky;
  top: 0;
  z-index: 30;
  display: flex;
  align-items: center;
  gap: 18px;
  min-height: 84px;
  padding: 12px clamp(18px, 3vw, 42px);
  background: rgba(255,255,255,.94);
  border-bottom: 1px solid #ececf6;
  backdrop-filter: blur(16px);
}

.pe-brand { display: flex; flex: 0 1 auto; min-width: 0; align-items: center; gap: 13px; margin-right: auto; }
.pe-shield {
  display: grid;
  place-items: center;
  width: 48px;
  height: 54px;
  color: white;
  font-size: 30px;
  font-weight: 900;
  background: linear-gradient(145deg, #8a49f2, #2615ae);
  clip-path: polygon(50% 0, 94% 14%, 89% 74%, 50% 100%, 11% 74%, 6% 14%);
  filter: drop-shadow(0 5px 7px rgba(74, 30, 196, .2));
}
.pe-brand strong { display: block; font-size: 21px; line-height: 1.05; letter-spacing: .01em; }
.pe-brand small { color: var(--muted); }
.pe-header-actions {
  display: flex;
  min-width: 0;
  align-items: center;
  gap: 10px;
  overflow-x: auto;
  overscroll-behavior-x: contain;
  scrollbar-width: none;
}
.pe-header-actions::-webkit-scrollbar { display: none; }

.action-card, .icon-button, .primary, .secondary, .ghost, .nav-link, .answer-button {
  border: 0;
  cursor: pointer;
  transition: transform .18s ease, box-shadow .18s ease, border-color .18s ease, background .18s ease;
}
.action-card:hover, .primary:hover, .secondary:hover, .feature-card:hover, .module-card:hover { transform: translateY(-2px); }
.action-card {
  display: flex;
  flex: 0 0 auto;
  align-items: center;
  gap: 11px;
  min-height: 58px;
  padding: 9px 17px;
  border: 1px solid var(--line);
  border-radius: 13px;
  background: white;
  box-shadow: 0 5px 16px rgba(30, 27, 97, .04);
}
.action-card .emoji { display: grid; place-items: center; min-width: 34px; font-size: 0; }
.action-card strong { display: block; font-size: 14px; }
.action-card small { display: block; margin-top: 2px; color: var(--muted); font-size: 10px; }
.icon-button {
  display: grid;
  place-items: center;
  min-width: 54px;
  min-height: 54px;
  border: 1px solid var(--line);
  border-radius: 13px;
  background: #fff;
  font-size: 24px;
  position: relative;
}
.icon-button > .p3d-icon { --p3d-size: 30px; }
.icon-button .count {
  position: absolute; top: -7px; right: -7px;
  min-width: 22px; height: 22px; padding: 0 5px;
  display: grid; place-items: center;
  border: 2px solid white; border-radius: 999px;
  background: var(--red); color: white; font: 800 11px/1 sans-serif;
}
.primary, .secondary, .ghost {
  min-height: 44px;
  padding: 0 18px;
  border-radius: 10px;
  font-weight: 800;
}
.primary { color: #fff; background: linear-gradient(135deg, #8540ed, #4e22d0); box-shadow: 0 10px 22px rgba(91, 42, 210, .22); }
.secondary { color: #4f25c8; background: #fff; border: 1px solid #dcd7f3; }
.ghost { color: #5c2fd0; background: #f5f0ff; }
.danger { color: #fff; background: #df433c; }
.wide { width: 100%; }
.progress-login{display:flex!important;align-items:center;justify-content:center;gap:9px;margin-top:16px;white-space:nowrap}
.progress-login>span{display:inline-block;line-height:1}

.landing { width: min(1500px, calc(100% - 36px)); margin: 0 auto; padding: 18px 0 32px; }
.hero-layout { display: grid; grid-template-columns: minmax(0, 3fr) minmax(280px, 1fr); gap: 16px; }
.hero {
  position: relative;
  min-height: 356px;
  overflow: hidden;
  border: 1px solid #e8e3f5;
  border-radius: 20px;
  background:
    radial-gradient(circle at 62% 28%, rgba(255,255,255,.9), transparent 18%),
    linear-gradient(135deg, #fbfaff 20%, #f2ecff 100%);
  box-shadow: var(--shadow);
}
.hero-copy {
  position: relative;
  z-index: 2;
  width: 64%;
  min-width: 0;
  padding: 40px 28px;
  background: linear-gradient(90deg, rgba(251,250,255,.99) 0%, rgba(248,245,255,.97) 82%, rgba(248,245,255,0) 100%);
}
.hero h1 { margin: 0 0 14px; font-size: clamp(38px, 4vw, 58px); line-height: .98; letter-spacing: -.045em; }
.hero h1 span { color: #6834d8; display: block; }
.hero p { max-width: 620px; color: #23275f; font-size: 16px; line-height: 1.6; }
.hero-art { position: absolute; z-index: 1; right: 0; bottom: 0; width: 53%; height: 100%; object-fit: cover; object-position: center; mix-blend-mode: multiply; }
.hero-points { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 10px; margin: 22px 0; }
.hero-point { display: flex; align-items: flex-start; gap: 8px; font-size: 11px; line-height: 1.35; }
.hero-point b { display: block; margin-bottom: 3px; }
.hero-point > span:first-child { display: grid; place-items: center; min-width: 29px; font-size: 0; }
.button-row { display: flex; gap: 12px; flex-wrap: wrap; }

.side-stack { display: grid; gap: 14px; }
.info-card {
  padding: 20px;
  border: 1px solid var(--line);
  border-radius: 18px;
  background: white;
  box-shadow: var(--shadow);
}
.info-card h3 { margin: 0 0 15px; font-size: 15px; }
.info-list { display: grid; gap: 14px; }
.info-row { display: grid; grid-template-columns: 28px 1fr auto; align-items: center; gap: 9px; font-size: 12px; }
.info-row b:last-child { color: #25256e; text-align: right; }
.progress-card {
  color: white;
  background: linear-gradient(145deg, #7242e4, #3b1bb4);
  border: 0;
}
.progress-ring {
  --value: 0;
  width: 90px; height: 90px; border-radius: 50%;
  display: grid; place-items: center;
  background: conic-gradient(#fff calc(var(--value) * 1%), rgba(255,255,255,.25) 0);
}
.progress-ring::before {
  content: attr(data-label);
  width: 70px; height: 70px; display: grid; place-items: center;
  border-radius: 50%; background: #5b2bd2; font-weight: 900; font-size: 23px;
}

.features { display: grid; grid-template-columns: repeat(4, 1fr); gap: 16px; margin: 18px 0; }
.feature-card {
  display: flex; align-items: center; gap: 16px;
  min-height: 124px; padding: 18px;
  border: 1px solid var(--line); border-radius: 17px; background: white;
  transition: transform .18s ease;
}
.feature-card:nth-child(2) { background: #fbfff9; }
.feature-card:nth-child(3) { background: #fffaf5; }
.feature-card:nth-child(4) { background: #fff8fb; }
.feature-icon { display: grid; flex: 0 0 50px; place-items: center; font-size: 0; }
.feature-icon .p3d-icon { --p3d-size: 48px; }
.feature-card h3 { margin: 0 0 6px; font-size: 15px; color: #4d29c8; }
.feature-card p { margin: 0 0 10px; color: var(--muted); font-size: 11px; line-height: 1.5; }
.text-link { border: 0; background: none; padding: 0; color: #5c27d2; cursor: pointer; font-weight: 800; }

.section-card { padding: 20px; border: 1px solid var(--line); border-radius: 20px; background: #fff; }
.section-head { display: flex; align-items: center; gap: 12px; margin-bottom: 16px; }
.section-head h2 { margin: 0; font-size: 18px; }
.section-head p { margin: 3px 0 0; color: var(--muted); font-size: 12px; }
.section-head .secondary { margin-left: auto; }
.module-grid { display: grid; grid-template-columns: repeat(10, minmax(0, 1fr)); gap: 9px; }
.module-card {
  position: relative;
  display: grid;
  align-content: center;
  justify-items: center;
  min-height: 95px;
  padding: 10px 6px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: linear-gradient(180deg, #fff, #fbfbff);
  text-align: center;
  transition: transform .18s ease, box-shadow .18s ease;
}
.module-card:hover { box-shadow: 0 9px 20px rgba(62,47,139,.12); }
.module-no { position: absolute; top: 8px; left: 8px; color: white; background: #6a36dd; border-radius: 4px; padding: 2px 4px; font-size: 9px; font-weight: 900; }
.module-icon { display: grid; place-items: center; min-height: 33px; margin: 5px 0; font-size: 0; }
.module-icon .p3d-icon { --p3d-size: 32px; }
.module-card strong { font-size: 9px; line-height: 1.25; }
.module-card .lock { position: absolute; right: 8px; bottom: 7px; font-size: 12px; }
.module-card.complete { border-color: #b7e9b8; background: #f8fff7; }
.module-card.complete::after { content: "✓"; position: absolute; right: 8px; bottom: 7px; width: 16px; height: 16px; border-radius: 50%; color: white; background: var(--green); font: 900 11px/16px sans-serif; }
.module-card.current { border: 2px solid #7c43eb; box-shadow: 0 0 0 5px #eee6ff; }
.module-card.locked { opacity: .72; }
.overall { display: grid; grid-template-columns: auto 1fr auto; gap: 14px; align-items: center; margin-top: 16px; font-size: 12px; }
.bar { height: 9px; overflow: hidden; border-radius: 999px; background: #e9e9f2; }
.bar > i { display: block; height: 100%; border-radius: inherit; background: linear-gradient(90deg, #53ba42, #7d42e6); }

.method { display: grid; grid-template-columns: repeat(6, 1fr); gap: 12px; margin-top: 18px; }
.method .info-card { text-align: center; min-height: 120px; }
.method .info-card > span { display: grid; place-items: center; min-height: 50px; font-size: 0; }
.method .info-card > span .p3d-icon { --p3d-size: 48px; }
.method h3 { margin: 8px 0 5px; color: #29216d; }
.method p { margin: 0; color: var(--muted); font-size: 11px; line-height: 1.5; }

.auth-page {
  min-height: 100vh;
  width: 100%;
  overflow-x: hidden;
  display: grid;
  place-items: center;
  padding: 24px;
  background: radial-gradient(circle at 70% 20%, #eee5ff, transparent 28%), linear-gradient(145deg,#fcfdff,#f7f3ff);
}
.auth-shell { display: grid; grid-template-columns: minmax(0,1.15fr) minmax(380px,.85fr); width: min(1050px, calc(100vw - 40px)); min-width: 0; min-height: 610px; overflow: hidden; border: 1px solid #e2ddf3; border-radius: 28px; background: white; box-shadow: 0 30px 80px rgba(45,24,121,.16); }
.auth-visual { position: relative; min-width: 0; overflow: hidden; padding: 48px; background: linear-gradient(145deg,#281477,#7135dc); color: white; }
.auth-visual::after { content: ""; position: absolute; width: 380px; height: 380px; right: -130px; bottom: -160px; border-radius: 50%; background: rgba(255,255,255,.1); }
.auth-visual h1 { max-width: 480px; margin: 80px 0 18px; overflow-wrap: anywhere; font-size: clamp(38px,4vw,48px); line-height: 1.02; }
.auth-visual p { max-width: 480px; font-size: 17px; line-height: 1.7; color: #e8ddff; }
.auth-benefits { display: grid; gap: 12px; margin-top: 35px; }
.auth-benefits span { display: flex; gap: 10px; align-items: center; }
.auth-form { min-width: 0; padding: 50px 42px; }
.auth-form h2 { margin: 32px 0 8px; font-size: 30px; }
.auth-form > p { margin: 0 0 26px; color: var(--muted); line-height: 1.5; }
.field { display: grid; gap: 7px; margin-bottom: 16px; }
.field label { font-size: 12px; font-weight: 800; }
.field input, .field select, .field textarea {
  width: 100%; min-height: 48px; padding: 11px 13px;
  border: 1px solid #dfe1ee; border-radius: 10px; background: #fcfcff; color: var(--ink); outline: 0;
}
.field textarea { min-height: 120px; resize: vertical; }
.field input:focus, .field select:focus, .field textarea:focus { border-color: #8050e4; box-shadow: 0 0 0 4px #eee8ff; }
.field input.invalid { border-color: #e24845; box-shadow: 0 0 0 4px #ffe8e7; }
.field-help { color: #737594; font-size: 11px; line-height: 1.45; }
.form-message { min-height: 24px; margin: 12px 0; font-size: 13px; }
.form-message.error { color: var(--red); }
.form-message.success { color: var(--green); }
.helper { color: var(--muted); font-size: 11px; line-height: 1.55; }

.dashboard-page { min-height: 100vh; background: #fbfcff; }
.dash-shell { display: grid; grid-template-columns: 232px minmax(0,1fr); width: 100%; min-height: 100vh; }
.sidebar {
  position: sticky; top: 0; height: 100vh; overflow-y: auto;
  padding: 20px 14px 16px;
  color: #1b1b3a;
  background: #fff;
  border-right: 1px solid #eaeaf5;
}
.sidebar .pe-brand { margin: 0 0 12px; padding: 4px 8px 16px; border-bottom: 1px dashed #eaeaf5; }
.sidebar .pe-brand strong { font-size: 12.5px; line-height: 1.25; letter-spacing: .3px; }
.sidebar .pe-brand small { color: #6b7194; font-size: 9px; letter-spacing: .45px; }
.side-nav { display: flex; flex-direction: column; gap: 3px; }
.nav-section { padding: 10px 10px 5px; color: #a6a9c7; font-size: 9px; font-weight: 900; letter-spacing: .7px; }
.nav-link {
  display: flex; align-items: center; gap: 12px;
  width: 100%; min-height: 42px; padding: 0 11px;
  border-radius: 12px; background: transparent; color: #6b7194;
  text-align: left; font-size: 12.5px; font-weight: 800;
}
.nav-link > span:nth-child(2) { flex: 1; white-space: nowrap; }
.nav-link em { padding: 2px 8px; border-radius: 999px; color: #ef4444; background: #feecec; font-size: 9px; font-style: normal; font-weight: 900; }
.nav-link:hover { color: #1b1b3a; background: #f7f6fd; }
.nav-link.active { color: #fff; background: linear-gradient(135deg,#8b5cf6,#7c3aed); box-shadow: 0 5px 14px rgba(124,58,237,.3); }
.nav-link.active em { color: #fff; background: rgba(255,255,255,.2); }
.nav-link .nav-icon { display: grid; flex: 0 0 27px; width: 27px; place-items: center; text-align: center; font-size: 0; }
.nav-link .nav-icon .p3d-icon { --p3d-size: 22px; }
.profile-mini { margin-top: 14px; padding: 13px; border: 1px solid #eaeaf5; border-radius: 14px; background: #f8f6ff; }
.profile-mini h4 { margin: 0 0 5px; }
.profile-mini small { color: #6b7194; }
.wallet { display: grid; grid-template-columns: repeat(3,1fr); gap: 7px; margin-top: 12px; }
.wallet div { padding: 9px 4px; border-radius: 10px; background: #fff; text-align: center; font-size: 10px; }
.wallet b { display: block; margin-bottom: 4px; font-size: 14px; }

.dash-main { width: 100%; min-width: 0; padding: 0 22px 30px; }
.dash-top {
  position: sticky; top: 0; z-index: 20;
  display: flex; align-items: center; gap: 14px;
  min-height: 94px; padding: 14px 4px;
  background: rgba(251,252,255,.94); backdrop-filter: blur(14px);
}
.welcome { margin-right: auto; }
.welcome h1 { margin: 0; font-size: 25px; }
.welcome p { margin: 7px 0 0; color: var(--muted); font-size: 13px; }
.mobile-menu { display: none; }
.dash-content { width: 100%; max-width: none; margin: 0; }
.dash-grid { display: grid; width: 100%; grid-template-columns: repeat(12, minmax(0,1fr)); gap: 14px; }
.dash-card {
  padding: 17px;
  border: 1px solid var(--line);
  border-radius: 15px;
  background: white;
  box-shadow: 0 6px 20px rgba(40,38,105,.035);
}
.dash-card h2, .dash-card h3 { margin: 0 0 14px; }
.dash-card h2 { font-size: 17px; }
.dash-card h3 { font-size: 14px; }
.col-3 { grid-column: span 3; } .col-4 { grid-column: span 4; } .col-5 { grid-column: span 5; }
.col-6 { grid-column: span 6; } .col-7 { grid-column: span 7; } .col-8 { grid-column: span 8; } .col-9 { grid-column: span 9; } .col-12 { grid-column: span 12; }
.stat-card { min-height: 145px; }
.big-stat { display: flex; align-items: center; gap: 17px; }
.big-badge { min-width: 80px; width: 80px; height: 80px; display: grid; place-items: center; color: white; background: linear-gradient(145deg,#903efa,#4b1bc5); clip-path: polygon(50% 0,90% 18%,100% 61%,72% 100%,28% 100%,0 61%,10% 18%); font-size: 28px; font-weight: 900; }
.metric { display: flex; justify-content: space-between; gap: 12px; margin: 8px 0; font-size: 12px; }
.metric strong { color: #4020b6; }
.week { display: grid; grid-template-columns: repeat(7,1fr); gap: 7px; text-align: center; }
.day b { display: block; margin-bottom: 8px; font-size: 10px; }
.day span { display: grid; place-items: center; height: 28px; border-radius: 50%; color: white; background: var(--green); font-size: 11px; }
.day.future span { color: #584a9d; background: #fff; border: 1px solid #d8d2ed; }
.mission { color: white; background: linear-gradient(135deg,#7843e7,#4e1bc9); }
.mission .bar { background: rgba(255,255,255,.22); }.mission .bar i { background: #ffc21e; }
.skill-row { display: grid; grid-template-columns: 115px 1fr 35px; gap: 10px; align-items: center; margin: 12px 0; font-size: 12px; }
.skill-row .bar i { background: var(--skill-color,#5a55e9); }
.check-list { display: grid; gap: 10px; margin: 0; padding: 0; list-style: none; font-size: 12px; }
.check-list li::before {
  content: "✓";
  display: inline-grid;
  place-items: center;
  width: 19px;
  height: 19px;
  margin-right: 8px;
  border: 1px solid rgba(255,255,255,.75);
  border-radius: 7px;
  color: white;
  background: radial-gradient(circle at 30% 18%, #b9ffc6, transparent 30%), linear-gradient(145deg,#67da7d,#149143);
  box-shadow: inset 0 1px rgba(255,255,255,.7), inset 0 -3px 5px rgba(0,73,20,.18), 0 3px 6px rgba(19,139,61,.22);
  font-size: 11px;
  font-weight: 900;
}
.check-list.bad li::before { content:"×"; background: radial-gradient(circle at 30% 18%, #ffc3be, transparent 30%), linear-gradient(145deg,#ff7770,#d72f33); box-shadow: inset 0 1px rgba(255,255,255,.7), inset 0 -3px 5px rgba(91,0,0,.18), 0 3px 6px rgba(205,44,48,.2); }
.activity-list, .word-list, .notes-list { display: grid; gap: 8px; }
.activity-item, .word-item, .note-item {
  display: grid; grid-template-columns: auto 1fr auto; gap: 10px; align-items: center;
  min-height: 45px; padding: 8px 10px; border: 1px solid #ececf6; border-radius: 10px; font-size: 12px;
}
.activity-item time { color: var(--muted); font-size: 10px; }
.word-item.learned { background: #f4fff4; border-color: #cfeacf; }
.chip { display: inline-flex; align-items: center; min-height: 25px; padding: 0 9px; border-radius: 999px; background: #f0ebff; color: #5f31d3; font-size: 10px; font-weight: 800; }
.empty { min-height: 170px; display: grid; place-items: center; color: var(--muted); text-align: center; }
.data-table { width: 100%; border-collapse: collapse; font-size: 12px; }
.data-table th, .data-table td { padding: 10px; border-bottom: 1px solid #ececf5; text-align: left; }
.data-table th { color: #66648a; font-size: 10px; text-transform: uppercase; letter-spacing: .05em; }
.form-row { display: grid; grid-template-columns: repeat(2,1fr); gap: 12px; }
.practice-box { min-height: 250px; display: grid; place-items: center; padding: 25px; border: 1px dashed #cfc6ea; border-radius: 14px; background: #faf8ff; text-align: center; }
.practice-box .practice-icon { display: grid; place-items: center; min-height: 84px; font-size: 0; }
.practice-box .practice-icon .p3d-icon { --p3d-size: 76px; }
.timer { font-size: 48px; font-weight: 900; letter-spacing: -.04em; }
.level-progress { display: flex; gap: 8px; align-items: center; }
.tag-cloud { display: flex; flex-wrap: wrap; gap: 8px; }
.tag-cloud button { min-height: 34px; padding: 0 12px; border: 1px solid #e1dcf3; border-radius: 999px; background: #fff; cursor: pointer; }
.tag-cloud button.selected { color: white; background: #6b35dc; border-color: #6b35dc; }

.modal-backdrop {
  position: fixed; inset: 0; z-index: 100;
  display: none; place-items: center; padding: 20px;
  background: rgba(18,15,64,.42); backdrop-filter: blur(5px);
}
.modal-backdrop.open { display: grid; }
.modal { width: min(500px,100%); max-height: 80vh; overflow: auto; padding: 24px; border-radius: 18px; background: #fff; box-shadow: 0 30px 80px rgba(0,0,0,.2); }
.modal-head { display: flex; align-items: center; gap: 12px; margin-bottom: 18px; }
.modal-head h2 { margin: 0; }
.modal-head button { margin-left: auto; }
.toast {
  position: fixed; z-index: 200; right: 20px; bottom: 20px;
  max-width: 380px; padding: 13px 17px; border-radius: 11px;
  color: white; background: #20156a; box-shadow: 0 16px 34px rgba(0,0,0,.2);
  transform: translateY(100px); opacity: 0; transition: .25s ease;
}
.toast.show { transform: translateY(0); opacity: 1; }

.admin-page { max-width: 1300px; margin: 0 auto; padding: 24px; }
.admin-head { display: flex; align-items: center; gap: 15px; margin-bottom: 20px; }
.admin-head .pe-brand { margin-right: auto; }
.code-result { margin-top: 14px; padding: 14px; border-radius: 10px; background: #f1edff; color: #4f20c7; font-size: 22px; font-weight: 900; letter-spacing: .04em; }
.license-admin-table{min-width:1180px}.license-admin-table td{vertical-align:top}.license-code-copy{padding:7px 10px;border:1px solid #cfc3f2;border-radius:8px;color:#4d22c5;background:#f7f3ff;font-weight:900;letter-spacing:.03em;cursor:pointer}.table-note{display:block;margin-top:5px;color:#777895;font-size:9px;line-height:1.35}.table-actions{display:grid;gap:7px}.compact{min-height:32px!important;padding:0 9px!important;font-size:10px}

@media (max-width: 1180px) {
  .pe-topbar { padding-inline: 16px; }
  .pe-brand strong { font-size: 17px; }
  .pe-brand small { font-size: 10px; }
  .pe-header-actions .action-card:nth-child(3) { display: none; }
  .pe-topbar .action-card { padding-inline: 12px; }
  .module-grid { grid-template-columns: repeat(5,1fr); }
  .method { grid-template-columns: repeat(3,1fr); }
  .hero-copy { width: 64%; }
  .hero-art { width: 52%; opacity: .84; }
  .dash-shell { grid-template-columns: 230px minmax(0,1fr); }
  .dash-top .action-card small { display:none; }
}

@media (max-width: 900px) {
  .pe-topbar { position: relative; flex-wrap: wrap; }
  .pe-header-actions { width: 100%; overflow-x: auto; }
  .hero-layout { grid-template-columns: 1fr; }
  .side-stack { grid-template-columns: repeat(2,1fr); }
  .features { grid-template-columns: repeat(2,1fr); }
  .hero-copy { width: 70%; }
  .auth-shell { grid-template-columns: minmax(0,1fr); width: min(560px, calc(100vw - 28px)); }
  .auth-visual { display: none; }
  .dash-shell { display: block; }
  .sidebar { position: fixed; z-index: 90; width: 275px; transform: translateX(-105%); transition: transform .25s ease; }
  .sidebar.open { transform: translateX(0); }
  .dash-main { padding: 0 14px 28px; }
  .mobile-menu { display: grid; }
  .dash-top .action-card { display: none; }
  .col-3, .col-4, .col-5, .col-6, .col-7, .col-8, .col-9 { grid-column: span 12; }
}

@media (max-width: 640px) {
  .landing { width: min(100% - 20px, 1500px); }
  .pe-brand { max-width: calc(100vw - 105px); }
  .pe-brand strong { font-size: 15px; }
  .pe-brand small { display:none; }
  .pe-topbar .action-card { min-width: 120px; padding-inline: 10px; }
  .hero { min-height: 520px; }
  .hero-copy { width: 100%; padding: 28px 20px; }
  .hero-art { width: 100%; height: 48%; opacity: .33; }
  .hero-points { grid-template-columns: 1fr; }
  .side-stack, .features, .method { grid-template-columns: 1fr; }
  .module-grid { grid-template-columns: repeat(2,1fr); }
  .section-head { align-items: flex-start; flex-wrap: wrap; }
  .section-head .secondary { margin-left: 0; }
  .form-row { grid-template-columns: 1fr; }
  .auth-form { padding: 30px 22px; }
  .welcome h1 { font-size: 19px; }
  .dash-top .icon-button:not(.mobile-menu) { display:none; }
  .skill-row { grid-template-columns: 85px 1fr 30px; }
}

/* Premium module grid supplied for the 30-module course. */
.sr-only { position:absolute!important; width:1px!important; height:1px!important; padding:0!important; margin:-1px!important; overflow:hidden!important; clip:rect(0,0,0,0)!important; white-space:nowrap!important; border:0!important; }
.module-card-premium {
  aspect-ratio:var(--cw) / var(--ch);
  min-height:0;
  padding:0;
  overflow:hidden;
  border:1px solid #e0e2ee;
  border-radius:16px;
  background:#fff;
  box-shadow:0 5px 12px rgba(20,27,79,.09);
}
.module-card-premium .module-sprite{position:absolute;z-index:1;left:var(--left);top:var(--top);width:var(--scale);max-width:none;height:auto;pointer-events:none}
.module-card-premium:hover { transform:translateY(-3px); box-shadow:0 12px 25px rgba(42,33,113,.15); }
.module-card-premium.current { border:3px solid #7140e5; box-shadow:0 0 0 5px #eee7ff,0 10px 24px rgba(74,40,170,.14); }
.module-card-premium.complete::after { display:none; }
.premium-course-grid,#module-list { grid-template-columns:repeat(8,minmax(0,1fr))!important; }
.module-poster{position:relative;display:block!important;width:100%;overflow:hidden;border-radius:14px;background:#fff}
.module-poster>img{display:block;width:100%;height:auto}
.module-hotspot{position:absolute;z-index:2;border-radius:14px;outline:0;transition:box-shadow .18s ease,transform .18s ease}
.module-hotspot:hover,.module-hotspot:focus-visible{box-shadow:inset 0 0 0 4px #7340e8,0 7px 18px rgba(72,40,169,.2);transform:scale(.985)}

/* Four connected skill centers. */
.skill-hub{display:grid;gap:18px}.skill-hero{position:relative;display:grid;grid-template-columns:minmax(0,1.45fr) minmax(250px,.55fr);min-height:330px;overflow:hidden;border:1px solid #e5def7;border-radius:22px;background:radial-gradient(circle at 58% 15%,#fff 0,transparent 26%),linear-gradient(135deg,#fff,#f4efff);box-shadow:0 14px 40px rgba(62,41,143,.08)}
.skill-hero-copy{position:relative;z-index:2;max-width:650px;padding:30px}.level-pill{display:inline-flex;padding:7px 13px;border-radius:7px;color:#fff;background:linear-gradient(135deg,#8b48ef,#4e1fd0);font-size:12px;font-weight:900}.skill-hero h1{margin:12px 0;font-size:clamp(35px,4vw,55px);line-height:.98;letter-spacing:-.045em}.skill-hero h1 em{display:block;color:#6d32dc;font-style:normal}.skill-hero-copy>p{max-width:570px;color:#393963;line-height:1.55}.skill-benefits{display:flex;flex-wrap:wrap;gap:18px;margin:20px 0}.skill-benefits span{display:flex;align-items:center;gap:7px;font-size:11px;font-weight:800}.skill-hero-art{position:absolute;z-index:1;right:19%;bottom:-2px;width:42%;height:95%;object-fit:cover;object-position:center;mix-blend-mode:multiply;opacity:.92}
.skill-progress{position:relative;z-index:3;align-self:center;min-height:280px;margin:18px;padding:20px;border:1px solid #ded6f2;border-radius:17px;background:rgba(255,255,255,.92);box-shadow:0 12px 28px rgba(41,29,107,.08)}.skill-progress h3{margin:0 0 12px;color:#4d24c4}.skill-progress .progress-ring{margin:8px auto 15px;background:conic-gradient(#6d35df calc(var(--value)*1%),#e9e1fa 0)}.skill-progress .progress-ring::before{color:#31206e;background:#fff}.skill-progress>div:not(.progress-ring){display:flex;justify-content:space-between;padding:6px 0;font-size:11px}
.skill-modules{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:13px}.skill-modules.seven{grid-template-columns:repeat(7,minmax(0,1fr))}.skill-module-card{display:grid;grid-template-rows:auto 115px auto auto;min-width:0;padding:14px;border:1px solid var(--line);border-radius:16px;background:#fff;box-shadow:0 7px 22px rgba(45,37,108,.045)}.skill-card-title{display:flex;gap:9px;align-items:flex-start;min-height:42px}.skill-card-title>span{display:grid;flex:0 0 31px;height:31px;place-items:center;border-radius:8px;color:#fff;background:linear-gradient(145deg,#8d43f1,#4b1ac8);font-size:11px;font-weight:900}.skill-card-title h3{margin:0;font-size:14px;line-height:1.25}.skill-illustration{display:grid;place-items:center}.skill-illustration .p3d-icon{--p3d-size:82px}.skill-module-card>p{min-height:38px;color:var(--muted);font-size:11px;line-height:1.45}.skill-enter{display:grid;grid-template-columns:auto 1fr auto;gap:7px;align-items:center;min-height:43px;padding:6px 9px;border:1px solid #dcd4f4;border-radius:10px;color:#4c24c7;background:#faf8ff;cursor:pointer;font-size:10px}.skill-enter b{text-align:left}.skill-enter span{font-weight:900}.skill-tools{display:grid;grid-template-columns:repeat(4,1fr);gap:13px}.skill-tools article{display:flex;align-items:center;gap:13px;min-height:115px;padding:16px;border:1px solid var(--line);border-radius:16px;background:linear-gradient(135deg,#fff,#fbf9ff)}.skill-tools h3{margin:0 0 6px;font-size:14px}.skill-tools p{margin:0;color:var(--muted);font-size:11px;line-height:1.5}
.practice-stage{position:relative;scroll-margin-top:105px;padding:22px;overflow:hidden;border:2px solid #7d43e6;border-radius:20px;background:linear-gradient(135deg,#fff,#f8f4ff);box-shadow:0 18px 45px rgba(79,39,178,.14)}.practice-close{position:absolute;z-index:2;top:14px;right:14px;width:36px;height:36px;border:0;border-radius:50%;color:#fff;background:#26136c;cursor:pointer;font-size:24px}.practice-stage-head{display:flex;gap:15px;align-items:center;padding-right:45px;border-bottom:1px solid #e4dcf5;padding-bottom:15px}.practice-stage-head span{color:#6c35dd;font-size:10px;font-weight:900;letter-spacing:.08em}.practice-stage-head h2{margin:4px 0}.practice-stage-head p{margin:0;color:var(--muted);font-size:12px}.xp-pill{margin-left:auto;padding:8px 11px;border-radius:999px;color:#784100;background:#ffe69c}.practice-body{min-height:260px;padding:24px 0}.practice-feedback{padding:13px 16px;border-radius:10px;color:#5b4b85;background:#eee8fa;font-weight:800}.practice-feedback.correct{color:#176f2b;background:#e8f9e9}.practice-feedback.wrong{color:#ae2c2b;background:#ffebea}
.listen-game{display:grid;justify-items:center;gap:14px;text-align:center}.sound-orb{display:grid;place-items:center;width:145px;height:145px;border:0;border-radius:50%;color:#185d31;background:radial-gradient(circle at 32% 22%,#fff,#b7efc3 42%,#56b76a);box-shadow:0 15px 30px rgba(37,153,65,.22);cursor:pointer}.practice-choices{display:flex;flex-wrap:wrap;justify-content:center;gap:12px}.practice-choices button,.word-bank button{min-width:140px;min-height:48px;padding:8px 15px;border:2px solid #ddd4f3;border-radius:12px;background:#fff;cursor:pointer;font-weight:800}.practice-choices button.correct{color:#14742b;border-color:#4abb59;background:#eaffeb}.practice-choices button.wrong{color:#b31f26;border-color:#e94d51;background:#fff0ef}.speak-practice{display:grid;grid-template-columns:1fr 1fr;gap:16px}.model-card,.record-card,.reading-paper,.menu-board,.message-paper{padding:22px;border:1px solid #ddd6ef;border-radius:15px;background:#fff}.model-card p{font-size:20px;line-height:1.6}.record-card{display:grid;justify-items:center;gap:12px;text-align:center}.audio-pulse{animation:pulse 1.5s ease-in-out infinite}@keyframes pulse{50%{transform:scale(1.08);filter:drop-shadow(0 0 13px #8355ed)}}.sentence-board{display:grid;gap:8px;min-height:110px;padding:14px;border:2px dashed #cfc2ef;border-radius:12px;background:#fff}.sentence-board span{padding:9px;border-radius:8px;background:#eee8ff}.word-bank{display:flex;gap:9px;flex-wrap:wrap;margin:14px 0}.routine-list{display:grid;gap:8px}.routine-list button{display:grid;grid-template-columns:70px 1fr auto;gap:12px;align-items:center;padding:12px;border:1px solid #ddd7ee;border-radius:10px;background:#fff;text-align:left;cursor:pointer}.menu-board{width:min(430px,100%);margin:auto;background:#5a321c;color:#fff}.menu-board p{display:flex;justify-content:space-between}

@media(max-width:1180px){.skill-modules.seven{grid-template-columns:repeat(4,minmax(0,1fr))}}
@media(max-width:1180px){.premium-course-grid,#module-list{grid-template-columns:repeat(6,minmax(0,1fr))!important}}
@media(max-width:900px){.premium-course-grid,#module-list{grid-template-columns:repeat(3,minmax(0,1fr))!important}.skill-hero{grid-template-columns:1fr}.skill-hero-art{right:0;width:54%;opacity:.25}.skill-progress{display:grid;grid-template-columns:90px 1fr;gap:5px 15px;align-items:center}.skill-progress h3{grid-column:1/-1}.skill-progress .progress-ring{grid-row:2/6}.skill-modules,.skill-modules.seven,.skill-tools{grid-template-columns:repeat(2,minmax(0,1fr))}}
@media(max-width:640px){.premium-course-grid,#module-list{grid-template-columns:repeat(2,minmax(0,1fr))!important}.skill-hero-copy{padding:22px}.skill-hero h1{font-size:36px}.skill-benefits{display:grid}.skill-progress{margin:12px}.skill-modules,.skill-modules.seven,.skill-tools,.speak-practice{grid-template-columns:1fr}.practice-stage-head{align-items:flex-start}.xp-pill{display:none}}

/* Responsive, functional skill studios */
.studio-hub{gap:14px}
.studio-desktop-reference{display:block}
.studio-mobile-interface{display:none}
.studio-reference{position:relative;width:100%;overflow:hidden;border:1px solid #e3def1;border-radius:18px;background:#fff;box-shadow:0 14px 38px rgba(41,29,107,.09)}
.studio-reference>img{display:block;width:100%;height:auto}
.studio-reference-hotspot{position:absolute;z-index:2;padding:0;border:0;border-radius:13px;background:transparent;cursor:pointer;transition:box-shadow .18s ease,transform .18s ease}
.studio-reference-hotspot:hover,.studio-reference-hotspot:focus-visible{outline:0;box-shadow:inset 0 0 0 4px #7440e8,0 7px 20px rgba(76,39,175,.22);transform:scale(.985)}
@media(min-width:901px){
  .studio-view .dash-top{display:none}
  .studio-view .dash-content{padding-top:14px}
  .full-studio-view .dash-shell{grid-template-columns:1fr}
  .full-studio-view > .dash-shell > .sidebar{display:none}
  .full-studio-view .dash-main,.full-studio-view .dash-content{padding:0}
  .full-studio-view .embedded-studio{border:0;border-radius:0;box-shadow:none}
  .full-studio-view .embedded-studio iframe{height:100vh;min-height:760px}
}
.studio-hero{grid-template-columns:minmax(0,1.55fr) minmax(280px,.62fr);min-height:300px;border-radius:18px}
.studio-hero .skill-hero-copy{max-width:640px;padding:26px 28px}
.studio-hero .skill-hero-art{right:25%;bottom:0;width:34%;height:100%;object-fit:contain;object-position:center bottom;mix-blend-mode:multiply}
.studio-hero .skill-progress{min-height:255px;margin:14px;padding:16px}
.studio-hero .skill-progress .progress-ring{width:100px;height:100px}
.studio-reward{margin-top:7px;padding:8px!important;border-radius:9px;background:linear-gradient(135deg,#f2edff,#fff5d8)}
.studio-section-title{display:flex;align-items:baseline;gap:16px;padding:2px 4px}
.studio-section-title h2{margin:0;color:#16165d;font-size:15px}
.studio-section-title p{margin:0;color:#686886;font-size:11px}
.studio-modules{grid-template-columns:repeat(4,minmax(0,1fr));gap:12px}
.studio-modules.count-7{grid-template-columns:repeat(4,minmax(0,1fr))}
.studio-modules.count-12{grid-template-columns:repeat(4,minmax(0,1fr))}
.studio-module-card{grid-template-rows:auto auto 1fr;min-height:205px;padding:14px;border-radius:13px}
.studio-writing .studio-module-card{min-height:260px}
.studio-speaking .studio-module-card{min-height:235px}
.studio-listening .studio-module-card{min-height:215px}
.studio-module-card .skill-card-title{min-height:38px}
.studio-module-card .skill-card-title h3{font-size:15px;font-weight:900;line-height:1.3}
.studio-module-card>p{min-height:auto;margin:5px 0 12px;color:#25255d;font-size:12px;font-weight:750;line-height:1.5}
.studio-entry{width:100%;min-height:46px;resize:vertical;padding:9px;border:1px solid #dfe1ec;border-radius:8px;color:#141548;background:#fff;font:inherit;font-size:11px;line-height:1.4}
.studio-entry:focus{outline:3px solid #e5dbff;border-color:#7140e5}
.studio-card-actions{display:flex;align-items:center;gap:7px;margin-top:8px;color:#206b2e;font-size:10px}
.studio-card-actions>b{margin-left:auto;white-space:nowrap}
.studio-check,.studio-mic{min-height:34px;border:1px solid #d9cef5;border-radius:8px;color:#4e22c7;background:#f9f7ff;cursor:pointer;font-size:10px;font-weight:900}
.studio-check{padding:7px 10px}
.studio-mic{display:grid;width:36px;place-items:center;border-radius:50%;color:#fff;background:linear-gradient(145deg,#32b972,#16824b)}
.studio-module-card.is-correct{border-color:#39ac56;box-shadow:0 0 0 3px #dff7e5}
.studio-module-card.is-wrong{border-color:#e65a5a;box-shadow:0 0 0 3px #ffe4e4}
.speaking-prompt{padding:7px 9px;border:1px solid #d5e9dc;border-radius:7px;color:#176f46;background:#f4fcf6;font-size:10px}
.studio-audio{display:grid;grid-template-columns:31px 1fr auto;gap:7px;align-items:center;padding:7px;border:1px solid #dfd8f3;border-radius:9px;background:#fff}
.studio-audio>button{display:grid;width:28px;height:28px;padding:0;place-items:center;border:0;border-radius:50%;background:#6d34df;cursor:pointer}
.studio-wave{height:18px;background:repeating-linear-gradient(90deg,#a596d9 0 2px,transparent 2px 5px);mask:linear-gradient(transparent 18%,#000 18% 82%,transparent 82%)}
.speed-chip{width:auto!important;padding:0 7px!important;border:1px solid #d8cff0!important;border-radius:999px!important;color:#4a22ba!important;background:#fff!important;font-size:9px}
.context-suggestions{display:flex;flex-wrap:wrap;gap:7px;margin:10px 0}
.context-suggestions button{padding:7px 10px;border:1px solid #dcd4f4;border-radius:999px;color:#4f26c5;background:#fff;cursor:pointer}

@media(max-width:1180px){
  .studio-modules,.studio-modules.count-7,.studio-modules.count-12{grid-template-columns:repeat(3,minmax(0,1fr))}
  .studio-hero .skill-hero-art{right:28%;width:31%}
}
@media(max-width:900px){
  .studio-desktop-reference{display:none}
  .studio-mobile-interface{display:block}
  .studio-hero{grid-template-columns:1fr;min-height:auto}
  .studio-hero .skill-hero-copy{min-height:300px;padding-right:34%}
  .studio-hero .skill-hero-art{right:1%;top:4%;bottom:auto;width:35%;height:285px;opacity:.92}
  .studio-hero .skill-progress{display:grid;grid-template-columns:100px 1fr;min-height:0;margin:10px}
  .studio-modules,.studio-modules.count-7,.studio-modules.count-12{grid-template-columns:repeat(2,minmax(0,1fr))}
}
@media(max-width:640px){
  .studio-hub{gap:12px}
  .studio-hero{border-radius:14px}
  .studio-hero .skill-hero-copy{min-height:0;padding:20px 18px 190px}
  .studio-hero .skill-hero-copy h1{max-width:100%;font-size:34px}
  .studio-hero .skill-hero-copy>p{font-size:14px}
  .studio-hero .skill-hero-art{right:50%;top:auto;bottom:125px;width:210px;height:210px;transform:translateX(50%);opacity:.9}
  .studio-hero .skill-progress{grid-template-columns:78px 1fr;margin:8px;padding:13px}
  .studio-hero .skill-progress .progress-ring{width:76px;height:76px}
  .studio-section-title{display:block}
  .studio-section-title p{margin-top:3px}
  .studio-modules,.studio-modules.count-7,.studio-modules.count-12{grid-template-columns:1fr}
  .studio-module-card,.studio-writing .studio-module-card,.studio-speaking .studio-module-card,.studio-listening .studio-module-card{display:block;min-height:0;padding:14px}
  .studio-module-card .skill-card-title{grid-column:1/-1}
  .studio-module-card>p{font-size:13px}
  .studio-module-card>.studio-entry,.studio-module-card>.speaking-prompt,.studio-module-card>.studio-audio{grid-column:1/-1}
  .studio-module-card>.studio-card-actions{grid-column:1/-1}
  .skill-tools{grid-template-columns:1fr}
  .practice-stage{padding:15px}
  .practice-body{padding:16px 0}
}

/* 2026-07-26: authoritative sidebar and touch-size layer. */
@media(min-width:901px){
  .dashboard-page.course-sidebar-view>.dash-shell{
    display:grid!important;
    grid-template-columns:286px minmax(0,1fr)!important;
  }
  .dashboard-page.course-sidebar-view>.dash-shell>.sidebar{
    display:block!important;
    visibility:visible!important;
    width:286px!important;
    transform:none!important;
  }
}
.sidebar{padding:22px 17px 18px}
.sidebar .pe-brand strong{font-size:15px;line-height:1.25}
.sidebar .pe-brand small{font-size:10.5px}
.nav-section{padding:14px 11px 6px;font-size:10.5px}
.nav-link{min-height:50px;padding:0 13px;border-radius:14px;font-size:14px}
.nav-link .nav-icon{flex-basis:33px;width:33px}
.nav-link .nav-icon .p3d-icon{--p3d-size:28px}
.profile-mini{position:relative;min-height:112px;margin-top:18px;padding:14px;text-align:center;overflow:hidden}
.sidebar-mascot{position:relative;left:auto;top:auto;width:88px;height:82px;margin:-3px auto 5px;overflow:hidden;border:0;border-radius:0;background:transparent;filter:drop-shadow(0 10px 13px rgba(58,32,139,.2));pointer-events:none;transform:none}
.sidebar-mascot img{width:100%;height:100%;object-fit:contain;object-position:center bottom}
.profile-mini h4{font-size:15px}
.wallet{grid-column:1/-1;margin-left:-70px}
.wallet div{font-size:11px}
.wallet b{font-size:15px}
.embedded-studio{border-radius:18px}
.embedded-studio iframe{min-height:1080px}

@media(max-width:900px){
  .dashboard-page>.dash-shell{display:block!important}
  .dashboard-page>.dash-shell>.sidebar{
    display:block!important;
    width:min(88vw,320px)!important;
    transform:translateX(-105%)!important;
  }
  .dashboard-page>.dash-shell>.sidebar.open{transform:translateX(0)!important}
  .dash-main{padding:0 12px 24px}
  .dash-top{display:flex!important;min-height:72px;padding:9px 0;gap:8px}
  .mobile-menu{display:grid!important;flex:0 0 48px;width:48px;height:48px}
  .welcome h1{font-size:19px}
  .welcome p{display:none}
  .dash-top .action-card{display:none}
  .embedded-studio iframe{min-height:1200px}
}
@media(max-width:640px){
  .dash-main{padding-inline:8px}
  .embedded-studio{border:0;border-radius:0;box-shadow:none}
  .embedded-studio iframe{min-height:1400px}
}
