:root {
    --primary-color: #2d5e3e;
    --primary-light: #4a7c5d;
    --primary-dark: #1a3a26;
    --secondary-color: #7cb342;
    --success-color: #4caf50;
    --warning-color: #ff9800;
    --danger-color: #f44336;
    --light-green: #e8f5e8;
    --golf-green: #4a7c5d;
    --grass-green: #7cb342;
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background-color: #f8f9fa;
    line-height: 1.6;
}

/* Custom Bootstrap overrides */
.btn-primary {
    background-color: var(--primary-color);
    border-color: var(--primary-color);
}

.btn-primary:hover {
    background-color: var(--primary-dark);
    border-color: var(--primary-dark);
}

.text-primary {
    color: var(--primary-color) !important;
}

.bg-primary {
    background-color: var(--primary-color) !important;
}

/* Hero Section */
.hero-section {
    position: relative;
    min-height: 70vh;
    display: flex;
    align-items: center;
    background: linear-gradient(135deg, var(--light-green) 0%, #ffffff 100%);
    overflow: hidden;
}

.hero-background {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-image: 
        radial-gradient(circle at 20% 80%, rgba(77, 124, 93, 0.1) 0%, transparent 50%),
        radial-gradient(circle at 80% 20%, rgba(124, 179, 66, 0.1) 0%, transparent 50%);
    z-index: 1;
}

.hero-content {
    position: relative;
    z-index: 2;
}

.logo-container {
    display: flex;
    flex-direction: column;
    align-items: center;
}

.logo-icon {
    width: 80px;
    height: 80px;
    margin-bottom: 1rem;
}

/* BB Logo Styling */
.bb-logo {
    display: inline-block;
    transition: transform 0.2s ease;
}

.bb-logo:hover {
    transform: scale(1.05);
}

.bb-logo svg {
    filter: drop-shadow(0 2px 4px rgba(76, 175, 80, 0.2));
}
}

.logo-icon-sm {
    width: 32px;
    height: 32px;
}

/* Feature Cards */
.feature-card {
    background: white;
    border-radius: 12px;
    border: 1px solid #e9ecef;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
    height: 100%;
}

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

.feature-icon i {
    width: 48px;
    height: 48px;
}

/* Round Cards */
.round-card {
    transition: transform 0.2s ease, box-shadow 0.2s ease;
    border: 1px solid #e9ecef;
}

.round-card:hover {
    transform: translateY(-1px);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.winner-badge {
    font-weight: 600;
    color: var(--primary-color);
    display: flex;
    align-items: center;
    justify-content: flex-end;
}

.winner-score {
    font-size: 1.1rem;
    font-weight: 700;
    color: var(--secondary-color);
}

/* Scorecard Styles */
.hole-nav {
    background: white;
    border-radius: 8px;
    padding: 1rem;
    border: 1px solid #e9ecef;
}

.hole-buttons {
    display: flex;
    gap: 0.5rem;
    flex-wrap: wrap;
}

.hole-button {
    min-width: 40px;
    height: 40px;
    border: 2px solid #e9ecef;
    border-radius: 50%;
    background: white;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s ease;
}

.hole-button:hover {
    border-color: var(--primary-color);
    color: var(--primary-color);
}

.hole-button.active {
    background: var(--primary-color);
    border-color: var(--primary-color);
    color: white;
}

.hole-button.completed {
    background: var(--success-color);
    border-color: var(--success-color);
    color: white;
}

.hole-info {
    border: 1px solid #e9ecef;
}

.hole-detail {
    text-align: center;
}

.detail-label {
    font-size: 0.8rem;
    color: #6c757d;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 0.25rem;
}

.detail-value {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--primary-color);
}

/* Score Input */
.score-input {
    margin-bottom: 1rem;
}

.score-input-group {
    display: flex;
    align-items: center;
    background: white;
    border: 2px solid #e9ecef;
    border-radius: 8px;
    padding: 0.75rem;
    transition: border-color 0.2s ease;
}

.score-input-group:focus-within {
    border-color: var(--primary-color);
}

.player-name {
    font-weight: 600;
    color: var(--primary-color);
    flex: 1;
}

.score-field {
    width: 60px;
    border: none;
    text-align: center;
    font-size: 1.2rem;
    font-weight: 700;
    background: transparent;
}

.score-field:focus {
    outline: none;
}

.par-indicator {
    font-size: 0.8rem;
    color: #6c757d;
    margin-left: 0.5rem;
}

/* Leaderboard */
.leaderboard-item {
    display: flex;
    justify-content: between;
    align-items: center;
    padding: 0.75rem 1rem;
    border-bottom: 1px solid #e9ecef;
    transition: background-color 0.2s ease;
}

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

.leaderboard-item:hover {
    background-color: #f8f9fa;
}

.leaderboard-item.leader {
    background-color: var(--light-green);
    border-left: 4px solid var(--primary-color);
}

.player-position {
    font-weight: 700;
    color: var(--primary-color);
    margin-right: 0.75rem;
    min-width: 30px;
}

.player-info {
    flex: 1;
}

.player-name-lb {
    font-weight: 600;
    margin-bottom: 0.25rem;
}

.player-status {
    font-size: 0.8rem;
    color: #6c757d;
}

.player-total {
    text-align: right;
}

.total-score {
    font-size: 1.1rem;
    font-weight: 700;
    color: var(--primary-color);
}

.to-par {
    font-size: 0.9rem;
    color: #6c757d;
}

/* Navigation Buttons */
.nav-buttons {
    position: sticky;
    bottom: 0;
    background: white;
    padding: 1rem 0;
    border-top: 1px solid #e9ecef;
    margin-top: 2rem;
}

/* Round Summary */
.winner-announcement {
    background: linear-gradient(135deg, var(--light-green) 0%, #ffffff 100%);
    border: 2px solid var(--primary-color);
}

.winner-trophy {
    animation: bounce 2s infinite;
}

@keyframes bounce {
    0%, 20%, 50%, 80%, 100% {
        transform: translateY(0);
    }
    40% {
        transform: translateY(-10px);
    }
    60% {
        transform: translateY(-5px);
    }
}

.standings-item {
    transition: background-color 0.2s ease;
}

.standings-item:hover {
    background-color: #f8f9fa;
}

.position-indicator {
    display: flex;
    align-items: center;
    min-width: 50px;
}

/* Statistics Cards */
.stat-card {
    background: white;
    border: 1px solid #e9ecef;
    border-radius: 8px;
    padding: 1.5rem;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

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

.stat-icon i {
    width: 32px;
    height: 32px;
}

.stat-value {
    font-size: 2rem;
    font-weight: 700;
    color: var(--primary-color);
    margin-bottom: 0.25rem;
}

.stat-label {
    font-size: 0.9rem;
    color: #6c757d;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

/* Scorecard Table Enhancements */
.table-responsive {
    border-radius: 8px;
    overflow: hidden;
}

.table th {
    background-color: var(--light-green);
    color: var(--primary-color);
    font-weight: 600;
    border: none;
    text-align: center;
}

.table td {
    text-align: center;
    vertical-align: middle;
    border-color: #e9ecef;
}

.table-success {
    background-color: #d4edda;
    color: #155724;
}

.table-warning {
    background-color: #fff3cd;
    color: #856404;
}

.table-danger {
    background-color: #f8d7da;
    color: #721c24;
}

/* Mobile Responsiveness */
@media (max-width: 768px) {
    .hero-section {
        min-height: 60vh;
        padding: 2rem 0;
    }
    
    .logo-icon {
        width: 60px;
        height: 60px;
    }
    
    .hole-buttons {
        justify-content: center;
    }
    
    .hole-button {
        min-width: 36px;
        height: 36px;
        font-size: 0.9rem;
    }
    
    .detail-value {
        font-size: 1.2rem;
    }
    
    .stat-value {
        font-size: 1.5rem;
    }
    
    .nav-buttons {
        padding: 0.75rem 0;
    }
}

@media (max-width: 576px) {
    .container-fluid {
        padding-left: 0.5rem;
        padding-right: 0.5rem;
    }
    
    .score-input-group {
        padding: 0.5rem;
    }
    
    .leaderboard-item {
        padding: 0.5rem;
    }
    
    .stat-card {
        padding: 1rem;
    }
}

/* Touch-friendly enhancements */
@media (hover: none) and (pointer: coarse) {
    .btn {
        min-height: 44px;
    }
    
    .hole-button {
        min-width: 44px;
        height: 44px;
    }
    
    .score-field {
        min-height: 44px;
    }
}

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

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

/* Toast notifications */
.toast-container {
    position: fixed;
    top: 1rem;
    right: 1rem;
    z-index: 1080;
}

/* Form enhancements */
.form-control:focus, .form-select:focus {
    border-color: var(--primary-color);
    box-shadow: 0 0 0 0.2rem rgba(45, 94, 62, 0.25);
}

.was-validated .form-control:invalid {
    border-color: var(--danger-color);
}

.was-validated .form-control:valid {
    border-color: var(--success-color);
}

/* Authentication Pages */
.auth-page {
    background: linear-gradient(135deg, var(--light-green) 0%, #f8f9fa 100%);
    min-height: 100vh;
    display: flex;
    align-items: center;
}

.auth-card {
    background: white;
    padding: 2rem;
    border-radius: 15px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.1);
    border: 1px solid #dee2e6;
}

.icon-circle {
    width: 60px;
    height: 60px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto;
}

.icon-circle i {
    width: 24px;
    height: 24px;
}

/* Golf Score Symbols - CSS-only shapes */
.score-symbol {
    display: inline-block;
    width: 18px;
    height: 18px;
    margin-left: 5px;
    vertical-align: middle;
    position: relative;
}

.score-symbol.eagle {
    /* Double concentric circles for eagle */
    border: 2px solid #2196F3;
    border-radius: 50%;
}

.score-symbol.eagle::before {
    content: '';
    position: absolute;
    top: 3px;
    left: 3px;
    right: 3px;
    bottom: 3px;
    border: 1px solid #2196F3;
    border-radius: 50%;
}

.score-symbol.birdie {
    /* Single circle outline for birdie - no fill */
    border: 2px solid #4CAF50;
    border-radius: 50%;
    background-color: transparent;
}

.score-symbol.bogey {
    /* Single square outline for bogey */
    border: 2px solid #FF9800;
    border-radius: 2px;
}

.score-symbol.double-bogey {
    /* Single square outline for double bogey */
    border: 2px solid #f44336;
    border-radius: 2px;
}

.score-symbol.triple-bogey {
    /* Triangle outline for triple bogey */
    width: 0;
    height: 0;
    border-left: 10px solid transparent;
    border-right: 10px solid transparent;
    border-bottom: 16px solid #9C27B0;
    margin-top: 2px;
}

.score-symbol.triple-bogey::before {
    content: '';
    position: absolute;
    top: 2px;
    left: -8px;
    width: 0;
    height: 0;
    border-left: 8px solid transparent;
    border-right: 8px solid transparent;
    border-bottom: 12px solid white;
}
