/* Importação de Fonte */
@import url('https://fonts.googleapis.com/css2?family=Inter:wght@400;600;700&display=swap');

:root {
    --cor-primaria: #e81d1d;
    --cor-primaria-dark: #b31414;
    --cor-dark: #2c343a;
    --cor-bg: #f8f9fa;
    --cor-card: #ffffff;
    --cor-texto: #333333;
    --transition: all 0.3s cubic-bezier(0.25, 0.8, 0.25, 1);
}

body {
    font-family: 'Inter', sans-serif;
    height: 100vh;
    display: flex;
    flex-direction: column;
    overflow: hidden;
    background-color: var(--cor-bg);
}

/* --- ESTRUTURA PRINCIPAL --- */
.container-principal {
    display: flex;
    flex: 1;
    height: 0;
    min-height: 0;
}

/* --- SIDEBAR (Sincronizada com a Home) --- */
.sidebar {
    background: linear-gradient(180deg, #FF0000 0%, #0000FF 100%);
    width: 250px;
    height: 100%;
    display: flex;
    flex-direction: column;
    padding: 1.5rem;
    flex-shrink: 0;
    box-sizing: border-box;
}

.logo {
    width: 100%;
    padding: 10px;
    border-radius: 12px;
    background: white;
    transition: var(--transition);
    margin-bottom: 20px;
}

.logo:hover {
    transform: scale(1.03);
}

.menu {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 8px;
    padding: 10px;
}

.btn-nav {
    display: block;
    background-color: rgba(0, 0, 0, 0.2);
    color: white;
    text-decoration: none;
    padding: 10px;
    border-radius: 10px;
    text-align: center;
    font-weight: 600;
    transition: var(--transition);
}

.btn-nav:hover {
    background-color: var(--cor-dark);
    transform: translateX(8px);
}

.rodape-sidebar {
    margin-top: auto;
    padding-top: 20px;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    text-align: center;
}

.rodape-sidebar p {
    color: white;
    font-size: 0.7rem;
    line-height: 1.4;
    opacity: 0.7;
}

/* --- DASHBOARD E CARDS DE SITES --- */
.dashboard {
    flex: 1;
    padding: 30px;
    background-color: #f0f2f5;
    overflow-y: auto;
    display: flex;
    flex-direction: column;
    gap: 30px;
}

.cards-row {
    display: flex;
    justify-content: flex-start;
    gap: 25px;
    flex-wrap: wrap;
}

.card {
    background-color: var(--cor-card);
    flex: 1;
    min-width: 220px;
    max-width: 23%;
    height: 250px;
    border-radius: 20px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    position: relative;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.05);
    transition: var(--transition);
    padding: 20px;
    text-decoration: none;
    border: 1px solid rgba(0, 0, 0, 0.05);
}

.card img {
    max-width: 80%;
    max-height: 60%;
    object-fit: contain;
    border-radius: 8px;
    transition: var(--transition);
}

.card:hover {
    transform: translateY(-10px);
    box-shadow: 0 15px 30px rgba(0, 0, 0, 0.1);
    border-color: var(--cor-primaria);
}

.legend {
    position: absolute;
    bottom: 15px;
    background-color: var(--cor-dark);
    color: white;
    padding: 5px 15px;
    border-radius: 20px;
    font-size: 0.75rem;
    font-weight: 600;
}

.card:hover .legend {
    background-color: rgb(236, 14, 14);
    transform: scale(1.05);
}

/* --- RESPONSIVIDADE --- */
@media (max-width: 900px) {
    .container-principal {
        flex-direction: column;
    }

    .sidebar {
        width: 100%;
        height: auto;
        flex-direction: row;
        justify-content: space-between;
        padding: 10px 15px;
    }

    .logo {
        width: 60px;
        margin-bottom: 0;
    }

    .menu {
        flex-direction: row;
        gap: 8px;
    }

    .rodape-sidebar {
        display: none;
    }

    .card {
        max-width: 46%;
    }
}

@media (max-width: 480px) {
    .card {
        max-width: 100%;
    }
}