/* 歴代記録ページの便利機能の見た目（js/record-tools.js と対） */

.rt-panel {
    --rt-accent: var(--season-accent, var(--sums-blue));
    --rt-accent-soft: var(--season-line, rgba(0, 91, 172, 0.22));
    display: grid;
    gap: 16px;
}

.rt-row {
    display: flex;
    flex-wrap: wrap;
    align-items: flex-end;
    gap: 12px;
}

.rt-field {
    display: grid;
    gap: 6px;
    min-width: 0;
}

.rt-field--grow {
    flex: 1 1 260px;
}

.rt-field > span {
    color: var(--muted);
    font-size: 12px;
    font-weight: 800;
    letter-spacing: 0.1em;
}

.rt-panel input,
.rt-panel select {
    min-height: 42px;
    padding: 8px 12px;
    color: var(--ink);
    background: #fff;
    border: 1px solid var(--line);
    border-radius: 0;
    font: inherit;
    font-size: 15px;
}

.rt-panel input:focus,
.rt-panel select:focus {
    outline: 2px solid var(--rt-accent);
    outline-offset: -1px;
}

.rt-panel .rt-search {
    width: 100%;
}

/* ===== しぼり込みチップ ===== */

.rt-chips {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.rt-chip {
    min-height: 38px;
    padding: 8px 14px;
    color: var(--rt-accent);
    background: #fff;
    border: 1px solid var(--line);
    border-radius: 0;
    font: inherit;
    font-size: 13px;
    font-weight: 800;
    cursor: pointer;
    transition: background 150ms ease, color 150ms ease, border-color 150ms ease;
}

.rt-chip:hover {
    border-color: var(--rt-accent);
}

.rt-chip.is-on {
    color: #fff;
    background: var(--rt-accent);
    border-color: var(--rt-accent);
}

.rt-chip--reset {
    color: var(--muted);
}

/* ===== タイム診断 ===== */

.rt-panel--judge {
    margin-top: 32px;
}

.rt-judge {
    padding-top: 0;
}

.rt-judge__title {
    margin: 0 0 12px;
    color: var(--rt-accent);
    font-size: 15px;
    font-weight: 900;
}

.rt-go {
    min-height: 42px;
    padding: 8px 22px;
    color: #fff;
    background: var(--rt-accent);
    border: 1px solid var(--rt-accent);
    border-radius: 0;
    font: inherit;
    font-size: 14px;
    font-weight: 800;
    cursor: pointer;
}

.rt-go:hover {
    filter: brightness(1.08);
}

.rt-result {
    margin: 12px 0 0;
    min-height: 1.6em;
    font-size: 15px;
    font-weight: 700;
}

.rt-result.is-done {
    color: var(--rt-accent);
}

.rt-result.is-error {
    color: #b3261e;
}

.rt-empty {
    margin: 24px 0;
    color: var(--muted);
    text-align: center;
}

/* ===== 表の装飾 ===== */

/* 歴代1位 */
.record-main tr.rt-top td:first-child::before {
    content: "👑";
    margin-right: 6px;
    font-size: 13px;
}

.record-main tr.rt-top td:nth-child(3) {
    font-weight: 900;
}

/* 今年度に出た記録 */
.record-main tr.rt-new {
    background: color-mix(in srgb, var(--season-accent, var(--sums-blue)) 9%, #fff);
}

.record-main tr.rt-new td:nth-child(3)::after {
    content: "NEW";
    margin-left: 8px;
    padding: 2px 6px;
    color: #fff;
    background: var(--season-accent, var(--sums-blue));
    font-size: 10px;
    font-weight: 900;
    letter-spacing: 0.08em;
    vertical-align: 2px;
}

@supports not (color: color-mix(in srgb, red 50%, blue)) {
    .record-main tr.rt-new {
        background: var(--soft, #f6f9fc);
    }
}

/* 現役部員の名前 */
.rt-current {
    color: var(--season-accent, var(--sums-blue));
    font-weight: 900;
    border-bottom: 2px solid var(--season-line, rgba(0, 91, 172, 0.3));
}

@media screen and (max-width: 640px) {
    .rt-row {
        flex-direction: column;
        align-items: stretch;
    }

    .rt-go {
        width: 100%;
    }
}
