/* WordPress-only additions. The home page uses site.css alone; these rules cover the other pages
   until each gets its own design. */

/* Pages other than the home page have no picture under the header, so it starts white. */
body:not(.home):not(.has-hero) .site-header.is-clear .bar { background: #fff; box-shadow: 0 1px 0 var(--paper-rule); }
body:not(.home):not(.has-hero) .site-header.is-clear .nav-top,
body:not(.home):not(.has-hero) .site-header.is-clear .langs-toggle { color: var(--paper-ink); text-shadow: none; }
body:not(.home):not(.has-hero) .site-header.is-clear .mark-colour { opacity: 1; }
body:not(.home):not(.has-hero) .site-header.is-clear .mark-white { opacity: 0; }
body:not(.home):not(.has-hero) .site-header.is-clear .bar-cta { background: var(--paper-ink); color: #fff; }
body:not(.home):not(.has-hero) .site-header.is-clear .nav-toggle { background: #fff; border-color: var(--paper-rule); }
body:not(.home):not(.has-hero) .site-header.is-clear .nav-toggle-bars,
body:not(.home):not(.has-hero) .site-header.is-clear .nav-toggle-bars::before,
body:not(.home):not(.has-hero) .site-header.is-clear .nav-toggle-bars::after { background: var(--paper-ink); }

body:not(.home) { background: var(--paper); color: var(--paper-ink); color-scheme: light; }
.wp-page { padding: calc(var(--bar-h) + clamp(3rem, 6vw, 5rem)) var(--gutter) clamp(4rem, 8vw, 7rem); min-height: 60vh; }
.wp-page > * { max-width: 48rem; margin-inline: auto; }
.wp-page .wp-block-post-title { font-size: var(--fs-h2); margin-bottom: 1.5rem; }
.wp-page .wp-block-post-content > * + * { margin-top: 1.1rem; }
.wp-page a { color: var(--blue); }

/* When someone is logged in, WordPress shows its admin bar at the top; the fixed header and menus sit below it. */
body.admin-bar .site-header { top: var(--wp-admin--admin-bar--height, 32px); }
body.admin-bar .site-nav.is-open { top: calc(var(--header-h) + var(--wp-admin--admin-bar--height, 32px)); }
body.admin-bar .langs-menu { top: calc(var(--bar-h) + var(--wp-admin--admin-bar--height, 32px)); }

/* Home page cards link to their service pages. */
.card h3 a { color: inherit; text-decoration: none; }
.card h3 a:hover { text-decoration: underline; text-underline-offset: 0.2em; }
.pg-section > .pg-cards:first-child { margin-top: 0; }

/* Home page "Who we work with" panel titles link to their pages. */
.who h3 a { color: inherit; text-decoration: none; }
.who h3 a:hover { text-decoration: underline; text-underline-offset: 0.2em; }

/* The contact form: a field people never see, left empty by people and filled in by bots. */
.contact-form .hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }
.contact-form { position: relative; }
#form-send:disabled { opacity: 0.7; cursor: progress; }
/* Answer to a form sent without the page script. */
.pg-sent { margin: 0; padding: 1rem var(--edge); background: var(--paper-ink); color: #fff; }

/* Translated labels can be longer than the English ones: a device tab keeps its name on one line. */
.device-tabs [role="tab"] { white-space: nowrap; }
@media (max-width: 30rem) {
  .device-tabs { gap: 0.15rem; overflow-x: auto; scrollbar-width: none; }
  .device-tabs [role="tab"] { padding-inline: 0.5rem; font-size: 0.84rem; }
}

/* The header button is longest in Spanish ("Hablar con un experto"); on the narrowest phones it tightens. */
@media (max-width: 24rem) {
  .bar { gap: 0.4rem; }
  .bar-cta { padding-inline: 0.65rem; font-size: 0.78rem; }
}

/* Languages at the foot of the phone menu, for phones too narrow for the header's language button. */
.nav-langs { display: none; }
@media (max-width: 30rem) {
  .nav-langs { display: flex; flex-wrap: wrap; gap: 0.25rem clamp(0.7rem, 3vw, 1.25rem); padding: 1.25rem 0 0.5rem; }
  .nav-langs a, .nav-langs span { padding-block: 0.5rem; font-size: 0.95rem; font-weight: 560; color: var(--paper-ink); text-decoration: none; }
  .nav-langs a[aria-current] { color: var(--blue); text-decoration: underline; text-underline-offset: 0.25em; }
  .nav-langs span { color: var(--paper-ink-2); }
  .nav-langs small { font-size: 0.8em; }
}
