* { box-sizing: border-box; margin: 0; padding: 0; }

    body {
      font-family: Inter, 'Segoe UI', ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, sans-serif;
      background: #f4f0e8;
      color: #172033;
      min-height: 100vh;
    }

    button, input, select { font: inherit; }
    button { cursor: pointer; }

    /* ─── HEADER ─── */
    .site-header {
      position: sticky;
      top: 0;
      z-index: 10;
      display: flex;
      align-items: center;
      justify-content: space-between;
      gap: 16px;
      padding: 16px clamp(18px, 4vw, 56px);
      border-bottom: 1px solid #ded6c8;
      background: rgba(244, 240, 232, 0.94);
      backdrop-filter: blur(12px);
    }

    .brand-button {
      border: 0;
      background: transparent;
      color: #172033;
      padding: 0;
      text-align: left;
      font-size: 1.05rem;
      font-weight: 800;
    }

    .brand-tagline {
      display: block;
      margin-top: 2px;
      color: #5d6472;
      font-size: 0.72rem;
      font-weight: 750;
    }

    .header-actions {
      display: flex;
      align-items: center;
      justify-content: flex-end;
      gap: 10px;
      flex-wrap: wrap;
    }

    .top-link {
      padding: 8px 10px;
      border-radius: 8px;
      color: #172033;
      text-decoration: none;
      font-size: 0.86rem;
      font-weight: 800;
    }

    .top-link:hover {
      background: rgba(33, 93, 91, 0.08);
      color: #215d5b;
    }

    .header-search {
      display: flex;
      align-items: center;
      gap: 6px;
    }

    .header-search input,
    .header-select {
      min-height: 38px;
      border: 1px solid #c7bdad;
      border-radius: 8px;
      color: #172033;
      background: #fffaf2;
      font-size: 0.86rem;
      font-weight: 700;
    }

    .header-search input {
      width: min(230px, 28vw);
      padding: 0 11px;
    }

    .header-select {
      max-width: 180px;
      padding: 0 8px;
    }

    .back-btn {
      display: none;
      align-items: center;
      gap: 8px;
      padding: 8px 16px;
      border: 1px solid #b9ad9c;
      border-radius: 8px;
      background: transparent;
      color: #172033;
      font-weight: 700;
      font-size: 0.88rem;
      transition: background 0.15s;
    }
    .back-btn:hover { background: rgba(42, 31, 20, 0.05); }
    .back-btn.visible { display: inline-flex; }

    /* ─── STATS BAR ─── */
    .stats-bar {
      background: rgba(138, 63, 43, 0.08);
      color: #8a3f2b;
      padding: 8px 20px;
      text-align: center;
      font-size: 0.84rem;
      font-weight: 700;
      letter-spacing: 0.02em;
    }

    .site-footer {
      padding: 28px clamp(18px, 4vw, 56px);
      border-top: 1px solid #ded6c8;
      background: #fffaf2;
      color: #5d6472;
      text-align: center;
      line-height: 1.6;
    }

    .site-footer strong {
      display: block;
      color: #172033;
      font-size: 1rem;
    }

    /* ─── CONTAINER ─── */
    .container {
      max-width: 1200px;
      margin: 0 auto;
      padding: 36px clamp(18px, 4vw, 48px) 64px;
    }

    .app-layout {
      display: grid;
      grid-template-columns: 220px minmax(0, 1fr);
      gap: 28px;
      align-items: start;
    }

    .side-nav {
      position: sticky;
      top: 88px;
      display: grid;
      gap: 10px;
      padding: 14px;
      border: 1px solid #d7cebf;
      border-radius: 8px;
      background: #fffaf2;
      box-shadow: 0 6px 20px rgba(42, 31, 20, 0.06);
    }

    .side-nav-title {
      margin-bottom: 4px;
      color: #8a3f2b;
      font-size: 0.78rem;
      font-weight: 850;
      text-transform: uppercase;
      letter-spacing: 0.04em;
    }

    .side-nav a {
      padding: 10px 12px;
      border: 1px solid transparent;
      border-radius: 8px;
      color: #172033;
      text-decoration: none;
      font-size: 0.9rem;
      font-weight: 800;
    }

    .side-nav a:hover,
    .side-nav a.active {
      border-color: #b9ad9c;
      background: rgba(33, 93, 91, 0.08);
      color: #215d5b;
    }

    #practice-view,
    #writing-practice-view,
    #passages-view,
    #business-practice-view,
    #search-view,
    #resources-view,
    #roadmap-view,
    #placeholder-view {
      display: none;
    }

    /* ─── HOME INTRO ─── */
    .intro {
      max-width: 780px;
      margin-bottom: 36px;
    }

    .eyebrow {
      margin: 0 0 10px;
      color: #8a3f2b;
      font-size: 0.82rem;
      font-weight: 800;
      text-transform: uppercase;
      letter-spacing: 0.05em;
    }

    h1 {
      font-size: clamp(2rem, 5vw, 3.5rem);
      line-height: 1.05;
      margin-bottom: 14px;
    }

    .intro-desc {
      color: #5d6472;
      font-size: 1.05rem;
      line-height: 1.65;
    }

    /* ─── CATEGORY SECTIONS ─── */
    .category-section { margin-bottom: 44px; }

    .category-header {
      display: flex;
      align-items: center;
      gap: 10px;
      margin-bottom: 14px;
      padding-bottom: 10px;
      border-bottom: 3px solid;
    }
    .category-header h2 { font-size: 1.1rem; font-weight: 800; }

    /* ─── TOPIC GRID ─── */
    .topic-grid {
      display: grid;
      grid-template-columns: repeat(auto-fill, minmax(190px, 1fr));
      gap: 14px;
    }

    .topic-card {
      background: #fffaf2;
      border: 1px solid #d7cebf;
      border-left: 5px solid;
      border-radius: 8px;
      padding: 20px 18px;
      cursor: pointer;
      text-decoration: none;
      display: block;
      color: #172033;
      box-shadow: 0 6px 20px rgba(42, 31, 20, 0.06);
      transition: transform 0.18s, box-shadow 0.18s;
    }
    .topic-card:hover, .topic-card:focus-visible {
      transform: translateY(-3px);
      box-shadow: 0 14px 36px rgba(42, 31, 20, 0.11);
      outline: none;
    }

    .topic-card-title {
      font-size: 1.05rem;
      font-weight: 800;
      color: #215d5b;
      margin-bottom: 6px;
    }
    .topic-card-count { font-size: 0.8rem; color: #5d6472; }
    .topic-card-arrow {
      display: block;
      margin-top: 12px;
      font-size: 0.8rem;
      font-weight: 700;
    }

    .word-of-day {
      margin-bottom: 28px;
      padding: 22px;
      border: 1px solid #d7cebf;
      border-left: 6px solid #8a3f2b;
      border-radius: 8px;
      background: #fffaf2;
      box-shadow: 0 6px 20px rgba(42, 31, 20, 0.06);
    }

    .word-of-day h2 {
      margin-bottom: 8px;
      color: #215d5b;
      font-size: 1.65rem;
    }

    .platform-grid {
      display: grid;
      grid-template-columns: repeat(auto-fit, minmax(210px, 1fr));
      gap: 14px;
      margin-bottom: 30px;
    }

    .platform-card {
      padding: 18px;
      border: 1px solid #d7cebf;
      border-radius: 8px;
      background: #fffaf2;
      box-shadow: 0 6px 20px rgba(42, 31, 20, 0.05);
    }

    .platform-card h2 {
      margin-bottom: 8px;
      color: #215d5b;
      font-size: 1.12rem;
    }

    .platform-card p {
      color: #5d6472;
      line-height: 1.5;
    }

    .platform-card.active-tool {
      border-left: 6px solid #215d5b;
    }

    .start-panel,
    .learning-paths {
      margin-bottom: 30px;
    }

    .start-panel {
      padding: 22px;
      border: 1px solid #d7cebf;
      border-left: 6px solid #215d5b;
      border-radius: 8px;
      background: #fffaf2;
      box-shadow: 0 6px 20px rgba(42, 31, 20, 0.06);
    }

    .start-panel h2,
    .section-heading h2 {
      margin-bottom: 14px;
      color: #215d5b;
      font-size: 1.28rem;
    }

    .start-grid,
    .path-grid {
      display: grid;
      grid-template-columns: repeat(auto-fit, minmax(190px, 1fr));
      gap: 12px;
    }

    .start-card,
    .path-card {
      display: grid;
      gap: 8px;
      min-height: 138px;
      padding: 16px;
      border: 1px solid #d7cebf;
      border-radius: 8px;
      background: white;
      color: #172033;
      text-decoration: none;
      box-shadow: 0 5px 16px rgba(42, 31, 20, 0.045);
      transition: transform 0.18s, box-shadow 0.18s;
    }

    .start-card:hover,
    .start-card:focus-visible,
    .path-card:hover,
    .path-card:focus-visible {
      transform: translateY(-2px);
      box-shadow: 0 12px 28px rgba(42, 31, 20, 0.1);
      outline: none;
    }

    .step-number {
      display: inline-flex;
      align-items: center;
      justify-content: center;
      width: 28px;
      height: 28px;
      border-radius: 999px;
      background: rgba(138, 63, 43, 0.12);
      color: #8a3f2b;
      font-weight: 850;
    }

    .start-card strong,
    .path-card h3 {
      color: #172033;
      font-size: 1rem;
      line-height: 1.25;
    }

    .start-card span:last-child,
    .path-card p {
      color: #5d6472;
      line-height: 1.45;
    }

    .roadmap-grid {
      display: grid;
      grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
      gap: 14px;
      margin-bottom: 24px;
    }

    .roadmap-card,
    .feedback-panel {
      padding: 20px;
      border: 1px solid #d7cebf;
      border-radius: 8px;
      background: #fffaf2;
      box-shadow: 0 6px 20px rgba(42, 31, 20, 0.05);
    }

    .roadmap-card h2,
    .feedback-panel h2 {
      margin-bottom: 12px;
      color: #215d5b;
      font-size: 1.08rem;
    }

    .roadmap-card ul {
      display: grid;
      gap: 8px;
      padding-left: 20px;
      color: #3d4351;
      line-height: 1.45;
    }

    .feedback-panel {
      margin-top: 10px;
    }

    .feedback-panel p {
      color: #5d6472;
      line-height: 1.6;
    }

    .resource-section {
      margin-bottom: 42px;
      padding-top: 8px;
    }

    .resource-landing-grid {
      display: grid;
      grid-template-columns: repeat(2, minmax(0, 1fr));
      gap: 16px;
      margin-bottom: 34px;
    }

    .resource-landing-card {
      display: block;
      min-height: 220px;
      padding: 24px;
      border: 1px solid #d7cebf;
      border-left: 6px solid #215d5b;
      border-radius: 8px;
      background: #fffaf2;
      color: #172033;
      text-decoration: none;
      box-shadow: 0 6px 20px rgba(42, 31, 20, 0.06);
      transition: transform 0.18s, box-shadow 0.18s;
    }

    .resource-landing-card:hover,
    .resource-landing-card:focus-visible {
      transform: translateY(-3px);
      box-shadow: 0 14px 36px rgba(42, 31, 20, 0.11);
      outline: none;
    }

    .resource-landing-card h2 {
      margin-bottom: 10px;
      color: #215d5b;
      font-size: 1.35rem;
    }

    .resource-landing-card p:not(.eyebrow) {
      color: #5d6472;
      line-height: 1.6;
    }

    .resource-section-header {
      max-width: 820px;
      margin-bottom: 16px;
      padding-bottom: 12px;
      border-bottom: 3px solid rgba(33, 93, 91, 0.18);
    }

    .resource-section-header h2 {
      margin-bottom: 8px;
      color: #215d5b;
      font-size: 1.45rem;
    }

    .resource-section-header p {
      color: #5d6472;
      line-height: 1.6;
    }

    .resource-grid {
      display: grid;
      grid-template-columns: repeat(2, minmax(0, 1fr));
      gap: 12px;
    }

    .resource-card {
      min-height: 142px;
      padding: 16px;
      border: 1px solid #d7cebf;
      border-radius: 8px;
      background: #fffaf2;
      box-shadow: 0 5px 16px rgba(42, 31, 20, 0.045);
    }

    .resource-card-topline {
      display: flex;
      align-items: flex-start;
      justify-content: space-between;
      gap: 10px;
      margin-bottom: 8px;
    }

    .resource-card h3 {
      color: #172033;
      font-size: 0.98rem;
      line-height: 1.25;
    }

    .resource-card p {
      color: #5d6472;
      font-size: 0.94rem;
      line-height: 1.5;
    }

    .resource-card .meta-chip {
      flex: 0 0 auto;
      white-space: nowrap;
      font-size: 0.7rem;
    }

    .worksheet-grid {
      display: grid;
      gap: 18px;
    }

    .worksheet-card {
      padding: 22px;
      border: 1px solid #d7cebf;
      border-radius: 8px;
      background: #fffaf2;
      box-shadow: 0 10px 24px rgba(42, 31, 20, 0.07);
    }

    .worksheet-header {
      display: flex;
      align-items: flex-start;
      justify-content: space-between;
      gap: 16px;
      margin-bottom: 16px;
      padding-bottom: 14px;
      border-bottom: 2px solid rgba(33, 93, 91, 0.16);
    }

    .worksheet-header h2 {
      color: #215d5b;
      font-size: 1.35rem;
      line-height: 1.2;
    }

    .worksheet-subtitle {
      margin-top: 4px;
      color: #5d6472;
      font-size: 0.95rem;
    }

    .worksheet-version {
      display: inline-flex;
      margin-top: 10px;
      padding: 5px 9px;
      border-radius: 999px;
      background: rgba(138, 63, 43, 0.1);
      color: #8a3f2b;
      font-size: 0.76rem;
      font-weight: 850;
    }

    .answer-key-actions {
      display: flex;
      align-items: center;
      flex-wrap: wrap;
      justify-content: flex-end;
      gap: 8px;
    }

    .teacher-version {
      margin-top: 0;
      background: rgba(33, 93, 91, 0.1);
      color: #215d5b;
    }

    .worksheet-section {
      margin-top: 16px;
    }

    .worksheet-section-header {
      display: flex;
      align-items: center;
      justify-content: space-between;
      gap: 12px;
      margin-bottom: 8px;
    }

    .worksheet-section-header h3 {
      color: #172033;
      font-size: 1rem;
    }

    .answer-key-toggle {
      padding: 7px 10px;
      border: 1px solid #b9ad9c;
      border-radius: 6px;
      background: #f2efe7;
      color: #215d5b;
      cursor: pointer;
      font-size: 0.82rem;
      font-weight: 800;
    }

    .answer-key-toggle:hover,
    .answer-key-toggle:focus-visible {
      border-color: #215d5b;
      background: rgba(33, 93, 91, 0.08);
      outline: none;
    }

    .worksheet-answer-key {
      padding: 14px;
      border: 1px solid rgba(33, 93, 91, 0.18);
      border-radius: 8px;
      background: rgba(33, 93, 91, 0.05);
    }

    .worksheet-answer-key.is-collapsed .answer-key-content {
      display: none;
    }

    .worksheet-table {
      width: 100%;
      margin-top: 8px;
      border-collapse: collapse;
      background: #fffdfa;
    }

    .worksheet-table th,
    .worksheet-table td {
      padding: 8px;
      border: 1px solid #d7cebf;
      text-align: left;
      vertical-align: top;
    }

    .worksheet-table th {
      color: #215d5b;
      background: rgba(33, 93, 91, 0.08);
      font-size: 0.82rem;
      text-transform: uppercase;
      letter-spacing: 0.04em;
    }

    .worksheet-list {
      margin: 8px 0 0 20px;
      color: #30394b;
      line-height: 1.6;
    }

    .worksheet-choices {
      display: flex;
      flex-wrap: wrap;
      gap: 8px;
      margin-top: 8px;
    }

    .worksheet-choices span {
      padding: 6px 8px;
      border: 1px solid #d7cebf;
      border-radius: 6px;
      background: #fffdfa;
      color: #30394b;
      font-size: 0.92rem;
    }

    .contact-note {
      margin-top: 14px;
      font-size: 0.88rem;
    }

    .meta-row {
      display: flex;
      flex-wrap: wrap;
      gap: 8px;
      margin: 10px 0 14px;
    }

    .meta-chip {
      display: inline-flex;
      align-items: center;
      min-height: 26px;
      padding: 4px 9px;
      border-radius: 999px;
      background: rgba(33, 93, 91, 0.1);
      color: #215d5b;
      font-size: 0.75rem;
      font-weight: 850;
    }

    .meta-chip.level {
      background: rgba(138, 63, 43, 0.1);
      color: #8a3f2b;
    }

    /* ─── TOPIC VIEW ─── */
    #topic-view { display: none; }

    .topic-header-box {
      margin-bottom: 24px;
      padding: 22px 24px;
      background: #fffaf2;
      border-radius: 8px;
      border-left: 6px solid;
      box-shadow: 0 6px 20px rgba(42, 31, 20, 0.06);
      display: flex;
      justify-content: space-between;
      align-items: center;
      flex-wrap: wrap;
      gap: 12px;
    }

    .topic-header-box h2 {
      font-size: 1.6rem;
      font-weight: 800;
      color: #215d5b;
      margin-bottom: 4px;
    }

    .topic-meta { color: #5d6472; font-size: 0.88rem; }

    .topic-header-actions {
      display: flex;
      align-items: center;
      flex-wrap: wrap;
      gap: 10px;
    }

    .category-badge {
      padding: 5px 14px;
      border-radius: 20px;
      font-size: 0.8rem;
      font-weight: 700;
      color: white;
    }

    .quiz-panel {
      display: none;
      margin-bottom: 18px;
      padding: 22px;
      border: 1px solid #d7cebf;
      border-radius: 8px;
      background: #fffaf2;
      box-shadow: 0 4px 12px rgba(42, 31, 20, 0.05);
    }

    .quiz-panel.visible {
      display: block;
    }

    .quiz-topline {
      display: flex;
      align-items: center;
      justify-content: space-between;
      gap: 12px;
      margin-bottom: 14px;
      color: #5d6472;
      font-size: 0.86rem;
      font-weight: 800;
    }

    .quiz-question {
      margin-bottom: 16px;
      color: #172033;
      font-size: 1.18rem;
      font-weight: 850;
      line-height: 1.35;
    }

    .quiz-options {
      display: grid;
      grid-template-columns: repeat(auto-fit, minmax(190px, 1fr));
      gap: 10px;
      margin-bottom: 14px;
    }

    .quiz-option {
      min-height: 48px;
      padding: 10px 12px;
      border: 1px solid #b9ad9c;
      border-radius: 8px;
      background: white;
      color: #172033;
      text-align: left;
      font-weight: 800;
    }

    .quiz-option.correct {
      border-color: #215d5b;
      background: #e8f7ef;
      color: #215d5b;
    }

    .quiz-option.incorrect {
      border-color: #b94a35;
      background: #fff0ec;
      color: #8a3f2b;
    }

    .quiz-feedback {
      min-height: 22px;
      color: #40495a;
      font-weight: 800;
      line-height: 1.4;
    }

    .quiz-actions {
      display: flex;
      flex-wrap: wrap;
      gap: 10px;
      margin-top: 16px;
    }

    .practice-panel,
    .passage-card {
      margin-bottom: 18px;
      padding: 22px;
      border: 1px solid #d7cebf;
      border-radius: 8px;
      background: #fffaf2;
      box-shadow: 0 4px 12px rgba(42, 31, 20, 0.05);
    }

    .passage-group {
      margin-bottom: 34px;
    }

    .passage-purpose {
      margin: 10px 0;
      color: #5d6472;
      font-size: 0.92rem;
      font-weight: 750;
      line-height: 1.45;
    }

    .practice-controls {
      display: flex;
      flex-wrap: wrap;
      gap: 10px;
      margin: 18px 0;
    }

    .practice-word-list {
      display: grid;
      grid-template-columns: repeat(auto-fit, minmax(190px, 1fr));
      gap: 10px;
      margin-top: 16px;
    }

    .writing-practice-list {
      display: grid;
      gap: 12px;
      margin-top: 16px;
    }

    .writing-blank-card {
      padding: 16px;
      border: 1px solid #d7cebf;
      border-radius: 8px;
      background: white;
    }

    .writing-blank-card h2 {
      margin-top: 12px;
      color: #215d5b;
      font-size: 1.2rem;
    }

    .cloze-card {
      padding: 20px;
    }

    .blank-sentence {
      margin: 12px 0 8px;
      color: #172033;
      font-size: 1.08rem;
      font-weight: 850;
      line-height: 1.55;
    }

    .blank-hint {
      margin-bottom: 10px;
      color: #5d6472;
      line-height: 1.45;
    }

    .writing-blank-input {
      width: 100%;
      min-height: 42px;
      padding: 0 12px;
      border: 1px solid #c7bdad;
      border-radius: 8px;
      color: #172033;
      background: #fffaf2;
      outline: none;
    }

    .writing-blank-input:focus { border-color: #8a3f2b; }
    .writing-blank-input.correct {
      border-color: #059669;
      background: #e8f7ef;
    }
    .writing-blank-input.incorrect {
      border-color: #b94a35;
      background: #fff0ec;
    }

    .word-bank {
      display: flex;
      flex-wrap: wrap;
      gap: 8px;
      margin: 14px 0;
    }

    .word-bank span {
      padding: 5px 10px;
      border-radius: 999px;
      background: rgba(33, 93, 91, 0.1);
      color: #215d5b;
      font-size: 0.82rem;
      font-weight: 850;
    }

    .cloze-passage {
      color: #30394b;
      font-size: 1rem;
      line-height: 2.2;
    }

    .cloze-input {
      width: min(170px, 100%);
      min-height: 34px;
      margin: 0 4px;
      padding: 0 10px;
      vertical-align: baseline;
      font-weight: 800;
    }

    .mini-word {
      padding: 12px;
      border: 1px solid #d7cebf;
      border-radius: 8px;
      background: white;
    }

    .mini-word > strong {
      display: block;
      margin-bottom: 6px;
      color: #215d5b;
    }

    .mini-word p {
      margin-top: 8px;
      color: #30394b;
      line-height: 1.4;
    }

    .passage-text {
      margin: 12px 0 18px;
      color: #30394b;
      line-height: 1.7;
    }

    .passage-question {
      margin-top: 14px;
      padding-top: 14px;
      border-top: 1px solid #e8e0d0;
    }

    .passage-question p {
      margin-bottom: 10px;
      font-weight: 800;
    }

    .passage-answer-label {
      display: grid;
      gap: 6px;
      margin: 10px 0;
      color: #40495a;
      font-size: 0.85rem;
      font-weight: 800;
    }

    .passage-answer-input {
      width: 100%;
      min-height: 92px;
      resize: vertical;
      padding: 12px 14px;
      border: 1px solid #c7bdad;
      border-radius: 8px;
      color: #172033;
      background: #fffaf2;
      line-height: 1.5;
      outline: none;
    }

    .passage-answer-input:focus { border-color: #8a3f2b; }

    .passage-feedback {
      display: grid;
      gap: 6px;
      margin-top: 10px;
      padding: 10px 12px;
      border-radius: 8px;
      background: rgba(33, 93, 91, 0.08);
      color: #30394b;
      font-weight: 650;
      line-height: 1.45;
    }

    .passage-feedback:empty { display: none; }
    .passage-feedback.correct { background: rgba(5, 150, 105, 0.12); }
    .passage-feedback.review { background: rgba(217, 119, 6, 0.12); }
    .passage-feedback.empty { background: rgba(138, 63, 43, 0.1); }

    .passage-feedback span {
      display: block;
      font-weight: 650;
    }

    /* ─── SEARCH ROW ─── */
    .search-row {
      display: flex;
      gap: 12px;
      align-items: flex-end;
      margin-bottom: 24px;
    }

    .search-label {
      flex: 1;
      display: grid;
      gap: 6px;
      color: #40495a;
      font-size: 0.85rem;
      font-weight: 700;
    }

    .search-input {
      width: 100%;
      min-height: 44px;
      padding: 0 14px;
      border: 1px solid #c7bdad;
      border-radius: 8px;
      font-size: 0.95rem;
      color: #172033;
      background: #fffaf2;
      outline: none;
      transition: border-color 0.15s;
    }
    .search-input:focus { border-color: #8a3f2b; }

    .word-count-badge {
      background: rgba(138, 63, 43, 0.1);
      color: #8a3f2b;
      padding: 6px 14px;
      border-radius: 20px;
      font-size: 0.82rem;
      font-weight: 700;
      white-space: nowrap;
      align-self: flex-end;
    }

    .study-toolbar {
      display: grid;
      grid-template-columns: minmax(220px, 1fr) auto;
      gap: 14px;
      align-items: center;
      margin-bottom: 18px;
      padding: 16px;
      border: 1px solid #d7cebf;
      border-radius: 8px;
      background: #fffaf2;
      box-shadow: 0 4px 12px rgba(42, 31, 20, 0.05);
    }

    .progress-label {
      display: flex;
      justify-content: space-between;
      gap: 12px;
      margin-bottom: 8px;
      color: #40495a;
      font-size: 0.86rem;
      font-weight: 800;
    }

    .progress-track {
      height: 10px;
      overflow: hidden;
      border-radius: 999px;
      background: #e7dfd1;
    }

    .progress-fill {
      width: 0%;
      height: 100%;
      border-radius: inherit;
      background: #215d5b;
      transition: width 0.2s ease;
    }

    .toolbar-actions {
      display: flex;
      flex-wrap: wrap;
      gap: 10px;
      justify-content: flex-end;
    }

    .study-button,
    .word-action {
      display: inline-flex;
      align-items: center;
      justify-content: center;
      min-height: 38px;
      padding: 0 13px;
      border: 1px solid #b9ad9c;
      border-radius: 8px;
      background: transparent;
      color: #172033;
      text-decoration: none;
      font-size: 0.85rem;
      font-weight: 800;
    }

    .study-button.active,
    .word-action.learned {
      border-color: #215d5b;
      background: #215d5b;
      color: white;
    }

    /* ─── WORDS GRID ─── */
    .words-grid {
      display: grid;
      grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
      gap: 16px;
    }

    .word-card {
      padding: 22px;
      background: #fffaf2;
      border: 1px solid #d7cebf;
      border-radius: 8px;
      box-shadow: 0 4px 12px rgba(42, 31, 20, 0.05);
    }

    .word-card.learned-card {
      border-color: rgba(33, 93, 91, 0.45);
      background: #f5fff9;
    }

    .word-title-row {
      display: flex;
      align-items: flex-start;
      justify-content: space-between;
      gap: 12px;
      margin-bottom: 16px;
      padding-bottom: 10px;
      border-bottom: 1px solid #e8e0d0;
    }

    .word-card h3 {
      font-size: 1.15rem;
      font-weight: 800;
      color: #215d5b;
      margin-bottom: 0;
    }

    .learned-pill {
      padding: 4px 9px;
      border-radius: 999px;
      background: rgba(33, 93, 91, 0.1);
      color: #215d5b;
      font-size: 0.72rem;
      font-weight: 850;
      white-space: nowrap;
    }

    dl { display: grid; gap: 12px; margin: 0; }

    dt {
      margin-bottom: 3px;
      color: #8a3f2b;
      font-size: 0.76rem;
      font-weight: 800;
      text-transform: uppercase;
      letter-spacing: 0.04em;
    }

    dd { margin: 0; color: #30394b; line-height: 1.55; font-size: 0.9rem; }

    .flashcard-answer.is-hidden {
      display: none;
    }

    .flashcard-prompt {
      margin-bottom: 14px;
      color: #5d6472;
      font-size: 0.92rem;
      line-height: 1.45;
    }

    .word-actions {
      display: flex;
      flex-wrap: wrap;
      gap: 8px;
      margin-top: 18px;
    }

    /* ─── EMPTY STATE ─── */
    .empty-state {
      grid-column: 1 / -1;
      padding: 36px;
      border: 1px dashed #b9ad9c;
      border-radius: 8px;
      text-align: center;
      color: #5d6472;
      background: rgba(255, 250, 242, 0.6);
    }

    /* ─── RESPONSIVE ─── */
    @media (max-width: 760px) {
      .site-header { flex-direction: column; align-items: flex-start; }
      .header-actions { width: 100%; justify-content: stretch; }
      .header-search { width: 100%; }
      .header-search input { width: 100%; }
      .header-select { max-width: none; width: 100%; }
      .top-link { flex: 1; text-align: center; }
      .back-btn.visible { width: 100%; justify-content: center; }
      .app-layout { grid-template-columns: 1fr; }
      .side-nav { position: static; }
      .search-row { flex-direction: column; align-items: stretch; }
      .study-toolbar { grid-template-columns: 1fr; }
      .toolbar-actions { justify-content: stretch; }
      .study-button { flex: 1; }
      .quiz-topline { flex-direction: column; align-items: flex-start; }
      .word-count-badge { text-align: center; }
      .resource-landing-grid { grid-template-columns: 1fr; }
      .resource-grid { grid-template-columns: 1fr; }
    }

    @media (max-width: 480px) {
      .topic-grid { grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); }
      .words-grid { grid-template-columns: 1fr; }
    }

    @media print {
      body {
        background: #ffffff;
        color: #111827;
      }

      .site-header,
      .side-nav,
      .back-btn,
      .intro,
      .word-actions,
      .print-worksheet-button,
      .answer-key-toggle,
      .site-footer {
        display: none !important;
      }

      .container,
      .shell,
      .app-layout {
        display: block;
        width: 100%;
        max-width: none;
        margin: 0;
        padding: 0;
      }

      .worksheet-grid {
        display: block;
      }

      .worksheet-card {
        margin: 0 0 24px;
        padding: 0;
        border: 0;
        border-radius: 0;
        background: #ffffff;
        box-shadow: none;
        break-inside: avoid;
        page-break-inside: avoid;
      }

      body[data-print-worksheet] .worksheet-card {
        display: none;
      }

      body[data-print-worksheet] .worksheet-card.is-print-target {
        display: block;
      }

      .worksheet-header {
        border-bottom-color: #444444;
      }

      .worksheet-answer-key {
        padding: 0;
        border: 0;
        background: #ffffff;
      }

      .worksheet-answer-key.is-collapsed .answer-key-content {
        display: block;
      }

      .worksheet-table th,
      .worksheet-table td,
      .worksheet-choices span {
        border-color: #666666;
      }

      .worksheet-table th {
        color: #111827;
        background: #eeeeee;
      }
    }
