/**
 * Ana sayfa ek bölümler — TEB şeridi, hizmet panelleri, güncel haberler, başkan carousel
 */

/* ========== TEB / Oda gündemi şeridi ========== */
.teb-ticker {
    padding: 2.5rem 0;
    background: linear-gradient(135deg, var(--brand-navy-dark) 0%, var(--brand-maroon-dark) 100%);
    overflow: hidden;
}

.teb-ticker__head {
    display: flex;
    align-items: baseline;
    gap: 1rem;
    margin-bottom: 1.25rem;
}

.teb-ticker__eyebrow {
    font-size: 0.65rem;
    font-weight: 700;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    color: var(--brand-gold-light);
}

.teb-ticker__title {
    margin: 0;
    font-size: 1.25rem;
    font-weight: 700;
    color: #fff;
}

.teb-ticker__viewport {
    position: relative;
    padding: 0.5rem 1rem 1rem;
    max-width: 100%;
    transition: padding 0.3s ease;
}

.teb-ticker__viewport.is-hovered,
.teb-ticker__viewport:hover {
    padding-left: 3.25rem;
    padding-right: 3.25rem;
}

.teb-ticker__rail {
    overflow: hidden;
    cursor: grab;
    padding: 0.4rem 0 0.6rem;
    mask-image: linear-gradient(90deg, transparent, #000 48px, #000 calc(100% - 48px), transparent);
    -webkit-mask-image: linear-gradient(90deg, transparent, #000 48px, #000 calc(100% - 48px), transparent);
}

.teb-ticker__rail.is-dragging {
    cursor: grabbing;
    user-select: none;
}

.teb-ticker__track {
    display: flex;
    width: max-content;
    will-change: transform;
}

.teb-ticker__set {
    display: flex;
    flex-shrink: 0;
    align-items: stretch;
    gap: 1rem;
    padding-right: 1rem;
}

.teb-ticker__nav {
    position: absolute;
    top: 50%;
    z-index: 4;
    width: 42px;
    height: 42px;
    border: 1px solid rgba(255, 255, 255, 0.25);
    border-radius: 50%;
    background: rgba(15, 40, 53, 0.65);
    backdrop-filter: blur(8px);
    color: #fff;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
    transform: translateY(-50%) scale(0.88);
    transition:
        opacity 0.28s ease,
        visibility 0.28s ease,
        transform 0.28s ease,
        background 0.2s,
        border-color 0.2s,
        box-shadow 0.2s;
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.2);
}

.teb-ticker__viewport.is-hovered .teb-ticker__nav,
.teb-ticker__viewport:hover .teb-ticker__nav,
.teb-ticker__viewport:focus-within .teb-ticker__nav {
    opacity: 1;
    visibility: visible;
    pointer-events: auto;
    transform: translateY(-50%) scale(1);
}

.teb-ticker__nav:hover {
    background: var(--brand-gold);
    border-color: var(--brand-gold);
    color: var(--brand-navy-dark);
    transform: translateY(-50%) scale(1.06);
}

.teb-ticker__nav:active {
    transform: translateY(-50%) scale(0.98);
}

.teb-ticker__nav--prev {
    left: 0.75rem;
}

.teb-ticker__nav--next {
    right: 0.75rem;
}

@media (max-width: 575px) {
    .teb-ticker__viewport.is-hovered,
    .teb-ticker__viewport:hover {
        padding-left: 2.75rem;
        padding-right: 2.75rem;
    }

    .teb-ticker__nav {
        width: 36px;
        height: 36px;
        font-size: 0.8rem;
    }

    .teb-ticker__nav--prev {
        left: 0.35rem;
    }

    .teb-ticker__nav--next {
        right: 0.35rem;
    }
}

@media (hover: none) {
    .teb-ticker__nav {
        opacity: 0.85;
        visibility: visible;
        pointer-events: auto;
        transform: translateY(-50%) scale(1);
    }

    .teb-ticker__viewport {
        padding-left: 2.75rem;
        padding-right: 2.75rem;
    }
}

.teb-ticker__card {
    flex: 0 0 min(300px, 85vw);
    display: flex;
    align-items: center;
    gap: 1rem;
    padding: 1rem 1.15rem;
    background: rgba(255, 255, 255, 0.08);
    border: 1px solid rgba(255, 255, 255, 0.12);
    border-radius: 16px;
    text-decoration: none;
    color: #fff;
    box-shadow: 0 0 0 0 transparent;
    transition: background 0.2s, border-color 0.2s, box-shadow 0.2s;
}

.teb-ticker__card:hover {
    background: rgba(255, 255, 255, 0.14);
    border-color: rgba(110, 197, 240, 0.65);
    box-shadow:
        0 0 0 1px rgba(110, 197, 240, 0.35),
        0 8px 24px rgba(0, 0, 0, 0.22);
    color: #fff;
}

.teb-ticker__icon {
    flex-shrink: 0;
    width: 48px;
    height: 48px;
    border-radius: 12px;
    background: rgba(255, 255, 255, 0.1);
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
}

.teb-ticker__icon img {
    width: 36px;
    height: 36px;
    object-fit: contain;
}

.teb-ticker__icon i {
    font-size: 1.25rem;
    color: var(--brand-gold);
}

.teb-ticker__text {
    flex: 1;
    min-width: 0;
    display: flex;
    flex-direction: column;
    gap: 0.2rem;
}

.teb-ticker__text strong {
    font-size: 0.875rem;
    font-weight: 600;
    line-height: 1.35;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.teb-ticker__text time {
    font-size: 0.7rem;
    color: rgba(255, 255, 255, 0.55);
}

.teb-ticker__arrow {
    opacity: 0.4;
    font-size: 0.75rem;
    transition: opacity 0.2s, transform 0.2s;
}

.teb-ticker__card:hover .teb-ticker__arrow {
    opacity: 1;
    transform: translateX(3px);
}

/* ========== Hizmet panelleri (nöbet + turnike) ========== */
.home-services {
    padding: 4rem 0;
    background: var(--bg-light);
}

.home-services__intro {
    text-align: center;
    max-width: 40rem;
    margin: 0 auto 2.5rem;
}

.home-services__eyebrow {
    display: inline-block;
    font-size: 0.7rem;
    font-weight: 700;
    letter-spacing: 0.14em;
    text-transform: uppercase;
    color: var(--brand-maroon);
    margin-bottom: 0.5rem;
}

.home-services__title {
    margin: 0;
    font-size: clamp(1.5rem, 3.2vw, 2rem);
    font-weight: 800;
    color: var(--text-dark);
    letter-spacing: -0.02em;
    line-height: 1.2;
}

.home-services__divider {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.85rem;
    margin: 1.15rem auto 1.1rem;
    max-width: 22rem;
}

.home-services__divider-line {
    flex: 1;
    height: 2px;
    border-radius: 2px;
    background: linear-gradient(
        90deg,
        transparent 0%,
        rgba(110, 197, 240, 0.45) 20%,
        var(--brand-gold) 50%,
        rgba(110, 197, 240, 0.45) 80%,
        transparent 100%
    );
}

.home-services__divider-mark {
    flex-shrink: 0;
    width: 36px;
    height: 36px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--brand-maroon) 0%, var(--brand-navy) 100%);
    color: var(--brand-gold-light);
    font-size: 0.85rem;
    box-shadow: 0 4px 14px rgba(43, 143, 199, 0.22);
}

.home-services__lead {
    margin: 0;
    font-size: clamp(0.9rem, 1.8vw, 1rem);
    line-height: 1.65;
    color: var(--text-light);
}

.home-services__grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: clamp(1rem, 2.5vw, 1.5rem);
    align-items: stretch;
}

.service-panel {
    display: flex;
    flex-direction: column;
    min-width: 0;
    background: var(--bg-white);
    border-radius: 20px;
    border: 1px solid var(--border-color);
    overflow: hidden;
    box-shadow: 0 8px 32px rgba(15, 40, 53, 0.06);
}

.service-panel--guard .service-panel__head {
    background: linear-gradient(135deg, var(--brand-maroon) 0%, var(--brand-maroon-dark) 100%);
}

.service-panel--turnike .service-panel__head {
    background: linear-gradient(135deg, var(--brand-teal) 0%, var(--brand-navy-dark) 100%);
}

.service-panel__head {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 0.75rem 1rem;
    padding: 1.25rem 1.35rem;
    color: #fff;
}

.service-panel__head > div:not(.service-panel__head-icon) {
    flex: 1 1 140px;
    min-width: 0;
}

.service-panel__head-icon {
    flex-shrink: 0;
}

.service-panel--guard .service-panel__pharmacy-logo {
    width: 44px;
    height: 44px;
    border-radius: 12px;
}

.service-panel__pharmacy-logo {
    position: relative;
    width: 44px;
    height: 44px;
    border-radius: 12px;
    background: linear-gradient(145deg, var(--brand-maroon) 0%, var(--brand-navy) 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    flex-shrink: 0;
    margin-top: 0.1rem;
    box-shadow: 0 3px 12px rgba(43, 143, 199, 0.22);
    border: 1px solid rgba(255, 255, 255, 0.08);
}

.service-panel__pharmacy-logo .guard-pharmacy-avatar__qr {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.service-panel__pharmacy-logo .guard-pharmacy-avatar__icon {
    position: absolute;
    width: 24px;
    height: 24px;
    opacity: 0.3;
    object-fit: contain;
}

.service-panel__pharmacy-logo .guard-pharmacy-avatar__monogram {
    position: relative;
    z-index: 1;
    font-size: 0.72rem;
    font-weight: 800;
    color: var(--brand-gold-light);
    letter-spacing: 0.03em;
}

.service-panel__head h2 {
    margin: 0;
    font-size: clamp(0.95rem, 2vw, 1.05rem);
    font-weight: 700;
    line-height: 1.3;
    word-break: break-word;
}

.service-panel__head p {
    margin: 0.15rem 0 0;
    font-size: 0.75rem;
    opacity: 0.8;
    word-break: break-word;
}

.service-panel__head-link {
    margin-left: auto;
    font-size: 0.75rem;
    font-weight: 600;
    color: var(--brand-gold-light);
    text-decoration: none;
    white-space: nowrap;
    padding: 0.35rem 0.75rem;
    border: 1px solid rgba(255, 255, 255, 0.25);
    border-radius: 100px;
    transition: background 0.2s;
}

.service-panel__head-link:hover {
    background: rgba(255, 255, 255, 0.15);
    color: #fff;
}

.service-panel__body {
    flex: 1 1 auto;
    min-height: 0;
    padding: 1rem 1.25rem;
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.service-panel__body--scroll {
    overflow-y: auto;
    scrollbar-width: thin;
    scrollbar-color: var(--brand-navy) transparent;
}

.service-panel__row {
    display: flex;
    gap: 0.85rem;
    align-items: flex-start;
    padding-bottom: 0.75rem;
    border-bottom: 1px dashed var(--border-color);
}

.service-panel__row:last-child {
    border-bottom: none;
    padding-bottom: 0;
}

.service-panel__dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: var(--brand-maroon);
    margin-top: 0.45rem;
    flex-shrink: 0;
    box-shadow: 0 0 0 3px var(--brand-gold-muted);
}

.service-panel--turnike .service-panel__dot {
    background: var(--brand-navy);
}

.service-panel__row-text {
    display: flex;
    flex-direction: column;
    gap: 0.2rem;
    min-width: 0;
}

.service-panel__row-text strong {
    font-size: 0.875rem;
    color: var(--text-dark);
    word-break: break-word;
}

.service-panel__row-text span {
    font-size: 0.8rem;
    color: var(--text-light);
    word-break: break-word;
}

.service-panel__actions {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0.45rem;
    margin-top: 0.35rem;
}

.service-panel__row-text .service-panel__actions a.service-panel__action {
    text-decoration: none !important;
}

.service-panel__action {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    padding: 0.36rem 0.72rem;
    font-size: 0.75rem;
    font-weight: 600;
    line-height: 1.2;
    text-decoration: none !important;
    border-radius: 8px;
    border: 1px solid var(--border-color, #e2e6ed);
    background: #fff;
    box-shadow: none;
    transition: background 0.18s ease, color 0.18s ease, border-color 0.18s ease;
}

.service-panel__action i {
    font-size: 0.7rem;
    flex-shrink: 0;
}

.service-panel__action--call {
    color: var(--brand-primary-dark, #1a6fa3) !important;
    border-color: #d4e3ef;
    background: #f7fafc;
}

.service-panel__row-text .service-panel__actions a.service-panel__action--call:hover,
.service-panel__row-text .service-panel__actions a.service-panel__action--call:focus-visible {
    color: var(--brand-primary-dark, #1a6fa3) !important;
    background: #eef5fa !important;
    border-color: rgba(43, 143, 199, 0.5) !important;
    text-decoration: none !important;
    box-shadow: none;
}

.service-panel__action--map {
    color: var(--brand-primary-dark, #1a6fa3) !important;
    border-color: #c5d9e8;
    background: #fff;
}

.service-panel__action--map i {
    color: var(--brand-primary, #2b8fc7);
}

.service-panel__row-text .service-panel__actions a.service-panel__action--map:hover,
.service-panel__row-text .service-panel__actions a.service-panel__action--map:focus-visible,
.service-panel__row-text .service-panel__actions a.service-panel__action--map:visited:hover {
    color: var(--brand-navy-dark, #134559) !important;
    background: #eef5fa !important;
    border-color: var(--brand-primary, #2b8fc7) !important;
    text-decoration: none !important;
    box-shadow: none;
}

.service-panel__row-text .service-panel__actions a.service-panel__action--map:hover i,
.service-panel__row-text .service-panel__actions a.service-panel__action--map:focus-visible i {
    color: var(--brand-primary-dark, #1a6fa3);
}

.service-panel__row--compact {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(0, 1.15fr) auto;
    align-items: center;
    gap: 0.5rem 0.75rem;
}

.service-panel__turnike-name {
    font-size: 0.8rem;
    font-weight: 700;
    color: var(--brand-navy);
    min-width: 0;
    word-break: break-word;
    line-height: 1.35;
    text-decoration: none;
    transition: color 0.15s ease;
}

a.service-panel__turnike-name:hover,
a.service-panel__turnike-name:focus-visible {
    color: var(--brand-maroon);
    text-decoration: underline;
    text-underline-offset: 2px;
}

.service-panel__turnike-pharmacy {
    font-size: 0.85rem;
    color: var(--text-dark);
    font-weight: 500;
    min-width: 0;
    word-break: break-word;
    line-height: 1.35;
}

.service-panel__row--compact .service-panel__badge,
.service-panel__row--compact .service-panel__badge--muted {
    flex-shrink: 0;
    white-space: nowrap;
}

.service-panel__badge {
    font-size: 0.65rem;
    font-weight: 700;
    text-transform: uppercase;
    padding: 0.2rem 0.5rem;
    background: var(--brand-gold-muted);
    color: var(--brand-maroon);
    border-radius: 4px;
    text-decoration: none;
}

.service-panel__badge--muted {
    background: var(--bg-light);
    color: var(--text-light);
}

.service-panel__empty {
    margin: 0;
    font-size: 0.875rem;
    color: var(--text-light);
    text-align: center;
    padding: 1rem 0;
}

.service-panel__cta {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    margin-top: auto;
    flex-shrink: 0;
    padding: 0.9rem;
    background: var(--brand-navy-dark);
    color: #fff !important;
    font-weight: 600;
    font-size: 0.85rem;
    text-decoration: none;
    transition: background 0.2s;
}

.service-panel__cta--light {
    background: var(--brand-maroon-dark);
}

.service-panel__cta:hover {
    background: var(--brand-maroon);
    color: #fff !important;
}

/* ========== Başkandan carousel ========== */
.president-hub__head {
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    gap: 1.5rem;
    margin-bottom: 1.75rem;
    flex-wrap: wrap;
}

.president-hub__layout {
    display: grid;
    grid-template-columns: 1fr 300px;
    gap: 1.5rem;
    align-items: stretch;
}

.president-hub__slides {
    position: relative;
    min-height: 360px;
}

.president-hub__pane {
    display: grid;
    grid-template-columns: 280px 1fr;
    background: linear-gradient(135deg, var(--brand-navy-dark) 0%, var(--brand-maroon-dark) 100%);
    border-radius: 24px;
    overflow: hidden;
    box-shadow: 0 16px 48px rgba(15, 40, 53, 0.18);
    min-height: 360px;
    animation: presidentPaneIn 0.4s ease;
}

.president-hub__pane[hidden] {
    display: none !important;
}

@keyframes presidentPaneIn {
    from { opacity: 0; transform: translateY(8px); }
    to { opacity: 1; transform: translateY(0); }
}

.president-hub__media {
    position: relative;
    overflow: hidden;
}

.president-hub__media img {
    width: 100%;
    height: 100%;
    min-height: 360px;
    object-fit: cover;
    object-position: 28% center;
}

.president-hub__placeholder {
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 360px;
    font-size: 4rem;
    color: rgba(110, 197, 240, 0.3);
    background: rgba(0, 0, 0, 0.2);
}

.president-hub__content {
    padding: 2rem 2rem 2rem 1.5rem;
    display: flex;
    flex-direction: column;
    justify-content: center;
    color: #fff;
    gap: 0.75rem;
}

.president-hub__content time {
    font-size: 0.8rem;
    color: rgba(255, 255, 255, 0.55);
}

.president-hub__content h3 {
    margin: 0;
    font-size: clamp(1.1rem, 2vw, 1.45rem);
    font-weight: 700;
    line-height: 1.35;
}

.president-hub__content p {
    margin: 0;
    font-size: 0.9rem;
    line-height: 1.7;
    color: rgba(255, 255, 255, 0.82);
    display: -webkit-box;
    -webkit-line-clamp: 5;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.president-hub__read {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    align-self: flex-start;
    margin-top: 0.5rem;
    padding: 0.65rem 1.2rem;
    background: var(--brand-gold);
    color: var(--brand-navy-dark) !important;
    font-weight: 700;
    font-size: 0.85rem;
    border-radius: 100px;
    text-decoration: none;
    transition: transform 0.2s, box-shadow 0.2s;
}

.president-hub__read:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(110, 197, 240, 0.4);
    color: var(--brand-navy-dark) !important;
}

.president-hub__nav {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
    max-height: 360px;
    overflow-y: auto;
    padding-right: 4px;
    scrollbar-width: thin;
}

.president-hub__nav-item {
    display: flex;
    align-items: flex-start;
    gap: 0.75rem;
    width: 100%;
    padding: 0.85rem 1rem;
    background: var(--bg-white);
    border: 1px solid var(--border-color);
    border-radius: 14px;
    cursor: pointer;
    text-align: left;
    transition: border-color 0.2s, box-shadow 0.2s, background 0.2s;
}

.president-hub__nav-item:hover {
    border-color: rgba(43, 143, 199, 0.3);
    box-shadow: 0 4px 12px rgba(15, 40, 53, 0.06);
}

.president-hub__nav-item.is-active {
    border-color: var(--brand-maroon);
    background: linear-gradient(135deg, rgba(43, 143, 199, 0.06), rgba(110, 197, 240, 0.08));
    box-shadow: 0 4px 16px rgba(43, 143, 199, 0.1);
}

.president-hub__nav-num {
    width: 28px;
    height: 28px;
    border-radius: 8px;
    background: var(--brand-maroon);
    color: #fff;
    font-size: 0.75rem;
    font-weight: 700;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.president-hub__nav-item.is-active .president-hub__nav-num {
    background: var(--brand-gold);
    color: var(--brand-navy-dark);
}

.president-hub__nav-title {
    font-size: 0.8rem;
    font-weight: 600;
    line-height: 1.4;
    color: var(--text-dark);
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

/* Responsive */
@media (max-width: 1199px) {
    .home-services {
        padding: 3rem 0;
    }

    .home-services__intro {
        margin-bottom: 2rem;
    }
}

@media (max-width: 991px) {
    .home-services__grid {
        grid-template-columns: 1fr;
    }

    .service-panel__body--scroll {
        max-height: 280px;
    }

    .president-hub__layout {
        grid-template-columns: 1fr;
    }

    .president-hub__nav {
        flex-direction: row;
        flex-wrap: nowrap;
        overflow-x: auto;
        max-height: none;
        padding-bottom: 4px;
    }

    .president-hub__nav-item {
        flex: 0 0 min(260px, 80vw);
    }

    .president-hub__pane {
        grid-template-columns: 1fr;
    }

    .president-hub__media img,
    .president-hub__placeholder {
        min-height: 220px;
        max-height: 260px;
    }
}

@media (max-width: 767px) {
    .home-services {
        padding: 2.5rem 0;
    }

    .home-services__intro {
        margin-bottom: 1.75rem;
    }

    .home-services__divider {
        margin: 1rem auto 0.9rem;
    }

    .service-panel__head {
        padding: 1rem 1.1rem;
    }

    .service-panel__body {
        padding: 0.85rem 1rem;
    }

    .service-panel__row--compact {
        grid-template-columns: 1fr auto;
    }

    .service-panel__turnike-pharmacy {
        grid-column: 1 / -1;
    }
}

@media (max-width: 575px) {
    .home-services {
        padding: 2rem 0;
    }

    .service-panel {
        border-radius: 16px;
    }

    .service-panel__head-link {
        width: 100%;
        text-align: center;
        margin-left: 0;
    }

    .service-panel__head-icon {
        width: 40px;
        height: 40px;
        font-size: 1rem;
    }

    .president-hub__content {
        padding: 1.5rem;
    }
}
