/* Trip Form Styles */
.trip-form-container {
    max-width: 800px;
    margin: 2em auto;
    padding: 2em;
    background: #fff;
    border-radius: 8px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

.trip-form .form-group {
    margin-bottom: 1.5em;
}

.trip-form label {
    display: block;
    margin-bottom: 0.5em;
    font-weight: 600;
    color: #333;
}

.trip-form input[type='text'],
.trip-form input[type='datetime-local'],
.trip-form input[type='number'],
.trip-form textarea {
    width: 100%;
    padding: 0.8em;
    border: 1px solid #ddd;
    border-radius: 4px;
    font-size: 1em;
}

.trip-form input:focus,
.trip-form textarea:focus {
    outline: none;
    border-color: #0073aa;
    box-shadow: 0 0 5px rgba(0,115,170,0.2);
}

.submit-button {
    background: #0073aa;
    color: white;
    padding: 1em 2em;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    font-size: 1em;
    font-weight: 500;
}

.submit-button:hover {
    background: #005177;
}

/* Trip Grid/List Styles */
.trips-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 2em;
}

.trips-filter {
    margin-bottom: 2em;
    display: flex;
    gap: 1em;
    align-items: center;
}

.trips-filter input,
.trips-filter select {
    padding: 0.8em;
    border: 1px solid #ddd;
    border-radius: 4px;
    min-width: 200px;
}

.trips-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 2em;
}

.trip-card {
    background: #fff;
    border-radius: 8px;
    padding: 1.5em;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.trip-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 4px 8px rgba(0,0,0,0.15);
}

.trip-card h3 {
    margin: 0 0 1em 0;
    color: #333;
    font-size: 1.2em;
}

.trip-card .trip-details {
    margin-bottom: 1.5em;
}

.trip-card .trip-details p {
    margin: 0.5em 0;
    color: #666;
}

.trip-card .trip-details strong {
    color: #333;
}

/* Single Trip Page Styles */
.trip-single-container {
    max-width: 1200px;
    margin: 2em auto;
    padding: 0 20px;
}

.trip-content-wrapper {
    background: #fff;
    padding: 2em;
    border-radius: 8px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

.trip-header {
    margin-bottom: 2em;
}

.trip-title {
    margin: 0 0 0.5em 0;
    color: #333;
    font-size: 2em;
}

.trip-meta {
    color: #666;
    font-size: 0.9em;
}

.trip-details-box {
    background: #f9f9f9;
    padding: 1.5em;
    border-radius: 4px;
    margin: 1.5em 0;
}

.trip-info p {
    margin: 0.8em 0;
    line-height: 1.6;
}

.trip-description {
    margin: 2em 0;
    line-height: 1.6;
}

.trip-description h2 {
    color: #333;
    margin-bottom: 1em;
}

/* Button Styles */
.view-trip-button, .join-trip-button, .leave-trip-button {
    display: inline-block;
    padding: 2px 10px;
    border-radius: 4px;
    text-decoration: none;
    font-weight: 500;
    transition: background-color 0.3s ease;
    border: none;
    cursor: pointer;
    margin-right: 1em;
}

.view-trip-button {
    background: #0073aa;
    color: white !important;
}

.view-trip-button:hover {
    background: #005177;
    text-decoration: none;
}

.join-trip-button {
    background: #4CAF50;
    color: white;
}

.join-trip-button:hover {
    background: #388E3C;
}

.leave-trip-button {
    background: #f44336;
    color: white;
}

.leave-trip-button:hover {
    background: #d32f2f;
}

/* Participant List Styles */
.trip-participants {
    margin-top: 2em;
}

.participant-list {
    list-style: none;
    padding: 0;
    margin: 1em 0;
    background: #f9f9f9;
    border-radius: 4px;
}

.participant-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1em;
    border-bottom: 1px solid #eee;
}

.participant-item:last-child {
    border-bottom: none;
}

.participant-info {
    display: flex;
    flex-direction: column;
}

.participant-name {
    font-weight: 500;
    color: #333;
}

.participant-email {
    font-size: 0.9em;
    color: #666;
}

.remove-participant-button {
    background: #f44336;
    color: white;
    border: none;
    padding: 0.5em 1em;
    border-radius: 3px;
    cursor: pointer;
    font-size: 0.875em;
}

.remove-participant-button:hover {
    background: #d32f2f;
}

/* Status Notifications */
.trip-status-notice {
    padding: 1em;
    margin-bottom: 1.5em;
    border-radius: 4px;
    font-weight: 500;
}

.trip-status-notice.pending {
    background-color: #fff3cd;
    color: #856404;
    border: 1px solid #ffeeba;
}

.trip-status-notice.draft {
    background-color: #f8f9fa;
    color: #383d41;
    border: 1px solid #d6d8db;
}

.pending-badge {
    background: #f0ad4e;
    color: white;
    padding: 0.3em 0.8em;
    border-radius: 3px;
    font-size: 0.875em;
    margin-bottom: 1em;
    display: inline-block;
}

/* Admin Actions */
.admin-actions {
    margin-top: 1.5em;
    padding-top: 1.5em;
    border-top: 1px solid #eee;
}

.edit-trip-button {
    background: #17a2b8;
    color: white !important;
    text-decoration: none;
    padding: 0.8em 1.5em;
    border-radius: 4px;
    display: inline-block;
    margin-right: 1em;
}

.edit-trip-button:hover {
    background: #138496;
    text-decoration: none;
}

.delete-trip-button {
    background-color: #dc3545;
    color: white;
    border: none;
    padding: 12px;
    border-radius: 4px;
    cursor: pointer;
    font-size: 18px;
}

.delete-trip-button:hover {
    background: #c82333;
}

/* Responsive Design */
@media (max-width: 768px) {
    .trips-grid {
        grid-template-columns: 1fr;
    }

    .trips-filter {
        flex-direction: column;
    }

    .trips-filter input,
    .trips-filter select {
        width: 100%;
    }

    .trip-single-container,
    .trip-form-container {
        padding: 1em;
        margin: 1em;
    }

    .trip-content-wrapper {
        padding: 1em;
    }

    .view-trip-button,
    .join-trip-button,
    .leave-trip-button {
        display: block;
        width: 100%;
        margin: 0.5em 0;
        text-align: center;
    }
}

/* Loading States */
.loading {
    opacity: 0.7;
    pointer-events: none;
    position: relative;
}

.loading::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 30px;
    height: 30px;
    margin: -15px 0 0 -15px;
    border: 3px solid #f3f3f3;
    border-top: 3px solid #0073aa;
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

div#load-more {
    text-align: center;
    margin: 20px;
}

div#load-more button {
    background: #0073aa;
    padding: 5px 10px;
    font-size: 17px;
    border-radius: 5px;
    border: none;
    color: #fff;
    cursor: pointer;
}