/* ==========================================================================
   CSS Custom Properties (Design System)
   ========================================================================== */
   :root {
    /* Colors */
    --bg-dark: #0a0a0f;
    --bg-surface: rgba(22, 22, 30, 0.6);
    --primary: #4e31ff;
    --primary-light: #7a63ff;
    --secondary: #00e5ff;
    --accent: #ff2a7a;
    
    --text-primary: #f8f8fc;
    --text-secondary: #9aa0af;
    --text-dark: #0a0a0f;
    
    /* Gradients */
    --gradient-brand: linear-gradient(135deg, var(--primary) 0%, var(--secondary) 100%);
    --gradient-glow: linear-gradient(135deg, rgba(78, 49, 255, 0.5) 0%, rgba(0, 229, 255, 0.5) 100%);
    
    /* Layout */
    --font-heading: 'Outfit', sans-serif;
    --font-body: 'Inter', sans-serif;
    --radius-sm: 8px;
    --radius-md: 16px;
    --radius-lg: 24px;
    --radius-pill: 100px;
    
    /* Effects */
    --glass-border: 1px solid rgba(255, 255, 255, 0.08);
    --glass-shadow: 0 8px 32px 0 rgba(0, 0, 0, 0.37);
    --transition-fast: 0.2s cubic-bezier(0.16, 1, 0.3, 1);
    --transition-smooth: 0.5s cubic-bezier(0.16, 1, 0.3, 1);
}

/* ==========================================================================
   Reset & Base Styles
   ========================================================================== */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: var(--font-body);
    background-color: var(--bg-dark);
    color: var(--text-primary);
    line-height: 1.6;
    overflow-x: hidden;
    position: relative;
}

h1, h2, h3, h4, h5, h6 {
    font-family: var(--font-heading);
    font-weight: 800;
    line-height: 1.2;
    margin-bottom: 1rem;
}

a {
    text-decoration: none;
    color: inherit;
    transition: var(--transition-fast);
}

ul {
    list-style: none;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 2rem;
}

/* Typography Utility */
.text-gradient {
    background: var(--gradient-brand);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    display: inline-block;
}

.h2 {
    font-size: clamp(2rem, 5vw, 3.5rem);
    margin-bottom: 1.5rem;
}

/* ==========================================================================
   Background Blobs (Aesthetics)
   ========================================================================== */
.blob {
    position: absolute;
    filter: blur(80px);
    z-index: -1;
    opacity: 0.5;
    animation: float-blob 20s infinite alternate;
}

.blob-1 {
    top: -10%;
    left: -10%;
    width: 600px;
    height: 600px;
    background: radial-gradient(circle, var(--primary) 0%, rgba(78,49,255,0) 70%);
}

.blob-2 {
    top: 30%;
    right: -20%;
    width: 800px;
    height: 800px;
    background: radial-gradient(circle, var(--secondary) 0%, rgba(0,229,255,0) 70%);
    animation-duration: 25s;
    animation-direction: alternate-reverse;
}

@keyframes float-blob {
    0% { transform: translate(0, 0) scale(1); }
    50% { transform: translate(5%, 10%) scale(1.1); }
    100% { transform: translate(-5%, -5%) scale(0.9); }
}

/* ==========================================================================
   Components (Glassmorphism, Buttons, Cards)
   ========================================================================== */
.glass-panel, .glass-card {
    background: var(--bg-surface);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border: var(--glass-border);
    box-shadow: var(--glass-shadow);
}

.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0.75rem 1.5rem;
    border-radius: var(--radius-pill);
    font-family: var(--font-heading);
    font-weight: 600;
    font-size: 1rem;
    cursor: pointer;
    transition: var(--transition-fast);
    border: none;
    outline: none;
}

.btn-primary {
    background: var(--gradient-brand);
    color: white;
    box-shadow: 0 4px 15px rgba(78, 49, 255, 0.4);
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(0, 229, 255, 0.5);
}

.btn-outline {
    background: transparent;
    color: var(--text-primary);
    border: 1px solid var(--text-primary);
}

.btn-outline:hover {
    background: var(--text-primary);
    color: var(--text-dark);
}

.btn-lg {
    padding: 1rem 2rem;
    font-size: 1.1rem;
}

.btn-block {
    width: 100%;
    padding: 1rem;
}

/* ==========================================================================
   Navigation
   ========================================================================== */
.navbar {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    padding: 1.5rem 0;
    z-index: 100;
    transition: var(--transition-fast);
}

.navbar.scrolled {
    padding: 1rem 0;
    background: rgba(10, 10, 15, 0.8);
    backdrop-filter: blur(12px);
    border-bottom: 1px solid rgba(255,255,255,0.05);
}

.nav-container {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo {
    font-family: var(--font-heading);
    font-size: 1.5rem;
    font-weight: 800;
    letter-spacing: -0.5px;
}

.logo span {
    color: var(--primary-light);
}

.nav-links {
    display: flex;
    gap: 2.5rem;
}

.nav-links a {
    font-size: 0.95rem;
    font-weight: 500;
    color: var(--text-secondary);
}

.nav-links a:hover {
    color: var(--text-primary);
}

.hamburger {
    display: none;
    flex-direction: column;
    gap: 5px;
    cursor: pointer;
}

.hamburger span {
    width: 25px;
    height: 2px;
    background: var(--text-primary);
    transition: var(--transition-fast);
}

/* ==========================================================================
   Hero Section
   ========================================================================== */
.hero {
    min-height: 100vh;
    display: flex;
    align-items: center;
    padding-top: 5rem;
    position: relative;
}

.hero-container {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
    align-items: center;
}

.badge {
    display: inline-block;
    padding: 0.4rem 1rem;
    border-radius: var(--radius-pill);
    background: rgba(78, 49, 255, 0.15);
    color: var(--primary-light);
    font-size: 0.85rem;
    font-weight: 600;
    margin-bottom: 1.5rem;
    border: 1px solid rgba(78, 49, 255, 0.3);
}

.hero h1 {
    font-size: clamp(3rem, 6vw, 4.5rem);
    letter-spacing: -1px;
    margin-bottom: 1.5rem;
}

.hero p {
    font-size: 1.2rem;
    color: var(--text-secondary);
    margin-bottom: 2.5rem;
    max-width: 90%;
}

.hero-actions {
    display: flex;
    gap: 1rem;
    margin-bottom: 3.5rem;
}

.stats {
    display: flex;
    gap: 3rem;
}

.stat-item h3 {
    font-size: 2rem;
    margin-bottom: 0.2rem;
    color: var(--text-primary);
}

.stat-item p {
    font-size: 0.9rem;
    color: var(--text-secondary);
    margin: 0;
}

/* Hero Bot Demo UI */
.bot-demo {
    border-radius: var(--radius-lg);
    overflow: hidden;
    transform: perspective(1000px) rotateY(-5deg) rotateX(5deg);
    transition: transform 0.5s ease;
}

.bot-demo:hover {
    transform: perspective(1000px) rotateY(0deg) rotateX(0deg);
}

.bot-header {
    padding: 1rem 1.5rem;
    background: rgba(0,0,0,0.4);
    display: flex;
    align-items: center;
    gap: 0.75rem;
    border-bottom: 1px solid rgba(255,255,255,0.05);
}

.status-dot {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background: #00e5ff;
    box-shadow: 0 0 10px #00e5ff;
}

.bot-name {
    font-weight: 600;
    font-size: 0.9rem;
}

.chat-container {
    padding: 1.5rem;
    display: flex;
    flex-direction: column;
    gap: 1rem;
    height: 350px;
    overflow-y: hidden;
}

.message {
    display: flex;
    gap: 0.75rem;
    align-items: flex-end;
    opacity: 0;
    transform: translateY(10px);
}

.message.visible {
    opacity: 1;
    transform: translateY(0);
    transition: all 0.4s ease;
}

.avatar {
    width: 30px;
    height: 30px;
    border-radius: 50%;
    background: var(--gradient-brand);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.8rem;
    font-weight: bold;
    flex-shrink: 0;
}

.msg-bubble {
    padding: 0.8rem 1rem;
    border-radius: var(--radius-md);
    font-size: 0.9rem;
    max-width: 85%;
    line-height: 1.4;
}

.msg-bot .msg-bubble {
    background: rgba(255,255,255,0.05);
    border: 1px solid rgba(255,255,255,0.1);
    border-bottom-left-radius: 4px;
}

.msg-user {
    flex-direction: row-reverse;
}

.msg-user .msg-bubble {
    background: var(--primary);
    border-bottom-right-radius: 4px;
}

.typing-indicator {
    display: flex;
    gap: 4px;
    padding: 1rem;
    background: rgba(255,255,255,0.05);
    border-radius: var(--radius-md);
    width: fit-content;
    margin-left: 2.5rem;
    opacity: 0;
}

.typing-indicator.active {
    opacity: 1;
}

.typing-indicator span {
    width: 6px;
    height: 6px;
    background: var(--text-secondary);
    border-radius: 50%;
    animation: bounce 1.4s infinite ease-in-out both;
}

.typing-indicator span:nth-child(1) { animation-delay: -0.32s; }
.typing-indicator span:nth-child(2) { animation-delay: -0.16s; }

@keyframes bounce {
    0%, 80%, 100% { transform: scale(0); }
    40% { transform: scale(1); }
}

/* ==========================================================================
   Features Section
   ========================================================================== */
.features {
    padding: 8rem 0;
}

.section-header {
    text-align: center;
    max-width: 600px;
    margin: 0 auto 4rem;
}

.section-header p {
    color: var(--text-secondary);
    font-size: 1.1rem;
}

.feature-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
}

.feature-card {
    padding: 2.5rem;
    border-radius: var(--radius-lg);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.feature-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 15px 35px rgba(0,0,0,0.5);
    border-color: rgba(78, 49, 255, 0.3);
}

.feature-icon {
    width: 60px;
    height: 60px;
    border-radius: var(--radius-md);
    background: rgba(78, 49, 255, 0.1);
    color: var(--secondary);
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 1.5rem;
}

.feature-card h3 {
    font-size: 1.5rem;
    margin-bottom: 1rem;
}

.feature-card p {
    color: var(--text-secondary);
    font-size: 0.95rem;
}

/* ==========================================================================
   Technology / Analytics Section
   ========================================================================== */
.tech-section {
    padding: 8rem 0;
    position: relative;
}

.tech-container {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 5rem;
    align-items: center;
}

.dashboard-preview {
    padding: 2rem;
    border-radius: var(--radius-lg);
}

.dash-row {
    display: flex;
    gap: 1.5rem;
    margin-bottom: 2rem;
}

.metric-box {
    flex: 1;
    background: rgba(0,0,0,0.3);
    border-radius: var(--radius-md);
    padding: 1.5rem;
    border: 1px solid rgba(255,255,255,0.05);
}

.metric-box .label {
    display: block;
    color: var(--text-secondary);
    font-size: 0.85rem;
    margin-bottom: 0.5rem;
}

.metric-box .value {
    font-family: var(--font-heading);
    font-size: 2rem;
    font-weight: 700;
}

.value.success { color: #00ff88; }
.value.highlight { color: var(--secondary); }

.bar-chart {
    display: flex;
    align-items: flex-end;
    gap: 5px;
    height: 40px;
    margin-top: 1rem;
}

.bar {
    flex: 1;
    background: var(--primary);
    border-radius: 3px 3px 0 0;
    opacity: 0.6;
}

.bar.b3 { background: var(--secondary); opacity: 1; }

.check-list {
    margin-top: 2rem;
}

.check-list li {
    position: relative;
    padding-left: 2rem;
    margin-bottom: 1rem;
    color: var(--text-primary);
}

.check-list li::before {
    content: '✓';
    position: absolute;
    left: 0;
    top: 2px;
    color: var(--secondary);
    font-weight: bold;
}

.ai-brain-anim {
    height: 150px;
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
}

.core-pulse {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: var(--primary);
    box-shadow: 0 0 30px var(--primary);
    animation: pulse 2s infinite;
}

.orbit {
    position: absolute;
    width: 120px;
    height: 120px;
    border-radius: 50%;
    border: 1px dashed var(--secondary);
    animation: spin 10s linear infinite;
}

@keyframes pulse {
    0% { transform: scale(1); box-shadow: 0 0 20px var(--primary); }
    50% { transform: scale(1.2); box-shadow: 0 0 40px var(--secondary); }
    100% { transform: scale(1); box-shadow: 0 0 20px var(--primary); }
}

@keyframes spin { 100% { transform: rotate(360deg); } }

/* ==========================================================================
   CTA Section
   ========================================================================== */
.cta-section {
    padding: 6rem 0;
}

.cta-box {
    padding: 5rem 3rem;
    border-radius: var(--radius-lg);
    text-align: center;
    max-width: 800px;
    margin: 0 auto;
    background: linear-gradient(180deg, rgba(22, 22, 30, 0.8) 0%, rgba(10, 10, 15, 0.9) 100%);
    border-top: 1px solid rgba(78, 49, 255, 0.5);
}

.cta-box h2 {
    margin-bottom: 1rem;
}

.cta-box p {
    color: var(--text-secondary);
    margin-bottom: 2.5rem;
    font-size: 1.1rem;
}

.contact-form {
    max-width: 500px;
    margin: 0 auto;
}

.form-group {
    margin-bottom: 1.2rem;
}

.contact-form input {
    width: 100%;
    padding: 1rem 1.5rem;
    border-radius: var(--radius-sm);
    background: rgba(0,0,0,0.3);
    border: 1px solid rgba(255,255,255,0.1);
    color: white;
    font-family: var(--font-body);
    font-size: 1rem;
    outline: none;
    transition: var(--transition-fast);
}

.contact-form input:focus {
    border-color: var(--primary);
    box-shadow: 0 0 10px rgba(78, 49, 255, 0.2);
}

/* ==========================================================================
   Footer
   ========================================================================== */
.footer {
    border-top: 1px solid rgba(255,255,255,0.05);
    padding: 4rem 0 2rem;
    background: rgba(5,5,8,0.8);
}

.footer-container {
    display: grid;
    grid-template-columns: 2fr 1fr 1fr;
    gap: 3rem;
    margin-bottom: 3rem;
}

.footer-brand p {
    color: var(--text-secondary);
    margin-top: 1rem;
    font-size: 0.9rem;
    max-width: 300px;
}

.footer-links h4 {
    color: white;
    margin-bottom: 1.5rem;
    font-size: 1.1rem;
}

.footer-links li {
    margin-bottom: 0.8rem;
}

.footer-links a {
    color: var(--text-secondary);
    font-size: 0.9rem;
}

.footer-links a:hover {
    color: var(--secondary);
}

.footer-bottom {
    text-align: center;
    padding-top: 2rem;
    border-top: 1px solid rgba(255,255,255,0.05);
    color: var(--text-secondary);
    font-size: 0.85rem;
}

/* ==========================================================================
   Animations & Utilitites (Scroll Reveals)
   ========================================================================== */
.fade-up { opacity: 0; transform: translateY(30px); transition: opacity 0.8s ease, transform 0.8s ease; }
.fade-left { opacity: 0; transform: translateX(30px); transition: opacity 0.8s ease, transform 0.8s ease; }
.fade-right { opacity: 0; transform: translateX(-30px); transition: opacity 0.8s ease, transform 0.8s ease; }

.fade-up.visible, .fade-left.visible, .fade-right.visible {
    opacity: 1; transform: translate(0);
}

.delay-1 { transition-delay: 0.2s; }
.delay-2 { transition-delay: 0.4s; }
.delay-3 { transition-delay: 0.6s; }

/* ==========================================================================
   Media Queries (Responsive)
   ========================================================================== */
@media (max-width: 992px) {
    .hero-container, .tech-container {
        grid-template-columns: 1fr;
        text-align: center;
    }
    
    .hero { padding-top: 8rem; }
    
    .hero p { margin: 0 auto 2rem; }
    .hero-actions { justify-content: center; }
    .stats { justify-content: center; }
    
    .tech-visual { order: 2; margin-top: 3rem; }
    .tech-content { order: 1; }
    .check-list { text-align: left; max-width: 400px; margin: 2rem auto 0; }
}

@media (max-width: 768px) {
    .nav-links, .nav-cta { display: none; }
    .hamburger { display: flex; }
    
    .hero h1 { font-size: 2.5rem; }
    .hero-actions { flex-direction: column; }
    
    .footer-container {
        grid-template-columns: 1fr;
        text-align: center;
    }
    
    .footer-brand p { margin: 1rem auto; }
}

/* ==========================================================================
   Modals (Termos de Uso)
   ========================================================================== */
.modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.7);
    backdrop-filter: blur(5px);
    -webkit-backdrop-filter: blur(5px);
    z-index: 1000;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.3s ease, visibility 0.3s ease;
}

.modal-overlay.active {
    opacity: 1;
    visibility: visible;
}

.modal-content {
    width: 90%;
    max-width: 600px;
    max-height: 80vh;
    display: flex;
    flex-direction: column;
    transform: translateY(20px);
    transition: transform 0.4s ease;
}

.modal-overlay.active .modal-content {
    transform: translateY(0);
}

.modal-header {
    padding: 1.5rem 2rem;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.modal-header h3 {
    margin: 0;
    color: var(--primary-light);
    font-size: 1.5rem;
}

.close-modal {
    background: transparent;
    border: none;
    color: var(--text-secondary);
    font-size: 2rem;
    cursor: pointer;
    line-height: 1;
    transition: color var(--transition-fast);
}

.close-modal:hover {
    color: var(--accent);
}

.modal-body {
    padding: 2rem;
    overflow-y: auto;
    color: var(--text-primary);
}

.modal-body h4 {
    font-family: var(--font-body);
    font-size: 1.1rem;
    color: var(--secondary);
    margin-top: 1.5rem;
    margin-bottom: 0.5rem;
}

.modal-body h4:first-child {
    margin-top: 0;
}

.modal-body p {
    font-size: 0.95rem;
    color: var(--text-secondary);
    margin-bottom: 1rem;
    line-height: 1.6;
}

.modal-footer-date {
    margin-top: 2rem;
    font-size: 0.85rem;
    color: var(--text-secondary);
    text-align: right;
    border-top: 1px dashed rgba(255, 255, 255, 0.1);
    padding-top: 1rem;
}
