/* 
==========================================================================
   MINDI GLOBAL | Responsive Styles - Circular Ecosystem
========================================================================== 
*/

@media screen and (max-width: 1023px) {
    body { overflow-y: auto; overflow-x: hidden; }
    
    .circular-layout { height: auto; display: block; overflow: visible; width: 100%; }
    .ecosystem-container { height: auto; flex-direction: column; justify-content: flex-start; padding: var(--spacing-xl) 0; overflow: visible; }
    
    .central-identity { position: relative; left: auto; top: auto; transform: none !important; margin-bottom: var(--spacing-xl); text-align: center; }
    .hero-line { font-size: clamp(3.5rem, 12vw, 6rem); }
    
    .brand-logo-img { max-height: 48px; max-width: 60vw; }
    
    /* Hide desktop SVG on mobile */
    .ecosystem-connections { display: none; }
    
    .ecosystem-layer {
        position: relative; height: auto; display: flex; flex-direction: column; align-items: center; gap: var(--spacing-lg);
        padding: 4rem 0; pointer-events: auto;
    }
    
    /* Vertical connecting line */
    .ecosystem-layer::before {
        content: ''; position: absolute; top: 0; bottom: 0; left: 50%; width: 1px; background-color: var(--color-line);
        transform: translateX(-50%); z-index: 0;
    }
    
    .company-node { width: 150px; height: 150px; }
    
    .company-node-wrapper {
        position: relative; left: auto !important; top: auto !important; transform: none !important;
        width: 100%; max-width: 400px; padding: 0 var(--container-padding);
        display: flex; flex-direction: column-reverse; align-items: center; gap: var(--spacing-xs);
        z-index: 10;
    }
    
    /* Reorder category for mobile */
    .node-category { 
        position: static !important; transform: none !important; white-space: normal; text-align: center;
        opacity: 1; margin-top: var(--spacing-sm); 
    }
    
    /* Mobile Popups */
    .btn-close-about, .btn-close-contact, .btn-close-detail { position: relative; top: auto; right: auto; margin-bottom: var(--spacing-lg); align-self: flex-end; }
    .about-panel, .contact-panel, .detail-panel { padding-top: var(--spacing-md); justify-content: flex-start; margin-top: 0; }
    .form-row { grid-template-columns: 1fr; gap: var(--spacing-md); }
}

@media screen and (min-width: 1024px) {
    :root { --container-padding: 4vw; }
    .desktop-nav { display: block; }
    .mobile-menu-trigger { display: none; }
    
    @media (max-height: 700px) {
        body { overflow-y: auto; }
        .circular-layout { height: auto; min-height: 100vh; }
        .ecosystem-container { min-height: 800px; }
    }
}

@media screen and (min-width: 1440px) {
    :root { --container-padding: 4vw; }
}

@media (prefers-reduced-motion: reduce) {
    *, *::before, *::after { animation-duration: 0.01ms !important; animation-iteration-count: 1 !important; transition-duration: 0.01ms !important; scroll-behavior: auto !important; }
    body.js-loaded .company-node-wrapper { opacity: 1 !important; }
    .detail-panel, .about-panel, .contact-panel { transform: none !important; }
}
