/* Mobile Responsive Optimizations for RehberYapi */

/* Tablet and Mobile */
@media (max-width: 992px) {

    /* Navbar - Tablet */
    .navbar-brand {
        padding: 8px 15px !important;
        height: auto !important;
    }

    .navbar-brand img {
        height: 100px !important;
        width: 125px !important;
    }

    .brand-text {
        font-size: 16px !important;
    }

    .navbar-nav .nav-link {
        padding: 12px 0 !important;
        font-size: 14px !important;
    }

    /* Hero Section */
    .hero-section img {
        height: 500px !important;
    }

    .hero-content h1 {
        font-size: 2rem !important;
    }

    /* Projects */
    .container-xxl {
        padding: 20px 0 !important;
    }

    .rounded.shadow-lg {
        padding: 15px !important;
    }

    /* Project Title */
    .row.align-items-center h4 {
        font-size: 1.3rem !important;
        margin-bottom: 15px !important;
    }

    /* Map Container */
    .map-container iframe {
        height: 200px !important;
        margin-top: 15px;
    }

    /* Photo Grid */
    .photo-frame {
        margin-bottom: 15px;
    }

    .photo-frame img {
        border-radius: 8px;
    }

    /* About Page - Tablet */
    .about-text {
        padding: 30px 20px !important;
    }

    .about-text h1 {
        font-size: 1.8rem !important;
    }

    .about-text p {
        font-size: 1rem !important;
    }

    .about .position-relative {
        min-height: 350px !important;
    }

    .about .position-relative img {
        height: 350px !important;
    }
}

/* Mobile Only */
@media (max-width: 768px) {

    /* Navbar */
    .navbar {
        padding: 0 !important;
    }

    .navbar-brand {
        padding: 8px 12px !important;
        height: auto !important;
        border: none !important;
        display: flex !important;
        align-items: center !important;
        max-width: 75% !important;
    }

    .navbar-brand img {
        height: 55px !important;
        width: 70px !important;
        flex-shrink: 0 !important;
    }

    .navbar-brand .brand-text,
    .brand-text {
        font-size: 11px !important;
        line-height: 1.2 !important;
        margin-left: 8px !important;
        max-width: 130px !important;
        white-space: normal !important;
        word-wrap: break-word !important;
        display: inline-block !important;
    }

    .navbar-toggler {
        padding: 8px 10px !important;
        font-size: 1.2rem !important;
        margin-right: 10px !important;
    }

    .navbar-nav {
        padding: 10px 0 !important;
    }

    .navbar-nav .nav-link {
        padding: 10px 15px !important;
        font-size: 14px !important;
    }

    /* Hide contact button on mobile navbar */
    .navbar .btn.btn-primary {
        display: none !important;
    }

    /* Hero Section */
    .hero-section img {
        height: 350px !important;
    }

    .hero-content h1 {
        font-size: 1.5rem !important;
        padding: 0 15px;
    }

    .hero-content .btn {
        font-size: 14px !important;
        padding: 12px 25px !important;
    }

    /* Projects Section */
    .container-xxl {
        padding: 15px 0 !important;
    }

    .rounded.shadow-lg {
        padding: 10px !important;
        margin: 0 10px;
    }

    /* Project Title and Map - Stack Vertically */
    .row.align-items-center {
        flex-direction: column;
        margin-bottom: 20px !important;
    }

    .row.align-items-center .col-lg-7,
    .row.align-items-center .col-lg-5 {
        width: 100%;
        max-width: 100%;
        padding: 0 !important;
    }

    .row.align-items-center h4 {
        font-size: 1.2rem !important;
        text-align: center;
        margin-bottom: 20px !important;
        margin-top: 10px !important;
        padding: 15px 10px !important;
        display: flex;
        align-items: center;
        justify-content: center;
        min-height: 60px;
    }

    .map-container {
        margin-top: 15px;
        margin-bottom: 15px;
    }

    .map-container iframe {
        height: 250px !important;
        border-radius: 8px;
    }

    /* Photo Grid - 2 Columns on Mobile */
    .row.g-4 {
        gap: 10px !important;
    }

    .col-lg-4.col-md-6.col-sm-6 {
        padding: 5px !important;
    }

    .photo-frame {
        margin-bottom: 10px;
        box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15);
    }

    .photo-frame img {
        height: 150px;
        object-fit: cover;
    }

    /* About Page */
    .about {
        padding: 0 !important;
    }

    .about .col-lg-6 {
        min-height: auto !important;
    }

    .about-text {
        padding: 20px 15px !important;
    }

    .about-text h1 {
        font-size: 1.5rem !important;
        margin-bottom: 20px !important;
    }

    .about-text h6 {
        font-size: 0.9rem !important;
    }

    .about-text p {
        font-size: 0.95rem !important;
        line-height: 1.6 !important;
        margin-bottom: 15px !important;
    }

    .about-text .btn {
        width: 100%;
        max-width: 300px;
        margin: 20px auto 0 !important;
        display: block;
    }

    .about .position-relative {
        min-height: 300px !important;
    }

    .about .position-relative img {
        height: 300px !important;
        object-fit: cover;
    }

    /* Footer */
    .footer {
        padding: 30px 0 !important;
    }

    .footer .col-lg-3,
    .footer .col-md-6 {
        margin-bottom: 20px;
    }

    .footer .col-lg-3:first-child {
        text-align: center !important;
    }

    .footer h4 {
        font-size: 1.1rem;
    }

    .footer p,
    .footer a {
        font-size: 14px;
    }

    .footer .btn-link {
        text-align: left !important;
        padding-left: 0 !important;
    }

    /* Topbar */
    .topbar {
        font-size: 12px;
    }

    /* Back to Top Button */
    .back-to-top {
        width: 45px !important;
        height: 45px !important;
        font-size: 18px !important;
    }

    /* WhatsApp Button */
    .whatsapp-float {
        width: 50px !important;
        height: 50px !important;
        bottom: 70px !important;
        right: 15px !important;
    }
}

/* Small Mobile */
@media (max-width: 480px) {

    /* Hero */
    .hero-section img {
        height: 250px !important;
    }

    .hero-content h1 {
        font-size: 1.2rem !important;
    }

    .hero-content .btn {
        font-size: 12px !important;
        padding: 10px 20px !important;
    }

    /* Projects */
    .rounded.shadow-lg {
        padding: 8px !important;
        margin: 0 5px;
    }

    .row.align-items-center h4 {
        font-size: 1rem !important;
        padding: 12px 8px !important;
        margin-top: 8px !important;
        margin-bottom: 15px !important;
    }

    .map-container iframe {
        height: 200px !important;
    }

    /* Photos - Single Column on Very Small Screens */
    .photo-frame img {
        height: 180px;
    }

    /* About Page - Small Mobile */
    .about-text h1 {
        font-size: 1.3rem !important;
    }

    .about-text p {
        font-size: 0.9rem !important;
    }

    .about .position-relative {
        min-height: 250px !important;
    }

    .about .position-relative img {
        height: 250px !important;
    }

    /* Footer */
    .footer {
        font-size: 13px;
    }

    .footer img {
        height: 100px !important;
        width: 130px !important;
    }
}

/* Landscape Mobile */
@media (max-width: 768px) and (orientation: landscape) {
    .hero-section img {
        height: 300px !important;
    }

    .photo-frame img {
        height: 120px;
    }
}

/* Touch Device Optimizations */
@media (hover: none) and (pointer: coarse) {

    /* Larger touch targets */
    .btn {
        min-height: 44px;
        min-width: 44px;
    }

    .photo-frame {
        cursor: pointer;
    }

    /* Remove hover effects on touch devices */
    .photo-frame:hover {
        transform: none;
    }
}

/* Print Styles */
@media print {

    .navbar,
    .topbar,
    .footer,
    .back-to-top,
    .whatsapp-float {
        display: none !important;
    }

    .hero-section {
        page-break-after: always;
    }

    .container-xxl {
        page-break-inside: avoid;
    }
}