/* =====================================================
   Tennis Predictor – Modern Tailwind-based Custom Styles
   ===================================================== */

:root {
  --color-tennis: #7acc42;
  --color-tennis-dark: #5fae36;
  --color-midnight: #0f172a;
  --color-stone: #94a3b8;
  --color-amber: #f59e0b;
}

body {
  color: #0f172a;
  font-family: Inter, 'Segoe UI', Roboto, sans-serif;
  background: linear-gradient(180deg, #f8fafc 0%, #ffffff 100%);
}

/* Navigation */
.nav-link {
  display: inline-flex;
  align-items: center;
  padding: 0.45rem 0.8rem;
  color: #1f2937;
  border-radius: 0.5rem;
  transition: all 0.18s ease-in-out;
  text-decoration: none;
}

.nav-link:hover,
.nav-link:focus {
  color: var(--color-tennis-dark);
  background: rgba(122, 204, 66, 0.12);
  transform: translateY(-1px);
}

.alert {
  border-radius: 0.75rem;
  border: 1px solid rgba(15, 23, 42, 0.08);
  background: #f8fafc;
  color: #0f172a;
}

.alert-info { background: #cff4fc; }
.alert-success { background: #dcfce7; }
.alert-warning { background: #fef3c7; }
.alert-danger { background: #fee2e2; }

/* Standard content components for existing Bulma classes */
.title,
.heading,
.subtitle {
  color: var(--color-midnight);
  font-weight: 700;
}

.title { font-size: 1.55rem; margin-bottom: 0.75rem; }
.subtitle { font-size: 1.15rem; margin-bottom: 0.5rem; }

.notification,
.box,
.tabs,
.field,
.level {
  background: #ffffff;
  border: 1px solid rgba(15, 23, 42, 0.08);
  border-radius: 0.75rem;
  padding: 0.9rem;
  box-shadow: 0 8px 20px rgba(15, 23, 42, 0.05);
}

.notification { background: #ecfdf5; border-color: rgba(122, 204, 66, 0.35); }

.box:hover,
.match-card:hover,
.table tbody tr:hover {
  box-shadow: 0 8px 22px rgba(15, 23, 42, 0.12);
}

/* Table styling */
.table {
  width: 100%;
  border-collapse: collapse;
  border-radius: 0.75rem;
  overflow: hidden;
  background: #fff;
  border: 1px solid rgba(15, 23, 42, 0.08);
}

.table th,
.table td {
  border-bottom: 1px solid rgba(15, 23, 42, 0.08);
  padding: 0.75rem 0.9rem;
  text-align: left;
}

.table thead th {
  background: #f1f5f9;
  color: #1f2937;
  font-weight: 700;
}

.table tbody tr {
  transition: background-color 0.2s ease, transform 0.2s ease;
}

.table tbody tr:hover {
  background-color: #f0fdf4;
  transform: translateY(-1px);
}

.table tbody tr td a {
  color: #0f172a;
  text-decoration: none;
  transition: color 0.2s ease;
}

.table tbody tr td a:hover {
  color: var(--color-tennis);
}

/* Match card and progress */
.match-card {
  border-radius: 0.9rem;
  border: 1px solid rgba(15, 23, 42, 0.1);
  background: #ffffff;
  padding: 1rem;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.match-card:hover {
  transform: translateY(-2px);
  box-shadow: 0 12px 26px rgba(15, 23, 42, 0.14);
}

.prob-bar {
  width: 100%;
  height: 0.6rem;
  background: #e2e8f0;
  border-radius: 999px;
  overflow: hidden;
  border: 1px solid #cbd5e1;
}

.prob-fill {
  height: 100%;
  border-radius: 999px;
  transition: width 0.4s ease;
}

.prob-fill.is-p1 { background: linear-gradient(90deg, #7acc42 0%, #45b836 100%); }
.prob-fill.is-p2 { background: linear-gradient(90deg, #f59e0b 0%, #ea580c 100%); }

.player-name.predicted-winner,
.tag.is-success,
.has-text-success {
  color: var(--color-tennis-dark) !important;
}

.tag.is-info { background-color: #0ea5e9; color: white; }
.tag.is-warning { background-color: #f59e0b; color: white; }
.tag.is-danger { background-color: #ef4444; color: white; }

.progress.is-small { height: 0.5rem; }

.table th { white-space: nowrap; }

code { background: #f1f5f9; padding: 0.1rem 0.25rem; border-radius: 0.25rem; }

/* Affiliate ad sidebar — stack below matches on small screens */
@media (max-width: 900px) {
  .home-layout { flex-direction: column !important; }
  .home-ad { flex: unset !important; width: 300px; margin: 0 auto; }
}

/* Forms */
.input,
select,
.button,
.field input,
.field select {
  padding: 0.55rem 0.75rem;
  border: 1px solid #cbd5e1;
  border-radius: 0.5rem;
  background: #fff;
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.input:focus,
select:focus,
.field input:focus,
.field select:focus {
  outline: none;
  border-color: var(--color-tennis);
  box-shadow: 0 0 0 3px rgba(122, 204, 66, 0.2);
}

