/* =====================================================
   欠席登録・欠席一覧
   ===================================================== */

[hidden] {
    display: none !important;
}

.field textarea {
    width: 100%;
    min-height: 110px;
    padding: 10px 12px;
    border: 1px solid var(--border);
    border-radius: 11px;
    background: #fff;
    color: var(--text);
    outline: none;
    resize: vertical;
    box-sizing: border-box;
    font: inherit;
    line-height: 1.6;
    transition:
        border-color 0.18s,
        box-shadow 0.18s;
}

.field textarea:focus {
    border-color: var(--primary);
    box-shadow:
        0 0 0 4px
        rgba(20, 87, 217, 0.11);
}

.absence-form-card {
    margin-top: 20px;
    margin-bottom: 20px;
    border-left:
        5px solid
        var(--danger);
}

.absence-form-card .form-grid {
    align-items: start;
}

.absence-reason-field {
    grid-column: 1 / -1;
}

.field-help {
    margin: 7px 0 0;
    color: var(--muted);
    font-size: 0.78rem;
    line-height: 1.5;
}

.absence-legend {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 8px;
    margin-bottom: 14px;
}

.absence-badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 58px;
    padding: 5px 10px;
    border: 1px solid transparent;
    border-radius: 999px;
    font-size: 0.8rem;
    font-weight: 800;
    line-height: 1;
    white-space: nowrap;
}

.absence-private {
    border-color: #d5d9de;
    background: #eef1f4;
    color: #495057;
}

.absence-official {
    border-color: #f3b9b9;
    background: #fdecec;
    color: #b42318;
}

.absence-paid-leave {
    border-color: #aadfbd;
    background: #e8f7ee;
    color: #157347;
}

.absence-list-card {
    border-top:
        3px solid
        rgba(217, 45, 32, 0.16);
}

.absence-list-card td {
    vertical-align: middle;
}

.absence-list-card td:nth-child(3) {
    min-width: 180px;
    white-space: normal;
    overflow-wrap: anywhere;
    line-height: 1.6;
}

.button:disabled {
    cursor: not-allowed;
    opacity: 0.62;
    transform: none;
}

@media (max-width: 700px) {
    .absence-form-card .form-grid {
        grid-template-columns: 1fr;
    }

    .absence-reason-field {
        grid-column: auto;
    }

    .absence-form-card
    .form-buttons {
        flex-direction: column;
    }

    .absence-form-card
    .form-buttons
    .button {
        width: 100%;
    }

    .absence-list-card
    td:nth-child(3) {
        min-width: 150px;
    }
}
