
/**
 * Public CSS
 *
 * @package EarthTribe_Events
 */

/* Event List Styles */
.earthtribe-events.grid {
        display: grid;
        gap: 30px;
        margin: 30px 0;
}

.earthtribe-events.grid[data-columns="1"] {
        grid-template-columns: 1fr;
}

.earthtribe-events.grid[data-columns="2"] {
        grid-template-columns: repeat(2, 1fr);
}

.earthtribe-events.grid[data-columns="3"] {
        grid-template-columns: repeat(3, 1fr);
}

.earthtribe-events.grid[data-columns="4"] {
        grid-template-columns: repeat(4, 1fr);
}

.earthtribe-events.list {
        display: flex;
        flex-direction: column;
        gap: 20px;
        margin: 30px 0;
}

.event-card {
        border: 1px solid #ddd;
        border-radius: 8px;
        overflow: hidden;
        background: #fff;
        transition: transform 0.3s, box-shadow 0.3s;
}

.event-card:hover {
        transform: translateY(-5px);
        box-shadow: 0 5px 20px rgba(0, 0, 0, 0.1);
}

.event-card .event-image {
        width: 100%;
        height: 200px;
        overflow: hidden;
}

.event-card .event-image img {
        width: 100%;
        height: 100%;
        object-fit: cover;
        transition: transform 0.3s;
}

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

.event-card .event-content {
        padding: 20px;
}

.event-card .event-title {
        margin: 0 0 15px 0;
        font-size: 20px;
        line-height: 1.3;
}

.event-card .event-title a {
        color: #333;
        text-decoration: none;
}

.event-card .event-title a:hover {
        color: #4CAF50;
}

.event-card .event-meta {
        display: flex;
        flex-direction: column;
        gap: 8px;
        margin-bottom: 15px;
        font-size: 14px;
        color: #666;
}

.event-card .event-meta > div {
        display: flex;
        align-items: center;
}

.event-card .event-meta .dashicons {
        margin-right: 8px;
        color: #4CAF50;
        width: 18px;
        height: 18px;
        font-size: 18px;
}

.event-card .event-excerpt {
        margin-bottom: 15px;
        color: #555;
        font-size: 14px;
        line-height: 1.6;
}

.event-card .event-footer {
        display: flex;
        justify-content: space-between;
        align-items: center;
        padding-top: 15px;
        border-top: 1px solid #eee;
}

.event-card .event-price {
        font-size: 18px;
        font-weight: bold;
        color: #4CAF50;
}

.event-button {
        display: inline-block;
        padding: 10px 20px;
        background: #4CAF50;
        color: white;
        text-decoration: none;
        border-radius: 4px;
        font-size: 14px;
        font-weight: 600;
        transition: background 0.3s;
        border: none;
        cursor: pointer;
}

.event-button:hover {
        background: #45a049;
        color: white;
}

/* Event Detail Styles */
.earthtribe-event-detail {
        margin: 30px 0;
}

.earthtribe-event-detail .event-detail-image {
        margin-bottom: 30px;
}

.earthtribe-event-detail .event-detail-image img {
        width: 100%;
        max-height: 500px;
        object-fit: cover;
        border-radius: 8px;
}

.earthtribe-event-detail .event-detail-title {
        font-size: 36px;
        margin-bottom: 20px;
}

.earthtribe-event-detail .event-detail-meta {
        background: #f5f5f5;
        padding: 20px;
        border-radius: 8px;
        margin-bottom: 30px;
}

.earthtribe-event-detail .event-detail-meta-item {
        margin-bottom: 15px;
        display: flex;
        align-items: flex-start;
}

.earthtribe-event-detail .event-detail-meta-item:last-child {
        margin-bottom: 0;
}

.earthtribe-event-detail .event-detail-meta-item .dashicons {
        margin-right: 10px;
        color: #4CAF50;
        flex-shrink: 0;
}

/* My Account Styles */
.earthtribe-my-registrations {
        margin: 30px 0;
}

.earthtribe-my-registrations .registration-item {
        border: 1px solid #ddd;
        border-radius: 8px;
        padding: 20px;
        margin-bottom: 20px;
        background: #fff;
}

.earthtribe-my-registrations .registration-item h3 {
        margin-top: 0;
        color: #4CAF50;
}

/* Responsive */
@media (max-width: 768px) {
        .earthtribe-events.grid[data-columns="2"],
        .earthtribe-events.grid[data-columns="3"],
        .earthtribe-events.grid[data-columns="4"] {
                grid-template-columns: 1fr;
        }

        .event-card .event-footer {
                flex-direction: column;
                gap: 15px;
                align-items: flex-start;
        }

        .earthtribe-event-detail .event-detail-title {
                font-size: 28px;
        }
}

/* Loading State */
.earthtribe-loading {
        text-align: center;
        padding: 40px;
}

.earthtribe-loading::before {
        content: "";
        display: inline-block;
        width: 40px;
        height: 40px;
        border: 4px solid #f3f3f3;
        border-top: 4px solid #4CAF50;
        border-radius: 50%;
        animation: spin 1s linear infinite;
}

@keyframes spin {
        0% {
                transform: rotate(0deg);
        }
        100% {
                transform: rotate(360deg);
        }
}

/* Registration Section Styles */
.event-registration-section {
        margin-top: 40px;
        padding: 30px;
        background: #f8f9fa;
        border-radius: 8px;
        text-align: center;
}

.earthtribe-register-button {
        padding: 15px 40px;
        background: #4CAF50;
        color: white;
        border: none;
        border-radius: 8px;
        font-size: 18px;
        font-weight: 600;
        cursor: pointer;
        transition: all 0.3s ease;
        box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
}

.earthtribe-register-button:hover {
        background: #45a049;
        transform: translateY(-2px);
        box-shadow: 0 6px 12px rgba(0, 0, 0, 0.15);
}

.login-notice {
        font-size: 16px;
        color: #555;
}

.login-notice a {
        color: #4CAF50;
        text-decoration: none;
        font-weight: 600;
}

.login-notice a:hover {
        text-decoration: underline;
}

/* Modal Styles */
.earthtribe-modal {
        display: none;
        position: fixed;
        z-index: 9999;
        left: 0;
        top: 0;
        width: 100%;
        height: 100%;
        overflow: auto;
        background-color: rgba(0, 0, 0, 0.6);
        backdrop-filter: blur(4px);
}

.earthtribe-modal-content {
        background-color: #fff;
        margin: 5% auto;
        padding: 40px;
        border-radius: 12px;
        max-width: 600px;
        width: 90%;
        position: relative;
        box-shadow: 0 10px 40px rgba(0, 0, 0, 0.2);
        animation: slideDown 0.3s ease;
}

@keyframes slideDown {
        from {
                opacity: 0;
                transform: translateY(-50px);
        }
        to {
                opacity: 1;
                transform: translateY(0);
        }
}

.earthtribe-modal-close {
        position: absolute;
        top: 20px;
        right: 25px;
        font-size: 35px;
        font-weight: bold;
        color: #999;
        cursor: pointer;
        line-height: 1;
        transition: color 0.2s;
}

.earthtribe-modal-close:hover {
        color: #333;
}

.earthtribe-modal-content h2 {
        margin: 0 0 30px 0;
        font-size: 28px;
        color: #2c3e50;
        text-align: center;
}

/* Payment Options Styles */
.earthtribe-payment-options {
        display: flex;
        flex-direction: column;
        gap: 20px;
}

.earthtribe-payment-option {
        display: flex;
        flex-direction: column;
        align-items: center;
        padding: 25px;
        background: #f8f9fa;
        border: 2px solid #e0e0e0;
        border-radius: 8px;
        cursor: pointer;
        transition: all 0.3s ease;
        text-align: center;
}

.earthtribe-payment-option:not(.earthtribe-coming-soon):hover {
        background: #4CAF50;
        border-color: #4CAF50;
        transform: translateY(-3px);
        box-shadow: 0 6px 12px rgba(76, 175, 80, 0.3);
}

.earthtribe-payment-option:not(.earthtribe-coming-soon):hover .payment-title,
.earthtribe-payment-option:not(.earthtribe-coming-soon):hover .payment-description {
        color: white;
}

.earthtribe-payment-option.earthtribe-coming-soon {
        opacity: 0.6;
        cursor: not-allowed;
}

.payment-icon {
        font-size: 48px;
        margin-bottom: 15px;
}

.payment-title {
        font-size: 22px;
        font-weight: 600;
        color: #2c3e50;
        margin-bottom: 8px;
}

.payment-description {
        font-size: 14px;
        color: #666;
}

/* Event Summary Styles */
.earthtribe-event-summary {
        background: #e8f5e9;
        padding: 20px;
        border-radius: 8px;
        margin-bottom: 30px;
        border-left: 4px solid #4CAF50;
}

.earthtribe-event-summary h3 {
        margin: 0 0 15px 0;
        color: #2c3e50;
        font-size: 20px;
}

.event-summary-item {
        padding: 8px 0;
        color: #555;
        font-size: 15px;
}

.event-summary-item strong {
        color: #2c3e50;
        margin-right: 8px;
}

/* Form Styles */
.earthtribe-form-group {
        margin-bottom: 25px;
}

.earthtribe-form-group label {
        display: block;
        margin-bottom: 8px;
        color: #2c3e50;
        font-weight: 600;
        font-size: 15px;
}

.earthtribe-form-group input[type="text"],
.earthtribe-form-group input[type="email"],
.earthtribe-form-group input[type="tel"] {
        width: 100%;
        padding: 12px 15px;
        border: 2px solid #e0e0e0;
        border-radius: 6px;
        font-size: 15px;
        transition: border-color 0.3s;
        box-sizing: border-box;
}

.earthtribe-form-group input:focus {
        outline: none;
        border-color: #4CAF50;
}

.earthtribe-form-message {
        padding: 15px;
        border-radius: 6px;
        margin-bottom: 20px;
        font-size: 14px;
        display: none;
}

.earthtribe-form-message.success {
        background: #d4edda;
        color: #155724;
        border: 1px solid #c3e6cb;
}

.earthtribe-form-message.error {
        background: #f8d7da;
        color: #721c24;
        border: 1px solid #f5c6cb;
}

.earthtribe-form-actions {
        display: flex;
        gap: 15px;
        margin-top: 30px;
}

.earthtribe-submit-btn,
.earthtribe-cancel-btn {
        flex: 1;
        padding: 14px 30px;
        border: none;
        border-radius: 6px;
        font-size: 16px;
        font-weight: 600;
        cursor: pointer;
        transition: all 0.3s ease;
}

.earthtribe-submit-btn {
        background: #4CAF50;
        color: white;
}

.earthtribe-submit-btn:hover:not(:disabled) {
        background: #45a049;
        transform: translateY(-2px);
        box-shadow: 0 4px 8px rgba(76, 175, 80, 0.3);
}

.earthtribe-submit-btn:disabled {
        opacity: 0.6;
        cursor: not-allowed;
}

.earthtribe-cancel-btn {
        background: #e0e0e0;
        color: #555;
}

.earthtribe-cancel-btn:hover {
        background: #d0d0d0;
}

/* Page Message */
.earthtribe-page-message {
        padding: 15px 20px;
        border-radius: 6px;
        margin-bottom: 30px;
        font-size: 15px;
        text-align: center;
}

.earthtribe-page-message.success {
        background: #d4edda;
        color: #155724;
        border: 1px solid #c3e6cb;
}

.earthtribe-page-message.error {
        background: #f8d7da;
        color: #721c24;
        border: 1px solid #f5c6cb;
}

/* Responsive Styles for Modals */
@media (max-width: 768px) {
        .earthtribe-modal-content {
                margin: 10% auto;
                padding: 25px;
                width: 95%;
        }

        .earthtribe-modal-content h2 {
                font-size: 22px;
        }

        .earthtribe-form-actions {
                flex-direction: column;
        }

        .payment-title {
                font-size: 18px;
        }

        .payment-icon {
                font-size: 36px;
        }
}
