/**
 * Events & Deadlines Styling
 * For section landing page event cards and countdown displays
 */

/* Events Section Container */
.sp-events-deadlines {
    margin: 40px 0;
    padding: 30px;
    background: #ffffff;
    border-radius: 12px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
}

.sp-events-deadlines h2 {
    font-size: 28px;
    margin: 0 0 25px 0;
    color: #2c3e50;
    font-weight: 700;
}

/* Events List Grid */
.sp-events-list {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 20px;
}

@media (max-width: 768px) {
    .sp-events-list {
        grid-template-columns: 1fr;
    }
}

/* Event Card - Note: Card itself is not clickable, only button inside */
.sp-event-card {
    background: #ffffff;
    border: 2px solid #e1e8ed;
    border-radius: 10px;
    overflow: hidden;
    display: flex;
    flex-direction: column;
}

/* Urgency States */
.sp-event-card.sp-event-urgent {
    border-color: #ff9800;
    background: #fff8f0;
}

.sp-event-card.sp-event-urgent-today {
    border-color: #e74c3c;
    background: #fff5f5;
    animation: pulse-urgent 2s ease-in-out infinite;
}

@keyframes pulse-urgent {
    0%, 100% {
        box-shadow: 0 0 0 0 rgba(231, 76, 60, 0.4);
    }
    50% {
        box-shadow: 0 0 0 8px rgba(231, 76, 60, 0);
    }
}

.sp-event-card.sp-event-passed {
    opacity: 0.6;
    border-color: #95a5a6;
}

/* Event Card Header */
.sp-event-card-header {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 15px 20px;
    background: #688664;
    color: white;
}

.sp-event-card[data-event-type="camp"] .sp-event-card-header {
    background: #2c5f4f;
}

.sp-event-card[data-event-type="fundraiser"] .sp-event-card-header {
    background: #6b5b7a;
}

.sp-event-card[data-event-type="payment_deadline"] .sp-event-card-header {
    background: #c9704d;
}

.sp-event-card[data-event-type="trip"] .sp-event-card-header {
    background: #5b7c99;
}

.sp-event-card[data-event-type="ceremony"] .sp-event-card-header {
    background: #8b4d4d;
}

.sp-event-card[data-event-type="special"] .sp-event-card-header {
    background: #6b5b7a;
}

.sp-event-icon {
    font-size: 24px;
    line-height: 1;
}

.sp-event-type {
    font-size: 13px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

/* Event Card Body */
.sp-event-card-body {
    padding: 20px;
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.sp-event-title {
    font-size: 20px;
    font-weight: 700;
    color: #2c3e50;
    margin: 0;
    line-height: 1.3;
}

.sp-event-description {
    font-size: 14px;
    color: #555;
    line-height: 1.5;
    margin: 0;
}

.sp-event-description p {
    margin: 0;
}

/* Event Meta Information */
.sp-event-meta {
    display: flex;
    flex-direction: column;
    gap: 8px;
    font-size: 14px;
    color: #555;
    padding: 12px 0;
    border-top: 1px solid #e1e8ed;
}

.sp-event-deadline,
.sp-event-date,
.sp-event-amount {
    display: flex;
    align-items: center;
}

.sp-event-meta strong {
    color: #2c3e50;
    margin-right: 6px;
}

.sp-event-amount {
    color: #27ae60;
    font-weight: 600;
}

/* Countdown Display */
.sp-event-countdown {
    padding: 12px 16px;
    background: #f8f9fa;
    border-radius: 8px;
    text-align: center;
    font-size: 15px;
    margin-top: auto;
}

/* Countdown badges inherited from section-landing.css - No need to redefine */
/* Note: If different styling needed for events, use more specific selectors:
   .sp-events-deadlines .sp-countdown-today { ... } */

/* Event Card Footer */
.sp-event-card-footer {
    padding: 15px 20px;
    background: #f8f9fa;
    border-top: 1px solid #e1e8ed;
}

.sp-button-event {
    display: inline-block;
    width: 100%;
    padding: 10px 20px;
    background: #5b7c99;
    color: white;
    text-align: center;
    text-decoration: none;
    border-radius: 6px;
    font-weight: 600;
    font-size: 14px;
    transition: background 0.3s ease;
}

.sp-button-event:hover {
    background: #4a6680;
    color: white;
    text-decoration: none;
}

.sp-event-card.sp-event-urgent .sp-button-event {
    background: #c9704d;
}

.sp-event-card.sp-event-urgent .sp-button-event:hover {
    background: #b5603f;
}

.sp-event-card.sp-event-urgent-today .sp-button-event {
    background: #8b4d4d;
}

.sp-event-card.sp-event-urgent-today .sp-button-event:hover {
    background: #753f3f;
}

/* Empty State */
.sp-events-deadlines .sp-no-events {
    text-align: center;
    padding: 40px 20px;
    color: #95a5a6;
    font-style: italic;
}

/* Responsive Design */
@media (max-width: 768px) {
    .sp-events-deadlines {
        padding: 20px;
        margin: 20px 0;
    }

    .sp-events-deadlines h2 {
        font-size: 24px;
        margin-bottom: 20px;
    }

    .sp-event-title {
        font-size: 18px;
    }

    .sp-event-card-body {
        padding: 15px;
    }
}
