/**
 * Events Calendar Styles
 * Mobile-responsive design for events calendar page
 */

/* Main Events Calendar Container */
.events-calendar-page {
    padding: 40px 0;
    min-height: 100vh;
}

.events-page-title {
    margin-bottom: 60px;
}

.events-page-title .wp-page-title {
    font-size: 48px;
    font-weight: 700;
    color: #333;
    text-transform: uppercase;
    letter-spacing: 2px;
}

/* Latest Event Hero Section */
.latest-event-section {
    margin-bottom: 60px;
    padding: 0;
    background: transparent;
    border-radius: 0;
    box-shadow: none;
}

.latest-event-image img {
    width: 100%;
    height: auto;
    border-radius: 8px;
    box-shadow: 0 4px 15px rgba(0,0,0,0.15);
}

.latest-event-content {
    padding-left: 30px;
    padding-top: 20px;
}

.event-label {
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
    color: #666;
    letter-spacing: 1px;
    margin-bottom: 15px;
    display: inline-block;
}

.event-date-time {
    font-size: 16px;
    color: #333;
    margin-bottom: 15px;
    font-weight: 500;
}

.event-title {
    font-size: 24px;
    font-weight: 700;
    margin-bottom: 15px;
    line-height: 1.3;
    color: #333;
    text-transform: uppercase;
}

.event-title a {
    color: inherit;
    text-decoration: none;
    transition: color 0.3s ease;
}

.event-title a:hover {
    color: #6c5ce7;
}

.event-excerpt {
    font-size: 15px;
    line-height: 1.6;
    color: #666;
    margin-bottom: 20px;
}

.event-actions .btn {
    padding: 12px 24px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1px;
    background-color: #8B4513;
    border-color: #8B4513;
    color: white;
    border-radius: 4px;
    font-size: 12px;
    transition: all 0.3s ease;
}

.event-actions .btn:hover {
    background-color: #654321;
    border-color: #654321;
    transform: translateY(-1px);
    box-shadow: 0 2px 8px rgba(139, 69, 19, 0.3);
}

/* Events Navigation */
.events-navigation {
    margin-bottom: 40px;
    padding: 20px 0 15px 0;
    border-bottom: 2px solid #eee;
}

.events-section-title {
    font-size: 24px;
    font-weight: 700;
    margin: 0 0 10px 0;
    color: #333;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.next-event-info {
    font-size: 16px;
    color: #666;
    margin: 10px 0 0 0;
    font-weight: 400;
}

.next-event-info strong {
    color: #333;
    font-weight: 600;
}

.next-event-info a {
    color: #333;
    text-decoration: none;
    transition: color 0.3s ease;
}

.next-event-info a:hover {
    color: #8B4513;
    text-decoration: underline;
}

.events-month-nav {
    display: flex;
    align-items: center;
    justify-content: flex-start;
    gap: 15px;
    flex-wrap: wrap;
}

.month-nav-btn {
    display: inline-block;
    color: #666;
    text-decoration: none;
    font-size: 18px;
    font-weight: bold;
    line-height: 1;
    padding: 5px;
    transition: color 0.3s ease;
}

.month-nav-btn:hover {
    color: #333;
}

.month-nav-btn * {
    margin: 0;
    padding: 0;
    line-height: 1;
}

.today-btn {
    width: auto;
    padding: 10px 16px;
    border-radius: 20px;
    font-weight: 600;
    text-transform: uppercase;
    font-size: 12px;
    letter-spacing: 1px;
    background-color: #f5f5f5;
    border: 1px solid #ddd;
    color: #333;
    text-decoration: none;
}

.today-btn:hover {
    background-color: #e0e0e0;
    border-color: #bbb;
}

.month-dropdown select {
    padding: 10px 35px 10px 12px;
    border: 1px solid #ddd;
    border-radius: 20px;
    background-color: white;
    font-size: 14px;
    min-width: 140px;
    font-weight: 500;
    transition: all 0.3s ease;
    color: #333 !important;
    appearance: none;
    background-image: url("data:image/svg+xml;charset=UTF-8,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23333' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3e%3cpolyline points='6,9 12,15 18,9'%3e%3c/polyline%3e%3c/svg%3e");
    background-repeat: no-repeat;
    background-position: right 8px center;
    background-size: 16px;
}

.month-dropdown select:focus {
    border-color: #8B4513;
    outline: none;
    box-shadow: 0 0 0 2px rgba(139, 69, 19, 0.1);
    background-color: white;
}

.month-dropdown select,
.month-dropdown select:focus,
.month-dropdown select:active,
.month-dropdown select:visited {
    color: #333 !important;
    background-color: white !important;
    -webkit-text-fill-color: #333 !important;
    opacity: 1 !important;
    -webkit-opacity: 1 !important;
}

.month-dropdown select option {
    color: #333 !important;
    background-color: white !important;
    font-weight: 500;
}

/* Custom Dropdown */
.custom-dropdown {
    position: relative;
    display: inline-block;
}

.dropdown-trigger {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 10px 12px;
    border: 1px solid #ddd;
    border-radius: 20px;
    background-color: white;
    cursor: pointer;
    min-width: 140px;
    font-size: 14px;
    font-weight: 500;
    color: #333;
    transition: all 0.3s ease;
}

.dropdown-trigger:hover {
    border-color: #bbb;
}

.dropdown-text {
    flex: 1;
    color: #333;
}

.dropdown-arrow {
    margin-left: 8px;
    font-size: 12px;
    color: #666;
    transition: transform 0.3s ease;
}

.dropdown-trigger.active .dropdown-arrow {
    transform: rotate(180deg);
}

.dropdown-menu {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: white;
    border: 1px solid #ddd;
    border-radius: 8px;
    box-shadow: 0 4px 12px rgba(0,0,0,0.1);
    z-index: 1000;
    max-height: 200px;
    overflow-y: auto;
    display: none;
}

.dropdown-menu.active {
    display: block;
}

.dropdown-item {
    display: block;
    padding: 10px 12px;
    color: #333;
    text-decoration: none;
    font-size: 14px;
    font-weight: 500;
    transition: background-color 0.2s ease;
    border-bottom: 1px solid #f5f5f5;
}

.dropdown-item:last-child {
    border-bottom: none;
}

.dropdown-item:hover {
    background-color: #f8f9fa;
    color: #333;
}

.dropdown-item.active {
    background-color: #e9ecef;
    color: #333;
    font-weight: 600;
}

/* Month Divider */
.month-divider {
    font-size: 28px;
    font-weight: 700;
    color: #333;
    margin: 50px 0 40px 0;
    padding-bottom: 15px;
    border-bottom: 3px solid #8B4513;
    text-transform: uppercase;
    letter-spacing: 1px;
}

/* Previous Events Section */
.previous-events-section {
    margin-bottom: 30px;
    padding: 20px 0 15px 0;
    border-bottom: 2px solid #eee;
}

.previous-events-title {
    font-size: 24px;
    font-weight: 700;
    margin: 0;
    color: #333;
    text-transform: uppercase;
    letter-spacing: 1px;
}

/* Event Items */
.event-item {
    margin-bottom: 40px;
    padding: 0;
    background-color: transparent;
    border: none;
    border-radius: 0;
    transition: all 0.3s ease;
    box-shadow: none;
}

.event-item:hover {
    box-shadow: none;
    transform: none;
    border-color: transparent;
}

.event-date-display {
    position: relative;
    text-align: center;
    background: #6c5ce7;
    padding: 15px 8px;
    border-radius: 0;
    color: white;
    box-shadow: none;
    min-height: 80px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    border-right: 3px solid #6c5ce7;
}

.event-item:not(:last-child) .event-date-display::after {
    content: '';
    position: absolute;
    top: 100%;
    left: 50%;
    transform: translateX(-50%);
    width: 3px;
    height: calc(100% + 40px);
    background-color: #6c5ce7;
    z-index: 1;
}

.day-name {
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
    margin-bottom: 4px;
    opacity: 0.9;
    letter-spacing: 0.5px;
}

.day-number {
    font-size: 24px;
    font-weight: 700;
    line-height: 1;
}

.event-content {
    padding-left: 25px;
    padding-top: 5px;
}

.event-content .event-date-time {
    font-size: 13px;
    color: #666;
    margin-bottom: 8px;
    font-weight: 500;
}

.event-content .event-title {
    font-size: 18px;
    margin-bottom: 8px;
    line-height: 1.3;
    font-weight: 700;
}

.event-content .event-title a {
    color: #333;
    text-decoration: none;
    transition: color 0.3s ease;
}

.event-content .event-title a:hover {
    color: #6c5ce7;
}

.event-location {
    font-size: 13px;
    color: #666;
    margin-bottom: 8px;
    font-style: italic;
    display: flex;
    align-items: center;
}

.event-location:before {
    content: "📍";
    margin-right: 6px;
}

.event-content .event-excerpt {
    font-size: 14px;
    line-height: 1.5;
    color: #666;
}

.event-image {
    text-align: center;
    padding-top: 5px;
}

.event-image img {
    width: 100%;
    height: auto;
    border-radius: 8px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
    transition: transform 0.3s ease;
    max-width: 200px;
    min-height: 120px;
    object-fit: cover;
}

.event-image img:hover {
    transform: scale(1.02);
}

.placeholder-image {
    background: linear-gradient(135deg, #f8f9fa 0%, #e9ecef 100%);
    border: 2px dashed #ddd;
    border-radius: 12px;
    height: 200px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #999;
    font-style: italic;
    font-size: 14px;
}

/* No Events Message */
.no-events {
    text-align: center;
    padding: 80px 20px;
    color: #666;
    font-size: 18px;
    background-color: #f8f9fa;
    border-radius: 12px;
    border: 2px dashed #ddd;
}

/* Mobile Responsive Design */
@media (max-width: 768px) {
    .events-calendar-page {
        padding: 20px 0;
    }
    
    .events-page-title .wp-page-title {
        font-size: 36px;
        margin-bottom: 40px;
    }
    
    .latest-event-section {
        padding: 0;
        margin-bottom: 40px;
    }
    
    .latest-event-content {
        padding-left: 0;
        text-align: left;
        margin-top: 20px;
    }
    
    .event-title {
        font-size: 20px;
    }
    
    .events-section-title {
        font-size: 22px;
        text-align: center;
    }
    
    .next-event-info {
        font-size: 14px;
        text-align: center;
    }
    
    .previous-events-title {
        font-size: 22px;
        text-align: center;
    }
    
    .events-month-nav {
        justify-content: center;
        margin-top: 20px;
        gap: 10px;
    }
    
    .month-nav-btn {
        font-size: 16px;
        padding: 3px;
    }
    
    .today-btn {
        padding: 10px 16px;
        font-size: 11px;
    }
    
    .month-dropdown select {
        min-width: 150px;
        padding: 10px 12px;
    }
    
    .month-divider {
        font-size: 22px;
        margin: 40px 0 30px 0;
        text-align: center;
    }
    
    .event-item {
        padding: 0;
        margin-bottom: 30px;
    }
    
    .event-item .col-md-1 {
        margin-bottom: 0;
    }
    
    .event-date-display {
        padding: 10px 8px;
        min-height: 60px;
    }
    
    .day-number {
        font-size: 18px;
    }
    
    .event-content {
        padding-left: 15px;
        text-align: left;
    }
    
    .event-content .event-title {
        font-size: 20px;
    }
    
    .event-image {
        margin-top: 20px;
    }
    
    .event-image img {
        max-width: 150px;
        min-height: 100px;
    }
    
    .event-actions .btn {
        padding: 12px 25px;
        font-size: 12px;
    }
}

@media (max-width: 480px) {
    .events-page-title .wp-page-title {
        font-size: 28px;
        letter-spacing: 1px;
    }
    
    .latest-event-section {
        padding: 20px 15px;
    }
    
    .event-title {
        font-size: 20px;
    }
    
    .event-excerpt {
        font-size: 14px;
    }
    
    .events-section-title {
        font-size: 18px;
    }
    
    .next-event-info {
        font-size: 13px;
        text-align: center;
    }
    
    .month-nav-btn {
        font-size: 14px;
        padding: 2px;
    }
    
    .today-btn {
        padding: 8px 12px;
        font-size: 10px;
    }
    
    .month-dropdown select {
        min-width: 120px;
        padding: 8px 10px;
        font-size: 12px;
    }
    
    .month-divider {
        font-size: 18px;
    }
    
    .event-item {
        padding: 20px 15px;
    }
    
    .event-date-display {
        padding: 12px 8px;
    }
    
    .day-name {
        font-size: 10px;
    }
    
    .day-number {
        font-size: 20px;
    }
    
    .event-content .event-title {
        font-size: 18px;
    }
    
    .event-content .event-excerpt {
        font-size: 14px;
    }
    
    .placeholder-image {
        height: 150px;
        font-size: 12px;
    }
    
    .no-events {
        padding: 50px 15px;
        font-size: 16px;
    }
}

/* Print Styles */
@media print {
    .events-month-nav,
    .event-actions,
    .latest-event-section {
        display: none;
    }
    
    .event-item {
        break-inside: avoid;
        box-shadow: none;
        border: 1px solid #ccc;
    }
    
    .event-title a {
        color: #000 !important;
        text-decoration: none;
    }
}
