@import url('https://fonts.googleapis.com/css2?family=Fredoka+One&family=Pacifico&display=swap');

body {
    margin: 0;
    overflow: hidden;
    font-family: 'Fredoka One', cursive;
    background-color: #fce4ec; /* Light pink background */
}
canvas {
    display: block;
}
#crosshair {
    position: absolute;
    top: 50%;
    left: 50%;
    width: 10px;
    height: 10px;
    border: 2px solid rgba(255, 255, 255, 0.7);
    border-radius: 50%;
    transform: translate(-50%, -50%);
    pointer-events: none;
    display: none;
}
#hotbar {
    position: absolute;
    bottom: 20px;
    left: 50%;
    transform: translateX(-50%);
    display: none;
    background: rgba(255, 192, 203, 0.5); /* Semi-transparent pink */
    border-radius: 15px;
    padding: 5px;
    border: 3px solid white;
    box-shadow: 0 0 15px rgba(255, 105, 180, 0.7);
}
.slot {
    width: 50px;
    height: 50px;
    border: 2px solid white;
    margin: 5px;
    cursor: pointer;
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
}
.slot.active {
    transform: scale(1.1);
    border-color: #ff69b4; /* Hot pink */
    box-shadow: 0 0 10px #ff69b4;
}
.slot img {
    width: 80%;
    height: 80%;
    object-fit: contain;
}

#mobile-controls {
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    display: none; /* Hidden by default */
}

#joystick-container {
    position: absolute;
    bottom: 90px;
    left: 30px;
    width: 120px;
    height: 120px;
    background: rgba(255, 255, 255, 0.2);
    border-radius: 50%;
    pointer-events: all;
}

#look-container {
    position: absolute;
    bottom: 90px;
    right: 150px;
    width: 120px;
    height: 120px;
    background: rgba(255, 255, 255, 0.2);
    border-radius: 50%;
    pointer-events: all;
}

#joystick-knob {
    position: absolute;
    width: 60px;
    height: 60px;
    background: rgba(255, 182, 193, 0.8);
    border: 3px solid white;
    border-radius: 50%;
    top: 30px;
    left: 30px;
}

#look-knob {
    position: absolute;
    width: 60px;
    height: 60px;
    background: rgba(255, 182, 193, 0.8);
    border: 3px solid white;
    border-radius: 50%;
    top: 30px;
    left: 30px;
}

#jump-button {
    position: absolute;
    bottom: 90px;
    right: 30px;
    width: 80px;
    height: 80px;
    background: rgba(255, 182, 193, 0.8);
    border: 3px solid white;
    color: white;
    font-size: 24px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    pointer-events: all;
    text-shadow: 2px 2px 4px rgba(0,0,0,0.3);
}

#action-buttons {
    position: absolute;
    bottom: 180px;
    right: 20px;
    display: flex;
    flex-direction: column;
    pointer-events: all;
}

.action-btn {
    width: 60px;
    height: 60px;
    background: rgba(147, 112, 219, 0.7); /* Medium purple */
    border: 3px solid white;
    color: white;
    font-size: 16px;
    font-family: 'Fredoka One', cursive;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 15px;
    text-shadow: 1px 1px 2px rgba(0,0,0,0.5);
}

#info-modal {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    background-color: rgba(255, 232, 240, 0.95);
    border: 5px solid white;
    border-radius: 20px;
    padding: 25px;
    text-align: center;
    color: #d63384;
    box-shadow: 0 10px 30px rgba(0,0,0,0.2);
    width: 80%;
    max-width: 400px;
    z-index: 100;
    display: none;
}
#info-modal h2 {
    font-family: 'Pacifico', cursive;
    font-size: 2.5em;
    margin-top: 0;
    color: #c2185b;
}
#info-modal button {
    background-color: #ff69b4;
    color: white;
    border: none;
    padding: 10px 20px;
    border-radius: 10px;
    font-family: 'Fredoka One', cursive;
    font-size: 1em;
    cursor: pointer;
    margin-top: 15px;
    box-shadow: 0 4px #d63384;
    transition: all 0.1s ease-in-out;
}
#info-modal button:active {
    transform: translateY(2px);
    box-shadow: 0 2px #d63384;
}

#main-menu, #settings-modal {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    background-color: rgba(255, 232, 240, 0.95);
    border: 5px solid white;
    border-radius: 20px;
    padding: 25px;
    text-align: center;
    color: #d63384;
    box-shadow: 0 10px 30px rgba(0,0,0,0.2);
    width: 80%;
    max-width: 400px;
    z-index: 100;
}

#main-menu h1 {
    font-family: 'Pacifico', cursive;
    font-size: 2.5em;
    margin-top: 0;
    color: #c2185b;
}

#main-menu button,
#settings-modal button {
    background-color: #ff69b4;
    color: white;
    border: none;
    padding: 10px 20px;
    border-radius: 10px;
    font-family: 'Fredoka One', cursive;
    font-size: 1em;
    cursor: pointer;
    margin: 10px;
    box-shadow: 0 4px #d63384;
    transition: all 0.1s ease-in-out;
}

#settings-modal {
    display: none;
}

@media (max-width: 768px) {
    #mobile-controls {
        display: block;
    }
}

/* Menu buttons used on index.html and settings page */
.menu-btn {
    display: inline-block;
    background-color: #ff69b4;
    color: white;
    text-decoration: none;
    padding: 10px 20px;
    border-radius: 10px;
    font-family: 'Fredoka One', cursive;
    font-size: 1em;
    margin: 10px;
    box-shadow: 0 4px #d63384;
    transition: all 0.1s ease-in-out;
}
.menu-btn:active {
    transform: translateY(2px);
    box-shadow: 0 2px #d63384;
}

#settings-page {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    background-color: rgba(255, 232, 240, 0.95);
    border: 5px solid white;
    border-radius: 20px;
    padding: 25px;
    text-align: center;
    color: #d63384;
    box-shadow: 0 10px 30px rgba(0,0,0,0.2);
    width: 80%;
    max-width: 400px;
    z-index: 100;
}

#settings-page select,
#settings-page label {
    display: block;
    margin-top: 10px;
}

#settings-page input[type="checkbox"] {
    margin-right: 5px;
}

/* Slider style for movement speed */
#speed-range {
    width: 100%;
    -webkit-appearance: none;
    height: 10px;
    background: #ffd1e7;
    border-radius: 5px;
    outline: none;
    margin-top: 5px;
}
#speed-range::-webkit-slider-thumb {
    -webkit-appearance: none;
    width: 20px;
    height: 20px;
    background: #ff69b4;
    border-radius: 50%;
    border: 2px solid white;
    cursor: pointer;
}
#speed-range::-moz-range-thumb {
    width: 20px;
    height: 20px;
    background: #ff69b4;
    border-radius: 50%;
    border: 2px solid white;
    cursor: pointer;
}

/* Dropdown style for graphics quality */
#quality-select {
    width: 100%;
    padding: 5px 10px;
    border: 2px solid #ff69b4;
    border-radius: 10px;
    background: #fff0f6;
    color: #d63384;
    font-family: 'Fredoka One', cursive;
    margin-top: 5px;
}

/* Checkbox appearance */
#settings-page input[type="checkbox"] {
    accent-color: #ff69b4;
}

/* Visually separate developer setting */
#settings-page label:last-of-type {
    margin-top: 20px;
    padding-top: 15px;
    border-top: 2px dashed #d63384;
}

#seed-modal {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    background-color: rgba(255, 232, 240, 0.95);
    border: 5px solid white;
    border-radius: 20px;
    padding: 25px;
    text-align: center;
    color: #d63384;
    box-shadow: 0 10px 30px rgba(0,0,0,0.2);
    width: 80%;
    max-width: 400px;
    z-index: 100;
}
#seed-modal input {
    width: 80%;
    padding: 5px;
    margin-top: 10px;
    font-family: 'Fredoka One', cursive;
}
#seed-modal button {
    background-color: #ff69b4;
    color: white;
    border: none;
    padding: 10px 20px;
    border-radius: 10px;
    font-family: 'Fredoka One', cursive;
    font-size: 1em;
    cursor: pointer;
    margin-top: 10px;
    box-shadow: 0 4px #d63384;
    transition: all 0.1s ease-in-out;
}
#seed-modal button:active {
    transform: translateY(2px);
    box-shadow: 0 2px #d63384;
}

#dev-panel {
    position: absolute;
    top: 10px;
    left: 10px;
    background: rgba(0,0,0,0.6);
    color: white;
    padding: 5px;
    font-family: monospace;
    font-size: 14px;
    border-radius: 5px;
    display: none;
    z-index: 120;
    pointer-events: all;
    resize: both;
    overflow: auto;
    min-width: 150px;
    min-height: 100px;
}
#dev-panel-header {
    cursor: move;
    user-select: none;
    padding: 2px 5px;
    margin: -5px -5px 5px -5px;
    background: rgba(255,255,255,0.1);
    text-align: center;
    font-weight: bold;
    border-radius: 5px 5px 0 0;
}
#dev-panel label {
    display: block;
    margin-top: 5px;
}

#dev-toggle {
    position: absolute;
    top: 10px;
    right: 10px;
    background: rgba(0,0,0,0.6);
    color: white;
    padding: 5px 10px;
    font-family: monospace;
    font-size: 14px;
    border-radius: 5px;
    display: none;
    z-index: 110;
    pointer-events: all;
}
