/* The portrait becomes a wide profile, with space for the name beside the subject. */
@media (max-width: 800px) {
  body.renduva-interface #quienes-somos {
    --vivid-about: url('/assets/vivid/about-hd.webp');
    padding: clamp(3.75rem, 10vw, 6rem) max(1.25rem, 5.2vw);
    background: radial-gradient(ellipse at 10% 25%, #0b2d55, transparent 65%), #03132e;
  }
  body.renduva-interface #quienes-somos::before {
    inset: 12% 0 auto;
    height: min(38rem, 75%);
    background: var(--vivid-about) right center / auto 100% no-repeat;
    opacity: .32;
    mask-image: linear-gradient(transparent, black 16%, black 74%, transparent);
  }
  #quienes-somos .about-inner {
    width: 100%;
    max-width: 36rem;
    gap: 1.45rem;
  }
  #quienes-somos .about-eyebrow { margin-bottom: 1rem; font-size: .75rem; letter-spacing: .18em; }
  #quienes-somos #about-title {
    max-width: 18ch;
    font-size: clamp(2rem, 8.2vw, 3.25rem);
    line-height: 1.08;
    letter-spacing: -.045em;
    text-wrap: balance;
  }
  #quienes-somos .about-description { margin-top: 1rem; font-size: 1rem; line-height: 1.65; }
  #quienes-somos .about-portrait {
    width: 100%;
    aspect-ratio: 1.85;
    max-height: 19rem;
    overflow: hidden;
  }
  #quienes-somos .about-portrait img {
    left: auto;
    right: -1.5%;
    top: 0;
    bottom: auto;
    width: 65%;
  }
  #quienes-somos .about-portrait-caption {
    left: 5%;
    bottom: 10%;
    width: auto;
    max-width: 50%;
    padding: .75rem 1rem;
    border-radius: .7rem;
  }
  #quienes-somos .about-portrait-caption::before { width: 1.3rem; margin-bottom: .5rem; }
  #quienes-somos .about-portrait-caption strong { color: #c1e1f8; font-size: .75rem; }
  #quienes-somos .about-portrait-caption span { display: block; margin-top: .15rem; color: #f5faff; font-size: clamp(1rem, 4.4vw, 1.5rem); font-weight: 700; line-height: 1.25; }
  #quienes-somos .about-values { gap: .75rem; }
  #quienes-somos .about-value { padding: 1rem; gap: .65rem; }
  #quienes-somos .about-value h3 { font-size: 1.08rem; line-height: 1.3; margin-bottom: .25rem; }
  #quienes-somos .about-value p { font-size: 1rem; line-height: 1.45; }
  #quienes-somos .about-action { flex-wrap: wrap; gap: .6rem 1rem; }
  #quienes-somos .about-note { margin: 0; font-size: .8125rem; line-height: 1.5; }
  #quienes-somos .about-note span { max-width: none; }
  #quienes-somos .about-cta { min-height: 3.15rem; font-size: 1rem; }
}
@media (max-width: 460px) {
  #quienes-somos .about-values { grid-template-columns: minmax(0, 1fr); grid-auto-rows: auto; }
  #quienes-somos .about-value { grid-template-columns: 2.5rem minmax(0, 1fr); align-items: center; gap: 1rem; }
  #quienes-somos .about-icon { width: 2.5rem; height: 2.5rem; }
  #quienes-somos .about-action { flex-direction: column; align-items: stretch; }
  #quienes-somos .about-note { justify-content: center; padding: 0; border: 0; text-align: center; }
}

@media (max-width: 760px) {
  /* Frame the headline with the two edges of the original glass artwork. */
  body.renduva-interface #contacto {
    --closing-art: url('/assets/vivid/closing-hd.webp');
    min-height: clamp(31rem, 82svh, 43rem);
    padding: 4rem max(1.25rem, 5vw);
    background: radial-gradient(ellipse at 50% 98%, #12478577, transparent 45%), #031331;
  }
  body.renduva-interface #contacto::before,
  body.renduva-interface #contacto::after {
    content: '';
    position: absolute;
    inset: 0 auto 0 0;
    width: 45%;
    background: var(--closing-art) left -2.4rem center / auto 100% no-repeat;
    mask-image: linear-gradient(to right, black, #0008 44%, transparent);
    opacity: .78;
    pointer-events: none;
  }
  body.renduva-interface #contacto::after {
    inset: 0 0 0 auto;
    background-position: right -2.4rem center;
    mask-image: linear-gradient(to left, black, #0008 44%, transparent);
  }
  #contacto .statement-content { gap: clamp(1.8rem, 6svh, 3rem); }
  #contacto #statement-title { margin: 0; font-size: clamp(2.05rem, 8.8vw, 3.85rem); line-height: 1.06; text-wrap: balance; }
  #contacto .statement-action { max-width: 100%; gap: .7rem; }
  #contacto .statement-eyebrow, #contacto .future-cta-note { margin: 0; font-size: .8125rem; }
  #contacto .future-cta { max-width: 100%; width: min(20rem, 88vw); min-height: 4.45rem; height: auto; }
  #contacto .future-cta-surface { height: auto; min-height: 3.85rem; padding: .6rem 1rem; gap: .75rem; }
  #contacto .future-cta-label { white-space: normal; font-size: 1rem; }
  #contacto .future-cta-port { width: 2rem; height: 2rem; }

  .site-footer { padding-inline: max(1.25rem, 5vw); }
  .site-footer .footer-main {
    grid-template-columns: minmax(0, 1fr);
    gap: .875rem;
    padding-block: 1.5rem 1rem;
  }
  .site-footer .footer-brand { min-height: 44px; }
  .site-footer .footer-brand picture { display: flex; }
  .site-footer .footer-navigation {
    grid-column: 1;
    grid-row: auto;
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 0 1rem;
    padding-block: .4rem;
    border-block: 1px solid #89cbff24;
  }
  .site-footer .footer-contact { grid-column: 1; grid-row: auto; display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: .125rem 1rem; }
  .site-footer :is(.footer-navigation a, .footer-contact-link, .footer-email, .footer-top, .footer-privacy a, .analytics-preferences) {
    display: inline-flex;
    align-items: center;
    min-height: 44px;
    padding-block: .5rem;
    font-size: .875rem;
    line-height: 1.4;
  }
  .site-footer .footer-bottom { align-items: center; gap: .25rem 1rem; padding-block: .75rem calc(4.5rem + env(safe-area-inset-bottom, 0px)); }
  .site-footer .footer-bottom small { width: 100%; max-width: none; font-size: .75rem; }
  .site-footer .footer-privacy { flex-wrap: wrap; gap: 0 1rem; }
  .site-footer .footer-top { margin-right: auto; }
  .site-footer .footer-top span { font-size: inherit; }

  /* Native modal sheets scroll internally, including on short landscape screens. */
  #brief-dialog, #whatsapp-dialog {
    --sheet-inset: max(.75rem, env(safe-area-inset-top, 0px));
    --sheet-height: calc(100dvh - var(--sheet-inset));
    position: fixed;
    inset: auto 0 0;
    margin: 0 auto;
    width: min(100%, 33rem);
    max-width: 100%;
    max-height: var(--sheet-height);
    border-radius: 1.25rem 1.25rem 0 0;
  }
  #brief-dialog::backdrop, #whatsapp-dialog::backdrop { background: #010c1fc9; backdrop-filter: blur(5px); }
  body:has(#brief-dialog[open], #whatsapp-dialog[open]) { overflow: hidden; }
  #brief-dialog .contact-dialog-content {
    max-height: calc(var(--sheet-height) - 2px);
    padding: 1.5rem max(1.25rem, env(safe-area-inset-right, 0px)) max(1.25rem, env(safe-area-inset-bottom, 0px)) max(1.25rem, env(safe-area-inset-left, 0px));
    scroll-padding-block: 1rem;
  }
  #brief-dialog .dialog-close, #whatsapp-dialog .wa-close {
    top: .4rem;
    right: max(.45rem, env(safe-area-inset-right, 0px));
    width: 44px;
    height: 44px;
    border: 1px solid #89c9ff33;
    background: #082347;
  }
  #brief-dialog h2 { padding-right: 2.3rem; font-size: clamp(1.4rem, 6.3vw, 1.8rem); line-height: 1.18; }
  #brief-dialog #brief-description { margin: .8rem 0 1.15rem; font-size: 1rem; line-height: 1.5; }
  #brief-dialog #brief-form { gap: .85rem; }
  #brief-dialog label, #whatsapp-dialog label { margin-bottom: .35rem; font-size: .875rem; line-height: 1.4; }
  #brief-dialog :is(input, select, textarea) { min-height: 46px; padding-block: .65rem; font-size: max(16px, 1rem); line-height: 1.4; }
  #brief-dialog textarea { height: 5.25rem; max-height: none; }
  #brief-dialog .contact-submit, #whatsapp-dialog .wa-send { min-height: 3rem; font-size: 1rem; }
  #brief-dialog .contact-reassurance, #whatsapp-dialog .wa-note { font-size: .8125rem; line-height: 1.4; }
  #whatsapp-dialog .wa-heading { padding: 1.4rem 3.7rem 1.15rem 1.25rem; }
  #whatsapp-dialog .wa-body { padding: 1.25rem 1.25rem max(1.25rem, env(safe-area-inset-bottom, 0px)); }
  #whatsapp-dialog .wa-eyebrow { font-size: .6875rem; letter-spacing: .13em; }
  #whatsapp-dialog .wa-person strong { font-size: 1rem; }
  #whatsapp-dialog .wa-person div > span { font-size: .875rem; }
  #whatsapp-dialog #whatsapp-intro { font-size: 1rem; line-height: 1.5; }
  #whatsapp-dialog textarea { font-size: max(16px, 1rem); }

  #whatsapp-launcher {
    right: max(.875rem, env(safe-area-inset-right, 0px));
    bottom: calc(.875rem + env(safe-area-inset-bottom, 0px) + var(--wa-consent-offset, 0px));
    display: grid;
    place-items: center;
    min-height: 48px;
    width: 48px;
    height: 48px;
    padding: 0;
    border-radius: 16px;
  }
  #whatsapp-launcher > span { display: none; }


  #renduva-consent {
    left: max(.625rem, env(safe-area-inset-left, 0px));
    right: max(.625rem, env(safe-area-inset-right, 0px));
    bottom: max(.625rem, env(safe-area-inset-bottom, 0px));
    width: auto;
    max-width: 25rem;
    max-height: calc(100dvh - max(1.5rem, env(safe-area-inset-top, 0px)) - max(.625rem, env(safe-area-inset-bottom, 0px)));
    margin-inline: auto;
    padding: .8rem 1rem .25rem;
    border-radius: 1rem;
    overscroll-behavior: contain;
    font-size: .8125rem;
  }
  #renduva-consent strong { font-size: .9375rem; }
  #renduva-consent p { margin: .2rem 0 .6rem; }
  #renduva-consent button { min-height: 44px; font-size: .875rem; white-space: normal; }
  #renduva-consent .consent-settings { margin: 0; }
  #renduva-consent summary, #renduva-consent .consent-settings > a { display: flex; align-items: center; gap: .25rem; min-height: 44px; padding: .35rem 0; font-size: .8125rem; }
  #renduva-consent label { display: flex; flex-direction: row; align-items: flex-start; min-height: 44px; }
  #renduva-consent input[type=checkbox] { min-height: 0; }
  #renduva-consent label b { font-size: .875rem; }
  #renduva-consent label small { font-size: .8125rem; }

  body.renduva-legal { --vivid-about: url('/assets/vivid/about-hd.webp'); }
  .renduva-legal > header { position: relative; align-items: center; gap: .7rem; padding: max(.7rem, env(safe-area-inset-top, 0px)) max(1rem, 4vw) .7rem; }
  .renduva-legal > header > a { display: inline-flex; min-height: 44px; align-items: center; line-height: 1.25; }
  .renduva-legal > header > a + a { margin-left: auto; text-align: right; font-size: .875rem; }
  .renduva-legal > header > .language-picker { position: relative; inset: auto; flex: none; width: 44px; height: 44px; }
  .renduva-legal main { padding: 2rem max(1rem, 4vw) 4rem; overflow-wrap: anywhere; }
  .renduva-legal main h1 { margin: .6rem 0 1rem; }
  .renduva-legal main p { font-size: 1rem; line-height: 1.6; }
  .renduva-legal main section { padding: 1.15rem; }
  .renduva-legal main section h2 { font-size: 1.25rem; line-height: 1.25; }
  .renduva-legal .table-wrap { overscroll-behavior-inline: contain; }
  .renduva-legal table { min-width: 30rem; table-layout: fixed; white-space: normal; font-size: .875rem; }
  .renduva-legal :is(th, td) { vertical-align: top; }
}

@media (max-width: 899px) {
  #whatsapp-launcher.wa-obstructs-action,
  body:has(#renduva-consent:not([hidden]), dialog[open], .chapter-nav.is-open) #whatsapp-launcher {
    visibility: hidden;
    pointer-events: none;
  }
}
