/**
 * Darts Training Hub - Gemeinsame Komponenten
 * ===========================================
 */

/* Page Title */
.page-title {
    background: white;
    padding: 15px 0;
    margin-bottom: 20px;
    border-bottom: 3px solid var(--success-color);
}

.page-title h2 {
    font-size: 1.5rem;
    font-weight: bold;
    margin: 0;
    color: var(--primary-color);
}

.page-title.accent-border {
    border-bottom-color: var(--accent-color);
}

.page-title.secondary-border {
    border-bottom-color: var(--secondary-color);
}

/* Game Panel */
.game-panel {
    background: white;
    border-radius: var(--border-radius);
    padding: 25px;
    box-shadow: var(--box-shadow);
    margin-bottom: 20px;
}

/* Stats Panel */
.stats-panel {
    background: white;
    border-radius: var(--border-radius);
    padding: 20px;
    box-shadow: var(--box-shadow);
    margin-bottom: 20px;
}

.stats-panel h5 {
    color: var(--primary-color);
    font-weight: bold;
    margin-bottom: 15px;
    padding-bottom: 10px;
    border-bottom: 2px solid var(--success-color);
}

/* Stat Row */
.stat-row {
    display: flex;
    justify-content: space-between;
    padding: 8px 0;
    border-bottom: 1px solid #eee;
}

.stat-row:last-child {
    border-bottom: none;
}

.stat-label {
    color: var(--text-muted);
}

.stat-value {
    font-weight: bold;
    color: var(--primary-color);
}

/* Difficulty Badge */
.difficulty-badge {
    display: inline-block;
    padding: 5px 15px;
    border-radius: 20px;
    font-size: 0.8rem;
    font-weight: bold;
    color: white;
}

.difficulty-badge.easy { background: var(--success-color); }
.difficulty-badge.standard { background: var(--warning-color); }
.difficulty-badge.hardcore { background: var(--secondary-color); }
.difficulty-badge.pro { background: var(--secondary-color); }

/* Difficulty Card */
.difficulty-card {
    border: 2px solid #e0e0e0;
    border-radius: var(--border-radius);
    padding: 25px;
    text-align: center;
    transition: all var(--transition-slow);
    cursor: pointer;
    height: 100%;
}

.difficulty-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--box-shadow-hover);
}

.difficulty-card.easy {
    border-color: var(--success-color);
}

.difficulty-card.easy:hover {
    background: linear-gradient(135deg, rgba(39, 174, 96, 0.1), rgba(39, 174, 96, 0.05));
}

.difficulty-card.standard {
    border-color: var(--warning-color);
}

.difficulty-card.standard:hover {
    background: linear-gradient(135deg, rgba(243, 156, 18, 0.1), rgba(243, 156, 18, 0.05));
}

.difficulty-card.hardcore,
.difficulty-card.pro {
    border-color: var(--secondary-color);
}

.difficulty-card.hardcore:hover,
.difficulty-card.pro:hover {
    background: linear-gradient(135deg, rgba(231, 76, 60, 0.1), rgba(231, 76, 60, 0.05));
}

.difficulty-icon {
    font-size: 3rem;
    margin-bottom: 15px;
}

.difficulty-card.easy .difficulty-icon { color: var(--success-color); }
.difficulty-card.standard .difficulty-icon { color: var(--warning-color); }
.difficulty-card.hardcore .difficulty-icon,
.difficulty-card.pro .difficulty-icon { color: var(--secondary-color); }

.difficulty-card h4 {
    font-weight: bold;
    margin-bottom: 10px;
}

.difficulty-card p {
    color: var(--text-muted);
    font-size: 0.9rem;
    margin-bottom: 15px;
}

/* Highscore List */
.highscore-list {
    list-style: none;
    padding: 0;
    margin: 0;
}

.highscore-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 10px;
    background: var(--gray-light);
    border-radius: 6px;
    margin-bottom: 8px;
}

.highscore-rank {
    width: 30px;
    height: 30px;
    border-radius: 50%;
    background: var(--success-color);
    color: white;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: bold;
    font-size: 0.9rem;
}

.highscore-score {
    font-weight: bold;
    font-size: 1.2rem;
    color: var(--primary-color);
}

.highscore-date {
    font-size: 0.8rem;
    color: #999;
}

/* Rules Panel */
.rules-panel {
    background: linear-gradient(135deg, var(--gray-light), var(--gray-medium));
    border-radius: var(--border-radius);
    padding: 20px;
}

.rules-panel h5 {
    color: var(--primary-color);
    font-weight: bold;
    margin-bottom: 15px;
}

.rules-panel ul {
    padding-left: 20px;
    margin-bottom: 0;
}

.rules-panel li {
    margin-bottom: 8px;
    color: #555;
}

/* Active Game Banner */
.active-game-banner {
    background: linear-gradient(135deg, var(--accent-color), #2980b9);
    color: white;
    padding: 20px;
    border-radius: var(--border-radius);
    margin-bottom: 20px;
}

.active-game-banner h4 {
    margin: 0 0 10px 0;
}

.active-game-banner .btn {
    margin-right: 10px;
}

/* Game Header */
.game-header {
    background: linear-gradient(135deg, var(--success-color) 0%, #1abc9c 100%);
    color: white;
    padding: 15px 0;
    margin-bottom: 25px;
}

.game-header h2 {
    font-size: 1.3rem;
    margin: 0;
}

/* Score Display */
.score-display {
    text-align: center;
    padding: 30px;
    background: linear-gradient(135deg, var(--success-color), #229954);
    color: white;
    border-radius: var(--border-radius);
    margin-bottom: 20px;
}

.score-display.negative {
    background: linear-gradient(135deg, var(--secondary-color), #c0392b);
}

.score-display h1 {
    font-size: 4rem;
    font-weight: bold;
    margin: 0;
    line-height: 1;
}

.score-display small {
    font-size: 1rem;
    opacity: 0.9;
}

/* Target Display */
.target-display {
    text-align: center;
    padding: 25px;
    background: linear-gradient(135deg, var(--primary-color), #34495e);
    color: white;
    border-radius: var(--border-radius);
    margin-bottom: 20px;
}

.target-display h2 {
    font-size: 3rem;
    font-weight: bold;
    margin: 0 0 5px 0;
}

.target-display p {
    margin: 0;
    opacity: 0.9;
}

.target-value {
    font-size: 1.2rem;
    background: rgba(255,255,255,0.2);
    padding: 5px 15px;
    border-radius: 20px;
    display: inline-block;
    margin-top: 10px;
}

/* Round Item */
.round-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 10px 15px;
    background: var(--gray-light);
    border-radius: 6px;
    margin-bottom: 8px;
}

.round-item.hit {
    border-left: 4px solid var(--success-color);
}

.round-item.miss {
    border-left: 4px solid var(--secondary-color);
}

/* Progress Dots/Markers */
.progress-marker {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.75rem;
    font-weight: bold;
    background: #e0e0e0;
    color: #999;
    transition: all var(--transition-slow);
}

.progress-marker.completed {
    background: var(--success-color);
    color: white;
}

.progress-marker.current {
    background: var(--primary-color);
    color: white;
    animation: pulse 1.5s infinite;
}

.progress-marker.upcoming {
    background: #f0f0f0;
    color: #bbb;
}

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

/* Timer Display */
.timer-display {
    background: var(--primary-color);
    color: white;
    border-radius: 8px;
    padding: 15px;
    text-align: center;
    margin-bottom: 20px;
}

.timer-display .time {
    font-size: 2rem;
    font-weight: bold;
    font-family: monospace;
}

.timer-display .label {
    font-size: 0.8rem;
    opacity: 0.8;
}

/* Abandon Button */
.btn-abandon {
    width: 100%;
    padding: 10px;
    background: transparent;
    border: 1px solid #ddd;
    color: #999;
    border-radius: 8px;
    font-size: 0.85rem;
    cursor: pointer;
    transition: all var(--transition-normal);
    margin-top: 20px;
}

.btn-abandon:hover {
    border-color: var(--secondary-color);
    color: var(--secondary-color);
}

/* Dart Badge */
.dart-badge {
    padding: 3px 8px;
    border-radius: 4px;
    font-size: 0.75rem;
    font-weight: 600;
}

.dart-badge.hit {
    background: rgba(39, 174, 96, 0.2);
    color: var(--success-color);
}

.dart-badge.miss {
    background: rgba(231, 76, 60, 0.2);
    color: var(--secondary-color);
}
