:root {
    --primary: #0f172a;
    --bg: #f8fafc;
    --card-bg: #ffffff;
    --japan-red: #bc002d;
    --korea-blue: #0047a0;
    --border: #e2e8f0;
    --text: #334155;
    --text-light: #64748b;
}

* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
}

body {
    background-color: var(--bg);
    color: var(--text);
    padding: 16px;
    line-height: 1.5;
}

header {
    text-align: center;
    margin-bottom: 24px;
    padding: 20px 0;
    border-bottom: 2px solid var(--border);
}

header h1 {
    font-size: 20px;
    color: var(--primary);
    margin-bottom: 6px;
}

header p {
    font-size: 14px;
    color: var(--text-light);
}

.filters {
    display: table;
    margin: 0 auto 24px auto;
    border-spacing: 8px 0;
}

.filter-btn {
    display: table-cell;
    background: var(--card-bg);
    border: 1px solid var(--border);
    padding: 8px 16px;
    border-radius: 20px;
    cursor: pointer;
    font-size: 13px;
    font-weight: 600;
    transition: all 0.2s ease;
    text-align: center;
}

.filter-btn.active {
    background: var(--primary);
    color: white;
    border-color: var(--primary);
}

.timeline {
    display: flex;
    flex-direction: column;
    max-width: 600px;
    margin: 0 auto;
}

.card {
    background: var(--card-bg);
    border: 1px solid var(--border);
    border-radius: 12px;
    padding: 16px;
    margin-bottom: 16px;
    box-shadow: 0 1px 3px rgba(0,0,0,0.02);
    transition: transform 0.2s;
    order: 1;
    transition: all 0.3s ease;
}

.card.concluido {
    order: 2; 
    opacity: 0.6; 
    background: #f1f5f9; 
    border-color: #cbd5e1;
}

.card.concluido .badge {
    background: #cbd5e1 !important;
    color: #475569 !important;
}

.card.hidden {
    display: none !important;
}

.card-header {
    display: table;
    width: 100%;
    margin-bottom: 12px;
}

.badge {
    display: table-cell;
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
    padding: 2px 8px;
    border-radius: 4px;
    width: 1%;
    white-space: nowrap;
}

.badge-abertura { background: #fef3c7; color: #d97706; }
.badge-encerramento { background: #f3e8ff; color: #7c3aed; }
.badge-jp { background: #fee2e2; color: var(--japan-red); }
.badge-kr { background: #e0f2fe; color: var(--korea-blue); }

.date-time {
    display: table-cell;
    text-align: right;
    font-size: 12px;
    color: var(--text-light);
    vertical-align: middle;
}

.match-title {
    font-size: 15px;
    font-weight: 600;
    margin-bottom: 12px;
    color: var(--primary);
}

.match-row {
    display: table;
    width: 100%;
    margin-top: 8px;
}

.venue {
    display: table-cell;
    font-size: 12px;
    color: var(--text-light);
    vertical-align: middle;
}

.placar-container {
    display: table-cell;
    text-align: right;
    width: 1%;
    white-space: nowrap;
}

.score-input {
    width: 36px;
    height: 28px;
    text-align: center;
    font-size: 14px;
    font-weight: 700;
    border: 1px solid var(--border);
    border-radius: 4px;
    background: #f8fafc;
}

.score-input:focus {
    outline: none;
    border-color: var(--text-light);
}

.x-sep {
    margin: 0 4px;
    font-size: 12px;
    color: var(--text-light);
}

.details-box {
    background: #f8fafc;
    border-radius: 6px;
    padding: 10px;
    font-size: 12px;
    color: var(--text-light);
    margin-top: 12px;
    border-left: 3px solid var(--border);
}

.details-box.jp { border-left-color: var(--japan-red); }
.details-box.kr { border-left-color: var(--korea-blue); }

footer {
    text-align: center;
    margin-bottom: 24px;
    padding: 20px 0;
    border-bottom: 2px solid var(--border);
}

  footer p {
    margin-top: 12px;
    font-size: 10px;
    font-weight: 60;
  }

  footer p i {
    cursor: pointer;
    transition: transform 0.2s, box-shadow 0.2s;
    color: var(--text-light);
  }

  footer p i:hover {
    transform: translateY(-5px);
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.3);
  } 

  footer a {
    text-decoration: none;
    position: relative;
  }

  footer a:hover {
    color: var(--japan-red);
    border-bottom-color: var(--korea-blue);
    cursor: pointer;
  }

  footer a::after {
    content: '';
    position: absolute;
    left: 0;
    bottom: 0;
    width: 0;
    height: 0.125rem;
    background-color: (--text-light);
    transition: width 0.4s ease;
    border-radius: 2px;
  }

  footer a:hover::after {
    width: 100%;
  }

.official-source {
    font-size: 12px;
    color: var(--text-light);
    margin-top: 12px;
    display: block;
}

.official-source a {
    color: var(--korea-blue);
    text-decoration: none;
    font-weight: 600;
}

.official-source a:hover {
    text-decoration: underline;
}