/* ===== COMPREHENSIVE RESPONSIVE FRAMEWORK ===== */
/* Inspired by indonepalexpress.com responsive design patterns */

/* === GLOBAL RESPONSIVE VARIABLES === */
:root {
    /* Breakpoints */
    --mobile-small: 320px;
    --mobile: 480px;
    --tablet: 768px;
    --desktop-small: 991px;
    --desktop: 1200px;
    --desktop-large: 1400px;
    
    /* Responsive spacing */
    --section-padding-mobile: 40px 0;
    --section-padding-tablet: 60px 0;
    --section-padding-desktop: 80px 0;
    
    /* Container responsive padding */
    --container-padding-mobile: 0 15px;
    --container-padding-tablet: 0 20px;
    --container-padding-desktop: 0 25px;
    
    /* Typography responsive scaling */
    --h1-mobile: 1.8rem;
    --h1-tablet: 2.5rem;
    --h1-desktop: 3.5rem;
    
    --h2-mobile: 1.5rem;
    --h2-tablet: 2rem;
    --h2-desktop: 2.5rem;
    
    --h3-mobile: 1.2rem;
    --h3-tablet: 1.4rem;
    --h3-desktop: 1.6rem;
    
    --body-mobile: 0.9rem;
    --body-tablet: 1rem;
    --body-desktop: 1.1rem;
}

/* === RESPONSIVE CONTAINER SYSTEM === */
.container {
    width: 100%;
    margin: 0 auto;
    padding: var(--container-padding-mobile);
}

@media (min-width: 576px) {
    .container { max-width: 540px; }
}

@media (min-width: 768px) {
    .container { 
        max-width: 720px; 
        padding: var(--container-padding-tablet);
    }
}

@media (min-width: 992px) {
    .container { max-width: 960px; }
}

@media (min-width: 1200px) {
    .container { 
        max-width: 1140px; 
        padding: var(--container-padding-desktop);
    }
}

@media (min-width: 1400px) {
    .container { max-width: 1320px; }
}

/* === RESPONSIVE GRID SYSTEM === */
.row {
    display: flex;
    flex-wrap: wrap;
    margin: 0 -15px;
}

.col {
    flex: 1;
    padding: 0 15px;
}

/* Mobile First Grid */
.col-12 { width: 100%; }
.col-11 { width: 91.66666667%; }
.col-10 { width: 83.33333333%; }
.col-9 { width: 75%; }
.col-8 { width: 66.66666667%; }
.col-7 { width: 58.33333333%; }
.col-6 { width: 50%; }
.col-5 { width: 41.66666667%; }
.col-4 { width: 33.33333333%; }
.col-3 { width: 25%; }
.col-2 { width: 16.66666667%; }
.col-1 { width: 8.33333333%; }

/* Tablet Grid */
@media (min-width: 768px) {
    .col-md-12 { width: 100%; }
    .col-md-11 { width: 91.66666667%; }
    .col-md-10 { width: 83.33333333%; }
    .col-md-9 { width: 75%; }
    .col-md-8 { width: 66.66666667%; }
    .col-md-7 { width: 58.33333333%; }
    .col-md-6 { width: 50%; }
    .col-md-5 { width: 41.66666667%; }
    .col-md-4 { width: 33.33333333%; }
    .col-md-3 { width: 25%; }
    .col-md-2 { width: 16.66666667%; }
    .col-md-1 { width: 8.33333333%; }
}

/* Desktop Grid */
@media (min-width: 992px) {
    .col-lg-12 { width: 100%; }
    .col-lg-11 { width: 91.66666667%; }
    .col-lg-10 { width: 83.33333333%; }
    .col-lg-9 { width: 75%; }
    .col-lg-8 { width: 66.66666667%; }
    .col-lg-7 { width: 58.33333333%; }
    .col-lg-6 { width: 50%; }
    .col-lg-5 { width: 41.66666667%; }
    .col-lg-4 { width: 33.33333333%; }
    .col-lg-3 { width: 25%; }
    .col-lg-2 { width: 16.66666667%; }
    .col-lg-1 { width: 8.33333333%; }
}

/* === RESPONSIVE TYPOGRAPHY === */
h1, .h1 {
    font-size: var(--h1-mobile);
    line-height: 1.2;
}

h2, .h2 {
    font-size: var(--h2-mobile);
    line-height: 1.3;
}

h3, .h3 {
    font-size: var(--h3-mobile);
    line-height: 1.4;
}

body, p, .body-text {
    font-size: var(--body-mobile);
    line-height: 1.6;
}

@media (min-width: 768px) {
    h1, .h1 { font-size: var(--h1-tablet); }
    h2, .h2 { font-size: var(--h2-tablet); }
    h3, .h3 { font-size: var(--h3-tablet); }
    body, p, .body-text { font-size: var(--body-tablet); }
}

@media (min-width: 1200px) {
    h1, .h1 { font-size: var(--h1-desktop); }
    h2, .h2 { font-size: var(--h2-desktop); }
    h3, .h3 { font-size: var(--h3-desktop); }
    body, p, .body-text { font-size: var(--body-desktop); }
}

/* === RESPONSIVE SPACING === */
.section-padding {
    padding: var(--section-padding-mobile);
}

@media (min-width: 768px) {
    .section-padding {
        padding: var(--section-padding-tablet);
    }
}

@media (min-width: 1200px) {
    .section-padding {
        padding: var(--section-padding-desktop);
    }
}

/* === RESPONSIVE NAVIGATION === */
.navbar-responsive {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    z-index: 1000;
    background: transparent;
    padding: 15px 0;
    transition: all 0.4s ease;
}

.navbar-responsive.scrolled {
    background-color: var(--primary-color);
    padding: 0;
    box-shadow: 0 5px 20px rgba(0,0,0,0.2);
}

.navbar-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    height: 80px;
}

.logo-responsive {
    height: 60px;
    width: auto;
    transition: all 0.3s ease;
}

@media (min-width: 768px) {
    .logo-responsive {
        height: 70px;
    }
}

.nav-menu {
    display: none;
    gap: 30px;
    align-items: center;
}

@media (min-width: 992px) {
    .nav-menu {
        display: flex;
    }
}

.nav-menu li a {
    font-weight: 500;
    font-size: 0.95rem;
    color: var(--white);
    transition: all 0.3s ease;
    position: relative;
    padding: 10px 0;
}

.nav-menu li a::after {
    content: '';
    position: absolute;
    width: 0;
    height: 2px;
    bottom: 5px;
    left: 0;
    background-color: var(--white);
    transition: all 0.3s ease;
}

.nav-menu li a:hover::after,
.nav-menu li a.active::after {
    width: 100%;
}

/* Mobile Menu */
.mobile-menu {
    position: fixed;
    top: 0;
    left: -100%;
    width: 85%;
    max-width: 400px;
    height: 100vh;
    background: var(--primary-color);
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    transition: 0.4s ease;
    z-index: 999;
    padding: 20px;
}

.mobile-menu.active {
    left: 0;
}

.mobile-menu li {
    margin: 15px 0;
}

.mobile-menu li a {
    font-size: 1.2rem;
    color: var(--white);
    font-weight: 500;
}

.hamburger {
    display: block;
    cursor: pointer;
    font-size: 1.5rem;
    color: var(--white);
    z-index: 1001;
}

@media (min-width: 992px) {
    .hamburger {
        display: none;
    }
}

/* === RESPONSIVE HERO SECTIONS === */
.hero-responsive {
    height: 60vh;
    min-height: 400px;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    color: var(--white);
    background-size: cover;
    background-position: center;
    background-attachment: scroll;
    position: relative;
}

@media (min-width: 768px) {
    .hero-responsive {
        height: 70vh;
        min-height: 500px;
    }
}

@media (min-width: 1200px) {
    .hero-responsive {
        height: 80vh;
        min-height: 600px;
        background-attachment: fixed;
    }
}

.hero-content-responsive {
    max-width: 800px;
    padding: 20px;
    z-index: 2;
    position: relative;
}

.hero-content-responsive h1 {
    margin-bottom: 20px;
    text-shadow: 2px 2px 10px rgba(0,0,0,0.5);
}

.hero-content-responsive p {
    margin-bottom: 30px;
    text-shadow: 1px 1px 5px rgba(0,0,0,0.5);
    opacity: 0.95;
}

/* === RESPONSIVE CARDS === */
.card-responsive {
    background: var(--white);
    border-radius: 15px;
    overflow: hidden;
    box-shadow: 0 5px 15px rgba(0,0,0,0.05);
    transition: all 0.3s ease;
    margin-bottom: 30px;
}

.card-responsive:hover {
    transform: translateY(-5px);
    box-shadow: 0 20px 40px rgba(0,0,0,0.1);
}

.card-img-responsive {
    height: 200px;
    overflow: hidden;
}

@media (min-width: 768px) {
    .card-img-responsive {
        height: 250px;
    }
}

.card-img-responsive img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s ease;
}

.card-responsive:hover .card-img-responsive img {
    transform: scale(1.1);
}

.card-content-responsive {
    padding: 20px;
}

@media (min-width: 768px) {
    .card-content-responsive {
        padding: 25px;
    }
}

/* === RESPONSIVE GRID LAYOUTS === */
.grid-responsive {
    display: grid;
    gap: 20px;
    grid-template-columns: 1fr;
}

@media (min-width: 576px) {
    .grid-responsive-2 {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (min-width: 768px) {
    .grid-responsive {
        gap: 25px;
    }
    
    .grid-responsive-3 {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (min-width: 992px) {
    .grid-responsive {
        gap: 30px;
    }
    
    .grid-responsive-3 {
        grid-template-columns: repeat(3, 1fr);
    }
    
    .grid-responsive-4 {
        grid-template-columns: repeat(4, 1fr);
    }
}

/* === RESPONSIVE BUTTONS === */
.btn-responsive {
    display: inline-block;
    padding: 12px 25px;
    background-color: var(--primary-color);
    color: var(--white);
    border-radius: 8px;
    font-weight: 500;
    transition: all 0.3s ease;
    border: none;
    cursor: pointer;
    text-align: center;
    font-size: 0.9rem;
    width: 100%;
}

@media (min-width: 576px) {
    .btn-responsive {
        width: auto;
        min-width: 150px;
    }
}

@media (min-width: 768px) {
    .btn-responsive {
        padding: 15px 30px;
        font-size: 1rem;
    }
}

.btn-responsive:hover {
    background-color: var(--secondary-color);
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(14, 165, 233, 0.4);
}

/* === RESPONSIVE FORMS === */
.form-responsive {
    width: 100%;
}

.form-group-responsive {
    margin-bottom: 20px;
}

.form-group-responsive label {
    display: block;
    margin-bottom: 8px;
    font-weight: 500;
    color: var(--text-dark);
    font-size: 0.9rem;
}

.form-group-responsive input,
.form-group-responsive textarea,
.form-group-responsive select {
    width: 100%;
    padding: 12px 15px;
    border: 1px solid #e2e8f0;
    border-radius: 8px;
    font-family: inherit;
    outline: none;
    transition: all 0.3s ease;
    font-size: 0.95rem;
}

@media (min-width: 768px) {
    .form-group-responsive input,
    .form-group-responsive textarea,
    .form-group-responsive select {
        padding: 15px 18px;
        font-size: 1rem;
    }
}

.form-group-responsive input:focus,
.form-group-responsive textarea:focus,
.form-group-responsive select:focus {
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px rgba(14, 165, 233, 0.1);
}

.form-row-responsive {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

@media (min-width: 768px) {
    .form-row-responsive {
        flex-direction: row;
    }
    
    .form-row-responsive .form-group-responsive {
        flex: 1;
    }
}

/* === RESPONSIVE FOOTER === */
.footer-responsive {
    background-color: #1e293b;
    color: #cbd5e1;
    padding: 50px 0 20px;
}

@media (min-width: 768px) {
    .footer-responsive {
        padding: 70px 0 20px;
    }
}

.footer-grid-responsive {
    display: grid;
    grid-template-columns: 1fr;
    gap: 30px;
    margin-bottom: 40px;
    text-align: center;
}

@media (min-width: 768px) {
    .footer-grid-responsive {
        grid-template-columns: repeat(2, 1fr);
        gap: 40px;
        text-align: left;
    }
}

@media (min-width: 992px) {
    .footer-grid-responsive {
        grid-template-columns: 1.5fr 1fr 1fr 1.2fr;
        margin-bottom: 50px;
    }
}

/* === RESPONSIVE FLOATING BUTTONS === */
.floating-btns-responsive {
    position: fixed;
    bottom: 20px;
    right: 20px;
    display: flex;
    flex-direction: column;
    gap: 10px;
    z-index: 999;
}

@media (min-width: 768px) {
    .floating-btns-responsive {
        bottom: 30px;
        right: 30px;
        gap: 15px;
    }
}

.float-btn-responsive {
    width: 50px;
    height: 50px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 1.4rem;
    box-shadow: 0 5px 15px rgba(0,0,0,0.2);
    transition: all 0.3s ease;
    animation: bounce 2s infinite;
}

@media (min-width: 768px) {
    .float-btn-responsive {
        width: 60px;
        height: 60px;
        font-size: 1.8rem;
    }
}

.float-btn-responsive:hover {
    transform: scale(1.1);
}

/* === RESPONSIVE UTILITIES === */
.text-center { text-align: center; }
.text-left { text-align: left; }
.text-right { text-align: right; }

@media (min-width: 768px) {
    .text-md-left { text-align: left; }
    .text-md-center { text-align: center; }
    .text-md-right { text-align: right; }
}

.d-none { display: none; }
.d-block { display: block; }
.d-flex { display: flex; }

@media (min-width: 768px) {
    .d-md-none { display: none; }
    .d-md-block { display: block; }
    .d-md-flex { display: flex; }
}

@media (min-width: 992px) {
    .d-lg-none { display: none; }
    .d-lg-block { display: block; }
    .d-lg-flex { display: flex; }
}

/* === RESPONSIVE MARGINS & PADDINGS === */
.m-0 { margin: 0; }
.m-1 { margin: 0.25rem; }
.m-2 { margin: 0.5rem; }
.m-3 { margin: 1rem; }
.m-4 { margin: 1.5rem; }
.m-5 { margin: 3rem; }

.p-0 { padding: 0; }
.p-1 { padding: 0.25rem; }
.p-2 { padding: 0.5rem; }
.p-3 { padding: 1rem; }
.p-4 { padding: 1.5rem; }
.p-5 { padding: 3rem; }

/* Responsive spacing */
@media (max-width: 767px) {
    .mb-mobile-0 { margin-bottom: 0; }
    .mb-mobile-1 { margin-bottom: 0.5rem; }
    .mb-mobile-2 { margin-bottom: 1rem; }
    .mb-mobile-3 { margin-bottom: 1.5rem; }
    .mb-mobile-4 { margin-bottom: 2rem; }
    .mb-mobile-5 { margin-bottom: 3rem; }
}

/* === RESPONSIVE ANIMATIONS === */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes bounce {
    0%, 20%, 50%, 80%, 100% {
        transform: translateY(0);
    }
    40% {
        transform: translateY(-10px);
    }
    60% {
        transform: translateY(-5px);
    }
}

.reveal-responsive {
    opacity: 0;
    transform: translateY(30px);
    transition: all 0.8s ease;
}

.reveal-responsive.active {
    opacity: 1;
    transform: translateY(0);
}

/* === RESPONSIVE IMAGE HANDLING === */
.img-responsive {
    max-width: 100%;
    height: auto;
    display: block;
}

.img-cover {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.img-contain {
    width: 100%;
    height: 100%;
    object-fit: contain;
}

/* === RESPONSIVE OVERFLOW HANDLING === */
.overflow-hidden { overflow: hidden; }
.overflow-x-hidden { overflow-x: hidden; }
.overflow-y-hidden { overflow-y: hidden; }

/* === RESPONSIVE FLEXBOX UTILITIES === */
.flex-column { flex-direction: column; }
.flex-row { flex-direction: row; }
.justify-center { justify-content: center; }
.justify-between { justify-content: space-between; }
.justify-around { justify-content: space-around; }
.align-center { align-items: center; }
.align-start { align-items: flex-start; }
.align-end { align-items: flex-end; }

@media (min-width: 768px) {
    .flex-md-row { flex-direction: row; }
    .flex-md-column { flex-direction: column; }
}

/* === RESPONSIVE POSITION UTILITIES === */
.position-relative { position: relative; }
.position-absolute { position: absolute; }
.position-fixed { position: fixed; }
.position-sticky { position: sticky; }

/* === RESPONSIVE Z-INDEX === */
.z-1 { z-index: 1; }
.z-2 { z-index: 2; }
.z-10 { z-index: 10; }
.z-50 { z-index: 50; }
.z-100 { z-index: 100; }
.z-999 { z-index: 999; }
.z-1000 { z-index: 1000; }