/* Layout Global */
html, body {
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    overflow-x: hidden;
    width: 100%;
}

.app-main {
    flex: 1;
    display: flex;
    flex-direction: column;
    overflow-x: hidden;
    width: 100%;
}

/* layout.css - Estrutura Principal */

.topbar {
    background-color: rgba(5, 32, 31, 0.85);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    color: var(--color-text-main);
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.2);
    position: sticky;
    top: 0;
    z-index: 100;
    border-bottom: 1px solid var(--color-border);
}

.topbar-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    height: 5rem;
    padding: 0 5%; /* Increased padding for full-width header */
}

.logo {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    font-size: 1.5rem;
    font-weight: 800;
    letter-spacing: -0.02em;
    color: var(--color-primary-700);
    text-decoration: none;
}

.logo-text {
    display: none; /* Deixar apenas a imagem, ou se quiser, deixar o texto. O usuario ja tem a imagem. Vamos mostrar só a imagem bonita. */
}

.logo-img {
    height: 48px; /* Aumentado pra não ficar achatado */
    width: auto;
    object-fit: contain;
}

.logo:hover {
    color: var(--color-primary-700);
}

/* Navegação */
.main-nav {
    display: flex;
    gap: 1.5rem;
    align-items: center;
}

.nav-link {
    position: relative;
    display: inline-block;
    color: var(--color-text-muted);
    font-weight: 500;
    font-size: 0.95rem;
    transition: color var(--transition-fast);
}

.nav-link:hover {
    color: var(--color-primary-500);
}

.nav-link.active {
    color: var(--color-primary-600);
    font-weight: 700;
}

.nav-link::after {
    content: '';
    position: absolute;
    bottom: -4px;
    left: 0;
    width: 0;
    height: 2px;
    background-color: var(--color-primary-500);
    transition: width var(--transition-normal);
}

.nav-link:hover::after, .nav-link.active::after {
    width: 100%;
}

.menu-toggle {
    display: none;
    background: none;
    border: none;
    cursor: pointer;
    color: var(--color-text-main);
    padding: 0.5rem;
}

/* Footer Premium Dark (NSNexus Style) */
.main-footer {
    background-color: var(--color-surface); /* Dark SaaS background */
    border-top: 1px solid var(--color-border);
    padding: 5rem 0 2rem;
    margin-top: 4rem;
    color: var(--color-text-muted);
}

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

.brand-col {
    gap: 1.5rem;
}

.footer-brand {
    display: flex;
    align-items: center;
}

.footer-brand .logo-img {
    height: 70px;
    margin-bottom: 0.5rem;
}

.brand-description {
    font-size: 0.95rem;
    color: #94a3b8;
    line-height: 1.6;
    max-width: 380px;
}

.social-links {
    display: flex;
    gap: 0.75rem;
    margin-top: 0.5rem;
}

.social-links a {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 36px;
    height: 36px;
    background: rgba(255, 255, 255, 0.05);
    border-radius: var(--radius-md);
    color: #94a3b8;
    transition: all var(--transition-fast);
}

.social-links a svg {
    width: 18px;
    height: 18px;
}

.social-links a:hover {
    background: rgba(255, 255, 255, 0.1);
    color: #fff;
}

.footer-heading {
    font-size: 0.85rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: #f8fafc; /* White almost */
    margin-bottom: 1.25rem;
}

.footer-col {
    display: flex;
    flex-direction: column;
    gap: 1.1rem;
}

.footer-col a,
.footer-col span {
    color: #94a3b8;
    font-size: 0.95rem;
    text-decoration: none;
    transition: color var(--transition-fast);
}

.footer-col a:hover {
    color: var(--color-primary-100); /* Teal bright */
}

.footer-contact-block {
    display: flex;
    flex-direction: column;
    gap: 0.85rem;
}

.footer-contact-item {
    display: flex;
    align-items: center;
    gap: 0.6rem;
}

.footer-contact-item svg {
    width: 16px;
    height: 16px;
    color: #64748b;
    flex-shrink: 0;
}

.footer-bottom {
    border-top: 1px solid rgba(255, 255, 255, 0.05);
    padding-top: 2rem;
    text-align: center;
    color: #64748b;
    font-size: 0.875rem;
}

@media (max-width: 768px) {
    .footer-content {
        grid-template-columns: 1fr;
        gap: 3rem;
    }
}

/* Responsivo */
@media (max-width: 768px) {
    .topbar-content {
        padding: 0 1rem;
        height: 4.5rem;
    }

    .menu-toggle {
        display: block;
    }
    
    .main-nav {
        display: none;
        position: absolute;
        top: 100%;
        left: 0;
        right: 0;
        background-color: rgba(5, 32, 31, 0.95);
        backdrop-filter: blur(12px);
        -webkit-backdrop-filter: blur(12px);
        border-bottom: 1px solid var(--color-border);
        flex-direction: column;
        padding: 1.5rem;
        box-shadow: var(--shadow-md);
        gap: 1rem;
    }
    
    .main-nav.show {
        display: flex;
    }
    
    .nav-btn {
        width: 100%;
        text-align: center;
    }
}
