/* ============================================
   EVENT GALLERY STYLES - COMPLETE
   ============================================ */

/* ----- Event Cards ----- */
.event-card {
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    border: none;
    border-radius: 12px;
    overflow: hidden;
    background: white;
}
.event-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.12);
}
.event-card .card-img-top {
    transition: transform 0.5s ease;
}
.event-card:hover .card-img-top {
    transform: scale(1.05);
}
.event-meta div {
    margin-bottom: 4px;
    font-size: 0.85rem;
}
.event-meta i {
    width: 20px;
    color: #1a237e;
}

/* ----- Photo Grid ----- */
.photo-card {
    position: relative;
    overflow: hidden;
    border-radius: 8px;
    cursor: pointer;
    transition: transform 0.3s ease;
}
.photo-card:hover {
    transform: scale(1.03);
}
.photo-card img {
    transition: filter 0.3s ease;
    width: 100%;
    height: 200px;
    object-fit: cover;
}
.photo-card:hover img {
    filter: brightness(0.9);
}
.photo-caption {
    font-size: 0.8rem;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    padding: 4px 8px;
    background: rgba(255, 255, 255, 0.9);
    border-radius: 0 0 8px 8px;
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    transform: translateY(100%);
    transition: transform 0.3s ease;
}
.photo-card:hover .photo-caption {
    transform: translateY(0);
}

/* ----- Comments ----- */
.comment-item {
    transition: background-color 0.3s ease;
    border-radius: 8px;
    padding: 15px;
    margin-bottom: 12px;
}
.comment-item:hover {
    background-color: #f0f2ff !important;
}
.comment-item .comment-content {
    font-size: 0.95rem;
    line-height: 1.6;
    margin-top: 4px;
    word-wrap: break-word;
}
.comment-item .comment-content .short-content,
.comment-item .comment-content .full-content {
    transition: all 0.3s ease;
}
.comment-item .comment-content .read-more-btn {
    color: #1a237e;
    cursor: pointer;
    font-weight: 500;
    transition: color 0.3s ease;
}
.comment-item .comment-content .read-more-btn:hover {
    color: #4caf50;
    text-decoration: underline;
}

/* Replies */
.replies-container {
    border-left: 2px solid #1a237e;
    padding-left: 20px;
    margin-top: 10px;
}
.replies-container .comment-item {
    background-color: #f8f9fa;
}
.replies-container .comment-item:hover {
    background-color: #e9ecef !important;
}
.reply-indicator {
    font-size: 0.75rem;
    color: #6c757d;
    display: flex;
    align-items: center;
    gap: 4px;
}

/* ----- Reactions ----- */
.reactions {
    display: flex;
    align-items: center;
    gap: 4px;
    flex-wrap: wrap;
    margin-top: 8px;
}
.reaction-btn {
    border: 1px solid #dee2e6;
    background: transparent;
    padding: 2px 10px;
    border-radius: 20px;
    font-size: 0.85rem;
    transition: all 0.2s ease;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    gap: 4px;
}
.reaction-btn:hover {
    background: #e8eaf6;
    transform: scale(1.05);
}
.reaction-btn.active {
    background: #1a237e;
    border-color: #1a237e;
    color: white;
}
.reaction-btn.active:hover {
    background: #283593;
    transform: scale(1.05);
}
.reaction-count {
    font-size: 0.75rem;
    min-width: 16px;
    text-align: center;
}
.reaction-btn.active .reaction-count {
    color: white;
}
.reaction-emoji {
    font-size: 1.1rem;
    line-height: 1;
}

/* Reaction animation */
@keyframes reactionPop {
    0% { transform: scale(1); }
    50% { transform: scale(1.4); }
    100% { transform: scale(1); }
}
.reaction-pop {
    animation: reactionPop 0.3s ease;
}

/* ----- Comment Actions ----- */
.comment-actions {
    display: flex;
    gap: 4px;
    flex-wrap: wrap;
}
.comment-actions .btn {
    font-size: 0.75rem;
    padding: 2px 8px;
}
.comment-actions .btn-outline-primary:hover {
    background: #1a237e;
    color: white;
}
.comment-actions .btn-outline-danger:hover {
    background: #dc3545;
    color: white;
}
.comment-actions .btn-outline-secondary:hover {
    background: #6c757d;
    color: white;
}

/* ----- Lightbox ----- */
.lightbox-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.9);
    z-index: 9999;
    display: none;
    justify-content: center;
    align-items: center;
    cursor: pointer;
}
.lightbox-overlay.active {
    display: flex;
}
.lightbox-content {
    max-width: 90%;
    max-height: 90%;
    position: relative;
}
.lightbox-content img {
    max-width: 100%;
    max-height: 80vh;
    border-radius: 8px;
    object-fit: contain;
}
.lightbox-content .lightbox-caption {
    color: white;
    text-align: center;
    padding: 15px;
    font-size: 1rem;
}
.lightbox-close {
    position: absolute;
    top: -40px;
    right: -40px;
    color: white;
    font-size: 2rem;
    cursor: pointer;
    background: none;
    border: none;
    transition: transform 0.3s ease;
}
.lightbox-close:hover {
    transform: rotate(90deg);
}
.lightbox-nav {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    color: white;
    font-size: 2rem;
    cursor: pointer;
    background: rgba(0, 0, 0, 0.5);
    padding: 15px;
    border: none;
    border-radius: 50%;
    transition: background 0.3s ease;
    width: 50px;
    height: 50px;
    display: flex;
    align-items: center;
    justify-content: center;
}
.lightbox-nav:hover {
    background: rgba(0, 0, 0, 0.8);
}
.lightbox-nav.prev {
    left: -70px;
}
.lightbox-nav.next {
    right: -70px;
}

/* ----- Form Elements ----- */
.comment-form textarea {
    border-radius: 10px;
    border: 2px solid #e0e0e0;
    padding: 12px;
    transition: border-color 0.3s ease;
}
.comment-form textarea:focus {
    border-color: #1a237e;
    box-shadow: 0 0 0 0.2rem rgba(26, 35, 126, 0.25);
}
.comment-form .char-count {
    font-size: 0.8rem;
    color: #666;
}
.comment-form .char-count.warning {
    color: #ff9800;
}
.comment-form .char-count.danger {
    color: #f44336;
}

/* ----- Reply Mode ----- */
.reply-mode {
    background: #e3f2fd;
    border-radius: 8px;
    padding: 10px 15px;
    margin-bottom: 10px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}
.reply-mode .reply-to {
    color: #1a237e;
    font-weight: 500;
}
.reply-mode .cancel-reply {
    cursor: pointer;
    color: #dc3545;
    font-weight: 500;
}
.reply-mode .cancel-reply:hover {
    text-decoration: underline;
}

/* ----- Admin Tables ----- */
.admin-event-table .flagged-badge {
    background: #ff9800;
    color: white;
    padding: 2px 8px;
    border-radius: 12px;
    font-size: 0.75rem;
}
.admin-event-table .reported-badge {
    background: #f44336;
    color: white;
    padding: 2px 8px;
    border-radius: 12px;
    font-size: 0.75rem;
    animation: pulse 2s infinite;
}
@keyframes pulse {
    0% { opacity: 1; }
    50% { opacity: 0.6; }
    100% { opacity: 1; }
}

/* ----- Report Modal ----- */
.report-modal .modal-header {
    background: #f44336;
    color: white;
}
.report-modal .modal-header .btn-close {
    filter: brightness(0) invert(1);
}
.report-reason-select {
    border-radius: 8px;
    padding: 10px;
    border: 2px solid #e0e0e0;
}
.report-reason-select:focus {
    border-color: #f44336;
    box-shadow: 0 0 0 0.2rem rgba(244, 67, 54, 0.25);
}

/* ----- Loading States ----- */
.loading-spinner {
    display: inline-block;
    width: 20px;
    height: 20px;
    border: 3px solid rgba(0, 0, 0, 0.1);
    border-top-color: #1a237e;
    border-radius: 50%;
    animation: spin 0.8s linear infinite;
}
@keyframes spin {
    to { transform: rotate(360deg); }
}

/* ----- Toast Notifications ----- */
.toast-container {
    position: fixed;
    top: 80px;
    right: 20px;
    z-index: 1050;
}
.toast-message {
    background: white;
    padding: 15px 20px;
    border-radius: 8px;
    box-shadow: 0 4px 15px rgba(0,0,0,0.15);
    margin-bottom: 10px;
    min-width: 250px;
    animation: slideIn 0.3s ease;
}
.toast-message.success {
    border-left: 4px solid #28a745;
}
.toast-message.error {
    border-left: 4px solid #dc3545;
}
.toast-message.info {
    border-left: 4px solid #17a2b8;
}
@keyframes slideIn {
    from { transform: translateX(100%); opacity: 0; }
    to { transform: translateX(0); opacity: 1; }
}
@keyframes slideOut {
    from { transform: translateX(0); opacity: 1; }
    to { transform: translateX(100%); opacity: 0; }
}

/* ----- Responsive ----- */
@media (max-width: 768px) {
    .lightbox-nav {
        width: 35px;
        height: 35px;
        font-size: 1.2rem;
    }
    .lightbox-nav.prev { left: 10px; }
    .lightbox-nav.next { right: 10px; }
    .lightbox-close {
        top: 10px;
        right: 10px;
        font-size: 1.5rem;
    }
    .reaction-btn {
        padding: 2px 6px;
        font-size: 0.75rem;
    }
    .comment-item .comment-content {
        font-size: 0.85rem;
    }
    .replies-container {
        padding-left: 10px;
    }
    .comment-actions .btn {
        font-size: 0.65rem;
        padding: 1px 6px;
    }
}

/* ----- Dark Mode Support ----- */
@media (prefers-color-scheme: dark) {
    .event-card {
        background: #2d2d2d;
        color: #e0e0e0;
    }
    .comment-item {
        background: #2d2d2d !important;
        color: #e0e0e0;
    }
    .comment-item:hover {
        background: #3d3d3d !important;
    }
    .replies-container .comment-item {
        background: #3d3d3d !important;
    }
    .replies-container .comment-item:hover {
        background: #4d4d4d !important;
    }
    .reaction-btn {
        border-color: #555;
        color: #e0e0e0;
    }
    .reaction-btn:hover {
        background: #444;
    }
    .reaction-btn.active {
        background: #1a237e;
        border-color: #1a237e;
        color: white;
    }
    .stat-card {
        background: #2d2d2d;
        color: #e0e0e0;
    }
}