/**
 * リセットCSS - 統合版
 * ブラウザのデフォルトスタイルをリセット
 * 全サイト共通の基礎スタイル
 */

/* ========================================
   ベースリセット
======================================== */
*,
*::before,
*::after {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

/* HTML5要素のリセット */
article, aside, details, figcaption, figure, 
footer, header, hgroup, main, menu, nav, section {
    display: block;
}

/* ========================================
   ボディとHTML
======================================== */
html {
    font-size: 100%;
    -webkit-text-size-adjust: 100%;
    -ms-text-size-adjust: 100%;
    scroll-behavior: smooth;
}

body {
    min-height: 100vh;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "Noto Sans JP", "Hiragino Sans", 
                 "Hiragino Kaku Gothic ProN", "Yu Gothic", YuGothic, Meiryo, sans-serif;
    font-size: 16px;
    line-height: 1.6;
    color: #333;
    background-color: #fff;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    text-rendering: optimizeLegibility;
    word-wrap: break-word;
    overflow-wrap: break-word;
}

/* ========================================
   タイポグラフィ
======================================== */
h1, h2, h3, h4, h5, h6 {
    font-weight: bold;
    line-height: 1.2;
    margin: 0;
}

p {
    margin: 0;
}

/* ========================================
   リスト
======================================== */
ul, ol {
    list-style: none;
    margin: 0;
    padding: 0;
}

/* ========================================
   リンク
======================================== */
a {
    text-decoration: none;
    color: inherit;
    background-color: transparent;
}

a:hover,
a:focus {
    outline: 0;
}

/* ========================================
   メディア要素
======================================== */
img {
    max-width: 100%;
    height: auto;
    vertical-align: middle;
    border: 0;
}

svg {
    overflow: hidden;
    vertical-align: middle;
}

video,
audio {
    display: inline-block;
    max-width: 100%;
}

/* ========================================
   フォーム要素
======================================== */
button,
input,
optgroup,
select,
textarea {
    font-family: inherit;
    font-size: inherit;
    line-height: inherit;
    color: inherit;
    margin: 0;
    padding: 0;
    border: 0;
    background: transparent;
}

/* チェックボックスとラジオボタンはネイティブスタイルを維持 */
input[type="checkbox"],
input[type="radio"] {
    /* ブラウザのデフォルトスタイルを保持 */
    border: revert;
    background: revert;
    -webkit-appearance: checkbox;
    -moz-appearance: checkbox;
    appearance: checkbox;
}

input[type="radio"] {
    -webkit-appearance: radio;
    -moz-appearance: radio;
    appearance: radio;
}

button {
    cursor: pointer;
    background: transparent;
    border: none;
    outline: none;
    -webkit-appearance: none;
    -moz-appearance: none;
    appearance: none;
}

button::-moz-focus-inner {
    border: 0;
    padding: 0;
}

input,
textarea {
    outline: none;
}

input[type="search"] {
    -webkit-appearance: textfield;
}

input[type="search"]::-webkit-search-cancel-button,
input[type="search"]::-webkit-search-decoration {
    -webkit-appearance: none;
}

textarea {
    overflow: auto;
    resize: vertical;
}

/* ========================================
   テーブル
======================================== */
table {
    border-collapse: collapse;
    border-spacing: 0;
    width: 100%;
}

td,
th {
    padding: 0;
}

/* ========================================
   その他の要素
======================================== */
blockquote,
q {
    quotes: none;
}

blockquote::before,
blockquote::after,
q::before,
q::after {
    content: '';
    content: none;
}

hr {
    height: 0;
    border: 0;
    margin: 0;
}

address {
    font-style: normal;
}

/* ========================================
   アクセシビリティ
======================================== */
.sr-only {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}

/* フォーカス時のアウトライン */
:focus-visible {
    outline: 2px solid #007bff;
    outline-offset: 2px;
}

/* ========================================
   印刷用スタイル
======================================== */
@media print {
    *,
    *::before,
    *::after {
        background: transparent !important;
        color: #000 !important;
        box-shadow: none !important;
        text-shadow: none !important;
    }
    
    a,
    a:visited {
        text-decoration: underline;
    }
    
    img {
        max-width: 100% !important;
    }
    
    @page {
        margin: 2cm;
    }
}