/* ===============================================
   RESPONSIVE FIXES FOR IMVEST SITE
   =============================================== */

/* ===============================================
   1. GLOBAL RESPONSIVE IMPROVEMENTS
   =============================================== */

/* Prevent horizontal scroll on all devices */
html, body {
    overflow-x: hidden;
    max-width: 100%;
}

/* Better container responsiveness */
.container {
    padding-left: 15px;
    padding-right: 15px;
}

@media (max-width: 576px) {
    .container {
        padding-left: 10px;
        padding-right: 10px;
    }
}

/* ===============================================
   2. BANNER SECTION RESPONSIVE FIXES
   =============================================== */

/* Banner grid improvements */
.banner__grid-2 {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 40px;
    align-items: center;
}

@media (max-width: 1200px) {
    .banner__grid-2 {
        gap: 30px;
    }
}

@media (max-width: 992px) {
    .banner__grid-2 {
        grid-template-columns: 1fr;
        gap: 40px;
        text-align: center;
    }
}

@media (max-width: 768px) {
    .banner__grid-2 {
        gap: 30px;
    }
}

/* Banner content responsive typography */
.banner__content-2 h2 {
    font-size: clamp(28px, 5vw, 68px);
    line-height: 1.2;
    margin-bottom: 30px;
}

@media (max-width: 768px) {
    .banner__content-2 h2 {
        margin-bottom: 20px;
    }
    
    .banner__content-2 h2 br {
        display: none;
    }
}

/* Banner subtitle improvements */
.banner__sbutitle-2 {
    font-size: clamp(12px, 2.5vw, 14px);
    padding: 8px 12px;
    margin-bottom: 20px;
    display: inline-block;
}

/* Banner button group responsive */
.banner__btn-group {
    display: flex;
    flex-direction: column;
    gap: 15px;
    align-items: flex-start;
}

@media (max-width: 992px) {
    .banner__btn-group {
        align-items: center;
    }
}

@media (max-width: 576px) {
    .banner__btn-group {
        width: 100%;
    }
    
    .banner__btn-group .bd-gradient-btn {
        width: 100%;
        text-align: center;
    }
}

/* Banner image responsive */
.banner__thumb-wrapper-2 {
    position: relative;
    width: 100%;
    max-width: 500px;
    margin: 0 auto;
}

@media (max-width: 768px) {
    .banner__thumb-wrapper-2 {
        max-width: 400px;
    }
}

@media (max-width: 576px) {
    .banner__thumb-wrapper-2 {
        max-width: 300px;
    }
}

.banner__thumb-2 img {
    width: 100%;
    height: auto;
    max-width: 100%;
}

/* ===============================================
   3. SECTION SPACING RESPONSIVE FIXES
   =============================================== */

.section-space {
    padding: 80px 0;
}

@media (max-width: 992px) {
    .section-space {
        padding: 60px 0;
    }
}

@media (max-width: 768px) {
    .section-space {
        padding: 50px 0;
    }
}

@media (max-width: 576px) {
    .section-space {
        padding: 40px 0;
    }
}

/* ===============================================
   4. TYPOGRAPHY RESPONSIVE IMPROVEMENTS
   =============================================== */

/* Heading responsive scaling */
h1 {
    font-size: clamp(32px, 6vw, 60px);
    line-height: 1.2;
}

h2 {
    font-size: clamp(28px, 5vw, 44px);
    line-height: 1.3;
}

h3 {
    font-size: clamp(20px, 4vw, 24px);
    line-height: 1.4;
}

h4 {
    font-size: clamp(18px, 3.5vw, 20px);
    line-height: 1.4;
}

/* Section titles responsive */
.section__title {
    font-size: clamp(28px, 5vw, 44px);
    line-height: 1.3;
    margin-bottom: 20px;
}

@media (max-width: 768px) {
    .section__title {
        margin-bottom: 15px;
    }
}

.section__subtitle-7 {
    font-size: clamp(12px, 2.5vw, 14px);
    padding: 8px 16px;
    margin-bottom: 15px;
}

/* ===============================================
   5. GRID LAYOUT RESPONSIVE FIXES
   =============================================== */

/* Feature boxes responsive grid */
.row.g-4 {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 2rem;
}

@media (max-width: 768px) {
    .row.g-4 {
        grid-template-columns: 1fr;
        gap: 1.5rem;
    }
}

/* Revolution section responsive */
.revolution__item {
    text-align: center;
    padding: 20px 15px;
}

@media (max-width: 768px) {
    .revolution__item {
        padding: 15px 10px;
    }
}

/* Working steps responsive */
.work__steps-main-3 .row.g-5 {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 2rem;
}

@media (max-width: 768px) {
    .work__steps-main-3 .row.g-5 {
        grid-template-columns: 1fr;
        gap: 1.5rem;
    }
}

/* ===============================================
   6. INVESTMENT VISUALIZATION RESPONSIVE
   =============================================== */

.investment-visualization {
    padding: 1.5rem;
}

@media (max-width: 768px) {
    .investment-visualization {
        padding: 1rem;
    }
}

.investment-controls .row.g-3 {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

@media (min-width: 768px) {
    .investment-controls .row.g-3 {
        flex-direction: row;
    }
}

.investment-controls .form-control,
.investment-controls .form-select {
    width: 100%;
    padding: 12px 16px;
    font-size: 16px; /* Prevent zoom on iOS */
}

/* Chart container responsive */
.chart-container {
    position: relative;
    width: 100%;
    height: 300px;
    margin: 2rem 0;
}

@media (max-width: 768px) {
    .chart-container {
        height: 250px;
        margin: 1.5rem 0;
    }
}

/* Stats grid responsive */
.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 1rem;
    margin-top: 2rem;
}

@media (max-width: 768px) {
    .stats-grid {
        grid-template-columns: 1fr;
        gap: 0.75rem;
        margin-top: 1.5rem;
    }
}

/* ===============================================
   7. WHY CHOOSE SLIDER RESPONSIVE
   =============================================== */

.why-choose-slider-wrapper {
    position: relative;
    padding: 0 20px;
}

@media (max-width: 768px) {
    .why-choose-slider-wrapper {
        padding: 0 10px;
    }
}

.slide-card {
    padding: 2rem;
    min-height: 300px;
}

@media (max-width: 768px) {
    .slide-card {
        padding: 1.5rem;
        min-height: 250px;
    }
}

.slide-title {
    font-size: clamp(18px, 4vw, 24px);
    margin-bottom: 1rem;
}

.slide-subtitle {
    font-size: clamp(14px, 3vw, 16px);
    margin-bottom: 1.5rem;
}

/* ===============================================
   8. COMPARISON CHART RESPONSIVE
   =============================================== */

.roi-chart-wrapper {
    position: relative;
    width: 100%;
    height: 400px;
    margin: 2rem 0;
}

@media (max-width: 768px) {
    .roi-chart-wrapper {
        height: 300px;
        margin: 1.5rem 0;
    }
}

.roi-legend {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 1rem;
    margin-top: 1rem;
}

@media (max-width: 576px) {
    .roi-legend {
        flex-direction: column;
        align-items: center;
        gap: 0.5rem;
    }
}

/* ===============================================
   9. FOOTER RESPONSIVE FIXES
   =============================================== */

.footer__bottom-2 {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 1rem;
}

@media (max-width: 768px) {
    .footer__bottom-2 {
        flex-direction: column;
        text-align: center;
    }
}

.footer__social {
    display: flex;
    gap: 10px;
    justify-content: center;
}

@media (max-width: 576px) {
    .footer__social {
        gap: 8px;
    }
}

/* ===============================================
   10. SUBSCRIBE SECTION RESPONSIVE
   =============================================== */

.subcribe__input {
    max-width: 100%;
    margin: 20px auto 0;
}

@media (max-width: 768px) {
    .subcribe__input {
        flex-direction: column;
        gap: 15px;
        padding: 15px;
    }
    
    .subcribe__input input {
        padding: 0 20px;
        text-align: center;
    }
    
    .subcribe__input .bd-gradient-btn {
        position: static;
        width: 100%;
    }
}

/* ===============================================
   11. ORBIT SECTION RESPONSIVE (ABOUT PAGE)
   =============================================== */

.orbit-section {
    position: relative;
    width: 100%;
    max-width: 520px;
    height: 520px;
    margin: 0 auto 48px auto;
    display: flex;
    align-items: center;
    justify-content: center;
}

@media (max-width: 768px) {
    .orbit-section {
        max-width: 400px;
        height: 400px;
        margin: 0 auto 30px auto;
    }
}

@media (max-width: 576px) {
    .orbit-section {
        max-width: 300px;
        height: 300px;
        margin: 0 auto 20px auto;
    }
}

.orbit-center {
    position: absolute;
    left: 50%;
    top: 50%;
    transform: translate(-50%, -50%);
    width: 160px;
    height: 160px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
}

@media (max-width: 768px) {
    .orbit-center {
        width: 120px;
        height: 120px;
    }
}

@media (max-width: 576px) {
    .orbit-center {
        width: 80px;
        height: 80px;
    }
}

.orbit-center img {
    width: 80%;
    height: auto;
    max-width: 100%;
}

@media (max-width: 768px) {
    .orbit-center img {
        width: 70%;
    }
}

@media (max-width: 576px) {
    .orbit-center img {
        width: 60%;
    }
}

/* ===============================================
   12. FOUNDER NOTE CARD RESPONSIVE
   =============================================== */

.founder-note-card {
    max-width: 100%;
    margin: 40px auto 60px auto;
    padding: 40px 30px;
    font-size: 1.2rem;
}

@media (max-width: 768px) {
    .founder-note-card {
        margin: 30px auto 40px auto;
        padding: 30px 20px;
        font-size: 1.1rem;
    }
}

@media (max-width: 576px) {
    .founder-note-card {
        margin: 20px auto 30px auto;
        padding: 20px 15px;
        font-size: 1rem;
    }
}

.founder-note-card h2 {
    font-size: clamp(20px, 4vw, 32px);
    margin-bottom: 20px;
}

.founder-note-card .founder-name {
    font-size: clamp(16px, 3vw, 20px);
    margin-top: 20px;
}

/* ===============================================
   13. OUR VALUES SECTION RESPONSIVE
   =============================================== */

.our-values__area {
    max-width: 100%;
    margin: 40px auto;
    padding: 30px 20px;
}

@media (max-width: 768px) {
    .our-values__area {
        margin: 30px auto;
        padding: 20px 15px;
    }
}

.our-values__area .row.gy-50 {
    display: flex;
    flex-direction: column;
    gap: 0;
}

@media (min-width: 992px) {
    .our-values__area .row.gy-50 {
        flex-direction: row;
        gap: 32px;
    }
}

.our-values__content-wrapper {
    flex: 1;
    margin-bottom: 30px;
}

@media (min-width: 992px) {
    .our-values__content-wrapper {
        margin-bottom: 0;
        margin-right: 32px;
    }
}

.our-values__cards {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 20px;
    flex: 1;
}

@media (max-width: 768px) {
    .our-values__cards {
        grid-template-columns: 1fr;
        gap: 15px;
    }
}

.our-values__item {
    width: 100%;
    min-width: auto;
    padding: 20px 15px;
}

@media (max-width: 768px) {
    .our-values__item {
        padding: 15px 10px;
    }
}

/* ===============================================
   14. TEAM SECTION RESPONSIVE
   =============================================== */

.team-flip-card {
    min-width: auto;
    max-width: 100%;
    margin: 0 auto 20px auto;
    height: auto;
    min-height: 350px;
}

@media (max-width: 768px) {
    .team-flip-card {
        min-height: 300px;
        margin: 0 auto 15px auto;
    }
}

.team__thumb {
    width: 150px;
    height: 150px;
    margin-bottom: 15px;
}

@media (max-width: 768px) {
    .team__thumb {
        width: 120px;
        height: 120px;
        margin-bottom: 12px;
    }
}

.team__contenrt h3 {
    font-size: clamp(16px, 3vw, 20px);
    margin-bottom: 5px;
}

.team__contenrt span {
    font-size: clamp(14px, 2.5vw, 16px);
    margin-bottom: 8px;
}

.team-desc {
    font-size: clamp(14px, 2.5vw, 16px);
    line-height: 1.5;
}

/* ===============================================
   15. UTILITY CLASSES
   =============================================== */

/* Text alignment responsive */
@media (max-width: 768px) {
    .text-center-mobile {
        text-align: center;
    }
}

/* Spacing responsive */
@media (max-width: 768px) {
    .mb-mobile-3 {
        margin-bottom: 1rem;
    }
    
    .mt-mobile-3 {
        margin-top: 1rem;
    }
}

/* Hide/show on different screen sizes */
@media (max-width: 768px) {
    .d-mobile-none {
        display: none !important;
    }
}

@media (min-width: 769px) {
    .d-desktop-none {
        display: none !important;
    }
}

/* ===============================================
   16. ACCESSIBILITY IMPROVEMENTS
   =============================================== */

/* Focus states for better accessibility */
.bd-gradient-btn:focus,
.btn:focus,
input:focus,
select:focus,
textarea:focus {
    outline: 2px solid var(--bd-theme-primary);
    outline-offset: 2px;
}

/* Better touch targets for mobile */
@media (max-width: 768px) {
    .bd-gradient-btn,
    .btn,
    button {
        min-height: 44px;
        min-width: 44px;
    }
}

/* ===============================================
   17. PERFORMANCE OPTIMIZATIONS
   =============================================== */

/* Reduce animations on mobile for better performance */
@media (max-width: 768px) {
    * {
        animation-duration: 0.3s !important;
        transition-duration: 0.3s !important;
    }
}

/* Optimize images for mobile */
@media (max-width: 768px) {
    img {
        max-width: 100%;
        height: auto;
    }
}

/* ===============================================
   18. ADDITIONAL MOBILE FIXES
   =============================================== */

/* Fix horizontal scroll issues */
@media (max-width: 768px) {
    .container-fluid {
        padding-left: 10px;
        padding-right: 10px;
    }
    
    .row {
        margin-left: -10px;
        margin-right: -10px;
    }
    
    .col, .col-1, .col-2, .col-3, .col-4, .col-5, .col-6,
    .col-7, .col-8, .col-9, .col-10, .col-11, .col-12,
    .col-auto, .col-sm, .col-sm-1, .col-sm-2, .col-sm-3,
    .col-sm-4, .col-sm-5, .col-sm-6, .col-sm-7, .col-sm-8,
    .col-sm-9, .col-sm-10, .col-sm-11, .col-sm-12,
    .col-md, .col-md-1, .col-md-2, .col-md-3, .col-md-4,
    .col-md-5, .col-md-6, .col-md-7, .col-md-8, .col-md-9,
    .col-md-10, .col-md-11, .col-md-12, .col-lg, .col-lg-1,
    .col-lg-2, .col-lg-3, .col-lg-4, .col-lg-5, .col-lg-6,
    .col-lg-7, .col-lg-8, .col-lg-9, .col-lg-10, .col-lg-11,
    .col-lg-12, .col-xl, .col-xl-1, .col-xl-2, .col-xl-3,
    .col-xl-4, .col-xl-5, .col-xl-6, .col-xl-7, .col-xl-8,
    .col-xl-9, .col-xl-10, .col-xl-11, .col-xl-12 {
        padding-left: 10px;
        padding-right: 10px;
    }
}

/* Fix overflow issues on small screens */
@media (max-width: 576px) {
    .banner__content-2 h2 {
        word-break: break-word;
        hyphens: auto;
    }
    
    .section__title {
        word-break: break-word;
        hyphens: auto;
    }
    
    .banner__sbutitle-2 {
        word-break: break-word;
    }
}

/* Improve touch targets for mobile */
@media (max-width: 768px) {
    .swiper-button-next,
    .swiper-button-prev {
        width: 44px;
        height: 44px;
    }
    
    .swiper-pagination-bullet {
        width: 12px;
        height: 12px;
        margin: 0 6px;
    }
}

/* Fix form elements on mobile */
@media (max-width: 768px) {
    .form-control,
    .form-select {
        font-size: 16px; /* Prevent zoom on iOS */
        padding: 12px 16px;
    }
    
    .btn {
        font-size: 16px;
        padding: 12px 24px;
    }
}

/* ===============================================
   19. PRINT STYLES
   =============================================== */

@media print {
    .header__area,
    .footer__area,
    .backtotop-wrap,
    .swiper-button-next,
    .swiper-button-prev,
    .swiper-pagination {
        display: none !important;
    }
    
    .section-space {
        padding: 20px 0;
    }
    
    .banner__area {
        padding: 20px 0;
    }
    
    * {
        color: #000 !important;
        background: #fff !important;
    }
}
