/* The home page, after Luise's Claude Design mockup (Website – Home). Values are hers. */

/* Self-hosted WOFF2, split by unicode-range: browsers fetch the latin-ext files only if a page
   uses a character from them. Files from fontsource (Google Fonts builds), same fonts as before. */
@font-face {
  font-family: "Hanken Grotesk";
  src: url("/fonts/hanken-grotesk-latin-wght-normal.woff2") format("woff2");
  font-weight: 100 900;
  font-style: normal;
  font-display: swap;
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: "Hanken Grotesk";
  src: url("/fonts/hanken-grotesk-latin-ext-wght-normal.woff2") format("woff2");
  font-weight: 100 900;
  font-style: normal;
  font-display: swap;
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
@font-face {
  font-family: "Instrument Serif";
  src: url("/fonts/instrument-serif-latin-400-normal.woff2") format("woff2");
  font-weight: 400;
  font-style: normal;
  font-display: swap;
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: "Instrument Serif";
  src: url("/fonts/instrument-serif-latin-ext-400-normal.woff2") format("woff2");
  font-weight: 400;
  font-style: normal;
  font-display: swap;
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}

:root {
  --bg: #F3F4F1;
  --ink: #15182A;
  --ink-2: #2B2F40;
  --muted: #4A4F60;
  --rule: #D9DCE3;
  --rule-2: #CDD1DA;
  --blue: #24308C;
  --serif: "Instrument Serif", Georgia, serif;
  --sans: "Hanken Grotesk", "Helvetica Neue", Helvetica, sans-serif;
  --pad-x: clamp(20px, 4vw, 48px);
  --pad-y: clamp(56px, 8vw, 112px);
}

html { scroll-behavior: smooth; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: var(--sans);
  font-size: 17px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}
a { color: var(--blue); text-decoration-thickness: 1px; text-underline-offset: 3px; }
a:hover { color: var(--ink); }
p { margin: 0; text-wrap: pretty; }
h1, h2, h3 { margin: 0; text-wrap: balance; }
figure { margin: 0; display: flex; flex-direction: column; gap: 12px; }
/* Paintings are shown whole: the box takes each image's own proportions from its width and height. */
figure img { width: 100%; height: auto; display: block; }
figcaption { font-size: 13px; line-height: 1.5; color: var(--muted); }

.wrap { max-width: 1280px; margin: 0 auto; padding: var(--pad-y) var(--pad-x); box-sizing: border-box; }
.ruled { border-top: 1px solid var(--rule); }
.serif { font-family: var(--serif); font-weight: 400; }
.label { font-size: 13px; font-weight: 500; letter-spacing: 0.14em; text-transform: uppercase; color: var(--muted); }
.h2 { font-family: var(--serif); font-weight: 400; font-size: clamp(44px, 5.5vw, 76px); line-height: 1; }

/* Header */
.site-header { border-bottom: 1px solid var(--rule); }
.site-header .wrap {
  padding: 22px var(--pad-x);
  display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 16px 40px;
}
.logo { font-family: var(--serif); font-size: 26px; line-height: 1; color: var(--ink); text-decoration: none; }
.main-nav {
  display: flex; flex-wrap: wrap; gap: 4px 28px;
  font-size: 13px; font-weight: 500; letter-spacing: 0.12em; text-transform: uppercase;
  /* The nav is a popover (the phone menu); on wider screens it stays an ordinary inline nav. */
  position: static; inset: auto; width: auto; height: auto; margin: 0; border: 0; padding: 0;
  overflow: visible; color: inherit; background: none;
}
.main-nav a { color: var(--ink); text-decoration: none; padding: 12px 0; }
.main-nav a:hover { color: var(--blue); }
.menu-button, .menu-top { display: none; }

/* Hero */
.hero {
  max-width: 1280px; margin: 0 auto; box-sizing: border-box;
  padding: clamp(48px, 8vw, 112px) var(--pad-x) clamp(56px, 8vw, 104px);
  display: grid; grid-template-columns: repeat(auto-fit, minmax(min(440px, 100%), 1fr));
  gap: clamp(40px, 6vw, 88px); align-items: end;
}
.hero-text { display: flex; flex-direction: column; gap: 32px; }
.hero h1 { font-family: var(--serif); font-weight: 400; font-size: clamp(60px, 9vw, 136px); line-height: 0.92; letter-spacing: -0.015em; }
.lede { max-width: 34ch; font-size: clamp(18px, 1.6vw, 21px); line-height: 1.55; color: var(--ink-2); }
.hero figure { gap: 14px; }
.hero img { background: #C9D3EA; }

/* Intro */
.intro .wrap {
  display: grid; grid-template-columns: repeat(auto-fit, minmax(min(300px, 100%), 1fr)); gap: 32px 88px;
}
.intro-quote { font-family: var(--serif); font-size: clamp(28px, 3vw, 40px); line-height: 1.18; }
.span-2 { display: flex; flex-direction: column; gap: 20px; grid-column: span 2; min-width: 0; }

/* Works */
.works .wrap { display: flex; flex-direction: column; gap: clamp(56px, 7vw, 96px); }
.section-head { display: flex; flex-wrap: wrap; align-items: baseline; justify-content: space-between; gap: 12px 40px; }
.work {
  display: grid; grid-template-columns: repeat(auto-fit, minmax(min(380px, 100%), 1fr));
  gap: 32px 72px; align-items: center; padding-top: 40px; border-top: 1px solid var(--rule);
}
.work-text { display: flex; flex-direction: column; gap: 16px; }
.period { font-size: 13px; font-weight: 500; letter-spacing: 0.14em; color: var(--blue); }
.work h3 { font-family: var(--serif); font-weight: 400; font-size: clamp(32px, 3.2vw, 44px); line-height: 1.05; }
.work-text p:last-child { max-width: 52ch; }
.work img { background: #E7E9EE; }

/* Walchensee */
.walchensee { background: #1C2672; color: #EEF0F7; }
.walchensee .wrap { padding: clamp(64px, 9vw, 128px) var(--pad-x); display: flex; flex-direction: column; gap: clamp(40px, 6vw, 72px); }
.walchensee-head { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(380px, 100%), 1fr)); gap: 32px 88px; align-items: end; }
.walchensee-head > div { display: flex; flex-direction: column; gap: 20px; }
.walchensee .label { color: #B9C1E6; }
.walchensee h2 { font-family: var(--serif); font-weight: 400; font-size: clamp(56px, 8vw, 120px); line-height: 0.95; }
.walchensee .lede { max-width: 46ch; color: #DDE1F2; }
.walchensee-pair { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(420px, 100%), 1fr)); gap: 24px; }
.walchensee-pair img { background: #3A4795; }
.walchensee figcaption { color: #B9C1E6; }
.walchensee-text {
  display: grid; grid-template-columns: repeat(auto-fit, minmax(min(340px, 100%), 1fr));
  gap: 24px 72px; padding-top: 40px; border-top: 1px solid #3B4693;
}
.walchensee-text p { color: #DDE1F2; }

/* Vita */
.vita .wrap { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(300px, 100%), 1fr)); gap: 40px 88px; }
.vita .span-2 { gap: 0; }
.vita-row { display: grid; grid-template-columns: 112px minmax(0, 1fr); gap: 24px; padding: 18px 0; border-top: 1px solid var(--rule); }
.vita-row:last-child { border-bottom: 1px solid var(--rule); }
.vita-row > :first-child { font-weight: 600; color: var(--blue); }

/* Exhibitions */
.exhibitions { background: #E9EBEF; }
.exhibitions .wrap { display: flex; flex-direction: column; gap: clamp(40px, 5vw, 64px); }
.exh-cols { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(420px, 100%), 1fr)); gap: 56px 88px; }
.exh-cols > div { display: flex; flex-direction: column; }
.list-head { margin: 0 0 16px; font-size: 13px; font-weight: 600; letter-spacing: 0.14em; text-transform: uppercase; color: var(--blue); }
.list-head.later { margin-top: 56px; }
.exh-list { display: flex; flex-direction: column; }
.exh-row { display: grid; grid-template-columns: 96px minmax(0, 1fr); gap: 20px; padding: 14px 0; border-top: 1px solid var(--rule-2); }
.exh-row:last-child { border-bottom: 1px solid var(--rule-2); }
.exh-row > :first-child { color: var(--muted); }
.collections { margin: 0; padding: 0; list-style: none; display: flex; flex-direction: column; }
.collections li { padding: 12px 0; border-top: 1px solid var(--rule-2); }
.collections li:last-child { border-bottom: 1px solid var(--rule-2); }

/* Estate */
.estate .wrap { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(340px, 100%), 1fr)); gap: 48px 88px; }
.estate .wrap > div { display: flex; flex-direction: column; gap: 20px; }
.estate p.text { max-width: 46ch; }
.estate .label { font-weight: 600; color: var(--blue); }
.gallery-name { font-family: var(--serif); font-size: clamp(30px, 3vw, 40px); line-height: 1.1; }
.text-link { align-self: flex-start; display: inline-flex; align-items: center; min-height: 48px; font-size: 15px; font-weight: 500; }

/* Footer */
.site-footer { border-top: 1px solid var(--rule); }
.site-footer .wrap {
  padding: 28px var(--pad-x);
  display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center; gap: 12px 32px;
  font-size: 13px; color: var(--muted);
}
/* The legal links (Imprint, Privacy) side by side; a larger tap area, without moving them. */
.footer-links { display: flex; gap: 24px; }
.site-footer a { padding: 12px 0; margin: -12px 0; }

/* Imprint and Privacy: the page title, then one narrow column of short sections, each under a rule. */
.legal .wrap { display: flex; flex-direction: column; gap: clamp(40px, 5vw, 64px); }
.legal-text { max-width: 36rem; display: flex; flex-direction: column; gap: 40px; }
.legal-text section { display: flex; flex-direction: column; gap: 12px; padding-top: 24px; border-top: 1px solid var(--rule); }
.legal-text h2 { font-family: var(--serif); font-weight: 400; font-size: clamp(26px, 2.4vw, 30px); line-height: 1.15; }

/* On narrow screens the two-column spans would force a third implicit column. */
@media (max-width: 760px) {
  .span-2 { grid-column: auto; }
}

/* Phones: the name small, a menu symbol (two lines) that opens the nav as a full-screen panel.
   The one-line desktop header needs about 643px + 8vw, so it fits from about 700px wide; the
   switch at 760px (as above) leaves room for font fallbacks.
   Browsers without popovers keep the desktop header, wrapped. */
@supports selector(:popover-open) {
  @media (max-width: 760px) {
    .site-header .wrap { padding: 7px var(--pad-x); flex-wrap: nowrap; }
    .logo { font-size: 19px; }
    .menu-button, .menu-close {
      display: block; position: relative; flex: none; width: 44px; height: 44px; margin: 0 -10px 0 0;
      padding: 0; border: 0; background: none; color: var(--ink); cursor: pointer;
    }
    .menu-button::before {
      content: ""; position: absolute; left: 10px; right: 10px; top: 17.5px; height: 9px;
      border-top: 1.5px solid; border-bottom: 1.5px solid; box-sizing: border-box;
    }
    .menu-close::before, .menu-close::after {
      content: ""; position: absolute; left: 10px; right: 10px; top: 21.25px; height: 1.5px;
      background: currentColor; transform: rotate(45deg);
    }
    .menu-close::after { transform: rotate(-45deg); }

    .main-nav:not(:popover-open) { display: none; }
    .main-nav:popover-open {
      position: fixed; inset: 0; max-width: none; max-height: none;
      flex-direction: column; flex-wrap: nowrap; gap: 0;
      padding: 0 var(--pad-x) 40px; box-sizing: border-box; overflow-y: auto; overscroll-behavior: contain;
      background: var(--bg); color: var(--ink);
    }
    .main-nav .menu-top {
      display: flex; align-items: center; justify-content: space-between; flex: none;
      padding: 7px 0; border-bottom: 1px solid var(--rule);
    }
    .menu-name { font-family: var(--serif); font-size: 19px; line-height: 1; letter-spacing: 0; text-transform: none; }
    .main-nav a {
      flex: none; padding: 20px 0; border-bottom: 1px solid var(--rule);
      font-family: var(--serif); font-size: 44px; font-weight: 400; line-height: 1;
      letter-spacing: 0; text-transform: none;
    }
    /* The page behind the open menu does not scroll. */
    html:has(.main-nav:popover-open) { overflow: hidden; }

    .hero { padding-top: 40px; }
  }
}
