.wt-legend {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 8px 16px;
}
.wt-legend-item {
    display: flex;
    align-items: baseline;
    gap: 8px;
    font-size: 0.88rem;
}
.wt-chip {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 2.1rem;
    padding: 2px 8px;
    border-radius: 999px;
    font-size: 0.75rem;
    font-weight: 700;
    line-height: 1.4;
}
.wt-chip.green { background: #dcfce7; color: #166534; }
.wt-chip.grey { background: #e2e8f0; color: #334155; }
.wt-chip.red { background: #fee2e2; color: #991b1b; }
.wt-chip.black { background: #0f172a; color: #f8fafc; }
.wt-chip.orange { background: #ffedd5; color: #9a3412; }
.wt-chip.yellow { background: #fef9c3; color: #854d0e; }
.wt-chip.lime { background: #ecfccb; color: #3f6212; }

.wt-table-wrap { overflow-x: auto; }
.wt-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 0.85rem;
}
.wt-table th,
.wt-table td {
    border-bottom: 1px solid #e2e8f0;
    padding: 8px 6px;
    vertical-align: top;
    text-align: left;
}
.wt-table th { color: #64748b; font-size: 0.75rem; text-transform: uppercase; letter-spacing: 0.03em; }
.wt-table input,
.wt-table select,
.wt-table textarea {
    width: 100%;
    min-width: 0;
}
.wt-table .wt-no { width: 2.4rem; font-weight: 700; color: #0C1248; padding-top: 14px; }
.wt-table .wt-serial { width: 8rem; }
.wt-table .wt-type { width: 11rem; }
.wt-table .wt-rating { width: 14rem; }
.wt-table .wt-photo { width: 7.5rem; }
.wt-ans-group {
    display: flex;
    flex-wrap: wrap;
    gap: 4px;
}
.wt-ans {
    border: 0;
    cursor: pointer;
    padding: 2px 7px;
    border-radius: 999px;
    font-size: 0.72rem;
    font-weight: 700;
    background: #f1f5f9;
    color: #475569;
}
.wt-ans.on.green { background: #166534; color: #fff; }
.wt-ans.on.grey { background: #475569; color: #fff; }
.wt-ans.on.red { background: #b91c1c; color: #fff; }
.wt-ans.on.black { background: #0f172a; color: #fff; }
.wt-ans.on.orange { background: #c2410c; color: #fff; }
.wt-ans.on.yellow { background: #ca8a04; color: #fff; }
.wt-ans.on.lime { background: #65a30d; color: #fff; }
.wt-auto {
    color: #0f172a;
    font-weight: 600;
    font-size: 0.82rem;
    margin-bottom: 4px;
}
.wt-auto.empty { color: #94a3b8; font-weight: 400; }
.wt-photo-view {
    display: block;
    margin: 0 0 4px;
    padding: 0;
    border: 0;
    background: transparent;
    cursor: zoom-in;
    line-height: 0;
}
.wt-photo-preview {
    width: 72px;
    height: 54px;
    object-fit: cover;
    border-radius: 6px;
    border: 1px solid #e2e8f0;
    display: block;
}
.wt-lightbox {
    position: fixed;
    inset: 0;
    z-index: 9999;
    background: rgba(15, 23, 42, 0.88);
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 48px 24px 64px;
}
.wt-lightbox[hidden] { display: none !important; }
.wt-lightbox img {
    max-width: 96vw;
    max-height: 90vh;
    object-fit: contain;
    border-radius: 6px;
    box-shadow: 0 12px 40px rgba(0, 0, 0, 0.45);
    background: #fff;
}
.wt-lightbox-close {
    position: absolute;
    top: 16px;
    right: 18px;
    width: 40px;
    height: 40px;
    border: 0;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.15);
    color: #fff;
    font-size: 1.5rem;
    line-height: 1;
    cursor: pointer;
}
.wt-lightbox-meta {
    position: absolute;
    bottom: 18px;
    left: 50%;
    transform: translateX(-50%);
    color: #e2e8f0;
    font-size: 0.85rem;
    text-align: center;
    max-width: 90vw;
}
.wt-totals {
    margin-top: 14px;
    display: flex;
    flex-wrap: wrap;
    gap: 10px 18px;
    font-size: 0.9rem;
}
.wt-totals strong { color: #0C1248; }
.wt-totals .bad { color: #b91c1c; }
