/* evidentlymethod.com shared styles: fonts, header, footer, layout switching and the small-screen rules.
   The page sections themselves keep the inline styles from the design canvas (design/*.dc.html). */

@font-face { font-family: 'Newsreader'; font-style: normal; font-display: swap; font-weight: 200 800; src: url(/assets/fonts/newsreader-latin-opsz-normal.woff2) format('woff2-variations'); }
@font-face { font-family: 'IBM Plex Sans'; font-style: normal; font-display: swap; font-weight: 400; src: url(/assets/fonts/ibm-plex-sans-latin-400-normal.woff2) format('woff2'); }
@font-face { font-family: 'IBM Plex Sans'; font-style: normal; font-display: swap; font-weight: 500; src: url(/assets/fonts/ibm-plex-sans-latin-500-normal.woff2) format('woff2'); }
@font-face { font-family: 'IBM Plex Sans'; font-style: normal; font-display: swap; font-weight: 600; src: url(/assets/fonts/ibm-plex-sans-latin-600-normal.woff2) format('woff2'); }
@font-face { font-family: 'IBM Plex Mono'; font-style: normal; font-display: swap; font-weight: 400; src: url(/assets/fonts/ibm-plex-mono-latin-400-normal.woff2) format('woff2'); }
@font-face { font-family: 'IBM Plex Mono'; font-style: normal; font-display: swap; font-weight: 500; src: url(/assets/fonts/ibm-plex-mono-latin-500-normal.woff2) format('woff2'); }

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: 96px; -webkit-text-size-adjust: 100%; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }
body { margin: 0; font-family: 'IBM Plex Sans', system-ui, sans-serif; color: #16191D; background: #F4F2EC; }
a { color: #1F4E5F; } a:hover { color: #143642; }
:focus-visible { outline: 3px solid #1F4E5F; outline-offset: 3px; }
img, svg { max-width: 100%; }
.skip-link { position: absolute; left: 12px; top: -60px; padding: 10px 16px; background: #16191D; color: #FFFFFF; border-radius: 6px; z-index: 100; }
.skip-link:focus { top: 12px; }

/* Header */
.site-header { position: sticky; top: 0; z-index: 50; display: flex; align-items: center; justify-content: space-between; gap: 24px; padding: 18px clamp(20px, 5.5vw, 80px); background: #F4F2EC; border-bottom: 1px solid #D9D5CA; }
.brand { display: flex; flex-direction: column; align-items: flex-start; gap: 2px; text-decoration: none; color: #16191D; }
.brand:hover { color: #16191D; }
.brand-name { font-family: 'Newsreader', Georgia, serif; font-size: 38px; font-weight: 700; letter-spacing: -0.01em; line-height: 1.05; }
.brand-tag { font-family: 'IBM Plex Mono', monospace; font-size: 14px; letter-spacing: 0.08em; color: #A4461F; white-space: nowrap; }
.site-nav { display: flex; align-items: center; gap: 30px; font-size: 20px; }
.site-nav a { color: #16191D; text-decoration: none; white-space: nowrap; }
.site-nav a:hover { color: #1F4E5F; text-decoration: underline; text-underline-offset: 6px; }
.site-nav a[aria-current="page"] { color: #1F4E5F; text-decoration: underline; text-underline-offset: 6px; }
.site-nav a.cta { display: inline-flex; align-items: center; min-height: 48px; padding: 0 22px; background: #1F4E5F; color: #FFFFFF; border-radius: 6px; font-weight: 500; text-decoration: none; }
.site-nav a.cta:hover { background: #143642; color: #FFFFFF; }
.menu-btn { display: none; width: 44px; height: 44px; align-items: center; justify-content: center; border: 1px solid #D9D5CA; border-radius: 6px; background: transparent; cursor: pointer; }
@media (max-width: 1360px) { .site-nav { gap: 20px; font-size: 17px; } .site-nav a.cta { min-height: 44px; padding: 0 18px; } }
@media (max-width: 1180px) { .brand-tag { font-size: 12px; } .site-nav { gap: 16px; font-size: 16px; } }

/* Footer */
.site-footer { display: flex; flex-direction: column; gap: 28px; padding: 64px clamp(20px, 5.5vw, 80px); background: #16191D; color: #F4F2EC; }
.site-footer .row { display: flex; justify-content: space-between; align-items: start; gap: 32px; flex-wrap: wrap; }
.site-footer .lockup { display: flex; align-items: baseline; gap: 12px; flex-wrap: wrap; }
.site-footer .lockup .n { font-family: 'Newsreader', Georgia, serif; font-size: 26px; font-weight: 600; }
.site-footer .lockup .t { font-family: 'IBM Plex Mono', monospace; font-size: 16px; letter-spacing: 0.12em; color: #E08A62; }
.site-footer p { margin: 0; font-size: 17px; color: #C9CCCF; }
.site-footer nav { display: flex; flex-wrap: wrap; gap: 16px 28px; font-size: 17px; }
.site-footer nav a { color: #F4F2EC; }
.site-footer .legal { padding-top: 24px; border-top: 1px solid #3A3F45; font-size: 14px; line-height: 1.6; color: #A9AEB3; }

/* Home page: one layout from the desktop design; src/home-responsive.css reflows it for tablets and phones. */
.layout-d > .root, .page-root { width: auto !important; max-width: 1600px; height: auto !important; margin: 0 auto; }
/* Tinted and dark bands run the full width of the window; their content stays in the 1600px column. */
.layout-d > .root > section[style*="background: #16191D"] { box-shadow: 0 0 0 100vmax #16191D; clip-path: inset(0 -100vmax); }
.layout-d > .root > section[style*="background: #E9E6DD"] { box-shadow: 0 0 0 100vmax #E9E6DD; clip-path: inset(0 -100vmax); }
/* Form */
.case-form .hp { position: absolute; left: -10000px; width: 1px; height: 1px; overflow: hidden; }
.case-form input:invalid:not(:placeholder-shown), .case-form textarea:invalid:not(:placeholder-shown) { border-color: #A4461F; }
.form-status { margin: 0; font-size: 17px; line-height: 1.5; }
.form-status.ok { color: #1F4E5F; } .form-status.err { color: #A4461F; }
.case-form button[disabled] { opacity: .6; cursor: progress; }

/* Small screens: header and footer (the menu button takes over below 1100px, so the full menu never overflows on a tablet held sideways) */
@media (max-width: 1099px) {
  .site-header { padding: 12px 20px; flex-wrap: wrap; gap: 12px; }
  .brand-name { font-size: 30px; }
  .brand-tag { font-size: 11px; letter-spacing: 0.06em; }
  .menu-btn { display: inline-flex; }
  .site-nav { display: none; width: 100%; flex-direction: column; align-items: stretch; gap: 0; font-size: 18px; padding: 8px 0 12px; }
  .site-nav.open { display: flex; }
  .site-nav a { padding: 12px 4px; border-top: 1px solid #E2DED4; }
  .site-nav a.cta { justify-content: center; margin-top: 12px; border-top: 0; }
  .site-footer { padding: 40px 20px; gap: 20px; }
  .site-footer .lockup .n { font-size: 22px; } .site-footer .lockup .t { font-size: 13px; }
}

/* Case study and other single-layout pages on small screens */
@media (max-width: 999px) {
  .page-root section { padding-left: 20px !important; padding-right: 20px !important; padding-top: 56px !important; margin-left: 0 !important; margin-right: 0 !important; max-width: none !important; }
  .page-root [style*="grid-template-columns"] { grid-template-columns: 1fr !important; gap: 20px !important; }
  .page-root h1 { font-size: 40px !important; line-height: 1.08 !important; }
  .page-root h2 { font-size: 32px !important; line-height: 1.12 !important; }
  .page-root h3 { font-size: 22px !important; }
  .page-root p, .page-root li { font-size: 17px !important; }
  .page-root table { display: block; overflow-x: auto; }
}

/* Plain text pages (privacy notice, form replies, 404) */
.plain-page { max-width: 760px; margin: 0 auto; padding: 72px clamp(20px, 5vw, 40px) 96px; font-size: 18px; line-height: 1.65; color: #3E444A; }
.plain-page h1 { font-family: 'Newsreader', Georgia, serif; font-weight: 500; font-size: clamp(36px, 6vw, 52px); line-height: 1.08; color: #16191D; margin: 0 0 24px; }
.plain-page h2 { font-family: 'Newsreader', Georgia, serif; font-weight: 500; font-size: 28px; color: #16191D; margin: 40px 0 12px; }
.plain-page .eyebrow { font-family: 'IBM Plex Mono', monospace; font-size: 15px; letter-spacing: 0.1em; color: #A4461F; margin: 0 0 12px; }
.plain-page .note { padding: 16px 20px; background: #E9E6DD; border-radius: 8px; font-size: 16px; }
body.plain .brand { margin-bottom: 40px; }

/* Desktop hero: the text and the whole animation fit in one screen below the header. (1000px and wider) */
@media (min-width: 1000px) {
  .layout-d #top { min-height: calc(100vh - 96px); box-sizing: border-box; padding-top: clamp(20px, 4vh, 56px) !important; padding-bottom: clamp(32px, 6vh, 80px) !important; align-items: center !important; }
  .layout-d #top > div:first-child { gap: clamp(10px, 2.2vh, 28px) !important; }
  .layout-d #top h1 { font-size: clamp(50px, 8vh, 84px) !important; }
  .layout-d #top h2 { font-size: clamp(24px, 3.6vh, 36px) !important; }
  .layout-d #top > div:first-child > p:first-of-type { font-size: clamp(16px, 2.3vh, 22px) !important; }
  .layout-d #top figure { gap: 10px !important; }
  .layout-d #top figure > div { padding-top: clamp(12px, 2vh, 24px) !important; }
  .layout-d #top figure p[data-evh] { font-size: clamp(19px, 2.8vh, 27px) !important; }
  .layout-d #top figure p[data-evh="d"] { font-size: clamp(36px, 5.6vh, 56px) !important; }
  .layout-d #top svg[data-evfield] { display: block; width: auto !important; max-width: 100%; height: calc(100vh - 96px - clamp(20px, 4vh, 56px) - clamp(32px, 6vh, 80px) - clamp(12px, 2vh, 24px) - 12px - 3 * 1.22 * clamp(19px, 2.8vh, 27px) - 28px - 34px) !important; min-height: 280px; margin: 0 auto; }
}

/* Section dividers are drawn as a 1px background line inset by the side padding; on phones the inset matches the 20px gutter. */
@media (max-width: 999px) { .page-root section[style*="linear-gradient(#D9D5CA"] { background-size: calc(100% - 40px) 1px !important; } }


/* Case study on phones: one 48px rhythm, readable tables and figures, no empty arrow cells. */
@media (max-width: 999px) {
  .page-root section { padding-top: 48px !important; padding-bottom: 48px !important; gap: 28px !important; }
  .page-root section[aria-label="Headline figures"] { display: grid !important; grid-template-columns: repeat(2, minmax(0, 1fr)) !important; gap: 0 16px !important; padding: 0 !important; margin: 0 20px !important; }
  .page-root section[aria-label="Headline figures"] > div { padding: 18px 0 !important; border-bottom: 1px solid #E2DED4; }
  .page-root section[aria-label="Headline figures"] > div:nth-last-child(-n+2) { border-bottom: 0; }
  .page-root section[aria-label="Headline figures"] > div > span:first-child { font-size: 40px !important; }
  .page-root section[aria-label="Headline figures"] > div > span:last-child { font-size: 13px !important; }
  .page-root figure[aria-label="Sources analysed by category"] { padding: 18px 16px !important; }
  .page-root figure[aria-label="Sources analysed by category"] > div { grid-template-columns: minmax(0, 1fr) 30px 68px !important; gap: 8px 10px !important; align-items: baseline !important; font-size: 15px !important; }
  .page-root figure[aria-label="Sources analysed by category"] > div > :nth-child(2) { grid-column: 1 / -1; grid-row: 2; height: 8px !important; }
  .page-root figure[aria-label="Sources analysed by category"] > div:first-child > :nth-child(2) { display: none; }
  .page-root figure[aria-label="Sources analysed by category"] > div:first-child { font-size: 12px !important; }
  .page-root figure[aria-label="Sources analysed by category"] > div > :nth-child(n+3) { font-size: 13px !important; }
  .page-root svg[viewBox="0 180 56 60"] { width: 56px !important; height: 44px !important; margin: 16px auto !important; transform: rotate(90deg); }
  .page-root blockquote { padding: 32px 24px !important; gap: 16px !important; }
  .page-root blockquote p { font-size: 30px !important; line-height: 1.2 !important; }
  .page-root blockquote cite { font-size: 12px !important; letter-spacing: 0.06em !important; line-height: 1.6; }
  .page-root > p:last-child { padding: 8px 20px 40px !important; font-size: 14px !important; }
}

/* Dated and numbered lists keep their label column on phones. */
@media (max-width: 999px) {
  .page-root li[style*="grid-template-columns: 104px"], .page-root li[style*="grid-template-columns: 160px"] { grid-template-columns: 92px minmax(0, 1fr) !important; gap: 12px !important; }
  .page-root li[style*="grid-template-columns: 56px"] { grid-template-columns: 48px minmax(0, 1fr) !important; gap: 10px !important; }
  .page-root li[style*="grid-template-columns: 160px"] > span:last-child { font-size: 16px !important; }
}

/* Case pages on tablets held upright (600 to 999px): wider margins, larger type, and cards in pairs rather than one long column. */
@media (min-width: 600px) and (max-width: 999px) {
  .page-root section { padding-left: 40px !important; padding-right: 40px !important; }
  .page-root section[style*="linear-gradient(#D9D5CA"] { background-size: calc(100% - 80px) 1px !important; }
  .page-root :not(section)[style*="grid-template-columns: repeat("] { grid-template-columns: repeat(2, minmax(0, 1fr)) !important; }
  .page-root :not(section)[style*="grid-template-columns: repeat("] > :last-child:nth-child(odd) { grid-column: 1 / -1; }
  .page-root section[aria-label="Headline figures"] { grid-template-columns: repeat(3, minmax(0, 1fr)) !important; margin: 0 40px !important; gap: 0 24px !important; }
  .page-root section[aria-label="Headline figures"] > div:nth-last-child(-n+3) { border-bottom: 0; }
  .page-root li[style*="grid-template-columns: 150px"] { grid-template-columns: 150px minmax(0, 1fr) !important; gap: 16px !important; }
  .page-root h1 { font-size: 52px !important; line-height: 1.06 !important; }
  .page-root h2 { font-size: 38px !important; line-height: 1.1 !important; }
  .page-root h3 { font-size: 24px !important; }
  .page-root p, .page-root li { font-size: 18px !important; }
  .page-root > p:last-child { padding: 8px 40px 48px !important; }
}

/* SS18 comparison on small screens: headline lines and the figures keep their weight. */
@media (max-width: 999px) {
  .page-root #professionals p[style*="font-size: 27px"] { font-size: 24px !important; line-height: 1.2 !important; }
  .page-root #professionals p[style*="font-size: 26px; line-height: 1.3"] { font-size: 22px !important; line-height: 1.35 !important; }
  .page-root #professionals [style*="gap: 14px 20px"] { grid-template-columns: repeat(2, minmax(0, 1fr)) !important; gap: 14px 20px !important; }
}
