/* ========================================
   POKER TOOL - CORE STYLES
   ======================================== */

/* Reset and Base Styles */
* {
    box-sizing: border-box;
}

body {
    font-family: 'Segoe UI', system-ui, -apple-system, sans-serif;
    margin: 0;
    padding: 0;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    min-height: 100vh;
    color: white;
    line-height: 1.6;
}

/* Navigation */
.poker-navbar {
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(10px);
    padding: 1rem 0;
    position: sticky;
    top: 0;
    z-index: 1000;
    border-bottom: 1px solid rgba(255, 255, 255, 0.2);
}

.poker-nav-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 2rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.poker-logo {
    font-size: 1.8rem;
    font-weight: bold;
    color: white;
    text-decoration: none;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.poker-back-btn {
    background: rgba(255, 255, 255, 0.2);
    color: white;
    border: none;
    padding: 0.5rem 1rem;
    border-radius: 25px;
    cursor: pointer;
    transition: all 0.3s ease;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
}

.poker-back-btn:hover {
    background: rgba(255, 255, 255, 0.3);
    transform: translateY(-2px);
}

/* Main Container */
.poker-container {
    max-width: 1600px;
    margin: 0 auto;
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(10px);
    border-radius: 20px;
    padding: 30px;
    box-shadow: 0 8px 32px rgba(31, 38, 135, 0.37);
    margin-top: 2rem;
    margin-bottom: 2rem;
    margin-left: 1rem;
    margin-right: 1rem;
}

/* Page Header */
.poker-page-header {
    text-align: center;
    margin-bottom: 30px;
}

.poker-page-header h1 {
    font-size: 2.5em;
    text-shadow: 2px 2px 4px rgba(0,0,0,0.3);
    margin-bottom: 0.5rem;
}

.poker-page-header p {
    opacity: 0.9;
    font-size: 1.1rem;
    max-width: 900px;
    margin: 0 auto;
}

/* Academic Introduction */
.poker-academic-intro {
    background: rgba(255, 255, 255, 0.95);
    border-radius: 15px;
    padding: 25px;
    margin-bottom: 30px;
    color: #333;
    box-shadow: 0 4px 16px rgba(0,0,0,0.2);
}

.poker-academic-intro h2 {
    color: #333;
    margin-bottom: 15px;
    display: flex;
    align-items: center;
    gap: 10px;
}

/* Tool Layout */
.poker-tool-layout {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 30px;
    margin-bottom: 30px;
}

/* Input Sections */
.poker-input-section {
    background: rgba(255, 255, 255, 0.1);
    border-radius: 15px;
    padding: 20px;
}

.poker-input-section h3 {
    margin-bottom: 15px;
    color: #4CAF50;
    display: flex;
    align-items: center;
    gap: 10px;
}

/* Form Elements */
.poker-input-group {
    margin-bottom: 15px;
}

.poker-input-group label {
    display: block;
    margin-bottom: 5px;
    font-weight: bold;
    color: white;
}

.poker-input-group input,
.poker-input-group select {
    width: 100%;
    padding: 10px;
    border: 2px solid rgba(255, 255, 255, 0.3);
    border-radius: 8px;
    background: rgba(255, 255, 255, 0.9);
    color: #333;
    font-weight: bold;
}

.poker-input-group input:focus,
.poker-input-group select:focus {
    outline: none;
    border-color: #4CAF50;
}

/* Strategy Results */
.poker-strategy-results {
    background: rgba(255, 255, 255, 0.95);
    border-radius: 15px;
    padding: 25px;
    margin-bottom: 30px;
    color: #333;
    box-shadow: 0 4px 16px rgba(0,0,0,0.2);
    display: none; /* Hidden by default, shown when strategy is calculated */
}

.poker-strategy-results h3 {
    text-align: center;
    color: #333;
    margin-bottom: 25px;
    font-size: 1.5em;
}

/* Range Display */
.poker-range-display {
    background: rgba(255, 255, 255, 0.1);
    border-radius: 15px;
    padding: 20px;
    margin-bottom: 30px;
    display: none; /* Hidden by default */
}

.poker-range-display h4 {
    color: #4CAF50;
    margin-bottom: 15px;
    text-align: center;
}

/* Calculation Details */
.poker-calculation-details {
    background: rgba(255, 255, 255, 0.1);
    border-radius: 15px;
    padding: 20px;
    margin-bottom: 30px;
    display: none; /* Hidden by default */
}

.poker-calculation-details h4 {
    color: #4CAF50;
    margin-bottom: 15px;
}

/* Math Formula Styling */
.poker-math-formula {
    background: rgba(0, 0, 0, 0.2);
    padding: 10px;
    border-radius: 8px;
    font-family: monospace;
    margin: 10px 0;
    color: white;
}

/* Button Styling */
.poker-btn {
    background: rgba(255, 255, 255, 0.2);
    color: white;
    border: 2px solid rgba(255, 255, 255, 0.3);
    padding: 10px 20px;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.3s ease;
    font-weight: bold;
    text-align: center;
}

.poker-btn:hover {
    background: rgba(255, 255, 255, 0.3);
    transform: scale(1.02);
}

.poker-btn.active {
    background: #4CAF50;
    border-color: #4CAF50;
}

/* Grid Layouts */
.poker-grid-2 {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 15px;
}

.poker-grid-3 {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 10px;
}

.poker-grid-auto {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 20px;
}

/* Card Styling */
.poker-card {
    background: white;
    color: #333;
    padding: 8px 12px;
    border-radius: 8px;
    font-weight: bold;
    font-size: 1.1em;
    box-shadow: 0 2px 8px rgba(0,0,0,0.3);
    cursor: pointer;
    transition: all 0.3s ease;
}

.poker-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0,0,0,0.4);
}

.poker-card.red {
    color: #d32f2f;
}

/* Status Display */
.poker-status {
    padding: 15px;
    border-radius: 10px;
    margin: 15px 0;
    text-align: center;
}

.poker-status.info {
    background: rgba(33, 150, 243, 0.2);
    border: 1px solid rgba(33, 150, 243, 0.5);
    color: #2196F3;
}

.poker-status.success {
    background: rgba(76, 175, 80, 0.2);
    border: 1px solid rgba(76, 175, 80, 0.5);
    color: #4CAF50;
}

.poker-status.warning {
    background: rgba(255, 152, 0, 0.2);
    border: 1px solid rgba(255, 152, 0, 0.5);
    color: #FF9800;
}

.poker-status.error {
    background: rgba(244, 67, 54, 0.2);
    border: 1px solid rgba(244, 67, 54, 0.5);
    color: #f44336;
}

/* Footer */
.poker-footer {
    background: rgba(0, 0, 0, 0.3);
    color: white;
    text-align: center;
    padding: 2rem;
    margin-top: 2rem;
}

.poker-footer p {
    opacity: 0.8;
    margin-bottom: 0.5rem;
}

/* Utility Classes */
.poker-hidden {
    display: none !important;
}

.poker-text-center {
    text-align: center;
}

.poker-text-bold {
    font-weight: bold;
}

.poker-margin-bottom {
    margin-bottom: 20px;
}

.poker-padding {
    padding: 20px;
}

/* Loading Animation */
.poker-loading {
    display: inline-block;
    width: 20px;
    height: 20px;
    border: 3px solid rgba(255,255,255,.3);
    border-radius: 50%;
    border-top-color: #fff;
    animation: poker-spin 1s ease-in-out infinite;
}

@keyframes poker-spin {
    to { transform: rotate(360deg); }
}
/* ========================================
   DECISION ENGINE CSS STYLES
   ======================================== */

/* Hand and Flop Input Styling */
.poker-hand-input, .poker-flop-input {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
    margin-bottom: 10px;
}

.poker-flop-card {
    display: flex;
    gap: 5px;
    align-items: center;
}

.poker-card-select {
    padding: 8px;
    border: 2px solid rgba(255, 255, 255, 0.3);
    border-radius: 6px;
    background: rgba(255, 255, 255, 0.9);
    color: #333;
    font-weight: bold;
    min-width: 80px;
    font-size: 0.9rem;
}

.poker-card-select:focus {
    outline: none;
    border-color: #4CAF50;
    box-shadow: 0 0 5px rgba(76, 175, 80, 0.3);
}

/* Betting Info Styling */
.poker-betting-info {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
    gap: 15px;
    margin-bottom: 15px;
}

.poker-bet-input {
    display: flex;
    flex-direction: column;
    gap: 5px;
}

.poker-bet-input label {
    font-size: 0.9rem;
    font-weight: bold;
    color: white;
}

.poker-number-input {
    padding: 8px;
    border: 2px solid rgba(255, 255, 255, 0.3);
    border-radius: 6px;
    background: rgba(255, 255, 255, 0.9);
    color: #333;
    font-weight: bold;
    font-size: 0.9rem;
}

.poker-number-input:focus {
    outline: none;
    border-color: #4CAF50;
    box-shadow: 0 0 5px rgba(76, 175, 80, 0.3);
}

/* Decision Section Styling */
.poker-decision-section {
    text-align: center;
    margin-top: 20px;
}

.poker-calculate-btn {
    background: linear-gradient(45deg, #4CAF50, #45a049);
    color: white;
    border: none;
    padding: 12px 30px;
    border-radius: 25px;
    font-size: 1.1rem;
    font-weight: bold;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 4px 15px rgba(76, 175, 80, 0.3);
}

.poker-calculate-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(76, 175, 80, 0.4);
    background: linear-gradient(45deg, #5cbf60, #4caf50);
}

.poker-calculate-btn:active {
    transform: translateY(0);
}

/* Decision Results Styling */
.poker-decision-result {
    background: rgba(255, 255, 255, 0.95);
    border-radius: 15px;
    padding: 20px;
    margin-top: 20px;
    color: #333;
    box-shadow: 0 4px 20px rgba(0,0,0,0.2);
    text-align: left;
}

.poker-decision-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
    padding-bottom: 15px;
    border-bottom: 2px solid rgba(0,0,0,0.1);
}

.poker-decision-title {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 1.8rem;
    font-weight: bold;
}

.poker-decision-icon {
    font-size: 2rem;
}

.poker-decision-text {
    text-transform: uppercase;
    letter-spacing: 1px;
}

.poker-confidence-badge {
    padding: 6px 12px;
    border-radius: 15px;
    font-size: 0.8rem;
    font-weight: bold;
    color: white;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.confidence-high { 
    background: #4CAF50; 
    box-shadow: 0 2px 8px rgba(76, 175, 80, 0.3);
}
.confidence-medium { 
    background: #FF9800; 
    box-shadow: 0 2px 8px rgba(255, 152, 0, 0.3);
}
.confidence-low { 
    background: #f44336; 
    box-shadow: 0 2px 8px rgba(244, 67, 54, 0.3);
}

/* Action Details Styling */
.poker-action-details {
    margin-bottom: 20px;
}

.poker-action-main {
    font-size: 1.2rem;
    margin-bottom: 10px;
    color: #333;
    padding: 10px;
    background: rgba(76, 175, 80, 0.1);
    border-radius: 8px;
    border-left: 4px solid #4CAF50;
}

.poker-action-reasoning {
    color: #666;
    line-height: 1.6;
    margin-left: 10px;
}

.poker-action-reasoning div {
    margin-bottom: 5px;
    padding: 2px 0;
}

/* Math Summary Styling */
.poker-math-summary {
    background: rgba(0,0,0,0.05);
    padding: 15px;
    border-radius: 10px;
    border: 1px solid rgba(0,0,0,0.1);
}

.poker-math-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 15px;
}

.poker-math-item {
    text-align: center;
    padding: 10px;
    background: white;
    border-radius: 8px;
    box-shadow: 0 2px 5px rgba(0,0,0,0.1);
}

.poker-math-label {
    font-size: 0.8rem;
    color: #666;
    margin-bottom: 4px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.poker-math-value {
    font-size: 1.3rem;
    font-weight: bold;
    color: #333;
    margin-bottom: 4px;
}

.poker-math-value.positive { 
    color: #4CAF50; 
    text-shadow: 0 1px 2px rgba(76, 175, 80, 0.2);
}
.poker-math-value.negative { 
    color: #f44336; 
    text-shadow: 0 1px 2px rgba(244, 67, 54, 0.2);
}

.poker-math-desc {
    font-size: 0.7rem;
    color: #888;
    line-height: 1.2;
}

/* Enhanced Status Messages */
.poker-status-message {
    animation: slideIn 0.3s ease;
    border-radius: 8px;
    margin: 10px 0;
    padding: 12px 15px;
    font-weight: 500;
}

@keyframes slideIn {
    from {
        opacity: 0;
        transform: translateY(-10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Mobile Responsiveness */
@media (max-width: 768px) {
    .poker-hand-input, .poker-flop-input {
        flex-direction: column;
        gap: 8px;
    }
    
    .poker-betting-info {
        grid-template-columns: 1fr;
        gap: 10px;
    }
    
    .poker-flop-card {
        justify-content: center;
    }
    
    .poker-decision-header {
        flex-direction: column;
        gap: 10px;
        text-align: center;
    }
    
    .poker-decision-title {
        font-size: 1.5rem;
    }
    
    .poker-math-grid {
        grid-template-columns: 1fr;
        gap: 10px;
    }
    
    .poker-action-main {
        font-size: 1.1rem;
    }
    
    .poker-calculate-btn {
        padding: 10px 25px;
        font-size: 1rem;
    }
}

/* Small screen adjustments */
@media (max-width: 480px) {
    .poker-card-select {
        min-width: 70px;
        font-size: 0.8rem;
        padding: 6px;
    }
    
    .poker-number-input {
        font-size: 0.8rem;
        padding: 6px;
    }
    
    .poker-decision-title {
        font-size: 1.3rem;
    }
    
    .poker-decision-icon {
        font-size: 1.5rem;
    }
}

/* Enhanced hover effects for interactive elements */
.poker-card-select:hover,
.poker-number-input:hover {
    border-color: rgba(76, 175, 80, 0.5);
}

.poker-bet-input:hover label {
    color: #4CAF50;
    transition: color 0.2s ease;
}

/* Loading state for calculation button */
.poker-calculate-btn.calculating {
    opacity: 0.7;
    cursor: not-allowed;
    transform: none !important;
}

.poker-calculate-btn.calculating::after {
    content: " 🔄";
    animation: spin 1s linear infinite;
}

@keyframes spin {
    from { transform: rotate(0deg); }
    to { transform: rotate(360deg); }
}