@import url('https://fonts.googleapis.com/css2?family=Poppins:wght@100;200;300;400;500;600&display=swap');

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    text-decoration: none;
    border: none;
    outline: none;
    font-family: 'Poppins', sans-serif;
}

html {
    font-size: 62.5%;
}

body {
    width: 100%;
    min-height: 100vh;
    overflow-x: hidden;
    background-color: black;
    color: white;
}

header {
    margin-top: 20px;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    padding: 1rem 9%;
    background-color: rgba(0, 0, 0, 0.8);
    display: flex;
    justify-content: space-between;
    align-items: center;
    z-index: 100;
}

.logo img {
    height: 50px;
    cursor: pointer;
    transition: 0.5s ease;
}

.logo img:hover {
    transform: scale(1.1);
}

nav a {
    font-size: 1.8rem;
    color: white;
    margin-left: 4rem;
    font-weight: 500;
    transition: 0.3s ease;
    border-bottom: 3px solid transparent;
}

nav a:first-child {
    margin-left: 0;
}

nav a:hover,
nav a.active {
    color: #ffa44b; /* THEME COLOR */
    border-bottom: 3px solid #ffa44b; /* THEME COLOR */
}

nav {
    display: flex;
    align-items: center;
}

section {
    min-height: 100vh;
    padding: 12rem 9% 5rem;
}

span {
    color: #ffa44b; /* THEME COLOR */
}

.page-title {
    font-size: 5rem;
    text-align: center;
    margin-bottom: 5rem;
}

.card-container {
    display: flex;
    flex-wrap: wrap;
    gap: 3rem;
    justify-content: center;
}

.card {
    background: #111;
    border: 1px solid var(--card-color, #ffa44b);
    border-radius: 1.5rem;
    padding: 3rem;
    width: 320px; /* A bit wider for more text */
    text-align: center;
    box-shadow: 0 0 10px var(--card-shadow, rgba(255, 164, 75, 0.2));
    display: flex;
    flex-direction: column;
    align-items: center;
    transition: all 0.4s ease;
    position: relative; /* For the full-card link */
}

.card h3 {
    font-size: 2.5rem;
    margin-bottom: 1rem;
    color: var(--card-color, #ffa44b);
    position: relative;
    z-index: 2;
}

.card-icon {
    width: 60px;
    height: 60px;
    object-fit: contain;
    margin-bottom: 1rem;
    position: relative;
    z-index: 2;
}

.card p {
    font-size: 1.4rem;
    flex-grow: 1;
    position: relative;
    z-index: 2;
    color: #a0aabf;
}

.card .btn {
    display: inline-block;
    padding: 1rem 2.8rem;
    background-color: transparent;
    border-radius: 4rem;
    font-size: 1.6rem;
    letter-spacing: 0.3rem;
    font-weight: 600;
    border: 2px solid var(--card-color, #48d1cc);
    transition: 0.3s ease;
    cursor: pointer;
    color: var(--card-color, #ffa44b);
}

.card .btn:hover {
    transform: scale(1.03);
    background-color: var(--card-color, #ffa44b);
    color: black;
    box-shadow: 0 0 25px var(--card-shadow, #ffa44b);
}

/* Card Hover Effects */
.card:hover {
    transform: translateY(-10px);
    background-color: var(--card-color, #ffa44b);
    box-shadow: 0 10px 25px var(--card-shadow, rgba(255, 164, 75, 0.4));
}

.card:hover h3, 
.card:hover p,
.card:hover .card-icon {
    color: #111 !important;
}

.card:hover .btn {
    background-color: #111;
    color: var(--card-color, #ffa44b);
    border-color: #111;
}

.card:hover .btn:hover {
    background-color: rgba(0, 0, 0, 0.8);
    box-shadow: 0 0 15px rgba(0, 0, 0, 0.5);
}

/* Navbar Dropdown */
.navbar-dropdown {
    position: relative;
    display: inline-block;
    margin-left: 4rem;
}

.navbar-dropdown::before {
    content: '';
    position: absolute;
    left: 0;
    right: 0;
    top: 100%;
    height: 1.5rem; /* This is the bridge height */
    background-color: transparent;
}

.navbar-dropdown-content {
    display: none;
    position: absolute;
    background-color: #111;
    min-width: 260px;
    box-shadow: 0px 8px 16px 0px rgba(0,0,0,0.5);
    z-index: 1;
    border-radius: 0.5rem;
    border: 1px solid #333;
    padding: 0.5rem 0;
    margin-top: 1.5rem;
    left: 50%;
    transform: translateX(-50%);
}

.navbar-dropdown-content a {
    color: white;
    padding: 1.2rem 2rem;
    text-decoration: none;
    display: block;
    font-size: 1.6rem;
    margin-left: 0 !important;
    border-bottom: none !important;
    transition: background-color 0.2s ease;
    font-weight: 500;
    text-align: left;
}

/* Reset margin for the dropdown trigger link, as the container gets the margin */
.navbar-dropdown > a {
    margin-left: 0;
}

.navbar-dropdown-content a:hover {
    background-color: #222;
    color: #ffa44b;
}

/* Responsive Navbar */
.nav-item-store,
.nav-item-affiliates,
.nav-item-ads,
.nav-item-devs,
.nav-item-resources,
.nav-item-about {
    display: inline-block;
}

.nav-dropdown-container {
    position: relative;
    display: none; /* Hidden by default, shown when items collapse */
    margin-left: 2rem;
}

.nav-more-arrow {
    font-size: 2.4rem;
    color: white;
    padding: 0.5rem;
    border-bottom: 3px solid transparent;
    cursor: pointer;
}

.nav-dropdown-content {
    display: none; /* Toggled by JS */
    position: absolute;
    right: 0;
    top: 100%;
    margin-top: 1.5rem;
    background-color: #111;
    min-width: 220px;
    box-shadow: 0px 8px 16px 0px rgba(0,0,0,0.5);
    z-index: 1;
    border-radius: 0.5rem;
    border: 1px solid #333;
    padding: 0.5rem 0;
    overflow: hidden;
}

.nav-dropdown-content a {
    display: none; /* Links inside are hidden by default */
    color: white;
    padding: 1.2rem 2rem;
    font-size: 1.6rem;
    margin-left: 0;
    border-bottom: none;
    transition: background-color 0.2s ease;
    font-weight: 500;
}

.nav-dropdown-content a:hover,
.nav-dropdown-content a.active {
    background-color: #222;
    border-bottom: none;
    color: #ffa44b;
}

.navbar-dropdown:hover .navbar-dropdown-content {
    display: block;
}

.navbar-dropdown:hover > a,
.navbar-dropdown > a.active {
    color: #ffa44b;
    border-bottom-color: #ffa44b;
}

/* Breakpoints for responsive navbar */
@media (max-width: 1250px) {
    nav .nav-item-resources { display: none; }
    .nav-dropdown-container { display: inline-block; }
    .nav-dropdown-content a[href*="resources.html"] { display: block; }
}

@media (max-width: 1150px) {
    nav .nav-item-about { display: none; }
    .nav-dropdown-content a[href*="about.html"] { display: block; }
}

@media (max-width: 1024px) {
    nav .nav-item-devs { display: none; }
    .nav-dropdown-content a[href*="developers.html"] { display: block; }
}

@media (max-width: 920px) {
    nav .nav-item-ads { display: none; }
    .nav-dropdown-content a[href*="ads.html"] { display: block; }
}

@media (max-width: 820px) {
    nav .nav-item-affiliates { display: none; }
    .nav-dropdown-content a[href*="affiliates.html"] { display: block; }
}

@media (max-width: 750px) {
    nav .nav-item-store { display: none; }
    .nav-dropdown-content a[href*="store.html"] { display: block; }
}

footer {
    background-color: #050505;
    padding: 5rem 9% 0;
    border-top: 1px solid #222;
    overflow-x: hidden;
}

.footer-top-content {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    flex-wrap: wrap;
    gap: 4rem;
    margin-bottom: 5rem;
}

.footer-logo img {
    width: 80px;
    height: auto;
}

.footer-links-container {
    display: flex;
    justify-content: flex-end;
    flex-wrap: wrap;
    gap: 2.5rem;
}

.footer-column {
    min-width: 160px;
}

.footer-column h3 {
    font-size: 2rem;
    color: white;
    margin-bottom: 2rem;
    position: relative;
    padding-bottom: 1rem;
    font-weight: 600;
}

.footer-column h3::after {
    content: '';
    position: absolute;
    left: 0;
    bottom: 0;
    width: 40px;
    height: 2px;
    background-color: #ffa44b;
}

.footer-column ul {
    list-style: none;
    padding: 0;
}

.footer-column ul li {
    margin-bottom: 1.2rem;
}

.footer-column ul li a {
    font-size: 1.5rem;
    color: #a0aabf;
    transition: all 0.3s ease;
    border-bottom: none;
    margin-left: 0;
}

.footer-column ul li a:hover {
    color: #ffa44b;
    padding-left: 5px;
    border-bottom: none;
}

.footer-column ul li a[href*="aeropro.html"]:hover { color: #788fff; }
.footer-column ul li a[href*="aeroprogold.html"]:hover { color: #ffe553; }
.footer-column ul li a[href*="courses.html"]:hover { color: #48d1cc; }
.footer-column ul li a[href*="staff/login.html"]:hover { color: #ff65f2; }
.footer-column ul li a[href*="discord.gg"]:hover { color: #5865F2; }

.footer-banner {
    text-align: center;
    padding-top: 4rem;
}

.footer-banner img {
    max-width: 800px;
    width: 100%;
    height: auto;
}

@media (max-width: 768px) {
    .footer-top-content {
        flex-direction: column;
        align-items: center;
        text-align: center;
    }
    .footer-links-container {
        justify-content: center;
        width: 100%;
    }
    .footer-column h3::after {
        left: 50%;
        transform: translateX(-50%);
    }
}

.footer-left {
    display: flex;
    align-items: flex-start;
    gap: 3rem;
}

@media (max-width: 768px) {
    .footer-left {
        flex-direction: column;
        align-items: center;
    }
}

.footer-settings {
    padding-top: 1rem;
}

.footer-settings h3 {
    font-size: 1.4rem;
    color: #a0aabf;
    margin-bottom: 0.5rem;
    font-weight: 500;
    text-align: left;
}

.theme-switch {
    position: relative;
    display: inline-block;
    width: 60px;
    height: 34px;
}

.theme-switch input {
    opacity: 0;
    width: 0;
    height: 0;
}

.switch-slider {
    position: absolute;
    cursor: pointer;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: #1a1a1a;
    border: 1px solid #333;
    transition: .4s;
    border-radius: 34px;
}

.switch-icon-container {
    position: absolute;
    height: 26px;
    width: 26px;
    left: 3px;
    bottom: 3px;
    background-color: #a0aabf;
    transition: .4s;
    border-radius: 50%;
    display: flex;
    justify-content: center;
    align-items: center;
    color: #1a1a1a;
    font-size: 1.4rem;
}

.theme-switch input:checked + .switch-slider .switch-icon-container {
    transform: translateX(26px);
}

.switch-slider .fa-sun { display: none; }
.theme-switch input:checked + .switch-slider .fa-moon { display: none; }
.theme-switch input:checked + .switch-slider .fa-sun { display: block; }

body.light-theme {
    background-color: white;
    color: black;
}

body.light-theme header {
    background-color: rgba(255, 255, 255, 0.8);
}

body.light-theme nav a,
body.light-theme .nav-more-arrow {
    color: black;
}

body.light-theme .switch-slider {
    background-color: #f0f0f0;
    border-color: #dcdcdc;
}

body.light-theme .switch-icon-container {
    background-color: #555;
    color: #f0f0f0;
}

body.light-theme input:checked + .switch-slider .switch-icon-container {
    background-color: #a0aabf;
    color: #1a1a1a;
}

body.light-theme .card {
    background: white;
    border-color: var(--card-color, #ffa44b);
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.05);
}

body.light-theme .card:hover h3,
body.light-theme .card:hover p,
body.light-theme .card:hover .card-icon {
    color: #111 !important;
}

body.light-theme .navbar-dropdown-content,
body.light-theme .nav-dropdown-content {
    background-color: white;
    border-color: #e0e0e0;
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.1);
}

body.light-theme .navbar-dropdown-content a,
body.light-theme .nav-dropdown-content a {
    color: #1a1a1a;
}

body.light-theme .navbar-dropdown-content a:hover,
body.light-theme .nav-dropdown-content a:hover {
    background-color: #f5f5f5;
}

body.light-theme footer {
    background-color: white;
    border-top-color: #e0e0e0;
}

body.light-theme .footer-column h3,
body.light-theme .footer-settings h3 {
    color: black;
}

body.light-theme .footer-column ul li a {
    color: #555;
}