﻿@font-face {
   font-family: 'SMB';
   src: local('Super Mario Bros.'),
        url('fonts/Super Mario Bros.ttf') format('truetype');
   font-style: normal;
}

/* Base styles */
* {
    box-sizing: border-box;
}

html, body {
    margin: 0;
    padding: 0;
    width: 100%;
    height: 100%;
    overflow: hidden;
    background: #5C94FC;
}

#game {
	height: 100vh; 
	width: 100vw; 
	position: absolute;  
	border: 1px solid #ccc; 
	overflow: hidden;
	background: #5C94FC;
}

#world { 
	margin: 0; padding: 0; height: 100%; width: 100%; position: absolute;
	bottom: 0; left: 0; z-index: 0;
}

.gauge {
	margin: 0; padding: 0; height: 50px; width: 70px; text-align: right; font-size: 2em;
	font-weight: bold; position: absolute; top: 17px; right: 52px; z-index: 1000;
	position: absolute; font-family: 'SMB';
}

.gaugeSprite {
	margin: 0; padding: 0; z-index: 1000; position: absolute;
}

#coinNumber {
	left: 0;
}

#liveNumber {
	right: 52px;
}

#coin {
	height: 32px; width: 32px; background-image : url(mario-objects.png);
	background-position: 0 0; top: 15px; left: 70px;
}

#live {
	height: 40px; width: 40px; background-image : url(mario-sprites.png);
	background-position : 0 -430px; top: 12px; right: 8px;
}

.figure {
	margin: 0; padding: 0; z-index: 99; position: absolute;
}

.matter {
	margin: 0; padding: 0; z-index: 95; position: absolute; width: 32px; height: 32px;
}

/* Mobile responsive styles */
@media screen and (max-width: 768px) {
    .gauge {
        font-size: 1.5em;
        height: 40px;
        width: 60px;
        top: 10px;
    }
    
    #coin {
        height: 24px; 
        width: 24px; 
        top: 12px; 
        left: 60px;
    }
    
    #live {
        height: 32px; 
        width: 32px; 
        top: 8px; 
        right: 8px;
    }
    
    #coinNumber {
        left: 0;
    }
    
    #liveNumber {
        right: 42px;
    }
}

/* Touch controls overlay */
.touch-controls {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    height: 120px;
    z-index: 1001;
    pointer-events: none;
}

.touch-control {
    position: absolute;
    background: rgba(255, 255, 255, 0.3);
    border: 2px solid rgba(255, 255, 255, 0.5);
    border-radius: 50%;
    pointer-events: auto;
    user-select: none;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: bold;
    color: white;
    text-shadow: 1px 1px 2px rgba(0,0,0,0.7);
}

.touch-left {
    bottom: 20px;
    left: 20px;
    width: 60px;
    height: 60px;
}

.touch-right {
    bottom: 20px;
    left: 100px;
    width: 60px;
    height: 60px;
}

.touch-jump {
    bottom: 20px;
    right: 20px;
    width: 60px;
    height: 60px;
}

.touch-down {
    bottom: 20px;
    right: 100px;
    width: 60px;
    height: 60px;
}

@media screen and (min-width: 769px){
.touch-controls {
        display: none;
    }
}
/* Hide touch controls on desktop */
@media screen and (min-width: 300px) {
}

/* Fullscreen button for large screens */
.fullscreen-btn {
    position: fixed;
    top: 20px;
    right: 20px;
    width: 40px;
    height: 40px;
    background: rgba(0, 0, 0, 0.7);
    border: none;
    border-radius: 5px;
    color: white;
    cursor: pointer;
    z-index: 1002;
    display: none;
}

@media screen and (min-width: 300px) {
    .fullscreen-btn {
        display:block;
    }
}

/* Music control button */
.music-btn {
    position: fixed;
    top: 70px;
    right: 20px;
    width: 40px;
    height: 40px;
    background: rgba(0, 0, 0, 0.7);
    border: none;
    border-radius: 5px;
    color: white;
    cursor: pointer;
    z-index: 1002;
    font-size: 16px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.music-btn:hover {
    background: rgba(0, 0, 0, 0.9);
}

.music-btn.muted {
    opacity: 0.5;
}