* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    overflow: hidden;
    background: #f8f8f8;
    color: white;
    /*background-image: url('../img/bg.jpg');*/
    background-size: cover;
    background-position: center center;
    
}



#gameContainer {
    position: relative;
    width: 100vw;
    height: 100vh;
}

#scoreBoard {
    position: absolute;
    top: 20px;
    left: 20px;
    font-size: 24px;
    font-weight: bold;
    z-index: 1000;
    background: rgba(0, 0, 0, 0.5);
    padding: 15px 25px;
    border-radius: 10px;
}

#timerBoard {
    position: absolute;
    top: 20px;
    right: 20px;
    font-size: 24px;
    font-weight: bold;
    z-index: 1000;
    background: rgba(0, 0, 0, 0.5);
    padding: 15px 25px;
    border-radius: 10px;
}

@media (max-width: 768px) {
  #scoreBoard {
        position: absolute;
        top: 20px;
        left: 20px;
        font-size: 14px;
        font-weight: bold;
        z-index: 1000;
        background: rgba(0, 0, 0, 0.5);
        padding: 15px 25px;
        border-radius: 10px;
    }

    #timerBoard {
        position: absolute;
        top: 20px;
        right: 20px;
        font-size: 14px;
        font-weight: bold;
        z-index: 1000;
        background: rgba(0, 0, 0, 0.5);
        padding: 15px 25px;
        border-radius: 10px;
    }
}


#timerBoard.warning {
    background: rgba(255, 100, 0, 0.7);
    animation: pulse 1s infinite;
}

@keyframes pulse {
    0%, 100% { transform: scale(1); }
    50% { transform: scale(1.05); }
}

#controlPanel {
    position: absolute;
    top: 100px;
    left: 20px;
    background: rgba(0, 0, 0, 0.7);
    padding: 20px;
    border-radius: 10px;
    z-index: 1000;
    width: 280px;
    display: none;
}

.control-group {
    margin-bottom: 20px;
}

.control-group label {
    display: block;
    margin-bottom: 8px;
    font-size: 14px;
    font-weight: bold;
}

.control-group input[type="range"] {
    width: 100%;
    cursor: pointer;
}

.control-value {
    display: inline-block;
    margin-left: 10px;
    color: #1e90ff;
    font-weight: bold;
}

#dropZone {
    position: absolute;
    bottom: 30px;
    left: 50%;
    transform: translateX(-50%);
    width: 150px;
    aspect-ratio: 9/16;
    background-image:url('../img/card.png');
    background-size: cover;
    background-position: center center;
    /*background: rgba(30, 144, 255, 0.7);*/
    border: 0px solid #fff;
    border-radius: 15px;
    z-index: 100;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 18px;
    font-weight: bold;
}

#dropZone.flash-green {
    animation: flashGreen 0.2s;
}

#dropZone.flash-red {
    animation: flashRed 0.2s;
}

@keyframes flashGreen {
    0%, 100% { background: rgba(30, 144, 255, 0.7); }
    50% { background: rgba(0, 255, 0, 0.2); box-shadow: 0 0 30px #00ff00; }
}

@keyframes flashRed {
    0%, 100% { background: rgba(30, 144, 255, 0.7); }
    50% { background: rgba(255, 0, 0, 0.2); box-shadow: 0 0 30px #ff0000; }
}

.falling-item {
    position: absolute;
    cursor: grab;
    transition: transform 0.1s;
    user-select: none;
}

.falling-item:active {
    cursor: grabbing;
}

.falling-item.dragging {
    z-index: 1000;
    opacity: 0.8;
}

.falling-item img {
    object-fit: contain;
    pointer-events: none;
    filter: drop-shadow(0 2px 5px rgba(0,0,0,0.5));
    border: 0px solid #fff;
}

.item-points {
    position: absolute;
    top: -20px;
    left: 50%;
    transform: translateX(-50%);
    
    padding: 2px 8px;
    border-radius: 5px;
    font-size: 12px;
    font-weight: bold;
    white-space: nowrap;
}

.item-points.positive {
    color: #05a844;
    background: rgba(255, 255, 255, 0.5);
    
}

.item-points.negative {
    color: #ff0000;
    background: rgba(255, 255, 255, 0.5);
}

#startButton {
    margin-top:30px;
    padding: 20px 40px;
    font-size: 24px;
    background: #fff;
    color: #e6007c;
    border: none;
    border-radius: 10px;
    cursor: pointer;
    z-index: 2000;
    transition: all 0.3s;
}

#startButton:hover {
    opacity: 0.5;
    transform: scale(1.1);
}


#gameStartModal {
    display: flex;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.9);
    z-index: 3000;
    justify-content: center;
    align-items: center;
}

#gameStartModal.hide {
    display: none;
}

#gameOverModal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.9);
    z-index: 3000;
    justify-content: center;
    align-items: center;
}

#gameOverModal.show {
    display: flex;
    
}

.modal-content {
    background: linear-gradient(135deg, #e6007a 0%, #57012f 100%);
    padding: 25px;
    border-radius: 20px;
    text-align: center;
    box-shadow: 0 10px 50px rgba(0, 0, 0, 0.5);
    animation: modalAppear 0.5s ease;
    margin: 0 3% 0 3%;
    width:100%;
    max-width: 800px;
}

@keyframes modalAppear {
    from {
        transform: scale(0.5);
        opacity: 0;
    }
    to {
        transform: scale(1);
        opacity: 1;
    }
}

.modal-content h1 {
    font-size: 38px;
    margin-bottom: 20px;
}

.modal-content p {
    font-size: 18px;
    margin: 15px 0;
}

.final-score {
    font-size: 64px;
    font-weight: bold;
    color: #ffd700;
    margin: 30px 0;
    text-shadow: 0 0 20px rgba(255, 215, 0, 0.5);
}

#restartButton {
    margin-top:60px;
    padding: 20px 40px;
    font-size: 24px;
    background: #fff;
    color: #e6007c;
    border: none;
    border-radius: 10px;
    cursor: pointer;
    z-index: 2000;
    transition: all 0.3s;
}

#restartButton:hover {
    opacity: 0.5;
    transform: scale(1.1);
}

/*CADASTRO*/
#cadastro{
    display: flex;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.9);
    z-index: 3500;
    justify-content: center;
    align-items: center;
}
.areaInputForm{
    width:100%;
    margin-bottom: 25px;
}
#startCadastro {
    margin-top:30px;
    padding: 20px 40px;
    font-size: 24px;
    background: #fff;
    color: #e6007c;
    border: none;
    border-radius: 10px;
    cursor: pointer;
    z-index: 2000;
    transition: all 0.3s;
}

#startCadastro:hover {
    opacity: 0.5;
    transform: scale(1.1);
}

input[type="text"]{
    border-radius: 10px!important;
}

/*Ranking*/
.verRanking {
    margin-top:30px;
    padding: 20px 40px;
    font-size: 24px;
    background: #fff;
    color: #e6007c;
    border: none;
    border-radius: 10px;
    cursor: pointer;
    z-index: 2000;
    transition: all 0.3s;
}

.verRanking:hover {
    opacity: 0.5;
    transform: scale(1.1);
}


.uk-modal{
    z-index:9000!important;
}

.uk-modal-dialog{
    background-color: transparent!important;
}

.uk-close{
    opacity: 1;
    font-size: 15px;
    border-radius: 50%;
}

.areaRanking{
    padding:3% 0 3%;
    max-height:80vh;
    overflow-y:auto;
    max-width: 800px;
    margin:0 auto;
}

.desenvolvedor{
    font-size:11px;
    margin-top: 30px!important;
    opacity: 0.5;
}