@charset "UTF-8";

/* --- Base Setup --- */
:root {
    --primary: #0f4c81;       /* アカデミックなネイビー */
    --primary-light: #e6f0fa;
    --accent: #d9534f;        /* 警告色 */
    --text-main: #333333;
    --text-sub: #666666;
    --bg-body: #f9f9f9;
    --bg-white: #ffffff;
    --border-color: #e0e0e0;
}

body {
    font-family: 'Noto Sans JP', sans-serif;
    background-color: var(--bg-body);
    color: var(--text-main);
    line-height: 1.8;
    margin: 0;
    padding: 0;
}

a { text-decoration: none; color: inherit; }
ul { list-style: none; padding: 0; margin: 0; }

/* --- Layout Utility --- */
.container {
    max-width: 1000px;
    margin: 0 auto;
    padding: 0 20px;
}

/* --- Header --- */
.site-header {
    background: var(--bg-white);
    box-shadow: 0 2px 10px rgba(0,0,0,0.05);
    padding: 1rem 0;
}
.header-inner {
    display: flex;
    justify-content: space-between;
    align-items: center;
}
.logo-text {
    font-weight: 700;
    font-size: 1.5rem;
    color: var(--primary);
    display: block;
}
.tagline {
    font-size: 0.8rem;
    color: var(--text-sub);
    font-weight: normal;
    display: block;
}
.main-nav ul {
    display: flex;
    gap: 20px;
}
.main-nav a {
    font-weight: 500;
    color: var(--text-main);
    transition: color 0.2s;
}
.main-nav a:hover, .main-nav a.active {
    color: var(--primary);
}

/* --- Hero Section --- */
.hero {
    background: linear-gradient(135deg, var(--primary) 0%, #1e3a8a 100%);
    color: white;
    padding: 3rem 0;
    text-align: center;
    margin-bottom: 3rem;
}
.hero h2 {
    font-size: 2rem;
    margin-bottom: 1rem;
}
.btn-primary {
    display: inline-block;
    background: var(--accent);
    color: white;
    padding: 0.8rem 2rem;
    border-radius: 4px;
    margin-top: 1rem;
    font-weight: bold;
    transition: opacity 0.2s;
}
.btn-primary:hover { opacity: 0.9; }

/* --- Grid & Cards --- */
.grid-wrapper {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 20px;
}
.incident-card {
    background: white;
    padding: 20px;
    border-radius: 8px;
    border: 1px solid var(--border-color);
    transition: transform 0.2s, box-shadow 0.2s;
}
.incident-card:hover {
    transform: translateY(-3px);
    box-shadow: 0 5px 15px rgba(0,0,0,0.05);
}
.incident-card h3 {
    font-size: 1.1rem;
    margin: 10px 0;
    color: var(--primary);
}
.tag {
    font-size: 0.75rem;
    padding: 3px 8px;
    border-radius: 4px;
    background: #eee;
    margin-right: 5px;
}
.tag-location { background: #e0f2f1; color: #00695c; }
.tag-age { background: #e3f2fd; color: #1565c0; }
.tag-type { background: #fff3e0; color: #ef6c00; }

/* --- Article Styling --- */
.article-page {
    margin-top: 2rem;
    background: white;
    padding: 40px;
    border-radius: 8px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.02);
}
.incident-title {
    font-size: 1.8rem;
    color: var(--text-main);
    border-bottom: 2px solid var(--primary-light);
    padding-bottom: 1rem;
    margin-bottom: 2rem;
}
.summary-text {
    font-size: 1.1rem;
    background: var(--primary-light);
    padding: 20px;
    border-radius: 6px;
}
.highlight-danger {
    color: var(--accent);
    font-weight: bold;
}

/* Table */
.incident-data-table {
    width: 100%;
    border-collapse: collapse;
    margin: 2rem 0;
}
.incident-data-table th, .incident-data-table td {
    border: 1px solid var(--border-color);
    padding: 12px;
    text-align: left;
}
.incident-data-table th {
    background: #f4f4f4;
    width: 30%;
}

/* Analysis Grid */
.analysis-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
    margin: 2rem 0;
}
.factor-card {
    background: #f8f9fa;
    padding: 20px;
    border-left: 4px solid #ccc;
}
.factor-card.human { border-color: #f0ad4e; }
.factor-card.environment { border-color: #5bc0de; }

/* Checklist */
.checklist li {
    padding: 10px 0;
    border-bottom: 1px dashed var(--border-color);
}
.checklist label { cursor: pointer; }
.checklist input { margin-right: 10px; }

/* Footer */
.site-footer {
    text-align: center;
    padding: 2rem 0;
    margin-top: 4rem;
    color: var(--text-sub);
    font-size: 0.9rem;
    border-top: 1px solid var(--border-color);
}

/* Mobile Responsive */
@media (max-width: 600px) {
    .header-inner { flex-direction: column; gap: 10px; }
    .analysis-grid { grid-template-columns: 1fr; }
    .article-page { padding: 20px; }
}

/* --- 追加分：検索ボックスとページタイトル --- */
.page-title {
    text-align: center;
    color: var(--primary);
    margin-bottom: 1rem;
}

.search-box-area {
    text-align: center;
    margin-bottom: 3rem;
    padding: 2rem;
    background: var(--primary-light);
    border-radius: 8px;
}

#searchInput {
    width: 80%;
    padding: 15px;
    font-size: 1.1rem;
    border: 2px solid var(--primary);
    border-radius: 30px;
    outline: none;
    transition: box-shadow 0.2s;
}

#searchInput:focus {
    box-shadow: 0 0 0 4px rgba(15, 76, 129, 0.2);
}

.lead {
    font-size: 1.2rem;
    font-weight: bold;
    color: var(--text-sub);
    margin-bottom: 2rem;
}

/* --- Pagination --- */
.pagination {
    display: flex;
    justify-content: center;
    gap: 10px;
    margin-top: 3rem;
}
.pagination a {
    display: block;
    width: 40px;
    height: 40px;
    line-height: 40px;
    text-align: center;
    border: 1px solid var(--border-color);
    border-radius: 4px;
    background: white;
    color: var(--primary);
    font-weight: bold;
    transition: all 0.2s;
}
.pagination a:hover {
    background: var(--primary-light);
}
.pagination a.active {
    background: var(--primary);
    color: white;
    border-color: var(--primary);
    pointer-events: none;
}