body {
    font-family: 'Arial', sans-serif;
    margin: 0;
    padding: 0;
    background-color: #f8f9fa;
}

body.theme-light {
    background: #fff;
    color: #222;
}

body.theme-darkred {
    background: #2d0101;
    color: #fff;
}

body.theme-dark {
    background: #181818;
    color: #fff;
}

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

.header {
    background-color: #a30000;
    color: white;
    padding: 20px;
    text-align: center;
}

.navbar {
    display: flex;
    justify-content: center;
    background-color: #343a40;
}

.navbar a {
    color: white;
    padding: 14px 20px;
    text-decoration: none;
    text-align: center;
}

.navbar a:hover {
    background-color: #495057;
}

.custom-navbar {
    background: rgba(0,0,0,0.08) !important;
    backdrop-filter: blur(8px);
    box-shadow: 0 2px 16px 0 rgba(139,0,0,0.08);
    transition: background 0.4s, box-shadow 0.4s;
}

.custom-navbar .navbar-brand {
    letter-spacing: 2px;
    font-size: 1.5rem;
}

.custom-navbar .nav-link {
    font-size: 1.1rem;
    margin: 0 0.5rem;
    transition: color 0.2s;
}

.custom-navbar .nav-link:hover {
    color: #ffc107 !important;
}

.custom-navbar.scrolled {
    background: #fff !important;
    box-shadow: 0 2px 16px 0 rgba(139,0,0,0.08);
}

.custom-navbar.scrolled .nav-link,
.custom-navbar.scrolled .navbar-brand {
    color: #a30000 !important;
    transition: color 0.3s;
}

@media (max-width: 991.98px) {
  .custom-navbar.scrolled {
    background: #fff !important;
  }
  .custom-navbar.scrolled .nav-link,
  .custom-navbar.scrolled .navbar-brand {
    color: #a30000 !important;
  }
  .custom-navbar .navbar-toggler {
    border-color: #a30000;
  }
  .custom-navbar.scrolled .navbar-toggler-icon {
    background-image: url("data:image/svg+xml;charset=utf8,%3Csvg viewBox='0 0 30 30' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath stroke='rgba(163,0,0,1)' stroke-width='2' stroke-linecap='round' stroke-miterlimit='10' d='M4 7h22M4 15h22M4 23h22'/%3E%3C/svg%3E");
  }
}

.main-content {
    padding: 20px;
}

.footer {
    background-color: #343a40;
    color: white;
    text-align: center;
    padding: 10px;
    position: relative;
    bottom: 0;
    width: 100%;
}

.btn-primary {
    background-color: #007bff;
    border: none;
}

.btn-primary:hover {
    background-color: #0056b3;
}

.card {
    border: 1px solid #dee2e6;
    border-radius: 0.25rem;
    margin-bottom: 20px;
}

.card-header {
    background-color: #a30000;
    color: white;
}

.card-body {
    padding: 15px;
}

.theme-toggle {
    border-radius: 20px;
    font-weight: 600;
    box-shadow: 0 1px 4px rgba(0,0,0,0.08);
    transition: background 0.2s, color 0.2s;
}

.banner-olimpico .container {
    background: rgba(0,0,0,0.25);
    border-radius: 18px;
    padding: 2rem 1rem;
}

.animated-pulse {
    animation: pulse 1.5s infinite;
}

@keyframes pulse {
    0% { box-shadow: 0 0 0 0 rgba(220,53,69,0.5); }
    70% { box-shadow: 0 0 0 12px rgba(220,53,69,0); }
    100% { box-shadow: 0 0 0 0 rgba(220,53,69,0); }
}

.btn-danger {
    background: #a30000;
    border: none;
}

.btn-danger:hover, .btn-danger:focus {
    background: #8B0000;
    color: #fff;
}

.carousel-control-next-icon,
.carousel-control-prev-icon {
    filter: invert(18%) sepia(99%) saturate(7492%) hue-rotate(356deg) brightness(90%) contrast(119%);
}

#sobre {
    background: #fff;
    border-radius: 24px;
    box-shadow: 0 4px 32px 0 rgba(139,0,0,0.08);
    margin-bottom: 2rem;
}

.sobre-navbar {
    background: #a30000 !important;
}

.sobre-navbar .nav-link,
.sobre-navbar .navbar-brand {
    color: #fff !important;
}

.sobre-navbar .nav-link.active,
.sobre-navbar .nav-link:focus,
.sobre-navbar .nav-link:hover {
    color: #fff !important;
    background: rgba(255,255,255,0.08);
}

.banner-index {
    width: 100%;
    text-align: center;
    background: #f8f9fa;
    padding: 32px 0 24px 0;
    margin-bottom: 30px;
    border-radius: 0 0 16px 16px;
    box-shadow: 0 2px 12px #0001;
    position: relative;
}
.banner-img {
    max-width: 90vw;
    max-height: 320px;
    border-radius: 12px;
    box-shadow: 0 2px 12px #bbb;
    margin-bottom: 18px;
}
.banner-frase {
    font-size: 2.1rem;
    color: #222;
    font-weight: bold;
    text-shadow: 0 2px 8px #fff8;
    margin-top: 8px;
}

/* Estilos de Acessibilidade */

/* Link para pular para o conteúdo principal */
.sr-only-focusable:focus {
    position: absolute;
    top: 0;
    left: 0;
    z-index: 9999;
    width: auto;
    height: auto;
    padding: 8px 16px;
    margin: 0;
    font-size: 16px;
    font-weight: bold;
    color: #fff;
    background: #a30000;
    text-decoration: none;
    border-radius: 0 0 4px 0;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.3);
}

/* Melhor contraste para links */
a {
    color: #a30000;
    text-decoration: underline;
}

a:hover, a:focus {
    color: #7a0000;
    text-decoration: underline;
}

/* Foco visível para elementos interativos */
button:focus,
.btn:focus,
input:focus,
textarea:focus,
select:focus,
a:focus {
    outline: 2px solid #a30000;
    outline-offset: 2px;
    box-shadow: 0 0 0 3px rgba(163, 0, 0, 0.3);
}

/* Melhor contraste para textos */
.text-secondary {
    color: #495057 !important;
}

/* Validação de formulários */
.form-control.is-invalid {
    border-color: #dc3545;
    box-shadow: 0 0 0 0.2rem rgba(220, 53, 69, 0.25);
}

.form-control.is-valid {
    border-color: #28a745;
    box-shadow: 0 0 0 0.2rem rgba(40, 167, 69, 0.25);
}

.invalid-feedback {
    display: block;
    width: 100%;
    margin-top: 0.25rem;
    font-size: 0.875em;
    color: #dc3545;
}

.valid-feedback {
    display: block;
    width: 100%;
    margin-top: 0.25rem;
    font-size: 0.875em;
    color: #28a745;
}

/* Melhor contraste para modais */
.modal-content {
    border: 1px solid #dee2e6;
    border-radius: 0.5rem;
    box-shadow: 0 0.5rem 1rem rgba(0, 0, 0, 0.15);
}

.modal-header {
    border-bottom: 1px solid #dee2e6;
}

.modal-footer {
    border-top: 1px solid #dee2e6;
}

/* Melhor contraste para cards */
.card {
    border: 1px solid rgba(0, 0, 0, 0.125);
    box-shadow: 0 0.125rem 0.25rem rgba(0, 0, 0, 0.075);
}

/* Indicadores de status para leitores de tela */
.sr-only {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}

/* Melhor contraste para badges */
.badge {
    font-size: 0.875em;
    font-weight: 600;
    padding: 0.375rem 0.75rem;
}

/* Estados de hover e focus mais visíveis */
.btn:hover,
.btn:focus {
    transform: translateY(-1px);
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
}

/* Melhoria na navegação por teclado */
.navbar-nav .nav-link:focus,
.navbar-nav .dropdown-toggle:focus {
    background-color: rgba(255, 255, 255, 0.1);
    border-radius: 4px;
}

/* Contraste melhorado para dropdown */
.dropdown-menu {
    border: 1px solid rgba(0, 0, 0, 0.15);
    box-shadow: 0 0.5rem 1rem rgba(0, 0, 0, 0.175);
}

.dropdown-item:hover,
.dropdown-item:focus {
    background-color: #f8f9fa;
    color: #a30000;
}

/* Melhor visibilidade para tabelas */
.table th,
.table td {
    border-top: 1px solid #dee2e6;
    padding: 0.75rem;
    vertical-align: top;
}

.table thead th {
    border-bottom: 2px solid #dee2e6;
    vertical-align: bottom;
}

/* Responsividade melhorada */
@media (max-width: 768px) {
    .sr-only-focusable:focus {
        font-size: 14px;
        padding: 6px 12px;
    }
    
    button:focus,
    .btn:focus,
    input:focus,
    textarea:focus,
    select:focus,
    a:focus {
        outline-width: 3px;
    }
}

/* Alto contraste para usuários que preferem */
@media (prefers-contrast: high) {
    body {
        background: #fff;
        color: #000;
    }
    
    .text-secondary {
        color: #000 !important;
    }
    
    .card {
        border: 2px solid #000;
    }
    
    .btn {
        border: 2px solid #000;
    }
}

/* Redução de movimento para usuários sensíveis */
@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
}

/* Melhor contraste para elementos importantes */
.text-danger {
    color: #dc3545 !important;
}

.text-success {
    color: #28a745 !important;
}

.text-warning {
    color: #ffc107 !important;
    background-color: #000;
    padding: 2px 4px;
    border-radius: 2px;
}

/* Foco melhorado para carrossel */
.carousel-control-prev:focus,
.carousel-control-next:focus {
    outline: 2px solid #fff;
    outline-offset: -2px;
}

/* Melhor contraste para alertas */
.alert {
    border: 1px solid transparent;
    border-radius: 0.375rem;
    padding: 0.75rem 1.25rem;
    margin-bottom: 1rem;
}

.alert-success {
    color: #155724;
    background-color: #d4edda;
    border-color: #c3e6cb;
}

.alert-danger {
    color: #721c24;
    background-color: #f8d7da;
    border-color: #f5c6cb;
}

.alert-warning {
    color: #856404;
    background-color: #fff3cd;
    border-color: #ffeaa7;
}

.alert-info {
    color: #0c5460;
    background-color: #d1ecf1;
    border-color: #bee5eb;
}