@import url('https://fonts.googleapis.com/css2?family=Outfit:wght@300;400;600;700&display=swap');

:root {
    --primary-gradient: linear-gradient(135deg, #00d2ff 0%, #3a7bd5 100%);
    --accent-color: #ffd600;
    --text-color: #000000;
    --glass-bg: rgba(255, 255, 255, 0.4);
    /* Increased opacity for black text readability */
    --glass-border: rgba(255, 255, 255, 0.5);
}

* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

body {
    font-family: 'Outfit', sans-serif;
    background: linear-gradient(135deg, #4facfe 0%, #00f2fe 100%);
    min-height: 100vh;
    display: block;
    color: var(--text-color);
    padding: 20px 15px 40px 15px;
    overflow-x: hidden;
}

.container {
    width: 100%;
    max-width: 450px;
    margin: 20px auto;
    display: block;
}

.card {
    background: var(--glass-bg);
    backdrop-filter: blur(15px);
    -webkit-backdrop-filter: blur(15px);
    border: 1px solid var(--glass-border);
    border-radius: 24px;
    padding: 40px;
    box-shadow: 0 8px 32px 0 rgba(0, 0, 0, 0.3);
    text-align: center;
    animation: fadeIn 0.6s ease-out;
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(20px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

h1 {
    font-size: 2.2rem;
    font-weight: 700;
    margin-bottom: 20px;
    color: #000000;
}

h2 {
    font-size: 1.4rem;
    margin-bottom: 15px;
    color: #000000;
}

p {
    margin-bottom: 25px;
    line-height: 1.6;
    color: #000000;
}

.input-group {
    margin-bottom: 30px;
    text-align: left;
}

input[type="text"],
input[type="password"],
textarea,
select {
    width: 100%;
    background: rgba(255, 255, 255, 0.3);
    border: 1px solid var(--glass-border);
    border-radius: 12px;
    padding: 15px;
    color: #000000;
    font-size: 1rem;
    margin-top: 8px;
    outline: none;
    transition: all 0.3s;
}

input:focus {
    background: rgba(255, 255, 255, 0.2);
    border-color: white;
}

::placeholder {
    color: rgba(0, 0, 0, 0.5);
}

.btn {
    background: var(--accent-color);
    color: #004e92;
    border: none;
    border-radius: 14px;
    padding: 16px 30px;
    font-size: 1.1rem;
    font-weight: 700;
    cursor: pointer;
    width: 100%;
    transition: all 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    text-decoration: none;
    display: inline-block;
    box-shadow: 0 4px 15px rgba(255, 214, 0, 0.3);
}

.btn:hover {
    transform: scale(1.03);
    box-shadow: 0 6px 20px rgba(255, 214, 0, 0.4);
}

.btn:active {
    transform: scale(0.98);
}

.btn-secondary {
    background: rgba(255, 255, 255, 0.4);
    color: #000000;
    box-shadow: none;
    margin-top: 10px;
    border: 1px solid var(--glass-border);
}

.vote-btns {
    display: grid;
    grid-template-columns: repeat(5, 1fr);
    gap: 8px;
    margin: 25px 0;
}

.vote-btn {
    background: rgba(255, 255, 255, 0.25);
    border: 1px solid var(--glass-border);
    color: #000000;
    height: 50px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 12px;
    font-size: 1.2rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s;
}

.vote-btn:hover {
    background: var(--accent-color);
    color: #004e92;
}

.photo-preview {
    width: 100%;
    border-radius: 18px;
    margin-bottom: 20px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
    border: 3px solid white;
}

.status-badge {
    background: rgba(255, 255, 255, 0.5);
    padding: 6px 15px;
    border-radius: 30px;
    font-size: 0.9rem;
    display: inline-block;
    margin-bottom: 20px;
    border: 1px solid var(--glass-border);
    color: #000000;
}

/* Admin specific styles */
.admin-card {
    max-width: 800px;
}

.admin-list {
    margin-top: 30px;
    text-align: left;
}

.admin-item {
    background: rgba(255, 255, 255, 0.05);
    border-radius: 15px;
    padding: 15px;
    margin-bottom: 12px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.admin-item img {
    width: 60px;
    height: 60px;
    object-fit: cover;
    border-radius: 10px;
    margin-right: 15px;
}

.stats-table {
    width: 100%;
    border-collapse: separate;
    border-spacing: 0 8px;
    margin-top: 20px;
}

.stats-table th {
    padding: 12px;
    text-transform: uppercase;
    font-size: 0.8rem;
    letter-spacing: 1px;
    color: #000000;
}

.stats-table td {
    background: rgba(255, 255, 255, 0.1);
    padding: 15px;
}

.stats-table td:first-child {
    border-radius: 12px 0 0 12px;
}

.stats-table td:last-child {
    border-radius: 0 12px 12px 0;
}

@media (max-width: 480px) {
    .card {
        padding: 25px 20px;
        animation: none;
        /* Disabilita animazione per evitare bug di posizionamento mobile */
    }

    h1 {
        font-size: 1.8rem;
    }

    body {
        padding: 33px 10px 50px 10px;
        /* Ridotto da 100px */
    }
}