/* --- RESET E ESTILOS GERAIS --- */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
}

body {
    background-color: #f4f7f6;
    color: #000000;
    padding: 20px;
}

header {
    text-align: center;
    margin-bottom: 30px;
}

.site-logo {
    max-width: 600px; /* Define a largura máxima da logo */
    height: auto;     /* Mantém a proporção correta da imagem */
    margin: 15px auto; /* Espaçamento: 20px em cima/baixo, automático nas laterais */
    display: block;   /* Garante que a logo fique em sua própria linha */
}

header h1 {
    color: #000000;
    font-size: 2.5rem;
    margin-bottom: 10px;
}

header p {
    color: #7f888d;
}

/* --- FILTROS --- */
.filter-container {
    display: flex;
    justify-content: center;
    gap: 15px;
    margin-bottom: 40px;
    flex-wrap: wrap;
}

.filter-btn {
    padding: 10px 20px;
    border: 2px solid #008ee1;
    border-radius: 25px;
    background: transparent;
    color: #008ee1;
    cursor: pointer;
    font-weight: 600;
    transition: all 0.3s ease;
}

.filter-btn:hover {
    background-color: rgba(91, 165, 183, 0.1);
}

/* Estado Ativo do Filtro */
.filter-btn.active {
    background-color: #008ee1;
    color: white;
}

/* --- GRID DA BIBLIOTECA --- */
#library-container {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 25px;
    max-width: 1200px;
    margin: 0 auto;
}

/* --- ESTILO DO CARD --- */
.card {
    background: white;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 4px 15px rgba(0,0,0,0.1);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    display: flex;
    flex-direction: column;
    animation: fadeIn 0.5s ease;
}

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(10px); }
    to { opacity: 1; transform: translateY(0); }
}

.card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 20px rgba(0,0,0,0.15);
}

/* Tag de Categoria no Card */
.card-tag {
    position: absolute;
    top: 15px;
    right: 15px;
    background-color: rgba(0,0,0,0.6);
    color: white;
    padding: 4px 10px;
    border-radius: 4px;
    font-size: 0.8rem;
    text-transform: uppercase;
}

.card-image {
    width: 100%;
    height: 200px;
    overflow: hidden;
    background-color: #ddd;
    position: relative;
}

.card-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.card-content {
    padding: 20px;
    flex-grow: 1;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
}

.card-title {
    font-size: 1.25rem;
    margin-bottom: 10px;
    color: #000000;
}

.card-summary {
    font-size: 0.95rem;
    color: #000000;
    line-height: 1.5;
    margin-bottom: 20px;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.read-btn {
    display: block;
    width: 100%;
    padding: 12px;
    background-color: #008ee1;
    color: white;
    text-align: center;
    text-decoration: none;
    border-radius: 6px;
    font-weight: bold;
    transition: background 0.2s;
}

.read-btn:hover {
    background-color: #006bb6;
}
