/* Desktop team layout - horizontal with photos left of text */
@media (min-width: 801px) {
    .team-grid {
        display: grid !important;
        grid-template-columns: 1fr !important;
        gap: 1rem !important;
        margin-top: 0 !important;
    }

    .team-member {
        display: flex !important;
        flex-direction: row !important;
        align-items: flex-start !important;
        gap: 2rem !important;
        padding: 1.5rem 0 !important;
        text-align: left !important;
        max-width: 900px !important;
        margin: 0 auto !important;
        background: transparent !important;
        border: none !important;
        box-shadow: none !important;
    }

    .member-photo,
    .member-image,
    .image-placeholder {
        flex-shrink: 0 !important;
        width: 140px !important;
        height: 160px !important;
        margin: 0 !important;
        border-radius: 12px !important;
        object-fit: cover !important;
        order: 1 !important;
    }

    .member-info {
        flex: 1 !important;
        text-align: left !important;
        order: 2 !important;
        padding-top: 0 !important;
    }

    .member-name,
    .team-member h3 {
        margin-bottom: 0.3rem !important;
        font-size: 1.3rem !important;
        text-align: left !important;
    }

    .member-role,
    .member-title {
        margin-bottom: 0.6rem !important;
        font-size: 0.95rem !important;
        text-align: left !important;
    }

    .member-description,
    .member-bio {
        font-size: 0.9rem !important;
        line-height: 1.5 !important;
        text-align: left !important;
    }

    /* Force horizontal layout for any team member variants */
    .team-section .team-member,
    .team-members .team-member {
        display: flex !important;
        flex-direction: row !important;
        align-items: flex-start !important;
        text-align: left !important;
    }
}

/* Dynamic scaling based on viewport size */
@media (max-width: 1400px) and (min-width: 801px) {
    /* Tablet/smaller desktop scaling */
    .hero-container {
        padding: 1.5rem !important;
    }
    
    .hero-title {
        font-size: clamp(3rem, 5vw, 4rem) !important;
    }
    
    .hero-subtitle {
        font-size: clamp(1rem, 2vw, 1.2rem) !important;
    }
    
    .feature-section {
        padding: 4rem 0 !important;
    }
    
    .nav-logo-img {
        height: clamp(120px, 15vw, 170px) !important;
    }
}

@media (max-width: 1200px) and (min-width: 801px) {
    /* Medium screen scaling */
    .hero-buttons {
        gap: 1rem !important;
    }
    
    .btn-primary, .btn-secondary {
        padding: 0.8rem 1.8rem !important;
        font-size: 0.9rem !important;
    }
    
    .feature-card {
        margin: 0 1rem !important;
    }
}

@media (max-width: 1000px) and (min-width: 801px) {
    /* Small desktop scaling */
    .hero-container {
        gap: 1.5rem !important;
    }
    
    .platform-image {
        width: 110% !important;
        height: 110% !important;
    }
    
    .team-member {
        margin: 0 0.5rem !important;
    }
}

/* Mobile-specific overrides */
@media (max-width: 800px) {
    /* Navigation layout and spacing */
    .nav-container {
        position: relative !important;
        justify-content: flex-end !important;
        padding: 0.5rem 1rem !important;
        z-index: 1000 !important;
        display: flex !important;
        align-items: center !important;
        gap: 1rem !important;
    }

    /* Hide navigation menu by default */
    .nav-menu {
        display: none;
        visibility: hidden;
    }
    
    /* Hide individual nav links by default */
    .nav-link {
        display: none;
        visibility: hidden;
    }
    
    /* Show dropdown when nav-menu has active class */
    .nav-menu.active {
        display: flex !important;
        visibility: visible !important;
        flex-direction: column !important;
        position: fixed !important;
        top: 70px !important;
        right: 15px !important;
        background: white !important;
        box-shadow: 0 4px 20px rgba(0, 0, 0, 0.15) !important;
        border-radius: 8px !important;
        padding: 8px 0 !important;
        width: 160px !important;
        z-index: 999999 !important;
        border: 1px solid #e5e7eb !important;
    }

    /* Ensure dropdown appears above all content on home page */
    .home-page .nav-menu.active,
    body.home-page .nav-menu.active {
        z-index: 9999999 !important;
        position: fixed !important;
    }

    /* Show nav links inside active dropdown */
    .nav-menu.active .nav-link {
        display: block !important;
        visibility: visible !important;
        padding: 12px 16px !important;
        color: #374151 !important;
        text-decoration: none !important;
        font-size: 14px !important;
        font-weight: 500 !important;
        border-bottom: none !important;
    }



   /* Remove black box around Noyes AI logo */
   .nav-logo,
   .nav-logo a,
   .nav-logo img,
   .nav-logo-img,
   .logo-container {
       outline: none !important;
       border: none !important;
       box-shadow: none !important;
       background: transparent !important;
   }

   .nav-logo:focus,
   .nav-logo a:focus,
   .nav-logo img:focus,
   .nav-logo-img:focus,
   .logo-container:focus,
   .nav-logo:active,
   .nav-logo a:active,
   .nav-logo img:active,
   .nav-logo-img:active,
   .logo-container:active {
       outline: none !important;
       border: none !important;
       box-shadow: none !important;
       background: transparent !important;
   }

    /* Align Sign In button to the left of hamburger */
    .nav-btn-primary {
        order: 1 !important;
        margin: 0 !important;
        padding: 0.5rem 1rem !important;
    }

    /* Hamburger menu */
    .hamburger {
        display: flex !important;
        flex-direction: column !important;
        justify-content: space-around !important;
        width: 1.5rem !important;
        height: 1.5rem !important;
        cursor: pointer !important;
        z-index: 100 !important;
        padding: 0 !important;
        order: 1 !important;
    }

    .hamburger span {
        width: 1.5rem !important;
        height: 0.2rem !important;
        background-color: #000 !important;
        border-radius: 0.2rem !important;
        transition: all 0.3s ease-in-out !important;
    }

    .hamburger.active span:nth-child(1) {
        transform: rotate(45deg) translate(0.5rem, 0.5rem) !important;
    }

    .hamburger.active span:nth-child(2) {
        opacity: 0 !important;
    }

    .hamburger.active span:nth-child(3) {
        transform: rotate(-45deg) translate(0.5rem, -0.5rem) !important;
    }

    /* Hide Sign In from dropdown */
    .nav-menu .nav-btn-primary {
        display: none !important;
    }

    /* Navigation links in vertical stack */
    .nav-menu.active .nav-link {
        display: block !important;
        padding: 0.5rem 1rem !important;
        margin: 0 !important;
        font-size: 0.9rem !important;
        font-weight: 500 !important;
        font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', 'SF Pro Display', 'Helvetica Neue', Arial, sans-serif !important;
        text-align: left !important;
        color: #333 !important;
        box-sizing: border-box !important;
        border-bottom: 1px solid rgba(0,0,0,0.1) !important;
        width: 100% !important;
        white-space: nowrap !important;
        overflow: hidden !important;
        text-overflow: ellipsis !important;
    }

    /* Remove border from last item */
    .nav-menu .nav-link:last-child {
        border-bottom: none !important;
    }

    /* Hover effect */
    .nav-menu .nav-link:hover {
        background-color: rgba(0,0,0,0.05) !important;
    }

    .nav-menu .nav-link:last-child {
        border-bottom: none !important;
    }

    .nav-menu .nav-link:hover {
        background-color: rgba(0, 0, 0, 0.05) !important;

        clear: both !important;
    }

    .nav-link:hover {
        background-color: rgba(0, 0, 0, 0.05) !important;
    }
    
    /* Force vertical layout */
    .nav-menu a {
        display: block !important;
        margin: 0 auto !important;
        float: none !important;
        clear: both !important;
    }

    /* Sign in button */
    .nav-btn-primary {
        display: block !important;
        width: 100% !important;
        padding: 1rem !important;
        margin: 0 !important;
        font-size: 1.1rem !important;
        text-align: center !important;
        border-bottom: 1px solid rgba(0, 0, 0, 0.1) !important;
    }

    /* Ensure the menu takes full height and scrolls if needed */
    .nav-menu.active {
        overflow-y: auto !important;
    }

    /* Prevent body scroll when menu is open */
    body.menu-open {
        overflow: hidden !important;
    }

    /* Mobile hero layout */
    .hero-container {
        flex-direction: column !important;
        padding: 1rem !important;
        align-items: center !important;
    }

    .hero-content {
        order: 1 !important;
        text-align: center !important;
        margin-top: 1rem !important;
        display: flex !important;
        flex-direction: column !important;
        align-items: center !important;
    }

    .hero-title {
        text-align: center !important;
        justify-content: center !important;
        margin: 0 auto !important;
        width: 100% !important;
        max-width: 90% !important;
    }

    .hero-title-line1 {
        text-align: center !important;
        width: 100% !important;
        display: block !important;
    }

    .hero-title-line2,
    .hero-title-line3 {
        text-align: center !important;
        display: inline !important;
        margin: 0 0.2rem !important;
    }

    .hero-subtitle {
        margin: 1.5rem auto 2rem auto !important;
        text-align: center !important;
        max-width: 90% !important;
    }

    .hero-buttons {
        display: flex !important;
        flex-direction: row !important;
        order: 2 !important;
        justify-content: center !important;
        align-items: center !important;
        margin: 0 auto !important;
        width: 100% !important;
        gap: 1rem !important;
        margin-bottom: 0.5rem !important;
        flex-wrap: nowrap !important;
    }

    .hero-visual {
        order: 3 !important;
        margin-top: -20rem !important;
        margin-left: 0rem !important;
        width: 100% !important;
        max-width: 600px !important;
        padding: 0 1rem !important;
    }

    .product-demo-mockup {
        margin: 0 auto !important;
        width: 100% !important;
        max-width: 500px !important;
    }

    .hero-university-logos {
        margin-top: -5rem !important;
    }

    /* Make logos one scrollable row on mobile */
    .static-logos {
        display: flex !important;
        flex-wrap: nowrap !important;
        overflow-x: auto !important;
        gap: 1.5rem !important;
        padding: 1.5rem !important;
        justify-content: flex-start !important;
        -webkit-overflow-scrolling: touch !important;
        scrollbar-width: none !important; /* Firefox */
    }

    .static-logos::-webkit-scrollbar {
        display: none !important; /* Chrome, Safari, Edge */
    }

    .university-logo {
        height: 30px !important;
        width: auto !important;
        flex-shrink: 0 !important;
        min-width: 60px !important;
    }

    /* Make specific logos bigger on mobile */
    .hero-university-logos img[src*="Duke"] {
        height: 40px !important;
        width: auto !important;
    }

    .hero-university-logos img[src*="Georgia"] {
        height: 40px !important;
        width: auto !important;
    }

    .hero-university-logos img[src*="Northwestern"] {
        height: 40px !important;
        width: auto !important;
    }

    .hero-university-logos img[src*="Frankfurt"] {
        height: 40px !important;
        width: auto !important;
    }

    /* Ensure video container is properly sized */
    .demo-video {
        width: 120% !important;
        height: auto !important;
        display: block !important;
    }

    .testimonials-section {
        margin-top: 0rem !important;
    }

    /* Force mobile navigation layout */
    .navbar .nav-menu {
        margin-left: auto !important;
        padding: 0 !important;
        display: flex !important;
        justify-content: flex-end !important;
        align-items: center !important;
        gap: 0 !important;
        margin-right: -0.25rem !important;
        width: auto !important;
        position: relative !important;
    }

    .navbar .nav-link {
        padding: 0.3rem 0.1rem !important;
        margin: 0 0.1rem !important;
        font-size: 0.75rem !important;
        letter-spacing: -0.02em !important;
        white-space: nowrap !important;
        display: inline-flex !important;
    }

    /* Position sign in button to far right */
    .nav-btn-primary {
        margin-left: 0.15rem !important;
        padding: 0.3rem 0.6rem !important;
        font-size: 0.8rem !important;
        margin-right: 0 !important;
    }

    /* Enhanced Mobile Footer Layout */
    .footer-otter {
        padding: 3rem 0 6rem 0 !important;
        min-height: auto !important;
    }

    .footer-container,
    .footer-otter .container {
        padding: 0 1.5rem !important;
        max-width: 100% !important;
    }

    .footer-large-text {
        text-align: left !important;
        margin-bottom: 2rem !important;
        padding-left: 1rem !important;
    }

    .footer-brand-text {
        font-size: 2.5rem !important;
        margin-bottom: 1rem !important;
        font-weight: 700 !important;
        letter-spacing: -0.02em !important;
        background: linear-gradient(135deg, #ffffff 0%, #e2e8f0 100%) !important;
        -webkit-background-clip: text !important;
        -webkit-text-fill-color: transparent !important;
        background-clip: text !important;
        text-align: left !important;
    }

    .footer-main {
        display: flex !important;
        flex-direction: column !important;
        align-items: center !important;
        gap: 3rem !important;
        margin-bottom: 4rem !important;
    }

    .footer-description-wrapper {
        text-align: center !important;
        max-width: 85% !important;
        margin: 2rem auto 2rem auto !important;
    }

    .footer-description {
        font-size: 0.95rem !important;
        line-height: 1.6 !important;
        color: #e2e8f0 !important;
        text-align: center !important;
        padding: 0 !important;
        margin: 0 !important;
        font-weight: 400 !important;
    }

    .footer-columns {
        display: flex !important;
        flex-direction: row !important;
        justify-content: center !important;
        gap: 3rem !important;
        width: 100% !important;
        max-width: 400px !important;
        margin: 0 auto !important;
        padding: 0 !important;
    }

    .footer-column {
        display: flex !important;
        flex-direction: column !important;
        align-items: center !important;
        text-align: center !important;
        margin: 0 !important;
        padding: 0 !important;
        flex: 1 !important;
    }

    .footer-column h4 {
        color: #ffffff !important;
        font-size: 1.1rem !important;
        font-weight: 600 !important;
        margin-bottom: 1rem !important;
        letter-spacing: 0.01em !important;
    }

    .footer-column a {
        color: #cbd5e1 !important;
        font-size: 0.95rem !important;
        text-decoration: none !important;
        margin-bottom: 0.75rem !important;
        transition: all 0.3s ease !important;
        font-weight: 400 !important;
        line-height: 1.4 !important;
    }

    .footer-column a:hover {
        color: #ffffff !important;
        transform: translateY(-1px) !important;
    }

    .footer-bottom {
        position: relative !important;
        bottom: auto !important;
        left: auto !important;
        right: auto !important;
        padding: 2rem 0 0 0 !important;
        border-top: 1px solid rgba(255, 255, 255, 0.1) !important;
        background: transparent !important;
        margin-top: 2rem !important;
    }

    .footer-bottom > div {
        display: flex !important;
        flex-direction: column !important;
        align-items: center !important;
        gap: 1.5rem !important;
        width: 100% !important;
        max-width: none !important;
        margin: 0 !important;
        position: relative !important;
    }

    .footer-copyright {
        color: #94a3b8 !important;
        font-size: 0.9rem !important;
        text-align: center !important;
        font-weight: 400 !important;
        position: absolute !important;
        left: 50% !important;
        transform: translateX(-50%) !important;
        width: 100% !important;
    }

    .footer-links {
        display: flex !important;
        flex-wrap: wrap !important;
        justify-content: center !important;
        gap: 1.5rem !important;
        margin: 0 !important;
    }

    .footer-links a {
        color: #94a3b8 !important;
        font-size: 0.85rem !important;
        text-decoration: none !important;
        transition: color 0.3s ease !important;
        font-weight: 400 !important;
    }

    .footer-links a:hover {
        color: #ffffff !important;
    }

    /* Logo adjustments */
    .nav-logo {
        margin-right: auto !important;
    }

    .nav-logo-img {
        height: 45px !important;
    }

    /* Make navbar transparent on mobile like desktop */
    .navbar {
        background: transparent !important;
        border-bottom: none !important;
        box-shadow: none !important;
    }

    /* Consistent text styling */
    .institutions-title {
        font-size: 1rem !important;
        line-height: 1.6 !important;
        font-weight: 600 !important;
        color: #000000 !important;
        margin-bottom: 1.5rem !important;
    }
@media (max-width: 768px) {
    .nav-logo {
        justify-content: flex-start !important;
        padding-left: 0 !important;
        margin-left: 0 !important;
    }

    .nav-logo-img {
        height: 60px !important;
        margin-left: -10px !important;
    }

    .logo-container {
        justify-content: flex-start !important;
        margin-left: -50px !important;
        padding-left: 0 !important;
    }

    .nav-container {
        padding: 0 1rem !important;
    }
}

/* Even smaller screens */
@media (max-width: 480px) {
    /* Shared tile styles - ensure proper stacking */
    .feature-section {
        margin: 0 !important;
        padding: 1rem !important;
        display: flex !important;
        flex-direction: column !important;
        margin-bottom: 2rem !important;
        width: 100% !important;
    }

    /* Ensure feature sections container stacks tiles vertically */
    .features-container,
    .feature-cards-container {
        display: flex !important;
        flex-direction: column !important;
        width: 100% !important;
        gap: 1rem !important;
    }

    .feature-card-container {
        padding: 0 !important;
        margin: 0 !important;
        display: flex !important;
        flex-direction: column !important;
    }

    .feature-content {
        padding: 0 !important;
        margin: 0 !important;
        display: flex !important;
        flex-direction: column !important;
    }

    .feature-text {
        padding-top: 0.5rem !important; /* Minimal padding above titles */
    }

    .feature-visual {
        position: relative !important;
        margin: -1rem auto -1rem auto !important;
        padding: 0 !important;
        display: flex !important;
        align-items: flex-start !important;
        justify-content: center !important;
        overflow: visible !important;
        width: 90vw !important;
    }

    /* First feature tile (Discover) */
    .feature-section:first-child {
        margin-bottom: 1rem !important;  /* Space between tiles */
        height: 450px !important;  /* ADJUST THIS VALUE to control first tile height */
    }

    .feature-section:first-child .feature-text {
        margin-bottom: 0.5rem !important;
    }

    .feature-section:first-child .platform-demo-image {
        transform: scale(1.8) !important;
        transform-origin: center center !important;
        margin: -5rem auto 0 auto !important;
        width: 100% !important;
        height: auto !important;
        display: block !important;
    }

    /* Second feature tile (Champion) */
    .feature-section.feature-section-second {
        height: 450px !important;  /* ADJUST THIS VALUE to control second tile height */
    }

    .feature-section-second .feature-text {
        margin-bottom: 0.5rem !important;
    }

    .feature-section.feature-section-second .platform-demo-image,
    .platform-demo-image-second {
        transform: scale(1.8) !important;
        transform-origin: center center !important;
        margin: 2rem auto 0 auto !important;
        width: 100% !important;
        height: auto !important;
        display: block !important;
    }

    /* Shared styles */
    .feature-text {
        padding-top: 1rem !important;  /* Reduced top padding */
        margin-bottom: 1rem !important;  /* Reduced bottom margin */
    }

    .feature-visual {
        width: 100% !important;
        overflow: visible !important;
    }

    .platform-demo-image {
        width: 100% !important;
        height: auto !important;
        display: block !important;
    }
}}

.footer-text {
        text-align: center !important;
        color: #ffffff !important;
    }

    .nav-bar {
        display: flex !important;
        justify-content: space-between !important;
        align-items: center !important;
        padding: 0.5rem 1rem !important;
        background-color: #ffffff !important;
        border-bottom: 1px solid #eaeaea !important;
    }

    .nav-logo {
        height: 20px !important;
        width: auto !important;
    }

    .nav-tabs {
        display: flex !important;
        gap: 1rem !important;
    }

    .nav-tab {
        font-size: 0.9rem !important;
        color: #000000 !important;
        text-decoration: none !important;
        padding: 0.5rem !important;
        transition: color 0.3s ease !important;
    }

    .nav-tab:hover {
        color: #007bff !important;
    }

    /* Team Page Mobile Styles */
    .team-member {
        padding: 0.5rem 1rem !important;
        gap: 0.5rem !important;
        flex-direction: column !important;
        align-items: center !important;
        text-align: center !important;
        margin-bottom: 0 !important;
    }

    .image-placeholder {
        width: 120px !important;
        height: 120px !important;
        margin: 0 auto !important;
        flex-shrink: 0 !important;
    }

    .team-photo {
        width: 120px !important;
        height: 120px !important;
    }

    .member-info {
        margin-left: 1rem !important;
        margin-right: 1rem !important;
        padding-left: 0.5rem !important;
        padding-right: 0.5rem !important;
        text-align: center !important;
        width: calc(100% - 2rem) !important;
    }

    .member-name {
        font-size: 1rem !important;
        margin-bottom: 0.3rem !important;
    }

    .member-role {
        font-size: 0.8rem !important;
        margin-bottom: 0.5rem !important;
    }

    .member-description {
        font-size: 0.75rem !important;
        line-height: 1.4 !important;
    }

    /* Examples Page Mobile Styles */
    .examples-title {
        margin-top: -5rem !important;
    }

    /* Mobile navbar transparent like desktop - blends with page backgrounds */
    .navbar.home-navbar {
        background: transparent !important;
        backdrop-filter: blur(12px) !important;
        border-bottom: none !important;
    }

    /* Transparent navbar for all other pages on mobile */
    .navbar:not(.home-navbar) {
        background: transparent !important;
        border-bottom: none !important;
    }

    /* Move testimonials to the right */
    .testimonials-section {
        margin-left: -1.5rem !important;
        padding-left: 1rem !important;
    }

    .testimonials-container {
        margin-left: 1rem !important;
    }

    /* Move team title logo to the left */
    .team-title-logo {
        margin-left: -1rem !important;
        transform: translateX(-10px) !important;
    }

    /* Make Let's Connect image larger on mobile */
    .contact-header img[src="connect.png"] {
        max-width: 350px !important;
        width: 100% !important;
        height: auto !important;
    }

    /* Make contact subtitle smaller on mobile */
    .contact-subtitle {
        font-size: 1rem !important;
        line-height: 1.5 !important;
    }

    /* Move Champion Decision-Making tile down */
    .feature-section-second {
        margin-top: 2rem !important;
        padding-top: 2rem !important;
    }



    /* Team page: Add space between "People of" and Noyes image, move image down */
    .team-title-container {
        gap: 1rem !important;
        align-items: center !important;
    }

    .team-title-logo {
        margin-left: 0 !important;
        margin-top: 0.5rem !important;
        transform: translateX(0) !important;
    }

    /* Make Sebastion photo same size as others - remove circular border */
    .team-member:first-of-type .member-photo {
        width: 120px !important;
        height: 120px !important;
    }

    .team-member:first-of-type .member-photo img {
        width: 120px !important;
        height: 120px !important;
        border-radius: 0 !important;
        object-fit: cover !important;
    }

    /* Fix tile borders being cut off on mobile */
    .feature-card-container {
        overflow: hidden !important;
        padding-bottom: 1rem !important;
        border: 2px dashed #9ca3af !important;
        border-radius: 16px !important;
    }

    .feature-content {
        padding-bottom: 1rem !important;
        overflow: hidden !important;
    }

    /* Ensure images don't overflow the tile borders */
    .feature-visual {
        overflow: hidden !important;
        max-height: calc(100% - 2rem) !important;
    }

    /* Make tile images larger and take full width on mobile */
    .platform-image {
        width: 180% !important;
        height: 180% !important;
        object-fit: cover !important;
        transform: translate(-20%, -15%) !important;
    }

    .feature-card-gradient:first-child .platform-image {
        width: 170% !important;
        height: 170% !important;
        transform: translate(-18%, -12%) !important;
    }

    .feature-card-gradient:last-child .platform-image {
        width: 200% !important;
        height: 200% !important;
        transform: translate(-25%, -25%) !important;
    }

    /* Adjust tile heights to accommodate content properly */
    .feature-section:first-child {
        height: 480px !important;
    }

    .feature-section-second {
        height: 480px !important;
    }
