/* United States Map Styles */

html,
body {
    height: 100%;
    overflow: hidden;
    margin: 0;
    padding: 0;
}

body {
    overflow-x: hidden;
    background: linear-gradient(135deg, #E3F2FD 0%, #BBDEFB 50%, #90CAF9 100%);
    position: fixed;
    width: 100%;
    height: 100vh;
}

.game-container {
    display: flex;
    flex-direction: column;
    align-items: center;
    width: 100%;
    height: 100vh;
    height: 100dvh;
    padding-top: 60px;
    padding-bottom: 20px;
    box-sizing: border-box;
    overflow: hidden;
    position: relative;
    z-index: 10;
}

.game-header {
    display: flex;
    flex-direction: column;
    align-items: center;
    width: 100%;
    flex-shrink: 0;
    margin-bottom: 15px;
    gap: 8px;
}

.game-title-header {
    font-size: clamp(1.8rem, 4vw, 2.8rem);
    color: #1565C0;
    font-family: var(--font-heading);
    text-align: center;
    margin-bottom: 0;
    font-weight: 700;
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.1);
}

.game-subtitle {
    font-size: clamp(1rem, 2vw, 1.2rem);
    color: #424242;
    font-family: var(--font-body);
    text-align: center;
    margin-top: -5px;
    font-weight: 500;
}

.map-container {
    flex: 1;
    width: 100%;
    max-width: 1200px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 20px;
    box-sizing: border-box;
    position: relative;
    overflow: visible;
}

.map-wrapper {
    position: relative;
    width: 100%;
    max-width: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto;
}

.usa-map-image {
    width: 100%;
    height: auto;
    max-height: calc(100vh - 200px);
    max-width: 100%;
    object-fit: contain;
    border-radius: 20px;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.15);
    background: rgba(255, 255, 255, 0.95);
    padding: 20px;
    box-sizing: border-box;
    display: block;
}

.map-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: all;
    z-index: 10;
    overflow: visible;
}

.state-region {
    transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
    cursor: pointer;
    fill: transparent;
    stroke: none;
    opacity: 0;
}

.state-region:hover {
    opacity: 1;
}

.state-region:active {
    opacity: 1;
}

.capital-info {
    position: absolute;
    top: 20px;
    left: 50%;
    transform: translateX(-50%);
    background: linear-gradient(135deg, #FFF8E7 0%, #FFE8B4 100%);
    border: 3px solid #FFB74D;
    border-radius: 20px;
    padding: 20px 40px;
    box-shadow: 0 8px 24px rgba(255, 183, 77, 0.4);
    z-index: 100;
    min-width: 300px;
    text-align: center;
    backdrop-filter: blur(10px);
    animation: slideIn 0.3s ease-out;
}

.capital-info.hidden {
    display: none;
}

.capital-content {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.capital-state-name {
    font-size: clamp(1.5rem, 3vw, 2rem);
    color: #5A4A42;
    font-family: var(--font-heading);
    font-weight: 700;
    text-shadow: 1px 1px 2px rgba(0, 0, 0, 0.1);
}

.capital-city-name {
    font-size: clamp(1.2rem, 2.5vw, 1.6rem);
    color: #1565C0;
    font-family: var(--font-heading);
    font-weight: 600;
    padding: 8px 16px;
    background: rgba(255, 255, 255, 0.6);
    border-radius: 12px;
    display: inline-block;
}

@keyframes slideIn {
    from {
        opacity: 0;
        transform: translateX(-50%) translateY(-20px);
    }
    to {
        opacity: 1;
        transform: translateX(-50%) translateY(0);
    }
}

.home-button {
    position: fixed;
    top: 20px;
    left: 20px;
    z-index: 1000;
    background: linear-gradient(135deg, #FFF8E7 0%, #FFE8B4 100%);
    color: #5A4A42;
    border: 3px solid #FFB74D;
    border-radius: 50px;
    padding: 12px 20px;
    font-size: 1.5rem;
    text-decoration: none;
    font-family: var(--font-heading);
    font-weight: 700;
    box-shadow: 0 4px 12px rgba(255, 183, 77, 0.3);
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    gap: 8px;
}

.home-button:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 16px rgba(255, 183, 77, 0.4);
    background: linear-gradient(135deg, #FFE8B4 0%, #FFD54F 100%);
}

.home-button:active {
    transform: translateY(0);
}

/* Mobile Responsiveness */
@media (max-width: 768px) {
    .game-container {
        padding-top: 80px;
        padding-bottom: 15px;
    }

    .game-header {
        margin-bottom: 10px;
    }

    .map-container {
        padding: 10px;
    }

    #us-map {
        padding: 10px;
        max-height: calc(100vh - 250px);
    }

    .capital-info {
        top: 10px;
        padding: 15px 25px;
        min-width: 250px;
        max-width: 90%;
    }

    .home-button {
        top: 10px;
        left: 10px;
        padding: 10px 16px;
        font-size: 1.2rem;
    }

    .state-path {
        stroke-width: 1.5;
    }
}

@media (max-width: 480px) {
    .capital-info {
        padding: 12px 20px;
        min-width: 200px;
    }

    .capital-state-name {
        font-size: 1.2rem;
    }

    .capital-city-name {
        font-size: 1rem;
        padding: 6px 12px;
    }
}

