/* Palette: Lake Michigan on a clear day */
:root {
  --ink: #0f2a33;      /* deep water, text */
  --lake: #1f6f78;     /* lake teal */
  --shallow: #7fb3b5;  /* near-shore water */
  --fog: #eef3f4;      /* sky / page */
  --paper: #ffffff;
  --signal: #e8b923;   /* focus + link underline */
  --slate: #50636a;    /* secondary text */

  --display: "Familjen Grotesk", "Helvetica Neue", Arial, sans-serif;
  --body: "Source Serif 4", Georgia, "Times New Roman", serif;

  --gutter: clamp(1.25rem, 5vw, 4rem);
  --measure: 34rem;
}

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

html { scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }

html { background: var(--paper); }

body {
  margin: 0;
  background: transparent;
  color: var(--ink);
  font-family: var(--body);
  font-size: 1.125rem;
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
}

a { color: inherit; text-decoration-color: var(--signal); text-decoration-thickness: 2px; text-underline-offset: 0.2em; }
a:hover { color: var(--lake); }
:focus-visible { outline: 3px solid var(--signal); outline-offset: 3px; border-radius: 2px; }

.skip {
  position: absolute; left: var(--gutter); top: -3rem;
  background: var(--ink); color: var(--paper); padding: 0.5rem 1rem; z-index: 10;
}
.skip:focus { top: 1rem; }

/* Fixed lakefront photo behind everything, 75% transparent */
body::before {
  content: "";
  position: fixed;
  inset: 0;
  z-index: -1;
  background: url("img/chicago-lakefront.jpg") center / cover no-repeat;
  opacity: 0.25;
  pointer-events: none;
}

/* Hero */
.hero {
  background: transparent;
  padding: 1.5rem var(--gutter) 0;
  overflow: hidden;
}

.nav {
  display: flex; gap: 1.75rem; justify-content: flex-end;
  font-family: var(--display); font-weight: 500; font-size: 1rem;
}
.nav a { text-decoration: none; padding: 0.25rem 0; }
.nav a:hover { text-decoration: underline; text-decoration-color: var(--signal); }

.identity {
  display: flex;
  align-items: center;
  gap: clamp(1rem, 3vw, 2.5rem);
  margin-top: clamp(3rem, 9vw, 6rem);
}

.portrait {
  flex: none;
  width: clamp(6.5rem, 17vw, 15rem);
  height: auto;
  aspect-ratio: 1;
  border-radius: 50%;
  border: 5px solid var(--paper);
  box-shadow: 0 0 0 2px var(--lake);
  object-fit: cover;
}

.name {
  font-family: var(--display);
  font-weight: 700;
  font-size: clamp(3.4rem, 14vw, 12.5rem);
  line-height: 0.86;
  letter-spacing: -0.045em;
  margin: 0;
}
.name span { display: block; }

.intro {
  max-width: 28rem;
  margin: 2rem 0 clamp(3rem, 8vw, 5rem);
  font-size: clamp(1.2rem, 2.2vw, 1.45rem);
  line-height: 1.45;
  color: var(--ink);
}

/* The lake: stripes that thicken toward the shore */
.horizon {
  height: clamp(5rem, 12vw, 9rem);
  margin: 0 calc(var(--gutter) * -1);
  background:
    linear-gradient(to bottom,
      var(--shallow) 0 2%,  transparent 2% 9%,
      var(--shallow) 9% 13%, transparent 13% 21%,
      var(--lake) 21% 28%,   transparent 28% 36%,
      var(--lake) 36% 47%,   transparent 47% 54%,
      var(--ink) 54% 100%);
}

/* Content */
main { padding: 0 var(--gutter); }

.block {
  display: grid;
  grid-template-columns: minmax(8rem, 1fr) minmax(0, 3fr);
  gap: 1rem 3rem;
  padding: clamp(3rem, 7vw, 5.5rem) 0;
  border-top: 1px solid #d5dfe1;
}
.block:first-child { border-top: 0; }

h2 {
  font-family: var(--display);
  font-weight: 700;
  font-size: 1.5rem;
  line-height: 1.2;
  margin: 0.2rem 0 0;
  color: var(--lake);
}

.prose { max-width: var(--measure); }
.prose p { margin: 0 0 1em; }
.prose p:last-child { margin-bottom: 0; }

.projects { list-style: none; margin: 0; padding: 0; max-width: 44rem; }
.projects li { padding: 0 0 1.75rem; }
.projects li + li { padding-top: 1.75rem; border-top: 1px solid #d5dfe1; }
.projects li:last-child { padding-bottom: 0; }
h3 {
  font-family: var(--display);
  font-weight: 700;
  font-size: 1.75rem;
  line-height: 1.15;
  letter-spacing: -0.02em;
  margin: 0 0 0.4rem;
}
.projects p { margin: 0; max-width: var(--measure); color: var(--slate); }

.email {
  font-family: var(--display);
  font-weight: 700;
  font-size: clamp(1.4rem, 3.5vw, 2.25rem);
  letter-spacing: -0.02em;
  word-break: break-word;
}

.footer {
  background: var(--ink);
  color: var(--fog);
  padding: 2rem var(--gutter);
  font-size: 0.95rem;
}
.footer p { margin: 0; }

/* Projects carousel */
.carousel { min-width: 0; }

.track {
  list-style: none;
  margin: 0;
  padding: 0.25rem 0.25rem 0.75rem;
  display: flex;
  gap: 1.5rem;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  scrollbar-width: none;
}
.track::-webkit-scrollbar { display: none; }

.slide {
  flex: 0 0 min(17.5rem, 78%);
  scroll-snap-align: start;
}

.card {
  display: flex;
  flex-direction: column;
  height: 100%;
  text-decoration: none;
  background: rgba(255, 255, 255, 0.88);
  border: 1px solid #c9d7da;
  border-radius: 10px;
  overflow: hidden;
}
.card img { display: block; width: 100%; height: auto; border-bottom: 1px solid #c9d7da; }
.card h3 { margin: 1rem 1.25rem 0.35rem; font-size: 1.5rem; }
.card p { margin: 0 1.25rem 1.25rem; color: var(--slate); font-size: 1rem; line-height: 1.5; }
.card:hover { color: var(--ink); border-color: var(--lake); }
.card:hover h3 { text-decoration: underline; text-decoration-color: var(--signal); text-decoration-thickness: 3px; text-underline-offset: 0.15em; }

.controls { display: flex; gap: 0.75rem; margin-top: 1.25rem; }
.controls button {
  font: 500 1rem/1 var(--display);
  color: var(--ink);
  background: var(--paper);
  border: 2px solid var(--ink);
  border-radius: 999px;
  min-width: 2.75rem;
  height: 2.75rem;
  padding: 0 1rem;
  cursor: pointer;
}
.controls button:hover { background: var(--ink); color: var(--paper); }
.controls .pause { margin-left: auto; }

/* Sub pages */
.sub-art { display: block; width: 12rem; height: auto; margin-top: 3rem; border-radius: 10px; border: 1px solid #c9d7da; }
.sub-name { font-size: clamp(3rem, 10vw, 8rem); margin-top: 1.5rem; }

@media (max-width: 40rem) {
  .identity { flex-direction: column; align-items: flex-start; }
  .block { grid-template-columns: 1fr; }
  .nav { justify-content: flex-start; }
}
