/*
 * 低忠実度ワイヤーフレーム - 共通スタイル
 * 入試正解デジタル 現状画面
 */

/* Google Material Icons */
@import url('https://fonts.googleapis.com/icon?family=Material+Icons');

.material-icons {
    font-size: inherit;
    vertical-align: middle;
    line-height: 1;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
    background: #fafafa;
    color: #333;
    font-size: 14px;
    line-height: 1.5;
}

/* ========================================
   ヘッダー
======================================== */
.header {
    background: #fff;
    border-bottom: 1px solid #e0e0e0;
    padding: 12px 24px;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.logo {
    display: flex;
    align-items: center;
    gap: 8px;
}

.logo-icon {
    width: 32px;
    height: 32px;
    background: #e5e5e5;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 10px;
    color: #666;
}

.logo-text {
    font-size: 16px;
    font-weight: bold;
    color: #333;
}

.user-menu {
    display: flex;
    align-items: center;
    gap: 16px;
}

.user-avatar {
    width: 32px;
    height: 32px;
    background: #e5e5e5;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 10px;
    color: #666;
}

.notification-icon {
    width: 24px;
    height: 24px;
    background: #f0f0f0;
    border-radius: 4px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 10px;
    color: #666;
}

/* ========================================
   ナビゲーション
======================================== */
.nav {
    background: #fff;
    border-bottom: 1px solid #e0e0e0;
    padding: 0 24px;
    display: flex;
    gap: 8px;
}

.nav-item {
    padding: 12px 16px;
    text-decoration: none;
    color: #666;
    font-size: 13px;
    border-bottom: 3px solid transparent;
    transition: all 0.2s;
}

.nav-item:hover {
    color: #333;
    background: #f5f5f5;
}

.nav-item.active {
    color: #333;
    border-bottom-color: #333;
    font-weight: 500;
}

/* ========================================
   メインコンテンツ
======================================== */
.main {
    max-width: 1200px;
    margin: 0 auto;
    padding: 24px;
}

.page-title {
    font-size: 18px;
    font-weight: bold;
    margin-bottom: 24px;
    display: flex;
    align-items: center;
    gap: 8px;
}

.page-title-icon {
    width: 24px;
    height: 24px;
    background: #e5e5e5;
    border-radius: 4px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 10px;
    color: #666;
}

/* ========================================
   カード / ボックス
======================================== */
.card {
    background: #fff;
    border: 1px solid #e0e0e0;
    border-radius: 8px;
    padding: 20px;
    margin-bottom: 16px;
}

.box {
    background: #f5f5f5;
    border: 1px dashed #ccc;
    border-radius: 4px;
    padding: 16px;
    margin-bottom: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #666;
    font-size: 12px;
    min-height: 40px;
}

.box-label {
    text-align: center;
}

/* ========================================
   タブ
======================================== */
.tabs {
    display: flex;
    gap: 4px;
    margin-bottom: 20px;
    border-bottom: 1px solid #e0e0e0;
}

.tab {
    padding: 10px 16px;
    background: transparent;
    border: none;
    color: #666;
    font-size: 13px;
    cursor: pointer;
    border-bottom: 2px solid transparent;
    text-decoration: none;
}

.tab:hover {
    color: #333;
}

.tab.active {
    color: #333;
    border-bottom-color: #333;
    font-weight: 500;
}

/* ========================================
   フォーム要素
======================================== */
.form-group {
    margin-bottom: 16px;
}

.form-label {
    display: block;
    font-size: 12px;
    color: #666;
    margin-bottom: 4px;
}

.form-input {
    width: 100%;
    padding: 10px 12px;
    border: 1px solid #ddd;
    border-radius: 4px;
    font-size: 14px;
    background: #fff;
}

.form-select {
    padding: 10px 12px;
    border: 1px solid #ddd;
    border-radius: 4px;
    font-size: 14px;
    background: #fff;
    min-width: 150px;
}

.form-row {
    display: flex;
    gap: 16px;
    align-items: flex-end;
}

/* チェックボックス */
.checkbox-group {
    display: flex;
    gap: 16px;
    flex-wrap: wrap;
}

.checkbox-item {
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 8px 12px;
    background: #f5f5f5;
    border: 1px solid #ddd;
    border-radius: 4px;
    font-size: 12px;
    color: #666;
}

/* ========================================
   ボタン
======================================== */
.btn {
    padding: 10px 20px;
    border-radius: 4px;
    font-size: 14px;
    cursor: pointer;
    border: 1px solid #ddd;
    background: #f5f5f5;
    color: #333;
}

.btn-primary {
    background: #666;
    color: #fff;
    border-color: #666;
}

.btn-outline {
    background: #fff;
    border-color: #ccc;
}

/* ========================================
   リスト
======================================== */
.list {
    border: 1px solid #e0e0e0;
    border-radius: 8px;
    overflow: hidden;
}

.list-header {
    background: #f5f5f5;
    padding: 12px 16px;
    display: flex;
    gap: 16px;
    font-size: 12px;
    color: #666;
    border-bottom: 1px solid #e0e0e0;
}

.list-item {
    padding: 12px 16px;
    border-bottom: 1px solid #f0f0f0;
    display: flex;
    align-items: center;
    gap: 12px;
}

.list-item:last-child {
    border-bottom: none;
}

.list-item:hover {
    background: #fafafa;
}

/* ========================================
   グリッド
======================================== */
.grid {
    display: grid;
    gap: 16px;
}

.grid-3 {
    grid-template-columns: repeat(3, 1fr);
}

.grid-4 {
    grid-template-columns: repeat(4, 1fr);
}

/* ========================================
   カードグリッド（プレイリスト用）
======================================== */
.playlist-card {
    background: #fff;
    border: 1px solid #e0e0e0;
    border-radius: 8px;
    overflow: hidden;
}

.playlist-card-image {
    height: 120px;
    background: #e5e5e5;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #999;
    font-size: 11px;
}

.playlist-card-body {
    padding: 12px;
}

.playlist-card-tag {
    display: inline-block;
    padding: 2px 8px;
    background: #f0f0f0;
    border-radius: 4px;
    font-size: 10px;
    color: #666;
    margin-bottom: 8px;
}

.playlist-card-title {
    font-size: 13px;
    font-weight: 500;
    margin-bottom: 4px;
    color: #333;
}

.playlist-card-subtitle {
    font-size: 11px;
    color: #999;
    margin-bottom: 8px;
}

.playlist-card-meta {
    font-size: 11px;
    color: #666;
}

/* ========================================
   タグ
======================================== */
.tag {
    display: inline-block;
    padding: 4px 10px;
    background: #f0f0f0;
    border-radius: 4px;
    font-size: 11px;
    color: #666;
    margin: 2px;
}

.tag-group {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-bottom: 16px;
}

/* ========================================
   バナー
======================================== */
.banner {
    background: linear-gradient(135deg, #e5e5e5, #f0f0f0);
    border: 1px dashed #ccc;
    border-radius: 8px;
    padding: 24px;
    margin-bottom: 24px;
    text-align: center;
    color: #666;
}

.banner-text {
    font-size: 14px;
}

/* ========================================
   日付グループ
======================================== */
.date-group {
    margin-bottom: 24px;
}

.date-label {
    font-size: 12px;
    color: #999;
    margin-bottom: 8px;
    padding: 4px 0;
}

/* ========================================
   進捗表示
======================================== */
.progress-text {
    font-size: 12px;
    color: #666;
}

/* ========================================
   フッター
======================================== */
.footer {
    background: #fff;
    border-top: 1px solid #e0e0e0;
    padding: 24px;
    margin-top: 48px;
}

.footer-links {
    display: flex;
    gap: 24px;
    justify-content: center;
    margin-bottom: 16px;
}

.footer-link {
    font-size: 12px;
    color: #666;
    text-decoration: none;
}

.footer-link:hover {
    color: #333;
}

.footer-copyright {
    text-align: center;
    font-size: 11px;
    color: #999;
}

/* ========================================
   検索結果
======================================== */
.search-result-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 16px;
}

.search-result-count {
    font-size: 16px;
    font-weight: bold;
}

.search-result-count span {
    color: #666;
}

.search-actions {
    display: flex;
    gap: 8px;
}

/* ========================================
   マイリスト用
======================================== */
.mylist-tabs {
    display: flex;
    gap: 8px;
    margin-bottom: 20px;
}

.mylist-tab {
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 8px 16px;
    background: transparent;
    border: none;
    color: #666;
    font-size: 13px;
    cursor: pointer;
    text-decoration: none;
    border-bottom: 2px solid transparent;
}

.mylist-tab:hover {
    color: #333;
}

.mylist-tab.active {
    color: #333;
    border-bottom-color: #333;
}

.mylist-tab-icon {
    width: 16px;
    height: 16px;
    background: #e5e5e5;
    border-radius: 2px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 8px;
    color: #666;
}

/* ========================================
   フィルターバー
======================================== */
.filter-bar {
    display: flex;
    gap: 12px;
    align-items: center;
    margin-bottom: 16px;
    flex-wrap: wrap;
}

/* ========================================
   統計表示
======================================== */
.stats {
    display: flex;
    gap: 16px;
    font-size: 12px;
    color: #666;
    margin-bottom: 16px;
}

.stats-item {
    display: flex;
    gap: 4px;
}

.stats-label {
    color: #999;
}

.stats-value {
    font-weight: 500;
    color: #333;
}

/* ========================================
   ユーティリティ
======================================== */
.text-muted {
    color: #999;
}

.text-small {
    font-size: 12px;
}

.mb-0 { margin-bottom: 0; }
.mb-8 { margin-bottom: 8px; }
.mb-16 { margin-bottom: 16px; }
.mb-24 { margin-bottom: 24px; }

.flex {
    display: flex;
}

.flex-between {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.gap-8 { gap: 8px; }
.gap-16 { gap: 16px; }

/* ========================================
   検索タグ入力
======================================== */
.search-tag-input {
    padding: 8px 12px;
    border: 1px solid #ddd;
    border-radius: 4px;
    background: #fff;
    min-height: 42px;
    display: flex;
    align-items: center;
    gap: 8px;
    flex-wrap: wrap;
}

.search-tag {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    padding: 4px 8px;
    background: #f0f0f0;
    border: 1px solid #ddd;
    border-radius: 4px;
    font-size: 13px;
    color: #333;
}

.search-tag-remove {
    cursor: pointer;
    color: #999;
    font-size: 12px;
}

.result-count-num {
    color: #333;
    font-weight: bold;
}

/* ========================================
   大学カード（検索結果用）
======================================== */
.university-card {
    background: #fff;
    border: 1px solid #e0e0e0;
    border-radius: 8px;
    overflow: hidden;
}

.university-card-header {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 16px 20px;
    border-bottom: 1px solid #e0e0e0;
}

.university-card-badge {
    display: flex;
    gap: 4px;
}

.badge-type {
    padding: 2px 8px;
    background: #e5e5e5;
    color: #666;
    font-size: 11px;
    border-radius: 2px;
}

.badge-region {
    padding: 2px 8px;
    background: #e5e5e5;
    color: #666;
    font-size: 11px;
    border-radius: 2px;
}

.university-card-name {
    flex: 1;
    font-size: 18px;
    font-weight: bold;
    color: #333;
}

.btn-favorite {
    padding: 8px 16px;
    background: #666;
    color: #fff;
    border: none;
    border-radius: 4px;
    font-size: 13px;
    cursor: pointer;
}

.university-card-body {
    padding: 20px;
}

/* 年度セクション */
.year-section {
    margin-bottom: 16px;
}

.year-section-header {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 16px;
}

.year-marker {
    width: 4px;
    height: 20px;
    background: #333;
    border-radius: 2px;
}

.year-label {
    font-size: 15px;
    font-weight: bold;
    color: #333;
}

.year-link {
    margin-left: auto;
    font-size: 12px;
    color: #666;
    text-decoration: none;
}

/* 学部リスト */
.faculty-list {
    border: 1px solid #e0e0e0;
    border-radius: 4px;
}

.faculty-item {
    padding: 12px 16px;
    border-bottom: 1px solid #f0f0f0;
    display: grid;
    grid-template-columns: 200px 180px 1fr;
    align-items: center;
    gap: 16px;
}

.faculty-item:last-child {
    border-bottom: none;
}

.faculty-name {
    font-size: 14px;
    font-weight: 500;
    color: #333;
}

.faculty-schedule {
    font-size: 12px;
    color: #666;
}

.subject-links {
    display: flex;
    gap: 6px;
    flex-wrap: wrap;
}

.subject-link {
    display: inline-block;
    padding: 4px 10px;
    font-size: 12px;
    color: #333;
    text-decoration: none;
    border: 1px solid #ccc;
    border-radius: 3px;
    background: #fff;
}

.subject-link:hover {
    background: #f5f5f5;
    border-color: #999;
}

.subject-link.subject-highlight {
    background: #f0f0f0;
    border-color: #999;
}

/* パスナビバナー */
.passnavi-banner {
    display: flex;
    align-items: center;
    gap: 16px;
    padding: 16px;
    background: #f5f5f5;
    border-radius: 4px;
    margin-top: 16px;
}

.passnavi-logo {
    padding: 4px 12px;
    background: #666;
    color: #fff;
    font-size: 12px;
    font-weight: bold;
    border-radius: 4px;
}

.passnavi-text {
    font-size: 13px;
    color: #333;
}

.passnavi-btn {
    padding: 6px 12px;
    font-size: 12px;
}

/* ========================================
   問題詳細画面
======================================== */
.ad-banner {
    background: #e5e5e5;
    border: 1px dashed #ccc;
    border-radius: 4px;
    padding: 24px;
    margin-bottom: 16px;
    text-align: center;
}

.ad-banner-content {
    color: #999;
    font-size: 12px;
}

.ad-banner-bottom {
    margin-top: 24px;
    margin-bottom: 0;
}

.breadcrumb {
    margin-bottom: 16px;
}

.breadcrumb-link {
    font-size: 13px;
    color: #666;
    text-decoration: none;
}

.content-tabs {
    display: flex;
    gap: 4px;
    margin-bottom: 16px;
    border-bottom: 1px solid #e0e0e0;
}

.content-tab {
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 12px 20px;
    background: transparent;
    border: none;
    color: #666;
    font-size: 14px;
    cursor: pointer;
    border-bottom: 3px solid transparent;
}

.content-tab.active {
    color: #333;
    border-bottom-color: #333;
    font-weight: 500;
}

.content-tab-icon {
    width: 20px;
    height: 20px;
    background: #e5e5e5;
    border-radius: 4px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 8px;
    color: #666;
}

.action-buttons {
    display: flex;
    justify-content: flex-end;
    gap: 8px;
    margin-bottom: 16px;
}

.btn-action {
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 8px 16px;
    font-size: 13px;
}

.btn-action.active {
    background: #666;
    color: #fff;
    border-color: #666;
}

.btn-icon {
    width: 16px;
    height: 16px;
    background: #e5e5e5;
    border-radius: 2px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 8px;
}

.btn-action.active .btn-icon {
    background: rgba(255,255,255,0.3);
    color: #fff;
}

/* 問題コンテンツ */
.problem-content {
    background: #fff;
    border: 1px solid #e0e0e0;
    border-radius: 8px;
    padding: 32px;
}

.problem-university {
    font-size: 24px;
    font-weight: bold;
    color: #333;
    text-align: center;
    margin-bottom: 8px;
}

.problem-title {
    font-size: 16px;
    font-weight: normal;
    color: #333;
    text-align: center;
    margin-bottom: 24px;
}

.problem-meta {
    margin-bottom: 16px;
    font-size: 13px;
    color: #333;
    line-height: 1.8;
}

.problem-meta-item {
    margin-bottom: 2px;
}

.problem-note {
    font-size: 12px;
    color: #666;
    margin-bottom: 32px;
    padding: 12px;
    background: #f9f9f9;
    border-radius: 4px;
}

.problem-question {
    display: flex;
    gap: 16px;
    margin-bottom: 32px;
    padding-bottom: 32px;
    border-bottom: 1px solid #e0e0e0;
}

.problem-question:last-of-type {
    border-bottom: none;
}

.problem-number {
    width: 32px;
    height: 32px;
    background: #333;
    color: #fff;
    border-radius: 4px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 16px;
    font-weight: bold;
    flex-shrink: 0;
}

.problem-body {
    flex: 1;
}

.problem-placeholder {
    font-size: 14px;
    line-height: 1.8;
    color: #333;
}

.problem-copyright {
    text-align: center;
    font-size: 11px;
    color: #999;
    margin-top: 32px;
    padding-top: 16px;
    border-top: 1px solid #e0e0e0;
}

/* ========================================
   モーダル
======================================== */
.modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.5);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 1000;
}

.modal {
    background: #fff;
    border-radius: 8px;
    width: 100%;
    max-width: 700px;
    max-height: 90vh;
    overflow-y: auto;
    box-shadow: 0 4px 24px rgba(0, 0, 0, 0.2);
}

.modal-header {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 20px 24px;
    border-bottom: 1px solid #e0e0e0;
    font-size: 18px;
    font-weight: bold;
    color: #333;
}

.modal-icon {
    width: 24px;
    height: 24px;
    background: #666;
    color: #fff;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 14px;
}

.modal-body {
    padding: 24px;
}

.modal-description {
    font-size: 14px;
    color: #333;
    line-height: 1.6;
    margin-bottom: 16px;
}

.modal-link {
    color: #333;
    text-decoration: underline;
}

.modal-legend {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    margin-bottom: 20px;
    padding: 12px;
    background: #f9f9f9;
    border-radius: 4px;
    font-size: 13px;
    color: #666;
}

.legend-item {
    display: flex;
    align-items: center;
    gap: 4px;
}

.status-circle {
    color: #333;
    font-weight: bold;
}

.status-triangle {
    color: #666;
    font-weight: bold;
}

.status-cross {
    color: #999;
    font-weight: bold;
}

.modal-progress {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 20px;
}

.progress-label {
    font-size: 13px;
    color: #666;
}

.progress-bar {
    flex: 1;
    height: 8px;
    background: #e0e0e0;
    border-radius: 4px;
    overflow: hidden;
}

.progress-fill {
    height: 100%;
    background: #666;
    border-radius: 4px;
}

.progress-count {
    font-size: 14px;
    font-weight: bold;
    color: #333;
}

/* ステータスリスト */
.status-list {
    border: 1px solid #e0e0e0;
    border-radius: 4px;
}

.status-list-header {
    display: grid;
    grid-template-columns: 80px 1fr 100px;
    gap: 8px;
    padding: 10px 16px;
    background: #f5f5f5;
    border-bottom: 1px solid #e0e0e0;
    font-size: 12px;
    color: #666;
}

.status-list-header .status-col-name {
    text-align: left;
}

.status-list-header .status-col-selector {
    text-align: center;
}

.status-list-header .status-col-date {
    text-align: right;
}

.status-list-item {
    display: grid;
    grid-template-columns: 80px 1fr 100px;
    gap: 8px;
    padding: 12px 16px;
    border-bottom: 1px solid #f0f0f0;
    align-items: center;
    font-size: 14px;
}

.status-list-item:last-child {
    border-bottom: none;
}

.status-col-name {
    font-weight: 500;
    color: #333;
}

.status-col-selector {
    display: flex;
    justify-content: center;
}

.status-col-date {
    text-align: right;
    font-size: 12px;
    color: #666;
}

.modal-note {
    margin-top: 16px;
    font-size: 12px;
    color: #999;
}

.modal-footer {
    display: flex;
    justify-content: flex-end;
    gap: 12px;
    padding: 16px 24px;
    border-top: 1px solid #e0e0e0;
    background: #fafafa;
}

.modal-btn-cancel {
    min-width: 100px;
}

.modal-btn-save {
    min-width: 100px;
}

/* ラジオボタングループ（◯△✕選択用） */
.status-radio-group {
    display: flex;
    gap: 0;
}

.status-radio-label {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 36px;
    height: 32px;
    border: 1px solid #ccc;
    background: #fff;
    cursor: pointer;
    font-size: 14px;
    color: #666;
    margin-left: -1px;
}

.status-radio-label:first-child {
    margin-left: 0;
    border-radius: 4px 0 0 4px;
}

.status-radio-label:last-child {
    border-radius: 0 4px 4px 0;
}

.status-radio-label:hover {
    background: #f5f5f5;
}

.status-radio-label.selected {
    background: #e5e5e5;
    border-color: #999;
    color: #333;
    font-weight: bold;
}

.status-radio-input {
    display: none;
}

/* 省略リンク */
.faculty-more {
    padding: 12px 16px;
    text-align: center;
    border-top: 1px solid #e0e0e0;
}

.faculty-more-link {
    font-size: 13px;
    color: #666;
    text-decoration: none;
}

.faculty-more-link:hover {
    text-decoration: underline;
}
