/* ============================================
   Pressiva — CSS Principal
   Portal de Notícias de Moçambique
   ============================================ */

/* Reset e base */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    --pr-dark: #0f0f1a;
    --pr-ink: #1a1a2e;
    --pr-accent: #e63946;
    --pr-accent-dark: #c1121f;
    --pr-text: #2b2d42;
    --pr-muted: #6c757d;
    --pr-light: #f8f9fa;
    --pr-white: #ffffff;
    --pr-border: #e9ecef;
    --pr-shadow: 0 2px 8px rgba(0,0,0,0.06);
    --pr-shadow-md: 0 4px 16px rgba(0,0,0,0.1);
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    font-size: 16px;
    line-height: 1.6;
    color: var(--pr-text);
    background: var(--pr-white);
}

a {
    color: var(--pr-accent);
    text-decoration: none;
    transition: color 0.15s;
}

a:hover {
    color: var(--pr-accent-dark);
}

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

h1, h2, h3, h4 {
    font-weight: 700;
    line-height: 1.3;
    color: #2b2d42 !important;
}

/* Exceção: headings dentro de containers escuros */
.archive-header h1,
.pr-topbar h1, .pr-topbar h2,
.sidebar-header h3,
.sidebar-newsletter h4,
.site-footer h3, .site-footer h4,
[class*="bg-dark"] h1, [class*="bg-dark"] h2, [class*="bg-dark"] h3,
.text-white h1, .text-white h2, .text-white h3 {
    color: #ffffff !important;
}

h1 { font-size: 2.2rem; margin-bottom: 1rem; }
h2 { font-size: 1.75rem; margin-bottom: 1rem; }
h3 { font-size: 1.35rem; margin-bottom: 0.75rem; }

p { margin-bottom: 1rem; }

/* ============================================
   BOTÕES — Override Bootstrap
   ============================================ */

.btn-primary,
.btn-success {
    background: var(--pr-accent) !important;
    border-color: var(--pr-accent) !important;
    color: #fff !important;
}

.btn-primary:hover,
.btn-primary:focus,
.btn-success:hover,
.btn-success:focus {
    background: var(--pr-accent-dark) !important;
    border-color: var(--pr-accent-dark) !important;
    color: #fff !important;
}

.btn-outline-success {
    color: var(--pr-accent) !important;
    border-color: var(--pr-accent) !important;
    background: transparent !important;
}

.btn-outline-success:hover {
    background: var(--pr-accent) !important;
    border-color: var(--pr-accent) !important;
    color: #fff !important;
}

/* ============================================
   FORMULÁRIOS
   ============================================ */
.form-box {
    max-width: 450px;
    margin: 3rem auto;
    background: var(--pr-white);
    padding: 2.5rem;
    border-radius: 8px;
    box-shadow: var(--pr-shadow-md);
}

.form-box h1 {
    font-family: 'Merriweather', Georgia, serif;
    font-size: 1.6rem;
    text-align: center;
    margin-bottom: 1.5rem;
}

.form-group {
    margin-bottom: 1.25rem;
}

.form-group label {
    display: block;
    margin-bottom: 0.5rem;
    font-weight: 500;
    color: var(--pr-text);
}

.form-control:focus {
    border-color: var(--pr-accent);
    box-shadow: 0 0 0 0.2rem rgba(230, 57, 70, 0.12);
}

.form-box .btn {
    width: 100%;
    padding: 0.9rem;
    font-size: 1.05rem;
}

.form-footer {
    text-align: center;
    margin-top: 1.5rem;
    color: var(--pr-muted);
}

/* ============================================
   ALERTAS
   ============================================ */
.alert-success {
    background: #f0fdf4;
    color: #166534;
    border-color: #86efac;
}

.alert-error,
.alert-danger {
    background: #fef2f2;
    color: #991b1b;
    border-color: #fca5a5;
}

.alert-warning {
    background: #fffbeb;
    color: #92400e;
    border-color: #fcd34d;
}

.alert-info {
    background: #eff6ff;
    color: #1e40af;
    border-color: #93c5fd;
}

/* ============================================
   DROPDOWNS (Bootstrap override)
   ============================================ */
.dropdown-menu {
    border: 1px solid var(--pr-border);
    border-radius: 6px;
    padding: 0.4rem;
    box-shadow: var(--pr-shadow-md);
    min-width: 220px;
}

.dropdown-item {
    border-radius: 4px;
    padding: 0.5rem 0.85rem;
    font-size: 0.88rem;
    transition: all 0.15s;
}

.dropdown-item:hover {
    background: var(--pr-light);
    color: var(--pr-accent);
}

.dropdown-item:active,
.dropdown-item.active {
    background: var(--pr-accent);
    color: #fff;
}

/* ============================================
   PAGINAÇÃO (Bootstrap override)
   ============================================ */
.page-link {
    color: var(--pr-text);
    border-color: var(--pr-border);
}

.page-link:hover {
    color: var(--pr-accent);
    border-color: var(--pr-accent);
    background: var(--pr-light);
}

.page-item.active .page-link {
    background: var(--pr-accent);
    border-color: var(--pr-accent);
    color: #fff;
}

/* ============================================
   BADGES (Bootstrap override)
   ============================================ */
.badge.bg-success,
.badge.bg-primary {
    background: var(--pr-accent) !important;
}

/* ============================================
   TOGGLER (hamburger)
   ============================================ */
.navbar-toggler {
    border: none !important;
    padding: 0.4rem 0.5rem;
}

.navbar-toggler:focus {
    box-shadow: none !important;
}

/* ============================================
   MOBILE NAVBAR COLLAPSE
   ============================================ */
@media (max-width: 991px) {
    .navbar-collapse {
        padding-top: 0.75rem;
        margin-top: 0.5rem;
        border-top: 1px solid var(--pr-border);
    }
    
    .pr-navbar .nav-link {
        padding: 0.65rem 0.75rem !important;
        border-radius: 4px;
        border-bottom: none !important;
    }
    
    .pr-navbar .nav-link.active {
        background: var(--pr-light) !important;
        border-bottom: none !important;
    }
    
    .pr-navbar .nav-link:hover {
        background: var(--pr-light) !important;
    }
    
    .dropdown-menu {
        border: none;
        background: var(--pr-light);
        margin: 0.25rem 0 0.5rem 1rem !important;
        padding: 0.25rem;
        box-shadow: none;
    }
}

/* ============================================
   UTILITÁRIOS
   ============================================ */
.text-accent { color: var(--pr-accent) !important; }
.bg-accent { background: var(--pr-accent) !important; }
.border-accent { border-color: var(--pr-accent) !important; }

/* Hover lift effect */
.hover-lift {
    transition: transform 0.2s, box-shadow 0.2s;
}
.hover-lift:hover {
    transform: translateY(-3px);
    box-shadow: var(--pr-shadow-md);
}

/* ============================================
   RESPONSIVO
   ============================================ */
@media (max-width: 768px) {
    h1 { font-size: 1.6rem; }
    h2 { font-size: 1.35rem; }
    
    .form-box {
        margin: 2rem 1rem;
        padding: 1.75rem;
    }
}