/* VGPS AI Predictor Styles v4.3 */

.vgps-container {
    max-width: 1400px;
    margin: 20px auto;
    padding: 20px;
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background: #f5f7fa;
    border-radius: 12px;
}

.vgps-header {
    background: linear-gradient(135deg, #2c3e50 0%, #4a6491 100%);
    color: white;
    padding: 25px;
    border-radius: 12px;
    margin-bottom: 25px;
    text-align: center;
    box-shadow: 0 4px 15px rgba(0,0,0,0.1);
}

.vgps-header h2 {
    margin: 0 0 10px 0;
    font-size: 28px;
    font-weight: 700;
}

.vgps-subtitle {
    margin: 0;
    opacity: 0.9;
    font-size: 16px;
}

.vgps-error {
    background: linear-gradient(135deg, #e74c3c 0%, #c0392b 100%);
    color: white;
    padding: 18px;
    border-radius: 10px;
    margin-bottom: 25px;
    text-align: center;
    font-weight: 500;
    box-shadow: 0 3px 10px rgba(231, 76, 60, 0.2);
}

.vgps-search-box {
    background: white;
    padding: 25px;
    border-radius: 12px;
    margin-bottom: 25px;
    box-shadow: 0 3px 15px rgba(0,0,0,0.08);
    border: 1px solid #e1e5eb;
}

.vgps-form-row {
    display: flex;
    gap: 15px;
    align-items: flex-end;
    margin-bottom: 15px;
}

@media (max-width: 768px) {
    .vgps-form-row {
        flex-direction: column;
    }
}

.vgps-form-group {
    flex: 1;
}

.vgps-form-group label {
    display: block;
    margin-bottom: 8px;
    font-weight: 600;
    color: #2c3e50;
    font-size: 15px;
}

.vgps-input {
    width: 100%;
    padding: 14px 16px;
    border: 2px solid #e1e5eb;
    border-radius: 8px;
    font-size: 16px;
    transition: all 0.3s ease;
    box-sizing: border-box;
}

.vgps-input:focus {
    outline: none;
    border-color: #3498db;
    box-shadow: 0 0 0 3px rgba(52, 152, 219, 0.1);
}

.vgps-hint {
    display: block;
    margin-top: 6px;
    color: #7f8c8d;
    font-size: 13px;
}

.vgps-form-actions {
    display: flex;
    gap: 10px;
    margin-bottom: 8px;
}

@media (max-width: 768px) {
    .vgps-form-actions {
        width: 100%;
    }
}

.vgps-button {
    padding: 14px 28px;
    border: none;
    border-radius: 8px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    flex: 1;
}

.vgps-button-primary {
    background: linear-gradient(135deg, #27ae60 0%, #219653 100%);
    color: white;
}

.vgps-button-primary:hover {
    background: linear-gradient(135deg, #219653 0%, #1e8749 100%);
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(39, 174, 96, 0.3);
}

.vgps-button-predict {
    background: linear-gradient(135deg, #9b59b6 0%, #8e44ad 100%);
    color: white;
}

.vgps-button-predict:hover {
    background: linear-gradient(135deg, #8e44ad 0%, #7d3c98 100%);
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(155, 89, 182, 0.3);
}

.vgps-auto-predict {
    padding-top: 15px;
    border-top: 1px solid #eee;
}

.vgps-checkbox {
    display: flex;
    align-items: center;
    gap: 10px;
    cursor: pointer;
    font-weight: 500;
    color: #2c3e50;
}

.vgps-checkbox input {
    width: 18px;
    height: 18px;
    cursor: pointer;
}

.vgps-stats {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 20px;
    margin-bottom: 25px;
}

@media (max-width: 768px) {
    .vgps-stats {
        grid-template-columns: 1fr;
    }
}

.vgps-stat {
    background: white;
    padding: 22px;
    border-radius: 10px;
    box-shadow: 0 3px 10px rgba(0,0,0,0.05);
    border-left: 4px solid #3498db;
    transition: transform 0.3s ease;
}

.vgps-stat:hover {
    transform: translateY(-3px);
    box-shadow: 0 5px 15px rgba(0,0,0,0.1);
}

.vgps-stat-label {
    display: block;
    color: #7f8c8d;
    font-size: 14px;
    margin-bottom: 8px;
    font-weight: 500;
}

.vgps-stat-value {
    display: block;
    font-size: 26px;
    font-weight: 700;
    color: #2c3e50;
}

.vgps-prediction-header {
    background: white;
    padding: 20px;
    border-radius: 10px;
    margin-bottom: 20px;
    border-left: 5px solid #3498db;
    box-shadow: 0 3px 10px rgba(0,0,0,0.05);
}

.current-pattern {
    margin-bottom: 10px;
    display: flex;
    align-items: center;
    gap: 10px;
    flex-wrap: wrap;
}

.pattern-score {
    background: #e8f4fc;
    padding: 6px 12px;
    border-radius: 6px;
    font-weight: 600;
    color: #2c3e50;
    border: 1px solid #d1e7f7;
    font-size: 16px;
}

.pattern-analysis {
    font-size: 14px;
    color: #7f8c8d;
    line-height: 1.5;
    padding-top: 10px;
    border-top: 1px solid #eee;
}

.vgps-algorithm-rules {
    background: #f8f9fa;
    padding: 18px;
    border-radius: 8px;
    margin: 20px 0;
    border-left: 4px solid #9b59b6;
}

.vgps-algorithm-rules h4 {
    margin: 0 0 15px 0;
    color: #2c3e50;
    font-size: 16px;
}

.rules-list {
    list-style: none;
    padding: 0;
    margin: 10px 0 0 0;
}

.rule-item {
    padding: 8px 0;
    border-bottom: 1px solid #e1e5eb;
    font-size: 14px;
    color: #2c3e50;
}

.rule-item:last-child {
    border-bottom: none;
}

.vgps-prediction-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 20px;
    margin-bottom: 25px;
}

@media (max-width: 768px) {
    .vgps-prediction-grid {
        grid-template-columns: 1fr;
    }
}

.vgps-prediction-card {
    background: white;
    border: 2px solid #e1e5eb;
    border-radius: 12px;
    padding: 22px;
    text-align: center;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.vgps-prediction-card:hover {
    border-color: #3498db;
    transform: translateY(-5px);
    box-shadow: 0 10px 25px rgba(52, 152, 219, 0.15);
}

.vgps-prediction-card:nth-child(1) {
    border-color: #f1c40f;
    background: linear-gradient(135deg, #fff9e6 0%, #fff 100%);
}

.vgps-prediction-card:nth-child(2) {
    border-color: #95a5a6;
    background: linear-gradient(135deg, #f8f9fa 0%, #fff 100%);
}

.vgps-prediction-card:nth-child(3) {
    border-color: #e67e22;
    background: linear-gradient(135deg, #fef5e7 0%, #fff 100%);
}

.prediction-rank {
    position: absolute;
    top: 10px;
    left: 10px;
    background: #2c3e50;
    color: white;
    width: 32px;
    height: 32px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: 14px;
}

.prediction-score {
    font-size: 36px;
    font-weight: 800;
    color: #2c3e50;
    margin: 15px 0;
    text-shadow: 2px 2px 4px rgba(0,0,0,0.1);
}

.prediction-result {
    font-size: 18px;
    font-weight: 700;
    margin: 10px 0;
    padding: 6px 16px;
    border-radius: 20px;
    display: inline-block;
    background: #f8f9fa;
}

.result-1 { 
    color: #27ae60; 
    background: rgba(39, 174, 96, 0.1) !important;
    border: 2px solid #27ae60 !important;
}

.result-X { 
    color: #f39c12; 
    background: rgba(243, 156, 18, 0.1) !important;
    border: 2px solid #f39c12 !important;
}

.result-2 { 
    color: #e74c3c; 
    background: rgba(231, 76, 60, 0.1) !important;
    border: 2px solid #e74c3c !important;
}

.prediction-probability {
    margin: 20px 0;
}

.probability-bar {
    height: 10px;
    background: #ecf0f1;
    border-radius: 5px;
    overflow: hidden;
    margin-bottom: 8px;
}

.probability-fill {
    height: 100%;
    background: linear-gradient(90deg, #27ae60, #2ecc71);
    border-radius: 5px;
    transition: width 1s ease-in-out;
}

.vgps-prediction-card:nth-child(1) .probability-fill {
    background: linear-gradient(90deg, #f1c40f, #f39c12);
}

.vgps-prediction-card:nth-child(2) .probability-fill {
    background: linear-gradient(90deg, #3498db, #2980b9);
}

.vgps-prediction-card:nth-child(3) .probability-fill {
    background: linear-gradient(90deg, #e74c3c, #c0392b);
}

.probability-value {
    font-size: 20px;
    font-weight: 700;
    color: #2c3e50;
}

.prediction-reason {
    margin-top: 10px;
    padding-top: 10px;
    border-top: 1px solid #eee;
    font-size: 13px;
    color: #7f8c8d;
    text-align: center;
    min-height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.prediction-occurrences {
    font-size: 11px;
    color: #95a5a6;
    margin-top: 5px;
}

.vgps-prediction-logic {
    background: #fef5e7;
    padding: 20px;
    border-radius: 10px;
    margin-top: 25px;
    border: 1px solid #f1c40f;
}

.vgps-prediction-logic h4 {
    margin: 0 0 15px 0;
    color: #2c3e50;
    font-size: 16px;
}

.vgps-prediction-logic p {
    margin: 0;
    line-height: 1.6;
    color: #34495e;
    font-size: 14px;
}

.vgps-no-predictions {
    background: #fef5e7;
    border: 2px solid #f1c40f;
    border-radius: 10px;
    padding: 30px;
    text-align: center;
    margin: 20px 0;
}

.vgps-no-predictions h3 {
    margin: 0 0 15px 0;
    color: #e67e22;
}

.vgps-no-predictions p {
    margin: 0;
    color: #7f8c8d;
    font-size: 15px;
    line-height: 1.5;
}

@keyframes ai-appear {
    0% { 
        opacity: 0;
        transform: translateY(20px) scale(0.95);
    }
    100% { 
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

.vgps-prediction-section {
    animation: ai-appear 0.6s ease-out;
}

.vgps-recent-scores {
    background: white;
    padding: 25px;
    border-radius: 12px;
    margin-top: 25px;
    box-shadow: 0 3px 15px rgba(0,0,0,0.05);
}

.vgps-recent-scores h4 {
    margin: 0 0 20px 0;
    color: #2c3e50;
    font-size: 18px;
    display: flex;
    align-items: center;
    gap: 10px;
}

.vgps-scores-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(95px, 1fr));
    gap: 10px;
    margin-top: 15px;
}

.vgps-recent-score {
    border: 2px solid #e1e5eb;
    border-radius: 8px;
    padding: 12px 8px;
    text-align: center;
    font-size: 13px;
    transition: all 0.3s ease;
    cursor: pointer;
    position: relative;
    overflow: hidden;
}

.vgps-recent-score:hover {
    transform: translateY(-3px);
    box-shadow: 0 5px 15px rgba(0,0,0,0.1);
    z-index: 1;
}

.vgps-recent-score::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 3px;
}

.vgps-recent-score.result-1::before { background: #27ae60; }
.vgps-recent-score.result-X::before { background: #f39c12; }
.vgps-recent-score.result-2::before { background: #e74c3c; }

.vgps-recent-line {
    display: block;
    font-size: 11px;
    color: #7f8c8d;
    margin-bottom: 5px;
    font-weight: 600;
}

.vgps-recent-score-value {
    display: block;
    font-weight: 700;
    font-size: 16px;
    margin-bottom: 5px;
}

.vgps-recent-result {
    display: block;
    font-size: 12px;
    font-weight: 700;
    padding: 3px 8px;
    border-radius: 12px;
    display: inline-block;
}