/* AlphaScore - LAMPスタイルシート */
/* フレームワーク不使用、素のCSS */

:root {
    --primary: #2563eb;
    --primary-dark: #1d4ed8;
    --secondary: #64748b;
    --success: #16a34a;
    --danger: #dc2626;
    --warning: #d97706;
    --bg: #f8fafc;
    --surface: #ffffff;
    --text: #1e293b;
    --text-muted: #64748b;
    --border: #e2e8f0;
    --radius: 8px;
    --shadow: 0 1px 3px rgba(0,0,0,0.1);
}

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

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    background: var(--bg);
    color: var(--text);
    line-height: 1.6;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

/* レイアウト */
.container { max-width: 1100px; margin: 0 auto; padding: 0 1rem; }
main.container { flex: 1; padding-top: 2rem; padding-bottom: 3rem; }

/* ヘッダー */
.site-header {
    background: var(--surface);
    border-bottom: 1px solid var(--border);
    position: sticky; top: 0; z-index: 100;
}
.nav-container {
    max-width: 1100px; margin: 0 auto; padding: 0.75rem 1rem;
    display: flex; align-items: center; justify-content: space-between;
}
.logo { font-weight: 700; font-size: 1.25rem; color: var(--primary); text-decoration: none; }
.nav-links { display: flex; align-items: center; gap: 1rem; }
.nav-links a { color: var(--text); text-decoration: none; font-size: 0.9rem; }
.nav-links a:hover { color: var(--primary); }
.nav-user { font-size: 0.85rem; color: var(--text-muted); }
.nav-notif { position: relative; }
.notif-badge {
    position: absolute; top: -6px; right: -8px;
    background: var(--danger); color: #fff; font-size: 0.7rem;
    width: 18px; height: 18px; border-radius: 50%;
    display: flex; align-items: center; justify-content: center;
}

/* フッター */
.site-footer {
    background: var(--surface); border-top: 1px solid var(--border);
    padding: 1.5rem 0; text-align: center; color: var(--text-muted); font-size: 0.85rem;
}

/* ボタン */
.btn {
    display: inline-block; padding: 0.5rem 1rem; border-radius: var(--radius);
    text-decoration: none; font-size: 0.9rem; font-weight: 500;
    border: 1px solid var(--border); background: var(--surface); color: var(--text);
    cursor: pointer; transition: all 0.15s;
}
.btn:hover { background: var(--bg); }
.btn-primary { background: var(--primary); color: #fff; border-color: var(--primary); }
.btn-primary:hover { background: var(--primary-dark); }
.btn-secondary { background: var(--secondary); color: #fff; border-color: var(--secondary); }
.btn-danger { background: var(--danger); color: #fff; border-color: var(--danger); }
.btn-sm { padding: 0.3rem 0.7rem; font-size: 0.8rem; }
.btn-block { display: block; width: 100%; text-align: center; margin-bottom: 0.5rem; }

/* カード */
.card {
    background: var(--surface); border: 1px solid var(--border);
    border-radius: var(--radius); padding: 1.5rem; box-shadow: var(--shadow);
}
.card h3 { margin-bottom: 1rem; font-size: 1.1rem; }

/* アラート */
.alert {
    padding: 0.75rem 1rem; border-radius: var(--radius); margin-bottom: 1rem;
    font-size: 0.9rem;
}
.alert-success { background: #dcfce7; color: #166534; border: 1px solid #bbf7d0; }
.alert-error { background: #fef2f2; color: #991b1b; border: 1px solid #fecaca; }
.alert-warning { background: #fffbeb; color: #92400e; border: 1px solid #fde68a; }

/* フォーム */
.form-group { margin-bottom: 1rem; }
.form-group label { display: block; font-weight: 500; margin-bottom: 0.3rem; font-size: 0.9rem; }
.form-control {
    width: 100%; padding: 0.5rem 0.75rem; border: 1px solid var(--border);
    border-radius: var(--radius); font-size: 0.9rem; background: var(--surface);
}
.form-control:focus { outline: none; border-color: var(--primary); box-shadow: 0 0 0 3px rgba(37,99,235,0.1); }
select.form-control { appearance: auto; }
textarea.form-control { resize: vertical; min-height: 80px; }

/* テーブル */
.table { width: 100%; border-collapse: collapse; }
.table th, .table td { padding: 0.75rem; text-align: left; border-bottom: 1px solid var(--border); }
.table th { font-weight: 600; font-size: 0.85rem; color: var(--text-muted); }
.table tr:hover { background: var(--bg); }

/* ヒーロー */
.hero { text-align: center; padding: 4rem 1rem; }
.hero h1 { font-size: 3rem; color: var(--primary); margin-bottom: 0.5rem; }
.hero-subtitle { font-size: 1.3rem; color: var(--text-muted); margin-bottom: 1rem; }
.hero p { max-width: 600px; margin: 0 auto 2rem; color: var(--text-muted); }
.hero-actions { display: flex; gap: 1rem; justify-content: center; }

/* 機能カード */
.feature-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 1.5rem; }
.feature-card { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); padding: 1.5rem; }
.feature-card h3 { margin-bottom: 0.5rem; }
.feature-card p { color: var(--text-muted); font-size: 0.9rem; }

/* ダッシュボード */
.dashboard-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); gap: 1.5rem; margin-top: 1.5rem; }

/* リスト */
.team-list, .match-list { list-style: none; }
.team-list li, .match-list li { padding: 0.5rem 0; border-bottom: 1px solid var(--border); }
.team-list li:last-child, .match-list li:last-child { border-bottom: none; }
.team-list a, .match-list a { text-decoration: none; color: var(--text); display: flex; align-items: center; gap: 0.5rem; }
.team-list a:hover, .match-list a:hover { color: var(--primary); }

/* バッジ */
.badge {
    display: inline-block; padding: 0.15rem 0.5rem; border-radius: 99px;
    font-size: 0.75rem; background: #e0e7ff; color: #3730a3;
}
.badge-success { background: #dcfce7; color: #166534; }
.badge-warning { background: #fef3c7; color: #92400e; }
.badge-danger { background: #fef2f2; color: #991b1b; }
.badge-test { background: #fef9c3; color: #854d0e; border: 1px solid #fde047; }
.alert-info { background: #eff6ff; color: #1e40af; border: 1px solid #bfdbfe; }

/* ステータス */
.status-scheduled { color: var(--warning); }
.status-in_progress { color: var(--primary); font-weight: 600; }
.status-completed { color: var(--success); }
.status-cancelled { color: var(--text-muted); text-decoration: line-through; }

/* ユーティリティ */
.text-muted { color: var(--text-muted); font-size: 0.85rem; }
.text-center { text-align: center; }
.mt-1 { margin-top: 1rem; }
.mt-2 { margin-top: 2rem; }
.mb-1 { margin-bottom: 1rem; }

/* レスポンシブ */
@media (max-width: 768px) {
    .hero h1 { font-size: 2rem; }
    .hero-actions { flex-direction: column; align-items: center; }
    .dashboard-grid { grid-template-columns: 1fr; }
    .nav-links { gap: 0.5rem; }
}


/* 言語切り替え */
.lang-switch { margin-left: 0.5rem; position: relative; }
.lang-btn {
    font-size: 1.4rem; background: none; border: none; cursor: pointer;
    padding: 0.2rem; line-height: 1; border-radius: 4px;
}
.lang-btn:hover { background: var(--bg); }
.lang-menu {
    display: none; position: absolute; right: 0; top: 2.2rem;
    background: var(--surface); border: 1px solid var(--border);
    border-radius: var(--radius); box-shadow: 0 4px 12px rgba(0,0,0,0.1);
    z-index: 200; min-width: 120px; overflow: hidden;
}
.lang-menu.show { display: block; }
.lang-menu a {
    display: block; padding: 0.5rem 0.75rem; text-decoration: none;
    color: var(--text); font-size: 0.9rem; white-space: nowrap;
}
.lang-menu a:hover { background: var(--bg); }
.lang-menu a.active { background: #e0e7ff; font-weight: 600; }
