/* ===== Responsive Design ===== */
@media (max-width: 1200px) {
    .dark-info-container,
    .content-grid,
    .cta-container {
        grid-template-columns: 1fr;
        gap: 3rem;
    }

    .wing-detail {
        padding: 6rem 0;
    }
    
    .wing-content {
        grid-template-columns: 1fr;
        gap: 3rem;
    }

    .wing-image {
        display: none;
    }

    .wing-container {
        margin-bottom: 0;
    }

    .cta-image {
        order: -1;
        text-align: center;
    }

    .features-container {
        padding: 0;
    }

    .use-cases-grid {
        grid-template-columns: 1fr;
        gap: 3rem;
    }

    .footer-grid {
        grid-template-columns: 1fr 1fr;
    }
}

@media (max-width: 1024px) {
    /* Hide wing image to prevent horizontal overflow */
    .wing-image {
        display: none;
    }

    .features-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 2rem;
    }

    .feature-card:nth-child(3) {
        grid-column: 1 / -1;
        max-width: 50%;
        margin: 0 auto;
    }

    .navbar {
        padding: 1.2rem 0;
    }

    .navbar.scrolled {
        padding: 1.2rem 0;
    }

    .nav-container {
        padding: 0 1.5rem;
        grid-template-columns: 1fr;
        position: relative;
    }

    .nav-logo {
        height: 50px;
        order: 1;
        justify-self: flex-start;
    }

    .nav-container a[href="#home"] {
        width: fit-content;
    }

    .navbar.scrolled .nav-logo {
        height: 50px;
    }

    .nav-left,
    .nav-right {
        position: fixed;
        left: -100%;
        top: 100px;
        flex-direction: column;
        background-color: var(--white);
        width: 100%;
        text-align: center;
        transition: var(--transition);
        padding: 2rem 0;
        gap: 1.5rem;
        justify-content: center;
    }

    .nav-left.active,
    .nav-right.active {
        left: 0;
    }

    .nav-left {
        top: 80px;
    }

    .nav-right {
        top: 230px;
        box-shadow: 0 10px 20px -5px rgba(0, 0, 0, 0.1);
        gap: 2.5rem;
        padding-top: 3rem;
    }

    .nav-toggle {
        display: flex;
    }

    .hero {
        padding-top: 92px;
    }

    .dark-info {
        padding: 4rem 1.5rem;
    }

    .dark-info-container {
        padding: 0;
        font-size: 1.2rem;
    }

    .dark-info-container h2 {
        font-size: 2rem;
    }

    .dark-info-box {
        padding: 2rem 1.5rem;
    }

    .features {
        padding: 4rem 1.5rem;
    }

    .features-container {
        padding: 0;
    }

    .feature-card {
        padding: 2rem 1.5rem;
    }

    .hero-title {
        margin-bottom: 2rem;
    }

    .hero-description {
        width: 100%;
        font-size: 1.2rem;
        margin-bottom: 2.5rem;
    }

    .hero-image {
        margin-top: 0;
        order: -1;
        text-align: center;
    }
    .hero-image img {
        width: 70%;
    }

    .hero-container {
        grid-template-columns: 1fr;
        padding: 3rem 1.5rem;
        gap: 1rem;
    }

    .wing-container,
    .wing-content,
    .content-grid,
    .cta-container {
        padding: 3rem 1.5rem;
        gap: 1rem;
    }

    .content-grid .content-text,
    .content-grid.reverse .content-text {
        padding-left: 0;
        padding-right: 0;
    }

    .content-grid .content-image,
    .content-grid.reverse .content-image {
        margin-left: 0;
        margin-right: 0;
        width: 100%;
    }

    .cta-content {
        margin-top: 0;
    }

    .content-section {
        padding: 4rem 1.5rem;
    }

    .content-container {
        padding: 0;
    }

    .use-cases-section {
        padding: 3rem 1.5rem;
    }

    .use-cases-container {
        padding: 0 1.5rem;
    }

    .use-case-content {
        padding: 2rem;
    }

    .how-container {
        padding: 0 1.5rem;
    }

    .content-grid.reverse {
        direction: ltr;
    }

    .footer-main {
        grid-template-columns: 1fr;
        gap: 3rem;
    }

    .footer-right {
        justify-content: flex-start;
    }

    .footer-bottom {
        flex-direction: column;
        gap: 2rem;
        align-items: flex-start;
    }

    .footer-legal {
        flex-direction: column;
        gap: 1rem;
    }

    .footer-dragonfly {
        /*width: 100%;*/
        width: auto;
        height: auto;
    }

    .footer-dragonfly img {
        mask-image: none;
        -webkit-mask-image: none;
        opacity: 0.5;
    }

    .how-grid {
        grid-template-columns: 1fr;
    }

    .how-item:nth-child(2),
    .how-item:nth-child(3),
    .how-item:nth-child(4) {
        margin-top: 0;
    }
    
    .wing-detail {
        padding: 3rem 0;
    }

    .cta-section {
        padding-left: 0;
        padding-right: 0;
    }
}

@media (max-width: 768px) {
    /* Ensure wing section doesn't cause overflow */
    .wing-detail {
        overflow: hidden;
    }

    /* Prevent images and media from causing overflow */
    img,
    svg {
        max-width: 100%;
        height: auto;
    }

    /* Reduce CTA section padding on mobile */
    .cta-section {
        padding: 1rem 0 !important;
    }

    /* Reduce CTA form padding on mobile */
    .cta-form {
        padding: 1.5rem !important;
    }

    /* Remove horizontal padding on footer container */
    .footer-container {
        padding-left: 0;
        padding-right: 0;
    }

    /* Footer adjustments for mobile */
    .footer {
        padding: 3rem 1.5rem 2rem;
    }

    .footer-logo {
        height: 80px;
    }

    .footer-contact-item {
        grid-template-columns: 1fr;
        gap: 0.25rem;
        margin-bottom: 1rem;
    }

    .footer-label {
        font-size: 0.9rem;
        opacity: 0.8;
    }

    .footer-contact-link {
        font-size: 1.1rem;
        word-break: break-all;
        line-height: 1.4;
    }

    .footer-copyright p,
    .footer-legal a {
        font-size: 1rem;
    }

    .footer-main {
        padding: 0 1.5rem;
    }

    .footer-bottom {
        padding-left: 1.5rem;
        padding-right: 1.5rem;
    }

    .use-cases-container {
        padding-left: 0;
        padding-right: 0;
    }

    .content-container {
        padding-left: 0;
        padding-right: 0;
    }

    .content-grid {
        padding-left: 0;
        padding-right: 0;
        margin-bottom: 0;
    }

    .wing-content h2 {
        margin-bottom: 2rem;
    }

    .features-grid {
        grid-template-columns: 1fr;
    }

    .feature-card:nth-child(3) {
        grid-column: auto;
        max-width: none;
        margin: 0;
    }

    .feature-icon {
        width: 100px;
        height: 100px;
    }

    .feature-card h3 {
        font-size: 2rem;
    }

    .feature-card p {
        font-size: 1.2rem;
    }

    /* Ensure no content extends beyond viewport on mobile */
    .content-image {
        width: 100% !important;
        margin-left: 0 !important;
        margin-right: 0 !important;
    }

    /* Ensure wing section doesn't cause overflow */
    .wing-detail {
        overflow: hidden;
    }

    /* Reduce button padding on mobile by ~30% */
    .hero-cta,
    .features-cta,
    .form-button {
        padding: 0.7rem 1.2rem 0.7rem 1.75rem;
        font-size: 1.1rem;
    }

    /* Reduce dark-info-box check-line font size on mobile */
    .dark-info-box .check-line {
        font-size: 1.3rem;
    }

    /* Reduce how-it-works padding to match other sections on mobile */
    .how-it-works {
        padding: 4rem 0;
    }

    /* Reduce wing-detail padding to match other sections on mobile */
    .wing-detail {
        padding: 4rem 0;
    }

    /* Remove top and bottom padding from wing-container on mobile */
    .wing-container {
        padding-top: 0;
        padding-bottom: 0;
    }

    /* Reduce faq-section padding to match other sections on mobile */
    .faq-section {
        padding: 4rem 1.5rem;
    }

    .faq-container {
        margin-bottom: 0;
    }

    /* Set CTA form input padding to 1rem on mobile */
    .cta-form .form-input,
    .cta-form textarea.form-input {
        padding-left: 1rem;
        padding-right: 1rem;
    }

    /* Adjust floating label position to match 1rem padding on mobile */
    .cta-form .form-group label:not(.form-checkbox-label) {
        left: 1rem;
    }
}
