/**
 * Haupt-Stylesheet für Frontend
 */

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    --primary-color: #1e3a8a;
    --secondary-color: #3b82f6;
    --success-color: #10b981;
    --danger-color: #ef4444;
    --warning-color: #f59e0b;
    --text-color: #1f2937;
    --text-muted: #6b7280;
    --bg-color: #f9fafb;
    --border-color: #e5e7eb;
    --white: #ffffff;
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    color: var(--text-color);
    background-color: var(--bg-color);
    line-height: 1.6;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

/* Header */
.main-header {
    background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
    color: var(--white);
    padding: 1rem 0;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
}

.header-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
}

.logo a {
    color: var(--white);
    text-decoration: none;
    font-size: 1.5rem;
    font-weight: bold;
}

.main-nav {
    display: flex;
    gap: 1rem;
    flex-wrap: wrap;
}

.main-nav a {
    color: var(--white);
    text-decoration: none;
    padding: 0.5rem 1rem;
    border-radius: 5px;
    transition: background-color 0.3s;
}

.main-nav a:hover,
.main-nav a.active {
    background-color: rgba(255,255,255,0.2);
}

/* Main Content */
.main-content {
    min-height: calc(100vh - 200px);
    padding: 2rem 0;
}

/* Footer */
.main-footer {
    background-color: var(--text-color);
    color: var(--white);
    padding: 2rem 0;
    margin-top: 3rem;
    text-align: center;
}

.main-footer a {
    color: var(--white);
    text-decoration: underline;
}

/* Buttons */
.btn {
    display: inline-block;
    padding: 0.75rem 1.5rem;
    border: none;
    border-radius: 5px;
    text-decoration: none;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s;
    font-size: 1rem;
}

.btn-primary {
    background-color: var(--secondary-color);
    color: var(--white);
}

.btn-primary:hover {
    background-color: var(--primary-color);
}

.btn-secondary {
    background-color: var(--text-muted);
    color: var(--white);
}

.btn-secondary:hover {
    background-color: #4b5563;
}

/* Page Header */
.page-header {
    margin-bottom: 2rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 1rem;
}

.page-header h1 {
    color: var(--primary-color);
}

/* Hero Section */
.hero-section {
    text-align: center;
    padding: 3rem 0;
    background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
    color: var(--white);
    border-radius: 10px;
    margin-bottom: 2rem;
}

.hero-section h1 {
    color: var(--white);
    margin-bottom: 1rem;
}

/* Widgets Grid */
.widgets-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
    margin-bottom: 2rem;
}

.widget-card {
    background: var(--white);
    padding: 1.5rem;
    border-radius: 10px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
}

.widget-card h2 {
    color: var(--primary-color);
    margin-bottom: 1rem;
    font-size: 1.25rem;
}

/* Match List */
.match-list {
    list-style: none;
}

.match-item {
    padding: 1rem;
    border-bottom: 1px solid var(--border-color);
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
}

.match-item:last-child {
    border-bottom: none;
}

.match-item.live {
    background-color: #fee2e2;
    border-left: 4px solid var(--danger-color);
}

.match-teams {
    display: flex;
    align-items: center;
    gap: 1rem;
    flex: 1;
    flex-wrap: wrap;
}

.score {
    font-weight: bold;
    font-size: 1.25rem;
    color: var(--primary-color);
}

.match-info {
    display: flex;
    gap: 1rem;
    color: var(--text-muted);
    font-size: 0.9rem;
}

.live-badge {
    background-color: var(--danger-color);
    color: var(--white);
    padding: 0.25rem 0.5rem;
    border-radius: 3px;
    font-weight: bold;
    font-size: 0.9rem;
}

/* Stats List */
.stats-list {
    list-style: none;
    counter-reset: rank;
}

.stats-list li {
    padding: 0.75rem;
    border-bottom: 1px solid var(--border-color);
    display: flex;
    align-items: center;
    gap: 1rem;
}

.stats-list li:last-child {
    border-bottom: none;
}

.rank {
    font-weight: bold;
    color: var(--primary-color);
    min-width: 2rem;
}

.name {
    flex: 1;
}

.value {
    font-weight: bold;
    color: var(--secondary-color);
}

/* News List */
.news-list {
    list-style: none;
}

.news-item {
    background: var(--white);
    padding: 1.5rem;
    border-radius: 10px;
    margin-bottom: 1.5rem;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
}

.news-item h2 {
    margin-bottom: 0.5rem;
}

.news-item h2 a {
    color: var(--primary-color);
    text-decoration: none;
}

.news-item h2 a:hover {
    text-decoration: underline;
}

.news-meta {
    color: var(--text-muted);
    font-size: 0.9rem;
    margin-bottom: 1rem;
    display: flex;
    gap: 1rem;
}

.news-category {
    background-color: var(--border-color);
    padding: 0.25rem 0.5rem;
    border-radius: 3px;
}

.news-article {
    background: var(--white);
    padding: 2rem;
    border-radius: 10px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
}

.news-content {
    margin-top: 1.5rem;
    line-height: 1.8;
}

/* Tables */
.data-table {
    width: 100%;
    border-collapse: collapse;
    background: var(--white);
    border-radius: 10px;
    overflow: hidden;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
}

.data-table th {
    background-color: var(--primary-color);
    color: var(--white);
    padding: 1rem;
    text-align: left;
    font-weight: 600;
}

.data-table td {
    padding: 1rem;
    border-bottom: 1px solid var(--border-color);
}

.data-table tr:last-child td {
    border-bottom: none;
}

.data-table tr:hover {
    background-color: #f3f4f6;
}

.data-table a {
    color: var(--secondary-color);
    text-decoration: none;
}

.data-table a:hover {
    text-decoration: underline;
}

/* League Table */
.league-table {
    width: 100%;
    border-collapse: collapse;
    background: var(--white);
    border-radius: 10px;
    overflow: hidden;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
}

.league-table th {
    background-color: var(--primary-color);
    color: var(--white);
    padding: 1rem;
    text-align: center;
    font-weight: 600;
}

.league-table td {
    padding: 1rem;
    text-align: center;
    border-bottom: 1px solid var(--border-color);
}

.league-table td:first-child {
    font-weight: bold;
    color: var(--primary-color);
}

.league-table td:nth-child(2) {
    text-align: left;
}

/* Content Grid */
.content-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
    margin-bottom: 2rem;
}

.content-card {
    background: var(--white);
    padding: 1.5rem;
    border-radius: 10px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
}

.content-card h2 {
    color: var(--primary-color);
    margin-bottom: 1rem;
}

/* Teams Grid */
.teams-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
    gap: 2rem;
}

.team-card {
    background: var(--white);
    padding: 1.5rem;
    border-radius: 10px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
    text-align: center;
}

.team-logo {
    width: 100px;
    height: 100px;
    object-fit: contain;
    margin-bottom: 1rem;
}

.team-logo-large {
    width: 150px;
    height: 150px;
    object-fit: contain;
}

.team-list {
    list-style: none;
}

.team-list li {
    padding: 0.75rem;
    border-bottom: 1px solid var(--border-color);
}

.team-list li:last-child {
    border-bottom: none;
}

.team-list a {
    display: flex;
    align-items: center;
    gap: 1rem;
    text-decoration: none;
    color: var(--text-color);
}

.team-list a:hover {
    color: var(--secondary-color);
}

/* Leagues Grid */
.leagues-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 2rem;
}

.league-card {
    background: var(--white);
    padding: 1.5rem;
    border-radius: 10px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
}

.league-card h2 {
    color: var(--primary-color);
    margin-bottom: 0.5rem;
}

.league-card h2 a {
    color: inherit;
    text-decoration: none;
}

.league-card h2 a:hover {
    text-decoration: underline;
}

.league-category {
    color: var(--text-muted);
    font-size: 0.9rem;
    margin-bottom: 1rem;
}

/* Livescore */
.livescore-container {
    display: flex;
    flex-direction: column;
    gap: 2rem;
}

.live-match-card {
    background: var(--white);
    padding: 2rem;
    border-radius: 10px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
    border-left: 4px solid var(--danger-color);
}

.live-match-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1.5rem;
}

.live-match-score {
    display: flex;
    justify-content: space-around;
    align-items: center;
    margin-bottom: 2rem;
    flex-wrap: wrap;
    gap: 1rem;
}

.live-match-score .team {
    text-align: center;
}

.live-match-score .team h3 {
    margin-bottom: 1rem;
    color: var(--primary-color);
}

.score-large {
    font-size: 3rem;
    font-weight: bold;
    color: var(--secondary-color);
}

.match-time {
    text-align: center;
}

.minute {
    font-size: 1.5rem;
    font-weight: bold;
    color: var(--danger-color);
}

.liveticker {
    margin-top: 2rem;
    padding-top: 2rem;
    border-top: 1px solid var(--border-color);
}

.liveticker h3 {
    margin-bottom: 1rem;
    color: var(--primary-color);
}

.liveticker-events {
    list-style: none;
    max-height: 300px;
    overflow-y: auto;
}

.liveticker-events li {
    padding: 0.75rem;
    border-bottom: 1px solid var(--border-color);
    display: flex;
    gap: 1rem;
}

.event-minute {
    font-weight: bold;
    color: var(--primary-color);
    min-width: 3rem;
}

/* Filter Box */
.filter-box {
    background: var(--white);
    padding: 1.5rem;
    border-radius: 10px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
    margin-bottom: 2rem;
}

.filter-form {
    display: flex;
    gap: 1rem;
    flex-wrap: wrap;
    align-items: flex-end;
}

.form-group {
    flex: 1;
    min-width: 200px;
}

.form-group label {
    display: block;
    margin-bottom: 0.5rem;
    font-weight: 600;
    color: var(--text-color);
}

.form-group input,
.form-group select {
    width: 100%;
    padding: 0.75rem;
    border: 2px solid var(--border-color);
    border-radius: 5px;
    font-size: 1rem;
}

.form-group input:focus,
.form-group select:focus {
    outline: none;
    border-color: var(--secondary-color);
}

/* Results */
.results-list {
    display: flex;
    flex-direction: column;
    gap: 2rem;
}

.results-day {
    background: var(--white);
    padding: 1.5rem;
    border-radius: 10px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
}

.results-day h2 {
    color: var(--primary-color);
    margin-bottom: 1rem;
    padding-bottom: 0.5rem;
    border-bottom: 2px solid var(--border-color);
}

/* Player Profile */
.player-profile {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
}

.player-info,
.player-stats {
    background: var(--white);
    padding: 1.5rem;
    border-radius: 10px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
}

.info-table {
    width: 100%;
}

.info-table th {
    text-align: left;
    padding: 0.75rem;
    color: var(--text-muted);
    width: 40%;
}

.info-table td {
    padding: 0.75rem;
}

.stats-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1rem;
}

.stat-box {
    text-align: center;
    padding: 1rem;
    background-color: var(--bg-color);
    border-radius: 5px;
}

.stat-value {
    font-size: 2rem;
    font-weight: bold;
    color: var(--secondary-color);
}

.stat-label {
    color: var(--text-muted);
    font-size: 0.9rem;
    margin-top: 0.5rem;
}

/* Badges */
.badge {
    display: inline-block;
    padding: 0.25rem 0.5rem;
    border-radius: 3px;
    font-size: 0.85rem;
    font-weight: 600;
}

.badge-live {
    background-color: var(--danger-color);
    color: var(--white);
}

.badge-finished {
    background-color: var(--text-muted);
    color: var(--white);
}

.badge-upcoming {
    background-color: var(--warning-color);
    color: var(--white);
}

/* Utility Classes */
.text-center {
    text-align: center;
}

.text-muted {
    color: var(--text-muted);
}

.content-box {
    background: var(--white);
    padding: 1.5rem;
    border-radius: 10px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
    margin-bottom: 2rem;
}

.team-header {
    display: flex;
    gap: 2rem;
    align-items: center;
    background: var(--white);
    padding: 2rem;
    border-radius: 10px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
    margin-bottom: 2rem;
}

.team-info {
    flex: 1;
}

.team-league {
    color: var(--text-muted);
    font-size: 0.9rem;
    margin-bottom: 0.5rem;
}

/* Responsive */
@media (max-width: 768px) {
    .header-content {
        flex-direction: column;
        align-items: flex-start;
    }
    
    .main-nav {
        margin-top: 1rem;
        width: 100%;
    }
    
    .main-nav a {
        flex: 1;
        text-align: center;
    }
    
    .page-header {
        flex-direction: column;
        align-items: flex-start;
    }
    
    .widgets-grid,
    .content-grid,
    .teams-grid,
    .leagues-grid {
        grid-template-columns: 1fr;
    }
    
    .live-match-score {
        flex-direction: column;
    }
    
    .stats-grid {
        grid-template-columns: 1fr;
    }
}

