* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
    font-family: Arial, sans-serif;
}

@font-face {
    font-family: Burbank Small;
    font-style: normal;
    font-display: swap;
    src: url(Burbank-Small.woff) format("woff"),url(Burbank-Small.ttf) format("truetype")
}

body {
    min-height: 100vh;
    background-color: #22a4f3;
    display: flex;
    flex-direction: column;
}

.page-container {
    display: flex;
    flex-direction: column;
    min-height: 100vh;
    justify-content: space-between;
    gap: 20px;
}

.main-container {
    display: flex;
    background-color: #22a4f3;
    flex-direction: row;
    flex-grow: 1;
    justify-content: space-between;
}

.navbar {
    position: relative;
    z-index: 1000;
    padding: 0 20px;
    display: flex;
    justify-content: flex-start;
    align-items: center;
    height: 50px;
    background-color: #22a4f3;
    gap: 15px;
}

.navbar a:hover {
    color: #f7e23c; /* Red text color on hover (use any color name or hex code) */
}

.navbar-mobile-button {
    display: none !important;
}

@media (max-width: 525px) {
    nav > a {
        display: none;
    }
}


.home-icon-group {
    display: flex;
    align-items: center;
}

.home-icon-wrapper {
    height: 32px;
    width: 28px;
    display: flex;
}

.arrow-icon-wrapper {
    height: 24px;
    width: 24px;
    display: flex;
}

.icon {
    height: 100%;
    width: 100%;
    fill: white;
    color: white;
    margin: auto;
}

nav a {
    color: #fff;
    font-size: 14px;
    font-weight: bold;
    font-family: Burbank Small;
    text-decoration: none;
}

nav div {
    color: #fff;
    font-size: 14px;
    font-weight: bold;
    font-family: Burbank Small;
    text-decoration: none;
}

#clear-cache {
    margin-left: auto;
}

.button {
    background-color: #007bff;
    color: white;
    padding: 6px 12px;
    border: none;
    border-radius: 8px;
    cursor: pointer;
    user-select: none;
    display: flex;
    justify-self: right;
}

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

.game {
    display: flex;
    justify-content: center;
    align-items: center;
    width: 100%;
    max-width: 60vw;
    z-index: 0;
}

.game-canvas {
    width: 100%;
    aspect-ratio: 1.58;
}

.ad {
    background: rgb(0, 65, 155);
    font-size: 12px;
    padding: 0px;
    display: flex;
    justify-content: center;
    flex-shrink: 0;
}

.ad.top {
    width: 970px;
    height: 90px;
    align-self: center !important;
}

.ad.side {
    margin-top: 50px;
    width: 160px;
    height: 600px;
    margin: 50px 20px;
}

@media (max-width: 1320px) {
    .ad.top {
        width: 728px;
        height: 90px;
    }
}

@media (max-width: 1080px) {
    .ad.side {
        width: 120px;
        height: 600px;
    }
}

@media (max-width: 1000px) {
    .ad.top {
        display: none;
    }
}

@media (max-width: 320px) {
    .ad.top {
        display: none;
    }
}

.tooltip-modal {
    text-align: left;
    background: rgba(0, 0, 0, 0.8);
    color: white;
    font-size: 16px;
    width: 100vw;
    height: 100vh;
    position: fixed;
    display: none;
    justify-content: flex-end;
    align-items: flex-start;
    flex-direction: column;
}

.tooltip-content {
    display: flex;
    width: 100%;
    height: 100%;
    flex-direction: column;
    justify-content: flex-end;
}

.penguin-tooltip {
    object-fit: contain;
    height: 50vh;
    width: auto;
    margin-left: -150px;
}

.tooltip-text {
    background: white;
    padding: 20px;
    font-size: 18px;
    color: black;
    margin: 20px;
    border: 3px solid #979797;
    max-width: 400px;
    border-radius: 8px;
}

.tooltip-button {
    width: 80px;
    display: flex;
    align-self: flex-end;
    margin-right: 20px;
}

.content {
    flex: 1;
    display: flex;
    justify-content: center;
    align-items: center;
}

.canvas-wrapper {
    display: flex;
    width: 100%;
    max-width: 80vh;
    aspect-ratio: 1.58;
    background: #ccc;
}

footer {
    display: flex;
    flex-direction: column;
    background: #22a4f3;
    color: #fff;
    padding: 10px;
    font-size: 12px;
    gap: 6px;
    text-align: center;
    flex-shrink: 0;
}

footer .links {
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 4px;
}

footer a {
    color: #ffcc00;
    font-weight: bold;
    text-decoration: none;
}

#exit-fullscreen-button {
    position: absolute;
    margin: 10px;
}

#exit-fullscreen-button {
    top: 0;
    right: 0;
    display: none;
}

/* ========================================
   NEW: Settings Dropdown Styles
   ======================================== */

.settings-dropdown {
    position: relative;
    display: inline-block;
}

/* Add invisible padding to bridge the gap */
.settings-dropdown::after {
    content: '';
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    height: 10px;
    z-index: 999;
}

.settings-trigger {
    cursor: pointer;
    transition: background-color 0.2s;
}

.settings-trigger:hover {
    background-color: #5a6268;
}

.resize:hover {
    background-color: #5a6268;
}

#fullscreen-button:hover {
    background-color: #5a6268;
}

.settings-dropdown-content {
    display: none;
    position: absolute;
    right: 0;
    top: 100%;
    margin-top: 2px;
    background-color: white;
    min-width: 220px;
    box-shadow: 0 8px 16px rgba(0, 0, 0, 0.3);
    border-radius: 8px;
    z-index: 1000;
    overflow: hidden;
    animation: dropdownSlide 0.2s ease-out;
}

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

.settings-dropdown:hover .settings-dropdown-content {
    display: block;
}

.dropdown-item {
    width: 100%;
    padding: 12px 16px;
    border: none;
    background: white;
    color: #202121;
    text-align: left;
    cursor: pointer;
    font-size: 14px;
    font-weight: 400;
    font-family: Burbank Small;
    transition: background-color 0.2s;
    display: flex;
    align-items: center;
    gap: 8px;
}

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

.dropdown-item:active {
    background-color: #e9ecef;
}

/* Special styling for the cache clear button */
#clear-cache-button:hover {
    background-color: #fff5f5;
    color: #dc3545;
}

#clear-yukon-button:hover {
    background-color: #f0f8ff;
    color: #007bff;
}

#hard-reload-button:hover {
    background-color: #f0fff4;
    color: #28a745;
}

/* Cache message styling */
@keyframes slideIn {
    from {
        transform: translateX(400px);
        opacity: 0;
    }
    to {
        transform: translateX(0);
        opacity: 1;
    }
}

#cache-message {
    position: fixed;
    top: 60px;
    right: 20px;
    padding: 15px 20px;
    border-radius: 8px;
    font-weight: bold;
    z-index: 10000;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.2);
    animation: slideIn 0.3s ease-out;
}

/* Mobile responsiveness */
@media (max-width: 768px) {
    .settings-dropdown-content {
        right: auto;
        left: 0;
    }
}

@media (max-width: 525px) {
    .settings-dropdown {
        margin-left: auto;
    }
}
