/* Reset e configurações básicas */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    /* Cores do tema escuro (padrão) - Dark Tech Palette */
    --background: 220 27% 8%;
    --foreground: 210 40% 98%;
    --card: 215 25% 20%;
    --card-foreground: 210 40% 98%;
    --popover: 215 25% 20%;
    --popover-foreground: 210 40% 98%;
    --primary: 238 90% 66%;
    --primary-foreground: 220 27% 8%;
    --secondary: 38 92% 50%;
    --secondary-foreground: 220 27% 8%;
    --muted: 215 25% 20%;
    --muted-foreground: 215 20% 65%;
    --accent: 158 64% 52%;
    --accent-foreground: 220 27% 8%;
    --destructive: 0 84% 60%;
    --destructive-foreground: 210 40% 98%;
    --border: 215 25% 20%;
    --input: 215 25% 20%;
    --ring: 238 90% 66%;
    --radius: 0.5rem;
    
    /* Cores personalizadas - Teal Tech */
    --primary-color: #00606C;
    --primary-dark: #004D56;
    --primary-light: #008B94;
    --secondary-color: #2563eb;
    --secondary-dark: #1d4ed8;
    --accent-color: #f59e0b;
    --accent-dark: #d97706;
    --surface: #334155;
    --surface-light: #475569;
    --background-alt: #1e293b;
    
    /* Gradientes */
    --gradient-primary: linear-gradient(135deg, #00606C 0%, #2563eb 100%);
    --gradient-secondary: linear-gradient(135deg, #f59e0b 0%, #ef4444 100%);
    --gradient-dark: linear-gradient(135deg, #0f172a 0%, #1e293b 100%);
}

.light {
    /* Cores do tema claro */
    --background: 0 0% 100%;
    --foreground: 222.2 84% 4.9%;
    --card: 0 0% 100%;
    --card-foreground: 222.2 84% 4.9%;
    --popover: 0 0% 100%;
    --popover-foreground: 222.2 84% 4.9%;
    --primary: 238 90% 66%;
    --primary-foreground: 0 0% 100%;
    --secondary: 38 92% 50%;
    --secondary-foreground: 0 0% 100%;
    --muted: 210 40% 96%;
    --muted-foreground: 215.4 16.3% 46.9%;
    --accent: 158 64% 52%;
    --accent-foreground: 0 0% 100%;
    --destructive: 0 84.2% 60.2%;
    --destructive-foreground: 210 40% 98%;
    --border: 214.3 31.8% 91.4%;
    --input: 214.3 31.8% 91.4%;
    --ring: 238 90% 66%;
    
    /* Cores personalizadas para tema claro */
    --primary-color: #00606C;
    --primary-dark: #004D56;
    --primary-light: #008B94;
}

.dark {
    /* Cores personalizadas para tema escuro */
    --primary-color: #D7E06B;
    --primary-dark: #C4D85A;
    --primary-light: #E8F07A;
    
    /* Gradiente para tema escuro */
    --gradient-primary: linear-gradient(135deg, #D7E06B 0%, #2563eb 100%);
}

body {
    font-family: 'Inter', sans-serif;
    background-color: hsl(var(--background));
    color: hsl(var(--foreground));
    line-height: 1.6;
    transition: background-color 0.3s ease, color 0.3s ease;
}

/* Força o tema escuro por padrão */
html {
    background-color: #0f172a;
}

html.light {
    background-color: #ffffff;
}

/* Utilitários */
.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 1rem;
}

.text-blue {
    color: var(--primary-color);
}

/* Header */
.header {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 80px;
    z-index: 9999;
    background: rgba(255, 255, 255, 0.95);
    border-bottom: 1px solid hsl(var(--border));
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
    transition: background-color 0.3s ease;
}

.dark .header {
    background: rgba(0, 0, 0, 0.8);
}

.header-container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    height: 100%;
    padding: 0 1.5rem;
    max-width: 1200px;
    margin: 0 auto;
}

.logo {
    width: 200px;
    pointer-events: auto;
    touch-action: manipulation;
}

.logo a {
    display: block;
    pointer-events: auto;
    touch-action: manipulation;
}

.logo-img {
    width: 100%;
    height: auto;
    max-width: 200px;
    transition: opacity 0.3s ease;
}

.header-actions {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.contact-btn,
.theme-toggle {
    background: none;
    border: none;
    padding: 0.5rem;
    border-radius: 0.5rem;
    cursor: pointer;
    color: hsl(var(--foreground));
    transition: background-color 0.2s ease;
    min-width: 40px;
    min-height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.contact-btn:hover,
.theme-toggle:hover {
    background-color: var(--primary-color);
    color: white;
}

.theme-toggle {
    position: relative;
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.sun-icon,
.moon-icon {
    position: absolute;
    transition: opacity 0.3s ease, transform 0.3s ease;
}

.dark .sun-icon {
    opacity: 0;
    transform: rotate(180deg);
}

.dark .moon-icon {
    opacity: 1;
    transform: rotate(0deg);
}

.sun-icon {
    opacity: 1;
    transform: rotate(0deg);
}

.moon-icon {
    opacity: 0;
    transform: rotate(-180deg);
}

/* Menu Mobile */
.menu-toggle {
    display: flex;
    flex-direction: column;
    gap: 4px;
    background: none;
    border: none;
    cursor: pointer;
    padding: 0.5rem;
    min-width: 40px;
    min-height: 40px;
    justify-content: center;
    align-items: center;
}

.menu-toggle span {
    width: 20px;
    height: 2px;
    background-color: hsl(var(--foreground));
    transition: all 0.3s ease;
    border-radius: 1px;
}

.menu-toggle.active span:nth-child(1) {
    transform: rotate(45deg) translate(5px, 5px);
}

.menu-toggle.active span:nth-child(2) {
    opacity: 0;
}

.menu-toggle.active span:nth-child(3) {
    transform: rotate(-45deg) translate(7px, -6px);
}

.mobile-menu {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100vh;
    background: hsl(var(--background));
    z-index: 10000;
    transform: translateY(-100%);
    transition: transform 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
}

.mobile-menu.active {
    transform: translateY(0);
}

.mobile-menu-content {
    text-align: center;
    width: 100%;
    padding: 2rem;
}

.mobile-logo {
    margin-bottom: 3rem;
}

.mobile-logo-img {
    width: 250px;
    height: auto;
    margin: 0 auto;
}

.mobile-nav-list {
    list-style: none;
    margin-bottom: 3rem;
}

.mobile-nav-list li {
    margin-bottom: 2rem;
}

.mobile-nav-link {
    font-size: 2rem;
    font-weight: 700;
    color: hsl(var(--foreground));
    text-decoration: none;
    transition: color 0.3s ease;
    font-family: monospace;
}

.mobile-nav-link:hover {
    color: var(--primary-color);
    font-style: italic;
}


/* Hero Section */
.hero {
    position: relative;
    height: 70vh;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    padding: 0;
}

.hero-background {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -1;
}

.wavy-bg {
    width: 100%;
    height: 100%;
    background: hsl(var(--background));
    position: relative;
}

.wavy-bg::before {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 100px;
    background: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 1200 120" preserveAspectRatio="none"><path d="M321.39,56.44c58-10.79,114.16-30.13,172-41.86,82.39-16.72,168.19-17.73,250.45-.39C823.78,31,906.67,72,985.66,92.83c70.05,18.48,146.53,26.09,214.34,3V0H0V27.35A600.21,600.21,0,0,0,321.39,56.44Z" fill="%23ffffff" fill-opacity="0.1"></path></svg>') repeat-x;
    background-size: 1200px 120px;
}

.hero-content {
    text-align: center;
    max-width: 800px;
    padding: 0 1rem;
    animation: fadeInUp 1s ease-out;
    margin-top: -2rem;
}

.hero-subtitle {
    font-size: 1.25rem;
    font-weight: 300;
    color: hsl(var(--foreground));
    margin-bottom: 1.5rem;
    opacity: 0;
    animation: fadeInUp 1s ease-out 0.2s forwards;
}

.hero-title {
    font-size: 3rem;
    font-weight: 700;
    color: hsl(var(--foreground));
    margin-bottom: 1.5rem;
    line-height: 1.2;
    opacity: 0;
    animation: fadeInUp 1s ease-out 0.4s forwards;
}

.hero-description {
    font-size: 1.25rem;
    font-weight: 300;
    color: hsl(var(--foreground));
    margin-bottom: 2rem;
    opacity: 0;
    animation: fadeInUp 1s ease-out 0.6s forwards;
}

.cta-button {
    background: var(--primary-color);
    color: white;
    border: none;
    padding: 1rem 2rem;
    font-size: 1.125rem;
    font-weight: 600;
    border-radius: 0.5rem;
    cursor: pointer;
    transition: all 0.3s ease;
    opacity: 0;
    animation: fadeInUp 1s ease-out 0.8s forwards;
    box-shadow: 0 4px 15px rgba(0, 96, 108, 0.3);
}

.dark .cta-button {
    box-shadow: 0 4px 15px rgba(215, 224, 107, 0.3);
}

.cta-button:hover {
    background: var(--primary-dark);
    transform: translateX(8px);
    box-shadow: 0 8px 25px rgba(0, 96, 108, 0.4);
}

.dark .cta-button:hover {
    box-shadow: 0 8px 25px rgba(215, 224, 107, 0.4);
}

.light .cta-button {
    background: var(--primary-color);
    color: white;
}

.light .cta-button:hover {
    background: var(--primary-dark);
}

/* About Section */
.about-section {
    padding: 3rem 0;
    background: hsl(var(--background));
}

.section-title {
    font-size: 2.5rem;
    font-weight: 700;
    color: var(--primary-color);
    text-align: center;
    margin-bottom: 3rem;
}

.features-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 1.5rem;
    margin-top: 2rem;
}

.feature-card {
    background: hsl(var(--card));
    border: 1px solid hsl(var(--border));
    border-radius: 0.75rem;
    padding: 1.5rem;
    cursor: pointer;
    transition: all 0.3s ease;
    position: relative;
    height: 160px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    text-align: center;
}

.feature-card:hover {
    background: var(--primary-color);
    color: white;
    border-color: var(--primary-color);
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(0, 96, 108, 0.2);
}

.dark .feature-card:hover {
    background: var(--primary-color);
    color: #0f172a;
    box-shadow: 0 8px 25px rgba(215, 224, 107, 0.2);
}

.feature-icon {
    position: absolute;
    top: 0.75rem;
    left: 0.75rem;
    color: var(--accent-color);
    filter: drop-shadow(0 0 8px rgba(245, 158, 11, 0.4));
}

.feature-expand-icon {
    position: absolute;
    top: 0.75rem;
    right: 0.75rem;
    color: hsl(var(--muted-foreground));
}

.feature-title {
    font-size: 1.125rem;
    font-weight: 600;
    color: hsl(var(--foreground));
    margin-bottom: 0.5rem;
}

.feature-description {
    font-size: 0.875rem;
    color: hsl(var(--muted-foreground));
}

/* Services Section */
.services-section {
    padding: 6rem 0;
    background: hsl(var(--muted));
}

.services-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 1.5rem;
    margin-top: 2rem;
}

.service-card {
    background: hsl(var(--card));
    border-radius: 0.75rem;
    padding: 2rem;
    text-align: center;
    transition: all 0.3s ease;
    border: 1px solid hsl(var(--border));
}

.service-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.1);
}

.service-icon {
    color: var(--primary-color);
    margin-bottom: 1rem;
}

.service-title {
    font-size: 1.25rem;
    font-weight: 600;
    color: hsl(var(--foreground));
    margin-bottom: 1rem;
}

.service-description {
    color: hsl(var(--muted-foreground));
    margin-bottom: 1.5rem;
    line-height: 1.6;
}

.service-link {
    color: var(--primary-color);
    text-decoration: none;
    font-weight: 500;
    transition: all 0.3s ease;
    padding: 0.5rem 1rem;
    border-radius: 0.5rem;
    display: inline-block;
    cursor: pointer;
    -webkit-tap-highlight-color: transparent;
    user-select: none;
}

.service-link:hover,
.service-link:focus {
    color: var(--primary-dark);
    background-color: rgba(0, 96, 108, 0.1);
    transform: translateY(-1px);
}

.service-link:active {
    color: var(--primary-dark);
    background-color: rgba(0, 96, 108, 0.2);
    transform: scale(0.95);
}

/* Footer */
.footer {
    background: hsl(var(--card));
    border-top: 1px solid hsl(var(--border));
    padding: 2rem 0;
}

.footer-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 1rem;
}

.footer-logo-img {
    width: 150px;
    height: auto;
}

.footer-info {
    text-align: right;
    color: hsl(var(--muted-foreground));
    font-size: 0.875rem;
}

.footer-info p {
    margin-bottom: 0.25rem;
}

/* Modal */
.modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.2);
    z-index: 100;
    display: none;
    align-items: center;
    justify-content: center;
    padding: 1rem;
}

.modal-overlay.active {
    display: flex;
}

.modal {
    background: hsl(var(--card));
    border-radius: 0.75rem;
    padding: 2rem;
    max-width: 550px;
    width: 100%;
    max-height: 60vh;
    position: relative;
    overflow-y: auto;
}

.modal-close {
    position: absolute;
    top: 0.75rem;
    right: 0.75rem;
    background: none;
    border: none;
    cursor: pointer;
    color: hsl(var(--muted-foreground));
    transition: color 0.3s ease;
}

.modal-close:hover {
    color: #ef4444;
}

.modal-content {
    text-align: center;
}

.modal-icon {
    font-size: 3rem;
    color: var(--accent-color);
    filter: drop-shadow(0 0 8px rgba(245, 158, 11, 0.4));
    margin-bottom: 1rem;
    border: 1px solid var(--accent-color);
    border-radius: 50%;
    padding: 1rem;
    display: inline-block;
}

.modal-title {
    font-size: 1.5rem;
    font-weight: 600;
    color: hsl(var(--foreground));
    margin-bottom: 1rem;
}

.modal-description {
    color: hsl(var(--muted-foreground));
    margin-bottom: 1.5rem;
    font-weight: 500;
}

.modal-text {
    color: hsl(var(--foreground));
    line-height: 1.6;
    text-align: left;
}

/* Animações */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Contact Button Active State */
.contact-btn.active {
    background-color: var(--primary-color);
    color: white;
}

.contact-btn.active:hover {
    background-color: #004D56;
}

/* Page Hero Styles */
.page-hero {
    padding: 8rem 0 4rem;
    background: hsl(var(--background));
    color: hsl(var(--foreground));
    text-align: center;
}

.page-hero-content {
    max-width: 800px;
    margin: 0 auto;
}

.page-hero-title {
    font-size: 3.5rem;
    font-weight: 700;
    margin-bottom: 1rem;
    line-height: 1.2;
}

.page-hero-subtitle {
    font-size: 1.5rem;
    font-weight: 300;
    margin-bottom: 1rem;
    opacity: 0.9;
}

.page-hero-description {
    font-size: 1.25rem;
    font-weight: 300;
    margin-bottom: 2rem;
    line-height: 1.6;
    opacity: 0.9;
}

/* Services Detail Section */
.services-detail-section {
    padding: 6rem 0;
    background: hsl(var(--background));
}

.services-detail-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
    margin-top: 3rem;
}

.service-detail-card {
    background: hsl(var(--card));
    border: 1px solid hsl(var(--border));
    border-radius: 0.75rem;
    padding: 2rem;
    text-align: center;
    transition: all 0.3s ease;
}

.service-detail-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.1);
}

.service-detail-icon {
    color: var(--primary-color);
    margin-bottom: 1.5rem;
}

.service-detail-card h3 {
    font-size: 1.5rem;
    font-weight: 600;
    color: hsl(var(--foreground));
    margin-bottom: 1rem;
}

.service-detail-card p {
    color: hsl(var(--muted-foreground));
    margin-bottom: 1.5rem;
    line-height: 1.6;
}

.service-features {
    list-style: none;
    text-align: left;
}

.service-features li {
    color: hsl(var(--muted-foreground));
    margin-bottom: 0.5rem;
    position: relative;
    padding-left: 1.5rem;
}

.service-features li::before {
    content: '✓';
    position: absolute;
    left: 0;
    color: var(--primary-color);
    font-weight: bold;
}

/* Process Section */
.process-section {
    padding: 6rem 0;
    background: hsl(var(--muted));
}

.process-timeline {
    margin-top: 3rem;
    position: relative;
}

.process-timeline::before {
    content: '';
    position: absolute;
    left: 2rem;
    top: 0;
    bottom: 0;
    width: 2px;
    background: var(--primary-color);
}

.process-step {
    display: flex;
    align-items: flex-start;
    margin-bottom: 3rem;
    position: relative;
}

.process-number {
    width: 4rem;
    height: 4rem;
    background: var(--primary-color);
    color: white;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    font-weight: 700;
    margin-right: 2rem;
    flex-shrink: 0;
    position: relative;
    z-index: 1;
}

.process-content {
    flex: 1;
    padding-top: 0.5rem;
}

.process-content h3 {
    font-size: 1.25rem;
    font-weight: 600;
    color: hsl(var(--foreground));
    margin-bottom: 0.5rem;
}

.process-content p {
    color: hsl(var(--muted-foreground));
    line-height: 1.6;
}

/* CTA Section */
.cta-section {
    padding: 6rem 0;
    background: hsl(var(--card));
    text-align: center;
}

.cta-content h2 {
    font-size: 2.5rem;
    font-weight: 700;
    color: hsl(var(--foreground));
    margin-bottom: 1rem;
}

.cta-content p {
    font-size: 1.25rem;
    color: hsl(var(--muted-foreground));
    margin-bottom: 2rem;
    max-width: 600px;
    margin-left: auto;
    margin-right: auto;
}

.cta-buttons {
    display: flex;
    gap: 1rem;
    justify-content: center;
    flex-wrap: wrap;
}

.cta-button.primary {
    background: var(--primary-color);
    color: white;
}

.cta-button.secondary {
    background: transparent;
    color: var(--primary-color);
    border: 2px solid var(--primary-color);
}

.cta-button.secondary:hover {
    background: var(--primary-color);
    color: white;
}

/* Responsividade */
@media (max-width: 768px) {
    .hero {
        height: 100vh;
        padding: 0;
    }
    
    .hero-content {
        margin-top: 0;
    }
    
    .hero-title {
        font-size: 2rem;
    }
    
    .hero-subtitle {
        font-size: 1rem;
    }
    
    .hero-description {
        font-size: 1rem;
    }
    
    .section-title {
        font-size: 2rem;
    }
    
    .about-section {
        padding: 4rem 0;
    }
    
    .features-grid,
    .services-grid {
        grid-template-columns: 1fr;
    }
    
    .footer-content {
        flex-direction: column;
        text-align: center;
    }
    
    .footer-info {
        text-align: center;
    }
    
    .mobile-nav-link {
        font-size: 1.5rem;
    }
    
    .page-hero-title {
        font-size: 2rem;
    }
    
    .service-link {
        padding: 0.75rem 1.5rem;
        font-size: 1.1rem;
        min-height: 44px;
        display: flex;
        align-items: center;
        justify-content: center;
    }
    
    .service-link:active {
        background-color: rgba(0, 96, 108, 0.3) !important;
        transform: scale(0.95) !important;
        color: var(--primary-dark) !important;
    }
}

/* Força efeito em dispositivos touch */
@media (hover: none) and (pointer: coarse) {
    .service-link:active {
        background-color: rgba(0, 96, 108, 0.3) !important;
        transform: scale(0.95) !important;
        color: var(--primary-dark) !important;
        transition: all 0.1s ease !important;
    }
}

@media (max-width: 480px) {
    .header-container {
        padding: 0 1rem;
    }
    
    .logo {
        width: 150px;
    }
    
    .hero-content {
        padding: 0 0.5rem;
    }
    
    .hero-title {
        font-size: 1.75rem;
    }
    
    .modal {
        margin: 1rem;
        padding: 1.5rem;
    }
    
    .page-hero-title {
        font-size: 1.75rem;
    }
}
