/**
 * Kamal Pankaj - Dynamic Portfolio & Resume Website
 * Comprehensive Multi-Device & Mobile Responsiveness Stylesheet
 * 
 * Breakpoints Covered:
 *   - Ultra-Wide / 4K (> 1400px)
 *   - Standard Desktop / Laptop (1200px - 1399px)
 *   - Medium Laptop / Tablet Landscape (992px - 1199px)
 *   - Tablet Portrait (768px - 991px)
 *   - Phablets / Large Phones (576px - 767px)
 *   - Standard Mobile Phones (375px - 575px)
 *   - Compact Mobile Phones (320px - 374px)
 */

/* ==========================================================================
   Global Overflow & Fluid Viewport Safeguards
   ========================================================================== */
html, body {
    max-width: 100%;
    overflow-x: hidden;
    position: relative;
    -webkit-text-size-adjust: 100%;
}

img, svg, video {
    max-width: 100%;
    height: auto;
}

/* ==========================================================================
   1. Ultra-Wide Screens (Min 1400px)
   ========================================================================== */
@media (min-width: 1400px) {
    .container {
        max-width: 1320px;
    }
    .hero-name-heading {
        font-size: 3.8rem;
    }
    .hero-photo-container {
        width: 420px;
        height: 420px;
        max-width: 85vw;
        max-height: 85vw;
    }
    .hero-photo-frame {
        width: 100%;
        height: 100%;
    }
}

/* ==========================================================================
   2. Large Laptops & Desktops (Max 1199.98px)
   ========================================================================== */
@media (max-width: 1199.98px) {
    .hero-name-heading {
        font-size: 2.85rem;
    }
    .hero-typing-box {
        font-size: 1.15rem;
    }
    .hero-photo-container {
        width: 340px;
        height: 340px;
        max-width: 80vw;
        max-height: 80vw;
        aspect-ratio: 1 / 1;
        margin: 0 auto;
        display: block;
    }
    .badge-tech-pos {
        left: -15px;
        top: 0;
    }
    .badge-nontech-pos {
        right: -15px;
        bottom: 20px;
    }
    .badge-exp-pos {
        left: 20px;
        bottom: -20px;
    }
    .section-title {
        font-size: 2.1rem;
    }
}

/* ==========================================================================
   3. Tablets & Small Laptops (Max 991.98px)
   ========================================================================== */
@media (max-width: 991.98px) {
    /* Navbar Collapse Drawer */
    .navbar-collapse {
        background: linear-gradient(145deg, #0B0F19 0%, #030712 100%);
        padding: 1.25rem 1.4rem;
        border-radius: 16px;
        margin-top: 0.85rem;
        border: 1px solid rgba(255, 255, 255, 0.12);
        box-shadow: 0 15px 40px rgba(0, 0, 0, 0.65);
    }
    .navbar-nav {
        flex-direction: column;
        align-items: stretch;
        gap: 0.35rem;
        width: 100%;
        margin-bottom: 1rem !important;
    }
    .navbar-nav .nav-item {
        width: 100%;
        margin: 0;
    }
    .navbar-nav .nav-link {
        padding: 0.75rem 1rem !important;
        width: 100%;
        display: flex;
        align-items: center;
        justify-content: space-between;
    }
    .dropdown-menu {
        position: static !important;
        transform: none !important;
        background: rgba(255, 255, 255, 0.04) !important;
        border: 1px solid rgba(255, 255, 255, 0.08) !important;
        box-shadow: none !important;
        margin: 0.5rem 0 !important;
        padding: 0.5rem !important;
        width: 100%;
    }
    .dropdown-menu::before {
        display: none !important;
    }
    .navbar-collapse .d-flex.align-items-center {
        width: 100%;
        justify-content: stretch;
    }
    .navbar-collapse .dropdown {
        width: 100%;
    }
    .navbar-collapse .dropdown button {
        width: 100%;
    }

    /* Hero Layout Centering */
    .hero-fullscreen {
        padding: 3.5rem 0;
        text-align: center;
    }
    .hero-name-heading {
        font-size: 2.5rem;
    }
    .hero-typing-box {
        justify-content: center;
    }
    .hero-description {
        margin-left: auto;
        margin-right: auto;
    }
    .hero-content .d-flex.flex-wrap {
        justify-content: center;
    }
    
    /* Hero Photo - Perfect Symmetric Circle */
    .hero-photo-container {
        width: 290px;
        height: 290px;
        max-width: 75vw;
        max-height: 75vw;
        aspect-ratio: 1 / 1;
        margin: 1.5rem auto 2.5rem;
        display: block;
    }
    .floating-badge {
        padding: 0.55rem 0.85rem;
    }
    .badge-label {
        font-size: 0.8rem;
    }
    .badge-sub {
        font-size: 0.7rem;
    }
    .badge-icon-wrap {
        width: 32px;
        height: 32px;
        font-size: 0.95rem;
    }
    .badge-tech-pos {
        top: -5px;
        left: -10px;
    }
    .badge-nontech-pos {
        bottom: 5px;
        right: -10px;
    }
    .badge-exp-pos {
        display: none;
    }

    /* Inner Page Headers */
    .inner-page-header {
        padding: 3.5rem 0 2.5rem;
        text-align: center;
    }
    .inner-page-header .d-flex.flex-wrap {
        justify-content: center;
    }

    /* Footer Responsive */
    .main-footer {
        padding: 3.5rem 0 1.5rem;
        text-align: center;
    }
    .footer-brand {
        display: inline-flex;
        margin: 0 auto 1rem;
    }
    .main-footer p {
        margin-left: auto;
        margin-right: auto;
    }
    .main-footer .d-flex.gap-2 {
        justify-content: center;
        margin-bottom: 2rem;
    }
    .footer-heading {
        margin-top: 1rem;
    }
    .footer-bottom {
        flex-direction: column;
        gap: 0.75rem;
        text-align: center;
    }
}

/* ==========================================================================
   4. Phablets & Mobile Landscape (Max 767.98px)
   ========================================================================== */
@media (max-width: 767.98px) {
    .navbar-brand-logo {
        width: 42px;
        height: 42px;
        border-radius: 10px;
    }
    .brand-text {
        font-size: 1.15rem;
    }
    .section-header {
        margin-bottom: 2.2rem;
    }
    .section-title {
        font-size: 1.85rem;
    }
    .section-subtitle {
        font-size: 0.75rem;
    }
    .section-desc {
        font-size: 0.9rem;
    }

    .hero-name-heading {
        font-size: 2.15rem;
        letter-spacing: -0.5px;
    }
    .hero-typing-box {
        font-size: 1.05rem;
        min-height: 2rem;
    }

    /* Hero Photo - Perfect Symmetric Circle */
    .hero-photo-container {
        width: 250px;
        height: 250px;
        max-width: 70vw;
        max-height: 70vw;
        aspect-ratio: 1 / 1;
        margin: 1rem auto 2rem;
        display: block;
    }
    .hero-photo-frame {
        padding: 5px;
    }
    .hero-photo-orbit,
    .hero-photo-orbit-inner {
        display: none !important; /* Prevent horizontal overflow & shape distortion */
    }
    .floating-badge {
        display: none !important; /* Hide floating badges on small screens for ultra-clean look */
    }

    /* Skills Filter Pills Horizontal Scroll */
    .skill-filter-pills {
        display: flex;
        flex-wrap: nowrap !important;
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
        padding-bottom: 8px;
        gap: 0.4rem;
        scrollbar-width: thin;
    }
    .skill-filter-pills::-webkit-scrollbar {
        height: 4px;
    }
    .skill-filter-pills::-webkit-scrollbar-thumb {
        background: rgba(255, 255, 255, 0.2);
        border-radius: 4px;
    }
    .skill-filter-btn {
        flex-shrink: 0;
        white-space: nowrap;
        font-size: 0.78rem;
        padding: 0.35rem 0.8rem;
    }

    /* Skills Grid */
    .tech-skills-grid {
        padding: 1.25rem 1rem;
    }
    .skill-grid-item {
        width: 100%;
    }

    /* Timeline */
    .timeline {
        padding-left: 1.5rem;
    }
    .timeline::before {
        left: 7px;
    }
    .timeline-dot {
        left: -1.5rem;
        width: 18px;
        height: 18px;
        top: 6px;
    }
    .timeline-card {
        padding: 1.25rem 1.2rem;
    }

    /* Floating Action Buttons */
    .whatsapp-float-btn {
        width: 50px;
        height: 50px;
        font-size: 1.65rem;
        bottom: 18px;
        left: 16px;
    }
    .back-to-top-btn {
        width: 48px;
        height: 48px;
        bottom: 18px;
        right: 16px;
    }
    .whatsapp-float-btn .wa-tooltip {
        display: none; /* Mobile touch friendly without hover tooltip */
    }

    /* CTA Banner Floating Card */
    .cta-banner-section {
        padding: 2.5rem 0 3.5rem;
    }
    .cta-banner-card {
        padding: 2.5rem 1.4rem;
        border-radius: 16px;
    }
    .cta-banner-card h2 {
        font-size: 1.5rem;
    }
}

/* ==========================================================================
   5. Standard Mobile Portrait (Max 575.98px)
   ========================================================================== */
@media (max-width: 575.98px) {
    .hero-fullscreen {
        padding: 2.5rem 0 3rem;
    }
    .hero-name-heading {
        font-size: 1.85rem;
    }
    .hero-badge-pill {
        font-size: 0.8rem;
        padding: 0.3rem 0.8rem;
    }
    
    /* Hero Photo - Perfect Symmetrical Circle */
    .hero-photo-container {
        width: 220px;
        height: 220px;
        max-width: 68vw;
        max-height: 68vw;
        aspect-ratio: 1 / 1;
        margin: 1rem auto 1.8rem;
        display: block;
    }
    .hero-photo-frame {
        padding: 4px;
        border-width: 3px;
    }
    .hero-description {
        font-size: 0.92rem;
        line-height: 1.65;
    }

    /* Hero Action Buttons - Full Width Touch */
    .hero-content .d-flex.flex-wrap .btn,
    .hero-content .d-flex.flex-wrap .dropdown,
    .hero-content .d-flex.flex-wrap .dropdown button {
        width: 100%;
        justify-content: center;
    }

    .profile-choice-box {
        padding: 1.25rem 1.15rem;
        border-radius: 14px;
    }
    .choice-title {
        font-size: 1.15rem;
    }
    .choice-desc {
        font-size: 0.82rem;
    }

    .about-avatar-frame {
        width: 210px;
        height: 210px;
        max-width: 65vw;
        max-height: 65vw;
        aspect-ratio: 1 / 1;
        margin: 0 auto;
        display: block;
    }
    
    .counter-box {
        padding: 1.25rem 0.85rem;
    }
    .counter-num {
        font-size: 2rem;
    }
    .counter-title {
        font-size: 0.8rem;
    }

    /* Filter Button Group */
    .filter-btn-group {
        display: flex;
        flex-wrap: nowrap !important;
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
        justify-content: flex-start !important;
        padding-bottom: 8px;
        margin-bottom: 2rem !important;
        scrollbar-width: none;
    }
    .filter-btn-group::-webkit-scrollbar {
        display: none;
    }
    .filter-btn-group .btn-filter {
        flex-shrink: 0;
        white-space: nowrap;
        font-size: 0.82rem;
        padding: 0.45rem 1rem;
    }

    /* Project Cards */
    .project-img-wrapper {
        height: 170px;
    }
    .project-body {
        padding: 1.25rem;
    }

    /* Contact Form & Info Card */
    .contact-info-card {
        padding: 1.8rem 1.3rem;
        border-radius: 16px;
    }
    .contact-info-item {
        padding: 0.65rem 0.75rem;
        gap: 0.75rem;
    }
    .contact-icon-box {
        width: 38px;
        height: 38px;
        font-size: 1.05rem;
    }
    .contact-value {
        font-size: 0.88rem;
    }
}

/* ==========================================================================
   6. Compact Mobile Screens (Max 375px)
   ========================================================================== */
@media (max-width: 375px) {
    .navbar-brand {
        font-size: 1.15rem;
    }
    .brand-badge {
        font-size: 0.8rem;
        padding: 0.2rem 0.45rem;
    }
    .hero-name-heading {
        font-size: 1.65rem;
    }
    
    /* Hero Photo - Perfect Symmetrical Circle */
    .hero-photo-container {
        width: 180px;
        height: 180px;
        max-width: 62vw;
        max-height: 62vw;
        aspect-ratio: 1 / 1;
        margin: 0.8rem auto 1.5rem;
        display: block;
    }
    .about-avatar-frame {
        width: 175px;
        height: 175px;
        max-width: 60vw;
        max-height: 60vw;
        aspect-ratio: 1 / 1;
        margin: 0 auto;
        display: block;
    }
    .btn {
        font-size: 0.88rem;
        padding: 0.55rem 1rem;
    }
}

