﻿/* =========================
   Design Tokens (PC)
   ========================= */
:root {
    /* Colors (東京都 別紙：設定表 基準色) */
    --tocho-green: #2E8B57;
    --tocho-green-dark: #256f46;
    --tocho-green-light: #e1ffd8;
    --tocho-navy: #002063; /* ①濃紺：重要帯、コピーライト、主要ボタン */
    --tocho-blue: #3e4770; /* ②紺   ：ナビ帯、下部リンク帯ほか */
    --tocho-gray: #dfe0e6; /* ③グレー：帯、表ヘッダ、区切り */
    --tocho-text: #222222; /* 本文テキスト */
    --tocho-hover: #5c6591; /* ナビ選択・ホバー */
    --tocho-white: #ffffff;
    /* Typography (PC 規定) */
    --font-size-base: 13px;
    --line-height-base: 24px;
}



/* =========================
   Base
   ========================= */
html, body {
    background: var(--tocho-white);
    color: var(--tocho-text);
}

body {
    font-size: var(--font-size-base);
    line-height: var(--line-height-base);
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    word-break: break-word;
}



/* =========================
   Layout regions
   ========================= */

/* Header */
header {
    background: var(--tocho-green);
    color: var(--tocho-white);
}

    header .title {
        color: var(--tocho-white);
        text-decoration: none;
    }

        header .title:hover, header a:focus {
            text-decoration: none;
        }

    header .nav-link {
        color: var(--tocho-white);
        font-size: 14px;
        line-height: 24px;
        display: inline-flex;
        align-items: center;
    }

        header .nav-link:hover,
        header .nav-link:focus {
            color: #d2d8f7; /* ホバー時のアクセント（東京都設定表準拠） */
        }

/* Footer */
footer {
    color: var(--tocho-text);
    background: var(--tocho-white);
    border-top-color: var(--tocho-green);
    padding-top: var(--sp-3);
    font-size: var(--font-size-base);
    line-height: 16px; /* コピーライト規定値に合わせ小さめ行高 */
}

    footer .nav-link {
        color: var(--tocho-text);
        font-size: 14px;
        line-height: 24px;
        display: inline-flex;
        align-items: center;
    }

        footer .nav-link:hover,
        footer .nav-link:focus {
            color: #d2d8f7; /* ホバー時のアクセント（東京都設定表準拠） */
        }


/* =========================
   Buttons
   ========================= */

/* 処理ボタン共通 */
.submit-button, .clear-button, .cancel-button, .submit-button-sm, .cancel-button-sm {
    display: inline-block;
    border: none;
    border-radius: 1rem;
    font-weight: 500;
    cursor: pointer;
    transition: background-color .2s;
    text-decoration: none;
    font-size: var(--font-size-base);
    line-height: var(--line-height-base);
}

.submit-button {
    background-color: var(--tocho-green);
    color: #fff;
    padding: 1rem 9rem;
    font-size: 1.5rem;
}

    .submit-button:hover {
        background-color: var(--tocho-green);
        color: #fff;
        filter: brightness(0.9);
        opacity: .9;
    }

.clear-button {
    background-color: #ff0000;
    color: #fff;
    padding: 1rem 1.5rem;
    font-size: 1.5rem;
}

    .clear-button:hover {
        background-color: #ff0000;
        color: #fff;
        filter: brightness(0.9);
        opacity: .9;
    }

.cancel-button {
    background-color: #e0e0e0;
    color: #000000;
    padding: 1rem 1.5rem;
    font-size: 1.5rem;
}

    .cancel-button:hover {
        background-color: #e0e0e0cc;
        color: #000000;
        filter: brightness(0.9);
        opacity: .9;
    }

.submit-button-sm {
    background-color: var(--tocho-green);
    color: #fff;
    padding: 1rem 5rem;
    font-size: 1rem;
}

    .submit-button-sm:hover {
        background-color: var(--tocho-green);
        color: #fff;
        filter: brightness(0.9);
        opacity: .9;
    }

.cancel-button-sm {
    background-color: #e0e0e0;
    color: #000000;
    padding: 1rem 5rem;
    font-size: 1rem;
}

    .cancel-button-sm:hover {
        background-color: #e0e0e0cc;
        color: #000000;
        filter: brightness(0.9);
        opacity: .9;
    }



/* =========================
   Forms
   ========================= */

/* ラジオ/チェックのカード風 */
.choice-card {
    display: inline-block;
    border: 1px solid var(--tocho-green);
    background: #fff;
    padding: var(--sp-3) var(--sp-4);
    margin: 0 var(--sp-2) var(--sp-2) 0;
    cursor: pointer;
}

    .choice-card.is-active,
    .choice-card:has(input:checked) {
        background: #eef1fb; /* 淡いハイライト */
        outline: 2px solid var(--tocho-green);
        outline-offset: 2px;
    }



/* =========================
   Tables
   ========================= */

/* 検索結果テーブルラッパー 明細スクロール用にサイズの指定など */
.search-result-wrapper {
    max-height: 400px; /* ← 表示エリアの高さを指定 */
    overflow-y: auto; /* ← 縦方向スクロール */
    border: 1px solid #ddd;
    border-radius: 6px;
}

/* 検索結果テーブル全体 */
.search-result-table {
    width: 100%;
    border-collapse: collapse;
    font-family: "Noto Sans JP", "ヒラギノ角ゴ ProN", Meiryo, sans-serif;
    color: var(--tocho-text);
    font-size: 1rem; /* ブラウザ標準16px相当 */
    line-height: 1.6;
}

    /* 見出し行（th） */
    .search-result-table th {
        position: sticky;
        top: 0;
        font-weight: 700;
        background: var(--tocho-gray);
        color: var(--tocho-green);
        border: 1px solid #ddd;
        padding: 10px 12px;
        font-size: 1.125rem; /* 約18px：東京都の本文基準に沿う */
        z-index: 2;
        white-space: nowrap;
    }

    /* 明細行（td） */
    .search-result-table td {
        padding: 10px 12px;
        border-bottom: 1px solid #e0e0e0;
        vertical-align: middle;
        font-size: 0.9375rem; /* 約15px：補足情報として適切 */
        white-space: nowrap;
    }

    /* ホバー行 */
    .search-result-table tbody tr:hover td {
        filter: brightness(1.1);
    }



/**
 * 検索結果部
*/
.result-detail-table {
    width: 100%;
    border-collapse: collapse;
    font-family: "Noto Sans JP", "ヒラギノ角ゴ ProN", Meiryo, sans-serif;
    color: #333;
    font-size: 1rem; /* 約16px */
    line-height: 1.6;
    border: 1px solid #e0e0e0;
    border-radius: 10px;
    overflow: hidden;
    background: #fff;
}

    /* セクション見出し */
    .result-detail-table th[colspan] {
        font-size: 1.125rem; /* 約18px */
        font-weight: 700;
        text-align: left;
        padding: 12px 10px;
        background: #f5f5f5;
        border-bottom: 2px solid #ccc;
    }

    /* th（ラベル） */
    .result-detail-table th {
        font-weight: 600;
        color: #555;
        background: #fafafa;
        width: 30%;
        padding: 8px 12px;
        border-bottom: 1px solid #e0e0e0;
        vertical-align: middle;
    }

    /* td（値） */
    .result-detail-table td {
        padding: 8px 12px;
        border-bottom: 1px solid #e0e0e0;
        vertical-align: middle;
    }

    /* セクション間の余白 */
    .result-detail-table + .result-detail-table {
        margin-top: 24px;
    }

/* 全体を囲うカード */
.result-detail-wrapper {
    border: 1px solid #ddd;
    border-radius: 10px;
    background: #fff;
    padding: 20px;
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.05);
}



/**
* アニメーション
*/
.fade-in {
    opacity: 0;
    transition: opacity 0.4s ease-in-out;
}

    .fade-in.show {
        opacity: 1;
    }


/**
* その他共通部品
*/

/* 区切り矢印 ▼ */
.arrow-down {
    content: "";
    display: block;
    margin: 0 auto;
    margin-top: 1rem;
    margin-bottom: 1rem;
    background: #4a5568;
    aspect-ratio: 7/1;
    width: 300px;
    clip-path: polygon(0 0,100% 0,50% 100%)
}

