/* ===== Referans Detay ===== */
.ref-wrap{ padding: 10px 0 40px; }

.ref-hero-kicker{
    display:inline-flex; align-items:center; gap:.55rem;
    padding:.35rem .75rem; border-radius:999px;
    background: rgba(255,255,255,.12);
    border: 1px solid rgba(255,255,255,.18);
    color: rgba(255,255,255,.90);
    font-weight: 800; font-size: .78rem;
    letter-spacing:.12em; text-transform: uppercase;
}

.ref-card{
    background:#fff;
    border: 1px solid rgba(15,23,42,.10);
    border-radius: 22px;
    box-shadow: 0 16px 44px rgba(15,23,42,.06);
    overflow:hidden;
}

.ref-cover{
    position: relative;
    background: #0b1220;
}
.ref-cover img{
    width: 100%;
    height: 380px;
    object-fit: cover;
    display:block;
    filter: saturate(1.02);
}
@media (max-width: 576px){
    .ref-cover img{ height: 240px; }
}

.ref-cover::after{
    content:"";
    position:absolute; inset:0;
    background: linear-gradient(180deg, rgba(2,6,23,0) 35%, rgba(2,6,23,.62) 100%);
    pointer-events:none;
}
.ref-cover-badges{
    position:absolute;
    left: 18px; right: 18px; bottom: 16px;
    z-index: 2;
    display:flex; flex-wrap:wrap; gap:10px; align-items:center;
}

.ref-pill{
    display:inline-flex; align-items:center; gap:10px;
    padding: 10px 14px;
    border-radius: 999px;
    font-weight: 900;
    font-size: 13px;
    line-height:1;
    border: 1px solid rgba(255,255,255,.16);
    background: rgba(2,6,23,.42);
    color: #fff;
    box-shadow: 0 10px 26px rgba(2,6,23,.20);
    backdrop-filter: blur(6px);
    user-select:none;
    white-space: nowrap;
}
.ref-pill .ico{
    width: 28px; height: 28px; border-radius: 999px;
    display:inline-flex; align-items:center; justify-content:center;
    border: 1px solid rgba(255,255,255,.18);
    background: rgba(255,255,255,.10);
    flex: 0 0 28px;
}
.ref-pill--primary{
    background: rgba(0,82,255,.20);
    border-color: rgba(0,82,255,.35);
}
.ref-pill--warm{
    background: rgba(255,122,0,.18);
    border-color: rgba(255,122,0,.35);
}

.ref-body{ padding: 20px 20px 18px; }
.ref-title{
    font-weight: 950;
    letter-spacing: -0.02em;
    color: #0f172a;
    margin: 0 0 8px;
    line-height: 1.1;
}
.ref-desc{
    color: #475569;
    font-size: 0.98rem;
    line-height: 1.75;
    margin: 0;
}

.ref-actions{
    margin-top: 14px;
    display:flex;
    flex-wrap: wrap;
    gap: 10px;
    align-items:center;
}
.ref-btn{
    display:inline-flex; align-items:center; gap:.55rem;
    padding: .70rem 1rem;
    border-radius: 14px;
    font-weight: 900;
    text-decoration:none;
    border: 1px solid rgba(15,23,42,.12);
    background: #fff;
    color: #0f172a;
    box-shadow: 0 10px 22px rgba(15,23,42,.05);
    transition: transform .16s ease, box-shadow .16s ease, border-color .16s ease, background .16s ease;
}
.ref-btn:hover{
    transform: translateY(-1px);
    border-color: rgba(0,82,255,.22);
    box-shadow: 0 14px 30px rgba(15,23,42,.08);
    color: var(--proda-primary);
}
.ref-btn--primary{
    border: 0;
    color:#fff;
    background: linear-gradient(135deg, var(--proda-primary-soft), var(--proda-secondary));
    box-shadow: 0 14px 34px rgba(0,82,255,.26);
}
.ref-btn--primary:hover{
    color:#fff;
    filter: brightness(1.02);
    border-color: transparent;
}

.ref-meta-grid{
    margin-top: 14px;
    display:grid;
    grid-template-columns: repeat(12, 1fr);
    gap: 12px;
}
.ref-meta{
    grid-column: span 6;
    background: #f8fafc;
    border: 1px solid rgba(15,23,42,.08);
    border-radius: 18px;
    padding: 12px 12px;
    display:flex;
    gap: 10px;
    align-items:flex-start;
}
.ref-meta .m-ico{
    width: 42px; height: 42px; border-radius: 16px;
    display:flex; align-items:center; justify-content:center;
    color:#fff;
    background: linear-gradient(135deg, var(--proda-primary), var(--proda-secondary));
    box-shadow: 0 12px 26px rgba(37,99,235,.20);
    flex: 0 0 42px;
}
.ref-meta .m-label{
    font-size: .78rem;
    letter-spacing: .12em;
    text-transform: uppercase;
    font-weight: 900;
    color: rgba(2,6,23,.55);
    margin: 2px 0 4px;
}
.ref-meta .m-val{
    font-weight: 900;
    color: #0f172a;
    margin: 0;
    line-height: 1.35;
    word-break: break-word;
}
@media (max-width: 992px){
    .ref-meta{ grid-column: span 12; }
}

.ref-gallery-wrap{
    margin-top: 16px;
    background:#fff;
    border: 1px solid rgba(15,23,42,.10);
    border-radius: 22px;
    box-shadow: 0 16px 44px rgba(15,23,42,.06);
    padding: 18px;
}
.ref-gallery-title{
    font-weight: 950;
    color:#0f172a;
    margin: 0 0 10px;
    letter-spacing: -0.01em;
    display:flex; align-items:center; gap:10px;
}
.ref-gallery-title i{
    width: 38px; height: 38px; border-radius: 14px;
    display:inline-flex; align-items:center; justify-content:center;
    color:#fff;
    background: linear-gradient(135deg, var(--proda-primary), var(--proda-secondary));
    box-shadow: 0 12px 26px rgba(37,99,235,.20);
}

/* Masonry (yükseklikler farklı olsa da iyi görünür) */
.ref-gallery{
    column-count: 3;
    column-gap: 12px;
}
.ref-gallery a{
    display:inline-block;
    width:100%;
    margin: 0 0 12px;
    break-inside: avoid;
    text-decoration:none;
}
.ref-gallery img{
    width:100%;
    height:auto;
    border-radius: 16px;
    border: 1px solid rgba(15,23,42,.10);
    box-shadow: 0 10px 26px rgba(15,23,42,.06);
    transition: transform .16s ease, box-shadow .16s ease, border-color .16s ease;
    display:block;
    background: #f1f5f9;
}
.ref-gallery a:hover img{
    transform: translateY(-1px);
    box-shadow: 0 16px 36px rgba(15,23,42,.10);
    border-color: rgba(0,82,255,.22);
}
@media (max-width: 992px){
    .ref-gallery{ column-count: 2; }
}
@media (max-width: 576px){
    .ref-gallery{ column-count: 1; }
}

/* Uzun Açıklama (aciklama_detay) */
.ref-long{
    margin-top: 16px;
    background:#fff;
    border: 1px solid rgba(15,23,42,.10);
    border-radius: 22px;
    box-shadow: 0 16px 44px rgba(15,23,42,.06);
    padding: 18px;
}
.ref-long-title{
    font-weight: 950;
    color:#0f172a;
    margin: 0 0 10px;
    letter-spacing: -0.01em;
    display:flex;
    align-items:center;
    gap:10px;
}
.ref-long-title i{
    width: 38px;
    height: 38px;
    border-radius: 14px;
    display:inline-flex;
    align-items:center;
    justify-content:center;
    color:#fff;
    background: linear-gradient(135deg, var(--proda-primary), var(--proda-secondary));
    box-shadow: 0 12px 26px rgba(37, 99, 235, 0.20);
}
.ref-long-content{
    color: rgba(2,6,23,.86);
    line-height: 1.9;
    font-size: 15.5px;
}
.ref-long-content img{
    max-width: 100%;
    height: auto;
    border-radius: 14px;
    border: 1px solid rgba(15,23,42,.10);
}
.ref-long-content p{ margin: 0 0 .95rem; }
.ref-long-content p:last-child{ margin-bottom: 0; }
.ref-gallery-item{
    cursor: zoom-in;
}

.ref-gallery-modal .modal-dialog{
    max-width: min(1180px, calc(100vw - 32px));
}

.ref-gallery-modal .modal-content{
    position: relative;
    background: rgba(2,6,23,.96);
    border: 1px solid rgba(255,255,255,.08);
    border-radius: 24px;
    overflow: hidden;
    box-shadow: 0 30px 80px rgba(2,6,23,.45);
}

.ref-gallery-close{
    position: absolute;
    top: 14px;
    right: 14px;
    z-index: 5;
    width: 46px;
    height: 46px;
    border: 0;
    border-radius: 999px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: rgba(255,255,255,.12);
    color: #fff;
    backdrop-filter: blur(8px);
}

.ref-gallery-close:hover{
    background: rgba(255,255,255,.18);
}

.ref-gallery-modal-body{
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 18px;
    min-height: 72vh;
    padding: 28px;
}

.ref-gallery-stage{
    flex: 1 1 auto;
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 60vh;
    overflow: hidden;
    border-radius: 20px;
}

.ref-gallery-stage img{
    max-width: 100%;
    max-height: 72vh;
    width: auto;
    height: auto;
    object-fit: contain;
    border-radius: 18px;
    box-shadow: 0 24px 60px rgba(0,0,0,.28);
    background: #0f172a;
}

.ref-gallery-nav{
    width: 56px;
    height: 56px;
    flex: 0 0 56px;
    border: 0;
    border-radius: 999px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: rgba(255,255,255,.12);
    color: #fff;
    box-shadow: 0 16px 34px rgba(0,0,0,.24);
    transition: transform .16s ease, background .16s ease;
}

.ref-gallery-nav:hover{
    transform: translateY(-1px);
    background: rgba(255,255,255,.18);
}

.ref-gallery-modal-foot{
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    padding: 0 28px 22px;
    color: #e5e7eb;
}

.ref-gallery-modal-title{
    font-weight: 900;
    letter-spacing: -.01em;
}

.ref-gallery-counter{
    font-weight: 800;
    color: rgba(229,231,235,.78);
}

@media (max-width: 768px){
    .ref-gallery-modal .modal-dialog{
        max-width: calc(100vw - 16px);
        margin: 8px auto;
    }

    .ref-gallery-modal-body{
        min-height: auto;
        padding: 18px 12px;
        gap: 10px;
    }

    .ref-gallery-stage{
        min-height: 44vh;
    }

    .ref-gallery-stage img{
        max-height: 62vh;
    }

    .ref-gallery-nav{
        width: 44px;
        height: 44px;
        flex-basis: 44px;
    }

    .ref-gallery-modal-foot{
        padding: 0 14px 16px;
        flex-direction: column;
        align-items: flex-start;
    }
}