/* ------------------------------
   RESET BÁSICO
------------------------------ */

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

html {
    scroll-behavior: smooth;
}

html,
body {
    overflow-x: hidden;
}

body {
    margin: 0;
    padding: 0;
    font-family: system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
    background:
        radial-gradient(circle at top, #151821 0%, #0b0e14 42%, #07090d 100%);
    color: #f3f6fb;
    line-height: 1.6;
}

/* ------------------------------
   VARIABLES
------------------------------ */

:root {
    --bg-main: #07090d;
    --bg-soft: #0d1118;
    --bg-card: #10151d;
    --bg-card-alt: #131924;

    --border-subtle: rgba(255, 255, 255, 0.08);
    --border-strong: rgba(255, 255, 255, 0.14);

    --accent: #4fa3ff;
    --accent-strong: #2f7ee6;
    --accent-soft: rgba(79, 163, 255, 0.14);

    --text-main: #f3f6fb;
    --text-muted: #bac4d3;
    --text-soft: #8c97a8;

    --radius-md: 14px;
    --radius-lg: 20px;
    --radius-xl: 28px;

    --shadow-soft: 0 18px 40px rgba(0, 0, 0, 0.32);
    --shadow-card: 0 14px 32px rgba(0, 0, 0, 0.24);

    --container-width: 1160px;
}

/* ------------------------------
   BASE
------------------------------ */

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

section {
    position: relative;
}

h1,
h2,
h3,
h4 {
    margin: 0 0 0.45em;
    font-weight: 650;
    line-height: 1.15;
    letter-spacing: -0.02em;
    color: var(--text-main);
}

p {
    margin: 0 0 1em;
    color: var(--text-muted);
}

a {
    transition: all 0.2s ease;
}

/* ------------------------------
   HEADER
------------------------------ */

.site-header {
    position: sticky;
    top: 0;
    z-index: 50;
    backdrop-filter: blur(14px);
    background: rgba(7, 9, 13, 0.78);
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

.header-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    min-height: 78px;
    gap: 20px;
}

.logo a {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    text-decoration: none;
    padding: 8px 12px;
    border-radius: 999px;
    border: 1px solid rgba(255, 255, 255, 0.08);
    background: rgba(255, 255, 255, 0.02);
}

.logo img {
    display: block;
    max-height: 34px;
    width: auto;
}

.main-nav {
    display: flex;
    align-items: center;
    gap: 22px;
    font-size: 0.95rem;
}

.main-nav a {
    text-decoration: none;
    color: var(--text-soft);
    position: relative;
    padding: 6px 2px;
}

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

.main-nav a::after {
    content: "";
    position: absolute;
    left: 0;
    bottom: -4px;
    width: 0;
    height: 2px;
    border-radius: 999px;
    background: var(--accent);
    transition: width 0.2s ease;
}

.main-nav a:hover::after {
    width: 100%;
}

.btn-nav {
    padding: 10px 16px !important;
    border-radius: 999px;
    border: 1px solid rgba(79, 163, 255, 0.34);
    background: rgba(79, 163, 255, 0.08);
    color: #dceaff !important;
}

.btn-nav:hover {
    background: rgba(79, 163, 255, 0.14);
    border-color: rgba(79, 163, 255, 0.5);
}

/* ------------------------------
   BOTONES
------------------------------ */

.btn-primary,
.btn-secondary {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    min-height: 46px;
    padding: 0 22px;
    border-radius: 999px;
    text-decoration: none;
    font-size: 0.95rem;
    font-weight: 600;
    border: none;
    cursor: pointer;
    white-space: nowrap;
    transition: transform 0.16s ease, box-shadow 0.16s ease, background 0.16s ease, border-color 0.16s ease;
}

.btn-primary {
    background: linear-gradient(135deg, var(--accent), var(--accent-strong));
    color: white;
    box-shadow: 0 12px 28px rgba(47, 126, 230, 0.22);
}

.btn-primary:hover {
    transform: translateY(-1px);
    box-shadow: 0 18px 34px rgba(47, 126, 230, 0.26);
}

.btn-secondary {
    background: rgba(255, 255, 255, 0.03);
    color: var(--text-main);
    border: 1px solid rgba(255, 255, 255, 0.12);
}

.btn-secondary:hover {
    background: rgba(255, 255, 255, 0.06);
    transform: translateY(-1px);
}

button.btn-secondary {
    width: 100%;
}

/* ------------------------------
   HERO
------------------------------ */

.hero {
    padding: 108px 0 84px;
}

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

.hero-text h1 {
    font-size: clamp(2.6rem, 4vw, 4.1rem);
    max-width: 760px;
    margin-bottom: 0.38em;
}

.hero-text p {
    font-size: 1.08rem;
    max-width: 640px;
    color: var(--text-muted);
}

.hero-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 14px;
    margin-top: 1.6rem;
}

.hero-visual {
    display: flex;
    align-items: center;
    justify-content: center;
}

.hero-card.hero-card-img {
    position: relative;
    width: 100%;
    max-width: 520px;
    aspect-ratio: 16 / 10;
    margin-inline: auto;
    padding: 0;
    overflow: hidden;
    border-radius: 30px;
    background:
        linear-gradient(180deg, rgba(255, 255, 255, 0.03), rgba(255, 255, 255, 0.015)),
        linear-gradient(145deg, #111723, #0a0d13);
    border: 1px solid rgba(255, 255, 255, 0.08);
    box-shadow: var(--shadow-soft);
}

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

.hero-card.hero-card-img::before {
    content: "";
    position: absolute;
    inset: 0;
    background:
        linear-gradient(180deg, rgba(255, 255, 255, 0.04), transparent 35%),
        radial-gradient(circle at top right, rgba(79, 163, 255, 0.10), transparent 40%);
    pointer-events: none;
}

.hero-card.hero-card-img::after {
    content: "";
    position: absolute;
    inset: auto 24px 20px 24px;
    height: 1px;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.18), transparent);
    pointer-events: none;
}

/* ------------------------------
   SECCIONES
------------------------------ */

.section {
    padding: 78px 0;
}

.section h2 {
    font-size: clamp(1.7rem, 2vw, 2.2rem);
    margin-bottom: 0.35em;
}

.section-intro {
    max-width: 700px;
    font-size: 1rem;
    color: var(--text-muted);
}

/* ------------------------------
   GRIDS / CARDS
------------------------------ */

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

.card {
    position: relative;
    overflow: hidden;
    padding: 24px 22px;
    border-radius: var(--radius-lg);
    background:
        linear-gradient(180deg, rgba(255, 255, 255, 0.018), rgba(255, 255, 255, 0.008)),
        linear-gradient(145deg, var(--bg-card-alt), var(--bg-card));
    border: 1px solid var(--border-subtle);
    box-shadow: var(--shadow-card);
}

.card::before {
    content: "";
    position: absolute;
    inset: 0 0 auto 0;
    height: 1px;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.14), transparent);
}

.card:hover {
    transform: translateY(-2px);
    border-color: var(--border-strong);
}

.card h3 {
    font-size: 1.08rem;
    margin-bottom: 0.6em;
}

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

.card ul {
    list-style: none;
    padding: 0;
    margin: 0 0 1em;
    color: var(--text-muted);
    font-size: 0.92rem;
}

.card ul li {
    position: relative;
    padding-left: 1.15em;
    margin-bottom: 0.42em;
}

.card ul li::before {
    content: "";
    position: absolute;
    left: 0;
    top: 0.62em;
    width: 6px;
    height: 6px;
    border-radius: 999px;
    background: var(--accent);
    transform: translateY(-50%);
}

.card a {
    color: var(--text-main);
}

.card-cta {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    margin-top: 0.3em;
    font-size: 0.9rem;
    font-weight: 600;
    text-decoration: none;
    color: var(--accent) !important;
}

.card-cta::after {
    content: "↗";
    font-size: 0.8rem;
    opacity: 0.8;
}

/* ------------------------------
   CLIENTES / LOGOS
------------------------------ */

.logos-clientes {
    margin-top: 30px;
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
    gap: 22px;
    align-items: stretch;
}

.logo-item {
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 86px;
    padding: 16px;
    border-radius: 16px;
    text-decoration: none;
    background: rgba(255, 255, 255, 0.025);
    border: 1px solid rgba(255, 255, 255, 0.06);
}

.logo-item:hover {
    background: rgba(255, 255, 255, 0.04);
    border-color: rgba(255, 255, 255, 0.1);
}

.logo-item img {
    max-width: 100%;
    max-height: 46px;
    width: auto;
    object-fit: contain;
    filter: grayscale(100%);
    opacity: 0.82;
    transition: all 0.25s ease;
}

.logo-item:hover img {
    filter: grayscale(0%);
    opacity: 1;
    transform: scale(1.03);
}

.logo-item::after {
    content: attr(data-name);
    position: absolute;
    bottom: -26px;
    left: 50%;
    transform: translateX(-50%);
    padding: 4px 10px;
    border-radius: 999px;
    background: rgba(11, 14, 20, 0.96);
    border: 1px solid rgba(255, 255, 255, 0.08);
    color: var(--text-main);
    font-size: 0.72rem;
    white-space: nowrap;
    opacity: 0;
    pointer-events: none;
    transition: all 0.2s ease;
}

.logo-item:hover::after {
    opacity: 1;
    transform: translateX(-50%) translateY(-2px);
}

/* ------------------------------
   CONTACTO
------------------------------ */

.section-contact .contact-header {
    margin-bottom: 10px;
}

#contacto .contact-grid {
    display: grid;
    grid-template-columns: minmax(0, 1.05fr) minmax(0, 1fr);
    gap: 30px;
    margin-top: 28px;
    align-items: start;
}

.contact-options {
    font-size: 0.96rem;
}

.contact-tag {
    display: inline-flex;
    align-items: center;
    padding: 5px 10px;
    border-radius: 999px;
    margin-bottom: 12px;
    background: rgba(79, 163, 255, 0.08);
    border: 1px solid rgba(79, 163, 255, 0.18);
    color: #dceaff;
    text-transform: uppercase;
    letter-spacing: 0.11em;
    font-size: 0.73rem;
    font-weight: 600;
}

.contact-note {
    margin-top: 14px;
    font-size: 0.88rem;
    color: var(--text-soft);
}

.contact-form {
    padding: 22px;
    border-radius: var(--radius-lg);
    background:
        linear-gradient(180deg, rgba(255, 255, 255, 0.02), rgba(255, 255, 255, 0.01)),
        linear-gradient(145deg, #111620, #0b0f16);
    border: 1px solid var(--border-subtle);
    box-shadow: var(--shadow-card);
}

.contact-form-title {
    margin: 0 0 12px;
    font-size: 1rem;
}

.contact-form input,
.contact-form textarea {
    width: 100%;
    margin-bottom: 12px;
    padding: 12px 13px;
    border-radius: 12px;
    border: 1px solid rgba(255, 255, 255, 0.08);
    background: rgba(255, 255, 255, 0.02);
    color: var(--text-main);
    font-family: inherit;
    font-size: 0.94rem;
}

.contact-form input::placeholder,
.contact-form textarea::placeholder {
    color: var(--text-soft);
}

.contact-form input:focus,
.contact-form textarea:focus {
    outline: none;
    border-color: rgba(79, 163, 255, 0.5);
    box-shadow: 0 0 0 3px rgba(79, 163, 255, 0.12);
}

.contact-form-note {
    margin: 8px 0 0;
    font-size: 0.82rem;
    color: var(--text-soft);
}

.contact-alert {
    position: fixed;
    left: 50%;
    bottom: 20px;
    transform: translateX(-50%);
    z-index: 9999;
    padding: 12px 18px;
    border-radius: 999px;
    background: rgba(12, 15, 22, 0.96);
    border: 1px solid rgba(255, 255, 255, 0.08);
    color: var(--text-main);
    box-shadow: 0 18px 40px rgba(0, 0, 0, 0.26);
    font-size: 0.88rem;
}

/* ------------------------------
   FOOTER
------------------------------ */

.site-footer {
    padding: 22px 0 28px;
    text-align: center;
    font-size: 0.84rem;
    color: var(--text-soft);
    border-top: 1px solid rgba(255, 255, 255, 0.05);
    background: rgba(255, 255, 255, 0.01);
}

/* ------------------------------
   RESPONSIVE
------------------------------ */

@media (max-width: 960px) {
    .hero-inner {
        grid-template-columns: 1fr;
        gap: 34px;
    }

    .hero-visual {
        order: -1;
    }

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

    #contacto .contact-grid {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 720px) {
    .header-inner {
        flex-wrap: wrap;
        padding: 12px 0;
    }

    .main-nav {
        width: 100%;
        flex-wrap: wrap;
        justify-content: flex-start;
        gap: 10px 16px;
        font-size: 0.88rem;
    }

    .hero {
        padding: 78px 0 56px;
    }

    .hero-text h1 {
        font-size: 2.2rem;
    }

    .section {
        padding: 56px 0;
    }

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

@media (max-width: 480px) {
    .container {
        padding: 0 18px;
    }

    .hero-actions {
        flex-direction: column;
        align-items: stretch;
    }

    .btn-primary,
    .btn-secondary {
        width: 100%;
    }
}