/* Main CSS file for KnowMe - Consolidated and modular */

/* ================================= */
/* CSS CUSTOM PROPERTIES (VARIABLES) */
/* ================================= */
:root {
    --primary-color: #005f83;
    --secondary-color: #00455E;
    --accent-color: #d79248;
    --accent-color-2: #00827B;
    --background-color: #f9fbfd;
    --text-color: #333333;
    --light-text-color: #666666;
    --border-radius: 12px;
    --transition: all 0.3s ease;
    --shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
    --shadow-strong: 0 6px 20px rgba(0, 0, 0, 0.15);
}

/* ================================= */
/* ALPINE.JS AND FRAMEWORK UTILITIES */
/* ================================= */
/* Hide Alpine.js elements before Alpine initializes */
[x-cloak] {
    display: none !important;
}

/* Common animation utilities */
.fade-in {
    animation: fadeIn 0.5s ease-in-out;
}

.slide-in-right {
    animation: slideInRight 0.3s ease-out;
}

@keyframes fadeIn {
    0% { opacity: 0; transform: translateY(10px); }
    100% { opacity: 1; transform: translateY(0); }
}

@keyframes slideInRight {
    0% { opacity: 0; transform: translateX(100%); }
    100% { opacity: 1; transform: translateX(0); }
}

body {
    background-color: var(--background-color);
}

main {
    padding-top: 0;
}

/* Navbar styling */
.navbar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    position: fixed;
    top: 12px;
    left: 50%;
    transform: translateX(-50%);
    width: calc(100% - 40px);
    max-width: 1100px;
    padding: 10px 24px;
    border-radius: 9999px;
    background: rgba(255, 255, 255, 0.88);
    backdrop-filter: blur(14px);
    border: 1px solid rgba(0, 95, 131, 0.08);
    box-shadow: 0 18px 45px rgba(0, 95, 131, 0.18);
    z-index: 1000;
    transition: transform 0.3s ease, box-shadow 0.3s ease, background 0.3s ease;
    min-height: 75px;
}

.navbar .logo {
    font-size: 1.5rem;
    font-weight: 600;
    color: #005f83;
    display: flex;
    align-items: center;
}

.navbar .logo img {
    height: 42px;
    margin-right: 10px;
}

.nav-links.active {
    display: flex; /* Show the dropdown menu */
}

.navbar ul {
    list-style: none;
    display: flex;
    gap: 20px;
}

.navbar ul li {
    display: inline-block;
}

.navbar ul li a {
    position: relative;
    display: inline-block;
    text-decoration: none;
    font-size: 1rem;
    font-weight: 500;
    color: var(--text-color);
    padding: 10px 18px;
    border-radius: 999px;
    transition: color 0.3s ease;
}

.navbar ul li a::after {
    content: '';
    position: absolute;
    left: 20%;
    bottom: 2px;
    transform: translateY(100%);
    width: 60%;
    height: 3px;
    background: linear-gradient(90deg, var(--primary-color), var(--accent-color));
    border-radius: 999px;
    transition: opacity 0.25s ease;
    opacity: 0;
}

.navbar ul li a:hover,
.navbar ul li a:focus {
    color: var(--primary-color);
}

.navbar ul li a:hover::after,
.navbar ul li a:focus::after,
.navbar ul li a.active::after {
    opacity: 1;
}



.menu-toggle {
    display: none;
    align-items: center;
    justify-content: center;
    flex-direction: column;
    gap: 7px;
    width: 34px;
    height: 26px;
    padding: 0;
    cursor: pointer;
    background: none;
    border: none;
    margin-left: -10px;
}

.menu-toggle-bar {
    width: 70%;
    height: 4px;
    background: var(--primary-color);
    border-radius: 999px;
    transition: transform 0.25s ease, opacity 0.25s ease, background 0.25s ease;
}

.menu-toggle.is-active .menu-toggle-bar:nth-child(1) {
    transform: translateY(14px) rotate(45deg);
}

.menu-toggle.is-active .menu-toggle-bar:nth-child(2) {
    opacity: 0;
    transform: scaleX(0.4);
}

.menu-toggle.is-active .menu-toggle-bar:nth-child(3) {
    transform: translateY(-7px) rotate(-45deg);
}

/* Footer styling */
.site-footer {
    background: transparent;
    color: white;
    padding: 50px 0 60px;
}

.footer-panel {
    position: relative;
    width: calc(100% - 40px);
    max-width: 1100px;
    margin: 0 auto;
    padding: 14px 30px;
    border-radius: 9999px;
    background: linear-gradient(135deg, rgba(0,95,131,0.95), rgba(0,130,123,0.92));
    box-shadow: 0 18px 45px rgba(0, 75, 105, 0.28);
    border: 1px solid rgba(255, 255, 255, 0.08);
    backdrop-filter: blur(14px);
    min-height: 75px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 24px;
}

.footer-left,
.footer-right {
    display: flex;
    align-items: center;
    gap: 18px;
}

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

.footer-right {
    justify-content: flex-end;
    text-align: right;
}

.footer-links {
    display: flex;
    align-items: center;
    gap: 14px;
    flex-wrap: wrap;
}

.footer-link {
    background: none;
    border: none;
    color: #ffffff;
    text-decoration: none;
    font-size: 0.95rem;
    font-family: inherit;
    padding: 0;
    cursor: pointer;
    transition: color 0.3s ease;
}

.footer-link:hover,
.footer-link:focus {
    color: #f6c27d;
    outline: none;
}

.footer-separator {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.35);
}

.footer-copy {
    margin: 0;
    font-size: 0.95rem;
    opacity: 0.9;
}


.site-footer a {
    color: inherit;
    text-decoration: none;
    transition: color 0.3s ease;
}

.site-footer a:hover,
.site-footer a:focus {
    color: #f6c27d;
}

/* Field input styling overrides */
input[type="email"] {
    width: 100%;
    padding: 12px 16px;
    border: 2px solid #ddd;
    border-radius: 12px;
    font-size: 1rem;
    font-family: 'Lexend', sans-serif;
    transition: all 0.5s ease-in-out;
}

input[type="email"]:focus {
    outline: none;
    border-color: #005f83;
    box-shadow: 0 0 0 3px rgba(0, 95, 131, 0.1);
}

input[type="email"]:hover {
    border-color: #00455E;
}

/* Responsive navbar */
@media (max-width: 1024px) {
    main > *:first-child {
        padding-top: 100px;
        margin-top: -100px;
    }

    .navbar .menu-toggle {
        display: flex;
    }

    .navbar .nav-links {
        display: none;
        position: fixed;
        top: 88px;
        right: 16px;
        width: min(260px, calc(100% - 32px));
        background: rgba(255, 255, 255, 0.96);
        border-radius: 20px;
        padding: 20px;
        border: 1px solid rgba(0, 95, 131, 0.1);
        box-shadow: 0 18px 40px rgba(0, 75, 105, 0.25);
        flex-direction: column;
    }
    
    .navbar .nav-links.active {
        display: flex;
    }
    
    .navbar .logo {
        font-size: 1.2rem;
    }
    
    .navbar .logo img {
        height: 42px;
    }

    .navbar ul {
        flex-direction: column;
        display: none;
    }

    .navbar ul.active {
        display: flex;
    }

    .navbar ul li {
        text-align: center;
        margin: 5px 0;
    }

    .navbar ul li a {
        color: var(--primary-color);
        padding: 12px 0;
    }

    .name-inputs {
        flex-direction: column;
        gap: 15px;
    }

    .mobile-spacer {
        height: 80px;
        width: 100%;
    }

    .footer-panel {
        flex-direction: column;
        text-align: center;
        gap: 16px;
    }

    .footer-left,
    .footer-right {
        flex-direction: column;
        gap: 10px;
        justify-content: center;
    }

    .footer-right {
        text-align: center;
    }

    .footer-separator {
        display: none;
    }
}

@keyframes gradientFlow {
    0% {
        background-position: 0% 50%;
    }
    50% {
        background-position: 100% 50%;
    }
    100% {
        background-position: 0% 50%;
    }
}
