/* Sprint 16 — 玖衍·英汉军语词典 */
:root {
  --mt-bg: #0a0e14;
  --mt-panel: #121a24;
  --mt-border: #2a3f5f;
  --mt-accent: #b388ff;
  --mt-accent2: #7ad8ff;
  --mt-gold: #ffd166;
  --mt-muted: #78909c;
}

.mt-main {
  position: relative;
  z-index: 1;
  max-width: 1200px;
  width: 100%;
  margin: 0 auto;
  padding: 28px 24px 48px;
  flex: 1;
}

.mt-hero {
  text-align: center;
  margin-bottom: 28px;
}

.mt-hero h1 {
  margin: 0 0 8px;
  font-size: clamp(22px, 3.5vw, 30px);
  color: var(--mt-accent);
  letter-spacing: 0.04em;
}

.mt-hero p {
  margin: 0;
  color: var(--mt-muted);
  font-size: 14px;
  line-height: 1.6;
}

.mt-stats {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  justify-content: center;
  margin-top: 16px;
}

.mt-stat {
  background: rgba(13, 27, 42, 0.7);
  border: 1px solid var(--mt-border);
  border-radius: 8px;
  padding: 8px 16px;
  font-size: 12px;
  color: var(--mt-muted);
}

.mt-stat strong {
  color: var(--mt-gold);
  font-size: 16px;
  margin-right: 6px;
}

.mt-search-bar {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  align-items: center;
  padding: 14px 16px;
  background: linear-gradient(135deg, rgba(26, 35, 50, 0.95), rgba(13, 27, 42, 0.9));
  border: 1px solid #5e35b1;
  border-radius: 10px;
  margin-bottom: 16px;
}

.mt-search-bar input[type="search"] {
  flex: 1;
  min-width: 200px;
  padding: 10px 14px;
  border-radius: 8px;
  border: 1px solid var(--mt-border);
  background: #0d1b2a;
  color: #e8eaed;
  font-size: 14px;
}

.mt-search-bar select {
  padding: 9px 12px;
  border-radius: 8px;
  border: 1px solid var(--mt-border);
  background: #0d1b2a;
  color: #e8eaed;
  font-size: 13px;
}

.mt-alpha {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-bottom: 16px;
}

.mt-alpha button {
  min-width: 32px;
  padding: 6px 8px;
  border-radius: 6px;
  border: 1px solid var(--mt-border);
  background: #0d1b2a;
  color: #90a4ae;
  cursor: pointer;
  font-size: 12px;
  font-weight: 600;
}

.mt-alpha button:hover,
.mt-alpha button.active {
  border-color: var(--mt-accent);
  color: var(--mt-accent);
  background: rgba(94, 53, 177, 0.25);
}

.mt-table-wrap {
  background: var(--mt-panel);
  border: 1px solid var(--mt-border);
  border-radius: 10px;
  overflow: hidden;
}

.mt-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 13px;
}

.mt-table th,
.mt-table td {
  border-bottom: 1px solid var(--mt-border);
  padding: 10px 14px;
  text-align: left;
  vertical-align: top;
}

.mt-table th {
  background: #0d1b2a;
  color: var(--mt-accent2);
  font-weight: 600;
  position: sticky;
  top: 0;
  z-index: 1;
}

.mt-table tbody tr:hover {
  background: rgba(122, 216, 255, 0.05);
}

.mt-table tbody tr:nth-child(even) {
  background: rgba(13, 27, 42, 0.35);
}

.mt-en {
  color: #e8eaed;
  font-weight: 500;
}

.mt-zh {
  color: #ce93d8;
}

.mt-abbr {
  display: inline-block;
  font-size: 11px;
  background: #311b92;
  color: #d1c4e9;
  padding: 2px 8px;
  border-radius: 999px;
  border: 1px solid #5e35b1;
}

.mt-tag {
  display: inline-block;
  font-size: 10px;
  padding: 2px 8px;
  border-radius: 999px;
  margin-right: 4px;
}

.mt-tag-domain { background: #1a237e; color: #9fa8da; }
.mt-tag-type { background: #1b4332; color: #95d5b2; }
.mt-tag-sea { background: #1a3a5c; color: #7ad8ff; }
.mt-tag-air { background: #1a3a2a; color: #9dff9d; }
.mt-tag-land { background: #3a2a1a; color: #ffd166; }
.mt-tag-cyber { background: #3a1a2a; color: #ff9db0; }
.mt-tag-general { background: #37474f; color: #cfd8dc; }

.mt-def {
  color: var(--mt-muted);
  font-size: 12px;
  line-height: 1.5;
  max-width: 360px;
}

.mt-link {
  font-size: 11px;
  color: var(--mt-accent2);
  text-decoration: none;
  border: 1px solid #1565c0;
  padding: 3px 8px;
  border-radius: 4px;
  background: rgba(21, 101, 192, 0.15);
  white-space: nowrap;
}

.mt-link:hover {
  background: rgba(21, 101, 192, 0.35);
  color: #fff;
}

.mt-pager {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 12px 16px;
  color: var(--mt-muted);
  font-size: 13px;
  border-top: 1px solid var(--mt-border);
}

.mt-pager button {
  padding: 6px 14px;
  border-radius: 6px;
  border: 1px solid var(--mt-border);
  background: #0d1b2a;
  color: #e8eaed;
  cursor: pointer;
}

.mt-pager button:disabled {
  opacity: 0.4;
  cursor: not-allowed;
}

.mt-meta {
  font-size: 11px;
  color: #546e7a;
  margin-bottom: 12px;
}

.mt-empty {
  padding: 40px;
  text-align: center;
  color: var(--mt-muted);
}

.mt-detail-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.72);
  z-index: 9999;
  display: none;
  align-items: center;
  justify-content: center;
  padding: 20px;
}

.mt-detail-overlay.is-open {
  display: flex;
}

.mt-detail {
  background: var(--mt-panel);
  border: 1px solid #5e35b1;
  border-radius: 12px;
  max-width: 640px;
  width: 100%;
  max-height: min(80vh, 720px);
  min-height: 120px;
  overflow-y: auto;
  padding: 24px 28px;
  box-shadow: 0 16px 48px rgba(0, 0, 0, 0.55);
  position: relative;
  z-index: 10000;
}

body.mt-modal-open {
  overflow: hidden;
}

.mt-detail h2 {
  margin: 0 0 12px;
  color: var(--mt-accent);
  font-size: 20px;
}

@media (max-width: 768px) {
  .mt-table-wrap { overflow-x: auto; }
  .mt-table { min-width: 720px; }
}
