/* ── Fluks SportFun — Publieke webapp ──────────────────────────────────── */
@import url('https://fonts.googleapis.com/css2?family=Bebas+Neue&family=DM+Sans:wght@300;400;500;600;700&display=swap');

:root {
    --orange: #F5A623;
    --orange-light: #FFBE5C;
    --orange-dim: rgba(245, 166, 35, 0.12);
    --blue: #1A8BC4;
    --blue-light: #2B9ED4;
    --blue-dim: rgba(26, 139, 196, 0.1);
    --navy: #0D4F7A;
    --navy-mid: #1A6FA0;
    --white: #FFFFFF;
    --off-white: #F4F8FB;
    --text: #1A2F3F;
    --text-muted: #6B8CA0;
    --border: #D8E8F0;
    --card-shadow: 0 2px 12px rgba(26, 139, 196, 0.08);
    --radius: 14px;
    --radius-sm: 8px;
}

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

html { font-size: 16px; scroll-behavior: smooth; }

body {
    font-family: 'DM Sans', sans-serif;
    background: var(--off-white);
    color: var(--text);
    min-height: 100vh;
    padding-bottom: 80px; /* room for bottom nav */
}

/* ── Typography ─────────────────────────────────── */
h1, h2, h3 { font-family: 'Bebas Neue', sans-serif; letter-spacing: 0.04em; line-height: 1.1; }
h1 { font-size: 2.8rem; }
h2 { font-size: 2rem; }
h3 { font-size: 1.5rem; }
p { line-height: 1.6; }

/* ── Header ─────────────────────────────────────── */
.site-header {
    background: linear-gradient(135deg, var(--navy) 0%, var(--navy-mid) 100%);
    color: white;
    padding: 12px 20px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    position: sticky;
    top: 0;
    z-index: 100;
    box-shadow: 0 2px 20px rgba(13, 79, 122, 0.3);
}

.site-logo {
    display: flex;
    align-items: center;
    gap: 10px;
    text-decoration: none;
    color: white;
}

.logo-mark {
    width: 40px;
    height: 40px;
    border-radius: 8px;
    overflow: hidden;
    flex-shrink: 0;
    background: white;
    display: flex;
    align-items: center;
    justify-content: center;
}

.logo-mark img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    padding: 3px;
}

.logo-text {
    display: flex;
    flex-direction: column;
    line-height: 1.1;
}

.logo-main { font-family: 'Bebas Neue', sans-serif; font-size: 20px; letter-spacing: 0.08em; }
.logo-sub  { font-size: 10px; color: rgba(255,255,255,0.55); font-weight: 500; letter-spacing: 0.12em; text-transform: uppercase; }

.header-actions { display: flex; gap: 8px; align-items: center; }

.btn-fav {
    background: transparent;
    border: 1.5px solid rgba(255,255,255,0.25);
    color: white;
    border-radius: 8px;
    padding: 6px 12px;
    font-size: 12px;
    font-weight: 600;
    cursor: pointer;
    text-decoration: none;
    display: flex;
    align-items: center;
    gap: 5px;
    transition: all 0.15s;
    font-family: 'DM Sans', sans-serif;
}
.btn-fav:hover { background: rgba(255,255,255,0.1); border-color: rgba(255,255,255,0.5); }
.btn-fav.has-favs { border-color: var(--orange); color: var(--orange); }

/* ── Hero banner ─────────────────────────────────── */
.hero {
    background: linear-gradient(135deg, var(--navy) 0%, var(--navy-mid) 50%, var(--blue) 100%);
    color: white;
    padding: 48px 20px 40px;
    text-align: center;
    position: relative;
    overflow: hidden;
}

.hero::before {
    content: '';
    position: absolute;
    top: -40px; right: -40px;
    width: 200px; height: 200px;
    background: var(--orange);
    opacity: 0.15;
    border-radius: 50%;
}

.hero::after {
    content: '';
    position: absolute;
    bottom: -60px; left: -30px;
    width: 160px; height: 160px;
    background: var(--orange-light);
    opacity: 0.1;
    border-radius: 50%;
}

.hero-tag {
    display: inline-block;
    background: var(--orange);
    color: white;
    font-size: 11px;
    font-weight: 700;
    letter-spacing: 0.14em;
    text-transform: uppercase;
    padding: 4px 12px;
    border-radius: 99px;
    margin-bottom: 14px;
}

.hero h1 { font-size: 3rem; color: white; }
.hero p { color: rgba(255,255,255,0.7); margin-top: 10px; font-size: 15px; }

.hero-links {
    display: flex;
    gap: 10px;
    justify-content: center;
    margin-top: 24px;
    flex-wrap: wrap;
}

.btn-primary {
    background: var(--orange);
    color: white;
    padding: 11px 22px;
    border-radius: 10px;
    text-decoration: none;
    font-weight: 700;
    font-size: 14px;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    transition: transform 0.1s, box-shadow 0.1s;
    border: none;
    cursor: pointer;
    font-family: 'DM Sans', sans-serif;
}
.btn-primary:hover { transform: translateY(-1px); box-shadow: 0 6px 20px rgba(232,86,10,0.4); }

.btn-secondary {
    background: rgba(255,255,255,0.12);
    color: white;
    padding: 11px 22px;
    border-radius: 10px;
    text-decoration: none;
    font-weight: 600;
    font-size: 14px;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    transition: background 0.15s;
    border: 1.5px solid rgba(255,255,255,0.2);
}
.btn-secondary:hover { background: rgba(255,255,255,0.2); }

/* ── Container ───────────────────────────────────── */
.container {
    max-width: 700px;
    margin: 0 auto;
    padding: 20px 16px;
}

/* ── Page title ──────────────────────────────────── */
.page-title {
    font-family: 'Bebas Neue', sans-serif;
    font-size: 1.8rem;
    color: var(--navy);
    letter-spacing: 0.04em;
    margin-bottom: 4px;
}
.page-subtitle { font-size: 13px; color: var(--text-muted); margin-bottom: 20px; }

/* ── Round tabs ──────────────────────────────────── */
.round-tabs {
    display: flex;
    gap: 6px;
    overflow-x: auto;
    padding-bottom: 4px;
    margin-bottom: 20px;
    scrollbar-width: none;
}
.round-tabs::-webkit-scrollbar { display: none; }

.round-tab {
    flex-shrink: 0;
    padding: 7px 16px;
    border-radius: 99px;
    font-size: 13px;
    font-weight: 600;
    background: white;
    border: 1.5px solid var(--border);
    color: var(--text-muted);
    cursor: pointer;
    text-decoration: none;
    transition: all 0.15s;
    font-family: 'DM Sans', sans-serif;
}
.round-tab:hover  { border-color: var(--orange); color: var(--orange); }
.round-tab.active { background: var(--orange); border-color: var(--orange); color: white; }

/* ── Match card ──────────────────────────────────── */
.match-card {
    background: white;
    border-radius: var(--radius);
    box-shadow: var(--card-shadow);
    padding: 14px 16px;
    margin-bottom: 10px;
    transition: transform 0.1s;
}
.match-card:hover { transform: translateY(-1px); }

.match-meta {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 10px;
    font-size: 11px;
    font-weight: 600;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.06em;
}

.match-cat-badge {
    background: var(--orange-dim);
    color: var(--orange);
    border-radius: 5px;
    padding: 2px 7px;
    font-size: 10px;
    font-weight: 700;
}

.match-final-badge {
    background: #FEF3C7;
    color: #92400E;
    border-radius: 5px;
    padding: 2px 7px;
    font-size: 10px;
    font-weight: 700;
}

.match-dot { color: var(--border); }

.match-teams {
    display: flex;
    align-items: center;
    gap: 10px;
}

.match-team {
    flex: 1;
    font-weight: 600;
    font-size: 15px;
    line-height: 1.2;
}
.match-team.home { text-align: right; }
.match-team.away { text-align: left; }
.match-team.fav  { color: var(--orange); }

.match-score {
    display: flex;
    align-items: center;
    gap: 4px;
    font-family: 'Bebas Neue', sans-serif;
    font-size: 26px;
    letter-spacing: 0.02em;
    flex-shrink: 0;
    min-width: 70px;
    justify-content: center;
}

.score-num { line-height: 1; }
.score-dash { color: var(--text-muted); font-size: 20px; padding: 0 2px; }

.match-score.played { color: var(--navy); }
.match-score.pending { color: var(--text-muted); }

.match-score-pending {
    font-size: 13px;
    font-weight: 600;
    color: var(--text-muted);
    text-align: center;
    min-width: 50px;
    flex-shrink: 0;
}

.match-ref {
    margin-top: 8px;
    padding-top: 8px;
    border-top: 1px solid var(--border);
    font-size: 11px;
    color: var(--text-muted);
    display: flex;
    align-items: center;
    gap: 5px;
}

.match-cancelled {
    opacity: 0.5;
}
.match-cancelled .match-cat-badge {
    background: #FEE2E2;
    color: #DC2626;
}

/* ── Standing card ───────────────────────────────── */
.standing-section { margin-bottom: 24px; }

.standing-label {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 10px;
}

.cat-badge {
    font-family: 'Bebas Neue', sans-serif;
    font-size: 18px;
    color: var(--navy);
    letter-spacing: 0.04em;
}
.poule-badge {
    font-size: 12px;
    font-weight: 600;
    color: white;
    background: var(--blue);
    padding: 2px 9px;
    border-radius: 99px;
}

.standing-table {
    background: white;
    border-radius: var(--radius);
    box-shadow: var(--card-shadow);
    overflow: hidden;
    width: 100%;
}

.standing-row {
    display: grid;
    grid-template-columns: 28px 1fr 36px 36px 36px 36px 36px;
    align-items: center;
    padding: 11px 14px;
    border-bottom: 1px solid var(--border);
    font-size: 13px;
    gap: 6px;
    transition: background 0.1s;
}
.standing-row:last-child { border-bottom: none; }
.standing-row:hover { background: var(--off-white); }
.standing-row.header {
    background: var(--off-white);
    font-size: 10px;
    font-weight: 700;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.07em;
    padding: 8px 14px;
}

.standing-pos { font-weight: 700; color: var(--text-muted); font-size: 12px; }
.standing-pos.top { color: var(--orange); }
.standing-name { font-weight: 600; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.standing-name.fav { color: var(--orange); }
.standing-pts { font-family: 'Bebas Neue', sans-serif; font-size: 17px; color: var(--navy); text-align: center; }
.standing-num { text-align: center; color: var(--text-muted); }

/* ── Team card ───────────────────────────────────── */
.team-header {
    background: linear-gradient(135deg, var(--navy), var(--blue));
    color: white;
    padding: 30px 20px 28px;
    text-align: center;
}

.team-initials {
    width: 72px; height: 72px;
    background: var(--orange);
    border-radius: 18px;
    font-family: 'Bebas Neue', sans-serif;
    font-size: 28px;
    color: white;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 12px;
    box-shadow: 0 4px 16px rgba(245, 166, 35, 0.4);
}

.team-name-big { font-size: 2rem; color: white; }
.team-meta-line { font-size: 13px; color: rgba(255,255,255,0.6); margin-top: 4px; }

.fav-btn {
    margin-top: 14px;
    background: transparent;
    border: 1.5px solid rgba(255,255,255,0.3);
    color: white;
    padding: 8px 20px;
    border-radius: 99px;
    font-size: 13px;
    font-weight: 600;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    transition: all 0.15s;
    font-family: 'DM Sans', sans-serif;
}
.fav-btn.is-fav { background: var(--orange); border-color: var(--orange); }
.fav-btn:hover { transform: scale(1.03); }

/* ── Stats grid ──────────────────────────────────── */
.stats-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 10px;
    margin: 20px 0;
}

.stat-card {
    background: white;
    border-radius: var(--radius-sm);
    padding: 14px 10px;
    text-align: center;
    box-shadow: var(--card-shadow);
}

.stat-number {
    font-family: 'Bebas Neue', sans-serif;
    font-size: 2rem;
    color: var(--navy);
    line-height: 1;
}

.stat-label {
    font-size: 11px;
    color: var(--text-muted);
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    margin-top: 3px;
}

/* ── Section heading ─────────────────────────────── */
.section-heading {
    font-family: 'Bebas Neue', sans-serif;
    font-size: 1.3rem;
    color: var(--navy);
    letter-spacing: 0.04em;
    margin: 24px 0 12px;
}

/* ── Quick links (home) ──────────────────────────── */
.quick-links {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 10px;
    margin: 24px 0;
}

.quick-link {
    background: white;
    border-radius: var(--radius);
    box-shadow: var(--card-shadow);
    padding: 20px 16px;
    text-decoration: none;
    color: var(--text);
    display: flex;
    flex-direction: column;
    gap: 8px;
    transition: transform 0.1s, box-shadow 0.1s;
    border: 2px solid transparent;
}
.quick-link:hover { transform: translateY(-2px); box-shadow: 0 8px 24px rgba(0,0,0,0.1); border-color: var(--orange); }

.quick-link-icon {
    font-size: 26px;
    line-height: 1;
}
.quick-link-title {
    font-family: 'Bebas Neue', sans-serif;
    font-size: 1.2rem;
    color: var(--navy);
    letter-spacing: 0.04em;
}
.quick-link-desc { font-size: 12px; color: var(--text-muted); }

/* ── Favorites empty state ───────────────────────── */
.empty-state {
    text-align: center;
    padding: 60px 20px;
    color: var(--text-muted);
}
.empty-icon { font-size: 48px; margin-bottom: 14px; }
.empty-title { font-family: 'Bebas Neue', sans-serif; font-size: 1.5rem; color: var(--navy); margin-bottom: 8px; letter-spacing: 0.04em; }
.empty-text { font-size: 14px; line-height: 1.6; max-width: 300px; margin: 0 auto 20px; }

/* ── Team search ─────────────────────────────────── */
.search-box {
    width: 100%;
    padding: 12px 16px;
    border: 1.5px solid var(--border);
    border-radius: var(--radius-sm);
    font-size: 15px;
    font-family: 'DM Sans', sans-serif;
    background: white;
    outline: none;
    transition: border-color 0.15s;
    margin-bottom: 16px;
}
.search-box:focus { border-color: var(--orange); }

/* ── Team list item ──────────────────────────────── */
.team-list-item {
    background: white;
    border-radius: var(--radius-sm);
    padding: 12px 16px;
    margin-bottom: 8px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    box-shadow: var(--card-shadow);
    text-decoration: none;
    color: var(--text);
    transition: transform 0.1s;
    border: 2px solid transparent;
}
.team-list-item:hover { transform: translateY(-1px); border-color: var(--orange-dim); }
.team-list-item.is-fav { border-color: var(--orange); }

.team-item-name { font-weight: 600; font-size: 15px; }
.team-item-meta { font-size: 12px; color: var(--text-muted); margin-top: 2px; }
.team-item-star { color: var(--orange); font-size: 18px; }

/* ── Bottom navigation ───────────────────────────── */
.bottom-nav {
    position: fixed;
    bottom: 0; left: 0; right: 0;
    background: linear-gradient(135deg, var(--navy) 0%, var(--navy-mid) 100%);
    display: flex;
    height: 68px;
    z-index: 200;
    box-shadow: 0 -4px 20px rgba(13, 79, 122, 0.25);
}

.nav-item {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 3px;
    text-decoration: none;
    color: rgba(255,255,255,0.45);
    font-size: 10px;
    font-weight: 600;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    transition: color 0.15s;
    cursor: pointer;
}
.nav-item:hover { color: rgba(255,255,255,0.8); }
.nav-item.active { color: var(--orange); }

.nav-icon { font-size: 20px; line-height: 1; }

/* ── Toernooi info block ─────────────────────────── */
.info-block {
    background: white;
    border-radius: var(--radius);
    box-shadow: var(--card-shadow);
    padding: 20px;
    margin-bottom: 16px;
}

.info-block h3 { color: var(--navy); margin-bottom: 10px; font-size: 1.1rem; }
.info-block p  { font-size: 14px; color: var(--text-muted); }

/* ── Category filter ─────────────────────────────── */
.cat-filter {
    display: flex;
    gap: 6px;
    overflow-x: auto;
    padding-bottom: 4px;
    margin-bottom: 16px;
    scrollbar-width: none;
}
.cat-filter::-webkit-scrollbar { display: none; }

.cat-tab {
    flex-shrink: 0;
    padding: 6px 14px;
    border-radius: 99px;
    font-size: 12px;
    font-weight: 700;
    background: white;
    border: 1.5px solid var(--border);
    color: var(--text-muted);
    cursor: pointer;
    text-decoration: none;
    transition: all 0.15s;
    font-family: 'DM Sans', sans-serif;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}
.cat-tab:hover  { border-color: var(--orange); color: var(--orange); }
.cat-tab.active { background: var(--navy); border-color: var(--navy); color: white; }

/* ── Responsive ──────────────────────────────────── */
@media (min-width: 600px) {
    .quick-links { grid-template-columns: repeat(4, 1fr); }
    .hero h1 { font-size: 4rem; }
    .bottom-nav { max-width: 700px; left: 50%; transform: translateX(-50%); border-radius: 20px 20px 0 0; }
}