main {
	max-width: 1500px;  margin-top: 200px;   
    margin-bottom: 20px;

  /* Syntax: clamp(minimum, preferred-fluid-value, maximum) */
  font-size: clamp(1.5rem, 4vw, 3rem);

	section { max-width: 1000px; margin: 10px auto; padding: 20px; }
/* Overrides desktop style when viewport is less than 600px (for smart phones) */
@media only screen and (max-width: 600px) {
 -webkit-text-size-adjust: none;
  text-size-adjust: none;

}

/* ---------- Base ---------- */
body {
  margin: 0;
  min-height: 100vh;
  background: white;
  color: black;
  font-family: 'Fahkwang', sans-serif;
}

article.content {height: 2rem;}

img { width: 100%; display: block; }
ol, ul { list-style: none; }

.pinned {
  position: fixed;
  inset: 0;
  z-index: 1;
  overflow: hidden;
}

.scroll-layer {
  position: relative;
  z-index: 2;                 /* above .pinned, below your overlays (z-index: 10) */
  pointer-events: none;       /* lets the mouse reach the pinned content (the spotlight) */
}

.spacer { height: 130vh; }    /* one empty screen of scrolling */

.item {
  display: grid;
  grid-template-columns: 1fr 1fr;    /* image | text */
  gap: 24px;
  width: min(90%, 1000px);
  margin: 0 auto 60px;
  pointer-events: auto;
}

.item img {
  display: block;
  width: 100%;
  height: auto;
}

.item .text {
  display: flex;
  flex-direction: column;
  justify-content: flex-end;         /* pushes the text to the bottom */
  padding: 20px;
  background: none;
}
.item .text h3,
.item .text p {
  margin: 0 0 6px;
  font-family: 'Fahkwang', sans-serif;
}

.item {
  opacity: 0;
  transform: translateY(40px);
  transition: opacity .6s ease, transform .6s ease;
}
.item.visible {
  opacity: 1;
  transform: none;
}

/* Stack on phones */
@media (max-width: 600px) {
  .item { grid-template-columns: 1fr; }
}
.slider-wrap {
  position: relative;
  min-width: 0;               /* stops the grid column from stretching to fit all images */
}

.slider {
  display: flex;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  scrollbar-width: none;      /* hide scrollbar (Firefox) */
  -webkit-overflow-scrolling: touch;
  touch-action: pan-x pan-y;  /* swipe sideways, page still scrolls vertically */
}
.slider::-webkit-scrollbar { display: none; }   /* hide scrollbar (Chrome/Safari) */

.slider img {
  flex: 0 0 100%;             /* each image fills the box */
  width: 100%;
  height: auto;
  scroll-snap-align: center;
  user-select: none;
  -webkit-user-drag: none;
}
.slider img { aspect-ratio: 4 / 3; object-fit: cover; }

.dots {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 12px;
  display: flex;
  justify-content: center;
  gap: 8px;
  pointer-events: none;
}
.dots span {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: rgba(255, 255, 255, .5);
  transition: background .2s ease, transform .2s ease;
}
.dots span.active {
  background: white;
  transform: scale(1.3);
}

/* ---------- Navbar ---------- */
.navbar {
  display: flex;
  align-items: center;
  padding: 10px;
  background: white;
}
.nav-links { margin-left: auto; }   /* pushes the menu to the right */

.nav-links a {
  display: inline-block;
  margin: 10px;
  padding: 10px 20px;
  background: white;
  color: black;
  font-size: 1rem;
  text-decoration: none;
  transition: transform .2s ease, background-color .2s ease;
}
.nav-links a:hover {
  background: darkorange;
  transform: translateY(-2px);
}

/* ---------- Hero grid ---------- */
.grid {
  display: grid;
  grid-template-columns: 1fr 3fr;
  margin-top: 5px;                /* replaces the empty iframe spacer */
}
.grid > * { margin: 0; padding: 0; }
.grid .content { background: darkorange; }

@media (max-width: 500px) {
  .grid { display: block; }
}

/* ---------- Overlays ---------- */
.overlay {
  position: fixed;
  inset: 0;
  display: grid;
  place-items: center;
  padding: 20px;
  background: rgba(0, 0, 0, 0);
  backdrop-filter: blur(2px);
  opacity: 0;
  visibility: hidden;
  transition: opacity .3s ease, visibility .3s ease;
  z-index: 10;
}
.overlay:target {
  opacity: 1;
  visibility: visible;
}
.overlay .backdrop {                 /* click outside the panel to close */
  position: absolute;
  inset: 0;
}

.panel {
  position: relative;
  width: min(100%, 640px);
  max-height: 70vh;
  overflow-y: auto;
  padding: 30px;
  background: rgba(255, 255, 255, 0.2);
  transform: translateY(20px) scale(.97);
  transition: transform .3s ease;
}
.overlay:target .panel {
  transform: translateY(0) scale(1);
}

.close {
  position: absolute;
  top: 14px;
  right: 16px;
  width: 36px;
  height: 36px;
  display: grid;
  place-items: center;
  font-size: 1.4rem;
  text-decoration: none;
  color: #222;
}

/* ---------- Two-column layout (about + resume) ---------- */
.two-col {
  display: grid;
  grid-template-columns: 140px 1fr;  /* label | content */
  gap: 28px 32px;
  align-items: start;
}
.two-col .info p { margin: 0 0 12px; }
.two-col .small { font-size: 13px; }

@media (max-width: 500px) {
  .two-col {
    grid-template-columns: 1fr;
    gap: 8px;
  }
  .two-col .info { margin-bottom: 20px; }
}

/* ---------- Contact form ---------- */
.contact-form {
  display: grid;
  gap: 20px;
  width: 100%;
  margin: 0 auto;
}
.contact-form h2 { margin: 0; font-weight: 400; }

.contact-form .field {
  display: grid;
  gap: 6px;
}
.contact-form label {
  font-size: .85rem;
  letter-spacing: .05em;
}
.contact-form input,
.contact-form textarea {
  width: 100%;
  box-sizing: border-box;
  padding: 12px;
  font: inherit;
  color: black;
  background: white;
  border: 1px solid black;
  border-radius: 0;
  transition: border-color .2s ease, box-shadow .2s ease;
}
.contact-form textarea { min-height: 160px; resize: vertical; }

.contact-form input:focus,
.contact-form textarea:focus {
  outline: none;
  border-color: darkorange;
  box-shadow: 0 0 0 3px rgba(255, 140, 0, .25);
}
.contact-form button {
  justify-self: start;
  padding: 12px 32px;
  font: inherit;
  color: black;
  background: white;
  border: 1px solid black;
  cursor: pointer;
  transition: background-color .2s ease, transform .2s ease;
}
.contact-form button:hover {
  background: darkorange;
  transform: translateY(-2px);
}

@media (min-width: 600px) {
  .contact-form .row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
  }
}
@media (max-width: 599px) {
  .contact-form .row { display: grid; gap: 20px; }

}
.spotlight {
  --x: -999px;
  --y: -999px;
  --size: 120px;

  position: relative;
  width: 100%;
  max-width: 100%;
  overflow: hidden;
  cursor: none;
  touch-action: none;
}

.layer { position: relative; }

.layer img {
  display: block;
  width: 100%;
  height: auto;
}

/* Text sitting on the image */
.caption {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  padding: 10px;
  color: white;
  min-width: 1200px;
  font-family: 'Fahkwang', sans-serif;
}
.caption p { font-family: 'Fahkwang', sans-serif; margin: 0 0 6px; color: white; font-size: clamp(1rem, 3.5vw, 4rem); }

/* Blurred layer: image and text are both blurred */
.base img {
  filter: blur(10px);
  transform: scale(1.05);   /* hides the soft edges */
}
.base .caption { filter: blur(4px); }

/* Sharp layer: same content, masked to a circle around the cursor */
.sharp {
  position: absolute;
  inset: 0;
  pointer-events: none;
  -webkit-mask-image: radial-gradient(circle var(--size) at var(--x) var(--y), #000 0%, #000 55%, transparent 100%);
          mask-image: radial-gradient(circle var(--size) at var(--x) var(--y), #000 0%, #000 55%, transparent 100%);
}
.sharp img {
  height: 100%;
  object-fit: cover;
}

