html {
  font-size: 14px;
}

@media (min-width: 768px) {
  html {
    font-size: 16px;
  }
}

.btn:focus, .btn:active:focus, .btn-link.nav-link:focus, .form-control:focus, .form-check-input:focus {
  box-shadow: 0 0 0 0.1rem white, 0 0 0 0.25rem #258cfb;
}

html {
  position: relative;
  min-height: 100%;
}

body {
  margin-bottom: 60px;
}

/* Links básicos */
a {
    text-decoration: none;
}

a:hover {
    text-decoration: underline;
}

/* ===== ESTILOS MODERNOS PARA O MENU ===== */

/* Navbar moderna com gradiente */
.modern-navbar {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    box-shadow: 0 2px 20px rgba(0,0,0,0.1);
    padding: 0.8rem 0;
    border: none;
}

/* Brand/Logo estilizado */
.navbar-brand {
    font-weight: 700;
    font-size: 1.8rem;
    color: white !important;
    text-shadow: 0 2px 4px rgba(0,0,0,0.3);
}

/* Links do menu principal */
.navbar-nav .nav-link {
    color: rgba(255, 255, 255, 0.9) !important;
    font-weight: 500;
    padding: 0.75rem 1.25rem !important;
    border-radius: 8px;
    margin: 0 0.25rem;
    transition: all 0.3s ease;
    position: relative;
}

/* Efeitos hover nos links */
.navbar-nav .nav-link:hover,
.navbar-nav .nav-link:focus {
    color: white !important;
    background-color: rgba(255, 255, 255, 0.1);
    transform: translateY(-2px);
    text-decoration: none;
}

/* Linha indicadora nos links */
.navbar-nav .nav-link::after {
    content: '';
    position: absolute;
    width: 0;
    height: 2px;
    bottom: 0;
    left: 50%;
    background-color: #ffd700;
    transition: all 0.3s ease;
}

.navbar-nav .nav-link:hover::after {
    width: 80%;
    left: 10%;
}

/* Dropdown menu estilizado */
.dropdown-menu {
    border: none;
    border-radius: 12px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.15);
    padding: 0.5rem 0;
    margin-top: 0.5rem;
    background: white;
}

/* Itens do dropdown */
.dropdown-item {
    padding: 0.75rem 1.5rem;
    font-weight: 500;
    color: #495057;
    border-radius: 0;
    transition: all 0.3s ease;
}

.dropdown-item:hover {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    transform: translateX(5px);
}

.dropdown-item i {
    margin-right: 0.75rem;
    width: 18px;
}

/* Botão toggle para mobile */
.navbar-toggler {
    border: none;
    padding: 0.5rem;
    border-radius: 8px;
}

.navbar-toggler:focus {
    box-shadow: none;
}

.navbar-toggler-icon {
    background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 30 30'%3e%3cpath stroke='rgba%28255, 255, 255, 0.85%29' stroke-linecap='round' stroke-miterlimit='10' stroke-width='2' d='M4 7h22M4 15h22M4 23h22'/%3e%3c/svg%3e");
}

/* Container principal com margem aprimorada */
.main-container {
    margin-top: 2rem;
}

/* Footer moderno */
.modern-footer {
    background: #343a40;
    color: #adb5bd;
    padding: 2rem 0 1rem;
    margin-top: 3rem;
}

.modern-footer a {
    color: #ffd700;
    text-decoration: none;
}

.modern-footer a:hover {
    color: #ffed4e;
    text-decoration: none;
}

/* ===== RESPONSIVIDADE ===== */
@media (max-width: 991.98px) {
    .navbar-nav .nav-link {
        padding: 0.5rem 1rem !important;
        margin: 0.25rem 0;
    }
    
    .dropdown-menu {
        margin-top: 0;
        border-radius: 8px;
    }
}

/* ===== ANIMAÇÕES PARA DROPDOWNS ===== */
.dropdown-menu {
    opacity: 0;
    transform: translateY(-10px);
    transition: all 0.3s ease;
    display: block;
    visibility: hidden;
}

.dropdown:hover .dropdown-menu,
.dropdown.show .dropdown-menu {
    opacity: 1;
    transform: translateY(0);
    visibility: visible;
}

/* ===== UTILITÁRIOS GERAIS ===== */
.text-shadow {
    text-shadow: 0 1px 3px rgba(0,0,0,0.3);
}

.box-shadow-sm {
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

.gradient-bg {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
}

/* Melhorar aparência dos botões */
.btn-modern {
    border-radius: 8px;
    font-weight: 500;
    padding: 0.5rem 1.5rem;
    transition: all 0.3s ease;
}

.btn-modern:hover {
    transform: translateY(-1px);
    box-shadow: 0 4px 8px rgba(0,0,0,0.15);
}

/* ADICIONADO PARA SUPORTE A DROPEND */
.dropend:hover > .dropdown-menu {
    display: block;
}

.dropend .dropdown-menu {
    top: 0;
    left: 100%;
    margin-left: 0.125rem;
}

/* ADICIONAR - Suporte para múltiplos níveis de dropdown */
.dropend .dropend .dropdown-menu {
    top: 0;
    left: 100%;
    margin-left: 0.125rem;
}

.dropend .dropend:hover > .dropdown-menu {
    display: block;
}

/* Ajustar z-index para evitar sobreposição */
.dropdown-menu .dropdown-menu {
    z-index: 1060;
}

/* ADICIONAR - Melhorar hover para submenus de terceiro nível */
.dropend .dropend:hover > .dropdown-menu {
    display: block !important;
    opacity: 1;
    transform: translateY(0);
    visibility: visible;
}

.dropend .dropend .dropdown-menu {
    top: 0;
    left: 100%;
    margin-left: 0.125rem;
    opacity: 0;
    transform: translateY(-10px);
    transition: all 0.3s ease;
    visibility: hidden;
}

/* Garantir que o hover funcione em todos os níveis */
.dropdown-item.dropdown-toggle:hover + .dropdown-menu,
.dropend:hover > .dropdown-menu {
    display: block !important;
    opacity: 1;
    transform: translateY(0);
    visibility: visible;
}
