/* ── Base ── */
body {
    margin: 0;
    padding: 0;
    padding-top: var(--ds-nav-height);
    font-family: var(--ds-font-body);
    font-weight: 400;
    background-color: var(--ds-surface);
    color: var(--ds-ink);
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

h1, h2, h3, h4, h5, h6 {
    font-family: var(--ds-font-display);
    font-weight: 700;
    letter-spacing: -0.01em;
    color: var(--ds-dark);
}

a {
    color: var(--ds-primary);
    text-decoration: none;
    transition: color var(--ds-transition);
}
a:hover {
    color: var(--ds-primary-dark);
}

/* ── Navbar ── */
#hub-navbar {
    font-family: var(--ds-font-display);
    font-weight: 600;
    height: var(--ds-nav-height);
    border-bottom: 4px solid var(--ds-primary);
    transition: box-shadow var(--ds-transition);
}
#hub-navbar.scrolled {
    box-shadow: 0 2px 16px rgba(0,0,0,0.18);
}
#hub-navbar .navbar-brand img {
    height: 36px;
}
#hub-navbar .nav-link {
    color: rgba(255,255,255,0.75);
    font-size: 0.875rem;
    padding: 0.5rem 1rem;
    transition: color var(--ds-transition);
}
#hub-navbar .nav-link:hover,
#hub-navbar .nav-link.active {
    color: #fff;
}
#hub-navbar .hub-label {
    font-size: 0.7rem;
    font-weight: 700;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: rgba(255,255,255,0.45);
    border-left: 1px solid rgba(255,255,255,0.15);
    padding-left: 1rem;
    margin-left: 0.75rem;
}

/* ── Hero ── */
.hub-hero {
    background: linear-gradient(135deg, var(--ds-dark) 0%, #1a1d21 100%);
    padding: 3.5rem 0 3rem;
    position: relative;
    overflow: hidden;
}
.hub-hero::before {
    content: '';
    position: absolute;
    top: -40%;
    right: -10%;
    width: 500px;
    height: 500px;
    background: radial-gradient(circle, rgba(var(--ds-primary-rgb), 0.08) 0%, transparent 70%);
    pointer-events: none;
}
.hub-hero h1 {
    color: #fff;
    font-weight: 800;
    font-size: 2.25rem;
    letter-spacing: -0.02em;
}
.hub-hero p {
    color: rgba(255,255,255,0.6);
    font-size: 1.05rem;
    max-width: 540px;
}
.hub-hero .accent-bar {
    width: 60px;
    height: 4px;
    background: var(--ds-primary);
    border-radius: 2px;
    margin-bottom: 1rem;
}

/* ── Breadcrumb ── */
.hub-breadcrumb {
    background-color: var(--ds-gray-200);
    padding: 0.6rem 0;
    font-size: 0.8rem;
    font-family: var(--ds-font-display);
}
.hub-breadcrumb .breadcrumb {
    margin: 0;
}
.hub-breadcrumb .breadcrumb-item a {
    color: var(--ds-slate);
}
.hub-breadcrumb .breadcrumb-item.active {
    color: var(--ds-muted);
}

/* ── Cards de ferramentas (Dashboard) ── */
.tool-card {
    border: 1px solid var(--ds-line);
    border-radius: var(--ds-radius);
    background: #fff;
    padding: 2rem 1.75rem;
    transition: transform var(--ds-transition), box-shadow var(--ds-transition);
    height: 100%;
    display: flex;
    flex-direction: column;
}
.tool-card:hover {
    transform: translateY(-3px);
    box-shadow: var(--ds-shadow-hover);
}
.tool-card .tool-icon {
    width: 52px;
    height: 52px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    margin-bottom: 1.25rem;
    flex-shrink: 0;
}
.tool-card .tool-icon.icon-red {
    background: rgba(var(--ds-primary-rgb), 0.08);
    color: var(--ds-primary);
}
.tool-card .tool-icon.icon-blue {
    background: rgba(0, 76, 151, 0.08);
    color: var(--ds-info);
}
.tool-card .tool-icon.icon-green {
    background: rgba(15, 138, 95, 0.08);
    color: var(--ds-success);
}
.tool-card .tool-icon.icon-slate {
    background: rgba(64, 64, 64, 0.08);
    color: var(--ds-slate);
}
.tool-card h3 {
    font-size: 1.15rem;
    font-weight: 700;
    margin-bottom: 0.5rem;
}
.tool-card p {
    color: var(--ds-muted);
    font-size: 0.875rem;
    line-height: 1.6;
    flex-grow: 1;
}
.tool-card .btn {
    align-self: flex-start;
}

/* ── Botoes ── */
.btn-hub {
    font-family: var(--ds-font-display);
    font-weight: 600;
    font-size: 0.85rem;
    padding: 0.5rem 1.25rem;
    border-radius: var(--ds-radius-sm);
    transition: all var(--ds-transition);
}
.btn-hub-primary {
    background: var(--ds-primary);
    color: #fff;
    border: 1px solid var(--ds-primary);
}
.btn-hub-primary:hover {
    background: var(--ds-primary-dark);
    border-color: var(--ds-primary-dark);
    color: #fff;
}
.btn-hub-outline {
    background: transparent;
    color: var(--ds-primary);
    border: 1px solid var(--ds-primary);
}
.btn-hub-outline:hover {
    background: var(--ds-primary);
    color: #fff;
}
.btn-hub-dark {
    background: var(--ds-dark);
    color: #fff;
    border: 1px solid var(--ds-dark);
}
.btn-hub-dark:hover {
    background: var(--ds-slate);
    border-color: var(--ds-slate);
    color: #fff;
}

/* ── Page Title (apps internas) ── */
.app-page-header {
    padding: 2.5rem 0 2rem;
}
.app-page-header h1 {
    font-size: 1.85rem;
    font-weight: 800;
    margin-bottom: 0.35rem;
}
.app-page-header p {
    color: var(--ds-muted);
    font-size: 0.95rem;
    margin: 0;
}
.app-page-header .accent-bar {
    width: 50px;
    height: 4px;
    background: var(--ds-primary);
    border-radius: 2px;
    margin-bottom: 0.75rem;
}

/* ── App Container ── */
.app-container {
    padding-bottom: 4rem;
}

/* ── Secao genérica ── */
.hub-section {
    padding: 3rem 0;
}

/* ── Footer ── */
.hub-footer {
    background: var(--ds-dark);
    color: rgba(255,255,255,0.55);
    padding: 2.5rem 0;
    font-size: 0.8rem;
    font-family: var(--ds-font-display);
    margin-top: auto;
}
.hub-footer a {
    color: rgba(255,255,255,0.7);
}
.hub-footer a:hover {
    color: #fff;
}
.hub-footer .footer-brand img {
    height: 30px;
    opacity: 0.8;
}
.hub-footer .footer-divider {
    border-top: 1px solid rgba(255,255,255,0.1);
    margin: 1.5rem 0;
}

/* ── Utilities ── */
.text-ds-primary { color: var(--ds-primary) !important; }
.text-ds-muted { color: var(--ds-muted) !important; }
.text-ds-slate { color: var(--ds-slate) !important; }
.bg-ds-surface { background-color: var(--ds-surface) !important; }
.bg-ds-surface-alt { background-color: var(--ds-surface-alt) !important; }

/* ── Animations ── */
@keyframes fadeInUp {
    from { opacity: 0; transform: translateY(20px); }
    to   { opacity: 1; transform: translateY(0); }
}
.animate-in {
    animation: fadeInUp 0.5s ease forwards;
    opacity: 0;
}
.animate-in:nth-child(1) { animation-delay: 0.05s; }
.animate-in:nth-child(2) { animation-delay: 0.1s; }
.animate-in:nth-child(3) { animation-delay: 0.15s; }
.animate-in:nth-child(4) { animation-delay: 0.2s; }
.animate-in:nth-child(5) { animation-delay: 0.25s; }
.animate-in:nth-child(6) { animation-delay: 0.3s; }
