body { font-family: Arial, sans-serif; background-color: #f4f4f9; color: #333; display: flex; justify-content: center; padding: 2rem; }
.container { background: white; padding: 2rem; border-radius: 8px; box-shadow: 0 4px 15px rgba(0,0,0,0.1); max-width: 800px; width: 100%; box-sizing: border-box; }

.text-center { text-align: center; }

.subtitle {
    font-size: 1.2rem;
    color: #7f8c8d;
    text-transform: uppercase;
    letter-spacing: 3px;
    margin-bottom: -15px;
    margin-top: 0;
    font-weight: bold;
    position: relative;
    z-index: 1;
}

.title-wrapper {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 15px; 
    margin-bottom: 2rem; 
}

.event-logo {
    height: 4.5rem; 
    width: auto;
}

.main-title {
    font-family: 'Montserrat', sans-serif;
    font-weight: 900; 
    font-style: italic;
    text-transform: uppercase;
    color: #2c3e50;
    font-size: 4.5rem;
    margin: 0; 
    text-shadow: 2px 2px 4px rgba(0,0,0,0.1);
}

.input-group { margin-bottom: 1.5rem; display: flex; flex-direction: column; align-items: center; }
.input-group label { font-weight: bold; margin-bottom: 10px; color: #34495e; }

.name-controls { display: flex; gap: 10px; width: 100%; max-width: 400px; justify-content: center; }
.name-controls input { flex: 1; padding: 0.8rem; border: 2px solid #ddd; border-radius: 30px; font-size: 1rem; text-align: center; outline: none; transition: border 0.3s; width: 100%; box-sizing: border-box; }
.name-controls input:focus { border-color: #3498db; }

.action-btn { padding: 0.8rem 1.5rem; background-color: #3498db; color: white; border: none; border-radius: 30px; cursor: pointer; font-weight: bold; transition: all 0.3s ease; box-shadow: 0 4px 6px rgba(52, 152, 219, 0.2); white-space: nowrap; }
.action-btn:hover { background-color: #2980b9; transform: translateY(-2px); box-shadow: 0 6px 12px rgba(52, 152, 219, 0.3); }

.action-btn.outline-btn { background-color: transparent; color: #e74c3c; border: 2px solid #e74c3c; box-shadow: none; }
.action-btn.outline-btn:hover { background-color: #e74c3c; color: white; box-shadow: 0 6px 12px rgba(231, 76, 60, 0.3); transform: translateY(-2px); }

.tier-status { background: #f8f9fa; border-top: 4px solid #f39c12; padding: 15px; margin: 20px auto; border-radius: 8px; font-size: 1.2rem; color: #2c3e50; max-width: 500px; box-shadow: 0 2px 8px rgba(0,0,0,0.05); }
.tier-reached { color: #27ae60; font-weight: 900; font-size: 1.4rem; margin-bottom: 5px; }
.tier-highlight { font-weight: bold; color: #d35400; }

.gallery { display: flex; flex-wrap: wrap; gap: 15px; margin-bottom: 2rem; justify-content: center; max-width: 660px; margin-left: auto; margin-right: auto; }
.upload-box { width: 120px; height: 120px; border: 2px dashed #3498db; border-radius: 15px; display: flex; align-items: center; justify-content: center; cursor: pointer; background-size: cover; background-position: center; position: relative; transition: 0.3s; }
.upload-box:not(.locked):hover { background-color: #f0f8ff; border-color: #2980b9; transform: scale(1.05); }
.upload-box.locked { border: none; cursor: default; box-shadow: 0 4px 8px rgba(0,0,0,0.1); }
.plus-sign { font-size: 3rem; color: #3498db; }
.loading-text { font-size: 0.9rem; color: #666; display: none; }

#statusMessage { text-align: center; font-weight: bold; color: #7f8c8d; margin-bottom: 1rem; }

.delete-btn { position: absolute; top: -10px; right: -10px; background-color: #e74c3c; color: white; border: none; border-radius: 50%; width: 28px; height: 28px; font-size: 18px; font-weight: bold; cursor: pointer; display: flex; align-items: center; justify-content: center; box-shadow: 0 2px 4px rgba(0,0,0,0.3); z-index: 10; transition: all 0.2s; line-height: 1; }
.delete-btn:hover { background-color: #c0392b; transform: scale(1.1); }
.upload-box:not(.locked) .delete-btn { display: none; }

.funny-quote { margin-top: 2rem; padding: 15px; font-size: 1.1rem; font-style: italic; color: #2c3e50; background-color: #e8f4f8; border-left: 5px solid #3498db; border-radius: 4px; text-align: center; transition: all 0.3s ease; font-weight: bold; }
.funny-quote.warning { background-color: #fdf2e9; border-left: 5px solid #e67e22; color: #d35400; }

/* =========================================
   MOBIILIRESPONSIIVISUUS (Puhelimen näytöt)
   ========================================= */
@media (max-width: 600px) {
    body {
        padding: 1rem; /* Vähemmän tyhjää tilaa reunoilla puhelimella */
    }
    
    .container {
        padding: 1.5rem 1rem;
    }

    /* Pienennetään otsikoita ja logoa puhelimella */
    .main-title {
        font-size: 2.2rem;
    }
    
    .event-logo {
        height: 2.2rem;
    }
    
    .subtitle {
        font-size: 0.9rem;
        margin-bottom: -10px; /* Säädetään väliä pienemmäksi */
    }
    
    .title-wrapper {
        gap: 8px; /* Logo ja teksti hieman lähemmäs toisiaan */
        margin-bottom: 1.5rem;
    }

    /* Nappien ja tekstikenttien asettelu kapealla ruudulla */
    .name-controls {
        flex-direction: column; /* Pinotaan kenttä ja nappi allekkain */
        align-items: stretch;
    }
    
    .action-btn {
        width: 100%; /* Napit koko leveydelle */
    }

    /* Pienennetään juomaruutuja hieman, jotta mahtuvat paremmin */
    .upload-box {
        width: 90px;
        height: 90px;
    }
    
    .plus-sign {
        font-size: 2rem;
    }
}