/* Custom Styles for Antifraude Online */

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: 'Inter', sans-serif;
    background-color: #000;
    background-image: radial-gradient(rgba(255, 255, 255, 0.1) 1px, transparent 0);
    background-size: 40px 40px;
    color: #fff;
    line-height: 1.6;
}

/* Navigation Styles */
nav {
    backdrop-filter: blur(10px);
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    z-index: 1000;
    padding: 1.5rem 0;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

nav .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

nav a {
    color: #a3a3a3;
    text-decoration: none;
    margin-left: 2rem;
    font-weight: 500;
    transition: color 0.3s ease;
}

nav a.logo {
    color: #fff;
    font-weight: 700;
    font-size: 1.25rem;
    margin-left: 0;
}

nav a:hover {
    color: #3b82f6;
}

/* General Section Styles */
section {
    padding: 100px 0;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

h2 {
    font-size: 2.5rem;
    margin-bottom: 3rem;
    color: #fff;
    text-align: center;
}

h2 span {
    color: #3b82f6;
}

/* Hero Section */
section:first-of-type {
    padding-top: 150px;
    background: url('img/capa-home.jfif');
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    min-height: 60vh;
    display: flex;
    align-items: center;
}

/* 1. Lessons Section (Text) */
.lessons-content {
    max-width: 800px;
    margin: 0 auto;
    font-size: 1.125rem;
    color: #d1d5db;
}

.lessons-content h3 {
    color: #fff;
    margin: 2rem 0 1rem;
    font-size: 1.5rem;
}

.lessons-content p {
    margin-bottom: 1.5rem;
}

/* 2. Videos Section (Gallery) */
.video-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 20px;
}

.video-card {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 8px;
    overflow: hidden;
    aspect-ratio: 16 / 9;
}

.video-card iframe {
    width: 100%;
    height: 100%;
    border: none;
}

/* 3. Materials Section */
.materials-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 40px;
}

.material-category h3 {
    font-size: 1.5rem;
    margin-bottom: 1.5rem;
    color: #3b82f6;
    border-bottom: 1px solid rgba(59, 130, 246, 0.3);
    padding-bottom: 0.5rem;
    display: inline-block;
}

.material-item {
    background: rgba(255, 255, 255, 0.03);
    padding: 1.5rem;
    border-radius: 8px;
    margin-bottom: 1rem;
    border: 1px solid rgba(255, 255, 255, 0.1);
    transition: all 0.3s ease;
}

.material-item:hover {
    border-color: #3b82f6;
    transform: translateY(-2px);
    box-shadow: 0 10px 30px rgba(59, 130, 246, 0.1);
}

.material-item a {
    color: #fff;
    display: block;
    font-weight: 500;
}

.material-item span {
    display: block;
    font-size: 0.875rem;
    color: #9ca3af;
    margin-top: 0.5rem;
}

/* 4. Blog Section */
.blog-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 30px;
}

.blog-card {
    background: rgba(17, 17, 17, 0.8);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 12px;
    overflow: hidden;
    transition: all 0.3s ease;
    display: flex;
    flex-direction: column;
}

.blog-card:hover {
    border-color: #3b82f6;
    transform: translateY(-5px);
    box-shadow: 0 10px 30px rgba(59, 130, 246, 0.1);
}

.blog-image {
    height: 200px;
    width: 100%;
    object-fit: cover;
    background-color: #1f2937;
}

.blog-content {
    padding: 1.5rem;
    flex: 1;
    display: flex;
    flex-direction: column;
}

.blog-tag {
    color: #3b82f6;
    font-size: 0.75rem;
    text-transform: uppercase;
    font-weight: 600;
    margin-bottom: 0.5rem;
}

.blog-title {
    font-size: 1.25rem;
    font-weight: 700;
    margin-bottom: 0.75rem;
    color: #fff;
}

.blog-excerpt {
    color: #9ca3af;
    font-size: 0.9rem;
    margin-bottom: 1.5rem;
    flex: 1;
}

.blog-link {
    color: #fff;
    font-weight: 600;
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    transition: color 0.3s ease;
}

.blog-link:hover {
    color: #3b82f6;
}

/* Responsive Adjustments */
@media (max-width: 768px) {
    body {
        background-size: 30px 30px;
    }

    h1 {
        font-size: 2.5rem !important;
    }

    h2 {
        font-size: 2rem !important;
    }

    nav .container {
        flex-direction: column;
        gap: 1rem;
    }

    nav a {
        margin: 0 10px;
    }
}

/* Scrollbar Styling */
::-webkit-scrollbar {
    width: 8px;
}

::-webkit-scrollbar-track {
    background: #000;
}

::-webkit-scrollbar-thumb {
    background: #4b5563;
    border-radius: 4px;
}


/* Article Page Styles */
.article-page {
    padding-top: 150px;
    min-height: 100vh;
}

.article-header {
    text-align: center;
    max-width: 800px;
    margin: 0 auto 3rem;
}

.article-category {
    display: inline-block;
    background: rgba(59, 130, 246, 0.1);
    color: #3b82f6;
    padding: 0.5rem 1rem;
    border-radius: 999px;
    font-size: 0.875rem;
    font-weight: 600;
    text-transform: uppercase;
    margin-bottom: 1.5rem;
    border: 1px solid rgba(59, 130, 246, 0.3);
}

.article-title {
    font-size: 3rem;
    line-height: 1.2;
    font-weight: 700;
    color: #fff;
    margin-bottom: 2rem;
}

.article-image-container {
    max-width: 1000px;
    margin: 0 auto 4rem;
    border-radius: 12px;
    overflow: hidden;
    border: 1px solid rgba(255, 255, 255, 0.1);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.5);
}

.article-image {
    width: 100%;
    height: auto;
    display: block;
}

.article-content {
    max-width: 800px;
    margin: 0 auto;
    font-size: 1.125rem;
    color: #d1d5db;
}

.article-content h3 {
    color: #fff;
    font-size: 1.75rem;
    margin: 3rem 0 1.5rem;
}

.article-content p {
    margin-bottom: 1.5rem;
    line-height: 1.8;
}

.article-content ul,
.article-content ol {
    margin-bottom: 1.5rem;
    padding-left: 2rem;
}

.article-content li {
    margin-bottom: 0.75rem;
}

.cta-box {
    margin: 4rem auto 0;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 12px;
    padding: 3rem;
    text-align: center;
}

.cta-box h3 {
    font-size: 1.5rem;
    margin-bottom: 0.5rem;
    color: #fff;
}

.cta-button {
    display: inline-block;
    background: #3b82f6;
    color: #fff;
    padding: 1rem 2rem;
    border-radius: 999px;
    font-weight: 600;
    text-decoration: none;
    margin-top: 1.5rem;
    transition: background 0.3s ease;
}

.cta-button:hover {
    background: #2563eb;
}

/* Additional Styles for Lessons Content */
.lessons-content h4 {
    color: #fff;
    margin: 1.5rem 0 1rem;
    font-size: 1.25rem;
    font-weight: 600;
}

.lessons-content ul,
.lessons-content ol {
    margin-bottom: 1.5rem;
    padding-left: 2rem;
    color: #d1d5db;
}

.lessons-content li {
    margin-bottom: 0.75rem;
}

.lessons-content strong {
    color: #fff;
}

/* Layout do Curso */
.course-section {
    background-color: #050505;
}

.course-layout {
    display: flex;
    flex-direction: row;
    height: calc(100vh - 140px);
    /* Altura dinâmica para desktop */
    min-height: 600px;
    background: #0f1011;
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 16px;
    overflow: hidden;
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.4);
}

/* Sidebar (Menu Lateral) */
.course-sidebar {
    width: 320px;
    min-width: 320px;
    flex-shrink: 0;
    background: #0a0a0a;
    border-right: 1px solid rgba(255, 255, 255, 0.05);
    display: flex;
    flex-direction: column;
}

.sidebar-header {
    padding: 24px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

.sidebar-header h3 {
    font-size: 1.1rem;
    color: #fff;
    margin-bottom: 5px;
    font-weight: 700;
}

.lessons-list {
    overflow-y: auto;
    flex: 1;
    padding: 0;
}

/* Accordion Styles */
.module-container {
    border-bottom: 1px solid rgba(255, 255, 255, 0.03);
}

.module-header {
    padding: 18px 24px;
    cursor: pointer;
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: rgba(255, 255, 255, 0.01);
    transition: all 0.2s ease;
    user-select: none;
}

.module-header:hover {
    background: rgba(255, 255, 255, 0.04);
}

.module-header span {
    font-weight: 600;
    color: #e5e7eb;
    font-size: 0.95rem;
}

.module-header .arrow-icon {
    transition: transform 0.3s ease;
    opacity: 0.5;
    width: 16px;
    height: 16px;
}

.module-header.open .arrow-icon {
    transform: rotate(180deg);
}

.module-header.open span {
    color: #3b82f6;
}

.module-lessons {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.4s ease-out;
    background: rgba(0, 0, 0, 0.2);
}

.module-lessons.open {
    max-height: 1000px;
    transition: max-height 0.5s ease-in;
}

/* Estilo dos Botões das Aulas */
.lesson-btn {
    display: block;
    width: 100%;
    text-align: left;
    padding: 12px 24px 12px 32px;
    background: transparent;
    border: none;
    color: #9ca3af;
    font-size: 0.9rem;
    cursor: pointer;
    transition: all 0.2s ease;
    border-left: 3px solid transparent;
    font-family: 'Inter', sans-serif;
    line-height: 1.4;
}

.lesson-btn:hover {
    color: #fff;
    background: rgba(255, 255, 255, 0.02);
}

.lesson-btn.active {
    background: rgba(59, 130, 246, 0.08);
    color: #3b82f6;
    border-left-color: #3b82f6;
}

.lesson-btn.is-intro {
    font-style: italic;
    opacity: 0.8;
    padding-left: 32px;
}

/* Área de Conteúdo */
.course-content-area {
    flex: 1;
    min-width: 0;
    /* Important for scrollable flex children */
    padding: 0;
    /* Remove padding from container to allow full width footer */
    height: 100%;
    background: #0f1011;
    position: relative;
    display: flex;
    flex-direction: column;
    overflow: hidden;
    /* Main container doesn't scroll */
}

.lesson-content-scroll {
    flex: 1;
    overflow-y: auto;
    padding: 60px;
    /* Padding moved inside */
}

.lesson-sticky-footer {
    padding: 20px 60px 80px 60px;
    /* Added extra bottom padding for "sendbar" clearance */
    background: #0f1011;
    border-top: 1px solid rgba(255, 255, 255, 0.05);
    z-index: 10;
    flex-shrink: 0;
    /* Never shrink */
}

.lesson-breadcrumbs {
    display: block;
    font-size: 0.8rem;
    color: #6b7280;
    text-transform: uppercase;
    letter-spacing: 1px;
    margin-bottom: 10px;
}

#lesson-display {
    max-width: 800px;
    margin: 0 auto;
}

#lesson-display h3 {
    font-size: 2.5rem;
    color: #fff;
    margin-bottom: 2rem;
    letter-spacing: -1px;
    line-height: 1.1;
}

/* Typography Improvements */
.lesson-body {
    color: #d1d5db;
    font-size: 1.05rem;
    line-height: 1.8;
}

.lesson-body h4,
.lesson-body h5 {
    color: #fff;
    margin-top: 2.5rem;
    margin-bottom: 1rem;
    font-weight: 600;
}

.lesson-body h4 {
    font-size: 1.5rem;
}

.lesson-body h5 {
    font-size: 1.2rem;
    color: #3b82f6;
}

.lesson-body p {
    margin-bottom: 1.25rem;
}

.lesson-body ul {
    margin-bottom: 2rem;
    list-style: none;
}

.lesson-body ul li {
    margin-bottom: 0.8rem;
    padding-left: 1.5rem;
    position: relative;
}

.lesson-body ul li::before {
    content: "•";
    color: #3b82f6;
    font-weight: bold;
    position: absolute;
    left: 0;
}

.lesson-body blockquote,
.lesson-body strong {
    color: #fff;
}

.lesson-body hr {
    border: 0;
    height: 1px;
    background: rgba(255, 255, 255, 0.1);
    margin: 3rem 0;
}

/* Navigation Buttons */
.lesson-nav {
    margin-top: 60px;
    padding-top: 30px;
    border-top: 1px solid rgba(255, 255, 255, 0.05);
    display: flex;
    justify-content: space-between;
    gap: 20px;
}

.nav-btn {
    padding: 12px 24px;
    border-radius: 8px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    font-family: 'Inter', sans-serif;
}

.nav-btn.prev {
    background: transparent;
    border: 1px solid rgba(255, 255, 255, 0.2);
    color: #a3a3a3;
}

.nav-btn.prev:hover {
    border-color: #fff;
    color: #fff;
}

.nav-btn.next {
    background: #3b82f6;
    border: 1px solid #3b82f6;
    color: #fff;
}

.nav-btn.next:hover {
    background: #2563eb;
    box-shadow: 0 0 15px rgba(59, 130, 246, 0.3);
}

/* Scrollbar Bonita para o Curso */
.lessons-list::-webkit-scrollbar,
.lesson-content-scroll::-webkit-scrollbar {
    width: 10px;
}

.lessons-list::-webkit-scrollbar-track,
.lesson-content-scroll::-webkit-scrollbar-track {
    background: #0a0a0a;
}

.lessons-list::-webkit-scrollbar-thumb,
.lesson-content-scroll::-webkit-scrollbar-thumb {
    background: #4b5563;
    border-radius: 4px;
    border: 2px solid #0a0a0a;
}

.lessons-list::-webkit-scrollbar-thumb:hover,
.lesson-content-scroll::-webkit-scrollbar-thumb:hover {
    background: #3b82f6;
}

/* Responsivo para Celular */
@media (max-width: 768px) {
    .course-layout {
        flex-direction: column;
        height: auto !important;
        overflow: visible !important;
    }

    .course-sidebar {
        width: 100%;
        min-width: auto;
        height: auto;
        max-height: 400px;
        border-right: none;
        border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    }

    .course-content-area {
        height: auto !important;
        overflow: visible !important;
        display: block;
        /* Disable flex column on mobile to allow natural flow? or Keep flex? */
        /* Let's keep flex but ensure height is auto */
    }

    .lesson-content-scroll {
        overflow: visible !important;
        /* Allow page scroll on mobile */
        padding: 30px 20px;
    }

    .lesson-sticky-footer {
        padding: 20px 20px 80px 20px;
        /* Extra padding for mobile overlay clearance */
        position: sticky;
        bottom: 0;
        background: #0f1011;
        /* Ensure background to cover content */
        border-top: 1px solid rgba(255, 255, 255, 0.1);
    }

    #lesson-display h3 {
        font-size: 1.8rem;
    }
}