/* Calendar Styles - Government Format Grid Calendar */
.custom-event-calendar {
    max-width: 1200px;
    margin: 0 auto;
    padding: 20px;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
    background: #f5f7fa;
    border-radius: 8px;
}

/* Calendar Header */
.calendar-header {
    margin-bottom: 30px;
    background: white;
    padding: 20px;
    border-radius: 8px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.calendar-selectors {
    display: flex;
    align-items: center;
    gap: 20px;
    margin-bottom: 20px;
    flex-wrap: wrap;
}

.selector-group {
    display: flex;
    align-items: center;
    gap: 10px;
}

.selector-group label {
    font-weight: 600;
    color: #2c3e50;
    font-size: 14px;
    margin: 0;
    white-space: nowrap;
}

.month-select,
.year-select {
    padding: 10px 12px;
    border: 2px solid #ddd;
    border-radius: 6px;
    font-size: 14px;
    font-weight: 500;
    color: #2c3e50;
    background: white;
    cursor: pointer;
    transition: all 0.3s ease;
    min-width: 120px;
}

.month-select:hover,
.year-select:hover {
    border-color: #3498db;
    background: #f8f9fa;
}

.month-select:focus,
.year-select:focus {
    outline: none;
    border-color: #3498db;
    box-shadow: 0 0 0 3px rgba(52, 152, 219, 0.1);
}

.btn-today {
    padding: 10px 20px;
    background: #27ae60;
    color: white;
    border: none;
    border-radius: 6px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    font-size: 14px;
    white-space: nowrap;
}

.btn-today:hover {
    background: #229954;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(39, 174, 96, 0.3);
}

.btn-today:active {
    transform: translateY(0);
}

.calendar-title {
    margin: 0;
    font-size: 28px;
    font-weight: 700;
    color: #2c3e50;
    text-align: center;
    padding-top: 10px;
}

/* Calendar Grid */
.calendar-grid {
    display: grid;
    grid-template-columns: repeat(7, 1fr);
    gap: 1px;
    background: #dee2e6;
    border: 2px solid #34495e;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

.calendar-day-header {
    background: #34495e;
    color: white;
    padding: 16px 10px;
    text-align: center;
    font-weight: 700;
    font-size: 13px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.calendar-day {
    background: white;
    min-height: 140px;
    padding: 12px;
    position: relative;
    transition: all 0.2s ease;
    border: 1px solid #dee2e6;
}

.calendar-day:not(.empty):hover {
    background: #f0f8ff;
    box-shadow: inset 0 0 10px rgba(52, 152, 219, 0.1);
}

.calendar-day.empty {
    background: #f1f3f5;
    cursor: not-allowed;
}

.calendar-day.today {
    background: linear-gradient(135deg, #e3f2fd 0%, #bbdefb 100%);
    border-left: 4px solid #3498db;
}

.day-number {
    display: inline-block;
    width: 34px;
    height: 34px;
    line-height: 34px;
    text-align: center;
    font-weight: 700;
    color: #2c3e50;
    border-radius: 50%;
    font-size: 14px;
}

.calendar-day.today .day-number {
    background: #3498db;
    color: white;
    box-shadow: 0 2px 6px rgba(52, 152, 219, 0.4);
}

.day-events {
    margin-top: 10px;
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.event-item {
    padding: 6px 8px;
    border-radius: 4px;
    font-size: 11px;
    color: white;
    cursor: pointer;
    transition: all 0.2s ease;
    display: flex;
    flex-direction: column;
    gap: 2px;
    border-left: 3px solid rgba(0, 0, 0, 0.2);
    overflow: hidden;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.15);
}

.event-item:hover {
    opacity: 0.95;
    transform: translateX(2px);
    box-shadow: 0 3px 8px rgba(0, 0, 0, 0.25);
}

.event-time {
    font-size: 10px;
    opacity: 0.95;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.3px;
}

.event-title {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    font-weight: 600;
}

/* Modal Styles */
.event-details-modal {
    position: fixed;
    z-index: 9999;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.6);
    display: flex;
    align-items: center;
    justify-content: center;
    animation: fadeIn 0.3s;
}

@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

.modal-content {
    background-color: white;
    padding: 0;
    border-radius: 12px;
    max-width: 700px;
    max-height: 90vh;
    overflow-y: auto;
    position: relative;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.3);
    animation: slideDown 0.3s;
    width: 95%;
    margin: 0 auto;
}

@keyframes slideDown {
    from {
        transform: translateY(-50px);
        opacity: 0;
    }
    to {
        transform: translateY(0);
        opacity: 1;
    }
}

.close-modal {
    position: absolute;
    right: 20px;
    top: 20px;
    font-size: 28px;
    font-weight: bold;
    color: #666;
    cursor: pointer;
    width: 35px;
    height: 35px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    transition: all 0.3s;
    z-index: 1;
    background: white;
}

.close-modal:hover {
    background: #f1f3f5;
    color: #000;
    transform: rotate(90deg);
}

.event-header {
    padding: 30px 30px 20px;
    border-bottom: 3px solid #f1f3f5;
    border-left: 5px solid;
}

.event-header h2 {
    margin: 0;
    font-size: 28px;
    color: #2c3e50;
    font-weight: 700;
}

.event-info-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 20px;
    padding: 25px 30px;
}

.info-item {
    display: flex;
    gap: 12px;
    align-items: start;
}

.info-icon {
    font-size: 24px;
    flex-shrink: 0;
    width: 32px;
}

.info-item strong {
    display: block;
    color: #666;
    font-size: 11px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 4px;
    font-weight: 700;
}

.info-item p {
    margin: 0;
    color: #2c3e50;
    font-size: 15px;
    font-weight: 500;
    line-height: 1.5;
}

.event-description,
.event-contact {
    padding: 25px 30px;
    border-top: 1px solid #f1f3f5;
}

.event-description h3,
.event-contact h3 {
    margin: 0 0 15px 0;
    font-size: 18px;
    color: #2c3e50;
    font-weight: 700;
}

.event-description p,
.event-contact p {
    line-height: 1.7;
    color: #555;
    margin: 8px 0;
    font-size: 15px;
}

.event-contact a {
    color: #3498db;
    text-decoration: none;
    font-weight: 500;
    transition: all 0.2s;
}

.event-contact a:hover {
    color: #2980b9;
    text-decoration: underline;
}

/* Event Submission Form Styles */
.event-submission-form-container {
    max-width: 800px;
    margin: 0 auto;
    padding: 20px;
}

.event-form {
    background: white;
    padding: 30px;
    border-radius: 12px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
}

.event-form h3 {
    margin: 0 0 25px 0;
    font-size: 26px;
    color: #2c3e50;
    font-weight: 700;
}

.form-group {
    margin-bottom: 20px;
}

.form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
    margin-bottom: 20px;
}

.form-group label {
    display: block;
    margin-bottom: 8px;
    font-weight: 700;
    color: #2c3e50;
    font-size: 14px;
}

.required {
    color: #e74c3c;
}

.form-group input[type="text"],
.form-group input[type="email"],
.form-group input[type="tel"],
.form-group input[type="date"],
.form-group input[type="time"],
.form-group input[type="number"],
.form-group textarea {
    width: 100%;
    padding: 12px;
    border: 2px solid #e1e8ed;
    border-radius: 6px;
    font-size: 15px;
    font-family: inherit;
    transition: border-color 0.3s;
    box-sizing: border-box;
}

.form-group input[type="color"] {
    width: 100%;
    height: 50px;
    padding: 5px;
    border: 2px solid #e1e8ed;
    border-radius: 6px;
    cursor: pointer;
    box-sizing: border-box;
}

.form-group input:focus,
.form-group textarea:focus {
    outline: none;
    border-color: #3498db;
    box-shadow: 0 0 0 3px rgba(52, 152, 219, 0.1);
}

.form-group textarea {
    resize: vertical;
    min-height: 100px;
}

.submit-btn {
    background: #3498db;
    color: white;
    padding: 14px 40px;
    border: none;
    border-radius: 6px;
    font-size: 16px;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.3s;
    width: 100%;
}

.submit-btn:hover {
    background: #2980b9;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(52, 152, 219, 0.3);
}

.submit-btn:disabled {
    background: #95a5a6;
    cursor: not-allowed;
    transform: none;
}

.form-message {
    margin: 15px 0;
}

.success-message {
    background: #d4edda;
    color: #155724;
    padding: 15px;
    border-radius: 6px;
    border-left: 4px solid #28a745;
}

.error-message {
    background: #f8d7da;
    color: #721c24;
    padding: 15px;
    border-radius: 6px;
    border-left: 4px solid #dc3545;
}

.login-required {
    background: white;
    padding: 40px;
    border-radius: 12px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    text-align: center;
}

.login-required h3 {
    margin: 0 0 15px 0;
    font-size: 24px;
    color: #2c3e50;
    font-weight: 700;
}

.login-required p {
    color: #666;
    margin-bottom: 25px;
    font-size: 15px;
}

.login-btn {
    display: inline-block;
    background: #3498db;
    color: white;
    padding: 12px 30px;
    border-radius: 6px;
    text-decoration: none;
    font-weight: 700;
    transition: all 0.3s;
}

.login-btn:hover {
    background: #2980b9;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(52, 152, 219, 0.3);
}

/* Responsive Design */
@media (max-width: 1024px) {
    .calendar-day {
        min-height: 120px;
        padding: 10px;
    }
    
    .day-number {
        width: 30px;
        height: 30px;
        line-height: 30px;
        font-size: 12px;
    }
    
    .event-item {
        font-size: 10px;
        padding: 5px 6px;
    }
    
    .calendar-title {
        font-size: 24px;
    }
}

@media (max-width: 768px) {
    .calendar-selectors {
        gap: 10px;
        padding: 0 10px;
    }
    
    .selector-group {
        gap: 6px;
    }
    
    .month-select,
    .year-select {
        min-width: 100px;
        font-size: 13px;
        padding: 8px 10px;
    }
    
    .btn-today {
        padding: 8px 16px;
        font-size: 13px;
    }
    
    .calendar-day {
        min-height: 100px;
        font-size: 11px;
        padding: 8px;
    }
    
    .calendar-day-header {
        padding: 12px 6px;
        font-size: 12px;
    }
    
    .day-number {
        width: 26px;
        height: 26px;
        line-height: 26px;
        font-size: 11px;
    }
    
    .day-events {
        margin-top: 6px;
        gap: 2px;
    }
    
    .event-item {
        font-size: 9px;
        padding: 4px 5px;
    }
    
    .event-time {
        font-size: 8px;
    }
    
    .calendar-title {
        font-size: 20px;
    }
    
    .modal-content {
        width: calc(100% - 20px);
        max-height: 95vh;
    }
    
    .event-header {
        padding: 20px 20px 15px;
    }
    
    .event-header h2 {
        font-size: 22px;
    }
    
    .event-info-grid {
        grid-template-columns: 1fr;
        padding: 15px 20px;
        gap: 15px;
    }
    
    .event-description,
    .event-contact {
        padding: 15px 20px;
    }
    
    .form-row {
        grid-template-columns: 1fr;
        gap: 15px;
    }
    
    .event-form {
        padding: 20px;
    }
}

@media (max-width: 480px) {
    .custom-event-calendar {
        padding: 10px;
    }
    
    .calendar-header {
        padding: 15px;
    }
    
    .calendar-selectors {
        flex-direction: column;
        align-items: stretch;
        gap: 10px;
    }
    
    .selector-group {
        width: 100%;
        flex-direction: column;
    }
    
    .month-select,
    .year-select,
    .btn-today {
        width: 100%;
    }
    
    .calendar-day {
        min-height: 80px;
        padding: 6px;
    }
    
    .day-number {
        width: 24px;
        height: 24px;
        line-height: 24px;
        font-size: 10px;
    }
    
    .event-item {
        font-size: 8px;
        padding: 3px 4px;
    }
    
    .calendar-title {
        font-size: 18px;
    }
}