/* --- Google Font Import --- */
@import url('https://fonts.googleapis.com/css2?family=Poppins:wght@300;400;600;700&display=swap');

/* --- General & Typography --- */
:root {
    --primary-color: #d81b60; /* Vibrant Pink/Red */
    --secondary-color: #ff8f00; /* Amber/Orange */
    --dark-bg: #1a1a1a;
    --light-bg: #2c2c2c;
    --text-color: #f5f5f5;
    --text-muted: #aaa;
    --border-color: #444;
}

body {
    font-family: 'Poppins', sans-serif;
    background-color: var(--dark-bg);
    color: var(--text-color);
    margin: 0;
    padding: 20px;
    line-height: 1.6;
}

.container {
    max-width: 900px;
    margin: 20px auto;
    background-color: var(--light-bg);
    padding: 30px;
    border-radius: 12px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.3);
}

h1, h2 {
    color: var(--primary-color);
    font-weight: 600;
}

a {
    color: var(--secondary-color);
    text-decoration: none;
    transition: color 0.3s;
}

    a:hover {
        color: #ffc107; /* Lighter Amber on hover */
    }

/* --- Buttons & Links --- */
.btn {
    display: inline-block;
    padding: 10px 20px;
    border-radius: 8px;
    text-decoration: none;
    color: #fff;
    font-weight: 600; /* Ensures consistent boldness */
    font-size: 1em; /* Ensures consistent size */
    font-family: inherit; /* Ensures both use the page's main font */
    cursor: pointer;
    border: none;
    transition: background-color 0.3s, transform 0.2s;
}

    .btn:hover {
        transform: translateY(-2px);
    }

.btn-primary {
    background-color: var(--primary-color);
}

    .btn-primary:hover {
        background-color: #c2185b;
    }

.btn-secondary {
    background-color: var(--secondary-color);
}

    .btn-secondary:hover {
        background-color: #ffa000;
    }

.btn-danger {
    background-color: #c62828;
}

    .btn-danger:hover {
        background-color: #b71c1c;
    }


/* --- Forms --- */
form {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

    form p {
        margin: 0;
    }

label {
    display: block;
    margin-bottom: 5px;
    font-weight: 600;
    color: var(--text-muted);
}

input[type="text"],
input[type="email"],
input[type="password"],
input[type="datetime-local"],
input[type="number"],
input[type="url"],
input[type="date"] {
    width: 100%;
    padding: 12px;
    background-color: var(--dark-bg);
    border: 1px solid var(--border-color);
    border-radius: 8px;
    color: var(--text-color);
    box-sizing: border-box;
    font-size: 1em;
}

#id_styles {
    list-style-type: none;
    padding: 0;
    color: var(--text-muted);
}

    #id_styles li label {
        display: inline-block;
        margin-left: 10px;
        font-weight: 400;
    }


/* --- Site Header --- */
.site-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1.5rem 2rem; /* Added more horizontal padding */
    text-align: center;
    border-bottom: 1px solid var(--border-color);
}

/* Add a rule for the new nav section */
.user-actions {
    display: flex;
}

.site-title {
    font-size: 2.5em; /* Slightly larger for impact */
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 2px;
    /* Fallback color for older browsers */
    color: var(--secondary-color);
    /* Create the vibrant color gradient */
    background-image: linear-gradient(45deg, var(--primary-color), var(--secondary-color));
    /* Clip the background to the text shape */
    -webkit-background-clip: text;
    background-clip: text;
    /* Make the text color transparent so the gradient shows through */
    color: transparent;
}

/* We add a 'main' tag to wrap the content */
main {
    padding: 20px;
}

/* Adjust body padding now that main has it */
body {
    padding: 0;
}

/* Add this new rule for the dropdown select element */
select {
    /* 1. Basic styling to match other inputs */
    width: 100%;
    padding: 12px;
    background-color: var(--dark-bg);
    border: 1px solid var(--border-color);
    border-radius: 8px;
    color: var(--text-color);
    font-size: 1em;
    font-family: inherit;
    box-sizing: border-box;
    cursor: pointer;
    /* 2. Hide the default browser arrow */
    -webkit-appearance: none;
    -moz-appearance: none;
    appearance: none;
    /* 3. Add a custom arrow using an SVG background image */
    background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16'%3e%3cpath fill='none' stroke='%23f5f5f5' stroke-linecap='round' stroke-linejoin='round' stroke-width='2' d='M2 5l6 6 6-6'/%3e%3c/svg%3e");
    background-repeat: no-repeat;
    background-position: right 1rem center;
    background-size: 1em;
    /* 4. Add padding to prevent text from overlapping the new arrow */
    padding-right: 2.5rem;
}

/* --- Event & Dashboard Specific --- */
.header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-bottom: 1px solid var(--border-color);
    padding-bottom: 15px;
    margin-bottom: 20px;
    flex-wrap: wrap;
    gap: 10px;
}

.header-actions a {
    margin-left: 10px;
}

.event {
    border-bottom: 1px solid var(--border-color);
    padding: 20px 0;
}

    .event:last-child {
        border-bottom: none;
    }

.event-name {
    font-size: 1.5em;
    color: var(--secondary-color);
    margin-bottom: 5px;
}

.event-details, .event-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 15px;
    align-items: center;
}

.styles span {
    background-color: var(--primary-color);
    color: #fff;
    padding: 4px 10px;
    border-radius: 15px;
    font-size: 0.9em;
}

/* --- Responsive Design --- */
@media (max-width: 768px) {
    body {
        padding: 10px;
    }

    .container {
        padding: 20px;
    }

    .header {
        flex-direction: column;
        align-items: stretch;
    }

        .header h1 {
            text-align: center;
            margin-bottom: 10px;
        }

    .header-actions {
        display: flex;
        justify-content: center;
    }

    .event-details, .event-actions {
        flex-direction: column;
        align-items: flex-start;
    }
}

/* --- Styles for Clickable Event List --- */
.event-card-link {
    display: block;
    text-decoration: none;
    color: inherit;
    border-radius: 8px;
    margin-bottom: 15px;
    transition: background-color 0.3s, transform 0.2s;
}

    .event-card-link .event {
        border-bottom: none; /* We remove the line, the card is the separator */
        background-color: var(--light-bg);
        padding: 20px;
        border: 1px solid var(--border-color);
        border-radius: 8px;
    }

    .event-card-link:hover {
        transform: translateY(-5px);
        background-color: #3a3a3a;
    }

        .event-card-link:hover .event-name {
            color: #fff;
        }


/* --- Styles for Event Detail Page --- */
.event-details-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
    margin-top: 20px;
    border-top: 1px solid var(--border-color);
    padding-top: 20px;
}

.detail-item strong {
    color: var(--secondary-color);
    font-size: 1.1em;
}

.detail-item p {
    margin: 5px 0 0 0;
}

@media (max-width: 768px) {
    .event-details-grid {
        grid-template-columns: 1fr; /* Stack items on mobile */
    }
}

/* --- Styles for Date Scroller --- */
.date-scroller {
    display: flex;
    overflow-x: auto;
    padding-bottom: 15px; /* For the scrollbar */
    margin-bottom: 20px;
    -ms-overflow-style: none; /* IE and Edge */
    scrollbar-width: none; /* Firefox */
}

    .date-scroller::-webkit-scrollbar {
        display: none; /* Hide scrollbar for Chrome, Safari and Opera */
    }

.date-item {
    flex: 0 0 auto; /* Prevent shrinking */
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    min-width: 65px;
    padding: 10px 5px;
    border: 1px solid var(--border-color);
    border-radius: 8px;
    margin-right: 10px;
    text-align: center;
    cursor: pointer;
    transition: background-color 0.3s, border-color 0.3s;
}

    .date-item:hover {
        background-color: #3a3a3a;
    }

    .date-item.active {
        background-color: var(--primary-color);
        border-color: var(--primary-color);
        color: #fff;
    }

        .date-item.active .day-name,
        .date-item.active .month-name {
            color: #fff;
        }

.day-name {
    font-size: 0.8em;
    font-weight: 600;
    text-transform: uppercase;
    color: var(--text-muted);
}

.day-number {
    font-size: 1.5em;
    font-weight: 700;
    line-height: 1.2;
}

.month-name {
    font-size: 0.8em;
    color: var(--text-muted);
}


.checkbox-group {
    display: flex;
    flex-wrap: nowrap; /* This ensures the items stay on one line */
    gap: 20px; /* Adjusts the space between checkboxes */
    align-items: center;
    overflow-x: auto; /* Adds a scrollbar if items overflow */
    padding-bottom: 10px; /* Adds space for the scrollbar */
}

.form-actions {
    margin-top: 20px;
    display: flex;
    gap: 10px;
}

    /* Add this new rule below the one above */
    .form-actions .btn {
        flex-grow: 1; /* This makes both buttons grow to fill the space equally */
        text-align: center; /* This centers the text inside the buttons */
    }

/* --- Styles for Collapsible Filter and Location Button --- */

/* Rule to hide the filter content when collapsed */
#filter-content.collapsed {
    display: none;
}

/* Container for the location input and button */
.location-input-group {
    display: flex;
    gap: 10px;
    align-items: center;
}

    .location-input-group input {
        flex-grow: 1; /* Input takes up most of the space */
    }

    .location-input-group button {
        flex-shrink: 0; /* Button does not shrink */
        padding: 12px; /* Make button height match input */
    }