.home-intro { padding-bottom: 64px; }
.welcome-card { transform: rotate(1.5deg); }
.welcome-strokes { display: flex; align-items: center; gap: 7px; height: 40px; margin: 20px 0 2px; }
.welcome-strokes span { display: block; width: 27%; height: 5px; border-radius: 99px; background: var(--yellow); transform: rotate(-4deg); }
.welcome-strokes span:nth-child(2) { width: 42%; background: rgba(255,255,255,0.6); transform: rotate(4deg); }
.welcome-strokes span:nth-child(3) { width: 20%; background: var(--orange); transform: rotate(-2deg); }
.category-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; padding: 30px 0 6px; }
.category-card { position: relative; min-height: 214px; display: flex; flex-direction: column; align-items: flex-start; justify-content: space-between; padding: 20px 21px 18px; border: 1px solid var(--line); border-radius: 2px 24px 2px 24px; background: var(--white); color: var(--ink); text-align: left; box-shadow: 0 13px 32px rgba(36,55,49,0.05); overflow: hidden; transition: transform 220ms ease, box-shadow 220ms ease, border-color 220ms ease; }
.category-card::after { position: absolute; right: -25px; bottom: -42px; width: 140px; height: 140px; border-radius: 50%; background: var(--green-soft); content: ''; opacity: 0.7; transition: transform 220ms ease; }
.category-card:hover { border-color: var(--green); box-shadow: var(--shadow); transform: translateY(-5px); }
.category-card:hover::after { transform: scale(1.15); }
.category-card-2 { background: var(--green); color: var(--white); border-color: var(--green); border-radius: 28px 2px 28px 2px; }
.category-card-2::after { background: rgba(243,201,93,0.22); }
.category-card-3 { border-radius: 28px 2px 28px 2px; background: #faf1df; }
.category-card-3::after { background: rgba(239,108,74,0.16); }
.category-card-4 { background: #fff2c7; border-radius: 2px 28px 2px 28px; }
.category-card-4::after { background: rgba(39,102,91,0.14); }
.category-card-gestures { background: #e9f1ee; border-color: #8db8aa; border-radius: 24px 2px 24px 2px; }
.category-card-gestures::after { background: rgba(39,102,91,0.18); }
.category-card-gestures .category-card-kicker, .category-card-gestures .category-card-arrow { color: var(--green); }
.category-number { position: relative; z-index: 1; color: var(--orange); font-size: 12px; font-weight: 900; letter-spacing: 0.1em; }
.category-card-2 .category-number { color: var(--yellow); }
.category-card-content { position: relative; z-index: 1; display: flex; flex-direction: column; gap: 8px; max-width: 205px; }
.category-card-kicker { margin-bottom: 4px; color: var(--orange); font-size: 9px; font-weight: 900; letter-spacing: 0.14em; }
.category-card-2 .category-card-kicker { color: var(--yellow); }
.category-card-content strong { font-size: clamp(22px, 2.8vw, 29px); line-height: 1; letter-spacing: -0.06em; }
.category-card-content > span:last-child { color: var(--muted); font-size: 12px; line-height: 1.45; }
.category-card-2 .category-card-content > span:last-child { color: rgba(255,255,255,0.68); }
.category-card-arrow { position: relative; z-index: 1; align-self: flex-end; color: var(--green); font-size: 24px; line-height: 1; }
.category-card-2 .category-card-arrow { color: var(--yellow); }
.category-card-meta { position: relative; z-index: 1; color: var(--muted); font-size: 10px; font-weight: 800; letter-spacing: 0.08em; text-transform: uppercase; }
.category-card-2 .category-card-meta { color: rgba(255,255,255,0.65); }
.lesson-view { padding-top: 24px; }
.back-button { display: inline-flex; align-items: center; gap: 8px; margin: 0 0 23px; padding: 0; border: 0; background: transparent; color: var(--muted); font-size: 12px; font-weight: 800; }
.back-button span { color: var(--orange); font-size: 20px; transition: transform 180ms ease; }
.back-button:hover { color: var(--ink); }
.back-button:hover span { transform: translateX(-3px); }
.loading-card { padding: 42px 0; color: var(--muted); font-size: 14px; }
.app-error { margin: 32px 0 0; padding: 15px 18px; border-left: 3px solid var(--orange); background: #fbe4dc; color: var(--ink); font-size: 13px; line-height: 1.45; }
.profession-view { padding-top: 24px; }
.profession-hero { display: flex; align-items: end; justify-content: space-between; gap: 28px; padding: 52px 0 58px; }
.profession-hero h1 { margin-bottom: 20px; font-size: clamp(42px, 6vw, 72px); }
.profession-hero-mark { width: 76px; height: 76px; display: grid; place-items: center; border-radius: 26px 6px 26px 6px; background: var(--green); color: var(--yellow); font-size: 36px; transform: rotate(6deg); box-shadow: var(--shadow); }
.profession-menu { margin-top: 6px; }
.profession-option-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; padding: 30px 0 10px; }
.profession-option { position: relative; min-height: 280px; display: flex; flex-direction: column; align-items: flex-start; justify-content: space-between; padding: 24px; border: 1px solid var(--line); border-radius: 3px 28px 3px 28px; background: var(--white); color: var(--ink); text-align: left; overflow: hidden; box-shadow: 0 13px 32px rgba(36,55,49,0.05); transition: transform 220ms ease, box-shadow 220ms ease, border-color 220ms ease; }
.profession-option::after { position: absolute; right: -34px; bottom: -44px; width: 150px; height: 150px; border-radius: 50%; background: var(--green-soft); content: ''; opacity: .78; transition: transform 220ms ease; }
.profession-option:hover { border-color: var(--green); box-shadow: var(--shadow); transform: translateY(-5px); }
.profession-option:hover::after { transform: scale(1.15); }
.profession-option-quiz { background: var(--green); color: var(--white); border-color: var(--green); border-radius: 28px 3px 28px 3px; }
.profession-option-quiz::after { background: rgba(243,201,93,.22); }
.profession-option-phrases { background: #fff2c7; }
.profession-option-phrases::after { background: rgba(239,108,74,.15); }
.profession-option-mission { background: #edf5f1; border-color: #b7d1c6; }
.profession-option-mission::after { background: rgba(39,102,91,.14); }
.profession-option-back { min-height: 150px; background: var(--paper-deep); }
.profession-option-back::after { background: rgba(239,108,74,.12); }
.profession-option-back .profession-option-icon { background: var(--white); color: var(--green); }
.profession-signals-panel { grid-column: 1 / -1; display: flex; align-items: center; gap: 18px; padding: 22px 24px; border: 1px dashed rgba(39,102,91,.3); border-radius: 3px 22px 3px 22px; background: rgba(255,253,248,.7); color: var(--muted); }
.profession-signals-panel h3 { margin: 3px 0 5px; color: var(--green); font-size: 25px; }
.profession-signals-panel p:last-child { margin: 0; font-size: 13px; line-height: 1.45; }
.profession-option-icon, .profession-option-copy, .profession-option-meta, .profession-option-arrow { position: relative; z-index: 1; }
.profession-option-icon { width: 54px; height: 54px; display: grid; place-items: center; border-radius: 16px 4px 16px 4px; background: var(--yellow); color: var(--ink); font-size: 28px; }
.profession-option-quiz .profession-option-icon { background: rgba(255,255,255,.16); }
.profession-option-copy { display: flex; flex-direction: column; gap: 8px; max-width: 225px; }
.profession-option-copy .category-card-kicker { margin-bottom: 0; }
.profession-option-quiz .category-card-kicker { color: var(--yellow); }
.profession-option-copy strong { font-size: 27px; line-height: 1; letter-spacing: -.06em; }
.profession-option-copy > span:last-child { color: var(--muted); font-size: 13px; line-height: 1.45; }
.profession-option-quiz .profession-option-copy > span:last-child { color: rgba(255,255,255,.7); }
.profession-option-meta { color: var(--muted); font-size: 10px; font-weight: 850; letter-spacing: .08em; text-transform: uppercase; }
.profession-option-quiz .profession-option-meta { color: rgba(255,255,255,.68); }
.profession-option-arrow { align-self: flex-end; color: var(--green); font-size: 25px; line-height: 1; }
.profession-option-quiz .profession-option-arrow { color: var(--yellow); }
.mission-shell { max-width: 790px; margin: 22px auto 0; border: 1px solid var(--line); border-radius: 3px 26px 3px 26px; background: var(--white); box-shadow: var(--shadow); overflow: hidden; }
.mission-header { display: flex; align-items: center; gap: 15px; padding: 23px 25px; border-bottom: 1px solid var(--line); background: #f8f5ef; }
.mission-header .eyebrow { margin-bottom: 5px; }
.mission-header h2 { font-size: 24px; }
.mission-scenario { margin: 5px 0 0; color: var(--muted); font-size: 13px; line-height: 1.4; }
.mission-header > div:last-child { min-width: 0; flex: 1; }
.mission-progress { height: 5px; margin-top: 12px; overflow: hidden; border-radius: 99px; background: rgba(39,102,91,.12); }
.mission-progress span { display: block; height: 100%; border-radius: inherit; background: var(--green); transition: width 240ms ease; }
.mission-avatar { width: 45px; height: 45px; display: grid; place-items: center; border-radius: 50%; background: var(--green); color: var(--yellow); font-size: 22px; }
.mission-chat { min-height: 320px; display: flex; flex-direction: column; gap: 12px; padding: 28px 24px; background: #e8f0ec; }
.mission-empty { align-self: center; margin: auto; max-width: 330px; padding: 25px 24px; border: 1px solid rgba(39,102,91,.14); border-radius: 4px 19px 4px 19px; background: var(--white); text-align: center; box-shadow: 0 10px 24px rgba(36,55,49,.07); }
.mission-empty-icon { width: 44px; height: 44px; display: grid; place-items: center; margin: 0 auto 12px; border-radius: 50%; background: var(--yellow); color: var(--green); font-size: 24px; }
.mission-empty strong { display: block; color: var(--ink); font-size: 17px; }
.mission-empty p { margin: 8px 0 0; color: var(--muted); font-size: 13px; line-height: 1.45; }
.mission-bubble { position: relative; display: flex; flex-wrap: wrap; align-items: center; gap: 5px 8px; max-width: 82%; padding: 11px 13px; border: 1px solid rgba(39,102,91,.12); box-shadow: 0 5px 13px rgba(36,55,49,.05); font-size: 16px; line-height: 1.4; }
.mission-bubble-keeper { align-self: flex-start; border-radius: 4px 17px 17px 17px; background: var(--white); color: var(--ink); }
.mission-bubble-user { align-self: flex-end; border-radius: 17px 4px 17px 17px; background: var(--green); color: var(--white); }
.mission-bubble-label { width: 100%; color: var(--muted); font-size: 10px; font-weight: 900; letter-spacing: .08em; text-transform: uppercase; }
.mission-bubble-user .mission-bubble-label { color: rgba(255,255,255,.68); }
.mission-bubble .speak-button { width: 23px; height: 23px; border-color: currentColor; color: inherit; }
.mission-choice-panel { align-self: stretch; margin-top: 5px; padding: 14px; border: 1px dashed rgba(39,102,91,.24); border-radius: 12px; background: rgba(255,253,248,.55); }
.mission-choice-heading { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.mission-choice-heading strong { color: var(--orange); font-size: 15px; }
.mission-choice-prompt { margin: 0 0 10px; color: var(--green); font-size: 11px; font-weight: 900; letter-spacing: .1em; text-transform: uppercase; }
.mission-timer-track { height: 4px; margin: -3px 0 12px; overflow: hidden; border-radius: 99px; background: rgba(210,139,91,.18); }
.mission-timer-track span { display: block; height: 100%; width: 100%; border-radius: inherit; background: var(--orange); transition: width 1s linear; }
.mission-options { display: flex; flex-direction: column; gap: 8px; }
.mission-option-row { display: flex; align-items: center; gap: 7px; }
.mission-option-button { min-width: 0; flex: 1; display: flex; align-items: center; gap: 9px; padding: 11px 12px; border: 1px solid var(--line); border-radius: 9px; background: var(--white); color: var(--ink); text-align: left; font-size: 15px; line-height: 1.35; transition: border-color 180ms ease, transform 180ms ease, box-shadow 180ms ease; }
.mission-option-button:hover { border-color: var(--green); box-shadow: 0 5px 13px rgba(36,55,49,.08); transform: translateY(-1px); }
.mission-option-row > .speak-button { width: 28px; height: 28px; }
.mission-option-letter { color: var(--orange); font-weight: 900; }
.mission-complete { align-self: center; display: flex; flex-direction: column; align-items: center; gap: 8px; margin-top: 8px; padding: 18px 20px; border-radius: 12px; background: var(--white); text-align: center; }
.mission-complete strong { color: var(--green); font-size: 17px; }
.mission-complete span { color: var(--muted); font-size: 13px; }
.mission-complete .secondary-button { margin-top: 5px; }
.mission-timeout strong { color: var(--orange); }
.profession-empty { max-width: 650px; margin: 42px auto; padding: 46px; border: 1px solid var(--line); border-radius: 3px 28px 3px 28px; background: var(--white); box-shadow: var(--shadow); text-align: center; }
.profession-empty-icon { display: grid; place-items: center; width: 64px; height: 64px; margin: 0 auto 18px; border-radius: 50%; background: var(--green-soft); font-size: 30px; }
.profession-empty h2 { margin-bottom: 16px; font-size: 35px; }
.profession-empty p:not(.eyebrow) { max-width: 420px; margin: 0 auto 24px; color: var(--muted); font-size: 14px; line-height: 1.55; }
.phrase-card .card-title { max-width: 640px; }
.phrase-card .phrase-title,
.phrase-card .phrase-title .audio-phrase { color: var(--green); }
.phrase-context { margin: 24px 0 0; padding: 20px 22px; border-left: 4px solid var(--yellow); background: #fff8dd; color: var(--muted); font-size: 18px; line-height: 1.55; }
.phrase-context strong { color: var(--ink); }
.grammar-note { display: flex; flex-direction: column; gap: 7px; }
.grammar-note > .grammar-note-heading { color: var(--green); }
.grammar-note > span:not(.grammar-note-heading) { color: var(--ink); }
.grammar-note > span strong { color: var(--green); font-weight: 900; }
.grammar-note .grammar-pos { font-weight: 950; }
.grammar-note .grammar-pos-verb { color: #c4777d; }
.grammar-note .grammar-pos-noun { color: #6d8fb5; }
.grammar-note .grammar-pos-adjective { color: #927faf; }
.grammar-note .grammar-pos-function { color: var(--green); }
.grammar-note .grammar-pos-pronoun { color: #d28b5b; }
.grammar-note .grammar-pos-other { color: var(--green); }
.phrase-card .translation-title { display: flex; align-items: center; gap: 8px; }
.phrase-highlight { font-weight: 900; text-decoration-line: underline; text-decoration-thickness: 2px; text-underline-offset: 3px; }
.card-title .phrase-pos-verb { color: #c94b52; }
.card-title .phrase-pos-noun { color: #2f6fba; }
.card-title .phrase-pos-adjective { color: #8051a8; }
.card-title .phrase-pos-other { color: var(--ink); }
.gesture-card { position: relative; }
.gesture-card .card-copy { width: 100%; }
.gesture-card .card-kicker { color: var(--green); }
.gesture-command { max-width: 720px; display: flex; align-items: center; gap: 10px; }
.gesture-inline-icon { display: inline-grid; place-items: center; width: 34px; height: 34px; flex: 0 0 auto; border: 1px solid rgba(243, 201, 93, 0.9); border-radius: 9px; background: #fff8dd; font-size: 23px; line-height: 1; letter-spacing: 0; }
.gesture-inline-image { width: 34px; height: 34px; flex: 0 0 auto; border: 1px solid #c8d9d2; border-radius: 9px; background: #edf5f1; object-fit: cover; }
.gesture-description { grid-column: 2 / -1; width: auto; margin-top: 24px; padding: 16px 18px; border-left: 4px solid var(--yellow); background: #fff8dd; color: var(--muted); font-size: 18px; line-height: 1.5; }
.gesture-description strong { color: var(--ink); }
.admin-gesture-icon { margin-right: 10px; font-size: 30px; vertical-align: middle; }

@media (max-width: 850px) {
  .category-grid { gap: 12px; }
  .category-card { min-height: 190px; }
  .category-card-content strong { font-size: 24px; }
  .category-card::after { right: 40px; bottom: -74px; }
  .lesson-view { padding-top: 12px; }
  .profession-option-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
  .profession-option { min-height: 220px; }
}

@media (max-width: 600px) {
  .home-intro { padding-bottom: 48px; }
  .category-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; padding-top: 27px; }
  .category-card { min-height: 168px; padding: 14px 13px 13px; border-radius: 2px 18px 2px 18px; }
  .category-card-content { max-width: 100%; gap: 5px; }
  .category-card-content strong { font-size: 18px; line-height: 1.05; letter-spacing: -0.045em; }
  .category-card-content > span:last-child { font-size: 10px; line-height: 1.25; display: -webkit-box; display: box; line-clamp: 2; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
  .category-number { font-size: 10px; }
  .category-card-meta { font-size: 8px; letter-spacing: .04em; }
  .category-card-arrow { font-size: 19px; }
  .profession-hero { padding: 40px 0 42px; }
  .profession-hero-mark { width: 58px; height: 58px; font-size: 28px; }
  .profession-option { min-height: 180px; padding: 15px; }
  .profession-option-icon { width: 44px; height: 44px; font-size: 24px; }
  .profession-option-copy { gap: 5px; }
  .profession-option-copy strong { font-size: 20px; }
  .profession-option-copy > span:last-child { font-size: 11px; line-height: 1.3; }
  .profession-option-meta { font-size: 8px; }
  .profession-option-arrow { font-size: 20px; }
  .mission-header { padding: 19px; }
  .mission-chat { min-height: 280px; padding: 24px 15px; }
  .mission-bubble { max-width: 94%; font-size: 15px; }
  .profession-empty { padding: 32px 22px; }
  .gesture-inline-icon { width: 31px; height: 31px; font-size: 21px; }
  .gesture-inline-image { width: 31px; height: 31px; }
  .gesture-description { font-size: 17px; }
}
