/* ═══════════════════════════════════════
   Keno Tulokset – CSS
   Teema: oranssi/keltainen
   ═══════════════════════════════════════ */

/* ─── Wrap ─── */
.keno-wrap {
    max-width: 900px; margin: 0 auto; font-family: inherit;
    width: 100% !important; box-sizing: border-box !important;
}
.keno-section {
    background: rgba(128,128,128,0.03); border-radius: 12px;
    padding: 20px; margin-bottom: 24px;
}

/* ─── Hero ─── */
.keno-hero {
    background: linear-gradient(150deg, #f59e0b 0%, #d97706 40%, #b45309 80%, #92400e 100%);
    color: #fff; border-radius: 20px; padding: 32px 24px 26px; margin-bottom: 24px;
    text-align: center; position: relative; overflow: hidden;
}
.keno-hero::before {
    content: ''; position: absolute; top: -50%; right: -15%;
    width: 350px; height: 350px; border-radius: 50%;
    background: rgba(255,255,255,0.05); pointer-events: none;
}
.keno-hero > * { position: relative; z-index: 1; }
.keno-hero, .keno-hero *, .keno-hero h2, .keno-hero p, .keno-hero span, .keno-hero div, .keno-hero strong {
    color: #fff !important;
}
.keno-hero h2 {
    margin: 0 0 6px; font-size: 1.5em; color: #fff;
    font-weight: 900; text-shadow: 0 1px 6px rgba(0,0,0,0.12);
}
.keno-live-date { font-size: 0.85em; opacity: 0.85; margin-bottom: 16px; }
.keno-live-badge {
    display: inline-block; background: rgba(255,255,255,0.2);
    padding: 2px 10px; border-radius: 20px; font-size: 0.75em;
    font-weight: 700; letter-spacing: 0.5px; margin-left: 6px;
}

/* ─── Draw tabs – pill segmented control ─── */
.keno-draw-tabs {
    display: flex; gap: 0; justify-content: center;
    margin: 14px auto 22px; max-width: 420px;
    background: rgba(0,0,0,0.18); border-radius: 12px;
    padding: 3px; position: relative;
}
.keno-draw-tab {
    flex: 1; background: transparent; border: none;
    border-radius: 10px; padding: 9px 8px 7px; cursor: pointer;
    color: rgba(255,255,255,0.6); font-family: inherit;
    font-weight: 700; transition: all 0.25s ease;
    display: flex; flex-direction: column; align-items: center;
    gap: 1px; position: relative;
}
.keno-draw-tab:hover:not(.disabled):not(.active) {
    color: rgba(255,255,255,0.9); background: rgba(255,255,255,0.08);
}
.keno-draw-tab.active {
    background: #fff; color: #92400e !important;
    box-shadow: 0 2px 12px rgba(0,0,0,0.18);
}
.keno-draw-tab.active .keno-draw-tab-label { color: #78350f !important; }
.keno-draw-tab.active .keno-draw-tab-time { color: #b45309 !important; opacity: 1; }
.keno-draw-tab.disabled {
    opacity: 0.3; cursor: default;
}
.keno-draw-tab-label { font-size: 0.8em; line-height: 1.2; font-weight: 800; }
.keno-draw-tab-time { font-size: 0.95em; font-weight: 900; opacity: 0.85; letter-spacing: 0.3px; }
.keno-draw-tab-badge {
    position: absolute; top: -7px; right: -4px;
    background: linear-gradient(135deg, #10b981, #059669); color: #fff;
    font-size: 0.5em; font-weight: 900; padding: 2px 6px; border-radius: 5px;
    letter-spacing: 0.4px; line-height: 1; box-shadow: 0 2px 6px rgba(16,185,129,0.35);
    text-transform: uppercase;
}
.keno-draw-tab-badge.pending {
    background: rgba(0,0,0,0.15); color: rgba(255,255,255,0.4);
    box-shadow: none; font-size: 0.48em;
}

/* ─── Number grid (20 balls) ─── */
.keno-balls {
    display: flex; flex-wrap: wrap; justify-content: center;
    gap: 8px; margin: 16px 0 10px;
}
.keno-ball {
    width: 44px; height: 44px; border-radius: 50%;
    background: rgba(255,255,255,0.2); color: #fff;
    display: flex; align-items: center; justify-content: center;
    font-weight: 800; font-size: 0.95rem;
    border: 2px solid rgba(255,255,255,0.35);
}
.keno-ball.kunkku {
    background: #fbbf24; color: #78350f !important;
    border-color: #f59e0b;
    box-shadow: 0 0 12px rgba(251,191,36,0.6);
}

/* ─── Hero kunkku & footer ─── */
.keno-hero-kunkku {
    margin-top: 10px; font-size: 0.82em; opacity: 0.85;
    background: rgba(0,0,0,0.1); display: inline-block;
    padding: 4px 14px; border-radius: 8px;
}
.keno-hero-kunkku:empty { display: none; }
.keno-hero-footer {
    margin-top: 12px; font-size: 0.75em; opacity: 0.6;
    text-align: center; letter-spacing: 0.2px;
}

/* ─── Dynamic text ─── */
.keno-dynamic-text { margin-bottom: 20px; line-height: 1.7; }
.keno-dynamic-text p { margin: 0 0 8px; }

/* ─── Status message ─── */
.keno-status-msg {
    background: #fef3c7; color: #92400e; border-radius: 8px;
    padding: 10px 16px; font-size: 0.9em; margin-bottom: 16px;
    text-align: center;
}

/* ─── Next draw countdown ─── */
.keno-countdown {
    background: rgba(245,158,11,0.08); border-radius: 10px;
    padding: 12px 16px; text-align: center; margin-bottom: 20px;
    font-size: 0.95em;
}
.keno-countdown strong { color: #d97706; }

/* ─── Tables ─── */
.keno-table {
    width: 100%; border-collapse: collapse; font-size: 0.88em; margin-top: 10px;
}
.keno-table th {
    background: rgba(245,158,11,0.08); padding: 8px 10px;
    text-align: left; font-weight: 700; font-size: 0.85em;
    text-transform: uppercase; letter-spacing: 0.3px;
}
.keno-table td { padding: 8px 10px; border-bottom: 1px solid rgba(128,128,128,0.08); }
.keno-table tr:hover td { background: rgba(245,158,11,0.04); }

/* ─── Stats grid ─── */
.keno-stats-grid {
    display: grid; grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
    gap: 12px; margin: 16px 0;
}
.keno-stat-card {
    background: rgba(128,128,128,0.04); border-radius: 10px;
    padding: 14px; text-align: center;
}
.keno-stat-big { font-size: 1.5em; font-weight: 800; color: #d97706; display: block; }
.keno-stat-label { font-size: 0.78em; opacity: 0.6; margin-top: 2px; display: block; }

/* ─── Number grid (tarkista / heatmap) ─── */
.keno-numgrid {
    display: grid; grid-template-columns: repeat(10, 1fr);
    gap: 6px; max-width: 520px; margin: 0 auto;
}
.keno-num-btn {
    width: 100%; aspect-ratio: 1; max-width: 48px; max-height: 48px;
    border: 2px solid rgba(128,128,128,0.15); border-radius: 50%;
    background: transparent; color: inherit; font-size: 0.85rem; font-weight: 700;
    cursor: pointer; transition: all 0.15s;
    display: flex; align-items: center; justify-content: center; padding: 0;
}
.keno-num-btn:hover { border-color: #f59e0b; background: rgba(245,158,11,0.08); }
.keno-num-btn.selected {
    background: #f59e0b; color: #fff; border-color: #d97706;
}
.keno-num-btn.hit {
    background: #22c55e; color: #fff; border-color: #16a34a;
}

/* ─── Heatmap colors ─── */
.keno-heat-1 { background: rgba(59,130,246,0.15); }
.keno-heat-2 { background: rgba(34,197,94,0.15); }
.keno-heat-3 { background: rgba(245,158,11,0.15); }
.keno-heat-4 { background: rgba(239,68,68,0.15); }
.keno-heat-5 { background: rgba(239,68,68,0.3); font-weight: 800; }

/* ─── Multiplier table (kertoimet) ─── */
.keno-multi-table {
    width: 100%; border-collapse: collapse; font-size: 0.9em;
}
.keno-multi-table th {
    background: #f59e0b; color: #fff; padding: 10px 12px; text-align: center;
}
.keno-multi-table td {
    padding: 8px 12px; text-align: center;
    border-bottom: 1px solid rgba(128,128,128,0.1);
}
.keno-multi-table tr:hover td { background: rgba(245,158,11,0.06); }
.keno-multi-highlight { background: rgba(245,158,11,0.1); font-weight: 700; }

/* ─── Draw time list ─── */
.keno-draw-times { display: flex; flex-direction: column; gap: 10px; }
.keno-draw-time-row {
    padding: 10px 14px; border-radius: 8px;
    background: rgba(128,128,128,0.04);
}

/* ─── Pagination ─── */
.keno-pagination { display: flex; gap: 6px; flex-wrap: wrap; margin-top: 16px; }
.keno-pagination a, .keno-pagination span {
    padding: 6px 12px; border-radius: 6px; font-size: 0.85em;
    text-decoration: none;
}
.keno-pagination a { background: rgba(128,128,128,0.06); color: inherit; }
.keno-pagination a:hover { background: rgba(245,158,11,0.15); }
.keno-pagination .current { background: #f59e0b; color: #fff; font-weight: 700; }

/* ─── Responsive ─── */
@media (max-width: 768px) {
    .keno-wrap { max-width: 100% !important; padding: 0 !important; overflow: hidden !important; }
    .keno-hero { padding: 20px 16px 18px; }
    .keno-hero h2 { font-size: 1.3em; }
    .keno-ball { width: 38px; height: 38px; font-size: 0.85rem; }
    .keno-balls { gap: 5px; }
    .keno-section { padding: 14px; }
    .keno-numgrid { grid-template-columns: repeat(7, 1fr); gap: 5px; }
    .keno-num-btn { max-width: 40px; max-height: 40px; font-size: 0.78rem; }
    .keno-stats-grid { grid-template-columns: repeat(2, 1fr); }
    .keno-table { font-size: 0.82em; }
    .keno-table th, .keno-table td { padding: 6px 7px; }
    .keno-draw-tabs { max-width: 100%; border-radius: 10px; }
    .keno-draw-tab { padding: 7px 6px 5px; border-radius: 8px; }
    .keno-draw-tab-label { font-size: 0.75em; }
    .keno-draw-tab-time { font-size: 0.82em; }
}
@media (max-width: 480px) {
    .keno-ball { width: 32px; height: 32px; font-size: 0.78rem; }
    .keno-balls { gap: 4px; }
    .keno-numgrid { grid-template-columns: repeat(7, 1fr); gap: 4px; }
    .keno-num-btn { max-width: 34px; max-height: 34px; font-size: 0.72rem; }
    .keno-draw-tab-label { font-size: 0.7em; }
    .keno-draw-tab-time { font-size: 0.75em; }
    .keno-draw-tab { padding: 6px 4px 4px; }
}
