/**
 * Stadtboote Inventar - Frontend Styles
 *
 * @package Stadtboote_Inventar
 */

/* ==========================================================================
   Variables
   ========================================================================== */
:root {
    --stadtboote-primary: #020C24;
    --stadtboote-primary-dark: #000510;
    --stadtboote-secondary: #6c757d;
    --stadtboote-success: #28a745;
    --stadtboote-light: #f8f9fa;
    --stadtboote-dark: #212529;
    --stadtboote-border: #dee2e6;
    --stadtboote-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
    --stadtboote-radius: 8px;
    --stadtboote-transition: all 0.3s ease;
}

/* ==========================================================================
   SVG Icons
   ========================================================================== */
.stadtboote-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    vertical-align: middle;
    line-height: 1;
}

.stadtboote-icon svg {
    width: 1em;
    height: 1em;
    display: block;
}

/* ==========================================================================
   Layout
   ========================================================================== */
.stadtboote-listing {
    margin: 2rem 0;
}

.stadtboote-grid {
    display: grid;
    gap: 1.5rem;
    margin: 1.5rem 0;
}

.stadtboote-grid-2 {
    grid-template-columns: repeat(2, 1fr);
}

.stadtboote-grid-3 {
    grid-template-columns: repeat(3, 1fr);
}

.stadtboote-grid-4 {
    grid-template-columns: repeat(4, 1fr);
}

@media (max-width: 1024px) {
    .stadtboote-grid-3,
    .stadtboote-grid-4 {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 640px) {
    .stadtboote-grid-2,
    .stadtboote-grid-3,
    .stadtboote-grid-4 {
        grid-template-columns: 1fr;
    }
}

/* ==========================================================================
   Filters
   ========================================================================== */
.stadtboote-filters {
    background: var(--stadtboote-light);
    padding: 1.5rem 2rem;
    border-radius: var(--stadtboote-radius);
    margin-bottom: 1.5rem;
}

.stadtboote-filter-form {
    display: flex;
    flex-direction: column;
    gap: 1.25rem;
}

.stadtboote-filter-row {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
    gap: 1.25rem;
    align-items: end;
}

/* Main filter row with all primary filters */
.stadtboote-filter-main {
    grid-template-columns: repeat(6, 1fr);
}

.stadtboote-filter-main .stadtboote-filter-checkbox {
    justify-content: flex-start;
    align-items: flex-end;
}

.stadtboote-filter-group {
    display: flex;
    flex-direction: column;
}

.stadtboote-filter-group label {
    display: block;
    font-size: 0.75rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 0.5rem;
    color: var(--stadtboote-secondary);
}

/* Unified input styling for Safari compatibility */
.stadtboote-filter-select,
.stadtboote-filter-number {
    width: 100%;
    height: 44px;
    padding: 0 0.875rem;
    border: 1px solid var(--stadtboote-border);
    border-radius: 6px;
    font-size: 0.9375rem;
    font-family: inherit;
    background-color: #fff;
    color: var(--stadtboote-dark);
    transition: var(--stadtboote-transition);
    /* Safari compatibility */
    -webkit-appearance: none;
    -moz-appearance: none;
    appearance: none;
    box-sizing: border-box;
}

/* Custom dropdown arrow */
.stadtboote-filter-select {
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12'%3E%3Cpath fill='%236c757d' d='M6 8L1 3h10z'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 0.875rem center;
    padding-right: 2.5rem;
    cursor: pointer;
}

/* Date input icon fix for Safari */
.stadtboote-filter-date {
    position: relative;
}

.stadtboote-filter-date::-webkit-calendar-picker-indicator {
    opacity: 0.6;
    cursor: pointer;
}

.stadtboote-filter-select:hover,
.stadtboote-filter-number:hover {
    border-color: var(--stadtboote-secondary);
}

.stadtboote-filter-select:focus,
.stadtboote-filter-number:focus {
    outline: none;
    border-color: var(--stadtboote-primary);
    box-shadow: 0 0 0 3px rgba(0, 102, 204, 0.1);
}

/* ==========================================================================
   Range Slider Dropdown (Airbnb Style)
   ========================================================================== */
.stadtboote-filter-range-dropdown {
    position: relative;
}

.stadtboote-range-trigger {
    display: flex;
    align-items: center;
    justify-content: space-between;
    width: 100%;
    height: 44px;
    padding: 0 0.875rem;
    border: 1px solid var(--stadtboote-border);
    border-radius: 6px;
    font-size: 0.9375rem;
    background-color: #fff;
    color: var(--stadtboote-dark);
    cursor: pointer;
    transition: var(--stadtboote-transition);
    -webkit-appearance: none;
    box-sizing: border-box;
}

.stadtboote-range-trigger:hover {
    border-color: var(--stadtboote-secondary);
}

.stadtboote-range-trigger.active {
    border-color: var(--stadtboote-primary);
    box-shadow: 0 0 0 3px rgba(0, 102, 204, 0.1);
}

.stadtboote-range-display {
    flex: 1;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.stadtboote-range-arrow {
    flex-shrink: 0;
    margin-left: 0.5rem;
    color: var(--stadtboote-secondary);
    transition: transform 0.2s ease;
}

.stadtboote-range-trigger.active .stadtboote-range-arrow {
    transform: rotate(180deg);
}

/* Popup */
.stadtboote-range-popup {
    position: absolute;
    top: calc(100% + 8px);
    left: 0;
    width: 320px;
    background: #fff;
    border-radius: 12px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.15);
    border: 1px solid var(--stadtboote-border);
    padding: 1.5rem;
    z-index: 1000;
    display: none;
}

.stadtboote-range-popup.active {
    display: block;
}

/* Suchmaske: Range-Popup-Inhalt innerhalb der Box (kein Clipping/Containing-Block-Konflikt) */
.stadtboote-search-form .stadtboote-filters,
.stadtboote-search-form .stadtboote-filter-form,
.stadtboote-search-form .stadtboote-filter-main,
.stadtboote-search-form .stadtboote-filter-range-dropdown {
    overflow: visible;
}

.stadtboote-search-form .stadtboote-range-popup {
    isolation: isolate;
    overflow: visible;
}

/* Suchmaske: linksbündig, aber Aktionszeile + Filter-Buttons wie ursprünglich */
.stadtboote-search-form-wrapper.stadtboote-search-form,
.stadtboote-search-form .stadtboote-filters,
.stadtboote-search-form .stadtboote-filter-form,
.stadtboote-search-form .stadtboote-filter-row,
.stadtboote-search-form .stadtboote-filter-main,
.stadtboote-search-form .stadtboote-filter-group,
.stadtboote-search-form .stadtboote-filter-group label,
.stadtboote-search-form .stadtboote-results-wrapper,
.stadtboote-search-form .stadtboote-results {
    text-align: left;
}

.stadtboote-search-form .stadtboote-filter-form {
    align-items: flex-start;
}

/* Suchmaske: responsive Basis – kein Overflow auf schmalen Viewports */
.stadtboote-search-form-wrapper {
    max-width: 100%;
    width: 100%;
    box-sizing: border-box;
}

.stadtboote-search-form .stadtboote-filters {
    width: 100%;
    max-width: 100%;
    box-sizing: border-box;
}

.stadtboote-search-form .stadtboote-filter-form,
.stadtboote-search-form .stadtboote-filter-row,
.stadtboote-search-form .stadtboote-filter-main {
    min-width: 0;
}

.stadtboote-search-form .stadtboote-filter-group {
    min-width: 0;
}

.stadtboote-search-form .stadtboote-filter-select,
.stadtboote-search-form .stadtboote-filter-number,
.stadtboote-search-form .stadtboote-filter-date,
.stadtboote-search-form .stadtboote-range-trigger,
.stadtboote-search-form .stadtboote-options-trigger {
    max-width: 100%;
    width: 100%;
    box-sizing: border-box;
}

/* Aktionszeile (Sortierung + Filter-Buttons): volle Breite, Layout wie vorher */
.stadtboote-search-form .stadtboote-filter-actions {
    width: 100%;
    justify-content: space-between;
    align-items: end;
}

/* Suchmaske: Live-AJAX – "Filter anwenden" nicht mehr nötig (optional ausblendbar) */
.stadtboote-search-form .stadtboote-filter-buttons .stadtboote-btn-primary {
    display: none;
}

/* Filter-Felder: keine justify-items-Override, damit Spalten gleich breit bleiben */
/* (justify-items: start wurde entfernt, Grid-Zellen strecken wie vorher) */

/* Slider Container */
.stadtboote-range-slider-container {
    position: relative;
    height: 40px;
    margin-bottom: 1.5rem;
}

.stadtboote-range-track {
    position: absolute;
    top: 50%;
    left: 0;
    right: 0;
    height: 4px;
    background: #e0e0e0;
    border-radius: 2px;
    transform: translateY(-50%);
}

.stadtboote-range-selected {
    position: absolute;
    height: 100%;
    background: var(--stadtboote-primary);
    border-radius: 2px;
}

/* Range Inputs */
.stadtboote-range-input {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    width: 100%;
    height: 40px;
    -webkit-appearance: none;
    appearance: none;
    background: transparent;
    pointer-events: none;
    margin: 0;
}

.stadtboote-range-input::-webkit-slider-thumb {
    -webkit-appearance: none;
    appearance: none;
    width: 28px;
    height: 28px;
    background: #fff;
    border: 2px solid var(--stadtboote-primary);
    border-radius: 50%;
    cursor: pointer;
    pointer-events: auto;
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.15);
    transition: transform 0.15s ease, box-shadow 0.15s ease;
}

.stadtboote-range-input::-webkit-slider-thumb:hover {
    transform: scale(1.1);
    box-shadow: 0 3px 10px rgba(0, 0, 0, 0.2);
}

.stadtboote-range-input::-webkit-slider-thumb:active {
    transform: scale(1.15);
}

.stadtboote-range-input::-moz-range-thumb {
    width: 28px;
    height: 28px;
    background: #fff;
    border: 2px solid var(--stadtboote-primary);
    border-radius: 50%;
    cursor: pointer;
    pointer-events: auto;
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.15);
}

/* Value inputs */
.stadtboote-range-values {
    display: flex;
    gap: 1rem;
}

.stadtboote-range-value-group {
    flex: 1;
}

.stadtboote-range-value-label {
    display: block;
    font-size: 0.75rem;
    font-weight: 600;
    color: var(--stadtboote-secondary);
    margin-bottom: 0.375rem;
}

.stadtboote-range-value-input {
    position: relative;
}

.stadtboote-range-number {
    width: 100%;
    height: 44px;
    padding: 0 0.875rem;
    border: 1px solid var(--stadtboote-border);
    border-radius: 24px;
    font-size: 0.9375rem;
    font-family: inherit;
    text-align: center;
    background: #fff;
    color: var(--stadtboote-dark);
    -webkit-appearance: none;
    -moz-appearance: textfield;
    box-sizing: border-box;
}

.stadtboote-range-number::-webkit-outer-spin-button,
.stadtboote-range-number::-webkit-inner-spin-button {
    -webkit-appearance: none;
    margin: 0;
}

.stadtboote-range-number:focus {
    outline: none;
    border-color: var(--stadtboote-primary);
}

/* Euro symbol for price inputs */
.stadtboote-range-value-euro {
    position: relative;
}

.stadtboote-range-value-euro::after {
    content: '€';
    position: absolute;
    right: 1rem;
    top: 50%;
    transform: translateY(-50%);
    color: var(--stadtboote-secondary);
    font-size: 0.875rem;
    pointer-events: none;
}

.stadtboote-range-value-euro .stadtboote-range-number {
    padding-right: 2rem;
}

/* ==========================================================================
   Buchungsoptionen Dropdown
   ========================================================================== */
.stadtboote-filter-options-dropdown {
    position: relative;
}

.stadtboote-options-trigger {
    display: flex;
    align-items: center;
    justify-content: space-between;
    width: 100%;
    height: 44px;
    padding: 0 0.875rem;
    border: 1px solid var(--stadtboote-border);
    border-radius: 6px;
    font-size: 0.9375rem;
    background-color: #fff;
    color: var(--stadtboote-dark);
    cursor: pointer;
    transition: var(--stadtboote-transition);
    box-sizing: border-box;
}

.stadtboote-options-trigger:hover {
    border-color: var(--stadtboote-secondary);
}

.stadtboote-options-trigger.active {
    border-color: var(--stadtboote-primary);
    box-shadow: 0 0 0 3px rgba(0, 102, 204, 0.1);
}

.stadtboote-options-display {
    flex: 1;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.stadtboote-options-arrow {
    flex-shrink: 0;
    margin-left: 0.5rem;
    color: var(--stadtboote-secondary);
    transition: transform 0.2s ease;
}

.stadtboote-options-trigger.active .stadtboote-options-arrow {
    transform: rotate(180deg);
}

/* Options Popup */
.stadtboote-options-popup {
    position: absolute;
    top: calc(100% + 8px);
    left: 0;
    min-width: 260px;
    max-height: 340px;
    overflow-y: auto;
    background: #fff;
    border-radius: 10px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.15);
    border: 1px solid var(--stadtboote-border);
    padding: 0.25rem 0;
    z-index: 1000;
    display: none;
}

.stadtboote-options-popup.active {
    display: block;
}

/* Option Items */
.stadtboote-options-list {
    display: flex;
    flex-direction: column;
    padding: 0.125rem 0.25rem;
}

.stadtboote-option-item {
    display: flex;
    align-items: center;
    gap: 0.4rem;
    padding: 0.125rem 0.75rem;
    cursor: pointer;
    transition: var(--stadtboote-transition);
    margin: 0;
    border-radius: 6px;
}

.stadtboote-option-item:hover {
    background: var(--stadtboote-light);
}

/* Hide native checkbox completely */
.stadtboote-option-item input[type="checkbox"] {
    position: absolute;
    opacity: 0;
    width: 0;
    height: 0;
    margin: 0;
    padding: 0;
}

/* Custom checkbox via span */
.stadtboote-option-item .stadtboote-option-check {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 18px;
    height: 18px;
    border: 1.5px solid #c4c4c4;
    border-radius: 4px;
    background: #fff;
    flex-shrink: 0;
    transition: var(--stadtboote-transition);
}

.stadtboote-option-item .stadtboote-option-check svg {
    width: 11px;
    height: 11px;
    opacity: 0;
    color: #fff;
    transition: opacity 0.15s ease;
}

.stadtboote-option-item:hover .stadtboote-option-check {
    border-color: var(--stadtboote-primary);
}

.stadtboote-option-item input[type="checkbox"]:checked ~ .stadtboote-option-check {
    background: var(--stadtboote-primary);
    border-color: var(--stadtboote-primary);
}

.stadtboote-option-item input[type="checkbox"]:checked ~ .stadtboote-option-check svg {
    opacity: 1;
}

/* Ausstattungs-Icon im Option-Item (einheitliche Größe und Farbe für hochgeladene + System-Icons) */
.stadtboote-option-item .stadtboote-icon {
    width: 18px;
    height: 18px;
    flex-shrink: 0;
    color: #D9C39F;
}

.stadtboote-option-item .stadtboote-icon svg,
.stadtboote-option-item .stadtboote-icon img {
    width: 18px;
    height: 18px;
    object-fit: contain;
}

/* Einheitlich beige #D9C39F: gefüllte Icons (fill) und Outline-Icons (stroke) sichtbar */
.stadtboote-option-item .stadtboote-icon svg,
.stadtboote-option-item .stadtboote-icon svg * {
    fill: #D9C39F;
    stroke: #D9C39F;
}

/* Outline-Icons (fill="none" / stroke): nicht füllen – nur Linien gefärbt, höhere Spezifität */
.stadtboote-option-item .stadtboote-icon svg[stroke],
.stadtboote-option-item .stadtboote-icon svg[fill="none"],
.stadtboote-option-item .stadtboote-icon svg[stroke] *,
.stadtboote-option-item .stadtboote-icon svg[fill="none"] * {
    fill: none !important;
}

/* Option text */
.stadtboote-option-text {
    font-size: 0.875rem;
    line-height: 1.3;
    color: var(--stadtboote-dark);
    font-weight: 400;
    text-transform: none;
}

/* Custom Checkbox */
.stadtboote-filter-checkbox {
    display: flex;
    align-items: center;
    gap: 0;
    min-height: 44px;
    position: relative;
}

/* Hide native checkbox */
.stadtboote-filter-checkbox input[type="checkbox"] {
    position: absolute;
    opacity: 0;
    width: 0;
    height: 0;
    pointer-events: none;
}

.stadtboote-filter-checkbox label {
    display: flex;
    align-items: center;
    gap: 0.625rem;
    cursor: pointer;
    margin-bottom: 0;
    font-size: 0.9375rem;
    font-weight: 500;
    color: var(--stadtboote-dark);
    user-select: none;
    position: relative;
    padding-left: 0;
}

/* Custom checkbox box */
.stadtboote-filter-checkbox label::before {
    content: '';
    display: inline-block;
    width: 20px;
    height: 20px;
    border: 2px solid var(--stadtboote-border);
    border-radius: 4px;
    background: #fff;
    transition: var(--stadtboote-transition);
    flex-shrink: 0;
}

/* Checkmark */
.stadtboote-filter-checkbox label::after {
    content: '';
    position: absolute;
    left: 7px;
    top: 50%;
    margin-top: -7px;
    width: 6px;
    height: 10px;
    border: solid transparent;
    border-width: 0 2px 2px 0;
    transform: rotate(45deg);
    transition: var(--stadtboote-transition);
}

/* Checked state */
.stadtboote-filter-checkbox input[type="checkbox"]:checked + label::before {
    background: var(--stadtboote-primary);
    border-color: var(--stadtboote-primary);
}

.stadtboote-filter-checkbox input[type="checkbox"]:checked + label::after {
    border-color: #fff;
}

/* Hover state */
.stadtboote-filter-checkbox label:hover::before {
    border-color: var(--stadtboote-primary);
}

/* Focus state */
.stadtboote-filter-checkbox input[type="checkbox"]:focus + label::before {
    box-shadow: 0 0 0 3px rgba(0, 102, 204, 0.1);
}

/* Actions row */
.stadtboote-filter-actions {
    display: flex;
    flex-wrap: wrap;
    justify-content: space-between;
    align-items: end;
    gap: 1rem;
    padding-top: 1rem;
    border-top: 1px solid var(--stadtboote-border);
    margin-top: 0.5rem;
}

.stadtboote-filter-buttons {
    display: flex;
    gap: 0.75rem;
    flex-wrap: wrap;
    height: 50px;
}

.stadtboote-filter-buttons .stadtboote-btn {
    padding: 0.625rem 1.25rem;
    font-size: 0.9375rem;
    min-height: auto;
    height: auto;
}

/* Responsive adjustments */
@media (max-width: 1024px) {
    .stadtboote-filter-main {
        grid-template-columns: repeat(3, 1fr);
    }
}

@media (max-width: 768px) {
    .stadtboote-filters {
        padding: 1.25rem;
    }
    
    .stadtboote-search-form .stadtboote-filters {
        padding: 1.25rem 1rem;
    }
    
    .stadtboote-filter-row,
    .stadtboote-filter-main {
        grid-template-columns: 1fr 1fr;
    }
    
    .stadtboote-search-form .stadtboote-filter-form {
        gap: 1rem;
    }
    
    .stadtboote-filter-actions {
        flex-direction: row;
        flex-wrap: wrap;
        align-items: center;
        justify-content: space-between;
    }
    
    /* Auf Mobil: Sortierung links, Filter zurücksetzen rechts */
    .stadtboote-filter-actions .stadtboote-filter-group {
        order: 1;
    }
    
    .stadtboote-filter-buttons {
        order: 2;
        margin-left: auto;
        justify-content: flex-end;
    }
    
    .stadtboote-filter-buttons .stadtboote-btn {
        flex: 0 1 auto;
        padding: 0.625rem 1rem !important;
        font-size: 0.875rem !important;
        min-height: auto !important;
        height: auto !important;
    }
    
    /* Dropdown-Popups auf Mobil nicht breiter als Viewport */
    .stadtboote-search-form .stadtboote-options-popup,
    .stadtboote-search-form .stadtboote-range-popup {
        max-width: min(340px, calc(100vw - 2rem));
        left: 0;
        right: auto;
    }
}

/* Suchmaske: ab 600px einspaltig und mobilfreundlich (nach 768px, damit es greift) */
@media (max-width: 600px) {
    .stadtboote-search-form .stadtboote-filters {
        padding: 1rem 0.75rem;
    }
    
    .stadtboote-search-form .stadtboote-filter-form,
    .stadtboote-search-form .stadtboote-filter-row,
    .stadtboote-search-form .stadtboote-filter-main {
        width: 100%;
    }
    
    .stadtboote-search-form .stadtboote-filter-row,
    .stadtboote-search-form .stadtboote-filter-main {
        grid-template-columns: 1fr;
        gap: 0.75rem;
    }
    
    /* Filtergruppen und Felder in Mobilansicht volle Breite */
    .stadtboote-search-form .stadtboote-filter-main > .stadtboote-filter-group,
    .stadtboote-search-form .stadtboote-filter-group {
        width: 100%;
        max-width: 100%;
    }
    
    .stadtboote-search-form .stadtboote-filter-select,
    .stadtboote-search-form .stadtboote-filter-number,
    .stadtboote-search-form .stadtboote-filter-date,
    .stadtboote-search-form .stadtboote-range-trigger,
    .stadtboote-search-form .stadtboote-options-trigger {
        width: 100%;
        max-width: 100%;
        box-sizing: border-box;
    }
    
    .stadtboote-search-form .stadtboote-filter-form {
        gap: 0.75rem;
    }
    
    .stadtboote-search-form .stadtboote-filter-actions {
        flex-direction: column;
        align-items: stretch;
        gap: 0.75rem;
        padding-top: 0.75rem;
        margin-top: 0.5rem;
    }
    
    .stadtboote-search-form .stadtboote-filter-actions .stadtboote-filter-group {
        order: 1;
    }
    
    .stadtboote-search-form .stadtboote-filter-buttons {
        order: 2;
        margin-left: 0;
        justify-content: stretch;
    }
    
    .stadtboote-search-form .stadtboote-filter-buttons .stadtboote-btn {
        flex: 1;
    }
}

@media (max-width: 480px) {
    .stadtboote-filter-row,
    .stadtboote-filter-main {
        grid-template-columns: 1fr;
    }
    
    .stadtboote-search-form .stadtboote-filters {
        padding: 1rem 0.875rem;
    }
    
    .stadtboote-search-form .stadtboote-filter-form {
        gap: 0.875rem;
    }
    
    .stadtboote-search-form .stadtboote-filter-group label {
        font-size: 0.7rem;
    }
    
    .stadtboote-filter-range .stadtboote-range-inputs {
        justify-content: flex-start;
    }
    
    .stadtboote-filter-range .stadtboote-filter-number {
        flex: 1;
        max-width: 100px;
    }
    
    .stadtboote-filter-buttons .stadtboote-btn {
        padding: 0.5rem 0.75rem !important;
        font-size: 0.8125rem !important;
        min-height: auto !important;
        height: auto !important;
    }
    
    /* Aktionszeile auf sehr schmalen Screens: untereinander, volle Breite */
    .stadtboote-search-form .stadtboote-filter-actions {
        flex-direction: column;
        align-items: stretch;
        gap: 0.75rem;
    }
    
    .stadtboote-search-form .stadtboote-filter-actions .stadtboote-filter-group {
        order: 1;
    }
    
    .stadtboote-search-form .stadtboote-filter-buttons {
        order: 2;
        margin-left: 0;
        justify-content: stretch;
    }
    
    .stadtboote-search-form .stadtboote-filter-buttons .stadtboote-btn {
        flex: 1;
    }
}

/* Sehr schmale Smartphones (z. B. 320–360px) */
@media (max-width: 360px) {
    .stadtboote-search-form .stadtboote-filters {
        padding: 0.75rem 0.625rem;
    }
    
    .stadtboote-search-form .stadtboote-filter-select,
    .stadtboote-search-form .stadtboote-filter-number,
    .stadtboote-search-form .stadtboote-range-trigger,
    .stadtboote-search-form .stadtboote-options-trigger {
        height: 42px;
        padding: 0 0.75rem;
        font-size: 0.875rem;
    }
}

/* ==========================================================================
   Flatpickr Custom Styling
   ========================================================================== */
.flatpickr-calendar {
    font-family: inherit;
    border-radius: 8px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.15);
    border: 1px solid var(--stadtboote-border);
    width: 320px !important;
}

.flatpickr-innerContainer {
    padding: 0 0.5rem 0.5rem 0.5rem;
}

.flatpickr-months {
    padding: 0.5rem 0;
}

.flatpickr-months .flatpickr-month {
    height: 36px;
}

.flatpickr-current-month {
    font-size: 1rem;
    font-weight: 600;
    color: var(--stadtboote-dark);
}

.flatpickr-current-month .flatpickr-monthDropdown-months,
.flatpickr-current-month input.cur-year {
    font-weight: 600;
}

.flatpickr-months .flatpickr-prev-month,
.flatpickr-months .flatpickr-next-month {
    top: 10px;
    padding: 8px;
    color: var(--stadtboote-secondary);
    fill: var(--stadtboote-secondary);
    transition: var(--stadtboote-transition);
}

.flatpickr-months .flatpickr-prev-month:hover,
.flatpickr-months .flatpickr-next-month:hover {
    color: var(--stadtboote-primary);
    fill: var(--stadtboote-primary);
}

.flatpickr-months .flatpickr-prev-month svg,
.flatpickr-months .flatpickr-next-month svg {
    width: 16px;
    height: 16px;
}

.flatpickr-weekdays {
    padding: 0.25rem 0;
}

.flatpickr-weekday {
    font-size: 0.75rem;
    font-weight: 600;
    color: var(--stadtboote-secondary);
    text-transform: uppercase;
}

.flatpickr-day {
    font-size: 0.875rem;
    color: var(--stadtboote-dark);
    border-radius: 6px;
    transition: var(--stadtboote-transition);
    max-width: 36px;
    height: 36px;
    line-height: 36px;
}

.flatpickr-day:hover {
    background: var(--stadtboote-light);
    border-color: var(--stadtboote-light);
}

.flatpickr-day.today {
    border-color: var(--stadtboote-primary);
}

.flatpickr-day.today:hover {
    background: var(--stadtboote-primary);
    border-color: var(--stadtboote-primary);
    color: #fff;
}

.flatpickr-day.selected,
.flatpickr-day.selected:hover {
    background: var(--stadtboote-primary);
    border-color: var(--stadtboote-primary);
    color: #fff;
}

.flatpickr-day.prevMonthDay,
.flatpickr-day.nextMonthDay {
    color: var(--stadtboote-secondary);
    opacity: 0.5;
}

.flatpickr-day.disabled {
    color: var(--stadtboote-border);
}

/* Date input base styling (before and after Flatpickr) */
.stadtboote-filter-date,
.stadtboote-filter-date.flatpickr-input + .stadtboote-datepicker-input,
.stadtboote-datepicker-input {
    width: 100%;
    height: 44px;
    padding: 0 2.5rem 0 0.875rem;
    border: 1px solid var(--stadtboote-border);
    border-radius: 6px;
    font-size: 0.9375rem;
    font-family: inherit;
    background-color: #fff;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='18' height='18' viewBox='0 0 24 24' fill='none' stroke='%236c757d' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Crect x='3' y='4' width='18' height='18' rx='2' ry='2'/%3E%3Cline x1='16' y1='2' x2='16' y2='6'/%3E%3Cline x1='8' y1='2' x2='8' y2='6'/%3E%3Cline x1='3' y1='10' x2='21' y2='10'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 0.75rem center;
    color: var(--stadtboote-dark);
    -webkit-appearance: none;
    -moz-appearance: none;
    appearance: none;
    box-sizing: border-box;
    cursor: pointer;
}

/* Hide original input when Flatpickr creates altInput */
.stadtboote-filter-date.flatpickr-input[type="hidden"] {
    display: none !important;
}

.stadtboote-filter-date::placeholder,
.stadtboote-datepicker-input::placeholder {
    color: var(--stadtboote-secondary);
    opacity: 0.7;
}

.stadtboote-filter-date:hover,
.stadtboote-datepicker-input:hover {
    border-color: var(--stadtboote-secondary);
}

.stadtboote-filter-date:focus,
.stadtboote-datepicker-input:focus {
    outline: none;
    border-color: var(--stadtboote-primary);
    box-shadow: 0 0 0 3px rgba(0, 102, 204, 0.1);
}

.stadtboote-filter-date[readonly],
.flatpickr-input[readonly] {
    cursor: pointer;
}

/* ==========================================================================
   Buttons
   ========================================================================== */
.stadtboote-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0.625rem 1.25rem;
    font-size: 0.9375rem;
    font-weight: 600;
    text-decoration: none;
    border-radius: 4px;
    cursor: pointer;
    transition: var(--stadtboote-transition);
    border: none;
    height: 44px;
}

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

.stadtboote-btn-primary:hover {
    background: var(--stadtboote-primary-dark);
    color: #fff;
}

.stadtboote-btn-secondary {
    background: transparent;
    color: var(--stadtboote-secondary);
    border: 1px solid var(--stadtboote-border);
}

.stadtboote-btn-secondary:hover {
    background: var(--stadtboote-light);
    color: var(--stadtboote-dark);
}

.stadtboote-btn-large {
    padding: 0.875rem 1.75rem;
    font-size: 1rem;
}

/* ==========================================================================
   Results
   ========================================================================== */
.stadtboote-results-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1rem;
}

.stadtboote-results-count {
    font-size: 0.9375rem;
    color: var(--stadtboote-secondary);
    margin: 0;
}

.stadtboote-no-results {
    text-align: center;
    padding: 3rem;
    background: var(--stadtboote-light);
    border-radius: var(--stadtboote-radius);
}

/* ==========================================================================
   Cards
   ========================================================================== */
.stadtboote-card {
    background: #fff;
    border-radius: var(--stadtboote-radius);
    overflow: hidden;
    box-shadow: var(--stadtboote-shadow);
    transition: var(--stadtboote-transition);
}

.stadtboote-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.12);
}

.stadtboote-card-link {
    display: block;
    text-decoration: none;
    color: inherit;
}

.stadtboote-card-image {
    position: relative;
    aspect-ratio: 4/3;
    overflow: hidden;
    background: var(--stadtboote-light);
}

.stadtboote-card-image img {
    width: 100% !important;
    height: 100% !important;
    max-width: none;
    object-fit: cover;
    object-position: center;
    display: block;
    position: absolute;
    top: 0;
    left: 0;
    transition: transform 0.4s ease;
}

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

.stadtboote-card-placeholder {
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, #e0e0e0 0%, #f5f5f5 100%);
}

/* Badges Container (nebeneinander) */
.stadtboote-card-badges {
    position: absolute;
    top: 0.75rem;
    left: 0.75rem;
    display: flex;
    gap: 0.25rem;
    flex-wrap: wrap;
    max-width: calc(100% - 1.5rem);
}

.stadtboote-card-badge {
    background: #020C24;
    color: #fff;
    padding: 0.2rem 0.5rem;
    font-size: 0.6875rem;
    font-weight: 600;
    border-radius: 4px;
    line-height: 1.35;
    text-transform: uppercase;
    letter-spacing: 0.035em;
    white-space: nowrap;
}

/* CPT-Badge (Boot, Floß, Tour) – eigene Farbe */
.stadtboote-card-badge-cpt {
    background: #D9C39F;
    color: #020C24;
}

.stadtboote-card-content {
    padding: 1rem;
    text-align: left;
}

.stadtboote-card-title {
    font-size: 1.125rem;
    font-weight: 700;
    margin: 0 0 0.5rem;
    color: var(--stadtboote-dark);
    line-height: 1.3;
    text-align: left;
}

.stadtboote-card-region {
    display: flex;
    align-items: center;
    gap: 0.25rem;
    font-size: 0.875rem;
    color: var(--stadtboote-secondary);
    margin: 0;
    padding-bottom: 0;
}

.stadtboote-card-region .stadtboote-icon {
    font-size: 1rem;
}

.stadtboote-card-meta {
    font-size: 0.875rem;
    color: var(--stadtboote-secondary);
    margin-bottom: 0.75rem;
}

.stadtboote-card-capacity {
    display: flex;
    align-items: center;
    gap: 0.25rem;
}

.stadtboote-card-capacity .stadtboote-icon {
    font-size: 1rem;
}

.stadtboote-card-features {
    display: flex;
    flex-wrap: wrap;
    gap: 0.375rem;
    margin-bottom: 1rem;
}

.stadtboote-feature-tag {
    background: var(--stadtboote-light);
    padding: 0.25rem 0.5rem;
    font-size: 0.75rem;
    border-radius: 3px;
    color: var(--stadtboote-dark);
}

.stadtboote-feature-more {
    background: var(--stadtboote-border);
    padding: 0.25rem 0.5rem;
    font-size: 0.75rem;
    border-radius: 3px;
    color: var(--stadtboote-secondary);
}

.stadtboote-card-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding-top: 0.75rem;
    border-top: 1px solid var(--stadtboote-border);
}

.stadtboote-card-price {
    display: flex;
    align-items: baseline;
    gap: 0.25rem;
}

.stadtboote-price-label {
    font-size: 0.75rem;
    color: var(--stadtboote-secondary);
}

.stadtboote-price-value {
    font-size: 1.25rem;
    font-weight: 700;
    color: #020C24;
}

.stadtboote-price-unit {
    font-size: 0.75rem;
    color: var(--stadtboote-secondary);
}

.stadtboote-card-cta {
    font-size: 0.875rem;
    font-weight: 600;
    color: #020C24;
}

/* ==========================================================================
   Pagination
   ========================================================================== */
.stadtboote-pagination {
    display: flex;
    justify-content: center;
    gap: 0.5rem;
    margin-top: 2rem;
}

.stadtboote-pagination .page-numbers {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 2.5rem;
    height: 2.5rem;
    padding: 0 0.75rem;
    background: #fff;
    border: 1px solid var(--stadtboote-border);
    border-radius: 4px;
    font-size: 0.9375rem;
    color: var(--stadtboote-dark);
    text-decoration: none;
    transition: var(--stadtboote-transition);
}

.stadtboote-pagination .page-numbers:hover {
    background: var(--stadtboote-light);
    border-color: var(--stadtboote-primary);
}

.stadtboote-pagination .page-numbers.current {
    background: var(--stadtboote-primary);
    border-color: var(--stadtboote-primary);
    color: #fff;
}

/* ==========================================================================
   Single / Detail View
   ========================================================================== */
.stadtboote-single-wrapper {
    padding: 2rem 0;
}

.stadtboote-breadcrumb {
    font-size: 0.875rem;
    margin-bottom: 1.5rem;
    color: var(--stadtboote-secondary);
}

.stadtboote-breadcrumb a {
    color: var(--stadtboote-secondary);
    text-decoration: none;
}

.stadtboote-breadcrumb a:hover {
    color: var(--stadtboote-primary);
}

.stadtboote-breadcrumb .separator {
    margin: 0 0.5rem;
}

.stadtboote-breadcrumb .current {
    color: var(--stadtboote-dark);
}

/* Old grid layout (deprecated) */
.stadtboote-detail-grid {
    display: grid;
    grid-template-columns: 1.2fr 1fr;
    gap: 2rem;
    margin-bottom: 2rem;
}

@media (max-width: 900px) {
    .stadtboote-detail-grid {
        grid-template-columns: 1fr;
    }
}

/* ==========================================================================
   NEW: V2 Layout with Sticky Sidebar
   ========================================================================== */
.stadtboote-detail-v2 .stadtboote-gallery-section {
    margin-bottom: 2rem;
}

.stadtboote-layout-wrapper {
    display: flex;
    gap: 2.5rem;
    align-items: flex-start;
}

@media (max-width: 1024px) {
    .stadtboote-layout-wrapper {
        flex-direction: column;
    }
}

/* Main Content Column */
.stadtboote-main-content {
    flex: 1;
    min-width: 0;
}

.stadtboote-detail-v2 .stadtboote-detail-header {
    margin-bottom: 0;
    padding-bottom: 1.5rem;
    border-bottom: none;
    position: relative;
}

/* Share Button */
.stadtboote-share-btn {
    position: absolute;
    right: 0;
    top: 0;
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.625rem 1rem;
    background: #fff;
    border: 1px solid var(--stadtboote-border);
    border-radius: 8px;
    color: var(--stadtboote-dark);
    font-size: 0.9375rem;
    font-weight: 500;
    cursor: pointer;
    transition: var(--stadtboote-transition);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
}

.stadtboote-share-btn:hover {
    background: var(--stadtboote-light);
    border-color: var(--stadtboote-primary);
    color: var(--stadtboote-primary);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.12);
}

.stadtboote-share-btn .stadtboote-icon {
    display: flex;
    align-items: center;
}

.stadtboote-share-btn-text {
    display: inline;
}

@media (max-width: 768px) {
    .stadtboote-share-btn {
        padding: 0.5rem 0.75rem;
        font-size: 0.875rem;
    }
    
    .stadtboote-share-btn-text {
        display: none;
    }
}

/* Sticky Sidebar */
.stadtboote-sidebar {
    flex: 0 0 350px;
    width: 350px;
    position: relative;
}

.stadtboote-sidebar-sticky {
    display: flex;
    flex-direction: column;
    gap: 1rem;
    position: relative;
}

.stadtboote-sidebar-box {
    background: #fff;
    border: 1px solid var(--stadtboote-border);
    border-radius: 12px;
    padding: 1.5rem;
    box-shadow: 0 6px 16px rgba(0, 0, 0, 0.12);
    /* JS will handle sticky positioning */
}

@media (max-width: 1024px) {
    .stadtboote-sidebar {
        flex: none;
        width: 100%;
        order: -1;
        margin-bottom: 2rem;
    }
}

/* Sidebar Price */
.stadtboote-sidebar-price {
    margin-bottom: 1.25rem;
    padding-bottom: 1.25rem;
    border-bottom: 1px solid var(--stadtboote-border);
}

.stadtboote-sidebar-price-prefix {
    font-size: 0.9rem;
    color: var(--stadtboote-secondary);
    margin-right: 0.25rem;
}

.stadtboote-sidebar-price-value {
    font-size: 1.75rem;
    font-weight: 700;
    color: var(--stadtboote-dark);
}

.stadtboote-sidebar-price-unit {
    font-size: 0.9rem;
    color: var(--stadtboote-secondary);
    margin-left: 0.25rem;
}

/* Sidebar Facts */
.stadtboote-sidebar-facts {
    margin-bottom: 1.25rem;
}

.stadtboote-sidebar-fact {
    display: flex;
    align-items: flex-start;
    gap: 0.75rem;
    padding: 0.6rem 0;
    border-bottom: 1px solid var(--stadtboote-border);
}

.stadtboote-sidebar-fact:last-child {
    border-bottom: none;
}

.stadtboote-sidebar-fact-icon {
    flex-shrink: 0;
}

.stadtboote-sidebar-fact-icon.stadtboote-icon {
    color: var(--stadtboote-primary);
    font-size: 1.25rem;
}

.stadtboote-sidebar-fact-content {
    flex: 1;
    min-width: 0;
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.stadtboote-sidebar-fact-label {
    font-size: 0.7rem;
    color: var(--stadtboote-secondary);
    text-transform: uppercase;
    letter-spacing: 0.5px;
    line-height: 1.2;
    margin-bottom: 2px;
}

.stadtboote-sidebar-fact-value {
    font-weight: 600;
    color: var(--stadtboote-dark);
    font-size: 0.9rem;
    line-height: 1.3;
}

/* When there's no label, center icon with value */
.stadtboote-sidebar-fact-positive {
    align-items: center;
}

.stadtboote-sidebar-fact-positive .stadtboote-sidebar-fact-icon {
    color: var(--stadtboote-success);
}

.stadtboote-sidebar-fact-positive .stadtboote-sidebar-fact-value {
    color: var(--stadtboote-success);
}

/* Sidebar CTA */
.stadtboote-sidebar-cta {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
    margin-bottom: 1.25rem;
}

.stadtboote-btn-block {
    width: 100%;
    text-align: center;
    justify-content: center;
}

.stadtboote-btn-outline {
    background: transparent;
    border: 2px solid var(--stadtboote-primary);
    color: var(--stadtboote-primary);
}

.stadtboote-btn-outline:hover {
    background: var(--stadtboote-primary);
    color: #fff;
}

/* Sidebar Anbieter */
.stadtboote-sidebar-anbieter {
    padding-top: 1rem;
    border-top: 1px solid var(--stadtboote-border);
    text-align: center;
}

.stadtboote-sidebar-anbieter-label {
    display: block;
    font-size: 0.75rem;
    color: var(--stadtboote-secondary);
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 0.25rem;
}

.stadtboote-sidebar-anbieter-logo {
    margin: 0.5rem 0;
}

.stadtboote-sidebar-anbieter-logo img {
    max-width: 120px;
    max-height: 60px;
    width: auto;
    height: auto;
    object-fit: contain;
    display: block;
    margin: 0 auto;
}

.stadtboote-sidebar-anbieter-name {
    font-weight: 600;
    color: var(--stadtboote-dark);
}

/* Sidebar PDF downloads */
.stadtboote-sidebar-downloads-heading {
    margin: 0;
    font-size: 0.75rem;
    font-weight: 600;
    color: var(--stadtboote-secondary);
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.stadtboote-sidebar-downloads .stadtboote-sidebar-downloads-items {
    list-style: none;
    list-style-type: none;
    margin: 0;
    padding: 0;
    padding-inline-start: 0;
}

.stadtboote-sidebar-downloads .stadtboote-sidebar-downloads-item {
    list-style: none;
    list-style-type: none;
    margin: 0;
    padding: 0;
}

.stadtboote-sidebar-downloads .stadtboote-sidebar-downloads-item::marker {
    content: none;
}

.stadtboote-sidebar-downloads-item + .stadtboote-sidebar-downloads-item {
    margin-top: 0.5rem;
}

.stadtboote-sidebar-downloads-link {
    display: flex;
    align-items: center;
    gap: 0.65rem;
    padding: 0.6rem 0.5rem;
    margin: 0 -0.5rem;
    border-radius: 8px;
    text-decoration: none;
    color: var(--stadtboote-dark);
    transition: background-color 0.15s ease;
}

.stadtboote-sidebar-downloads-link:hover {
    background: rgba(0, 0, 0, 0.04);
    color: var(--stadtboote-primary, #0a6ebd);
}

.stadtboote-sidebar-downloads-icon.stadtboote-icon {
    flex-shrink: 0;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    color: var(--stadtboote-primary, #0a6ebd);
}

.stadtboote-sidebar-downloads-icon.stadtboote-icon svg {
    display: block;
}

.stadtboote-sidebar-downloads-text {
    min-width: 0;
    display: flex;
    align-items: center;
}

.stadtboote-sidebar-downloads-title {
    font-weight: 600;
    font-size: 0.9rem;
    line-height: 1;
}

/* ==========================================================================
   Airbnb-Style Gallery Grid
   ========================================================================== */
.stadtboote-gallery-section {
    position: relative;
    margin-bottom: 1.5rem;
}

.stadtboote-gallery-grid {
    display: grid;
    gap: 8px;
    border-radius: 16px;
    overflow: hidden;
    position: relative;
    height: clamp(280px, 38vw, 450px);
    align-items: stretch;
    grid-auto-flow: dense;
}

/* Single image layout */
.stadtboote-gallery-grid.has-one {
    grid-template-columns: 1fr;
    grid-template-rows: 1fr;
}

/* 2 images layout */
.stadtboote-gallery-grid.has-two {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    grid-template-rows: 1fr;
}

/* 3+ images layout (2 columns: 1 large left, 2 small right) */
.stadtboote-gallery-grid.has-three {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    grid-template-rows: repeat(2, minmax(0, 1fr));
}

.stadtboote-gallery-grid.has-three .stadtboote-gallery-item-0 {
    grid-row: 1 / 3;
}

/* 4 images layout */
.stadtboote-gallery-grid.has-four {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    grid-template-rows: repeat(2, minmax(0, 1fr));
}

/* 5 images layout (1 large left, 4 small right in 2x2) */
.stadtboote-gallery-grid.has-five {
    grid-template-columns: repeat(4, minmax(0, 1fr));
    grid-template-rows: repeat(2, minmax(0, 1fr));
}

.stadtboote-gallery-grid.has-five .stadtboote-gallery-item-0 {
    grid-column: 1 / 3;
    grid-row: 1 / 3;
}

/* 8 images layout (hero + 7 tiles) */
.stadtboote-gallery-grid.has-six,
.stadtboote-gallery-grid.has-seven,
.stadtboote-gallery-grid.has-eight {
    grid-template-columns: repeat(4, minmax(0, 1fr));
    grid-template-rows: repeat(3, minmax(0, 1fr));
    height: clamp(360px, 48vw, 580px);
}

.stadtboote-gallery-grid.has-six .stadtboote-gallery-item-0,
.stadtboote-gallery-grid.has-seven .stadtboote-gallery-item-0,
.stadtboote-gallery-grid.has-eight .stadtboote-gallery-item-0 {
    grid-column: 1 / 3;
    grid-row: 1 / 3;
}

/* 6 images curated layout (no empty cells) */
.stadtboote-gallery-grid.has-six .stadtboote-gallery-item-1 {
    grid-column: 3 / 4;
    grid-row: 1 / 3;
}

.stadtboote-gallery-grid.has-six .stadtboote-gallery-item-2 {
    grid-column: 4 / 5;
    grid-row: 1 / 3;
}

.stadtboote-gallery-grid.has-six .stadtboote-gallery-item-3 {
    grid-column: 1 / 3;
    grid-row: 3 / 4;
}

.stadtboote-gallery-grid.has-six .stadtboote-gallery-item-4 {
    grid-column: 3 / 4;
    grid-row: 3 / 4;
}

.stadtboote-gallery-grid.has-six .stadtboote-gallery-item-5 {
    grid-column: 4 / 5;
    grid-row: 3 / 4;
}

/* 7 images curated layout (no empty cells) */
.stadtboote-gallery-grid.has-seven .stadtboote-gallery-item-1 {
    grid-column: 3 / 4;
    grid-row: 1 / 3;
}

.stadtboote-gallery-grid.has-seven .stadtboote-gallery-item-2 {
    grid-column: 4 / 5;
    grid-row: 1 / 3;
}

.stadtboote-gallery-grid.has-seven .stadtboote-gallery-item-3 {
    grid-column: 1 / 2;
    grid-row: 3 / 4;
}

.stadtboote-gallery-grid.has-seven .stadtboote-gallery-item-4 {
    grid-column: 2 / 3;
    grid-row: 3 / 4;
}

.stadtboote-gallery-grid.has-seven .stadtboote-gallery-item-5 {
    grid-column: 3 / 4;
    grid-row: 3 / 4;
}

.stadtboote-gallery-grid.has-seven .stadtboote-gallery-item-6 {
    grid-column: 4 / 5;
    grid-row: 3 / 4;
}

/* 8 images curated layout (no empty cells) */
.stadtboote-gallery-grid.has-eight .stadtboote-gallery-item-1 {
    grid-column: 3 / 4;
    grid-row: 1 / 3;
}

.stadtboote-gallery-grid.has-eight .stadtboote-gallery-item-2 {
    grid-column: 4 / 5;
    grid-row: 1 / 2;
}

.stadtboote-gallery-grid.has-eight .stadtboote-gallery-item-3 {
    grid-column: 4 / 5;
    grid-row: 2 / 3;
}

.stadtboote-gallery-grid.has-eight .stadtboote-gallery-item-4 {
    grid-column: 1 / 2;
    grid-row: 3 / 4;
}

.stadtboote-gallery-grid.has-eight .stadtboote-gallery-item-5 {
    grid-column: 2 / 3;
    grid-row: 3 / 4;
}

.stadtboote-gallery-grid.has-eight .stadtboote-gallery-item-6 {
    grid-column: 3 / 4;
    grid-row: 3 / 4;
}

.stadtboote-gallery-grid.has-eight .stadtboote-gallery-item-7 {
    grid-column: 4 / 5;
    grid-row: 3 / 4;
}

.stadtboote-gallery-grid.has-eight.portrait-heavy {
    grid-template-columns: repeat(5, minmax(0, 1fr));
    grid-template-rows: 3fr 3fr 2fr 2fr;
}

.stadtboote-gallery-grid.has-eight.portrait-heavy .stadtboote-gallery-item-0 {
    grid-column: 1 / 4;
    grid-row: 1 / 3;
}

.stadtboote-gallery-grid.has-eight.portrait-heavy .stadtboote-gallery-item-1 {
    grid-column: 4 / 5;
    grid-row: 1 / 3;
}

.stadtboote-gallery-grid.has-eight.portrait-heavy .stadtboote-gallery-item-2 {
    grid-column: 5 / 6;
    grid-row: 1 / 3;
}

.stadtboote-gallery-grid.has-eight.portrait-heavy .stadtboote-gallery-item-3 {
    grid-column: 1 / 2;
    grid-row: 3 / 5;
}

.stadtboote-gallery-grid.has-eight.portrait-heavy .stadtboote-gallery-item-4 {
    grid-column: 2 / 3;
    grid-row: 3 / 5;
}

.stadtboote-gallery-grid.has-eight.portrait-heavy .stadtboote-gallery-item-5 {
    grid-column: 3 / 4;
    grid-row: 3 / 5;
}

.stadtboote-gallery-grid.has-eight.portrait-heavy .stadtboote-gallery-item-6 {
    grid-column: 4 / 5;
    grid-row: 3 / 5;
}

.stadtboote-gallery-grid.has-eight.portrait-heavy .stadtboote-gallery-item-7 {
    grid-column: 5 / 6;
    grid-row: 3 / 5;
}

.stadtboote-gallery-grid.has-eight.portrait-mixed-2 {
    grid-template-columns: repeat(5, minmax(0, 1fr));
    grid-template-rows: repeat(3, minmax(0, 1fr));
}

.stadtboote-gallery-grid.has-eight.portrait-mixed-2 .stadtboote-gallery-item-0 {
    grid-column: 1 / 4;
    grid-row: 1 / 3;
}

.stadtboote-gallery-grid.has-eight.portrait-mixed-2 .stadtboote-gallery-item-1 {
    grid-column: 4 / 5;
    grid-row: 1 / 3;
}

.stadtboote-gallery-grid.has-eight.portrait-mixed-2 .stadtboote-gallery-item-2 {
    grid-column: 5 / 6;
    grid-row: 1 / 3;
}

.stadtboote-gallery-grid.has-eight.portrait-mixed-2 .stadtboote-gallery-item-3 {
    grid-column: 1 / 2;
    grid-row: 3 / 4;
}

.stadtboote-gallery-grid.has-eight.portrait-mixed-2 .stadtboote-gallery-item-4 {
    grid-column: 2 / 3;
    grid-row: 3 / 4;
}

.stadtboote-gallery-grid.has-eight.portrait-mixed-2 .stadtboote-gallery-item-5 {
    grid-column: 3 / 4;
    grid-row: 3 / 4;
}

.stadtboote-gallery-grid.has-eight.portrait-mixed-2 .stadtboote-gallery-item-6 {
    grid-column: 4 / 5;
    grid-row: 3 / 4;
}

.stadtboote-gallery-grid.has-eight.portrait-mixed-2 .stadtboote-gallery-item-7 {
    grid-column: 5 / 6;
    grid-row: 3 / 4;
}

.stadtboote-gallery-grid.has-eight.portrait-heavy-2 {
    grid-template-columns: repeat(5, minmax(0, 1fr));
    grid-template-rows: 3fr 3fr 2fr 2fr;
}

.stadtboote-gallery-grid.has-eight.portrait-heavy-2 .stadtboote-gallery-item-0 {
    grid-column: 1 / 4;
    grid-row: 1 / 3;
}

.stadtboote-gallery-grid.has-eight.portrait-heavy-2 .stadtboote-gallery-item-1 {
    grid-column: 4 / 5;
    grid-row: 1 / 3;
}

.stadtboote-gallery-grid.has-eight.portrait-heavy-2 .stadtboote-gallery-item-2 {
    grid-column: 5 / 6;
    grid-row: 1 / 3;
}

.stadtboote-gallery-grid.has-eight.portrait-heavy-2 .stadtboote-gallery-item-3 {
    grid-column: 1 / 2;
    grid-row: 3 / 5;
}

.stadtboote-gallery-grid.has-eight.portrait-heavy-2 .stadtboote-gallery-item-4 {
    grid-column: 2 / 3;
    grid-row: 3 / 5;
}

.stadtboote-gallery-grid.has-eight.portrait-heavy-2 .stadtboote-gallery-item-5 {
    grid-column: 3 / 4;
    grid-row: 3 / 5;
}

.stadtboote-gallery-grid.has-eight.portrait-heavy-2 .stadtboote-gallery-item-6 {
    grid-column: 4 / 5;
    grid-row: 3 / 5;
}

.stadtboote-gallery-grid.has-eight.portrait-heavy-2 .stadtboote-gallery-item-7 {
    grid-column: 5 / 6;
    grid-row: 3 / 5;
}

.stadtboote-gallery-grid.has-six.landscape-heavy .stadtboote-gallery-item-1 {
    grid-column: 3 / 4;
    grid-row: 1 / 2;
}

.stadtboote-gallery-grid.has-six.landscape-heavy .stadtboote-gallery-item-2 {
    grid-column: 4 / 5;
    grid-row: 1 / 2;
}

.stadtboote-gallery-grid.has-six.landscape-heavy .stadtboote-gallery-item-3 {
    grid-column: 1 / 3;
    grid-row: 3 / 4;
}

.stadtboote-gallery-grid.has-six.landscape-heavy .stadtboote-gallery-item-4 {
    grid-column: 3 / 4;
    grid-row: 2 / 4;
}

.stadtboote-gallery-grid.has-six.landscape-heavy .stadtboote-gallery-item-5 {
    grid-column: 4 / 5;
    grid-row: 2 / 4;
}

.stadtboote-gallery-grid.has-seven.landscape-heavy .stadtboote-gallery-item-1 {
    grid-column: 3 / 4;
    grid-row: 1 / 2;
}

.stadtboote-gallery-grid.has-seven.landscape-heavy .stadtboote-gallery-item-2 {
    grid-column: 4 / 5;
    grid-row: 1 / 2;
}

.stadtboote-gallery-grid.has-seven.landscape-heavy .stadtboote-gallery-item-3 {
    grid-column: 3 / 4;
    grid-row: 2 / 3;
}

.stadtboote-gallery-grid.has-seven.landscape-heavy .stadtboote-gallery-item-4 {
    grid-column: 1 / 2;
    grid-row: 3 / 4;
}

.stadtboote-gallery-grid.has-seven.landscape-heavy .stadtboote-gallery-item-5 {
    grid-column: 2 / 4;
    grid-row: 3 / 4;
}

.stadtboote-gallery-grid.has-seven.landscape-heavy .stadtboote-gallery-item-6 {
    grid-column: 4 / 5;
    grid-row: 2 / 4;
}

.stadtboote-gallery-grid.has-eight.landscape-heavy .stadtboote-gallery-item-1 {
    grid-column: 3 / 4;
    grid-row: 1 / 2;
}

.stadtboote-gallery-grid.has-eight.landscape-heavy .stadtboote-gallery-item-2 {
    grid-column: 4 / 5;
    grid-row: 1 / 2;
}

.stadtboote-gallery-grid.has-eight.landscape-heavy .stadtboote-gallery-item-3 {
    grid-column: 3 / 4;
    grid-row: 2 / 3;
}

.stadtboote-gallery-grid.has-eight.landscape-heavy .stadtboote-gallery-item-4 {
    grid-column: 1 / 2;
    grid-row: 3 / 4;
}

.stadtboote-gallery-grid.has-eight.landscape-heavy .stadtboote-gallery-item-5 {
    grid-column: 2 / 3;
    grid-row: 3 / 4;
}

.stadtboote-gallery-grid.has-eight.landscape-heavy .stadtboote-gallery-item-6 {
    grid-column: 3 / 4;
    grid-row: 3 / 4;
}

.stadtboote-gallery-grid.has-eight.landscape-heavy .stadtboote-gallery-item-7 {
    grid-column: 4 / 5;
    grid-row: 2 / 4;
}

.stadtboote-gallery-item {
    overflow: hidden;
    cursor: pointer;
    position: relative;
    background: var(--stadtboote-light);
    min-height: 0;
    align-self: stretch;
}

.stadtboote-gallery-item img {
    position: absolute;
    top: 0;
    left: 0;
    width: 100% !important;
    height: 100% !important;
    max-width: none !important;
    max-height: none !important;
    object-fit: cover;
    object-position: center;
    display: block;
    transition: transform 0.3s ease, opacity 0.3s ease;
}

.stadtboote-gallery-item:hover img {
    transform: scale(1.03);
}

.stadtboote-gallery-item::after {
    content: '';
    position: absolute;
    inset: 0;
    background: rgba(0, 0, 0, 0);
    transition: background 0.3s ease;
}

.stadtboote-gallery-item:hover::after {
    background: rgba(0, 0, 0, 0.1);
}

.stadtboote-gallery-item-more-count {
    position: absolute;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.35rem;
    font-weight: 700;
    color: #fff;
    background: rgba(0, 0, 0, 0.45);
    z-index: 2;
    pointer-events: none;
}

.stadtboote-gallery-placeholder {
    width: 100%;
    height: clamp(280px, 38vw, 450px);
    border-radius: 16px;
    background: linear-gradient(135deg, #eceff3 0%, #f8f9fa 100%);
}

/* Show all button */
.stadtboote-gallery-show-all {
    position: absolute;
    bottom: 16px;
    right: 16px;
    background: #fff;
    border: 1px solid #222;
    border-radius: 8px;
    padding: 8px 16px;
    font-size: 0.875rem;
    font-weight: 600;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 8px;
    transition: var(--stadtboote-transition);
    z-index: 10;
    color: #222;
}

.stadtboote-gallery-show-all:hover {
    background: #f7f7f7;
}

.stadtboote-gallery-show-all .stadtboote-icon {
    font-size: 1.125rem;
}

/* Responsive */
@media (max-width: 768px) {
    .stadtboote-gallery-grid {
        height: clamp(220px, 62vw, 320px);
        border-radius: 12px;
    }
    
    .stadtboote-gallery-grid.has-two,
    .stadtboote-gallery-grid.has-three,
    .stadtboote-gallery-grid.has-four,
    .stadtboote-gallery-grid.has-five {
        grid-template-columns: repeat(2, minmax(0, 1fr));
        grid-template-rows: repeat(2, minmax(0, 1fr));
    }

    .stadtboote-gallery-grid.has-six,
    .stadtboote-gallery-grid.has-seven,
    .stadtboote-gallery-grid.has-eight {
        grid-template-columns: repeat(2, minmax(0, 1fr));
        grid-template-rows: repeat(4, minmax(0, 1fr));
        height: clamp(320px, 95vw, 520px);
    }
    
    .stadtboote-gallery-grid.has-three .stadtboote-gallery-item-0,
    .stadtboote-gallery-grid.has-five .stadtboote-gallery-item-0,
    .stadtboote-gallery-grid.has-two .stadtboote-gallery-item-0 {
        grid-column: auto;
        grid-row: auto;
    }

    .stadtboote-gallery-grid.has-three .stadtboote-gallery-item-0 {
        grid-column: 1 / 3;
        grid-row: 1 / 2;
    }

    .stadtboote-gallery-grid.has-five .stadtboote-gallery-item-4 {
        display: none;
    }

    .stadtboote-gallery-grid.has-six .stadtboote-gallery-item-0 {
        grid-column: 1 / 2;
        grid-row: 1 / 2;
    }

    .stadtboote-gallery-grid.has-six .stadtboote-gallery-item-1 {
        grid-column: 2 / 3;
        grid-row: 1 / 2;
    }

    .stadtboote-gallery-grid.has-six .stadtboote-gallery-item-2 {
        grid-column: 1 / 2;
        grid-row: 2 / 3;
    }

    .stadtboote-gallery-grid.has-six .stadtboote-gallery-item-3 {
        grid-column: 2 / 3;
        grid-row: 2 / 3;
    }

    .stadtboote-gallery-grid.has-six .stadtboote-gallery-item-4 {
        grid-column: 1 / 3;
        grid-row: 3 / 4;
    }

    .stadtboote-gallery-grid.has-six .stadtboote-gallery-item-5 {
        grid-column: 1 / 3;
        grid-row: 4 / 5;
    }

    .stadtboote-gallery-grid.has-seven .stadtboote-gallery-item-0 {
        grid-column: 1 / 2;
        grid-row: 1 / 2;
    }

    .stadtboote-gallery-grid.has-seven .stadtboote-gallery-item-1 {
        grid-column: 2 / 3;
        grid-row: 1 / 2;
    }

    .stadtboote-gallery-grid.has-seven .stadtboote-gallery-item-2 {
        grid-column: 1 / 2;
        grid-row: 2 / 3;
    }

    .stadtboote-gallery-grid.has-seven .stadtboote-gallery-item-3 {
        grid-column: 2 / 3;
        grid-row: 2 / 3;
    }

    .stadtboote-gallery-grid.has-seven .stadtboote-gallery-item-4 {
        grid-column: 1 / 2;
        grid-row: 3 / 4;
    }

    .stadtboote-gallery-grid.has-seven .stadtboote-gallery-item-5 {
        grid-column: 2 / 3;
        grid-row: 3 / 4;
    }

    .stadtboote-gallery-grid.has-seven .stadtboote-gallery-item-6 {
        grid-column: 1 / 3;
        grid-row: 4 / 5;
    }

    .stadtboote-gallery-item-more-count {
        font-size: 1.05rem;
    }
    
    .stadtboote-gallery-show-all {
        bottom: 12px;
        right: 12px;
        padding: 6px 14px;
        font-size: 0.8rem;
    }

    .stadtboote-gallery-placeholder {
        height: clamp(220px, 62vw, 320px);
        border-radius: 12px;
    }
}

/* Main image + thumbnails gallery (mobile only) */
.stadtboote-gallery-mobile {
    display: none;
}

.stadtboote-gallery-desktop {
    display: block;
}

.stadtboote-gallery-mobile .stadtboote-detail-gallery {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.stadtboote-gallery-mobile .stadtboote-gallery-main {
    border-radius: 14px;
    overflow: hidden;
    cursor: zoom-in;
    position: relative;
    aspect-ratio: 16 / 9;
    background: var(--stadtboote-light);
}

.stadtboote-gallery-mobile .stadtboote-gallery-main img {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    max-width: none !important;
    max-height: none !important;
    object-fit: cover;
    display: block;
    opacity: 1;
    transform: scale(1);
    animation: stadtbooteKenBurns 6s cubic-bezier(0.25, 0, 0.35, 1) infinite alternate;
}

@keyframes stadtbooteKenBurns {
    0%   { transform: scale(1); }
    100% { transform: scale(1.08); }
}

.stadtboote-gallery-mobile .stadtboote-main-image-fadeout {
    width: 100% !important;
    height: 100% !important;
    max-width: none !important;
    max-height: none !important;
    object-fit: cover;
    object-position: center;
    display: block;
    pointer-events: none;
    opacity: 1;
    transition: opacity 0.45s ease;
}

.stadtboote-gallery-mobile .stadtboote-gallery-thumbs {
    display: flex;
    gap: 0.5rem;
    overflow-x: auto;
    overflow-y: hidden;
    padding: 0.1rem 0 0.25rem;
    scrollbar-width: thin;
    -webkit-overflow-scrolling: touch;
    scroll-snap-type: x proximity;
}

.stadtboote-gallery-mobile .stadtboote-thumb {
    appearance: none;
    -webkit-appearance: none;
    flex: 0 0 auto;
    width: 88px;
    aspect-ratio: 4 / 3;
    height: auto;
    scroll-snap-align: center;
    border-radius: 8px;
    overflow: hidden;
    cursor: pointer;
    opacity: 0.72;
    transition: var(--stadtboote-transition);
    border: 2px solid transparent;
    padding: 0;
    background: transparent;
    position: relative;
}

.stadtboote-gallery-mobile .stadtboote-thumb:hover {
    opacity: 0.92;
}

.stadtboote-gallery-mobile .stadtboote-thumb.active {
    opacity: 1;
    border-color: var(--stadtboote-primary);
    box-shadow: 0 0 0 1px rgba(2, 12, 36, 0.25);
}

.stadtboote-gallery-mobile .stadtboote-thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

@media (max-width: 768px) {
    .stadtboote-gallery-desktop {
        display: none;
    }

    .stadtboote-gallery-mobile {
        display: block;
    }

    .stadtboote-gallery-mobile .stadtboote-gallery-main {
        aspect-ratio: 4 / 3;
    }

    .stadtboote-gallery-mobile .stadtboote-thumb {
        flex: 0 0 auto;
        width: 80px;
        aspect-ratio: 4 / 3;
        height: auto;
    }
}

/* ==========================================================================
   Lightbox
   ========================================================================== */
.stadtboote-lightbox {
    position: fixed;
    inset: 0;
    z-index: 999999;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.3s ease, visibility 0.3s ease;
}

.stadtboote-lightbox.active {
    opacity: 1;
    visibility: visible;
}

.stadtboote-lightbox-overlay {
    position: absolute;
    inset: 0;
    background: rgba(0, 0, 0, 0.9);
    cursor: pointer;
}

.stadtboote-lightbox-content {
    position: relative;
    max-width: 90vw;
    max-height: 90vh;
    z-index: 1;
}

.stadtboote-lightbox-image {
    max-width: 90vw;
    max-height: 85vh;
    object-fit: contain;
    display: block;
    border-radius: 4px;
}

.stadtboote-lightbox-close {
    position: absolute;
    top: -40px;
    right: 0;
    width: 36px;
    height: 36px;
    background: transparent;
    border: none;
    color: #fff;
    font-size: 32px;
    cursor: pointer;
    opacity: 0.8;
    transition: opacity 0.2s;
    line-height: 1;
}

.stadtboote-lightbox-close:hover {
    opacity: 1;
}

.stadtboote-lightbox-prev,
.stadtboote-lightbox-next {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    width: 50px;
    height: 50px;
    background: rgba(255, 255, 255, 0.1);
    border: none;
    color: #fff;
    font-size: 24px;
    cursor: pointer;
    border-radius: 50%;
    opacity: 0.8;
    transition: all 0.2s;
}

.stadtboote-lightbox-prev:hover,
.stadtboote-lightbox-next:hover {
    opacity: 1;
    background: rgba(255, 255, 255, 0.2);
}

.stadtboote-lightbox-prev {
    left: -70px;
}

.stadtboote-lightbox-next {
    right: -70px;
}

.stadtboote-lightbox-counter {
    text-align: center;
    color: #fff;
    font-size: 14px;
    margin-top: 15px;
    opacity: 0.8;
}

body.stadtboote-lightbox-open {
    overflow: hidden;
}

@media (max-width: 768px) {
    .stadtboote-lightbox-prev {
        left: 10px;
    }
    
    .stadtboote-lightbox-next {
        right: 10px;
    }
    
    .stadtboote-lightbox-prev,
    .stadtboote-lightbox-next {
        width: 40px;
        height: 40px;
        font-size: 20px;
        background: rgba(0, 0, 0, 0.5);
    }
    
    .stadtboote-lightbox-close {
        top: 10px;
        right: 10px;
    }
}

/* Detail Info */
.stadtboote-detail-header {
    margin-bottom: 1.5rem;
}

.stadtboote-type-badges {
    display: flex;
    flex-wrap: wrap;
    gap: 0.25rem;
    margin-bottom: 0.75rem;
}

.stadtboote-type-badge {
    display: inline-block;
    background: #020C24;
    color: #fff;
    padding: 0.2rem 0.5rem;
    font-size: 0.6875rem;
    font-weight: 600;
    border-radius: 4px;
    line-height: 1.35;
    text-transform: uppercase;
    letter-spacing: 0.035em;
}

.stadtboote-detail-title {
    font-size: 2rem;
    font-weight: 700;
    margin: 0 0 0.5rem;
    line-height: 1.2;
}

.stadtboote-detail-location,
.stadtboote-detail-anbieter {
    display: flex;
    align-items: center;
    gap: 0.375rem;
    font-size: 0.9375rem;
    color: var(--stadtboote-secondary);
    margin: 0.25rem 0;
    padding-bottom: 0;
}

.stadtboote-detail-location .stadtboote-icon {
    font-size: 1.125rem;
}

/* Sehenswürdigkeiten Tags */
.stadtboote-sehenswuerdigkeiten-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    margin-top: 1rem;
}

.stadtboote-sehenswuerdigkeit-tag {
    display: inline-flex;
    align-items: center;
    padding: 0 0.75rem;
    height: 30px;
    background: var(--stadtboote-light);
    color: var(--stadtboote-text);
    font-size: 0.8125rem;
    font-weight: 500;
    border-radius: 5px;
    border: 1px solid var(--stadtboote-border);
    transition: var(--stadtboote-transition);
}

.stadtboote-sehenswuerdigkeit-tag:hover {
    background: var(--stadtboote-primary);
    color: #fff;
    border-color: var(--stadtboote-primary);
}

/* Price Box */
.stadtboote-price-box {
    background: var(--stadtboote-light);
    padding: 1.25rem;
    border-radius: var(--stadtboote-radius);
    margin-bottom: 1.5rem;
}

.stadtboote-price-main {
    display: flex;
    align-items: baseline;
    gap: 0.375rem;
}

.stadtboote-price-box .stadtboote-price-value {
    font-size: 1.75rem;
}

.stadtboote-kaution {
    font-size: 0.875rem;
    color: var(--stadtboote-secondary);
    margin: 0.5rem 0 0;
}

/* Key Facts */
.stadtboote-key-facts {
    display: flex;
    flex-wrap: wrap;
    gap: 1rem;
    margin-bottom: 1.5rem;
}

.stadtboote-fact {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.5rem 0.75rem;
    background: var(--stadtboote-light);
    border-radius: 4px;
    font-size: 0.875rem;
}

.stadtboote-fact .stadtboote-icon {
    color: var(--stadtboote-primary);
    font-size: 1.25rem;
}

.stadtboote-fact-label {
    color: var(--stadtboote-secondary);
}

.stadtboote-fact-value {
    font-weight: 600;
    color: var(--stadtboote-dark);
}

.stadtboote-fact-positive {
    background: rgba(40, 167, 69, 0.1);
}

.stadtboote-fact-positive .stadtboote-icon {
    color: var(--stadtboote-success);
}

/* CTA Buttons */
.stadtboote-cta-buttons {
    display: flex;
    flex-wrap: wrap;
    gap: 0.75rem;
}

/* Content Sections */
.stadtboote-detail-content {
    max-width: 800px;
}

.stadtboote-section {
    margin-bottom: 2.5rem;
}

.stadtboote-section h2 {
    font-size: 1.375rem;
    font-weight: 700;
    margin: 0 0 1rem;
    padding-bottom: 0.5rem;
    border-bottom: 1px solid #DFE2E6;
}

.stadtboote-description {
    font-size: 1rem;
    line-height: 1.7;
}

/* Video unter der Beschreibung */
.stadtboote-video-section {
    margin-top: 0;
}

.stadtboote-video-section .stadtboote-video-wrapper {
    width: 100%;
    max-width: 100%;
    border-radius: 12px;
    overflow: hidden;
    background: #000;
    border: 1px solid var(--stadtboote-border);
    position: relative;
    aspect-ratio: 16 / 9;
}

.stadtboote-video-section .stadtboote-video-player {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: cover;
    vertical-align: middle;
}

/* YouTube Embed */
.stadtboote-video-section .stadtboote-video-youtube iframe {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    border: 0;
}

/* Anbieter im Hauptinhalt – Layout */
.stadtboote-anbieter-card {
    margin: 0;
    padding-top: 0.25rem;
}

.stadtboote-anbieter-card-header {
    display: inline-block;
    text-decoration: none;
    color: var(--stadtboote-dark, #020C24);
    margin-bottom: 1rem;
    transition: opacity 0.2s;
}

.stadtboote-anbieter-card-header:hover {
    opacity: 0.85;
}

.stadtboote-anbieter-card-logo {
    flex-shrink: 0;
}

.stadtboote-anbieter-card-logo img {
    max-width: 120px;
    max-height: 56px;
    width: auto;
    height: auto;
    object-fit: contain;
    display: block;
}

.stadtboote-anbieter-card-name {
    font-weight: 700;
    font-size: 1.375rem;
    letter-spacing: -0.02em;
    line-height: 1.25;
}

.stadtboote-anbieter-card-contact {
    display: grid;
    grid-template-columns: 1fr;
    gap: 0.75rem 0;
}

.stadtboote-anbieter-card-contact p {
    margin: 0 !important;
    padding: 0 !important;
}

.stadtboote-anbieter-contact-logo {
    display: flex;
    align-items: flex-start;
}

.stadtboote-anbieter-contact-logo img {
    max-width: 120px;
    max-height: 56px;
    width: auto;
    height: auto;
    object-fit: contain;
    display: block;
}

.stadtboote-anbieter-contact-right {
    display: flex;
    flex-direction: column;
    gap: 0;
}

@media (min-width: 560px) {
    .stadtboote-anbieter-card-contact {
        grid-template-columns: 1.5fr 1fr 1fr;
        column-gap: 1.5rem;
        row-gap: 0;
        align-items: start;
    }

    .stadtboote-anbieter-contact-address {
        grid-column: 1;
        padding-right: 1rem;
    }

    .stadtboote-anbieter-contact-right {
        grid-column: 2;
    }

    .stadtboote-anbieter-contact-logo {
        grid-column: 3;
    }
}

.stadtboote-anbieter-contact-row {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    margin: 0;
    padding: 0;
    font-size: 0.9375rem;
    line-height: 1.2;
    color: var(--stadtboote-dark, #020C24);
    min-height: 0;
}

.stadtboote-anbieter-contact-right .stadtboote-anbieter-contact-row {
    line-height: 1.6;
    padding-bottom: 0 !important;
}

.stadtboote-anbieter-address {
    line-height: 1.6;
    align-items: flex-start;
}

.stadtboote-anbieter-address .stadtboote-icon {
    margin-top: 0.2em;
}

.stadtboote-anbieter-contact-row .stadtboote-icon {
    flex-shrink: 0;
    margin: 0;
    width: 20px;
    height: 20px;
    color: var(--stadtboote-secondary, #6b7280);
}

.stadtboote-anbieter-contact-row .stadtboote-icon svg {
    width: 20px;
    height: 20px;
}

.stadtboote-anbieter-contact-row span,
.stadtboote-anbieter-contact-row a {
    color: inherit;
    text-decoration: none;
    word-break: break-word;
}

.stadtboote-anbieter-contact-row a:hover {
    text-decoration: underline;
}

.stadtboote-highlights-list {
    list-style: none;
    padding: 0;
    margin: 0;
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 0.5rem 1.5rem;
}

@media (max-width: 768px) {
    .stadtboote-highlights-list {
        grid-template-columns: 1fr;
    }
}

.stadtboote-highlights-list li {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.25rem 0;
}

.stadtboote-highlights-list .stadtboote-icon {
    color: var(--stadtboote-success);
    flex-shrink: 0;
    font-size: 1.25rem;
}

.stadtboote-features-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
    gap: 0.75rem;
}

.stadtboote-feature-item {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.625rem 0.875rem;
    background: var(--stadtboote-light);
    border-radius: 4px;
    font-size: 0.9375rem;
}

/* ==========================================================================
   Zusätzliche Ausstattungen (Airbnb Style Pills)
   ========================================================================== */
.stadtboote-ausstattungen-section {
    margin-bottom: 2rem;
}

.stadtboote-ausstattungen-grid {
    display: flex;
    flex-wrap: wrap;
    gap: 0.75rem;
}

.stadtboote-ausstattung-pill {
    display: inline-flex;
    align-items: center;
    gap: 0.625rem;
    padding: 0.75rem 1.25rem;
    border: 1px solid var(--stadtboote-border);
    border-radius: 24px;
    font-size: 0.9375rem;
    color: var(--stadtboote-dark);
    background: #fff;
    transition: var(--stadtboote-transition);
}

.stadtboote-ausstattung-pill:hover {
    border-color: var(--stadtboote-secondary);
    background: var(--stadtboote-light);
}

.stadtboote-ausstattung-pill .stadtboote-icon {
    color: var(--stadtboote-secondary);
    width: 20px;
    height: 20px;
    flex-shrink: 0;
}

.stadtboote-ausstattung-pill .stadtboote-icon svg,
.stadtboote-ausstattung-pill .stadtboote-icon img {
    width: 20px;
    height: 20px;
    object-fit: contain;
}

@media (max-width: 480px) {
    .stadtboote-ausstattung-pill {
        padding: 0.625rem 1rem;
        font-size: 0.875rem;
    }
    
    .stadtboote-ausstattung-pill .stadtboote-icon,
    .stadtboote-ausstattung-pill .stadtboote-icon svg,
    .stadtboote-ausstattung-pill .stadtboote-icon img {
        width: 18px;
        height: 18px;
    }
}

.stadtboote-feature-item .stadtboote-icon {
    color: var(--stadtboote-success);
    font-size: 1.125rem;
}

/* Inquiry Form */
.stadtboote-inquiry-form {
    background: var(--stadtboote-light);
    padding: 1.5rem;
    border-radius: var(--stadtboote-radius);
}

.stadtboote-form-placeholder {
    text-align: center;
    color: var(--stadtboote-secondary);
    margin: 0;
}

/* ==========================================================================
   Archive Header
   ========================================================================== */
.stadtboote-archive-header {
    text-align: center;
    margin-bottom: 2rem;
    padding-bottom: 1.5rem;
    border-bottom: 1px solid var(--stadtboote-border);
}

.stadtboote-archive-title {
    font-size: 2.25rem;
    font-weight: 700;
    margin: 0 0 0.75rem;
}

.stadtboote-archive-description {
    font-size: 1.125rem;
    color: var(--stadtboote-secondary);
    margin: 0;
    max-width: 600px;
    margin-left: auto;
    margin-right: auto;
}

/* ==========================================================================
   Loading State
   ========================================================================== */
.stadtboote-loading {
    position: relative;
    pointer-events: none;
}

.stadtboote-loading::after {
    content: '';
    position: absolute;
    inset: 0;
    background: rgba(255, 255, 255, 0.7);
    display: flex;
    align-items: center;
    justify-content: center;
}

.stadtboote-spinner {
    width: 40px;
    height: 40px;
    border: 3px solid var(--stadtboote-light);
    border-top-color: var(--stadtboote-primary);
    border-radius: 50%;
    animation: stadtboote-spin 0.8s linear infinite;
}

@keyframes stadtboote-spin {
    to {
        transform: rotate(360deg);
    }
}

/* ==========================================================================
   Liegeplatz Section
   ========================================================================== */
.stadtboote-liegeplatz-section {
    margin-bottom: 2.5rem;
}

.stadtboote-liegeplatz-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    margin-bottom: 1rem;
    flex-wrap: wrap;
}

.stadtboote-liegeplatz-adresse {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.9rem;
    color: var(--stadtboote-dark);
    margin: 0;
    padding: 0;
    line-height: 1.4;
}

.stadtboote-liegeplatz-adresse .stadtboote-icon {
    color: var(--stadtboote-primary);
    font-size: 1.25rem;
}

.stadtboote-btn-small {
    padding: 0.4rem 0.75rem;
    font-size: 0.8rem;
}

.stadtboote-btn-small .stadtboote-icon {
    font-size: 0.9rem;
}

.stadtboote-liegeplatz-map-wrapper {
    margin-bottom: 1rem;
    border-radius: var(--stadtboote-radius);
    overflow: hidden;
    box-shadow: var(--stadtboote-shadow);
}

.stadtboote-frontend-map {
    width: 100%;
    height: 300px;
    background: var(--stadtboote-light);
}

@media (min-width: 768px) {
    .stadtboote-frontend-map {
        height: 350px;
    }
}

/* ==========================================================================
   Tour Route Section
   ========================================================================== */
.stadtboote-route-section {
    margin-bottom: 2.5rem;
}

.stadtboote-route-info {
    margin-bottom: 1.5rem;
}

.stadtboote-route-stops-list {
    list-style: none;
    padding: 0;
    margin: 0;
    position: relative;
}

.stadtboote-route-stops-list::before {
    content: '';
    position: absolute;
    left: 12px;
    top: 24px;
    bottom: 24px;
    width: 2px;
    background: linear-gradient(to bottom, var(--stadtboote-primary) 0%, var(--stadtboote-primary) 100%);
    border-radius: 1px;
}

.stadtboote-route-stop-item {
    display: flex;
    align-items: center;
    gap: 1rem;
    padding: 0.75rem 0;
    position: relative;
}

.stadtboote-route-stop-item .stadtboote-route-icon {
    width: 24px;
    height: 24px;
    flex-shrink: 0;
    background: white;
    position: relative;
    z-index: 1;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
}

.stadtboote-route-stop-item .stadtboote-route-icon svg {
    width: 18px;
    height: 18px;
    color: var(--stadtboote-primary);
}

.stadtboote-route-start .stadtboote-route-icon svg {
    color: #28a745;
}

.stadtboote-route-end .stadtboote-route-icon svg {
    color: #dc3545;
}

.stadtboote-route-stop-name {
    flex: 1;
    font-weight: 500;
    color: var(--stadtboote-text);
}

.stadtboote-route-stop-label {
    font-size: 0.8rem;
    color: var(--stadtboote-muted);
    background: var(--stadtboote-light);
    padding: 0.25rem 0.5rem;
    border-radius: var(--stadtboote-radius-sm);
}

.stadtboote-route-map-wrapper {
    margin-bottom: 1rem;
    border-radius: var(--stadtboote-radius);
    overflow: hidden;
    box-shadow: var(--stadtboote-shadow);
}

.stadtboote-tour-route-map {
    height: 350px;
}

@media (min-width: 768px) {
    .stadtboote-tour-route-map {
        height: 400px;
    }
}

/* Route Map InfoWindow Styles */
.stadtboote-route-marker-info {
    padding: 8px 12px;
    min-width: 120px;
    max-width: 250px;
    font-family: var(--stadtboote-font-family, -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif);
}

.stadtboote-route-marker-info strong {
    display: block;
    font-size: 14px;
    font-weight: 600;
    color: #1a1a1a;
    line-height: 1.4;
    white-space: nowrap;
}

.stadtboote-route-marker-info small {
    display: block;
    font-size: 12px;
    color: #666;
    margin-top: 0px;
}

.stadtboote-route-marker-info br {
    height: 1px;
}

/* Override Google Maps InfoWindow default styles */
.gm-style-iw-c {
    padding: 0 !important;
    border-radius: 8px !important;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15) !important;
}

.gm-style-iw-d {
    overflow: visible !important;
    max-height: none !important;
}

.gm-style-iw-tc::after {
    background: #fff !important;
}

/* Map Popup Styles */
.stadtboote-map-popup {
    width: 280px;
    font-family: var(--stadtboote-font-family, -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif);
    position: relative;
    padding-bottom: 12px;
}

/* Arrow/Zipfel at bottom of popup */
.stadtboote-map-popup::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 0;
    height: 0;
    border-left: 12px solid transparent;
    border-right: 12px solid transparent;
    border-top: 12px solid #fff;
}

.stadtboote-map-popup-image {
    position: relative;
    width: 100%;
    height: 180px;
    overflow: hidden;
    border-radius: 16px 16px 0 0;
}

.stadtboote-map-popup-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.stadtboote-map-popup-badge {
    position: absolute;
    top: 12px;
    left: 12px;
    background: #0066cc;
    color: #fff;
    font-size: 0.75rem;
    font-weight: 600;
    padding: 0.375rem 0.75rem;
    border-radius: 6px;
    text-transform: uppercase;
    letter-spacing: 0.025em;
}

.stadtboote-map-popup-content {
    padding: 12px;
    padding-bottom: 0;
}

.stadtboote-map-popup-title {
    font-size: 1.125rem;
    font-weight: 700;
    color: #1a1a1a;
    margin: 0 0 0.25rem;
    line-height: 1.3;
}

.stadtboote-map-popup-region {
    font-size: 0.875rem;
    color: #6b7280;
    margin: 0;
}

.stadtboote-map-popup-price {
    font-size: 1.25rem;
    font-weight: 700;
    color: #1a1a1a;
    margin: 0 0 1rem;
}

.stadtboote-map-popup-price span {
    font-size: 0.875rem;
    font-weight: 400;
    color: #6b7280;
}

.stadtboote-map-popup-btn {
    display: block;
    width: 100%;
    padding: 0.75rem 1rem;
    background: #0066cc;
    color: #fff !important;
    font-size: 0.9375rem;
    font-weight: 600;
    text-align: center;
    text-decoration: none !important;
    border-radius: 8px;
    transition: background 0.2s ease;
    box-sizing: border-box;
}

.stadtboote-map-popup-btn:hover {
    background: #0052a3;
    color: #fff !important;
    text-decoration: none !important;
}

/* Override Google Maps InfoWindow styles */
.gm-style .gm-style-iw-c {
    padding: 0 !important;
    padding-top: 0 !important;
    border-radius: 16px !important;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.15) !important;
    max-width: 320px !important;
    max-height: none !important;
}

.gm-style .gm-style-iw-d {
    overflow: visible !important;
    overflow-y: visible !important;
    overflow-x: visible !important;
    max-height: none !important;
    max-width: none !important;
    padding: 0 !important;
}

.gm-style .gm-style-iw-d > div {
    max-height: none !important;
}

.gm-style .gm-style-iw-tc::after,
.gm-style .gm-style-iw-t::after {
    display: none !important;
}

/* Hide the arrow/tail of InfoWindow */
.gm-style .gm-style-iw-tc {
    display: none !important;
}

/* Position close button on top of image */
.gm-style .gm-style-iw-c > button.gm-ui-hover-effect {
    position: absolute !important;
    top: 8px !important;
    right: 8px !important;
    z-index: 100 !important;
    background: rgba(255, 255, 255, 0.9) !important;
    border-radius: 50% !important;
    width: 32px !important;
    height: 32px !important;
    opacity: 1 !important;
}

.gm-style .gm-style-iw-c > button.gm-ui-hover-effect > span {
    margin: 6px !important;
}

/* Remove the header area that creates white space */
.gm-style .gm-style-iw-chr {
    display: none !important;
}

.stadtboote-liegeplatz-header .stadtboote-btn {
    display: inline-flex;
    align-items: center;
    gap: 0.375rem;
    flex-shrink: 0;
}

/* ==========================================================================
   Technische Details Section
   ========================================================================== */
.stadtboote-tech-section {
    margin-bottom: 2.5rem;
}

.stadtboote-tech-details {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 0 3rem;
}

@media (max-width: 768px) {
    .stadtboote-tech-details {
        grid-template-columns: 1fr;
        gap: 0;
    }
}

.stadtboote-tech-column {
    display: flex;
    flex-direction: column;
}

.stadtboote-tech-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0.5rem 0;
    border-bottom: 1px solid var(--stadtboote-border);
    font-size: 0.9rem;
}

.stadtboote-tech-row:last-child {
    border-bottom: none;
}

@media (max-width: 768px) {
    .stadtboote-tech-row:last-child {
        border-bottom: 1px solid var(--stadtboote-border);
    }
    
    .stadtboote-tech-column:last-child .stadtboote-tech-row:last-child {
        border-bottom: none;
    }
}

.stadtboote-tech-label {
    font-weight: 600;
    color: var(--stadtboote-dark);
}

.stadtboote-tech-value {
    color: var(--stadtboote-text);
    text-align: right;
}

/* ==========================================================================
   Similar Boats Section
   ========================================================================== */
.stadtboote-similar-section {
    padding: 3rem 0;
    margin-top: 3rem;
}

@media (max-width: 768px) {
    /* Gleiche nutzbare Breite wie .stadtboote-main-content – kein doppeltes .container */
    .stadtboote-similar-section .container {
        width: 100%;
        max-width: 100%;
        padding-left: 0;
        padding-right: 0;
    }
}

.stadtboote-similar-section h2 {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--stadtboote-dark);
    margin: 0 0 1.5rem;
    padding-bottom: 0.5rem;
    border-bottom: 1px solid #DFE2E6;
}

.stadtboote-similar-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1.5rem;
}

@media (max-width: 992px) {
    .stadtboote-similar-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 576px) {
    .stadtboote-similar-grid {
        grid-template-columns: 1fr;
    }
}

/* Similar cards now use .stadtboote-card styles */
.stadtboote-similar-grid .stadtboote-card {
    /* Cards inherit all styles from .stadtboote-card */
}

/* ==========================================================================
   Inquiry Modal
   ========================================================================== */
.stadtboote-modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 99999;
    align-items: center;
    justify-content: center;
    padding: 1rem;
}

.stadtboote-modal.active {
    display: flex;
}

.stadtboote-modal-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.6);
    backdrop-filter: blur(4px);
}

.stadtboote-modal-content {
    position: relative;
    background: #fff;
    border-radius: var(--stadtboote-radius);
    max-width: 750px;
    width: 100%;
    max-height: 90vh;
    overflow-y: auto;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
    animation: stadtboote-modal-appear 0.3s ease;
}

@keyframes stadtboote-modal-appear {
    from {
        opacity: 0;
        transform: translateY(-20px) scale(0.95);
    }
    to {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

.stadtboote-modal-close {
    position: absolute;
    top: 1rem;
    right: 1rem;
    width: 40px;
    height: 40px;
    border: none;
    background: var(--stadtboote-light);
    border-radius: 50%;
    font-size: 1.5rem;
    line-height: 1;
    cursor: pointer;
    color: var(--stadtboote-secondary);
    transition: var(--stadtboote-transition);
    z-index: 10;
}

.stadtboote-modal-close:hover {
    background: var(--stadtboote-dark);
    color: #fff;
}

.stadtboote-modal-header {
    padding: 2rem 2rem 1rem;
    border-bottom: 1px solid var(--stadtboote-border);
}

.stadtboote-modal-header h2 {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--stadtboote-dark);
    margin: 0 0 0.25rem;
}

.stadtboote-modal-subtitle {
    font-size: 0.9rem;
    color: var(--stadtboote-secondary);
    margin: 0;
}

.stadtboote-modal-body {
    padding: 0 2rem 2rem;
}

body.stadtboote-modal-open {
    overflow: hidden;
}

/* Zusätzlich: Theme-Scroll-Container sperren (Fallback) */
body.stadtboote-modal-open #ajax-content-wrap,
body.stadtboote-modal-open .ocm-effect-wrap-inner,
body.stadtboote-modal-open .ocm-effect-wrap {
    overflow: hidden !important;
    touch-action: none;
}

/* Modal form styling adjustments */
.stadtboote-modal .stadtboote-inquiry-form {
    padding: 0;
}

@media (max-width: 576px) {
    .stadtboote-modal-content {
        max-height: 95vh;
    }
    
    .stadtboote-modal-header {
        padding: 1.5rem 1.5rem 1rem;
    }
    
    .stadtboote-modal-body {
        padding: 1rem 1.5rem 1.5rem;
    }
    
    .stadtboote-modal-close {
        top: 0.75rem;
        right: 0.75rem;
    }
}
