:root {
    --c-primary: #2563eb;
    --c-primary-hover: #1d4ed8;
    --c-bg-body: #fafafb;
    --c-bg-card: #ffffff;
    --c-text-main: #111827;
    --c-text-muted: #6b7280;
    --c-footer-bg: #030a1c;
    --c-footer-text: #9ca3af;
    --c-tag-bg: #dbeafe;
    --c-tag-text: #1e40af;
    --font-main: 'Inter', sans-serif;
    --transition: 0.3s ease;
}

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

body {
    font-family: var(--font-main);
    background-color: var(--c-bg-body);
    color: var(--c-text-main);
    line-height: 1.6;
    overflow-x: hidden;
    position: relative;
}

body.dark-mode {
    --c-bg-body: #111827;
    --c-bg-card: #1f2937;
    --c-text-main: #f9fafb;
    --c-text-muted: #9ca3af;
}

/* Gradient background blob */
.bg-blob {
    position: absolute;
    top: 10%;
    left: -15%;
    width: 50vw;
    height: 50vw;
    background: radial-gradient(circle, rgba(244, 207, 207, 0.4) 0%, rgba(216, 243, 246, 0.4) 50%, transparent 70%);
    filter: blur(80px);
    z-index: -1;
    pointer-events: none;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

a {
    text-decoration: none;
    color: inherit;
    transition: var(--transition);
}

img {
    max-width: 100%;
    display: block;
}

/* Header */
.site-header {
    background-color: var(--c-bg-card);
    box-shadow: 0 2px 10px rgba(0,0,0,0.05);
    padding-bottom: 0;
}

.header-top {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px 0;
}

.header-spacer {
    flex: 1;
}

.logo-container {
    flex: 1;
    display: flex;
    justify-content: center;
}

.logo-img {
    height: 80px;
    border-radius: 50%;
}

.header-actions {
    flex: 1;
    display: flex;
    justify-content: flex-end;
    align-items: center;
    gap: 12px;
}

.icon-btn {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    border: 1px solid #e5e7eb;
    background: transparent;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: var(--transition);
}

.icon-btn img {
    width: 16px;
    height: 16px;
}

.icon-btn.blue-btn {
    background: var(--c-primary);
    border-color: var(--c-primary);
}

.icon-btn.dark-btn {
    background: #111827;
    border-color: #111827;
}

.subscribe-btn {
    background-color: var(--c-primary);
    color: white;
    border: none;
    padding: 8px 16px;
    border-radius: 4px;
    font-weight: 500;
    display: flex;
    align-items: center;
    gap: 8px;
    cursor: pointer;
    transition: var(--transition);
}

.subscribe-btn:hover, .icon-btn.blue-btn:hover {
    background-color: var(--c-primary-hover);
}

.btn-icon {
    width: 16px;
    height: 16px;
}

/* Navigation */
.main-nav {
    border-top: 1px solid #e5e7eb;
    border-bottom: 1px solid #e5e7eb;
    background-color: #f8fafc;
}

.nav-list {
    list-style: none;
    display: flex;
    justify-content: center;
    gap: 30px;
    padding: 15px 0;
}

.nav-list a {
    font-weight: 600;
    font-size: 14px;
    color: var(--c-text-main);
}

.nav-list a.active, .nav-list a:hover {
    color: var(--c-primary);
    border-bottom: 2px solid var(--c-primary);
    padding-bottom: 14px;
}

/* News Ticker */
.news-ticker {
    display: flex;
    align-items: center;
    padding: 10px 20px;
    background: var(--c-bg-card);
    margin-top: 20px;
    border-radius: 4px;
}

.ticker-label {
    background: var(--c-primary);
    color: white;
    padding: 6px 12px;
    font-size: 13px;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 8px;
    white-space: nowrap;
}

.dot {
    width: 6px;
    height: 6px;
    background: white;
    border-radius: 50%;
}

.ticker-content {
    flex: 1;
    display: flex;
    gap: 20px;
    padding: 0 15px;
    overflow: hidden;
    white-space: nowrap;
    align-items: center;
}

.ticker-item {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 13px;
    font-weight: 500;
}

.ticker-item img {
    width: 40px;
    height: 24px;
    object-fit: cover;
    border-radius: 2px;
}

/* Hero Carousel */
.hero-carousel {
    margin-top: 30px;
    display: flex;
    align-items: center;
    gap: 20px;
    position: relative;
}

.carousel-track {
    display: flex;
    gap: 20px;
    overflow: hidden;
    flex: 1;
}

.hero-card {
    position: relative;
    flex: 1;
    min-width: 0;
    height: 400px;
    border-radius: 8px;
    overflow: hidden;
    transition: var(--transition);
}

.hero-card.active {
    flex: 1.5;
}

.card-bg {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.hero-card::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 70%;
    background: linear-gradient(to top, rgba(0,0,0,0.8), transparent);
}

.card-content {
    position: absolute;
    bottom: 20px;
    left: 20px;
    right: 20px;
    z-index: 2;
    color: white;
}

.tags {
    display: flex;
    gap: 8px;
    margin-bottom: 10px;
    flex-wrap: wrap;
}

.tag {
    background: var(--c-tag-bg);
    color: var(--c-tag-text);
    padding: 4px 10px;
    border-radius: 4px;
    font-size: 11px;
    font-weight: 600;
    text-transform: uppercase;
}

.card-content h2 {
    font-size: 22px;
    margin-bottom: 12px;
    line-height: 1.3;
}

.meta-info {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 12px;
    opacity: 0.9;
}

.avatar, .avatar-sm {
    border-radius: 50%;
    object-fit: cover;
}

.avatar {
    width: 24px;
    height: 24px;
}

.meta-icon, .meta-icon-sm {
    width: 14px;
    height: 14px;
    filter: brightness(0) invert(1);
}

.meta-info.light {
    color: var(--c-text-muted);
}
.meta-info.light .meta-icon-sm {
    filter: none;
    opacity: 0.6;
}

.carousel-btn {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: white;
    border: 1px solid #e5e7eb;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 2px 5px rgba(0,0,0,0.1);
    z-index: 10;
}
.carousel-btn img {
    width: 20px;
    height: 20px;
}

/* Sections Common */
.section-header {
    display: flex;
    align-items: center;
    gap: 15px;
    margin: 40px 0 20px;
}

.section-header hr {
    flex: 1;
    border: none;
    border-top: 1px solid #e5e7eb;
}

.section-header h3 {
    font-size: 18px;
    font-weight: 700;
    white-space: nowrap;
}

/* Editor Choice Grid */
.grid-4 {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 20px;
}

.post-card {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.post-img {
    width: 100%;
    height: 180px;
    object-fit: cover;
    border-radius: 6px;
}

.post-card h4 {
    font-size: 15px;
    line-height: 1.4;
}

.tags.mini .tag {
    padding: 2px 6px;
    font-size: 9px;
}

.avatar-sm {
    width: 16px;
    height: 16px;
}

/* Dark overlay variant */
.img-wrapper.dark-overlay {
    position: relative;
    height: 100%;
    border-radius: 6px;
    overflow: hidden;
}

.img-wrapper.dark-overlay .post-img {
    height: 100%;
}

.img-wrapper.dark-overlay::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(to top, rgba(0,40,20,0.9), rgba(0,0,0,0.2));
}

.overlay-content {
    position: absolute;
    bottom: 15px;
    left: 15px;
    right: 15px;
    z-index: 2;
    color: white;
}

.overlay-content h4 {
    margin-bottom: 5px;
}

.overlay-content .meta-info.light {
    color: rgba(255,255,255,0.8);
}

/* Two Columns Layout */
.two-columns {
    display: flex;
    gap: 40px;
    margin-top: 50px;
    margin-bottom: 50px;
}

.main-feed {
    flex: 2;
    display: flex;
    flex-direction: column;
    gap: 30px;
}

.feed-item {
    display: flex;
    gap: 20px;
}

.feed-img {
    width: 280px;
    height: 180px;
    object-fit: cover;
    border-radius: 6px;
}

.feed-content {
    flex: 1;
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.feed-content h2 {
    font-size: 20px;
    margin: 8px 0;
}

.feed-content p {
    color: var(--c-text-muted);
    font-size: 14px;
    margin: 10px 0;
}

.read-more {
    color: var(--c-primary);
    font-weight: 600;
    font-size: 14px;
}

.sidebar {
    flex: 1;
}

.recent-posts {
    list-style: none;
}

.recent-posts li {
    margin-bottom: 15px;
}

.recent-posts a {
    font-size: 14px;
    font-weight: 600;
    line-height: 1.4;
    display: block;
}

.recent-posts a:hover {
    color: var(--c-primary);
}

/* Welcome Section */
.welcome-section {
    margin-bottom: 60px;
}

.welcome-box {
    background: white;
    padding: 40px;
    border-radius: 12px;
    text-align: center;
    box-shadow: 0 10px 30px rgba(0,0,0,0.03);
    max-width: 800px;
    margin: 0 auto;
}

.welcome-box h2 {
    font-size: 24px;
    margin-bottom: 20px;
    color: var(--c-text-main);
}

.welcome-logo {
    margin: 20px 0;
}

.welcome-box p {
    color: var(--c-text-muted);
    font-size: 15px;
}

/* Footer */
.site-footer {
    background-color: var(--c-footer-bg);
    color: white;
    padding-top: 60px;
}

.footer-container {
    display: grid;
    grid-template-columns: 2fr 1fr 1fr;
    gap: 40px;
    margin-bottom: 40px;
}

.disclaimer-text {
    color: var(--c-footer-text);
    font-size: 13px;
    line-height: 1.8;
}

.footer-col h4 {
    font-size: 16px;
    margin-bottom: 10px;
}

.wave-divider {
    margin-bottom: 20px;
}

.footer-links {
    list-style: none;
}

.footer-links li {
    margin-bottom: 12px;
}

.footer-links a {
    color: var(--c-footer-text);
    font-size: 14px;
    text-decoration: underline;
}

.footer-links a:hover {
    color: white;
}

.footer-bottom {
    border-top: 1px solid rgba(255,255,255,0.1);
    padding: 20px 0;
    text-align: center;
    font-size: 13px;
    color: var(--c-footer-text);
}

/* Cookie Modal (Right side) */
.cookie-modal {
    position: fixed;
    bottom: 30px;
    right: 30px;
    width: 320px;
    background: white;
    border-radius: 8px;
    box-shadow: 0 10px 40px rgba(0,0,0,0.15);
    padding: 20px;
    z-index: 1000;
    transform: translateX(120%);
    transition: transform 0.5s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

.cookie-modal.show {
    transform: translateX(0);
}

.cookie-content h4 {
    font-size: 16px;
    margin-bottom: 10px;
    color: var(--c-text-main);
}

.cookie-content p {
    font-size: 13px;
    color: var(--c-text-muted);
    margin-bottom: 15px;
}

.cookie-actions {
    display: flex;
    gap: 10px;
    align-items: center;
}

.btn-accept {
    background: var(--c-primary);
    color: white;
    border: none;
    padding: 8px 16px;
    border-radius: 4px;
    cursor: pointer;
    font-weight: 500;
    flex: 1;
}

.btn-close {
    background: #f3f4f6;
    border: none;
    width: 34px;
    height: 34px;
    border-radius: 4px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
}
.btn-close img {
    width: 14px;
    height: 14px;
    opacity: 0.6;
}

/* Scroll Top Button */
.scroll-top {
    position: fixed;
    bottom: 30px;
    right: 30px;
    width: 44px;
    height: 44px;
    border-radius: 50%;
    background: var(--c-primary);
    color: white;
    border: none;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 4px 10px rgba(37, 99, 235, 0.3);
    opacity: 0;
    visibility: hidden;
    transition: var(--transition);
    z-index: 999;
}

.scroll-top.visible {
    opacity: 1;
    visibility: visible;
}

.scroll-top img {
    width: 20px;
    height: 20px;
    filter: brightness(0) invert(1);
}

/* Responsive */
@media (max-width: 992px) {
    .grid-4 {
        grid-template-columns: repeat(2, 1fr);
    }
    .two-columns {
        flex-direction: column;
    }
    .footer-container {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 768px) {
    .header-top {
        flex-direction: column;
        gap: 15px;
    }
    .hero-carousel {
        flex-direction: column;
    }
    .carousel-track {
        flex-direction: column;
        width: 100%;
    }
    .hero-card {
        height: 250px;
    }
    .feed-item {
        flex-direction: column;
    }
    .feed-img {
        width: 100%;
    }
    .cookie-modal {
        right: 15px;
        bottom: 15px;
        width: calc(100% - 30px);
    }
}

/* Inner page styles */
/* --- ESTILOS DA PÁGINA INTERNA (ARTIGO) --- */

.article-page {
    padding-top: 40px;
    padding-bottom: 60px;
}

.article-header {
    text-align: center;
    margin-bottom: 40px;
    max-width: 900px;
    margin-left: auto;
    margin-right: auto;
}

.article-header .tags {
    justify-content: center;
    margin-bottom: 15px;
}

.article-title {
    font-size: 40px;
    font-weight: 700;
    color: var(--c-text-main);
    margin-bottom: 20px;
    line-height: 1.25;
}

.article-header .meta-info {
    justify-content: center;
    margin-bottom: 35px;
    font-size: 14px;
}

/* Imagens Responsivas */
.article-main-img {
    width: 100%;
    height: auto;
    max-height: 550px;
    object-fit: cover;
    border-radius: 12px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.08);
}

.article-inline-img {
    width: 100%;
    height: auto;
    border-radius: 8px;
    margin: 35px 0;
    box-shadow: 0 4px 15px rgba(0,0,0,0.05);
}

/* Layout do Artigo */
.article-layout {
    display: flex;
    gap: 50px;
    margin-top: 40px;
}

.article-body {
    flex: 2;
    min-width: 0;
    font-size: 17px;
    line-height: 1.85;
    color: #374151;
}

body.dark-mode .article-body {
    color: #d1d5db;
}

.article-sidebar {
    flex: 1;
    min-width: 320px;
    display: flex;
    flex-direction: column;
    gap: 30px;
}

/* Estilos de Texto (H1-H6, P, Span) */
.article-body h1, 
.article-body h2, 
.article-body h3, 
.article-body h4, 
.article-body h5, 
.article-body h6 {
    color: var(--c-text-main);
    font-weight: 700;
    margin: 40px 0 20px;
    line-height: 1.3;
}

.article-body h1 { font-size: 34px; }
.article-body h2 { font-size: 28px; border-bottom: 2px solid #e5e7eb; padding-bottom: 10px; }
.article-body h3 { font-size: 24px; }
.article-body h4 { font-size: 20px; }
.article-body h5 { font-size: 18px; text-transform: uppercase; letter-spacing: 0.5px; }
.article-body h6 { font-size: 16px; text-transform: uppercase; color: var(--c-text-muted); }

body.dark-mode .article-body h2 { border-color: #374151; }

.article-body p {
    margin-bottom: 25px;
}

.article-body span.highlight {
    background-color: rgba(37, 99, 235, 0.1);
    color: var(--c-primary);
    padding: 2px 6px;
    border-radius: 4px;
    font-weight: 600;
}

/* Listas (UL, OL) */
.article-body ul, 
.article-body ol {
    margin: 0 0 30px 20px;
    padding-left: 20px;
}

.article-body ul li, 
.article-body ol li {
    margin-bottom: 10px;
    padding-left: 5px;
}

.article-body ul {
    list-style-type: disc;
}

.article-body ol {
    list-style-type: decimal;
}

/* Tabelas */
.article-table {
    width: 100%;
    border-collapse: collapse;
    margin: 40px 0;
    font-size: 15px;
    background: var(--c-bg-card);
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 2px 10px rgba(0,0,0,0.03);
}

.article-table th, 
.article-table td {
    border: 1px solid #e5e7eb;
    padding: 14px 20px;
    text-align: left;
}

.article-table th {
    background-color: #f8fafc;
    font-weight: 600;
    color: var(--c-text-main);
}

body.dark-mode .article-table th, 
body.dark-mode .article-table td {
    border-color: #374151;
}
body.dark-mode .article-table th {
    background-color: #1f2937;
}

/* Oglavlenie (TOC) */
.toc-box {
    background-color: #f8fafc;
    border: 1px solid #e5e7eb;
    border-radius: 8px;
    padding: 25px;
    margin-bottom: 40px;
}

body.dark-mode .toc-box {
    background-color: #1f2937;
    border-color: #374151;
}

.toc-title {
    font-size: 18px;
    font-weight: 700;
    margin-bottom: 15px;
    color: var(--c-text-main);
    display: flex;
    align-items: center;
    gap: 10px;
}

.toc-list {
    list-style: none !important;
    margin: 0 !important;
    padding: 0 !important;
}

.toc-list li {
    margin-bottom: 12px !important;
}

.toc-list a {
    color: var(--c-primary);
    font-weight: 500;
    text-decoration: none;
    transition: var(--transition);
}

.toc-list a:hover {
    text-decoration: underline;
    color: var(--c-primary-hover);
}

/* Formulários Comuns */
.form-group {
    margin-bottom: 20px;
}

.form-group label {
    display: block;
    margin-bottom: 8px;
    font-size: 14px;
    font-weight: 600;
    color: var(--c-text-main);
}

.form-control {
    width: 100%;
    padding: 12px 15px;
    border: 1px solid #d1d5db;
    border-radius: 6px;
    font-family: var(--font-main);
    font-size: 15px;
    background: var(--c-bg-card);
    color: var(--c-text-main);
    transition: var(--transition);
}

.form-control:focus {
    border-color: var(--c-primary);
    outline: none;
    box-shadow: 0 0 0 3px rgba(37,99,235,0.15);
}

body.dark-mode .form-control {
    border-color: #4b5563;
}

.submit-btn {
    background: var(--c-primary);
    color: white;
    border: none;
    padding: 14px 28px;
    border-radius: 6px;
    font-weight: 600;
    cursor: pointer;
    transition: var(--transition);
    font-size: 15px;
}

.submit-btn:hover {
    background: var(--c-primary-hover);
}

.submit-btn.full-width {
    width: 100%;
}

/* Comentários */
.comments-section {
    margin-top: 60px;
    padding-top: 40px;
    border-top: 1px solid #e5e7eb;
}

body.dark-mode .comments-section {
    border-color: #374151;
}

.comments-section h3 {
    font-size: 26px;
    margin-bottom: 25px;
    color: var(--c-text-main);
}

/* Widgets / Sidebar */
.widget {
    background: var(--c-bg-card);
    border-radius: 12px;
    padding: 30px;
    box-shadow: 0 4px 20px rgba(0,0,0,0.03);
    border: 1px solid #f3f4f6;
}

body.dark-mode .widget {
    border-color: #374151;
    box-shadow: none;
}

.widget h3 {
    font-size: 18px;
    font-weight: 700;
    margin-bottom: 20px;
    color: var(--c-text-main);
    position: relative;
    padding-bottom: 10px;
}

.widget h3::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 40px;
    height: 3px;
    background: var(--c-primary);
    border-radius: 2px;
}

/* Bloco de Interligação (Related Articles) */
.related-list {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.related-item {
    display: flex;
    align-items: center;
    gap: 15px;
    group: hover;
}

.related-item img {
    width: 80px;
    height: 60px;
    object-fit: cover;
    border-radius: 6px;
}

.related-item span {
    font-size: 14px;
    font-weight: 600;
    line-height: 1.4;
    transition: var(--transition);
}

.related-item:hover span {
    color: var(--c-primary);
}

/* Responsividade */
@media (max-width: 992px) {
    .article-layout {
        flex-direction: column;
    }
    .article-sidebar {
        min-width: 100%;
    }
    .article-title {
        font-size: 32px;
    }
}

@media (max-width: 768px) {
    .article-title {
        font-size: 26px;
    }
    .article-layout {
        gap: 30px;
    }
}