/* NGSL-specific layout. Shared controls/buttons live in ../shared/common.css */
.main-content { width: min(1500px, calc(100% - 32px)); margin: 16px auto 40px; }
.table-wrap { overflow: auto; border: 1px solid #e2e8f0; border-radius: 14px; background: #fff; box-shadow: 0 4px 18px rgba(15,23,42,.045); }
.word-table { width: 100%; border-collapse: collapse; table-layout: fixed; }
.word-table thead { background: #edf2f9; color: #334155; }
.word-table th { padding: 12px 11px; border-bottom: 1px solid #dbe3ee; text-align: left; font-size: calc(12px * var(--voca-scale)); font-weight: 850; white-space: nowrap; }
.word-table td { padding: 13px 11px; border-bottom: 1px solid #edf1f6; vertical-align: middle; }
.word-table tbody tr:last-child td { border-bottom: 0; }
.word-table tbody tr:hover { background: #f8fbff; }
.word-table th:nth-child(1), .word-table td:nth-child(1) { width: 94px; }
.word-table th:nth-child(2), .word-table td:nth-child(2) { width: 27%; }
.word-table th:nth-child(3), .word-table td:nth-child(3) { width: 34%; }
.word-table th:nth-child(4), .word-table td:nth-child(4) { width: 310px; }
.word-table th:nth-child(5), .word-table td:nth-child(5) { width: 54px; text-align: center; }
.rank-marker { display: inline-flex; align-items: center; gap: 6px; white-space: nowrap; }
.tier-badge { width: 22px; height: 22px; flex: 0 0 22px; display: inline-flex; align-items: center; justify-content: center; border-radius: 6px; color: #fff; font-size: 11px; font-weight: 900; }
.tier-badge.tier-1 { background: #2563eb; }
.tier-badge.tier-2 { background: #059669; }
.tier-badge.tier-3 { background: #d97706; }
.tier-badge.tier-4 { background: #7c3aed; }
.tier-badge.tier-5 { background: #ea580c; }
.tier-badge.tier-6 { background: #db2777; }
.rank-number { color: #475569; font-size: calc(12px * var(--voca-scale)); font-weight: 850; font-variant-numeric: tabular-nums; }
.word-info-cell { min-width: 0; }
.word-main { color: #172554; font-size: calc(22px * var(--voca-scale)); font-weight: 850; line-height: 1.18; letter-spacing: -.025em; overflow-wrap: anywhere; }
.word-subline { display: flex; flex-wrap: wrap; align-items: baseline; gap: 5px; margin-top: 5px; color: #64748b; font-size: calc(14px * var(--voca-scale)); line-height: 1.4; overflow-wrap: anywhere; }
.subline-label { color: #94a3b8; font-size: calc(10px * var(--voca-scale)); font-weight: 800; }
.forms-cell { color: #475569; font-weight: 600; }
.meaning-main { color: #1e293b; font-size: calc(17px * var(--voca-scale)); font-weight: 750; line-height: 1.45; overflow-wrap: anywhere; }
.english-def { margin-top: 4px; color: #64748b; font-size: calc(14px * var(--voca-scale)); line-height: 1.5; overflow-wrap: anywhere; }
.tools-cell { white-space: nowrap; }
.check-box { width: 24px; height: 24px; }
.checked-row .word-main { color: #b91c1c; }
@media (max-width: 1050px) {
  .word-table th:nth-child(2), .word-table td:nth-child(2) { width: 24%; }
  .word-table th:nth-child(3), .word-table td:nth-child(3) { width: 30%; }
  .word-table th:nth-child(4), .word-table td:nth-child(4) { width: 290px; }
  .action-button, .audio-btn, .dict-link, .voca-art-trigger { min-width: 0; }
}
@media (max-width: 760px) {
  .main-content { width: calc(100% - 20px); margin-top: 10px; }
  .table-wrap { overflow: visible; border: 0; background: transparent; box-shadow: none; }
  .word-table, .word-table tbody { display: block; width: 100%; }
  .word-table thead { display: none; }
  .word-table tbody tr {
    display: grid;
    grid-template-columns: auto minmax(0,1fr) auto;
    grid-template-areas: "rank word check" "meaning meaning meaning" "tools tools tools";
    gap: 9px 10px;
    align-items: start;
    margin-bottom: 9px;
    padding: 13px 12px;
    border: 1px solid #e2e8f0;
    border-radius: 13px;
    background: #fff;
    box-shadow: 0 2px 8px rgba(15,23,42,.045);
  }
  .word-table td { display: block; width: auto !important; padding: 0; border: 0; min-width: 0; }
  .word-table td:nth-child(1) { grid-area: rank; }
  .word-table td:nth-child(2) { grid-area: word; }
  .word-table td:nth-child(3) { grid-area: meaning; }
  .word-table td:nth-child(4) { grid-area: tools; }
  .word-table td:nth-child(5) { grid-area: check; justify-self: end; }
  .rank-marker { gap: 5px; }
  .tier-badge { width: 21px; height: 21px; flex-basis: 21px; }
  .word-main { font-size: calc(22px * var(--voca-scale)); }
  .word-subline { margin-top: 4px; font-size: calc(14px * var(--voca-scale)); }
  .meaning-main { font-size: calc(16px * var(--voca-scale)); }
  .english-def { font-size: calc(13px * var(--voca-scale)); }
  .tools-cell { padding-top: 1px !important; }
  .action-group { flex-wrap: nowrap; gap: 7px; }
}
