:root {
    --ew-navy: #14284b;
    --ew-navy-dark: #0e1c36;
    --ew-navy-light: #1e3a66;
    --ew-sage: #a8bfa3;
    --ew-sage-dark: #7f9a78;
    --ew-sage-light: #d4e3d0;
    --ew-accent: #6b8f71;
    --ew-warm-white: #faf8f5;
    --ew-beige: #f3eee6;
    --ew-charcoal: #2c2c2c;
    --ew-muted: #5c6570;
    --ew-border: #e4ddd2;
    --ew-radius: 1rem;
    --ew-shadow: 0 0.75rem 2rem rgba(20, 40, 75, 0.08);
    --ew-font-display: "Cormorant Garamond", Georgia, serif;
    --ew-font-body: "Source Sans 3", "Segoe UI", sans-serif;
}

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

html {
    scroll-behavior: smooth;
}

body {
    font-family: var(--ew-font-body);
    color: var(--ew-charcoal);
    background: var(--ew-warm-white);
    line-height: 1.65;
}

h1, h2, h3, h4, h5, h6,
.display-font {
    font-family: var(--ew-font-display);
    color: var(--ew-navy);
    font-weight: 600;
    letter-spacing: -0.02em;
    line-height: 1.2;
}

a {
    color: var(--ew-navy-light);
    text-decoration: none;
}

a:hover {
    color: var(--ew-accent);
}

img {
    max-width: 100%;
    height: auto;
}

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

.bg-warm {
    background-color: var(--ew-warm-white);
}

.bg-beige {
    background-color: var(--ew-beige);
}

.bg-navy {
    background-color: var(--ew-navy);
    color: #fff;
}

.bg-sage-soft {
    background-color: var(--ew-sage-light);
}

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

.text-sage {
    color: var(--ew-sage-dark) !important;
}

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

.btn {
    border-radius: 999px;
    font-weight: 600;
    padding: 0.7rem 1.5rem;
    transition: transform 0.2s ease, box-shadow 0.2s ease, background-color 0.2s ease;
}

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

.btn-primary {
    --bs-btn-bg: var(--ew-navy);
    --bs-btn-border-color: var(--ew-navy);
    --bs-btn-hover-bg: var(--ew-navy-dark);
    --bs-btn-hover-border-color: var(--ew-navy-dark);
    --bs-btn-active-bg: var(--ew-navy-dark);
    --bs-btn-active-border-color: var(--ew-navy-dark);
    --bs-btn-disabled-bg: var(--ew-navy);
    --bs-btn-disabled-border-color: var(--ew-navy);
}

.btn-secondary {
    --bs-btn-color: var(--ew-navy);
    --bs-btn-bg: var(--ew-sage);
    --bs-btn-border-color: var(--ew-sage);
    --bs-btn-hover-color: var(--ew-navy);
    --bs-btn-hover-bg: var(--ew-sage-dark);
    --bs-btn-hover-border-color: var(--ew-sage-dark);
    --bs-btn-active-color: var(--ew-navy);
    --bs-btn-active-bg: var(--ew-sage-dark);
    --bs-btn-active-border-color: var(--ew-sage-dark);
}

.btn-outline-light {
    --bs-btn-color: #fff;
    --bs-btn-border-color: rgba(255, 255, 255, 0.7);
    --bs-btn-hover-bg: #fff;
    --bs-btn-hover-border-color: #fff;
    --bs-btn-hover-color: var(--ew-navy);
}

.btn-outline-navy {
    --bs-btn-color: var(--ew-navy);
    --bs-btn-border-color: var(--ew-navy);
    --bs-btn-hover-bg: var(--ew-navy);
    --bs-btn-hover-border-color: var(--ew-navy);
    --bs-btn-hover-color: #fff;
    border-width: 2px;
}

.site-header {
    background: rgba(250, 248, 245, 0.92);
    backdrop-filter: blur(10px);
    border-bottom: 1px solid var(--ew-border);
    position: sticky;
    top: 0;
    z-index: 1030;
}

.navbar-brand {
    font-family: var(--ew-font-display);
    font-size: 1.6rem;
    font-weight: 700;
    color: var(--ew-navy) !important;
    letter-spacing: -0.03em;
}

.site-brand {
    line-height: 1;
}

.site-brand__name {
    font-family: var(--ew-font-display);
    font-weight: 700;
    letter-spacing: -0.03em;
}

.site-brand__mark {
    display: inline-flex;
    flex-shrink: 0;
    width: 2.5rem;
    height: 2.5rem;
}

.site-brand__mark--image {
    object-fit: contain;
    border-radius: 0.65rem;
}

.site-brand__mark-svg {
    width: 100%;
    height: 100%;
    display: block;
}

.site-brand__mark-bg {
    fill: var(--ew-navy);
}

.site-brand__mark-fg {
    fill: var(--ew-warm-white);
}

.site-brand__mark-accent {
    fill: var(--ew-sage);
}

.site-brand--inverse .site-brand__name {
    color: #fff;
}

.site-brand--inverse .site-brand__mark-bg {
    fill: var(--ew-sage);
}

.site-brand--inverse .site-brand__mark-fg {
    fill: var(--ew-navy-dark);
}

.site-brand--inverse .site-brand__mark-accent {
    fill: var(--ew-warm-white);
}

.site-brand--compact .site-brand__name {
    font-size: 1.05rem;
}

.site-brand--compact .site-brand__mark {
    width: 2rem;
    height: 2rem;
}

.navbar-brand img,
.navbar-brand .site-brand__mark--image {
    max-height: 2.5rem;
    width: auto;
}

.navbar-nav .nav-link {
    color: var(--ew-charcoal);
    font-weight: 600;
    padding: 0.5rem 0.9rem !important;
}

.navbar-nav .nav-link:hover,
.navbar-nav .nav-link.active {
    color: var(--ew-accent);
}

.hero {
    position: relative;
    min-height: 88vh;
    display: flex;
    align-items: center;
    color: #fff;
    overflow: hidden;
    background: var(--ew-navy);
}

.hero-media {
    position: absolute;
    inset: 0;
    background-size: cover;
    background-position: center;
    transform: scale(1.02);
    animation: heroZoom 18s ease-in-out infinite alternate;
}

.hero-overlay {
    position: absolute;
    inset: 0;
    background: linear-gradient(105deg, rgba(14, 28, 54, 0.88) 0%, rgba(14, 28, 54, 0.55) 48%, rgba(20, 40, 75, 0.35) 100%);
}

.hero-content {
    position: relative;
    z-index: 2;
    padding: 6rem 0 5rem;
}

.hero h1 {
    color: #fff;
    font-size: clamp(2.4rem, 5vw, 4.2rem);
    max-width: 16ch;
    margin-bottom: 1.25rem;
}

.hero .lead {
    color: rgba(255, 255, 255, 0.9);
    max-width: 38rem;
    font-size: 1.15rem;
}

.eyebrow {
    display: inline-block;
    text-transform: uppercase;
    letter-spacing: 0.14em;
    font-size: 0.75rem;
    font-weight: 700;
    color: var(--ew-sage);
    margin-bottom: 0.85rem;
}

.section {
    padding: 5rem 0;
}

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

.section-heading .eyebrow {
    color: var(--ew-accent);
}

.card-ew {
    background: #fff;
    border: 1px solid var(--ew-border);
    border-radius: var(--ew-radius);
    box-shadow: var(--ew-shadow);
    overflow: hidden;
    height: 100%;
    transition: transform 0.25s ease, box-shadow 0.25s ease;
}

/* Auth cards must size to content so bottom margin stays visible. */
.auth-page .card-ew,
.card-ew.h-auto {
    height: auto;
}

.auth-page .card-ew:hover {
    transform: none;
}

.card-ew:hover {
    transform: translateY(-4px);
    box-shadow: 0 1rem 2.5rem rgba(20, 40, 75, 0.12);
}

.card-ew .card-img-top {
    aspect-ratio: 4 / 3;
    object-fit: cover;
    width: 100%;
}

.card-ew .card-body {
    padding: 1.5rem;
}

.feature-icon {
    width: 3rem;
    height: 3rem;
    border-radius: 0.85rem;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: var(--ew-sage-light);
    color: var(--ew-navy);
    margin-bottom: 1rem;
    font-size: 1.25rem;
}

.process-step {
    position: relative;
    padding: 1.5rem;
    background: #fff;
    border-radius: var(--ew-radius);
    border: 1px solid var(--ew-border);
    height: 100%;
}

.process-step .step-number {
    font-family: var(--ew-font-display);
    font-size: 2rem;
    color: var(--ew-sage-dark);
    line-height: 1;
    margin-bottom: 0.75rem;
}

.testimonial {
    background: #fff;
    border-radius: var(--ew-radius);
    border: 1px solid var(--ew-border);
    padding: 1.75rem;
    height: 100%;
}

.testimonial .quote {
    font-family: var(--ew-font-display);
    font-size: 1.35rem;
    color: var(--ew-navy);
    margin-bottom: 1.25rem;
}

.faq-item {
    background: #fff;
    border: 1px solid var(--ew-border);
    border-radius: 0.85rem;
    margin-bottom: 0.75rem;
    overflow: hidden;
}

.faq-item button {
    width: 100%;
    text-align: left;
    background: transparent;
    border: 0;
    padding: 1.1rem 1.25rem;
    font-weight: 600;
    color: var(--ew-navy);
}

.faq-item .faq-body {
    display: none;
    padding: 0 1.25rem 1.15rem;
    color: var(--ew-muted);
}

.faq-item.open .faq-body {
    display: block;
}

.cta-banner {
    background: linear-gradient(120deg, var(--ew-navy) 0%, var(--ew-navy-light) 60%, #2f5a4a 100%);
    color: #fff;
    border-radius: calc(var(--ew-radius) + 0.25rem);
    padding: 3rem;
    position: relative;
    overflow: hidden;
}

.cta-banner h2,
.cta-banner p {
    color: #fff;
}

.site-footer {
    background: var(--ew-navy-dark);
    color: rgba(255, 255, 255, 0.82);
    padding: 4rem 0 2rem;
}

.site-footer a {
    color: rgba(255, 255, 255, 0.82);
}

.site-footer a:hover {
    color: var(--ew-sage);
}

.site-footer h5 {
    color: #fff;
    font-size: 1.15rem;
    margin-bottom: 1rem;
}

.social-links {
    display: flex;
    flex-wrap: wrap;
    gap: 0.65rem;
}

.social-links__item {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 2.5rem;
    height: 2.5rem;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.08);
    border: 1px solid rgba(255, 255, 255, 0.16);
    transition: background-color 0.2s ease, border-color 0.2s ease, transform 0.2s ease;
}

.social-links__item:hover,
.social-links__item:focus-visible {
    background: rgba(168, 191, 163, 0.28);
    border-color: var(--ew-sage);
    color: #fff;
    transform: translateY(-1px);
}

.social-links__icon {
    width: 1.15rem;
    height: 1.15rem;
    display: block;
}

.form-label {
    font-weight: 600;
    color: var(--ew-navy);
}

.form-control,
.form-select {
    border-radius: 0.75rem;
    border-color: var(--ew-border);
    padding: 0.75rem 1rem;
    background: #fff;
}

.form-control:focus,
.form-select:focus {
    border-color: var(--ew-sage);
    box-shadow: 0 0 0 0.2rem rgba(168, 191, 163, 0.35);
}

.honeypot-field {
    position: absolute;
    left: -10000px;
    top: auto;
    width: 1px;
    height: 1px;
    overflow: hidden;
}

.demo-banner {
    background: #fff3cd;
    border: 1px solid #ffe69c;
    color: #664d03;
    border-radius: 0.75rem;
    padding: 0.9rem 1.1rem;
    margin-bottom: 1.5rem;
}

.reveal {
    opacity: 0;
    transform: translateY(18px);
    transition: opacity 0.6s ease, transform 0.6s ease;
}

.reveal.visible {
    opacity: 1;
    transform: none;
}

.admin-shell {
    min-height: 100vh;
    background: #f4f6f8;
}

.admin-sidebar {
    width: 260px;
    background: var(--ew-navy-dark);
    color: #fff;
    min-height: 100vh;
}

.admin-sidebar a {
    color: rgba(255, 255, 255, 0.8);
    display: block;
    padding: 0.65rem 1rem;
    border-radius: 0.5rem;
    margin: 0.15rem 0.75rem;
}

.admin-sidebar a:hover,
.admin-sidebar a.active {
    background: rgba(255, 255, 255, 0.08);
    color: #fff;
}

.admin-main {
    flex: 1;
}

/* Admin list/filter panels must size to content; height:100% is for public equal-height grids. */
.admin-main .card-ew {
    height: auto;
}

.admin-main .card-ew:hover {
    transform: none;
}

.stat-card {
    background: #fff;
    border-radius: var(--ew-radius);
    border: 1px solid #e6ebf0;
    padding: 1.25rem;
    height: 100%;
}

.stat-card .stat-value {
    font-family: var(--ew-font-display);
    font-size: 2.2rem;
    color: var(--ew-navy);
    line-height: 1;
}

.badge-status {
    border-radius: 999px;
    padding: 0.35rem 0.7rem;
    font-weight: 600;
}

.page-hero {
    background: linear-gradient(135deg, var(--ew-beige), var(--ew-warm-white));
    padding: 4.5rem 0 3rem;
    border-bottom: 1px solid var(--ew-border);
}

.service-detail-media {
    border-radius: var(--ew-radius);
    overflow: hidden;
    box-shadow: var(--ew-shadow);
}

.service-detail-media img {
    width: 100%;
    aspect-ratio: 16 / 10;
    object-fit: cover;
}

.list-check {
    list-style: none;
    padding-left: 0;
}

.list-check li {
    position: relative;
    padding-left: 1.6rem;
    margin-bottom: 0.55rem;
}

.list-check li::before {
    content: "";
    position: absolute;
    left: 0;
    top: 0.45rem;
    width: 0.65rem;
    height: 0.65rem;
    border-radius: 50%;
    background: var(--ew-sage);
}

@keyframes heroZoom {
    from { transform: scale(1.02); }
    to { transform: scale(1.08); }
}

.cta-banner--onecrib {
    background: linear-gradient(120deg, var(--ew-navy-dark) 0%, var(--ew-navy) 55%, #2f5a4a 100%);
}

.whatsapp-float {
    --whatsapp-float-size: 3.5rem;
    position: fixed;
    right: max(1rem, env(safe-area-inset-right, 0px));
    bottom: max(1rem, env(safe-area-inset-bottom, 0px));
    z-index: 1040;
    width: var(--whatsapp-float-size);
    height: var(--whatsapp-float-size);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 999px;
    background: #25d366;
    color: #fff;
    box-shadow: 0 0.65rem 1.5rem rgba(20, 40, 75, 0.22);
    transition: transform 0.2s ease, box-shadow 0.2s ease, background-color 0.2s ease;
}

.whatsapp-float:hover,
.whatsapp-float:focus-visible {
    color: #fff;
    background: #1ebe57;
    transform: translateY(-2px) scale(1.04);
    box-shadow: 0 0.85rem 1.75rem rgba(20, 40, 75, 0.28);
}

.whatsapp-float:focus-visible {
    outline: 3px solid rgba(37, 211, 102, 0.45);
    outline-offset: 3px;
}

.whatsapp-float__icon {
    width: 1.65rem;
    height: 1.65rem;
    display: block;
}

.whatsapp-float__tooltip {
    position: absolute;
    right: calc(100% + 0.75rem);
    top: 50%;
    transform: translateY(-50%);
    white-space: nowrap;
    background: var(--ew-navy-dark);
    color: #fff;
    font-size: 0.85rem;
    font-weight: 600;
    line-height: 1.3;
    padding: 0.55rem 0.85rem;
    border-radius: 0.65rem;
    box-shadow: 0 0.5rem 1.25rem rgba(20, 40, 75, 0.18);
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
    transition: opacity 0.2s ease, visibility 0.2s ease;
}

.whatsapp-float__tooltip::after {
    content: "";
    position: absolute;
    left: 100%;
    top: 50%;
    transform: translateY(-50%);
    border: 6px solid transparent;
    border-left-color: var(--ew-navy-dark);
}

.whatsapp-float:hover .whatsapp-float__tooltip,
.whatsapp-float:focus-visible .whatsapp-float__tooltip {
    opacity: 1;
    visibility: visible;
}

.whatsapp-cta--footer {
    color: var(--ew-sage);
    text-decoration: underline;
    text-underline-offset: 0.15em;
    font-weight: 600;
}

.whatsapp-cta--footer:hover,
.whatsapp-cta--footer:focus-visible {
    color: #fff;
}

.site-footer__whatsapp {
    padding-right: 4.5rem;
}

.ew-flash-toasts {
    z-index: 1090;
    max-width: min(26rem, calc(100vw - 1.5rem));
}

.ew-flash-toast {
    width: 100%;
    border-radius: 0.75rem;
    box-shadow: 0 0.75rem 1.75rem rgba(20, 40, 75, 0.16);
    font-family: var(--ew-font-body);
}

.ew-flash-toast .toast-body {
    font-size: 0.95rem;
    line-height: 1.45;
    padding: 0.85rem 0.35rem 0.85rem 1rem;
}

.ew-flash-toast--danger {
    color: #842029;
    background-color: #f8d7da;
}

.ew-flash-toast--success {
    color: #fff;
    background-color: var(--ew-navy);
}

@media (max-width: 991.98px) {
    .hero {
        min-height: 72vh;
    }

    .hero-content {
        padding: 5rem 0 3.5rem;
    }

    .admin-sidebar {
        width: 100%;
        min-height: auto;
    }

    .whatsapp-float__tooltip {
        display: none;
    }

    .site-footer {
        padding-bottom: 5.5rem;
    }
}

@media (prefers-reduced-motion: reduce) {
    .whatsapp-float,
    .whatsapp-float__tooltip {
        transition: none;
    }

    .whatsapp-float:hover,
    .whatsapp-float:focus-visible {
        transform: none;
    }
}
