:root {
    --brand-navy: #123c69;
    --brand-navy-dark: #0b294b;
    --brand-blue: #246fa8;
    --brand-sky: #e8f3fb;
    --brand-mint: #dff3ec;
    --brand-green: #24745a;
    --brand-amber: #f0a23a;
    --ink: #17212b;
    --ink-soft: #586573;
    --surface: #ffffff;
    --surface-soft: #f5f8fb;
    --border: #dce5ec;
    --shadow-sm: 0 8px 24px rgba(18, 60, 105, 0.08);
    --shadow-md: 0 20px 55px rgba(18, 60, 105, 0.13);
    --radius-sm: 12px;
    --radius-md: 20px;
    --radius-lg: 30px;
}

html {
    position: relative;
    min-height: 100%;
    font-size: 16px;
    scroll-behavior: smooth;
}

body {
    min-height: 100vh;
    margin: 0;
    color: var(--ink);
    background: var(--surface-soft);
    font-family: Inter, ui-sans-serif, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
    line-height: 1.55;
    text-rendering: optimizeLegibility;
}

h1,
h2,
h3,
h4,
h5,
h6 {
    color: var(--brand-navy-dark);
    font-weight: 750;
    letter-spacing: -0.025em;
}

h1 {
    font-size: clamp(2rem, 4vw, 3.65rem);
    line-height: 1.07;
}

h2 {
    line-height: 1.15;
}

a {
    color: var(--brand-blue);
    text-underline-offset: 3px;
}

a:hover {
    color: var(--brand-navy-dark);
}

.site-header {
    position: sticky;
    top: 0;
    z-index: 1030;
    background: rgba(255, 255, 255, 0.94);
    border-bottom: 1px solid rgba(220, 229, 236, 0.9);
    backdrop-filter: blur(12px);
}

.site-header .navbar {
    min-height: 76px;
    padding: 0.65rem 0;
}

.brand-lockup {
    display: inline-flex;
    align-items: center;
    padding: 0;
}

.brand-lockup img {
    display: block;
    max-width: 176px;
    height: auto;
}

.site-header .nav-link {
    padding: 0.65rem 0.85rem !important;
    color: #364553;
    border-radius: 10px;
    font-size: 0.94rem;
    font-weight: 650;
}

.site-header .nav-link:hover,
.site-header .nav-link:focus {
    color: var(--brand-navy);
    background: var(--brand-sky);
}

.site-header .nav-link-methodology {
    color: var(--brand-navy);
    border: 1px solid #bfd5e6;
}

.site-main {
    min-height: calc(100vh - 340px);
}

.site-main > .container,
.site-main > div > .container {
    max-width: 1140px;
}

.home-hero {
    overflow: hidden;
    padding: clamp(4rem, 8vw, 7.5rem) 0;
    background:
        radial-gradient(circle at 92% 15%, rgba(36, 111, 168, 0.15), transparent 30%),
        linear-gradient(145deg, #ffffff 10%, #eef6fb 100%);
}

.eyebrow {
    display: inline-flex;
    align-items: center;
    margin-bottom: 1rem;
    color: var(--brand-green);
    font-size: 0.78rem;
    font-weight: 800;
    letter-spacing: 0.12em;
    text-transform: uppercase;
}

.hero-copy {
    max-width: 620px;
    margin: 1.35rem 0 1.8rem;
    color: var(--ink-soft);
    font-size: clamp(1.08rem, 2vw, 1.28rem);
}

.hero-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 0.8rem;
}

.trust-row {
    display: flex;
    flex-wrap: wrap;
    gap: 0.65rem 1.25rem;
    margin-top: 1.8rem;
    color: #4a5b69;
    font-size: 0.9rem;
    font-weight: 650;
}

.trust-row span::before {
    content: "✓";
    margin-right: 0.45rem;
    color: var(--brand-green);
    font-weight: 900;
}

.hero-visual {
    padding: 1rem;
    filter: drop-shadow(0 28px 48px rgba(18, 60, 105, 0.14));
}

.category-section,
.how-it-works {
    padding: clamp(4rem, 7vw, 6.5rem) 0;
}

.category-section {
    background: var(--surface);
}

.section-heading {
    max-width: 680px;
    margin-bottom: 2.5rem;
}

.section-heading h2 {
    margin-bottom: 0.85rem;
    font-size: clamp(1.9rem, 3vw, 2.7rem);
}

.section-heading p {
    margin: 0;
    color: var(--ink-soft);
    font-size: 1.08rem;
}

.section-heading-centered {
    margin-right: auto;
    margin-left: auto;
    text-align: center;
}

.category-card {
    position: relative;
    height: 100%;
    overflow: hidden;
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--radius-md);
    box-shadow: var(--shadow-sm);
    transition: transform 180ms ease, box-shadow 180ms ease, border-color 180ms ease;
}

.category-card:hover {
    transform: translateY(-6px);
    border-color: #b8cfdf;
    box-shadow: var(--shadow-md);
}

.category-card-featured {
    border-color: #9ec8ba;
}

.category-image {
    display: grid;
    min-height: 190px;
    place-items: center;
}

.category-image-air {
    background: #e8f3fb;
}

.category-image-paint {
    background: #fff1dd;
}

.category-image-flooring {
    background: #e6f3ee;
}

.category-card-body {
    padding: 1.55rem;
}

.category-status {
    display: inline-flex;
    margin-bottom: 0.75rem;
    padding: 0.32rem 0.65rem;
    color: var(--brand-green);
    background: var(--brand-mint);
    border-radius: 999px;
    font-size: 0.72rem;
    font-weight: 800;
    letter-spacing: 0.04em;
    text-transform: uppercase;
}

.category-card h3 {
    margin-bottom: 0.7rem;
    font-size: 1.38rem;
}

.category-card p {
    min-height: 78px;
    color: var(--ink-soft);
}

.category-card a {
    font-weight: 750;
    text-decoration: none;
}

.how-it-works {
    background: var(--surface-soft);
}

.steps-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1.25rem;
}

.process-step {
    padding: 2rem;
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--radius-md);
}

.step-number {
    display: grid;
    width: 44px;
    height: 44px;
    margin-bottom: 1.15rem;
    color: #ffffff;
    background: var(--brand-navy);
    border-radius: 13px;
    place-items: center;
    font-weight: 800;
}

.process-step h3 {
    font-size: 1.18rem;
}

.process-step p {
    margin-bottom: 0;
    color: var(--ink-soft);
}

.btn {
    border-radius: 11px;
    font-weight: 720;
    transition: transform 140ms ease, box-shadow 140ms ease, background-color 140ms ease;
}

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

.btn-primary {
    color: #ffffff;
    background: var(--brand-navy);
    border-color: var(--brand-navy);
    box-shadow: 0 8px 18px rgba(18, 60, 105, 0.18);
}

.btn-primary:hover,
.btn-primary:focus {
    color: #ffffff;
    background: var(--brand-navy-dark);
    border-color: var(--brand-navy-dark);
}

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

.btn-outline-primary:hover {
    color: #ffffff;
    background: var(--brand-navy);
    border-color: var(--brand-navy);
}

.btn-outline-secondary {
    color: #3e5161;
    border-color: #aebdc8;
}

.form-control,
.form-select,
.input-group-text {
    min-height: 48px;
    border-color: #cdd9e2;
    border-radius: 10px;
}

.form-control,
.form-select {
    background-color: #ffffff;
}

.form-control:focus,
.form-select:focus,
.form-check-input:focus {
    border-color: #6ea6cc;
    box-shadow: 0 0 0 0.22rem rgba(36, 111, 168, 0.14);
}

.form-label {
    color: #2f3f4c;
    font-weight: 700;
}

.form-text {
    color: #687784;
}

.form-check-input:checked {
    background-color: var(--brand-navy);
    border-color: var(--brand-navy);
}

.card {
    border: 1px solid var(--border);
    border-radius: var(--radius-md);
    box-shadow: var(--shadow-sm);
}

.card-body {
    padding: clamp(1.35rem, 3vw, 2rem);
}

.alert {
    border: 0;
    border-radius: var(--radius-sm);
}

.table {
    --bs-table-bg: transparent;
}

.site-main .container.py-4 {
    padding-top: clamp(2.5rem, 6vw, 4.5rem) !important;
    padding-bottom: clamp(3.5rem, 7vw, 6rem) !important;
}

.site-main .lead {
    color: var(--ink-soft);
}

.site-footer {
    padding: 3.5rem 0 1.5rem;
    color: rgba(255, 255, 255, 0.78);
    background: var(--brand-navy-dark);
}

.footer-grid {
    display: grid;
    grid-template-columns: minmax(0, 1.5fr) minmax(220px, 1fr);
    gap: 2rem;
    align-items: start;
}

.footer-description {
    max-width: 430px;
    margin: 1rem 0 0;
}

.footer-links {
    display: flex;
    flex-wrap: wrap;
    justify-content: flex-end;
    gap: 0.75rem 1.4rem;
}

.footer-links a {
    color: rgba(255, 255, 255, 0.86);
    font-weight: 650;
    text-decoration: none;
}

.footer-links a:hover {
    color: #ffffff;
}

.footer-bottom {
    display: flex;
    justify-content: space-between;
    gap: 1rem;
    margin-top: 2.5rem;
    padding-top: 1.4rem;
    border-top: 1px solid rgba(255, 255, 255, 0.13);
    font-size: 0.86rem;
}

@media (max-width: 991.98px) {
    .site-header .navbar-collapse {
        padding: 1rem 0 0.5rem;
    }

    .site-header .nav-link {
        margin-bottom: 0.25rem;
    }

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

@media (max-width: 767.98px) {
    h1 {
        font-size: 2.35rem;
    }

    .home-hero {
        padding-top: 3.5rem;
    }

    .hero-actions .btn {
        width: 100%;
    }

    .category-card p {
        min-height: auto;
    }

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

    .footer-links {
        justify-content: flex-start;
    }

    .footer-bottom {
        flex-direction: column;
    }
}

@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        scroll-behavior: auto !important;
        transition-duration: 0.01ms !important;
    }
}


/* Ajustes consolidados 1.3.0 */
.category-image-heating {
    background: #fff1dd;
}

.contact-cta {
    padding: 0 0 clamp(4rem, 7vw, 6.5rem);
    background: var(--surface);
}

.contact-cta-card {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 2rem;
    padding: clamp(1.5rem, 4vw, 2.5rem);
    background: linear-gradient(135deg, #edf6fb, #ffffff);
    border: 1px solid var(--border);
    border-radius: var(--radius-md);
    box-shadow: var(--shadow-sm);
}

.contact-cta-card h2 {
    margin-bottom: 0.65rem;
}

.contact-cta-card p {
    margin-bottom: 0;
    color: var(--ink-soft);
}

.contact-card,
.recommendation-panel {
    padding: 1.25rem;
    background: #ffffff;
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    box-shadow: var(--shadow-sm);
}

.recommendation-panel {
    display: flex;
    flex-direction: column;
    min-height: 78px;
    justify-content: center;
}

.recommendation-panel strong {
    color: var(--brand-navy);
    font-size: 1.25rem;
}

.result-focus-target {
    scroll-margin-top: 110px;
    transition: box-shadow 220ms ease, transform 220ms ease;
}

.result-focus-target:focus {
    outline: none;
}

.result-focus-visible {
    box-shadow: 0 0 0 4px rgba(36, 111, 168, 0.2), var(--shadow-md);
}

.mobile-submit-bar {
    display: flex;
    justify-content: flex-start;
    margin-top: 1rem;
}

@media (max-width: 767.98px) {
    body {
        padding-bottom: 0;
    }

    .site-header .navbar {
        min-height: 66px;
    }

    .brand-lockup img {
        max-width: 148px;
    }

    .site-main .container.py-4,
    .calculator-page {
        padding-top: 1.75rem !important;
        padding-bottom: 5.5rem !important;
    }

    .form-control,
    .form-select,
    .input-group-text {
        min-height: 50px;
        font-size: 1rem;
    }

    .mobile-submit-bar {
        position: sticky;
        bottom: 0;
        z-index: 1020;
        margin: 1.25rem -0.75rem -0.75rem;
        padding: 0.75rem;
        background: rgba(245, 248, 251, 0.96);
        border-top: 1px solid var(--border);
        backdrop-filter: blur(10px);
    }

    .mobile-submit-bar .btn {
        width: 100%;
        min-height: 50px;
    }

    .card-body {
        padding: 1.2rem;
    }

    .result-focus-target dl.row dt,
    .result-focus-target dl.row dd {
        width: 100%;
    }

    .result-focus-target dl.row dd {
        margin-bottom: 1rem;
    }

    .contact-cta-card {
        align-items: stretch;
        flex-direction: column;
    }

    .contact-cta-card .btn {
        width: 100%;
    }
}

/* Inicio compacto 1.3.1 */
.home-hero-compact {
    padding-top: clamp(2.5rem, 5vw, 4.5rem);
    padding-bottom: clamp(2rem, 4vw, 3.25rem);
}

.hero-visual-compact img {
    max-height: 360px;
}

.hero-tool-links {
    display: flex;
    flex-wrap: wrap;
    gap: 0.65rem;
    margin-top: 1rem;
}

.hero-tool-links a {
    padding: 0.55rem 0.8rem;
    border: 1px solid var(--border);
    border-radius: 999px;
    background: #fff;
    color: var(--brand-navy);
    font-size: 0.92rem;
    font-weight: 700;
    text-decoration: none;
}

.hero-tool-links a:hover,
.hero-tool-links a:focus-visible {
    border-color: var(--brand-blue);
    color: var(--brand-blue);
}

.category-section-raised {
    padding-top: clamp(2.25rem, 4vw, 3.5rem);
}

.section-heading-compact {
    margin-bottom: 1.75rem;
}

@media (max-width: 767.98px) {
    .home-hero-compact {
        padding-top: 2rem;
        padding-bottom: 1.5rem;
    }

    .hero-tool-links {
        display: grid;
        grid-template-columns: 1fr 1fr;
    }

    .hero-tool-links a {
        text-align: center;
    }

    .category-section-raised {
        padding-top: 1.5rem;
    }
}

/* Home: las cuatro herramientas tienen el mismo peso visual */
.hero-tools-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 0.8rem;
    margin-top: 1.5rem;
}

.hero-tools-grid .btn {
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 58px;
    padding-inline: 1rem;
    text-align: center;
    white-space: normal;
}

.tools-anchor-link {
    display: inline-flex;
    margin-top: 1rem;
    font-weight: 700;
    text-decoration: none;
}

.tools-anchor-link:hover,
.tools-anchor-link:focus-visible {
    text-decoration: underline;
}

@media (max-width: 575.98px) {
    .hero-tools-grid {
        grid-template-columns: 1fr;
        gap: 0.7rem;
    }

    .hero-tools-grid .btn {
        width: 100%;
        min-height: 52px;
    }
}
