/* ==========================================
   ANA SAYFA — hizmetler
   Solda Kurumsal bölümü gibi büyük tipografili, açılır hizmet listesi;
   sağda hero gibi noktalı gri, yapışkan önizleme kartı (dev kelime, çizim,
   dönen slogan rozeti, koyu buton).
   ========================================== */

.ugr-services {
    --ink: #0d0d0d;
    --brand: #ffdd00;
    --muted: #c9c9c9;
    --line: rgba(13, 13, 13, 0.14);

    position: relative;
    margin: 0 12px 12px;
    padding: clamp(88px, 13vh, 130px) clamp(16px, 2.5vw, 32px) clamp(48px, 8vh, 80px);
    /* Sıralama: Projeler beyaz → Hizmetler gri */
    background: #f4f3f1;
    color: var(--ink);
    border-radius: 28px;
}

/* --- Köşe etiketleri (Kurumsal / Projeler ile aynı) --- */
.ugr-services__eyebrow,
.ugr-services__count {
    position: absolute;
    top: clamp(24px, 4vh, 40px);
    margin: 0;
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 0.75rem;
    font-weight: 600;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.ugr-services__eyebrow {
    left: clamp(16px, 2.5vw, 32px);
}

.ugr-services__eyebrow span {
    width: 8px;
    height: 8px;
    background: var(--brand);
    box-shadow: 0 0 0 1px var(--ink);
}

.ugr-services__count {
    right: clamp(16px, 2.5vw, 32px);
}

.ugr-services__count strong {
    font-size: 1rem;
    font-weight: 900;
    letter-spacing: -0.02em;
}

/* --- Yerleşim --- */
.ugr-services__layout {
    display: grid;
    grid-template-columns: minmax(0, 1.12fr) minmax(0, 0.88fr);
    gap: clamp(28px, 4.5vw, 80px);
    align-items: start;
}

.ugr-services__title {
    margin: 0 0 clamp(28px, 5vh, 48px);
    max-width: 13ch;
    font-size: clamp(2.2rem, 4.6vw, 4.6rem);
    font-weight: 900;
    line-height: 0.98;
    letter-spacing: -0.055em;
    text-wrap: balance;
}

/* --- Hizmet listesi --- */
.ugr-services__list {
    margin: 0;
    padding: 0;
    list-style: none;
    border-bottom: 1px solid var(--line);
}

.svc-row {
    border-top: 1px solid var(--line);
    opacity: 0;
    translate: 0 24px;
    transition: opacity 0.7s ease, translate 0.9s cubic-bezier(0.16, 1, 0.3, 1);
}

.ugr-services.is-visible .svc-row {
    opacity: 1;
    translate: 0 0;
    transition-delay: calc(var(--i) * 70ms);
}

.svc-row__head {
    display: grid;
    grid-template-columns: 3.4rem minmax(0, 1fr) auto;
    align-items: center;
    gap: 12px;
    padding: clamp(14px, 2.2vh, 22px) 0;
    color: inherit;
    text-decoration: none;
    outline: none;
}

.svc-row__num {
    justify-self: start;
    padding: 4px 8px;
    border-radius: 999px;
    font-size: 0.7rem;
    font-weight: 700;
    letter-spacing: 0.06em;
    color: rgba(13, 13, 13, 0.45);
    transition: background 0.3s ease, color 0.3s ease, box-shadow 0.3s ease;
}

.svc-row__title {
    justify-self: start;
    font-size: clamp(1.35rem, 2.5vw, 2.5rem);
    font-weight: 800;
    line-height: 1.08;
    letter-spacing: -0.045em;
    color: var(--muted);
    transition: color 0.35s ease, translate 0.5s cubic-bezier(0.16, 1, 0.3, 1);
}

/* Aktif satırda her satırın altına sarı fosforlu kalem çizgisi çekilir */
.svc-row__title > span {
    background-image: linear-gradient(var(--brand), var(--brand));
    background-repeat: no-repeat;
    background-position: 0 88%;
    background-size: 0% 0.32em;
    -webkit-box-decoration-break: clone;
    box-decoration-break: clone;
    transition: background-size 0.55s cubic-bezier(0.65, 0, 0.35, 1);
}

.svc-row__arrow {
    display: grid;
    place-items: center;
    width: 44px;
    height: 44px;
    border-radius: 50%;
    box-shadow: inset 0 0 0 1.5px var(--line);
    color: rgba(13, 13, 13, 0.4);
    transition: background 0.3s ease, color 0.3s ease, box-shadow 0.3s ease, transform 0.45s cubic-bezier(0.16, 1, 0.3, 1);
}

.svc-row__arrow svg {
    width: 16px;
    height: 16px;
}

.svc-row__head:hover .svc-row__title {
    color: var(--ink);
}

.svc-row.is-active .svc-row__num {
    background: var(--brand);
    color: var(--ink);
    box-shadow: 0 0 0 1px var(--ink);
}

.svc-row.is-active .svc-row__title {
    color: var(--ink);
    translate: 6px 0;
}

.svc-row.is-active .svc-row__title > span {
    background-size: 100% 0.32em;
}

.svc-row.is-active .svc-row__arrow {
    background: var(--ink);
    color: var(--brand);
    box-shadow: inset 0 0 0 1.5px var(--ink);
    transform: rotate(45deg);
}

.svc-row__head:focus-visible .svc-row__title {
    outline: 2px solid var(--ink);
    outline-offset: 4px;
}

/* Açılan gövde */
.svc-row__body {
    display: grid;
    grid-template-rows: 0fr;
    transition: grid-template-rows 0.55s cubic-bezier(0.65, 0, 0.35, 1);
}

.svc-row.is-active .svc-row__body {
    grid-template-rows: 1fr;
}

.svc-row__inner {
    min-height: 0;
    overflow: hidden;
    padding-left: calc(3.4rem + 12px);
}

/* Alt boşluk içerikte tutulur; kapalı satırda (0fr) hiç yer kaplamaz */
.svc-row__inner::after {
    content: '';
    display: block;
    height: clamp(18px, 3vh, 26px);
}

.svc-row__inner > :first-child {
    margin-top: 0;
}

.svc-row__inner p {
    margin: 0;
    max-width: 54ch;
    font-size: 0.92rem;
    line-height: 1.65;
    color: #4a4a4a;
}

.svc-row__chips {
    margin: 14px 0 0;
    padding: 0;
    list-style: none;
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.svc-row__chips li {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    padding: 6px 12px;
    border-radius: 999px;
    background: #f1f0ee;
    font-size: 0.72rem;
    font-weight: 600;
}

.svc-row__chips li::before {
    content: '';
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: var(--brand);
    box-shadow: 0 0 0 1px var(--ink);
}

/* Çizim yalnızca dar ekranda liste içinde gösterilir */
.svc-row__art {
    display: none;
}

/* --- Önizleme kartı --- */
.ugr-services__preview {
    position: sticky;
    top: 24px;
}

.svc-preview {
    position: relative;
    height: 90vh;
    overflow: hidden;
    container-type: inline-size;
    isolation: isolate;
    border-radius: 28px;
    background-color: #e8e7e5;
    background-image: radial-gradient(rgba(0, 0, 0, 0.07) 1px, transparent 1.2px);
    background-size: 16px 16px;
}

.svc-preview__label {
    position: absolute;
    z-index: 3;
    top: 24px;
    left: 24px;
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 0.72rem;
    font-weight: 600;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.svc-preview__label span {
    width: 8px;
    height: 8px;
    background: var(--brand);
    box-shadow: 0 0 0 1px var(--ink);
}

.svc-preview__label em {
    font-style: normal;
}

.svc-preview__stage {
    position: absolute;
    inset: 0;
}

/* Arkadaki dev soluk kelime (hizmetin ilk kelimesi) */
.svc-preview__word {
    position: absolute;
    z-index: 0;
    left: 50%;
    top: 23%;
    translate: -50% -50%;
    /* Kartın genişliğine göre: uzun kelimeler de sığar */
    font-size: clamp(2.5rem, 12cqi, 7rem);
    font-weight: 900;
    line-height: 1;
    letter-spacing: -0.06em;
    text-transform: uppercase;
    white-space: nowrap;
    color: rgba(13, 13, 13, 0.09);
    transition: opacity 0.25s ease, scale 0.5s cubic-bezier(0.16, 1, 0.3, 1);
}

.svc-preview__word.is-changing {
    opacity: 0;
    scale: 0.92;
}

/* Çizimler: ortadan daire şeklinde açılarak gelir */
.svc-preview__img {
    position: absolute;
    z-index: 1;
    inset: 30% 8% 17%;
    width: 84%;
    height: 75%;
    object-fit: contain;
    mix-blend-mode: multiply;
    filter: brightness(1.12) contrast(1.08);
    opacity: 0;
    clip-path: circle(0% at 50% 55%);
    scale: 0.94;
    transition: clip-path 0.8s cubic-bezier(0.65, 0, 0.35, 1), opacity 0.4s ease, scale 0.9s cubic-bezier(0.16, 1, 0.3, 1);
}

.svc-preview__img.is-active {
    opacity: 1;
    clip-path: circle(80% at 50% 55%);
    scale: 1;
}

/* Dönen slogan rozeti */
.svc-preview__badge {
    position: absolute;
    z-index: 3;
    top: 18px;
    right: 18px;
    width: clamp(92px, 8vw, 118px);
    height: auto;
    overflow: visible;
}

.svc-preview__badge text {
    font-size: 9.4px;
    font-weight: 800;
    letter-spacing: 0.08em;
    fill: var(--ink);
    transform-origin: 60px 60px;
    animation: svc-badge-spin 16s linear infinite;
}

.svc-preview__badge circle {
    fill: var(--brand);
    stroke: var(--ink);
    stroke-width: 1.5;
}

.svc-preview__badge-arrow {
    fill: none;
    stroke: var(--ink);
    stroke-width: 2.4;
    stroke-linecap: round;
    stroke-linejoin: round;
}

@keyframes svc-badge-spin {
    to { transform: rotate(360deg); }
}

/* Hero'daki koyu kutu tarzında buton */
.svc-preview__pill {
    position: absolute;
    z-index: 3;
    left: 50%;
    bottom: 24px;
    translate: -50% 0;
    display: flex;
    align-items: center;
    gap: 12px;
    max-width: calc(100% - 48px);
    height: 58px;
    padding: 0 10px 0 18px;
    border-radius: 12px;
    background: #1c1c1c;
    color: #f2f2f2;
    font-size: 0.9rem;
    font-weight: 500;
    text-decoration: none;
    white-space: nowrap;
    box-shadow: 0 18px 40px -18px rgba(0, 0, 0, 0.55), inset 0 0 0 1px rgba(255, 255, 255, 0.06);
    transition: transform 0.3s ease;
}

.svc-preview__pill > span:nth-child(2) {
    overflow: hidden;
    text-overflow: ellipsis;
}

.svc-preview__pill:hover {
    transform: translateY(-2px);
}

.svc-preview__pill-dot {
    flex: none;
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: var(--brand);
    box-shadow: 0 0 0 4px color-mix(in srgb, var(--brand) 25%, transparent);
}

.svc-preview__pill-btn {
    flex: none;
    display: grid;
    place-items: center;
    width: 38px;
    height: 38px;
    border-radius: 50%;
    background: #4a4a4a;
    transition: background 0.2s ease, color 0.2s ease, transform 0.3s ease;
}

.svc-preview__pill:hover .svc-preview__pill-btn {
    background: var(--brand);
    color: var(--ink);
    transform: rotate(-45deg);
}

.svc-preview__pill-btn svg {
    width: 16px;
    height: 16px;
}

/* --- Dar ekran: önizleme kalkar, çizim liste içinde görünür --- */
@media (max-width: 900px) {
    .ugr-services {
        margin: 0 8px 8px;
    }

    .ugr-services__layout {
        grid-template-columns: 1fr;
    }

    .ugr-services__preview {
        display: none;
    }

    .svc-row__head {
        grid-template-columns: 2.8rem minmax(0, 1fr) auto;
    }

    .svc-row__inner {
        padding-left: 0;
    }

    .svc-row__art {
        display: block;
        height: 220px;
        margin: 16px 0 0;
        padding: 12px;
        border-radius: 18px;
        background-color: #e8e7e5;
        background-image: radial-gradient(rgba(0, 0, 0, 0.07) 1px, transparent 1.2px);
        background-size: 16px 16px;
        box-sizing: border-box;
        isolation: isolate;
    }

    .svc-row__art img {
        display: block;
        width: 100%;
        height: 100%;
        object-fit: contain;
        mix-blend-mode: multiply;
        filter: brightness(1.12) contrast(1.08);
    }
}

@media (prefers-reduced-motion: reduce) {
    .svc-row,
    .svc-row__title,
    .svc-row__body,
    .svc-preview__img,
    .svc-preview__word {
        transition: none;
    }

    .svc-row {
        opacity: 1;
        translate: none;
    }

    .svc-preview__badge text {
        animation: none;
    }
}
