/* ============================================
   LESSON 22 — SPECIFIC STYLES
   Persuading & Suggesting
   ============================================ */

/* ── Part 1: Options legend ── */
.l22-legend {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 8px 20px;
  margin-bottom: 20px;
  padding: 14px 16px;
  background: var(--bg-card-2);
  border: 1.5px solid var(--border);
  border-radius: var(--radius);
}
@media (max-width: 500px) { .l22-legend { grid-template-columns: 1fr; } }

.l22-legend-row {
  display: flex;
  align-items: center;
  gap: 10px;
}
.l22-legend-letter {
  width: 26px;
  height: 26px;
  border-radius: 50%;
  background: var(--bg-card);
  border: 1.5px solid var(--gold);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1rem;
  font-weight: 800;
  color: var(--gold);
  flex-shrink: 0;
}
.l22-legend-text {
  font-size: .97rem;
  color: var(--text-muted);
}

/* ── Part 1: Table ── */
.l22-p1-table {
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin-bottom: 8px;
}
.l22-p1-header {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
  padding: 0 14px 4px;
  font-size: 1rem;
  font-weight: 800;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: .06em;
}
.l22-p1-row {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 10px;
  align-items: center;
  padding: 10px 14px;
  background: var(--bg-card-2);
  border: 1.5px solid var(--border);
  border-radius: var(--radius);
}
.l22-p1-section {
  display: flex;
  align-items: center;
  gap: 10px;
}
.l22-p1-num {
  width: 24px;
  height: 24px;
  border-radius: 50%;
  background: var(--bg-card);
  border: 1.5px solid var(--border);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1rem;
  font-weight: 800;
  color: var(--gold);
  flex-shrink: 0;
}
.l22-p1-label {
  font-size: 1rem;
  font-weight: 600;
  color: var(--text);
}

/* ── Shared select wrapper ── */
.l22-sel-wrap {
  border: 2px solid var(--border);
  border-radius: 8px;
  overflow: hidden;
  transition: border-color .18s, background .18s;
}
.l22-sel-wrap.l22-correct { border-color: var(--success); background: rgba(74,222,128,.07); }
.l22-sel-wrap.l22-wrong   { border-color: var(--error);   background: rgba(248,113,113,.07); }

.l22-select {
  width: 100%;
  padding: 8px 12px;
  background: transparent;
  color: var(--text);
  font-size: .97rem;
  font-family: inherit;
  font-weight: 600;
  border: none;
  outline: none;
  cursor: pointer;
  appearance: none;
  -webkit-appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath d='M1 1l5 5 5-5' stroke='%23888' stroke-width='1.5' fill='none' stroke-linecap='round'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 10px center;
  padding-right: 28px;
}
.l22-select:disabled { cursor: not-allowed; opacity: .8; }
.l22-select option   { background: var(--bg-card); color: var(--text); }

/* ── Part 2: Synonym rows ── */
.l22-p2-list {
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin-bottom: 8px;
}
.l22-p2-row {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}
.l22-p2-num {
  width: 24px;
  height: 24px;
  border-radius: 50%;
  background: var(--bg-card);
  border: 1.5px solid var(--border);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1rem;
  font-weight: 800;
  color: var(--gold);
  flex-shrink: 0;
}
.l22-p2-label {
  font-size: 1rem;
  font-weight: 600;
  color: var(--text);
  min-width: 140px;
}
.l22-p2-eq {
  color: var(--gold);
  font-weight: 700;
  font-size: 1rem;
}
.l22-p2-inp {
  flex: 1;
  min-width: 160px;
  padding: 8px 13px;
  background: var(--bg-card);
  border: 1.5px solid var(--border);
  border-radius: 8px;
  color: var(--text);
  font-size: 1rem;
  font-family: inherit;
  font-weight: 500;
  outline: none;
  transition: border-color .15s, background .15s;
}
.l22-p2-inp:focus       { border-color: var(--gold); }
.l22-p2-inp.l22-correct { border-color: var(--success); background: rgba(74,222,128,.07); color: var(--success); }
.l22-p2-inp.l22-wrong   { border-color: var(--error);   background: rgba(248,113,113,.07); }

/* ── Part 1 row right side (dropdown + script btn) ── */
.l22-p1-row-right {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}

/* ── Part 2 inline explanation panels ── */
.l22-p2-exp {
  margin: 3px 0 8px 0;
  padding: 9px 14px;
  border-radius: var(--radius);
  font-size: .97rem;
  line-height: 1.7;
  border: 1px solid var(--border);
}
.l22-p2-exp-ok  { background: rgba(72,199,116,.08); border-color: var(--success); }
.l22-p2-exp-err { background: rgba(255,100,100,.07); border-color: var(--error); }

/* ── Part 1 inline explanation panels ── */
.l22-p1-exp {
  margin: 4px 0 10px 0;
  padding: 12px 16px;
  border-radius: var(--radius);
  font-size: .97rem;
  line-height: 1.8;
  border: 1px solid var(--border);
}
.l22-p1-exp-ok  { background: rgba(72,199,116,.08); border-color: var(--success); }
.l22-p1-exp-err { background: rgba(255,100,100,.07); border-color: var(--error); }

/* ── Explanation ── */
.l22-exp-list { display: flex; flex-direction: column; gap: 8px; }
.l22-exp-row {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 14px;
  background: var(--bg-card-2);
  border: 1.5px solid var(--border);
  border-radius: var(--radius);
  flex-wrap: wrap;
}
.l22-exp-left  { font-weight: 700; color: var(--text); font-size: 1rem; }
.l22-exp-arrow { color: var(--gold); font-size: .97rem; }
.l22-exp-right { color: var(--text-muted); font-size: 1rem; }

/* ── Study Tip ── */
.l22-tip-box { display: flex; flex-direction: column; gap: 14px; }
.l22-tip-item {
  display: flex;
  gap: 14px;
  align-items: flex-start;
  padding: 14px 16px;
  background: var(--bg-card-2);
  border: 1.5px solid var(--border);
  border-radius: var(--radius);
}
.l22-tip-icon  { font-size: 1.2rem; flex-shrink: 0; margin-top: 1px; }
.l22-tip-title { font-weight: 700; color: var(--gold); margin-bottom: 4px; font-size: 1rem; }
.l22-tip-body  { color: var(--text-muted); font-size: .97rem; line-height: 1.55; margin: 0; }

.l22-phrase-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 8px;
}
.l22-chip {
  padding: 5px 12px;
  border-radius: 14px;
  font-size: .8rem;
  font-weight: 600;
  border: 1.5px solid rgba(201,168,76,.3);
  background: rgba(201,168,76,.07);
  color: var(--gold);
  font-style: italic;
}

/* ── Shake animation ── */
@keyframes l22-shake {
  0%,100% { transform: translateX(0); }
  20%     { transform: translateX(-6px); }
  40%     { transform: translateX(6px); }
  60%     { transform: translateX(-4px); }
  80%     { transform: translateX(4px); }
}
.l22-shake { animation: l22-shake .4s ease; }
