/* ========================================
   HOME PREMIUM STYLES
   ======================================== */

/* Hero Section Premium */
.hero-premium {
    position: relative;
    min-height: calc(100vh - 120px);
    display: flex;
    align-items: center;
    background: linear-gradient(135deg, rgba(10, 10, 10, 1) 0%, rgba(20, 20, 20, 1) 100%);
    padding: 6rem 0;
    overflow: hidden;
}

.hero-premium::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: 
        radial-gradient(circle at 20% 50%, rgba(227, 6, 19, 0.1) 0%, transparent 50%),
        radial-gradient(circle at 80% 80%, rgba(212, 165, 116, 0.08) 0%, transparent 50%);
    pointer-events: none;
}

.hero-title {
    font-size: clamp(2.5rem, 6vw, 5rem);
    font-weight: 900;
    color: #ffffff !important;
    margin-bottom: 1.5rem;
    line-height: 1.1;
    letter-spacing: -0.02em;
    text-transform: uppercase;
    text-shadow: 0 4px 20px rgba(0, 0, 0, 0.5);
    background: none !important;
    -webkit-background-clip: initial !important;
    -webkit-text-fill-color: #ffffff !important;
    background-clip: initial !important;
}

/* Forçar visibilidade após animação */
.hero-title[style] {
    opacity: 1 !important;
    visibility: visible !important;
}

.hero-subtitle {
    font-size: 1.25rem;
    color: #b4b4b4;
    margin-bottom: 2rem;
    line-height: 1.6;
    max-width: 600px;
}

.hero-actions {
    display: flex;
    gap: 1rem;
    flex-wrap: wrap;
}

.hero-visual {
    position: relative;
    width: 100%;
    height: 500px;
    border-radius: 1.5rem;
    overflow: hidden;
}

.hero-visual-bg {
    position: absolute;
    top: -20px;
    right: -20px;
    width: calc(100% + 40px);
    height: calc(100% + 40px);
    background: linear-gradient(135deg, rgba(227, 6, 19, 0.2) 0%, rgba(212, 165, 116, 0.2) 100%);
    filter: blur(40px);
    z-index: 0;
}

.hero-visual img {
    position: relative;
    z-index: 1;
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: 1.5rem;
    border: 1px solid rgba(255, 255, 255, 0.1);
}

/* Section Premium */
.section-premium {
    padding-top: 1%;
    padding-bottom: 5rem;
    position: relative;
}

.section-title {
    font-size: 2.5rem;
    font-weight: 800;
    color: #ffffff;
    margin-bottom: 1rem;
    text-align: center;
    text-transform: uppercase;
    letter-spacing: -0.01em;
    opacity: 1;
    visibility: visible;
}

.accent-line {
    width: 80px;
    height: 4px;
    background: linear-gradient(90deg, #e30613 0%, #d4a574 100%);
    margin: 0 auto 3rem;
    border-radius: 2px;
    opacity: 1;
    visibility: visible;
}

/* Grid Premium */
.grid-premium {
    display: grid;
    gap: 2rem;
}

.grid-premium-3 {
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
}

/* Grid com divisores horizontais - 3 colunas */
.grid-premium-3.grid-with-dividers {
    grid-template-columns: repeat(3, 1fr);
    row-gap: 3rem;
    column-gap: 2rem;
}

/* Adicionar linhas horizontais entre as rows */
.grid-premium-3.grid-with-dividers > .card-premium:nth-child(3n + 1):nth-child(n + 4)::before,
.grid-premium-3.grid-with-dividers > .card-premium:nth-child(3n + 2):nth-child(n + 4)::before,
.grid-premium-3.grid-with-dividers > .card-premium:nth-child(3n + 3):nth-child(n + 4)::before {
    content: '';
    position: absolute;
    left: -2rem;
    right: -2rem;
    top: -1.5rem;
    height: 1px;
    background: linear-gradient(
        90deg,
        transparent 0%,
        rgba(227, 6, 19, 0.2) 10%,
        rgba(227, 6, 19, 0.4) 50%,
        rgba(227, 6, 19, 0.2) 90%,
        transparent 100%
    );
}

/* Primeira linha horizontal - começa do primeiro item da segunda linha (4º item) */
.grid-premium-3.grid-with-dividers > .card-premium:nth-child(4)::before {
    left: calc(-100% - 2rem); /* Estende para incluir as 3 colunas */
    width: calc(300% + 4rem);
}

.grid-premium-4 {
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
}

.grid-premium-5 {
    grid-template-columns: repeat(5, 1fr);
    justify-items: center;
}

/* Se tiver menos de 5 itens, centralizar */
.grid-premium-5:has(.card-premium:nth-child(-n+4):last-child) {
    justify-content: center;
}

/* Garantir que cada card ocupe uma coluna fixa */
.grid-premium-5 > .card-premium {
    width: 100%;
    max-width: 280px;
}

/* Card Premium */
.card-premium {
    background: linear-gradient(135deg, rgba(255,255,255,0.05) 0%, rgba(255,255,255,0.02) 100%);
    border-radius: 1.5rem;
    padding: 1.5rem;
    border: 1px solid rgba(255, 255, 255, 0.08);
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
    overflow: hidden;
    text-decoration: none;
    display: block;
    opacity: 1;
    visibility: visible;
}

.card-premium::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(135deg, rgba(227, 6, 19, 0.1) 0%, rgba(212, 165, 116, 0.1) 100%);
    opacity: 0;
    transition: opacity 0.4s ease;
    pointer-events: none;
}

.card-premium:hover {
    transform: translateY(-8px);
    border-color: rgba(227, 6, 19, 0.3);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.3);
}

.card-premium:hover::before {
    opacity: 1;
}

.card-image {
    width: 100%;
    height: 250px;
    border-radius: 1rem;
    overflow: hidden;
    margin-bottom: 1.25rem;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.05);
}

/* Modo retrato APENAS para catálogos */
.card-image-catalog {
    height: 400px;
}

.card-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s cubic-bezier(0.4, 0, 0.2, 1);
}

/* Object-fit contain APENAS para catálogos */
.card-image-catalog img {
    object-fit: contain;
}

.card-premium:hover .card-image img {
    transform: scale(1.1);
}

.card-title {
    font-size: 1.25rem;
    font-weight: 700;
    color: #ffffff;
    margin-bottom: 5px !important;
    line-height: 1.3;
    text-align: center;
}

.card-meta {
    font-size: 0.875rem;
    color: #888888;
    margin-bottom: 0;
}

.card-description {
    color: #b4b4b4;
    font-size: 0.9375rem;
    margin-bottom: 1.25rem;
    line-height: 1.6;
}

.card-badge {
    position: absolute;
    top: 1.75rem;
    right: 1.75rem;
    background: rgba(227, 6, 19, 0.9);
    backdrop-filter: blur(10px);
    color: #ffffff;
    padding: 0.5rem 1rem;
    border-radius: 2rem;
    font-size: 0.75rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

/* Line Cards */
.card-line {
    text-align: center;
    padding: 1rem;
}

.card-line .card-image {
    height: 140px;
    width: 100%;
    margin-bottom: 0.75rem;
}

.card-line .card-image img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    padding: 0.5rem;
}

.card-line .card-title {
    font-size: 1rem;
    margin-bottom: 0.5rem;
}

.card-line .card-meta {
    font-size: 0.8rem;
}

.line-placeholder {
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, rgba(227, 6, 19, 0.1) 0%, rgba(212, 165, 116, 0.1) 100%);
    color: #d4a574;
    font-size: 3rem;
}

/* Buttons Premium */
.btn-premium {
    padding: 1rem 2rem;
    border-radius: 1rem;
    font-weight: 600;
    font-size: 1rem;
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    text-decoration: none;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    transition: all 250ms cubic-bezier(0.4, 0, 0.2, 1);
    border: none;
    cursor: pointer;
    position: relative;
    overflow: hidden;
}

.btn-premium-primary {
    background: linear-gradient(135deg, #dc3545 0%, #1a1a1a 100%);
    color: #ffffff;
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.4);
}

.btn-premium-primary::before {
    content: '';
    position: absolute;
    right: calc(-20% + 50px);
    top: 50%;
    transform: translateY(-50%);
    width: 120%;
    height: 120%;
    background-image: url('../images/logo-botoes.png');
    background-position: right center;
    background-repeat: no-repeat;
    background-size: auto 180%;
    opacity: 0.12;
    pointer-events: none;
}

.btn-premium-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.6);
    color: #ffffff;
}

.btn-premium-primary:hover::before {
    opacity: 0.25;
}

.btn-premium-ghost {
    background: transparent;
    color: #ffffff;
    border: 2px solid rgba(255, 255, 255, 0.12);
    box-shadow: none;
}

.btn-premium-ghost:hover {
    background: rgba(255, 255, 255, 0.05);
    border-color: #ffc107;
    color: #ffc107;
    transform: translateY(-2px);
}

/* CTA Section */
.cta-premium {
    padding: 5rem 0;
    background: linear-gradient(135deg, #0a0a0a 0%, #3a3a3a 100%);
}

.cta-box {
    text-align: center;
    padding: 4rem 2rem;
    background: linear-gradient(135deg, rgba(255,255,255,0.05) 0%, rgba(255,255,255,0.02) 100%);
    border-radius: 2rem;
    border: 1px solid rgba(255, 255, 255, 0.08);
    opacity: 1;
    visibility: visible;
}

.cta-box h3 {
    font-size: 2rem;
    font-weight: 800;
    color: #ffffff;
    margin-bottom: 1rem;
    text-transform: uppercase;
}

.cta-box p {
    font-size: 1.125rem;
    color: #b4b4b4;
    margin-bottom: 2rem;
}

/* Responsive */
@media (max-width: 991px) {
    .hero-premium {
        min-height: auto;
        padding: 4rem 0;
    }

    .hero-visual {
        height: 400px;
        margin-top: 3rem;
    }

    .section-premium {
        padding-top: 1%;
        padding-bottom: 3rem;
    }

    .section-title {
        font-size: 2rem;
    }
}

/* Centralizar conteúdo dos cards na Home */
.home .card-premium {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
}

@media (max-width: 576px) {
    .hero-title {
        font-size: 2rem;
    }

    .hero-subtitle {
        font-size: 1rem;
    }

    .hero-actions {
        flex-direction: column;
    }

    .btn-premium {
        width: 100%;
        justify-content: center;
    }

    .grid-premium-3,
    .grid-premium-4,
    .grid-premium-5 {
        grid-template-columns: 1fr;
    }
}

/* Responsivo para tablets */
@media (max-width: 1200px) {
    .grid-premium-5 {
        grid-template-columns: repeat(3, 1fr);
    }
}

@media (max-width: 768px) {
    .grid-premium-5 {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .grid-premium-5 > .card-premium {
        max-width: 100%;
    }
    
    .grid-premium-3.grid-with-dividers {
        grid-template-columns: repeat(2, 1fr);
    }
    
    /* Ajustar linhas horizontais para 2 colunas */
    .grid-premium-3.grid-with-dividers > .card-premium:nth-child(n + 4)::before {
        display: none;
    }
    
    .grid-premium-3.grid-with-dividers > .card-premium:nth-child(2n + 1):nth-child(n + 3)::before {
        content: '';
        position: absolute;
        left: -1rem;
        width: calc(200% + 2rem);
        top: -1.5rem;
        height: 1px;
        background: linear-gradient(
            90deg,
            transparent 0%,
            rgba(227, 6, 19, 0.2) 10%,
            rgba(227, 6, 19, 0.4) 50%,
            rgba(227, 6, 19, 0.2) 90%,
            transparent 100%
        );
    }
}

@media (max-width: 576px) {
    .grid-premium-3.grid-with-dividers {
        grid-template-columns: 1fr;
    }
    
    /* Remover todas as linhas horizontais no mobile */
    .grid-premium-3.grid-with-dividers > .card-premium::before {
        display: none !important;
    }
}
