/* Final public-shell layer. Load after the existing site stylesheets.
   Scope: contact, request-demo aliases and 404 shells, plus logo sizing.
   SVG backgrounds are corrected in the assets, not hidden by this layer. */

:root {
  --public-bg: #ffffff;
  --public-fg: #202024;
  --public-muted: #5d5e68;
  --public-line: #e5e2e5;
  --public-surface: #faf9fa;
  --public-link: #801d3e;
  --public-button: #801d3e;
  --public-button-hover: #681632;
  --public-button-fg: #ffffff;
}

:root[data-theme="dark"] {
  --public-bg: #0e0b0d;
  --public-fg: #f5f3f4;
  --public-muted: #c2bac0;
  --public-line: #393037;
  --public-surface: #191417;
  --public-link: #f0a9bf;
  --public-button: #801d3e;
  --public-button-hover: #92254a;
}

/* Corporate pages keep their own palette. Only the small public-info shells
   receive this page background and their matching inherited site variables. */
html:has(.public-info) {
  --ivory: var(--public-bg);
  --ink: var(--public-fg);
  --secondary: var(--public-muted);
  --muted: var(--public-muted);
  --line: var(--public-line);
  --surface: var(--public-surface);
  --card: var(--public-surface);
}

body:has(.public-info) {
  background: var(--public-bg);
  color: var(--public-fg);
}

.public-info {
  width: 100%;
  max-width: 960px;
  min-height: 62vh;
  padding: clamp(52px, 8vw, 100px) 0 clamp(60px, 8vw, 100px);
  color: var(--public-fg);
}

.public-copy {
  color: var(--public-fg);
  overflow-wrap: anywhere;
}

.public-copy[hidden] {
  display: none !important;
}

.public-copy h1,
.public-copy h2,
.public-copy h3 {
  color: var(--public-fg);
  text-wrap: balance;
}

.public-copy h1 {
  max-width: 820px;
  margin: 0 0 28px;
  font-size: clamp(36px, 5.8vw, 66px);
  line-height: 1.13;
  letter-spacing: -.03em;
}

.public-copy p,
.public-copy li {
  max-width: 740px;
  color: var(--public-muted);
  font-size: 17px;
  line-height: 1.75;
}

.public-copy p + p {
  margin-top: 20px;
}

.public-copy .eyebrow {
  margin: 0 0 24px;
  color: var(--public-link);
  font-size: 11px;
  line-height: 1.6;
  letter-spacing: .15em;
}

.public-copy a:not(.button) {
  color: var(--public-link);
  text-decoration: underline;
  text-decoration-thickness: 1px;
  text-underline-offset: 4px;
}

.public-copy .button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  max-width: 100%;
  min-height: 52px;
  margin: 26px 0;
  padding: 14px 22px;
  border: 1px solid var(--public-button);
  border-radius: 12px;
  background: var(--public-button);
  color: var(--public-button-fg);
  font-size: 16px;
  font-weight: 600;
  line-height: 1.5;
  text-align: center;
  text-decoration: none;
  overflow-wrap: anywhere;
  box-shadow: 0 8px 24px #801d3e18;
}

.public-copy .button:hover {
  border-color: var(--public-button-hover);
  background: var(--public-button-hover);
  color: var(--public-button-fg);
  box-shadow: 0 10px 28px #801d3e26;
}

.public-copy a:focus-visible,
.site-header:has(.public-logo) a:focus-visible,
.site-header:has(.public-logo) button:focus-visible,
.public-info ~ .site-footer a:focus-visible {
  outline: 3px solid var(--public-link);
  outline-offset: 5px;
}

.public-copy .public-text-link {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  margin-top: 24px;
  font-size: 16px;
  line-height: 1.5;
}

.public-legal-list a {
  background: var(--public-surface);
  border-color: var(--public-line);
}

/* Public shells have no mobile menu toggle, so navigation remains visible
   as a second row instead of inheriting the corporate collapsed menu. */
.site-header:has(.public-logo) {
  min-height: 104px;
  gap: 24px;
  background: var(--public-bg);
  color: var(--public-fg);
  border-color: var(--public-line);
}

.site-header:has(.public-logo) .brand-link {
  display: flex;
  align-items: center;
  min-width: 0;
  flex: 0 1 200px;
}

.site-header .public-logo {
  display: block;
  width: 200px;
  max-width: 100%;
  height: auto;
  background: transparent;
}

.site-header:has(.public-logo) .main-nav {
  flex-wrap: wrap;
  gap: 20px;
}

.site-header:has(.public-logo) .main-nav a {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  padding: 8px 0;
  color: var(--public-fg);
  font-size: 14px;
}

.site-header:has(.public-logo) .main-nav a:hover {
  color: var(--public-link);
}

.site-header:has(.public-logo) .header-controls {
  gap: 4px;
}

.header-controls button[data-public-lang] {
  min-width: 40px;
  min-height: 44px;
  padding: 8px;
  border: 1px solid transparent;
  border-radius: 10px;
  background: transparent;
  color: var(--public-muted);
  font-size: 13px;
  font-weight: 600;
}

.header-controls button[data-public-lang]:hover,
.header-controls button[data-public-lang]:focus-visible,
.header-controls button[data-public-lang][aria-pressed="true"] {
  border-color: var(--public-line);
  background: var(--public-surface);
  color: var(--public-link);
}

.public-info ~ .site-footer {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 12px 28px;
  padding: 28px 0 32px;
  color: var(--public-muted);
  border-color: var(--public-line);
}

.public-info ~ .site-footer small {
  color: var(--public-muted);
  font-size: 13px;
}

.public-info ~ .site-footer > a {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  color: var(--public-muted);
  font-size: 14px;
  line-height: 1.5;
  overflow-wrap: anywhere;
}

.public-info ~ .site-footer > a:hover {
  color: var(--public-link);
  text-decoration: underline;
  text-underline-offset: 4px;
}

/* Logo size must fit alongside language and appearance controls at 320px. */
.legal-brand {
  min-width: 0;
}

.legal-brand img {
  max-width: 100%;
  height: auto;
  background: transparent;
}

@media (max-width: 900px) {
  .site-header:has(.public-logo) {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    grid-template-rows: minmax(78px, auto) auto;
    gap: 0 16px;
    padding: 0 0 10px;
  }

  .site-header:has(.public-logo) .brand-link {
    grid-column: 1;
    grid-row: 1;
    width: min(200px, 100%);
  }

  .site-header:has(.public-logo) .header-controls {
    grid-column: 2;
    grid-row: 1;
  }

  .site-header:has(.public-logo) .main-nav {
    display: flex;
    grid-column: 1 / -1;
    grid-row: 2;
    flex-direction: row;
    align-items: center;
    justify-content: flex-start;
    width: 100%;
    margin: 0;
    padding: 0;
    gap: 4px 22px;
  }

  .site-header:has(.public-logo) .main-nav a {
    border: 0;
    padding: 8px 0;
  }
}

@media (max-width: 768px) {
  .site-header:has(.public-logo) {
    position: static;
  }

  .site-header:has(.public-logo) .brand-link,
  .site-header .public-logo {
    width: 164px;
    max-width: 100%;
  }

  .site-header:has(.public-logo) .main-nav {
    justify-content: center;
    gap: 4px 18px;
  }

  .site-header:has(.public-logo) .main-nav a {
    font-size: 13px;
  }

  .public-info {
    min-height: 55vh;
    padding: 52px 0 64px;
    text-align: center;
  }

  .public-copy h1,
  .public-copy p {
    margin-right: auto;
    margin-left: auto;
  }

  .public-copy p {
    font-size: 16px;
    line-height: 1.75;
  }

  .public-copy .button {
    padding: 14px 18px;
    font-size: 15px;
  }

  .public-info ~ .site-footer {
    justify-content: center;
    text-align: center;
    gap: 8px 20px;
  }

  .public-info ~ .site-footer small {
    flex-basis: 100%;
  }
}

@media (max-width: 360px) {
  .site-header:has(.public-logo) {
    column-gap: 10px;
  }

  .site-header:has(.public-logo) .brand-link,
  .site-header .public-logo {
    width: 142px;
  }

  .site-header:has(.public-logo) .main-nav {
    gap: 2px 16px;
  }

  .public-copy h1 {
    font-size: 34px;
  }

  .legal-header {
    padding-right: 16px;
    padding-left: 16px;
    gap: 12px;
  }

  .legal-brand img {
    width: 118px;
  }

  .legal-controls {
    gap: 8px;
  }

  .language-switch button {
    min-width: 32px;
    min-height: 38px;
    padding: 7px;
  }

  .legal-controls .theme-switch {
    width: 40px;
    height: 40px;
    flex: 0 0 40px;
  }
}

@media (prefers-reduced-motion: reduce) {
  .public-copy .button,
  .site-header:has(.public-logo) a {
    transition: none;
  }

  .public-copy .button:hover {
    transform: none;
  }
}

@media print {
  body:has(.public-info) {
    background: #ffffff;
    color: #111111;
  }

  .public-copy,
  .public-copy h1,
  .public-copy h2,
  .public-copy p,
  .public-copy li {
    color: #111111;
  }

  .public-copy .button,
  .public-copy a:not(.button) {
    background: #ffffff;
    color: #111111;
    border-color: #555555;
    box-shadow: none;
  }
}

/* Shared geometry; decorative SVGs inherit each component's text colour. */
.tricios-ui-icon{display:inline-block;vertical-align:middle;width:20px;height:20px;flex:0 0 20px;overflow:visible;fill:none;stroke:currentColor;stroke-width:1.5;stroke-linecap:round;stroke-linejoin:round}
.public-text-link{gap:12px}.registry-link .tricios-ui-icon{width:16px;height:16px;margin-left:3px}.document-card .card-arrow{display:flex;flex-shrink:0;padding-top:3px}.document-card .card-arrow .tricios-ui-icon{width:20px;height:20px}.document-related .tricios-ui-icon{width:16px;height:16px;flex-basis:16px}.preview-battery{display:inline-block;vertical-align:middle;width:20px;height:14px}

/* Shared page canvas: consistent across corporate, commercial and legal windows. */
:root[data-theme="light"] {
  --page-canvas: #fff;
  --ivory: #fff;
  --bg: #fff;
  --public-bg: #fff;
}
:root[data-theme="dark"] {
  --page-canvas: #000;
  --ivory: #000;
  --bg: #000;
  --public-bg: #000;
}
html[data-theme], html[data-theme] body {
  background-color: var(--page-canvas) !important;
}
html[data-theme] .site-header,
html[data-theme] .public-header,
html[data-theme] .legal-header,
html[data-theme] .language-options {
  background-color: var(--page-canvas);
}

/* Sales windows follow the selected theme instead of forcing graphite in light mode. */
html[data-theme="light"] :is(.software-section,.configurator-suite,.marketing-sales-panel,.one-off-card) {
  color-scheme: light;
  --ivory: #fff;
  --panel: #fff;
  --ink: #151a22;
  --secondary: #596374;
  --line: #dce1e8;
  --surface: #fff;
  --card: #fff;
  --ink-rgb: 21,26,34;
  color: var(--ink);
  background-color: #fff;
}
html[data-theme="dark"] :is(.software-section,.configurator-suite,.marketing-sales-panel,.one-off-card) {
  color-scheme: dark;
  --ivory: #000;
  --panel: #000;
  --ink: #f4f4f5;
  --secondary: #bfc3cc;
  --line: #3b3b40;
  --surface: #000;
  --card: #000;
  --ink-rgb: 244,244,245;
  color: var(--ink);
  background-color: #000;
}
html[data-theme] .one-off-card-art { color: var(--ink); }

html[data-theme="light"] .product-art[data-furniture-kind],
html[data-theme="light"] .cutlist-benefit strong { color: var(--ink); }

/* Light-only colour separates 3D and Web cards from the white page. */
html[data-theme="light"] .configurator-suite {
  --card: #f7f8fa;
  --surface: #f2f4f7;
  --line: #dce1e8;
}
html[data-theme="light"] .marketing-sales-panel {
  --card: #f7f8fa;
  --surface: #f2f4f7;
  --line: #dce1e8;
  background-color: #f2f4f7;
}
html[data-theme="light"] .marketing-sales-panel .marketing-feature {
  background-color: transparent;
}

/* Keep the current catalogue cover visible without cropping its copy. */
.site-preview img[data-demo-preview] { aspect-ratio: 16 / 9; object-fit: contain; }

/* All public copy is centred on desktop and mobile. */
main, main :is(h1,h2,h3,h4,h5,h6,p,label,summary,li,figcaption), footer { text-align:center; }
main :is(.hero-description,.overview-content>p,.mkt-copy>p,.sponsor-description,.sponsor-note,.interest-intro,.interest-description) { margin-inline:auto; }
main :is(.mkt-copy,.contact-actions) { align-items:center; }
main :is(.hero-actions,.sponsor-actions,.interest-actions,.checklist,.sponsor-sample-top,.sponsor-sample-footer) { justify-content:center; }
main :is(.sponsor-details ul,.product-card ul) { list-style-position:inside;padding-inline:0; }
html[data-theme=light] { --public-surface:#f7f8fa; --public-line:#dce1e8; }
html[data-theme=dark] { --public-surface:#111113; --public-line:#3b3b40; }
.sponsor-page main :is(.interest-copy,.sponsor-details,.sponsor-step,.interest-status) { text-align:center; }
.sponsor-page main :is(h1,h2,h3,p) { margin-inline:auto; }
.sponsor-page .interest-back { display:flex;justify-content:center;width:fit-content;margin-inline:auto; }

:root[data-theme=light] { --public-surface:#f7f8fa; --public-line:#dce1e8; }
:root[data-theme=dark] { --public-surface:#111113; --public-line:#3b3b40; }
.sponsor-page .interest-hero { grid-template-columns:minmax(0,1fr);justify-items:center; }
.sponsor-page .interest-hero>div { width:100%;max-width:760px;margin-inline:auto; }
.sponsor-page .interest-actions { justify-content:center; }
.sponsor-page .interest-status { margin-inline:auto; }

/* Compact introduction, matching the approved mobile proportions. */
.corporate-home .intro-brand { width:clamp(120px,34vw,160px); }

/* The three solution arrows share the Web card treatment. */
#divisiones .division-card .card-arrow { background:var(--accent);border-color:var(--accent);color:var(--accent-ink); }
html[data-theme=dark] #divisiones .division-card .card-arrow { border-color:var(--accent-electric);box-shadow:0 0 12px rgba(var(--accent-electric-rgb),.12); }

.corporate-home .hero-actions { justify-content:center; }
.corporate-home .hero-actions .quiet-link { margin-inline:auto;justify-content:center;width:fit-content; }

.corporate-home .hero-copy { text-align:center; }
.corporate-home .hero-description { text-align:center;margin-inline:auto; }
.corporate-home .overview-content { grid-template-columns:minmax(0,1fr);text-align:center; }

/* Minimal solution cards and a single centred 3D heading. */
#divisiones .card-top { justify-content:center; }
.configurator-suite-heading { grid-template-columns:minmax(0,1fr);text-align:center; }

/* Keep labels optically centred while their icons stay on the right. */
.configurator-suite .product-card summary,
.configurator-suite .product-primary { position:relative;display:flex;justify-content:center;text-align:center;padding-inline:44px; }
.configurator-suite .product-card summary>span { position:absolute;right:0;top:50%;transform:translateY(-50%); }
.configurator-suite .product-primary>svg { position:absolute;right:18px;top:50%;transform:translateY(-50%); }

.configurator-suite .product-card details[open] summary>span { transform:translateY(-50%) rotate(45deg); }

/* 279: fewer nested frames, shared spacing and a compact legal footer. */
.corporate-home :is(.software-section,.configurator-suite,.marketing-sales-panel) {
 border:0;box-shadow:none;padding:clamp(20px,3vw,36px) 0;border-radius:0;
}
.corporate-home :is(#tricios-3d,#tricios-web) { padding:56px 16px 20px !important; }
.corporate-home .configurator-suite { margin-top:12px; }
.corporate-home .configurator-suite-heading { margin-bottom:28px; }
.corporate-home .configurator-grid { gap:24px; }
.corporate-home .configurator-grid .product-card { border-radius:20px; }
.corporate-home .product-art { border-bottom:0; }
.corporate-home .cutlist-benefit { border-top:0; }
.corporate-home .marketing-sales-panel .marketing-feature { border:0;box-shadow:none; }
.corporate-home .marketing-sales-panel .site-preview { box-shadow:none;border-radius:16px;margin:0;padding:16px; }
.corporate-home .site-footer { display:flex;flex-direction:column;align-items:center;gap:14px;padding:32px 0;text-align:center; }
.corporate-home .site-footer .footer-links { justify-content:center;gap:24px; }
.corporate-home .site-footer .prelaunch-legal-links { display:flex;justify-content:center;padding:0;border:0;margin:0; }
.corporate-home .site-footer .prelaunch-legal-identity { display:flex;flex-direction:column;gap:3px;align-items:center;font-size:11px;line-height:1.5;margin:0;padding:0;border:0; }
.corporate-home .site-footer .prelaunch-legal-identity p { margin:0; }
.corporate-home .site-footer .back-top { align-self:center; }
@media(max-width:768px){
 .corporate-home :is(#tricios-3d,#tricios-web) { padding-top:40px !important; }
 .corporate-home .configurator-grid { gap:20px; }
}

/* No rectangular surface behind the two rounded Web cards. */
html.corporate-home[data-theme] .marketing-sales-panel,
html.corporate-home[data-theme] .marketing-sales-panel .marketing-feature {
 background:transparent !important;
}
.corporate-home .marketing-sales-panel { overflow:visible; }
.corporate-home .marketing-sales-panel .marketing-feature { grid-template-columns:minmax(0,1fr) minmax(0,1.2fr);gap:24px;min-width:0; }
.corporate-home .marketing-sales-panel :is(.mkt-copy,.site-preview) { min-width:0;max-width:100%;margin:0; }
.corporate-home .marketing-sales-panel .mkt-copy { padding:28px; }
.corporate-home .marketing-bottom { justify-content:center;text-align:center;padding-inline:16px; }
.corporate-home .marketing-bottom>p { margin-inline:auto; }
@media(max-width:768px){
 .corporate-home .marketing-sales-panel .marketing-feature { grid-template-columns:minmax(0,1fr);gap:20px; }
 .corporate-home .marketing-sales-panel .mkt-copy { padding:24px 20px; }
}
.corporate-home .site-footer .prelaunch-legal-identity[hidden] { display:none; }

/* Dark-only depth: near-black centre, black edges and a restrained rim. */
html.corporate-home[data-theme=dark] #software .configurator-suite .product-card,
html.corporate-home[data-theme=dark] .marketing-sales-panel .marketing-feature .mkt-copy,
html.corporate-home[data-theme=dark] .marketing-sales-panel .marketing-feature .site-preview {
 background:radial-gradient(ellipse at 50% 42%,#100f12 0%,#050506 62%,#000 100%) !important;
 border:1px solid #ffffff14;
 box-shadow:inset 0 1px 0 #ffffff08,0 16px 32px -20px #000,0 2px 8px #0008;
}
html.corporate-home[data-theme=dark] .configurator-suite .product-art { background:transparent !important; }
html.corporate-home[data-theme=dark] .configurator-suite .cutlist-benefit strong,
html.corporate-home[data-theme=dark] .configurator-suite .cutlist-benefit span { color:#fff; }

.archived-notice { max-width:900px;margin:24px auto;padding:18px 24px;border:1px solid var(--public-line);border-radius:12px;text-align:center;color:var(--public-fg);background:var(--public-surface); }
.archived-notice p { margin:8px 0 0;line-height:1.6; }
.corporate-home .prelaunch-legal-identity { max-width:680px;overflow-wrap:anywhere; }

html.corporate-home[data-theme] body .marketing-integrated .marketing-sales-panel { background:transparent !important; }
