/* Kaiho Pasu. One stylesheet, no frameworks. Colours are taken from the logo. */

@font-face {
  font-family: 'Montserrat';
  src: url('/fonts/montserrat-latin-wght.woff2') format('woff2');
  font-weight: 100 900;
  font-style: normal;
  font-display: swap;
}

:root {
  color-scheme: light;
  --bg: #fffdf8;
  --tint: #f6f2ea;
  --card: #ffffff;
  --ink: #1c1917;
  --muted: #5b554f;
  --line: #e8e2d8;
  --link: #3b51a3;
  --red: #e42f2f;
  --orange: #f7941d;
  --yellow: #f2d40c;
  --green: #6cbd45;
  --cyan: #3fbcc7;
  --blue: #3f57a6;
  --purple: #a24c9c;
  --pink: #e38bbd;
  --radius: 18px;
  --wrap: 1140px;
  --head: 'Montserrat', ui-sans-serif, system-ui, sans-serif;
  --body: ui-sans-serif, system-ui, -apple-system, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; scroll-padding-top: 88px; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font: 400 1.0625rem/1.7 var(--body);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}
img, video { display: block; max-width: 100%; height: auto; }
a { color: var(--link); text-underline-offset: 3px; text-decoration-thickness: 1px; }
a:hover { text-decoration-thickness: 2px; }
:focus-visible { outline: 3px solid var(--blue); outline-offset: 3px; border-radius: 6px; }
h1, h2, h3 { font-family: var(--head); line-height: 1.15; letter-spacing: -0.02em; margin: 0; }
p { margin: 0 0 1em; }
ul { margin: 0; padding: 0; list-style: none; }

.wrap { max-width: var(--wrap); margin: 0 auto; padding: 0 24px; }
.narrow { max-width: 760px; }
.visually-hidden { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.skip { position: absolute; left: 12px; top: -60px; background: var(--ink); color: #fff; padding: 10px 14px; border-radius: 10px; z-index: 20; }
.skip:focus { top: 12px; }
.ext { font-size: .8em; margin-left: .2em; opacity: .7; }

/* The logo's colours as one band */
.stripe {
  height: 6px;
  background: linear-gradient(90deg,
    var(--red) 0 12.5%, var(--orange) 0 25%, var(--yellow) 0 37.5%, var(--green) 0 50%,
    var(--cyan) 0 62.5%, var(--blue) 0 75%, var(--purple) 0 87.5%, var(--pink) 0);
}

/* Header */
.site-header {
  position: sticky; top: 0; z-index: 10;
  background: rgb(255 253 248 / .86);
  backdrop-filter: saturate(1.4) blur(14px);
  -webkit-backdrop-filter: saturate(1.4) blur(14px);
  border-bottom: 1px solid var(--line);
}
.header-row { display: flex; align-items: center; justify-content: space-between; gap: 24px; min-height: 68px; }
.brand img { width: 168px; }
.main-nav { display: flex; gap: 4px; flex-wrap: wrap; }
.main-nav a {
  color: var(--ink); text-decoration: none; font: 600 .95rem/1 var(--head);
  padding: 10px 14px; border-radius: 999px;
}
.main-nav a:hover { background: var(--tint); }
.main-nav a[aria-current="page"] { background: var(--ink); color: #fff; }

/* Home hero */
.hero { padding: clamp(48px, 9vw, 112px) 0 clamp(24px, 3vw, 40px); text-align: center; }
.hero-title { display: flex; flex-direction: column; align-items: center; gap: 28px; }
.hero-logo { width: min(760px, 92%); }
.hero-tag { font-size: clamp(1.7rem, 4.2vw, 3rem); font-weight: 800; }
.hero-lead { max-width: 720px; margin: 22px auto 0; font-size: clamp(1.08rem, 1.6vw, 1.25rem); color: var(--muted); }
.hero-actions { display: flex; gap: 12px; justify-content: center; flex-wrap: wrap; margin-top: 32px; }
.button {
  display: inline-block; text-decoration: none; font: 700 1rem/1 var(--head);
  padding: 15px 24px; border-radius: 999px; background: var(--ink); color: #fff;
  transition: transform .15s ease;
}
.button:hover { transform: translateY(-1px); }
.button-quiet { background: transparent; color: var(--ink); box-shadow: inset 0 0 0 1.5px var(--ink); }

/* Sections */
.section { padding: clamp(48px, 7vw, 88px) 0; }
.tint { background: var(--tint); }
.section-title { font-size: clamp(1.5rem, 2.6vw, 2rem); font-weight: 800; margin-bottom: 28px; }
.section-title::after {
  content: ''; display: block; width: 56px; height: 5px; border-radius: 3px; margin-top: 14px;
  background: linear-gradient(90deg, var(--red) 0 33%, var(--yellow) 0 66%, var(--blue) 0);
}
.section-head { display: flex; align-items: baseline; justify-content: space-between; gap: 16px; flex-wrap: wrap; }
.more { font-weight: 600; text-decoration: none; }
.vision { padding-top: clamp(24px, 4vw, 48px); }
.vision .prose p { font-size: 1.15rem; }

/* Cards */
.cards { display: grid; gap: 22px; }
.cards-projects { grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); }
.cards-teams { grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); }
.card {
  display: flex; flex-direction: column; text-decoration: none; color: var(--ink);
  background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden;
  transition: transform .2s ease, box-shadow .2s ease;
}
.card:hover { transform: translateY(-3px); box-shadow: 0 14px 34px rgb(28 25 23 / .10); }
.card-media { display: block; aspect-ratio: 4 / 3; background: var(--tint); overflow: hidden; }
.card-media img { width: 100%; height: 100%; object-fit: cover; }
.cards-teams .card-media { aspect-ratio: 16 / 10; }
.card-body { display: flex; flex-direction: column; gap: 6px; padding: 18px 20px 22px; }
.card-kicker { font: 700 .72rem/1 var(--head); letter-spacing: .12em; text-transform: uppercase; color: var(--muted); }
.card-title { font: 800 1.3rem/1.2 var(--head); letter-spacing: -0.01em; }
.card-sub { color: var(--muted); font-weight: 600; font-size: .95rem; }
.card-text { color: var(--muted); font-size: .97rem; line-height: 1.6; }

/* Films */
.side { display: grid; gap: 28px; align-content: start; }
.film { margin: 0; }
.film figcaption { display: flex; align-items: center; gap: 10px; margin-top: 12px; font: 600 1rem/1.3 var(--head); }
.film-tag { font: 700 .7rem/1 var(--head); letter-spacing: .12em; text-transform: uppercase; color: #fff; background: var(--red); padding: 5px 8px; border-radius: 6px; }
.film video, .poster video { width: 100%; aspect-ratio: 16 / 9; background: #111; border-radius: 14px; object-fit: cover; }

/* Faces */
.faces { display: flex; flex-wrap: wrap; gap: 12px; }
.faces img { width: 72px; height: 72px; border-radius: 50%; object-fit: cover; object-position: 50% 25%; border: 3px solid var(--card); box-shadow: 0 2px 8px rgb(28 25 23 / .12); transition: transform .15s ease; }
.faces a:hover img { transform: scale(1.06); }

/* Inner pages */
.page-head { padding: clamp(40px, 6vw, 72px) 0 8px; }
.page-head h1 { font-size: clamp(2.2rem, 5vw, 3.4rem); font-weight: 800; }
.page-sub { margin-top: 10px; font: 600 1.2rem/1.4 var(--head); color: var(--muted); }
.crumb { margin-bottom: 12px; font: 700 .78rem/1 var(--head); letter-spacing: .12em; text-transform: uppercase; }
.crumb a { text-decoration: none; color: var(--muted); }
.split { padding-top: 32px; }
.split-grid { display: grid; gap: 40px; grid-template-columns: minmax(0, 1.1fr) minmax(0, 1fr); align-items: start; }
.prose p, .vision-list li { font-size: 1.1rem; }
.vision-list { display: grid; gap: 12px; }
.vision-list li { padding-left: 22px; position: relative; }
.vision-list li::before { content: ''; position: absolute; left: 0; top: .7em; width: 9px; height: 9px; border-radius: 50%; background: var(--orange); }
.poster { margin: 0; }
.poster img { width: 100%; border-radius: var(--radius); border: 1px solid var(--line); background: #fff; }
.poster figcaption { margin-top: 10px; font-size: .9rem; color: var(--muted); text-align: center; }
.framework { margin: 0; }
.framework img { width: min(960px, 100%); margin: 0 auto; border-radius: var(--radius); border: 1px solid var(--line); background: #fff; }

/* People */
.people { display: grid; gap: 18px; grid-template-columns: repeat(auto-fill, minmax(170px, 1fr)); }
.person {
  display: flex; flex-direction: column; align-items: center; text-align: center; gap: 8px;
  background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 22px 14px 18px;
}
.person img { width: 112px; height: 112px; border-radius: 50%; object-fit: cover; object-position: 50% 25%; }
.person-name { font: 700 1.02rem/1.3 var(--head); }
.person-links { display: flex; gap: 12px; font-size: .9rem; }
.person-links a { text-decoration: none; font-weight: 600; }

/* Stories */
.stories { columns: 2 380px; column-gap: 22px; }
.story {
  break-inside: avoid; margin: 0 0 22px; background: var(--card); border: 1px solid var(--line);
  border-radius: var(--radius); padding: 24px 26px 10px;
}
.story header { display: flex; align-items: center; gap: 14px; margin-bottom: 14px; }
.story img { width: 64px; height: 64px; border-radius: 50%; object-fit: cover; object-position: 50% 25%; }
.story h2 { font-size: 1.2rem; font-weight: 800; }
.story p { color: #3a3531; }
.story:target { box-shadow: 0 0 0 3px var(--yellow); }

/* Footer */
.site-footer { margin-top: 0; background: #1c1917; color: #e9e4dc; }
.site-footer a { color: #fff; }
.footer-grid { display: grid; gap: 32px; grid-template-columns: 1.4fr repeat(3, 1fr); padding-top: 52px; padding-bottom: 28px; }
.footer-brand img { width: 220px; background: #fff; padding: 10px 14px; border-radius: 12px; }
.motto { margin: 16px 0 6px; font: 700 1.1rem/1.3 var(--head); }
.site-footer h2 { font-size: .78rem; letter-spacing: .12em; text-transform: uppercase; color: #b9b1a6; margin-bottom: 14px; }
.site-footer li { margin-bottom: 8px; }
.site-footer li a { text-decoration: none; }
.site-footer li a:hover { text-decoration: underline; }
.fine { padding-bottom: 28px; font-size: .85rem; color: #b9b1a6; }

/* Small screens */
@media (max-width: 860px) {
  .split-grid { grid-template-columns: 1fr; }
  .footer-grid { grid-template-columns: 1fr 1fr; }
  .footer-brand { grid-column: 1 / -1; }
}
@media (max-width: 640px) {
  .header-row { flex-direction: column; align-items: flex-start; gap: 6px; padding-top: 10px; padding-bottom: 8px; }
  .brand img { width: 140px; }
  .main-nav { margin-left: -10px; flex-wrap: nowrap; gap: 0; overflow-x: auto; scrollbar-width: none; max-width: calc(100% + 20px); }
  .main-nav a { padding: 8px 10px; font-size: .88rem; white-space: nowrap; }
  .cards-teams { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
  .cards-teams .card-media { aspect-ratio: 1 / 1; }
  .cards-teams .card-body { padding: 12px 14px 16px; }
  .cards-teams .card-title { font-size: 1rem; }
  html { scroll-padding-top: 120px; }
  .stories { columns: 1; }
  .people { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .card, .button, .faces img { transition: none; }
}
