* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    min-height: 100vh;
    min-height: 100dvh; /* Dynamic viewport height for mobile */
    margin: 0;
    padding: 0;
    color: #333;
    overflow-x: hidden;
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
    -webkit-user-select: none;
    -moz-user-select: none;
    -ms-user-select: none;
    user-select: none;
    touch-action: manipulation;
}

.game-container {
    min-height: 100vh;
    min-height: 100dvh; /* Dynamic viewport height for mobile */
    display: flex;
    flex-direction: column;
    padding: 10px;
    box-sizing: border-box;
}

.game-header {
    background: rgba(255, 255, 255, 0.95);
    border-radius: 10px;
    padding: 10px 15px;
    margin-bottom: 10px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.1);
    backdrop-filter: blur(10px);
    flex-shrink: 0;
}

.header-controls {
    display: flex;
    align-items: center;
    gap: 15px;
}

.game-header h1 {
    font-size: 1.8em;
    color: #4a90e2;
    font-weight: bold;
    margin: 0;
}

.stats {
    display: flex;
    gap: 10px;
}

.streak, .score, .games-played {
    background: #4a90e2;
    color: white;
    padding: 8px 12px;
    border-radius: 15px;
    font-weight: bold;
    font-size: 0.9em;
}

.game-content {
    flex: 1;
    background: rgba(255, 255, 255, 0.95);
    border-radius: 10px;
    padding: 15px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.1);
    backdrop-filter: blur(10px);
    display: flex;
    flex-direction: column;
    min-height: 0;
}

.location-info {
    text-align: center;
    margin-bottom: 10px;
    flex-shrink: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    position: relative;
}

.location-info h2 {
    font-size: 1.4em;
    color: #2c3e50;
    margin: 0;
    flex-grow: 1;
}

.location-info p {
    font-size: 1em;
    color: #7f8c8d;
    font-style: italic;
}

.location-title-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    margin: 0;
}

.location-title-row h2 {
    margin: 0;
    flex: 1;
}

.location-controls {
    display: flex;
    align-items: center;
    gap: 8px;
}

.location-hint {
    font-size: 0.9em;
    color: #7f8c8d;
    font-style: italic;
    margin: 5px 0 0 0;
    transition: all 0.3s ease;
    line-height: 1.3;
}

.location-hint.hidden {
    opacity: 0;
    transform: translateY(-5px);
    pointer-events: none;
    margin-top: 0;
    height: 0;
    overflow: hidden;
}

.hint-toggle {
    background: rgba(74, 144, 226, 0.1);
    border: 2px solid #4a90e2;
    border-radius: 50%;
    width: 36px;
    height: 36px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.3s ease;
    font-size: 18px;
    padding: 0;
    box-shadow: 0 2px 6px rgba(74, 144, 226, 0.2);
    flex-shrink: 0;
}

.hint-toggle:hover {
    background: #4a90e2;
    transform: translateY(-1px);
    box-shadow: 0 4px 8px rgba(74, 144, 226, 0.3);
}

.hint-toggle:active {
    transform: translateY(0);
}

.hint-toggle.active {
    background: #4a90e2;
    color: white;
}

/* Fade in animation for hints */
@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(-10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.map-container {
    position: relative;
    flex: 1;
    display: flex;
    flex-direction: column;
    min-height: 0;
}

#map {
    width: 100%;
    flex: 1;
    border: 2px solid #34495e;
    border-radius: 8px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.2);
    min-height: 200px;
    touch-action: pan-x pan-y;
}

#map:hover {
    transform: none;
}

/* Custom Leaflet marker styles */
.player-pin, .actual-pin {
    border: none;
    background: transparent;
}

.leaflet-div-icon {
    background: transparent;
    border: none;
}

/* Layer control styling */
.leaflet-control-layers {
    background: rgba(255, 255, 255, 0.95) !important;
    border-radius: 8px !important;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15) !important;
    backdrop-filter: blur(10px);
    border: none !important;
}

.leaflet-control-layers-expanded {
    padding: 8px 10px !important;
}

.leaflet-control-layers-toggle {
    background-image: none !important;
    width: 30px !important;
    height: 30px !important;
}

.leaflet-control-layers-toggle:after {
    content: '🗺️';
    font-size: 16px;
    line-height: 30px;
    text-align: center;
    display: block;
}

.leaflet-control-layers label {
    font-size: 13px !important;
    font-weight: 500 !important;
    color: #2c3e50 !important;
    margin-bottom: 4px !important;
}

.leaflet-control-layers-separator {
    border-top: 1px solid #ddd !important;
    margin: 5px 0 !important;
}

.map-overlay {
    margin-top: 10px;
    display: flex;
    gap: 10px;
    flex-shrink: 0;
    justify-content: center;
}

button {
    background: #e74c3c;
    color: white;
    border: none;
    padding: 12px 20px;
    border-radius: 25px;
    font-size: 1em;
    font-weight: bold;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 2px 8px rgba(231, 76, 60, 0.3);
    min-height: 44px; /* Apple recommended touch target size */
    min-width: 44px;
    touch-action: manipulation;
    -webkit-tap-highlight-color: transparent;
}

button:hover:not(:disabled) {
    background: #c0392b;
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(231, 76, 60, 0.4);
}

button:disabled {
    background: #bdc3c7;
    cursor: not-allowed;
    transform: none;
    box-shadow: none;
}

#next-round {
    background: #27ae60;
    box-shadow: 0 2px 8px rgba(39, 174, 96, 0.3);
    margin: 4px 0;
}

#next-round:hover {
    background: #219a52;
    box-shadow: 0 4px 12px rgba(39, 174, 96, 0.4);
}

#share-result {
    background: #f39c12;
    box-shadow: 0 2px 8px rgba(243, 156, 18, 0.3);
}

#share-result:hover {
    background: #e67e22;
    box-shadow: 0 4px 12px rgba(243, 156, 18, 0.4);
}

.result-panel {
    background: linear-gradient(135deg, #74b9ff 0%, #0984e3 100%);
    color: white;
    padding: 8px 12px;
    border-radius: 8px;
    text-align: center;
    margin-bottom: 8px;
    box-shadow: 0 2px 10px rgba(116, 185, 255, 0.3);
    flex-shrink: 0;
    position: relative;
    z-index: 10;
    order: 1;
}

.result-panel h3 {
    font-size: 1.2em;
    margin: 0 0 5px 0;
}

.result-panel p {
    font-size: 1em;
    margin: 2px 0;
}

.difficulty-indicator {
    flex-shrink: 0;
}

#difficulty-level {
    background: #9b59b6;
    color: white;
    padding: 4px 8px;
    border-radius: 10px;
    font-weight: bold;
    font-size: 0.8em;
    box-shadow: 0 1px 5px rgba(155, 89, 182, 0.3);
}

/* Top Streaks Button */
.top-streaks-btn {
    background: linear-gradient(135deg, #f39c12 0%, #e67e22 100%);
    color: white;
    border: none;
    padding: 8px 16px;
    border-radius: 20px;
    font-size: 0.9em;
    font-weight: bold;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 2px 8px rgba(243, 156, 18, 0.3);
    min-height: 36px;
    display: flex;
    align-items: center;
    gap: 6px;
    white-space: nowrap;
}

.top-streaks-btn:hover {
    background: linear-gradient(135deg, #e67e22 0%, #d35400 100%);
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(243, 156, 18, 0.4);
}

/* Modal Styles */
.modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.7);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 1000;
    backdrop-filter: blur(5px);
}

.modal-content {
    background: rgba(255, 255, 255, 0.98);
    border-radius: 15px;
    width: 90%;
    max-width: 600px;
    max-height: 80vh;
    overflow-y: auto;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.3);
    backdrop-filter: blur(10px);
}

.modal-header {
    background: linear-gradient(135deg, #4a90e2 0%, #357abd 100%);
    color: white;
    padding: 20px;
    border-radius: 15px 15px 0 0;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.modal-header h2 {
    margin: 0;
    font-size: 1.5em;
    font-weight: bold;
}

.modal-close {
    background: none;
    border: none;
    color: white;
    font-size: 2em;
    cursor: pointer;
    padding: 0;
    width: 30px;
    height: 30px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    transition: all 0.3s ease;
}

.modal-close:hover {
    background: rgba(255, 255, 255, 0.2);
    transform: scale(1.1);
}

.modal-body {
    padding: 20px;
}

.leaderboard-info {
    text-align: center;
    margin-bottom: 20px;
    padding: 15px;
    background: rgba(74, 144, 226, 0.1);
    border-radius: 8px;
    border-left: 4px solid #4a90e2;
}

.leaderboard-info p {
    margin: 0;
    color: #2c3e50;
    font-size: 1.1em;
    font-weight: 500;
}

.leaderboard-container {
    background: white;
    border-radius: 10px;
    overflow: hidden;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
}

.leaderboard-header {
    background: linear-gradient(135deg, #34495e 0%, #2c3e50 100%);
    color: white;
    padding: 15px;
    display: grid;
    grid-template-columns: 60px 1fr 100px 120px;
    gap: 15px;
    font-weight: bold;
    font-size: 0.9em;
}

.leaderboard-list {
    min-height: 200px;
}

.leaderboard-entry {
    padding: 15px;
    border-bottom: 1px solid #ecf0f1;
    display: grid;
    grid-template-columns: 60px 1fr 100px 120px;
    gap: 15px;
    align-items: center;
    transition: all 0.3s ease;
}

.leaderboard-entry:hover {
    background: rgba(74, 144, 226, 0.05);
}

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

.rank {
    font-weight: bold;
    font-size: 1.2em;
    color: #4a90e2;
    text-align: center;
}

.rank.gold {
    color: #f1c40f;
}

.rank.silver {
    color: #95a5a6;
}

.rank.bronze {
    color: #cd7f32;
}

.player-name {
    font-weight: 600;
    color: #2c3e50;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.streak-value {
    font-weight: bold;
    font-size: 1.1em;
    color: #27ae60;
    text-align: center;
}

.streak-date {
    color: #7f8c8d;
    font-size: 0.9em;
    text-align: center;
}

.empty-leaderboard {
    text-align: center;
    padding: 40px 20px;
    color: #7f8c8d;
}

.empty-leaderboard h3 {
    margin: 0 0 10px 0;
    color: #95a5a6;
    font-size: 1.3em;
}

.empty-leaderboard p {
    margin: 0;
    font-size: 1em;
}

.leaderboard-footer {
    padding: 20px;
    text-align: center;
    border-top: 1px solid #ecf0f1;
    background: rgba(248, 249, 250, 0.8);
}

.clear-streaks-btn {
    background: #e74c3c;
    color: white;
    border: none;
    padding: 10px 20px;
    border-radius: 20px;
    font-size: 0.9em;
    font-weight: bold;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 2px 8px rgba(231, 76, 60, 0.3);
}

.clear-streaks-btn:hover {
    background: #c0392b;
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(231, 76, 60, 0.4);
}

/* Game Start Screen Styles */
.game-start-screen {
    background: rgba(255, 255, 255, 0.95);
    border-radius: 10px;
    padding: 30px;
    text-align: center;
    backdrop-filter: blur(10px);
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.1);
    margin: 20px;
    max-width: 600px;
    margin-left: auto;
    margin-right: auto;
}

.game-start-screen h2 {
    color: #2c3e50;
    margin-bottom: 25px;
    font-size: 2.2em;
}

.instructions {
    text-align: left;
    margin: 25px 0;
}

.instructions h3 {
    color: #4a90e2;
    margin-bottom: 15px;
    font-size: 1.4em;
    text-align: center;
}

.instructions ul {
    list-style: none;
    padding: 0;
    margin: 0;
}

.instructions li {
    padding: 8px 0;
    font-size: 1.1em;
    color: #2c3e50;
    line-height: 1.5;
}

.streak-info {
    background: rgba(74, 144, 226, 0.1);
    border-radius: 8px;
    padding: 15px;
    margin: 20px 0;
    border-left: 4px solid #4a90e2;
}

.streak-info h4 {
    color: #4a90e2;
    margin-bottom: 10px;
    font-size: 1.1em;
    text-align: center;
}

.streak-info ul {
    list-style: none;
    padding: 0;
    margin: 0;
}

.streak-info li {
    padding: 5px 0;
    font-size: 1em;
    color: #2c3e50;
    line-height: 1.4;
}

.ready-text {
    text-align: center;
    font-size: 1.2em;
    color: #4a90e2;
    font-weight: bold;
    margin: 25px 0 15px 0;
}

.start-button {
    background: linear-gradient(135deg, #27ae60 0%, #2ecc71 100%);
    color: white;
    border: none;
    padding: 15px 40px;
    border-radius: 25px;
    font-size: 1.3em;
    font-weight: bold;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 4px 15px rgba(39, 174, 96, 0.3);
    min-height: 50px;
    margin-top: 10px;
}

.start-button:hover {
    background: linear-gradient(135deg, #219a52 0%, #27ae60 100%);
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(39, 174, 96, 0.4);
}

/* Timer Display Styles */
.timer-display {
    background: linear-gradient(135deg, #e74c3c 0%, #c0392b 100%);
    color: white;
    padding: 6px 12px;
    border-radius: 20px;
    font-weight: bold;
    font-size: 0.9em;
    box-shadow: 0 2px 8px rgba(231, 76, 60, 0.3);
    display: flex;
    align-items: center;
    gap: 4px;
    flex-shrink: 0;
    min-width: 60px;
    justify-content: center;
}

.timer-display.warning {
    background: linear-gradient(135deg, #f39c12 0%, #e67e22 100%);
    animation: pulse 1s infinite;
}

.timer-display.critical {
    background: linear-gradient(135deg, #e74c3c 0%, #c0392b 100%);
    animation: pulse 0.5s infinite;
}

@keyframes pulse {
    0% { transform: scale(1); }
    50% { transform: scale(1.05); }
    100% { transform: scale(1); }
}

.timer-icon {
    font-size: 1em;
}

/* Multiplayer Styles */
.game-mode-selector, .multiplayer-setup {
    background: rgba(255, 255, 255, 0.95);
    border-radius: 10px;
    padding: 20px;
    text-align: center;
    backdrop-filter: blur(10px);
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.1);
    margin: 20px;
}

.game-mode-selector h2, .multiplayer-setup h2 {
    color: #2c3e50;
    margin-bottom: 20px;
    font-size: 1.5em;
}

.game-mode-selector button {
    margin: 10px;
    padding: 15px 30px;
    font-size: 1.1em;
    min-width: 150px;
}

.player-count {
    margin-bottom: 20px;
}

.player-count label {
    display: block;
    margin-bottom: 10px;
    font-weight: bold;
    color: #2c3e50;
}

.player-count input {
    padding: 8px 12px;
    border: 2px solid #bdc3c7;
    border-radius: 8px;
    font-size: 1em;
    width: 80px;
    text-align: center;
}

.player-name-input {
    margin-bottom: 15px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
}

.player-name-input label {
    font-weight: bold;
    color: #2c3e50;
    min-width: 100px;
}

.player-name-input input {
    padding: 8px 12px;
    border: 2px solid #bdc3c7;
    border-radius: 8px;
    font-size: 1em;
    flex: 1;
    max-width: 200px;
}

.multiplayer-info {
    background: rgba(52, 152, 219, 0.1);
    border-radius: 8px;
    padding: 10px;
    margin-bottom: 10px;
    text-align: center;
}

.current-player {
    font-size: 1.2em;
    font-weight: bold;
    color: #2c3e50;
    margin-bottom: 5px;
}

.current-player-location {
    font-size: 1.1em;
    font-weight: bold;
    color: #e74c3c;
    margin-bottom: 10px;
    padding: 5px 10px;
    background: rgba(231, 76, 60, 0.1);
    border-radius: 6px;
}

.players-status {
    display: flex;
    justify-content: center;
    gap: 15px;
    flex-wrap: wrap;
}

.player-status {
    padding: 5px 10px;
    border-radius: 15px;
    background: rgba(149, 165, 166, 0.3);
    font-size: 0.9em;
    color: #2c3e50;
}

.player-status.current {
    background: #3498db;
    color: white;
    font-weight: bold;
}

.multiplayer-results {
    background: linear-gradient(135deg, #74b9ff 0%, #0984e3 100%);
    color: white;
    padding: 15px;
    border-radius: 10px;
    text-align: center;
    margin-bottom: 10px;
    box-shadow: 0 2px 10px rgba(116, 185, 255, 0.3);
}

.multiplayer-results h3 {
    margin: 0 0 15px 0;
    font-size: 1.3em;
}

.player-result-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 8px 12px;
    margin-bottom: 8px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 8px;
    gap: 10px;
}

.player-result-item .rank {
    font-size: 1.2em;
    min-width: 30px;
}

.player-result-item .player-name {
    font-weight: bold;
    flex: 1;
    text-align: left;
}

.player-result-item .distance {
    font-weight: bold;
    color: #f1c40f;
}

.player-result-item .total-distance {
    font-size: 0.9em;
    opacity: 0.8;
}

.round-winner {
    font-size: 1.2em;
    font-weight: bold;
    margin: 15px 0;
    padding: 10px;
    background: rgba(39, 174, 96, 0.3);
    border-radius: 8px;
}

/* Mobile-first responsive design */
@media (max-width: 768px) {
    .game-container {
        padding: 5px;
    }
    
    /* Layer control mobile adjustments */
    .leaflet-control-layers {
        font-size: 12px !important;
    }
    
    .leaflet-control-layers-toggle {
        width: 28px !important;
        height: 28px !important;
    }
    
    .leaflet-control-layers-toggle:after {
        font-size: 14px;
        line-height: 28px;
    }
    
    .leaflet-control-layers label {
        font-size: 12px !important;
    }
    
    .game-header {
        flex-direction: row;
        gap: 8px;
        text-align: center;
        padding: 6px 8px;
        align-items: center;
        justify-content: space-between;
    }
    
    .stats {
        display: flex;
        justify-content: flex-end;
        flex-wrap: nowrap;
        gap: 4px;
    }
    
    .game-header h1 {
        font-size: 1.2em;
        margin: 0;
        flex-shrink: 0;
    }
    
    .map-overlay {
        flex-direction: row;
        justify-content: center;
        gap: 12px;
        margin-top: 12px;
    }
    
    .location-info h2 {
        font-size: 1.3em;
        margin: 0;
    }
    
    .location-info {
        gap: 6px;
    }
    
    .location-title-row {
        gap: 8px;
    }
    
    .timer-display {
        font-size: 0.8em;
        padding: 4px 8px;
        min-width: 50px;
    }
    
    .location-title-row h2 {
        font-size: 1.3em;
    }
    
    .hint-toggle {
        width: 28px;
        height: 28px;
        font-size: 14px;
    }
    
    .location-hint {
        font-size: 0.85em;
        line-height: 1.4;
        margin-top: 8px;
    }
    
    #difficulty-level {
        font-size: 0.7em;
        padding: 3px 6px;
    }
    
    .streak, .score, .games-played {
        font-size: 0.75em;
        padding: 4px 6px;
        min-height: 28px;
        display: flex;
        align-items: center;
        white-space: nowrap;
    }
    
    button {
        padding: 12px 20px;
        font-size: 1em;
        min-height: 48px;
        min-width: 120px;
    }
    
    .result-panel {
        padding: 12px;
        margin-bottom: 8px;
    }
    
    .result-panel h3 {
        font-size: 1.3em;
        margin-bottom: 8px;
    }
    
    .result-panel p {
        font-size: 1.1em;
        margin: 4px 0;
    }
}

@media (max-width: 480px) {
    .game-container {
        padding: 3px;
    }
    
    .game-header {
        padding: 4px 6px;
        gap: 4px;
    }
    
    .game-header h1 {
        font-size: 1.0em;
    }
    
    .stats {
        gap: 3px;
    }
    
    .streak, .score, .games-played {
        font-size: 0.65em;
        padding: 3px 5px;
        min-height: 24px;
        border-radius: 12px;
    }
    
    .location-title-row h2 {
        font-size: 1.2em;
    }
    
    .location-title-row {
        gap: 6px;
    }
    
    .timer-display {
        font-size: 0.75em;
        padding: 3px 6px;
        min-width: 45px;
    }
    
    .hint-toggle {
        width: 24px;
        height: 24px;
        font-size: 12px;
    }
    
    .location-hint {
        font-size: 0.8em;
        line-height: 1.5;
        margin-top: 6px;
        padding: 0 2px;
    }
    
    #difficulty-level {
        font-size: 0.65em;
        padding: 2px 5px;
    }
    
    .game-content {
        padding: 8px;
    }
    
    .map-overlay {
        gap: 8px;
        margin-top: 8px;
    }
    
    button {
        padding: 10px 16px;
        font-size: 0.9em;
        min-height: 44px;
        min-width: 100px;
    }
    
    .result-panel {
        padding: 10px;
    }
    
    .result-panel h3 {
        font-size: 1.2em;
    }
    
    .result-panel p {
        font-size: 1em;
    }
    
    #difficulty-level {
        font-size: 0.8em;
        padding: 3px 6px;
    }
}

/* Extra small mobile devices */
@media (max-width: 320px) {
    .game-header h1 {
        font-size: 0.9em;
    }
    
    .location-title-row h2 {
        font-size: 1.1em;
    }
    
    .location-title-row {
        gap: 4px;
    }
    
    .timer-display {
        font-size: 0.7em;
        padding: 2px 5px;
        min-width: 40px;
    }
    
    .hint-toggle {
        width: 22px;
        height: 22px;
        font-size: 11px;
    }
    
    .location-hint {
        font-size: 0.75em;
        line-height: 1.5;
        margin-top: 4px;
        padding: 0;
    }
    
    .stats {
        flex-direction: row;
        gap: 2px;
    }
    
    .streak, .score, .games-played {
        font-size: 0.6em;
        padding: 2px 4px;
        min-height: 20px;
        border-radius: 10px;
    }
    
    .map-overlay {
        flex-direction: column;
        gap: 6px;
    }
    
    button {
        font-size: 0.85em;
        padding: 8px 12px;
        min-width: 80px;
    }
}

/* Social Share Buttons */
.share-buttons {
    margin-top: 6px;
    text-align: center;
}

.share-buttons h4 {
    margin-bottom: 4px;
    color: white;
    font-size: 0.8em;
    font-weight: normal;
}

.social-share {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 12px;
    margin-top: 4px;
    flex-wrap: nowrap;
}

.share-btn {
    width: 24px;
    height: 24px;
    border: none;
    background: transparent;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0;
}

.share-btn:hover {
    transform: translateY(-1px) scale(1.1);
    opacity: 0.8;
}

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

.share-btn svg {
    width: 20px;
    height: 20px;
    fill: white;
}

.share-btn:hover svg {
    fill: white;
}

/* Footer */
.game-footer {
    margin-top: auto;
    padding: 8px 15px;
    text-align: center;
    background: rgba(255, 255, 255, 0.9);
    border-radius: 8px;
    margin-bottom: 5px;
    flex-shrink: 0;
}

.game-footer p {
    margin: 0;
    color: #6c757d;
    font-size: 0.85em;
    font-weight: 500;
}

/* Mobile adjustments for social share */
@media (max-width: 768px) {
    .social-share {
        gap: 6px;
    }
    
    .share-btn {
        width: 22px;
        height: 22px;
    }
    
    .share-btn svg {
        width: 18px;
        height: 18px;
    }
    
    .share-buttons h4 {
        font-size: 0.8em;
        margin-bottom: 4px;
    }
    
    .share-buttons {
        margin-top: 6px;
    }
    
    .result-panel {
        padding: 8px 12px;
        margin-bottom: 8px;
    }
    
    .result-panel h3 {
        font-size: 1.3em;
        margin-bottom: 4px;
    }
    
    .result-panel p {
        font-size: 1.0em;
        margin: 2px 0;
    }
    
    .streak-info {
        padding: 12px;
        margin: 15px 0;
    }
    
    .streak-info h4 {
        font-size: 1em;
        margin-bottom: 8px;
    }
    
    .streak-info li {
        font-size: 0.9em;
        padding: 4px 0;
    }
    
    .header-controls {
        gap: 10px;
    }
    
    .top-streaks-btn {
        font-size: 0.8em;
        padding: 6px 12px;
        min-height: 32px;
    }
    
    .modal-content {
        width: 95%;
        max-height: 85vh;
    }
    
    .modal-header {
        padding: 15px;
    }
    
    .modal-header h2 {
        font-size: 1.3em;
    }
    
    .modal-body {
        padding: 15px;
    }
    
    .leaderboard-header {
        padding: 12px 15px;
        grid-template-columns: 50px 1fr 80px 100px;
        gap: 10px;
        font-size: 0.8em;
    }
    
    .leaderboard-entry {
        padding: 12px 15px;
        grid-template-columns: 50px 1fr 80px 100px;
        gap: 10px;
    }
    
    .rank {
        font-size: 1em;
    }
    
    .player-name {
        font-size: 0.9em;
    }
    
    .streak-value {
        font-size: 1em;
    }
    
    .streak-date {
        font-size: 0.8em;
    }
}

@media (max-width: 480px) {
    .social-share {
        gap: 4px;
    }
    
    .share-btn {
        width: 20px;
        height: 20px;
    }
    
    .share-btn svg {
        width: 16px;
        height: 16px;
    }
    
    .game-footer {
        padding: 6px 10px;
    }
    
    .game-footer p {
        font-size: 0.75em;
    }
    
    .share-buttons {
        margin-top: 4px;
    }
    
    .share-buttons h4 {
        font-size: 0.8em;
        margin-bottom: 3px;
    }
    
    .result-panel {
        padding: 8px 10px;
        margin-bottom: 6px;
    }
    
    .result-panel h3 {
        font-size: 1.4em;
        margin-bottom: 4px;
    }
    
    .result-panel p {
        font-size: 1.1em;
        margin: 2px 0;
    }
    
    .streak-info {
        padding: 10px;
        margin: 12px 0;
    }
    
    .streak-info h4 {
        font-size: 0.95em;
        margin-bottom: 6px;
    }
    
    .streak-info li {
        font-size: 0.85em;
        padding: 3px 0;
    }
    
    .header-controls {
        gap: 8px;
    }
    
    .top-streaks-btn {
        font-size: 0.75em;
        padding: 5px 10px;
        min-height: 28px;
    }
    
    .modal-content {
        width: 98%;
        max-height: 90vh;
    }
    
    .modal-header {
        padding: 12px;
    }
    
    .modal-header h2 {
        font-size: 1.2em;
    }
    
    .modal-body {
        padding: 12px;
    }
    
    .leaderboard-header {
        padding: 10px 12px;
        grid-template-columns: 40px 1fr 60px 80px;
        gap: 8px;
        font-size: 0.75em;
    }
    
    .leaderboard-entry {
        padding: 10px 12px;
        grid-template-columns: 40px 1fr 60px 80px;
        gap: 8px;
    }
    
    .rank {
        font-size: 0.9em;
    }
    
    .player-name {
        font-size: 0.85em;
    }
    
    .streak-value {
        font-size: 0.9em;
    }
    
    .streak-date {
        font-size: 0.75em;
    }
    
    .leaderboard-info {
        padding: 12px;
        margin-bottom: 15px;
    }
    
    .leaderboard-info p {
        font-size: 1em;
    }
    
    .clear-streaks-btn {
        font-size: 0.8em;
        padding: 8px 16px;
    }
}