:root {
    --primary: #2a5298;
    --secondary: #f39c12;
    --accent: #e67e22;
    --glass: rgba(255, 255, 255, 0.15);
    --glass-border: rgba(255, 255, 255, 0.2);
    --text: #ffffff;
    --text-dark: #333333;
    --shadow: 0 8px 32px 0 rgba(0, 0, 0, 0.37);
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Outfit', sans-serif;
}

body {
    min-height: 100vh;
    display: flex;
    justify-content: center;
    align-items: center;
    overflow-x: hidden;
    background: #000;
}

/* Background Logic */
.background-container {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -1;
    background: #1a2a44 url('background.jpg') center center no-repeat;
    background-size: contain; /* Zapewnia widoczność całego obrazu */
}

.overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, rgba(42, 82, 152, 0.4), rgba(0, 0, 0, 0.6));
}
/* Usunięto animację zoomBackground, aby nie przycinała obrazu */

/* Layout */
#app {
    width: 100%;
    max-width: 1200px; /* Zwiększono, aby panel admina się mieścił */
    padding: 20px;
    display: flex;
    justify-content: center;
    z-index: 1;
}

.glass-card {
    background: var(--glass);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border-radius: 24px;
    border: 1px solid var(--glass-border);
    padding: 40px;
    box-shadow: var(--shadow);
    width: 100%;
    display: none;
    animation: fadeIn 0.5s ease-out;
}

.glass-card.active {
    display: block;
}

.user-header {
    display: flex;
    justify-content: flex-end;
    margin-bottom: -20px;
}

.glass-card.wide {
    max-width: 100%; 
    padding: 30px;
}

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

/* Typography */
h1 {
    font-size: 2rem;
    font-weight: 600;
    margin-bottom: 8px;
    text-align: center;
}

h2 {
    font-size: 1.5rem;
    margin-bottom: 20px;
}

p {
    opacity: 0.8;
    text-align: center;
    margin-bottom: 20px;
    line-height: 1.5;
}

.short-description p {
    font-style: italic;
    font-size: 1rem;
}

.long-description {
    margin-bottom: 30px;
    background: rgba(255, 255, 255, 0.05);
    padding: 20px;
    border-radius: 16px;
}

.long-description p {
    text-align: left;
    font-size: 0.95rem;
}

.highlight-text {
    font-weight: 600;
    color: var(--secondary);
    margin-top: 15px;
    font-size: 1.1rem;
    text-align: center !important;
}

/* Forms */
.input-group {
    margin-bottom: 20px;
}

label {
    display: block;
    margin-bottom: 8px;
    font-size: 0.9rem;
    font-weight: 300;
}

input[type="text"],
input[type="password"],
input[type="tel"],
input[type="email"] {
    width: 100%;
    padding: 18px 25px; /* Powiększony padding */
    border-radius: 12px;
    border: 1px solid var(--glass-border);
    background: rgba(255, 255, 255, 0.1);
    color: white;
    font-size: 1.1rem; /* Powiększona czcionka */
    outline: none;
    transition: all 0.3s;
}

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

/* Buttons */
.btn-primary {
    width: 100%;
    padding: 16px;
    border-radius: 12px;
    border: none;
    background: linear-gradient(90deg, var(--secondary), var(--accent));
    color: white;
    font-weight: 600;
    font-size: 1rem;
    cursor: pointer;
    transition: transform 0.2s, box-shadow 0.2s;
    margin-top: 10px;
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(243, 156, 18, 0.4);
}

.btn-text {
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid var(--glass-border);
    color: white;
    padding: 8px 16px;
    border-radius: 8px;
    cursor: pointer;
    font-size: 0.85rem;
    transition: all 0.3s;
    text-decoration: none;
    display: flex;
    align-items: center;
    gap: 8px;
}

.btn-text:hover {
    background: rgba(255, 71, 87, 0.2); /* Delikatny czerwony akcent przy wylogowaniu */
    border-color: rgba(255, 71, 87, 0.5);
    transform: translateY(-1px);
}

.btn-text::before {
    content: '←'; 
    font-size: 1.1rem;
}

.btn-secondary {
    padding: 10px 20px;
    border-radius: 8px;
    border: 1px solid var(--glass-border);
    background: rgba(255, 255, 255, 0.1);
    color: white;
    cursor: pointer;
    font-size: 0.9rem;
}

/* Checkbox Switch */
.checkbox-group {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 25px;
}

.switch {
    position: relative;
    display: inline-block;
    width: 50px;
    height: 24px;
}

.switch input { opacity: 0; width: 0; height: 0; }

.slider {
    position: absolute;
    cursor: pointer;
    top: 0; left: 0; right: 0; bottom: 0;
    background-color: rgba(255,255,255,0.2);
    transition: .4s;
}

.slider:before {
    position: absolute;
    content: "";
    height: 18px; width: 18px;
    left: 4px; bottom: 3px;
    background-color: white;
    transition: .4s;
}

input:checked + .slider { background-color: var(--secondary); }
input:checked + .slider:before { transform: translateX(24px); }
.slider.round { border-radius: 34px; }
.slider.round:before { border-radius: 50%; }

/* Success Msg */
.success-card {
    text-align: center;
    display: none;
}

.success-card.hidden { display: none; }
.success-card:not(.hidden) { display: block; }

.icon {
    font-size: 3rem;
    color: #2ecc71;
    margin-bottom: 10px;
}

/* Admin Table */
.header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 30px;
}

.actions {
    display: flex;
    gap: 10px;
    align-items: center;
}

.table-container {
    overflow-x: auto;
    margin-top: 20px;
}

table {
    width: 100%;
    border-collapse: collapse;
    min-width: 600px;
}

th, td {
    padding: 12px 8px; /* Mniejszy padding, aby tabela była bardziej zwarta */
    text-align: left;
    border-bottom: 1px solid var(--glass-border);
    font-size: 0.9rem;
    color: #ffffff; /* Wpisy na biało */
}

th {
    font-weight: 600;
    color: var(--secondary);
}

.stats {
    display: flex;
    gap: 20px;
    margin-bottom: 20px;
}

.stat-item .label { opacity: 0.7; font-size: 0.9rem; }
.stat-item .value { font-weight: 600; font-size: 1.2rem; margin-left: 5px; }

/* Responsive */
@media (max-width: 600px) {
    .glass-card {
        padding: 30px 20px;
    }
    
    #app {
        padding: 10px;
    }

    .header {
        flex-direction: column;
        gap: 10px;
        align-items: flex-start;
    }
}

.error-msg {
    color: #ff4757;
    font-size: 0.9rem;
    margin-top: 10px;
    text-align: center;
}

/* Organizer Info */
.organizer-info {
    margin-top: 30px;
}

.organizer-info hr {
    border: none;
    border-top: 1px solid var(--glass-border);
    margin-bottom: 15px;
}

.organizer-info p {
    font-size: 0.8rem;
    margin-bottom: 5px;
    opacity: 0.7;
    text-align: center;
}

.organizer-label {
    text-transform: uppercase;
    letter-spacing: 1px;
    font-weight: 600;
    font-size: 0.7rem !important;
    color: var(--secondary);
    opacity: 1 !important;
}

.hidden {
    display: none !important;
}
