* { user-select: none; -webkit-user-select: none; box-sizing: border-box; }
       body { 
            margin: 0; background: #000; font-family: 'Segoe UI', sans-serif; 
            display: flex; justify-content: center; align-items: center; 
            /* Use dvh to account for browser toolbars */
            height: 100dvh; 
            min-height: -webkit-fill-available;
            touch-action: none; overflow: hidden;
        }

        #game-container { 
            position: relative; 
            width: 100vw; max-width: 450px; 
            /* Match the body height */
            height: 100dvh; 
            background: radial-gradient(circle at center, #0a0a1a 0%, #000 100%);
            overflow: hidden;
            /* Add padding to the container itself to push everything down */
            /*padding-top: env(safe-area-inset-top, 0px);*/
            padding-top: 0;
        }
canvas {
    position: absolute;
    width: 100%; 
    height: 100%; 
    display: block; 
    z-index: 1;
    image-rendering: -moz-crisp-edges;
    image-rendering: -webkit-optimize-contrast;
    image-rendering: pixelated;
    image-rendering: optimizeSpeed;
}

        /* New Menu Styles */
#start-menu {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 12px;
    z-index: 800;
}

.start-overlay-sector-level{
    /*color: #cbcbcb;*/
    color: #5fd3ff;
    text-shadow: 0px 0px 10px #3fa6dd;
    font-size: 2rem;
    font-weight: 700;
}

.copyright {
    margin-top: 20px;
    color: #dcfcff;
    font-size: 0.8rem;
    font-family: monospace;
}
.copyright-year{
    color: #dcfcff;
}
/* Sector Selection Overlay */
#sector-overlay {
    position: absolute; top: 0; left: 0; width: 100%; height: 100%;
    background: rgba(0,0,0,0.95); z-index: 900; display: none;
    flex-direction: column; justify-content: center; align-items: center;
}
#breach-slots { letter-spacing: 5px; font-weight: bold; transition: 0.3s; }
#breach-tracker{
    font-size: 0.8rem;
    font-weight: 700;
    color: #ff3366;
    margin: 10px 0px;    
}
.breach-active { color: #ff0000; text-shadow: 0 0 10px #ff0000; }
.sector-list {
    width: 200px;
    height: 300px;
    overflow-y: auto;
    border: 1px solid #00f2ff;
    margin-bottom: 20px;
    padding: 10px;
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.sector-item {
    padding: 15px;
    border: 1px solid #333;
    color: #fff;
    text-align: center;
    cursor: pointer;
}
.overlay-high-score-container, .random-sub-title{
    color: #ffffff;
    display: flex;
    flex-direction:column;
    justify-content: center;
    align-items: center;
}
.overlay-high-score{
    color: gold;
    font-size: 3rem;
    font-weight: 800;
    margin: 10px;
}
.overlay-high-score {
    display: flex;
    align-items: center;
    gap: 8px;
    color: #FCD116;
    text-shadow: 0px 0px 8px #FCD116;
    font-family: 'Orbitron', sans-serif; /* Or your preferred font */
}

.overlay-high-score::before {
    content: "";
    display: inline-block;
    width: 50px;
    height: 50px;
    background-color: currentColor; /* Matches the #FCD116 text */
    /* Exact Match: Stroke-only mask to prevent shading */
    -webkit-mask: url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 100 100"><polygon points="50 5, 90 25, 90 75, 50 95, 10 75, 10 25" fill="none" stroke="black" stroke-width="8"/><line x1="50" y1="25" x2="50" y2="75" stroke="black" stroke-width="10" stroke-linecap="round"/><path d="M 61 35 A 18 18 0 1 0 61 65" fill="none" stroke="black" stroke-width="10" stroke-linecap="round"/></svg>') no-repeat center;
    mask: url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 100 100"><polygon points="50 5, 90 25, 90 75, 50 95, 10 75, 10 25" fill="none" stroke="black" stroke-width="8"/><line x1="50" y1="25" x2="50" y2="75" stroke="black" stroke-width="10" stroke-linecap="round"/><path d="M 61 35 A 18 18 0 1 0 61 65" fill="none" stroke="black" stroke-width="10" stroke-linecap="round"/></svg>') no-repeat center;
    mask-size: contain;
    -webkit-mask-size: contain;
}
.sector-item:active { background: #00f2ff; color: #000; }

/* Hide the crawl when the menu is active */
.crawl-hidden { animation: none !important; display: none !important; }
        
        .ui-panel {
            position: absolute; 
            /*top: env(safe-area-inset-top, 20px); */
            left: 0;
            width: 100%; 
            padding: 10px 20px;
            display: flex; 
            flex-direction: column; 
            padding: calc(10px + env(safe-area-inset-top, 10px)) 20px 10px 20px;
            /*color: #ffd700; */
            color: #00deff;
            font-weight: bold; 
            font-family: monospace; 
            pointer-events: none;
            z-index: 10;
        }
        .ui-top { display: flex; justify-content: space-between; align-items: center; width: 100%; }
#score-and-life-container{
    display: flex;
    flex-direction: column;
    gap: 5px;
}
#score, #hangar-total-currency-container { 
    font-size: 1.8rem;
    font-weight: bold;
    /*text-shadow: 0 0 10px #ffd700;*/ 
    color: #ffffff;
    text-shadow: 0px 0px 11px #3b9fff;
    margin-bottom: 14px;
}
#score {
    display: flex;
    align-items: center;
    justify-content: flex-start;
    gap: 6px;
    font-family: 'Orbitron', sans-serif;
    font-size: 24px;
    margin-bottom: 0;
}

#score::before {
    content: "";
    display: inline-block;
    width: 0.8em; 
    height: 0.8em;
    background-color: currentColor;
    /* Clean mask using only strokes - No shading */
    -webkit-mask: url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 100 100"><polygon points="50 5, 90 25, 90 75, 50 95, 10 75, 10 25" fill="none" stroke="black" stroke-width="8"/><line x1="50" y1="25" x2="50" y2="75" stroke="black" stroke-width="10" stroke-linecap="round"/><path d="M 61 35 A 18 18 0 1 0 61 65" fill="none" stroke="black" stroke-width="10" stroke-linecap="round"/></svg>') no-repeat center;
    mask: url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 100 100"><polygon points="50 5, 90 25, 90 75, 50 95, 10 75, 10 25" fill="none" stroke="black" stroke-width="8"/><line x1="50" y1="25" x2="50" y2="75" stroke="black" stroke-width="10" stroke-linecap="round"/><path d="M 61 35 A 18 18 0 1 0 61 65" fill="none" stroke="black" stroke-width="10" stroke-linecap="round"/></svg>') no-repeat center;
    mask-size: contain;
    -webkit-mask-size: contain;
}
        #stability { font-size: 0.9rem; }

        #intro-overlay, #game-over-overlay, #success-overlay {
            position: absolute; top: 0; left: 0; width: 100%; height: 100%;
            background: rgba(0,0,0,0.9); z-index: 600; display: none; 
            flex-direction: column; justify-content: center; align-items: center;
        }

        #intro-overlay { background: black; display: none; z-index: 700; perspective: 300px; }
        #intro-crawl {
            position: relative; color: #ffd700; text-align: center;
            font-weight: bold; width: 85%; transform: rotateX(20deg);
            animation: crawl 20s linear forwards;
        }
        @keyframes crawl { 0% { top: 400px; } 100% { top: -600px; } }

        #boss-ui { width: 100%; display: none; margin-top: 10px; }
        #boss-bar-container { width: 100%; height: 8px; background: rgba(255,0,0,0.2); border: 1px solid #ff0000; }
        #boss-hp-fill { width: 100%; height: 100%; background: #ff0000; box-shadow: 0 0 10px #ff0000; }

        .overlay-title { font-size: 2rem; text-align: center; margin-bottom: 30px; }
        #game-over-overlay h2 { color: #ff0000; text-shadow: 0 0 20px #ff0000; }
        #success-overlay h2 { color: #00f2ff; text-shadow: 0 0 20px #00f2ff; }
        
.btn-group {
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    gap: 35px;
    margin-top: 30px;
    width: 350px;
}
button, .more-games-btn { 
    padding: 15px;
    background: transparent;
    border: 2px solid #75e4ff;
    color: #75e4ff;
    text-shadow: 0px 0px 4px;
    box-shadow: 0px 0px 8px;
    /*border-color: #00f2ff;
    color: #00f2ff;*/
    border-color: #00ffa8;
    color: #00ffa8;
    border-radius: 12px;
    cursor: pointer;
    font-family: monospace;
    font-weight: bold;
    transition: 0.2s;
    width: 100%;
}
.play-btn, .resume-btn, .restart-btn, .next-sector-btn{
    font-size: 1.3rem;
}
.close-hangar-btn{
    max-width:70vw;
}
#amplify-btn{
    position: relative;
    display: flex;
    color: rgb(255, 215, 0);
    background: rgba(255, 215, 0, 0.1);
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 10px 20px;
    font-weight: bold;
    cursor: pointer;
    border: 2px solid rgb(255, 215, 0);
    border-radius: 4px;
}
.test-flight-btn{
    border-color: #ffcf00;
    color: #ffcf00;
}
.overlay-main-btns-container, .multiple-btn-container{
    display: flex;
    flex-direction: row;
    justify-content: center;
    align-items: center;
    gap: 25px;
    width: 350px;
}
.pause-overlay-btns{
    
}
.open-hangar-btn{
    position: relative;
    border: 2px solid #cecdc3;
    box-shadow: 0px 0px 8px white;
    color: #ffe000;
    padding: 11px;
    width: 69px !important;
    height: 58px;
}
.open-hangar-btn svg{
    max-height:50px;
}
.revive-btn{
    border-color: #0fc607;
    color: #0fc607;
    margin-bottom: 20px;
}
.more-games-btn, .share-btn{
    border: 2px solid #f2f2f2;
    color: #f2f2f2;
    text-align: center;
    text-decoration: none;
}
        button:active { background: #ffd700; color: #000; }
.btn-next { 
    border-color: #00f2ff; 
    color: #00f2ff; 
}
.select-sector-btn{
    /*border-color: #d6e3f5;
    color: #d6e3f5;*/
    border: 2px solid #f2f2f2;
    color: #f2f2f2;
}
#warning-text, #sector-market-text , #black-baron-enters-text{
    position: absolute; top: 40%; width: 100%; text-align: center;
    color: #ff0000; text-shadow: 0px 0px 4px #ff0000;font-size: 2rem; font-weight: bold; display: none; z-index: 400;
    animation: flash 0.9s infinite;
}
#sector-market-text{
    color: #ffffff;
    text-shadow: 0px 0px 8px #46dd8e;
    animation: flash 0.6s infinite;
}
#black-baron-enters-text {
    position: absolute;
    top: 30%;
    width: 100%;
    text-align: center;
    color: #f23131;
    text-shadow: 0px 0px 15px #372a2a, 0px 0px 5px #000;
    font-family: monospace;
    font-weight: 900;
    font-size: 1.4rem;
    letter-spacing: 5px;
    text-transform: uppercase;
    pointer-events: none;
    opacity: 0;
    
    /* 2.8s total ensures it finishes BEFORE your 3s setTimeout hits */
    animation: baronFastFit 2.8s ease-in-out forwards;
}

@keyframes baronFastFit {
    0% { 
        opacity: 0; 
        transform: scale(0.9);
        filter: blur(8px);
    }
    /* Fade in ends at 0.4s (approx 14%) */
    14% { 
        opacity: 1; 
        transform: scale(1);
        filter: blur(0px);
    }
    /* Hold starts to drop at 2.2s (approx 78%) */
    78% { 
        opacity: 1; 
        transform: scale(1);
        filter: blur(0px);
    }
    /* Final fade out over the last 0.6s */
    100% { 
        opacity: 0; 
        transform: scale(1.1);
        filter: blur(4px);
    }
}

@keyframes flash { 0%, 100% { opacity: 1; } 50% { opacity: 0; } }
.hidden { display: none !important; }
#hangar-overlay {
    display: none; /* Toggle with JS */
    position: fixed;
    top: 0; left: 0; width: 100%; height: 100%;
    background: rgba(0, 0, 0, 0.95);
    flex-direction: column;
    align-items: center;
    color: white;
    font-family: 'Courier New', Courier, monospace;
    z-index: 1000;
}

#skin-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
    padding: 20px;
    width: 90%;
    
    /* Use height instead of max-height to force the constraint */
    height: 60vh; 
    
    /* Modern scrolling properties */
    overflow-y: auto;
    overflow-x: hidden;
    
    /* Fix for mobile momentum scrolling */
    -webkit-overflow-scrolling: touch; 
    
    /* Ensure touch events aren't swallowed */
    touch-action: pan-y;
    
    /* Prevent the grid from shrinking or growing weirdly */
    flex-shrink: 0;
}

.skin-card {
    /*background: rgba(255, 255, 255, 0.05);
    border: 1px solid #444;*/
    background: rgb(41 41 41 / 86%);
    border: 1px solid #262525;
    border-radius: 10px;
    padding: 15px;
    text-align: center;
    transition: transform 0.2s, border-color 0.2s;
    height: auto;
    min-height: 142px;
}

.skin-card:active {
    transform: scale(0.95);
    border-color: #00f2ff;
}

.svg-container {
    width: 80px;
    height: 80px;
    margin: 0 auto 10px;
}

.skin-card p {
    margin: 0;
    font-size: 12px;
    letter-spacing: 1px;
    color: #ffffff;
}
/* The ship you are currently flying */
.skin-card.equipped-active {
    border: 2px solid #00f2ff !important; /* Cyan or Neon Blue */
    box-shadow: 0 0 15px rgba(0, 242, 255, 0.5);
    background: rgba(0, 242, 255, 0.05);
}

/* Add a small 'IN USE' label if you want to be extra clear */
.skin-card.equipped-active::after {
    content: 'IN USE';
    position: absolute;
    top: 5px;
    left: 5px;
    font-size: 12px;
    color: #00f2ff;
    font-weight: bold;
    letter-spacing: 1px;
}
.details-drawer {
    grid-column: 1 / -1; /* Always spans both columns */
    display: none; /* Hidden by default */
    background: rgb(10 20 25 / 95%);
    border: 1px solid #66c6c0;
    border-radius: 8px;
    padding: 15px;
    margin: 10px 0;
    transition: all 0.3s ease;
}

/* When active, we show it */
.details-drawer.active {
    display: block;
    animation: fadeIn 0.2s ease-in;
}

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

#modal-container {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    z-index: 2000;
    pointer-events: none; /* Allows clicking through to the background when modal is closed */
    background: rgba(0, 0, 0, 0);
    transition: background 0.3s ease;
}

/* When modal is open, we turn on pointer events for the darkened backdrop */
#modal-container.active {
    pointer-events: all;
    background: rgba(0, 0, 0, 0.6);
}

#unlock-modal {
    position: fixed;
    top: 0; left: 0;
    width: 100vw; height: 100vh;
    background: rgba(0, 0, 0, 0.85);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 1000;
    /*backdrop-filter: blur(4px);*/
}

.modal-content {
    background: #0a0a1a;
    border: 2px solid #00f2ff;
    padding: 30px;
    text-align: center;
    max-width: 400px;
    border-radius: 4px; /* Sharp edges feel more military/tech */
    box-shadow: 0 0 30px rgba(0, 242, 255, 0.2);
}

.modal-title {
    color: #ff3333; /* Red for 'Warning/Action' */
    font-size: 1.2rem;
    margin-bottom: 20px;
    letter-spacing: 3px;
}

.modal-text {
    color: #fff;
    line-height: 1.6;
    margin-bottom: 30px;
}

.price-highlight { color: #FCD116; font-weight: bold; }
.unit-highlight { color: #00f2ff; font-weight: bold; }

.modal-actions {
    display: flex;
    gap: 20px;
    justify-content: center;
}

/* Concise Buttons to reduce mistakes */
.btn-primary {
    background: #00f2ff;
    color: #000;
    border: none;
    padding: 12px 25px;
    font-weight: bold;
    cursor: pointer;
}

.btn-secondary {
    background: transparent;
    color: #888;
    border: 1px solid #444;
    padding: 12px 25px;
    cursor: pointer;
}

.btn-primary:hover { background: #fff; }
.btn-secondary:hover { color: #fff; border-color: #fff; }

#ship-modal {
    position: absolute;
    right: 0;
    top: 0;
    width: 80vw;
    height: 100%;
    background: #0a0a0a;
    border-left: 2px solid #ffd700;
    padding: 30px 20px;
    box-sizing: border-box;
    display: flex;
    flex-direction: column;
    align-items: center;
    box-shadow: -10px 0 20px rgba(0,0,0,0.5);
    
    /* The Magic Slide */
    transform: translateX(100%);
    transition: transform 0.3s cubic-bezier(0.25, 1, 0.5, 1);
}

.ship-card {
    transition: transform 0.1s active;
}

.ship-card:active {
    transform: scale(0.95);
}

#sector-list {
    display: grid;
    /* This creates the 4 VERTICAL standing columns */
    grid-template-columns: repeat(4, 1fr); 
    
    /* Remove grid-template-rows and grid-auto-flow! */
    gap: 12px;
    padding: 15px;
    width: 80%;
    max-height: 50vh;
    
    /* Vertical scroll only */
    overflow-y: auto;
    overflow-x: hidden;
    
    border: 1px solid #333;
    background: rgba(255, 255, 255, 0.05);
    border-radius: 5px;
    -webkit-overflow-scrolling: touch;
    overflow-y: scroll !important; 
    touch-action: pan-y !important;
    -webkit-overflow-scrolling: touch; 
    
    pointer-events: auto;
}

#sector-list::-webkit-scrollbar {
    height: 6px;
}

#sector-list::-webkit-scrollbar-thumb {
    background: #333;
    border-radius: 10px;
}

/* Style for the individual sector buttons inside the grid */
#sector-list button {
    margin: 0 !important;
    padding: 15px 5px;
    background: rgb(20 36 44 / 75%);
    box-shadow: 0px 0px 5px;
    border: 1px solid #444;
    color: #fff;
    font-size: 1.2rem;
    font-family: 'monospace';
    text-transform: uppercase;
    cursor: pointer;
    transition: 0.2s;
}

#sector-list button:active {
    background: #ffd700;
    color: #000;
}

/* Container for top-right UI */
.ui-controls {
    display: flex;
    flex-direction: column;
    align-items: flex-end; /* Align everything to the right edge */
    gap: 8px;
}

/* Horizontal row for the buttons */
.control-buttons {
    display: flex;
    gap: 10px;
}
.menu-btn{
    pointer-events: auto;
}
/* Base style for SVG Icon Buttons */
.icon-btn {
    background: rgba(0, 0, 0, 0.6);
    border: 1px solid #dbf2ff;
    color: aliceblue;
    color: #dbf2ff;
    text-shadow: 0px 0px 11px #3b9fff;
    width: 36px;
    height: 36px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    border-radius: 7px;
    padding: 6px;
    transition: all 0.2s ease;
    box-shadow: 0 0 10px rgba(0, 242, 255, 0.2);
    pointer-events: auto;
}

.icon-btn svg {
    width: 100%;
    height: 100%;
}

.icon-btn:active {
    background: #00f2ff;
    color: #000;
    box-shadow: 0 0 20px #00f2ff;
    transform: scale(0.95);
}

/* Stability Text Style Adjustments */
#stability {
    font-family: monospace;
    font-size: 0.8rem;
    /*color: #00f2ff;
    text-shadow: 0 0 5px #00f2ff;*/
    /*color: #04ff00;
    text-shadow: 0 0 5px #00ff03;*/
    color: #4fff00;
    text-shadow: 0 0 5px #4fff00;
    background: rgba(0, 0, 0, 0.4);
    padding: 2px 6px;
    /*border-right: 2px solid #00f2ff;*/
}
#heart-container {
    width: 90px; /* Adjusted to fit 3 hearts perfectly */
    height: 21px;
    top: 0;
    left:-5px;
    position: relative;
    /* Added quotes and ensured the color code %23333333 is clean */
    background-image: url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" fill="%23333333"><path d="M12 21.35l-1.45-1.32C5.4 15.36 2 12.28 2 8.5 2 5.42 4.42 3 7.5 3c1.74 0 3.41.81 4.5 2.09C13.09 3.81 14.76 3 16.5 3 19.58 3 22 5.42 22 8.5c0 3.78-3.4 6.86-8.55 11.54L12 21.35z"/></svg>');
    background-repeat: repeat-x;
    background-size: 30px 23px;
    background-position: left center; /* CRITICAL: Align with the fill */
    overflow: hidden;
}

#heart-fill {
    width: 100%;
    height: 100%;
    background-image: url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" fill="%23ff0000"><path d="M12 21.35l-1.45-1.32C5.4 15.36 2 12.28 2 8.5 2 5.42 4.42 3 7.5 3c1.74 0 3.41.81 4.5 2.09C13.09 3.81 14.76 3 16.5 3 19.58 3 22 5.42 22 8.5c0 3.78-3.4 6.86-8.55 11.54L12 21.35z"/></svg>');
    background-repeat: repeat-x;
    background-size: 30px 23px;
    background-position: left center;
    transition: width 0.3s ease-out;
    filter: drop-shadow(0 0 5px #ff0000);
}
#breach-slots {
    /* EMPTY DIAMOND OUTLINES (Grey) */
    background-image: url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" fill="none" stroke="%23333333" stroke-width="2"><path d="M12 2L2 12l10 10 10-10L12 2z"/></svg>');
    background-repeat: repeat-x;
    background-size: 30px 25px;
    background-position: left center;
}

#breach-fill {
    /* ACTIVE BREACH DIAMONDS (Neon Orange with "!") */
    background-image: url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" fill="%23ff8800"><path d="M12 2L2 12l10 10 10-10L12 2z"/><text x="12" y="17" text-anchor="middle" fill="black" font-weight="bold" font-family="Arial" font-size="12">!</text></svg>');
    background-repeat: repeat-x;
    background-size: 30px 25px;
    background-position: left center;
    filter: drop-shadow(0 0 5px #ff8800);
}

.breach-active {
    animation: breach-flicker 0.8s infinite;
}

@keyframes breach-flicker {
    0% { opacity: 1; }
    50% { opacity: 0.7; }
    100% { opacity: 1; }
}
#pause-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.85);
    /*backdrop-filter: blur(4px);*/ /* Adds a high-end tech feel */
    z-index: 2000;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    text-align: center;
}
.overlay-content{
    position: relative;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
}
/* Ensure the button group matches your existing UI style */
#pause-overlay .btn-group {
    display: flex;
    flex-direction: column;
}

#pause-overlay button {
    width: 100%;
    text-transform: uppercase;
    letter-spacing: 1px;
}

/* Ensure the card is the reference point for absolute children */
.skin-card {
    position: relative;
    overflow: hidden; /* Keeps the tag from poking out if you use a ribbon style */
    transition: opacity 0.3s ease;
}

.status-tag {
    position: absolute;
    top: 5px;
    right: 5px;
    padding: 2px 8px;
    font-size: 10px;
    font-weight: bold;
    border-radius: 3px;
    letter-spacing: 1px;
    pointer-events: none; /* So it doesn't block the click on the card */
    z-index: 5;
}

.locked-tag {
    background: rgba(255, 0, 0, 0.7);
    color: white;
    border: 1px solid #ff3333;
    text-shadow: 0 0 5px rgba(0,0,0,0.5);
}

.owned-tag {
    /*background: rgba(0, 242, 255, 0.2);
    color: #00f2ff;
    border: 1px solid #00f2ff;*/
    background: rgb(0 255 125 / 20%);
    color: #00ff80;
    border: 1px solid #00ffad;
}

#end-test-btn{
    position: fixed;
    top: 25px;
    left: auto;
    right: 20px;
    width: 200px;
    padding: 12px 24px;
    background: rgba(255, 50, 50, 0.9);
    color: white;
    border: 2px solid white;
    border-radius: 12px;
    font-size: 0.7rem;
    font-weight: 900;
    z-index: 10000;
    cursor: pointer;
    box-shadow: rgba(255, 0, 0, 0.6) 0px 0px 20px;
    font-family: inherit;
    transition: 0.3s;
}
#start-menu, 
#hangar-overlay, 
#sector-select-overlay, 
#pause-overlay, 
#game-over-overlay, 
#intro-overlay, 
#success-overlay, 
#revive-overlay {
    padding-top: calc(80px + env(safe-area-inset-top, 0px));
    box-sizing: border-box;
}

.get-it-on-btn-container{
    display:none;
    margin: 30px auto;
    gap: 25px;
}
@keyframes blink {
    0% { opacity: 1; }
    50% { opacity: 0; }
    100% { opacity: 1; }
}
@media only screen and (max-width: 375px) {
    #skin-grid{
        height: 50vh;
    }
}
@media only screen and (max-width: 600px) {
    .btn-group{
        width: 90vw;
    }
    .overlay-main-btns-container, .multiple-btn-container{
        width: 90vw;
    }
}
/* Add this to your main game container or canvas */
#gameCanvas, .modal-content, .skin-card {
    transform: translateZ(0); /* Forces a new GPU layer */
    will-change: transform;
    backface-visibility: hidden;
}

