/* Reset e configurações globais */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: Arial, sans-serif;
    background-color: #f5f5f5;
}

/* Navigation */
.nav {
    background-color: #000000;
    padding: 0;
}

.nav-content {
    max-width: 1200px;
    margin: 0 auto;
    display: flex;
    justify-content: center;
}

.nav-item {
    padding: 10px 25px;
    color: white;
    text-decoration: none;
    font-weight: 500;
    transition: background-color 0.3s;
}

.nav-item:hover {
    background-color: rgba(255, 255, 255, 0.1);
}

.logo-title {
    display: flex;
    align-items: center;
}

#logo {
    height: clamp(16px, 4.5vw, 25px);
    white-space: nowrap;
    line-height: 30px;
    margin-right: 15px;
}

h1 {
    margin: 0;
    font-size: clamp(16px, 4.5vw, 20px);
    white-space: nowrap;
    line-height: 30px;
    color: white;
    /* O tamanho da fonte será de no mínimo 16px, idealmente 5% da largura da tela, e no máximo 20px */
}

/* Hero Section */
.hero {
    background: linear-gradient(135deg, #000000, #45452b, #fffb00);
    padding: 23px 0;
    color: white;
}

.hero-content {
    max-width: 1200px;
    margin: 0 auto;
    display: flex;
    align-items: center;
    padding: 0 20px;
}

.hero-book {
    flex: 1;
    text-align: center;
}

.book-image {
    width: 110px;
    height: 210px;
    margin: 0 auto;
    border-radius: 8px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
    overflow: hidden;
}

.QRCODE {
    width: 130px;
    height: 130px;
    margin: 0 auto;
    border-radius: 8px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
    overflow: hidden;
}



.book-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}


.hero-highlight {
    color: #fff;
}

/* Dots indicator */
.hero-dots {
    text-align: center;
    margin-top: 20px;
}

.dot {
    display: inline-block;
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background-color: rgba(255, 255, 255, 0.5);
    margin: 0 5px;
}

.dot.active {
    background-color: white;
}

/* Bestsellers */
.bestsellers {
    max-width: 1500px;
    margin: 10px auto;
    padding: 5px;
    height: 5px;
}

.bestsellers h2 {
    text-align: center;
    color: #000000;
    margin-bottom: 40px;
    font-size: 28px;
    height: 5px;
}

.books-grid {
    display: grid;
    grid-template-columns: repeat(5, 1fr);
    gap: 30px;
}

.book-card {
    background: white;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    transition: transform 0.3s;
    cursor: pointer;
}

.book-card:hover {
    transform: translateY(-5px);
}

.book-cover {
    width: 100%;
    height: 200px;
    position: relative;
}

.book-cover img {
    width: 100%;
    height: 100%;
}

.book-info {
    padding: 15px;
}

.book-title {
    font-size: 14px;
    font-weight: bold;
    color: #333;
    margin-bottom: 5px;
    line-height: 1.3;
    height: 5px;
}

.book-author {
    font-size: 12px;
    color: #666;
    margin-bottom: 10px;
}

/* Main container - escondido até login */
.main-container {
    display: none;
    /* Ocultado por padrão, será exibido após login */
}

/*::::::::::::Estilos para a tela de login:::::::::::::::: */
.login-container {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    width: 300px;
    /* Largura ajustada */
    height: 200px;
    /* Altura ajustada */
    background-color: #fff;
    border-radius: 8px;
    box-shadow: 0 0 10px rgba(0, 0, 0, 0.1);
    margin: auto;
    /* Centraliza verticalmente */
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
}

.login-container input[type="text"] {
    width: 80%;
    padding: 10px;
    margin-bottom: 10px;
    border: 1px solid #ddd;
    border-radius: 4px;
    font-size: 16px;
}

.login-container input[type="button"] {
    width: 80%;
    padding: 10px;
    background-color: #000;
    color: #dfeb00;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    font-size: 16px;
}


/* Spinner - EXATAMENTE como na segunda página */
#spinner {
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    z-index: 9999;
    width: 150px;
    height: 150px;
    display: none;
    justify-content: center;
    align-items: center;
}

#spinner::before {
    content: "";
    box-sizing: border-box;
    position: absolute;
    width: 150px;
    height: 150px;
    border: 16px solid #000000;
    border-top: 16px solid #dfeb00;
    border-radius: 50%;
    animation: spin 2s linear infinite;
}

#spinner-text {
    position: absolute;
    font-size: 40px;
    color: #000000;
    font-family: Arial, sans-serif;
}

@keyframes spin {
    0% {
        transform: rotate(0deg);
    }

    100% {
        transform: rotate(360deg);
    }
}

/* Responsividade */
@media (max-width: 768px) {
    .hero-content {
        flex-direction: column;
        text-align: center;
    }

    .nav-content {
        flex-wrap: wrap;
    }
}

@media (max-width: 480px) {
    .books-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .header-top {
        flex-direction: column;
        gap: 10px;
        text-align: center;
    }

    .header-left,
    .header-right {
        flex-wrap: wrap;
        justify-content: center;
    }
}