:root { --scene-content: 1; }
.pond-frame { overflow: hidden; }
.controls { opacity: var(--scene-content); }
.scene-navigation {
  position: absolute; z-index: 4; top: 32px; left: 50%; transform: translateX(-50%);
  display: flex; align-items: center; justify-content: center; gap: 32px;
  color: #eff2df; white-space: nowrap;
}
.scene-navigation a {
  display: inline-flex; align-items: center; min-height: 44px;
  font-size: 15px; font-weight: 500; letter-spacing: .06em;
  color: rgba(245, 248, 238, 0.92); text-decoration: none;
  text-shadow: 0 1px 12px rgba(10,34,24,0.85), 0 2px 4px rgba(10,34,24,0.9);
  transition: color 0.2s ease, text-shadow 0.2s ease;
}
.scene-navigation a[aria-current] {
  color: #ffffff;
  font-weight: 600;
  text-decoration: underline; text-underline-offset: 8px; text-decoration-color: rgba(220, 235, 215, 0.85);
}
.scene-navigation a:hover {
  color: #ffffff;
  text-shadow: 0 1px 16px rgba(10,34,24,0.95), 0 0 14px rgba(255,255,255,0.35);
}
.scene-navigation a:focus-visible { outline: 1px solid #eef2d5; outline-offset: 6px; }
.work-atmosphere { position: absolute; inset: 34px; border-radius: 40px; filter: blur(24px); pointer-events: none; z-index: 1; opacity: 0; background: radial-gradient(ellipse at 50% 40%, #183a2fe8 0%, #183a2fb8 35%, #183a2f55 62%, transparent 82%); }
[data-scene="work"] .work-atmosphere { opacity: 0; }
[data-scene]:not([data-scene="home"]) .controls { display: none; }
[data-journey="true"] #pond { pointer-events: none; }
.about-scene { position: absolute; inset: 0; z-index: 2; pointer-events: none; opacity: var(--scene-content); color: #f0f1de; transition: opacity 0.35s ease; }
@media (max-width: 600px) {
  .scene-navigation { top: 23px; gap: 22px; }
}
@media (max-height: 500px) and (orientation: landscape) {
  .scene-navigation { top: 10px; }
}
@media (prefers-reduced-motion: reduce) {
  /* nothing to reset here now */
}
/* Water reaches the display edges; navigation stays inside safe areas. */
@media (max-width: 600px), (max-width: 960px) and (max-height: 500px) {
  .scene-navigation { top: calc(18px + env(safe-area-inset-top)); }
}
@media (max-width: 960px) and (max-height: 500px) {
  .scene-navigation { top: calc(10px + env(safe-area-inset-top)); }
}


/* Real contact links float quietly over the water and keep generous tap targets. */
.contact-scene { position: absolute; inset: 0; z-index: 2; pointer-events: none; opacity: var(--scene-content); display: grid; place-items: center; transition: opacity 0.35s ease; }
.contact-details { text-align: center; width: min(520px, calc(100% - 48px)); color: #edf1dc; text-shadow: 0 1px 12px #173e32; }
.contact-label { display: block; font-size: 13px; font-weight: 500; letter-spacing: .12em; margin-bottom: 8px; color: #dfe8d2; }
.contact-address { display: inline-block; padding: 8px 0; font: 400 clamp(23px, 3.6vw, 36px)/1.35 "DM Sans", sans-serif; letter-spacing: -.025em; overflow-wrap: anywhere; }
.contact-details a { color: inherit; text-decoration: none; pointer-events: auto; }
.contact-details a:hover { color: white; text-decoration: underline; text-decoration-thickness: 1px; text-underline-offset: 7px; }
.contact-details a:focus-visible { outline: 1px solid #edf1dc; outline-offset: 7px; border-radius: 2px; }
[data-journey="true"] .contact-details a { pointer-events: none; }

.contact-socials {
  margin-top: 18px;
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 14px;
}
.contact-social-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  border-radius: 50%;
  color: #edf1dc;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(237, 241, 220, 0.25);
  box-shadow: 0 2px 10px rgba(23, 62, 50, 0.35);
  transition: transform 0.25s cubic-bezier(0.34, 1.56, 0.64, 1), background 0.2s ease, border-color 0.2s ease, color 0.2s ease, box-shadow 0.2s ease;
  pointer-events: auto;
}
.contact-social-link svg {
  width: 20px;
  height: 20px;
  fill: currentColor;
}
.contact-details .contact-social-link:hover {
  color: #ffffff;
  background: rgba(255, 255, 255, 0.2);
  border-color: rgba(255, 255, 255, 0.6);
  transform: translateY(-2px) scale(1.08);
  text-decoration: none;
  box-shadow: 0 4px 16px rgba(23, 62, 50, 0.5);
}
.contact-details .contact-social-link:active {
  transform: translateY(0) scale(0.94);
}
.contact-details .contact-social-link:focus-visible {
  outline: 2px solid #edf1dc;
  outline-offset: 4px;
  border-radius: 50%;
  text-decoration: none;
}
@media (prefers-reduced-motion: reduce) {
  .contact-social-link { transition: none; }
  .contact-details .contact-social-link:hover { transform: none; }
}

/* Semantic content keeps its layout; its visible copy is lit below the water. */
[data-submerged="true"] { opacity: 0; }

/* Keep the UI in the visible viewport, but let Safari sample real water above
   and below it. A fixed canvas or overflow-hidden document clips this bleed. */
html[data-pond-bleed="true"] {
  --pond-bleed: max(120px, calc(100lvh - 100svh), env(safe-area-inset-top), env(safe-area-inset-bottom));
  height: auto;
  overflow: visible;
  scrollbar-width: none;
}
[data-pond-bleed="true"] body {
  height: auto;
  overflow: visible;
  padding-block: var(--pond-bleed);
}
[data-pond-bleed="true"] .pond-frame { overflow: visible; }
[data-pond-bleed="true"] #pond {
  top: calc(-1 * var(--pond-bleed));
  bottom: auto;
  height: calc(100% + 2 * var(--pond-bleed));
}

/* A quiet corner ribbon, separate from the navigation and pond interactions. */
.development-ribbon {
  position: absolute;
  z-index: 5;
  top: env(safe-area-inset-top, 0px);
  right: env(safe-area-inset-right, 0px);
  padding: 8px 18px 8px 24px;
  font: 500 13px/1.25 "DM Sans", sans-serif;
  letter-spacing: .045em;
  white-space: nowrap;
  color: #eceddb;
  background: rgba(25, 53, 43, .76);
  clip-path: polygon(0 0, 100% 0, 100% 100%, 0 100%, 8px 50%);
  -webkit-backdrop-filter: blur(8px);
  backdrop-filter: blur(8px);
  pointer-events: none;
  user-select: none;
}
@media (max-width: 600px) {
  .development-ribbon {
    padding: 6px 14px 6px 18px;
    font-size: 11px;
    clip-path: polygon(0 0, 100% 0, 100% 100%, 0 100%, 6px 50%);
  }
}
