/* MERRIWEATHER */
@font-face {
    font-family: 'Merriweather';
    font-style: italic;
    font-weight: 400;
    src: url('/static/fonts/merriweather-v33-latin-italic.woff2') format('woff2');
    font-display: swap;
}

body {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    min-height: 100vh;
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
}

/* --- Efeito Hover CTA --- */
#dynamic-cta-container a {
    text-decoration: none;
    display: inline-flex;
}
#dynamic-cta-container a:hover {
    transform: translateY(-4px);
    box-shadow: 0 15px 30px rgba(0,0,0,0.3);
}

/* Container flutuante no topo direito unificando Login e Idioma */
.top-right-bar {
    position: fixed;
    top: 20px;
    right: 20px;
    z-index: 9999;
    display: flex;
    align-items: center;
    gap: 15px;
}

.auth-widget {
    display: flex;
    align-items: center;
    gap: 10px;
    background: rgba(255, 255, 255, 0.1);
    padding: 10px 16px;
    border-radius: 12px;
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.2);
    color: white;
    font-size: 13px;
    font-weight: 600;
}

.auth-widget a {
    color: white;
    text-decoration: none;
    transition: opacity 0.3s;
}

.auth-widget a:hover {
    opacity: 0.8;
    text-decoration: underline;
}

.auth-btn-login {
    background: #ff7675;
    padding: 6px 12px;
    border-radius: 6px;
    cursor: pointer;
    border: none;
    color: white;
    font-weight: bold;
}

.auth-btn-login:hover {
    background: #d63031;
}

.language-selector {
    display: flex;
    gap: 12px;
    background: rgba(255, 255, 255, 0.1);
    padding: 10px 16px;
    border-radius: 12px;
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.2);
}



.language-btn {
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.3);
    font-size: 13px;
    cursor: pointer;
    transition: all 0.3s ease;
    opacity: 0.7;
    color: white;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 8px 14px;
    border-radius: 6px;
    font-weight: 600;
    min-width: 100px;
}

.language-btn img {
    width: 24px;
    height: 18px;
    border-radius: 3px;
    object-fit: cover;
}

.language-btn:hover {
    transform: scale(1.05);
    opacity: 0.9;
}

.language-btn.active {
    opacity: 1;
    transform: scale(1.05);
    background: rgba(255, 255, 255, 0.25);
    border: 1px solid rgba(255, 255, 255, 0.5);
    box-shadow: 0 0 15px rgba(255, 255, 255, 0.3);
}

.main-container {
    padding: 50px 20px;
}

.header {
    text-align: center;
    color: white;
    margin-bottom: 50px;
}

.header h1 {
    font-size: 3rem;
    font-weight: bold;
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.3);
    margin-bottom: 10px;
}

.header p {
    font-size: 1.2rem;
    opacity: 0.9;
}

.header-logo {
    width: 60px;
    height: 60px;
    object-fit: contain;
    filter: drop-shadow(2px 2px 4px rgba(0, 0, 0, 0.3));
}


.app-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 30px;
    max-width: 1200px;
    margin: 0 auto;
}

.app-card {
    background: white;
    border-radius: 15px;
    padding: 30px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.2);
    transition: all 0.3s ease;
    cursor: pointer;
    text-decoration: none;
    color: inherit;
    display: block;
    position: relative;
}

.app-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 15px 40px rgba(0, 0, 0, 0.3);
}

.app-icon {
    font-size: 3rem;
    margin-bottom: 20px;
    text-align: center;
}

.app-card.elo .app-icon {
    color: #667eea;
}

.app-card.music .app-icon {
    color: #f093fb;
}

.app-card.admin .app-icon {
    color: #4facfe;
}

.app-card.mud .app-icon {
    color: #43e97b;
}

.app-card.goat .app-icon {
    color: #FFD700;
}

.app-card.power .app-icon {
    color: #550000;
}

.app-card.contos .app-icon {
    color: #00A859;
}

.app-card.contos_de .app-icon {
    color: #4A470E;
}

.app-card.spotify .app-icon {
    color: #1db954;
}

.app-card.spotify .app-badge {
    background: rgba(29, 185, 84, 0.1);
    color: #1db954;
}

.app-title {
    font-size: 1.5rem;
    font-weight: bold;
    margin-bottom: 10px;
    text-align: center;
}

.app-description {
    color: #666;
    text-align: center;
    line-height: 1.6;
    margin-bottom: 15px;
}

.app-badge {
    display: inline-block;
    padding: 5px 15px;
    border-radius: 20px;
    font-size: 0.8rem;
    margin-top: 15px;
    font-weight: 600;
}

.app-card.elo .app-badge {
    background: rgba(102, 126, 234, 0.1);
    color: #667eea;
}

.app-card.music .app-badge {
    background: rgba(240, 147, 251, 0.1);
    color: #f093fb;
}

.app-card.admin .app-badge {
    background: rgba(79, 172, 254, 0.1);
    color: #4facfe;
}

.app-card.mud .app-badge {
    background: rgba(67, 233, 123, 0.1);
    color: #43e97b;
}

.app-card.goat .app-badge {
    background: rgba(255, 215, 0, 0.1);
    color: #FFD700;
}

.app-card.power .app-badge {
    background: rgba(202, 153, 171, 0.1);
    color: #550000;
}

.app-card.contos .app-badge {
    background: rgba(106, 163, 138, 0.1);
    color: #00A859;
}

.app-card.contos_de .app-badge {
    background: rgba(138, 135, 80, 0.1);
    color: #4A470E;
}

.language-badge {
    position: absolute;
    top: 10px;
    right: 10px;
    background: rgba(0, 0, 0, 0.15);
    color: white;
    padding: 6px 12px;
    border-radius: 12px;
    font-size: 0.75rem;
    font-weight: bold;
    text-align: center;
    display: flex;
    align-items: center;
    gap: 6px;
}

.language-badge img {
    width: 18px;
    height: 13px;
    border-radius: 2px;
    object-fit: cover;
}

.hidden {
    display: none;
}

/* Footer Copyright */
.footer-copyright {
    text-align: center;
    padding: 30px 20px;
    margin-top: 50px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 12px;
    backdrop-filter: blur(10px);
    color: white;
    font-size: 0.9rem;
}

.footer-copyright a {
    color: white;
    text-decoration: none;
    font-weight: 600;
    border-bottom: 2px solid rgba(255, 255, 255, 0.3);
    padding-bottom: 2px;
    transition: all 0.3s ease;
}

.footer-copyright a:hover {
    border-bottom-color: white;
}

/* Estilo para os novos cards especiais */
.special-card {
    background: white;
    border-radius: 15px;
    padding: 25px;
    box-shadow: 0 15px 35px rgba(0, 0, 0, 0.2);
    transition: all 0.4s ease;
    text-decoration: none;
    color: inherit;
    display: block;
    height: 100%;
}

.special-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.3);
}

.special-card h3 {
    color: #667eea;
    margin-bottom: 15px;
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 1.3rem;
}

.special-card p {
    color: #666;
    line-height: 1.6;
    font-size: 0.95rem;
    margin-bottom: 15px;
}

.link-list-item {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 10px;
    background: linear-gradient(135deg, rgba(102, 126, 234, 0.1), rgba(118, 75, 162, 0.1));
    border-radius: 8px;
    margin-bottom: 8px;
    transition: all 0.3s ease;
}

.link-list-item:hover {
    background: linear-gradient(135deg, rgba(102, 126, 234, 0.2), rgba(118, 75, 162, 0.2));
    transform: translateX(5px);
}

.link-list-item i {
    color: #667eea;
}

.link-list-item a {
    color: #333;
    text-decoration: none;
    font-weight: 600;
    flex: 1;
}

.link-list-item a:hover {
    color: #667eea;
}

.break-row {
    flex-basis: 100%;
    width: 100%;
    height: 0;
}

.grid-break {
    grid-column: 1 / -1;
}

.admin-row {
    grid-column: 1 / -1;
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 30px;
}

.text-center {
    text-align: center;
}

.nerd-citation {
    margin: 24px 0;
    text-align: center;
    font-size: 1.2rem;
    opacity: 0.85;
    font-style: italic;
    font-family: 'Merriweather', serif;
}

@media (max-width: 700px) {
    .admin-row {
        grid-template-columns: 1fr;
    }
}

/* --- News Ticker Ajustado --- */
.news-ticker {
    margin: 30px auto 0;
    max-width: 600px;
    background: rgba(0, 0, 0, 0.25);
    border: 1px solid rgba(255, 255, 255, 0.15);
    border-radius: 30px;
    padding: 10px 20px;
    display: flex;
    align-items: center;
    gap: 15px;
    overflow: hidden;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
}

/* Recuperando a cor do Badge original */
.news-badge {
    background: linear-gradient(135deg, #ff4757, #ff6b81);
    color: white;
    padding: 4px 12px;
    border-radius: 20px;
    font-size: 0.75rem;
    font-weight: bold;
    text-transform: uppercase;
    white-space: nowrap;
    box-shadow: 0 2px 8px rgba(255, 71, 87, 0.4);
    display: flex;
    align-items: center;
    gap: 5px;
}

#news-link {
    flex: 1;
    overflow: hidden;
    text-decoration: none;
    display: flex;
}

#news-text {
    color: white;
    font-size: 0.95rem;
    white-space: nowrap;
    display: inline-block;
    transition: opacity 0.5s ease;
}

/* Animação de ida sem volta (sem repetir o texto) */
.animate-marquee {
    animation: marquee-single 5s linear forwards;
    /* 5s para dar tempo de ler antes dos 6s totais */
}

@keyframes marquee-single {
    0% {
        transform: translateX(0);
    }

    100% {
        transform: translateX(calc(-100% + 400px));
    }
}

.fade-out {
    opacity: 0 !important;
}

/* --- Widget de Datas Nerds --- */
.nerd-calendar-widget {
    grid-column: 1 / -1;
    /* Ocupa a largura total no topo do grid */
    background: rgba(0, 0, 0, 0.4);
    border: 1px dashed rgba(255, 255, 255, 0.3);
    border-radius: 15px;
    padding: 15px 25px;
    margin-bottom: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 20px;
    color: #4facfe;
    /* Cor ciano/azul tecnológica */
    font-family: 'Courier New', Courier, monospace;
}

.calendar-date {
    font-size: 1.4rem;
    font-weight: bold;
    border-right: 2px solid rgba(79, 172, 254, 0.5);
    padding-right: 20px;
    color: white;
}

.calendar-event {
    font-size: 1.1rem;
    letter-spacing: 1px;
}

.calendar-icon {
    font-size: 1.5rem;
    animation: pulse 2s infinite;
}

@keyframes pulse {
    0% {
        opacity: 1;
    }

    50% {
        opacity: 0.4;
    }

    100% {
        opacity: 1;
    }
}

/* --- Badges do Calendário --- */
.cal-status-badge {
    padding: 2px 10px;
    border-radius: 10px;
    font-size: 0.7rem;
    text-transform: uppercase;
    font-weight: bold;
    margin-left: 10px;
}

.status-today {
    background: #ff4757;
    color: white;
    box-shadow: 0 0 10px rgba(255, 71, 87, 0.5);
    animation: pulse 1.5s infinite;
    /* Usa o pulse que você já tem */
}

.status-upcoming {
    background: rgba(255, 255, 255, 0.15);
    color: #4facfe;
    border: 1px solid rgba(79, 172, 254, 0.3);
}

/* --- Caixa de Introdução do Clube --- */
.intro-box {
    min-height: 300px;
    /* Mantém o espaço reservado antes do conteúdo carregar */
    display: flex;
    flex-direction: column;
    justify-content: center;
    max-width: 1000px;
    margin: 40px auto 50px auto;
    background: rgba(0, 0, 0, 0.25);
    border: 1px solid rgba(255, 255, 255, 0.15);
    border-radius: 20px;
    padding: 35px 45px;
    color: rgba(255, 255, 255, 0.95);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.2);
    backdrop-filter: blur(10px);
}

/* Força a exibição imediata do texto enquanto os ícones carregam */
i.fa,
i.fas,
i.fab,
i.far {
    font-display: swap !important;
}

.intro-box h2 {
    font-family: 'Merriweather', serif;
    color: #4facfe;
    margin-bottom: 25px;
    font-size: 1.8rem;
    letter-spacing: 1px;
    text-align: center;
    text-shadow: 1px 1px 3px rgba(0, 0, 0, 0.5);
}

.intro-box p {
    font-size: 1.05rem;
    line-height: 1.7;
    margin-bottom: 18px;
    text-align: justify;
}

.intro-box p:last-child {
    margin-bottom: 0;
    font-weight: 600;
    text-align: center;
    color: #f093fb;
    font-size: 1.15rem;
    margin-top: 25px;
}

@media (max-width: 700px) {
    .intro-box {
        padding: 25px 20px;
        margin: 30px 10px;
    }
}

/* --- Container de Recomendações (Scroll Automático) --- */
.recommendations-container {
    max-height: 220px;
    overflow-y: auto;
    padding-right: 8px;
    scroll-behavior: smooth;
}

.recommendations-container::-webkit-scrollbar {
    width: 6px;
}

.recommendations-container::-webkit-scrollbar-track {
    background: rgba(255, 255, 255, 0.05);
    border-radius: 10px;
}

.recommendations-container::-webkit-scrollbar-thumb {
    background: rgba(102, 126, 234, 0.4);
    border-radius: 10px;
}

.recommendations-container::-webkit-scrollbar-thumb:hover {
    background: rgba(102, 126, 234, 0.8);
}

/* --- Estilos do Banner de Cookies --- */
.cookie-banner {
    position: fixed;
    bottom: 0;
    left: 0;
    width: 100%;
    background-color: rgba(17, 24, 39, 0.95);
    border-top: 1px solid rgba(168, 85, 247, 0.5);
    padding: 15px 20px;
    box-shadow: 0 -5px 20px rgba(0, 0, 0, 0.5);
    z-index: 9999;
    backdrop-filter: blur(10px);
    color: #d1d5db;
}

.cookie-banner.hidden {
    display: none;
}

.cookie-content {
    max-width: 1200px;
    margin: 0 auto;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: space-between;
    gap: 15px;
}

@media (min-width: 768px) {
    .cookie-content {
        flex-direction: row;
    }
}

.cookie-content p {
    margin: 0;
    font-size: 0.9rem;
    line-height: 1.5;
}

.cookie-content i {
    color: #a855f7;
    margin-right: 8px;
    font-size: 1.2rem;
}

.cookie-content a {
    color: #a855f7;
    text-decoration: underline;
    transition: color 0.3s;
}

.cookie-content a:hover {
    color: #d8b4fe;
}

.cookie-banner button {
    background-color: #9333ea;
    color: white;
    border: none;
    padding: 10px 25px;
    border-radius: 50px;
    font-weight: bold;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 4px 15px rgba(168, 85, 247, 0.4);
    white-space: nowrap;
}

.cookie-banner button:hover {
    background-color: #7e22ce;
    transform: scale(1.05);
}