@charset "utf-8";

/* 既存の下層ページと同じタイトル帯を使用 */
#accident-contact-title {
    background-image: url("../images/contact.png");
    background-position: center center;
    background-repeat: no-repeat;
    background-size: cover;
}

.accident-contact-intro {
    line-height: 1.8;
    margin-bottom: 35px;
}

.contact-tabs {
    display: flex;
    gap: 12px;
    border-bottom: 3px solid #40aca5;
    margin-bottom: 30px;
}
.contact-tabs[hidden], .contact-panel[hidden] { display: none; }
.contact-tabs button {
    flex: 1;
    padding: 20px 12px;
    border: 1px solid #40aca5;
    border-bottom: 0;
    border-radius: 8px 8px 0 0;
    background: #fbfaf5;
    color: #333;
    font: inherit;
    font-size: clamp(16px, 2vw, 20px);
    line-height: 1.5;
    cursor: pointer;
}
.contact-tabs button[aria-selected="true"] {
    background: #40aca5;
    color: #142f2d;
    font-weight: bold;
}
.contact-tab-word {
    display: inline-block;
    white-space: nowrap;
}
.contact-tabs button:hover { background: #e1f3f1; }
.contact-tabs button[aria-selected="true"]:hover { background: #40aca5; }
.contact-tabs button:focus-visible, .contact-table-scroll:focus-visible,
.contact-table a:focus-visible { outline: 3px solid #285b88; outline-offset: 3px; }
.contact-table-heading {
    background: #f4f2ed;
    border-left: 5px solid #40aca5;
    padding: 15px 20px;
    font-family: 'Noto Serif JP', serif;
    font-size: clamp(18px, 2vw, 24px);
    font-weight: normal;
    margin-bottom: 20px;
}
.contact-panel + .contact-panel { margin-top: 35px; }
.contact-tabs:not([hidden]) ~ .contact-panel { margin-top: 0; }
.contact-table-scroll { overflow-x: auto; padding: 3px; }
.contact-table { width: 100%; min-width: 700px; border-collapse: collapse; table-layout: fixed; }
.contact-table caption {
    position: absolute;
    width: 1px;
    height: 1px;
    overflow: hidden;
    clip-path: inset(50%);
}
.contact-table th, .contact-table td {
    padding: 18px 16px;
    border: 1px solid #ccc;
    vertical-align: middle;
    line-height: 1.8;
    font-size: 16px;
    overflow-wrap: anywhere;
}
.contact-table thead th { background: #e1f3f1; text-align: left; }
.contact-table tbody th { background: #fbfaf5; font-weight: normal; text-align: left; }
.contact-table thead th:first-child { width: 34%; }
.life-table thead th:nth-child(2) { width: 29%; }
.contact-phone { color: #285b88; font-size: 20px; white-space: nowrap; text-decoration: underline; text-underline-offset: 4px; }
.contact-table a:hover { color: #c33; }
.contact-table .contact-procedure {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
    max-width: 100%;
    min-height: 44px;
    box-sizing: border-box;
    margin-top: 14px;
    padding: 10px 16px;
    border: 1px solid #40aca5;
    border-radius: 6px;
    background: #40aca5;
    color: #142f2d;
    font-weight: bold;
    line-height: 1.5;
    text-decoration: none;
    transition: background-color .2s, border-color .2s, color .2s;
}
.contact-procedure::after {
    content: "";
    width: 7px;
    height: 7px;
    flex-shrink: 0;
    border-top: 2px solid currentColor;
    border-right: 2px solid currentColor;
    transform: rotate(45deg);
}
.contact-table .contact-procedure:hover {
    background: #e1f3f1;
    border-color: #28746f;
    color: #142f2d;
}
.contact-common-number { text-align: center; }
.table-scroll-note { display: none; font-size: 14px; margin-bottom: 10px; }
@media screen and (max-width: 760px) {
    .contact-tabs { gap: 6px; }
    .contact-tabs button { padding: 16px 10px; }
    .contact-table-scroll { overflow: visible; padding: 0; }
    .contact-table { display: block; min-width: 0; table-layout: auto; }
    .contact-table thead {
        position: absolute;
        width: 1px;
        height: 1px;
        overflow: hidden;
        clip-path: inset(50%);
    }
    .contact-table tbody {
        display: flex;
        flex-direction: column;
        margin-bottom: 20px;
        border: 1px solid #ccc;
        border-radius: 6px;
        overflow: hidden;
    }
    .contact-table tr { display: contents; }
    .contact-table tbody th, .contact-table td {
        display: block;
        width: auto;
        padding: 14px 16px;
        border: 0;
        text-align: left;
    }
    .contact-table tbody th {
        order: 0;
        background: #e1f3f1;
        font-weight: bold;
        border-bottom: 1px solid #ccc;
    }
    .contact-table td { order: 1; }
    .contact-table td[data-label="自動車保険以外"],
    .contact-table td[data-label="備考"] {
        order: 2;
        border-top: 1px solid #ddd;
        background: #fbfaf5;
    }
    .contact-table td::before {
        content: attr(data-label);
        display: block;
        margin-bottom: 6px;
        font-size: 14px;
        font-weight: bold;
        color: #333;
    }
    .contact-phone { display: inline-block; padding: 4px 0; }
    .contact-table .contact-procedure { width: 100%; }
}
