/* ==========================================================================
   CityNet — full-screen video hero (jumbotron)
   ========================================================================== */

html {
    scroll-behavior: smooth;
}

.video-cases {
    scroll-margin-top: 50px; /* 50px yuqoriroqda to'xtaydi */
}
.tariff {
    scroll-margin-top: 150px; /* 50px yuqoriroqda to'xtaydi */
}
.my-img-th{
    width: 100%;
}

.hero-video {
    position: relative;
    width: 100%;
    max-width: 100%;
    height: 100vh;
    min-height: 560px;
    /* pull under the fixed header so the video fills from the very top (0,0) */
    margin-top: -92px;
    padding: 0;
    overflow: hidden;
    display: flex;
    align-items: end;
}

/* Video fills the whole section, edge to edge (top/right/bottom/left = 0) */
.hero-video__media {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center;
    z-index: 1;
    /* poster stays crisp until the video is ready */
    background: #091c43 center/cover no-repeat;
}

/* Flat overlay on top of the video, 0.3 opacity */
.my-opacity {
    position: absolute;
    inset: 0;
    z-index: 2;
    background: #091c43;
    opacity: 0.3;
    pointer-events: none;
}

/* Second overlay: gradient from the bottom (70%) fading to 10% at the center */
.my-opacity-2 {
    position: absolute;
    inset: 0;
    z-index: 2;
    pointer-events: none;
    background: linear-gradient(to top,
            rgba(9, 28, 67, 0.7) 0%,
            rgba(9, 28, 67, 0.1) 50%,
            rgba(9, 28, 67, 0) 100%);
}

/* Content sits inside the same container as the rest of the page */
.hero-video__content {
    position: relative;
    z-index: 3;
    width: 100%;
    color: #fff;
}

.hero-video__inner {
    text-align: left;
}

.hero-video__title {
    font-size: clamp(24px, 4vw, 36px);
    line-height: 1.1;
    font-weight: 800;
    margin: 0 0 20px;
    max-width: 750px;
    text-transform: uppercase;
    text-shadow: 0 4px 24px rgba(0, 0, 0, 0.35);
}

.hero-video__text {
    font-size: clamp(15px, 1.6vw, 24px);
    line-height: 1.6;
    margin: 0;
    opacity: 0.95;
    max-width: 640px;
 ;
    text-shadow: 0 2px 12px rgba(0, 0, 0, 0.35);
}

/* Three rounded outlined buttons under the hero text — single row */
.hero-video__buttons {
    display: flex;
    justify-content: end;
    flex-wrap: nowrap;
    gap: 16px;
    /*margin-top: 32px;*/
    margin-top: -32px;
    margin-bottom: 50px;
}

.hero-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    white-space: nowrap;
    padding: 14px 28px;
    border: 1.5px solid rgba(255, 255, 255, 0.8);
    border-radius: 999px;
    color: #fff;
    font-size: clamp(13px, 1.05vw, 16px);
    font-weight: 600;
    line-height: 1;
    text-decoration: none;
    background: transparent;
    transition: background 0.25s ease, border-color 0.25s ease, color 0.25s ease;
}

.hero-btn:hover {
    background: rgba(255, 255, 255, 0.15);
    border-color: #fff;
}

/* Animated scroll-down arrow, centered at the bottom */
.hero-video__scroll {
    position: absolute;
    left: 50%;
    bottom: 32px;
    transform: translateX(-50%);
    z-index: 3;
    display: flex;
    width: 48px;
    height: 48px;
    align-items: center;
    justify-content: center;
    color: #fff;
    cursor: pointer;
    background: transparent;
    border: none;
    animation: hero-bounce 1.8s ease-in-out infinite;
    transition: opacity 0.3s ease;
}

.hero-video__scroll:hover {
    opacity: 0.7;
}

.hero-video__scroll svg {
    width: 40px;
    height: 40px;
    filter: drop-shadow(0 2px 8px rgba(0, 0, 0, 0.4));
}

@keyframes hero-bounce {
    0%, 20%, 50%, 80%, 100% {
        transform: translateX(-50%) translateY(0);
    }
    40% {
        transform: translateX(-50%) translateY(-14px);
    }
    60% {
        transform: translateX(-50%) translateY(-7px);
    }
}

@media (max-width: 768px) {
    .hero-video {
        margin-top: -71px;
    }
    .hero-video__inner {
        margin: 0 auto;
        text-align: center;
    }
    .hero-video__buttons {
        flex-wrap: wrap;
        justify-content: center;
        gap: 12px;
    }
    .hero-btn {
        padding: 12px 18px;
    }
    .hero-video__scroll {
        bottom: 20px;
    }
}

@media (prefers-reduced-motion: reduce) {
    .hero-video__scroll {
        animation: none;
    }
}

/* ==========================================================================
   Shared icon-card grid — IT услуги / Оборудование / Интернет-сервисы
   6 equal-height cards, icon on top, title below (colors unchanged)
   ========================================================================== */
.it-services,
.equipment,
.internet-services {
    padding: 55px 0 15px;
}

.svc-grid {
    display: grid;
    grid-template-columns: repeat(6, 1fr);
    grid-auto-rows: 1fr;
    gap: 20px;
    margin-top: 34px;
}

.svc-card {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: flex-start;
    gap: 18px;
    height: 100%;
    min-height: 176px;
    padding: 30px 14px;
    border-radius: 20px;
    text-decoration: none;
    /* same brand blue gradient used across the site */
    background: linear-gradient(84.64deg, #136bff -18.08%, #00bcff 90.14%);
    box-shadow: 0px 0px 9.8px 0px rgba(0, 188, 255, 0.5);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.svc-card:hover {
    transform: translateY(-6px);
    box-shadow: 0 10px 26px rgba(0, 188, 255, 0.55);
}

.svc-card__icon {
    width: 126px;
    height: 126px;
    flex: 0 0 auto;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-top: 8px;
}

.svc-card__icon svg {
    width: 100%;
    height: 100%;
    /* crisp neon glow around the thin line icons */
    filter: drop-shadow(0 0 2px rgba(255, 255, 255, 0.95))
            drop-shadow(0 0 6px rgba(150, 230, 255, 0.75))
            drop-shadow(0 0 12px rgba(0, 200, 255, 0.45));
}

.svc-card:hover .svc-card__icon svg {
    filter: drop-shadow(0 0 3px rgba(255, 255, 255, 1))
            drop-shadow(0 0 9px rgba(150, 230, 255, 0.9))
            drop-shadow(0 0 16px rgba(0, 200, 255, 0.6));
}

/* product image inside the card (IT услуги / Оборудование) */
.svc-card__img {
    width: 100%;
    height: 104px;
    flex: 0 0 auto;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-top: 4px;
}

.svc-card__img img {
    max-width: 100%;
    max-height: 100%;
    object-fit: contain;
    transition: transform 0.3s ease;
}

.svc-card:hover .svc-card__img img {
    transform: scale(1.06);
}

.svc-card__title {
    color: #fff;
    font-family: "Lato", sans-serif;
    font-size: 15px;
    font-weight: 500;
    line-height: 1.35;
    text-align: center;
    /* reserve two lines so single/double-line titles keep cards aligned */
    min-height: 2.7em;
    display: flex;
    align-items: center;
    justify-content: center;
}

@media (max-width: 1100px) {
    .svc-grid {
        grid-template-columns: repeat(3, 1fr);
    }
}

@media (max-width: 600px) {
    .svc-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 14px;
    }
    .svc-card {
        min-height: 150px;
        padding: 24px 10px;
    }
}

/* ==========================================================================
   Последние новости — 4 cards in a row, image on top (colors unchanged)
   ========================================================================== */
.news .news__cards {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 24px;
    max-width: 100%;
    margin: 34px 0 35px;
}

.news .news__cards__card {
    position: relative;
    box-sizing: border-box;
    flex-direction: column;
    align-items: stretch;
    justify-content: flex-start;
    gap: 16px;
    padding: 18px 18px 50px;
    border: 1px solid rgba(148, 158, 199, 0.28);
    border-radius: 18px;
    background: rgba(255, 255, 255, 0.015);
    transition: border-color 0.3s ease, transform 0.3s ease, background 0.3s ease;
}

.news .news__cards__card:hover {
    border-color: #00bcff;
    background: rgba(0, 188, 255, 0.04);
    transform: translateY(-4px);
}

.news .news__cards__card-img {
    box-sizing: border-box;
    width: 100%;
    min-width: 0;
    max-width: 100%;
    height: 180px;
    min-height: 180px;
    max-height: 180px;
    border-radius: 12px;
}

.news .news__cards__card-img img {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: 12px;
}

.news .news__cards__card__content {
    gap: 10px;
    padding: 0 2px;
}

/* date sits at the top-left, arrow is pinned to the bottom-right corner */
.news .news__cards__card__content .news__card__row {
    display: block;
}

.news .news__cards__card__content .news__card__row .arrow-up {
    position: absolute;
    right: 16px;
    bottom: 16px;
    margin-top: 0;
    width: 18px;
    height: 18px;
}

.news .news__cards__card__content .news__card__text p {
    font-size: 16px;
    line-height: 1.4;
}

.news .news-btn {
    display: flex;
    width: fit-content;
    align-items: center;
    justify-content: center;
    margin: 8px auto 0;
}

@media (max-width: 1100px) {
    .news .news__cards {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 574px) {
    .news .news__cards {
        grid-template-columns: 1fr;
    }
}

/* ==========================================================================
   Портфолио / видео кейсы — 4 video-case cards with play button
   ========================================================================== */
.video-cases {
    padding: 55px 0 15px;
}

.video-cases__grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 22px;
    margin-top: 34px;
}

.vcase-card {
    display: flex;
    flex-direction: column;
    width: 100%;
    text-align: left;
    cursor: pointer;
    background: transparent;
    border: none;
    padding: 0;
    font: inherit;
    color: inherit;
}

.vcase-card__media {
    position: relative;
    /* taller preview than a plain 16:9 thumbnail */
    aspect-ratio: 4 / 3.4;
    border-radius: 16px;
    overflow: hidden;
    background-color: #0d1a3a;
    background-size: cover;
    background-position: center;
    border: 1px solid rgba(255, 255, 255, 0.12);
    transition: border-color 0.3s ease, transform 0.3s ease;
}

.vcase-card:hover .vcase-card__media {
    transform: translateY(-5px);
    border-color: rgba(0, 188, 255, 0.6);
}

/* gradient behind the overlaid title/content at the bottom of the card */
.vcase-card__media::after {
    content: "";
    position: absolute;
    inset: 0;
    z-index: 1;
    background: linear-gradient(to top,
            rgba(6, 15, 38, 0.92) 0%,
            rgba(6, 15, 38, 0.6) 28%,
            rgba(6, 15, 38, 0.12) 55%,
            rgba(6, 15, 38, 0) 75%);
    pointer-events: none;
}

.vcase-card__play {
    position: absolute;
    top: 42%;
    left: 50%;
    transform: translate(-50%, -50%);
    z-index: 2;
    width: 58px;
    height: 58px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.18);
    border: 1.5px solid rgba(255, 255, 255, 0.85);
    backdrop-filter: blur(2px);
    transition: background 0.3s ease, transform 0.3s ease;
}

.vcase-card:hover .vcase-card__play {
    background: rgba(0, 188, 255, 0.35);
    transform: translate(-50%, -50%) scale(1.08);
}

.vcase-card__play svg {
    width: 26px;
    height: 26px;
    margin-left: 3px;
}

/* title/content overlaid on the video, pinned to the bottom */
.vcase-card__content {
    position: absolute;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 2;
    padding: 20px 20px 20px;
    text-align: left;
}

.vcase-card__title {
    color: #fff;
    font-family: "Lato", sans-serif;
    font-size: 16px;
    font-weight: 700;
    line-height: 1.3;
    margin-bottom: 6px;
}

.vcase-card__sub {
    color: #c4ccdf;
    font-family: "Lato", sans-serif;
    font-size: 13px;
    font-weight: 400;
    line-height: 1.35;
}

@media (max-width: 1100px) {
    .video-cases__grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 574px) {
    .video-cases__grid {
        grid-template-columns: 1fr;
    }
}

/* ==========================================================================
   Video-case modal — reused for any Портфолио card
   ========================================================================== */
.vcase-modal {
    position: fixed;
    inset: 0;
    z-index: -1;
    opacity: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 30px;
    transition: opacity 0.25s ease;
}

.vcase-modal--show {
    z-index: 1000;
    opacity: 1;
}

.vcase-modal__backdrop {
    position: absolute;
    inset: 0;
    background: rgba(9, 15, 40, 0.85);
}

.vcase-modal__dialog {
    position: relative;
    z-index: 1;
    width: 100%;
    max-width: 960px;
    background: #12173a;
    border-radius: 20px;
    padding: 28px;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.5);
}

.vcase-modal__close {
    position: absolute;
    right: 24px;
    top: 24px;
    width: 24px;
    height: 24px;
    background: transparent;
    border: none;
    cursor: pointer;
    z-index: 2;
}

.vcase-modal__close path {
    transition: 300ms;
}

.vcase-modal__close:hover path {
    fill: #00bcff;
}

.vcase-modal__title {
    color: #fff;
    font-family: "Lato", sans-serif;
    font-size: 20px;
    font-weight: 700;
    margin-bottom: 18px;
    padding-right: 30px;
}

.vcase-modal__video {
    display: block;
    width: 100%;
    max-height: 70vh;
    border-radius: 14px;
    background: #000;
}

@media (max-width: 600px) {
    .vcase-modal {
        padding: 14px;
    }
    .vcase-modal__dialog {
        padding: 18px;
    }
    .vcase-modal__title {
        font-size: 16px;
    }
}
