:root {
    --bg: #020c1b;
    --bg-light: #0a192f;
    --bg-card: rgba(10, 25, 47, 0.72);
    --primary: #64ffda;
    --primary-2: #48b1bf;
    --primary-glow: rgba(100, 255, 218, 0.25);
    --title: #e6f1ff;
    --text: #8892b0;
    --white: #ffffff;
    --border-soft: rgba(100, 255, 218, 0.1);
    --border-strong: rgba(100, 255, 218, 0.2);
    --shadow-soft: 0 20px 40px rgba(2, 12, 27, 0.45);
    --transition: all 0.35s ease;
}

*,
*::before,
*::after {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
    overflow-x: hidden;
}

body {
    margin: 0;
    padding: 0;
    background-color: transparent;
    color: var(--text);
    font-family: 'Inter', sans-serif;
    line-height: 1.75;
    overflow-x: hidden;
    max-width: 100%;
}

h1,
h2,
h3,
h4,
h5,
h6,
.logo {
    font-family: 'Poppins', sans-serif;
    color: var(--title);
    margin-bottom: 0;
}

a {
    text-decoration: none;
}

img {
    max-width: 100%;
    display: block;
    -webkit-user-select: none;
    user-select: none;
    pointer-events: auto;
}

#particles-js {
    position: fixed;
    inset: 0;
    z-index: 0;
    background-color: var(--bg);
    pointer-events: none;
    overflow: hidden;
}

section,
header,
footer,
main,
.modal {
    position: relative;
    z-index: 2;
}

.site-main,
.portfolio-page-main,
.hero,
section,
footer {
    overflow-x: clip;
}

.bg-dark-custom {
    background: transparent;
}

.text-secondary {
    color: var(--text) !important;
}

.gradient {
    background: linear-gradient(90deg, var(--primary), var(--primary-2));
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
}

.top-tag {
    color: var(--primary);
    font-size: 0.82rem;
    letter-spacing: 4px;
    text-transform: uppercase;
    font-weight: 800;
}

.glass-card {
    background: var(--bg-card);
    border: 1px solid var(--border-soft);
    border-radius: 18px;
    -webkit-backdrop-filter: blur(12px);
    backdrop-filter: blur(12px);
    box-shadow: var(--shadow-soft);
}

.btn-main,
.btn-ia-special,
.view-project-btn,
.btn-home {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    border-radius: 8px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1px;
    transition: var(--transition);
    cursor: pointer;
    max-width: 100%;
    text-align: center;
}

.btn-main {
    padding: 14px 28px;
    border: 1px solid var(--primary);
    color: var(--primary);
    background: transparent;
    font-size: 0.86rem;
}

.btn-main:hover {
    background: rgba(100, 255, 218, 0.08);
    color: var(--primary);
    box-shadow: 0 0 20px var(--primary-glow);
    transform: translateY(-2px);
}

.btn-ia-special {
    padding: 14px 28px;
    background: var(--primary);
    color: var(--bg);
    border: 1px solid var(--primary);
    box-shadow: 0 0 18px var(--primary-glow);
    font-size: 0.86rem;
}

.btn-ia-special:hover {
    background: transparent;
    color: var(--primary);
}

.view-project-btn,
.btn-home {
    padding: 12px 22px;
    border: 1px solid var(--primary);
    color: var(--primary);
    background: transparent;
    font-size: 0.84rem;
}

.view-project-btn:hover,
.btn-home:hover {
    background: var(--primary);
    color: var(--bg);
    box-shadow: 0 0 15px var(--primary-glow);
}

.container {
    padding-left: 16px;
    padding-right: 16px;
}

header.navbar {
    padding: 16px 0;
    background: rgba(2, 12, 27, 0.88);
    -webkit-backdrop-filter: blur(15px);
    backdrop-filter: blur(15px);
    border-bottom: 1px solid rgba(100, 255, 218, 0.06);
    overflow-x: clip;
}

.navbar-brand.logo {
    display: inline-flex;
    flex-direction: column;
    line-height: 1;
    gap: 6px;
    max-width: 100%;
}

.navbar-brand.logo .main-name {
    font-size: 2.15rem;
    font-weight: 900;
    letter-spacing: -1.6px;
    line-height: 0.92;
    color: var(--white);
}

.navbar-brand.logo .sub-text {
    font-size: 0.68rem;
    font-weight: 600;
    letter-spacing: 2.4px;
    line-height: 1.15;
    text-transform: uppercase;
    color: var(--primary);
}

.nav-link {
    color: var(--title) !important;
    font-size: 0.96rem;
    font-weight: 600;
    letter-spacing: 0.4px;
    margin: 0 12px;
    opacity: 0.84;
    transition: var(--transition);
}

.nav-link:hover {
    opacity: 1;
    color: var(--primary) !important;
}

.navbar-toggler {
    border-color: rgba(100, 255, 218, 0.2);
}

.navbar-toggler:focus {
    box-shadow: 0 0 0 0.15rem rgba(100, 255, 218, 0.2);
}

.navbar-toggler-icon {
    filter: invert(1);
}

.site-main,
.portfolio-page-main {
    width: 100%;
    max-width: 100%;
}

section {
    padding: 80px 0;
    width: 100%;
    max-width: 100%;
}

.row > * {
    min-width: 0;
}

.hero {
    min-height: 100vh;
    display: flex;
    align-items: center;
    padding-top: 140px;
    padding-bottom: 70px;
    width: 100%;
    max-width: 100%;
}

.hero .row {
    align-items: center;
}

.hero-title,
.hero h1 {
    font-size: clamp(2.6rem, 5vw, 5rem);
    line-height: 1.02;
    letter-spacing: -1.6px;
    max-width: 760px;
    word-break: break-word;
    overflow-wrap: break-word;
}

.hero-description,
.hero .lead {
    font-size: 1.1rem;
    line-height: 1.75;
    max-width: 660px;
    margin-top: 1.75rem;
    margin-bottom: 1.75rem;
}

.hero-content .top-tag {
    margin-bottom: 1rem !important;
}

.cta-hero {
    margin-top: 2rem !important;
}

.hero-photo-box {
    width: 100%;
    max-width: 460px;
    padding: 20px;
    border-radius: 28px;
    background: linear-gradient(180deg, rgba(100, 255, 218, 0.08), rgba(72, 177, 191, 0.03));
    border: 1px solid rgba(100, 255, 218, 0.14);
    -webkit-backdrop-filter: blur(14px);
    backdrop-filter: blur(14px);
    box-shadow: 0 24px 50px rgba(0, 0, 0, 0.35);
    overflow: hidden;
}

.hero-photo {
    width: 100%;
    aspect-ratio: 1 / 1.12;
    object-fit: cover;
    object-position: center top;
    border-radius: 22px;
    border: 1px solid rgba(100, 255, 218, 0.12);
}

.stats-grid .stat-item {
    border-left: 1px solid var(--primary);
    padding-left: 20px;
}

.stat-item strong {
    display: block;
    color: var(--white);
    margin-bottom: 8px;
    font-size: 1.08rem;
}

.stat-item span {
    display: block;
    font-size: 0.92rem;
    line-height: 1.65;
}

.portfolio-card {
    background: var(--bg-light);
    border-radius: 16px;
    overflow: hidden;
    border: 1px solid rgba(100, 255, 218, 0.1);
    transition: var(--transition);
    height: 100%;
    box-shadow: var(--shadow-soft);
}

.portfolio-card:hover {
    transform: translateY(-8px);
    border-color: var(--primary);
}

.portfolio-img-wrapper {
    position: relative;
    overflow: hidden;
}

.portfolio-img-wrapper img {
    width: 100%;
    transition: var(--transition);
}

.portfolio-card:hover .portfolio-img-wrapper img {
    transform: scale(1.05);
}

.portfolio-body h4 {
    color: var(--white);
    font-size: 1.18rem;
    line-height: 1.35;
}

.brand-grid {
    display: grid;
    grid-template-columns: repeat(6, minmax(0, 1fr));
    gap: 16px;
    width: 100%;
}

.brand-badge {
    background: rgba(10, 25, 47, 0.7);
    border: 1px solid rgba(100, 255, 218, 0.1);
    border-radius: 14px;
    padding: 15px 16px;
    text-align: center;
    color: var(--title);
    font-weight: 600;
    font-size: 0.92rem;
    transition: var(--transition);
    min-width: 0;
}

.brand-badge:hover {
    border-color: var(--primary);
    transform: translateY(-3px);
}

.cta-box {
    padding: 42px;
    border-radius: 24px;
    border: 1px solid rgba(100, 255, 218, 0.16);
    background: linear-gradient(135deg, rgba(100, 255, 218, 0.07), rgba(72, 177, 191, 0.03));
    box-shadow: var(--shadow-soft);
    -webkit-backdrop-filter: blur(12px);
    backdrop-filter: blur(12px);
    overflow: hidden;
}

.cta-box h2 {
    font-size: clamp(1.9rem, 4vw, 2.9rem);
    line-height: 1.12;
    overflow-wrap: break-word;
}

.contact-image-box {
    min-height: 340px;
    border: 1px solid rgba(100, 255, 218, 0.08);
    background: rgba(10, 25, 47, 0.35);
    overflow: hidden;
}

.object-fit-cover {
    object-fit: cover;
}

#form-contato .form-control {
    background: rgba(10, 25, 47, 0.4) !important;
    border: 1px solid rgba(100, 255, 218, 0.2) !important;
    color: var(--white) !important;
    padding: 14px 16px;
    border-radius: 8px;
    transition: var(--transition);
    font-size: 1rem;
    max-width: 100%;
}

#form-contato .form-control:focus {
    background: rgba(10, 25, 47, 0.7) !important;
    border-color: var(--primary) !important;
    box-shadow: 0 0 10px var(--primary-glow) !important;
    outline: none;
}

#form-contato .form-control::placeholder {
    color: rgba(136, 146, 176, 0.6);
}

#form-contato label {
    color: var(--primary);
    font-size: 0.88rem;
    font-weight: 700;
    margin-bottom: 8px;
    text-transform: uppercase;
    letter-spacing: 1.1px;
}

input,
textarea {
    -webkit-user-select: text !important;
    -moz-user-select: text !important;
    -ms-user-select: text !important;
    user-select: text !important;
}

.btn-form-submit {
    width: 100%;
    margin-top: 12px;
    padding: 16px;
    font-size: 1rem;
}

.footer {
    background: #020c1b;
    border-top: 1px solid rgba(100, 255, 218, 0.05);
    overflow-x: clip;
}

.footer .navbar-brand.logo .main-name {
    font-size: 2rem;
}

.footer .navbar-brand.logo .sub-text {
    font-size: 0.66rem;
    letter-spacing: 2.4px;
}

.footer-title {
    font-size: 0.84rem;
    text-transform: uppercase;
    letter-spacing: 3px;
    color: var(--white);
    margin-bottom: 1.5rem;
}

.footer-links-premium li + li {
    margin-top: 10px;
}

.footer-links-premium a {
    color: var(--text);
    transition: 0.3s;
    font-size: 0.98rem;
}

.footer-links-premium a:hover {
    color: var(--primary);
    padding-left: 10px;
}

.footer-social-icons {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-top: 20px;
    flex-wrap: wrap;
}

.footer-social-icons .view-project-btn {
    width: 46px;
    height: 46px;
    padding: 0;
    border-radius: 50%;
}

.footer-bottom {
    border-top: 1px solid rgba(100, 255, 218, 0.08);
}

.ai-status-badge {
    background: rgba(100, 255, 218, 0.05);
    padding: 10px 20px;
    border-radius: 50px;
    font-size: 0.95rem;
    color: var(--text);
    border: 1px solid var(--primary-glow);
    display: inline-flex;
    align-items: center;
    gap: 10px;
    max-width: 100%;
}

.pulse-dot {
    width: 8px;
    height: 8px;
    background: var(--primary);
    border-radius: 50%;
    box-shadow: 0 0 10px var(--primary);
    animation: pulse-ia 2s infinite;
}

@keyframes pulse-ia {
    0% {
        transform: scale(0.9);
        opacity: 1;
    }
    50% {
        transform: scale(1.5);
        opacity: 0.4;
    }
    100% {
        transform: scale(0.9);
        opacity: 1;
    }
}

.modal {
    z-index: 10000 !important;
}

.modal-backdrop {
    z-index: 9999 !important;
}

.modal-content {
    background: var(--bg-light);
    border: 1px solid var(--primary);
    border-radius: 12px;
    box-shadow: 0 0 40px rgba(0, 0, 0, 0.8);
    -webkit-backdrop-filter: blur(20px);
    backdrop-filter: blur(20px);
    overflow: hidden;
}

.btn-close-custom {
    position: absolute;
    top: 20px;
    right: 20px;
    background: transparent;
    border: none;
    color: var(--primary);
    font-size: 1.5rem;
    z-index: 10001;
    cursor: pointer;
    line-height: 1;
}

#back-to-top {
    position: fixed;
    bottom: 30px;
    right: 30px;
    width: 52px;
    height: 52px;
    background: var(--bg-light);
    color: var(--primary);
    border: 1px solid var(--primary);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    z-index: 10001;
    transition: var(--transition);
    opacity: 0;
    visibility: hidden;
    transform: translateY(20px);
    box-shadow: 0 0 15px var(--primary-glow);
}

#back-to-top.active {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

#back-to-top:hover {
    background: var(--primary);
    color: var(--bg);
}

.legal-card {
    background: rgba(10, 25, 47, 0.9) !important;
    padding: 50px;
    border-radius: 20px;
    border: 1px solid rgba(100, 255, 218, 0.1);
    -webkit-backdrop-filter: blur(10px);
    backdrop-filter: blur(10px);
    color: var(--white) !important;
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.35);
    overflow: hidden;
}

.legal-text-content h2 {
    margin-top: 2rem;
    margin-bottom: 1rem;
    color: var(--primary);
    font-size: 1.3rem;
    font-weight: 700;
}

.legal-text-content p,
.legal-text-content li {
    color: var(--title);
    margin-bottom: 1rem;
    font-size: 1rem;
    line-height: 1.8;
}

#custom-cursor {
    width: 20px;
    height: 20px;
    border: 2px solid var(--primary);
    border-radius: 50%;
    position: fixed;
    pointer-events: none;
    z-index: 99999;
    transition: width 0.3s, height 0.3s, transform 0.08s linear;
}

body.protected {
    -webkit-user-select: none;
    -moz-user-select: none;
    -ms-user-select: none;
    user-select: none;
}

.error-section {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
}

.error-code {
    font-size: clamp(8rem, 20vw, 12rem);
    font-weight: 800;
    line-height: 1;
    background: linear-gradient(180deg, var(--primary) 0%, transparent 100%);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    opacity: 0.35;
    margin-bottom: -2rem;
    font-family: 'Poppins', sans-serif;
}

.error-title {
    font-size: 2.2rem;
    color: var(--white);
    margin-bottom: 1.5rem;
}

.error-text {
    max-width: 560px;
    margin: 0 auto 2rem;
    color: var(--text);
    font-size: 1.04rem;
    line-height: 1.8;
}

.timeline {
    display: grid;
    gap: 22px;
}

.timeline-item {
    padding: 28px;
    border-radius: 18px;
    background: var(--bg-card);
    border: 1px solid var(--border-soft);
    box-shadow: var(--shadow-soft);
    overflow: hidden;
}

.timeline-top {
    display: flex;
    flex-wrap: wrap;
    justify-content: space-between;
    gap: 12px;
    margin-bottom: 8px;
}

.timeline-role {
    color: var(--white);
    font-weight: 700;
    font-size: 1.08rem;
}

.timeline-date {
    color: var(--primary);
    font-weight: 700;
    font-size: 0.94rem;
}

.timeline-company {
    color: var(--title);
    font-weight: 600;
    margin-bottom: 10px;
    font-size: 1rem;
}

.tag-row {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}

.tag {
    padding: 9px 13px;
    border-radius: 999px;
    border: 1px solid rgba(100, 255, 218, 0.15);
    background: rgba(100, 255, 218, 0.05);
    color: var(--title);
    font-size: 0.88rem;
    font-weight: 500;
    max-width: 100%;
}

.section-header h2,
section h2.display-5,
section h2.display-6 {
    line-height: 1.12;
    letter-spacing: -1px;
}

.section-header p,
section p.text-secondary,
section .text-secondary {
    font-size: 1rem;
}

#page-loader {
    position: fixed;
    inset: 0;
    background: #0a0a0a;
    z-index: 99999;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: opacity 0.5s ease, visibility 0.5s;
}

.logo-loader {
    font-size: 2.5rem;
    font-weight: bold;
    color: #fff;
    letter-spacing: 2px;
    font-family: 'Poppins', sans-serif;
}

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

.loader-bar {
    width: 150px;
    height: 3px;
    background: rgba(255, 255, 255, 0.1);
    margin: 20px auto 0;
    position: relative;
    overflow: hidden;
    border-radius: 5px;
}

.loader-bar::after {
    content: '';
    position: absolute;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, #00ff88, transparent);
    animation: loading 1.5s infinite;
}

@keyframes loading {
    100% {
        left: 100%;
    }
}

.loader-hidden {
    opacity: 0;
    visibility: hidden;
}

@media (max-width: 1199.98px) {
    .hero-title,
    .hero h1 {
        font-size: clamp(2.5rem, 6vw, 4.4rem);
    }

    .hero-photo-box {
        max-width: 420px;
    }
}

@media (max-width: 991.98px) {
    .navbar-collapse {
        margin-top: 18px;
        padding: 18px 0 8px;
        border-top: 1px solid rgba(100, 255, 218, 0.08);
    }

    .nav-link {
        margin: 8px 0;
    }

    .brand-grid {
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }

    .hero {
        min-height: unset;
        padding-top: 130px;
        padding-bottom: 60px;
        text-align: center;
    }

    .hero .row {
        min-height: unset;
    }

    .hero-title,
    .hero h1,
    .hero .lead,
    .hero-description {
        max-width: 100%;
        margin-left: auto;
        margin-right: auto;
    }

    .hero-photo-box {
        max-width: 360px;
    }

    .cta-hero {
        justify-content: center;
    }
}

@media (max-width: 767.98px) {
    section {
        padding: 64px 0;
    }

    .navbar-brand.logo .main-name {
        font-size: 1.9rem;
    }

    .navbar-brand.logo .sub-text {
        font-size: 0.58rem;
        letter-spacing: 2px;
    }

    .brand-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .legal-card,
    .cta-box,
    .timeline-item {
        padding: 26px;
    }

    .hero-title,
    .hero h1 {
        font-size: clamp(2.2rem, 9vw, 3.7rem);
        line-height: 1.04;
        letter-spacing: -1.2px;
    }

    .hero .lead,
    .hero-description {
        font-size: 1.02rem;
    }

    .hero-photo-box {
        max-width: 300px;
        padding: 16px;
    }

    .top-tag {
        font-size: 0.74rem;
        letter-spacing: 3.2px;
    }
}

@media (max-width: 575.98px) {
    .btn-main,
    .btn-ia-special,
    .view-project-btn,
    .btn-home {
        width: 100%;
    }

    .brand-grid {
        grid-template-columns: 1fr;
    }

    .legal-card {
        padding: 22px;
    }

    .hero {
        padding-top: 115px;
        padding-bottom: 50px;
    }

    .cta-hero {
        gap: 12px !important;
    }

    .container {
        padding-left: 14px;
        padding-right: 14px;
    }
}