@import url("https://fonts.googleapis.com/css2?family=Elms+Sans:wght@100;200;300;400;500;600;700;800;900&display=swap");

:root {
  --page-ink: #111111;
  --muted-ink: rgba(17, 17, 17, 0.66);
  --panel-fill: rgba(246, 247, 248, 0.78);
  --panel-stroke: rgba(17, 17, 17, 0.12);
  --panel-shadow: rgba(17, 17, 17, 0.18);
  --hairline: rgba(17, 17, 17, 0.16);
  --hover-fill: rgba(255, 255, 255, 0.32);
}

html {
  box-sizing: border-box;
  min-height: 100%;
}

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

body {
  min-height: 100vh;
  margin: 0;
  color: var(--page-ink);
  font-family: "Elms Sans", sans-serif;
  font-size: 16px;
  line-height: 1.55;
  background: #f1f1ee;
}

::selection {
  background: rgba(242, 209, 61, 0.45);
}

a,
a:visited {
  color: inherit;
  text-decoration-color: rgba(17, 17, 17, 0.36);
  text-underline-offset: 0.18em;
}

a:hover {
  text-decoration-color: rgba(17, 17, 17, 0.88);
}

h1,
h2,
h3,
h4,
h5,
h6,
p,
li {
  margin-top: 0;
  margin-bottom: 24px;
}

.mondrian-background {
  position: fixed;
  inset: 0;
  z-index: 0;
  overflow: hidden;
  background: #ffffff;
}

#mondrian-canvas,
.background-wash {
  position: absolute;
  inset: 0;
}

#mondrian-canvas {
  display: block;
  width: 100vw;
  height: 100vh;
}

.background-wash {
  background:
    linear-gradient(to bottom, rgba(255, 255, 255, 0), rgba(255, 255, 255, 0.04) 62%, rgba(255, 255, 255, 0.02)),
    radial-gradient(circle at 18% 18%, rgba(255, 255, 255, 0.05), transparent 38%),
    radial-gradient(circle at 80% 20%, rgba(255, 255, 255, 0.03), transparent 34%);
  pointer-events: none;
}

.page-shell {
  position: relative;
  z-index: 1;
  padding: calc(100vh - 48px) 20px 56px;
  pointer-events: none;
}

.content-panel {
  position: sticky;
  top: 30px;
  width: min(100%, 880px);
  margin: 0 auto;
  border: 1px solid var(--panel-stroke);
  border-radius: 22px 22px 18px 18px;
  background: var(--panel-fill);
  box-shadow: 0 28px 72px var(--panel-shadow);
  backdrop-filter: blur(22px) saturate(108%);
  -webkit-backdrop-filter: blur(22px) saturate(108%);
  pointer-events: auto;
  overflow: hidden;
  transform-origin: 50% 0;
  transition:
    box-shadow 320ms ease,
    border-color 240ms ease;
}

.panel-titlebar {
  display: flex;
  align-items: center;
  justify-content: flex-start;
  min-height: 34px;
  padding: 14px 18px 0;
}

.panel-stoplights {
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

.stoplight {
  width: 12px;
  height: 12px;
  padding: 0;
  border: 0;
  border-radius: 999px;
  appearance: none;
  box-shadow: inset 0 0 0 1px rgba(17, 17, 17, 0.16);
  cursor: pointer;
}

.stoplight-close {
  background: #ff5f57;
}

.stoplight-minimize {
  background: #febc2e;
}

.stoplight-expand {
  background: #28c840;
}

.panel-inner {
  padding: 16px 34px 28px;
}

.panel-inner > *:last-child {
  margin-bottom: 0;
}

body[data-panel-state="hidden"] .content-panel {
  display: none;
}

body[data-panel-state="hidden"] .page-shell {
  padding: 0;
}

body[data-panel-state="expanded"] .content-panel {
  box-shadow: 0 24px 56px rgba(17, 17, 17, 0.15);
}

h1,
h2,
h3,
h4,
h5,
h6 {
  font-family: "Elms Sans", sans-serif;
  font-weight: 500;
  letter-spacing: 0.01em;
}

h1 {
  margin-bottom: 12px;
  font-size: clamp(2.35rem, 5vw, 4rem);
  line-height: 0.95;
  font-weight: 300;
}

h2 {
  margin-top: 38px;
  margin-bottom: 18px;
  font-size: clamp(1.15rem, 1.5vw, 1.35rem);
  line-height: 1.2;
}

p,
li {
  font-size: 1rem;
}

.emoji {
  position: relative;
  top: 0.08em;
  margin-right: 0.18em;
  font-size: 1.15em;
  line-height: 0;
}

.project-list {
  list-style: none;
  padding-left: 0;
  margin-bottom: 28px;
}

.project-item {
  display: grid;
  grid-template-columns: minmax(0, 190px) minmax(0, 1fr);
  gap: 22px;
  align-items: start;
  padding: 10px 0 4px;
  border-top: 1px solid var(--hairline);
}

.project-item:last-child {
  border-bottom: 1px solid var(--hairline);
}

.project-image-frame {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 190px;
  min-height: 0;
  padding: 0;
}

.project-image-frame.is-empty {
  opacity: 0;
}

.project-item img {
  display: block;
  width: auto;
  max-width: 100%;
  max-height: 80px;
  height: auto;
}

.project-copy {
  min-width: 0;
}

.project-copy > a:first-child,
.panel-inner > p > a:first-child,
.project-copy > a:first-child:visited {
  font-weight: 600;
}

.section-divider {
  display: flex;
  align-items: center;
  gap: 14px;
  margin: 30px 0;
  color: var(--muted-ink);
}

.section-divider-prefix {
  flex: 0 0 auto;
  font-family: "Elms Sans", sans-serif;
  font-size: 0.85rem;
  letter-spacing: 0.08em;
}

.section-divider-line {
  flex: 1 1 auto;
  height: 1px;
  background: var(--hairline);
}

.footer {
  margin-top: 28px;
  padding-top: 18px;
  border-top: 1px solid var(--hairline);
  font-size: 0.84rem;
}

.status-section {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px;
}

.footer-link {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding: 6px 10px;
  border-radius: 999px;
  text-decoration: none;
  background: rgba(255, 255, 255, 0.18);
  border: 1px solid rgba(17, 17, 17, 0.12);
}

.footer-link svg {
  width: 14px;
  height: 14px;
  fill: none;
  stroke: currentColor;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
  flex: 0 0 auto;
}

.footer-link:hover {
  background: rgba(255, 255, 255, 0.34);
}

@media (max-width: 760px) {
  .page-shell {
    padding-top: calc(100vh - 46px);
  }

  .panel-titlebar {
    padding: 12px 16px 0;
  }

  .panel-inner {
    padding: 14px 22px 22px;
  }

  .project-item {
    grid-template-columns: 1fr;
    gap: 16px;
  }

  .project-image-frame {
    width: 100%;
  }

  .project-item img {
    max-width: min(100%, 190px);
  }
}

@media (max-width: 560px) {
  body {
    font-size: 15px;
  }

  .page-shell {
    padding: calc(100vh - 44px) 12px 36px;
  }

  .content-panel {
    border-radius: 18px 18px 16px 16px;
  }

  .panel-dock {
    bottom: 14px;
  }

  h1 {
    font-size: clamp(2rem, 12vw, 3rem);
  }

  .status-section {
    gap: 8px;
  }
}
