/* ============================================
   PARLAY BUILDER STYLES
   ============================================ */

/* Main Panels */
.parlay-games-panel {
    background: #f8f9fa;
    border-radius: 10px;
    padding: 20px;
    min-height: 500px;
}

.parlay-summary-panel {
    background: linear-gradient(135deg, #f0f7ff 0%, #e8f4fd 100%);
    border: 2px solid #007bff;
    border-radius: 10px;
    padding: 20px;
    position: sticky;
    top: 80px;
}

/* Sport Tabs */
#sportTabs {
    border-bottom: 2px solid #dee2e6;
    margin-bottom: 0;
}

#sportTabs > li > a {
    color: #495057;
    font-weight: 600;
    padding: 8px 15px;
    border-radius: 5px 5px 0 0;
}

#sportTabs > li.active > a,
#sportTabs > li > a:hover {
    background-color: #007bff;
    color: white !important;
    border-color: #007bff;
}

/* Game Date Groups */
.game-date-group {
    margin-bottom: 20px;
}

.game-date-header {
    background: #343a40;
    color: white;
    padding: 8px 15px;
    border-radius: 5px;
    margin-bottom: 10px;
    font-size: 14px;
}

/* Game Cards */
.game-card {
    background: white;
    border: 1px solid #dee2e6;
    border-radius: 8px;
    padding: 12px 15px;
    margin-bottom: 10px;
    transition: all 0.2s ease;
}

.game-card:hover {
    border-color: #007bff;
    box-shadow: 0 2px 8px rgba(0, 123, 255, 0.15);
}

.game-time {
    font-size: 12px;
    color: #6c757d;
    margin-bottom: 8px;
}

.game-matchup {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.team-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.team-name {
    font-weight: 600;
    font-size: 14px;
    color: #212529;
    flex: 1;
    min-width: 0;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.team-buttons {
    display: flex;
    gap: 5px;
    flex-shrink: 0;
}

.total-row {
    display: flex;
    align-items: center;
    gap: 10px;
    padding-top: 8px;
    border-top: 1px dashed #dee2e6;
    margin-top: 5px;
}

.total-label {
    font-size: 12px;
    color: #6c757d;
    flex: 1;
}

/* Spread Button (inline with ML) */
.spread-btn {
    font-size: 11px;
    padding: 4px 8px;
    border-radius: 15px;
    min-width: 55px;
    white-space: nowrap;
}

.spread-btn .spread-line {
    font-weight: 600;
}

.spread-btn .spread-prob {
    font-size: 10px;
    opacity: 0.9;
}

.spread-btn.active {
    background-color: #28a745 !important;
    border-color: #28a745 !important;
    color: white !important;
    transform: scale(1.02);
}

.spread-btn.active .spread-prob {
    opacity: 1;
}

/* Parlay Buttons */
.parlay-btn {
    font-size: 12px;
    padding: 4px 10px;
    border-radius: 15px;
    min-width: 70px;
    transition: all 0.2s ease;
}

.parlay-btn .prob-badge {
    font-size: 10px;
    opacity: 0.8;
    margin-left: 3px;
}

.parlay-btn.active {
    background-color: #007bff !important;
    border-color: #007bff !important;
    color: white !important;
    transform: scale(1.05);
}

.parlay-btn.active .prob-badge {
    opacity: 1;
}

/* Parlay Legs List */
.parlay-legs-list {
    list-style: none;
    padding: 0;
    margin: 0;
}

.parlay-leg-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 10px;
    background: white;
    border-radius: 6px;
    margin-bottom: 8px;
    border-left: 4px solid #007bff;
}

.leg-info {
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.leg-sport {
    font-size: 10px;
    color: #6c757d;
    text-transform: uppercase;
    font-weight: 600;
}

.leg-team {
    font-weight: 600;
    font-size: 14px;
    color: #212529;
}

.leg-type {
    font-size: 11px;
    color: #007bff;
    text-transform: capitalize;
}

.leg-prob {
    display: flex;
    align-items: center;
    gap: 10px;
}

.prob-value {
    font-weight: bold;
    color: #28a745;
    font-size: 14px;
}

.remove-leg {
    padding: 2px 6px;
    font-size: 10px;
    border-radius: 50%;
}

/* Parlay Analysis Card */
.parlay-analysis-card {
    background: white;
    border-radius: 8px;
    padding: 15px;
    margin-bottom: 15px;
}

.parlay-analysis-card h5 {
    color: #007bff;
    margin-bottom: 15px;
    font-size: 16px;
    border-bottom: 2px solid #007bff;
    padding-bottom: 8px;
}

.analysis-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 8px 0;
    border-bottom: 1px solid #f0f0f0;
}

.analysis-row:last-of-type {
    border-bottom: none;
}

.analysis-label {
    color: #6c757d;
    font-size: 13px;
}

.analysis-value {
    font-size: 16px;
    color: #212529;
}

.odds-value {
    color: #007bff;
}

.decimal-odds {
    font-size: 12px;
    color: #6c757d;
    margin-left: 5px;
}

.highlight-row {
    background: linear-gradient(90deg, #d4edda 0%, #c3e6cb 100%);
    margin: 10px -15px;
    padding: 12px 15px !important;
}

.payout-value {
    color: #28a745;
    font-size: 20px;
}

.profit-value {
    color: #28a745;
}

.value-indicator {
    text-align: center;
    padding: 8px;
    border-radius: 5px;
    font-weight: 600;
    margin-top: 10px;
    font-size: 13px;
}

.value-indicator.text-success {
    background: #d4edda;
}

.value-indicator.text-warning {
    background: #fff3cd;
}

.value-indicator.text-danger {
    background: #f8d7da;
}

.value-indicator.text-info {
    background: #d1ecf1;
}

/* Probability Breakdown */
.probability-breakdown {
    background: #f8f9fa;
    border-radius: 8px;
    padding: 12px;
}

.probability-breakdown h6 {
    font-size: 12px;
    color: #6c757d;
    margin-bottom: 8px;
}

.prob-formula {
    font-size: 13px;
    color: #495057;
}

.prob-item {
    display: inline-block;
    background: white;
    padding: 2px 8px;
    border-radius: 10px;
    margin: 2px;
    font-weight: 600;
}

/* Stake Input */
.parlay-stake {
    display: flex;
    align-items: center;
    gap: 10px;
}

.parlay-stake label {
    font-size: 14px;
    color: #495057;
    margin-bottom: 0;
}

.parlay-stake input {
    border: 2px solid #dee2e6;
    border-radius: 5px;
    padding: 5px 10px;
    font-size: 14px;
    font-weight: 600;
}

.parlay-stake input:focus {
    border-color: #007bff;
    outline: none;
}

/* Legend */
.parlay-legend h5 {
    font-size: 14px;
    color: #495057;
    margin-bottom: 10px;
}

/* Responsive Adjustments */
@media (max-width: 992px) {
    .parlay-summary-panel {
        position: relative;
        top: 0;
        margin-top: 20px;
    }
}

@media (max-width: 768px) {
    .parlay-games-panel,
    .parlay-summary-panel {
        padding: 15px;
    }
    
    .game-card {
        padding: 10px;
    }
    
    .team-name {
        font-size: 13px;
    }
    
    .parlay-btn {
        font-size: 11px;
        padding: 3px 8px;
        min-width: 55px;
    }
    
    .spread-btn {
        font-size: 10px;
        min-width: 50px;
        padding: 3px 6px;
    }
    
    #sportTabs > li > a {
        padding: 6px 10px;
        font-size: 12px;
    }
}

@media (max-width: 480px) {
    .team-row {
        flex-wrap: wrap;
        gap: 5px;
    }
    
    .team-name {
        width: 100%;
    }
    
    .team-buttons {
        width: 100%;
        justify-content: flex-start;
    }
    
    .total-row {
        flex-wrap: wrap;
    }
    
    .spread-btn {
        font-size: 10px;
        min-width: 50px;
    }
}

