/* ================================================
   AVATON - Shared Styles
   ================================================ */

/* Reset & Base */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    --black: #000000;
    --off-black: #0a0a0a;
    --dark-gray: #1a1a1a;
    --mid-gray: #666666;
    --light-gray: #999999;
    --white: #ffffff;

    /* Subtle Metallic Blue - Elegant and refined */
    --metallic-gradient: linear-gradient(135deg,
        #7BB8FF 0%,
        #5BA3F0 35%,
        #4A8FDB 65%,
        #3A7CC7 100%);
    --metallic-shine: linear-gradient(90deg,
        transparent 0%,
        rgba(255, 255, 255, 0.3) 50%,
        transparent 100%);

    /* Accent color */
    --accent: #5BA3F0;
    --accent-dim: rgba(91, 163, 240, 0.1);
    --accent-border: rgba(91, 163, 240, 0.25);
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
    background: var(--black);
    color: var(--white);
    line-height: 1.65;
    font-size: 16px;
    overflow-x: hidden;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

.container {
    max-width: 1900px;
    margin: 0 auto;
    padding: 0 5rem;
}

/* ================================================
   Navigation
   ================================================ */
nav {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 1000;
    padding: 2rem 0;
    background: transparent;
    backdrop-filter: blur(10px);
    border-bottom: 1px solid rgba(91, 168, 255, 0.08);
    transition: all 0.4s ease;
}

nav.scrolled {
    padding: 1.25rem 0;
    background: rgba(0, 0, 0, 0.85);
    backdrop-filter: blur(30px);
}

.nav-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo {
    font-size: 1.6rem;
    font-weight: 800;
    letter-spacing: -0.02em;
    color: var(--white);
    text-decoration: none;
    transition: color 0.3s ease;
}

.logo:hover {
    background: var(--metallic-gradient);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.nav-links {
    display: flex;
    gap: 3rem;
    list-style: none;
}

.nav-links > li {
    position: relative;
}

.nav-links a {
    color: var(--light-gray);
    text-decoration: none;
    font-size: 0.95rem;
    font-weight: 500;
    letter-spacing: -0.01em;
    transition: color 0.3s ease;
    position: relative;
}

.nav-links > li > a::before {
    content: '';
    position: absolute;
    bottom: -4px;
    left: 0;
    width: 0;
    height: 2px;
    background: var(--metallic-gradient);
    transition: width 0.3s ease;
}

.nav-links a:hover {
    color: var(--white);
}

.nav-links > li > a:hover::before {
    width: 100%;
}

/* Dropdown Menu - Click-based Two Column */
.nav-dropdown {
    position: relative;
}

.nav-dropdown > a {
    display: flex;
    align-items: center;
    gap: 0.35rem;
    cursor: pointer;
}

.nav-dropdown > a::after {
    content: '';
    width: 0;
    height: 0;
    border-left: 4px solid transparent;
    border-right: 4px solid transparent;
    border-top: 5px solid var(--light-gray);
    transition: transform 0.3s ease, border-color 0.3s ease;
}

.nav-dropdown.active > a::after {
    border-top-color: var(--white);
    transform: rotate(180deg);
}

.nav-dropdown > a:hover::after {
    border-top-color: var(--white);
}

.dropdown-menu {
    position: absolute;
    top: 100%;
    left: 50%;
    transform: translateX(-50%);
    min-width: 560px;
    background: rgba(10, 10, 10, 0.98);
    border: 1px solid var(--dark-gray);
    border-radius: 16px;
    padding: 1.5rem;
    margin-top: 1rem;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
    backdrop-filter: blur(20px);
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.5);
    pointer-events: none;
}

.nav-dropdown.active .dropdown-menu {
    opacity: 1;
    visibility: visible;
    margin-top: 0.75rem;
    pointer-events: auto;
}

.dropdown-columns {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 2rem;
}

.dropdown-column h4 {
    font-size: 0.7rem;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    color: var(--white);
    margin-bottom: 1rem;
    padding: 0 0.75rem;
    font-weight: 600;
}

.dropdown-menu a {
    display: block;
    padding: 0.65rem 0.75rem;
    border-radius: 8px;
    transition: background 0.2s ease;
    color: var(--light-gray);
    font-size: 0.9rem;
    font-weight: 500;
    white-space: nowrap;
}

.dropdown-menu a::before {
    display: none;
}

.dropdown-menu a:hover {
    background: rgba(91, 163, 240, 0.1);
    color: var(--white);
}

/* Dropdown overlay for click-outside detection */
.dropdown-overlay {
    position: fixed;
    inset: 0;
    z-index: 999;
    display: none;
}

.dropdown-overlay.active {
    display: block;
}

.cta-nav {
    padding: 0.85rem 2rem;
    background: transparent;
    border: 2px solid transparent;
    background-image: linear-gradient(#000, #000), var(--metallic-gradient);
    background-origin: border-box;
    background-clip: padding-box, border-box;
    color: var(--white);
    font-size: 0.9rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    letter-spacing: 0;
    border-radius: 8px;
}

.cta-nav:hover {
    background-image: var(--metallic-gradient), var(--metallic-gradient);
    color: var(--black);
    box-shadow: 0 0 30px rgba(74, 158, 255, 0.6);
}

/* ================================================
   Section Styles
   ================================================ */
section {
    padding: 8rem 0;
    position: relative;
}

.section-label {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.8rem;
    letter-spacing: 0.05em;
    text-transform: uppercase;
    color: #5BA3F0;
    margin-bottom: 1.5rem;
    font-weight: 600;
    padding: 0.5rem 1rem;
    background: rgba(91, 163, 240, 0.1);
    border: 1px solid rgba(91, 163, 240, 0.25);
    border-radius: 50px;
}

.section-label::before {
    content: '✦';
    font-size: 0.7rem;
}

.section-title {
    font-size: clamp(2rem, 4vw, 3.5rem);
    font-weight: 800;
    line-height: 1.25;
    letter-spacing: -0.02em;
    margin-bottom: 2rem;
}

.section-subtitle {
    font-size: 1.15rem;
    color: var(--light-gray);
    max-width: 900px;
    line-height: 1.7;
    font-weight: 400;
}

/* ================================================
   Buttons
   ================================================ */
.btn-primary {
    padding: 1.2rem 3rem;
    background: linear-gradient(135deg,
        #A8D4FF 0%,
        #7BB8FF 25%,
        #5BA3F0 50%,
        #4A8FDB 75%,
        #5BA3F0 100%);
    background-size: 200% 200%;
    color: var(--black);
    border: none;
    border-radius: 8px;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    letter-spacing: 0;
    text-decoration: none;
    display: inline-block;
    position: relative;
    overflow: hidden;
    animation: buttonGradient 3s ease infinite;
}

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

.btn-primary::after {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: linear-gradient(90deg,
        transparent 0%,
        rgba(255, 255, 255, 0.4) 50%,
        transparent 100%);
    animation: shimmer 3s infinite;
    pointer-events: none;
}

@keyframes shimmer {
    0% { transform: translateX(-100%) translateY(-100%) rotate(30deg); }
    100% { transform: translateX(100%) translateY(100%) rotate(30deg); }
}

.btn-primary:hover {
    box-shadow: 0 10px 40px rgba(74, 158, 255, 0.6);
    transform: translateY(-2px);
    filter: brightness(1.15);
}

.btn-secondary {
    padding: 1.2rem 3rem;
    background: transparent;
    color: var(--white);
    border: 1px solid rgba(255, 255, 255, 0.3);
    font-size: 1rem;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.3s ease;
    letter-spacing: 0;
    text-decoration: none;
    display: inline-block;
    border-radius: 8px;
}

.btn-secondary:hover {
    background: var(--white);
    color: var(--black);
}

/* Solution/Article Link Style */
.solution-link {
    color: var(--white);
    text-decoration: none;
    font-weight: 600;
    font-size: 0.95rem;
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    transition: color 0.3s ease;
}

.solution-link::after {
    content: '→';
    transition: transform 0.3s ease;
}

.solution-link:hover {
    background: var(--metallic-gradient);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.solution-link:hover::after {
    transform: translateX(5px);
}

/* ================================================
   Cards (Shared)
   ================================================ */
.card {
    background: var(--off-black);
    border: 1px solid var(--dark-gray);
    border-radius: 16px;
    padding: 2.5rem;
    transition: all 0.4s ease;
    position: relative;
}

.card::before {
    content: '';
    position: absolute;
    inset: -1px;
    border-radius: 17px;
    padding: 1px;
    background: linear-gradient(135deg, rgba(91, 163, 240, 0.4), rgba(74, 143, 219, 0.1), rgba(91, 163, 240, 0.2));
    -webkit-mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
    -webkit-mask-composite: xor;
    mask-composite: exclude;
    opacity: 0;
    transition: opacity 0.4s ease;
    pointer-events: none;
}

.card:hover::before {
    opacity: 1;
}

.card:hover {
    border-color: transparent;
    transform: translateY(-5px);
    box-shadow: 0 20px 60px rgba(74, 158, 255, 0.15);
}

/* ================================================
   Footer
   ================================================ */
footer {
    padding: 5rem 0 3rem;
    border-top: 1px solid var(--dark-gray);
}

.footer-content {
    display: grid;
    grid-template-columns: 2fr 1fr 1fr 1fr;
    gap: 3rem;
    margin-bottom: 3rem;
}

.footer-brand h3 {
    font-size: 1.8rem;
    font-weight: 800;
    margin-bottom: 1rem;
}

.footer-brand p {
    color: var(--light-gray);
    line-height: 1.6;
    margin-bottom: 1.5rem;
}

.footer-column h4 {
    font-size: 0.9rem;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    margin-bottom: 1.5rem;
    color: var(--light-gray);
}

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

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

.footer-column a {
    color: var(--light-gray);
    text-decoration: none;
    transition: color 0.3s ease;
}

.footer-column a:hover {
    color: var(--white);
}

.footer-bottom {
    padding-top: 2rem;
    border-top: 1px solid var(--dark-gray);
    display: flex;
    justify-content: space-between;
    align-items: center;
    color: var(--mid-gray);
    font-size: 0.9rem;
}

.footer-bottom a {
    color: var(--mid-gray);
    text-decoration: none;
    transition: color 0.3s ease;
}

.footer-bottom a:hover {
    color: var(--white);
}

/* ================================================
   Animations
   ================================================ */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(40px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Scroll Reveal */
.reveal {
    opacity: 0;
    transform: translateY(50px);
    transition: all 0.8s ease;
}

.reveal.active {
    opacity: 1;
    transform: translateY(0);
}

/* ================================================
   Responsive
   ================================================ */
@media (max-width: 1400px) {
    .container {
        padding: 0 4rem;
    }
}

@media (max-width: 1200px) {
    .container {
        padding: 0 3rem;
    }
}

@media (max-width: 1024px) {
    .nav-links {
        display: none;
    }

    .cta-nav {
        display: none;
    }

    .footer-content {
        grid-template-columns: 1fr 1fr;
        gap: 2rem;
    }
}

/* ================================================
   Mobile Hamburger Menu
   ================================================ */
.mobile-menu-toggle {
    display: none;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    width: 44px;
    height: 44px;
    background: transparent;
    border: none;
    cursor: pointer;
    padding: 0;
    z-index: 1001;
}

.mobile-menu-toggle span {
    display: block;
    width: 24px;
    height: 2px;
    background: var(--white);
    transition: all 0.3s ease;
    position: relative;
}

.mobile-menu-toggle span::before,
.mobile-menu-toggle span::after {
    content: '';
    position: absolute;
    left: 0;
    width: 24px;
    height: 2px;
    background: var(--white);
    transition: all 0.3s ease;
}

.mobile-menu-toggle span::before {
    top: -7px;
}

.mobile-menu-toggle span::after {
    top: 7px;
}

/* Hamburger animation when open */
.mobile-menu-toggle.active span {
    background: transparent;
}

.mobile-menu-toggle.active span::before {
    top: 0;
    transform: rotate(45deg);
}

.mobile-menu-toggle.active span::after {
    top: 0;
    transform: rotate(-45deg);
}

/* Mobile Menu Drawer */
.mobile-menu {
    position: fixed;
    top: 0;
    right: -100%;
    width: 100%;
    max-width: 400px;
    height: 100vh;
    background: rgba(0, 0, 0, 0.98);
    backdrop-filter: blur(20px);
    z-index: 1000;
    padding: 6rem 2rem 2rem;
    transition: right 0.3s ease;
    overflow-y: auto;
}

.mobile-menu.active {
    right: 0;
}

.mobile-menu-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.5);
    z-index: 999;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
}

.mobile-menu-overlay.active {
    opacity: 1;
    visibility: visible;
}

.mobile-menu-links {
    list-style: none;
    padding: 0;
    margin: 0;
}

.mobile-menu-links li {
    border-bottom: 1px solid var(--dark-gray);
}

.mobile-menu-links > li > a {
    display: block;
    padding: 1.25rem 0;
    color: var(--white);
    text-decoration: none;
    font-size: 1.1rem;
    font-weight: 500;
    transition: color 0.2s ease;
}

.mobile-menu-links > li > a:hover {
    color: var(--accent);
}

/* Mobile Dropdown */
.mobile-menu-links > li > a.mobile-dropdown-toggle {
    display: flex !important;
    justify-content: space-between;
    align-items: center;
    width: 100%;
    cursor: pointer;
}

.mobile-dropdown-toggle::after {
    content: '';
    width: 0;
    height: 0;
    border-left: 5px solid transparent;
    border-right: 5px solid transparent;
    border-top: 6px solid var(--light-gray);
    transition: transform 0.3s ease;
    flex-shrink: 0;
    margin-left: 1rem;
}

.mobile-dropdown.active .mobile-dropdown-toggle::after {
    transform: rotate(180deg);
}

.mobile-dropdown-menu {
    display: none;
    padding: 0.5rem 0 1rem 1rem;
}

.mobile-dropdown.active .mobile-dropdown-menu {
    display: block;
}

.mobile-dropdown-menu a {
    display: block;
    padding: 0.75rem 0;
    color: var(--light-gray);
    text-decoration: none;
    font-size: 0.95rem;
    transition: color 0.2s ease;
}

.mobile-dropdown-menu a:hover {
    color: var(--accent);
}

.mobile-dropdown-label {
    font-size: 0.7rem;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    color: var(--white);
    margin: 1.25rem 0 0.5rem;
    font-weight: 700;
}

.mobile-menu-cta {
    margin-top: 2rem;
    padding-top: 2rem;
    border-top: 1px solid var(--dark-gray);
}

.mobile-menu-cta .btn-primary {
    width: 100%;
    text-align: center;
    justify-content: center;
}

@media (max-width: 1024px) {
    .mobile-menu-toggle {
        display: flex !important;
    }

    .nav-links {
        display: none !important;
    }

    .cta-nav {
        display: none !important;
    }
}

@media (max-width: 768px) {
    section {
        padding: 5rem 0;
    }

    .container {
        padding: 0 2rem;
    }

    .footer-content {
        grid-template-columns: 1fr;
    }

    .footer-bottom {
        flex-direction: column;
        gap: 1rem;
        text-align: center;
    }
}

/* ================================================
   Cursor Glow Effect
   ================================================ */
.cursor-glow {
    position: fixed;
    width: 500px;
    height: 500px;
    border-radius: 50%;
    background: radial-gradient(circle, rgba(91, 168, 255, 0.15) 0%, transparent 70%);
    pointer-events: none;
    z-index: 9999;
    opacity: 0;
    transition: opacity 0.3s ease;
}
