@charset "utf-8";

/* =====================================================
   MOBILE OPTIMIZĀCIJA — estrichgridas.lv
   ===================================================== */

/* ── Mazie telefoni (līdz 575px) ── */
@media (max-width: 575px) {
    .container {
        width: 100%;
        max-width: 100%;
        padding-left: 15px;
        padding-right: 15px;
    }
}

/* ── Visi telefoni (līdz 767px) ── */
@media (max-width: 767px) {

    /* --- Top bar --- */
    .top-bar {
        display: none;
    }

    /* --- Navbar --- */
    .header {
        background-color: rgba(0,0,0,0.95);
    }

    .navbar-nav .nav-link {
        font-size: 16px !important;
        padding: 10px 15px !important;
    }

    /* --- Hero sekcija --- */
    .slider-banner .slider-table .slider-vm h1 {
        color: #fff;
        font-size: 20px;
    }

    .slider-banner .slider-table .slider-vm p {
        margin-bottom: 5px;
        font-size: 13px;
    }

    .slider-banner .slides img {
        height: 450px;
    }

    .main-slider .flex-direction-nav a {
        font-size: 20px;
    }

    .mouse-down {
        bottom: 20px;
    }

    /* --- Vispārīgie sadaļu atkāpumi --- */
    .all-space {
        padding: 40px 0;
    }

    .height-60 { height: 30px; }
    .height-40 { height: 20px; }
    .height-30 { height: 15px; }

    /* --- Par mums --- */
    .h1, h1 {
        font-size: 22px;
    }

    .inner {
        margin-bottom: 30px;
    }

    /* --- Skaitītāji (gadi) --- */
    .counter-section {
        width: 100%;
        min-height: auto;
        padding: 50px 15px 30px;
        overflow: visible !important;
    }

    .counter-section .container,
    .counter-section .row,
    .counter-section .col-lg-12 {
        overflow: visible !important;
    }

    .counter .count {
        font-size: 32px;
        line-height: 40px;
    }

    .counter {
        font-size: 15px;
        margin-bottom: 15px;
    }

    /* --- Sauklis (parallax) --- */
    .parallax-text {
        font-size: 16px !important;
        line-height: 1.5 !important;
        white-space: normal !important;
        padding: 0 20px;
    }

    .slogan-section {
        min-height: 120px;
        padding: 30px 15px !important;
    }

    /* --- Pakalpojumi --- */
    .services-list .content {
        text-align: left;
    }

    .services-list li {
        padding: 15px 10px;
    }

    /* --- Galerija --- */
    .gallery-grid {
        grid-template-columns: repeat(2, 1fr) !important;
        gap: 6px;
        padding: 6px;
    }

    .work-wrapper img {
        height: 170px;
        display: block;
        width: 100%;
        object-fit: cover;
    }

    /* Overlay — vienmēr redzams mobilajā, fiksēts apakšā */
    .work-wrapper {
        overflow: visible !important;
        position: relative !important;
    }

    .card-overlay {
        display: flex !important;
        opacity: 1 !important;
        background: linear-gradient(to top, rgba(0,0,0,0.92) 0%, rgba(0,0,0,0.3) 100%) !important;
        border: none !important;
        position: absolute !important;
        top: auto !important;
        left: 0 !important;
        right: 0 !important;
        bottom: 0 !important;
        width: 100% !important;
        height: auto !important;
        min-height: 48px !important;
        padding: 6px 6px 8px !important;
        align-items: flex-end !important;
        justify-content: center !important;
        overflow: hidden !important;
        box-sizing: border-box !important;
    }

    .overlay-inner {
        position: static !important;
        transform: none !important;
        width: 100% !important;
        text-align: center !important;
    }

    .card-overlay h4.base {
        font-size: 9px !important;
        line-height: 1.25 !important;
        margin: 0 auto !important;
        color: #fff !important;
        text-align: center !important;
        word-break: break-word !important;
        white-space: normal !important;
        overflow: hidden !important;
        display: -webkit-box !important;
        -webkit-line-clamp: 3 !important;
        -webkit-box-orient: vertical !important;
    }

    .card-overlay .line,
    .card-overlay p {
        display: none !important;
    }

    /* Palielinājuma ikona — mazāka uz telefona */
    .work-wrapper .overlay-inner::after,
    .work-wrapper .card-overlay-inner::after {
        font-size: 13px !important;
        margin-top: 4px !important;
    }

    /* --- Parallax atspējots uz telefona --- */
    .bg-parallax,
    .jarallax,
    .jarallax-container {
        background-attachment: scroll !important;
        transform: none !important;
        will-change: auto !important;
    }

    /* --- Karte --- */
    #projects-map {
        height: 320px !important;
    }

    /* --- Komanda --- */
    .team .team-img {
        background-size: cover;
        height: 220px;
        margin-bottom: 15px;
    }

    /* --- Kalkulators --- */
    .btn1.container2 {
        display: flex;
        flex-direction: column;
        width: 100%;
        padding: 0 10px;
    }

    .column {
        width: 100% !important;
        margin-bottom: 12px;
    }

    .custom-select, .btn2 {
        width: 100% !important;
        max-width: 100%;
    }

    /* --- FAQ --- */
    .faq-section {
        padding: 20px 0;
    }

    .faq_question {
        font-size: 14px;
        padding: 12px 15px;
    }

    /* --- Kontakti --- */
    #contact .col-md-6 {
        margin-bottom: 20px;
    }

    #contact .contact {
        text-align: center;
    }

    /* --- Forma --- */
    .form-control {
        font-size: 14px;
    }

    /* --- Footer --- */
    .footer-widget-social ul {
        text-align: center;
        padding: 0;
    }

    .footer-widget-social a {
        border-radius: 50%;
        font-size: 14px;
        line-height: 15px;
        padding: 8px;
        width: 30px;
        height: 30px;
    }

    .f-b {
        text-align: center;
        margin-bottom: 10px;
    }

    /* --- Atpakaļ uz augšu poga --- */
    .back-to-top {
        bottom: 15px;
        right: 15px;
        width: 36px;
        height: 36px;
        font-size: 13px;
        border-radius: 50%;
    }

    /* --- LRTK logo --- */
    div[style*="lrtk"] img,
    img[src="images/lrtk.png"] {
        max-height: 60px !important;
    }

    /* --- Btn --- */
    .btn-lg {
        padding: 10px 15px;
        font-size: 13px;
    }

    /* --- Sekciju virsraksti --- */
    .section-heading {
        font-size: 20px;
    }
}

/* ── Planšetes (768px – 991px) ── */
@media (min-width: 768px) and (max-width: 991px) {

    .all-space {
        padding: 50px 0;
    }

    .parallax-text {
        font-size: 1.4rem !important;
        white-space: normal !important;
        padding: 0 30px;
    }

    .gallery-grid {
        grid-template-columns: repeat(3, 1fr);
    }

    #projects-map {
        height: 400px !important;
    }

    .counter .count {
        font-size: 36px;
    }

    .navbar-nav .nav-link {
        font-size: 14px !important;
    }
}
