/* Internal pages share the approved homepage palette and editorial rhythm.
   DESIGN_VARIANCE 6 / MOTION_INTENSITY 3 / VISUAL_DENSITY 3.
   Existing Blade, CMS content and native components remain the source of truth.
   Square media and panels, pill actions, 4px form controls. */
body:not(.page-home) {
  --color-bg: #111514;
  --color-surface: #19201d;
  --color-surface-alt: #202a25;
  --color-text: #f1f4f0;
  --color-muted: #bbc5bf;
  --color-brand: #72d9c4;
  --color-brand-deep: #72d9c4;
  --color-accent: #72d9c4;
  --color-border: #3c4741;
  --shadow-soft: none;
  --radius-sm: 4px;
  --radius-md: 0;
  --radius-lg: 0;
  --studio-gutter: clamp(20px, 4.2vw, 72px);
  --container: min(1320px, calc(100% - var(--studio-gutter) * 2));
  background: var(--color-bg);
  color: var(--color-text);
}

body:not(.page-home) .container { width: var(--container); }
/* Reserve the header before its custom element is registered. */
body:not(.page-home) > site-header {
  display: block;
  min-height: 77px;
  position: sticky;
  top: 0;
  z-index: 1000;
}
body:not(.page-home) .site-header {
  position: static;
  background: var(--color-bg);
  border-color: var(--color-border);
  backdrop-filter: none;
}
body:not(.page-home) .header-inner { min-height: 76px; }
body:not(.page-home) .site-nav { gap: 16px; }
body:not(.page-home) .site-nav ul { gap: 18px; }
body:not(.page-home) .nav-link { font-size: .875rem; font-weight: 400; }
body:not(.page-home) .site-header .btn { min-height: 44px; padding: 11px 17px; font-size: .8rem; }
body:not(.page-home) .site-footer { background: var(--color-bg); border-color: var(--color-border); }
body:not(.page-home) .nav-link.is-active { border-color: var(--color-brand); }
body:not(.page-home) main > section { padding-block: clamp(40px, 5vw, 72px); }
body:not(.page-home) :is(.page-hero, .cms-hero, .sardex-hero, .webpronto-hero) {
  min-height: auto;
  padding-block: 48px 64px;
  background: var(--color-bg);
  border-bottom: 1px solid var(--color-border);
}
body:not(.page-home) :is(.page-hero, .cms-hero, .sardex-hero)::before,
body:not(.page-home) :is(.page-hero, .cms-hero, .sardex-hero)::after { content: none; }
body:not(.page-home) :is(h1, h2, h3) { font-weight: 400; text-wrap: balance; }
body:not(.page-home) :is(.page-hero, .cms-hero, .sardex-hero, .webpronto-hero) h1 {
  max-width: 25ch;
  font-size: clamp(2.15rem, 4vw, 3.75rem);
  font-weight: 400;
  line-height: 1.12;
  letter-spacing: -.045em;
  margin-block: 16px 24px;
}
body:not(.page-home) :is(.page-hero, .cms-hero) p:not(.kicker):not(.cms-meta):not(.webpronto-microcopy) {
  max-width: 62ch;
  font-size: 1rem;
  line-height: 1.75;
  color: var(--color-muted);
}
body:not(.page-home) :is(.section-head, .cms-statement) { max-width: 72ch; }
body:not(.page-home) :is(.section-head, .cms-statement, .contact-wrap, .cta-panel) h2 {
  font-size: clamp(1.75rem, 3vw, 2.8rem);
  line-height: 1.2;
  letter-spacing: -.035em;
  font-weight: 400;
  color: var(--color-text);
}
body:not(.page-home) .kicker { color: var(--color-brand); font-weight: 400; }
body:not(.page-home) main > section:not(:first-child) .kicker {
  text-transform: none;
  letter-spacing: 0;
  font-size: .85rem;
}
body:not(.page-home) :is(p, li) { line-height: 1.75; }
body:not(.page-home) a { text-underline-offset: .3em; }
body:not(.page-home) :focus-visible { outline: 2px solid var(--color-brand); outline-offset: 5px; }

body:not(.page-home) .btn { min-height: 48px; box-shadow: none; background-image: none; font-weight: 600; border-radius: 999px; }
body:not(.page-home) .btn:hover { transform: none; }
body:not(.page-home) .btn:active { transform: scale(.98); }
body:not(.page-home) .btn-primary,
body:not(.page-home) .cta-panel .btn-primary { background: var(--color-brand); border-color: var(--color-brand); color: #11231d; }
body:not(.page-home) .btn-primary:hover { background: #a3e9d9; border-color: #a3e9d9; color: #11231d; }
body:not(.page-home) .btn-primary:active { background: #b8efe2; }
body:not(.page-home) .btn-secondary,
body:not(.page-home) .cta-panel .btn-secondary { background: transparent; border-color: #66756c; color: var(--color-text); }
body:not(.page-home) .btn-secondary:hover { background: var(--color-surface-alt); }
body:not(.page-home) .text-link { display: inline-flex; align-items: center; min-height: 44px; font-size: .9rem; font-weight: 400; text-decoration: underline; }
body:not(.page-home) .badge { background: transparent; padding-inline: 0; color: var(--color-brand); text-transform: none; letter-spacing: 0; font-weight: 400; }

body:not(.page-home) :is(.card, .cms-card, .pricing-card, .surface, .highlight-box, .cta-panel, .sardex-example, .sardex-package-card) {
  background: transparent;
  box-shadow: none;
  border-radius: 0;
  border-color: var(--color-border);
}
body:not(.page-home) :is(.card, .cms-card):hover,
body:not(.page-home) :is(.card, .cms-card):focus-within { transform: none; box-shadow: none; }
body:not(.page-home) :is(.editorial-grid, .cms-feature-grid, .sector-grid) {
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 40px 64px;
}
body:not(.page-home) :is(.editorial-grid, .cms-post-grid) > :is(.card, .cms-card) {
  border: 0;
  border-top: 1px solid var(--color-border);
  padding: 24px 0 0;
  height: auto;
}
body:not(.page-home) :is(.editorial-grid, .service-groups) :is(h2, h3) {
  font-weight: 400;
  letter-spacing: -.025em;
  color: var(--color-text);
}
body:not(.page-home) .service-groups > .card {
  padding: 32px 0;
  border: 0;
  border-top: 1px solid var(--color-border);
  background: transparent;
}
body:not(.page-home) :is(.feature-band, .ai-feature, .cms-webpronto-context, .cms-webpronto-grid, .webpronto-related-section) {
  background: var(--color-surface);
  border-color: var(--color-border);
}
body:not(.page-home) .cta-panel {
  grid-template-columns: minmax(0, 1fr);
  align-items: start;
  gap: 24px;
  padding: clamp(24px, 4vw, 48px);
  background: var(--color-surface);
  border: 1px solid var(--color-border);
}
body:not(.page-home) .cta-panel p { color: var(--color-muted); max-width: 65ch; }
body:not(.page-home) :is(.hero-split img, .card-media, .cms-card img, .sector-project-image) { border-radius: 0; }
body:not(.page-home) .card-media { width: 100%; max-width: 100%; margin: 0 0 24px; height: auto; }
body:not(.page-home) .hero-split { gap: 56px; }
body.page-centro-creativo .hero-split img { aspect-ratio: 16 / 10; }
body:not(.page-home) .cms-project-preview { margin: 0; }
body:not(.page-home) .cms-project-preview img { width: 100%; height: auto; }
body:not(.page-home) .cms-project-preview figcaption { font-size: .8rem; color: var(--color-muted); margin-top: 16px; }
body:not(.page-home) .cms-project-preview a { color: var(--color-brand); }

body:not(.page-home) .contact-form { background: var(--color-surface); border-radius: 0; box-shadow: none; }
body:not(.page-home) .contact-form :is(input, select, textarea) { background: var(--color-bg); color: var(--color-text); border-color: #66756c; border-radius: 4px; }
body:not(.page-home) .contact-form :is(input, textarea)::placeholder { color: var(--color-muted); }
body:not(.page-home) .contact-form input[type=checkbox] { accent-color: var(--color-brand); }
body:not(.page-home) .contact-form label { color: var(--color-text); }
body:not(.page-home) .form-note { border-color: var(--color-brand); }
body:not(.page-home) .cms-content article { max-width: 850px; }
body:not(.page-home) .cms-content article :is(h2, h3) { margin-top: 40px; }
body:not(.page-home) .cms-content article p { color: var(--color-muted); }
body:not(.page-home) .cms-content article :is(table, pre) { max-width: 100%; overflow-x: auto; display: block; }
body:not(.page-home) .cms-post-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 48px 64px; }
body:not(.page-home) .cms-post-grid .cms-card :is(h2, h3) { margin-block: 16px; font-size: clamp(1.4rem, 2vw, 1.8rem); font-weight: 400; letter-spacing: -.025em; line-height: 1.3; }
body:not(.page-home) .cms-post-grid :is(h2, h3) a { color: var(--color-text); text-decoration: none; }
body:not(.page-home) .cms-post-grid :is(h2, h3) a:hover { color: var(--color-brand); text-decoration: underline; }
body:not(.page-home) .cms-post-grid .cms-card { min-width: 0; }
body:not(.page-home) .cms-post-grid .badge { margin-bottom: 0; color: var(--color-brand); }
body:not(.page-home) .cms-post-grid img { margin-bottom: 24px; }
body:not(.page-home) .cms-post-grid p { color: var(--color-muted); }
body:not(.page-home) .cms-post-grid .cms-card > p:not(.badge) { display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; }
body:not(.page-home) .studio-pagination {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  margin-top: 48px;
  padding-top: 24px;
  border-top: 1px solid var(--color-border);
}
body:not(.page-home) .studio-pagination p { margin: 0; color: var(--color-muted); font-size: .9rem; }
body:not(.page-home) .studio-pagination ul { display: flex; flex-wrap: wrap; gap: 8px; list-style: none; margin: 0; padding: 0; }
body:not(.page-home) .studio-pagination li > :is(a, span) {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 44px;
  min-height: 44px;
  padding: 8px 14px;
  border: 1px solid var(--color-border);
  border-radius: 999px;
  font-size: .9rem;
  color: var(--color-text);
  text-decoration: none;
}
body:not(.page-home) .studio-pagination a:hover { background: var(--color-surface); color: var(--color-brand); }
body:not(.page-home) .studio-pagination [aria-current="page"] { background: var(--color-brand); color: #11231d; border-color: var(--color-brand); }
body:not(.page-home) .studio-pagination [aria-disabled="true"] { color: var(--color-muted); border-color: transparent; }
body:not(.page-home) :is(.number-steps li, .cms-process-grid article) { background: transparent; box-shadow: none; border-color: var(--color-border); border-radius: 0; }
body:not(.page-home) .number-steps li::before { box-shadow: none; background: transparent; color: var(--color-brand); }
body:not(.page-home) .sardex-microcopy { color: var(--color-muted); }
body:not(.page-home) :is(.sardex-badge-row, .sardex-trust-row) span { background: transparent; border: 0; border-radius: 0; color: var(--color-muted); padding-left: 0; font-weight: 400; }
body:not(.page-home) .webpronto-price { color: var(--color-text); }
body:not(.page-home) .sardex-price { color: var(--color-brand); }

@media (min-width: 1100px) {
  body:not(.page-home) .site-header .header-inner { width: var(--container); }
  body:not(.page-home) .btn { white-space: nowrap; }
}
/* Match the homepage breakpoint before the complete navigation stops fitting. */
@media (max-width: 1240px) {
  body:not(.page-home) .menu-toggle { display: inline-flex; }
  body:not(.page-home) .site-nav {
    position: fixed;
    inset: 76px 20px auto;
    width: calc(100% - 40px);
    max-height: calc(100dvh - 96px);
    overflow-y: auto;
    padding: 20px;
    flex-direction: column;
    align-items: flex-start;
    background: var(--color-surface);
    border: 1px solid var(--color-border);
    border-radius: 12px;
    box-shadow: none;
    transform: none;
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
  }
  body:not(.page-home) .site-nav.is-open { opacity: 1; visibility: visible; pointer-events: auto; }
  body:not(.page-home) .site-nav ul { flex-direction: column; align-items: stretch; width: 100%; gap: 4px; }
  body:not(.page-home) .nav-link { display: block; padding: 13px 0; }
  body:not(.page-home) .site-nav > .btn { width: 100%; }
}
@media (max-width: 767px) {
  body:not(.page-home) { --container: calc(100% - 40px); }
  body:not(.page-home) main > section { padding-block: 40px; }
  body:not(.page-home) :is(.page-hero, .cms-hero, .sardex-hero, .webpronto-hero) { padding-block: 32px 40px; }
  body:not(.page-home) :is(.page-hero, .cms-hero, .sardex-hero, .webpronto-hero) h1 { font-size: clamp(2rem, 7vw, 2.75rem); }
  body:not(.page-home) :is(.hero-split, .cms-hero-grid, .method-layout, .editorial-grid, .cms-feature-grid, .sector-grid, .cms-post-grid) { grid-template-columns: minmax(0, 1fr); gap: 32px; }
  body:not(.page-home) .cms-content { overflow-wrap: break-word; }
  body:not(.page-home) .page-links { gap: 12px 24px; }
  body:not(.page-home) .btn { max-width: 100%; }
  body:not(.page-home) .contact-form :is(input, select, textarea) { font-size: 1rem; }
}
@media (prefers-reduced-motion: reduce) {
  body:not(.page-home) :is(.card, .btn, .text-link)::after,
  body:not(.page-home) :is(.card, .btn, .text-link) { transition: none; transform: none; }
}
