:root {
            --primary-color: #13294B;
            --secondary-color: #e30b5c;
            --accent-color: #6a9ebc;
            --light-accent: #d1e8f5;
            --dark-accent: #2c3e50;
            --light-color: #f7f9fc;
            --text-color: #333;
            --light-gray: #f1f1f1;
            --medium-gray: #ddd;
            --dark-gray: #888;
            
            --font-title-main: 'Playfair Display', serif; 
            --font-title-number: 'Playfair Display', serif; 
            --font-date-location: 'Open Sans', sans-serif; 

            --font-heading: 'Playfair Display', serif; 
            --font-body: 'Roboto', sans-serif;    

            --shadow-sm: 0 2px 5px rgba(0,0,0,0.1);
            --shadow-md: 0 4px 8px rgba(0,0,0,0.12);
            --shadow-lg: 0 10px 20px rgba(0,0,0,0.15);
            --border-radius: 8px;
            --transition-speed: 0.3s;
            --rapid-color: #4a6741;
            --blitz-color: #674141;
            --deposit-fee-color: #007bff; /* Blue for deposit */
        }

        * {
            margin: 0;
            padding: 0;
            box-sizing: border-box;
        }

        body {
            font-family: var(--font-body);
            line-height: 1.7;
            color: var(--text-color);
            background-color: var(--light-color);
            font-variant-ligatures: none;
        }

        .container {
            width: 90%;
            max-width: 1200px;
            margin: 0 auto;
            padding: 20px;
        }

        header {
            background: linear-gradient(135deg, var(--primary-color) 0%, #101c30 100%);
            color: white;
            padding: 20px 0 10px; 
            box-shadow: var(--shadow-md);
            position: relative;
            overflow: hidden; 
            z-index: 3; 
        }

        .header-content {
            display: flex;
            flex-direction: column; /* Main items stacked vertically */
            align-items: center;
            position: relative;
            z-index: 1;
            gap: 15px; 
        }
        
        .header-top-row {
            display: flex;
            justify-content: space-between; /* Pushes title block and date/location apart */
            align-items: center; /* Vertically aligns items in this row */
            width: 100%;
            gap: 20px; /* Gap between title block, logo, and date/location */
            flex-wrap: wrap; /* Allow wrapping for responsiveness */
        }


        .festival-main-title-group {
            display: flex;
            align-items: flex-end; /* Align baseline of "1" and "Maasch & Kirsch" */
            gap: 8px; 
        }

        .festival-number {
            font-family: var(--font-title-number);
            font-weight: 900; 
            font-size: 6.5rem; /* Larger number */
            line-height: 0.85; /* Crucial for vertical alignment with two lines of text */
            color: white;
            text-shadow: 2px 2px 4px rgba(0,0,0,0.3);
            margin-right: 5px; /* Space before text */
        }
        .festival-number sup {
            font-size: 0.4em; /* Smaller superscript */
            font-weight: 700;
            vertical-align: super;
            margin-left: -0.1em; /* Fine-tune spacing */
        }


        .festival-name-brand-group {
            display: flex;
            flex-direction: column;
            text-align: left;
        }

        .festival-brand {
            font-family: var(--font-title-main);
            font-weight: 700;
            font-size: 3rem; 
            letter-spacing: 1px;
            color: white;
            text-shadow: 2px 2px 4px rgba(0,0,0,0.2);
            line-height: 1.0;
            font-feature-settings: "liga" 0, "clig" 0, "dlig" 0, "calt" 0, "salt" 0, "ss01" 0, "ss02" 0;
        }

        /* Force standard ampersand glyph when using Playfair Display */
        h1, h2, h3, h4, h5, h6, .festival-event-type {
            font-feature-settings: "liga" 0, "clig" 0, "dlig" 0, "calt" 0, "salt" 0, "ss01" 0, "ss02" 0;
        }

        .ampersand-fallback {
            font-family: var(--font-body);
            font-weight: inherit;
            letter-spacing: normal;
        }

        .festival-event-type {
            font-family: var(--font-title-main);
            font-weight: 700; 
            font-size: 2.4rem; 
            letter-spacing: 1px;
            color: rgba(255, 255, 255, 0.95);
            text-shadow: 1px 1px 3px rgba(0,0,0,0.2);
            line-height: 1.0;
            margin-top: -5px; /* Pull up slightly */
        }
        

        .festival-date-location-group {
            display: flex;
            flex-direction: column;
            text-align: right; /* Align to the right */
            padding-left: 10px; 
            justify-content: center; 
            margin-left: auto; /* Pushes it to the right if space allows */
        }

        .festival-date {
            font-family: var(--font-date-location);
            font-size: 2rem; 
            font-weight: 700; 
            letter-spacing: 0.5px;
            color: var(--secondary-color); 
            text-shadow: 1px 1px 2px rgba(0,0,0,0.3);
            line-height: 1.1;
        }

        .festival-location {
            font-family: var(--font-date-location);
            font-size: 1.8rem; 
            font-weight: 600;
            color: var(--secondary-color); 
            text-shadow: 1px 1px 2px rgba(0,0,0,0.2);
            line-height: 1.1;
        }


        .festival-subtitle-container {
             width: 100%; 
             text-align: center;
             position: relative; 
             z-index: 4; 
             margin-top: 5px; /* Reduced from 10px */
             margin-bottom: -30px; 
        }
        .festival-subtitle {
            font-family: var(--font-heading); 
            font-size: 2.0rem; 
            font-weight: 700;
            color: white; 
            text-shadow: 2px 2px 5px rgba(0, 0, 0, 0.7); 
            padding: 10px 20px; 
            display: inline-block;
            font-style: italic; 
        }
        @media screen and (max-width: 992px) { /* Adjust breakpoint for stacking */
            .header-top-row {
                flex-direction: column; /* Stack title, logo, date */
                align-items: center;
                gap: 15px;
            }
            .festival-main-title-group, .festival-name-brand-group, .festival-date-location-group {
                 text-align: center; /* Center all text when stacked */
                 padding-left: 0;
            }
            .festival-date-location-group { margin-left: 0; }
            .festival-number { font-size: 5rem; }
            .festival-brand { font-size: 2.5rem; }
            .festival-event-type { font-size: 2rem; }
            .festival-date { font-size: 1.7rem; }
            .festival-location { font-size: 1.5rem; }
        }

         @media screen and (max-width: 480px) {
            .festival-number { font-size: 4rem; }
            .festival-brand { font-size: 2rem; }
            .festival-event-type { font-size: 1.6rem; }
            .festival-date { font-size: 1.4rem; }
            .festival-location { font-size: 1.2rem; }
            .festival-subtitle { font-size: 1.3rem; margin-bottom: -15px;}
         }

        .hero-banner {
            width: 100%;
            display: block;
            max-height: 500px;
            object-fit: cover;
            box-shadow: var(--shadow-md);
            margin-top: 0; 
            position: relative; 
            z-index: 1; 
        }

        h1 { 
            font-family: var(--font-heading);
            font-weight: 700;
            letter-spacing: 1px;
            text-shadow: 2px 2px 4px rgba(0,0,0,0.3);
            font-size: 2.5rem;
            margin: 0;
        }

        h2 {
            font-family: var(--font-heading);
            color: var(--primary-color);
            margin-bottom: 1rem;
            position: relative;
            padding-bottom: 0.5rem;
        }

        #information h2#info-headline { 
            font-family: var(--font-body);
            font-weight: 700; 
        }

        h2::after {
            content: "";
            position: absolute;
            bottom: 0;
            left: 0;
            width: 70px;
            height: 3px;
            background: var(--secondary-color);
        }

        h3 {
            font-family: var(--font-heading);
            color: var(--dark-accent);
            margin: 1.5rem 0 0.5rem;
        }

        p {
            margin-bottom: 1rem;
        }
        .info-card p, .info-card ul {
            margin-bottom: 0.5rem; 
        }
        .info-card ul {
            list-style-position: inside;
            list-style-type: disc; 
            padding-left: 0;
        }
        .info-card ul li { 
            list-style-type: disc;
            margin-bottom: 0.25rem;
        }


        .main-content {
            background-color: white;
            border-radius: var(--border-radius);
            box-shadow: var(--shadow-md);
            margin-top: -20px;
            position: relative;
            z-index: 2; 
        }

        .tabs {
            overflow: visible;
            display: flex;
            flex-wrap: wrap;
            position: sticky;
            top: 0;
            z-index: 10;
            background-color: var(--secondary-color);
            border-top-left-radius: var(--border-radius);
            border-top-right-radius: var(--border-radius);
        }

        .tab-button {
            background-color: var(--secondary-color);
            border: none;
            outline: none;
            cursor: pointer;
            padding: 16px;
            transition: all var(--transition-speed);
            font-size: 16px;
            font-weight: 600;
            color: white;
            flex-grow: 1; 
            text-align: center;
            position: relative;
            font-family: var(--font-body);
            border-radius: 0;
            flex-basis: 0; 
        }
        .tournament-dropdown-container {
             position: relative;
             flex-grow: 1; 
             flex-basis: 0; 
             display: flex; 
        }
        .tournament-dropdown-container .tab-button {
             width: 100%; 
        }


        .tab-button:hover {
            background-color: #c60b4e;
        }

        .tab-button.active {
            background-color: #a10940;
        }

        .tab-button:first-child {
            border-top-left-radius: var(--border-radius);
        }

        .tournament-dropdown {
            position: absolute;
            z-index: 100;
            top: 100%;
            left: 0;
            width: 230px;
            display: none;
            background-color: var(--secondary-color);
            box-shadow: var(--shadow-md);
            border-bottom-left-radius: var(--border-radius);
            border-bottom-right-radius: var(--border-radius);
        }

        .tournament-dropdown-trigger.active + .tournament-dropdown {
            display: block;
        }

        .dropdown-item {
            padding: 14px 16px;
            display: block;
            color: white;
            text-decoration: none;
            text-align: left;
            transition: all 0.2s;
            font-weight: 600;
            font-family: var(--font-body);
        }

        .dropdown-item:hover {
            background-color: #c60b4e;
        }

        .dropdown-item.active {
            background-color: #a10940;
        }

        .tab-content {
            display: none;
            padding: 30px;
            border-top: none;
            background-color: white;
            min-height: 500px;
            animation: fadeIn 0.5s;
        }

        @keyframes fadeIn {
            from { opacity: 0; transform: translateY(10px); }
            to { opacity: 1; transform: translateY(0); }
        }

        .blog-posts {
            display: grid;
            gap: 25px;
        }

        .blog-post {
            background-color: white;
            padding: 25px;
            border-radius: var(--border-radius);
            box-shadow: var(--shadow-sm);
            transition: transform var(--transition-speed), box-shadow var(--transition-speed);
            border-left: 4px solid var(--accent-color);
        }

        .blog-post:hover {
            transform: translateY(-5px);
            box-shadow: var(--shadow-md);
        }

        .blog-post h3 {
            margin-top: 0;
            color: var(--primary-color);
        }

        .blog-post .date {
            color: var(--dark-gray);
            font-style: italic;
            margin-bottom: 10px;
            font-size: 0.9rem;
        }

        .form-group {
            margin-bottom: 20px;
        }
        .player-contact-fields-wrapper { 
            display: flex;
            gap: 15px;
            flex-wrap: wrap; 
        }
        .player-contact-fields-wrapper .form-group {
            flex: 1; 
            min-width: 200px; 
            margin-bottom: 10px; 
        }

        .player-contact-info { 
             margin-top: 15px;
             padding-top: 15px;
             border-top: 1px solid var(--medium-gray);
        }
        .player-contact-note {
            font-size: 0.9em;
            color: var(--dark-gray);
            margin-top: 5px;
        }


        .player-search-container {
            display: flex;
            gap: 10px;
            align-items: flex-start; 
        }

        .player-search-input {
            flex-grow: 1;
        }

        .search-controls {
            display: flex;
            gap: 10px;
        }

        .registration-info-box {
            background-color: #ffffff;
            padding: 20px;
            border-radius: var(--border-radius);
            box-shadow: var(--shadow-sm);
            margin-bottom: 25px;
        }
        .registration-info-box h3 {
            color: var(--primary-color);
            margin-bottom: 10px;
        }
        .registration-info-box p {
            margin-bottom: 12px;
        }
        .registration-info-list {
            margin-left: 20px;
            color: var(--text-color);
        }
        .registration-info-list li {
            margin-bottom: 8px;
        }
        .registration-info-sublist {
            margin-top: 10px;
            margin-left: 20px;
        }
        #registration-instructions,
        #registration-contact-section {
            margin-bottom: 25px;
        }

        @media (max-width: 768px) {
            .player-search-container {
                flex-direction: column;
            }
            .search-controls {
                flex-direction: row; 
                width: 100%;
            }
             .manual-entry-btn {
                 flex-grow: 1; 
             }
        }


        label {
            display: block;
            margin-bottom: 8px;
            font-weight: 600;
            color: var(--dark-accent);
        }

        input[type="text"],
        input[type="email"],
        input[type="number"],
        input[type="tel"],
        select,
        textarea {
            width: 100%;
            padding: 12px;
            border: 1px solid var(--medium-gray);
            border-radius: var(--border-radius);
            font-family: var(--font-body);
            font-size: 1rem; /* Ensure consistent font size */
            transition: border-color var(--transition-speed), box-shadow var(--transition-speed);
            background-color: var(--light-color);
        }

        input[type="text"]:focus,
        input[type="email"]:focus,
        input[type="number"]:focus,
        input[type="tel"]:focus,
        select:focus,
        textarea:focus {
            outline: none;
            border-color: var(--accent-color);
            box-shadow: 0 0 0 3px rgba(106, 158, 188, 0.2);
        }

        button {
            background: linear-gradient(135deg, var(--secondary-color) 0%, #cd0950 100%);
            color: white;
            padding: 12px 24px;
            border: none;
            border-radius: var(--border-radius);
            cursor: pointer;
            font-size: 16px;
            font-weight: 600;
            transition: all var(--transition-speed);
            box-shadow: var(--shadow-sm);
            font-family: var(--font-body);
        }

        button:hover {
            background: linear-gradient(135deg, #cd0950 0%, var(--secondary-color) 100%);
            box-shadow: var(--shadow-md);
            transform: translateY(-2px);
        }

        .add-player-btn {
            padding: 12px;
            min-width: 120px;
            background-color: var(--accent-color);
        }

        .add-player-btn:hover {
            background-color: #5889a7;
        }

        .manual-entry-btn {
            padding: 12px;
            background-color: var(--dark-accent);
             white-space: nowrap; 
        }

        .manual-entry-btn:hover {
            background-color: #1a2a3a;
        }

        .manual-entry-form {
            display: none;
            background-color: var(--light-color);
            padding: 20px;
            margin-top: 20px;
            border-radius: var(--border-radius);
            border: 1px solid var(--medium-gray);
            animation: slideDown 0.4s;
        }

        .manual-entry-form h3 {
            margin-top: 0;
            padding-bottom: 10px;
            border-bottom: 1px solid var(--medium-gray);
            color: var(--primary-color);
        }

        .manual-form-controls {
            display: flex;
            gap: 15px;
            margin-top: 20px;
        }

        .manual-form-row {
            display: flex;
            flex-wrap: wrap;
            gap: 15px;
            margin-bottom: 15px;
        }

        .manual-form-field {
            flex: 1;
            min-width: 200px;
        }

        .autocomplete-container {
            position: relative;
        }

        .autocomplete-items {
            position: absolute;
            border: 1px solid var(--medium-gray);
            border-top: none;
            z-index: 99;
            top: 100%;
            left: 0;
            right: 0;
            max-height: 250px;
            overflow-y: auto;
            border-radius: 0 0 var(--border-radius) var(--border-radius);
            box-shadow: var(--shadow-md);
            background-color: white;
        }

        .autocomplete-items div {
            padding: 12px 15px;
            cursor: pointer;
            border-bottom: 1px solid #f5f5f5;
            transition: background-color var(--transition-speed);
        }

        .autocomplete-items div:hover {
            background-color: var(--light-accent);
        }

        .player-info-box {
            background-color: var(--light-color);
            border: 1px solid var(--medium-gray);
            border-radius: var(--border-radius);
            padding: 20px;
            margin-top: 20px;
            display: none;
            box-shadow: var(--shadow-sm);
            animation: slideDown 0.4s;
        }

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

        .player-info-box h3 {
            margin-top: 0;
            padding-bottom: 10px;
            border-bottom: 1px solid var(--medium-gray);
            color: var(--primary-color);
        }

        .player-info-grid {
            display: grid;
            grid-template-columns: repeat(4, 1fr); /* Four columns for top row */
            gap: 10px 20px; 
            margin: 15px 0;
        }
        .player-info-grid.middle-row {
            grid-template-columns: repeat(3, 1fr); /* Three columns for middle row */
        }
        .player-info-grid.bottom-row {
            grid-template-columns: repeat(4, 1fr); /* Four columns for bottom row */
        }


        .player-info-item {
            padding: 5px 0; 
            position: relative;
            display: flex; /* For label and value side-by-side */
            flex-direction: column; /* Stack label above value */
        }
        .player-info-label {
            font-weight: 600;
            color: var(--dark-accent);
            margin-bottom: 3px; /* Space between label and value */
            font-size: 0.9em; /* Slightly smaller label */
        }
        .player-info-item span:not(.player-info-label) { /* Value styling */
            font-size: 1rem; /* Restore default value font size */
        }


        .edit-club-btn {
            font-size: 12px;
            padding: 2px 8px;
            margin-left: 8px;
            background-color: var(--light-accent);
            color: var(--dark-accent);
            border: 1px solid var(--accent-color);
            opacity: 0.7;
        }

        .edit-club-btn:hover {
            opacity: 1;
            background-color: var(--accent-color);
            color: white;
            transform: none;
        }

        /* Styling for Open Selection */
        .open-selection {
            margin-top: 20px;
            padding: 20px;
            border: 1px solid var(--medium-gray);
            border-radius: var(--border-radius);
            background-color: #fff; /* Light background for the fieldset */
        }
        .open-selection legend {
            font-weight: 700; /* Bolder legend */
            color: var(--primary-color);
            margin-bottom: 15px; /* More space below legend */
            padding: 0 5px; /* Some padding for the legend text */
            font-size: 1.1em;
        }
        .open-selection-options {
            display: grid; /* Use grid for better alignment */
            grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); /* Responsive columns */
            gap: 15px; /* Gap between options */
        }
        .open-selection-options label {
            display: flex;
            align-items: center;
            padding: 10px; /* Padding inside each option box */
            border: 1px solid var(--light-gray);
            border-radius: var(--border-radius);
            cursor: pointer;
            transition: all 0.2s ease;
            background-color: var(--light-color);
        }
        .open-selection-options label:hover {
            background-color: var(--light-accent);
            border-color: var(--accent-color);
        }
        .open-selection-options input[type="radio"] {
             width: auto; 
             margin-right: 8px; /* More space after radio button */
             cursor: pointer;
             transform: scale(1.2); /* Slightly larger radio button */
        }
        .open-selection-options input[type="radio"]:checked + span {
            font-weight: 600;
            color: var(--primary-color);
        }
        .open-selection-options label.disabled-option { /* Style for disabled options */
            background-color: #f9f9f9;
            cursor: not-allowed;
            opacity: 0.7;
        }
        .open-selection-options input[type="radio"]:disabled + span {
             color: var(--dark-gray);
             text-decoration: none; /* Remove line-through, rely on general disabled style */
        }
         .open-selection-note {
             font-size: 0.85em; /* Slightly smaller note */
             color: var(--dark-gray);
             margin-left: 8px; /* Space before note */
             font-style: italic;
         }


        .selected-players {
            margin-top: 30px;
        }

        .selected-players h3 {
            margin-bottom: 15px;
        }

        .player-list {
            max-height: 400px;
            overflow-y: auto;
            border: 1px solid var(--medium-gray);
            border-radius: var(--border-radius);
        }

        .player-list-empty {
            padding: 20px;
            text-align: center;
            color: var(--dark-gray);
            font-style: italic;
        }

        .player-card {
            display: flex;
            justify-content: space-between;
            align-items: center;
            padding: 15px;
            border-bottom: 1px solid var(--medium-gray);
            background-color: white;
            transition: background-color var(--transition-speed);
        }

        .player-card:last-child {
            border-bottom: none;
        }

        .player-card:hover {
            background-color: var(--light-color);
        }

        .player-card-info {
            flex-grow: 1;
        }

        .player-card-name {
            font-weight: 600;
            color: var(--primary-color);
            font-size: 1.1em; /* Slightly larger name */
        }

        .player-card-details {
            color: var(--dark-gray);
            font-size: 0.85rem; /* Slightly smaller details */
            margin-top: 4px;
        }

        .player-fee {
            font-weight: 600;
            /* color set by JS based on deposit status */
            margin-right: 10px;
        }
        .player-fee.deposit {
            color: var(--deposit-fee-color); /* Specific color for deposit fees */
        }
        .player-fee.standard-fee {
            color: var(--secondary-color); /* Default fee color */
        }

        .deposit-refund-note {
            font-size: 0.8em;
            font-style: italic;
            color: var(--dark-gray);
            margin-left: 5px;
        }

        .imprint-details p {
            margin-bottom: 12px;
        }

        .remove-player-btn {
            background-color: transparent;
            color: var(--dark-gray);
            padding: 5px 10px;
            box-shadow: none;
            border: 1px solid var(--medium-gray);
            border-radius: 4px;
            font-size: 14px;
        }

        .remove-player-btn:hover {
            background-color: #f8d7da;
            color: #dc3545;
            border-color: #dc3545;
            transform: none;
            box-shadow: none;
        }

        #map, .tournament-embed {
            width: 100%;
            border: 1px solid var(--medium-gray);
            border-radius: var(--border-radius);
            overflow: hidden;
            box-shadow: var(--shadow-sm);
            margin: 20px 0;
        }

        #map {
            height: 500px;
        }

        .tournament-embed {
            height: 1000px;
        }

        .tournament-placeholder {
            display: flex;
            align-items: center;
            justify-content: center;
            height: 100%;
            padding: 40px;
            text-align: center;
            font-style: italic;
            color: var(--dark-gray);
            background: linear-gradient(135deg, rgba(19,41,75,0.05), rgba(226,11,92,0.05));
        }

        .tournament-embed iframe {
            width: 100%;
            height: 100%;
            border: none;
        }

        .venue-details {
            display: flex;
            flex-wrap: wrap;
            gap: 30px;
            margin-top: 30px;
        }

        .venue-address {
            flex: 1;
            min-width: 250px;
            background-color: var(--light-color);
            padding: 20px;
            border-radius: var(--border-radius);
            box-shadow: var(--shadow-sm);
        }

        .venue-address h3 {
            color: var(--primary-color);
            margin-top: 0;
        }

        .venue-description {
            margin-top: 30px;
            background-color: var(--light-color);
            padding: 20px;
            border-radius: var(--border-radius);
            box-shadow: var(--shadow-sm);
        }

        .venue-image {
            width: 100%;
            max-width: 100%;
            height: auto;
            border-radius: var(--border-radius);
            margin-top: 20px;
            overflow: hidden;
            box-shadow: var(--shadow-md);
        }

        .venue-image img {
            width: 100%;
            height: auto;
            display: block;
        }

        .info-cards {
            display: grid;
            grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
            gap: 25px;
            margin-top: 30px;
        }

        .tournament-group {
            margin-bottom: 40px;
        }

        .tournament-group:not(:last-child) {
            padding-bottom: 20px;
            border-bottom: 1px solid var(--medium-gray);
        }

        .tournament-group h2, .tournament-group h3.open-group-title {
            margin-top: 0;
            color: var(--primary-color);
            padding-bottom: 10px;
            border-bottom: 1px solid var(--light-accent);
            margin-bottom: 20px;
        }

        .info-cards-2col, .info-cards-3col { 
            display: grid;
            gap: 25px;
            margin-top: 20px;
        }
        .info-cards-2col {
            grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); 
        }
        .info-cards-3col {
            grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); 
        }

        @media (min-width: 992px) { 
            .tournament-group .info-cards-3col, 
            .tournament-section-title + .info-cards-3col 
            {
                grid-template-columns: repeat(3, 1fr);
            }
        }
         @media (max-width: 768px) {
            .info-cards-2col, .info-cards-3col { 
                grid-template-columns: 1fr;
            }
        }


        .tournament-section-title {
            margin-top: 40px;
            margin-bottom: 20px;
            padding-bottom: 10px;
            border-bottom: 1px solid var(--medium-gray);
            display: flex;
            align-items: center;
        }
        .tournament-section-description { 
            margin-bottom: 20px;
        }


        .tournament-section-title h2 {
            margin: 0;
        }

        .rapid-tournament {
            color: var(--rapid-color);
        }

        .rapid-tournament::after {
            background: var(--rapid-color);
        }

        .blitzschach-tournament { 
            color: var(--blitz-color);
        }

        .blitzschach-tournament::after { 
            background: var(--blitz-color);
        }

        .info-card {
            background-color: white;
            border-radius: var(--border-radius);
            box-shadow: var(--shadow-sm);
            padding: 25px;
            transition: transform var(--transition-speed);
            display: flex;
            flex-direction: column;
        }

        .info-card:hover {
            transform: translateY(-5px);
            box-shadow: var(--shadow-md);
        }

        .info-card-header {
            display: flex;
            align-items: center;
            gap: 15px;
            margin-bottom: 15px;
            padding-bottom: 10px;
            border-bottom: 1px solid var(--light-accent);
        }

        .info-card-header h3 {
            color: var(--primary-color);
            margin: 0;
            padding: 0;
            border: none;
        }

        .info-card.rapid .info-card-header h3 {
            color: var(--rapid-color);
        }

        .info-card.blitz .info-card-header h3 { 
            color: var(--blitz-color);
        }


        .info-card .note { 
             margin-top: 10px;
             font-size: 0.9em;
             color: var(--dark-gray); 
        }

        .info-card-icon {
            font-size: 24px;
            color: var(--secondary-color);
            margin-bottom: 0;
            line-height: 1;
            flex-shrink: 0;
        }

        .info-card.rapid .info-card-icon {
            color: var(--rapid-color);
        }

        .info-card.blitz .info-card-icon { 
            color: var(--blitz-color);
        }


        .fee-display {
            margin-top: 10px; 
            padding-top: 0; 
        }
        .fee-display.open-fee-display { 
            border-top: none;
            margin-top: 0; 
        }


        .fee-display-header { 
            display: flex;
            align-items: center;
            gap: 15px;
            margin-bottom: 15px;
        }

        .fee-display-header .info-card-icon {
            font-size: 24px;
            margin-bottom: 0;
        }

        .fee-display-header h4 {
            font-family: var(--font-heading);
            font-weight: 700;
            font-size: 1.2em;
            margin: 0;
            border: none;
            padding: 0;
        }


        .fee-display p {
            margin-bottom: 0.5rem;
        }

        .info-card.rapid .fee-display-header h4 { 
            color: var(--rapid-color);
        }

        .info-card.blitz .fee-display-header h4 { 
            color: var(--blitz-color);
        }

        .download-btn {
            display: inline-flex;
            align-items: center;
            gap: 10px;
            background: var(--primary-color);
            color: white;
            padding: 12px 24px;
            border-radius: var(--border-radius);
            text-decoration: none;
            font-weight: 600;
            transition: all var(--transition-speed);
            margin: 20px 0;
            box-shadow: var(--shadow-sm);
        }

        .download-btn + .download-btn {
            margin-left: 15px;
        }

        .download-btn:hover {
            background: var(--dark-accent);
            transform: translateY(-2px);
            box-shadow: var(--shadow-md);
        }

.download-icon {
    font-size: 20px;
}

.bank-details-highlight {
    display: inline-block;
    margin-top: 0.75rem;
    font-weight: 700;
    color: var(--primary-color);
}

.bank-details-highlight .bank-detail-row {
    display: flex;
    align-items: baseline;
    gap: 8px;
    font-size: 1.04em;
    line-height: 1.4;
}

.bank-detail-label {
    min-width: 9rem;
}

.bank-detail-value {
    flex: 1;
}

footer {
    background-color: var(--primary-color);
            color: white;
            padding-top: 20px; 
            margin-top: 50px;
            text-align: center; 
        }
        
        .footer-logo-container { /* Container for centering */
            display: flex;
            justify-content: center;
            align-items: center;
            padding: 10px 0; /* Padding around logo */
            margin-bottom: 15px;
        }
        .footer-logo { 
            height: 80px; /* Larger footer logo for better presence */
            width: auto;
            background-color: rgba(255, 255, 255, 0.9); /* White background for logo itself */
            padding: 12px; /* Padding inside the white box */
            border-radius: var(--border-radius);
            box-shadow: var(--shadow-sm);
        }

        .copyright {
            text-align: center;
            padding: 20px 0; 
            color: rgba(255, 255, 255, 0.6);
            display: flex;
            justify-content: center;
            flex-wrap: wrap;
            gap: 20px;
            align-items: center;
            border-top: 1px solid rgba(255,255,255,0.15); /* Light separator above copyright */
        }

        .copyright p {
            margin: 0;
        }

        .footer-links {
            display: flex;
            gap: 20px;
        }

        .footer-links a {
            color: rgba(255, 255, 255, 0.8);
            text-decoration: none;
            transition: color var(--transition-speed);
        }

        .footer-links a:hover {
            color: white;
            text-decoration: underline;
        }

        .modal {
            display: none; position: fixed; z-index: 1000; left: 0; top: 0; width: 100%; height: 100%; overflow: auto; background-color: rgba(0, 0, 0, 0.5); animation: fadeIn 0.3s;
        }
        .modal-content {
            background-color: white; margin: 5% auto; padding: 30px; border-radius: var(--border-radius); box-shadow: var(--shadow-lg); width: 80%; max-width: 800px; max-height: 80vh; overflow-y: auto; animation: slideDown 0.4s;
        }
        .modal-content p { margin-bottom: 0.5em; } 
        .modal-content ul { margin-bottom: 1em; margin-left: 20px;}
        .modal-content h3 { margin-top: 1.5rem; margin-bottom: 0.5rem;}
        .modal-content .impressum-spacer { margin-bottom: 1em; }
        .close-btn {
            color: var(--dark-gray); float: right; font-size: 28px; font-weight: bold; cursor: pointer; transition: color var(--transition-speed);
        }
        .close-btn:hover { color: var(--primary-color); }

        #loading-indicator { text-align: center; margin: 20px 0; display: none; }
        .spinner { border: 4px solid rgba(0, 0, 0, 0.1); width: 36px; height: 36px; border-radius: 50%; border-left-color: var(--secondary-color); animation: spin 1s linear infinite; display: inline-block; }
        @keyframes spin { 0% { transform: rotate(0deg); } 100% { transform: rotate(360deg); } }

        .schedule-table { width: 100%; border-collapse: collapse; margin: 20px 0; background-color: white; border-radius: var(--border-radius); overflow: hidden; box-shadow: var(--shadow-sm); }
        .schedule-table th, .schedule-table td { padding: 12px 15px; border-bottom: 1px solid var(--light-gray); }
        .schedule-table th { background-color: var(--primary-color); color: white; text-align: left; }
        .schedule-table tr:last-child td { border-bottom: none; }
        
        .schedule-table tr.open-event-row td { background-color: white; } 
        .schedule-table tr.open-event-row:nth-child(even) td { background-color: #ffffff; } 
        
        .schedule-table tr.rapid-event td { background-color: rgba(74, 103, 65, 0.1) !important; } 
        .rapid-event .schedule-event { color: var(--rapid-color); font-weight: 600; }
        .schedule-table tr.blitzschach-event td { background-color: rgba(103, 65, 65, 0.1) !important; } 
        .blitzschach-event .schedule-event { color: var(--blitz-color); font-weight: 600; } 
        .schedule-day { font-weight: 600; color: var(--primary-color); }


        .fees-table { width: 100%; border-collapse: collapse; margin: 15px 0; background-color: white; border-radius: var(--border-radius); overflow: hidden; box-shadow: var(--shadow-sm); }
        .fees-table th, .fees-table td { padding: 12px 15px; border-bottom: 1px solid var(--light-gray); vertical-align: top; }
        .fees-table th { background-color: var(--primary-color); color: white; text-align: left; }
        .fees-table tr:last-child td { border-bottom: none; }
        .note { font-style: italic; color: var(--dark-gray); display: block; margin-top: 5px; font-size: 0.9em; }

        .payment-summary { background-color: var(--light-color); border: 1px solid var(--medium-gray); border-radius: var(--border-radius); padding: 20px; margin-top: 20px; box-shadow: var(--shadow-sm); display: none; }
        .payment-summary h3 { margin-top: 0; padding-bottom: 10px; border-bottom: 1px solid var(--medium-gray); color: var(--primary-color); }
        .payment-row { display: flex; justify-content: space-between; padding: 10px 0; border-bottom: 1px solid var(--light-gray); }
        .payment-row:last-child { border-bottom: none; }
        .payment-total { font-weight: 600; color: var(--secondary-color); font-size: 1.1em; margin-top: 10px; padding-top: 10px; border-top: 2px solid var(--medium-gray); }
        .payment-total .player-fee.deposit { /* Ensure deposit color is also applied in total if needed, though usually total is one color */
             color: var(--deposit-fee-color);
        }
        .payment-reference { background-color: white; padding: 15px; border-radius: var(--border-radius); margin-top: 15px; font-family: monospace; font-size: 1.1em; text-align: center; border: 1px dashed var(--accent-color); display: none; } /* Hide initially */

        .success-message { display: none; background-color: #d4edda; color: #155724; padding: 25px; border-radius: var(--border-radius); margin-bottom: 30px; border: 1px solid #c3e6cb; animation: fadeIn 0.5s; position: relative; }
        .success-message h3 { color: #155724; margin-bottom: 15px; }
        .registration-details { background-color: white; padding: 20px; border-radius: var(--border-radius); margin-top: 15px; border: 1px solid #c3e6cb; }
        .registration-player { padding: 10px 0; border-bottom: 1px solid #eee; }
        .registration-player:last-child { border-bottom: none; }
        .close-msg-btn { position: absolute; top: 15px; right: 15px; background-color: transparent; color: #155724; border: 1px solid #c3e6cb; padding: 5px 10px; cursor: pointer; font-size: 14px; border-radius: 4px; }
        .close-msg-btn:hover { background-color: #c3e6cb; transform: none; box-shadow: none; }

        .database-source { display: inline-block; margin-left: 5px; font-size: 0.8em; padding: 2px 6px; border-radius: 4px; background-color: var(--light-accent); color: var(--dark-accent); }

        .language-switcher { position: absolute; top: 10px; right: 20px; z-index: 10; display: flex; align-items: center; gap: 10px; }
        .language-btn { background: none; padding: 0; margin: 0; border: none; cursor: pointer; transition: all 0.2s; opacity: 0.7; box-shadow: none; width: 40px; height: 30px; display: flex; align-items: center; justify-content: center; }
        .language-btn svg { width: 100%; height: 100%; }
        .language-btn:hover { opacity: 1; transform: translateY(-1px); box-shadow: 0 2px 5px rgba(0,0,0,0.2); }
        .language-btn.active { opacity: 1; box-shadow: 0 0 0 2px white; }

        .time-slots { display: flex; flex-direction: column; gap: 5px; }
        .time-slot { display: flex; align-items: center; padding: 2px 0; }

        .tournament-description { margin-top: 30px; padding: 20px; background-color: var(--light-color); border-radius: var(--border-radius); }
        
        .gallery-grid {
            display: grid;
            grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
            gap: 20px;
            margin-top: 20px;
        }
        .gallery-item {
            border: 1px solid var(--medium-gray);
            border-radius: var(--border-radius);
            overflow: hidden;
            box-shadow: var(--shadow-sm);
            background-color: var(--light-gray); 
            display: flex;
            flex-direction: column; 
            align-items: center;
            justify-content: flex-start; 
            color: var(--dark-gray);
        }
        .gallery-item img {
            width: 100%;
            height: 200px; 
            object-fit: cover;
            display: block;
        }
        .gallery-item p.caption { 
            padding: 10px;
            text-align: center;
            font-size: 0.9em;
            margin: 0;
            background-color: var(--light-color);
            width: 100%; 
            font-style: normal; 
        }


        @media screen and (max-width: 768px) {
            /* .header-content stack handled by .header-top-row flex-wrap */
            .tab-button, .tournament-dropdown-container { padding: 12px 8px; font-size: 14px; width: auto;  }
            .tournament-dropdown { width: 100%; }
            .player-info-grid, 
            .player-info-grid.middle-row, 
            .player-info-grid.bottom-row { 
                grid-template-columns: 1fr; /* Single column on smaller screens */
            }
            .tab-content { padding: 20px; }
            .venue-details { flex-direction: column; }
            .modal-content { width: 90%; margin: 10% auto; }
            .fees-table th, .fees-table td { font-size: 0.9em; padding: 8px 10px; }
        }

        @media screen and (max-width: 480px) {
            .tab-button, .tournament-dropdown-container { width: auto;  }
            #map, .tournament-embed { height: 400px; }
            .copyright { flex-direction: column; gap: 10px; }
            .open-selection-options { grid-template-columns: 1fr; } /* Stack open selection options */
        }
