/* Home (/ and /pt/): choose Digitalization or Public Funding. Built by scripts/build_home.py. */
@font-face { font-family: "Host Grotesk"; font-weight: 400; font-display: swap; src: url(/assets/fonts/font-6be6f339.woff2) format("woff2"); }
@font-face { font-family: "Host Grotesk"; font-weight: 500; font-display: swap; src: url(/assets/fonts/font-c67a7cfb.woff2) format("woff2"); }
@font-face { font-family: "Instrument Serif"; font-style: italic; font-display: swap; src: url(/assets/fonts/font-a003af28.woff2) format("woff2"); }
:root { color-scheme: dark; --bg: #000; --muted: #bdbdbd; --line: rgba(250, 250, 250, .14); --orange: #ee620d; --yellow: #ffe94d; --ease: cubic-bezier(.2, .7, .2, 1); }
* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; background: var(--bg); color: #fff; font: 17px/1.5 "Host Grotesk", system-ui, -apple-system, "Segoe UI", sans-serif; }
a { color: #fff; text-underline-offset: 3px; }

/* Header floats over the two halves. */
.hm-top {
  position: absolute; z-index: 3; top: 0; left: 0; right: 0;
  display: flex; align-items: center; justify-content: space-between; gap: 16px;
  padding: 24px clamp(16px, 4vw, 56px);
  background: linear-gradient(180deg, rgba(0, 0, 0, .55), rgba(0, 0, 0, 0));
}
.hm-logo { display: inline-flex; min-height: 44px; align-items: center; }
.hm-logo img { width: 104px; height: auto; display: block; }
.hm-title { position: absolute; left: 50%; transform: translateX(-50%); margin: 0; font-weight: 400; font-size: 18px; letter-spacing: -.01em; white-space: nowrap; }
.hm-contact { display: inline-flex; align-items: center; min-height: 44px; padding: 0 18px; border: 1px solid rgba(255, 255, 255, .6); border-radius: 999px; text-decoration: none; font-size: 15px; }
.hm-contact:hover { background: #fff; color: #000; }

/* The split. */
.hm-split { display: grid; grid-template-columns: 1fr 1fr; height: 100vh; height: 100svh; min-height: 560px; }
.hm-half { position: relative; overflow: hidden; display: flex; align-items: flex-end; text-decoration: none; isolation: isolate; outline: none; }
.hm-half + .hm-half { border-left: 1px solid var(--line); }
.hm-img {
  position: absolute; inset: 0; z-index: -2; width: 100%; height: 100%; object-fit: cover;
  transform: scale(1.001); transition: transform 1.1s var(--ease), filter .6s var(--ease);
}
.hm-dig .hm-img { object-position: 42% 50%; }
.hm-pf .hm-img { object-position: 62% 50%; }
.hm-half::after { /* legibility: dark from the bottom, where the text is */
  content: ""; position: absolute; inset: 0; z-index: -1;
  background: linear-gradient(180deg, rgba(0, 0, 0, 0) 35%, rgba(0, 0, 0, .78) 100%);
}
.hm-body { display: grid; gap: 10px; justify-items: start; width: 100%; padding: 0 clamp(20px, 4vw, 56px) clamp(104px, 14vh, 140px); }
.hm-num { font: italic 20px/1 "Instrument Serif", Georgia, serif; letter-spacing: .1em; }
.hm-dig .hm-num { color: #ffb27d; }
.hm-pf .hm-num { color: var(--yellow); }
.hm-name { margin: 0; font-weight: 400; font-size: clamp(44px, 6.4vw, 112px); line-height: .98; letter-spacing: -.05em; }
/* The two names show the inverse of what is behind each letter (orange turns blue, blue turns yellow, the
   silhouette turns light), like the section heroes. Each half is isolated, so only its own image counts. */
.hm-name { color: #fff; mix-blend-mode: difference; }
/* Mid orange inverts to a blue of the same brightness, which is hard to read: shade the Digitalization half
   more where the text sits, so the inverted letters come out light blue (3:1 or better). */
.hm-dig::after { background: linear-gradient(180deg, rgba(0, 0, 0, 0) 15%, rgba(0, 0, 0, .55) 48%, rgba(0, 0, 0, .82) 100%); }
@media (forced-colors: active) { .hm-name { mix-blend-mode: normal; } }
.hm-sub { font: italic clamp(22px, 2.2vw, 32px)/1.1 "Instrument Serif", Georgia, serif; }
.hm-desc { max-width: 34ch; color: rgba(255, 255, 255, .9); }
.hm-go {
  display: inline-flex; align-items: center; gap: 10px; margin-top: 10px; min-height: 48px; padding: 0 22px;
  border: 1px solid #fff; border-radius: 999px; transition: background-color .3s, color .3s;
}

/* Hover (mouse) and keyboard focus: the chosen image grows, the other one dims. */
@media (hover: hover) and (pointer: fine) {
  .hm-half:hover .hm-img { transform: scale(1.08); }
  .hm-split:hover .hm-half:not(:hover) .hm-img { filter: brightness(.45) saturate(.7); }
  .hm-half:hover .hm-go { background: #fff; color: #000; }
}
.hm-half:focus-visible .hm-img { transform: scale(1.08); }
.hm-split:focus-within .hm-half:not(:focus-visible) .hm-img { filter: brightness(.45) saturate(.7); }
.hm-half:focus-visible .hm-go { background: #fff; color: #000; }
.hm-half:focus-visible::before { content: ""; position: absolute; inset: 6px; z-index: 2; border: 3px solid #fff; border-radius: 8px; pointer-events: none; }
@media (prefers-reduced-motion: reduce) {
  .hm-img { transition: filter .2s; }
  .hm-half:hover .hm-img, .hm-half:focus-visible .hm-img { transform: scale(1.001); }
}

.hm-foot { padding: 32px clamp(16px, 4vw, 56px) 96px; border-top: 1px solid var(--line); font-size: 14px; color: var(--muted); }
.hm-foot ul { list-style: none; margin: 0 0 12px; padding: 0; display: flex; flex-wrap: wrap; gap: 4px 20px; }
.hm-foot a { display: inline-flex; align-items: center; min-height: 44px; color: var(--muted); }
.hm-foot a:hover { color: #fff; }
.hm-foot p { margin: 0; }

/* Phones and small tablets: the halves stack. Each is at least half the screen and grows with its text,
   so nothing is cut on short or narrow phones; the page scrolls instead. */
@media (max-width: 809.98px) {
  .hm-split { grid-template-columns: 1fr; grid-template-rows: auto auto; height: auto; min-height: 100vh; min-height: 100svh; }
  .hm-half { min-height: 50vh; min-height: 50svh; }
  .hm-half + .hm-half { border-left: 0; border-top: 1px solid var(--line); }
  .hm-top { flex-wrap: wrap; row-gap: 6px; padding-top: 16px; padding-bottom: 16px; }
  .hm-title { position: static; transform: none; order: 3; flex-basis: 100%; font-size: 15px; white-space: normal; text-align: center; }
  .hm-logo img { width: 84px; }
  .hm-contact { padding: 0 14px; font-size: 14px; }
  .hm-body { padding: 24px 20px 28px; gap: 6px; }
  .hm-dig .hm-body { padding-top: 128px; } /* below the header */
  .hm-pf .hm-body { padding-bottom: 92px; } /* clear of the language and cookie buttons */
  .hm-name { font-size: clamp(34px, 12.4vw, 60px); }
  .hm-sub { font-size: 22px; }
  .hm-desc { font-size: 15px; }
  .hm-go { margin-top: 6px; }
}
/* Landscape phones and other short screens with room for two columns: let the halves grow with their text
   (the page scrolls), keep the text clear of the language and cookie buttons at the bottom. */
@media (min-width: 810px) and (max-height: 560px) {
  .hm-split { height: auto; min-height: 100vh; min-height: 100svh; }
  .hm-top { padding-top: 14px; padding-bottom: 14px; }
  .hm-body { padding-top: 96px; padding-bottom: 84px; gap: 6px; }
  .hm-name { font-size: clamp(36px, 5.2vw, 64px); }
  .hm-sub { font-size: 22px; }
  .hm-desc { font-size: 14px; }
  .hm-go { margin-top: 4px; }
}
@media (min-width: 810px) and (max-height: 440px) {
  .hm-desc { display: none; } /* landscape phones: the section pages say the same; keeps the buttons above the dock */
}
