@import url('https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700&family=Montserrat:wght@400;700;800;900&display=swap');

:root {
    --primary-color: #FFD700;
    /* Gold */
    --primary-hover: #e6c200;
    --bg-color: #0d0d0d;
    /* Black Background */
    --sidebar-color: #1a1a1a;
    /* Card/Sidebar Background */
    --text-color: #ffffff;
    --text-muted: #cccccc;
    --border-color: #333333;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    background-color: var(--bg-color);
    color: var(--text-color);
    font-family: 'Inter', sans-serif;
    height: 100vh;
    overflow: hidden;
}

/* Typography for Headings */
h1,
h2,
h3 {
    font-family: 'Montserrat', sans-serif;
    text-transform: uppercase;
}

.dashboard-layout {
    display: flex;
    height: 100vh;
    width: 100vw;
}

/* Sidebar Styling */
.sidebar {
    width: 280px;
    background-color: var(--sidebar-color);
    border-right: 1px solid var(--border-color);
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    padding: 2rem;
    flex-shrink: 0;
}

.sidebar-top {
    display: flex;
    flex-direction: column;
    gap: 3rem;
}

.logo-area {
    display: flex;
    align-items: center;
    justify-content: flex-start;
    /* Alinhado à esquerda como pedido */
    padding-bottom: 2rem;
    border-bottom: 1px solid var(--border-color);
}

.sidebar-logo {
    max-width: 100%;
    height: auto;
    max-height: 50px;
    /* Tamanho pequeno */
    display: block;
    object-fit: contain;
}

.logo-text {
    color: var(--primary-color);
    font-family: 'Montserrat', sans-serif;
    font-weight: 800;
    font-size: 1rem;
    margin-left: 10px;
    /* Espaço entre imagem e texto */
    line-height: 1.2;
    text-transform: uppercase;
    text-shadow: 0 0 10px rgba(255, 215, 0, 0.4);
    /* Leve brilho dourado */
}

.sidebar-menu {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.menu-item {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    color: var(--text-muted);
    text-decoration: none;
    font-size: 0.95rem;
    font-weight: 600;
    padding: 1rem;
    border-radius: 8px;
    transition: all 0.3s ease;
    border: 1px solid transparent;
}

.menu-item:hover {
    background-color: rgba(255, 215, 0, 0.1);
    color: var(--primary-color);
    border-color: rgba(255, 215, 0, 0.2);
}

.menu-item.active {
    background-color: var(--primary-color);
    color: #000;
    /* Black text on Gold background */
    box-shadow: 0 0 15px rgba(255, 215, 0, 0.3);
    font-weight: 800;
}

.menu-item.active i {
    color: #000;
}

.logout-btn {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    color: #ef4444;
    text-decoration: none;
    font-weight: 600;
    padding: 1rem;
    border-radius: 8px;
    transition: background-color 0.2s;
    margin-top: auto;
    border: 1px solid transparent;
}

.logout-btn:hover {
    background-color: rgba(239, 68, 68, 0.1);
    border-color: rgba(239, 68, 68, 0.2);
}

/* Main Content Styling */
.main-content {
    flex-grow: 1;
    overflow-y: auto;
    padding: 3rem;
    background-color: var(--bg-color);
}

.content-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 3rem;
    border-bottom: 1px solid var(--border-color);
    padding-bottom: 1.5rem;
}

.content-header h1 {
    font-size: 2rem;
    font-weight: 800;
    color: var(--text-color);
}

.user-badge {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    background: rgba(255, 215, 0, 0.1);
    color: var(--primary-color);
    padding: 0.5rem 1rem;
    border-radius: 50px;
    font-size: 0.85rem;
    font-weight: 700;
    border: 1px solid var(--primary-color);
    box-shadow: 0 0 10px rgba(255, 215, 0, 0.1);
}

/* Products Grid */
.products-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 2rem;
}

.product-card {
    background: var(--sidebar-color);
    border: 1px solid var(--border-color);
    border-radius: 12px;
    overflow: hidden;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    position: relative;
}

.product-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.5);
    border-color: var(--primary-color);
}

.card-image {
    height: 180px;
    background: #000;
    display: flex;
    align-items: center;
    justify-content: center;
    border-bottom: 1px solid var(--border-color);
    position: relative;
    overflow: hidden;
    padding: 0;
}

/* Optional: Subtle glow effect in image area */
.card-image::after {
    content: '';
    position: absolute;
    width: 60%;
    height: 60%;
    background: var(--primary-color);
    filter: blur(60px);
    opacity: 0.15;
    border-radius: 50%;
    z-index: 0;
}

.card-image img {
    max-width: 100%;
    max-height: 100%;
    width: 100%;
    height: 100%;
    object-fit: cover;
    /* Faz a imagem cobrir todo o espaço */
    z-index: 1;
    transition: transform 0.5s ease;
}

.product-card:hover .card-image img {
    transform: scale(1.1);
    /* Zoom suave ao passar o mouse */
}

.card-info {
    padding: 1.5rem;
    text-align: center;
}

.card-info h3 {
    font-size: 1.25rem;
    margin-bottom: 0.75rem;
    color: var(--text-color);
    font-weight: 700;
}

.card-info p {
    color: var(--text-muted);
    font-size: 0.9rem;
    margin-bottom: 1.5rem;
    line-height: 1.5;
    height: 42px;
    /* Fixed height for alignment */
    overflow: hidden;
}

.btn-access {
    background-color: var(--primary-color);
    color: #000;
    /* Black text ensures readability on Gold */
    border: none;
    padding: 1rem 1.5rem;
    border-radius: 6px;
    font-weight: 800;
    cursor: pointer;
    width: 100%;
    transition: all 0.2s;
    text-transform: uppercase;
    font-size: 0.9rem;
    letter-spacing: 0.5px;

    /* Adicionado para links funcionarem como botões */
    display: block;
    text-align: center;
    text-decoration: none;
}

.btn-access:hover {
    background-color: #fff;
    transform: scale(1.02);
    box-shadow: 0 0 15px rgba(255, 215, 0, 0.4);
}

/* Scrollbar */
::-webkit-scrollbar {
    width: 8px;
}

::-webkit-scrollbar-track {
    background: var(--bg-color);
}

::-webkit-scrollbar-thumb {
    background: #333;
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: var(--primary-color);
}

/* Responsive adjustments */
@media (max-width: 768px) {
    .dashboard-layout {
        flex-direction: column;
        height: auto;
        min-height: 100vh;
        overflow-y: auto;
    }

    body {
        overflow-y: auto;
    }

    .sidebar {
        width: 100%;
        height: auto;
        padding: 1.5rem;
        border-right: none;
        border-bottom: 1px solid var(--border-color);
    }

    .sidebar-top {
        gap: 1.5rem;
    }

    .main-content {
        padding: 1.5rem;
    }

    .content-header {
        flex-direction: column;
        gap: 1rem;
        align-items: flex-start;
        margin-bottom: 2rem;
    }
}