/* Mobile menu button */
.mobile-menu-btn {
    display: none;
    background: none;
    border: none;
    color: #fff;
    font-size: 1.5rem;
    cursor: pointer;
    padding: 0.5rem;
    transition: color 0.3s ease;
}

.mobile-menu-btn:hover {
    color: #00ffd5;
}

/* Mobile styles */
@media screen and (max-width: 768px) {
    .cyber-nav {
        padding: 0.5rem 1rem;
        background: #111;
        border-bottom: 1px solid #00ffd5;
        position: fixed;
        top: 0;
        left: 0;
        width: 100%;
        z-index: 1000;
    }

    .nav-brand a {
        font-size: 1.2rem;
    }

    .mobile-menu-btn {
        display: block;
        position: absolute;
        right: 1rem;
        top: 50%;
        transform: translateY(-50%);
    }

    .nav-links {
        display: none;
        position: absolute;
        top: 100%;
        left: 0;
        width: 100%;
        background: #111;
        flex-direction: column;
        padding: 0;
        gap: 0;
        border-bottom: 1px solid #00ffd5;
    }

    .nav-links a {
        padding: 0.8rem 1rem;
        width: 100%;
        text-align: left;
        border-radius: 0;
        font-size: 0.9rem;
        color: #00ffd5;
    }

    .nav-links a:hover {
        background: rgba(0, 255, 213, 0.1);
    }

    .nav-links a.active {
        background: rgba(0, 255, 213, 0.15);
        box-shadow: none;
    }

    .nav-links.active {
        display: flex;
    }

    /* Adjust body padding for mobile */
    body {
        padding-top: 50px;
    }
}

@media (max-width: 768px) {
    body {
        padding-top: 60px;
    }
    .cyber-nav {
        position: fixed;
        top: 0;
        left: 0;
        width: 100%;
        z-index: 99999;
        background-color: rgba(10, 10, 15, 0.9);
        border-bottom: 2px solid #FFD700;
        height: 60px;
    }

    .mobile-menu-btn {
        display: block;
        position: absolute;
        right: 1rem;
        top: 50%;
        transform: translateY(-50%);
        z-index: 100000;
        font-size: 1.2rem;
        padding: 0.3rem;
        background: none;
        border: none;
        color: inherit;
        cursor: pointer;
    }

    .nav-links {
        display: none;
        position: fixed;
        top: 60px;
        left: 0;
        width: 100%;
        background-color: rgba(10, 10, 15, 0.95);
        backdrop-filter: blur(10px);
        padding: 1rem;
        z-index: 99998;
        border-bottom: 2px solid var(--neon-blue);
    }

    .nav-links.active {
        display: flex;
        flex-wrap: wrap;
        justify-content: center;
        gap: 15px;
    }

    .nav-links a {
        flex: 0 1 calc(40% - 15px);
        margin: 0;
        padding: 8px 15px;
        font-size: 0.9rem;
        text-align: center;
        color: #FFD700;
        border: 1px solid transparent;
        transition: all 0.3s ease;
        white-space: nowrap;
    }

    .nav-links a:hover,
    .nav-links a.active {
        border-color: #FFD700;
        text-shadow: 0 0 5px #FFD700;
    }

    .nav-links .contact-button {
        margin-top: 1rem;
        font-size: 1rem;
        padding: 0.5rem 1.2rem;
        background: var(--neon-blue);
        color: var(--bg-dark);
        font-weight: bold;
    }

    /* Mobile dropdown styles */
    .nav-dropdown {
        width: 100%;
        flex: 0 1 100%;
    }

    .nav-dropdown .dropdown-toggle {
        width: 100%;
        justify-content: center;
        padding: 8px 15px;
        font-size: 0.9rem;
        color: #FFD700;
        border: 1px solid transparent;
    }

    .nav-dropdown .dropdown-toggle i {
        margin-left: 0.5rem;
        transition: transform 0.3s ease;
    }

    .nav-dropdown .dropdown-menu {
        position: static;
        display: none;
        width: 100%;
        background: rgba(10, 10, 15, 0.95);
        border: 1px solid #FFD700;
        border-radius: 4px;
        margin-top: 0.5rem;
        padding: 0.5rem 0;
        opacity: 1;
        visibility: visible;
        transform: none;
        box-shadow: none;
    }

    .nav-dropdown .dropdown-menu.show {
        display: block;
    }

    .nav-dropdown .dropdown-menu a {
        display: block;
        padding: 8px 20px;
        color: #FFD700;
        font-size: 0.85rem;
        text-align: left;
        border-left: 3px solid transparent;
        margin: 0;
        flex: none;
    }

    .nav-dropdown .dropdown-menu a:hover,
    .nav-dropdown .dropdown-menu a.active {
        background: rgba(255, 215, 0, 0.1);
        border-left-color: #FFD700;
        text-shadow: 0 0 5px #FFD700;
    }

    /* Animation for menu items */
    .nav-links.active a {
        animation: slideIn 0.3s ease-out forwards;
        opacity: 0;
    }

    @keyframes slideIn {
        from {
            transform: translateX(-20px);
            opacity: 0;
        }
        to {
            transform: translateX(0);
            opacity: 1;
        }
    }

    /* Delay each menu item animation */
    .nav-links.active > a:nth-child(1) { animation-delay: 0.1s; }
    .nav-links.active > a:nth-child(2) { animation-delay: 0.2s; }
    .nav-links.active > a:nth-child(3) { animation-delay: 0.3s; }
    .nav-links.active > a:nth-child(4) { animation-delay: 0.4s; }
    .nav-links.active > a:nth-child(5) { animation-delay: 0.5s; }
    .nav-links.active > a:nth-child(6) { animation-delay: 0.6s; }
    .nav-links.active > a:nth-child(7) { animation-delay: 0.7s; }
    .nav-links.active > a:nth-child(8) { animation-delay: 0.8s; }
    .nav-links.active > a:nth-child(9) { animation-delay: 0.9s; }
}

/* Only hide nav-links on mobile for army pages */
@media (max-width: 768px) {
    .army .nav-links {
        display: none;
        position: fixed;
        top: 60px;
        left: 0;
        right: 0;
        background-color: #000000;
        z-index: 1000;
        height: auto;
        max-height: fit-content;
    }

    .army .nav-links.active {
        display: grid;
        grid-template-columns: repeat(2, 1fr);
        gap: 10px;
        padding: 15px;
        justify-items: center;
        align-items: start;
    }
}

/* Only apply these styles on mobile */
@media (max-width: 768px) {
    .army .nav-links a {
        width: auto;
        min-width: 120px;
        max-width: 150px;
        margin: 0;
        padding: 8px 15px;
        font-size: 0.9rem;
        text-align: center;
        color: #FFD700;
        border: 1px solid transparent;
        transition: all 0.3s ease;
    }

    .army .nav-links.active {
        flex-direction: row;
        flex-wrap: wrap;
        justify-content: center;
        gap: 10px;
    }

    .army .nav-links.active a {
        width: calc(50% - 20px);
        min-width: 120px;
        max-width: 180px;
        margin: 2px;
        padding: 6px 10px;
        text-align: center;
    }
}

/* Ensure dropdown menu items are not affected by army nav-links styles */
.army .nav-dropdown .dropdown-menu,
body.army .nav-dropdown .dropdown-menu {
    position: absolute !important;
    top: 100% !important;
    left: 0 !important;
    display: block !important;
    background: rgba(10, 10, 15, 0.98) !important;
    border: 2px solid var(--neon-blue) !important;
    border-radius: 4px !important;
    min-width: 200px !important;
    padding: 0.5rem 0 !important;
    margin-top: 0.3rem !important;
    z-index: 999999 !important;
    box-shadow: 0 4px 20px rgba(0, 243, 255, 0.3) !important;
}

.army .nav-dropdown .dropdown-menu a,
body.army .nav-dropdown .dropdown-menu a {
    display: block !important;
    width: auto !important;
    min-width: auto !important;
    max-width: none !important;
    padding: 0.7rem 1.2rem !important;
    margin: 0 !important;
    text-align: left !important;
    color: var(--text-color) !important;
    border: none !important;
    border-left: 3px solid transparent !important;
}

@media (max-width: 378px) {
    .teams-table-wrapper {
        display: flex;
        justify-content: center; /* Center the table within the wrapper */
        width: 100%; /* Full width for responsiveness */
        margin: 0 10px; /* Add horizontal margins to prevent overflow */
    }

    .teams-table {
        width: 100%; /* Full width for mobile */
        max-width: 800px; /* Set a maximum width for mobile */
        border-collapse: collapse; /* Ensure borders are collapsed */
    }

    .teams-table th, .teams-table td {
        border: none; /* Remove borders from table cells */
        padding: 10px; /* Keep padding for spacing */
        text-align: left;
    }

    .teams-table tr:nth-child(even) {
        background-color: #333333; /* Dark gray for even rows */
    }

    .teams-table tr:nth-child(odd) {
        background-color: #444444; /* Slightly lighter dark gray for odd rows */
    }
    .section-title {
        font-size: 24px;
        color: #FF007F;
        text-shadow: 0 0 10px #FF007F;
    }
    .section-description {
        font-size: 16px;
        padding: 0 10px;
        color: #00FFCC;
    }
    .team-info {
        display: flex;
        flex-direction: column;
        align-items: center;
    }
    .team-info img {
        max-width: 120px; /* Increase the size of the team logo */
        height: auto;
        border: 2px solid #00FFFF; /* Change border to neon blue */
        border-radius: 10px;
    }
    .teams-container {
        padding: 20px;
        background-color: rgba(0, 0, 0, 0.8);
        border-radius: 10px;
        margin: 10px;
    }
    .team-info {
        margin: 15px 0;
        text-align: center;
    }
}

@media (min-width: 379px) and (max-width: 768px) {
    .teams-table-wrapper {
        display: flex;
        justify-content: center; /* Center the table within the wrapper */
        width: 100%; /* Full width for responsiveness */
        margin: 0 10px; /* Add horizontal margins to prevent overflow */
    }

    .teams-table {
        width: 100%; /* Full width for mobile */
        max-width: 800px; /* Set a maximum width for mobile */
        border-collapse: collapse; /* Ensure borders are collapsed */
    }

    .teams-table th, .teams-table td {
        border: none; /* Remove borders from table cells */
        padding: 10px; /* Keep padding for spacing */
        text-align: left;
    }

    .teams-table tr:nth-child(even) {
        background-color: #333333; /* Dark gray for even rows */
    }

    .teams-table tr:nth-child(odd) {
        background-color: #444444; /* Slightly lighter dark gray for odd rows */
    }
    .section-title {
        font-size: 24px;
        color: #FF007F;
        text-shadow: 0 0 10px #FF007F;
    }
    .section-description {
        font-size: 16px;
        padding: 0 10px;
        color: #00FFCC;
    }
    .team-info {
        display: flex;
        flex-direction: column;
        align-items: center;
    }
    .team-info img {
        max-width: 120px; /* Increase the size of the team logo */
        height: auto;
        border: 2px solid #00FFFF; /* Change border to neon blue */
        border-radius: 10px;
    }
    .teams-container {
        padding: 20px;
        background-color: rgba(0, 0, 0, 0.8);
        border-radius: 10px;
        margin: 10px;
    }
    .team-info {
        margin: 15px 0;
        text-align: center;
    }
}

@media (min-width: 769px) {
    .teams-table-wrapper {
        display: flex;
        justify-content: center; /* Center the table within the wrapper */
        width: 100%; /* Full width for responsiveness */
        margin: 0 10px; /* Add horizontal margins to prevent overflow */
    }

    .teams-table {
        width: 100%; /* Full width for larger screens */
        max-width: none; /* Remove max-width to allow full size */
        margin: 0 auto; /* Center the table */
        border-collapse: collapse; /* Ensure borders are collapsed */
    }

    .teams-table th, .teams-table td {
        border: none; /* Remove borders from table cells */
        padding: 10px; /* Keep padding for spacing */
        text-align: left;
    }

    .teams-table tr:nth-child(even) {
        background-color: #333333; /* Dark gray for even rows */
    }

    .teams-table tr:nth-child(odd) {
        background-color: #444444; /* Slightly lighter dark gray for odd rows */
    }
    .section-title {
        font-size: 24px;
        color: #FF007F;
        text-shadow: 0 0 10px #FF007F;
    }
    .section-description {
        font-size: 16px;
        padding: 0 10px;
        color: #00FFCC;
    }
    .team-info {
        display: flex;
        align-items: center; /* Align items vertically */
    }
    .team-info img {
        max-width: 120px; /* Increase the size of the team logo */
        height: auto;
        border: 2px solid #00FFFF; /* Change border to neon blue */
        border-radius: 10px;
        margin-right: 10px; /* Add space between logo and name */
    }
    .teams-container {
        padding: 20px;
        background-color: rgba(0, 0, 0, 0.8);
        border-radius: 10px;
        margin: 10px;
    }
    .team-info {
        margin: 15px 0;
        text-align: center;
    }
}

body {
    background-color: #0c0c0c;
    color: #e0e0e0;
    font-family: 'Inter', sans-serif;
}

.cyber-footer {
    background-color: rgba(10, 10, 15, 0.9);
    color: #e0e0e0;
    text-align: center;
    padding: 10px;
}

/* Mobile menu button */
.mobile-menu-btn {
    display: none;
    background: none;
    border: none;
    color: #FFD700;
    font-size: 1.5rem;
    cursor: pointer;
    padding: 10px;
    z-index: 1000;
}

/* Only apply mobile styles when screen is small enough */
@media (max-width: 768px) {
    .mobile-menu-btn {
        display: block;
    }

    .nav-links {
        display: none;
        position: fixed;
        top: 60px;
        left: 0;
        right: 0;
        height: auto;
        background-color: #000000;
        z-index: 1000;
    }

    .nav-links.active {
        display: grid;
        grid-template-columns: repeat(2, 1fr);
        gap: 10px;
        padding: 15px;
        justify-items: center;
        align-items: start;
    }

    .nav-links a {
        width: auto;
        min-width: 120px;
        max-width: 150px;
        margin: 0;
        padding: 8px 15px;
        font-size: 0.9rem;
        text-align: center;
        color: #FFD700;
        border: 1px solid transparent;
        transition: all 0.3s ease;
    }
}

/* Desktop nav styles */
@media (min-width: 769px) {
    .nav-links {
        display: flex;
        align-items: center;
        gap: 20px;
    }

    .nav-links a {
        color: #FFD700;
        text-decoration: none;
        padding: 5px 10px;
        transition: all 0.3s ease;
    }
}

/* Army page specific mobile styles */
body.army .mobile-menu-btn {
    color: var(--text-color);
    text-shadow: 0 0 5px var(--neon-blue);
}

body.army .mobile-menu-btn:hover {
    color: var(--neon-blue);
}

@media (max-width: 768px) {
    body.army .nav-links {
        background: #222222; /* Dark background for the menu */
        border: 1px solid var(--neon-blue);
        box-shadow: 0 0 15px rgba(0, 243, 255, 0.2);
        display: none;
    }

    body.army .nav-links.active {
        display: flex;
    }

    body.army .nav-links a {
        text-transform: uppercase;
        letter-spacing: 1px;
    }

    body.army .nav-links a:hover,
    body.army .nav-links a:focus,
    body.army .nav-links a.active {
        color: var(--neon-blue);
        text-shadow: 0 0 5px var(--neon-blue);
    }

    body.army .nav-links .contact-button {
        border: 1px solid var(--neon-blue);
        background: rgba(0, 243, 255, 0.1);
    }

    body.army .nav-links .contact-button:hover {
        background: var(--neon-blue);
        color: var(--bg-dark);
    }

    body.army #header {
        padding-bottom: 0;
    }
}
