/* Mitgliederliste Block */
.blv-mitgliederliste-container {
    margin: 30px 0;
}

.blv-mitglieder-table {
    width: 100%;
    border-collapse: collapse;
    margin-bottom: 20px;
    background: #fff;
    border-radius: 8px;
    overflow: hidden;
}

.blv-mitgliederliste-container:not(.has-background):not(.has-border-color) .blv-mitglieder-table {
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.05);
}

/* If block has background color, make table transparent to show it */
.blv-mitgliederliste-container.has-background .blv-mitglieder-table {
    background: transparent;
}

.blv-mitglieder-table th,
.blv-mitglieder-table td {
    padding: 12px 15px;
    text-align: left;
    border-bottom: 1px solid #eee;
}

.blv-mitglieder-table th {
    background-color: #f8f9fa;
    font-weight: 700;
    color: #333;
    text-transform: uppercase;
    font-size: 0.85rem;
    letter-spacing: 0.05em;
}

.blv-mitglieder-table tr:last-child td {
    border-bottom: none;
}

.blv-mitglieder-table tr:hover {
    background-color: rgba(0, 0, 0, 0.02);
}

/* Stripes Style */
.is-style-stripes .blv-mitglieder-table tbody tr:nth-child(odd) {
    background-color: rgba(0, 0, 0, 0.05);
}

/* Ensure padding from block supports is applied correctly to the wrapper */
.blv-mitgliederliste-container {
    box-sizing: border-box;
}

.blv-load-more-container {
    text-align: center;
    margin-top: 20px;
}

.blv-load-more-link {
    display: inline-block;
    color: #007cba;
    text-decoration: underline;
    font-size: 0.95rem;
    cursor: pointer;
    transition: color 0.2s;
}

.blv-load-more-link:hover {
    color: #006799;
    text-decoration: none;
}

.blv-load-more-link.is-loading {
    opacity: 0.6;
    cursor: not-allowed;
    text-decoration: none;
}

/* BLV Lehrstellenportal Blocks Styling */

.blv-lehrstellen-portal {
    max-width: 100%;
    margin-bottom: 30px;
}

.blv-filter-form {
    margin-bottom: 30px;
}

.blv-filter-form label {
    font-weight: bold;
    margin-right: 10px;
}

.blv-filter-form select {
    padding: 8px;
    border-radius: 4px;
    border: 1px solid #ccc;
}

.blv-filter-form select:focus {
    border-color: #007cba;
    outline: none;
}

.blv-results-counter {
    margin: 20px 0;
    font-size: 1.1rem;
    color: #444;
    padding-bottom: 10px;
}

/* Lehrstellen List View */
.blv-lehrstellen-list {
    display: flex;
    flex-direction: column;
    gap: 15px;
    max-width: 100%;
}

.blv-lehrstelle-row {
    display: flex;
    align-items: center;
    border: 1px solid #eee;
    padding: 15px 25px;
    border-radius: 8px;
    background: #fff;
    transition: border-color 0.2s;
    flex-wrap: nowrap;
    max-width: 100%;
    box-sizing: border-box;
}


.blv-logo-cell {
    width: 80px;
    height: 80px;
    flex-shrink: 0;
    margin-right: 25px;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    background: #f0f0f0;
    border-radius: 4px;
}

.blv-logo-cell img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    display: block;
}

.blv-info-cell {
    flex-grow: 1;
    min-width: 0;
}

.blv-info-cell h3 {
    margin: 0 0 5px 0;
    font-size: 1.2rem;
    color: #333;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.blv-info-meta {
    font-size: 0.95rem;
    color: #666;
    display: flex;
    flex-wrap: wrap;
    gap: 15px;
}

.blv-info-meta a {
    color: inherit;
    text-decoration: underline;
}

.blv-action-cell {
    margin-left: 20px;
    flex-shrink: 0;
}

/* Ensure the WP block buttons groups layout correctly */
.blv-action-cell .wp-block-buttons {
    display: flex;
    gap: 10px;
    justify-content: flex-end;
}

/* Base styles for the button links to ensure consistent 'standard' size */
.blv-action-cell .wp-block-button__link {
    font-size: 0.95rem !important;
    padding: 10px 22px !important;
    line-height: 1.2;
    text-decoration: none !important;
    white-space: nowrap;
    border-radius: 6px;
    /* A sensible default that works with most themes */
}

/* Bewerbung Info Block - Clean Header Style */
.blv-bewerbung-info-clean {
    margin-bottom: 50px;
    padding-bottom: 30px;
    border-bottom: 2px solid #f0f0f0;
}

.blv-bewerbung-header-flex {
    display: flex;
    align-items: center;
    gap: 30px;
}

.blv-bewerbung-h1 {
    margin: 0 0 10px 0 !important;
    font-size: 2.5rem !important;
    color: #1d2327 !important;
    line-height: 1.1;
    font-weight: 800;
}

.blv-bewerbung-subtitle {
    font-size: 1.4rem;
    color: #646970;
    line-height: 1.4;
}

.blv-bewerbung-subtitle a {
    color: #41b883;
    text-decoration: none;
}

.blv-bewerbung-subtitle a:hover {
    text-decoration: underline;
}

/* Mobile adjustments */
@media (max-width: 768px) {
    .blv-bewerbung-header-flex {
        flex-direction: column;
        align-items: flex-start;
        gap: 20px;
    }

    .blv-bewerbung-h1 {
        font-size: 1.8rem !important;
    }

    .blv-bewerbung-subtitle {
        font-size: 1.2rem;
    }
}

/* Map Container */
#blv-map-container {
    height: 500px;
    margin-top: 50px;
    border-radius: 8px;
    border: 1px solid #ddd;
    overflow: hidden;
    max-width: 100%;
}

/* Logo Wall Slider */
.blv-logo-slider-container {
    overflow: hidden;
    width: 100%;
    display: flex;
    flex-direction: column;
    gap: 30px;
    padding: 40px 0;
}

.blv-logo-marquee {
    display: flex;
    overflow: hidden;
    user-select: none;
    gap: 60px;
}

.blv-marquee-content {
    display: flex;
    gap: 60px;
    flex-shrink: 0;
    min-width: 100%;
    justify-content: space-around;
}

.blv-marquee-left .blv-marquee-content {
    animation: blv-scroll-left 40s linear infinite;
}

.blv-marquee-right .blv-marquee-content {
    animation: blv-scroll-right 40s linear infinite;
}

@keyframes blv-scroll-left {
    from {
        transform: translateX(0);
    }

    to {
        transform: translateX(calc(-50% - 30px));
    }
}

@keyframes blv-scroll-right {
    from {
        transform: translateX(calc(-50% - 30px));
    }

    to {
        transform: translateX(0);
    }
}

.blv-logo-slider-container .blv-logo-item {
    width: 150px;
    flex-shrink: 0;
    display: flex;
    align-items: center;
    justify-content: center;
}

.blv-logo-slider-container .blv-logo-item img {
    max-width: 100%;
    height: auto;
    display: block;
    transition: transform 0.3s ease;
}

.blv-logo-slider-container .blv-logo-item img:hover {
    transform: scale(1.05);
}

/* Mobile Responsiveness */
@media (max-width: 768px) {
    .blv-lehrstelle-row {
        padding: 15px;
        gap: 15px;
    }

    .blv-logo-cell {
        width: 60px;
        height: 60px;
        margin-right: 0;
    }

    .blv-info-cell h3 {
        font-size: 1.1rem;
        white-space: normal;
        overflow: visible;
    }

    .blv-info-meta {
        gap: 8px 15px;
        font-size: 0.9rem;
    }

    .blv-action-cell {
        margin-left: 10px;
    }

    .blv-button {
        padding: 8px 12px;
        font-size: 0.85rem;
    }

    #blv-map-container {
        height: 400px;
        margin-top: 30px;
    }
}

@media (max-width: 540px) {
    .blv-lehrstelle-row {
        flex-direction: column;
        align-items: flex-start;
        text-align: left;
    }

    .blv-logo-cell {
        width: 50px;
        height: 50px;
    }

    .blv-info-cell {
        width: 100%;
    }

    .blv-action-cell {
        width: 100%;
        margin-left: 0;
        margin-top: 5px;
    }

    .blv-button {
        display: block;
        width: 100%;
        text-align: center;
    }

    .blv-filter-form {
        padding: 15px;
    }

    .blv-filter-form select {
        width: 100%;
        margin-top: 10px;
    }
}

@media (max-width: 400px) {
    .blv-info-meta {
        flex-direction: column;
        gap: 4px;
    }

    .blv-logo-marquee {
        gap: 20px;
    }

    .blv-marquee-content {
        gap: 20px;
    }
}