/* ========================================
   Estilos Customizados - Tutorial ESP32
   Professor Reginaldo
   ======================================== */

/* Scrollbar customizada */
::-webkit-scrollbar {
    width: 8px;
    height: 8px;
}

::-webkit-scrollbar-track {
    background: #1e293b;
}

::-webkit-scrollbar-thumb {
    background: #475569;
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: #64748b;
}

/* Animações */
@keyframes float {
    0%, 100% { transform: translateY(0px); }
    50% { transform: translateY(-10px); }
}

@keyframes pulse-glow {
    0%, 100% { box-shadow: 0 0 20px rgba(6, 182, 212, 0.3); }
    50% { box-shadow: 0 0 40px rgba(6, 182, 212, 0.6); }
}

@keyframes fade-in {
    from { opacity: 0; transform: translateY(20px); }
    to { opacity: 1; transform: translateY(0); }
}

.animate-float {
    animation: float 3s ease-in-out infinite;
}

.animate-pulse-glow {
    animation: pulse-glow 2s ease-in-out infinite;
}

.animate-fade-in {
    animation: fade-in 0.6s ease-out forwards;
}

/* Glassmorphism */
.glass {
    background: rgba(30, 41, 59, 0.7);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.glass-card {
    background: rgba(51, 65, 85, 0.5);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    border: 1px solid rgba(255, 255, 255, 0.08);
    transition: all 0.3s ease;
}

.glass-card:hover {
    background: rgba(71, 85, 105, 0.6);
    border-color: rgba(6, 182, 212, 0.3);
    transform: translateY(-5px);
}

/* Código */
.code-block {
    background: #0f172a;
    border: 1px solid #334155;
    border-radius: 8px;
    overflow: hidden;
}

.code-header {
    background: #1e293b;
    padding: 8px 16px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-bottom: 1px solid #334155;
}

.code-content {
    padding: 16px;
    overflow-x: auto;
    font-family: 'Fira Code', 'Monaco', 'Consolas', monospace;
    font-size: 14px;
    line-height: 1.6;
}

/* Botão de Copiar */
.copy-btn {
    background: #334155;
    color: #94a3b8;
    padding: 6px 12px;
    border-radius: 6px;
    font-size: 12px;
    cursor: pointer;
    transition: all 0.2s ease;
    border: none;
}

.copy-btn:hover {
    background: #475569;
    color: #e2e8f0;
}

.copy-btn.copied {
    background: #059669;
    color: #ffffff;
}

/* Gradientes */
.gradient-text {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 50%, #06b6d4 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.gradient-border {
    position: relative;
    background: linear-gradient(135deg, #667eea, #764ba2);
    padding: 2px;
    border-radius: 12px;
}

.gradient-border > * {
    background: #1e293b;
    border-radius: 10px;
}

/* Cards de Atividade */
.activity-card {
    position: relative;
    overflow: hidden;
}

.activity-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: linear-gradient(90deg, #667eea, #764ba2, #06b6d4);
}

.activity-number {
    width: 48px;
    height: 48px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, #667eea, #764ba2);
    border-radius: 12px;
    font-size: 20px;
    font-weight: bold;
    color: white;
}

/* Navegação */
.nav-link {
    position: relative;
    color: #94a3b8;
    transition: color 0.3s ease;
}

.nav-link:hover {
    color: #06b6d4;
}

.nav-link::after {
    content: '';
    position: absolute;
    bottom: -4px;
    left: 0;
    width: 0;
    height: 2px;
    background: #06b6d4;
    transition: width 0.3s ease;
}

.nav-link:hover::after {
    width: 100%;
}

/* Dicas e Alertas */
.tip-box {
    background: rgba(6, 182, 212, 0.1);
    border-left: 4px solid #06b6d4;
    padding: 16px;
    border-radius: 0 8px 8px 0;
}

.warning-box {
    background: rgba(245, 158, 11, 0.1);
    border-left: 4px solid #f59e0b;
    padding: 16px;
    border-radius: 0 8px 8px 0;
}

.info-box {
    background: rgba(99, 102, 241, 0.1);
    border-left: 4px solid #6366f1;
    padding: 16px;
    border-radius: 0 8px 8px 0;
}

/* Tabela de Conceitos */
.concept-table {
    width: 100%;
    border-collapse: collapse;
}

.concept-table th {
    background: #334155;
    padding: 12px 16px;
    text-align: left;
    font-weight: 600;
    color: #e2e8f0;
}

.concept-table td {
    padding: 12px 16px;
    border-bottom: 1px solid #334155;
    color: #cbd5e1;
}

.concept-table tr:hover td {
    background: rgba(51, 65, 85, 0.5);
}

/* Responsivo */
@media (max-width: 768px) {
    .code-content {
        font-size: 12px;
        padding: 12px;
    }
    
    .activity-number {
        width: 40px;
        height: 40px;
        font-size: 16px;
    }
}
