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

:root {
    --primary: #4a90d9;
    --primary-dark: #2e6ab3;
    --primary-light: #6ba3e0;
    --secondary: #5ba0e8;
    --accent: #f0a500;
    --success: #10b981;
    --danger: #ef4444;
    --dark: #1e3a5f;
    --gray: #64748b;
    --light: #e8f4fc;
    --white: #ffffff;
    --gradient: linear-gradient(135deg, #4a90d9 0%, #2e6ab3 100%);
    --gradient-light: linear-gradient(135deg, #6ba3e0 0%, #4a90d9 100%);
    /* Pozadina novog izgleda - menja se na /page-visibility (layout ih prepisuje) */
    --bg-from: #5b9be3;
    --bg-to: #3b8f9c;
    /* Pozadina iza loga - podrazumevano nema je; layout je ukljucuje kad je
       izabrana boja (home_settings.logo_bg_color) */
    --logo-bg: transparent;
    --logo-pad: 0px;
    --logo-shadow: none;
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background: var(--gradient);
    min-height: 100vh;
    color: var(--dark);
}

header {
    background: rgba(255, 255, 255, 0.15);
    backdrop-filter: blur(10px);
    padding: 1rem 2rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 1rem;
    border-bottom: 1px solid rgba(255, 255, 255, 0.25);
}

header h1 {
    color: #fff;
    font-size: 1.8rem;
    font-weight: 700;
    text-shadow: 0 2px 4px rgba(0,0,0,0.2);
}

nav {
    display: flex;
    gap: 0.5rem;
    flex-wrap: wrap;
}

nav a {
    color: #fff;
    text-decoration: none;
    padding: 0.5rem 1rem;
    border-radius: 25px;
    transition: all 0.3s ease;
    font-size: 0.9rem;
    font-weight: 500;
}

nav a:hover {
    background: rgba(255, 255, 255, 0.25);
    transform: translateY(-2px);
}

main {
    max-width: 1000px;
    margin: 2rem auto;
    padding: 2rem;
    background: var(--white);
    border-radius: 16px;
    box-shadow: 0 15px 50px rgba(0, 0, 0, 0.2);
}

/* Login page - smaller form */
main.login-page {
    max-width: 400px;
    margin: 4rem auto;
    padding: 2rem;
}

main.login-page h2 {
    text-align: center;
    font-size: 1.5rem;
}

main.login-page .event-form {
    gap: 1rem;
}

main.login-page .form-group input {
    padding: 0.7rem 0.9rem;
}

main.login-page .btn {
    width: 100%;
    padding: 0.75rem;
}

main h2 {
    color: var(--primary-dark);
    margin-bottom: 1.5rem;
    padding-bottom: 0.5rem;
    border-bottom: 3px solid var(--primary-light);
    font-weight: 700;
}

main h3 {
    color: var(--primary-dark);
    margin-top: 1.5rem;
    margin-bottom: 1rem;
}

/* Hero section */
.hero {
    text-align: center;
    padding: 3rem 2rem;
    background: var(--gradient-light);
    border-radius: 12px;
    margin-bottom: 2rem;
    color: white;
}

.hero h2 {
    border: none;
    font-size: 2rem;
    margin-bottom: 0.5rem;
    color: white;
}

.hero-with-logo {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 2rem;
    flex-wrap: wrap;
}

.club-logo {
    width: 150px;
    height: 150px;
    object-fit: contain;
    border-radius: 12px;
    background: var(--logo-bg);
    padding: calc(var(--logo-pad) * 10);
    box-shadow: var(--logo-shadow);
}

.hero-text {
    text-align: left;
}

.hero-with-logo .hero-text h2 {
    font-size: 2.2rem;
    margin-bottom: 0.25rem;
}

@media (max-width: 600px) {
    .hero-with-logo {
        flex-direction: column;
        text-align: center;
    }

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

    .club-logo {
        width: 120px;
        height: 120px;
    }
}

.hero-subtitle {
    color: rgba(255,255,255,0.9);
    font-size: 1.1rem;
}

/* Content sections */
.content-section {
    margin-bottom: 1.5rem;
    padding: 1.25rem;
    background: var(--light);
    border-radius: 10px;
    border-left: 4px solid var(--primary);
}

.content-section h3 {
    margin-top: 0;
    margin-bottom: 0.75rem;
    color: var(--primary-dark);
}

.content-section p {
    line-height: 1.7;
    margin-bottom: 0.75rem;
    color: var(--gray);
}

.content-section ul {
    margin-left: 1.5rem;
    margin-bottom: 0.75rem;
}

.content-section li {
    line-height: 1.7;
    margin-bottom: 0.4rem;
    color: var(--gray);
}

.cta-section {
    text-align: center;
    background: var(--gradient);
    color: white;
    border-left: none;
}

.cta-section h3 {
    color: white;
}

.cta-section p {
    color: rgba(255,255,255,0.9);
}

/* Events list */
.events-list {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.event-card {
    background: var(--light);
    border-left: 4px solid var(--secondary);
    padding: 1.25rem;
    border-radius: 0 10px 10px 0;
    transition: all 0.3s ease;
    position: relative;
}

.event-card:hover {
    transform: translateX(6px);
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
}

/* Special event - glowing effect */
.event-card.event-special {
    border-left-color: var(--accent);
    background: linear-gradient(135deg, #fff9e6 0%, #fff3cc 100%);
    animation: special-glow 2s ease-in-out infinite;
    position: relative;
}


@keyframes special-glow {
    0%, 100% {
        box-shadow: 0 0 5px rgba(240, 165, 0, 0.3),
                    0 0 10px rgba(240, 165, 0, 0.2),
                    0 0 15px rgba(240, 165, 0, 0.1);
    }
    50% {
        box-shadow: 0 0 10px rgba(240, 165, 0, 0.5),
                    0 0 20px rgba(240, 165, 0, 0.3),
                    0 0 30px rgba(240, 165, 0, 0.2);
    }
}

@keyframes star-pulse {
    0%, 100% {
        transform: scale(1);
        opacity: 1;
    }
    50% {
        transform: scale(1.2);
        opacity: 0.8;
    }
}

.event-card h3 {
    color: var(--dark);
    margin-bottom: 0.5rem;
    margin-top: 0;
}

.event-card-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 1rem;
    margin-bottom: 0.75rem;
}

.event-card-header h3 {
    margin-bottom: 0;
    flex: 1;
}

.event-card-header .event-actions {
    display: flex;
    gap: 0.5rem;
    flex-shrink: 0;
    flex-wrap: wrap;
}

@media (max-width: 600px) {
    .event-card-header {
        flex-direction: column;
        gap: 0.5rem;
    }

    .event-card-header .event-actions {
        flex-shrink: 1;
        width: 100%;
    }

    .event-card-header .event-actions .btn-action {
        flex: 1;
        justify-content: center;
        padding: 0.45rem 0.5rem;
        font-size: 0.8rem;
    }
}

.header-actions {
    display: flex;
    gap: 0.5rem;
    flex-wrap: wrap;
}

.event-club-badge {
    position: absolute;
    top: 1rem;
    right: 1rem;
    background: var(--gradient);
    color: #fff;
    padding: 0.25rem 0.75rem;
    border-radius: 15px;
    font-size: 0.75rem;
    font-weight: 600;
}

.event-badges-row {
    position: absolute;
    top: 1rem;
    right: 1rem;
    display: flex;
    gap: 0.5rem;
    flex-wrap: wrap;
    justify-content: flex-end;
}

.event-special .event-badges-row {
    right: 2.5rem;
    align-items: center;
}

.event-badge {
    padding: 0.25rem 0.75rem;
    border-radius: 15px;
    font-size: 0.75rem;
    font-weight: 600;
}

.event-badge-club {
    background: var(--gradient);
    color: #fff;
}

.event-badge-paid {
    background: #059669;
    color: #ffffff;
}

.event-badge-status.status-pending {
    background: #f59e0b;
    color: #ffffff;
}

.event-badge-status.status-approved {
    background: #059669;
    color: #ffffff;
}

.event-badge-status.status-rejected {
    background: #dc2626;
    color: #ffffff;
}

@media (max-width: 600px) {
    .event-card .event-badges-row {
        position: static;
        margin-bottom: 0.35rem;
    }
}

.event-card-date {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    background: linear-gradient(135deg, #eff6ff, #e0f2fe);
    border-left: 3px solid var(--primary);
    border-radius: 6px;
    padding: 0.45rem 0.7rem;
    margin-bottom: 0.5rem;
    color: var(--primary);
}

.event-card-date svg {
    flex-shrink: 0;
    opacity: 0.7;
}

.event-card-date-value {
    font-weight: 700;
    font-size: 1.15rem;
    color: var(--primary-dark);
}

.event-card-time-value {
    font-size: 1.15rem;
    font-weight: 700;
    color: var(--primary-dark);
}

.event-deadline strong,
.event-guide strong {
    font-weight: 600;
    color: var(--dark);
}

.event-meta {
    margin-bottom: 0.5rem;
}

.event-deadline {
    color: var(--dark);
    font-size: 0.9rem;
    margin-bottom: 0.3rem;
    font-weight: 400;
}

.event-description {
    color: var(--gray);
    line-height: 1.6;
}

.past-event {
    opacity: 0.6;
    border-left-color: var(--gray);
}

.payment-urgent {
    border-left-color: #dc2626;
    background: linear-gradient(to right, #fee2e2 0%, var(--light) 100%);
    animation: pulse-urgent 2s infinite;
}

@keyframes pulse-urgent {
    0%, 100% {
        box-shadow: 0 5px 20px rgba(220, 38, 38, 0.15);
    }
    50% {
        box-shadow: 0 5px 25px rgba(220, 38, 38, 0.3);
    }
}

.payment-urgent .event-deadline {
    color: #dc2626;
    font-weight: 600;
}

.past-label {
    color: var(--gray);
    font-style: italic;
}

.no-events {
    text-align: center;
    color: var(--gray);
    font-style: italic;
    padding: 2rem;
}

/* Clubs list */
.clubs-title {
    margin-top: 2rem;
}

.clubs-list {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
    gap: 1rem;
    margin-top: 1rem;
}

.club-card {
    background: var(--gradient);
    padding: 1rem;
    border-radius: 10px;
    color: white;
    transition: transform 0.3s ease;
}

.club-card:hover {
    transform: translateY(-3px);
}

.club-card h4 {
    color: white;
    margin-bottom: 0.4rem;
}

.club-location {
    color: rgba(255,255,255,0.85);
    font-size: 0.8rem;
}

/* Badges */
.badge {
    display: inline-block;
    padding: 0.25rem 0.6rem;
    border-radius: 15px;
    font-size: 0.7rem;
    font-weight: 600;
}

.admin-badge {
    background: var(--accent);
    color: white;
}

.active-badge {
    background: var(--success);
    color: white;
}

.inactive-badge {
    background: var(--danger);
    color: white;
}

.role-badge {
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.role-user {
    background: var(--gray);
    color: white;
}

.role-admin {
    background: var(--accent);
    color: white;
}

.role-super_admin {
    background: linear-gradient(135deg, #e74c3c 0%, #c0392b 100%);
    color: white;
}

/* Forms */
.event-form {
    display: flex;
    flex-direction: column;
    gap: 1.25rem;
    margin-bottom: 2rem;
}

.form-group {
    display: flex;
    flex-direction: column;
    gap: 0.4rem;
}

.form-group small {
    color: var(--gray);
    font-size: 0.75rem;
}

.form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1rem;
}

.form-group label {
    font-weight: 600;
    color: var(--dark);
    font-size: 0.9rem;
}

.form-group input,
.form-group textarea,
.form-group select {
    padding: 0.75rem 0.9rem;
    border: 2px solid #d1e3f6;
    border-radius: 8px;
    font-size: 0.95rem;
    transition: all 0.3s ease;
    width: 100%;
    max-width: 100%;
}

.form-group input:focus,
.form-group textarea:focus,
.form-group select:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(74, 144, 217, 0.15);
}

.input-hint {
    display: block;
    margin-top: 0.35rem;
    font-size: 0.8rem;
    color: #64748b;
}

/* Custom Time Picker - Button Style */
.time-picker-buttons {
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.time-picker-btn {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 0.75rem 1.5rem;
    background: linear-gradient(135deg, #f8fafc 0%, #e2e8f0 100%);
    border: 2px solid #cbd5e1;
    border-radius: 12px;
    cursor: pointer;
    transition: all 0.2s ease;
    min-width: 80px;
}

.time-picker-btn:hover {
    border-color: var(--primary);
    background: linear-gradient(135deg, #eff6ff 0%, #dbeafe 100%);
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(74, 144, 217, 0.2);
}

.time-picker-label {
    font-size: 0.7rem;
    color: #64748b;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 0.25rem;
}

.time-picker-value {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--primary);
}

.time-picker-colon {
    font-size: 2rem;
    font-weight: 700;
    color: var(--primary);
    line-height: 1;
}

/* Time Picker Dialog */
.time-dialog-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.5);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 2000;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
}

.time-dialog-overlay.active {
    opacity: 1;
    visibility: visible;
}

.time-dialog {
    background: white;
    border-radius: 16px;
    padding: 1.5rem;
    max-width: 400px;
    width: 90%;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
    transform: scale(0.9);
    transition: transform 0.3s ease;
}

.time-dialog-overlay.active .time-dialog {
    transform: scale(1);
}

.time-dialog-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1.25rem;
    padding-bottom: 0.75rem;
    border-bottom: 2px solid #e2e8f0;
}

.time-dialog-header h4 {
    margin: 0;
    color: var(--dark);
    font-size: 1.1rem;
}

.time-dialog-close {
    width: 32px;
    height: 32px;
    border: none;
    background: #f1f5f9;
    border-radius: 8px;
    font-size: 1.25rem;
    cursor: pointer;
    color: #64748b;
    transition: all 0.2s ease;
}

.time-dialog-close:hover {
    background: #e2e8f0;
    color: var(--dark);
}

.time-dialog-grid {
    display: grid;
    gap: 0.5rem;
}

.hours-grid {
    grid-template-columns: repeat(6, 1fr);
}

.minutes-grid {
    grid-template-columns: repeat(2, 1fr);
}

.time-option-btn {
    padding: 0.75rem;
    border: 2px solid #e2e8f0;
    background: white;
    border-radius: 10px;
    font-size: 1rem;
    font-weight: 600;
    color: var(--dark);
    cursor: pointer;
    transition: all 0.2s ease;
}

.time-option-btn:hover {
    border-color: var(--primary);
    background: #eff6ff;
    color: var(--primary);
    transform: scale(1.05);
}

.time-option-btn:active {
    transform: scale(0.95);
}

.time-option-large {
    padding: 1.5rem;
    font-size: 1.5rem;
}

/* Date Picker Button */
.date-picker-btn {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 0.85rem 1.25rem;
    background: linear-gradient(135deg, #f8fafc 0%, #e2e8f0 100%);
    border: 2px solid #cbd5e1;
    border-radius: 12px;
    cursor: pointer;
    transition: all 0.2s ease;
    width: 100%;
    text-align: left;
}

.date-picker-btn:hover {
    border-color: var(--primary);
    background: linear-gradient(135deg, #eff6ff 0%, #dbeafe 100%);
}

.date-picker-btn svg {
    color: var(--primary);
    flex-shrink: 0;
}

.date-picker-value {
    font-size: 1rem;
    font-weight: 600;
    color: var(--dark);
}

/* Date Picker Dialog */
.date-dialog {
    max-width: 360px;
}

.date-picker-content {
    padding-top: 0.5rem;
}

.date-picker-nav {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 1rem;
}

.date-nav-btn {
    width: 40px;
    height: 40px;
    border: none;
    background: #f1f5f9;
    border-radius: 10px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #64748b;
    transition: all 0.2s ease;
}

.date-nav-btn:hover {
    background: var(--primary);
    color: white;
}

.date-picker-month-year {
    display: flex;
    gap: 0.5rem;
}

.date-select {
    padding: 0.5rem 0.75rem;
    border: 2px solid #e2e8f0;
    border-radius: 8px;
    font-size: 0.95rem;
    font-weight: 600;
    background: white;
    cursor: pointer;
    color: var(--dark);
}

.date-select:focus {
    outline: none;
    border-color: var(--primary);
}

.date-picker-weekdays {
    display: grid;
    grid-template-columns: repeat(7, 1fr);
    gap: 0.25rem;
    margin-bottom: 0.5rem;
    text-align: center;
}

.date-picker-weekdays span {
    font-size: 0.75rem;
    font-weight: 600;
    color: #94a3b8;
    padding: 0.5rem 0;
}

.date-picker-days {
    display: grid;
    grid-template-columns: repeat(7, 1fr);
    gap: 0.25rem;
}

.date-day-empty {
    aspect-ratio: 1;
}

.date-day-btn {
    aspect-ratio: 1;
    border: none;
    background: #f8fafc;
    border-radius: 10px;
    font-size: 0.95rem;
    font-weight: 500;
    color: var(--dark);
    cursor: pointer;
    transition: all 0.15s ease;
}

.date-day-btn:hover {
    background: var(--primary);
    color: white;
    transform: scale(1.1);
}

.date-day-today {
    background: #dbeafe;
    color: var(--primary);
    font-weight: 700;
}

.date-day-selected {
    background: var(--primary) !important;
    color: white !important;
    font-weight: 700;
}

/* Optional date picker button */
.date-picker-btn-optional {
    border-style: dashed;
}

.date-picker-btn-optional .date-picker-value {
    color: #94a3b8;
}

.date-picker-btn-small {
    padding: 0.4rem 0.6rem;
    font-size: 0.8rem;
    min-width: 0;
    gap: 0;
    border-radius: 8px;
}

.date-picker-btn-small .date-picker-value {
    font-size: 0.8rem;
}

/* Clear date button */
.btn-clear-date {
    width: 100%;
    margin-top: 1rem;
    padding: 0.6rem 1rem;
    font-size: 0.9rem;
}

.checkbox-group {
    flex-direction: row;
    align-items: center;
}

.checkbox-group label {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    cursor: pointer;
}

.checkbox-group input[type="checkbox"] {
    width: 18px;
    height: 18px;
    accent-color: var(--primary);
}

.clubs-checkboxes {
    border: 2px solid #d1e3f6;
    border-radius: 8px;
    padding: 0.75rem;
    max-height: 180px;
    overflow-y: auto;
}

.club-membership-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0.5rem 0;
    border-bottom: 1px solid #e8f4fc;
}

.club-membership-row:last-child {
    border-bottom: none;
}

.admin-label {
    font-size: 0.8rem;
    color: var(--accent);
    font-weight: 600;
}

.guide-label {
    font-size: 0.8rem;
    color: var(--success);
    font-weight: 600;
}

.guide-badge {
    background: var(--success);
    color: white;
}

.public-badge {
    background: var(--accent);
    color: white;
    font-size: 0.7rem;
    padding: 0.2rem 0.5rem;
    border-radius: 4px;
    font-weight: 600;
    margin-left: 0.5rem;
    vertical-align: middle;
}

.checkbox-label {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    cursor: pointer;
    font-weight: 500;
}

.checkbox-label input[type="checkbox"] {
    width: 18px;
    height: 18px;
    cursor: pointer;
}

.public-checkbox {
    background: #fffbeb;
    padding: 1rem;
    border-radius: 8px;
    border: 1px solid #fbbf24;
}

.public-checkbox small {
    display: block;
    margin-top: 0.5rem;
    color: var(--gray);
}

/* Checkbox row */
.checkbox-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1rem;
}

@media (max-width: 600px) {
    .checkbox-row {
        grid-template-columns: 1fr;
    }
}

.special-checkbox {
    color: var(--accent);
    font-weight: 600;
}

/* Transport options */
.transport-options {
    display: flex;
    gap: 1rem;
    flex-wrap: wrap;
}

.transport-options .radio-label {
    background: var(--light);
    padding: 0.5rem 1rem;
    border-radius: 6px;
    cursor: pointer;
    transition: all 0.2s;
}

.transport-options .radio-label:has(input:checked) {
    background: var(--primary);
    color: white;
}

/* Daily descriptions */
.daily-desc-item {
    background: var(--light);
    padding: 0.75rem;
    border-radius: 6px;
    margin-bottom: 0.5rem;
}

.daily-desc-item label {
    font-size: 0.85rem;
    color: var(--primary-dark);
}

.daily-desc-item textarea {
    margin-top: 0.25rem;
}

/* Event requirements badges */
.event-requirements {
    display: flex;
    gap: 0.5rem;
    flex-wrap: wrap;
    margin-top: 0.5rem;
}

.requirement-badge {
    font-size: 0.75rem;
    padding: 0.25rem 0.5rem;
    border-radius: 4px;
    display: inline-flex;
    align-items: center;
    gap: 0.25rem;
}

.requirement-badge-passport {
    background: #fef3c7;
    color: #92400e;
}

.requirement-badge-greencard {
    background: #d1fae5;
    color: #065f46;
}

.requirement-badge-kombi {
    background: #dbeafe;
    color: #1e40af;
}

.requirement-badge-own {
    background: #f3e8ff;
    color: #6b21a8;
}

/* Public events on homepage */
.public-events-list {
    display: flex;
    flex-direction: column;
    gap: 1rem;
    margin-top: 1rem;
}

.public-event-card {
    background: var(--light);
    padding: 1.25rem;
    border-radius: 10px;
    border-left: 4px solid var(--primary);
}

.public-event-card h4 {
    margin: 0 0 0.75rem 0;
    color: var(--dark);
}

.public-event-card .event-meta {
    margin-bottom: 0.5rem;
}

.public-event-card .event-meta p {
    margin: 0.25rem 0;
    font-size: 0.9rem;
}

.public-event-card .event-description {
    margin: 0.75rem 0 0 0;
    color: var(--gray);
    font-size: 0.9rem;
}

.public-events-note {
    margin-top: 1rem;
    color: var(--gray);
    font-style: italic;
    font-size: 0.9rem;
}

/* Member events modal */
.modal-body {
    max-height: 60vh;
    overflow-y: auto;
}

.events-section {
    margin-bottom: 1.5rem;
}

.events-section h4 {
    margin: 0 0 0.75rem 0;
    color: var(--dark);
    font-size: 1rem;
    border-bottom: 2px solid var(--light);
    padding-bottom: 0.5rem;
}

.no-events-small {
    color: var(--gray);
    font-style: italic;
    font-size: 0.9rem;
    margin: 0;
}

.member-events-list {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.member-event-item {
    background: var(--light);
    padding: 0.85rem;
    border-radius: 8px;
    border-left: 3px solid var(--primary);
}

.member-event-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 0.5rem;
    margin-bottom: 0.35rem;
}

.member-event-header strong {
    color: var(--dark);
    font-size: 0.95rem;
}

.event-status-badge {
    font-size: 0.7rem;
    padding: 0.2rem 0.5rem;
    border-radius: 4px;
    font-weight: 600;
    text-transform: uppercase;
}

.event-status-badge.status-pending {
    background: var(--accent);
    color: white;
}

.event-status-badge.status-approved {
    background: var(--success);
    color: white;
}

.event-status-badge.status-rejected {
    background: var(--danger);
    color: white;
}

.event-status-badge.status-guide {
    background: #8b5cf6;
    color: white;
}

.member-event-badges {
    display: flex;
    gap: 0.5rem;
    align-items: center;
}

/* Role Toggle - Icon based */
.role-toggles {
    display: flex;
    gap: 1rem;
    margin-top: 0.5rem;
}

.role-toggle {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    cursor: pointer;
    user-select: none;
    padding: 0.75rem 1rem;
    background: #f8fafc;
    border: 2px solid #e2e8f0;
    border-radius: 12px;
    transition: all 0.3s ease;
    flex: 1;
    justify-content: center;
}

.role-toggle:hover {
    border-color: #cbd5e1;
    background: #f1f5f9;
}

.role-toggle input[type="checkbox"] {
    display: none;
}

.role-toggle-label {
    font-size: 0.95rem;
    font-weight: 600;
    color: #94a3b8;
    transition: all 0.3s ease;
    text-decoration: line-through;
}

.role-toggle input[type="checkbox"]:checked ~ .role-toggle-label {
    color: var(--primary);
    text-decoration: none;
}

/* Active state styling */
.role-toggle:has(input[type="checkbox"]:checked) {
    border-color: var(--primary);
    background: linear-gradient(135deg, #eff6ff 0%, #dbeafe 100%);
}

.role-toggle-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 36px;
    height: 36px;
    background: #e2e8f0;
    border-radius: 10px;
    color: #94a3b8;
    transition: all 0.3s ease;
    position: relative;
}

/* Strikethrough overlay on inactive icon */
.role-toggle-icon::after {
    content: '';
    position: absolute;
    width: 28px;
    height: 2px;
    background: #94a3b8;
    transform: rotate(-45deg);
    transition: all 0.3s ease;
    opacity: 1;
}

.role-toggle input[type="checkbox"]:checked ~ .role-toggle-icon {
    background: var(--primary);
    color: white;
}

.role-toggle input[type="checkbox"]:checked ~ .role-toggle-icon::after {
    opacity: 0;
}

/* Locked role (for current admin editing self) */
.role-locked {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.75rem 1rem;
    background: linear-gradient(135deg, #fef3c7 0%, #fde68a 100%);
    border: 2px solid #fbbf24;
    border-radius: 12px;
    color: #92400e;
    font-weight: 600;
    font-size: 0.9rem;
}

.role-locked-icon {
    display: flex;
    align-items: center;
    color: #d97706;
}

.member-event-date {
    font-size: 0.85rem;
    color: var(--gray);
    margin-bottom: 0.5rem;
}

.member-event-payment {
    margin-top: 0.5rem;
    padding-top: 0.5rem;
    border-top: 1px solid rgba(0,0,0,0.1);
}

.payment-status-full {
    color: var(--success);
    font-weight: 600;
    font-size: 0.85rem;
}

.payment-status-partial {
    color: var(--accent);
    font-weight: 500;
    font-size: 0.85rem;
}

.installments-mini {
    display: flex;
    flex-wrap: wrap;
    gap: 0.35rem;
    margin-top: 0.5rem;
}

.installment-mini {
    font-size: 0.75rem;
    padding: 0.2rem 0.4rem;
    border-radius: 4px;
    font-weight: 500;
}

.installment-mini.paid {
    background: var(--success);
    color: white;
}

.installment-mini.unpaid {
    background: #e2e8f0;
    color: var(--gray);
}

.disabled-input {
    background: #e5e7eb;
    color: #6b7280;
    cursor: not-allowed;
}

.club-name-label {
    font-weight: 500;
    color: var(--dark);
    min-width: 150px;
}

.form-actions {
    display: flex;
    gap: 0.75rem;
}

/* Price and installments */
.price-row {
    align-items: flex-end;
}

.currency-group {
    min-width: 180px;
}

.radio-group {
    display: flex;
    gap: 0.6rem;
}

.radio-label {
    display: flex;
    align-items: center;
    gap: 0.6rem;
    cursor: pointer;
    padding: 0.75rem 1.1rem;
    border: 2px solid #e2e8f0;
    border-radius: 12px;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    font-weight: 700;
    background: linear-gradient(180deg, #ffffff 0%, #f8fafc 100%);
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.04);
}

.radio-label:hover {
    border-color: var(--primary-light);
    background: linear-gradient(180deg, #f0f9ff 0%, #e0f2fe 100%);
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(59, 130, 246, 0.15);
}

.radio-label:has(input:checked) {
    border-color: var(--primary);
    background: linear-gradient(135deg, #dbeafe 0%, #bfdbfe 100%);
    box-shadow: 0 4px 12px rgba(59, 130, 246, 0.2);
}

.radio-label input[type="radio"] {
    accent-color: var(--primary);
    width: 20px;
    height: 20px;
}

.radio-label span {
    font-size: 1rem;
    color: var(--dark);
}

.installments-group {
    background: linear-gradient(145deg, #f8fafc 0%, #e0f2fe 100%);
    padding: 1.5rem;
    border-radius: 16px;
    border: 2px solid #bfdbfe;
    box-shadow: 0 4px 15px rgba(59, 130, 246, 0.08);
}

.installments-group > label:first-child {
    font-size: 1rem;
    color: var(--primary-dark);
    font-weight: 700;
    display: block;
    margin-bottom: 0.25rem;
}

.installment-buttons {
    display: flex;
    gap: 0.75rem;
    margin-top: 1rem;
}

.installment-btn {
    width: 60px;
    height: 60px;
    border: 3px solid #e2e8f0;
    background: linear-gradient(180deg, #ffffff 0%, #f1f5f9 100%);
    border-radius: 16px;
    font-size: 1.5rem;
    font-weight: 800;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    color: var(--primary-dark);
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.07), 0 1px 3px rgba(0, 0, 0, 0.06);
}

.installment-btn:hover {
    border-color: var(--primary-light);
    background: linear-gradient(180deg, #f0f9ff 0%, #e0f2fe 100%);
    transform: translateY(-3px) scale(1.05);
    box-shadow: 0 8px 25px rgba(74, 144, 217, 0.25);
    color: var(--primary);
}

.installment-btn.active {
    border-color: transparent;
    background: linear-gradient(135deg, #4a90d9 0%, #2563eb 100%);
    color: white;
    box-shadow: 0 8px 25px rgba(37, 99, 235, 0.4), inset 0 1px 0 rgba(255,255,255,0.2);
    transform: translateY(-2px) scale(1.05);
}

.installment-btn.active:hover {
    background: linear-gradient(135deg, #3b82f6 0%, #1d4ed8 100%);
    box-shadow: 0 10px 30px rgba(37, 99, 235, 0.5);
}

.installment-inputs {
    margin-top: 1.5rem;
    padding-top: 1.5rem;
    border-top: 2px dashed rgba(59, 130, 246, 0.3);
}

.installment-inputs > label {
    display: block;
    font-weight: 700;
    color: var(--primary-dark);
    font-size: 1rem;
    margin-bottom: 1rem;
}

.installment-fields {
    display: flex;
    flex-wrap: wrap;
    gap: 1rem;
}

.installment-field {
    display: flex;
    align-items: center;
    gap: 0.6rem;
    background: white;
    padding: 0.75rem 1rem;
    border-radius: 12px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.06);
    border: 1px solid #e2e8f0;
}

.installment-field label {
    font-size: 0.9rem;
    color: #64748b;
    font-weight: 700;
    white-space: nowrap;
}

.installment-amount-input {
    width: 110px;
    padding: 0.7rem 0.85rem;
    border: 2px solid #cbd5e1;
    border-radius: 10px;
    font-size: 1.1rem;
    text-align: center;
    font-weight: 700;
    color: var(--primary-dark);
    background: #f8fafc;
    transition: all 0.2s ease;
}

.installment-amount-input:focus {
    outline: none;
    border-color: var(--primary);
    background: white;
    box-shadow: 0 0 0 4px rgba(59, 130, 246, 0.15);
}

.installment-amount-input.input-error {
    border-color: var(--danger);
    background: #fef2f2;
    animation: shake 0.4s ease;
}

@keyframes shake {
    0%, 100% { transform: translateX(0); }
    20% { transform: translateX(-6px); }
    40% { transform: translateX(6px); }
    60% { transform: translateX(-4px); }
    80% { transform: translateX(4px); }
}

.installment-error {
    margin-top: 1.25rem;
    padding: 1rem 1.25rem;
    background: linear-gradient(135deg, #fef2f2 0%, #fee2e2 100%);
    color: #b91c1c;
    border-radius: 12px;
    font-size: 0.95rem;
    font-weight: 600;
    border-left: 4px solid #ef4444;
    box-shadow: 0 2px 10px rgba(239, 68, 68, 0.1);
}

.club-info {
    background: var(--light);
    padding: 0.6rem 0.9rem;
    border-radius: 8px;
    margin-bottom: 0.5rem;
    border-left: 3px solid var(--primary);
}

/* Buttons */
.btn {
    background: var(--gradient);
    color: white;
    border: none;
    padding: 0.75rem 1.5rem;
    font-size: 0.95rem;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.3s ease;
    text-decoration: none;
    display: inline-block;
    text-align: center;
    font-weight: 600;
}

.btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(74, 144, 217, 0.4);
}

.btn-secondary {
    background: var(--gray);
}

.btn-secondary:hover {
    background: var(--dark);
    box-shadow: 0 5px 15px rgba(100, 116, 139, 0.4);
}

.btn-danger {
    background: var(--danger);
}

.btn-danger:hover {
    background: #dc2626;
    box-shadow: 0 5px 15px rgba(239, 68, 68, 0.4);
}

.btn-small {
    padding: 0.4rem 0.85rem;
    font-size: 0.8rem;
}

/* Messages */
.message {
    padding: 0.9rem 1rem;
    border-radius: 8px;
    margin-bottom: 1rem;
    font-weight: 500;
    font-size: 0.9rem;
}

.message.success {
    background: #d1fae5;
    color: #065f46;
    border: 1px solid #a7f3d0;
}

.message.error {
    background: #fee2e2;
    color: #991b1b;
    border: 1px solid #fecaca;
}

.message.info {
    background: #dbeafe;
    color: #1e40af;
    border: 1px solid #bfdbfe;
}

/* Admin sections */
.events-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 1rem;
    margin-top: 2rem;
}

.events-header h2 {
    margin: 0;
    border: none;
}

.toggle-links {
    display: flex;
    gap: 0.5rem;
}

.event-actions {
    display: flex;
    gap: 0.5rem;
    margin-top: 1rem;
    padding-top: 1rem;
    border-top: 1px solid #d1e3f6;
}

/* Clubs admin */
.clubs-admin-list {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.club-admin-card {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    background: var(--light);
    padding: 1.25rem;
    border-radius: 10px;
    border: 1px solid #d1e3f6;
}

.club-admin-card.inactive {
    opacity: 0.5;
}

.club-admin-card h3 {
    margin: 0 0 0.4rem 0;
    color: var(--dark);
}

.club-description {
    color: var(--gray);
    font-size: 0.85rem;
    margin-bottom: 0.4rem;
}

.club-actions {
    display: flex;
    gap: 0.5rem;
    flex-wrap: wrap;
}

/* Users list */
.users-list {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.user-card {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    background: var(--light);
    padding: 1.25rem;
    border-radius: 10px;
    border: 1px solid #d1e3f6;
}

.user-card.compact {
    padding: 0.85rem;
    align-items: center;
}

.user-card.inactive {
    opacity: 0.5;
}

.user-card.member-inactive {
    opacity: 0.5;
    background: #f1f1f1;
}

.badge.inactive-badge {
    background: var(--gray);
    color: #fff;
}

.user-info h3 {
    margin: 0 0 0.2rem 0;
    color: var(--dark);
}

.user-fullname {
    color: var(--gray);
    font-size: 0.85rem;
    margin-bottom: 0.4rem;
}

.user-info {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0.15rem 0.4rem;
}

.user-last-activity {
    width: 100%;
    display: inline-flex;
    align-items: center;
    gap: 0.25rem;
    font-size: 0.78rem;
    color: var(--gray);
    cursor: default;
}

.user-clubs {
    margin-top: 0.4rem;
    display: flex;
    flex-wrap: wrap;
    gap: 0.25rem;
}

.club-tag {
    background: #d1e3f6;
    color: var(--dark);
    padding: 0.2rem 0.5rem;
    border-radius: 12px;
    font-size: 0.7rem;
    font-weight: 500;
}

.club-tag.admin-tag {
    background: #fef3c7;
    color: #92400e;
}

.club-tag.guide-tag {
    background: #d1fae5;
    color: #065f46;
}

.user-actions {
    display: flex;
    gap: 0.5rem;
    flex-wrap: wrap;
}

/* Club members section */
.club-members-section {
    margin-bottom: 1.5rem;
    padding: 1.25rem;
    background: var(--light);
    border-radius: 10px;
}

.club-members-section h3 {
    margin-top: 0;
    color: var(--primary-dark);
    padding-bottom: 0.4rem;
    border-bottom: 2px solid var(--primary-light);
}

.club-members-section .users-list {
    margin-top: 0.75rem;
}

/* Member stats */
.member-search {
    margin-bottom: 1rem;
}

.member-search-wrapper {
    position: relative;
    display: flex;
    align-items: center;
}

.member-search-icon {
    position: absolute;
    left: 12px;
    color: var(--gray);
    pointer-events: none;
}

.member-search-wrapper input {
    width: 100%;
    padding: 0.6rem 2.5rem 0.6rem 2.5rem;
    border: 2px solid #e2e8f0;
    border-radius: 10px;
    font-size: 0.95rem;
    transition: border-color 0.2s;
    box-sizing: border-box;
}

.member-search-wrapper input:focus {
    border-color: var(--primary);
    outline: none;
}

.member-search-clear {
    position: absolute;
    right: 8px;
    background: none;
    border: none;
    font-size: 1.3rem;
    color: var(--gray);
    cursor: pointer;
    width: 28px;
    height: 28px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    transition: all 0.15s;
}

.member-search-clear:hover {
    background: #e2e8f0;
    color: var(--dark);
}

.member-stats {
    display: flex;
    gap: 1rem;
    margin-bottom: 1rem;
    padding: 0.6rem 0;
    border-bottom: 1px solid #d1e3f6;
}

.member-stats .stat {
    font-size: 0.85rem;
    color: var(--gray);
}

.member-stats .stat strong {
    color: var(--dark);
}

.member-stats .stat-active strong {
    color: var(--success);
}

.member-stats .stat-inactive strong {
    color: var(--danger);
}

/* Filter form */
.filter-form {
    background: var(--light);
    padding: 1rem;
    border-radius: 10px;
    margin-bottom: 1rem;
}

.filter-row {
    display: grid;
    grid-template-columns: 1fr 1fr auto;
    gap: 1rem;
    align-items: end;
}

.filter-buttons {
    display: flex;
    flex-direction: row;
    gap: 0.5rem;
    align-items: center;
}

.filter-buttons .btn {
    white-space: nowrap;
}

.role-filter {
    display: flex;
    gap: 0.5rem;
    margin-bottom: 1rem;
    flex-wrap: wrap;
}

.role-filter-btn {
    background: rgba(255, 255, 255, 0.7);
    color: var(--dark);
}

.role-filter-btn.active {
    background: var(--gradient);
    color: var(--white);
    box-shadow: 0 3px 10px rgba(74, 144, 217, 0.35);
}

@media (max-width: 768px) {
    .filter-row {
        grid-template-columns: 1fr;
    }
}

/* Footer */
footer {
    position: relative;
    text-align: center;
    padding: 1.25rem;
    color: rgba(255, 255, 255, 0.9);
    margin-top: 2rem;
    font-weight: 500;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.75rem;
    flex-wrap: wrap;
}

/* Navbar / footer branding */
.site-brand {
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.site-brand-logo {
    height: 42px;
    width: auto;
    max-width: 120px;
    object-fit: contain;
    border-radius: 8px;
}

.brand-edit-btn {
    background: rgba(255, 255, 255, 0.25);
    border: 1px solid rgba(255, 255, 255, 0.4);
    color: #fff;
    border-radius: 8px;
    padding: 0.35rem;
    cursor: pointer;
    transition: all 0.2s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    line-height: 0;
}

.brand-edit-btn:hover {
    background: rgba(255, 255, 255, 0.4);
    transform: scale(1.1);
}

.form-hint {
    display: block;
    margin-top: 0.35rem;
    font-size: 0.8rem;
    color: var(--gray);
}

@media print {
    .brand-edit-btn {
        display: none !important;
    }
}

/* Event card link */
.event-card-link {
    text-decoration: none;
    color: inherit;
    display: block;
}

/* Event registration badges */
.event-registration-badge {
    position: absolute;
    top: 1rem;
    right: 6rem;
    width: 28px;
    height: 28px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1rem;
}

.event-registration-badge.status-pending {
    background: #fef3c7;
    color: #92400e;
}

.event-registration-badge.status-approved {
    background: #059669;
    color: #ffffff;
    box-shadow: 0 2px 4px rgba(5, 150, 105, 0.3);
}

.event-registration-badge.status-rejected {
    background: #fee2e2;
    color: #991b1b;
}

.event-registration-badge-text {
    position: absolute;
    top: 1rem;
    right: 6rem;
    padding: 0.25rem 0.75rem;
    border-radius: 15px;
    font-size: 0.75rem;
    font-weight: 600;
}

.event-registration-badge-text.status-pending {
    background: #f59e0b;
    color: #ffffff;
    box-shadow: 0 2px 4px rgba(245, 158, 11, 0.3);
}

.event-registration-badge-text.status-approved {
    background: #059669;
    color: #ffffff;
    box-shadow: 0 2px 4px rgba(5, 150, 105, 0.3);
}

.event-registration-badge-text.status-rejected {
    background: #dc2626;
    color: #ffffff;
    box-shadow: 0 2px 4px rgba(220, 38, 38, 0.3);
}

.event-paid-badge {
    position: absolute;
    top: 1rem;
    right: 9.5rem;
    width: 28px;
    height: 28px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1rem;
    background: #d1fae5;
    color: #065f46;
}

.event-paid-badge-text {
    position: absolute;
    top: 1rem;
    right: 12.5rem;
    background: #059669;
    color: #ffffff;
    padding: 0.25rem 0.75rem;
    border-radius: 15px;
    font-size: 0.75rem;
    font-weight: 600;
    box-shadow: 0 2px 4px rgba(5, 150, 105, 0.3);
}

.event-guide {
    color: var(--dark);
    font-size: 0.9rem;
    margin-bottom: 0.3rem;
    font-weight: 400;
}

/* Event price display */
.event-price {
    color: var(--dark);
    font-size: 0.9rem;
    margin-bottom: 0.3rem;
    font-weight: 400;
}

.event-price strong {
    font-weight: 600;
    color: var(--dark);
}

.event-price-value {
    color: var(--success);
    font-weight: 600;
}

.event-installments {
    font-size: 0.85rem;
    color: var(--gray);
    margin-top: 0.25rem;
}

.event-detail-price {
    font-size: 1rem;
    margin-bottom: 1rem;
    color: var(--dark);
}

.event-detail-price strong {
    color: var(--primary-dark);
}

.price-main {
    font-size: 1.2rem;
    font-weight: 700;
    color: var(--success);
}

.installments-detail {
    margin-top: 0.75rem;
    padding: 0.75rem;
    background: #f0f9ff;
    border-radius: 8px;
    border-left: 3px solid var(--primary);
}

.installments-detail-title {
    font-weight: 600;
    color: var(--primary-dark);
    margin-bottom: 0.5rem;
    font-size: 0.9rem;
}

.installments-list {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
}

.installment-item {
    background: white;
    padding: 0.4rem 0.75rem;
    border-radius: 6px;
    font-size: 0.85rem;
    border: 1px solid #d1e3f6;
}

.installment-item-number {
    color: var(--gray);
    font-weight: 500;
}

.installment-item-amount {
    color: var(--dark);
    font-weight: 600;
}

.installment-item-deadline {
    color: var(--gray);
    font-size: 0.8rem;
    font-style: italic;
}

.event-detail-info-box {
    margin-top: 1rem;
    padding: 0.75rem;
    background: #f0f9ff;
    border-radius: 8px;
    border-left: 3px solid var(--primary);
    font-size: 0.95rem;
    color: var(--dark);
}

.event-detail-info-box strong {
    color: var(--primary-dark);
    font-weight: 600;
}

.event-detail-info-box p {
    margin: 0.25rem 0 0 0;
    color: var(--dark);
}

/* Back link */
.back-link {
    display: inline-block;
    color: var(--primary);
    text-decoration: none;
    margin-bottom: 1.5rem;
    font-weight: 500;
    transition: color 0.3s ease;
}

.back-link:hover {
    color: var(--primary-dark);
}

/* Event detail page */
.event-detail {
    background: var(--light);
    border-radius: 12px;
    padding: 1.5rem;
    border: 1px solid #d1e3f6;
}

.event-detail-header {
    display: flex;
    flex-direction: row;
    justify-content: space-between;
    align-items: flex-start;
    flex-wrap: wrap;
    gap: 0.5rem;
    margin-bottom: 1.5rem;
    padding-bottom: 1rem;
    border-bottom: 2px solid #d1e3f6;
}

.event-detail-header h2 {
    margin: 0;
    border: none;
    padding: 0;
}

.event-detail-header .event-club-badge {
    position: static;
}

.event-detail-header .event-badges-row {
    position: static;
    margin-bottom: 0.5rem;
}

.event-detail-info {
    margin-bottom: 1.5rem;
}

.event-detail-date {
    display: flex;
    align-items: center;
    gap: 0.6rem;
    margin-bottom: 1rem;
    background: linear-gradient(135deg, #dbeafe 0%, #e0e7ff 100%);
    padding: 0.75rem 1rem;
    border-radius: 10px;
    border-left: 4px solid var(--primary);
}

.event-detail-date svg {
    color: var(--primary);
    flex-shrink: 0;
}

.event-date-text {
    display: flex;
    align-items: baseline;
    gap: 0.5rem;
}

.event-date-value {
    font-size: 1.25rem;
    font-weight: 700;
    color: var(--primary-dark);
}

.event-time-value {
    font-size: 1.25rem;
    font-weight: 700;
    color: var(--primary-dark);
}

.event-detail-guide,
.event-detail-deadline {
    font-size: 1rem;
    margin-bottom: 1rem;
    color: var(--dark);
}

.event-detail-guide strong,
.event-detail-deadline strong {
    color: var(--primary-dark);
}

.event-detail-deadline.deadline-urgent {
    color: #dc2626;
}

.event-detail-deadline.deadline-urgent strong {
    color: #dc2626;
}

.event-detail.payment-urgent {
    border-color: #dc2626;
    background: linear-gradient(to right, #fee2e2 0%, var(--light) 100%);
}

.event-detail-section {
    margin-top: 1.5rem;
    padding-top: 1rem;
    border-top: 1px solid #e5e7eb;
    font-size: 1rem;
    color: var(--dark);
    line-height: 1.7;
}

.event-detail-section strong {
    display: block;
    color: var(--primary-dark);
    margin-bottom: 0.5rem;
}

.event-detail-section p {
    margin: 0;
    color: var(--gray);
}

.event-detail-max-members {
    margin-top: 1.5rem;
    padding-top: 1rem;
    border-top: 1px solid #e5e7eb;
    font-size: 1rem;
    color: var(--dark);
}

.event-detail-max-members strong {
    color: var(--primary-dark);
}

.event-detail-description {
    margin-top: 1.5rem;
    padding-top: 1rem;
    border-top: 1px solid #e5e7eb;
    color: var(--gray);
    line-height: 1.7;
}

.event-detail-description strong {
    display: block;
    color: var(--primary-dark);
    margin-bottom: 0.5rem;
}

/* Event requirements section */
.event-requirements-section {
    margin-top: 1.5rem;
    padding-top: 1rem;
    border-top: 1px solid #e5e7eb;
}

.event-requirements-section strong {
    display: block;
    color: var(--primary-dark);
    margin-bottom: 0.5rem;
}

/* Event duration */
.event-duration {
    margin-top: 0.75rem;
    color: var(--gray);
}

.event-duration strong {
    color: var(--primary-dark);
}

/* Daily descriptions */
.event-daily-descriptions {
    margin-top: 1.5rem;
    padding-top: 1rem;
    border-top: 1px solid #e5e7eb;
}

.event-daily-descriptions strong {
    display: block;
    color: var(--primary-dark);
    margin-bottom: 0.75rem;
}

.daily-description-item {
    background: var(--light);
    padding: 0.75rem;
    border-radius: 6px;
    margin-bottom: 0.5rem;
    border-left: 3px solid var(--primary);
}

.daily-description-date {
    font-weight: 600;
    color: var(--primary-dark);
    font-size: 0.9rem;
    margin-bottom: 0.25rem;
}

.daily-description-item p {
    margin: 0;
    color: var(--gray);
    font-size: 0.9rem;
}

/* Event registration section */
.event-registration-section {
    background: #fff;
    padding: 1.25rem;
    border-radius: 10px;
    border: 1px solid #d1e3f6;
    margin-top: 1.5rem;
}

.event-registration-section h3 {
    margin-top: 0;
    margin-bottom: 1rem;
    color: var(--primary-dark);
}

.event-registration-section p {
    margin-bottom: 1rem;
}

.registration-status {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 1rem;
    border-radius: 8px;
    margin-bottom: 1rem;
}

.registration-status.status-pending {
    background: #fef3c7;
    color: #92400e;
}

.registration-status.status-approved {
    background: #d1fae5;
    color: #065f46;
}

.registration-status.status-rejected {
    background: #fee2e2;
    color: #991b1b;
}

.registration-status .status-icon {
    font-size: 1.5rem;
}

.registration-status .status-text {
    font-weight: 600;
}

.registration-amount {
    background: #dbeafe;
    color: #1e40af;
    padding: 0.75rem 1rem;
    border-radius: 8px;
    margin-bottom: 1rem;
    font-weight: 500;
}

/* Admin registrations page */
.registrations-section {
    margin-bottom: 2rem;
}

.registrations-section h3 {
    margin-top: 0;
    padding-bottom: 0.5rem;
    border-bottom: 2px solid var(--primary-light);
}

.registrations-list {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
    margin-top: 1rem;
}

.registration-card {
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: var(--light);
    padding: 1rem 1.25rem;
    border-radius: 10px;
    border: 1px solid #d1e3f6;
    flex-wrap: wrap;
    gap: 1rem;
}

.registration-info {
    flex: 1;
    min-width: 200px;
}

.registration-info strong {
    color: var(--dark);
    display: block;
    margin-bottom: 0.25rem;
}

.registration-info .meta {
    font-size: 0.85rem;
    color: var(--dark);
    display: flex;
    flex-direction: column;
    gap: 0.2rem;
}

.registration-info .meta span {
    display: block;
}

.registration-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    width: 100%;
    gap: 1rem;
}

.registration-header strong {
    color: var(--dark);
}

.reject-form-header {
    flex-shrink: 0;
}

.registration-card:has(.registration-header) .registration-info {
    width: 100%;
}

.registration-card:has(.registration-header) .registration-actions {
    width: 100%;
}

.registration-actions {
    display: flex;
    gap: 0.5rem;
    align-items: center;
    flex-wrap: wrap;
}

.registration-actions > form:not(.installment-form) {
    display: inline-flex;
}

.registration-actions form {
    display: flex;
    gap: 0.5rem;
    align-items: center;
}

.registration-card.registration-paid {
    border-color: #059669;
    background: linear-gradient(to right, #a7f3d0 0%, var(--light) 100%);
}

.registration-card.registration-urgent {
    border-color: #dc2626;
    background: linear-gradient(to right, #fee2e2 0%, var(--light) 100%);
    animation: pulse-urgent 2s infinite;
}

.deadline-urgent {
    color: #dc2626 !important;
    font-weight: 600;
}

.paid-badge {
    display: inline-block;
    background: #059669;
    color: #ffffff;
    padding: 0.2rem 0.6rem;
    border-radius: 12px;
    font-size: 0.75rem;
    font-weight: 600;
    margin-left: 0.25rem;
}

.amount-input {
    width: 100px;
    padding: 0.4rem 0.6rem;
    border: 2px solid #d1e3f6;
    border-radius: 6px;
    font-size: 0.85rem;
}

.amount-input:focus {
    outline: none;
    border-color: var(--primary);
}

.visibility-checkbox {
    display: flex;
    align-items: center;
    gap: 0.3rem;
    font-size: 0.8rem;
    color: var(--gray);
}

.btn-success {
    background: var(--success);
}

.btn-success:hover {
    background: #059669;
    box-shadow: 0 5px 15px rgba(16, 185, 129, 0.4);
}

.btn-accent {
    background: linear-gradient(135deg, #f59e0b 0%, #d97706 100%);
}

.btn-accent:hover {
    background: linear-gradient(135deg, #d97706 0%, #b45309 100%);
    box-shadow: 0 5px 15px rgba(245, 158, 11, 0.4);
}

.btn-info {
    background: linear-gradient(135deg, #8b5cf6 0%, #7c3aed 100%);
}

.btn-info:hover {
    background: linear-gradient(135deg, #7c3aed 0%, #6d28d9 100%);
    box-shadow: 0 5px 15px rgba(139, 92, 246, 0.4);
}

/* Page header with toggle */
.page-header-with-toggle {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 1rem;
    margin-bottom: 1.5rem;
}

.super-admin-actions {
    display: flex;
    gap: 0.5rem;
    margin-bottom: 1rem;
    flex-wrap: wrap;
}

.super-admin-actions .btn {
    font-size: 0.8rem;
    padding: 0.4rem 0.8rem;
}

.page-header-with-toggle h2 {
    margin: 0;
    border: none;
    padding: 0;
}

.history-badge {
    display: inline-block;
    background: var(--accent);
    color: white;
    padding: 0.15rem 0.5rem;
    border-radius: 10px;
    font-size: 0.75rem;
    margin-left: 0.3rem;
    vertical-align: middle;
}

/* Installment payment buttons */
.installment-payment-buttons {
    display: flex;
    flex-wrap: wrap;
    gap: 0.6rem;
    align-items: center;
}

.installment-form {
    display: inline-block;
}

.btn-installment {
    background: linear-gradient(135deg, #3b82f6 0%, #1d4ed8 100%);
    color: white;
    border: none;
    padding: 0.75rem 1.25rem;
    font-size: 1rem;
    border-radius: 12px;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    font-weight: 700;
    box-shadow: 0 4px 15px rgba(59, 130, 246, 0.35), inset 0 1px 0 rgba(255,255,255,0.15);
    min-width: 100px;
    text-align: center;
    letter-spacing: 0.3px;
}

.btn-installment:hover {
    background: linear-gradient(135deg, #2563eb 0%, #1e40af 100%);
    transform: translateY(-3px) scale(1.02);
    box-shadow: 0 8px 25px rgba(59, 130, 246, 0.45);
}

.btn-installment:active {
    transform: translateY(-1px) scale(1.01);
}

.btn-installment-paid {
    background: linear-gradient(135deg, #10b981 0%, #059669 100%);
    color: white;
    border: none;
    padding: 0.75rem 1.25rem;
    font-size: 1rem;
    border-radius: 12px;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    font-weight: 700;
    box-shadow: 0 4px 15px rgba(16, 185, 129, 0.4), inset 0 1px 0 rgba(255,255,255,0.15);
    min-width: 100px;
    text-align: center;
    letter-spacing: 0.3px;
}

.btn-installment-paid:hover {
    background: linear-gradient(135deg, #059669 0%, #047857 100%);
    transform: translateY(-3px) scale(1.02);
    box-shadow: 0 8px 25px rgba(16, 185, 129, 0.5);
}

.btn-installment-paid:active {
    transform: translateY(-1px) scale(1.01);
}

.paid-check {
    margin-left: 0.4rem;
    font-weight: bold;
    font-size: 1.1rem;
}

.no-price {
    color: var(--gray);
    font-style: italic;
    font-size: 0.9rem;
    padding: 0.5rem 0;
    background: #f8fafc;
    border-radius: 8px;
    padding: 0.5rem 1rem;
}

/* Payment History Styles */
.payment-stats {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
    gap: 1rem;
    margin-bottom: 2rem;
}

.payment-stat {
    background: white;
    padding: 1.25rem;
    border-radius: 12px;
    text-align: center;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.06);
    border-left: 4px solid var(--gray);
}

.payment-stat-total {
    border-left-color: var(--primary);
}

.payment-stat-income {
    border-left-color: var(--success);
}

.payment-stat-refund {
    border-left-color: var(--danger);
}

.payment-stat-net {
    border-left-color: var(--accent);
}

.payment-stat .stat-label {
    display: block;
    font-size: 0.85rem;
    color: var(--gray);
    margin-bottom: 0.5rem;
    font-weight: 500;
}

.payment-stat .stat-value {
    display: block;
    font-size: 1.4rem;
    font-weight: 700;
    color: var(--dark);
}

.payment-history-list {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.payment-history-card {
    display: flex;
    gap: 1rem;
    background: white;
    padding: 1rem 1.25rem;
    border-radius: 12px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
    border-left: 4px solid var(--success);
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.payment-history-card:hover {
    transform: translateX(4px);
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.08);
}

.payment-history-card.payment-refund {
    border-left-color: var(--danger);
    background: linear-gradient(90deg, #fef2f2 0%, white 100%);
}

.payment-history-card.payment-income {
    border-left-color: var(--success);
    background: linear-gradient(90deg, #f0fdf4 0%, white 100%);
}

.payment-history-icon {
    width: 48px;
    height: 48px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    flex-shrink: 0;
}

.payment-income .payment-history-icon {
    background: linear-gradient(135deg, #d1fae5 0%, #a7f3d0 100%);
}

.payment-refund .payment-history-icon {
    background: linear-gradient(135deg, #fee2e2 0%, #fecaca 100%);
}

.payment-history-info {
    flex: 1;
    min-width: 0;
}

.payment-history-main {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 1rem;
    margin-bottom: 0.5rem;
}

.payment-user {
    font-size: 1rem;
    color: var(--dark);
}

.payment-amount {
    font-size: 1.1rem;
    font-weight: 700;
    white-space: nowrap;
}

.amount-income {
    color: var(--success);
}

.amount-refund {
    color: var(--danger);
}

.payment-history-details {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem 1rem;
    margin-bottom: 0.5rem;
    font-size: 0.9rem;
}

.payment-event {
    color: var(--primary-dark);
    font-weight: 600;
}

.payment-installment {
    color: var(--gray);
    background: #f1f5f9;
    padding: 0.15rem 0.5rem;
    border-radius: 4px;
    font-size: 0.8rem;
}

.payment-club {
    color: var(--gray);
}

.payment-history-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem 1.5rem;
    font-size: 0.8rem;
    color: var(--gray);
}

.payment-admin {
    font-style: italic;
}

.payment-time {
    color: #94a3b8;
}

@media (max-width: 600px) {
    .payment-history-card {
        flex-direction: column;
        gap: 0.75rem;
    }

    .payment-history-icon {
        width: 40px;
        height: 40px;
        font-size: 1.2rem;
    }

    .payment-history-main {
        flex-direction: column;
        align-items: flex-start;
        gap: 0.25rem;
    }
}

/* Payment Summary Cards */
.payment-summary-cards {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 1rem;
    margin-bottom: 2rem;
}

.summary-card {
    display: flex;
    align-items: center;
    gap: 1rem;
    padding: 1.25rem;
    background: white;
    border-radius: 12px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
}

.summary-card-icon {
    width: 48px;
    height: 48px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.summary-card-positive .summary-card-icon {
    background: #d1fae5;
    color: #059669;
}

.summary-card-negative .summary-card-icon {
    background: #fee2e2;
    color: #dc2626;
}

.summary-card-total .summary-card-icon {
    background: #dbeafe;
    color: #2563eb;
}

.summary-card-content {
    display: flex;
    flex-direction: column;
}

.summary-card-label {
    font-size: 0.85rem;
    color: var(--gray);
    margin-bottom: 0.25rem;
}

.summary-card-value {
    font-size: 1.25rem;
    font-weight: 700;
    color: var(--dark);
}

/* Payment Table View */
.payment-history-table {
    background: white;
    border-radius: 12px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
    overflow: hidden;
}

.payment-table-header {
    display: grid;
    grid-template-columns: 1.5fr 1.5fr 0.8fr 1fr 1fr 1fr;
    gap: 0.5rem;
    padding: 1rem 1.25rem;
    background: #f8fafc;
    font-weight: 600;
    font-size: 0.85rem;
    color: var(--gray);
    border-bottom: 1px solid #e2e8f0;
}

.payment-table-row {
    display: grid;
    grid-template-columns: 1.5fr 1.5fr 0.8fr 1fr 1fr 1fr;
    gap: 0.5rem;
    padding: 1rem 1.25rem;
    border-bottom: 1px solid #f1f5f9;
    align-items: center;
    transition: background 0.2s ease;
}

.payment-table-row:last-child {
    border-bottom: none;
}

.payment-table-row:hover {
    background: #f8fafc;
}

.payment-table-row.row-positive {
    border-left: 3px solid var(--success);
}

.payment-table-row.row-negative {
    border-left: 3px solid var(--danger);
    background: #fef2f2;
}

.payment-table-row.row-negative:hover {
    background: #fee2e2;
}

.col-user strong {
    color: var(--dark);
}

.col-event {
    color: var(--primary-dark);
    font-size: 0.9rem;
}

.col-date {
    font-size: 0.85rem;
    color: var(--gray);
}

.col-admin {
    font-size: 0.85rem;
    color: var(--gray);
}

.installment-badge {
    display: inline-block;
    background: #e0f2fe;
    color: #0369a1;
    padding: 0.2rem 0.5rem;
    border-radius: 4px;
    font-size: 0.8rem;
    font-weight: 500;
}

.col-amount {
    font-weight: 700;
    text-align: right;
}

.col-amount.amount-positive {
    color: var(--success);
}

.col-amount.amount-negative {
    color: var(--danger);
}

/* Empty State */
.empty-state {
    text-align: center;
    padding: 3rem 1rem;
    color: var(--gray);
}

.empty-state svg {
    margin-bottom: 1rem;
    opacity: 0.5;
}

.empty-state p {
    font-size: 1.1rem;
}

@media (max-width: 900px) {
    .payment-table-header {
        display: none;
    }

    .payment-table-row {
        display: flex;
        flex-direction: column;
        gap: 0.5rem;
        padding: 1rem;
    }

    .payment-table-row .col-amount {
        text-align: left;
        font-size: 1.1rem;
    }
}

/* User Payment Status on Event Page */
.user-payment-status {
    margin-top: 1.5rem;
    padding: 1.25rem;
    background: linear-gradient(135deg, #f0fdf4 0%, #dcfce7 100%);
    border-radius: 12px;
    border: 2px solid #86efac;
}

.user-payment-status h4 {
    margin: 0 0 1rem 0;
    color: #166534;
    font-size: 1rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.user-payment-status h4::before {
    content: '💰';
}

.payment-complete {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 1rem;
    background: linear-gradient(135deg, #10b981 0%, #059669 100%);
    border-radius: 10px;
    color: white;
}

.payment-complete-icon {
    width: 36px;
    height: 36px;
    background: rgba(255,255,255,0.2);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.25rem;
    font-weight: bold;
}

.payment-complete-text {
    flex: 1;
    font-weight: 600;
    font-size: 1rem;
}

.payment-complete-amount {
    font-size: 1.2rem;
    font-weight: 700;
}

.payment-progress {
    padding: 1rem;
    background: white;
    border-radius: 10px;
    border: 1px solid #d1fae5;
}

.payment-progress-text {
    margin-bottom: 0.75rem;
    color: var(--dark);
    font-size: 0.95rem;
}

.payment-progress-text strong {
    color: var(--success);
    font-size: 1.1rem;
}

.payment-progress-bar {
    height: 12px;
    background: #e2e8f0;
    border-radius: 6px;
    overflow: hidden;
}

.payment-progress-fill {
    height: 100%;
    background: linear-gradient(90deg, #10b981 0%, #34d399 100%);
    border-radius: 6px;
    transition: width 0.5s ease;
}

.installments-status {
    margin-top: 1rem;
}

.installments-status-title {
    font-weight: 600;
    color: #166534;
    margin-bottom: 0.75rem;
    font-size: 0.9rem;
}

.installments-status-list {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
}

.installment-status-item {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.6rem 1rem;
    border-radius: 10px;
    font-size: 0.9rem;
    transition: all 0.2s ease;
}

.installment-status-item.installment-paid {
    background: linear-gradient(135deg, #10b981 0%, #059669 100%);
    color: white;
    box-shadow: 0 2px 8px rgba(16, 185, 129, 0.3);
}

.installment-status-item.installment-unpaid {
    background: white;
    color: var(--dark);
    border: 2px solid #e2e8f0;
}

.installment-status-num {
    font-weight: 600;
}

.installment-status-amount {
    font-weight: 700;
}

.installment-status-icon {
    font-weight: bold;
    font-size: 1rem;
}

.installment-paid .installment-status-icon {
    color: white;
}

.installment-unpaid .installment-status-icon {
    color: #cbd5e1;
}

.installment-status-deadline {
    font-size: 0.8rem;
    color: var(--gray);
    font-style: italic;
}

.installment-status-deadline.deadline-urgent {
    color: white;
    font-weight: 600;
    font-style: normal;
}

.installment-deadline-urgent.installment-unpaid {
    border-color: var(--danger);
    background: #fef2f2;
}

.installment-deadline-urgent .installment-status-deadline {
    color: var(--danger);
    font-weight: 600;
    font-style: normal;
}

/* Logs page */
.logs-list {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.log-entry {
    background: var(--light);
    padding: 0.75rem 1rem;
    border-radius: 8px;
    border-left: 4px solid var(--primary);
    font-size: 0.9rem;
}

.log-entry .log-time {
    color: var(--gray);
    font-size: 0.8rem;
    margin-bottom: 0.25rem;
}

.log-entry .log-action {
    color: var(--dark);
}

.log-entry .log-action strong {
    color: var(--primary-dark);
}

.log-entry.action-approved {
    border-left-color: var(--success);
}

.log-entry.action-rejected {
    border-left-color: var(--danger);
}

.log-entry.action-amount {
    border-left-color: var(--accent);
}

.log-entry.action-payment {
    border-left-color: #10b981;
}

.log-entry.action-status {
    border-left-color: var(--primary);
}

.log-paid {
    color: #059669;
    font-weight: 600;
    background: #d1fae5;
    padding: 0.1rem 0.4rem;
    border-radius: 4px;
}

.log-refund {
    color: #dc2626;
    font-weight: 600;
    background: #fee2e2;
    padding: 0.1rem 0.4rem;
    border-radius: 4px;
}

/* Custom Modal Dialog */
.modal-overlay {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    backdrop-filter: blur(4px);
    z-index: 1000;
    justify-content: center;
    align-items: center;
}

.modal-overlay.active {
    display: flex;
}

.modal-dialog {
    background: white;
    border-radius: 16px;
    padding: 2rem;
    max-width: 400px;
    width: 90%;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
    text-align: center;
    animation: modalSlideIn 0.3s ease;
}

@keyframes modalSlideIn {
    from {
        opacity: 0;
        transform: scale(0.9) translateY(-20px);
    }
    to {
        opacity: 1;
        transform: scale(1) translateY(0);
    }
}

.modal-icon {
    width: 60px;
    height: 60px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 1.5rem;
    font-size: 1.8rem;
}

.modal-icon.confirm {
    background: #dbeafe;
    color: var(--primary);
}

.modal-icon.warning {
    background: #fef3c7;
    color: #d97706;
}

.modal-icon.danger {
    background: #fee2e2;
    color: var(--danger);
}

.modal-dialog h3 {
    color: var(--dark);
    margin-bottom: 0.75rem;
    font-size: 1.25rem;
}

.modal-dialog p {
    color: var(--gray);
    margin-bottom: 1.5rem;
    line-height: 1.6;
}

.modal-buttons {
    display: flex;
    gap: 0.75rem;
    justify-content: center;
}

.modal-buttons .btn {
    min-width: 100px;
}

/* Large modal for forms */
.modal-large {
    max-width: 600px;
    width: 95%;
    max-height: 90vh;
    overflow-y: auto;
}

.modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1.5rem;
    padding-bottom: 1rem;
    border-bottom: 1px solid #e2e8f0;
}

.modal-header-danger {
    border-bottom-color: var(--danger);
}

.modal-header-danger h3 {
    color: var(--danger);
}

.modal-small {
    max-width: 400px;
    width: 90%;
}

.modal-body {
    text-align: center;
    padding: 1rem 0;
}

.delete-icon {
    color: var(--danger);
    margin-bottom: 1rem;
}

.delete-event-title {
    font-weight: 600;
    color: var(--dark) !important;
    font-size: 1.1rem;
    margin: 0.5rem 0 !important;
}

.delete-warning {
    font-size: 0.85rem;
    color: var(--gray) !important;
    margin-top: 1rem !important;
}

/* Icon Buttons */
.btn-icon {
    width: 36px;
    height: 36px;
    border-radius: 8px;
    border: none;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s ease;
}

.btn-edit {
    background: #e0f2fe;
    color: #0284c7;
}

.btn-edit:hover {
    background: #0284c7;
    color: white;
}

.btn-delete {
    background: #fee2e2;
    color: #dc2626;
}

.btn-delete:hover {
    background: #dc2626;
    color: white;
}

/* Action Buttons with Text and Icon */
.btn-action {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    padding: 0.5rem 0.85rem;
    border-radius: 8px;
    border: none;
    cursor: pointer;
    font-size: 0.85rem;
    font-weight: 500;
    transition: all 0.2s ease;
}

.btn-action svg {
    flex-shrink: 0;
}

.btn-action-edit {
    background: #e0f2fe;
    color: #0369a1;
}

.btn-action-edit:hover {
    background: #0284c7;
    color: white;
}

.btn-action-delete {
    background: #fee2e2;
    color: #b91c1c;
}

.btn-action-delete:hover {
    background: #dc2626;
    color: white;
}

.btn-action-reject {
    background: #fef3c7;
    color: #92400e;
}

.btn-action-reject:hover {
    background: #f59e0b;
    color: white;
}

.btn-action-view {
    background: #f0fdf4;
    color: #15803d;
    text-decoration: none;
}

.btn-action-view:hover {
    background: #16a34a;
    color: white;
}

.event-actions {
    display: flex;
    gap: 0.5rem;
    flex-wrap: wrap;
}

.modal-header h3 {
    margin: 0;
}

.modal-close {
    background: none;
    border: none;
    font-size: 1.75rem;
    color: var(--gray);
    cursor: pointer;
    padding: 0;
    line-height: 1;
    transition: color 0.2s;
}

.modal-close:hover {
    color: var(--dark);
}

.modal-form .form-group {
    margin-bottom: 1rem;
}

.modal-form .form-row {
    display: flex;
    gap: 1rem;
}

.modal-form .form-row .form-group {
    flex: 1;
}

.modal-form label {
    display: block;
    margin-bottom: 0.25rem;
    font-weight: 500;
    color: var(--dark);
    font-size: 0.9rem;
}

.modal-form input,
.modal-form select {
    width: 100%;
    max-width: 100%;
    padding: 0.5rem 0.75rem;
    border: 2px solid #d1e3f6;
    border-radius: 8px;
    font-size: 0.95rem;
    background: var(--white);
    transition: border-color 0.2s, box-shadow 0.2s;
}

.modal-form input:focus,
.modal-form select:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.1);
}

.modal-form small {
    display: block;
    color: var(--gray);
    font-size: 0.8rem;
    margin-top: 0.25rem;
}

.modal-form .clubs-checkboxes {
    background: var(--light);
    padding: 0.75rem;
    border-radius: 8px;
}

.modal-form .modal-buttons {
    margin-top: 1.5rem;
    padding-top: 1rem;
    border-top: 1px solid #e2e8f0;
    justify-content: flex-end;
}

@media (max-width: 600px) {
    .modal-large {
        padding: 1.25rem;
    }

    .modal-form .form-row {
        flex-direction: column;
        gap: 0;
    }
}

/* Event participants section */
.event-participants-section {
    margin-top: 2rem;
    padding-top: 1.5rem;
    border-top: 1px solid #e2e8f0;
}

.event-participants-section h3 {
    color: var(--dark);
    margin-bottom: 1rem;
    font-size: 1.1rem;
}

.participants-stats {
    display: flex;
    flex-wrap: wrap;
    gap: 1.5rem;
    margin-bottom: 1rem;
    padding: 0.75rem 1rem;
    background: var(--light);
    border-radius: 8px;
}

.stat-item {
    color: var(--dark);
    font-size: 0.9rem;
}

.stat-item strong {
    color: var(--primary-dark);
}

.no-participants {
    color: var(--gray);
    font-style: italic;
    padding: 1rem 0;
}

.participants-list {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.participant-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0.75rem 1rem;
    border-radius: 8px;
    background: #f8fafc;
    border-left: 3px solid var(--gray);
}

.participant-item.participant-paid {
    background: linear-gradient(90deg, #dcfce7 0%, #f8fafc 100%);
    border-left-color: var(--success);
}

.participant-item.participant-unpaid {
    background: linear-gradient(90deg, #fee2e2 0%, #f8fafc 100%);
    border-left-color: var(--danger);
}

.participant-info {
    display: flex;
    flex-direction: column;
    gap: 0.25rem;
}

.participant-name {
    font-weight: 500;
    color: var(--dark);
}

.driver-badge {
    display: inline-block;
    margin-left: 0.25rem;
    cursor: help;
}

.btn-driver-toggle {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 24px;
    height: 24px;
    border: 1px solid var(--gray);
    border-radius: 4px;
    background: var(--light);
    color: var(--gray);
    cursor: pointer;
    padding: 0;
    margin-left: 0.25rem;
    vertical-align: middle;
    transition: all 0.2s;
}

.btn-driver-toggle:hover {
    border-color: var(--primary);
    color: var(--primary);
    background: #e8f4f8;
}

.btn-driver-toggle.active {
    border-color: var(--success);
    color: var(--success);
    background: #e8f8e8;
}

.btn-driver-toggle.active:hover {
    border-color: var(--danger);
    color: var(--danger);
    background: #f8e8e8;
}

.registration-option {
    background: var(--light);
    padding: 0.75rem;
    border-radius: 6px;
    margin-bottom: 1rem;
}

.registration-option .checkbox-label {
    color: var(--dark);
}

.participant-phone {
    font-size: 0.85rem;
    color: var(--gray);
}

.participant-status .badge-paid {
    background: var(--success);
    color: white;
    padding: 0.25rem 0.75rem;
    border-radius: 12px;
    font-size: 0.8rem;
    font-weight: 500;
}

.participant-status .badge-unpaid {
    background: #fecaca;
    color: #991b1b;
    padding: 0.25rem 0.75rem;
    border-radius: 12px;
    font-size: 0.8rem;
    font-weight: 500;
}

.participant-payment-info {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.participant-payment-info .badge-paid {
    background: var(--success);
    color: white;
    padding: 0.25rem 0.75rem;
    border-radius: 12px;
    font-size: 0.8rem;
    font-weight: 500;
}

.participant-payment-info .badge-unpaid {
    background: #fecaca;
    color: #991b1b;
    padding: 0.25rem 0.75rem;
    border-radius: 12px;
    font-size: 0.8rem;
    font-weight: 500;
}

.participant-payment-info .badge-installments {
    background: #fef3c7;
    color: #92400e;
    padding: 0.25rem 0.75rem;
    border-radius: 12px;
    font-size: 0.8rem;
    font-weight: 500;
}

/* Enhanced Payment Display */
.payment-badge {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    padding: 0.4rem 0.75rem;
    border-radius: 8px;
    font-size: 0.85rem;
    font-weight: 600;
}

.payment-badge svg {
    flex-shrink: 0;
}

.payment-badge-full {
    background: linear-gradient(135deg, #d1fae5 0%, #a7f3d0 100%);
    color: #065f46;
}

.payment-badge-unpaid {
    background: linear-gradient(135deg, #fee2e2 0%, #fecaca 100%);
    color: #991b1b;
}

.payment-badge-ok {
    background: linear-gradient(135deg, #dbeafe 0%, #bfdbfe 100%);
    color: #1e40af;
}

/* Compact Payment Progress */
.payment-progress-compact {
    display: flex;
    flex-direction: column;
    gap: 0.4rem;
    min-width: 180px;
}

.payment-progress-stats {
    display: flex;
    justify-content: space-between;
    gap: 1rem;
    font-size: 0.85rem;
}

.payment-installment-count {
    color: #6b7280;
}

.payment-installment-count strong {
    color: var(--primary);
    font-size: 1rem;
}

.payment-amount-display {
    color: #6b7280;
}

.payment-amount-display strong {
    color: #059669;
    font-size: 1rem;
}

.payment-progress-bar-mini {
    height: 6px;
    background: #e5e7eb;
    border-radius: 3px;
    overflow: hidden;
}

.payment-progress-fill-mini {
    height: 100%;
    background: linear-gradient(90deg, #10b981 0%, #059669 100%);
    border-radius: 3px;
    transition: width 0.3s ease;
}

@media (max-width: 600px) {
    .participant-item {
        flex-direction: column;
        align-items: flex-start;
        gap: 0.5rem;
    }

    .participant-payment-info {
        width: 100%;
    }

    .payment-progress-compact {
        min-width: 0;
        width: 100%;
    }

    .event-detail-header {
        flex-direction: column;
    }

    .event-detail-header .event-badges-row {
        align-self: flex-end;
        order: -1;
    }
}

/* Back Button */
.back-button {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.6rem 1rem;
    background: white;
    color: var(--primary);
    text-decoration: none;
    border-radius: 8px;
    font-weight: 500;
    font-size: 0.95rem;
    border: 2px solid var(--primary);
    margin-bottom: 1.5rem;
    transition: all 0.2s ease;
}

.back-button:hover {
    background: var(--primary);
    color: white;
}

.back-button svg {
    transition: transform 0.2s ease;
}

.back-button:hover svg {
    transform: translateX(-3px);
}

/* ==================== NEWS STYLES ==================== */

.news-list {
    display: flex;
    flex-direction: column;
    gap: 1rem;
    margin-top: 1rem;
}

.news-card {
    background: var(--white);
    border-radius: 12px;
    border-left: 4px solid var(--primary);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
    padding: 1.25rem;
    transition: all 0.3s ease;
}

.news-card:hover {
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.12);
    transform: translateY(-2px);
}

.news-card.news-expired {
    border-left-color: var(--gray);
    background: #f8fafc;
    opacity: 0.8;
}

.news-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 1rem;
    margin-bottom: 0.75rem;
}

.news-header h3 {
    margin: 0;
    font-size: 1.1rem;
    color: var(--dark);
}

.news-badges {
    display: flex;
    gap: 0.5rem;
    flex-shrink: 0;
}

.news-badges .badge {
    font-size: 0.7rem;
    padding: 0.2rem 0.5rem;
    border-radius: 4px;
    font-weight: 600;
}

.news-badges .public-badge {
    background: var(--accent);
    color: white;
}

.news-badges .expired-badge {
    background: var(--gray);
    color: white;
}

.news-image {
    margin-bottom: 0.75rem;
}

.news-image a {
    display: inline-block;
}

.news-image img {
    max-height: 160px;
    width: auto;
    border-radius: 8px;
    display: block;
    object-fit: cover;
    cursor: pointer;
    transition: opacity 0.2s;
}

.news-image img:hover {
    opacity: 0.85;
}

.news-body-left,
.news-body-right {
    display: flex;
    gap: 1rem;
    margin-bottom: 0.75rem;
}

.news-body-right {
    flex-direction: row-reverse;
}

.news-body-left .news-image,
.news-body-right .news-image {
    flex-shrink: 0;
    margin-bottom: 0;
}

.news-body-left .news-image img,
.news-body-right .news-image img {
    max-height: 160px;
    width: auto;
}

.news-body-left .news-content,
.news-body-right .news-content {
    flex: 1;
    margin-bottom: 0;
}

.image-position-group {
    margin-top: 0.5rem;
}

.image-position-group > label {
    display: block;
    font-weight: 600;
    font-size: 0.9rem;
    margin-bottom: 0.4rem;
    color: var(--dark);
}

.image-position-options {
    display: flex;
    gap: 0.5rem;
    flex-wrap: wrap;
}

.image-position-option {
    display: flex;
    align-items: center;
    gap: 0.35rem;
    padding: 0.4rem 0.7rem;
    border: 2px solid #d1e3f6;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.2s ease;
    font-size: 0.85rem;
    color: var(--gray);
}

.image-position-option:hover {
    border-color: var(--primary-light);
}

.image-position-option input[type="radio"] {
    display: none;
}

.image-position-option:has(input:checked) {
    border-color: var(--primary);
    background: var(--light);
    color: var(--dark);
}

.image-position-option:has(input:checked) .image-position-icon svg {
    stroke: var(--primary);
}

.image-position-icon {
    display: flex;
    align-items: center;
}

.file-upload-area {
    border: 2px dashed #d1e3f6;
    border-radius: 8px;
    padding: 1.25rem;
    cursor: pointer;
    transition: all 0.3s ease;
    background: #f8fbff;
}

.file-upload-area:hover {
    border-color: var(--primary);
    background: var(--light);
}

.file-upload-content {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    color: var(--gray);
}

.file-upload-content svg {
    flex-shrink: 0;
    color: var(--primary-light);
}

.file-upload-preview {
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.file-upload-preview img {
    width: 48px;
    height: 48px;
    object-fit: cover;
    border-radius: 6px;
}

.file-upload-preview span {
    font-size: 0.9rem;
    color: var(--dark);
    word-break: break-all;
}

.current-image-preview {
    margin-top: 0.5rem;
    display: flex;
    align-items: center;
    gap: 1rem;
}

.current-image-preview img {
    max-width: 120px;
    max-height: 80px;
    border-radius: 6px;
    object-fit: cover;
}

.news-content {
    color: var(--gray);
    line-height: 1.6;
    margin-bottom: 1rem;
    font-size: 0.95rem;
}

.news-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding-top: 0.75rem;
    border-top: 1px solid #e2e8f0;
}

.news-meta {
    display: flex;
    gap: 1.5rem;
    flex-wrap: wrap;
}

.news-date,
.news-author {
    display: flex;
    align-items: center;
    gap: 0.4rem;
    font-size: 0.85rem;
    color: var(--gray);
}

.news-date svg,
.news-author svg {
    color: var(--primary);
}

.news-actions {
    display: flex;
    gap: 0.5rem;
}

/* Home page news section */
.home-news-section {
    margin-top: 2rem;
    padding-top: 2rem;
    border-top: 2px solid var(--light);
}

.home-news-section h3 {
    margin-bottom: 1rem;
    color: var(--dark);
}

.home-news-list {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.home-news-card {
    background: var(--light);
    padding: 1rem 1.25rem;
    border-radius: 10px;
    border-left: 3px solid var(--accent);
}

.home-news-card h4 {
    margin: 0 0 0.5rem 0;
    font-size: 1rem;
    color: var(--dark);
}

.home-news-card p {
    margin: 0;
    color: var(--gray);
    font-size: 0.9rem;
    line-height: 1.5;
}

.home-news-card .news-date {
    margin-top: 0.5rem;
    font-size: 0.8rem;
}

.view-all-link {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    margin-top: 1rem;
    color: var(--primary);
    text-decoration: none;
    font-weight: 500;
}

.view-all-link:hover {
    text-decoration: underline;
}

/* Responsive */
@media (max-width: 768px) {
    header {
        flex-direction: column;
        text-align: center;
    }

    .site-brand {
        justify-content: center;
        flex-wrap: wrap;
    }

    .site-brand-logo {
        height: 36px;
    }

    nav {
        justify-content: center;
    }

    main {
        margin: 1rem;
        padding: 1.25rem;
        border-radius: 12px;
    }

    main.login-page {
        margin: 2rem 1rem;
    }

    .form-row {
        grid-template-columns: 1fr;
    }

    .club-admin-card,
    .user-card {
        flex-direction: column;
        gap: 0.75rem;
    }

    .user-card.compact {
        padding: 0.85rem 1rem;
    }

    .user-card.compact .user-info {
        width: 100%;
        gap: 0.2rem 0.4rem;
    }

    .club-actions,
    .user-actions {
        width: 100%;
    }

    .user-card.compact .user-actions {
        display: grid;
        grid-template-columns: repeat(3, 1fr);
        gap: 0.35rem;
    }

    .user-card.compact .user-actions .btn {
        text-align: center;
        padding-left: 0.3rem;
        padding-right: 0.3rem;
        font-size: 0.78rem;
    }

    .events-header {
        flex-direction: column;
        align-items: flex-start;
    }

    .hero h2 {
        font-size: 1.5rem;
    }

    .news-header {
        flex-direction: column;
        gap: 0.5rem;
    }

    .news-footer {
        flex-direction: column;
        gap: 0.75rem;
        align-items: flex-start;
    }

    .news-actions {
        width: 100%;
        justify-content: flex-end;
    }

    .news-body-left,
    .news-body-right {
        flex-direction: column;
    }
}

/* ==================== PRINT STYLES ==================== */

.print-only {
    display: none;
}

.participants-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1rem;
}

.participants-header h3 {
    margin: 0;
}

.participants-header-actions {
    display: flex;
    gap: 0.5rem;
    align-items: center;
    flex-wrap: wrap;
}

.btn-print {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
}

@media print {
    /* Hide everything except print container */
    body * {
        visibility: hidden;
    }

    .print-only,
    .print-only * {
        visibility: visible;
    }

    .print-only {
        display: block !important;
        position: absolute;
        left: 0;
        top: 0;
        width: 100%;
        padding: 20px;
        background: white;
    }

    .print-header {
        text-align: center;
        margin-bottom: 30px;
        border-bottom: 2px solid #333;
        padding-bottom: 15px;
    }

    .print-header h1 {
        font-size: 18pt;
        margin: 0 0 5px 0;
        color: #333;
    }

    .print-header h2 {
        font-size: 14pt;
        margin: 0 0 5px 0;
        color: #555;
    }

    .print-header .print-date {
        font-size: 11pt;
        color: #666;
        margin: 0;
    }

    .print-table {
        width: 100%;
        border-collapse: collapse;
        margin-bottom: 20px;
    }

    .print-table th,
    .print-table td {
        border: 1px solid #333;
        padding: 8px 10px;
        text-align: left;
        font-size: 10pt;
    }

    .print-table th {
        background: #f0f0f0;
        font-weight: bold;
    }

    .print-table th:first-child {
        width: 40px;
        text-align: center;
    }

    .print-table td:first-child {
        text-align: center;
    }

    .print-table .signature-cell {
        width: 120px;
    }

    .print-footer {
        margin-top: 20px;
        padding-top: 10px;
        border-top: 1px solid #ccc;
        display: flex;
        justify-content: space-between;
    }

    .print-footer p {
        margin: 0;
        font-size: 10pt;
        color: #666;
    }

    .print-generated {
        font-style: italic;
    }
}

/* ===================
   Gallery
   =================== */

.gallery-list {
    display: flex;
    flex-direction: column;
    gap: 1.25rem;
    margin-top: 1rem;
}

.gallery-card {
    background: var(--white);
    border-radius: 12px;
    border-left: 4px solid var(--primary);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
    padding: 1.25rem;
    transition: all 0.3s ease;
}

.gallery-card:hover {
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.12);
    transform: translateY(-2px);
}

.gallery-header {
    margin-bottom: 0.75rem;
}

.gallery-title-row {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 1rem;
}

.gallery-title-row h3 {
    margin: 0;
    font-size: 1.1rem;
    color: var(--dark);
}

.gallery-badges {
    display: flex;
    gap: 0.5rem;
    flex-shrink: 0;
}

.gallery-badges .badge {
    font-size: 0.7rem;
    padding: 0.2rem 0.5rem;
    border-radius: 4px;
    font-weight: 600;
}

.gallery-date {
    display: inline-flex;
    align-items: center;
    gap: 0.3rem;
    font-size: 0.85rem;
    color: var(--gray);
    margin-top: 0.25rem;
}

.gallery-description {
    font-size: 0.9rem;
    color: #475569;
    margin-bottom: 0.75rem;
    line-height: 1.5;
}

.gallery-thumbs {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 0.75rem;
    margin-bottom: 0.75rem;
    padding: 0.75rem;
    background: #f8fafc;
    border-radius: 10px;
    border: 1px solid #e2e8f0;
}

.gallery-thumb-link {
    display: block;
    border-radius: 8px;
    overflow: hidden;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
    aspect-ratio: 16/9;
    box-shadow: 0 1px 4px rgba(0, 0, 0, 0.1);
}

.gallery-ratio-4-3 .gallery-thumb-link { aspect-ratio: 4/3; }
.gallery-ratio-3-2 .gallery-thumb-link { aspect-ratio: 3/2; }
.gallery-ratio-1-1 .gallery-thumb-link { aspect-ratio: 1/1; }

.gallery-thumb-link:hover {
    transform: scale(1.03);
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.2);
}

.gallery-thumb {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    cursor: pointer;
}

.gallery-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding-top: 0.5rem;
    border-top: 1px solid #f1f5f9;
}

.gallery-meta {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 0.5rem 1.1rem;
    font-size: 0.8rem;
    color: var(--gray);
}

.gallery-actions {
    display: flex;
    gap: 0.5rem;
}

/* Gallery image management in edit modal */
.gallery-images-manage {
    display: flex;
    flex-wrap: wrap;
    gap: 0.75rem;
}

.gallery-manage-item {
    position: relative;
    border-radius: 8px;
    overflow: hidden;
    border: 2px solid #e2e8f0;
    transition: all 0.2s ease;
}

.gallery-manage-item img {
    height: 80px;
    width: auto;
    max-width: 120px;
    object-fit: cover;
    display: block;
}

.gallery-manage-item.marked-for-delete {
    border-color: var(--danger);
    opacity: 0.5;
}

.gallery-manage-item.marked-for-delete::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(239, 68, 68, 0.15);
}

.gallery-manage-delete {
    position: absolute;
    top: 2px;
    right: 2px;
    width: 22px;
    height: 22px;
    border-radius: 50%;
    border: none;
    background: rgba(239, 68, 68, 0.85);
    color: white;
    font-size: 14px;
    line-height: 1;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background 0.2s ease;
}

.gallery-manage-delete:hover {
    background: var(--danger);
}

.gallery-image-count {
    font-size: 0.8rem;
    color: var(--gray);
}

/* Aspect ratio picker */
.aspect-ratio-options {
    display: flex;
    gap: 0.75rem;
    flex-wrap: wrap;
}

.aspect-ratio-option {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.3rem;
    cursor: pointer;
    padding: 0.5rem 0.6rem;
    border-radius: 8px;
    border: 2px solid #e2e8f0;
    transition: all 0.2s ease;
    font-size: 0.8rem;
    color: var(--gray);
}

.aspect-ratio-option:hover {
    border-color: var(--primary-light);
}

.aspect-ratio-option:has(input:checked) {
    border-color: var(--primary);
    background: var(--light);
    color: var(--dark);
    font-weight: 600;
}

.aspect-ratio-option input {
    display: none;
}

.aspect-ratio-preview {
    display: block;
    width: 48px;
    background: #cbd5e1;
    border-radius: 4px;
    border: 1px solid #94a3b8;
}

.aspect-ratio-option:has(input:checked) .aspect-ratio-preview {
    background: var(--primary-light);
    border-color: var(--primary);
}

@media (max-width: 768px) {
    .gallery-thumbs {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 480px) {
    .gallery-thumbs {
        grid-template-columns: 1fr;
        gap: 0.5rem;
        padding: 0.5rem;
    }

    .gallery-manage-item img {
        height: 60px;
        max-width: 90px;
    }
}

/* ===================
   Home Page Editing
   =================== */

.hero {
    position: relative;
}

.hero-empty {
    background: var(--light);
    border: 2px dashed var(--primary-light);
    text-align: center;
    padding: 2rem;
}

.hero:not(.hero-with-logo):not(.hero-align-left) .hero-text {
    text-align: center;
}

.hero-align-left {
    justify-content: flex-start;
    text-align: left;
}

.hero-align-left .hero-text {
    text-align: left;
}

.hero-edit-btn {
    position: absolute;
    top: 0.75rem;
    right: 0.75rem;
    background: rgba(255, 255, 255, 0.25);
    border: 1px solid rgba(255, 255, 255, 0.4);
    color: white;
    border-radius: 8px;
    padding: 0.5rem;
    cursor: pointer;
    transition: all 0.2s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 2;
}

.hero-edit-btn:hover {
    background: rgba(255, 255, 255, 0.4);
    transform: scale(1.1);
}

.content-section {
    position: relative;
}

.section-admin-actions {
    position: absolute;
    top: 0.75rem;
    right: 0.75rem;
    display: flex;
    gap: 0.35rem;
    z-index: 2;
    opacity: 0.4;
    transition: opacity 0.2s ease;
}

.content-section:hover .section-admin-actions {
    opacity: 1;
}

.content-section.align-center h3 {
    text-align: center;
}

/* Section image */
.section-image {
    margin-bottom: 0.75rem;
}

.section-image img {
    max-height: 200px;
    max-width: 100%;
    width: auto;
    border-radius: 8px;
    display: block;
    object-fit: cover;
}

/* Section body left/right layout */
.section-body-left,
.section-body-right {
    display: flex;
    gap: 1rem;
    margin-bottom: 0.75rem;
}

.section-body-right {
    flex-direction: row-reverse;
}

.section-body-left .section-image,
.section-body-right .section-image {
    flex-shrink: 0;
    margin-bottom: 0;
}

.section-body-left .section-image img,
.section-body-right .section-image img {
    max-height: 200px;
    width: auto;
}

.section-body-left .section-content,
.section-body-right .section-content {
    flex: 1;
}

/* Section parsed content */
.section-content p {
    line-height: 1.7;
    margin-bottom: 0.75rem;
    color: var(--gray);
}

.section-content ul {
    margin-left: 1.5rem;
    margin-bottom: 0.75rem;
}

.section-content li {
    line-height: 1.7;
    margin-bottom: 0.4rem;
    color: var(--gray);
}

.section-content a {
    color: var(--primary);
    text-decoration: underline;
}

.section-content a:hover {
    color: var(--primary-dark);
}

/* Add section button */
.add-section-wrapper {
    text-align: center;
    margin: 1.5rem 0 0.5rem;
}

/* Title align options */
.title-align-options {
    display: flex;
    gap: 1rem;
}

.radio-label {
    display: flex;
    align-items: center;
    gap: 0.4rem;
    cursor: pointer;
    font-size: 0.9rem;
    color: var(--dark);
}

/* Format toolbar */
.format-toolbar {
    display: flex;
    gap: 0.25rem;
    margin-bottom: 0.35rem;
    padding: 0.35rem;
    background: #f1f5f9;
    border-radius: 6px 6px 0 0;
    border: 1px solid #d1d5db;
    border-bottom: none;
}

.format-btn {
    background: var(--white);
    border: 1px solid #d1d5db;
    border-radius: 4px;
    padding: 0.3rem 0.5rem;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--dark);
    transition: all 0.15s ease;
    min-width: 30px;
    min-height: 28px;
}

.format-btn:hover {
    background: var(--primary);
    color: white;
    border-color: var(--primary);
}

.format-toolbar + textarea {
    border-radius: 0 0 8px 8px;
    border-top: none;
}

@media (max-width: 600px) {
    .section-body-left,
    .section-body-right {
        flex-direction: column;
    }

    .section-admin-actions {
        opacity: 1;
    }
}

/* ==========================================
   Activity Log Styles
   ========================================== */

.activity-stats {
    display: flex;
    gap: 1rem;
    margin-bottom: 1rem;
    padding: 0.6rem 0;
    border-bottom: 1px solid #d1e3f6;
}

.activity-stats .stat {
    font-size: 0.85rem;
    color: var(--gray);
}

.activity-stats .stat strong {
    color: var(--dark);
}

/* Activity log list - card based */
.activity-log-list {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.activity-log-item {
    display: flex;
    align-items: flex-start;
    gap: 0.85rem;
    background: var(--light);
    padding: 0.85rem 1rem;
    border-radius: 0 10px 10px 0;
    border-left: 3px solid #cbd5e1;
    transition: all 0.2s ease;
}

.activity-log-item:hover {
    transform: translateX(4px);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.06);
}

/* Category border colors */
.activity-log-item-auth { border-left-color: #3b82f6; }
.activity-log-item-auth.activity-log-action-login { border-left-color: #10b981; }
.activity-log-item-auth.activity-log-action-logout { border-left-color: #ef4444; }
.activity-log-item-auth.activity-log-action-password_change { border-left-color: #f59e0b; }
.activity-log-item-event { border-left-color: #10b981; }
.activity-log-item-news { border-left-color: #f59e0b; }
.activity-log-item-gallery { border-left-color: #8b5cf6; }
.activity-log-item-registration { border-left-color: #ec4899; }
.activity-log-item-payment { border-left-color: #14b8a6; }
.activity-log-item-member { border-left-color: #f97316; }
.activity-log-item-home { border-left-color: #6366f1; }

/* Icon circle */
.activity-log-icon {
    width: 34px;
    height: 34px;
    min-width: 34px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #e2e8f0;
    color: #64748b;
    flex-shrink: 0;
}

.activity-log-icon-auth { background: #dbeafe; color: #2563eb; }
.activity-log-action-login .activity-log-icon-auth,
.activity-log-icon-auth.activity-log-action-login { background: #d1fae5; color: #059669; }
.activity-log-action-logout .activity-log-icon-auth,
.activity-log-icon-auth.activity-log-action-logout { background: #fee2e2; color: #dc2626; }
.activity-log-action-password_change .activity-log-icon-auth,
.activity-log-icon-auth.activity-log-action-password_change { background: #fef3c7; color: #d97706; }
.activity-log-icon-event { background: #d1fae5; color: #059669; }
.activity-log-icon-news { background: #fef3c7; color: #d97706; }
.activity-log-icon-gallery { background: #ede9fe; color: #7c3aed; }
.activity-log-icon-registration { background: #fce7f3; color: #db2777; }
.activity-log-icon-payment { background: #ccfbf1; color: #0d9488; }
.activity-log-icon-member { background: #fed7aa; color: #ea580c; }
.activity-log-icon-home { background: #e0e7ff; color: #4f46e5; }

.activity-log-content {
    flex: 1;
    min-width: 0;
}

.activity-log-top {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 0.75rem;
    margin-bottom: 0.3rem;
}

.activity-log-desc {
    font-size: 0.9rem;
    color: var(--dark);
    font-weight: 500;
    line-height: 1.4;
}

.activity-log-bottom {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 0.5rem;
}

.activity-log-user {
    font-size: 0.8rem;
    color: var(--gray);
    font-weight: 500;
}

.activity-log-date {
    font-size: 0.78rem;
    color: #94a3b8;
    white-space: nowrap;
}

/* Category badges */
.activity-badge {
    display: inline-flex;
    align-items: center;
    padding: 0.2rem 0.65rem;
    border-radius: 20px;
    font-size: 0.7rem;
    font-weight: 600;
    white-space: nowrap;
    letter-spacing: 0.01em;
    flex-shrink: 0;
}

.activity-badge-auth { background: #dbeafe; color: #1e40af; }
.activity-badge-auth-login { background: #d1fae5; color: #065f46; }
.activity-badge-auth-logout { background: #fee2e2; color: #991b1b; }
.activity-log-icon-auth-login { background: #d1fae5; color: #059669; }
.activity-log-icon-auth-logout { background: #fee2e2; color: #dc2626; }
.activity-badge-event { background: #d1fae5; color: #065f46; }
.activity-badge-news { background: #fef3c7; color: #92400e; }
.activity-badge-gallery { background: #ede9fe; color: #5b21b6; }
.activity-badge-registration { background: #fce7f3; color: #9d174d; }
.activity-badge-payment { background: #ccfbf1; color: #134e4a; }
.activity-badge-member { background: #fed7aa; color: #9a3412; }
.activity-badge-home { background: #e0e7ff; color: #3730a3; }

/* Pagination */
.pagination {
    display: flex;
    justify-content: center;
    gap: 0.3rem;
    margin-top: 1.5rem;
    flex-wrap: wrap;
}

.pagination .btn-active {
    background: var(--primary);
    color: white;
    border-color: var(--primary);
}

/* ==========================================
   Member Activity Modal
   ========================================== */
.activity-modal-filters {
    display: flex;
    gap: 0.4rem;
    margin-bottom: 1rem;
    flex-wrap: wrap;
    padding-bottom: 0.75rem;
    border-bottom: 1px solid #e2e8f0;
}

.activity-modal-filters .btn {
    font-size: 0.78rem;
    padding: 0.3rem 0.7rem;
    border-radius: 20px;
    background: #f1f5f9;
    color: var(--gray);
    border: 1px solid #e2e8f0;
}

.activity-modal-filters .btn:hover {
    background: #e2e8f0;
}

.activity-modal-filters .btn.active {
    background: var(--primary);
    color: white;
    border-color: var(--primary);
}

.activity-list {
    max-height: 420px;
    overflow-y: auto;
    padding-right: 0.25rem;
}

.activity-list-item {
    display: flex;
    align-items: flex-start;
    gap: 0.75rem;
    padding: 0.7rem 0.75rem;
    border-radius: 8px;
    margin-bottom: 0.35rem;
    background: #f8fafc;
    border: 1px solid #f1f5f9;
    transition: background 0.15s ease;
}

.activity-list-item:hover {
    background: #f1f5f9;
}

.activity-list-icon {
    width: 30px;
    height: 30px;
    min-width: 30px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.activity-list-body {
    flex: 1;
    min-width: 0;
}

.activity-list-desc {
    font-size: 0.88rem;
    color: var(--dark);
    font-weight: 500;
    line-height: 1.35;
    margin-bottom: 0.2rem;
}

.activity-list-meta {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.5rem;
}

.activity-list-date {
    font-size: 0.75rem;
    color: #94a3b8;
    white-space: nowrap;
}

/* Responsive */
@media (max-width: 768px) {
    .activity-log-item {
        padding: 0.75rem;
        gap: 0.65rem;
    }

    .activity-log-top {
        flex-direction: column;
        gap: 0.3rem;
    }

    .activity-log-bottom {
        flex-direction: column;
        align-items: flex-start;
        gap: 0.15rem;
    }

    .activity-list-item {
        flex-direction: column;
        gap: 0.3rem;
    }

    .activity-list-meta {
        width: 100%;
    }
}

/* Password toggle */
.password-input-wrapper {
    position: relative;
    display: flex;
    align-items: center;
}

.password-input-wrapper input {
    flex: 1;
    padding-right: 2.5rem !important;
}

.password-toggle {
    position: absolute;
    right: 0.5rem;
    background: none;
    border: none;
    cursor: pointer;
    color: var(--gray);
    padding: 0.25rem;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: color 0.2s;
}

.password-toggle:hover {
    color: var(--dark);
}

/* Remember me */
.remember-me-group {
    margin-top: -0.25rem;
}

.remember-me-label {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    cursor: pointer;
    font-size: 0.9rem;
    color: var(--gray);
}

.remember-me-label input[type="checkbox"] {
    width: 1rem;
    height: 1rem;
    cursor: pointer;
}

/* Online/Offline status dots */
.status-dot {
    display: inline-block;
    width: 10px;
    height: 10px;
    border-radius: 50%;
    margin-right: 0.35rem;
    flex-shrink: 0;
}

.online-dot {
    background: var(--success);
    box-shadow: 0 0 6px rgba(16, 185, 129, 0.5);
}

.offline-dot {
    background: #cbd5e1;
}

/* Force logout button */
.btn-warning {
    background: linear-gradient(135deg, #f59e0b 0%, #d97706 100%);
}

.btn-warning:hover {
    background: linear-gradient(135deg, #d97706 0%, #b45309 100%);
    box-shadow: 0 5px 15px rgba(245, 158, 11, 0.4);
}

.btn-icon {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    white-space: nowrap;
    flex-shrink: 0;
}

.btn-icon svg {
    flex-shrink: 0;
}

/* ===================== Profile Page ===================== */
.profile-page {
    max-width: 520px;
    margin: 0 auto;
}

.profile-page h2 {
    text-align: center;
    margin-bottom: 1.5rem;
}

.profile-card {
    background: var(--white);
    border-radius: 12px;
    padding: 1.5rem 2rem;
    box-shadow: 0 2px 12px rgba(0,0,0,0.08);
}

.profile-section {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.profile-field {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.6rem 0;
}

.profile-label {
    font-size: 0.85rem;
    color: var(--gray);
    text-transform: uppercase;
    letter-spacing: 0.5px;
    font-weight: 500;
}

.profile-value {
    font-size: 1rem;
    font-weight: 600;
    color: var(--dark);
}

.profile-divider {
    height: 1px;
    background: #e2e8f0;
    margin: 1rem 0;
}

.profile-card .form-group {
    margin-bottom: 0;
}

.profile-card .form-group label {
    font-size: 0.85rem;
    color: var(--gray);
    text-transform: uppercase;
    letter-spacing: 0.5px;
    font-weight: 500;
    margin-bottom: 0.4rem;
}

.profile-card .form-group input[type="text"],
.profile-card .form-group input[type="email"] {
    width: 100%;
    padding: 0.6rem 0.8rem;
    border: 2px solid #e2e8f0;
    border-radius: 8px;
    font-size: 0.95rem;
    transition: border-color 0.2s;
    box-sizing: border-box;
}

.profile-card .form-group input[type="text"]:focus,
.profile-card .form-group input[type="email"]:focus {
    border-color: var(--primary);
    outline: none;
}

.profile-actions {
    display: flex;
    gap: 0.75rem;
    margin-top: 1.5rem;
    padding-top: 1rem;
    border-top: 1px solid #e2e8f0;
}

.profile-actions .btn {
    flex: 1;
    text-align: center;
}

.section-title {
    margin: 1.5rem 0 1rem;
    font-size: 1.2rem;
    color: var(--dark);
    padding-bottom: 0.5rem;
    border-bottom: 2px solid var(--light);
}

/* ===================== Blood Type Selector ===================== */
.blood-type-selector {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 8px;
}

.blood-type-btn {
    background: var(--white);
    border: 2px solid #e2e8f0;
    border-radius: 10px;
    padding: 10px 8px;
    font-size: 1rem;
    font-weight: 700;
    color: var(--dark);
    cursor: pointer;
    transition: all 0.2s ease;
    text-align: center;
}

.blood-type-btn:hover {
    border-color: var(--primary);
    background: var(--light);
    transform: translateY(-1px);
}

.blood-type-btn.selected {
    border-color: var(--danger);
    background: linear-gradient(135deg, #fef2f2 0%, #fee2e2 100%);
    color: var(--danger);
    box-shadow: 0 2px 8px rgba(239, 68, 68, 0.2);
}

/* ===================== Styled Select ===================== */
.styled-select {
    padding: 0.55rem 2rem 0.55rem 0.8rem;
    border: 2px solid #e2e8f0;
    border-radius: 8px;
    font-size: 0.95rem;
    background: var(--white);
    cursor: pointer;
    width: 100%;
    appearance: auto;
    transition: border-color 0.2s, box-shadow 0.2s;
}

.styled-select:focus {
    border-color: var(--primary);
    outline: none;
    box-shadow: 0 0 0 3px rgba(74, 144, 217, 0.15);
}

.styled-select:hover {
    border-color: #cbd5e1;
}

/* ===================== Custom Select with Search ===================== */
.custom-select-search-wrapper {
    position: relative;
    width: 100%;
}

.custom-select-search-input {
    width: 100%;
    padding: 0.5rem 0.75rem;
    border: 2px solid #e2e8f0;
    border-radius: 8px;
    font-size: 0.9rem;
    background: var(--white);
    transition: border-color 0.2s, box-shadow 0.2s;
    cursor: text;
}

.custom-select-search-input:focus {
    border-color: var(--primary);
    outline: none;
    box-shadow: 0 0 0 3px rgba(74, 144, 217, 0.15);
}

.custom-select-dropdown {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    max-height: 200px;
    overflow-y: auto;
    background: var(--white);
    border: 2px solid #e2e8f0;
    border-top: none;
    border-radius: 0 0 8px 8px;
    z-index: 100;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

.custom-select-dropdown.open {
    display: block;
}

.custom-select-option {
    padding: 0.5rem 0.75rem;
    cursor: pointer;
    font-size: 0.9rem;
    transition: background-color 0.15s;
}

.custom-select-option:hover {
    background: var(--light);
}

.custom-select-native {
    width: 100%;
    padding: 0.5rem 0.75rem;
    border: 2px solid #e2e8f0;
    border-radius: 8px;
    font-size: 0.9rem;
    background: var(--white);
    cursor: pointer;
    transition: border-color 0.2s, box-shadow 0.2s;
    appearance: auto;
}

.custom-select-native:focus {
    border-color: var(--primary);
    outline: none;
    box-shadow: 0 0 0 3px rgba(74, 144, 217, 0.15);
}

/* ===================== Custom Dropdown Component ===================== */
.custom-dropdown-wrapper {
    position: relative;
    flex: 1;
    min-width: 0;
}

.custom-dropdown-trigger {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    width: 100%;
    padding: 0.5rem 0.75rem;
    border: 2px solid #e2e8f0;
    border-radius: 8px;
    background: var(--white);
    cursor: pointer;
    font-size: 0.85rem;
    color: var(--dark);
    transition: border-color 0.2s, box-shadow 0.2s;
    text-align: left;
    font-family: inherit;
}

.custom-dropdown-trigger:hover {
    border-color: #cbd5e1;
}

.custom-dropdown-trigger:focus {
    border-color: var(--primary);
    outline: none;
    box-shadow: 0 0 0 3px rgba(74, 144, 217, 0.15);
}

.custom-dropdown-wrapper.open .custom-dropdown-trigger {
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(74, 144, 217, 0.15);
    border-bottom-left-radius: 0;
    border-bottom-right-radius: 0;
}

.custom-dropdown-trigger svg:first-child {
    flex-shrink: 0;
    color: var(--gray);
}

.custom-dropdown-text {
    flex: 1;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.custom-dropdown-arrow {
    flex-shrink: 0;
    color: var(--gray);
    transition: transform 0.2s;
}

.custom-dropdown-wrapper.open .custom-dropdown-arrow {
    transform: rotate(180deg);
}

.custom-dropdown-menu {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    max-height: 220px;
    overflow-y: auto;
    background: var(--white);
    border: 2px solid var(--primary);
    border-top: 1px solid #e2e8f0;
    border-radius: 0 0 8px 8px;
    z-index: 1001;
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.12);
}

.custom-dropdown-menu.has-search {
    overflow: hidden;
    max-height: none;
}

.custom-dropdown-menu.has-search .custom-dropdown-items {
    max-height: 180px;
    overflow-y: auto;
}

.custom-dropdown-wrapper.open .custom-dropdown-menu {
    display: block;
}

.custom-dropdown-search-box {
    padding: 0.5rem;
    border-bottom: 1px solid #e2e8f0;
    position: sticky;
    top: 0;
    background: var(--white);
}

.custom-dropdown-search {
    width: 100%;
    padding: 0.4rem 0.6rem;
    border: 1px solid #e2e8f0;
    border-radius: 6px;
    font-size: 0.85rem;
    outline: none;
    font-family: inherit;
}

.custom-dropdown-search:focus {
    border-color: var(--primary);
}

.custom-dropdown-item {
    padding: 0.5rem 0.75rem;
    cursor: pointer;
    font-size: 0.85rem;
    transition: background-color 0.15s;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.custom-dropdown-item:hover {
    background: var(--light);
}

.custom-dropdown-item.active {
    background: rgba(74, 144, 217, 0.1);
    color: var(--primary-dark);
    font-weight: 600;
}

.custom-dropdown-modal-header {
    display: none;
}

.custom-dropdown-overlay {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.3);
    z-index: 1000;
    backdrop-filter: blur(2px);
}

.custom-dropdown-overlay.active {
    display: block;
}

/* ===================== Event Filter Toggle ===================== */
.event-filter-toggle {
    display: flex;
    gap: 6px;
    margin-bottom: 1.5rem;
}

.event-filter-btn {
    border-radius: 20px !important;
    transition: all 0.2s ease;
}

.event-filter-btn:not(.active) {
    background: var(--white) !important;
    border: 1px solid #e2e8f0;
    color: var(--gray) !important;
    box-shadow: none !important;
}

.event-filter-btn:not(.active):hover {
    border-color: var(--primary);
    color: var(--primary) !important;
}

/* ===================== Requirement Modals ===================== */
.requirement-modal .modal-dialog {
    animation: modalSlideIn 0.3s ease;
}

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

.require-field-buttons {
    margin-top: 1rem;
}

.require-field-buttons .btn {
    text-align: left;
    justify-content: flex-start;
}

/* ===================== Analytics ===================== */
.analytics-summary {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
    gap: 1rem;
    margin-bottom: 2rem;
}

.analytics-stat-card {
    background: var(--light);
    border-radius: 12px;
    padding: 1.2rem;
    text-align: center;
}

.analytics-stat-number {
    font-size: 2rem;
    font-weight: 700;
    color: var(--primary-dark);
    line-height: 1;
}

.analytics-stat-label {
    font-size: 0.85rem;
    color: var(--gray);
    margin-top: 0.3rem;
}

.analytics-chart-wrapper {
    background: var(--white);
    border: 1px solid var(--border);
    border-radius: 10px;
    padding: 20px 15px 10px 15px;
    margin-bottom: 0.5rem;
}

.analytics-chart-body {
    display: flex;
    align-items: stretch;
}

.analytics-y-axis {
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    height: 180px;
    padding-right: 8px;
    text-align: right;
    flex-shrink: 0;
}

.analytics-y-label {
    font-size: 0.7rem;
    color: var(--gray);
    line-height: 1;
    white-space: nowrap;
}

.analytics-chart-area {
    position: relative;
    height: 180px;
    flex: 1;
    min-width: 0;
}

.analytics-grid {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    pointer-events: none;
}

.analytics-grid-line {
    position: absolute;
    left: 0;
    right: 0;
    height: 1px;
    background: #e0e0e0;
}

.analytics-chart {
    display: flex;
    align-items: flex-end;
    gap: 3px;
    height: 100%;
    width: 100%;
    position: relative;
    z-index: 1;
}

.analytics-chart-bar-group {
    flex: 1;
    min-width: 0;
    display: flex;
    align-items: flex-end;
    height: 100%;
    cursor: default;
}

.analytics-chart-bars {
    flex: 1;
    width: 100%;
    display: flex;
    gap: 2px;
    align-items: flex-end;
    height: 100%;
}

.analytics-chart-bar {
    flex: 1;
    border-radius: 3px 3px 0 0;
    min-height: 2px;
    transition: opacity 0.2s;
}

.analytics-chart-bar-group:hover .analytics-chart-bar {
    opacity: 0.8;
}

.analytics-x-axis {
    display: flex;
    margin-top: 4px;
}

.analytics-x-spacer {
    flex-shrink: 0;
    width: 40px;
}

.analytics-x-labels {
    display: flex;
    flex: 1;
    gap: 3px;
}

.analytics-x-label {
    flex: 1;
    font-size: 0.65rem;
    color: var(--gray);
    text-align: center;
}

.bar-logged {
    background: linear-gradient(180deg, var(--primary) 0%, var(--primary-dark) 100%);
}

.bar-guest {
    background: linear-gradient(180deg, #94a3b8 0%, #64748b 100%);
}

.bar-app {
    background: linear-gradient(180deg, #34d399 0%, #059669 100%);
}

/* Aplikacija bez prijave */
.bar-app-guest {
    background: linear-gradient(180deg, #fbbf24 0%, #d97706 100%);
}

/* Dan bez poseta: tanka siva crtica umesto obojenog stubica */
.analytics-chart-bar.bar-empty {
    background: #e5e7eb;
}

.analytics-chart-head {
    display: flex;
    flex-wrap: wrap;
    align-items: baseline;
    justify-content: space-between;
    gap: 0.25rem 1rem;
    margin: 1.5rem 0 0.5rem;
}

.analytics-chart-head:first-child {
    margin-top: 0;
}

.analytics-chart-title {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 1rem;
    margin: 0;
}

.analytics-chart-meta {
    font-size: 0.8rem;
    color: var(--gray);
}

.analytics-chart-bar-group.is-clickable {
    cursor: pointer;
}

.analytics-chart-bar-group.is-clickable:hover .analytics-chart-bar {
    opacity: 0.65;
}

.analytics-day-link {
    font-weight: 600;
    text-decoration: underline;
}

/* Detalji dana (klik na dan u analitici) - sopstvene boje i poravnanje,
   da ne nasledi beli/centriran tekst iz sidebar izgleda */
.day-details-body {
    padding: 0.5rem 0 0;
    max-height: 70vh;
    overflow-y: auto;
    color: #1e293b;
    text-align: left;
}

.day-details-empty {
    color: #64748b;
    text-align: center;
    padding: 1rem 0;
}

.day-visit {
    border: 1px solid #e2e8f0;
    border-radius: 10px;
    margin-bottom: 0.75rem;
    overflow: hidden;
}

.day-visit-head {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0.25rem 1rem;
    padding: 0.6rem 0.9rem;
    background: #f1f5f9;
    color: #1e293b;
}

.day-visit-ip {
    font-family: monospace;
    font-size: 0.85rem;
    color: #1e293b;
}

.day-visit-muted {
    color: #64748b;
    font-size: 0.8rem;
}

.day-visit-head .day-visit-muted:last-child {
    margin-left: auto;
}

.day-visit-pages {
    list-style: none;
    margin: 0;
    padding: 0.3rem 0.9rem;
    font-size: 0.875rem;
    color: #1e293b;
}

.day-visit-pages li {
    display: flex;
    gap: 0.75rem;
    padding: 0.3rem 0;
    border-top: 1px solid #f1f5f9;
}

.day-visit-pages li:first-child {
    border-top: none;
}

.day-visit-time {
    font-family: monospace;
    color: #64748b;
    flex-shrink: 0;
}

.day-visit > .day-visit-muted {
    margin: 0;
    padding: 0.5rem 0.9rem;
}

/* Stranice koje jos nisu posebno doterane za novi izgled (BaseController::render
   dodaje main-panel): naslov stoji na pozadini kao na ostalim stranicama novog
   izgleda, a ostatak sadrzaja je u beloj kartici (layout ga umotava u .panel-card),
   da tabele, modali i padajuci meniji ostanu citljivi. */
.layout-sidebar main.main-panel > h2 {
    margin-bottom: 2rem;
}

.layout-sidebar main.main-panel > .page-header-with-toggle {
    margin-bottom: 2rem;
}

.layout-sidebar .panel-card {
    background: var(--white);
    color: var(--dark);
    text-align: left;
    border-radius: 16px;
    padding: 2rem;
    box-shadow: 0 15px 50px rgba(0, 0, 0, 0.18);
}

.layout-sidebar .panel-card > :first-child {
    margin-top: 0;
}

@media (max-width: 768px) {
    .layout-sidebar .panel-card {
        padding: 1.25rem;
        border-radius: 12px;
    }

    .layout-sidebar main.main-panel > h2,
    .layout-sidebar main.main-panel > .page-header-with-toggle {
        margin-bottom: 1.25rem;
    }
}

/* Dve kolone na stranicama sa formama (profil, SEO, vidljivost); na uzem
   ekranu jedna ispod druge */
.panel-columns {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 1.5rem 2rem;
    align-items: start;
}

.panel-col {
    display: flex;
    flex-direction: column;
    gap: 1rem;
    min-width: 0;
}

.panel-col .seo-section:last-child {
    margin-bottom: 0;
}

.panel-col > .card {
    margin: 0;
}

/* Profil u dve kolone, u beloj kartici - bez druge kartice unutra */
.layout-sidebar .profile-page {
    max-width: none;
}

.panel-card .profile-card {
    padding: 0;
    box-shadow: none;
}

.profile-card .panel-columns {
    gap: 1rem 2.5rem;
}

.profile-card .panel-col {
    gap: 0;
}

@media (max-width: 1100px) {
    .panel-columns {
        grid-template-columns: minmax(0, 1fr);
    }
}

/* Boje pozadine na /page-visibility */
.bg-colors-row {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0.75rem 1.25rem;
    margin-bottom: 0.5rem;
}

.bg-color-field {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    cursor: pointer;
    font-weight: normal;
}

.bg-color-field input[type="color"] {
    width: 44px;
    height: 36px;
    padding: 2px;
    border: 1px solid #cbd5e1;
    border-radius: 8px;
    background: #fff;
    cursor: pointer;
}

.bg-color-preview {
    flex: 1;
    min-width: 120px;
    height: 36px;
    border-radius: 8px;
    border: 1px solid #cbd5e1;
}

/* Tabela i naslovi analitike u sidebar izgledu (beo tekst na plavoj pozadini) */
.layout-sidebar .analytics-table td {
    border-bottom-color: rgba(255, 255, 255, 0.25);
}

.layout-sidebar .analytics-table tr:hover td {
    background: rgba(255, 255, 255, 0.12);
}

.layout-sidebar .analytics-day-link {
    color: #fff;
}

.layout-sidebar .analytics-chart-meta {
    color: rgba(255, 255, 255, 0.85);
}

.analytics-legend {
    display: flex;
    gap: 1.5rem;
    justify-content: center;
    margin-bottom: 2rem;
}

.analytics-legend-item {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 0.85rem;
    color: var(--gray);
}

.analytics-legend-color {
    width: 14px;
    height: 14px;
    border-radius: 3px;
    display: inline-block;
}

/* Analytics tabs */
.analytics-tabs {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 0.5rem;
    margin-bottom: 1.5rem;
}

.analytics-tab {
    padding: 0.6rem 0.5rem;
    border: 2px solid #e2e8f0;
    background: var(--light);
    font-size: 0.85rem;
    color: var(--gray);
    cursor: pointer;
    border-radius: 8px;
    white-space: nowrap;
    transition: all 0.2s;
    text-align: center;
}

.analytics-tab:hover {
    color: var(--primary);
    border-color: var(--primary);
    background: #eef4fb;
}

.analytics-tab.active {
    color: #fff;
    background: var(--primary);
    border-color: var(--primary);
    font-weight: 600;
}

.analytics-tab-panel {
    display: none;
}

.analytics-tab-panel.active {
    display: block;
}

.analytics-table-wrapper {
    overflow-x: auto;
    margin-bottom: 2rem;
}

.analytics-table {
    width: 100%;
    border-collapse: collapse;
}

.analytics-table th,
.analytics-table td {
    padding: 0.6rem 1rem;
    text-align: left;
    border-bottom: 1px solid #e2e8f0;
    font-size: 0.9rem;
}

.analytics-table th {
    background: var(--light);
    font-weight: 600;
    color: var(--dark);
    white-space: nowrap;
}

.analytics-table tr:hover td {
    background: #f8fafc;
}

.analytics-page-url {
    font-family: 'Courier New', monospace;
    font-size: 0.8rem;
    color: var(--gray);
}


/* ===================== Registration Filters ===================== */
.registration-filters {
    display: flex;
    gap: 0.75rem;
    margin-bottom: 1rem;
    flex-wrap: wrap;
    background: var(--light);
    padding: 0.75rem 1rem;
    border-radius: 10px;
}

.registration-filter-group {
    position: relative;
    display: flex;
    align-items: center;
}

.registration-filter-group svg.filter-icon {
    position: absolute;
    left: 10px;
    pointer-events: none;
    color: var(--gray);
}

.registration-filter-group select {
    padding: 0.5rem 2rem 0.5rem 2.2rem;
    border: 2px solid #e2e8f0;
    border-radius: 8px;
    font-size: 0.85rem;
    background: var(--white);
    cursor: pointer;
    min-width: 190px;
    appearance: auto;
    transition: border-color 0.2s, box-shadow 0.2s;
}

.registration-filter-group select:focus {
    border-color: var(--primary);
    outline: none;
    box-shadow: 0 0 0 3px rgba(74, 144, 217, 0.15);
}

.registration-filter-group select:hover {
    border-color: #cbd5e1;
}

/* ===================== Responsive adjustments ===================== */
@media (max-width: 600px) {
    .registration-filters {
        flex-direction: column;
    }

    .registration-filter-group {
        width: 100%;
    }

    .registration-filter-group select {
        min-width: unset;
        width: 100%;
        max-width: 100%;
        font-size: 0.8rem;
    }

    .custom-dropdown-wrapper {
        width: 100%;
    }

    /* Obicni selekti - centriran modal */
    .custom-dropdown-menu {
        position: fixed;
        top: 50%;
        left: 50%;
        transform: translate(-50%, -50%);
        bottom: auto;
        right: auto;
        width: 88%;
        max-width: 340px;
        max-height: 65vh;
        border-radius: 12px;
        border: none;
        box-shadow: 0 8px 40px rgba(0, 0, 0, 0.25);
        z-index: 1001;
        animation: fadeInDropdownModal 0.2s ease-out;
        overflow-y: auto;
    }

    /* Selekti sa searchom (korisnici) - modal sa marginama */
    .custom-dropdown-wrapper.open .custom-dropdown-menu.has-search {
        top: 50%;
        left: 50%;
        right: auto;
        transform: translate(-50%, -50%);
        width: calc(100% - 2.5rem);
        max-width: 340px;
        height: auto;
        max-height: 70vh;
        border-radius: 12px;
        box-shadow: 0 8px 40px rgba(0, 0, 0, 0.25);
        display: flex;
        flex-direction: column;
        overflow: hidden;
    }

    .custom-dropdown-menu.has-search .custom-dropdown-modal-header {
        display: flex;
        align-items: center;
        justify-content: space-between;
        padding: 0.85rem 1rem;
        border-bottom: 1px solid #e2e8f0;
        background: var(--white);
        order: 0;
        flex-shrink: 0;
    }

    .custom-dropdown-modal-title {
        font-weight: 600;
        font-size: 1rem;
        color: var(--primary);
    }

    .custom-dropdown-modal-close {
        background: none;
        border: none;
        font-size: 1.6rem;
        color: var(--gray);
        cursor: pointer;
        padding: 0 0.25rem;
        line-height: 1;
        font-family: inherit;
    }

    .custom-dropdown-menu.has-search .custom-dropdown-items {
        flex: 1;
        min-height: 0;
        overflow-y: auto;
        order: 1;
    }

    .custom-dropdown-menu.has-search .custom-dropdown-search-box {
        order: 2;
        border-bottom: none;
        border-top: 1px solid #e2e8f0;
        padding: 0.75rem;
        background: var(--white);
        flex-shrink: 0;
    }

    .custom-dropdown-wrapper.open .custom-dropdown-trigger {
        border-bottom-left-radius: 8px;
        border-bottom-right-radius: 8px;
    }

    .custom-dropdown-item {
        padding: 0.75rem 1rem;
        font-size: 0.95rem;
    }

    .custom-dropdown-search {
        padding: 0.7rem 0.85rem;
        font-size: 16px;
        border-radius: 8px;
    }

    @keyframes fadeInDropdownModal {
        from { opacity: 0; }
        to { opacity: 1; }
    }

    .header-actions {
        flex-wrap: wrap;
        gap: 0.5rem;
    }

    .header-actions .btn {
        font-size: 0.8rem;
        padding: 0.4rem 0.75rem;
    }

    .custom-select-native,
    .custom-select-search-input {
        font-size: 16px; /* Prevent iOS zoom */
    }

    .blood-type-selector {
        grid-template-columns: repeat(4, 1fr);
        gap: 6px;
    }

    .blood-type-btn {
        padding: 8px 4px;
        font-size: 0.9rem;
    }

    .analytics-summary {
        grid-template-columns: repeat(2, 1fr);
    }

    .analytics-tab {
        padding: 0.55rem 0.4rem;
        font-size: 0.8rem;
    }

    .analytics-chart-wrapper {
        padding: 10px 8px 6px 8px;
        overflow: hidden;
    }

    .analytics-chart-body {
        display: flex;
        align-items: stretch;
    }

    .analytics-y-axis {
        display: none;
    }

    .analytics-chart-area {
        height: 120px;
    }

    .analytics-x-spacer {
        display: none;
    }

    .analytics-x-label {
        font-size: 0.45rem;
    }

    .profile-page {
        max-width: 100%;
    }

    .profile-card {
        padding: 1rem 1.2rem;
    }

    .profile-actions {
        flex-direction: column;
    }
}

/* ===== DB Update / Migrations ===== */

.dbupdate-stats {
    display: flex;
    gap: 1rem;
    margin-bottom: 1.5rem;
    flex-wrap: wrap;
}

.dbupdate-stat {
    background: rgba(255, 255, 255, 0.9);
    border-radius: 12px;
    padding: 1rem 1.5rem;
    text-align: center;
    min-width: 100px;
}

.dbupdate-stat-number {
    display: block;
    font-size: 1.8rem;
    font-weight: 700;
    color: var(--dark);
}

.dbupdate-stat-label {
    display: block;
    font-size: 0.85rem;
    color: var(--gray);
    margin-top: 0.25rem;
}

.dbupdate-stat-success {
    border-bottom: 3px solid var(--success);
}

.dbupdate-stat-pending {
    border-bottom: 3px solid var(--accent);
}

.dbupdate-stat-skipped {
    border-bottom: 3px solid var(--gray);
}

.dbupdate-stat-error {
    border-bottom: 3px solid var(--danger);
}

.dbupdate-actions {
    margin-bottom: 1.5rem;
}

.dbupdate-list {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.dbupdate-card {
    background: rgba(255, 255, 255, 0.95);
    border-radius: 10px;
    padding: 1rem 1.25rem;
    border-left: 4px solid var(--gray);
}

.dbupdate-card-executed {
    border-left-color: var(--success);
}

.dbupdate-card-pending {
    border-left-color: var(--accent);
}

.dbupdate-card-error {
    border-left-color: var(--danger);
}

.dbupdate-card-skipped {
    border-left-color: var(--gray);
    opacity: 0.7;
}

.dbupdate-card-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 1rem;
    flex-wrap: wrap;
}

.dbupdate-card-info {
    display: flex;
    align-items: center;
    gap: 1rem;
    flex-wrap: wrap;
}

.dbupdate-filename {
    font-weight: 600;
    color: var(--dark);
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.95rem;
}

.dbupdate-filename svg {
    color: var(--gray);
    flex-shrink: 0;
}

.dbupdate-date {
    font-size: 0.8rem;
    color: var(--gray);
}

.dbupdate-card-right {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.dbupdate-badge {
    display: inline-block;
    padding: 0.25rem 0.75rem;
    border-radius: 20px;
    font-size: 0.8rem;
    font-weight: 600;
}

.dbupdate-badge-success {
    background: rgba(16, 185, 129, 0.15);
    color: #059669;
}

.dbupdate-badge-pending {
    background: rgba(240, 165, 0, 0.15);
    color: #d97706;
}

.dbupdate-badge-error {
    background: rgba(239, 68, 68, 0.15);
    color: #dc2626;
}

.dbupdate-badge-skipped {
    background: rgba(100, 116, 139, 0.15);
    color: var(--gray);
}

.dbupdate-error {
    background: rgba(239, 68, 68, 0.08);
    border: 1px solid rgba(239, 68, 68, 0.2);
    border-radius: 8px;
    padding: 0.75rem 1rem;
    margin-top: 0.75rem;
    font-size: 0.85rem;
    color: #dc2626;
    word-break: break-word;
}

.dbupdate-card-actions {
    margin-top: 0.75rem;
    display: flex;
    gap: 0.5rem;
}

.dbupdate-modal-overlay {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.5);
    backdrop-filter: blur(4px);
    z-index: 1000;
    justify-content: center;
    align-items: center;
}

.dbupdate-modal-overlay.active {
    display: flex;
}

.dbupdate-modal {
    background: #fff;
    border-radius: 16px;
    padding: 2rem;
    max-width: 420px;
    width: 90%;
    text-align: center;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
    animation: dbModalIn 0.2s ease-out;
}

@keyframes dbModalIn {
    from { opacity: 0; transform: scale(0.9) translateY(10px); }
    to { opacity: 1; transform: scale(1) translateY(0); }
}

.dbupdate-modal-icon {
    width: 56px;
    height: 56px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 1rem;
    background: rgba(240, 165, 0, 0.12);
    color: var(--accent);
}

.dbupdate-modal-icon-success {
    background: rgba(16, 185, 129, 0.12);
    color: var(--success);
}

.dbupdate-modal-icon-warning {
    background: rgba(240, 165, 0, 0.12);
    color: var(--accent);
}

.dbupdate-modal-icon-secondary {
    background: rgba(100, 116, 139, 0.12);
    color: var(--gray);
}

.dbupdate-modal-title {
    font-size: 1.2rem;
    font-weight: 700;
    color: var(--dark);
    margin-bottom: 0.5rem;
}

.dbupdate-modal-message {
    color: var(--gray);
    font-size: 0.95rem;
    margin-bottom: 0.25rem;
}

.dbupdate-modal-detail {
    color: var(--dark);
    font-weight: 600;
    font-size: 0.9rem;
    background: var(--light);
    display: inline-block;
    padding: 0.3rem 0.8rem;
    border-radius: 6px;
    margin-bottom: 1.5rem;
    word-break: break-all;
}

.dbupdate-modal-buttons {
    display: flex;
    gap: 0.75rem;
    justify-content: center;
}

.dbupdate-modal-buttons .btn {
    min-width: 100px;
}

@media (max-width: 600px) {
    .dbupdate-stats {
        gap: 0.5rem;
    }

    .dbupdate-stat {
        min-width: 70px;
        padding: 0.75rem 1rem;
    }

    .dbupdate-stat-number {
        font-size: 1.4rem;
    }

    .dbupdate-card-header {
        flex-direction: column;
        align-items: flex-start;
    }
}

/* ============================
   LOGIN ATTEMPTS
   ============================ */

.login-attempt-stats {
    display: flex;
    gap: 1rem;
    margin-bottom: 1rem;
    flex-wrap: wrap;
}

.login-attempt-stat {
    background: var(--white);
    border-radius: 10px;
    padding: 0.75rem 1.25rem;
    display: flex;
    flex-direction: column;
    align-items: center;
    min-width: 100px;
    box-shadow: 0 1px 4px rgba(0, 0, 0, 0.06);
}

.login-attempt-stat-label {
    font-size: 0.78rem;
    color: var(--gray);
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.login-attempt-stat-value {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--dark);
}

.login-attempt-stat-success .login-attempt-stat-value {
    color: var(--success);
}

.login-attempt-stat-failure .login-attempt-stat-value {
    color: var(--danger);
}

.login-attempt-list {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.login-attempt-item {
    display: flex;
    align-items: flex-start;
    gap: 0.85rem;
    padding: 0.85rem 1rem;
    border-radius: 0 10px 10px 0;
    border-left: 3px solid #cbd5e1;
    transition: all 0.2s ease;
}

.login-attempt-item:hover {
    transform: translateX(4px);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.06);
}

.login-attempt-success {
    background: #f0fdf4;
    border-left-color: var(--success);
}

.login-attempt-failure {
    background: #fef2f2;
    border-left-color: var(--danger);
    padding: 1rem 1.1rem;
    font-weight: 500;
}

.login-attempt-icon {
    width: 36px;
    height: 36px;
    min-width: 36px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.login-attempt-icon-success {
    background: #d1fae5;
    color: #059669;
}

.login-attempt-icon-failure {
    background: #fee2e2;
    color: #dc2626;
}

.login-attempt-content {
    flex: 1;
    min-width: 0;
}

.login-attempt-top {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 0.75rem;
    margin-bottom: 0.3rem;
}

.login-attempt-info {
    display: flex;
    align-items: baseline;
    gap: 0.4rem;
    flex-wrap: wrap;
}

.login-attempt-username {
    font-size: 0.92rem;
    font-weight: 600;
    color: var(--dark);
}

.login-attempt-fullname {
    font-size: 0.82rem;
    color: var(--gray);
}

.login-attempt-unknown {
    font-size: 0.82rem;
    color: var(--danger);
    font-style: italic;
}

.login-attempt-bottom {
    display: flex;
    align-items: center;
    gap: 1rem;
    flex-wrap: wrap;
}

.login-attempt-password {
    font-size: 0.82rem;
    color: var(--gray);
}

.login-attempt-password code {
    background: rgba(0, 0, 0, 0.06);
    padding: 0.1rem 0.4rem;
    border-radius: 4px;
    font-size: 0.82rem;
    font-family: 'Courier New', monospace;
}

.login-attempt-failure .login-attempt-password code {
    background: rgba(239, 68, 68, 0.1);
    color: #b91c1c;
    font-weight: 600;
}

.login-attempt-ip {
    font-size: 0.78rem;
    color: #94a3b8;
}

.login-attempt-date {
    font-size: 0.78rem;
    color: #94a3b8;
    margin-left: auto;
}

.attempt-badge {
    font-size: 0.72rem;
    padding: 0.2rem 0.6rem;
    border-radius: 20px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    white-space: nowrap;
}

.attempt-badge-success {
    background: #d1fae5;
    color: #059669;
}

.attempt-badge-failure {
    background: #fee2e2;
    color: #dc2626;
}

@media (max-width: 600px) {
    .login-attempt-stats {
        gap: 0.5rem;
    }

    .login-attempt-stat {
        flex: 1;
        min-width: 80px;
        padding: 0.6rem 0.8rem;
    }

    .login-attempt-stat-value {
        font-size: 1.2rem;
    }

    .login-attempt-top {
        flex-direction: column;
        gap: 0.3rem;
    }

    .login-attempt-bottom {
        flex-direction: column;
        align-items: flex-start;
        gap: 0.3rem;
    }

    .login-attempt-date {
        margin-left: 0;
    }
}

/* ============ Online Time ============ */

.online-time-tabs {
    display: flex;
    gap: 0.5rem;
    margin-bottom: 1.5rem;
}

.online-time-panel {
    margin-top: 1rem;
}

/* Detail table (user data) */
.ot-detail-table {
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.ot-detail-header {
    display: flex;
    align-items: center;
    padding: 0.75rem 1rem;
    background: var(--dark);
    color: var(--white);
    border-radius: 8px 8px 0 0;
    font-weight: 600;
    font-size: 0.85rem;
}

.ot-detail-row {
    display: flex;
    align-items: center;
    padding: 0.6rem 1rem;
    background: #f8fafc;
    transition: background 0.2s;
}

.ot-detail-row:hover {
    background: #f1f5f9;
}

.ot-detail-footer {
    display: flex;
    align-items: center;
    padding: 0.75rem 1rem;
    background: var(--light);
    border-radius: 0 0 8px 8px;
    font-weight: 700;
    border-top: 2px solid var(--primary);
}

.ot-detail-col-label {
    flex: 1;
    min-width: 0;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.ot-detail-col-time {
    flex: 1;
    min-width: 0;
}

.ot-detail-col-duration {
    width: auto;
    text-align: right;
    font-weight: 600;
    flex-shrink: 0;
    font-variant-numeric: tabular-nums;
    white-space: nowrap;
    margin-right: 10px;
}

.ot-detail-col-visits {
    width: 60px;
    text-align: center;
    flex-shrink: 0;
}

.ot-detail-col-pages {
    width: 70px;
    text-align: center;
    flex-shrink: 0;
}

.ot-detail-footer .ot-detail-col-duration {
    color: var(--primary-dark);
}

/* Summary chart */
.summary-chart {
    background: var(--white);
    border: 1px solid var(--border);
    border-radius: 10px;
    padding: 20px 15px 10px 15px;
    margin-bottom: 16px;
}

.summary-chart .chart-body {
    display: flex;
    align-items: stretch;
}

.summary-chart .chart-y-axis {
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    height: 180px;
    padding-right: 8px;
    text-align: right;
    flex-shrink: 0;
}

.summary-chart .chart-y-label {
    font-size: 0.7rem;
    color: var(--gray);
    line-height: 1;
    white-space: nowrap;
}

.summary-chart .chart-area {
    position: relative;
    height: 180px;
    flex: 1;
    min-width: 0;
}

.summary-chart .chart-grid {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    pointer-events: none;
}

.summary-chart .chart-grid-line {
    position: absolute;
    left: 0;
    right: 0;
    height: 1px;
    background: #e0e0e0;
}

.summary-chart .chart-bars {
    display: flex;
    align-items: flex-end;
    gap: 2px;
    height: 100%;
    width: 100%;
    position: relative;
    z-index: 1;
}

.summary-chart .chart-bar-col {
    flex: 1;
    display: flex;
    align-items: flex-end;
    justify-content: center;
    height: 100%;
    min-width: 0;
}

.summary-chart .chart-bar {
    flex: 1;
    min-height: 2px;
    border-radius: 3px 3px 0 0;
    transition: height 0.4s ease;
    cursor: default;
}

.summary-chart .chart-bar:hover {
    opacity: 0.75;
}

.summary-chart .chart-bar-time {
    background: linear-gradient(180deg, var(--primary), var(--primary-dark));
}

.summary-chart .chart-x-axis {
    display: flex;
    margin-top: 4px;
}

.summary-chart .chart-x-spacer {
    flex-shrink: 0;
    width: 40px;
}

.summary-chart .chart-x-labels {
    display: flex;
    flex: 1;
    gap: 2px;
}

.summary-chart .chart-bar-label {
    flex: 1;
    font-size: 0.65rem;
    color: var(--gray);
    white-space: nowrap;
    text-align: center;
}

/* Ranking table */
.ranking-table {
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.ranking-header {
    display: flex;
    align-items: center;
    padding: 0.75rem 1rem;
    background: var(--dark);
    color: var(--white);
    border-radius: 8px 8px 0 0;
    font-weight: 600;
    font-size: 0.85rem;
}

.ranking-row {
    display: flex;
    align-items: center;
    padding: 0.65rem 1rem;
    background: #f8fafc;
    transition: background 0.2s;
}

.ranking-row:last-child {
    border-radius: 0 0 8px 8px;
}

.ranking-row:hover {
    background: #f1f5f9;
}

.ranking-col-rank {
    width: 40px;
    text-align: center;
    font-weight: 700;
    flex-shrink: 0;
}

.ranking-col-name {
    flex: 1;
    min-width: 0;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.ranking-col-time {
    width: auto;
    text-align: right;
    font-weight: 600;
    flex-shrink: 0;
    white-space: nowrap;
}

.ranking-col-visits {
    width: 60px;
    text-align: center;
    flex-shrink: 0;
}

/* Top 3 */
.ranking-gold {
    background: linear-gradient(135deg, #fef9c3 0%, #fde68a 100%);
    font-weight: 600;
}

.ranking-gold:hover {
    background: linear-gradient(135deg, #fde68a 0%, #fcd34d 100%);
}

.ranking-gold .ranking-col-rank {
    color: #b45309;
    font-size: 1.1rem;
}

.ranking-silver {
    background: linear-gradient(135deg, #f1f5f9 0%, #e2e8f0 100%);
    font-weight: 500;
}

.ranking-silver:hover {
    background: linear-gradient(135deg, #e2e8f0 0%, #cbd5e1 100%);
}

.ranking-silver .ranking-col-rank {
    color: #475569;
    font-size: 1.05rem;
}

.ranking-bronze {
    background: linear-gradient(135deg, #fef3e2 0%, #fed7aa 100%);
    font-weight: 500;
}

.ranking-bronze:hover {
    background: linear-gradient(135deg, #fed7aa 0%, #fdba74 100%);
}

.ranking-bronze .ranking-col-rank {
    color: #9a3412;
    font-size: 1.05rem;
}

.time-value {
    font-variant-numeric: tabular-nums;
}

/* Responsive */
@media (max-width: 600px) {
    .ot-detail-col-pages {
        display: none;
    }

    .ot-detail-col-visits {
        width: 50px;
        font-size: 0.75rem;
        white-space: nowrap;
    }

    .ot-detail-col-duration {
        margin-right: 12px;
        font-size: 0.75rem;
        white-space: normal;
        word-break: break-word;
        line-height: 1.2;
    }

    .ot-detail-header,
    .ot-detail-row,
    .ot-detail-footer {
        padding-right: 0.4rem;
    }

    .ot-detail-col-label {
        font-size: 0.8rem;
    }

    .ranking-header,
    .ranking-row {
        padding: 0.5rem 0.4rem;
    }

    .ranking-col-rank {
        width: 18px;
        margin-right: 8px;
    }

    .ranking-col-name {
        white-space: normal;
        word-wrap: break-word;
        line-height: 1.3;
    }

    .ranking-col-time {
        white-space: normal;
        word-break: break-word;
        text-align: right;
        margin-right: 14px;
        line-height: 1.3;
    }

    .ranking-col-visits {
        width: 40px;
        margin-right: 0;
    }

    .summary-chart {
        padding: 10px 8px 6px 8px;
        overflow: hidden;
    }

    .summary-chart .chart-body {
        display: flex;
        align-items: stretch;
    }

    .summary-chart .chart-y-axis {
        display: none;
    }

    .summary-chart .chart-area {
        height: 120px;
    }

    .summary-chart .chart-x-spacer {
        display: none;
    }

    .summary-chart .chart-bar-label {
        font-size: 0.45rem;
    }

    .ot-detail-header span,
    .ot-detail-row span,
    .ot-detail-footer span {
        font-size: 0.75rem;
    }

    .ot-detail-col-duration {
        margin-right: 4px;
    }
}

/* ===== Notifications ===== */
.nav-notifications {
    position: relative;
    display: inline-flex;
    align-items: center;
}

/* Broj neprocitanih uz tekst "Obavestenja" (u liniji, ne preko ikonice) */
.nav-notifications .notification-badge {
    position: static;
    margin-left: 6px;
}

.notification-badge {
    position: absolute;
    top: -6px;
    right: -8px;
    background: var(--danger);
    color: white;
    border-radius: 50%;
    width: 18px;
    height: 18px;
    font-size: 11px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: bold;
}

.notifications-list {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.notification-item {
    background: white;
    border-radius: 12px;
    padding: 1rem 1.25rem;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    box-shadow: 0 1px 3px rgba(0,0,0,0.05);
}

.notification-unread {
    border-left: 3px solid var(--primary);
    background: var(--light);
}

.notification-title {
    font-weight: 600;
    margin-bottom: 2px;
}

.notification-message {
    font-size: 0.9rem;
    color: var(--gray);
}

.notification-date {
    font-size: 0.8rem;
    color: var(--gray);
    margin-top: 4px;
}

.notification-action {
    flex-shrink: 0;
}

/* ===== Like Button ===== */
.like-btn {
    background: none;
    border: none;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    gap: 4px;
    color: var(--gray);
    font-size: 0.85rem;
    padding: 2px 6px;
    border-radius: 4px;
    transition: all 0.2s;
}

.like-btn:hover {
    color: var(--danger);
    background: rgba(239, 68, 68, 0.08);
}

.like-btn.liked {
    color: var(--danger);
}

.like-display {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    color: var(--gray);
    font-size: 0.85rem;
}

.news-view-count {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    color: var(--gray);
    font-size: 0.85rem;
}

/* ===== Star Rating ===== */
.star-rating-input {
    display: flex;
    flex-direction: row-reverse;
    justify-content: center;
    gap: 4px;
    margin-bottom: 12px;
}

.star-rating-input input {
    display: none;
}

.star-rating-input label {
    font-size: 2.5rem;
    color: #ddd;
    cursor: pointer;
    transition: color 0.15s;
}

.star-rating-input label:hover,
.star-rating-input label:hover ~ label,
.star-rating-input input:checked ~ label {
    color: #f0a500;
}

.stars-display {
    display: inline-flex;
    gap: 1px;
}

.star {
    color: #ddd;
    font-size: 1rem;
}

.star-filled {
    color: #f0a500;
}

.event-rating-display {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-top: 6px;
    margin-bottom: 6px;
}

.event-rating-display .stars-display {
    gap: 2px;
}

.event-rating-display .star {
    font-size: 1.4rem;
}

.rating-text {
    font-size: 1rem;
    color: var(--text);
    font-weight: 600;
}

.event-title-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
}

.event-reviews-section {
    margin-top: 1.5rem;
    padding-top: 1.5rem;
    border-top: 1px solid #e2e8f0;
}

.review-form-section {
    margin-bottom: 1.5rem;
}

.review-form {
    display: flex;
    align-items: flex-end;
    gap: 12px;
}

.user-review-info {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 1rem;
    color: var(--gray);
}

.reviews-list {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.review-item {
    padding: 8px 12px;
    background: var(--light);
    border-radius: 8px;
}

.review-header {
    display: flex;
    align-items: center;
    gap: 10px;
    flex-wrap: wrap;
}

.review-author {
    font-weight: 600;
    font-size: 0.9rem;
}

.review-date {
    font-size: 0.8rem;
    color: var(--gray);
    margin-left: auto;
}

/* ===== Gender Selector ===== */
.gender-selector {
    display: flex;
    gap: 12px;
}

.radio-label {
    display: flex;
    align-items: center;
    gap: 6px;
    cursor: pointer;
    padding: 6px 12px;
    border-radius: 8px;
    transition: background 0.2s;
}

.radio-label:hover {
    background: var(--light);
}

.radio-label input[type="radio"] {
    accent-color: var(--primary);
}

/* ===== Data Overview Table ===== */
.data-overview-table-wrapper {
    overflow-x: auto;
    border-radius: 12px;
    background: white;
    box-shadow: 0 1px 3px rgba(0,0,0,0.05);
}

.data-overview-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 0.85rem;
}

.data-overview-table th,
.data-overview-table td {
    padding: 8px 12px;
    text-align: left;
    border-bottom: 1px solid #e2e8f0;
    white-space: nowrap;
}

.data-overview-table th {
    background: var(--light);
    font-weight: 600;
    position: sticky;
    top: 0;
}

/* Istorija uredjaja (Dnevni kodovi): vremenska linija sa obojenim tackama */
.dc-timeline {
    position: relative;
    margin: 0.25rem 0 0.5rem;
    padding-left: 1.75rem;
}

.dc-timeline::before {
    content: '';
    position: absolute;
    left: 0.55rem;
    top: 0.6rem;
    bottom: 0.6rem;
    width: 2px;
    background: #e2e8f0;
}

.dc-tl-item {
    position: relative;
    padding: 0.55rem 0.85rem;
    margin-bottom: 0.5rem;
    background: #f8fafc;
    border: 1px solid #e2e8f0;
    border-radius: 10px;
}

.dc-tl-dot {
    position: absolute;
    left: -1.55rem;
    top: 0.9rem;
    width: 0.8rem;
    height: 0.8rem;
    border-radius: 50%;
    border: 2px solid #fff;
    box-shadow: 0 0 0 2px currentColor;
    background: currentColor;
}

.dc-tl-dot.enter { color: var(--success); }
.dc-tl-dot.revoke { color: var(--danger); }
.dc-tl-dot.unlink { color: #94a3b8; }
.dc-tl-dot.fail { color: var(--warning, #f59e0b); }

.dc-tl-head {
    display: flex;
    justify-content: space-between;
    align-items: baseline;
    gap: 1rem;
    flex-wrap: wrap;
}

.dc-tl-title {
    font-weight: 600;
    color: var(--dark);
}

.dc-tl-title.enter { color: #0f7b5f; }
.dc-tl-title.revoke { color: var(--danger); }
.dc-tl-title.fail { color: #b45309; }

.dc-tl-time {
    font-size: 0.8rem;
    color: var(--gray);
    white-space: nowrap;
}

.dc-tl-meta {
    margin-top: 0.3rem;
    font-size: 0.85rem;
    color: var(--gray);
}

/* Prozor sa tabelom (Dnevni kodovi): sire od obicnog prozora, a tabela
   prelama tekst u celijama umesto horizontalnog skrolovanja */
.info-dialog {
    max-width: 900px;
    text-align: left;
    overflow-x: hidden;
}

.info-dialog .data-overview-table th,
.info-dialog .data-overview-table td {
    white-space: normal !important;
    padding: 8px 10px;
}

.data-overview-table tfoot td {
    font-weight: 600;
    background: var(--light);
    border-top: 2px solid var(--primary);
}

.data-ok {
    color: #0f7b5f;
}

.data-missing {
    color: var(--danger);
}

.data-value {
    font-size: 0.82rem;
    word-break: break-all;
}

.data-required {
    color: var(--accent);
    font-weight: 600;
    font-size: 0.8rem;
}

.bulk-require-section {
    background: white;
    border-radius: 12px;
    padding: 1rem 1.25rem;
    margin-bottom: 1rem;
    box-shadow: 0 1px 3px rgba(0,0,0,0.05);
}

.bulk-require-section h3 {
    font-size: 0.95rem;
    margin-bottom: 8px;
}

.bulk-require-buttons {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

/* ===== Page Visibility ===== */
.pv-header {
    border-bottom: 2px solid var(--primary) !important;
    padding-bottom: 0.5rem !important;
}

.pv-col-header {
    width: 40px;
    text-align: center;
    font-size: 0.75rem;
    font-weight: 600;
    color: var(--gray);
}

/* Kolona sa duzim naslovom ("Neprijavljen") - siri i naslov i prekidaci
   ispod njega, da se tekst ne preklapa sa susednom kolonom */
.pv-col-wide {
    width: 76px;
}

/* Sektori na stranici Vidljivost: svaki u svom okviru sa naslovom */
.pv-section {
    margin: 1rem 1rem 1.25rem;
    padding: 0.25rem 1rem 0.5rem;
    background: #f8fafc;
    border: 1px solid #e2e8f0;
    border-left: 4px solid var(--primary);
    border-radius: 10px;
}

.pv-section-title {
    padding: 0.75rem 0 0.25rem;
    font-size: 0.8rem;
    font-weight: 700;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    color: var(--primary);
}

.pv-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0.75rem 0;
    border-bottom: 1px solid #e2e8f0;
}

.pv-row:last-child {
    border-bottom: none;
}

.pv-page-name {
    font-weight: 600;
    font-size: 0.9rem;
    flex: 1;
    min-width: 0;
}

.pv-toggles {
    display: flex;
    gap: 0.75rem;
    align-items: center;
    flex-shrink: 0;
}

.pv-toggle {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 4px;
    cursor: pointer;
    position: relative;
}

.pv-toggle input {
    opacity: 0;
    width: 0;
    height: 0;
    position: absolute;
}

.pv-toggle-slider {
    width: 40px;
    height: 22px;
    background: #cbd5e1;
    border-radius: 22px;
    transition: all 0.3s ease;
    position: relative;
}

.pv-toggle-slider::before {
    content: '';
    position: absolute;
    width: 16px;
    height: 16px;
    left: 3px;
    top: 3px;
    background: white;
    border-radius: 50%;
    transition: all 0.3s ease;
    box-shadow: 0 1px 3px rgba(0,0,0,0.2);
}

.pv-toggle input:checked + .pv-toggle-slider {
    background: var(--success);
}

.pv-toggle input:checked + .pv-toggle-slider::before {
    transform: translateX(18px);
}

/* ===== SEO podesavanja (/seo) ===== */
.seo-section {
    border: 1px solid #e2e8f0;
    border-radius: 10px;
    margin-bottom: 1rem;
    overflow: hidden;
    background: var(--white);
}

.seo-section-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    padding: 0.9rem 1rem;
    background: #f8fafc;
    border-bottom: 1px solid #e2e8f0;
}

.seo-section-head.is-plain {
    border-bottom: none;
}

.seo-section-title {
    font-weight: 700;
    font-size: 0.95rem;
    color: var(--dark);
}

.seo-section-sub {
    display: block;
    font-weight: 400;
    font-size: 0.78rem;
    color: var(--gray);
    margin-top: 0.2rem;
    max-width: 46ch;
}

.seo-section-body {
    padding: 1rem;
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.seo-master {
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(74, 144, 217, 0.10);
}

.seo-master .seo-section-head {
    background: var(--light);
}

/* Zatamnjenje sekcija kad je glavni prekidac ugasen */
.seo-dimmed {
    opacity: 0.5;
    filter: grayscale(0.55);
    transition: opacity 0.25s ease, filter 0.25s ease;
}

/* Zakljucano: koristi se samo za podkvacice mape sajta */
.seo-locked {
    pointer-events: none;
}

.seo-field-head {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    gap: 0.75rem;
}

.seo-counter {
    font-size: 0.72rem;
    color: var(--gray);
    font-variant-numeric: tabular-nums;
    white-space: nowrap;
}

.seo-counter.is-long {
    color: var(--accent);
    font-weight: 600;
}

.seo-counter.is-over {
    color: var(--danger);
    font-weight: 600;
}

/* Pregled kako stranica izgleda u rezultatima pretrage */
.seo-preview {
    border: 1px dashed #cbd5e1;
    border-radius: 10px;
    padding: 0.9rem 1rem;
    background: #fcfdff;
}

.seo-preview-label {
    font-size: 0.72rem;
    text-transform: uppercase;
    letter-spacing: 0.04em;
    color: var(--gray);
    margin-bottom: 0.6rem;
}

.seo-preview-url {
    font-size: 0.78rem;
    color: #3c7a3c;
    word-break: break-all;
}

.seo-preview-title {
    color: #1a0dab;
    font-size: 1.05rem;
    line-height: 1.3;
    margin: 0.15rem 0 0.25rem;
}

.seo-preview-desc {
    font-size: 0.85rem;
    color: #4d5156;
    line-height: 1.45;
}

.seo-preview-desc.is-empty {
    color: var(--danger);
    font-style: italic;
}

.seo-subchecks {
    display: flex;
    flex-direction: column;
    gap: 0.6rem;
    padding-left: 0.25rem;
}

.seo-actions {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    flex-wrap: wrap;
    padding: 1rem;
    border-top: 1px solid #e2e8f0;
    background: #f8fafc;
}

.seo-warning {
    font-size: 0.78rem;
    color: var(--gray);
    max-width: 52ch;
}

@media (max-width: 600px) {
    .seo-section-head { flex-direction: column; align-items: flex-start; }
    .seo-actions { flex-direction: column; align-items: stretch; }
    .seo-actions .btn { width: 100%; }
}

.seo-section-body textarea,
.seo-section-body input[type="text"] {
    font-family: inherit;
    font-size: 0.9rem;
    line-height: 1.5;
    resize: vertical;
}

/* Uspravno slaganje polja u admin formama - form-group nema spoljasnji razmak */
.settings-stack {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
    padding: 1.25rem;
}

.settings-stack .current-image-preview {
    display: flex;
    align-items: center;
    gap: 0.9rem;
    margin-top: 0.6rem;
    padding: 0.6rem;
    background: #f8fafc;
    border: 1px solid #e2e8f0;
    border-radius: 8px;
}

.settings-stack .current-image-preview img {
    width: 56px;
    height: 56px;
    object-fit: contain;
    border-radius: 6px;
    background: var(--white);
    flex-shrink: 0;
}

/* ===== Politika privatnosti (/privatnost) ===== */
.privacy-body {
    padding: 1.5rem;
    line-height: 1.7;
    color: var(--dark);
}

.privacy-body h3 {
    margin: 1.75rem 0 0.6rem;
    font-size: 1.05rem;
    color: var(--primary-dark);
    border-bottom: 2px solid var(--light);
    padding-bottom: 0.35rem;
}

.privacy-body h3:first-child {
    margin-top: 0;
}

.privacy-body h4 {
    margin: 1.1rem 0 0.4rem;
    font-size: 0.92rem;
    color: var(--dark);
}

.privacy-body p {
    margin: 0 0 0.85rem;
    font-size: 0.92rem;
}

.privacy-body ul {
    margin: 0 0 0.95rem;
    padding-left: 1.25rem;
    font-size: 0.92rem;
}

.privacy-body li {
    margin-bottom: 0.45rem;
}

.privacy-body a {
    color: var(--primary-dark);
    text-decoration: underline;
}

footer {
    flex-direction: column;
    gap: 0.45rem;
}

/* Tekst footera i dugme za izmenu ostaju u istom redu */
.footer-main {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.75rem;
    flex-wrap: wrap;
}

.footer-legal {
    margin: 0;
    font-size: 0.8rem;
    opacity: 0.85;
}

.footer-legal a {
    color: inherit;
    text-decoration: underline;
}

.privacy-head {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 1rem;
    flex-wrap: wrap;
}

.privacy-meta {
    color: var(--gray);
    margin-top: 0.5rem;
    font-size: 0.9rem;
}

.privacy-lang {
    flex-shrink: 0;
    padding: 0.35rem 0.8rem;
    border: 1px solid var(--primary);
    border-radius: 999px;
    font-size: 0.8rem;
    font-weight: 600;
    color: var(--primary-dark);
    text-decoration: none;
    white-space: nowrap;
}

.privacy-lang:hover {
    background: var(--light);
}

/* ===================
   Pocetna - desni sidebar umesto navbara
   =================== */

.layout-sidebar {
    --sidebar-width: 260px;
    padding-right: var(--sidebar-width);
    /* Nezan prelaz iz gornjeg levog u donji desni ugao, fiksiran za ekran */
    background: linear-gradient(135deg, var(--bg-from) 0%, var(--bg-to) 100%) fixed;
    /* Footer (politika privatnosti) uvek skroz dole */
    display: flex;
    flex-direction: column;
    min-height: 100vh;
}

.layout-sidebar main {
    flex: 1 0 auto;
    width: 100%;
}

.layout-sidebar footer {
    margin-top: 0;
    padding-bottom: 1.5rem;
}

.site-sidebar {
    position: fixed;
    top: 0;
    right: 0;
    bottom: 0;
    width: var(--sidebar-width);
    padding: 2.5rem 1.5rem;
    background: transparent;
    overflow-y: auto;
    z-index: 100;
    /* Linkovi vertikalno na sredini ekrana */
    display: flex;
    flex-direction: column;
}

.sidebar-nav {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
    margin: auto 0;
}

.sidebar-nav a {
    /* Narandzasto-zuta (#ffae06) da se meni razlikuje od belih sekcija */
    color: #ffae06;
    font-size: 1.9rem;
    font-weight: 800;
    /* Font nema tezi rez od bold-a, pa kontura iste boje dodatno zadebljava slova */
    -webkit-text-stroke: 0.9px currentColor;
    letter-spacing: 0.01em;
    padding: 0.5rem 1rem;
    border-radius: 12px;
    text-shadow: none;
}

.sidebar-nav a:hover {
    color: #ffae06;
    background: rgba(255, 255, 255, 0.25);
    transform: translateX(-4px);
}

.sidebar-toggle,
.sidebar-backdrop {
    display: none;
}

/* Dugme "vise" - strelica levo, kad se otvori okrene se na desno */
.sidebar-more-btn {
    width: 52px;
    height: 52px;
    margin-left: 0.6rem;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #ffae06;
    border: 3px solid #ffae06;
    border-radius: 50%;
    background: transparent;
    cursor: pointer;
    transition: background 0.25s ease, color 0.25s ease, transform 0.2s ease;
}

.sidebar-more-btn svg {
    transition: transform 0.5s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.sidebar-more-btn:hover {
    background: rgba(255, 255, 255, 0.25);
    transform: scale(1.08);
}

/* Na hover strelica "gurka" levo */
.sidebar-more-btn:not(.open):hover svg {
    animation: sidebarMoreNudge 0.9s ease-in-out infinite;
}

@keyframes sidebarMoreNudge {
    0%, 100% { transform: translateX(0); }
    50% { transform: translateX(-4px); }
}

.sidebar-more-btn.open {
    background: #ffae06;
    color: #1f4f8f;
}

.sidebar-more-btn.open svg {
    transform: rotate(180deg);
}

/* Strelice jedna pored druge */
.sidebar-more-row {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    margin-left: 0.6rem;
}

.sidebar-more-row .sidebar-more-btn {
    margin-left: 0;
}

/* Druga strelica: stranice samo za super admina - crvenkasta */
.sidebar-admin-btn {
    color: #f87171;
    border-color: #f87171;
}

.sidebar-admin-btn.open {
    background: #f87171;
    color: #fff;
}

/* Ostali linkovi se pojavljuju levo od menija */
.sidebar-more {
    position: fixed;
    top: 50%;
    right: calc(var(--sidebar-width) - 0.5rem);
    max-height: 85vh;
    max-width: calc(100vw - var(--sidebar-width) - 2rem);
    overflow: auto;
    /* Po 5 linkova u koloni, nove kolone se dodaju sa strane */
    display: grid;
    grid-template-rows: repeat(5, auto);
    grid-auto-flow: column;
    grid-auto-columns: max-content;
    gap: 0.5rem 2rem;
    padding: 1.5rem 1.25rem;
    background: rgba(22, 50, 92, 0.92);
    backdrop-filter: blur(10px);
    border-radius: 16px;
    box-shadow: 0 15px 40px rgba(0, 0, 0, 0.25);
    opacity: 0;
    visibility: hidden;
    transform: translate(30px, -50%) scale(0.96);
    transition: opacity 0.3s ease, transform 0.35s cubic-bezier(0.34, 1.56, 0.64, 1), visibility 0.3s;
    z-index: 101;
}

.sidebar-more.open {
    opacity: 1;
    visibility: visible;
    transform: translate(0, -50%) scale(1);
}

.sidebar-more a {
    /* Ista velicina kao linkovi u sidebaru */
    font-size: 1.9rem;
    white-space: nowrap;
    padding: 0.5rem 1rem;
}

.sidebar-more a:hover {
    background: rgba(255, 255, 255, 0.12);
    transform: translateX(-4px);
}

/* Sadrzaj bez kartice - sekcije se stapaju sa pozadinom */
.layout-sidebar main {
    max-width: none;
    margin: 0;
    /* Desno veci razmak da tekst ne dodiruje meni */
    padding: 2rem 6rem 1rem 3rem;
    background: transparent;
    box-shadow: none;
    border-radius: 0;
    color: #fff;
}

.layout-sidebar .hero,
.layout-sidebar .hero-with-logo,
.layout-sidebar .hero-align-left {
    display: flex;
    align-items: center;
    justify-content: flex-start;
    gap: 1.25rem;
    flex-wrap: nowrap;
    flex-direction: row;
    text-align: left;
    padding: 0 3.5rem 0 0;
    margin-bottom: 5rem;
    background: transparent;
    border-radius: 0;
}

body.layout-sidebar .hero .hero-text {
    text-align: left;
}

/* Poravnanje iz hero podesavanja: "Centar" centrira logo i naziv */
body.layout-sidebar .hero:not(.hero-align-left) {
    justify-content: center;
    padding-left: 3.5rem;
}

body.layout-sidebar .hero:not(.hero-align-left):not(.hero-with-logo) .hero-text {
    text-align: center;
}

.layout-sidebar .club-logo {
    width: 160px;
    height: 160px;
    flex-shrink: 0;
}

.layout-sidebar .hero h2,
.layout-sidebar .hero-with-logo .hero-text h2 {
    font-size: 3rem;
    line-height: 1.15;
    margin: 0;
    padding: 0;
}

.layout-sidebar .hero-edit-btn {
    top: 50%;
    right: 0;
    transform: translateY(-50%);
}

.layout-sidebar .hero-edit-btn:hover {
    transform: translateY(-50%) scale(1.1);
}

.layout-sidebar .hero-empty {
    border-color: rgba(255, 255, 255, 0.5);
}

.layout-sidebar .content-section {
    background: transparent;
    border: none;
    border-radius: 0;
    padding: 0;
    margin-bottom: 3rem;
}

.layout-sidebar .content-section h3 {
    font-size: 2rem;
    font-weight: 700;
    color: #fff;
    margin: 0 0 1.25rem;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.15);
}

.layout-sidebar .content-section p,
.layout-sidebar .content-section li {
    color: rgba(255, 255, 255, 0.92);
    font-size: 1.1rem;
    line-height: 1.75;
}

.layout-sidebar .content-section a:not(.btn) {
    color: #fff;
}

.layout-sidebar .section-admin-actions {
    top: 0;
    right: 0;
}

/* "Pogledajte dogadjaje" i "Dodaj sekciju" izgledaju kao obicne sekcije */
.layout-sidebar .cta-section {
    text-align: left;
    background: transparent;
}

.layout-sidebar .add-section-wrapper {
    text-align: left;
    margin: 0 0 2rem;
}

.layout-sidebar .cta-section .btn,
.layout-sidebar .add-section-wrapper .btn {
    background: transparent;
    color: #fff;
    border: 2px solid rgba(255, 255, 255, 0.85);
    box-shadow: none;
    font-size: 1.05rem;
    padding: 0.7rem 1.6rem;
}

.layout-sidebar .cta-section .btn:hover,
.layout-sidebar .add-section-wrapper .btn:hover {
    background: #fff;
    color: var(--primary-dark);
}

/* Mali ekrani - sidebar se otvara preko sendvic dugmeta */
@media (max-width: 768px) {
    .layout-sidebar {
        padding-right: 0;
    }

    .layout-sidebar main {
        padding: 1.25rem 1rem 1rem;
    }

    body.sidebar-open {
        overflow: hidden;
    }

    /* Na telefonu otvoren meni prekriva ceo ekran */
    .site-sidebar {
        width: 100%;
        border-left: none;
        padding: 5rem 1.5rem 2rem;
        background: linear-gradient(135deg, var(--bg-from) 0%, var(--bg-to) 100%);
        transform: translateX(100%);
        transition: transform 0.3s ease;
        z-index: 1001;
    }

    .site-sidebar.open {
        transform: translateX(0);
    }

    .sidebar-nav {
        align-items: center;
        gap: 1.5rem;
    }

    .sidebar-nav a {
        font-size: 2rem;
    }

    .sidebar-nav a:hover {
        transform: none;
    }

    .sidebar-more-btn {
        display: none;
    }

    .sidebar-more,
    .sidebar-more.open {
        position: static;
        display: flex;
        flex-direction: column;
        max-width: none;
        max-height: none;
        overflow: visible;
        align-items: center;
        gap: 1.5rem;
        padding: 0;
        background: transparent;
        backdrop-filter: none;
        box-shadow: none;
        opacity: 1;
        visibility: visible;
        transform: none;
    }

    .sidebar-more a {
        font-size: 2rem;
    }

    .sidebar-toggle {
        position: fixed;
        top: 1rem;
        right: 1rem;
        z-index: 1002;
        width: 44px;
        height: 44px;
        display: flex;
        flex-direction: column;
        justify-content: center;
        align-items: center;
        gap: 5px;
        background: rgba(255, 255, 255, 0.2);
        border: 1px solid rgba(255, 255, 255, 0.35);
        border-radius: 10px;
        backdrop-filter: blur(10px);
        cursor: pointer;
    }

    .sidebar-toggle span {
        display: block;
        width: 22px;
        height: 2px;
        background: #fff;
        border-radius: 2px;
        transition: transform 0.3s ease, opacity 0.2s ease;
    }

    .sidebar-toggle.open span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
    .sidebar-toggle.open span:nth-child(2) { opacity: 0; }
    .sidebar-toggle.open span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

    .sidebar-backdrop {
        display: block;
        position: fixed;
        inset: 0;
        background: rgba(0, 0, 0, 0.35);
        opacity: 0;
        pointer-events: none;
        transition: opacity 0.3s ease;
        z-index: 1000;
    }

    .sidebar-backdrop.open {
        opacity: 1;
        pointer-events: auto;
    }

    /* Mesto za sendvic dugme pored naslova */
    .layout-sidebar .hero {
        margin-bottom: 3.5rem;
    }

    /* Edit dugme ide ispod sendvic dugmeta */
    .layout-sidebar .hero-edit-btn {
        top: auto;
        bottom: -2.75rem;
        transform: none;
    }

    .layout-sidebar .hero-edit-btn:hover {
        transform: scale(1.1);
    }

    .layout-sidebar .club-logo {
        width: 96px;
        height: 96px;
    }

    .layout-sidebar .hero h2,
    .layout-sidebar .hero-with-logo .hero-text h2 {
        font-size: 1.75rem;
    }

    body.layout-sidebar .hero:not(.hero-align-left) {
        padding-left: 0;
    }

    .layout-sidebar .content-section h3 {
        font-size: 1.6rem;
    }
}

/* ===================
   Login - forma levo, slika desno, sidebar meni preko slike
   =================== */

body.layout-sidebar.layout-login {
    padding-right: 0;
}

body.layout-login main,
body.layout-login main.login-page {
    width: 50%;
    max-width: none;
    margin: 0;
    padding: 2.5rem 3rem 1rem;
    display: flex;
    flex-direction: column;
    align-items: center;
}

body.layout-login footer {
    width: 50%;
}

.login-brand {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 1rem;
    min-height: 64px;
}

.login-brand-logo {
    width: 64px;
    height: 64px;
    object-fit: contain;
    border-radius: 12px;
    background: var(--logo-bg);
    padding: calc(var(--logo-pad) * 6);
    box-shadow: var(--logo-shadow);
}

.login-brand-title {
    color: #fff;
    font-size: 1.6rem;
    font-weight: 700;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.15);
}

.login-form-wrap {
    width: 100%;
    max-width: 380px;
    margin: auto 0;
    padding: 2rem 0;
}

body.layout-login main h2 {
    color: #fff;
    font-size: 2rem;
    border: none;
    padding: 0;
    margin: 0 0 0.35rem;
    text-align: left;
}

.login-lead {
    color: rgba(255, 255, 255, 0.85);
    margin-bottom: 1.75rem;
}

body.layout-login .form-group label,
body.layout-login .remember-me-label {
    color: #fff;
}

body.layout-login .form-group input[type="text"],
body.layout-login .form-group input[type="password"] {
    background: #fff;
    border: 2px solid transparent;
    border-radius: 10px;
    padding: 0.8rem 1rem;
}

body.layout-login .form-group input[type="text"]:focus,
body.layout-login .form-group input[type="password"]:focus {
    border-color: #1f4f8f;
    box-shadow: 0 0 0 3px rgba(255, 255, 255, 0.35);
}

body.layout-login .login-form-wrap .btn[type="submit"] {
    width: 100%;
    padding: 0.85rem;
    font-size: 1.05rem;
    background: #0050ff;
    color: #fff;
    border-radius: 10px;
    box-shadow: 0 6px 18px rgba(0, 40, 140, 0.3);
}

body.layout-login .login-form-wrap .btn[type="submit"]:hover {
    background: #0043d6;
    transform: translateY(-1px);
}

/* Desna polovina sa slikom */
.login-visual {
    position: fixed;
    top: 0;
    right: 0;
    bottom: 0;
    width: 50%;
    background-color: #1f4f8f;
    background-size: cover;
    background-position: center;
    z-index: 1;
}

.login-visual::after {
    /* Blago zatamnjenje uz desnu ivicu da meni bude citljiv preko slike */
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(90deg, rgba(0, 0, 0, 0) 55%, rgba(0, 0, 0, 0.35) 100%);
    pointer-events: none;
}

.login-visual-empty {
    background: linear-gradient(135deg, #2e6ab3 0%, #1e5f6b 100%);
}

.login-visual-edit {
    position: absolute;
    left: 1.5rem;
    bottom: 1.5rem;
    z-index: 2;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.6rem 1rem;
    color: #fff;
    font-weight: 600;
    background: rgba(0, 0, 0, 0.35);
    border: 1px solid rgba(255, 255, 255, 0.5);
    border-radius: 10px;
    backdrop-filter: blur(6px);
    cursor: pointer;
    transition: background 0.2s ease;
}

.login-visual-edit:hover {
    background: rgba(0, 0, 0, 0.55);
}

body.layout-login .sidebar-nav > a {
    text-shadow: 0 2px 10px rgba(0, 0, 0, 0.45);
}

@media (max-width: 768px) {
    body.layout-login main,
    body.layout-login main.login-page,
    body.layout-login footer {
        width: 100%;
    }

    body.layout-login main,
    body.layout-login main.login-page {
        padding: 1.25rem 1rem 1rem;
    }

    .login-brand {
        padding-right: 3.5rem;
    }

    .login-visual {
        display: none;
    }
}

/* ===================
   Dogadjaji i Vesti u sidebar izgledu - bez kartica, beli tekst na gradijentu
   =================== */

.layout-sidebar main > h2,
.layout-sidebar main:not(.main-panel) .page-header h2 {
    color: #fff;
    font-size: 2.6rem;
    font-weight: 700;
    border: none;
    padding: 0;
    margin: 0 0 4rem;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.15);
}

.layout-sidebar .events-list,
.layout-sidebar .news-list {
    gap: 0;
}

.layout-sidebar .event-card,
.layout-sidebar .event-card.event-special,
.layout-sidebar .news-card {
    background: transparent;
    border: none;
    border-radius: 0;
    box-shadow: none;
    padding: 0 0 2rem;
    margin: 0 0 3rem;
    border-bottom: 1px solid rgba(255, 255, 255, 0.2);
}

.layout-sidebar .event-card:last-child,
.layout-sidebar .news-card:last-child {
    border-bottom: none;
}

.layout-sidebar .event-card:hover,
.layout-sidebar .news-card:hover {
    transform: none;
    box-shadow: none;
}

.layout-sidebar .event-card h3,
.layout-sidebar .event-card-header h3,
.layout-sidebar .news-card h3,
.layout-sidebar .news-header h3 {
    color: #fff;
    font-size: 1.8rem;
    font-weight: 700;
    margin: 0 0 0.75rem;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.15);
}

.layout-sidebar .event-card-link {
    color: inherit;
}

.layout-sidebar .event-card-date {
    background: transparent;
    border: none;
    padding: 0;
    margin-bottom: 1rem;
    color: #fff;
}

.layout-sidebar .event-card-date svg {
    color: #fff;
}

.layout-sidebar .event-card-date-value,
.layout-sidebar .event-card-time-value {
    color: #fff;
    font-size: 1.15rem;
}

.layout-sidebar .event-description,
.layout-sidebar .event-meta,
.layout-sidebar .event-meta *,
.layout-sidebar .event-price,
.layout-sidebar .event-guide,
.layout-sidebar .event-deadline,
.layout-sidebar .event-installments,
.layout-sidebar .news-content,
.layout-sidebar .news-content p {
    color: rgba(255, 255, 255, 0.92);
}

.layout-sidebar .event-description,
.layout-sidebar .news-content {
    font-size: 1.1rem;
    line-height: 1.75;
}

.layout-sidebar .event-price-value {
    color: #fff;
}

.layout-sidebar .news-content a,
.layout-sidebar .event-description a {
    color: #fff;
    text-decoration: underline;
}

.layout-sidebar .news-image img {
    border-radius: 12px;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.2);
    max-height: 380px;
    max-width: 100%;
}

@media (max-width: 768px) {
    .layout-sidebar .news-image img {
        max-height: 280px;
    }
}

.layout-sidebar .news-footer {
    border-top: none;
    padding-top: 0.75rem;
}

.layout-sidebar .news-meta,
.layout-sidebar .news-meta *,
.layout-sidebar .news-date,
.layout-sidebar .news-author,
.layout-sidebar .news-view-count {
    color: rgba(255, 255, 255, 0.8);
}

/* Broj pregleda ispod naslova sekcije na pocetnoj */
.section-views {
    margin: -0.25rem 0 0.75rem;
}

/* Pregledi iz aplikacije (telefon) odmah posle pregleda sa sajta (oko) */
.news-view-count + .news-view-count {
    margin-left: 0.6rem;
}

@media (max-width: 768px) {
    .layout-sidebar main > h2,
    .layout-sidebar main:not(.main-panel) .page-header h2 {
        font-size: 2rem;
        padding-right: 3.5rem;
        margin-bottom: 2.75rem;
    }

    .layout-sidebar .event-card h3,
    .layout-sidebar .event-card-header h3,
    .layout-sidebar .news-card h3,
    .layout-sidebar .news-header h3 {
        font-size: 1.45rem;
    }
}

.layout-sidebar .event-card.event-special {
    animation: none;
}

/* Poseban dogadjaj u novom izgledu: narandzast naslov sa senkom i blagim sjajem */
.layout-sidebar .event-card.event-special h3,
.layout-sidebar .event-card.event-special .event-card-header h3 {
    color: #ffb74d;
    font-weight: 800;
    text-shadow: 0 2px 3px rgba(0, 0, 0, 0.45),
                 0 0 12px rgba(255, 152, 0, 0.45);
    animation: special-title-glow 2.5s ease-in-out infinite;
}

/* Zvezdica ispred naslova posebnog dogadjaja */
.layout-sidebar .event-card.event-special h3::before {
    content: "★";
    display: inline-block;
    margin-right: 0.45rem;
    color: #ffca28;
    text-shadow: 0 2px 3px rgba(0, 0, 0, 0.45),
                 0 0 10px rgba(255, 193, 7, 0.8);
    animation: star-pulse 2s ease-in-out infinite;
}

@keyframes special-title-glow {
    0%, 100% {
        text-shadow: 0 2px 3px rgba(0, 0, 0, 0.45),
                     0 0 8px rgba(255, 152, 0, 0.3);
    }
    50% {
        text-shadow: 0 2px 3px rgba(0, 0, 0, 0.45),
                     0 0 18px rgba(255, 167, 38, 0.75);
    }
}

@media (prefers-reduced-motion: reduce) {
    .layout-sidebar .event-card.event-special h3,
    .layout-sidebar .event-card.event-special h3::before {
        animation: none;
    }
}

/* Logo i naziv na vrhu stranica (Dogadjaji, Vesti...) */
.page-brand {
    display: inline-flex;
    align-items: center;
    gap: 1.1rem;
    margin-bottom: 3rem;
    text-decoration: none;
}

.page-brand-logo {
    width: 96px;
    height: 96px;
    object-fit: contain;
    border-radius: 12px;
    background: var(--logo-bg);
    padding: calc(var(--logo-pad) * 8);
    box-shadow: var(--logo-shadow);
    flex-shrink: 0;
}

.page-brand-title {
    color: #fff;
    font-size: 2.2rem;
    font-weight: 700;
    line-height: 1.15;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.15);
}

@media (max-width: 768px) {
    .page-brand {
        padding-right: 3.5rem;
        margin-bottom: 2rem;
        gap: 0.8rem;
    }

    .page-brand-logo {
        width: 64px;
        height: 64px;
    }

    .page-brand-title {
        font-size: 1.5rem;
    }
}

/* Vesti: slika pored teksta zauzima vise mesta */
.layout-sidebar .news-body-left,
.layout-sidebar .news-body-right {
    gap: 2rem;
}

.layout-sidebar .news-body-left .news-image,
.layout-sidebar .news-body-right .news-image {
    width: min(34%, 380px);
}

.layout-sidebar .news-body-left .news-image img,
.layout-sidebar .news-body-right .news-image img {
    width: 100%;
    height: auto;
    max-height: 480px;
    object-fit: cover;
}

@media (max-width: 768px) {
    .layout-sidebar .news-body-left .news-image,
    .layout-sidebar .news-body-right .news-image {
        width: 100%;
    }

    .layout-sidebar .news-body-left .news-image img,
    .layout-sidebar .news-body-right .news-image img {
        max-height: 380px;
    }
}

.layout-sidebar .news-body-left .news-image a,
.layout-sidebar .news-body-right .news-image a {
    display: block;
    width: 100%;
}

/* Modal za dogadjaj: na sirem ekranu dve kolone umesto skrola */
@media (min-width: 1100px) {
    #eventModal .modal-dialog.modal-large {
        max-width: 1180px;
        max-height: 94vh;
        padding: 1.75rem 2.25rem;
    }

    #eventModal .event-form-grid {
        display: grid;
        grid-template-columns: 1fr 1fr;
        gap: 0 2.5rem;
        align-items: start;
        text-align: left;
    }

    #eventModal .event-form-col {
        min-width: 0;
    }

    #eventModal #modal_description {
        min-height: 300px;
    }

    #eventModal .modal-header {
        margin-bottom: 1rem;
    }

    #eventModal .form-group {
        margin-bottom: 0.9rem;
    }
}

/* Modal za vest: isto dve kolone na sirem ekranu (levo tekst, desno slika i datumi) */
@media (min-width: 1100px) {
    #newsModal .modal-dialog.modal-large {
        max-width: 1180px;
        max-height: 94vh;
        padding: 1.75rem 2.25rem;
    }

    #newsModal .news-form-grid {
        display: grid;
        grid-template-columns: 1fr 1fr;
        gap: 0 2.5rem;
        align-items: start;
        text-align: left;
    }

    #newsModal .news-form-col {
        min-width: 0;
    }

    #newsModal #news_content {
        min-height: 420px;
    }

    #newsModal .modal-header {
        margin-bottom: 1rem;
    }

    #newsModal .form-group {
        margin-bottom: 0.9rem;
    }
}

/* Admin zaglavlje (Dogadjaji/Vesti) u sidebar izgledu */
.layout-sidebar .page-header-with-toggle {
    margin-bottom: 1.25rem;
    align-items: flex-end;
}

.layout-sidebar .page-header-with-toggle h2 {
    color: #fff;
    font-size: 2.6rem;
    font-weight: 700;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.15);
}

.layout-sidebar .header-actions {
    gap: 0.75rem;
}

.layout-sidebar .header-actions .btn {
    padding: 0.8rem 1.5rem;
    font-size: 1rem;
    border-radius: 10px;
}

/* Glavna akcija - puna plava kao dugme na loginu */
.layout-sidebar .header-actions .btn:not(.btn-secondary) {
    background: #0050ff;
    color: #fff;
    box-shadow: 0 6px 18px rgba(0, 40, 140, 0.3);
}

.layout-sidebar .header-actions .btn:not(.btn-secondary):hover {
    background: #0043d6;
}

/* Sporedna akcija - beli okvir */
.layout-sidebar .header-actions .btn-secondary {
    background: transparent;
    color: #fff;
    border: 2px solid rgba(255, 255, 255, 0.85);
    box-shadow: none;
}

.layout-sidebar .header-actions .btn-secondary:hover {
    background: #fff;
    color: var(--primary-dark);
}

.layout-sidebar main:not(.main-panel) .member-stats {
    gap: 0.6rem;
    flex-wrap: wrap;
    border-bottom: none;
    padding: 0;
    margin-bottom: 3rem;
}

.layout-sidebar main:not(.main-panel) .member-stats .stat {
    font-size: 0.95rem;
    color: #fff;
    background: rgba(255, 255, 255, 0.18);
    border: 1px solid rgba(255, 255, 255, 0.3);
    padding: 0.4rem 0.9rem;
    border-radius: 20px;
}

.layout-sidebar main:not(.main-panel) .member-stats .stat strong,
.layout-sidebar main:not(.main-panel) .member-stats .stat-active strong,
.layout-sidebar main:not(.main-panel) .member-stats .stat-inactive strong {
    color: #fff;
    font-weight: 800;
}

.layout-sidebar main:not(.main-panel) .member-stats .stat-active {
    background: rgba(16, 185, 129, 0.35);
    border-color: rgba(16, 185, 129, 0.6);
}

.layout-sidebar main:not(.main-panel) .member-stats .stat-inactive {
    background: rgba(239, 68, 68, 0.3);
    border-color: rgba(239, 68, 68, 0.55);
}

/* Filteri "Svi / Moje prijave / Bez prijave" */
.layout-sidebar .event-filter-toggle {
    margin-bottom: 2.5rem;
    gap: 0.5rem;
}

.layout-sidebar .event-filter-btn {
    padding: 0.5rem 1.1rem !important;
    font-size: 0.95rem !important;
}

.layout-sidebar .event-filter-btn.active {
    background: #fff !important;
    color: var(--primary-dark) !important;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15) !important;
}

.layout-sidebar .event-filter-btn:not(.active) {
    background: rgba(255, 255, 255, 0.15) !important;
    border: 1px solid rgba(255, 255, 255, 0.4);
    color: #fff !important;
}

.layout-sidebar .event-filter-btn:not(.active):hover {
    background: rgba(255, 255, 255, 0.28) !important;
    border-color: #fff;
    color: #fff !important;
}

.layout-sidebar main:not(.main-panel) .empty-state,
.layout-sidebar main:not(.main-panel) .empty-state p {
    color: rgba(255, 255, 255, 0.85);
}

@media (max-width: 768px) {
    .layout-sidebar .page-header-with-toggle {
        padding-right: 3.5rem;
    }

    .layout-sidebar .page-header-with-toggle h2 {
        font-size: 2rem;
    }
}

/* Galerija u sidebar izgledu */
.layout-sidebar .gallery-list {
    gap: 0;
    margin-top: 0;
}

.layout-sidebar .gallery-card {
    background: transparent;
    border: none;
    border-radius: 0;
    box-shadow: none;
    padding: 0 0 2.5rem;
    margin-bottom: 2.5rem;
    border-bottom: 1px solid rgba(255, 255, 255, 0.2);
}

.layout-sidebar .gallery-card:last-child {
    border-bottom: none;
}

.layout-sidebar .gallery-card:hover {
    transform: none;
    box-shadow: none;
}

.layout-sidebar .gallery-header {
    margin-bottom: 1rem;
}

.layout-sidebar .gallery-title-row h3 {
    color: #fff;
    font-size: 1.8rem;
    font-weight: 700;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.15);
}

.layout-sidebar .gallery-date {
    color: #fff;
    font-size: 1.1rem;
    font-weight: 600;
    margin-top: 0.5rem;
}

.layout-sidebar .gallery-description {
    color: rgba(255, 255, 255, 0.92);
    font-size: 1.1rem;
    line-height: 1.75;
    margin-bottom: 1.25rem;
}

.layout-sidebar .gallery-thumbs {
    background: transparent;
    border: none;
    padding: 0;
    gap: 1rem;
    margin-bottom: 1rem;
}

.layout-sidebar .gallery-thumb-link {
    border-radius: 12px;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.2);
}

.layout-sidebar .gallery-footer {
    border-top: none;
}

.layout-sidebar .gallery-meta,
.layout-sidebar .gallery-image-count {
    color: rgba(255, 255, 255, 0.8);
}

/* Srce za lajkove (galerija i vesti) na gradijentu */
.layout-sidebar .like-btn,
.layout-sidebar .like-display {
    color: rgba(255, 255, 255, 0.85);
}

.layout-sidebar .like-btn:hover {
    color: #fff;
    background: rgba(255, 255, 255, 0.15);
}

.layout-sidebar .like-btn.liked {
    color: #ff8a8a;
}

/* Srce u vestima i galeriji - vece (vidi se samo prijavljenima), odvojeno
   od broja slika i pregleda */
.like-btn-lg {
    font-size: 1.05rem;
    gap: 6px;
    margin-left: 0.6rem;
}

@media (max-width: 768px) {
    .layout-sidebar .gallery-thumbs {
        grid-template-columns: repeat(2, 1fr);
        gap: 0.6rem;
    }

    .layout-sidebar .gallery-title-row h3 {
        font-size: 1.45rem;
    }
}

/* Razmak ispod admin naslova stranice (Galerija nema statistiku ispod) */
.layout-sidebar .page-header-with-toggle {
    margin-bottom: 4rem;
}

.layout-sidebar .page-header-with-toggle:has(+ .member-stats) {
    margin-bottom: 1.25rem;
}

/* Modal za galeriju: na sirem ekranu dve kolone, veci opis */
@media (min-width: 1100px) {
    #galleryModal .modal-dialog.modal-large {
        max-width: 1100px;
        max-height: 94vh;
        padding: 1.75rem 2.25rem;
    }

    #galleryModal .modal-form-grid {
        display: grid;
        grid-template-columns: 1fr 1fr;
        gap: 0 2.5rem;
        align-items: start;
        text-align: left;
    }

    #galleryModal .modal-form-col {
        min-width: 0;
    }

    #galleryModal #gallery_description {
        min-height: 320px;
    }
}

/* Footer u sidebar izgledu: tekst levo, pa razmak, pa politika privatnosti */
.layout-sidebar footer {
    flex-direction: row;
    justify-content: flex-start;
    align-items: center;
    gap: 2.5rem;
    padding-left: 3rem;
    padding-right: 3rem;
    text-align: left;
}

.layout-sidebar footer .footer-main {
    order: 1;
    justify-content: flex-start;
}

.layout-sidebar footer .footer-main p,
.layout-sidebar footer .footer-legal {
    font-size: 0.85rem;
}

.layout-sidebar footer .footer-main p {
    margin: 0;
}

.layout-sidebar footer .footer-legal {
    order: 2;
}

@media (max-width: 768px) {
    .layout-sidebar footer {
        padding-left: 1rem;
        padding-right: 1rem;
        gap: 1.5rem;
    }
}

/* Politika privatnosti u sidebar izgledu */
.layout-sidebar .privacy-page {
    max-width: 960px !important;
    margin: 0 !important;
    background: transparent;
    border: none;
    box-shadow: none;
    padding: 0;
}

.layout-sidebar .privacy-page .card-header {
    background: transparent;
    border: none;
    padding: 0;
    margin-bottom: 2.5rem;
}

.layout-sidebar .privacy-head h2 {
    color: #fff;
    font-size: 2.6rem;
    font-weight: 700;
    border: none;
    padding: 0;
    margin: 0;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.15);
}

.layout-sidebar .privacy-meta {
    color: rgba(255, 255, 255, 0.8);
    font-size: 0.95rem;
}

.layout-sidebar .privacy-lang {
    color: #fff;
    border: 2px solid rgba(255, 255, 255, 0.85);
    padding: 0.45rem 1rem;
    font-size: 0.9rem;
}

.layout-sidebar .privacy-lang:hover {
    background: #fff;
    color: var(--primary-dark);
}

.layout-sidebar .privacy-body {
    padding: 0;
    color: rgba(255, 255, 255, 0.92);
}

.layout-sidebar .privacy-body h3 {
    color: #fff;
    font-size: 1.6rem;
    font-weight: 700;
    border-bottom: none;
    padding-bottom: 0;
    margin: 2.75rem 0 1rem;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.15);
}

.layout-sidebar .privacy-body h3:first-child {
    margin-top: 0;
}

.layout-sidebar .privacy-body h4 {
    color: #fff;
    font-size: 1.15rem;
    margin: 1.5rem 0 0.5rem;
}

.layout-sidebar .privacy-body p,
.layout-sidebar .privacy-body ul {
    font-size: 1.05rem;
    line-height: 1.75;
}

.layout-sidebar .privacy-body strong {
    color: #fff;
}

.layout-sidebar .privacy-body a {
    color: #fff;
}

@media (max-width: 768px) {
    .layout-sidebar .privacy-head h2 {
        font-size: 2rem;
    }

    .layout-sidebar .privacy-body h3 {
        font-size: 1.35rem;
    }
}

/* Brisanje naloga - forma na gradijentu */
.layout-sidebar .privacy-page .settings-stack {
    max-width: 560px;
}

.layout-sidebar .privacy-page .form-group label {
    color: #fff;
    font-weight: 600;
}

.layout-sidebar .privacy-page .form-group small {
    color: rgba(255, 255, 255, 0.75);
}

.layout-sidebar .privacy-page .form-group input,
.layout-sidebar .privacy-page .form-group textarea {
    background: #fff;
    border: 2px solid transparent;
    border-radius: 10px;
    padding: 0.8rem 1rem;
}

.layout-sidebar .privacy-page .form-group input:focus,
.layout-sidebar .privacy-page .form-group textarea:focus {
    border-color: #1f4f8f;
    box-shadow: 0 0 0 3px rgba(255, 255, 255, 0.35);
}

.layout-sidebar .privacy-page .btn-danger {
    padding: 0.85rem 1.75rem;
    font-size: 1.05rem;
    border-radius: 10px;
    box-shadow: 0 6px 18px rgba(127, 29, 29, 0.3);
}

/* Pocetna: slika pored teksta sekcije zauzima vise mesta */
.layout-sidebar .section-body-left,
.layout-sidebar .section-body-right {
    gap: 2rem;
}

.layout-sidebar .section-body-left .section-image,
.layout-sidebar .section-body-right .section-image {
    width: min(34%, 420px);
}

.layout-sidebar .section-body-left .section-image img,
.layout-sidebar .section-body-right .section-image img {
    width: 100%;
    height: auto;
    max-height: 420px;
    object-fit: cover;
    border-radius: 12px;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.2);
}

@media (max-width: 768px) {
    .layout-sidebar .section-body-left,
    .layout-sidebar .section-body-right {
        flex-direction: column;
        gap: 1rem;
    }

    .layout-sidebar .section-body-left .section-image,
    .layout-sidebar .section-body-right .section-image {
        width: 100%;
    }

    .layout-sidebar .section-body-left .section-image img,
    .layout-sidebar .section-body-right .section-image img {
        max-height: 360px;
    }
}

/* Slike pored teksta (pocetna i vesti) se prikazuju cele, bez secenja */
.layout-sidebar .section-body-left .section-image img,
.layout-sidebar .section-body-right .section-image img,
.layout-sidebar .news-body-left .news-image img,
.layout-sidebar .news-body-right .news-image img {
    max-height: none;
    height: auto;
    object-fit: contain;
}
