/*
CSS variables, global defaults, fonts, and span overrides
*/

* {
    box-sizing: border-box;
    /* z-index: 1; */  /* Removed as it's commented out and likely unnecessary globally */
}

/* Font Faces */
@font-face {
    font-family: 'Balto-Bold';
    src: url('/static/fonts/Balto-Bold.woff2') format('woff2'),
        url('/static/fonts/Balto-Bold.woff') format('woff'),
        url('/static/fonts/Balto-Bold.ttf') format('truetype');
    font-weight: bold;
    font-style: normal;
}

@font-face {
    font-family: 'Balto-Book';
    src: url('/static/fonts/Balto-Book.woff2') format('woff2'),
        url('/static/fonts/Balto-Book.woff') format('woff'),
        url('/static/fonts/Balto-Book.ttf') format('truetype');
    font-weight: normal;
    font-style: normal;
}

@font-face {
    font-family: 'Balto-Medium';
    src: url('/static/fonts/Balto-Medium.woff2') format('woff2'),
        url('/static/fonts/Balto-Medium.woff') format('woff'),
        url('/static/fonts/Balto-Medium.ttf') format('truetype');
    font-weight: 500;
    font-style: normal;
}

@font-face {
    font-family: 'Balto-Light';
    src: url('/static/fonts/Balto-Light.woff2') format('woff2'),
        url('/static/fonts/Balto-Light.woff') format('woff'),
        url('/static/fonts/Balto-Light.ttf') format('truetype');
    font-weight: 300;
    font-style: normal;
}

/* CSS Variables */
:root {
    --dark: #0c0c0c;
    --light: #ebebeb;
    --primary: #0ca066;
    --primary-brighter: #13ca81;
    --secondary: #85fccc;
    --primary-darker: #2b5085;
}

/* Global Styles */
html {
    height: 100%;
}

body {
    display: flex;
    flex-direction: column;
    min-height: 100vh;
    margin: 0;
    padding: 0;
    font-family: 'Balto-Book';
    background: var(--light);
}
.page-content-wrapper {
    flex-grow: 1; 
}

.page-content-wrapper {
    flex-grow: 1; 
}

a,
a:hover,
a:focus,
a:active {
    color: inherit;
    text-decoration: none;
}

h2 {
    font-family: 'Balto-Medium';
    font-size: 44px;
    margin: 0 0 25px 0;
}

section {
    background: var(--light);
    margin: 0;
}
/* First container of a section is page width */
section > div {
    width: 80%;
    margin: 0 auto;
    padding: 30px 0 40px 0;
}

p {
    margin: 0;
    font-size: 18px;
    line-height: 150%;
}

.primary-colour {
    color: var(--primary);
}

/*
Page Header
*/
header {
    width: 100%;
    background: var(--dark);
    color: white;
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px 50px; /* Adjusted padding */
    position: relative; /* For z-index context if needed & icon positioning */
    z-index: 990; /* Below nav overlay and mobile menu panel */
}

.header-logo img {
    width: 260px;
    display: block; /* Prevents extra space below image */
}

/* Navbar */
.header-nav {
    display: flex; /* For aligning icon and ul on mobile if needed, though icon is absolute */
    align-items: center;
}

/* Desktop Navigation (default) */
.header-nav ul {
    list-style-type: none;
    display: flex;
    flex-direction: row;
    justify-content: flex-end; /* Align to right */
    align-items: center;
    margin: 0; /* Reset margin */
    padding: 0; /* Reset padding */
}

.header-nav ul a { /* Styles for desktop links */
    padding: 0 17px;
    text-transform: uppercase;
    font-size: 21px;
    font-family: 'Balto-Medium';
    letter-spacing: 0.5px;
    color: white;
    text-decoration: none;
    transition: color 0.2s ease-in-out;
}

.header-nav ul a li {
    padding-bottom: 3px;
    border-bottom: 3px solid transparent;
    transition: border-color 0.2s ease-in-out;
}

.header-nav ul a:hover {
    color: var(--primary);
}
.header-nav ul a:hover li {
    border-bottom-color: var(--primary-brighter);
}

.header-nav ul a.active {
    color: var(--primary-brighter);
}
.header-nav ul a.active li {
    border-bottom-color: var(--primary-brighter) !important;
}

/* Hamburger Icon - Hidden on Desktop by default */
.header-nav a.icon {
    display: none; /* Hidden on desktop */
    font-size: 28px;
    color: white;
    padding: 5px 8px; /* Tappable area */
    position: absolute; /* Position relative to header */
    right: 25px;
    top: 50%;
    z-index: 1001; /* Above mobile menu panel */
    cursor: pointer;
}


/* --- Mobile Navigation Styles --- */
@media screen and (max-width: 900px) {
    header {
        padding: 15px 25px; /* Reduced padding on mobile */
    }

    .header-logo img {
        width: 200px; /* Smaller logo on mobile */
    }

    /* Hide desktop links */
    .header-nav ul a:not(.icon) { /* Ensure icon itself if it were an <a> inside <ul> is not hidden by this */
        /* The HTML structure changed, so this rule might not be needed if ul itself is restyled */
    }
    
    /* Show Hamburger Icon */
    .header-nav a.icon {
        display: block;
    }

    /* Mobile Menu Panel (ul) */
    .header-nav ul#header-nav-ul {
        position: fixed;
        top: 0;
        right: -100%; /* Start off-screen */
        width: min(80%, 300px); /* 80% of viewport width, max 300px */
        height: 100vh;
        background: var(--dark);
        flex-direction: column;
        justify-content: flex-start;
        align-items: stretch; /* Make <a> take full width */
        padding: 80px 0 20px 0; /* Top padding to clear header/icon, no side padding on ul itself */
        box-shadow: -3px 0 15px rgba(0,0,0,0.25);
        transition: right 0.35s cubic-bezier(0.25, 0.46, 0.45, 0.94);
        z-index: 1000; /* Below icon, above overlay */
        overflow-y: auto; /* Scroll if many items */
    }

    .header-nav.responsive ul#header-nav-ul {
        right: 0; /* Slide in */
    }

    /* Links within Mobile Menu */
    .header-nav ul#header-nav-ul a {
        display: block; /* Full width for tap */
        padding: 15px 25px; /* Padding inside the link */
        font-size: 18px;
        font-family: 'Balto-Medium'; /* Consistent font */
        text-transform: uppercase;
        letter-spacing: 0.5px;
        color: var(--light);
        border-bottom: 1px solid rgba(255, 255, 255, 0.08);
        transition: background-color 0.2s ease, color 0.2s ease;
    }
    .header-nav ul#header-nav-ul a:last-child {
        border-bottom: none;
    }
    .header-nav ul#header-nav-ul a:hover,
    .header-nav ul#header-nav-ul a:focus {
        background-color: rgba(255, 255, 255, 0.1);
        color: var(--primary-brighter);
    }
    .header-nav ul#header-nav-ul a.active {
        color: var(--primary-brighter);
        background-color: rgba(0,0,0,0.1); /* Subtle active background */
    }
    .header-nav ul#header-nav-ul a li { /* Reset desktop li specific styles */
        padding-bottom: 0;
        border-bottom: none;
    }
    .header-nav ul#header-nav-ul a.active li {
         border-bottom: none !important;
    }

    /* Hide desktop hover/active effects for li within mobile */
    .header-nav.responsive ul a:hover li,
    .header-nav.responsive ul a.active li {
        border-bottom-color: transparent !important;
    }
}


/* Body class when mobile menu is open */
body.mobile-nav-open {
    overflow: hidden; /* Prevent scrolling of the page content */
}

/* Navigation Overlay */
.nav-overlay {
    display: none;
    position: fixed;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.1); /* Darker overlay */
    z-index: 900; /* Below menu panel, above page content */
    opacity: 0;
    transition: opacity 1s ease;
}

body.mobile-nav-open .nav-overlay {
    display: block;
    opacity: 1;
}

/*
Footer
*/

footer {
    width: 100%;
    background: var(--dark);
    color: white;
    padding: 10px 0 25px 0;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
}

footer>p {
    font-size: 13px;
    margin-top: 20px;
}

footer>.socials i {
    font-size: 20px;
    margin: 0 6px;
}

.contact-us {
    color:#677079
}

/* Schedule Page Styles */
.schedule-section {
    background: var(--light);
    padding-bottom: 50px;
}

.schedule-header {
    background: var(--dark);
    color: white;
    padding: 40px 50px;
    text-align: center;
    margin-top: 20px;
    margin-bottom: 40px;
    position: relative;
}

.schedule-header h1 {
    font-family: 'Balto-Bold';
    font-size: 42px;
    margin-bottom: 0;
}

.schedule-content {
    width: 90%;
    margin: 0 auto;
}

.matches-table-container {
    background: white;
    border-radius: 8px;
    padding: 25px;
    margin-bottom: 30px;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
    overflow-x: auto;
}

.matches-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 15px;
    min-width: 1000px;
}

.matches-table th {
    background-color: var(--dark);
    color: white;
    padding: 12px 15px;
    text-align: left;
    font-family: 'Balto-Medium';
    position: sticky;
    top: 0;
}

.matches-table tr {
    border-bottom: 1px solid #eee;
}

.matches-table tr:nth-child(even) {
    background-color: #f9f9f9;
}

.matches-table tr:hover {
    background-color: #f0f0f0;
}

.matches-table td {
    padding: 12px 15px;
    vertical-align: middle;
}

.matches-table a {
    /*color: var(--primary);*/  /*Removed comment*/
    text-decoration: none;
    transition: color 0.2s ease;
}

.matches-table a:hover {
    color: var(--primary-darker);
    text-decoration: underline;
}

/* Status Badges */
.status-badge {
    display: inline-block;
    padding: 6px 10px;
    border-radius: 30px;
    font-size: 14px;
    font-family: 'Balto-Medium';
    text-align: center;
}

.status-badge.confirmed {
    background-color: rgba(12, 160, 102, 0.15);
    color: var(--primary);
}

.status-badge.unconfirmed {
    background-color: rgba(255, 193, 7, 0.75);
    color: white;  /* Simplified: Only one color needed */
}

.status-badge.unavailable {
    background-color: rgba(108, 117, 125, 0.15);
    color: #6c757d;
}

.status-badge i {
    margin-right: 4px;
}

/* Button Styles */
/*Combined button style*/

.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    border-radius: 6px;
    font-family: 'Balto-Medium';
    transition: all 0.2s ease;
    cursor: pointer;
    border: none;
    text-decoration: none;
}



.schedule-actions {  /*This class only apply here*/
    display: flex;
    gap: 15px;
    margin-top: 20px;
}

.btn-primary {
    background-color: var(--primary);
    color: white;
    padding: 10px 20px; /*Kept more specific padding from first declaration*/
    font-size: 15px; /*Kept more specific font-size from first declaration*/
}
.btn-primary:hover {
     background-color: var(--primary-brighter);
}

.btn-secondary,.btn-admin { /*Combined as style the same*/
       background-color: var(--dark);
    color: white;
     padding: 10px 20px; /*Kept more specific padding from first declaration*/
    font-size: 15px; /*Kept more specific font-size from first declaration*/
}

.btn-admin{
   background-color: #6c757d; /*Overwrites --dark*/
}
.btn-secondary:hover {
    background-color: #2c2c2c;
}
.btn-admin:hover{
  background-color: #5a6268;
}

.btn-success { /*Unique button*/
    background-color: #28a745;
    color: white;
    padding: 10px 20px; /*Kept more specific padding from first declaration*/
    font-size: 15px; /*Kept more specific font-size from first declaration*/
}

.btn-success:hover {
    background-color: #218838;
}


/* Responsive Adjustments */
@media screen and (max-width: 992px) {
    .schedule-header {
        padding: 30px 20px;
    }

    .schedule-header h1 {
        font-size: 32px;
    }

    .schedule-content {
        width: 95%;
    }

      .btn {  /*Apply to all .btn in this media querie*/
        padding: 8px 16px;
        font-size: 14px;
    }
}



/* Event Details Page Styles */

.event-details {
    background: var(--light);
    padding-bottom: 50px;
}

.event-header {  /*This class is used on multiple pages, keep specific*/
    background: var(--dark);
    color: white;
    padding: 40px 50px;
    text-align: center;
    margin-top: 20px;
    margin-bottom: 40px;
    position: relative;
}

.event-header h1 {  /*This class is used on multiple pages, keep specific*/
    font-family: 'Balto-Bold';
    font-size: 48px;
    margin-bottom: 15px;
}

.event-date {   /*This class is used on multiple pages, keep specific*/
    font-family: 'Balto-Medium';
    font-size: 22px;
    color: var(--secondary);
}

.admin-notice {
    position: absolute;
    top: 15px;
    right: 15px;
    background: rgba(255, 0, 0, 0.1);
    color: #ff4d4d;
    padding: 8px 12px;
    border-radius: 4px;
    font-family: 'Balto-Medium';
    font-size: 14px;
}

.event-content {  /*This class is used on multiple pages, keep specific*/
    width: 80%;
    margin: 0 auto;
}

/* Event Info Cards */
.event-info {
    display: flex;
    justify-content: space-between;
    margin-bottom: 40px;
    gap: 30px;
}

.info-card {
    background: white;
    border-radius: 8px;
    padding: 25px;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
    flex: 1;
}

.info-card h3 {
    font-family: 'Balto-Medium';
    font-size: 24px;
    margin-bottom: 20px;
    color: var(--dark);
    padding-bottom: 10px;
    border-bottom: 2px solid var(--primary);
}

.info-card ul {
    list-style-type: none;
    padding: 0;
    margin: 0;
}

.info-card li {
    margin-bottom: 14px;
    font-size: 16px;
    display: flex;
    align-items: center;
}

.info-card li i {
    color: var(--primary);
    margin-right: 10px;
    width: 20px;
    text-align: center;
}

/* Registration Status */
.registration-status {
    text-align: center;
}

/*Reuse .status-badge and variations */

.status-badge.open {  /*Specific status*/
    background-color: rgba(12, 160, 102, 0.15);
    color: var(--primary);
}

.status-badge.closed { /*Specific status*/
    background-color: rgba(220, 53, 69, 0.15);
    color: #dc3545;
}


/* Event Description */
.event-description {
    background: white;
    border-radius: 8px;
    padding: 25px;
    margin-bottom: 40px;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
}

.event-description h3 { /*Keep specific*/
    font-family: 'Balto-Medium';
    font-size: 24px;
    margin-bottom: 20px;
    color: var(--dark);
    padding-bottom: 10px;
    border-bottom: 2px solid var(--primary);
}

.description-content {
    white-space: pre-line;
    word-break: break-word;
    overflow-wrap: break-word; 
    line-height: 1.6;
    color: #333;
}

/* Categories Section */
.categories-section {
    background: white;
    border-radius: 8px;
    padding: 25px;
    margin-bottom: 40px;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
}

.categories-section h3 {/*Keep specific*/
    font-family: 'Balto-Medium';
    font-size: 24px;
    margin-bottom: 20px;
    color: var(--dark);
    padding-bottom: 10px;
    border-bottom: 2px solid var(--primary);
}

.categories-grid { /*Used multiple times*/
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    gap: 20px;
}

.category-card {
    background: #f8f9fa;
    padding: 15px;
    border-radius: 6px;
    border-left: 4px solid var(--primary);
}

.category-card h4 {
    margin-top: 0;
    margin-bottom: 10px;
    font-family: 'Balto-Medium';
    font-size: 16px;
}

.category-card p {
    margin: 0;
    font-size: 14px;
    color: #666;
}

/* Buttons and Actions */
.event-actions {
    background: white;
    border-radius: 8px;
    padding: 25px;
    margin-bottom: 30px;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
}

.event-actions h3 {/*Keep specific*/
    font-family: 'Balto-Medium';
    font-size: 24px;
    margin-bottom: 20px;
    color: var(--dark);
    padding-bottom: 10px;
    border-bottom: 2px solid var(--primary);
}

.action-buttons {
    display: flex;
    flex-wrap: wrap;
    gap: 15px;
}

.admin-actions {
    margin-top: 30px;
    padding-top: 20px;
    border-top: 1px dashed #ddd;
    width: 100%;
}

.admin-buttons {
    display: flex;
    flex-wrap: wrap;
    gap: 15px;
}

.back-link {   /*Used multiple times*/
    width: 80%;
    margin: 0 auto;
    padding-top: 20px;
}

.back-link a {  /*Used multiple times*/
    color: var(--dark);
    font-family: 'Balto-Medium';
    display: inline-flex;
    align-items: center;
    transition: color 0.2s ease;
    text-decoration: none; /*Already in global a style*/
}

.back-link a:hover { /*Used multiple times*/
    color: var(--primary);
}

.back-link i {  /*Used multiple times*/
    margin-right: 8px;
}

/* Responsive Adjustments */
@media screen and (max-width: 900px) {
    /* .event-header and h1 already styled in previous media query */

    .event-content {
        width: 90%;
    }

    .event-info {
        flex-direction: column;
    }
     /*Categories grid already has a minmax, just reduce min*/
    .categories-grid {
          grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
    }

}



/* Signup Page Styles - Based on Event Details styling */
.signup-details {
    background: var(--light);
    padding-bottom: 50px;
}

/*Reuse event header*/

.signup-content {  /*This class is used on multiple pages, keep specific*/
    width: 80%;
    margin: 0 auto;
    max-width: 800px;
}

/* Signup Form Card */
.signup-card {
    background: white;
    border-radius: 8px;
    padding: 25px;
    margin-bottom: 30px;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
}

.partner-form {
    background: white;
    border-radius: 8px;
    padding: 25px;
    margin-bottom: 30px;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
    /* Keep initial hide/show transition based on checkbox */
    opacity: 0;
    max-height: 0;
    overflow: hidden; /* Important for smooth checkbox toggle */
    transition: opacity 0.5s ease-in-out, max-height 0.5s ease-in-out, margin-bottom 0.3s ease-in-out, padding 0.3s ease-in-out;
    /* Remove padding when hidden by checkbox */
    padding-top: 0;
    padding-bottom: 0;
    margin-bottom: 0; /* Remove margin when hidden by checkbox */
}

.partner-form.partner-form-visible {
    opacity: 1;
    max-height: 1000px; /* Allow space for content */
    overflow: visible;
    /* Restore padding/margin when shown by checkbox */
    padding: 25px;
    margin-bottom: 30px;
}

/* Style the NEW collapsible content area */
.partner-form-content {
    max-height: 800px; /* Adjust as needed, should be larger than expected content */
    opacity: 1;
    transition: max-height 0.4s ease-in-out, opacity 0.3s ease-in-out 0.1s, margin-top 0.4s ease-in-out, padding-top 0.4s ease-in-out, padding-bottom 0.4s ease-in-out;
    margin-top: 20px; /* Space below H3/confirmation */
    padding-top: 0; /* Adjust if needed */
    padding-bottom: 0; /* Adjust if needed */
}

/* Style the state when the content is collapsed AFTER confirmation */
.partner-form-content.collapsed {
    max-height: 0;
    opacity: 0;
    margin-top: 0;
    padding-top: 0;
    padding-bottom: 0;
    /* Prevent interaction with hidden elements */
    pointer-events: none;
}

/* Style the NEW confirmation message area */
.partner-confirmation-message {
    background-color: #e6f9f0; /* Light green background */
    border-left: 4px solid var(--primary);
    padding: 10px 15px;
    border-radius: 4px;
    margin-top: 15px; /* Space below H3 */
    display: none; /* Hidden by default */
}

/* Use Flexbox for layout within the confirmation message */
.partner-confirmation-message .confirmation-content {
    display: flex;
    align-items: center;
    justify-content: space-between; /* Pushes text left, button right */
}

.partner-confirmation-message p {
    margin: 0;
    color: var(--primary-darker); /* Darker green text */
    font-family: 'Balto-Medium';
    font-size: 15px;
    display: flex;
    align-items: center;
    flex-grow: 1; /* Allow text to take available space */
    margin-right: 15px; /* Add space between text and button */
}

.partner-confirmation-message i.fa-check-circle { /* Target only the check icon */
    margin-right: 8px;
    color: var(--primary); /* Green check icon */
    font-size: 1.1em;
    flex-shrink: 0; /* Prevent icon from shrinking */
}

/* Style for the edit button */
.edit-partner-button {
    /* btn-sm handles padding/font-size */
    /* Prevent button from shrinking */
}
/* Adjust icon margin specifically for the small edit button if needed */
.edit-partner-button i {
    margin-right: 4px;
}

.signup-card h3,
.partner-form h3 { /*Keep specific*/
    font-family: 'Balto-Medium';
    font-size: 24px;
    margin-bottom: 20px;
    color: var(--dark);
    padding-bottom: 10px;
    border-bottom: 2px solid var(--primary);
}

.signup-description,
.payment-description {
    margin-bottom: 20px;
    line-height: 1.6;
    color: #333;
}

.category-option {  /*This class is used on multiple pages, keep specific*/
    display: flex;
    position: relative;
    flex-direction: column;
    justify-content: space-between;
    padding: 0.6rem 0.75rem;
    background: #f8f9fa;
    align-items: center;
    border-radius: 6px;
    border-left: 4px solid var(--primary);
    transition: all 0.2s ease;
    margin-bottom: 10px;
    cursor: pointer;
}

.category-option:hover {
    background: #f0f0f0;
}

.category-selected-partner {
    display: flex;
    flex-direction: row;
    align-items: center;
}

.partner-display {
    display: flex;
    flex-direction: row;
    align-items: center;
}


.category-checkbox {
    width: 20px;
    height: 20px;
    cursor: pointer;
}

.category-radio {
    margin:20px;
    padding: 15px;
    margin-left: 20px;
    margin-right: 20px;
    width: 20px;
    height: 20px;
    cursor: pointer;
}

.category-details {
    display: flex;
    align-items: center;
    padding: 15px;
    width: 100%;
}

.category-details h4 {
    margin: 0;
    font-family: 'Balto-Medium';
    font-size: 16px;
    text-wrap: wrap;
    padding-right: 15px;
}

.partner-input-group {
    display: flex; /* Use flexbox to align input and button */
    align-items: center; /* Vertically align items */
}

.partner-search-input {
    flex-grow: 1; /* Allow input to grow and take available space */
}

.signed-up-indicator {
    margin-left: 5px; /* Add some spacing between the player ID and the indicator */
    color: var(--primary);      /* Make the indicator green to visually represent "signed up" */
    font-size: 0.9em; /* Slightly smaller font size for the indicator */
}

.signed-up-indicator i {
    margin-right: 3px; /* Space between icon and text */
}


/* Form Actions */
.form-actions {
    display: flex;
    justify-content: space-between;
    margin-top: 20px;
}

.autocomplete-dropdown {
    position: absolute; /* Position it relative to the nearest positioned ancestor */
    top: 100%;        /* Position it below the input */
    left: 0;
    right: 0;
    z-index: 1000;     /* Ensure it's above other elements */
    background-color: #fff;
    border: 1px solid #ced4da;
    border-top: none; /* Remove top border to visually connect to input */
    border-radius: 0 0 0.25rem 0.25rem; /* Rounded bottom corners */
    box-shadow: 0 0.5rem 1rem rgba(0, 0, 0, 0.15); /* Optional shadow */
    display: block;      /* Initially hidden */
}

.autocomplete-list {
    list-style: none;
    padding: 0;
    margin: 0;
}

.autocomplete-list li {
    padding: 0.5rem 1rem;
    cursor: pointer;
    white-space: nowrap;      /* Prevent text from wrapping to the next line */
    overflow: hidden;         /* Hide overflowing text */
    text-overflow: ellipsis; /* Show ellipsis (...) for truncated text */
    max-width: 100%; 
}

.autocomplete-list li:hover {
    background-color: #f8f9fa; /* Light gray on hover */
}

.autocomplete-list li.selected { /* Class for highlighting selected item (optional) */
    background-color: #007bff; /* Example primary blue */
    color: white;
}



/* Loading Spinner */
.loading-container {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 30px 0;
}

.spinner {
    border: 4px solid rgba(0, 0, 0, 0.1);
    border-radius: 50%;
    border-top: 4px solid var(--primary);
    width: 30px;
    height: 30px;
    animation: spin 2s linear infinite;
    margin-bottom: 15px;
}

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

    100% {
        transform: rotate(360deg);
    }
}

/* Success Message */
#success-message {
    text-align: center;
}

.success-icon {
    color: var(--primary);
    font-size: 60px;
    margin-bottom: 20px;
}

#success-title {
    color: var(--primary);
    margin-bottom: 15px;
}

/* Payment Element Container */
.payment-element-container {
    margin-bottom: 25px;
}

/* Payment Message */
.payment-message {
    background-color: #f8d7da;
    color: #721c24;
    padding: 10px;
    border-radius: 4px;
    margin-top: 15px;
    text-align: center;
}

.hidden {
    display: none;
}



/* Responsive Adjustments */
@media screen and (max-width: 600px) {
    /*Header already done*/

    .signup-content {
        width: 90%;
    }

    .category-selected-partner {
        flex-direction: column;
    }

    .categories-grid { /*Change to single column*/
        grid-template-columns: 1fr;
    }

    .form-actions {
        flex-direction: column;
        gap: 15px;
    }

     .btn { /*Fill width*/
        width: 100%;
    }

}



/* Match Details Page Styles */
.match-details-section {
    background: var(--light);
    padding-bottom: 50px;
}

.match-header { /*Keep specifics, this class used multiple times*/
    background: var(--dark);
    color: white;
    padding: 40px 50px;
    text-align: center;
    margin-top: 20px;
    margin-bottom: 40px;
    position: relative;
}

.match-header h1 {  /*Keep specifics, this class used multiple times*/
    font-family: 'Balto-Bold';
    font-size: 42px;
    margin-bottom: 10px;
}

.match-id {   /*Keep specifics, this class used multiple times*/
    font-family: 'Balto-Medium';
    font-size: 18px;
    color: var(--secondary);
}

.match-content {   /*Keep specifics, this class used multiple times*/
    width: 80%;
    margin: 0 auto;
}

.match-info-card {  /*Keep specifics, this class used multiple times*/
    background: white;
    border-radius: 8px;
    padding: 30px;
    margin-bottom: 30px;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
}

/* Teams Display */
.teams-display {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 30px;
    padding-bottom: 30px;
    border-bottom: 1px solid #eee;
}

.team {
    flex: 1;
    text-align: center;
}

.team-label {
    font-family: 'Balto-Bold';
    color: var(--dark);
    font-size: 18px;
    margin-bottom: 10px;
}

.team-names {
    font-size: 16px;
    line-height: 1.4;
}

.vs-container {
    padding: 0 20px;
}

.vs-circle {
    width: 50px;
    height: 50px;
    background-color: var(--primary);
    color: white;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-family: 'Balto-Bold';
    font-size: 16px;
}

/* Match Details Grid */
.match-details-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    gap: 20px;
    margin-top: 20px;
}

.detail-item {
    padding: 15px;
    background: #f8f9fa;
    border-radius: 6px;
    border-left: 4px solid var(--primary);
}

.detail-label {
    font-family: 'Balto-Medium';
    font-size: 16px;
    color: var(--dark);
    margin-bottom: 8px;
    display: flex;
    align-items: center;
}

.detail-label i {
    color: var(--primary);
    margin-right: 8px;
}

.detail-value {
    font-size: 16px;
}

/* Action Buttons */
.match-actions {  /*Keep specific*/
    display: flex;
    gap: 15px;
}



/* Responsive Adjustments */
@media screen and (max-width: 900px) {
  /*Match header and content already done*/

    .teams-display {
        flex-direction: column;
        gap: 20px;
    }

    .vs-container {
        padding: 10px 0;
    }

    .match-details-grid {
        grid-template-columns: 1fr;
    }

    .match-actions {  /*Match actions*/
        flex-direction: column;
    }

     /*Buttons already styled globally for this media query*/
}



/* Match Result Page Styles */
.match-result-section {
    background: var(--light);
    padding-bottom: 50px;
}

/*Reuse .match-header, .match-id and .match-content*/

/*Reuse .match-info-card*/

/*Reuse team display, .vs-container and .vs-circle */


/* Winner Display */
.winner-display {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    margin-bottom: 30px;
    padding-bottom: 30px;
    border-bottom: 1px solid #eee;
}

.winner-label {
    font-family: 'Balto-Bold';
    color: var(--dark);
    font-size: 20px;
    margin-bottom: 10px;
    display: flex;
    align-items: center;
}

.winner-label i {
    color: gold;
    margin-right: 10px;
    font-size: 24px;
}

.winner-value {
    font-family: 'Balto-Medium';
    font-size: 18px;
    color: var(--primary);
}

/* Games Results */
.games-results {
    margin-bottom: 30px;
    padding-bottom: 30px;
    border-bottom: 1px solid #eee;
}

.games-results h3 { /*Keep Specific*/
    font-family: 'Balto-Medium';
    font-size: 22px;
    margin-bottom: 20px;
    color: var(--dark);
}

.games-grid {
    display: grid;
     grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); /*Smaller min size*/
    gap: 15px;
}

.game-item {
    padding: 15px;
    background: #f8f9fa;
    border-radius: 6px;
    text-align: center;
    border-top: 4px solid var(--primary);
}

.game-label {
    font-family: 'Balto-Medium';
    font-size: 16px;
    color: var(--dark);
    margin-bottom: 10px;
}

.game-score {
    font-family: 'Balto-Bold';
    font-size: 20px;
}

/*Reuse match-details-grid and .detail-item and detail label*/

.detail-value.confirmed {  /*Keep Specific*/
    color: var(--primary);
    font-family: 'Balto-Medium';
}

/*Reuse .match-actions and responsive*/
/*Reuse .btn and variations and responsive styles*/



/* Responsive Adjustments */
@media screen and (max-width: 900px) {
 /*Match header and content, teams display and match actions already done*/

     .games-grid {
        grid-template-columns: repeat(auto-fill, minmax(120px, 1fr));  /*Smaller min*/
    }
        /*Match detail grids already done*/

}

/* --- General Typography and Spacing for Smaller Screens --- */
@media screen and (max-width: 991.98px) { /* Bootstrap's 'lg' breakpoint and below */
    h1, .event-header h1, .match-header h1 { /* Target main headings */
        font-size: 2.25rem; /* Slightly smaller */
    }
    h2, .schedule-header h1 { /* Target secondary headings and schedule header */
        font-size: 1.75rem;
        margin-bottom: 20px;
    }
    h3, .info-card h3, .event-description h3, .categories-section h3, .signup-card h3, .partner-form h3, .games-results h3, .participant-list-section h3 {
        font-size: 1.5rem; /* Smaller for card/section titles */
        margin-bottom: 15px;
    }
    p, .info-card li, .description-content, .detail-value, .team-names, .winner-value {
        font-size: 1rem; /* Bootstrap default is 1rem (16px), adjust if needed */
        line-height: 1.6;
    }
    section > div { /* Main content containers within sections */
        width: 90%; /* More width on smaller screens */
        padding: 20px 0 30px 0;
    }
    .signup-content, .match-content, .event-content { /* Specific content wrappers */
        width: 95%;
    }
    .back-link {
        width: 95%;
    }
}

@media screen and (max-width: 767.98px) { /* Bootstrap's 'md' breakpoint and below */
    h1, .event-header h1, .match-header h1 {
        font-size: 2rem;
    }
    h2, .schedule-header h1 {
        font-size: 1.6rem;
    }
    h3, .info-card h3, .event-description h3, .categories-section h3, .signup-card h3, .partner-form h3, .games-results h3, .participant-list-section h3 {
        font-size: 1.35rem;
    }
    p, .info-card li, .description-content, .detail-value, .team-names, .winner-value {
        font-size: 0.95rem; /* Slightly smaller on phones */
    }
    .btn { /* Make all buttons a bit smaller on mobile */
        padding: 8px 16px;
        font-size: 14px;
    }
    .form-actions { /* Stack form action buttons */
        flex-direction: column;
        gap: 10px; /* Space between stacked buttons */
    }
    .form-actions { /* Make stacked buttons full width */
        width: 100%;
    }
    .match-actions { /* Stack match action buttons */
        flex-direction: column;
    }
     .match-actions {
        width: 100%;
    }
}

@media screen and (max-width: 575.98px) { /* Bootstrap's 'sm' breakpoint and below (very small screens) */
    h1, .event-header h1, .match-header h1 {
        font-size: 1.75rem;
    }
    h2, .schedule-header h1 {
        font-size: 1.4rem;
    }
    h3, .info-card h3, .event-description h3, .categories-section h3, .signup-card h3, .partner-form h3, .games-results h3, .participant-list-section h3 {
        font-size: 1.2rem;
    }
    section > div, .signup-content, .match-content, .event-content, .back-link {
        width: 95%; /* Almost full width */
        padding-left: 15px; /* Reduce side padding slightly */
        padding-right: 15px;
    }
}


/* --- Header & Navigation Specifics --- */
@media screen and (max-width: 900px) { /* Your existing breakpoint for nav toggle */
    header {
        padding: 20px 25px; /* Reduce header padding */
        flex-wrap: wrap; /* Allow logo and nav toggle to wrap if needed */
    }
    .header-logo img {
        width: 200px; /* Smaller logo */
    }
    .header-nav a.icon { /* Ensure icon is well-positioned and tappable */
        top: 22px;      /* Adjust based on new header padding */
        right: 20px;
        font-size: 30px; /* Ensure good tap size */
    }
    .header-nav.responsive ul { /* Full-width mobile menu */
        width: 100%;
        padding: 70px 25px 25px 25px; /* Top padding to clear header */
        border-bottom-left-radius: 0; /* Full width, no radius needed */
        box-shadow: 0px 5px 10px rgba(0,0,0,0.2); /* Add shadow for depth */
        height: 100vh; /* Full viewport height */
        overflow-y: auto; /* Allow scrolling if many items */
    }
    .header-nav.responsive a {
        display: block; /* Ensure links take full width */
        padding: 12px 0; /* Good tappable area */
        text-align: left; /* Align text to left */
        font-size: 18px; /* Slightly smaller font for mobile menu */
        border-bottom: 1px solid rgba(255, 255, 255, 0.08);
    }
    .header-nav.responsive a:last-child {
        border-bottom: none;
    }
    .header-nav.responsive a:hover li {
        border-bottom-color: transparent; /* Remove underline hover for stacked items */
    }
    .header-nav.responsive .active li {
        border-bottom-color: transparent; /* Remove underline for active in mobile menu */
    }
    .header-nav.responsive .active {
        color: var(--primary-brighter); /* Ensure active link color persists */
        background-color: rgba(255, 255, 255, 0.05); /* Slight highlight for active item */
        border-radius: 4px;
    }
}

/* --- Event Details Page Specifics --- */
@media screen and (max-width: 767.98px) { /* Below md */
    .event-info {
        flex-direction: column; /* Stack info cards */
        gap: 20px; /* Reduce gap for stacked items */
    }
    .info-card {
        margin-bottom: 0; /* Remove bottom margin if it's the last one in flex column */
    }
    .categories-grid {
        grid-template-columns: 1fr; /* Single column for category cards */
    }
    .action-buttons, .admin-buttons {
        flex-direction: column; /* Stack action buttons */
        gap: 10px;
    }
    .action-buttons .btn, .admin-buttons .btn {
        width: 100%; /* Make buttons full width when stacked */
    }
}

/* --- Signup Page Specifics --- */
@media screen and (max-width: 767.98px) {
    .category-radio {
        position: static; /* Remove absolute positioning */
        margin-left: 0; /* Align with text */
    }
    .partner-search-input .form-control {
        font-size: 0.9rem; /* Slightly smaller search input */
    }
}

/* --- Match Details & Result Page Specifics --- */
@media screen and (max-width: 767.98px) {
    .teams-display {
        flex-direction: column; /* Stack teams */
        gap: 15px;
    }
    .vs-container {
        padding: 15px 0;
    }
    .match-details-grid {
        grid-template-columns: 1fr; /* Single column for details */
    }
    .games-grid {
        grid-template-columns: repeat(auto-fill, minmax(120px, 1fr));
    }
}

/* --- Schedule/Matches Table Specifics --- */
@media screen and (max-width: 767.98px) {
    .matches-table-container {
        padding: 15px; /* Reduce padding on smaller screens */
    }
    .matches-table th, .matches-table td {
        padding: 8px 10px; /* Reduce cell padding */
        font-size: 13px;   /* Smaller font for table content */
    }
    .matches-table th:nth-child(3), /* Category */
    .matches-table td:nth-child(3),
    .matches-table th:nth-child(8), /* Match ID */
    .matches-table td:nth-child(8) {
        /* Optionally hide less critical columns on very small screens */
        /* display: none; */
    }
}

/* static/stylesheets/style_new.css */

/* --- Event Details Page Specific Styles --- */
.event-details-page .event-content { /* Specific targeting for event details content */
    width: 85%; /* Slightly wider on desktop than general sections */
}

@media (max-width: 991.98px) {
    .event-details-page .event-content {
        width: 90%;
    }
}
@media (max-width: 767.98px) {
    .event-details-page .event-content {
        width: 95%;
    }
}


/* Event Info Cards Row - (using Bootstrap grid, so minimal custom CSS needed here) */
.event-info-row {
    margin-bottom: 2rem; /* Consistent bottom margin */
}
.info-card { /* Style from your view_category_participants for consistency */
    background: white;
    border-radius: 0.5rem; /* Slightly larger radius */
    padding: 1.5rem; /* More padding */
    box-shadow: 0 0.25rem 0.75rem rgba(0, 0, 0, 0.08); /* Softer shadow */
    display: flex; /* For h-100 to work well if content varies */
    flex-direction: column;
}
.info-card h3 {
    font-size: 1.5rem; /* Adjust if needed */
    margin-bottom: 1.25rem;
}
.info-card ul li i { /* Ensure icons are aligned nicely */
    font-size: 1.1em; /* Make icons slightly larger */
    width: 24px;      /* Give icons fixed width for alignment */
}

.registration-status p { /* Spacing for registration close date */
    font-size: 0.9rem;
    color: #495057;
}
.registration-status .btn {
    font-size: 1rem; /* Make signup button slightly larger */
}


/* Event Description - Make it a card */
.event-description-card {
    background: white;
    border-radius: 0.5rem;
    padding: 1.5rem;
    margin-bottom: 2rem;
    box-shadow: 0 0.25rem 0.75rem rgba(0, 0, 0, 0.08);
}
.event-description-card h3 {
    font-size: 1.5rem;
    margin-bottom: 1rem;
}


/* Categories Section */
.categories-section {
    background: none; /* Remove card-like background if each category is a card */
    padding: 0;
    margin-bottom: 2rem;
    box-shadow: none;
}
.categories-section h3 { /* Center the "Event Categories" title */
    text-align: center;
    font-size: 1.75rem;
    border-bottom: none; /* Remove border if categories are cards */
    margin-bottom: 1.5rem;
}

.categories-grid {
    display: grid;
    /* Using Bootstrap's responsive grid column classes via HTML is often easier */
    /* Fallback grid CSS: */
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); /* Default for larger screens */
    gap: 1.5rem; /* Spacing between cards */
}

/* NEW Styling for Individual Category Cards */
.category-card-wrapper { /* For outer spacing if needed */
    display: flex; /* For h-100 to work on link */
}
.category-card-link {
    display: flex; /* Make the link a flex container */
    flex-direction: column;
    background-color: #fff;
    border: 1px solid #e0e0e0;
    border-radius: 0.5rem;
    text-decoration: none;
    color: inherit;
    transition: transform 0.2s ease-out, box-shadow 0.2s ease-out;
    width: 100%; /* Ensure link takes full width of its grid cell */
    overflow: hidden; /* Ensure content respects border-radius */
    box-shadow: 0 0.125rem 0.25rem rgba(0,0,0,.075);
}
.category-card-link:hover {
    transform: translateY(-4px);
    box-shadow: 0 0.5rem 1rem rgba(0,0,0,0.12);
    color: inherit; /* Keep text color on hover */
}
.category-card-content {
    padding: 1.25rem;
    flex-grow: 1; /* Allows this content to take available space */
    display: flex;
    flex-direction: column;
}
.category-card-content .category-title {
    font-family: 'Balto-Medium', Arial, sans-serif;
    font-size: 1.1rem;
    color: var(--dark, #343a40);
    margin-bottom: 0.5rem;
}
.category-card-content .category-teams,
.category-card-content .category-fee-display {
    font-family: 'Balto-Book', Arial, sans-serif;
    font-size: 0.9rem;
    color: #495057;
}
.category-card-content .category-fee-display {
    margin-top: 0.25rem;
}
.category-card-content .view-participants-link {
    font-family: 'Balto-Medium', Arial, sans-serif;
    color: var(--primary, #007bff);
    font-size: 0.85rem;
    margin-top: auto; /* Pushes this link to the bottom of the card content */
    padding-top: 0.75rem; /* Space above it */
    align-self: flex-start; /* Keep it left-aligned */
}
.category-card-content .view-participants-link:hover {
    text-decoration: underline;
}


/* Event Actions - Stack buttons on mobile */
.event-actions { /* Remove card styling if it was there */
    padding: 0;
    margin-bottom: 2rem;
    border-radius: 0;
    box-shadow: none;
    background: none;
}
.event-actions h3 {
    text-align: center;
}
.action-buttons, .admin-buttons {
    justify-content: center; /* Center buttons */
}

@media (max-width: 767.98px) {
    .categories-grid {
        grid-template-columns: 1fr; /* Single column on mobile */
        gap: 1rem;
    }
    .category-card-link {
        padding: 1rem; /* Slightly less padding on mobile cards */
    }
    .action-buttons, .admin-buttons {
        flex-direction: column;
        gap: 0.75rem; /* Space between stacked buttons */
    }
    .action-buttons .btn, .admin-buttons .btn {
        width: 100%; /* Full width buttons */
    }
}

.back-link-container { /* Container for the back link */
    margin-top: 2rem;
    /* text-align will be handled by Bootstrap classes (text-center, text-md-start) */
}
.back-link-container .btn {
    font-family: 'Balto-Medium', Arial, sans-serif;
}

.cookie-consent-banner {
    position: fixed;
    bottom: 0;
    left: 0;
    width: 100%;
    background-color: var(--dark, #343a40); /* Dark background */
    color: var(--light, #f8f9fa);          /* Light text */
    padding: 15px 20px;
    box-shadow: 0 -2px 10px rgba(0,0,0,0.2);
    z-index: 1050; /* High z-index to be on top */
    display: flex;
    flex-wrap: wrap; /* Allow content and actions to wrap on small screens */
    justify-content: space-between;
    align-items: center;
    font-size: 0.9rem;
}

.cookie-consent-content {
    flex-grow: 1;
    margin-right: 20px; /* Space between text and buttons */
}

.cookie-consent-content p {
    margin-bottom: 0.5rem;
    line-height: 1.5;
    font-size: 0.85rem; /* Slightly smaller text for the banner */
    color: #e9ecef; /* Lighter text on dark background */
}
.cookie-consent-content p:last-child {
    margin-bottom: 0;
}

.cookie-consent-content a {
    color: var(--primary-brighter, #13ca81); /* Your link color */
    text-decoration: underline;
}
.cookie-consent-content a:hover {
    color: #fff;
}

.cookie-consent-actions {
    display: flex;
    gap: 10px; /* Space between buttons */
    flex-shrink: 0; /* Prevent buttons from shrinking too much */
}

.cookie-consent-actions .btn {
    font-size: 0.8rem; /* Smaller buttons */
    padding: 0.3rem 0.75rem;
}
.cookie-consent-actions .btn-primary { /* Assuming your existing .btn-primary is suitable */
    /* background-color: var(--primary); color: white; */
}
.cookie-consent-actions .btn-outline-secondary {
    color: #ccc;
    border-color: #ccc;
}
.cookie-consent-actions .btn-outline-secondary:hover {
    color: #fff;
    background-color: #5a6268;
    border-color: #545b62;
}


@media (max-width: 767px) {
    .cookie-consent-banner {
        flex-direction: column;
        text-align: center;
    }
    .cookie-consent-content {
        margin-right: 0;
        margin-bottom: 15px;
    }
    .cookie-consent-actions {
        width: 100%;
        justify-content: center;
    }
}