:root {
    --primary-color: #388e3c;
    --secondary-color: #66bb6a;
    --accent-color: #81c784;
    --bg-color: #1a1a1a;
    --text-color: #e0e0e0;
    --card-bg: #2d2d2d;
    --pixel-size: 4px;
    --shadow: 4px 4px 0px rgba(0, 0, 0, 0.5);
}

body {
    font-family: 'Press Start 2P', cursive;
    background-color: #000;
    color: var(--text-color);
    margin: 0;
    padding: 0;
    display: flex;
    justify-content: center;
    align-items: center;
    image-rendering: pixelated;
    overflow: hidden;
    width: 100vw;
    height: 100vh;
}

.pixel-border {
    border: var(--pixel-size) solid #000;
    box-shadow: 
        inset -var(--pixel-size) -var(--pixel-size) 0px #111,
        var(--pixel-size) var(--pixel-size) 0px rgba(0,0,0,0.2);
}

.pixel-border-small {
    border: 2px solid #000;
    box-shadow: 2px 2px 0px rgba(0,0,0,0.2);
}

.game-container {
    width: 100%;
    height: 100%;
    background-color: var(--card-bg);
    padding: 0;
    display: flex;
    flex-direction: column;
    position: relative;
    overflow: hidden;
}

header.hud-top {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    padding: 15px 30px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: linear-gradient(to bottom, rgba(0,0,0,0.8), transparent);
    z-index: 1000;
    pointer-events: none;
}

h1 {
    margin: 0;
    color: var(--secondary-color);
    font-size: 1.5rem;
    text-shadow: 3px 3px 0px #000;
}

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

.indicators {
    display: flex;
    gap: 30px;
}

.indicator-item {
    font-family: 'Press Start 2P', cursive;
    font-size: 0.6rem;
    color: #fff;
    text-shadow: 2px 2px #000;
}

.indicator-item span {
    font-weight: bold;
}

/* REALISM ELEMENTS */
.ready-badge {
    position: absolute;
    top: -10px;
    right: -10px;
    background: #ffff00;
    color: #000;
    padding: 2px 5px;
    font-size: 0.4rem;
    animation: pulse 1s infinite;
}

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

/* RAID SCREEN SHAKE */
.shake-screen {
    animation: screenShake 0.1s infinite;
}

@keyframes screenShake {
    0% { transform: translate(2px, 1px) rotate(0deg); }
    10% { transform: translate(-1px, -2px) rotate(-1deg); }
    20% { transform: translate(-3px, 0px) rotate(1deg); }
    30% { transform: translate(0px, 2px) rotate(0deg); }
    40% { transform: translate(1px, -1px) rotate(1deg); }
    50% { transform: translate(-1px, 2px) rotate(-1deg); }
    60% { transform: translate(-3px, 1px) rotate(0deg); }
    70% { transform: translate(2px, 1px) rotate(-1deg); }
    80% { transform: translate(-1px, -1px) rotate(1deg); }
    90% { transform: translate(2px, 2px) rotate(0deg); }
    100% { transform: translate(1px, -2px) rotate(-1deg); }
}

.stat-item {
    font-size: 0.7rem;
    background: #333;
    padding: 10px;
    color: #fff;
}

.action-bar {
    display: flex;
    justify-content: center;
    gap: 20px;
    margin-bottom: 20px;
}

/* TOOLS BAR */
.tools-bar {
    background: #222;
    display: flex;
    justify-content: center;
    padding: 10px;
    gap: 10px;
    border-bottom: 2px solid #333;
}

.tool-btn {
    background: #333;
    border: 2px solid #000;
    color: #4caf50;
    padding: 10px;
    font-family: 'Press Start 2P', cursive;
    font-size: 0.5rem;
    cursor: pointer;
    flex: 1;
}

.tool-btn.active {
    background: #4caf50;
    color: #fff;
    box-shadow: inset 4px 4px 0px #2e7d32;
}

.btn {
    padding: 15px;
    font-family: 'Press Start 2P', cursive;
    font-size: 0.6rem;
    cursor: pointer;
    border: 3px solid #000;
    background-color: var(--primary-color);
    color: white;
    box-shadow: inset -4px -4px 0px #2e7d32;
}

.btn:hover {
    background-color: var(--secondary-color);
    transform: translate(2px, 2px);
    box-shadow: inset -2px -2px 0px #2e7d32;
}

.btn.secondary {
    background-color: #795548;
    box-shadow: inset -4px -4px 0px #5d4037;
}

.btn.small {
    padding: 8px;
    font-size: 0.5rem;
}

.station-nav {
    display: flex;
    justify-content: center;
    gap: 10px;
    margin-bottom: 20px;
    background: #111;
    padding: 10px;
    border: 4px solid #333;
}

.nav-tab {
    background: #222;
    border: 2px solid #444;
    color: #4caf50;
    padding: 10px 15px;
    font-family: 'Press Start 2P', cursive;
    font-size: 0.6rem;
    cursor: pointer;
    transition: all 0.3s;
}

.nav-tab:hover {
    background: #333;
    border-color: #ff00ff;
}

.nav-tab.active {
    background: #ff00ff;
    color: #fff;
    border-color: #ffff00;
    box-shadow: 0 0 15px rgba(255,0,255,0.5);
}

.farm-field {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 20px;
    padding: 25px;
    background-color: #2b1b17;
    border: var(--pixel-size) solid #1a0f0d;
}

.pot-slot {
    min-height: 180px;
    background: rgba(0,0,0,0.3);
    border: 2px dashed #444;
    display: flex;
    justify-content: center;
    align-items: center;
    position: relative;
    transition: all 0.3s;
}

.pot-slot.locked {
    background: rgba(0,0,0,0.8);
    border: 2px solid #222;
    cursor: not-allowed;
    filter: grayscale(1);
}

.lock-icon {
    font-size: 2rem;
    opacity: 0.3;
}

.plant-container {
    width: 100%;
    height: 100%;
    display: flex;
    flex-direction: column;
    align-items: center;
    background: none;
    padding: 10px;
    border: none;
    cursor: pointer;
    position: relative;
}

.plant-visual {
    position: relative;
    height: 100px;
    width: 100%;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: flex-end;
}

/* PLANT VISUAL CONTAINER */
.plant-visual {
    position: relative;
    height: 120px;
    width: 100%;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: flex-end;
}

/* DRAGGABLE ITEMS */
[draggable="true"] {
    cursor: grab;
}

[draggable="true"]:active {
    cursor: grabbing;
}

/* ORGANIC PIXEL LEAVES */
.leaf {
    position: absolute;
    background: #4caf50;
    border: 3px solid #000;
    image-rendering: pixelated;
    filter: drop-shadow(4px 4px 0 #1b5e20);
}

.leaf.left {
    left: 10%;
    transform: rotate(-35deg);
}

.leaf.right {
    right: 10%;
    transform: rotate(35deg);
}

.stage-1 .leaf { width: 8px; height: 12px; bottom: 30px; }
.stage-2 .leaf { width: 18px; height: 28px; bottom: 40px; }
.stage-3 .leaf { width: 26px; height: 42px; bottom: 50px; }
.stage-4 .leaf { 
    width: 32px; 
    height: 60px; 
    bottom: 60px; 
    background: #2e7d32;
    border-radius: 4px; /* Slightly rounded edges for pixel art feel */
}

.plant-emoji {
    font-size: 2rem;
    z-index: 5;
    margin-bottom: -5px;
}

/* REPLACING EMOJIS WITH CSS ART IN JS */

.plant-emoji.shake {
    animation: shake 0.5s;
}

@keyframes shake {
    0%, 100% { transform: rotate(0deg); }
    25% { transform: rotate(10deg); }
    75% { transform: rotate(-10deg); }
}

/* TRAP STAR V8 OVERHAUL */
.pink { 
    color: #ff00ff; 
    text-shadow: 0 0 10px #ff00ff; 
    font-size: 3rem;
}

#loading-actions {
    position: relative;
    z-index: 100;
    margin-top: 40px;
}

#loading-actions button {
    animation: pulseButton 2s infinite;
}

@keyframes pulseButton {
    0% { transform: scale(1); box-shadow: 0 0 0px #ff00ff; }
    50% { transform: scale(1.05); box-shadow: 0 0 20px #ff00ff; }
    100% { transform: scale(1); box-shadow: 0 0 0px #ff00ff; }
}

/* NEW PHONE APPS STYLING */
.crypto-card {
    background: rgba(0,0,0,0.6);
    padding: 15px;
    margin: 10px;
    border: 2px solid #ffff00;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 10px;
}

.crypto-graph {
    display: flex;
    align-items: flex-end;
    gap: 2px;
    height: 40px;
    background: rgba(0,0,0,0.5);
    margin: 10px 0;
    padding: 5px;
    border-bottom: 1px solid #4caf50;
}

.graph-bar {
    flex: 1;
    background: #ff00ff;
    min-width: 4px;
}

.crypto-btns {
    display: flex;
    gap: 10px;
    width: 100%;
}

.crypto-btns button {
    flex: 1;
}

.strain-selector-container {
    margin-left: 20px;
    display: flex;
    align-items: center;
}

#strain-select {
    background: #222;
    color: #4caf50;
    font-family: 'Press Start 2P', cursive;
    font-size: 0.5rem;
    padding: 5px;
    outline: none;
}

.bank-entry {
    font-size: 0.4rem;
    padding: 8px;
    border-bottom: 1px solid #333;
    display: flex;
    justify-content: space-between;
}

.bank-entry.positive { color: #0f0; }
.bank-entry.negative { color: #f00; }

.stat-row {
    font-size: 0.5rem;
    padding: 10px;
    background: rgba(0,0,0,0.4);
    margin-bottom: 5px;
}

.news-item {
    font-size: 0.4rem;
    padding: 10px;
    background: #111;
    border-left: 4px solid #ff00ff;
    margin-bottom: 10px;
    line-height: 1.4;
}

/* BETTER SCROLLBARS FOR ALL CONTAINERS */
.phone-screen::-webkit-scrollbar,
.inventory-grid::-webkit-scrollbar,
#orders-list::-webkit-scrollbar,
#upgrade-list::-webkit-scrollbar {
    width: 4px;
}

.phone-screen::-webkit-scrollbar-thumb,
.inventory-grid::-webkit-scrollbar-thumb,
#orders-list::-webkit-scrollbar-thumb,
#upgrade-list::-webkit-scrollbar-thumb {
    background: #ff00ff;
}
.yellow-star { 
    color: #ffff00; 
    font-size: 3.5rem;
    display: inline-block;
    animation: starPulse 1s infinite alternate; 
}

@keyframes starPulse {
    from { transform: scale(1); filter: drop-shadow(0 0 5px #ffff00); }
    to { transform: scale(1.3); filter: drop-shadow(0 0-25px #ffff00); }
}

.spinning-assets {
    position: absolute;
    width: 100%;
    height: 100%;
    pointer-events: none;
    overflow: hidden;
}

@keyframes assetSpin {
    from { transform: rotate(0deg) translate(150px) rotate(0deg); }
    to { transform: rotate(360deg) translate(150px) rotate(-360deg); }
}

.spin-item {
    position: absolute;
    top: 50%;
    left: 50%;
    margin-top: -30px;
    margin-left: -30px;
    width: 60px;
    height: 60px;
    background-size: contain;
    animation: assetSpin 8s infinite linear;
    image-rendering: pixelated;
    filter: drop-shadow(0 0 10px rgba(255,0,255,0.5));
}

.pill { 
    background: #ff00ff;
    width: 20px; height: 10px;
    border-radius: 10px;
    border: 2px solid #000;
}
.syringe { 
    background: #ccc;
    width: 5px; height: 40px;
    border: 2px solid #000;
}
.drum-mag { 
    background: #333;
    width: 30px; height: 30px;
    border-radius: 50%;
    border: 2px solid #000;
}

.spin-item:nth-child(2) { animation-delay: -1s; }
.spin-item:nth-child(3) { animation-delay: -2s; }
.spin-item:nth-child(4) { animation-delay: -3s; }
.spin-item:nth-child(5) { animation-delay: -4s; }
.spin-item:nth-child(6) { animation-delay: -5s; }
.spin-item:nth-child(7) { animation-delay: -6s; }
.spin-item:nth-child(8) { animation-delay: -7s; }

/* DYNAMIC LOADING BACKGROUND */
#loading-screen {
    background: radial-gradient(circle at center, #1a1a1a 0%, #000 100%);
    overflow: hidden;
}

#loading-screen::after {
    content: '';
    position: absolute;
    width: 200%; height: 200%;
    background: url('https://www.transparenttextures.com/patterns/asfalt-dark.png');
    opacity: 0.1;
    animation: moveBg 20s linear infinite;
}

@keyframes moveBg {
    from { transform: translate(-25%, -25%); }
    to { transform: translate(0, 0); }
}

/* PIXEL ART ASSETS */
.balaclava { 
    background: #111;
    clip-path: polygon(20% 0%, 80% 0%, 90% 20%, 90% 80%, 80% 100%, 20% 100%, 10% 80%, 10% 20%);
    box-shadow: inset 15px 25px 0 -10px #fff, inset -15px 25px 0 -10px #fff; /* Eye holes */
}
.glock { 
    background: #333;
    clip-path: polygon(0% 0%, 80% 0%, 80% 30%, 30% 30%, 30% 100%, 0% 100%);
}
.glock::after {
    content: '';
    position: absolute;
    bottom: -10px; left: 5px;
    width: 15px; height: 30px;
    background: #222; /* Extended mag */
}
.flower { 
    background: #4caf50;
    clip-path: polygon(50% 0%, 100% 50%, 50% 100%, 0% 50%);
    box-shadow: inset 0 0 10px #2e7d32;
}
.phone-icon { 
    background: #222;
    border: 2px solid #555;
    border-radius: 5px;
}
.glove { 
    background: #000;
    clip-path: polygon(10% 0%, 90% 0%, 100% 40%, 80% 100%, 20% 100%, 0% 40%);
}

/* PHONE OVERLAY (FIRST PERSON) */
.phone-overlay {
    position: fixed;
    bottom: -100%;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 2000;
    transition: bottom 0.6s cubic-bezier(0.34, 1.56, 0.64, 1);
    display: flex;
    justify-content: center;
    align-items: flex-end;
    pointer-events: none;
    background: radial-gradient(circle at bottom, rgba(0,255,0,0.1) 0%, transparent 50%); /* Phone light emission on user */
}

.phone-overlay.show {
    bottom: 0;
    pointer-events: all;
}

.phone-hand-container {
    position: relative;
    z-index: 5;
    transform: translateY(-80px); /* Lifted up further */
}

.hoodie-arms {
    position: absolute;
    bottom: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: 1;
}

.arm {
    position: absolute;
    bottom: -100px;
    width: 250px;
    height: 500px;
    background: #0a0a0a;
    border: 8px solid #000;
    box-shadow: inset 0 0 50px rgba(0,0,0,0.8);
}

.left-arm { 
    left: 10%; 
    transform: rotate(25deg);
    border-radius: 100px 100px 0 0;
}
.right-arm { 
    right: 10%; 
    transform: rotate(-25deg);
    border-radius: 100px 100px 0 0;
}

/* GLOVES ON ARMS */
.arm::after {
    content: '';
    position: absolute;
    top: 0; left: 0;
    width: 100%; height: 100px;
    background: #111;
    border-bottom: 5px solid #000;
}

.phone-glow {
    position: absolute;
    top: 50%; left: 50%;
    width: 400px; height: 600px;
    background: radial-gradient(circle, rgba(0,255,0,0.3) 0%, transparent 70%);
    transform: translate(-50%, -50%);
    pointer-events: none;
    mix-blend-mode: screen;
    animation: flicker 0.2s infinite alternate;
}

/* ZOOMABLE STATIONS */
.world-slider {
    position: relative;
    width: 100%;
    height: 100vh;
    margin-top: 0;
}

.world-slider.sliding {
    filter: blur(2px) contrast(1.2);
    transition: filter 0.3s;
}

.rooms-container {
    display: flex;
    width: 700%; /* 7 Rooms: Grow, Dry, Roll, Pack, Kitchen, Inv, Help */
    height: 100%;
    transition: transform 1.2s cubic-bezier(0.7, 0, 0.3, 1);
}

.room {
    width: 14.2857%;
    height: 100%;
    display: flex;
    justify-content: center;
    align-items: center;
    position: relative;
    background: #050505;
    overflow: hidden;
}

/* GRITTY OVERLAY */
.room::before {
    content: '';
    position: absolute;
    top: 0; left: 0; width: 100%; height: 100%;
    background-image: 
        radial-gradient(circle at 50% 50%, transparent 50%, rgba(0,0,0,0.5) 100%),
        url('https://www.transparenttextures.com/patterns/asfalt-dark.png');
    pointer-events: none;
    z-index: 5;
    opacity: 0.3;
}

.room-content {
    width: 100%;
    height: 100%;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    position: relative;
}

/* METAL TABLE ENHANCEMENT */
.metal-table {
    width: 95%;
    height: 80%;
    background: #1a1a1a;
    border: 10px solid #000;
    position: relative;
    box-shadow: 
        inset 0 0 100px #000,
        0 50px 0 #000;
    background-image: repeating-linear-gradient(45deg, transparent, transparent 10px, rgba(255,255,255,0.02) 10px, rgba(255,255,255,0.02) 20px);
}

.far-view {
    transform: scale(0.75);
    filter: brightness(0.3) blur(1px);
}

.room.zoomed {
    transform: scale(1);
    filter: brightness(1) blur(0);
}

/* PACK AREA STYLING */
.pack-area-station {
    width: 100%;
    height: 100%;
    display: flex;
    justify-content: center;
    align-items: center;
}

.metal-table {
    width: 90%;
    height: 350px;
    background: linear-gradient(to bottom, #444, #222);
    border: 8px solid #111;
    position: relative;
    box-shadow: 0 30px 0 #000;
}

.swinging-light {
    position: absolute;
    top: -150px;
    left: 50%;
    width: 6px;
    height: 180px;
    background: #111;
    transform-origin: top center;
    animation: lightSway 5s infinite ease-in-out;
    z-index: 10;
}

.swinging-light::after {
    content: '';
    position: absolute;
    bottom: -30px;
    left: -25px;
    width: 56px;
    height: 30px;
    background: #ffd54f;
    clip-path: polygon(20% 0%, 80% 0%, 100% 100%, 0% 100%);
    box-shadow: 0 0 100px rgba(255,213,79,0.8);
    animation: flicker 0.05s infinite alternate;
}

@keyframes lightSway {
    0%, 100% { transform: rotate(-8deg); }
    50% { transform: rotate(8deg); }
}

@keyframes flicker {
    from { opacity: 0.8; }
    to { opacity: 1; }
}

.bin-label {
    position: absolute;
    top: 20px;
    font-size: 0.8rem;
    color: #4caf50;
    text-shadow: 2px 2px 0 #000;
    padding: 10px;
    background: rgba(0,0,0,0.5);
    border: 2px solid #000;
}

.bin-left { left: 40px; }
.bin-right { right: 40px; }

/* LEAF PHYSICS STYLING */
.pixel-leaf {
    width: 30px;
    height: 40px;
    background: #4caf50;
    border: 2px solid #000;
    position: absolute;
    cursor: grab;
    z-index: 10;
    box-shadow: 
        inset -4px -4px 0 rgba(0,0,0,0.3),
        inset 4px 4px 0 rgba(255,255,255,0.1);
}

.pixel-leaf::after {
    content: '';
    position: absolute;
    top: 50%; left: 10%; width: 80%; height: 2px;
    background: rgba(0,0,0,0.2);
}

/* SCALE ENHANCEMENT */
.scale-station {
    position: absolute;
    bottom: 100px;
    left: 50%;
    transform: translateX(-50%);
    z-index: 20;
}

.digital-scale {
    width: 300px;
    height: 100px;
    background: #222;
    border: 8px solid #000;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    box-shadow: 
        inset 0 0 40px #000,
        0 20px 0 #111;
}

.scale-screen {
    background: #001a00;
    color: #0f0;
    font-family: 'Courier New', monospace;
    font-size: 2.5rem;
    padding: 10px 30px;
    border: 5px solid #111;
    min-width: 200px;
    text-shadow: 0 0 15px #0f0;
    letter-spacing: 5px;
}

.pixel-leaf:active { cursor: grabbing; }

/* MODAL / CUT UI */
.modal {
    position: fixed;
    top: 0; left: 0; width: 100%; height: 100%;
    background: rgba(0,0,0,0.9);
    z-index: 3000;
    display: flex;
    justify-content: center;
    align-items: center;
    backdrop-filter: blur(5px);
}

.modal-content {
    background: #111;
    padding: 40px;
    text-align: center;
    border: 8px solid #ff00ff;
    box-shadow: 0 0 50px rgba(255,0,255,0.3);
}

.cut-options {
    display: flex;
    gap: 15px;
    margin: 25px 0;
}

/* HUD ST★R LOGIC */
.trap-star-hud {
    font-size: 1.2rem;
    color: #ff00ff;
}

.star-logo {
    color: #ffff00;
    display: inline-block;
    animation: starPulse 1s infinite alternate;
}

/* KITCHEN STATION */
.ovens-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 20px;
    padding: 20px;
    width: 90%;
}

/* DRY STATION */
.dry-station {
    width: 80%;
    background: #1a1a1a;
    padding: 30px;
    text-align: center;
}

.dry-info {
    display: flex;
    justify-content: center;
    gap: 30px;
    margin-bottom: 20px;
    font-size: 0.6rem;
}

.drying-rack {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 15px;
}

.dry-slot {
    height: 120px;
    background: #222;
    border: 2px dashed #444;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    position: relative;
}

.dry-slot.locked {
    background: #000;
    opacity: 0.5;
}

.hanging-bud {
    width: 20px;
    height: 40px;
    background: #2e7d32;
    clip-path: polygon(50% 0%, 100% 100%, 0% 100%);
    margin-bottom: 10px;
    animation: sway 2s infinite ease-in-out;
}

@keyframes sway {
    0%, 100% { transform: rotate(-5deg); }
    50% { transform: rotate(5deg); }
}

.oven-slot {
    height: 200px;
    background: #333;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
    padding: 15px;
}

.oven-slot.locked {
    background: rgba(0,0,0,0.8);
    filter: grayscale(1);
    opacity: 0.5;
}

.ingredient-crafting {
    margin-top: 30px;
    background: #111;
    padding: 20px;
    display: flex;
    flex-direction: column;
    gap: 10px;
}

/* ORDERS */
.fill-order {
    border-color: #ff00ff !important;
    background: rgba(255,0,255,0.1);
}

.quick-order {
    border-color: #4caf50 !important;
}

.order-tag {
    font-size: 0.5rem;
    padding: 2px 5px;
    background: #000;
    display: inline-block;
    margin-bottom: 5px;
}

.fill-order .order-tag { color: #ff00ff; }
.quick-order .order-tag { color: #4caf50; }

/* INVENTORY STATION */
.inventory-grid {
    width: 400px;
    max-height: 500px;
    background: #222;
    padding: 20px;
    display: flex;
    flex-direction: column;
    gap: 10px;
    overflow-y: auto;
}

.inv-item {
    display: flex;
    justify-content: space-between;
    padding: 10px;
    background: #111;
    color: #4caf50;
    font-size: 0.7rem;
}

/* HELP STATION */
.help-panel {
    width: 400px;
    background: #111;
    padding: 30px;
    text-align: center;
}

.help-panel h2 {
    color: #ff00ff;
    margin-bottom: 20px;
}

.help-panel p {
    font-size: 0.6rem;
    margin-top: 20px;
    color: #888;
}

/* REMOVING OLD STYLES THAT ARE SUPERSEDED */

.hidden {
    display: none !important;
}

.overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: #000;
    z-index: 1000;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    transition: opacity 0.5s ease;
}

.hanging-light {
    width: 80px;
    height: 10px;
    background: #ffd54f; /* Yellow shade from image */
    position: absolute;
    top: 0;
    left: 50%;
    transform: translateX(-50%);
    border: 2px solid #000;
    box-shadow: 
        0 4px 0 #ffd54f, 
        0 8px 0 #ffd54f,
        -4px 0 0 #000, 4px 0 0 #000;
    transform-origin: top center;
    animation: sway 6s infinite ease-in-out;
}

.hanging-light::before {
    content: '';
    position: absolute;
    top: -40px;
    left: 50%;
    width: 4px;
    height: 40px;
    background: #333;
    transform: translateX(-50%);
}

.hanging-light::after {
    content: '419';
    position: absolute;
    bottom: -60px;
    left: 50%;
    transform: translateX(-50%);
    color: #ffd54f;
    font-size: 1.5rem;
    font-family: 'Press Start 2P', cursive;
    text-shadow: 0 0 20px #ffd54f;
    opacity: 0.8;
    animation: flickerLight 3s infinite alternate;
}

@keyframes sway {
    0%, 100% { transform: translateX(-50%) rotate(-3deg); }
    50% { transform: translateX(-50%) rotate(3deg); }
}

@keyframes flickerLight {
    0%, 100% { opacity: 0.8; text-shadow: 0 0 30px #ffd54f; }
    15% { opacity: 0.2; text-shadow: 0 0 5px #ffd54f; }
    18% { opacity: 0.9; text-shadow: 0 0 50px #ffd54f; }
    22% { opacity: 0.4; text-shadow: 0 0 15px #ffd54f; }
    50% { opacity: 0.7; text-shadow: 0 0 25px #ffd54f; }
}

/* BEAT SYNCED SHAKE */
.beat-shake {
    animation: beatShake 0.15s cubic-bezier(.36,.07,.19,.97) both;
}

@keyframes beatShake {
    0% { transform: scale(1); }
    50% { transform: scale(1.015) rotate(0.2deg); }
    100% { transform: scale(1); }
}

/* GLOBAL SHAKE EFFECT (PUNCHIER) */
.shake-screen {
    animation: screenShake 0.1s infinite;
}

@keyframes screenShake {
    0% { transform: translate(1px, 1px); }
    25% { transform: translate(-1px, -1px); }
    50% { transform: translate(-1px, 1px); }
    75% { transform: translate(1px, -1px); }
    100% { transform: translate(0, 0); }
}

.loading-title {
    margin-bottom: 30px;
    z-index: 10;
}

.loading-text {
    margin-top: 20px;
    font-size: 0.8rem;
    color: #4caf50;
    animation: blinkText 1.5s infinite;
}

@keyframes blinkText {
    0%, 100% { opacity: 1; }
    50% { opacity: 0; }
}

/* MAIN MENU */
.menu-content {
    background: #1a1a1a;
    padding: 50px;
    text-align: center;
}

.menu-buttons {
    display: flex;
    flex-direction: column;
    gap: 20px;
    margin-top: 30px;
}

.btn.large {
    padding: 20px 40px;
    font-size: 1rem;
}

/* SETTINGS */
.settings-options {
    display: flex;
    flex-direction: column;
    gap: 20px;
    margin: 30px 0;
}

.volume-control {
    display: flex;
    align-items: center;
    gap: 15px;
    font-size: 0.6rem;
}

/* TRAP HOUSE ENVIRONMENT */
.room-view {
    background: #0a0a0a;
    border: 10px solid #222;
    padding: 40px;
    box-shadow: 
        inset 0 0 200px #000,
        0 20px 0 #000;
    position: relative;
    overflow: hidden;
    background-image: 
        linear-gradient(45deg, #0d0d0d 25%, transparent 25%),
        linear-gradient(-45deg, #0d0d0d 25%, transparent 25%),
        linear-gradient(45deg, transparent 75%, #0d0d0d 75%),
        linear-gradient(-45deg, transparent 75%, #0d0d0d 75%);
    background-size: 20px 20px;
}

/* DIGITAL SCALE STATION */
.grow-tent {
    background: #0d0d0d;
    border: 12px solid #222;
    border-radius: 4px;
    position: relative;
    overflow: hidden;
    box-shadow: 0 0 20px rgba(76,175,80,0.2);
}

/* RED CUP PIXEL ART */
.pot {
    width: 50px;
    height: 70px;
    background: #ff0000; /* Bright red */
    position: relative;
    margin: 0 auto;
    border: 4px solid #000;
    clip-path: polygon(5% 0%, 95% 0%, 85% 100%, 15% 100%);
    box-shadow: 
        inset -8px 0 0 rgba(0,0,0,0.2),
        inset 8px 0 0 rgba(255,255,255,0.1);
}

.pot::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 12px;
    background: #ff4d4d;
    border-bottom: 4px solid #000;
}

.pot::after {
    content: '';
    position: absolute;
    top: 20px;
    left: 15%;
    width: 6px;
    height: 30px;
    background: rgba(255,255,255,0.4); /* Sharp white highlight */
}

.pack-area {
    background: #1a1a1a;
    border: 8px solid #333;
    padding: 40px;
    box-shadow: 
        0 10px 0 #000,
        inset 0 0 50px #000;
}

.scale-display {
    background: #000;
    color: #00ff00;
    padding: 40px;
    font-family: 'Press Start 2P', cursive;
    font-size: 1.8rem;
    border: 10px solid #444;
    box-shadow: 
        inset 0 0 30px #000,
        0 4px 0 #222;
    text-shadow: 0 0 20px rgba(0,255,0,0.8);
    letter-spacing: 4px;
}

/* DRYING RACK ART */
.drying-rack {
    background: #2a1b17;
    border: 4px solid #1a0f0d;
    padding: 30px;
}

.dry-slot {
    background: #1a0f0d;
    border: 3px solid #000;
    box-shadow: inset 0 0 20px #000;
}


/* DRYING RACK */
.drying-rack {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 15px;
    background: #333;
    padding: 20px;
    min-height: 150px;
}

.dry-slot {
    background: #222;
    border: 2px dashed #555;
    height: 150px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    position: relative;
    transition: all 0.3s;
}

.dry-slot.locked {
    background: rgba(0,0,0,0.8);
    border: 2px solid #222;
    filter: grayscale(1);
    cursor: not-allowed;
}

/* PIXEL NUG ART */
.hanging-bud, .nug-icon {
    width: 20px;
    height: 25px;
    background: #4caf50;
    border: 2px solid #000;
    position: relative;
    border-radius: 4px;
    box-shadow: 
        3px 3px 0 #2e7d32,
        -2px 2px 0 #81c784;
    animation: sway 3s infinite ease-in-out;
}

.hanging-bud::after {
    content: '';
    position: absolute;
    top: -5px;
    left: 50%;
    width: 2px;
    height: 6px;
    background: #333;
}

@keyframes sway {
    0%, 100% { transform: rotate(-5deg); }
    50% { transform: rotate(5deg); }
}

/* PACK AREA */
.pack-area {
    background: #333;
    padding: 30px;
    text-align: center;
}

.scale-display {
    background: #000;
    color: #0f0;
    padding: 20px;
    font-size: 1.2rem;
    margin-bottom: 20px;
    border: 4px solid #444;
}

.pack-controls {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.inventory {
    background: #111;
    padding: 15px;
    margin-top: 30px;
    border: 2px solid #4caf50;
}

.progress-bar-container {
    width: 80%;
    height: 12px;
    background: #000;
    border: 2px solid #555;
    margin-top: 5px;
}

.progress-bar {
    height: 100%;
    background: #4caf50;
    width: 0%;
}

.harvest-indicator {
    position: absolute;
    top: 5px;
    left: 50%;
    transform: translateX(-50%);
    background: #ffd54f;
    color: #000;
    padding: 4px;
    font-size: 0.5rem;
    border: 2px solid #000;
    white-space: nowrap;
    display: none;
    z-index: 10;
}

.plant-container.ready .harvest-indicator {
    display: block;
    animation: bounce 0.5s infinite alternate;
}

@keyframes bounce {
    from { transform: translateX(-50%) translateY(0); }
    to { transform: translateX(-50%) translateY(-5px); }
}

.plant-container.ready {
    border-color: #ffd54f;
}

.game-layout {
    display: grid;
    grid-template-columns: 1fr 280px;
    gap: 30px;
}

/* PHONE AESTHETICS OVERHAUL */
.phone-container {
    width: 280px;
    height: 560px;
    background: #111;
    border: 8px solid #222;
    border-radius: 40px;
    position: relative;
    box-shadow: 0 0 50px rgba(0,0,0,0.9);
    overflow: hidden;
}

.phone-screen {
    position: relative;
    width: 100%;
    height: 100%;
    background: #000 url('https://w0.peakpx.com/wallpaper/403/126/HD-wallpaper-trap-house-graffiti-dark-aesthetic.jpg') no-repeat center;
    background-size: cover;
    display: flex;
    flex-direction: column;
    overflow-y: auto;
    overflow-x: hidden;
}

.phone-header {
    background: rgba(0,0,0,0.8);
    color: #4caf50;
    font-size: 0.5rem;
    padding: 15px 10px 5px;
    text-align: center;
    position: sticky;
    top: 0;
    z-index: 10;
    border-bottom: 1px solid #333;
}

.phone-apps {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 20px;
    padding: 30px 20px;
    margin-top: 0;
}

.app-btn {
    background: rgba(20,20,20,0.8);
    border: 2px solid #333;
    color: white;
    padding: 10px 5px;
    border-radius: 12px;
    font-family: 'Press Start 2P', cursive;
    font-size: 0.35rem;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
    transition: all 0.2s;
    position: relative;
}

.app-btn span.badge {
    position: absolute;
    top: -5px;
    right: -5px;
    background: #ff0000;
    color: white;
    font-size: 0.3rem;
    padding: 2px 5px;
    border-radius: 50%;
    border: 1px solid white;
    display: none;
}

.app-btn span.badge.show {
    display: block;
}

.app-btn:hover {
    background: rgba(255,0,255,0.2);
    border-color: #ff00ff;
    transform: translateY(-5px);
}

.app-btn span.app-icon {
    font-size: 1.2rem;
}

.phone-app {
    padding: 0; /* Removed padding to let sticky button span full width */
    background: rgba(0,0,0,0.95);
    min-height: 100%;
    position: relative;
}

.phone-app h4 {
    color: #ff00ff;
    font-size: 0.7rem;
    margin: 10px 20px 20px;
    text-align: center;
    border-bottom: 2px solid #ff00ff;
    padding-bottom: 10px;
}

.app-content-wrapper {
    padding: 0 20px 20px;
}

.phone-back-btn {
    position: sticky;
    top: 0;
    left: 0;
    background: rgba(0,0,0,0.8);
    border: none;
    color: #ff00ff;
    font-size: 1rem;
    padding: 10px 15px;
    cursor: pointer;
    z-index: 100;
    width: 100%;
    text-align: left;
    border-bottom: 1px solid #333;
    margin-bottom: 10px;
}

.phone-back-btn:hover {
    color: #ffff00;
}

/* APP SPECIFIC STYLES */
.bank-balance-card {
    background: linear-gradient(135deg, #111 0%, #222 100%);
    border: 2px solid #4caf50;
    padding: 20px;
    border-radius: 15px;
    margin-bottom: 20px;
    text-align: center;
}

.bank-balance-card h2 {
    color: #4caf50;
    font-size: 1rem;
    margin: 10px 0;
}

.app-section-title {
    font-size: 0.5rem;
    color: #888;
    margin: 15px 0 10px;
    text-transform: uppercase;
}

.detailed-app-list {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.item-row {
    background: #111;
    border: 1px solid #333;
    padding: 12px;
    border-radius: 8px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 0.45rem;
}

.item-row .price {\ color: #4caf50; }

.crypto-card {
    background: #111;
    border: 2px solid #ffff00;
    border-radius: 15px;
    padding: 20px;
    margin-bottom: 15px;
}

.news-item {
    border-left: 4px solid #ff00ff;
    background: #111;
    padding: 12px;
    margin-bottom: 15px;
    border-radius: 0 8px 8px 0;
    font-size: 0.45rem;
}

.order-item {
    margin-bottom: 15px;
}

.phone-home-btn {
    width: 40px;
    height: 40px;
    background: #333;
    border: 2px solid #444;
    border-radius: 50%;
    position: sticky;
    bottom: 10px;
    left: 50%;
    transform: translateX(-50%);
    cursor: pointer;
    z-index: 20;
    margin-top: 10px;
    margin-bottom: 10px;
}

.phone-home-btn:hover {
    background: #444;
    border-color: #555;
}

/* CUSTOM SCROLLBARS FOR PHONE */
.phone-screen::-webkit-scrollbar {
    width: 0;
}

.phone-app::-webkit-scrollbar {
    width: 4px;
}

.phone-app::-webkit-scrollbar-thumb {
    background: #ff00ff;
    border-radius: 10px;
}

.phone-home-btn {
    position: absolute;
    bottom: 15px;
    left: 50%;
    transform: translateX(-50%);
    width: 45px;
    height: 45px;
    background: #222;
    border: 4px solid #333;
    border-radius: 50%;
    cursor: pointer;
    box-shadow: inset 0 0 10px #000;
}

/* CSS Pixel Art Pots */
.pot {
    width: 60px;
    height: 40px;
    background: #8d6e63;
    position: relative;
    margin: 0 auto;
    box-shadow: 
        inset -4px -4px 0px #5d4037,
        4px 0px 0px #000,
        -4px 0px 0px #000,
        0px 4px 0px #000;
}

.pot::before {
    content: '';
    position: absolute;
    top: -4px;
    left: -4px;
    width: 68px;
    height: 8px;
    background: #a1887f;
    border: 2px solid #000;
}

/* Growth Indicators */
.plant-needs {
    display: flex;
    flex-direction: column;
    gap: 5px;
    margin-top: 10px;
    width: 100%;
}

.need-bar-container {
    height: 6px;
    background: #000;
    border: 1px solid #444;
}

.need-bar {
    height: 100%;
}

.need-bar.water { background: #2196f3; }
.need-bar.nutrients { background: #ffeb3b; }

.inventory {
    background: #333;
    padding: 15px;
    margin-top: 20px;
}

.inventory h3 {
    font-size: 0.8rem;
    margin: 0 0 10px 0;
}

.inventory-items {
    font-size: 0.6rem;
    display: flex;
    gap: 20px;
}

.order-item {
    background: #222;
    padding: 8px;
    border: 2px solid #000;
    font-size: 0.5rem;
    margin-bottom: 8px;
    animation: pulse 1s infinite alternate;
}

.badge {
    background: #f44336;
    color: white;
    padding: 2px 6px;
    border-radius: 50%;
    font-size: 0.4rem;
    margin-left: 5px;
    display: none;
}

.badge.show {
    display: inline-block;
}

@keyframes pulse {
    from { border-color: #000; }
    to { border-color: #4caf50; }
}

.floating-text {
    position: absolute;
    top: 20%;
    left: 50%;
    transform: translateX(-50%);
    color: #4caf50;
    font-size: 0.8rem;
    font-weight: bold;
    animation: floatUp 1s forwards;
    pointer-events: none;
    z-index: 100;
}

@keyframes rainbowCycle {
    0% { background: radial-gradient(circle, red 0%, transparent 70%); }
    20% { background: radial-gradient(circle, orange 0%, transparent 70%); }
    40% { background: radial-gradient(circle, yellow 0%, transparent 70%); }
    60% { background: radial-gradient(circle, green 0%, transparent 70%); }
    80% { background: radial-gradient(circle, blue 0%, transparent 70%); }
    100% { background: radial-gradient(circle, violet 0%, transparent 70%); }
}

.upgrade-item {
    background: #222;
    border: 2px solid #333;
    padding: 10px;
    margin-bottom: 10px;
    font-size: 0.45rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
}
