/* Modern, responsive styles for Consulado Ecuador Events System */

:root {
    --primary-color: #7c3aed;
    --primary-hover: #6b21a8;
    --secondary-color: #64748b;
    --success-color: #10b981;
    --danger-color: #ef4444;
    --warning-color: #f59e0b;
    --info-color: #a855f7;
    --light-bg: #f8fafc;
    --border-color: #e2e8f0;
    --text-primary: #1f2937;
    --text-secondary: #6b7280;
    --shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
    --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
    --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.1);
    --transition: all 0.3s ease;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
    line-height: 1.6;
    color: var(--text-primary);
    background: var(--light-bg);
    overflow-x: hidden;
    max-width: 100vw;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

/* Header */
.main-header {
    background: linear-gradient(135deg, #6b21a8 0%, #a855f7 100%);
    color: #fff;
    padding: 20px 0;
    box-shadow: var(--shadow-md);
}

.header-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 20px;
}

.logo-section {
    display: flex;
    align-items: center;
    gap: 15px;
}

.logo-img {
    height: 60px;
    width: auto;
}

.logo-text {
    display: flex;
    flex-direction: column;
}

.logo-title {
    font-size: 1.5rem;
    font-weight: 700;
    line-height: 1.2;
}

.logo-subtitle {
    font-size: 1.2rem;
    font-weight: 500;
    opacity: 0.95;
}

.header-actions {
    display: flex;
    gap: 15px;
    align-items: center;
}

.lang-switcher, .admin-link, .back-link {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 10px 20px;
    background: rgba(255, 255, 255, 0.2);
    color: #fff;
    text-decoration: none;
    border-radius: 8px;
    transition: var(--transition);
    font-weight: 500;
}

.lang-switcher:hover, .admin-link:hover, .back-link:hover {
    background: rgba(255, 255, 255, 0.3);
    transform: translateY(-2px);
}

/* Main Content */
.main-content {
    padding: 40px 0;
    min-height: calc(100vh - 200px);
}

.page-header {
    margin-bottom: 30px;
}

.page-header h1 {
    font-size: 2.5rem;
    color: var(--text-primary);
    display: flex;
    align-items: center;
    gap: 15px;
}

/* Events Grid */
.events-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(350px, 1fr));
    gap: 30px;
    margin-top: 30px;
    align-items: stretch;
}

.event-card {
    background: #fff;
    border-radius: 12px;
    box-shadow: var(--shadow-md);
    overflow: hidden;
    transition: var(--transition);
    display: flex;
    flex-direction: column;
}

.event-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-lg);
}

.event-card-image {
    width: 100%;
    max-height: 250px;
    overflow: hidden;
    background: var(--light-bg);
    display: flex;
    align-items: center;
    justify-content: center;
}

.event-card-image-link {
    display: block;
    text-decoration: none;
    transition: opacity 0.2s;
    width: 100%;
    max-height: 250px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.event-card-image-link:hover {
    opacity: 0.85;
}

.event-card-image img {
    width: auto;
    height: auto;
    max-width: 100%;
    max-height: 250px;
    object-fit: contain;
    display: block;
}

.event-card-header {
    padding: 12px 15px;
    background: var(--light-bg);
    border-bottom: 2px solid var(--border-color);
}

.event-badge {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 6px 12px;
    border-radius: 20px;
    font-size: 0.875rem;
    font-weight: 600;
}

.badge-zoom {
    background: #dbeafe;
    color: #7c3aed;
}

.badge-inperson {
    background: #d1fae5;
    color: #166534;
}

.badge-hidden {
    background: #fef3c7;
    color: #92400e;
    font-size: 0.75rem;
}

.event-card-body {
    padding: 15px;
    flex: 1;
}

.event-title {
    font-size: 1.5rem;
    color: var(--text-primary);
    margin-bottom: 12px;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.event-description {
    color: var(--text-secondary);
    margin-bottom: 15px;
    line-height: 1.6;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.event-meta {
    display: flex;
    flex-direction: column;
    gap: 10px;
    margin-bottom: 15px;
}

.meta-item {
    display: flex;
    align-items: center;
    gap: 10px;
    color: var(--text-secondary);
    font-size: 0.95rem;
}

.meta-item i {
    color: var(--primary-color);
    width: 20px;
}

.location-link {
    color: var(--primary-color);
    text-decoration: none;
    transition: var(--transition);
}

.location-link:hover {
    color: var(--primary-hover);
    text-decoration: underline;
}

.spots-indicator {
    padding: 10px;
    border-radius: 8px;
    font-weight: 600;
    text-align: center;
    margin-top: 15px;
}

.spots-indicator {
    background: #d1fae5;
    color: #166534;
}

.spots-low {
    background: #fef3c7;
    color: #78350f;
}

.spots-full {
    background: #fee2e2;
    color: #991b1b;
}

/* Countdown Timer */
.countdown-timer {
    background: linear-gradient(135deg, #faf5ff 0%, #f3e8ff 100%);
    border: 2px solid #a855f7;
    border-radius: 12px;
    padding: 12px;
    margin: 12px 0;
    min-height: 95px;
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.countdown-label {
    text-align: center;
    font-weight: 600;
    color: #6b21a8;
    margin-bottom: 10px;
    font-size: 0.95rem;
}

.countdown-display {
    display: flex;
    justify-content: space-around;
    gap: 10px;
}

.countdown-unit {
    display: flex;
    flex-direction: column;
    align-items: center;
    min-width: 50px;
}

.countdown-number {
    font-size: 1.8rem;
    font-weight: 700;
    color: #7c3aed;
    line-height: 1;
}

.countdown-text {
    font-size: 0.75rem;
    color: #6b7280;
    margin-top: 4px;
    text-transform: uppercase;
}

.event-card-footer {
    padding: 15px;
    background: var(--light-bg);
    border-top: 1px solid var(--border-color);
    margin-top: auto;
}

/* Buttons */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 12px 24px;
    border: none;
    border-radius: 8px;
    font-weight: 600;
    font-size: 1rem;
    cursor: pointer;
    transition: var(--transition);
    text-decoration: none;
    text-align: center;
}

.btn-primary {
    background: var(--primary-color);
    color: #fff;
}

.btn-primary:hover {
    background: var(--primary-hover);
    transform: translateY(-2px);
    box-shadow: var(--shadow-md);
}

.btn-secondary {
    background: var(--secondary-color);
    color: #fff;
}

.btn-secondary:hover {
    background: #475569;
}

.btn-danger {
    background: var(--danger-color);
    color: #fff;
}

.btn-danger:hover {
    background: #dc2626;
}

.btn-success {
    background: var(--success-color);
    color: #fff;
}

.btn-info {
    background: var(--info-color);
    color: #fff;
}

.btn-zoom {
    background: #2563eb;
    color: #fff;
}

.btn-disabled {
    background: #9ca3af;
    color: #fff;
    cursor: not-allowed;
}

.btn-block {
    width: 100%;
}

.btn-lg {
    padding: 14px 28px;
    font-size: 1.1rem;
}

.btn-sm {
    padding: 6px 12px;
    font-size: 0.875rem;
}

/* Forms */
.form-control {
    width: 100%;
    padding: 12px;
    border: 2px solid var(--border-color);
    border-radius: 8px;
    font-size: 1rem;
    transition: var(--transition);
    font-family: inherit;
}

.form-control:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px rgba(30, 64, 175, 0.1);
}

.form-group {
    margin-bottom: 20px;
}

.form-group label {
    display: block;
    margin-bottom: 8px;
    font-weight: 600;
    color: var(--text-primary);
}

.form-text {
    display: block;
    margin-top: 6px;
    font-size: 0.875rem;
    color: var(--text-secondary);
}

.required {
    color: var(--danger-color);
}

textarea.form-control {
    resize: vertical;
    min-height: 100px;
}

.checkbox-label {
    display: flex;
    align-items: center;
    gap: 10px;
    cursor: pointer;
    font-weight: 500;
}

.checkbox-label input[type="checkbox"] {
    width: 18px;
    height: 18px;
    cursor: pointer;
}

/* Registration Page */
.registration-wrapper {
    display: grid;
    grid-template-columns: 1fr 2fr;
    gap: 30px;
    max-width: 1400px;
    margin: 0 auto;
}

.event-info-card, .registration-form-card {
    background: #fff;
    border-radius: 12px;
    padding: 30px;
    box-shadow: var(--shadow-md);
}

.event-info-card h2 {
    color: var(--primary-color);
    margin-bottom: 15px;
}

.event-details {
    margin-top: 20px;
}

.detail-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 0;
    border-bottom: 1px solid var(--border-color);
}

.detail-item:last-child {
    border-bottom: none;
}

.zoom-badge {
    margin-top: 15px;
    padding: 12px;
    background: #dbeafe;
    color: #7c3aed;
    border-radius: 8px;
    font-weight: 600;
    text-align: center;
}

.registration-form-card h3 {
    color: var(--primary-color);
    margin-bottom: 20px;
    display: flex;
    align-items: center;
    gap: 10px;
}

.form-section {
    margin-bottom: 30px;
    padding-bottom: 30px;
    border-bottom: 2px solid var(--border-color);
}

.form-section:last-of-type {
    border-bottom: none;
}

.form-section h4 {
    color: var(--text-primary);
    margin-bottom: 20px;
}

.form-actions {
    display: flex;
    gap: 15px;
    margin-top: 30px;
}

/* Confirmation Page */
.confirmation-header {
    text-align: center;
    margin-bottom: 40px;
}

.confirmation-icon {
    font-size: 5rem;
    color: var(--success-color);
    margin-bottom: 20px;
}

.confirmation-code-display {
    font-size: 1.2rem;
    color: var(--text-secondary);
    margin-top: 10px;
}

.confirmation-code-display strong {
    color: var(--primary-color);
    font-size: 1.5rem;
    font-weight: 700;
    letter-spacing: 2px;
}

.confirmation-wrapper {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 30px;
    max-width: 1200px;
    margin: 0 auto;
}

.event-summary-card, .attendee-info-card {
    background: #fff;
    border-radius: 12px;
    padding: 30px;
    box-shadow: var(--shadow-md);
}

.event-summary-card h2, .attendee-info-card h2 {
    color: var(--primary-color);
    margin-bottom: 15px;
}

.event-summary-card h3 {
    font-size: 1.5rem;
    color: var(--text-primary);
    margin-bottom: 15px;
}

.event-meta-list {
    margin: 20px 0;
}

.zoom-info {
    background: #dbeafe;
    padding: 20px;
    border-radius: 8px;
    margin: 20px 0;
    text-align: center;
}

.zoom-info h4 {
    color: #7c3aed;
    margin-bottom: 15px;
}

.zoom-password {
    margin-top: 15px;
    color: #7c3aed;
}

.calendar-actions, .action-buttons {
    display: flex;
    gap: 15px;
    margin-top: 20px;
    flex-wrap: wrap;
}

.info-table {
    width: 100%;
    border-collapse: collapse;
    margin: 15px 0;
}

.info-table th, .info-table td {
    padding: 12px;
    text-align: left;
    border-bottom: 1px solid var(--border-color);
}

.info-table th {
    font-weight: 600;
    color: var(--text-secondary);
    width: 30%;
}

.edit-form {
    margin-top: 20px;
}

/* Admin Login */
.login-container {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, #6b21a8 0%, #a855f7 100%);
    padding: 20px;
}

.login-card {
    background: #fff;
    border-radius: 16px;
    padding: 40px;
    box-shadow: var(--shadow-lg);
    width: 100%;
    max-width: 450px;
}

.login-header {
    text-align: center;
    margin-bottom: 30px;
}

.login-logo {
    height: 80px;
    margin-bottom: 20px;
}

.login-header h1 {
    color: var(--primary-color);
    margin-bottom: 10px;
}

.login-form {
    margin: 30px 0;
}

.login-footer {
    display: flex;
    justify-content: space-between;
    margin-top: 20px;
    padding-top: 20px;
    border-top: 1px solid var(--border-color);
}

.lang-switcher-link, .back-to-home {
    color: var(--primary-color);
    text-decoration: none;
    display: flex;
    align-items: center;
    gap: 6px;
    font-weight: 500;
    transition: var(--transition);
}

.lang-switcher-link:hover, .back-to-home:hover {
    color: var(--primary-hover);
}

/* Admin Dashboard */
.admin-body {
    background: #f1f5f9;
}

.admin-layout {
    display: flex;
    min-height: 100vh;
}

.admin-sidebar {
    width: 280px;
    background: linear-gradient(180deg, #6b21a8 0%, #7c3aed 100%);
    color: #fff;
    display: flex;
    flex-direction: column;
    box-shadow: var(--shadow-lg);
}

.sidebar-header {
    padding: 30px 20px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.2);
    text-align: center;
}

.sidebar-logo {
    height: 60px;
    margin-bottom: 15px;
}

.sidebar-header h2 {
    font-size: 1.2rem;
}

.sidebar-nav {
    flex: 1;
    padding: 20px 0;
}

.nav-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 15px 20px;
    color: rgba(255, 255, 255, 0.9);
    text-decoration: none;
    transition: var(--transition);
}

.nav-item:hover {
    background: rgba(255, 255, 255, 0.1);
    color: #fff;
}

.nav-item.active {
    background: rgba(255, 255, 255, 0.2);
    color: #fff;
    border-left: 4px solid #fff;
}

.nav-item i {
    font-size: 1.2rem;
    width: 24px;
}

.sidebar-footer {
    padding: 20px;
    border-top: 1px solid rgba(255, 255, 255, 0.2);
}

.admin-user-info {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 10px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 8px;
    margin-bottom: 15px;
}

.sidebar-link {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 10px;
    color: rgba(255, 255, 255, 0.9);
    text-decoration: none;
    border-radius: 6px;
    transition: var(--transition);
    margin-bottom: 8px;
}

.sidebar-link:hover {
    background: rgba(255, 255, 255, 0.1);
    color: #fff;
}

.admin-main {
    flex: 1;
    padding: 40px;
    overflow-y: auto;
}

.admin-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 30px;
    flex-wrap: wrap;
    gap: 20px;
}

.admin-header h1 {
    font-size: 2rem;
    color: var(--text-primary);
    display: flex;
    align-items: center;
    gap: 12px;
}

.admin-stats {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 20px;
    margin-bottom: 30px;
}

.stat-card {
    background: #fff;
    border-radius: 12px;
    padding: 25px;
    box-shadow: var(--shadow-md);
    display: flex;
    align-items: center;
    gap: 20px;
}

.stat-icon {
    font-size: 3rem;
    color: var(--primary-color);
}

.stat-value {
    font-size: 2.5rem;
    font-weight: 700;
    color: var(--text-primary);
}

.stat-label {
    color: var(--text-secondary);
    font-size: 0.95rem;
}

.admin-table {
    width: 100%;
    background: #fff;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: var(--shadow-md);
}

.admin-table thead {
    background: var(--light-bg);
}

.admin-table th, .admin-table td {
    padding: 15px;
    text-align: left;
    border-bottom: 1px solid var(--border-color);
}

.admin-table th {
    font-weight: 600;
    color: var(--text-primary);
}

.admin-table tbody tr:hover {
    background: var(--light-bg);
}

.event-past {
    opacity: 0.7;
}

.signup-count {
    font-weight: 700;
    color: var(--primary-color);
    font-size: 1.1rem;
}

.action-buttons {
    display: flex;
    gap: 8px;
}

.text-muted {
    color: var(--text-secondary);
    font-size: 0.9rem;
    display: block;
}

.admin-form {
    max-width: 1200px;
}

.form-card {
    background: #fff;
    border-radius: 12px;
    padding: 30px;
    margin-bottom: 25px;
    box-shadow: var(--shadow-md);
}

.form-card h3 {
    color: var(--primary-color);
    margin-bottom: 20px;
    padding-bottom: 15px;
    border-bottom: 2px solid var(--border-color);
}

.form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
}

.question-item {
    background: var(--light-bg);
    padding: 20px;
    border-radius: 8px;
    margin-bottom: 15px;
    border: 2px solid var(--border-color);
}

/* Alerts */
.alert {
    padding: 15px 20px;
    border-radius: 8px;
    margin-bottom: 20px;
    display: flex;
    align-items: center;
    gap: 12px;
}

.alert i {
    font-size: 1.2rem;
}

.alert-success {
    background: #d1fae5;
    color: #166534;
    border-left: 4px solid #10b981;
}

.alert-error {
    background: #fee2e2;
    color: #991b1b;
    border-left: 4px solid #ef4444;
}

.alert-warning {
    background: #fef3c7;
    color: #78350f;
    border-left: 4px solid #f59e0b;
}

.alert-info {
    background: #dbeafe;
    color: #7c3aed;
    border-left: 4px solid #a855f7;
}

.alert-dismissible {
    position: relative;
    padding-right: 50px;
}

.alert-close {
    position: absolute;
    right: 15px;
    top: 50%;
    transform: translateY(-50%);
    background: none;
    border: none;
    font-size: 1.2rem;
    cursor: pointer;
    opacity: 0.7;
    transition: var(--transition);
}

.alert-close:hover {
    opacity: 1;
}

/* Modal */
.modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    z-index: 1000;
    align-items: center;
    justify-content: center;
    padding: 20px;
}

.modal-content {
    background: #fff;
    border-radius: 12px;
    width: 100%;
    max-width: 600px;
    max-height: 90vh;
    overflow-y: auto;
    box-shadow: var(--shadow-lg);
}

.modal-header {
    padding: 20px 30px;
    border-bottom: 2px solid var(--border-color);
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.modal-header h2 {
    color: var(--primary-color);
    margin: 0;
}

.modal-close {
    background: none;
    border: none;
    font-size: 1.5rem;
    cursor: pointer;
    color: var(--text-secondary);
    transition: var(--transition);
}

.modal-close:hover {
    color: var(--text-primary);
}

.modal-content form {
    padding: 30px;
}

.modal-footer {
    display: flex;
    gap: 15px;
    padding-top: 20px;
    border-top: 1px solid var(--border-color);
}

/* Empty State */
.empty-state {
    text-align: center;
    padding: 60px 20px;
    color: var(--text-secondary);
}

.empty-state i {
    font-size: 5rem;
    margin-bottom: 20px;
    opacity: 0.5;
}

.empty-state p {
    font-size: 1.2rem;
}

/* Footer */
.main-footer {
    background: var(--text-primary);
    color: #fff;
    padding: 30px 0;
    margin-top: 60px;
}

.footer-content {
    text-align: center;
}

.footer-content p {
    margin: 5px 0;
}

/* Responsive */
@media (max-width: 1024px) {
    .admin-layout {
        flex-direction: column;
    }
    
    .admin-sidebar {
        width: 100%;
    }
    
    .sidebar-nav {
        display: flex;
        overflow-x: auto;
    }
    
    .nav-item {
        white-space: nowrap;
    }
}

@media (max-width: 768px) {
    .header-content {
        flex-direction: column;
        align-items: flex-start;
    }
    
    .logo-title {
        font-size: 1.2rem;
    }
    
    .logo-subtitle {
        font-size: 1rem;
    }
    
    .events-grid {
        grid-template-columns: 1fr;
    }
    
    .registration-wrapper, .confirmation-wrapper {
        grid-template-columns: 1fr;
    }
    
    .form-row {
        grid-template-columns: 1fr;
    }
    
    .form-actions, .action-buttons, .calendar-actions {
        flex-direction: column;
    }
    
    .btn-block {
        width: 100%;
    }
    
    .admin-main {
        padding: 20px;
    }
    
    .admin-stats {
        grid-template-columns: 1fr;
    }
    
    .admin-table {
        font-size: 0.9rem;
    }
    
    .admin-table th, .admin-table td {
        padding: 10px;
    }
}

@media (max-width: 480px) {
    .logo-img {
        height: 40px;
    }

    .page-header h1 {
        font-size: 1.8rem;
    }

    .event-title {
        font-size: 1.2rem;
    }

    .btn {
        padding: 10px 16px;
        font-size: 0.9rem;
    }

    .form-control {
        padding: 10px;
    }
    
    /* Better mobile spacing for signup */
    .registration-wrapper {
        padding: 10px;
    }
    
    .event-info-card, .registration-form-card {
        padding: 20px 15px;
        border-radius: 8px;
    }
    
    .container {
        padding: 10px;
    }
    
    /* Make sure images don't overflow */
    img {
        max-width: 100%;
        height: auto;
    }
    
    /* Better form spacing on mobile */
    .form-group {
        margin-bottom: 15px;
    }
    
    /* Ensure tables are responsive */
    .event-details {
        font-size: 0.9rem;
    }
    
    .detail-item {
        padding: 8px 0;
    }
}/* Utility Classes */
.text-center { text-align: center; }
.text-right { text-align: right; }
.text-danger { color: var(--danger-color); }
.text-success { color: var(--success-color); }
.mt-1 { margin-top: 0.5rem; }
.mt-2 { margin-top: 1rem; }
.mt-3 { margin-top: 1.5rem; }
.mb-1 { margin-bottom: 0.5rem; }
.mb-2 { margin-bottom: 1rem; }
.mb-3 { margin-bottom: 1.5rem; }

code {
    background: var(--light-bg);
    padding: 4px 8px;
    border-radius: 4px;
    font-family: 'Courier New', monospace;
    font-size: 0.9em;
}

/* Calendar View Styles */
.calendar-controls {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 30px;
    padding: 20px;
    background: white;
    border-radius: 12px;
    box-shadow: var(--shadow-sm);
}

.calendar-month-title {
    font-size: 24px;
    font-weight: 600;
    color: var(--primary-color);
}

.calendar-grid {
    background: white;
    border-radius: 12px;
    box-shadow: var(--shadow-md);
    overflow: hidden;
    width: 100%;
}

.calendar-header {
    display: grid;
    grid-template-columns: repeat(7, minmax(0, 1fr));
    background: linear-gradient(135deg, #6b21a8 0%, #a855f7 100%);
    color: white;
    font-weight: 600;
    width: 100%;
}

.calendar-day-name {
    padding: 15px;
    text-align: center;
    border-right: 1px solid rgba(255, 255, 255, 0.2);
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.calendar-day-name:last-child {
    border-right: none;
}

.calendar-body {
    display: grid;
    grid-template-columns: repeat(7, minmax(0, 1fr));
    gap: 1px;
    background: var(--border-color);
    width: 100%;
}

.calendar-day {
    background: white;
    min-height: 120px;
    width: 100%;
    min-width: 0;
    max-width: 100%;
    padding: 8px;
    cursor: pointer;
    transition: var(--transition);
    position: relative;
    overflow: hidden;
    box-sizing: border-box;
    word-wrap: break-word;
    word-break: break-word;
}

.calendar-day:hover {
    background: #faf5ff;
    z-index: 10;
    box-shadow: var(--shadow-md);
}

.calendar-day-empty {
    background: #f9fafb;
    cursor: default;
}

.calendar-day-empty:hover {
    background: #f9fafb;
    transform: none;
    box-shadow: none;
}

.calendar-day-number {
    font-weight: 600;
    font-size: 16px;
    color: var(--text-primary);
    margin-bottom: 8px;
    word-wrap: break-word;
}

.calendar-day-today {
    background: #faf5ff;
    border: 2px solid var(--primary-color);
}

.calendar-day-today .calendar-day-number {
    color: var(--primary-color);
    font-weight: 700;
    font-size: 18px;
}

.calendar-events {
    display: flex;
    flex-direction: column;
    gap: 4px;
    width: 100%;
    min-width: 0;
}

.calendar-event {
    background: linear-gradient(135deg, #6b21a8 0%, #a855f7 100%);
    color: white;
    padding: 6px 8px;
    border-radius: 6px;
    font-size: 12px;
    cursor: pointer;
    transition: var(--transition);
    display: flex;
    align-items: center;
    gap: 4px;
    min-width: 0;
    max-width: 100%;
    word-wrap: break-word;
    word-break: break-word;
}

.calendar-event:hover {
    background: linear-gradient(135deg, #7c3aed 0%, #c084fc 100%);
    box-shadow: var(--shadow-sm);
}

.calendar-event i {
    font-size: 10px;
    flex-shrink: 0;
}

.calendar-event-time {
    font-weight: 600;
    font-size: 11px;
    flex-shrink: 0;
}

.calendar-event-title {
    flex: 1;
    min-width: 0;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

/* Responsive Calendar */
@media (max-width: 768px) {
    .calendar-day {
        min-height: 80px;
        padding: 4px;
    }
    
    .calendar-day-number {
        font-size: 14px;
    }
    
    .calendar-event {
        font-size: 10px;
        padding: 4px 6px;
    }
    
    .calendar-event-time {
        display: none;
    }
    
    .calendar-controls {
        flex-direction: column;
        gap: 15px;
    }
    
    .calendar-month-title {
        font-size: 20px;
    }
}

/* Event Image Styles */
.event-card-image {
    width: 100%;
    height: 250px;
    overflow: hidden;
    background: #f3f4f6;
}

.event-card-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

/* Modal Actions */
.modal-actions {
    display: flex;
    gap: 10px;
    justify-content: flex-end;
    padding: 20px 30px;
    border-top: 1px solid var(--border-color);
    background: var(--light-bg);
}

/* Event card image responsive adjustments */
@media (max-width: 768px) {
    .event-card-image {
        height: 200px;
    }
}

@media (min-width: 1200px) {
    .event-card-image {
        height: 280px;
    }
}

/* Ticket Display Styles */
.tickets-section {
    background: white;
    border-radius: 12px;
    padding: 30px;
    margin: 30px 0;
    box-shadow: var(--shadow-md);
}

.tickets-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
    padding-bottom: 20px;
    border-bottom: 2px solid var(--border-color);
}

.tickets-header h2 {
    color: var(--primary-color);
    font-size: 28px;
    margin: 0;
    display: flex;
    align-items: center;
    gap: 12px;
}

.tickets-info-alert {
    background: linear-gradient(135deg, #fef3c7 0%, #fde68a 100%);
    border: 2px solid var(--warning-color);
    border-radius: 8px;
    padding: 16px 20px;
    margin-bottom: 30px;
    display: flex;
    align-items: flex-start;
    gap: 16px;
}

.tickets-info-alert i {
    color: var(--warning-color);
    font-size: 24px;
    flex-shrink: 0;
    margin-top: 2px;
}

.tickets-info-alert p {
    margin: 0;
    color: #78350f;
    line-height: 1.6;
}

.tickets-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
    gap: 24px;
    margin-top: 20px;
}

.ticket-card {
    background: linear-gradient(135deg, #fafafa 0%, #ffffff 100%);
    border: 2px solid var(--primary-color);
    border-radius: 12px;
    padding: 24px;
    box-shadow: var(--shadow-md);
    transition: var(--transition);
}

.ticket-card:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow-lg);
}

.ticket-card-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
}

.ticket-card-header h3 {
    color: var(--primary-color);
    margin: 0;
    font-size: 20px;
}

.ticket-status {
    padding: 6px 12px;
    border-radius: 20px;
    font-size: 13px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.ticket-status.valid {
    background: #d1fae5;
    color: #065f46;
}

.ticket-status.checked-in {
    background: #fee2e2;
    color: #991b1b;
}

.ticket-qr {
    text-align: center;
    padding: 20px;
    background: white;
    border: 3px solid #e9d5ff;
    border-radius: 8px;
    margin-bottom: 20px;
}

.ticket-qr .qr-image {
    max-width: 100%;
    height: auto;
    width: 250px;
    border-radius: 4px;
}

.ticket-qr .qr-error {
    color: var(--danger-color);
    margin: 20px 0;
}

.ticket-info {
    text-align: center;
}

.ticket-code-label {
    font-size: 14px;
    color: var(--text-secondary);
    margin: 0 0 8px 0;
}

.ticket-code {
    font-family: 'Courier New', monospace;
    font-size: 13px;
    background: white;
    border: 1px solid var(--border-color);
    padding: 10px;
    border-radius: 6px;
    word-break: break-all;
    color: var(--text-primary);
    margin: 0;
}

/* Print styles for tickets */
@media print {
    body * {
        visibility: hidden;
    }
    
    .tickets-section,
    .tickets-section * {
        visibility: visible;
    }
    
    .tickets-section {
        position: absolute;
        left: 0;
        top: 0;
        width: 100%;
        box-shadow: none;
        padding: 0;
    }
    
    .tickets-header button,
    .main-header,
    .main-footer,
    .back-link,
    .action-buttons,
    .confirmation-wrapper {
        display: none !important;
    }
    
    .ticket-card {
        page-break-inside: avoid;
        break-inside: avoid;
        margin-bottom: 30px;
    }
    
    .tickets-grid {
        grid-template-columns: 1fr;
    }
}

/* Mobile responsive for tickets */
@media (max-width: 768px) {
    .tickets-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 16px;
    }
    
    .tickets-header button {
        width: 100%;
    }
    
    .tickets-grid {
        grid-template-columns: 1fr;
    }
}

/* Event Status Modal */
.event-status-modal {
    display: none;
    position: fixed;
    z-index: 1000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0,0,0,0.5);
    animation: fadeIn 0.3s;
}

.event-status-modal-content {
    background-color: white;
    margin: 15% auto;
    padding: 30px;
    border-radius: 12px;
    max-width: 500px;
    box-shadow: 0 4px 20px rgba(0,0,0,0.3);
    text-align: center;
    animation: slideIn 0.3s;
}

@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

@keyframes slideIn {
    from { transform: translateY(-50px); opacity: 0; }
    to { transform: translateY(0); opacity: 1; }
}

.event-status-modal-icon {
    font-size: 4rem;
    margin-bottom: 20px;
}

.event-status-modal-icon.full {
    color: #7c3aed;
}

.event-status-modal-icon.closed {
    color: #7c3aed;
}

.event-status-modal h2 {
    margin-bottom: 15px;
    color: #1f2937;
}

.event-status-modal p {
    color: #6b7280;
    margin-bottom: 25px;
    line-height: 1.6;
}

.event-status-modal-close {
    background: linear-gradient(135deg, #7c3aed 0%, #c084fc 100%);
    color: white;
    padding: 12px 30px;
    border: none;
    border-radius: 8px;
    cursor: pointer;
    font-size: 16px;
    font-weight: 600;
    transition: transform 0.2s;
}

.event-status-modal-close:hover {
    transform: translateY(-2px);
}
