/*
Theme Name: IPTVFlix
Author: Marcos
Version: 3.4 - Corrigido
*/

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    background: #0b0b0b;
    color: #fff;
    font-family: 'Segoe UI', Arial, sans-serif;
    /* Evita que o header fixo cubra o conteúdo */
    padding-top: 80px; /* ajuste conforme a altura do header */
}

@media (max-width: 768px) {
    body {
        padding-top: 70px; /* header menor no mobile */
    }
}

/* HEADER FIXO */
.main-header {
    position: fixed;
    width: 100%;
    top: 0;
    z-index: 999;
    background: rgba(0,0,0,0.9);
    backdrop-filter: blur(10px);
    border-bottom: 1px solid rgba(255,255,255,0.05);
}

.container-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 15px 30px;
}

.logo a {
    font-size: 22px;
    font-weight: bold;
    color: #fff;
    text-decoration: none;
}

.logo span {
    color: #00ff88;
}

/* ===== MENU HAMBÚRGUER ===== */
.menu {
    display: none;
    position: absolute;
    top: 70px;
    left: 0;
    width: 100%;
    background: #000;
    flex-direction: column;
    align-items: center;
    padding: 20px 0;
    gap: 15px;
    border-top: 1px solid #333;
    box-shadow: 0 5px 10px rgba(0,0,0,0.5);
    z-index: 998;
}

.menu.active {
    display: flex;
}

.menu a {
    color: #fff;
    text-decoration: none;
    font-size: 18px;
    padding: 12px 20px;
    width: 100%;
    text-align: center;
    transition: background 0.3s, color 0.3s;
}

.menu a:hover {
    background: #00ff88;
    color: #000;
}

.menu-toggle {
    display: block;
    font-size: 30px;
    color: #fff;
    cursor: pointer;
    padding: 10px 15px;
    z-index: 9999;
}

/* HERO */
.hero {
    position: relative;
    height: 100vh;
    background: url('/wp-content/uploads/bg.jpg') center/cover no-repeat;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
}

.hero::after {
    content: "";
    position: absolute;
    width: 100%;
    height: 100%;
    background: linear-gradient(to top, #0b0b0b 10%, transparent 80%);
}

.hero-content {
    position: relative;
    z-index: 2;
    max-width: 800px;
    padding: 0 20px;
}

.hero h1 {
    font-size: 70px;
    font-weight: 800;
    letter-spacing: 2px;
}

.hero h1 span {
    color: #00ff88;
}

.hero p {
    margin-top: 10px;
    font-size: 20px;
    color: #ccc;
}

.hero-buttons {
    margin-top: 30px;
}

.btn-primary {
    background: #00ff88;
    color: #000;
    padding: 15px 35px;
    border-radius: 50px;
    text-decoration: none;
    font-weight: bold;
    margin-right: 10px;
    transition: 0.3s;
    box-shadow: 0 0 20px #00ff88;
    display: inline-block;
    border: none;
    cursor: pointer;
}

.btn-primary:hover {
    transform: scale(1.05);
}

.btn-secondary {
    background: transparent;
    border: 2px solid #fff;
    padding: 15px 35px;
    border-radius: 50px;
    text-decoration: none;
    color: #fff;
    transition: 0.3s;
    display: inline-block;
}

.btn-secondary:hover {
    background: #fff;
    color: #000;
}

/* BENEFÍCIOS */
.benefits {
    padding: 40px 20px;
    background: #111;
    text-align: center;
    display: flex;
    justify-content: center;
    gap: 40px;
    flex-wrap: wrap;
}

.benefit {
    font-size: 18px;
    color: #00ff88;
}

/* SEÇÕES GERAIS */
.catalogo, .top10, .planos {
    padding: 60px 20px;
}

.catalogo h2, .top10 h2, .planos h2 {
    font-size: 32px;
    margin-bottom: 30px;
    text-align: center;
}

/* ===== CARDS DE CONTEÚDO (LADO A LADO) ===== */
.grid {
    display: flex;
    flex-wrap: wrap;
    gap: 20px;
    justify-content: center;
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 15px;
}

.card {
    flex: 0 0 calc(50% - 20px);
    max-width: calc(50% - 20px);
    background: #111;
    border-radius: 10px;
    overflow: hidden;
    transition: transform 0.3s;
    cursor: pointer;
    position: relative;
}

/* Tablets - 3 cards */
@media (min-width: 600px) {
    .card {
        flex: 0 0 calc(33.333% - 20px);
        max-width: calc(33.333% - 20px);
    }
}

/* Desktop - 4 cards */
@media (min-width: 900px) {
    .card {
        flex: 0 0 calc(25% - 20px);
        max-width: calc(25% - 20px);
    }
}

/* Desktop grande - 5 cards */
@media (min-width: 1200px) {
    .card {
        flex: 0 0 calc(20% - 20px);
        max-width: calc(20% - 20px);
    }
}

.card:hover {
    transform: scale(1.03);
}

.card img {
    width: 100%;
    height: 180px;
    object-fit: cover;
    display: block;
}

@media (min-width: 768px) {
    .card img {
        height: 200px;
    }
}

@media (min-width: 1024px) {
    .card img {
        height: 220px;
    }
}

.card-overlay {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    background: linear-gradient(to top, rgba(0,0,0,0.9), transparent);
    padding: 20px 8px 8px;
    color: #fff;
    opacity: 0;
    transition: opacity 0.3s;
}

.card:hover .card-overlay {
    opacity: 1;
}

.card-overlay h3 {
    font-size: 14px;
    text-align: center;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    color: #00ff88;
}

/* ===== TOP 10 ===== */
.top-grid {
    display: flex;
    flex-wrap: wrap;
    gap: 20px;
    justify-content: center;
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 15px;
}

.top-card {
    flex: 0 0 calc(50% - 20px);
    max-width: calc(50% - 20px);
    background: #111;
    border-radius: 10px;
    overflow: hidden;
    transition: transform 0.3s;
    cursor: pointer;
    position: relative;
}

@media (min-width: 600px) {
    .top-card {
        flex: 0 0 calc(33.333% - 20px);
        max-width: calc(33.333% - 20px);
    }
}

@media (min-width: 900px) {
    .top-card {
        flex: 0 0 calc(25% - 20px);
        max-width: calc(25% - 20px);
    }
}

.top-card:hover {
    transform: scale(1.03);
}

.top-card img {
    width: 100%;
    height: 180px;
    object-fit: cover;
}

.top-card .rank {
    position: absolute;
    top: 5px;
    left: 8px;
    font-size: 36px;
    font-weight: bold;
    color: #00ff88;
    text-shadow: 2px 2px 4px rgba(0,0,0,0.5);
    z-index: 2;
}

.top-card h4 {
    background: rgba(0,0,0,0.8);
    padding: 8px;
    font-size: 13px;
    text-align: center;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

/* ===== PLANOS ===== */
.planos-grid {
    display: flex;
    gap: 30px;
    justify-content: center;
    flex-wrap: wrap;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

.plan-card {
    background: #111;
    padding: 30px 20px;
    border-radius: 20px;
    width: 280px;
    transition: transform 0.3s;
    box-shadow: 0 0 25px rgba(0,255,136,0.2);
    text-align: center;
    display: flex;
    flex-direction: column;
    align-items: center;
}

.plan-card:hover {
    transform: scale(1.05);
}

.plan-card.destaque {
    border: 2px solid #00ff88;
    box-shadow: 0 0 30px rgba(0,255,136,0.4);
}

.plan-card h3 {
    font-size: 24px;
    margin-bottom: 10px;
    color: #fff;
}

.price {
    font-size: 40px;
    color: #00ff88;
    margin: 15px 0;
    font-weight: bold;
}

.plan-card ul {
    list-style: none;
    margin-bottom: 20px;
    width: 100%;
}

.plan-card li {
    margin: 8px 0;
    color: #ccc;
}

.plan-card .btn-primary {
    margin-top: 10px;
    width: 100%;
    text-align: center;
}

/* DISPOSITIVOS */
.devices {
    text-align: center;
    padding: 40px 20px;
    background: #0a0a0a;
    color: #aaa;
    font-size: 16px;
}

.devices p {
    margin: 5px 0;
}

/* FOOTER */
.main-footer {
    background: #000;
    padding: 40px 20px;
    text-align: center;
    border-top: 1px solid #222;
}

.footer-content h3 {
    font-size: 24px;
    margin-bottom: 10px;
    color: #fff;
}

.footer-content p {
    color: #aaa;
    margin: 10px 0;
    max-width: 600px;
    margin-left: auto;
    margin-right: auto;
}

.footer-links {
    margin: 20px 0;
}

.footer-links a {
    margin: 0 15px;
    color: #ccc;
    text-decoration: none;
    transition: 0.3s;
}

.footer-links a:hover {
    color: #00ff88;
}

.copy {
    margin-top: 20px;
    font-size: 13px;
    color: #666;
}

/* WHATSAPP FLUTUANTE */
.whatsapp-float {
    position: fixed;
    bottom: 20px;
    right: 20px;
    background: #25D366;
    color: #fff;
    font-size: 26px;
    width: 55px;
    height: 55px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    text-decoration: none;
    box-shadow: 0 0 15px rgba(0,255,136,0.4);
    z-index: 999;
    transition: transform 0.3s;
}

.whatsapp-float:hover {
    transform: scale(1.1);
}

/* ===== RESPONSIVIDADE ===== */
@media (max-width: 768px) {
    .hero h1 {
        font-size: 40px;
    }

    .hero p {
        font-size: 16px;
    }

    .hero-buttons .btn-primary,
    .hero-buttons .btn-secondary {
        display: block;
        margin: 10px auto;
        width: 80%;
        text-align: center;
    }

    .benefits {
        flex-direction: column;
        gap: 15px;
    }
    
    .container-header {
        padding: 12px 20px;
    }
}

@media (max-width: 480px) {
    .hero h1 {
        font-size: 32px;
    }
    
    .grid, .top-grid {
        gap: 10px;
    }
    
    .card, .top-card {
        flex: 0 0 calc(50% - 10px);
        max-width: calc(50% - 10px);
    }
    
    .card img, .top-card img {
        height: 150px;
    }
}