:root {
    --primary: #1a237e; 
    --secondary: #2e7d32; 
    --bg: #f4f7f6;
    --card: #ffffff; 
    --text-main: #1c1c1c; 
    --text-muted: #575757;
    --radius: 18px;
    --whatsapp: #25d366;
    --accent-fire: #e65100;
}

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

body { 
    font-family: system-ui, -apple-system, sans-serif; 
    background-color: var(--bg); 
    color: var(--text-main); 
    line-height: 1.4; 
    transition: background-color 0.3s; 
    padding-top: 70px !important; 
}

body.dark-mode { 
    --bg: #121212; 
    --card: #1e1e1e; 
    --text-main: #f0f0f0; 
    --text-muted: #b5b5b5; 
}

/* Acessibilidade */
.sr-only {
    position: absolute; 
    width: 1px; 
    height: 1px; 
    padding: 0; 
    margin: -1px;
    overflow: hidden; 
    clip: rect(0, 0, 0, 0); 
    border: 0;
}

/* Utilitários */
.h-full { height: 100%; }
.mb-0 { margin-bottom: 0 !important; }
.mb-25 { margin-bottom: 25px; }
.w-45 { width: 45%; }
.w-60 { width: 60%; }
.w-85 { width: 85%; }
.w-90 { width: 90%; }
.pointer-events-none { pointer-events: none; }
.icon-fire { color: var(--accent-fire); }

main { 
    max-width: 900px; 
    margin: 0 auto; 
    padding-bottom: 60px; 
}

.section-title { 
    padding: 20px 15px 10px; 
    font-size: 0.85rem; 
    font-weight: 800; 
    text-transform: uppercase; 
    color: var(--primary); 
    display: flex; 
    align-items: center; 
    gap: 10px; 
}

/* ALTERADO PARA #6670D9 */
body.dark-mode .section-title {
    color: #6670D9;
}

.section-title::after { 
    content: ""; 
    flex: 1; 
    height: 1px; 
    background: rgba(0,0,0,0.08); 
}

/* Correção para a linha no Modo Escuro */
body.dark-mode .section-title::after {
    background: rgba(255, 255, 255, 0.1);
}

/* Carrossel Destaques */
.carousel-wrapper { 
    padding: 0 15px; 
    margin-bottom: 20px; 
}

.carousel-container { 
    position: relative; 
    width: 100%; 
    aspect-ratio: 3 / 2; 
    background: var(--card); 
    border-radius: var(--radius); 
    overflow: hidden; 
}

.carousel-slide { 
    position: absolute; 
    inset: 0; 
    opacity: 0; 
    transition: opacity 0.6s ease; 
    cursor: pointer; 
    z-index: 1; 
    overflow: hidden;
}

.carousel-slide.active { 
    opacity: 1; 
    z-index: 2; 
}

.carousel-slide img { 
    width: 100%; 
    height: 100%; 
    object-fit: cover; 
    display: block;
}

.carousel-overlay { 
    position: absolute; 
    bottom: 0; 
    left: 0; 
    right: 0; 
    padding: 35px 15px 25px; 
    background: linear-gradient(transparent, rgba(0,0,0,0.88)); 
    color: white; 
    z-index: 3; 
}

.carousel-overlay h3 { 
    font-weight: 700; 
    line-height: 1.25;
    margin-top: 4px;
    word-wrap: break-word;
    display: -webkit-box;
    -webkit-line-clamp: 3; 
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.carousel-overlay h3.font-lg { font-size: clamp(1.1rem, 2.5vw, 1.35rem); }
.carousel-overlay h3.font-md { font-size: clamp(0.95rem, 2vw, 1.15rem); }
.carousel-overlay h3.font-sm { font-size: clamp(0.8rem, 1.7vw, 0.95rem); }

.carousel-dots {
    position: absolute;
    bottom: 10px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    align-items: center;
    gap: 6px;
    z-index: 10;
}

.carousel-dot {
    width: 7px;
    height: 7px;
    background-color: rgba(255, 255, 255, 0.4);
    border-radius: 50%;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    cursor: pointer;
}

.carousel-dot.active {
    width: 20px;
    border-radius: 10px;
    background-color: #ffcc00; 
}

.badge-destaque { 
    background: var(--secondary); 
    color: #fff; 
    padding: 2px 8px; 
    font-size: 8px; 
    font-weight: 800; 
    text-transform: uppercase; 
    border-radius: 4px; 
    margin-bottom: 6px; 
    display: inline-block; 
}

.nav-btn { 
    position: absolute; 
    top: 50%; 
    transform: translateY(-50%); 
    width: 32px; 
    height: 32px; 
    background: rgba(0,0,0,0.4); 
    border: none; 
    color: white; 
    border-radius: 50%; 
    z-index: 10; 
    cursor: pointer; 
    font-size: 10px; 
    display: flex; 
    align-items: center; 
    justify-content: center; 
}

#prev-btn { left: 10px; } 
#next-btn { right: 10px; }

/* Cards & Feeds */
.feed-container { 
    display: grid; 
    grid-template-columns: 1fr; 
    gap: 12px; 
    padding: 0 15px; 
}

@media (min-width: 768px) { 
    .feed-container { grid-template-columns: 1fr 1fr; } 
}

.news-card { 
    display: flex; 
    background: var(--card); 
    padding: 10px; 
    border-radius: 14px; 
    box-shadow: 0 2px 8px rgba(0,0,0,0.04); 
    cursor: pointer; 
    border: 1px solid transparent; 
    transition: border-color 0.2s; 
    align-items: center;
    overflow: hidden;
    text-decoration: none;
    color: inherit;
}

.news-card:hover { border-color: var(--secondary); }

.news-card img { 
    width: 95px; 
    height: 65px; 
    aspect-ratio: 3 / 2;
    object-fit: cover; 
    border-radius: 10px; 
    flex-shrink: 0; 
    display: block;
    overflow: hidden;
}

.news-content { 
    margin-left: 12px; 
    display: flex; 
    flex-direction: column; 
    justify-content: center; 
    width: 100%; 
}

.news-content h3 { 
    font-size: 0.95rem; 
    font-weight: 500; 
    margin-bottom: 4px; 
    line-height: 1.2; 
}

.news-meta { 
    font-size: 11px; 
    color: var(--text-muted); 
    display: flex; 
    align-items: center; 
    gap: 8px; 
}

.news-meta .author { 
    font-weight: 600; 
    color: var(--secondary); 
}

.news-meta .dot { 
    width: 3px; 
    height: 3px; 
    background: #ccc; 
    border-radius: 50%; 
}

/* Banners Call-to-Action */
.mid-section-community,
.mid-section-collab {
    margin: 15px 15px 20px;
    background: var(--card);
    padding: 14px 16px;
    border-radius: 14px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    text-decoration: none;
    color: inherit;
    border: 1px solid rgba(0, 0, 0, 0.06);
    box-shadow: 0 2px 6px rgba(0,0,0,0.02);
    transition: transform 0.2s, border-color 0.2s, box-shadow 0.2s;
    gap: 12px;
}

body.dark-mode .mid-section-community,
body.dark-mode .mid-section-collab {
    border-color: rgba(255, 255, 255, 0.08);
}

.mid-section-community:hover {
    border-color: #25d366;
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(37, 211, 102, 0.12);
}

.mid-section-collab:hover {
    border-color: var(--primary);
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(26, 35, 126, 0.12);
}

.community-info,
.collab-info {
    display: flex;
    align-items: center;
    gap: 12px;
    flex: 1;
    min-width: 0;
}

.community-icon-box,
.collab-icon-box {
    width: 38px;
    height: 38px;
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    font-size: 1.1rem;
}

.community-icon-box {
    background: rgba(37, 211, 102, 0.1);
    color: #25d366;
}

.collab-icon-box {
    background: rgba(26, 35, 126, 0.08);
    color: var(--primary);
}

body.dark-mode .community-icon-box {
    background: rgba(37, 211, 102, 0.15);
}

/* ALTERADO PARA #6670D9 */
body.dark-mode .collab-icon-box {
    background: rgba(102, 112, 217, 0.15);
    color: #6670D9;
}

.community-text-details,
.collab-text-details {
    display: flex;
    flex-direction: column;
    min-width: 0;
}

.community-title,
.collab-title {
    font-size: 0.88rem;
    font-weight: 700;
    color: var(--text-main);
    line-height: 1.25;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.community-sub,
.collab-sub {
    font-size: 0.75rem;
    color: var(--text-muted);
    margin-top: 2px;
    line-height: 1.2;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.community-btn-action,
.collab-btn-action {
    font-size: 0.72rem;
    font-weight: 800;
    text-transform: uppercase;
    display: inline-flex;
    align-items: center;
    gap: 4px;
    flex-shrink: 0;
    letter-spacing: 0.3px;
}

.community-btn-action { color: #25d366; }
.collab-btn-action { color: var(--primary); }

/* ALTERADO PARA #6670D9 */
body.dark-mode .collab-btn-action { color: #6670D9; }

/* Paginação com números */
.pagination-container { 
    display: flex; 
    justify-content: center; 
    align-items: center; 
    gap: 8px; 
    margin-top: 35px; 
}

.page-numbers-group {
    display: flex;
    gap: 6px;
    align-items: center;
}

.page-btn { 
    background: var(--card); 
    border: 1px solid rgba(0,0,0,0.1); 
    color: var(--text-main); 
    min-width: 36px; 
    height: 36px; 
    padding: 0 8px;
    border-radius: 10px; 
    cursor: pointer; 
    transition: all 0.2s ease; 
    display: flex; 
    align-items: center; 
    justify-content: center; 
    font-size: 13px; 
    font-weight: 600;
}

body.dark-mode .page-btn {
    border-color: rgba(255,255,255,0.1);
}

.page-btn:hover:not(:disabled) { 
    border-color: var(--primary); 
    color: var(--primary); 
    transform: translateY(-1px);
}

/* ALTERADO PARA #6670D9 */
body.dark-mode .page-btn:hover:not(:disabled) {
    border-color: #6670D9;
    color: #6670D9;
}

.page-btn.active {
    background-color: var(--primary);
    color: #ffffff !important;
    border-color: var(--primary);
    font-weight: 800;
}

/* ALTERADO PARA #6670D9 */
body.dark-mode .page-btn.active {
    background-color: #6670D9;
    color: #121212 !important;
    border-color: #6670D9;
}

.page-btn:disabled { 
    opacity: 0.3; 
    cursor: default; 
    transform: none;
}

/* Skeleton Shimmer Loading */
.shimmer { 
    background: linear-gradient(90deg, #e0e0e0 25%, #ecebeb 50%, #e0e0e0 75%); 
    background-size: 200% 100%; 
    animation: loading-shimmer 1.5s infinite; 
}

body.dark-mode .shimmer { 
    background: linear-gradient(90deg, #252525 25%, #333333 50%, #252525 75%); 
    background-size: 200% 100%; 
}

@keyframes loading-shimmer { 
    0% { background-position: 200% 0; } 
    100% { background-position: -200% 0; } 
}

.skeleton-text { height: 12px; border-radius: 6px; margin-bottom: 8px; }
.skeleton-overlay { background: linear-gradient(transparent, rgba(0,0,0,0.6)); }
.sk-badge { width: 30%; height: 12px; margin-bottom: 10px; }
.sk-title { width: 80%; height: 20px; }
.sk-thumb { width: 95px; height: 65px; border-radius: 10px; flex-shrink: 0; }

/* Seção: Últimas Atualizações de Frota */
.fleet-section-wrapper {
    max-width: 900px;
    margin: 15px auto 20px;
    padding: 0 15px;
}

.fleet-section-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 12px;
    gap: 10px;
    flex-wrap: nowrap;
}

.fleet-section-title {
    font-size: 0.8rem;
    font-weight: 800;
    text-transform: uppercase;
    color: var(--primary);
    display: flex;
    align-items: center;
    gap: 6px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

/* ALTERADO PARA #6670D9 */
body.dark-mode .fleet-section-title {
    color: #6670D9;
}

.fleet-header-link {
    font-size: 0.72rem;
    font-weight: 800;
    color: var(--secondary);
    text-decoration: none;
    text-transform: uppercase;
    display: inline-flex;
    align-items: center;
    gap: 4px;
    white-space: nowrap;
    flex-shrink: 0;
    transition: opacity 0.2s;
}

.fleet-header-link:hover {
    opacity: 0.8;
}

/* Carrossel Discreto de Frotas */
.fleet-carousel-container {
    width: 100%;
    overflow-x: auto;
    overflow-y: hidden;
    scroll-behavior: smooth;
    -webkit-overflow-scrolling: touch;
    padding-bottom: 8px;
}

.fleet-carousel-container::-webkit-scrollbar {
    height: 4px;
}

.fleet-carousel-container::-webkit-scrollbar-track {
    background: rgba(0, 0, 0, 0.03);
    border-radius: 4px;
}

body.dark-mode .fleet-carousel-container::-webkit-scrollbar-track {
    background: rgba(255, 255, 255, 0.03);
}

.fleet-carousel-container::-webkit-scrollbar-thumb {
    background: rgba(0, 0, 0, 0.15);
    border-radius: 4px;
}

body.dark-mode .fleet-carousel-container::-webkit-scrollbar-thumb {
    background: rgba(255, 255, 255, 0.15);
}

.fleet-carousel-track {
    display: flex;
    gap: 12px;
}

/* Card da Aeronave */
.fleet-item-card {
    flex: 0 0 220px;
    background: var(--card);
    border-radius: 14px;
    overflow: hidden;
    border: 1px solid rgba(0, 0, 0, 0.06);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.04);
    text-decoration: none;
    color: inherit;
    transition: transform 0.2s, border-color 0.2s, box-shadow 0.2s;
    display: flex;
    flex-direction: column;
}

body.dark-mode .fleet-item-card {
    border-color: rgba(255, 255, 255, 0.08);
}

.fleet-item-card:hover {
    transform: translateY(-2px);
    border-color: var(--primary);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
}

.fleet-card-media {
    position: relative;
    width: 100%;
    aspect-ratio: 16 / 9;
    background-color: #0f172a;
    overflow: hidden;
}

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

.fleet-spotter-credit {
    position: absolute;
    bottom: 5px;
    right: 7px;
    color: #ffffff;
    font-size: 9px;
    font-weight: 500;
    text-shadow: 0 1px 3px rgba(0, 0, 0, 0.9);
    pointer-events: none;
    z-index: 2;
    opacity: 0.9;
}

.fleet-card-content {
    padding: 10px 12px;
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.fleet-card-top {
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.fleet-reg {
    font-weight: 800;
    font-size: 0.88rem;
    color: var(--primary);
    letter-spacing: 0.5px;
}

/* ALTERADO PARA #6670D9 */
body.dark-mode .fleet-reg {
    color: #6670D9;
}

.fleet-status-badge {
    font-size: 9px;
    font-weight: 700;
    padding: 2px 6px;
    border-radius: 4px;
    text-transform: uppercase;
    white-space: nowrap;
}

.fleet-status-badge.status-ativa {
    background: rgba(30, 58, 138, 0.1);
    color: #1e3a8a;
}

/* ALTERADO PARA #6670D9 */
body.dark-mode .fleet-status-badge.status-ativa {
    background: rgba(102, 112, 217, 0.15);
    color: #6670D9;
}

.fleet-status-badge.status-estocada {
    background: rgba(239, 68, 68, 0.1);
    color: #ef4444;
}

.fleet-status-badge.status-manutencao {
    background: rgba(245, 158, 11, 0.1);
    color: #f59e0b;
}

.fleet-card-body {
    display: flex;
    flex-direction: column;
    gap: 1px;
}

.fleet-model {
    font-size: 0.78rem;
    font-weight: 600;
    color: var(--text-main);
    line-height: 1.2;
}

.fleet-operator {
    font-size: 0.72rem;
    color: var(--text-muted);
}

.fleet-card-skeleton {
    flex: 0 0 220px;
    height: 185px;
    border-radius: 14px;
}

.fleet-empty-state {
    width: 100%;
    text-align: center;
    padding: 20px;
    color: var(--text-muted);
    font-size: 0.85rem;
    background: var(--card);
    border-radius: 14px;
}
