:root {
    --color-primary: #f68a1e;
    --color-dark: #0f1014;
    --color-bg: #f5f7fb;
    --color-text: #1a1b20;
    --color-muted: #777b86;
    --color-accent: #266cff;
    /* IA */
    --radius-lg: 18px;
    --radius-md: 12px;
    --shadow-soft: 0 18px 45px rgba(15, 16, 20, 0.12);
}

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

html,
body {
    margin: 0;
    padding: 0;
}

body {
    font-family: "Inter", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
    color: var(--color-text);
    background: white;
}

/* Utils */
.container {
    width: 100%;
    max-width: 1120px;
    margin: 0 auto;
    padding: 0 20px;
}

.site-header {
    position: sticky;
    top: 0;
    z-index: 1000;
    width: 100%;
}

.section {
    padding: 80px 0;
}

.section-header {
    text-align: center;
    max-width: 640px;
    margin: 0 auto 40px;
}

.section-header h2 {
    font-family: "Poppins", sans-serif;
    font-size: 32px;
    margin-bottom: 10px;
}

.section-header p {
    color: var(--color-muted);
}

/* Top bar */
.top-bar {
    background: var(--color-dark);
    color: #fff;
    font-size: 13px;
}

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

.top-bar-left span+span {
    margin-left: 16px;
}

/* Navbar */
.navbar {
    background: #ffffff;
    border-bottom: 1px solid #e1e4ef;
    /* Removed sticky from here so the whole header sticks via .site-header */
}

.navbar-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 14px 20px;
    transition: padding 0.3s ease;
}

.navbar.scrolled .navbar-inner {
    padding: 8px 20px;
}

.navbar-logo img {
    height: 44px;
    transition: height 0.3s ease;
}

.navbar.scrolled .navbar-logo img {
    height: 36px;
}

.navbar-menu {
    list-style: none;
    display: flex;
    gap: 20px;
    margin: 0 0 0 auto;
    padding: 0;
}

.navbar-menu a {
    text-decoration: none;
    color: var(--color-muted);
    font-weight: 500;
    font-size: 14px;
}

.navbar-menu a:hover {
    color: var(--color-primary);
}

.navbar-cta {
    margin-left: 20px;
}

.navbar-toggle {
    display: none;
    background: none;
    border: none;
    font-size: 22px;
}

/* Buttons */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 999px;
    border: 1px solid transparent;
    font-weight: 600;
    font-size: 14px;
    padding: 10px 20px;
    text-decoration: none;
    cursor: pointer;
    transition: all 0.15s ease-out;
}

.btn-primary {
    background: linear-gradient(135deg, var(--color-primary), #ffb347);
    color: #fff;
    box-shadow: 0 10px 30px rgba(246, 138, 30, 0.5);
}

.btn-primary:hover {
    transform: translateY(-1px);
    box-shadow: 0 14px 38px rgba(246, 138, 30, 0.6);
}

.btn-outline {
    background: transparent;
    border-color: #d0d4e4;
    color: var(--color-text);
}

.btn-outline:hover {
    border-color: var(--color-primary);
    color: var(--color-primary);
}

.btn-lg {
    padding: 12px 26px;
}

.btn-full {
    width: 100%;
}

.btn-light {
    background: #ffffff;
    color: var(--color-text);
}

/* Hero */
.hero {
    padding: 70px 0 60px;
    background: url('../img/banner_principal.png');
    background-size: cover;
    background-position: center;
}

.hero-inner {
    display: grid;
    grid-template-columns: minmax(0, 2.2fr) minmax(0, 1fr);
    gap: 40px;
    align-items: center;
    max-width: 1280px;
    /* Wider than standard container */
}

.hero-left {
    background: linear-gradient(130deg, rgba(255, 255, 255, 0.546), rgba(255, 255, 255, 0.35));
    padding: 40px;
    border-radius: 30px;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.2);
    backdrop-filter: blur(10px);
    transform: translateX(-200px);
    /* Move box to the left */
}

.hero-badges {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-bottom: 20px;
}

.hero-badge {
    padding: 6px 14px;
    border-radius: 999px;
    font-size: 12px;
    background: #eef1ff;
    color: #0d0c0c90;
}

.hero h1 {
    font-family: "Poppins", sans-serif;
    font-size: 40px;
    line-height: 1.15;
    margin: 0 0 16px;
}

.hero .highlight {
    color: #ffb347;
}

.hero-text {
    color: #0d0c0ce1;
    margin-bottom: 24px;
}

.hero-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    margin-bottom: 28px;
}

.hero-stats {
    display: flex;
    gap: 24px;
    flex-wrap: wrap;
}

.stat-number {
    font-family: "Poppins", sans-serif;
    font-size: 22px;
    font-weight: 600;
}

.stat-label {
    display: block;
    font-size: 13px;
    color: #0d0c0c90;
}

/* Hero right */
.hero-right {
    display: flex;
    justify-content: center;
}

.hero-image-card {
    position: relative;
    border-radius: 26px;
    overflow: hidden;
    box-shadow: var(--shadow-soft);
    background: #000;
}

.hero-image-card img {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.hero-floating-card {
    position: absolute;
    right: 16px;
    left: auto;
    background: #ffffff;
    border-radius: 16px;
    padding: 10px 14px;
    box-shadow: 0 12px 30px rgba(8, 14, 40, 0.25);
    max-width: 220px;
}

.hero-floating-card-top {
    top: 16px;
}

.hero-floating-card-bottom {
    bottom: 16px;
}

.hero-floating-card .small-label {
    margin: 0;
    font-size: 11px;
    text-transform: uppercase;
    color: var(--color-accent);
    letter-spacing: 0.06em;
}

.hero-floating-card .floating-main {
    margin: 4px 0 0;
    font-size: 13px;
}

/* About */
.about {
    background: #ffffff;
}

.about-inner {
    display: grid;
    grid-template-columns: minmax(0, 1.2fr) minmax(0, 1fr);
    gap: 40px;
    align-items: center;
}

.about h2 {
    font-family: "Poppins", sans-serif;
    font-size: 30px;
    margin-bottom: 14px;
}

.about p {
    color: var(--color-muted);
}

.about p+p {
    margin-top: 8px;
}

.about-stats {
    display: flex;
    flex-wrap: wrap;
    gap: 20px;
    margin: 20px 0 24px;
}

.about-stats>div {
    min-width: 120px;
}

/* About image */
.about-image-card {
    position: relative;
    border-radius: 24px;
    overflow: hidden;
    box-shadow: var(--shadow-soft);
}

.about-image-card img {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.about-tag {
    position: absolute;
    bottom: 18px;
    left: 18px;
    background: rgba(15, 16, 20, 0.92);
    color: #fff;
    border-radius: 999px;
    padding: 8px 14px;
    font-size: 12px;
}

/* CTA band */
.cta-band {
    background: linear-gradient(135deg, #ffb347, #ffb347);
    color: #000;
    width: 80%;
    margin: 0 auto;
    border-radius: 50px;
}

.cta-band-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
}

.cta-band h3 {
    margin: 0 0 6px;
    font-family: "Poppins", sans-serif;
    font-size: 24px;
}

.cta-band p {
    margin: 0;
    font-size: 14px;
}

/* Services */
.services {
    background: var(--color-bg);
}

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

.service-card {
    background: #ffffff;
    border-radius: 20px;
    padding: 22px 22px 24px;
    box-shadow: 0 16px 36px rgba(15, 16, 20, 0.08);
}

.service-card h3 {
    font-family: "Poppins", sans-serif;
    font-size: 18px;
    margin-bottom: 8px;
}

.service-card p {
    font-size: 14px;
    color: var(--color-muted);
    margin-bottom: 10px;
}

.service-card ul {
    padding-left: 18px;
    margin: 0;
    font-size: 13px;
    color: var(--color-text);
}

/* Calculator */
.calculator {
    background: #ffffff;
}

.calculator-inner {
    display: grid;
    grid-template-columns: minmax(0, 1.1fr) minmax(0, 1fr);
    gap: 32px;
    align-items: flex-start;
}

.calculator h2 {
    font-family: "Poppins", sans-serif;
    font-size: 28px;
}

.calculator p {
    color: var(--color-muted);
}

.calculator-form {
    background: var(--color-bg);
    border-radius: 24px;
    padding: 22px 20px;
    box-shadow: var(--shadow-soft);
}

.form-row {
    margin-bottom: 16px;
}

.form-row label {
    display: block;
    font-size: 13px;
    font-weight: 500;
    margin-bottom: 6px;
}

.form-row input,
.form-row select,
.form-row textarea {
    width: 100%;
    padding: 10px 11px;
    border-radius: 12px;
    border: 1px solid #ccd0e0;
    font-size: 14px;
    font-family: inherit;
    outline: none;
}

.form-row input:focus,
.form-row select:focus,
.form-row textarea:focus {
    border-color: var(--color-accent);
    box-shadow: 0 0 0 1px rgba(38, 108, 255, 0.16);
}

.calculator-note {
    font-size: 12px;
    color: var(--color-muted);
    margin-top: 8px;
}

/* Instagram placeholder */
.instagram {
    background: #ffffff;
}

.instagram-placeholder {
    border-radius: 20px;
    border: 1px dashed #d4d7e5;
    padding: 40px;
    text-align: center;
    color: var(--color-muted);
}

/* Contact */
.contact {
    background: var(--color-bg);
}

.contact-inner {
    display: grid;
    grid-template-columns: minmax(0, 1.1fr) minmax(0, 1fr);
    gap: 32px;
}

.contact-info h2 {
    font-family: "Poppins", sans-serif;
    font-size: 28px;
    margin-bottom: 10px;
}

.contact-info p {
    color: var(--color-muted);
}

.contact-info ul {
    list-style: none;
    padding: 0;
    margin: 14px 0 0;
    font-size: 14px;
}

.contact-info li+li {
    margin-top: 4px;
}

.contact-form {
    background: #ffffff;
    border-radius: 24px;
    padding: 22px 20px;
    box-shadow: var(--shadow-soft);
}

/* Chat IA Widget */
.ia-chat-widget {
    position: fixed;
    right: 22px;
    bottom: 90px;
    width: 350px;
    max-width: calc(100vw - 44px);
    opacity: 0;
    visibility: hidden;
    transform: translateY(20px) scale(0.95);
    transition: all 0.3s ease;
    z-index: 999;
}

.ia-chat-widget.active {
    opacity: 1;
    visibility: visible;
    transform: translateY(0) scale(1);
}

.chat-card {
    background: #ffffff;
    border-radius: 15px;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.2);
    overflow: hidden;
    display: flex;
    flex-direction: column;
    height: 500px;
}

.chat-header {
    background: linear-gradient(135deg, var(--color-primary), #ffb347);
    color: #fff;
    padding: 15px 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.chat-title {
    margin: 0;
    font-weight: 600;
    font-size: 15px;
}

.chat-close {
    background: none;
    border: none;
    color: #fff;
    font-size: 20px;
    cursor: pointer;
    padding: 0;
    width: 24px;
    height: 24px;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0.9;
    transition: opacity 0.2s;
}

.chat-close:hover {
    opacity: 1;
}

.chat-body {
    flex: 1;
    padding: 20px;
    overflow-y: auto;
    background: #f5f7fb;
}

.chat-message {
    display: flex;
    gap: 10px;
    margin-bottom: 15px;
    align-items: flex-end;
}

.chat-message-bot {
    justify-content: flex-start;
}

.chat-message-user {
    justify-content: flex-end;
}

.chat-avatar {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 20px;
    flex-shrink: 0;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.chat-avatar img {
    width: 28px;
    height: 28px;
    object-fit: contain;
}

.chat-message-user .chat-avatar {
    order: 2;
    background: var(--color-primary);
}

.chat-content {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.chat-message-user .chat-content {
    align-items: flex-end;
}

.chat-message-bot .chat-content {
    align-items: flex-start;
}

.chat-bubble {
    background: rgba(246, 138, 30, 0.15);
    border-radius: 15px;
    padding: 15px 15px;
    max-width: 70%;
}

.chat-message-user .chat-bubble {
    background: #fff;
    border: 1px solid #e1e4ef;
}

.chat-bubble p {
    margin: 0;
    font-size: 14px;
    line-height: 1.5;
    color: var(--color-text);
}

.chat-timestamp {
    font-size: 11px;
    color: var(--color-muted);
    font-style: italic;
}

.chat-start-indicator {
    text-align: center;
    font-size: 11px;
    color: var(--color-muted);
    margin-bottom: 16px;
    font-style: normal;
}

.chat-footer {
    padding: 15px;
    background: #fff;
    border-top: 1px solid #e1e4ef;
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.chat-footer-row {
    display: flex;
    gap: 10px;
}

.chat-input {
    flex: 1;
    border: 1px solid #ccd0e0;
    border-radius: 12px;
    padding: 10px 12px;
    font-size: 14px;
    font-family: inherit;
    resize: none;
    outline: none;
    transition: border-color 0.2s;
}

.chat-input:focus {
    border-color: var(--color-primary);
    box-shadow: 0 0 0 2px rgba(246, 138, 30, 0.1);
}

.chat-send {
    background: linear-gradient(135deg, var(--color-primary), #ffb347);
    color: #fff;
    border: none;
    border-radius: 12px;
    padding: 10px 20px;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: transform 0.2s;
}

.chat-send:hover {
    transform: translateY(-1px);
}

.chat-clear {
    background: none;
    border: none;
    color: var(--color-muted);
    font-size: 13px;
    font-weight: 500;
    cursor: pointer;
    padding: 0;
    align-self: flex-start;
    text-decoration: underline;
}

.chat-clear:hover {
    color: var(--color-primary);
}

/* Chat IA button */
.ia-chat-button {
    position: fixed;
    right: 22px;
    bottom: 22px;
    background: linear-gradient(135deg, var(--color-primary), #ffb347);
    color: #fff;
    border: none;
    border-radius: 999px;
    padding: 14px 24px;
    font-size: 15px;
    font-weight: 600;
    box-shadow: 0 14px 36px rgba(246, 138, 30, 0.4);
    cursor: pointer;
    transition: all 0.3s ease;
    z-index: 1000;
    display: inline-flex;
    align-items: center;
    gap: 8px;
}

.ia-chat-button:hover {
    transform: translateY(-2px);
    box-shadow: 0 18px 42px rgba(246, 138, 30, 0.5);
}

.chat-button-icon {
    width: 20px;
    height: 20px;
    margin-right: 6px;
    vertical-align: middle;
}

.ia-chat-button.hidden {
    opacity: 0;
    visibility: hidden;
    transform: scale(0.8);
}

.chat-notification {
    position: absolute;
    top: -6px;
    right: -6px;
    background: #ff4f4f;
    color: #fff;
    border-radius: 999px;
    font-size: 11px;
    font-weight: 700;
    width: 20px;
    height: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.2);
    transition: transform 0.2s ease, opacity 0.2s ease;
}

.chat-notification.hidden {
    opacity: 0;
    transform: scale(0);
}

/* Footer */
.site-footer {
    background: #0f1014;
    color: #a4a7b3;
    padding: 20px 0;
    margin-top: 40px;
    font-size: 13px;
}

.footer-inner {
    text-align: center;
}

.footer-small {
    margin-top: 4px;
}

/* IA loader */
.ia-loader {
    position: fixed;
    inset: 0;
    background: radial-gradient(circle at top, rgba(15, 16, 20, 0.94), rgba(15, 16, 20, 0.98));
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 1000;
    color: #fff;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.25s ease-out;
}

.ia-loader.active {
    opacity: 1;
    pointer-events: all;
}

.ia-loader-box {
    text-align: center;
}

.ia-loader p {
    margin: 10px 0 4px;
    font-size: 14px;
}

.ia-loader small {
    font-size: 11px;
    color: #b5b9c7;
}

.ia-loader-dots {
    display: inline-flex;
    gap: 6px;
}

.ia-loader-dots span {
    width: 8px;
    height: 8px;
    border-radius: 999px;
    background: #fff;
    opacity: 0.4;
    animation: iaDot 1s infinite ease-in-out;
}

.ia-loader-dots span:nth-child(2) {
    animation-delay: 0.15s;
}

.ia-loader-dots span:nth-child(3) {
    animation-delay: 0.3s;
}

@keyframes iaDot {

    0%,
    60%,
    100% {
        transform: translateY(0);
        opacity: 0.4;
    }

    30% {
        transform: translateY(-5px);
        opacity: 1;
    }
}

/* Responsive */
@media (max-width: 1500px) {
    .hero-left {
        transform: translateX(-60px);
        margin-left: auto;
        margin-right: auto;
    }
}

@media (max-width: 960px) {

    .hero-inner,
    .about-inner,
    .calculator-inner,
    .contact-inner {
        grid-template-columns: minmax(0, 1fr);
    }

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

    .cta-band-inner {
        flex-direction: column;
        align-items: flex-start;
    }

    .hero-left {
        transform: none;
        margin: 0 auto;
        width: 100%;
        padding: 28px;
    }

    .hero-right {
        order: -1;
    }
}

@media (max-width: 768px) {
    .navbar-toggle {
        display: block;
    }

    .navbar-menu {
        position: absolute;
        top: 100%;
        right: 0;
        background: #ffffff;
        padding: 10px 16px 12px;
        flex-direction: column;
        gap: 12px;
        display: none;
        box-shadow: 0 16px 30px rgba(0, 0, 0, 0.12);
    }

    .navbar-menu.open {
        display: flex;
    }

    .navbar-cta {
        display: none;
    }

    .hero {
        padding-top: 40px;
    }

    .hero h1 {
        font-size: 32px;
    }
}

/* Clients Slider */
.clients {
    background: #ffffff;
    overflow: hidden;
}

.clients-slider {
    position: relative;
    width: 80%;
    padding: 20px 0;
    margin-left: 0;
}

.clients-track {
    display: flex;
    gap: 40px;
    width: max-content;
    transition: transform 0.5s ease-in-out;
}

.client-item {
    flex: 0 0 auto;
    width: 150px;
    height: 150px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #fff;
    border-radius: 16px;
}

.client-item img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    transition: transform 0.3s ease;
}

.client-item img:hover {
    transform: scale(1.05);
}
