﻿/* ===========================
    SECTION LAYOUT
    =========================== */
.sgk-section {
    background: #0f467c;
    border-radius: 16px;
    margin: 4.6em;
}

#sgk-infos, #gib-infos {
    height: 520px;
}

.sgk-section > .col-md-4:last-child {
    display: flex;
    flex-direction: column;
    height: 520px;
    gap: 12px;
    min-height: 0;
}


    .sgk-section > .col-md-4:last-child > .row {
        margin: 0;
        min-height: 0;
    }

#newspaper, #turmob-news {
    flex: 1 1 0;
    min-height: 0;
}

    #newspaper > .col-12,
    #turmob-news > .col-12 {
        padding-left: 0;
        padding-right: 0;
        min-height: 0;
    }

    /* ===========================
    COMMON CARD BASE
    =========================== */
    #sgk-infos .card,
    #gib-infos .card,
    #newspaper .card,
    #turmob-news .card {
        border: 0;
        border-radius: 14px;
        overflow: hidden;
        background: #fff;
        height: 100%;
        display: flex;
        flex-direction: column;
        min-height: 0;
    }

    #sgk-infos .card-header,
    #gib-infos .card-header,
    #newspaper .card-header,
    #turmob-news .card-header {
        background: rgba(255,255,255,.92);
        border-bottom: 1px solid rgba(0,0,0,.06);
        padding: .75rem 1rem;
        flex: 0 0 auto;
        display: flex;
        align-items: center;
        justify-content: space-between;
        gap: .75rem;
    }

    #newspaper .newspaper-head,
    #turmob-news .turmob-head,
    #sgk-infos .sgk-head,
    #gib-infos .gib-head {
        display: flex;
        align-items: center;
        gap: .75rem;
        min-width: 0;
    }

    #newspaper .card-header a,
    #turmob-news .card-header a,
    #sgk-infos .card-header a,
    #gib-infos .card-header a {
        flex: 0 0 auto;
        display: inline-flex;
        align-items: center;
        justify-content: center;
    }

    /* ===========================
    LOGOS (Resmi Gazete + TURMOB)
    =========================== */
    #newspaper .newspaper-logo,
    #turmob-news .turmob-logo {
        width: 60px !important;
        height: 36px;
        object-fit: contain;
        display: block;
    }

    /* ===========================
    LIST AREA (Scroll garantisi)
    =========================== */
    #sgk-infos .sgk-list,
    #gib-infos .gib-list,
    #newspaper .newspaper-list,
    #turmob-news .turmob-list {
        flex: 1 1 auto;
        overflow-y: auto;
        min-height: 0;
    }

        #sgk-infos .sgk-list::-webkit-scrollbar,
        #gib-infos .gib-list::-webkit-scrollbar,
        #newspaper .newspaper-list::-webkit-scrollbar,
        #turmob-news .turmob-list::-webkit-scrollbar {
            width: 10px;
        }

        #sgk-infos .sgk-list::-webkit-scrollbar-thumb,
        #gib-infos .gib-list::-webkit-scrollbar-thumb,
        #newspaper .newspaper-list::-webkit-scrollbar-thumb,
        #turmob-news .turmob-list::-webkit-scrollbar-thumb {
            background: rgba(0,0,0,.15);
            border-radius: 999px;
            border: 2px solid #fff;
        }

/* ===========================
    SGK ITEMS
    =========================== */
#sgk-infos .sgk-ico {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 10px;
    color: #007bff;
    font-size: 34px;
}

#sgk-infos .sgk-item {
    padding: .85rem 1rem;
    border-bottom: 1px solid rgba(0,0,0,.06);
    transition: background .15s ease;
}

    #sgk-infos .sgk-item:hover {
        background: rgba(0,123,255,.04);
    }

    #sgk-infos .sgk-item:last-child {
        border-bottom: 0;
    }

#sgk-infos .sgk-item-title {
    font-weight: 600;
    line-height: 1.25;
    color: #212529;
}

#sgk-infos .sgk-meta {
    font-size: 12px;
    color: #6c757d;
    display: flex;
    gap: .75rem;
    flex-wrap: wrap;
    margin-top: .35rem;
}

#sgk-infos .sgk-link {
    text-decoration: none;
    color: inherit;
    display: block;
}

    #sgk-infos .sgk-link:hover .sgk-item-title {
        text-decoration: underline;
    }

/* ===========================
    GIB ITEMS
    =========================== */
#gib-infos .gib-ico {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 10px;
    color: #0A808B;
    font-size: 35px;
}

#gib-infos .gib-item {
    padding: .85rem 1rem;
    border-bottom: 1px solid rgba(0,0,0,.06);
    transition: background .15s ease;
}

    #gib-infos .gib-item:hover {
        background: rgba(40,167,69,.04);
    }

    #gib-infos .gib-item:last-child {
        border-bottom: 0;
    }

#gib-infos .gib-item-title {
    font-weight: 600;
    line-height: 1.25;
    color: #212529;
}

#gib-infos .gib-item-summary {
    margin-top: .35rem;
    font-size: 13px;
    color: #495057;
    line-height: 1.35;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

#gib-infos .gib-meta {
    font-size: 12px;
    color: #6c757d;
    display: flex;
    gap: .75rem;
    flex-wrap: wrap;
    margin-top: .45rem;
}

#gib-infos .gib-link {
    text-decoration: none;
    color: inherit;
    display: block;
}

    #gib-infos .gib-link:hover .gib-item-title {
        text-decoration: underline;
    }

/* ===========================
    NEWSPAPER ITEMS
    =========================== */
#newspaper .newspaper-ico {
    width: 34px;
    height: 34px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 10px;
    color: #dc3545;
    font-size: 16px;
}

#newspaper .newspaper-item {
    padding: .75rem 1rem;
    border-bottom: 1px solid rgba(0,0,0,.06);
    transition: background .15s ease;
}

    #newspaper .newspaper-item:hover {
        background: rgba(220,53,69,.04);
    }

    #newspaper .newspaper-item:last-child {
        border-bottom: 0;
    }

#newspaper .newspaper-item-title {
    font-weight: 600;
    line-height: 1.25;
    color: #212529;
}

#newspaper .newspaper-meta {
    font-size: 12px;
    color: #6c757d;
    margin-top: .35rem;
}

#newspaper .newspaper-link {
    text-decoration: none;
    color: inherit;
    display: block;
}

    #newspaper .newspaper-link:hover .newspaper-item-title {
        text-decoration: underline;
    }

/* ===========================
    TURMOB ITEMS
    =========================== */
#turmob-news .turmob-ico {
    width: 34px;
    height: 34px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 10px;
    color: #1B2473;
    font-size: 16px;
}

#turmob-news .turmob-item {
    padding: .75rem 1rem;
    border-bottom: 1px solid rgba(0,0,0,.06);
    transition: background .15s ease;
}

    #turmob-news .turmob-item:hover {
        background: rgba(255,193,7,.06);
    }

    #turmob-news .turmob-item:last-child {
        border-bottom: 0;
    }

#turmob-news .turmob-item-title {
    font-weight: 600;
    line-height: 1.25;
    color: #212529;
}

#turmob-news .turmob-meta {
    font-size: 12px;
    color: #6c757d;
    margin-top: .35rem;
}

#turmob-news .turmob-link {
    text-decoration: none;
    color: inherit;
    display: block;
}

    #turmob-news .turmob-link:hover .turmob-item-title {
        text-decoration: underline;
    }

/* ===========================
    EMPTY STATES
    =========================== */
#sgk-infos .sgk-empty,
#gib-infos .gib-empty,
#newspaper .newspaper-empty,
#turmob-news .turmob-empty {
    flex: 1 1 auto;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 1rem;
    color: #6c757d;
    text-align: center;
}

/* ===========================
    RESPONSIVE
    =========================== */
@media (max-width: 767.98px) {
    #sgk-infos, #gib-infos {
        height: auto;
    }

    .sgk-section > .col-md-4:last-child {
        height: auto;
        display: block;
    }

    #newspaper, #turmob-news {
        min-height: 320px;
        margin-top: 12px;
    }
}

.right-stack {
    display: flex;
    flex-direction: column;
    height: 520px;
    gap: 12px;
}

.right-slot {
    flex: 1 1 0;
    min-height: 0;
}

#turmob-news .turmob-card,
#newspaper .newspaper-card {
    height: 100%;
    display: flex;
    flex-direction: column;
    min-height: 0;
}

#turmob-news .turmob-list,
#newspaper .newspaper-list {
    flex: 1 1 auto;
    overflow-y: auto;
    min-height: 0;
}

.turmob-logo,
.newspaper-logo {
    width: 60px !important;
    height: auto;
    object-fit: contain;
    display: block;
}

@media (max-width: 1199.98px) {
    .sgk-section {
        margin: 1.5rem;
        border-radius: 14px;
    }
}

@media (max-width: 767.98px) {
    .sgk-section {
        margin: .75rem;
        border-radius: 12px;
        padding-left: .5rem;
        padding-right: .5rem;
    }
}

@media (max-width: 991.98px) {
    #sgk-infos, #gib-infos {
        height: auto;
        min-height: 320px;
    }

    .right-stack {
        height: auto;
    }

    #newspaper, #turmob-news {
        min-height: 320px;
    }
}

@media (max-width: 767.98px) {
    #sgk-infos .sgk-list,
    #gib-infos .gib-list,
    #newspaper .newspaper-list,
    #turmob-news .turmob-list {
        max-height: 320px;
        overflow-y: auto;
    }

    #newspaper .card-header,
    #turmob-news .card-header,
    #sgk-infos .card-header,
    #gib-infos .card-header {
        padding: .6rem .75rem;
    }

    #newspaper .newspaper-logo,
    #turmob-news .turmob-logo,
    .turmob-logo,
    .newspaper-logo {
        width: 52px !important;
        height: 32px;
    }
}

@media (max-width: 991.98px) {
    .sgk-section > .col-md-4:last-child {
        margin-top: 12px;
    }
}

@media (max-width: 575.98px) {
    #sgk-infos .sgk-item,
    #gib-infos .gib-item,
    #newspaper .newspaper-item,
    #turmob-news .turmob-item {
        padding: .65rem .75rem;
    }

}