/* ================================================================
   page_institution_detail.css
   WCAG 2.1 AA – Kontrast, Fokus, Screenreader-Unterstützung
   ================================================================ */

/* ── Utilities ─────────────────────────────────────────────────── */
.sr-only {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}

/* ── Wrapper ───────────────────────────────────────────────────── */
.inst-detail {
    max-width: 860px;
    margin: 0 auto;
    padding-bottom: 4rem;
}

/* ── Cover ─────────────────────────────────────────────────────── */
.inst-cover {
    position: relative;
    width: 100%;
    height: 220px;
    background-size: cover;
    background-position: center;
    background-color: #e2e8f0;
}

/* Urheber-Badge (WCAG 1.4.3: Kontrast ≥ 4.5:1) */
.inst-cover__author {
    position: absolute;
    bottom: 0.5rem;
    left: 0.6rem;
    font-size: 0.72rem;
    line-height: 1;
    color: #ffffff;
    background-color: rgba(0, 0, 0, 0.52);
    padding: 0.2rem 0.45rem;
    border-radius: 3px;
    /* Weiß auf rgba(0,0,0,0.52) ≈ Kontrast >7:1 (AAA) */
}

.inst-cover__author-link {
    color: #ffffff;
    text-decoration: underline;
    text-underline-offset: 2px;
}

.inst-cover__author-link:hover {
    text-decoration: none;
}

.inst-cover__author-link:focus-visible {
    outline: 2px solid #ffffff;
    outline-offset: 2px;
    border-radius: 2px;
}

/* ── Header ────────────────────────────────────────────────────── */
.inst-header {
    position: relative;
    padding: 1.5rem 1.5rem 0;
}

.inst-header__inner {
    padding-right: 6rem; /* Platz für Zurück-Link */
}

.inst-header__back {
    position: absolute;
    top: 1.25rem;
    right: 1.25rem;
    display: inline-flex;
    align-items: center;
    gap: 0.3rem;
    font-size: 0.875rem;
    color: var(--color-primary);
    text-decoration: none;
    padding: 0.35rem 0.65rem;
    border-radius: 6px;
    transition: background 0.15s;
}
.inst-header__back:hover {
    background: #eff6ff;
}
.inst-header__back:focus-visible {
    outline: 3px solid var(--color-primary);
    outline-offset: 2px;
}

.inst-header__meta {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    flex-wrap: wrap;
    margin-bottom: 0.35rem;
}

.inst-category {
    font-size: 0.8rem;
    font-weight: 600;
    color: #475569;
    text-transform: uppercase;
    letter-spacing: 0.04em;
}

.inst-verified {
    display: inline-flex;
    align-items: center;
    gap: 0.25rem;
    font-size: 0.78rem;
    color: #166534;
    background: #dcfce7;
    padding: 0.15rem 0.5rem;
    border-radius: 100rem;
}

.inst-header__name {
    font-size: 1.75rem;
    font-weight: 700;
    line-height: 1.2;
    margin-bottom: 0.35rem;
}

.inst-header__address {
    display: flex;
    align-items: center;
    gap: 0.3rem;
    font-size: 0.9rem;
    color: #64748b;
    margin-bottom: 0.5rem;
}

.inst-header__rating {
    display: flex;
    align-items: center;
    gap: 0.4rem;
    margin-bottom: 0.5rem;
}

.inst-stars {
    color: #e6a817;
    font-size: 1.05rem;
    letter-spacing: 0.03em;
}

.inst-rating-label {
    font-size: 0.875rem;
    color: #475569;
}

/* ── Tab-Navigation ────────────────────────────────────────────── */
.inst-tabs {
    padding: 0 1.5rem;
    border-bottom: 2px solid var(--color-border);
    margin-top: 1.25rem;
}

.inst-tablist {
    display: flex;
    gap: 0;
    overflow-x: auto;
    scrollbar-width: none;
}
.inst-tablist::-webkit-scrollbar { display: none; }

.inst-tab {
    flex-shrink: 0;
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    padding: 0.75rem 1rem;
    font-size: 0.9rem;
    font-weight: 500;
    color: #64748b;
    background: none;
    border: none;
    border-bottom: 3px solid transparent;
    margin-bottom: -2px;
    cursor: pointer;
    font-family: inherit;
    transition: color 0.15s, border-color 0.15s;
    white-space: nowrap;
}
.inst-tab:hover {
    color: var(--color-primary);
}
.inst-tab:focus-visible {
    outline: 3px solid var(--color-primary);
    outline-offset: -2px;
    border-radius: 4px 4px 0 0;
}
.inst-tab--active,
.inst-tab[aria-selected="true"] {
    color: var(--color-primary);
    border-bottom-color: var(--color-primary);
    font-weight: 600;
}

.inst-tab__badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 1.35rem;
    height: 1.35rem;
    padding: 0 0.35rem;
    font-size: 0.72rem;
    font-weight: 700;
    background: #e2e8f0;
    color: #475569;
    border-radius: 100rem;
}
.inst-tab--active .inst-tab__badge,
.inst-tab[aria-selected="true"] .inst-tab__badge {
    background: #dbeafe;
    color: #1d4ed8;
}

/* ── Panels ────────────────────────────────────────────────────── */
.inst-panels {
    padding: 0 1.5rem;
}

.inst-panel {
    display: none;
}
.inst-panel--active,
.inst-panel:not([hidden]) {
    display: block;
}

.inst-panel__inner {
    padding: 1.5rem 0;
}

/* ── Info-Grid (Übersicht) ─────────────────────────────────────── */
.inst-info-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
    gap: 1rem;
}

.inst-info-card {
    background: #f8fafc;
    border: 1px solid var(--color-border);
    border-radius: 8px;
    padding: 1.1rem 1.25rem;
}
.inst-info-card--full {
    grid-column: 1 / -1;
}

.inst-info-card__title {
    font-size: 0.8rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: #64748b;
    margin-bottom: 0.65rem;
}

.inst-info-card__text {
    font-size: 0.925rem;
    color: #334155;
    line-height: 1.6;
}
.inst-info-card__text--pre {
    white-space: pre-line;
}
.inst-info-card__empty {
    font-size: 0.875rem;
    color: #94a3b8;
}

.inst-contact-list {
    list-style: none;
    padding: 0;
    margin: 0;
    display: flex;
    flex-direction: column;
    gap: 0.6rem;
}
.inst-contact-list li {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.9rem;
}
.inst-contact-list a {
    color: var(--color-primary);
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    gap: 0.25rem;
    word-break: break-all;
}
.inst-contact-list a:hover { text-decoration: underline; }
.inst-contact-list a:focus-visible {
    outline: 3px solid var(--color-primary);
    outline-offset: 2px;
    border-radius: 2px;
}
.inst-contact-list__empty {
    color: #94a3b8;
    font-size: 0.875rem;
}

/* ── Barrierefreiheit ──────────────────────────────────────────── */
.acc-group-filter {
    margin-bottom: 1.25rem;
}
.acc-group-filter__label {
    font-size: 0.85rem;
    font-weight: 600;
    color: #64748b;
    display: block;
    margin-bottom: 0.5rem;
}
.acc-group-filter__buttons {
    display: flex;
    flex-wrap: wrap;
    gap: 0.4rem;
}
.acc-group-btn {
    padding: 0.35rem 0.85rem;
    font-size: 0.85rem;
    font-family: inherit;
    border: 1.5px solid var(--color-border);
    border-radius: 100rem;
    background: #fff;
    color: #475569;
    cursor: pointer;
    transition: border-color 0.15s, background 0.15s, color 0.15s;
    white-space: nowrap;
}
.acc-group-btn:hover {
    border-color: var(--color-primary);
    color: var(--color-primary);
}
.acc-group-btn:focus-visible {
    outline: 3px solid var(--color-primary);
    outline-offset: 2px;
}
.acc-group-btn--active,
.acc-group-btn[aria-pressed="true"] {
    background: var(--color-primary);
    border-color: var(--color-primary);
    color: #fff;
    font-weight: 600;
}

.acc-criteria-list {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.acc-item {
    background: #f8fafc;
    border: 1px solid var(--color-border);
    border-radius: 8px;
    padding: 1rem 1.1rem;
    transition: border-color 0.15s;
}
.acc-item[hidden] { display: none; }

.acc-item__head {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 0.75rem;
    margin-bottom: 0.4rem;
}
.acc-item__name-wrap {
    display: flex;
    align-items: flex-start;
    gap: 0.5rem;
    flex: 1;
}
.acc-item__name-wrap svg {
    flex-shrink: 0;
    margin-top: 0.1rem;
    color: #94a3b8;
}
.acc-item__name {
    font-size: 0.95rem;
    font-weight: 600;
    color: #1e293b;
    line-height: 1.4;
}
.acc-item__desc {
    font-size: 0.85rem;
    color: #64748b;
    line-height: 1.5;
    margin-bottom: 0.35rem;
    margin-left: 1.625rem;
}
.acc-item__count {
    font-size: 0.78rem;
    color: #94a3b8;
    margin-left: 1.625rem;
    margin-bottom: 0.35rem;
}

/* Barrierefreiheits-Badges */
.acc-badge {
    display: inline-block;
    padding: 0.2rem 0.65rem;
    font-size: 0.78rem;
    font-weight: 700;
    border-radius: 100rem;
    white-space: nowrap;
    flex-shrink: 0;
}
.acc-badge.badge--met     { background: #dcfce7; color: #166534; }
.acc-badge.badge--partial { background: #fef9c3; color: #854d0e; }
.acc-badge.badge--not-met { background: #fee2e2; color: #991b1b; }
.acc-badge.badge--unknown { background: #f1f5f9; color: #64748b; }

.acc-item__details {
    margin-left: 1.625rem;
    margin-top: 0.4rem;
}
.acc-item__details summary {
    font-size: 0.82rem;
    color: var(--color-primary);
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    gap: 0.25rem;
    list-style: none;
    padding: 0;
}
.acc-item__details summary::-webkit-details-marker { display: none; }
.acc-item__details summary::before {
    content: '▸';
    font-size: 0.65rem;
    transition: transform 0.15s;
}
.acc-item__details[open] summary::before {
    transform: rotate(90deg);
}
.acc-item__details summary:focus-visible {
    outline: 3px solid var(--color-primary);
    outline-offset: 2px;
    border-radius: 2px;
}
.acc-item__details p {
    font-size: 0.85rem;
    color: #475569;
    line-height: 1.5;
    margin-top: 0.35rem;
    padding-left: 0.75rem;
    border-left: 2px solid #e2e8f0;
}

/* Prioritätstrennlinie (Gruppe vs. alle übrigen) */
.acc-criteria-list .acc-divider {
    border: none;
    border-top: 2px dashed #e2e8f0;
    margin: 0.5rem 0;
}
.acc-criteria-list .acc-divider-label {
    font-size: 0.78rem;
    color: #94a3b8;
    text-transform: uppercase;
    letter-spacing: 0.04em;
    font-weight: 600;
    text-align: center;
    position: relative;
    margin: 0.75rem 0 0.5rem;
}
.acc-criteria-list .acc-divider-label span {
    background: #fff;
    padding: 0 0.5rem;
    position: relative;
    z-index: 1;
}
.acc-criteria-list .acc-divider-label::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 0;
    right: 0;
    height: 1px;
    background: #e2e8f0;
}

/* ── Rezensionen ───────────────────────────────────────────────── */
.review-write-section {
    margin-bottom: 1.5rem;
    padding-bottom: 1.25rem;
    border-bottom: 1px solid var(--color-border);
}
.review-write-section--guest {
    font-size: 0.9rem;
    color: #64748b;
}
.review-write-section--guest a {
    color: var(--color-primary);
}
.review-write-section--own {
    background: #f0f9ff;
    border: 1px solid #bae6fd;
    border-radius: 8px;
    padding: 1rem 1.1rem;
    margin-bottom: 1.5rem;
}
.review-own-hint {
    font-size: 0.875rem;
    color: #0369a1;
    margin-bottom: 0.65rem;
}
.review-own-actions {
    display: flex;
    gap: 0.5rem;
    flex-wrap: wrap;
}

.review-own-badge {
    display: inline-block;
    font-size: 0.7rem;
    font-weight: 700;
    background: #dbeafe;
    color: #1d4ed8;
    padding: 0.1rem 0.4rem;
    border-radius: 100rem;
    margin-left: 0.3rem;
    vertical-align: middle;
}
.review-card--own {
    border-color: #bae6fd;
    background: #f0f9ff;
}

.review-card {
    background: #fff;
    border: 1px solid var(--color-border);
    border-radius: 8px;
    padding: 1.1rem 1.25rem;
    margin-bottom: 0.75rem;
}

.review-card__head {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 0.75rem;
    margin-bottom: 0.65rem;
}
.review-card__author-wrap {
    display: flex;
    align-items: center;
    gap: 0.6rem;
}
.review-card__avatar {
    width: 2rem;
    height: 2rem;
    border-radius: 50%;
    background: #dbeafe;
    color: #1d4ed8;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: 0.9rem;
    flex-shrink: 0;
}

.review-card__avatar--img {
    object-fit: cover;
    background: none;
    display: block;
    border: 1.5px solid #e5e7eb;
}
.review-card__author {
    font-size: 0.9rem;
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 0.35rem;
}
.review-card__author-link {
    color: inherit;
    text-decoration: none;
    font-weight: 700;
}
.review-card__author-link:hover,
.review-card__author-link:focus-visible {
    color: var(--color-primary, #1a73e8);
    text-decoration: underline;
}
.review-card__author-link:focus-visible {
    outline: 2px solid var(--color-primary, #1a73e8);
    outline-offset: 2px;
    border-radius: 2px;
}
.review-card__level {
    width: 1.375rem;
    height: 1.375rem;
    font-size: 0.6875rem;
    flex-shrink: 0;
}
/* Level-Badge-Farben (identisch zu profile) */
.level-badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    font-weight: 700;
    background: #e2e8f0;
    color: #475569;
}
.level-badge--1  { background: #e0f2fe; color: #0369a1; }
.level-badge--2  { background: #dcfce7; color: #166534; }
.level-badge--3  { background: #fef9c3; color: #854d0e; }
.level-badge--4  { background: #fde68a; color: #92400e; }
.level-badge--5  { background: #fed7aa; color: #9a3412; }
.level-badge--6  { background: #fecaca; color: #991b1b; }
.level-badge--7  { background: #f5d0fe; color: #7e22ce; }
.level-badge--8  { background: #c7d2fe; color: #3730a3; }
.level-badge--9  { background: #99f6e4; color: #0f766e; }
.level-badge--10 { background: #1e293b; color: #f1f5f9; }
.review-card__date {
    font-size: 0.8rem;
    color: #94a3b8;
    display: block;
}
.review-card__rating {
    display: flex;
    gap: 0.05rem;
}
.review-card__star {
    font-size: 1rem;
    color: #e2e8f0;
}
.review-card__star--filled {
    color: #e6a817;
}
.review-card__title {
    font-size: 1rem;
    font-weight: 600;
    margin-bottom: 0.35rem;
}
.review-card__text {
    font-size: 0.9rem;
    color: #334155;
    line-height: 1.6;
}
.review-card__images {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    margin-top: 0.75rem;
}
.review-card__img {
    width: 80px;
    height: 80px;
    object-fit: cover;
    border-radius: 4px;
    border: 1px solid var(--color-border);
    transition: opacity 0.15s;
}
.review-card__img:hover { opacity: 0.85; }

/* ── Anfahrt / Transport ───────────────────────────────────────── */
.inst-section-title {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 1.05rem;
    font-weight: 700;
    color: #1e293b;
    margin-bottom: 0.85rem;
}

.inst-divider {
    border: none;
    border-top: 1px solid var(--color-border);
    margin: 1.5rem 0;
}

.transport-block {
    margin-bottom: 0.5rem;
}

.transport-loading {
    display: flex;
    align-items: center;
    gap: 0.65rem;
    font-size: 0.9rem;
    color: #64748b;
    padding: 0.75rem 0;
}
.transport-spinner {
    display: inline-block;
    width: 1rem;
    height: 1rem;
    border: 2px solid #e2e8f0;
    border-top-color: var(--color-primary);
    border-radius: 50%;
    animation: spin 0.7s linear infinite;
    flex-shrink: 0;
}
@keyframes spin { to { transform: rotate(360deg); } }

/* Reduzierte Bewegung */
@media (prefers-reduced-motion: reduce) {
    .transport-spinner { animation: none; border-top-color: var(--color-primary); }
}

.transport-card {
    background: #f8fafc;
    border: 1px solid var(--color-border);
    border-radius: 8px;
    padding: 0.9rem 1.1rem;
    margin-bottom: 0.6rem;
    display: flex;
    align-items: flex-start;
    gap: 0.85rem;
}
.transport-card__icon {
    flex-shrink: 0;
    width: 2rem;
    height: 2rem;
    border-radius: 50%;
    background: #dbeafe;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #1d4ed8;
}
.transport-card__body {
    flex: 1;
    min-width: 0;
}
.transport-card__name {
    font-size: 0.95rem;
    font-weight: 600;
    color: #1e293b;
    margin-bottom: 0.2rem;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}
.transport-card__meta {
    font-size: 0.82rem;
    color: #64748b;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    flex-wrap: wrap;
}
.transport-card__distance {
    display: inline-flex;
    align-items: center;
    gap: 0.2rem;
    font-weight: 600;
    color: #1e293b;
}

/* Quellenangabe Haltestellen – WCAG-Transparenz */
.stations-source-notice {
    margin-top: 0.75rem;
    padding: 0.65rem 0.85rem;
    background: #f1f5f9;
    border-left: 3px solid #94a3b8;
    border-radius: 0 6px 6px 0;
    font-size: 0.8rem;
    color: #475569;
    line-height: 1.5;
}
.stations-source-notice strong { color: #334155; }
.stations-source-notice a {
    color: var(--color-primary);
    text-decoration: none;
}
.stations-source-notice a:hover { text-decoration: underline; }
.stations-source-notice a:focus-visible {
    outline: 3px solid var(--color-primary);
    outline-offset: 2px;
    border-radius: 2px;
}

.transport-empty {
    font-size: 0.9rem;
    color: #94a3b8;
    padding: 0.5rem 0;
}

/* ── Leerzustand: Haltestelle vorschlagen ──────────────────────── */
.stations-empty {
    padding: 0.5rem 0 0.75rem;
}

.stations-empty__text {
    font-size: 0.9rem;
    color: #64748b;
    margin: 0 0 0.85rem;
    line-height: 1.5;
}

/* ── Suggest-Station-Modal ─────────────────────────────────────── */
.modal-desc {
    font-size: 0.9rem;
    color: #64748b;
    margin: 0 0 1.25rem;
}

.modal-field {
    display: flex;
    flex-direction: column;
    gap: 0.3rem;
    margin-bottom: 1rem;
}

.modal-label {
    font-size: 0.875rem;
    font-weight: 600;
    color: #334155;
}

.modal-label--optional {
    font-weight: 400;
    color: #94a3b8;
    font-size: 0.8rem;
}

.modal-input {
    padding: 0.55rem 0.75rem;
    border: 1px solid var(--color-border, #e2e8f0);
    border-radius: 6px;
    font-size: 0.9rem;
    font-family: inherit;
    color: #1e293b;
    background: #fff;
    transition: border-color 0.15s, box-shadow 0.15s;
    width: 100%;
    box-sizing: border-box;
}

.modal-input:focus {
    outline: none;
    border-color: var(--color-primary);
    box-shadow: 0 0 0 3px color-mix(in srgb, var(--color-primary) 20%, transparent);
}

.modal-input[aria-invalid="true"] {
    border-color: #ef4444;
}

.modal-input--textarea {
    resize: vertical;
    min-height: 5rem;
}

.modal-field-error {
    font-size: 0.8rem;
    color: #dc2626;
    margin: 0;
}

.suggest-station-success {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.9rem;
    color: #16a34a;
    font-weight: 500;
    padding: 0.75rem 0 0.25rem;
    outline: none;
}

.suggest-station-success[hidden] {
    display: none;
}

/* ── Parking-Card (ausklappbar) ────────────────────────────────── */
.parking-card {
    background: #f8fafc;
    border: 1px solid var(--color-border);
    border-radius: 8px;
    margin-bottom: 0.6rem;
    overflow: hidden;
}

/* Immer sichtbarer Kopf – klickbar */
.parking-card__trigger {
    width: 100%;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.75rem;
    padding: 0.9rem 1.1rem;
    background: none;
    border: none;
    cursor: pointer;
    font-family: inherit;
    text-align: left;
    transition: background 0.15s;
}
.parking-card__trigger:hover { background: #f1f5f9; }
.parking-card__trigger:focus-visible {
    outline: 3px solid var(--color-primary);
    outline-offset: -2px;
}

.parking-card__title-wrap {
    display: flex;
    align-items: center;
    gap: 0.6rem;
    flex: 1;
    min-width: 0;
}
.parking-card__name {
    font-size: 0.95rem;
    font-weight: 600;
    color: #1e293b;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}
.parking-card__badges {
    display: flex;
    align-items: center;
    gap: 0.35rem;
    flex-shrink: 0;
}
.parking-card__badge-acc {
    display: inline-flex;
    align-items: center;
    gap: 0.2rem;
    font-size: 0.72rem;
    font-weight: 700;
    background: #dcfce7;
    color: #166534;
    padding: 0.15rem 0.45rem;
    border-radius: 100rem;
}
.parking-card__chevron {
    flex-shrink: 0;
    color: #94a3b8;
    transition: transform 0.2s;
}
.parking-card__trigger[aria-expanded="true"] .parking-card__chevron {
    transform: rotate(180deg);
}

/* Ausklappbarer Detail-Bereich */
.parking-card__details {
    border-top: 1px solid var(--color-border);
    padding: 0.9rem 1.1rem 1rem;
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
    gap: 0.6rem 1.25rem;
}
.parking-card__details[hidden] { display: none; }

.parking-card__detail-item {
    display: flex;
    flex-direction: column;
    gap: 0.15rem;
}
.parking-card__detail-label {
    font-size: 0.72rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.04em;
    color: #94a3b8;
}
.parking-card__detail-value {
    font-size: 0.875rem;
    color: #334155;
}

.parking-card__acc-box {
    grid-column: 1 / -1;
    display: flex;
    align-items: flex-start;
    gap: 0.4rem;
    background: #f0fdf4;
    border-left: 3px solid #86efac;
    border-radius: 0 4px 4px 0;
    padding: 0.5rem 0.75rem;
    font-size: 0.85rem;
    color: #166534;
}

.parking-card__map-link {
    grid-column: 1 / -1;
    display: inline-flex;
    align-items: center;
    gap: 0.3rem;
    font-size: 0.85rem;
    color: var(--color-primary);
    text-decoration: none;
    margin-top: 0.25rem;
}
.parking-card__map-link:hover { text-decoration: underline; }
.parking-card__map-link:focus-visible {
    outline: 3px solid var(--color-primary);
    outline-offset: 2px;
    border-radius: 2px;
}

/* Entfernung im Parkplatz-Kopf (analoges Design zu Haltestellen) */
.parking-card__distance {
    display: inline-flex;
    align-items: center;
    gap: 0.2rem;
    font-size: 0.78rem;
    font-weight: 600;
    color: #475569;
}

/* Sichtbarer Beschreibungstext direkt unter dem Trigger */
.parking-card__desc {
    margin: 0;
    padding: 0 1.1rem 0.75rem 3.15rem; /* links: Trigger-Padding + Icon-Breite + Gap */
    font-size: 0.85rem;
    color: #64748b;
    line-height: 1.5;
}

/* ── Veranstaltungen (Coming Soon) ─────────────────────────────── */
.inst-coming-soon {
    text-align: center;
    padding: 3rem 1rem;
    color: #94a3b8;
}
.inst-coming-soon svg { color: #cbd5e1; margin-bottom: 0.85rem; }
.inst-coming-soon h2  { font-size: 1.15rem; color: #64748b; margin-bottom: 0.35rem; }
.inst-coming-soon p   { font-size: 0.9rem; }

/* ── Panel-Action (z.B. BF-bewerten-Button) ────────────────────── */
.inst-panel__action {
    margin-top: 1.5rem;
    padding-top: 1.25rem;
    border-top: 1px solid var(--color-border);
}
.inst-panel__action-hint {
    font-size: 0.9rem;
    color: #64748b;
}
.inst-panel__action-hint a {
    color: var(--color-primary);
}

/* ── Allgemeine Leer-Zustand ────────────────────────────────────── */
.inst-empty-state {
    font-size: 0.9rem;
    color: #94a3b8;
    padding: 1.5rem 0;
    text-align: center;
}

/* ── Responsive ────────────────────────────────────────────────── */
@media (max-width: 600px) {
    .inst-header {
        padding: 1rem 1rem 0;
    }
    .inst-header__name {
        font-size: 1.4rem;
    }
    .inst-tabs {
        padding: 0 1rem;
    }
    .inst-panels {
        padding: 0 1rem;
    }
    .inst-info-grid {
        grid-template-columns: 1fr;
    }
    .inst-cover {
        height: 150px;
    }
}


/* ================================================================
   Öffnungszeiten – ausklappbare Wochentabelle
   (identisch mit component_institution_info.css oh-* Styles)
   ================================================================ */

.oh-details { width: 100%; }

.oh-summary
{
    display: flex;
    align-items: center;
    gap: 0.4rem;
    cursor: pointer;
    list-style: none;
    font-size: 0.95rem;
    line-height: 1.3;
    padding: 0.1rem 0;
    border-radius: 3px;
    outline-offset: 3px;
}

.oh-summary::-webkit-details-marker { display: none; }

.oh-summary:focus-visible { outline: 3px solid #0057b7; }

.oh-today-day
{
    font-weight: 600;
    min-width: 1.6rem;
    color: var(--color-text);
}

.oh-today-hours          { flex: 1; }
.oh-today-hours--open    { color: #1a6b36; }
.oh-today-hours--closed  { color: #888; }

.oh-chevron
{
    flex-shrink: 0;
    color: #888;
    transition: transform 0.18s ease;
}

.oh-details[open] .oh-chevron { transform: rotate(180deg); }

.oh-table
{
    width: 100%;
    border-collapse: collapse;
    margin-top: 0.45rem;
    font-size: 0.88rem;
}

.oh-table th,
.oh-table td
{
    padding: 0.22rem 0.3rem;
    text-align: left;
    vertical-align: middle;
}

.oh-table th
{
    font-weight: 600;
    width: 2.2rem;
    color: #555;
}

.oh-table td           { color: #333; }
.oh-table td.oh-closed { color: #aaa; }

.oh-table__row--today th,
.oh-table__row--today td
{
    color: var(--color-primary);
    font-weight: 600;
}

.oh-table__row--today td.oh-closed { color: #c0392b; }

@media (prefers-reduced-motion: reduce) { .oh-chevron { transition: none; } }


/* ================================================================
   Dateien-Tab – Dokumentkategorien + Dokumente
   ================================================================ */

.doc-categories
{
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.doc-category
{
    background: #f8fafc;
    border: 1px solid var(--color-border);
    border-radius: 8px;
    padding: 1.1rem 1.25rem;
}

.doc-category__title
{
    font-size: 0.8rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: #64748b;
    margin-bottom: 0.4rem;
}

.doc-category__desc
{
    font-size: 0.85rem;
    color: #64748b;
    margin-bottom: 0.65rem;
}

.doc-category__empty
{
    font-size: 0.875rem;
    color: #94a3b8;
    padding: 0.25rem 0;
}

/* Dokumentliste */
.doc-list
{
    list-style: none;
    padding: 0;
    margin: 0;
    display: flex;
    flex-direction: column;
    gap: 0.4rem;
}

.doc-item__link
{
    display: flex;
    align-items: center;
    gap: 0.65rem;
    padding: 0.6rem 0.75rem;
    background: #ffffff;
    border: 1px solid var(--color-border);
    border-radius: 6px;
    text-decoration: none;
    color: var(--color-text);
    transition: border-color 0.15s, box-shadow 0.15s;
}

.doc-item__link:hover
{
    border-color: var(--color-primary);
    box-shadow: 0 0 0 2px rgba(26, 115, 232, 0.12);
}

.doc-item__link:focus-visible
{
    outline: 3px solid var(--color-primary);
    outline-offset: 2px;
    border-radius: 6px;
}

.doc-item__icon
{
    flex-shrink: 0;
    color: var(--color-primary);
}

.doc-item__info
{
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 0.1rem;
    min-width: 0;
}

.doc-item__title
{
    font-size: 0.9rem;
    font-weight: 500;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.doc-item__meta
{
    font-size: 0.78rem;
    color: #64748b;
}

.doc-item__author-link
{
    color: #64748b;
    text-decoration: underline;
    text-underline-offset: 2px;
}

.doc-item__author-link:hover  { color: var(--color-primary); }

.doc-item__download
{
    flex-shrink: 0;
    color: #94a3b8;
}

.doc-item__link:hover .doc-item__download
{
    color: var(--color-primary);
}

/* ── Ähnliche Orte ────────────────────────────────────────────────
   WCAG 2.1 AA: Kontrast ≥ 4.5:1, Fokus sichtbar, semantische Liste
   ─────────────────────────────────────────────────────────────────*/
.similar-places {
    margin-top: 2rem;
    padding-top: 1.5rem;
    border-top: 1px solid var(--color-border);
}

.similar-places__list {
    list-style: none;
    padding: 0;
    margin: 0.75rem 0 0;
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    gap: 0.75rem;
}

/* Karte */
.similar-card {
    display: flex;
    flex-direction: column;
    border: 1px solid var(--color-border);
    border-radius: 10px;
    overflow: hidden;
    text-decoration: none;
    color: inherit;
    background: #ffffff;
    transition: box-shadow 0.15s, border-color 0.15s;
}

.similar-card:hover {
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.08);
    border-color: var(--color-primary);
}

/* WCAG 2.4.7 / 2.4.11: sichtbarer Fokusindikator */
.similar-card:focus-visible {
    outline: 3px solid var(--color-primary);
    outline-offset: 2px;
}

/* Bild */
.similar-card__img {
    width: 100%;
    height: 110px;
    background-size: cover;
    background-position: center;
    background-color: #e2e8f0;
    flex-shrink: 0;
}

/* Placeholder ohne Cover-Bild */
.similar-card__img--placeholder {
    display: flex;
    align-items: center;
    justify-content: center;
    color: #94a3b8;
}

/* Text-Bereich */
.similar-card__body {
    display: flex;
    flex-direction: column;
    gap: 0.2rem;
    padding: 0.65rem 0.8rem 0.65rem;
    flex: 1;
}

.similar-card__name {
    font-size: 0.9rem;
    font-weight: 600;
    /* WCAG 1.4.3: #1e293b auf #fff = Kontrast > 14:1 */
    color: #1e293b;
    line-height: 1.25;
}

.similar-card__address {
    font-size: 0.78rem;
    /* WCAG 1.4.3: #64748b auf #fff = Kontrast ≈ 4.6:1 */
    color: #64748b;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

/* Pfeil wird ausgeblendet – redundant zum Hover/Fokus-Signal */
.similar-card__arrow {
    display: none;
}

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

/* ── Favoriten-Button ───────────────────────────────────────────── */

/* Container unter den Header-Infos */
.inst-header__actions {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    margin-top: 0.75rem;
}

/*
 * btn-favorite
 * WCAG 1.4.3: Text + Icon auf weißem Hintergrund (#64748b ≈ 4.6:1)
 * WCAG 1.4.11: Fokusring 3 px, sichtbarer Zustandswechsel
 * WCAG 4.1.2: role=button via <button>, aria-pressed, aria-label
 */
.btn-favorite {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    padding: 0.4rem 0.85rem 0.4rem 0.65rem;
    border: 1.5px solid #cbd5e1;
    border-radius: 100rem;
    background: #ffffff;
    color: #64748b;
    font-size: 0.875rem;
    font-weight: 500;
    line-height: 1;
    cursor: pointer;
    transition: border-color 0.15s, color 0.15s, background 0.15s;
    /* Mindest-Klickfläche WCAG 2.5.8 (AAA): 44×44 px */
    min-height: 2.25rem;
}

.btn-favorite:hover {
    border-color: #e11d48;
    color: #e11d48;
    background: #fff1f2;
}

.btn-favorite:focus-visible {
    outline: 3px solid var(--color-primary, #1a73e8);
    outline-offset: 2px;
}

/* Aktiv-Zustand (favorisiert) */
.btn-favorite--active {
    border-color: #e11d48;
    color: #e11d48;
    background: #fff1f2;
}

.btn-favorite--active:hover {
    border-color: #be123c;
    color: #be123c;
    background: #ffe4e6;
}

/* Icon-Übergang */
.btn-favorite__icon {
    transition: fill 0.15s, stroke 0.15s;
    flex-shrink: 0;
}

/* Deaktiviert während API-Aufruf */
.btn-favorite:disabled {
    opacity: 0.6;
    cursor: wait;
}

/* ── Veranstaltungen-Tab ────────────────────────────────────────── */

.inst-events-heading {
    font-size: 1rem;
    font-weight: 700;
    color: #374151;
    margin: 0 0 1rem;
    padding-bottom: 0.4rem;
    border-bottom: 1px solid #e5e7eb;
}

.inst-events-heading--past {
    margin-top: 2rem;
    color: #6b7280;
}

.inst-event-list {
    list-style: none;
    padding: 0;
    margin: 0 0 1rem;
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

/*
 * Event-Karte
 * WCAG 1.4.3: alle Texte ≥ 4.5:1 auf weiß
 * WCAG 1.4.11: Fokusring auf Links sichtbar (3 px)
 */
.inst-event-card {
    display: flex;
    border: 1px solid #e5e7eb;
    border-radius: 10px;
    overflow: hidden;
    background: #fff;
}

.inst-event-card--past {
    background: #f9fafb;
    opacity: 0.8;
}

/* Cover-Bild links */
.inst-event-card__cover {
    width: 120px;
    flex-shrink: 0;
    background-size: cover;
    background-position: center;
    background-color: #f1f5f9;
}

.inst-event-card__body {
    flex: 1;
    padding: 1rem;
    display: flex;
    flex-direction: column;
    gap: 0.4rem;
}

/* Datum / Uhrzeit / Dauer */
.inst-event-card__meta {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    flex-wrap: wrap;
}

.inst-event-card__date {
    font-size: 0.82rem;
    font-weight: 700;
    color: var(--color-primary, #1a73e8);
    /* WCAG 1.4.3: #1a73e8 auf weiß ≈ 4.7:1 */
}

.inst-event-card__time,
.inst-event-card__duration {
    font-size: 0.82rem;
    color: #6b7280;
}

.inst-event-card__time::before {
    content: '·';
    margin-right: 0.5rem;
}

.inst-event-card__duration::before {
    content: '·';
    margin-right: 0.5rem;
}

.inst-event-card__title {
    font-size: 1rem;
    font-weight: 600;
    color: #111827;
    margin: 0;
    line-height: 1.3;
}

.inst-event-card__desc {
    font-size: 0.875rem;
    color: #374151;
    margin: 0;
    line-height: 1.5;
}

/* Preiszeile */
.inst-event-card__footer {
    margin-top: auto;
    padding-top: 0.5rem;
    display: flex;
    align-items: center;
    gap: 1rem;
    flex-wrap: wrap;
}

.inst-event-card__price {
    font-size: 0.82rem;
    color: #374151;
    display: flex;
    align-items: center;
    gap: 0.3rem;
}

.inst-event-card__price-acc {
    color: #6b7280;
}

.inst-event-card__links {
    display: flex;
    gap: 0.5rem;
    flex-wrap: wrap;
}

/* Fokusring auf Ticket-Links (WCAG 2.4.7 / 2.4.11) */
.inst-event-card__links a:focus-visible {
    outline: 3px solid var(--color-primary, #1a73e8);
    outline-offset: 2px;
}

/* Vergangene Veranstaltungen – schlanker */
.inst-event-list--past .inst-event-card {
    border-style: dashed;
}

/* Reduzierte Bewegung */
@media (prefers-reduced-motion: reduce) {
    .inst-event-card {
        transition: none;
    }
}

/* Schmale Viewports */
@media (max-width: 520px) {
    .inst-event-card__cover {
        display: none;
    }
}

/* ── Externe Veranstaltungslinks ──────────────────────────────────── */
.inst-events-external {
    margin-top: 2rem;
    padding-top: 1.5rem;
    border-top: 1px solid var(--color-border, #e0e0e0);
}

.inst-events-external__links {
    display: flex;
    gap: 0.75rem;
    flex-wrap: wrap;
    margin-top: 0.75rem;
}

/* Fokusring auf externe Veranstaltungslinks (WCAG 2.4.7 / 2.4.11) */
.inst-events-external__links a:focus-visible {
    outline: 3px solid var(--color-primary, #1a73e8);
    outline-offset: 2px;
}
