/* 基本レイアウト */
.subtitle {
    text-align: center;
    color: #64748b;
    font-size: 1.1rem;
    margin-bottom: 2rem;
}

.main-container {
    display: flex;
    flex-direction: column;
    gap: 2rem;
    max-width: 1000px;
    margin: 0 auto;
}

.card {
    background: white;
    border-radius: 12px;
    padding: 2rem;
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
}

.section-title {
    font-size: 1.5rem;
    font-weight: 600;
    color: #334155;
    margin-bottom: 1.5rem;
    padding-bottom: 0.75rem;
    border-bottom: 2px solid #f1f5f9;
}

/* 現在の番号表示 */
.current-number-display {
    text-align: center;
    margin-bottom: 2rem;
    padding: 2rem;
    background: linear-gradient(135deg, #3b82f6 0%, #2563eb 100%);
    border-radius: 12px;
    box-shadow: 0 8px 20px rgba(59, 130, 246, 0.4);
}

.current-number {
    font-size: 6rem;
    font-weight: 700;
    color: white;
    text-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
    font-family: 'Arial Black', sans-serif;
    animation: pulse 1s ease-in-out;
}

.current-number.drawn {
    animation: popIn 0.5s ease-out;
}

@keyframes pulse {
    0%, 100% { transform: scale(1); }
    50% { transform: scale(1.05); }
}

@keyframes popIn {
    0% {
        transform: scale(0);
        opacity: 0;
    }
    50% {
        transform: scale(1.2);
    }
    100% {
        transform: scale(1);
        opacity: 1;
    }
}

.current-label {
    font-size: 1.1rem;
    color: #dbeafe;
    font-weight: 600;
    margin-top: 1rem;
}

/* 統計バー */
.stats-bar {
    display: flex;
    justify-content: center;
    gap: 3rem;
    margin-bottom: 2rem;
    padding: 1.5rem;
    background: #f8fafc;
    border-radius: 8px;
}

.stat-item {
    text-align: center;
}

.stat-label {
    display: block;
    font-size: 0.9rem;
    color: #64748b;
    font-weight: 600;
    margin-bottom: 0.5rem;
}

.stat-value {
    display: block;
    font-size: 2rem;
    color: #3b82f6;
    font-weight: 700;
}

/* ボタン */
.button-row {
    display: flex;
    gap: 1rem;
    margin-bottom: 1.5rem;
}

.action-btn {
    flex: 1;
    padding: 1rem;
    border: 2px solid #e2e8f0;
    border-radius: 8px;
    font-weight: 600;
    font-size: 1.1rem;
    cursor: pointer;
    transition: all 0.2s;
}

.action-btn.primary {
    background: linear-gradient(135deg, #10b981 0%, #059669 100%);
    color: white;
    border-color: #10b981;
    box-shadow: 0 4px 12px rgba(16, 185, 129, 0.3);
}

.action-btn.primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 16px rgba(16, 185, 129, 0.4);
}

.action-btn.primary:disabled {
    background: #94a3b8;
    border-color: #94a3b8;
    cursor: not-allowed;
    transform: none;
    box-shadow: none;
}

.action-btn.secondary {
    background: white;
    color: #64748b;
}

.action-btn.secondary:hover {
    border-color: #94a3b8;
    color: #475569;
}

/* 抽選履歴 */
.history-list {
    display: flex;
    flex-wrap: wrap;
    gap: 0.75rem;
    min-height: 100px;
}

.history-item {
    width: 60px;
    height: 60px;
    background: linear-gradient(135deg, #dbeafe 0%, #bfdbfe 100%);
    border: 2px solid #60a5fa;
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    font-weight: 700;
    color: #1e40af;
    animation: slideIn 0.3s ease-out;
}

@keyframes slideIn {
    from {
        transform: scale(0);
        opacity: 0;
    }
    to {
        transform: scale(1);
        opacity: 1;
    }
}

.empty-state {
    width: 100%;
    text-align: center;
    color: #94a3b8;
    padding: 2rem;
    font-size: 1.1rem;
}

/* 番号グリッド */
.number-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(50px, 1fr));
    gap: 0.5rem;
}

.number-cell {
    aspect-ratio: 1;
    background: #f8fafc;
    border: 2px solid #e2e8f0;
    border-radius: 6px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.1rem;
    font-weight: 600;
    color: #475569;
    transition: all 0.2s;
}

.number-cell.drawn {
    background: linear-gradient(135deg, #ef4444 0%, #dc2626 100%);
    border-color: #ef4444;
    color: white;
    transform: scale(0.95);
}

/* 使い方 */
.usage-content {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
    margin-bottom: 2rem;
}

.usage-step {
    display: flex;
    gap: 1rem;
    align-items: flex-start;
}

.step-number {
    width: 40px;
    height: 40px;
    background: #3b82f6;
    color: white;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    flex-shrink: 0;
}

.step-text h3 {
    font-size: 1.1rem;
    font-weight: 600;
    color: #334155;
    margin-bottom: 0.5rem;
}

.step-text p {
    color: #64748b;
    line-height: 1.6;
}

/* ヒントセクション */
.tips-section {
    background: #eff6ff;
    border: 2px solid #93c5fd;
    border-radius: 8px;
    padding: 1.5rem;
    margin-bottom: 1.5rem;
}

.tips-title {
    font-size: 1.1rem;
    font-weight: 600;
    color: #1e40af;
    margin-bottom: 1rem;
}

.tips-text {
    color: #1e40af;
    line-height: 1.8;
}

/* フロー例 */
.example-section {
    background: #f0fdf4;
    border: 2px solid #86efac;
    border-radius: 8px;
    padding: 1.5rem;
    margin-bottom: 1.5rem;
}

.example-title {
    font-size: 1.1rem;
    font-weight: 600;
    color: #166534;
    margin-bottom: 1rem;
}

.flow-steps {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.flow-item {
    background: white;
    border-radius: 6px;
    padding: 1rem;
}

.flow-number {
    font-size: 0.85rem;
    color: #166534;
    font-weight: 600;
    margin-bottom: 0.5rem;
}

.flow-desc {
    font-family: 'Courier New', monospace;
    font-size: 0.9rem;
    color: #15803d;
}

.flow-arrow {
    text-align: center;
    font-size: 1.5rem;
    color: #22c55e;
    font-weight: 700;
}

/* ユースケース */
.use-cases {
    background: #fef3c7;
    border: 2px solid #fbbf24;
    border-radius: 8px;
    padding: 1.5rem;
}

.use-cases-title {
    font-size: 1.1rem;
    font-weight: 600;
    color: #92400e;
    margin-bottom: 1rem;
}

.use-cases-list {
    list-style: none;
    padding: 0;
    margin: 0;
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.use-cases-list li {
    color: #92400e;
    padding-left: 1.5rem;
    position: relative;
    line-height: 1.6;
}

.use-cases-list li::before {
    content: "✓";
    position: absolute;
    left: 0;
    color: #f59e0b;
    font-weight: 700;
}

/* ビンゴカード生成ツールへのリンク */
.related-bingo-tool {
    background: linear-gradient(135deg, #eff6ff 0%, #dbeafe 100%);
    border: 2px solid #93c5fd;
}

.bingo-link-content {
    display: flex;
    align-items: center;
    gap: 1.5rem;
}

.bingo-link-icon {
    font-size: 4rem;
    flex-shrink: 0;
}

.bingo-link-text {
    flex: 1;
}

.bingo-link-text h3 {
    font-size: 1.3rem;
    font-weight: 700;
    color: #1e40af;
    margin-bottom: 0.5rem;
}

.bingo-link-text p {
    color: #1e40af;
    line-height: 1.6;
}

.bingo-link-btn {
    padding: 0.875rem 1.5rem;
    background: linear-gradient(135deg, #3b82f6 0%, #2563eb 100%);
    color: white;
    border-radius: 8px;
    font-weight: 600;
    text-decoration: none;
    white-space: nowrap;
    transition: all 0.2s;
    box-shadow: 0 4px 12px rgba(59, 130, 246, 0.3);
    display: inline-block;
}

.bingo-link-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 16px rgba(59, 130, 246, 0.4);
}

/* 関連ツール */
#relatedToolsContainer {
    margin-top: 3rem;
}

/* 広告セクション */
.ad-section {
    margin-top: 3rem;
    text-align: center;
}

/* レスポンシブ */
@media (max-width: 768px) {
    .current-number {
        font-size: 4rem;
    }

    .button-row {
        flex-direction: column;
    }

    .stats-bar {
        gap: 2rem;
    }

    .number-grid {
        grid-template-columns: repeat(auto-fill, minmax(45px, 1fr));
    }

    .card {
        padding: 1.5rem;
    }
}
