/* annekevries.nl -- one page. Layout only: colours and fonts live in theme.css.

   Layout idea: the photo (.hero) is fixed in place. The .sheet (flat background,
   straight top edge) starts below the visible part of the photo and slides over it
   when you scroll. */

:root {

  /* how much of the first screen stays free BELOW the photo (the name is on the photo now).
     Smaller number = taller photo. */
  --below: 120px;
  --hero-h: max(46vh, calc(100vh - var(--below)));
}
@supports (height: 1svh) {
  :root { --hero-h: max(46svh, calc(100svh - var(--below))); }
}

*, *::before, *::after { box-sizing: border-box; }

html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }

body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: var(--font-body);
  font-size: 1.0625rem;
  line-height: 1.65;
}

img { display: block; max-width: 100%; }

a { color: var(--accent); }
a:focus-visible { outline: 3px solid var(--accent); outline-offset: 3px; border-radius: 6px; }

.wrap {
  width: 100%;
  max-width: 1120px;
  margin-left: auto;
  margin-right: auto;
  padding-left: clamp(20px, 4vw, 48px);
  padding-right: clamp(20px, 4vw, 48px);
}

/* ---------- fixed photo ---------- */

.hero {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: var(--hero-h);
  overflow: hidden;
  background: #1e4b57;    /* shown for a moment before the image arrives */
  z-index: 0;
}

.hero__img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: 50% 55%;
}

/* soft dark fades: at the bottom behind the name, at the top behind the caption and language link */
.hero::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  height: 14rem;
  background: linear-gradient(to top, rgba(0, 0, 0, .6), rgba(0, 0, 0, 0));
  pointer-events: none;
}
.hero::before {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  top: 0;
  height: 6rem;
  background: linear-gradient(to bottom, rgba(0, 0, 0, .55), rgba(0, 0, 0, 0));
  pointer-events: none;
  z-index: 1;
}

/* name + tagline on the photo, bottom left */
.hero__name {
  position: absolute;
  z-index: 2;
  left: clamp(20px, 4vw, 48px);
  right: clamp(20px, 4vw, 48px);
  bottom: clamp(1.5rem, 4vw, 2.75rem);
  color: #fff;
}
.hero__name h1 { text-shadow: 0 2px 18px rgba(0, 0, 0, .45); }
.hero__name .tagline { color: #fff; text-shadow: 0 1px 6px rgba(0, 0, 0, .6); }

/* photo caption: description + credit, plain text at the top left of the photo */
.hero__caption {
  z-index: 2;
  position: absolute;
  left: clamp(20px, 4vw, 48px);
  top: 12px;
  max-width: min(46rem, calc(100% - 110px));
  margin: 0;
  font-size: .75rem;
  line-height: 1.4;
  color: #fff;
  text-shadow: 0 1px 3px rgba(0, 0, 0, .75);
}

/* language switch: plain text, no box */
.lang {
  position: absolute;
  z-index: 2;
  top: 10px;
  right: clamp(12px, 3vw, 40px);
}
.lang a {
  display: block;
  padding: .5rem .6rem;
  font-size: .95rem;
  font-weight: 700;
  letter-spacing: .06em;
  text-decoration: none;
  color: #fff;
  text-shadow: 0 1px 3px rgba(0, 0, 0, .8);
}
.lang a:hover { text-decoration: underline; }

/* ---------- the sheet that slides over the photo ---------- */

.sheet {
  position: relative;
  z-index: 1;
  margin-top: var(--hero-h);
  min-height: 100vh;
  min-height: 100svh;
  background: var(--bg);
}

h1 {
  margin: 0;
  font-family: var(--font-name);
  font-weight: 600;
  font-size: clamp(2.1rem, 6vw, 4.4rem);
  line-height: 1.02;
  letter-spacing: -.01em;
}

.tagline {
  margin: .5rem 0 0;
  font-size: clamp(1.1rem, 2.4vw, 1.5rem);
  color: var(--accent);
  font-weight: 500;
}

/* rectangular photo, floated right: the intro text runs around it */
.portrait {
  float: right;
  width: clamp(100px, 22vw, 180px);
  height: auto;
  aspect-ratio: 4 / 5;
  object-fit: cover;
  border-radius: 2px;
  margin: .3rem 0 1rem clamp(1rem, 3vw, 2rem);
}

/* ---------- text: directly on the flat sheet, no box; one column ---------- */

.content {
  padding-top: clamp(1.5rem, 5vw, 3rem);
  scroll-margin-top: 1rem;
}

.about { max-width: 46rem; }
.projects { clear: both; }

.about p { margin: 0 0 1.1rem; }
.about .intro { font-size: 1.15rem; }
.about__intro { margin-bottom: 1.5rem; }

.projects {
  margin: 0;
  padding-left: 1.4rem;
  list-style: disc;
}
.projects li { margin: 0 0 1.5rem; padding-left: .3rem; }
.projects li::marker { color: var(--ochre); }
.projects strong { display: block; font-weight: 700; margin-bottom: .25rem; }
.projects span { display: block; }
.projects .paper { margin-top: .4rem; font-size: .95rem; }
.projects .paper a { color: var(--ochre); }

/* ---------- link buttons: logo + label, no box ---------- */

.links {
  display: flex;
  justify-content: space-around;
  gap: 12px;
  margin-top: 2.25rem;
}

.btn {
  flex: 1 1 0;
  min-width: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: .5rem;
  padding: .4rem;
  color: var(--ink);
  font-weight: 600;
  font-size: .95rem;
  text-decoration: none;
  transition: transform .15s ease;
}
.btn svg { width: 44px; height: 44px; }
.btn:hover { transform: translateY(-2px); }
.btn:hover span { text-decoration: underline; }

.footer {
  padding-top: 3rem;
  padding-bottom: 2rem;
  text-align: center;
  font-size: .8rem;
  color: var(--muted);
}
.footer p { margin: 0; }

/* ---------- wide screens: everything aligns left with the name ---------- */

@media (min-width: 900px) {
  .links { justify-content: flex-start; gap: 2.5rem; }
  .btn { flex: none; min-width: 5.5rem; }

  .footer { text-align: left; }
}

/* ---------- phone ---------- */

@media (max-width: 640px) {
  .lang { top: 6px; right: 8px; }

}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .btn { transition: none; }
}
