/* ========================================
   企業検索ページ専用スタイル
   ======================================== */
.companies-list {
    background-color: #fff;
    padding: 2rem;
    border-radius: 8px;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.companies-list h2 {
    font-size: 1.75rem;
    color: #222;
    margin-bottom: 1.5rem;
    padding-bottom: 0.5rem;
    border-bottom: 2px solid #0066cc;
}

.search-form {
    background-color: #f9f9f9;
    padding: 1.5rem;
    border-radius: 8px;
    margin-bottom: 2rem;
}

.form-row {
    display: flex;
    flex-wrap: wrap;
    gap: 1rem;
    margin-bottom: 1rem;
}

.form-group {
    flex: 1;
    min-width: 250px;
    margin-bottom: 0.5rem;
}

.form-group.year-group {
    flex: 1;
    min-width: 300px;
}

.year-inputs {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.year-inputs input {
    flex: 1;
}

.year-separator {
    color: #666;
    font-weight: 600;
}

.form-group label {
    display: block;
    font-weight: 600;
    margin-bottom: 0.5rem;
    color: #333;
}

.form-group input[type="text"],
.form-group input[type="number"],
.form-group select {
    width: 100%;
    padding: 0.5rem;
    border: 1px solid #ddd;
    border-radius: 4px;
    font-size: 1rem;
    font-family: inherit;
}

.form-group input[type="text"]:focus,
.form-group input[type="number"]:focus,
.form-group select:focus {
    outline: none;
    border-color: #0066cc;
    box-shadow: 0 0 0 3px rgba(0, 102, 204, 0.1);
}

.form-group select[multiple] {
    height: auto;
}

.form-actions {
    display: flex;
    gap: 1rem;
    margin-top: 1.5rem;
}

.form-actions button {
    padding: 0.75rem 1.5rem;
    border: none;
    border-radius: 4px;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: background-color 0.3s ease;
}

.form-actions button[type="submit"] {
    background-color: #0066cc;
    color: #fff;
}

.form-actions button[type="submit"]:hover {
    background-color: #0052a3;
}

.form-actions button[type="reset"],
.form-actions .reset-button {
    background-color: #f0f0f0;
    color: #333;
}

.form-actions button[type="reset"]:hover,
.form-actions .reset-button:hover {
    background-color: #e0e0e0;
}

.form-actions .reset-button {
    display: inline-block;
    padding: 0.75rem 1.5rem;
    border: none;
    border-radius: 4px;
    font-size: 1rem;
    font-weight: 600;
    text-decoration: none;
    cursor: pointer;
    transition: background-color 0.3s ease;
    text-align: center;
}

.search-results {
    margin-top: 2rem;
}

main.main-content.industries-detail h2,
main.main-content.categories-detail h2{
    margin-bottom: 1rem;
}

.search-results > p {
    margin-bottom: 1rem;
    font-weight: 600;
    color: #555;
}

.other-cohort-options {
    margin-left: 1.5rem;
    margin-bottom: 0.75rem;
    color: #444;
    font-size: 0.95rem;
}

.other-cohort-options__prefix {
    font-weight: 600;
}

.other-cohort-options a {
    color: #0066cc;
    text-decoration: underline;
}

.search-results table {
    width: 100%;
    border-collapse: collapse;
    background-color: #fff;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
}

.search-results table th,
.search-results table td {
    padding: 0.75rem;
    text-align: left;
    border-bottom: 1px solid #e0e0e0;
}

.search-results table th {
    background-color: #f5f5f5;
    font-weight: 600;
    color: #333;
    white-space: nowrap;
}

.search-results table tbody tr:hover {
    background-color: #f9f9f9;
}

.search-results table td a {
    color: #0066cc;
    font-weight: 500;
}

.search-results table td a:hover {
    text-decoration: underline;
}

.cohort-chart-section {
    margin-bottom: 2rem;
}

.cohort-chart-container {
    background-color: #fff;
    border-radius: 12px;
    padding: 1.5rem;
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.08);
    max-width: 520px;
    margin: 0 auto;
}

.cohort-chart-container--industry {
    max-width: 720px;
}

.cohort-chart-container--market {
    max-width: 400px;
}

.cohort-chart-title {
    font-size: 1rem;
    font-weight: 600;
    margin-bottom: 1rem;
    color: #222;
    text-align: center;
}

.cohort-chart-canvas-wrapper {
    position: relative;
    width: 100%;
    min-height: 360px;
}

.cohort-chart-canvas {
    width: 100% !important;
    height: 100% !important;
}

@media (max-width: 768px) {
    .cohort-chart-container {
        padding: 1rem;
    }

    .cohort-chart-canvas-wrapper {
        min-height: 260px;
    }
}

/* ========================================
   説明文セクション
   ======================================== */
.description-section {
    background-color: #f8f9fa;
    padding: 1.5rem;
    border-radius: 6px;
    margin-bottom: 2rem;
    border-left: 4px solid #0066cc;
}

.description-text {
    color: #444;
    line-height: 1.8;
    margin: 0;
    white-space: pre-wrap;
}

/* テーブル内の短い説明文 */
.description {
    margin-top: 0.5rem;
    font-size: 0.9rem;
    color: #666;
    line-height: 1.6;
    font-style: italic;
}

/* ========================================
   レスポンシブ: スマートフォン (最大767px)
   ======================================== */
@media (max-width: 767px) {
    .companies-list {
        padding: 1.5rem;
    }

    .companies-list h2 {
        font-size: 1.5rem;
    }

    .search-form {
        padding: 1rem;
    }

    .description-section {
        padding: 1rem;
        margin-bottom: 1.5rem;
    }

    .description-text {
        font-size: 0.9rem;
    }

    .description {
        font-size: 0.85rem;
    }

    .form-row {
        flex-direction: column;
    }

    .form-group {
        min-width: 100%;
    }

    .form-group.year-group {
        min-width: 100%;
    }

    .form-actions {
        flex-direction: column;
    }

    .form-actions button,
    .form-actions .reset-button {
        width: 100%;
    }

    .search-results table {
        font-size: 0.875rem;
    }

    .search-results table th,
    .search-results table td {
        padding: 0.5rem;
    }
}

/* ========================================
   レスポンシブ: タブレット (768px以上)
   ======================================== */
@media (min-width: 768px) {
    .companies-list {
        padding: 3rem;
    }

    .companies-list h2 {
        font-size: 2rem;
    }
}
