* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'MS Sans Serif', 'Tahoma', sans-serif;
    overflow: hidden;
    background: #008080;
    height: 100vh;
    width: 100vw;
    cursor: url('./elements/cursor.png'), auto;
}

* {
    cursor: url('./elements/cursor.png'), auto;
}

/* Loading Screen */
.loading-screen {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: #000;
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 1000;
    transition: opacity 0.5s ease-out;
}

.loading-screen.fade-out {
    opacity: 0;
    pointer-events: none;
}

.loading-content {
    text-align: center;
    color: #fff;
}

.loading-logo {
    margin-bottom: 30px;
    display: flex;
    justify-content: center;
    align-items: center;
}

.loading-logo img {
    width: 120px;
    height: 120px;
    object-fit: contain;
}

.loading-title {
    font-size: 48px;
    margin-bottom: 40px;
    color: #fff;
    text-transform: lowercase;
    letter-spacing: 2px;
}

.ellipsis {
    display: inline-block;
}

.ellipsis .dot {
    opacity: 0;
    animation: dotFade 1.4s infinite;
}

.ellipsis .dot:nth-child(1) {
    animation-delay: 0s;
}

.ellipsis .dot:nth-child(2) {
    animation-delay: 0.2s;
}

.ellipsis .dot:nth-child(3) {
    animation-delay: 0.4s;
}

@keyframes dotFade {
    0%, 100% {
        opacity: 0;
    }
    50% {
        opacity: 1;
    }
}

.loading-bar-container {
    width: 300px;
    height: 20px;
    background: #333;
    border: 2px solid #666;
    position: relative;
    margin: 0 auto;
}

.loading-bar {
    height: 100%;
    width: 0%;
    background: linear-gradient(to bottom, #00ff00, #00cc00);
    transition: width 0.1s linear;
    border: 1px solid #00ff00;
}

.hidden {
    display: none !important;
}

/* Desktop */
.desktop {
    width: 100vw;
    height: 100vh;
    background: url('elements/wallpaper.png') center center / cover no-repeat;
    position: relative;
    overflow: hidden;
}

/* Desktop Icons */
.desktop-icons {
    position: absolute;
    top: 20px;
    left: 20px;
    display: flex;
    flex-direction: column;
    gap: 60px;
}

.desktop-icon {
    display: flex;
    flex-direction: column;
    align-items: center;
    width: 80px;
    cursor: pointer;
    padding: 5px;
    border-radius: 2px;
    transition: background 0.2s;
}

.desktop-icon:hover {
    background: rgba(255, 255, 255, 0.1);
}

.desktop-icon:active {
    background: rgba(255, 255, 255, 0.2);
}

.icon-image {
    font-size: 48px;
    margin-bottom: 5px;
    text-align: center;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 48px;
    height: 48px;
}

.icon-image img {
    width: 48px;
    height: 48px;
    object-fit: contain;
}

.icon-label {
    color: #fff;
    text-shadow: 1px 1px 2px #000;
    font-size: 12px;
    text-align: center;
    word-break: break-word;
}

/* Windows */
.window {
    position: absolute;
    background: #c0c0c0;
    border: 2px outset #c0c0c0;
    box-shadow: 2px 2px 10px rgba(0, 0, 0, 0.5);
    width: 500px;
    height: 400px;
    display: none;
    z-index: 100;
}

#game-window {
    width: 1000px;
    height: 800px;
}

#memes-window {
    width: 500px;
    height: 450px;
}

#twitter-window,
#pump-window {
    width: 500px;
    height: 400px;
}

#lore-window {
    width: 550px;
    height: 340px;
}

.window.active {
    display: block;
}

.window-titlebar {
    background: linear-gradient(to bottom, #0080ff, #0055aa);
    color: #fff;
    padding: 4px 8px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    cursor: move;
    font-size: 11px;
    font-weight: bold;
    user-select: none;
}

.window-title {
    flex: 1;
}

.window-close {
    background: #c0c0c0;
    border: 1px outset #c0c0c0;
    width: 20px;
    height: 20px;
    cursor: pointer;
    font-size: 16px;
    line-height: 1;
    padding: 0;
    margin-left: 5px;
}

.window-close:active {
    border: 1px inset #c0c0c0;
}

.window-content {
    padding: 20px;
    background: #c0c0c0;
    height: calc(100% - 30px);
    overflow: auto;
}

.game-window-content {
    display: flex;
    flex-direction: column;
    padding: 0;
    overflow: hidden;
}

/* Game Window */
.game-main-area {
    flex: 1;
    display: flex;
    flex-direction: column;
    padding: 20px;
    overflow: hidden;
}

.touch-counter {
    text-align: center;
    margin-bottom: 10px;
    flex-shrink: 0;
}

.touch-counter h2 {
    font-size: 24px;
    color: #000;
    transition: color 0.3s ease;
}

.touch-counter h2.flash-green {
    animation: flashGreen 0.5s ease-out;
}

@keyframes flashGreen {
    0% {
        color: #000;
    }
    50% {
        color: #00ff00;
        text-shadow: 0 0 10px rgba(0, 255, 0, 0.8);
    }
    100% {
        color: #000;
    }
}

.game-area {
    flex: 1;
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 0;
    overflow: hidden;
}

.grass-icon {
    cursor: url('./elements/cursor.png'), pointer;
    transition: transform 0.1s;
    user-select: none;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    height: 100%;
    position: relative;
}

.auto-touch-cursor {
    position: absolute;
    width: 54px !important;
    height: 54px !important;
    max-width: 54px !important;
    max-height: 54px !important;
    min-width: 54px !important;
    min-height: 54px !important;
    pointer-events: none;
    z-index: 10;
    opacity: 0;
    transition: opacity 0.3s;
    object-fit: contain;
    image-rendering: crisp-edges;
}

.auto-touch-cursor.active {
    opacity: 1;
}

.auto-touch-cursor.pulse {
    animation: cursorPulse 0.3s ease-out;
}

@keyframes cursorPulse {
    0% {
        transform: translate(-50%, -50%) scale(1);
    }
    50% {
        transform: translate(-50%, -50%) scale(1.3);
    }
    100% {
        transform: translate(-50%, -50%) scale(1);
    }
}

.grass-icon img {
    width: 100%;
    height: 100%;
    max-width: 300px;
    max-height: 300px;
    object-fit: contain;
    pointer-events: none;
    animation: pulse 2s ease-in-out infinite, pulseGlow 2s ease-in-out infinite;
}

@keyframes pulse {
    0%, 100% {
        transform: scale(1);
    }
    50% {
        transform: scale(1.1);
    }
}

@keyframes pulseGlow {
    0%, 100% {
        filter: drop-shadow(0 0 15px rgba(0, 255, 0, 0.4));
    }
    50% {
        filter: drop-shadow(0 0 25px rgba(0, 255, 0, 0.7));
    }
}

.grass-icon:hover {
    transform: scale(1.02);
}

.grass-icon:active {
    transform: scale(0.98);
}

/* Floating +1 animation */
.float-number {
    position: fixed;
    pointer-events: none;
    font-size: 32px;
    font-weight: bold;
    color: #00ff00;
    z-index: 10000;
    animation: floatUp 1s ease-out forwards;
    text-shadow: 0 0 10px rgba(0, 255, 0, 1), 0 0 20px rgba(0, 255, 0, 0.8);
}

@keyframes floatUp {
    0% {
        opacity: 1;
        transform: translateY(0) scale(1) rotate(0deg);
    }
    50% {
        opacity: 1;
        transform: translateY(-30px) scale(1.2) rotate(5deg);
    }
    100% {
        opacity: 0;
        transform: translateY(-80px) scale(0.8) rotate(-5deg);
    }
}

/* Shop Section */
.shop-section {
    background: #d0d0d0;
    border-top: 2px inset #c0c0c0;
    padding: 15px;
    flex-shrink: 0;
}

.shop-title {
    font-size: 16px;
    font-weight: bold;
    color: #000;
    margin-bottom: 10px;
    text-align: center;
}

.shop-items {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.shop-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: #c0c0c0;
    border: 2px inset #c0c0c0;
    padding: 10px 15px;
}

.shop-item.locked {
    opacity: 0.5;
    filter: grayscale(100%);
    pointer-events: none;
}

.shop-item-info {
    display: flex;
    flex-direction: column;
    gap: 5px;
}

.shop-item-name {
    font-size: 14px;
    font-weight: bold;
    color: #000;
}

.shop-item-cost {
    font-size: 12px;
    color: #333;
}

.shop-btn {
    background: #c0c0c0;
    border: 2px outset #c0c0c0;
    padding: 8px 20px;
    font-size: 14px;
    cursor: pointer;
    font-family: 'MS Sans Serif', 'Tahoma', sans-serif;
    font-weight: bold;
}

.shop-btn:active {
    border: 2px inset #c0c0c0;
}

.shop-btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

.shop-btn:hover:not(:disabled) {
    background: #d0d0d0;
}

.upgrade-status {
    margin-top: 10px;
    color: #000;
    font-size: 11px;
    text-align: center;
}

/* Memes Window */
.memes-content {
    background: #c0c0c0;
    overflow: hidden;
}

.meme-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 15px;
}

.meme-item {
    background: #fff;
    border: 2px inset #c0c0c0;
    padding: 5px;
    text-align: center;
    min-height: 150px;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
}

.meme-item img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    max-height: 200px;
    cursor: pointer;
    transition: transform 0.2s;
}

.meme-item img:hover {
    transform: scale(1.05);
}

/* Meme Overlay */
.meme-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    background: rgba(0, 0, 0, 0.9);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 10000;
    cursor: pointer;
}

.meme-overlay-content {
    position: relative;
    max-width: 90vw;
    max-height: 90vh;
    display: flex;
    justify-content: center;
    align-items: center;
}

.meme-overlay-content img {
    max-width: 100%;
    max-height: 90vh;
    object-fit: contain;
    border: 3px solid #fff;
    box-shadow: 0 0 30px rgba(0, 0, 0, 0.8);
}

.meme-close-btn {
    position: absolute;
    top: -40px;
    right: -40px;
    background: #ff0000;
    border: 2px solid #fff;
    color: #fff;
    width: 40px;
    height: 40px;
    font-size: 24px;
    cursor: pointer;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: bold;
    line-height: 1;
}

.meme-close-btn:hover {
    background: #cc0000;
}

/* Social Links Window */
.social-links {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.social-link {
    background: #c0c0c0;
    border: 2px outset #c0c0c0;
    padding: 15px 20px;
    text-decoration: none;
    color: #000;
    text-align: center;
    font-size: 14px;
    cursor: pointer;
    display: block;
}

.social-link:active {
    border: 2px inset #c0c0c0;
}

.social-link:hover {
    background: #d0d0d0;
}

.social-content {
    text-align: center;
    padding: 20px;
}

.social-content p {
    margin-bottom: 20px;
    color: #000;
    background: #fff;
    padding: 15px;
    border: 2px inset #c0c0c0;
    text-align: left;
    line-height: 1.6;
}

/* Taskbar */
.taskbar {
    position: fixed;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 40px;
    background: linear-gradient(to bottom, #245edb, #1941a5) !important;
    display: flex;
    align-items: center;
    z-index: 1000;
}

.start-button {
    background: linear-gradient(to bottom, #4fc44f, #2d9a2d) !important;
    border: 2px outset #4fc44f;
    padding: 6px 20px;
    height: 36px;
    font-family: 'MS Sans Serif', 'Tahoma', sans-serif;
    font-weight: bold;
    font-size: 13px;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 8px;
}

.start-button-logo {
    width: 20px !important;
    height: 20px !important;
    max-width: 20px !important;
    max-height: 20px !important;
    object-fit: contain;
}

.start-button-text {
    color: #fff;
    font-weight: bold;
    text-shadow: 1px 1px 2px rgba(0, 0, 0, 0.4);
}

.start-button:active {
    border: 2px inset #2d9a2d;
    background: linear-gradient(to bottom, #2d9a2d, #1f7a1f);
}

.taskbar-items {
    display: flex;
    gap: 5px;
    margin-left: 10px;
    flex: 1;
}

.taskbar-item {
    background: #c0c0c0;
    border: 2px inset #c0c0c0;
    padding: 5px 15px;
    cursor: pointer;
    font-size: 11px;
    display: flex;
    align-items: center;
}

.taskbar-item:hover {
    background: #d0d0d0;
}

