/* --- GERENCIADOR DE LIVROS --- */
.admin-page {
    max-width: 800px;
    margin: 100px auto 50px auto;
    padding: 0 20px;
    width: 90%; /* Garante margens em telas menores que 800px */
}

.admin-header {
    text-align: center;
    margin-bottom: 30px;
}

.admin-header h1 {
    font-family: var(--fonte-titulo);
    color: var(--texto-escuro);
    font-size: 2.2rem;
}

.admin-header p {
    color: var(--texto-suave);
}

.admin-card {
    background: var(--branco);
    border-radius: 16px;
    padding: 30px;
    margin-bottom: 30px;
    border: 1px solid rgba(212, 138, 133, 0.15);
    box-shadow: 0 8px 25px rgba(0,0,0,.04);
}

.admin-card h2 {
    font-family: var(--fonte-titulo);
    color: var(--texto-escuro);
    margin-bottom: 20px;
}

.form-group {
    margin-bottom: 18px;
}

.form-group label {
    display: block;
    margin-bottom: 6px;
    font-weight: 600;
    font-size: 0.9rem;
    color: var(--texto-escuro);
}

.checkbox-group label {
    display: flex;
    align-items: center;
    gap: 8px;
    cursor: pointer;
}

.form-control {
    width: 100%;
    padding: 12px;
    border: 1px solid var(--rosa-claro);
    border-radius: 8px;
    font-family: var(--fonte-corpo);
    box-sizing: border-box;
    background-color: var(--bg-creme);
}

.form-control:focus {
    outline: none;
    border-color: var(--rosa-escuro);
}

.form-actions {
    display: flex;
    gap: 10px;
}

.btn-save {
    flex: 1;
    border: none;
    padding: 14px;
    border-radius: 8px;
    background: var(--dourado);
    color: var(--branco);
    font-size: 1rem;
    font-weight: 700;
    cursor: pointer;
    transition: opacity 0.2s;
}

.btn-cancel {
    padding: 14px;
    border-radius: 8px;
    border: 1px solid var(--rosa-escuro);
    background: transparent;
    color: var(--rosa-escuro);
    font-weight: 600;
    cursor: pointer;
}

.btn-save:hover { opacity: 0.9; }

/* Lista Admin */
.book-item-admin {
    display: flex;
    align-items: center;
    gap: 15px;
    padding: 15px;
    border-bottom: 1px solid rgba(212, 138, 133, 0.15);
}

.book-item-admin:last-child {
    border-bottom: none;
}

.book-item-admin img {
    width: 50px;
    height: 75px;
    object-fit: cover;
    border-radius: 4px;
}

.book-item-info {
    flex-grow: 1;
}

.book-item-info h4 {
    margin: 0;
    font-size: 1rem;
    color: var(--texto-escuro);
}

.book-item-info p {
    margin: 2px 0 0 0;
    font-size: 0.8rem;
    color: var(--texto-suave);
}

.book-item-actions {
    display: flex;
    gap: 8px;
}

.btn-edit, .btn-delete {
    padding: 6px 12px;
    border-radius: 6px;
    border: none;
    cursor: pointer;
    font-weight: 600;
    font-size: 0.8rem;
}

.btn-edit { background: var(--rosa-suave); color: var(--texto-escuro); }
.btn-delete { background: #e74c3c; color: white; }

@media (max-width: 600px) {
    .book-item-admin {
        flex-direction: column;
        align-items: flex-start;
    }
    .book-item-actions {
        width: 100%;
        margin-top: 10px;
    }
    .btn-edit, .btn-delete { flex: 1; }
}