/* ===== RESET E BASE ===== */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    /* Cores */
    --primary-color: #4361ee;
    --primary-dark: #3a56d4;
    --secondary-color: #3f37c9;
    --accent-color: #4895ef;
    --light-color: #f8f9fa;
    --dark-color: #212529;
    --gray-color: #6c757d;
    --light-gray: #e9ecef;
    --white: #ffffff;
    --black: #000000;
    
    /* Tipografia */
    --font-family: 'Poppins', sans-serif;
    --font-light: 300;
    --font-regular: 400;
    --font-semibold: 600;
    --font-bold: 700;
    
    /* Espaçamento */
    --section-padding: 80px 0;
    --container-max: 1200px;
    
    /* Transições */
    --transition: all 0.3s ease;
    
    /* Sombras */
    --box-shadow: 0 4px 20px rgba(0, 0, 0, 0.1);
    --box-shadow-hover: 0 8px 30px rgba(0, 0, 0, 0.15);
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: var(--font-family);
    font-weight: var(--font-regular);
    line-height: 1.6;
    color: var(--dark-color);
    background-color: var(--white);
}

.container {
    max-width: var(--container-max);
    margin: 0 auto;
    padding: 0 20px;
}

/* ===== HEADER ===== */
.header {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    background: var(--white);
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    z-index: 1000;
    transition: var(--transition);
}

.header.scrolled {
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    padding: 10px 0;
}

.header .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px 20px;
}

.logo {
    font-size: 24px;
    font-weight: var(--font-bold);
    color: var(--dark-color);
    text-decoration: none;
}

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

.navbar {
    display: flex;
    align-items: center;
}

.nav-links {
    display: flex;
    list-style: none;
    gap: 30px;
}

.nav-links a {
    text-decoration: none;
    color: var(--dark-color);
    font-weight: var(--font-semibold);
    transition: var(--transition);
    position: relative;
}

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

.nav-links a.active::after {
    content: '';
    position: absolute;
    bottom: -5px;
    left: 0;
    width: 100%;
    height: 2px;
    background: var(--primary-color);
}

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

.hamburger span {
    width: 25px;
    height: 2px;
    background: var(--dark-color);
    transition: var(--transition);
}

/* ===== BUTTONS ===== */
.btn {
    display: inline-block;
    padding: 12px 30px;
    border-radius: 50px;
    text-decoration: none;
    font-weight: var(--font-semibold);
    transition: var(--transition);
    cursor: pointer;
    border: none;
}

.btn-primary {
    background: var(--primary-color);
    color: var(--white);
}

.btn-primary:hover {
    background: var(--primary-dark);
    transform: translateY(-2px);
    box-shadow: var(--box-shadow-hover);
}

.btn-secondary {
    background: var(--light-color);
    color: var(--primary-color);
    border: 2px solid var(--primary-color);
}

.btn-secondary:hover {
    background: var(--primary-color);
    color: var(--white);
}

.btn-small {
    padding: 8px 20px;
    font-size: 14px;
    background: var(--primary-color);
    color: var(--white);
    border-radius: 50px;
    text-decoration: none;
    transition: var(--transition);
}

.btn-small:hover {
    background: var(--primary-dark);
}

/* ===== HERO SECTION ===== */
.hero {
    padding: 150px 0 80px;
    background: linear-gradient(135deg, #f5f7fa 0%, #c3cfe2 100%);
}

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

.hero-content h1 {
    font-size: 48px;
    font-weight: var(--font-bold);
    line-height: 1.2;
    margin-bottom: 20px;
    color: var(--dark-color);
}

.hero-content p {
    font-size: 18px;
    color: var(--gray-color);
    margin-bottom: 30px;
    line-height: 1.8;
}

.hero-buttons {
    display: flex;
    gap: 20px;
}

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

.hero-image img {
    max-width: 100%;
    border-radius: 15px;
    box-shadow: var(--box-shadow);
}

/* ===== SECTIONS COMMON ===== */
.section-header {
    text-align: center;
    margin-bottom: 50px;
}

.section-header h2 {
    font-size: 36px;
    font-weight: var(--font-bold);
    color: var(--dark-color);
    margin-bottom: 15px;
}

.section-header p {
    font-size: 16px;
    color: var(--gray-color);
}

/* ===== SERVICES ===== */
.services {
    padding: var(--section-padding);
    background: var(--white);
}

.services-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 30px;
}

.service-card {
    background: var(--white);
    padding: 30px;
    border-radius: 15px;
    text-align: center;
    box-shadow: var(--box-shadow);
    transition: var(--transition);
    border: 1px solid var(--light-gray);
}

.service-card:hover {
    transform: translateY(-10px);
    box-shadow: var(--box-shadow-hover);
    border-color: var(--primary-color);
}

.service-icon {
    font-size: 50px;
    margin-bottom: 20px;
}

.service-card h3 {
    font-size: 20px;
    font-weight: var(--font-semibold);
    margin-bottom: 15px;
    color: var(--dark-color);
}

.service-card p {
    font-size: 14px;
    color: var(--gray-color);
    margin-bottom: 20px;
    line-height: 1.6;
}

/* ===== ABOUT ===== */
.about {
    padding: var(--section-padding);
    background: var(--light-gray);
}

.about-content {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 50px;
    align-items: center;
}

.about-image img {
    width: 100%;
    border-radius: 15px;
    box-shadow: var(--box-shadow);
}

.about-text p {
    font-size: 16px;
    color: var(--gray-color);
    margin-bottom: 20px;
    line-height: 1.8;
}

.stats {
    display: flex;
    gap: 30px;
    margin-top: 30px;
}

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

.stat-number {
    display: block;
    font-size: 32px;
    font-weight: var(--font-bold);
    color: var(--primary-color);
}

.stat-label {
    display: block;
    font-size: 14px;
    color: var(--gray-color);
    margin-top: 5px;
}

/* ===== PORTFOLIO ===== */
.portfolio {
    padding: var(--section-padding);
    background: var(--white);
}

.portfolio-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 30px;
}

.portfolio-item {
    position: relative;
    border-radius: 15px;
    overflow: hidden;
    box-shadow: var(--box-shadow);
    transition: var(--transition);
    cursor: pointer;
}

.portfolio-item:hover {
    transform: scale(1.03);
    box-shadow: var(--box-shadow-hover);
}

.portfolio-item img {
    width: 100%;
    height: 250px;
    object-fit: cover;
    display: block;
}

.portfolio-overlay {
    position: absolute;
    bottom: -100%;
    left: 0;
    right: 0;
    background: rgba(0, 0, 0, 0.9);
    padding: 20px;
    color: var(--white);
    transition: var(--transition);
    text-align: center;
}

.portfolio-item:hover .portfolio-overlay {
    bottom: 0;
}

.portfolio-overlay h3 {
    font-size: 18px;
    margin-bottom: 10px;
}

.portfolio-overlay p {
    font-size: 14px;
    margin-bottom: 15px;
    opacity: 0.9;
}

/* ===== CONTACT ===== */
.contact {
    padding: var(--section-padding);
    background: var(--light-gray);
}

.contact-content {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 50px;
}

.contact-form {
    background: var(--white);
    padding: 30px;
    border-radius: 15px;
    box-shadow: var(--box-shadow);
}

.form-group {
    margin-bottom: 20px;
}

.form-group input,
.form-group textarea {
    width: 100%;
    padding: 15px;
    border: 1px solid var(--light-gray);
    border-radius: 8px;
    font-family: var(--font-family);
    font-size: 16px;
    transition: var(--transition);
}

.form-group input:focus,
.form-group textarea:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px rgba(67, 97, 238, 0.2);
}

.form-group textarea {
    resize: vertical;
    min-height: 120px;
}

.contact-form button {
    width: 100%;
    margin-top: 10px;
}

.contact-info {
    display: flex;
    flex-direction: column;
    gap: 30px;
}

.info-item {
    display: flex;
    gap: 20px;
    align-items: flex-start;
}

.info-icon {
    font-size: 30px;
}

.info-text h4 {
    font-size: 18px;
    font-weight: var(--font-semibold);
    margin-bottom: 10px;
    color: var(--dark-color);
}

.info-text p {
    font-size: 14px;
    color: var(--gray-color);
    line-height: 1.8;
}

.social-links h4 {
    font-size: 18px;
    font-weight: var(--font-semibold);
    margin-bottom: 15px;
    color: var(--dark-color);
}

.social-icons {
    display: flex;
    gap: 15px;
    flex-wrap: wrap;
}

.social-icon {
    display: inline-block;
    padding: 10px 20px;
    background: var(--primary-color);
    color: var(--white);
    border-radius: 8px;
    text-decoration: none;
    font-size: 14px;
    transition: var(--transition);
}

.social-icon:hover {
    background: var(--primary-dark);
    transform: translateY(-2px);
}

/* ===== FOOTER ===== */
.footer {
    background: var(--dark-color);
    color: var(--white);
    padding: 50px 0 0;
}

.footer-content {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 50px;
    margin-bottom: 40px;
}

.footer-section h3,
.footer-section h4 {
    font-size: 18px;
    font-weight: var(--font-semibold);
    margin-bottom: 20px;
    color: var(--white);
}

.footer-section p {
    font-size: 14px;
    color: var(--gray-color);
    line-height: 1.8;
}

.footer-section ul {
    list-style: none;
}

.footer-section ul li {
    margin-bottom: 10px;
}

.footer-section ul li a {
    color: var(--gray-color);
    text-decoration: none;
    transition: var(--transition);
}

.footer-section ul li a:hover {
    color: var(--primary-color);
}

.footer-bottom {
    text-align: center;
    padding: 20px 0;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.footer-bottom p {
    font-size: 14px;
    color: var(--gray-color);
}

/* ===== BACK TO TOP ===== */
.back-to-top {
    position: fixed;
    bottom: 30px;
    right: 30px;
    width: 50px;
    height: 50px;
    background: var(--primary-color);
    color: var(--white);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    text-decoration: none;
    font-size: 24px;
    box-shadow: var(--box-shadow);
    transition: var(--transition);
    opacity: 0;
    visibility: hidden;
    z-index: 1000;
}

.back-to-top.visible {
    opacity: 1;
    visibility: visible;
}

.back-to-top:hover {
    background: var(--primary-dark);
    transform: translateY(-5px);
}

/* ===== RESPONSIVE ===== */
@media (max-width: 1024px) {
    .hero .container,
    .about-content,
    .contact-content {
        grid-template-columns: 1fr;
        gap: 40px;
    }
    
    .hero {
        text-align: center;
    }
    
    .hero-content {
        order: 2;
    }
    
    .hero-image {
        order: 1;
    }
    
    .hero-content h1 {
        font-size: 40px;
    }
    
    .hero-buttons {
        justify-content: center;
    }
    
    .services-grid,
    .portfolio-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 768px) {
    .nav-links {
        position: fixed;
        top: 80px;
        left: 0;
        width: 100%;
        background: var(--white);
        flex-direction: column;
        align-items: center;
        padding: 30px 0;
        gap: 20px;
        box-shadow: 0 5px 20px rgba(0, 0, 0, 0.1);
        transform: translateY(-150%);
        transition: var(--transition);
    }
    
    .nav-links.active {
        transform: translateY(0);
    }
    
    .hamburger {
        display: flex;
    }
    
    .hamburger.active span:nth-child(1) {
        transform: rotate(45deg) translate(5px, 5px);
    }
    
    .hamburger.active span:nth-child(2) {
        opacity: 0;
    }
    
    .hamburger.active span:nth-child(3) {
        transform: rotate(-45deg) translate(5px, -5px);
    }
    
    .hero-content h1 {
        font-size: 32px;
    }
    
    .hero-content p {
        font-size: 16px;
    }
    
    .section-header h2 {
        font-size: 28px;
    }
    
    .services-grid,
    .portfolio-grid {
        grid-template-columns: 1fr;
    }
    
    .about-text p {
        font-size: 14px;
    }
    
    .stats {
        flex-wrap: wrap;
    }
    
    .stat-item {
        flex: 1 1 100px;
    }
    
    .contact-content {
        grid-template-columns: 1fr;
    }
    
    .footer-content {
        grid-template-columns: 1fr;
        text-align: center;
    }
    
    .footer-section ul {
        padding-left: 0;
    }
    
    .footer-section ul li {
        display: inline-block;
        margin: 0 10px 15px;
    }
}

@media (max-width: 480px) {
    .hero-content h1 {
        font-size: 28px;
    }
    
    .hero-buttons {
        flex-direction: column;
    }
    
    .section-header h2 {
        font-size: 24px;
    }
    
    .section-header p {
        font-size: 14px;
    }
    
    .service-card {
        padding: 20px;
    }
    
    .about-text p {
        font-size: 14px;
    }
    
    .stats {
        gap: 20px;
    }
    
    .contact-form {
        padding: 20px;
    }
    
    .back-to-top {
        width: 45px;
        height: 45px;
        bottom: 20px;
        right: 20px;
    }
}

/* ===== ANIMATIONS ===== */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.service-card,
.portfolio-item,
.about-image,
.about-text,
.contact-form,
.contact-info {
    opacity: 0;
    animation: fadeInUp 0.6s ease forwards;
}

.service-card:nth-child(1) { animation-delay: 0.1s; }
.service-card:nth-child(2) { animation-delay: 0.2s; }
.service-card:nth-child(3) { animation-delay: 0.3s; }
.service-card:nth-child(4) { animation-delay: 0.4s; }
.service-card:nth-child(5) { animation-delay: 0.5s; }
.service-card:nth-child(6) { animation-delay: 0.6s; }

.portfolio-item:nth-child(1) { animation-delay: 0.1s; }
.portfolio-item:nth-child(2) { animation-delay: 0.2s; }
.portfolio-item:nth-child(3) { animation-delay: 0.3s; }
.portfolio-item:nth-child(4) { animation-delay: 0.4s; }
.portfolio-item:nth-child(5) { animation-delay: 0.5s; }
.portfolio-item:nth-child(6) { animation-delay: 0.6s; }
