/* ============================================================
   Shared site extras: AI chat widget, floating buttons, blog.
   Colors come from each site's own styles.css variables.
   ============================================================ */

/* ---------- Floating buttons: everything on the right ---------- */
/* Chat launcher sits bottom-right; WhatsApp and Call stack above it. */
body .whatsapp-float {
  right: 22px;
  left: auto;
  bottom: 96px;
}
body .call-float {
  right: 22px;
  left: auto;
  bottom: 166px;
}

.sx-launcher {
  position: fixed;
  right: 20px;
  bottom: 20px;
  z-index: 90;
  width: 62px;
  height: 62px;
  border: 0;
  border-radius: 50%;
  cursor: pointer;
  display: grid;
  place-items: center;
  color: #fff;
  background: linear-gradient(160deg, var(--graphite-800, #183452), var(--graphite-950, #06101c));
  box-shadow: 0 0 0 3px var(--co-red, #c9a227), 0 14px 34px rgba(6, 16, 28, 0.35);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}
.sx-launcher:hover { transform: translateY(-2px) scale(1.03); }
.sx-launcher:focus-visible { outline: 3px solid var(--co-red, #c9a227); outline-offset: 4px; }
.sx-launcher svg { width: 28px; height: 28px; }
.sx-launcher .sx-icon-close { display: none; }
.sx-open .sx-launcher .sx-icon-chat { display: none; }
.sx-open .sx-launcher .sx-icon-close { display: block; }
.sx-launcher-dot {
  position: absolute;
  top: 4px;
  right: 4px;
  width: 13px;
  height: 13px;
  border-radius: 50%;
  background: #2fbf71;
  border: 2px solid #fff;
}
.sx-launcher::after {
  content: "";
  position: absolute;
  inset: -3px;
  border-radius: 50%;
  border: 3px solid var(--co-red, #c9a227);
  animation: sxRing 2.6s ease-out infinite;
  pointer-events: none;
}
.sx-open .sx-launcher::after { display: none; }
@keyframes sxRing {
  0% { transform: scale(1); opacity: 0.7; }
  70%, 100% { transform: scale(1.35); opacity: 0; }
}

/* ---------- Teaser bubble ---------- */
.sx-teaser {
  position: fixed;
  right: 94px;
  bottom: 30px;
  z-index: 89;
  max-width: 250px;
  padding: 12px 34px 12px 14px;
  border-radius: 16px 16px 4px 16px;
  background: #fff;
  color: var(--ink, #0c1828);
  font-family: var(--font-body, system-ui, sans-serif);
  font-size: 14px;
  line-height: 1.4;
  box-shadow: 0 14px 40px rgba(6, 16, 28, 0.2);
  border: 1px solid var(--line-light, rgba(12, 24, 40, 0.09));
  cursor: pointer;
  animation: sxPop 0.35s cubic-bezier(0.22, 1, 0.36, 1);
}
.sx-teaser strong { display: block; margin-bottom: 2px; }
.sx-teaser-close {
  position: absolute;
  top: 6px;
  right: 8px;
  border: 0;
  background: transparent;
  color: var(--ink-faint, #7a8b9d);
  font-size: 18px;
  line-height: 1;
  cursor: pointer;
  padding: 2px 4px;
}
@keyframes sxPop {
  from { opacity: 0; transform: translateY(10px) scale(0.96); }
  to { opacity: 1; transform: none; }
}

/* ---------- Panel ---------- */
.sx-panel {
  position: fixed;
  right: 20px;
  bottom: 96px;
  z-index: 95;
  width: 380px;
  height: min(600px, calc(100vh - 130px));
  display: flex;
  flex-direction: column;
  overflow: hidden;
  border-radius: 20px;
  background: var(--paper, #f3f6fa);
  color: var(--ink, #0c1828);
  font-family: var(--font-body, system-ui, sans-serif);
  box-shadow: 0 30px 80px rgba(6, 16, 28, 0.35);
  border: 1px solid rgba(255, 255, 255, 0.6);
  animation: sxPop 0.3s cubic-bezier(0.22, 1, 0.36, 1);
}
.sx-panel[hidden] { display: none; }
.sx-head {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 16px 16px 14px;
  color: var(--cream, #eaf2fa);
  background:
    radial-gradient(ellipse 80% 120% at 100% 0%, rgba(255, 255, 255, 0.12), transparent 60%),
    linear-gradient(160deg, var(--graphite-800, #183452), var(--graphite-950, #06101c));
  border-bottom: 3px solid var(--co-red, #c9a227);
}
.sx-avatar {
  position: relative;
  flex: none;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  background: var(--co-red, #c9a227);
  color: #fff;
  font-weight: 700;
}
.sx-avatar svg { width: 22px; height: 22px; }
.sx-avatar::after {
  content: "";
  position: absolute;
  right: -1px;
  bottom: -1px;
  width: 11px;
  height: 11px;
  border-radius: 50%;
  background: #2fbf71;
  border: 2px solid var(--graphite-900, #0a1a2e);
}
.sx-head-text { min-width: 0; flex: 1; }
.sx-head-text strong { display: block; font-size: 15px; line-height: 1.25; }
.sx-head-text span { font-size: 12px; color: var(--cream-muted, rgba(234, 242, 250, 0.74)); }
.sx-head-btn {
  flex: none;
  border: 0;
  background: rgba(255, 255, 255, 0.1);
  color: inherit;
  width: 32px;
  height: 32px;
  border-radius: 50%;
  cursor: pointer;
  display: grid;
  place-items: center;
}
.sx-head-btn:hover { background: rgba(255, 255, 255, 0.2); }
.sx-head-btn svg { width: 16px; height: 16px; }

.sx-log {
  flex: 1;
  overflow-y: auto;
  padding: 18px 14px 8px;
  display: flex;
  flex-direction: column;
  gap: 10px;
  scroll-behavior: smooth;
}
.sx-msg {
  max-width: 84%;
  padding: 10px 14px;
  font-size: 14.5px;
  line-height: 1.45;
  border-radius: 16px;
  white-space: pre-wrap;
  overflow-wrap: anywhere;
  animation: sxPop 0.25s ease;
}
.sx-msg-bot {
  align-self: flex-start;
  background: var(--card, #fff);
  border: 1px solid var(--line-light, rgba(12, 24, 40, 0.09));
  border-bottom-left-radius: 4px;
  box-shadow: 0 4px 14px rgba(6, 16, 28, 0.05);
}
.sx-msg-user {
  align-self: flex-end;
  color: #fff;
  background: linear-gradient(180deg, var(--co-red, #c9a227), var(--co-red-deep, #a68516));
  border-bottom-right-radius: 4px;
}
.sx-typing {
  align-self: flex-start;
  display: inline-flex;
  gap: 4px;
  padding: 13px 14px;
  border-radius: 16px;
  border-bottom-left-radius: 4px;
  background: var(--card, #fff);
  border: 1px solid var(--line-light, rgba(12, 24, 40, 0.09));
}
.sx-typing i {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--ink-faint, #7a8b9d);
  animation: sxDot 1.2s infinite ease-in-out;
}
.sx-typing i:nth-child(2) { animation-delay: 0.15s; }
.sx-typing i:nth-child(3) { animation-delay: 0.3s; }
@keyframes sxDot {
  0%, 60%, 100% { transform: translateY(0); opacity: 0.45; }
  30% { transform: translateY(-4px); opacity: 1; }
}

.sx-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  padding: 2px 0 4px;
}
.sx-chip {
  border: 1px solid var(--co-red, #c9a227);
  color: var(--co-red-deep, #a68516);
  background: var(--card, #fff);
  border-radius: 999px;
  padding: 7px 13px;
  font: inherit;
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
}
.sx-chip:hover { background: var(--co-red, #c9a227); color: #fff; }

/* Summary card shown when all details are collected */
.sx-summary {
  align-self: stretch;
  background: var(--card, #fff);
  border: 1px solid var(--line-light, rgba(12, 24, 40, 0.09));
  border-top: 3px solid var(--co-red, #c9a227);
  border-radius: 14px;
  padding: 14px;
  font-size: 13.5px;
  box-shadow: 0 8px 24px rgba(6, 16, 28, 0.07);
}
.sx-summary h4 {
  margin: 0 0 8px;
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--ink-soft, #45566a);
}
.sx-summary dl {
  margin: 0;
  display: grid;
  grid-template-columns: 82px minmax(0, 1fr);
  gap: 5px 10px;
}
.sx-summary dt { color: var(--ink-faint, #7a8b9d); }
.sx-summary dd { margin: 0; font-weight: 600; overflow-wrap: anywhere; }
.sx-summary-edit { margin: 10px 0 0; font-size: 12px; color: var(--ink-soft, #45566a); }
.sx-consent {
  margin: 10px 0 0;
  font-size: 11px;
  line-height: 1.45;
  color: var(--ink-faint, #7a8b9d);
}
.sx-consent a { color: inherit; }
.sx-submit {
  width: 100%;
  margin-top: 12px;
  border: 0;
  border-radius: 12px;
  padding: 13px;
  font: inherit;
  font-size: 15px;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: #fff;
  cursor: pointer;
  background: linear-gradient(180deg, var(--co-red, #c9a227), var(--co-red-deep, #a68516));
  box-shadow: 0 10px 24px rgba(6, 16, 28, 0.18);
}
.sx-submit:disabled { opacity: 0.65; cursor: wait; }

.sx-form {
  display: flex;
  gap: 8px;
  padding: 10px 12px 12px;
  background: var(--card, #fff);
  border-top: 1px solid var(--line-light, rgba(12, 24, 40, 0.09));
}
.sx-input {
  flex: 1;
  min-width: 0;
  border: 1px solid var(--line-light, rgba(12, 24, 40, 0.12));
  background: var(--paper, #f3f6fa);
  border-radius: 999px;
  padding: 11px 16px;
  font: inherit;
  font-size: 15px;
  color: inherit;
}
.sx-input:focus { outline: none; border-color: var(--co-red, #c9a227); box-shadow: 0 0 0 3px rgba(0, 0, 0, 0.04); }
.sx-send {
  flex: none;
  width: 44px;
  height: 44px;
  border: 0;
  border-radius: 50%;
  cursor: pointer;
  color: #fff;
  display: grid;
  place-items: center;
  background: linear-gradient(180deg, var(--co-red, #c9a227), var(--co-red-deep, #a68516));
}
.sx-send:disabled { opacity: 0.5; cursor: default; }
.sx-send svg { width: 18px; height: 18px; }
.sx-foot {
  padding: 0 12px 10px;
  background: var(--card, #fff);
  font-size: 11px;
  text-align: center;
  color: var(--ink-faint, #7a8b9d);
}

@media (max-width: 560px) {
  body .whatsapp-float { right: 16px; bottom: 86px; }
  body .call-float { right: 16px; bottom: 150px; }
  .sx-launcher { right: 14px; bottom: 14px; width: 58px; height: 58px; }
  .sx-teaser { right: 82px; bottom: 22px; max-width: calc(100vw - 110px); }
  .sx-panel {
    right: 0;
    left: 0;
    bottom: 0;
    width: auto;
    height: calc(100% - 56px);
    max-height: none;
    border-radius: 20px 20px 0 0;
  }
  .sx-open .sx-launcher,
  .sx-open .whatsapp-float,
  .sx-open .call-float { display: none; }
  .sx-input { font-size: 16px; } /* stop iOS zoom on focus */
}

@media (prefers-reduced-motion: reduce) {
  .sx-launcher::after { animation: none; }
  .sx-panel, .sx-msg, .sx-teaser { animation: none; }
}

/* ---------- Header + footer links ---------- */
.header-blog-link {
  font-weight: 600;
  font-size: 15px;
  color: var(--ink, #0c1828);
  text-decoration: none;
  padding: 6px 4px;
  margin-right: 14px;
  border-bottom: 2px solid transparent;
}
.header-blog-link:hover { border-bottom-color: var(--co-red, #c9a227); }
.header-right { display: flex; align-items: center; }
@media (max-width: 420px) {
  .header-blog-link { margin-right: 8px; font-size: 14px; }
}

/* ---------- Home page "latest articles" ---------- */
.blog-latest .blog-latest-head {
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
  gap: 16px;
  flex-wrap: wrap;
  margin-bottom: 28px;
}
.blog-latest .blog-latest-head h2 { margin: 0; }
.blog-all-link {
  font-weight: 700;
  color: var(--co-red-deep, #a68516);
  text-decoration: none;
}
.blog-all-link:hover { text-decoration: underline; }

/* ---------- Blog cards ---------- */
.blog-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 22px;
}
.blog-card {
  display: flex;
  flex-direction: column;
  overflow: hidden;
  border-radius: var(--radius, 18px);
  background: var(--card, #fff);
  border: 1px solid var(--line-light, rgba(12, 24, 40, 0.09));
  box-shadow: var(--shadow-soft, 0 10px 40px rgba(6, 16, 28, 0.08));
  color: var(--ink, #0c1828);
  text-decoration: none;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}
.blog-card:hover { transform: translateY(-4px); box-shadow: var(--shadow-lift, 0 22px 50px rgba(6, 16, 28, 0.14)); }
.blog-card-media {
  aspect-ratio: 16 / 9;
  overflow: hidden;
  background: linear-gradient(160deg, var(--graphite-800, #183452), var(--graphite-950, #06101c));
  display: grid;
  place-items: center;
}
.blog-card-media img { width: 100%; height: 100%; object-fit: cover; display: block; }
.blog-card-fallback {
  font-family: var(--font-display, Georgia, serif);
  font-size: 64px;
  font-style: italic;
  color: var(--co-red, #c9a227);
  opacity: 0.85;
}
.blog-card-body { padding: 18px 20px 22px; display: flex; flex-direction: column; gap: 8px; flex: 1; }
.blog-card-date {
  font-size: 12px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  color: var(--brass, #b8860b);
}
.blog-card h3 { margin: 0; font-family: var(--font-display, Georgia, serif); font-size: 20px; line-height: 1.3; }
.blog-card p { margin: 0; color: var(--ink-soft, #45566a); font-size: 15px; flex: 1; }
.blog-card-more { margin-top: 6px; font-weight: 700; font-size: 14px; color: var(--co-red-deep, #a68516); }

/* ---------- Blog pages ---------- */
.blog-main { padding-bottom: 80px; }
.blog-hero {
  padding: 64px 0 56px;
  color: var(--cream, #eaf2fa);
  background:
    radial-gradient(ellipse 60% 80% at 100% 0%, rgba(255, 255, 255, 0.08), transparent 60%),
    linear-gradient(160deg, var(--graphite-850, #10243c), var(--graphite-950, #06101c));
  margin-bottom: 48px;
}
.blog-hero .eyebrow { color: var(--co-red, #c9a227); }
.blog-hero h1 {
  font-family: var(--font-display, Georgia, serif);
  font-size: clamp(34px, 5vw, 54px);
  line-height: 1.1;
  margin: 10px 0 14px;
  font-weight: 400;
  color: var(--cream, #eaf2fa);
}
.blog-hero h1 em { color: var(--co-red, #c9a227); }
.blog-hero-lede { max-width: 620px; color: var(--cream-muted, rgba(234, 242, 250, 0.74)); font-size: 17px; }
.blog-pager {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-top: 36px;
  color: var(--ink-soft, #45566a);
}
.blog-pager a { font-weight: 700; color: var(--co-red-deep, #a68516); text-decoration: none; }
.blog-empty { text-align: center; padding: 60px 0; }
.blog-empty h1, .blog-empty h2 { font-family: var(--font-display, Georgia, serif); margin-bottom: 10px; }
.blog-empty p { color: var(--ink-soft, #45566a); margin-bottom: 22px; }

.blog-article-wrap {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 360px;
  gap: 48px;
  align-items: start;
  padding-top: 40px;
}
.blog-aside { position: sticky; top: 100px; scroll-margin-top: 100px; }
.blog-aside .form-card { opacity: 1; transform: none; }
.blog-crumbs { font-size: 14px; color: var(--ink-faint, #7a8b9d); margin-bottom: 18px; }
.blog-crumbs a { color: var(--ink-soft, #45566a); text-decoration: none; }
.blog-crumbs a:hover { text-decoration: underline; }
.blog-crumbs span { margin: 0 6px; }
.blog-article h1 {
  font-family: var(--font-display, Georgia, serif);
  font-size: clamp(30px, 4.2vw, 46px);
  line-height: 1.15;
  font-weight: 700;
  margin-bottom: 14px;
}
.blog-meta { color: var(--ink-faint, #7a8b9d); font-size: 14px; margin-bottom: 26px; }
.blog-cover {
  width: 100%;
  max-height: 460px;
  object-fit: cover;
  border-radius: var(--radius, 18px);
  margin-bottom: 30px;
  box-shadow: var(--shadow-soft, 0 10px 40px rgba(6, 16, 28, 0.08));
}
.blog-content { font-size: 18px; line-height: 1.75; color: var(--ink, #0c1828); }
.blog-content > * + * { margin-top: 1.1em; }
.blog-content h2, .blog-content h3, .blog-content h4 {
  font-family: var(--font-display, Georgia, serif);
  line-height: 1.25;
  margin-top: 1.8em;
}
.blog-content h2 { font-size: 28px; }
.blog-content h3 { font-size: 22px; }
.blog-content h4 { font-size: 19px; }
.blog-content a { color: var(--co-red-deep, #a68516); font-weight: 600; }
.blog-content ul, .blog-content ol { padding-left: 1.4em; }
.blog-content li + li { margin-top: 0.35em; }
.blog-content blockquote {
  border-left: 4px solid var(--co-red, #c9a227);
  padding: 6px 0 6px 20px;
  color: var(--ink-soft, #45566a);
  font-style: italic;
}
.blog-content img, .blog-content figure img { max-width: 100%; height: auto; border-radius: 14px; }
.blog-content figure { margin: 1.6em 0; }
.blog-content code {
  background: var(--paper-alt, #e7eef6);
  padding: 2px 6px;
  border-radius: 6px;
  font-size: 0.9em;
}
.blog-content hr { border: 0; border-top: 1px solid var(--line-light, rgba(12, 24, 40, 0.12)); margin: 2em 0; }
.blog-cta {
  margin-top: 44px;
  padding: 24px;
  border-radius: var(--radius, 18px);
  background: linear-gradient(160deg, var(--graphite-850, #10243c), var(--graphite-950, #06101c));
  color: var(--cream, #eaf2fa);
  display: flex;
  flex-direction: column;
  gap: 8px;
  align-items: flex-start;
}
.blog-cta strong { font-family: var(--font-display, Georgia, serif); font-size: 22px; }
.blog-cta span { color: var(--cream-muted, rgba(234, 242, 250, 0.74)); margin-bottom: 8px; }
.blog-cta .btn { display: none; }
.blog-related { margin-top: 70px; }
.blog-related h2 { font-family: var(--font-display, Georgia, serif); font-size: 30px; margin-bottom: 24px; }

@media (max-width: 960px) {
  .blog-article-wrap { grid-template-columns: 1fr; gap: 36px; }
  .blog-aside { position: static; }
  .blog-cta .btn { display: inline-block; }
}
@media (max-width: 560px) {
  .blog-hero { padding: 44px 0 40px; margin-bottom: 32px; }
  .blog-content { font-size: 17px; }
}

/* ---------- Service landing pages ---------- */
.svc-hero-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 14px 18px; margin-top: 24px; }
.svc-hero-note { font-size: 14px; color: var(--cream-muted, rgba(234, 242, 250, 0.74)); }
.svc-page .blog-hero { margin-bottom: 0; }
.svc-wrap { padding-top: 32px; }
.svc-page .blog-content > h2:first-child { margin-top: 0.4em; }
.svc-faq { display: flex; flex-direction: column; gap: 10px; }
.svc-faq details {
  background: var(--card, #fff);
  border: 1px solid var(--line-light, rgba(12, 24, 40, 0.09));
  border-radius: 14px;
  padding: 14px 18px;
}
.svc-faq summary {
  cursor: pointer;
  font-weight: 700;
  font-size: 17px;
  list-style: none;
  display: flex;
  justify-content: space-between;
  gap: 12px;
}
.svc-faq summary::-webkit-details-marker { display: none; }
.svc-faq summary::after { content: "+"; color: var(--co-red, #c9a227); font-size: 22px; line-height: 1; }
.svc-faq details[open] summary::after { content: "\2212"; }
.svc-faq details p { margin-top: 10px; font-size: 16px; color: var(--ink-soft, #45566a); }
.svc-more { margin-top: 64px; }
.svc-more h2 { font-family: var(--font-display, Georgia, serif); font-size: 28px; margin-bottom: 20px; }
.svc-links { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 12px; }
.svc-links a {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 16px 18px;
  border-radius: 14px;
  background: var(--card, #fff);
  border: 1px solid var(--line-light, rgba(12, 24, 40, 0.09));
  color: var(--ink, #0c1828);
  font-weight: 700;
  text-decoration: none;
  transition: border-color 0.15s ease, transform 0.15s ease;
}
.svc-links a:hover { border-color: var(--co-red, #c9a227); transform: translateY(-2px); }
.svc-links a span { color: var(--co-red, #c9a227); }

/* Footer "services" row on every page */
.footer-services {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 18px;
  padding: 18px 0 4px;
  font-size: 14px;
}
.footer-services a { color: inherit; opacity: 0.85; text-decoration: none; }
.footer-services a:hover { opacity: 1; text-decoration: underline; }
