/* ============================================================================
   Troolify — Shared Site Shell (header + mobile menu + shell buttons)
   ----------------------------------------------------------------------------
   Styles for the dark navbar / mobile menu / shell buttons that assets/js/layout.js
   injects on every page. This is loaded by the tool pages (tools/*) alongside
   tailwind.css so their injected header & footer match index.html.

   Root pages load style.css, which already contains the same rules.

   The shared button/brand/search classes are scoped under .navbar / .mobile-menu
   so they never bleed into tool-page content styles (tool-shared.css defines
   generic .btn / .brand used by the catalog & tool UI).
   ============================================================================ */

/* Navigation */
.navbar {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    z-index: 1000;
    padding: 1.5rem 0;
    transition: 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}

.navbar.scrolled {
    padding: 1rem 0;
    background: rgba(33, 37, 41, 0.7);
    -webkit-backdrop-filter: blur(20px);
    backdrop-filter: blur(20px);
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.nav-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 1.5rem;
    display: grid;
    grid-template-columns: 1fr auto 1fr;
    align-items: center;
    gap: 1.5rem;
}

.nav-actions {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 1.5rem;
}

.navbar .brand {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    text-decoration: none;
    color: #F8F9FA;
}

.navbar .brand-logo-img {
    height: 36px;
    width: auto;
    object-fit: contain;
    padding: 3px 6px;
    border-radius: 10px;
    background: rgba(255, 255, 255, 0.07);
    border: 1px solid rgba(255, 255, 255, 0.1);
    filter: drop-shadow(0 4px 14px rgba(59, 130, 246, 0.35));
}

.navbar .brand-text {
    font-weight: 700;
    font-size: 1.25rem;
    letter-spacing: -0.02em;
}

.navbar .brand-sub {
    display: block;
    font-weight: 500;
    font-size: 0.7rem;
    letter-spacing: 0.02em;
    color: #ADB5BD;
    margin-top: 2px;
}

.nav-links {
    display: flex;
    gap: 2.5rem;
}

.nav-links-left {
    justify-content: flex-start;
}

.nav-links-right {
    justify-content: flex-end;
}

.nav-links a {
    color: #ADB5BD;
    text-decoration: none;
    font-size: 0.95rem;
    font-weight: 500;
    transition: 0.2s ease;
}

.nav-links a:hover, .nav-links a.active {
    color: #F8F9FA;
}

.mobile-menu-btn {
    display: none;
    background: none;
    border: none;
    color: #F8F9FA;
    font-size: 1.5rem;
    cursor: pointer;
}

.mobile-menu {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100vh;
    background: rgba(5, 5, 9, 0.98);
    backdrop-filter: blur(20px);
    z-index: 999;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 2rem;
    opacity: 0;
    pointer-events: none;
    transition: 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}

.mobile-menu.open {
    opacity: 1;
    pointer-events: all;
}

.mobile-menu a {
    color: #F8F9FA;
    text-decoration: none;
    font-size: 1.5rem;
    font-weight: 600;
}

.navbar .nav-search-btn,
.mobile-menu .nav-search-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.04);
    border: 1px solid rgba(255, 255, 255, 0.1);
    color: #F8F9FA;
    cursor: pointer;
    font-size: 1rem;
    transition: 0.2s ease;
}
.navbar .nav-search-btn:hover,
.mobile-menu .nav-search-btn:hover {
    background: rgba(59, 130, 246, 0.15);
    border-color: rgba(59, 130, 246, 0.4);
    color: #60A5FA;
    box-shadow: 0 0 15px rgba(59, 130, 246, 0.2);
}

/* Shell buttons (scoped so they don't override tool-page .btn styles) */
.navbar .btn,
.mobile-menu .btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    padding: 0.75rem 1.5rem;
    border-radius: 100px;
    font-weight: 500;
    font-size: 1rem;
    text-decoration: none;
    transition: 0.4s cubic-bezier(0.16, 1, 0.3, 1);
    cursor: pointer;
    border: none;
}

.navbar .btn-primary,
.mobile-menu .btn-primary {
    background: linear-gradient(135deg, #3B82F6, #2563EB);
    color: #F8F9FA;
    box-shadow: 0 4px 20px rgba(59, 130, 246, 0.3);
}

.navbar .btn-primary:hover,
.mobile-menu .btn-primary:hover {
    box-shadow: 0 6px 30px rgba(59, 130, 246, 0.5);
    transform: translateY(-2px);
    background: linear-gradient(135deg, #60A5FA, #3B82F6);
}

.navbar .btn-nav {
    background: rgba(59, 130, 246, 0.1);
    color: #E9ECEF;
    border: 1px solid rgba(59, 130, 246, 0.3);
    padding: 0.5rem 1.25rem;
    font-size: 0.9rem;
}
.navbar .btn-nav:hover {
    background: rgba(59, 130, 246, 0.2);
    box-shadow: 0 0 15px rgba(59, 130, 246, 0.4);
}

/* Responsive */
@media (max-width: 992px) {
    .nav-links {
        gap: 1.5rem;
    }
    .nav-actions {
        gap: 1rem;
    }
    .navbar .btn-nav {
        display: none;
    }
}

@media (max-width: 768px) {
    .nav-links, .navbar .btn-nav {
        display: none;
    }

    .mobile-menu-btn {
        display: block;
    }

    .nav-container {
        grid-template-columns: 1fr auto 1fr;
        gap: 0.5rem;
    }
    .navbar .brand-text {
        font-size: 1.1rem;
    }
}
