/* ==========================================================================
   REFERENZEN – Stile für Grid-Shortcodes und Einzelansicht
   ========================================================================== */

/* --------------------------------------------------------------------------
   Übersichts-Grid
   -------------------------------------------------------------------------- */

.ref-grid-liste {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 28px;
}

@media (max-width: 560px) {
    .ref-grid-liste { grid-template-columns: 1fr; }
}

/* --------------------------------------------------------------------------
   Karte mit Overlay
   -------------------------------------------------------------------------- */

.ref-card {
    display: block;
    position: relative;
    text-decoration: none;
    /* Platz nach unten für die herausragende Box */
    padding-bottom: 36px;
    transition: transform 0.25s ease;
}

.ref-card:hover {
    transform: translateY(-4px);
}

.ref-card-img {
    position: relative;
    border-radius: 12px;
    overflow: hidden;
}

.ref-card-img img {
    width: 100%;
    height: auto;
    display: block;
    transition: transform 0.45s ease;
}

.ref-card:hover .ref-card-img img {
    transform: scale(1.04);
}

.ref-card-no-img {
    width: 100%;
    height: 100%;
    background: #ddd;
}

/* Box zentriert, ragt aus dem Bild nach unten heraus */
.ref-card-overlay {
    position: absolute;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 78%;
    background: rgba(255, 255, 255, 0.78);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    color: #fff;
    text-align: center;
    padding: 14px 20px 16px;
    border-radius: 5px;
    transition: background 0.25s ease;
    z-index: 2;
}

.ref-card:hover .ref-card-overlay {
    background: rgba(255, 255, 255, 0.90);
}

.ref-card-overlay h3 {
    margin: 0 0 4px;
  font-size: clamp(1.1em, 3vw, 1.5em) !important;
    font-weight: 300;
    line-height: 1.3;
}

p.ref-card-excerpt  {
    margin: 0;
    font-size: clamp(0.8em, 2.5vw, 0.9em) !important;
    line-height: 1.45;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

/* --------------------------------------------------------------------------
   Filter-Leiste
   -------------------------------------------------------------------------- */

.ref-filter {
    display: flex;
    justify-content: center;
    gap: 20px;
    align-items: center;
    position: relative;
    margin-bottom: 42px;
    padding-bottom: 14px;
}

.ref-filter-btn {
    background: none;
    border: none;
    box-shadow: none;
    padding: 0 4px;
    cursor: pointer;
    font-size: clamp(0.8em, 2.5vw, 0.9em) !important;
    color: #aaa;
    transition: color 0.2s;
    white-space: nowrap;
}

.ref-filter-btn:hover {
    color: #333;
}

.ref-filter-btn.active {
    color: #222;
    font-weight: 500;
}

/* animierter Punkt */
.ref-filter-dot {
    position: absolute;
    bottom: 0;
    width: 6px;
    height: 6px;
    margin-top: -5px;
    border-radius: 50%;
    background: currentColor;
    transform: translateX(-50%);
    opacity: 0;
    transition: left 0.35s cubic-bezier(0.4, 0, 0.2, 1);
    pointer-events: none;
}

/* --------------------------------------------------------------------------
   Einzelansicht – Wrapper
   -------------------------------------------------------------------------- */

.ref-wrap {
    max-width: var(--ref-max-width, 1100px);
    margin: 30px auto;
    padding: 0 20px 60px;
}

/* --------------------------------------------------------------------------
   Einzelansicht – Breadcrumb
   -------------------------------------------------------------------------- */

.ref-breadcrumb {
    font-size: 13px;
    color: #888;
    margin-bottom: 28px;
}

.ref-breadcrumb a {
    color: inherit;
    text-decoration: none;
}

.ref-breadcrumb a:hover {
    text-decoration: underline;
}

.ref-breadcrumb .ref-sep {
    margin: 0 6px;
    color: #ccc;
}

/* --------------------------------------------------------------------------
   Einzelansicht – Großes Hauptbild
   -------------------------------------------------------------------------- */

.ref-hero-image {
    width: 100%;
    border-radius: 10px;
    overflow: hidden;
    margin-bottom: 40px;
    background: #f0f0f0;
}

.ref-hero-image img {
    width: 100%;
    height: auto;
    max-height: 600px;
    object-fit: cover;
    display: block;
}

/* --------------------------------------------------------------------------
   Einzelansicht – Textinhalt
   -------------------------------------------------------------------------- */

.ref-detail-text {
    max-width: 780px;
    margin-bottom: 56px;
}

.ref-detail-text h1 {
    font-size: clamp(24px, 4vw, 36px);
    line-height: 1.2;
    margin: 0 0 14px;
}

.ref-kategorie {
    font-size: 14px;
    color: #888;
    margin: 0 0 20px;
}

.ref-excerpt {
    font-size: 17px;
    color: #555;
    line-height: 1.65;
    margin-bottom: 24px;
    padding-bottom: 24px;
    border-bottom: 1px solid #e5e5e5;
}

.ref-description {
    font-size: 15px;
    line-height: 1.75;
    color: #444;
    margin-bottom: 28px;
}

.ref-inquiry-btn {
    display: inline-block;
    background: #1a1a2e;
    color: #fff;
    padding: 12px 28px;
    border-radius: 6px;
    font-size: 15px;
    font-weight: 600;
    text-decoration: none;
    transition: opacity 0.2s ease;
}

.ref-inquiry-btn:hover {
    opacity: 0.8;
    color: #fff;
}

/* --------------------------------------------------------------------------
   Einzelansicht – Bildercollage (CSS-Columns Masonry)
   -------------------------------------------------------------------------- */

.ref-collage {
    columns: 3;
    column-gap: 14px;
}

.ref-collage img {
    width: 100%;
    height: auto;
    display: block;
    margin-bottom: 14px;
    break-inside: avoid;
    border-radius: 8px;
}

@media (max-width: 860px) {
    .ref-collage { columns: 2; }
}

@media (max-width: 480px) {
    .ref-collage { columns: 1; }
}
