/* Branch Hill Apps — minimal, Apple-inspired */

@font-face {
  font-family: "EB Garamond";
  font-style: normal;
  font-weight: 600;
  font-display: swap;
  src: url("/assets/fonts/EBGaramond-600.woff2") format("woff2");
}

:root {
  --bg: #0b0b0c;
  --text: #f5f5f7;
  --muted: rgba(235, 235, 245, 0.65);
  --card: rgba(118, 118, 128, 0.16);
  --card-border: rgba(235, 235, 245, 0.14);
  --shadow: 0 24px 60px rgba(0, 0, 0, 0.35);
  --radius: 16px;
}

* {
  box-sizing: border-box;
}

html,
body {
  height: 100%;
  background-color: var(--bg);
}

body {
  margin: 0;
  color: var(--text);
  background:
    radial-gradient(1200px 520px at 50% -140px, rgba(64, 110, 255, 0.16), rgba(0, 0, 0, 0) 58%),
    linear-gradient(180deg, rgba(18, 34, 72, 0.40) 0%, rgba(11, 11, 12, 1) 42%);
  background-color: var(--bg);
  font-family: -apple-system, BlinkMacSystemFont, "SF Pro Display", "SF Pro Text", "Helvetica Neue",
    Helvetica, Arial, system-ui, sans-serif;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

.page {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 64px 20px;
  padding-bottom: calc(64px + env(safe-area-inset-bottom, 0px));
  gap: 28px;
  position: relative;
  z-index: 1;
  overflow-x: hidden;
}

.hero {
  text-align: center;
  position: relative;
}

.pond {
  width: min(560px, 92vw);
  padding: 0 14px;
  margin: 0 auto 10px;
  opacity: 0.9;
}

.pond--bottom {
  position: fixed;
  left: 0;
  right: 0;
  bottom: calc(-1 * env(safe-area-inset-bottom, 0px));
  width: 100vw;
  height: clamp(360px, 54vh, 620px);
  max-width: none;
  padding: 0;
  margin: 0;
  pointer-events: none;
  opacity: 0.95;
  z-index: 0;
}

.pond svg {
  display: block;
  width: 100%;
  height: auto;
  overflow: visible;
}

.pond--bottom svg {
  width: 100%;
  height: 100%;
}

/* Subtle water animation */
@media (prefers-reduced-motion: no-preference) {
  .pond--bottom svg {
    transform-origin: 50% 70%;
    animation: pondSway 9s ease-in-out infinite;
  }

  .pond--bottom .ripples {
    transform-origin: 50% 65%;
    transform-box: fill-box;
    animation: ripplesPulse 7s ease-in-out infinite;
  }

  .pond--bottom .pond-glow {
    transform-origin: 50% 50%;
    transform-box: fill-box;
    animation: glowDrift 6.5s ease-in-out infinite;
  }
}

@keyframes pondSway {
  0% {
    transform: translateX(0px) translateY(0px) scale(1);
  }
  50% {
    transform: translateX(-10px) translateY(-4px) scale(1.01);
  }
  100% {
    transform: translateX(0px) translateY(0px) scale(1);
  }
}

@keyframes ripplesPulse {
  0% {
    opacity: 0.38;
    transform: translateX(0px) translateY(0px) scale(1);
  }
  35% {
    opacity: 0.65;
    transform: translateX(6px) translateY(-5px) scale(1.02);
  }
  70% {
    opacity: 0.30;
    transform: translateX(-4px) translateY(4px) scale(0.995);
  }
  100% {
    opacity: 0.38;
    transform: translateX(0px) translateY(0px) scale(1);
  }
}

@keyframes glowDrift {
  0% {
    opacity: 0.55;
    transform: translateX(0px) translateY(0px);
  }
  50% {
    opacity: 0.95;
    transform: translateX(10px) translateY(-10px);
  }
  100% {
    opacity: 0.55;
    transform: translateX(0px) translateY(0px);
  }
}

.pond {
  opacity: 0.75;
}

.wordmark {
  margin: 0;
  font-family: "EB Garamond", Garamond, "Times New Roman", serif;
  font-size: clamp(58px, 9vw, 108px);
  font-weight: 600;
  letter-spacing: -0.02em;
  line-height: 1.02;

  /* Glassy text treatment */
  color: transparent;
  background-image: linear-gradient(
    180deg,
    rgba(255, 255, 255, 0.96) 0%,
    rgba(255, 255, 255, 0.68) 55%,
    rgba(225, 242, 255, 0.62) 100%
  );
  -webkit-background-clip: text;
  background-clip: text;

  text-shadow: none;
}

.wordmark-line {
  display: inline;
  white-space: nowrap;
}

@media (max-width: 520px) {
  .wordmark {
    font-size: clamp(72px, 14vw, 116px);
    line-height: 0.96;
    letter-spacing: -0.015em;
  }

  .wordmark-line {
    display: block;
  }

  /* Slightly tighter vertical rhythm on mobile */
  .wordmark-line--b {
    margin-top: -0.10em;
  }
  .wordmark-line--c {
    margin-top: -0.10em;
  }
}

.visually-hidden {
  position: absolute !important;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

.apps {
  width: min(760px, 100%);
}




.apps-list {
  list-style: none;
  padding: 0;
  margin: 0;
  display: grid;
  grid-template-columns: 1fr;
  gap: 12px;
}

.app {
  border-radius: var(--radius);
  background: var(--card);
  border: 1px solid var(--card-border);
  box-shadow: var(--shadow);
  overflow: hidden;
}

.app-link {
  display: flex;
  flex-direction: column;
  gap: 4px;
  padding: 16px 18px;
  color: inherit;
  text-decoration: none;
}

.app-link--row {
  flex-direction: row;
  align-items: center;
  gap: 14px;
}

.app-icon {
  width: 56px;
  height: 56px;
  border-radius: 14px;
  border: 1px solid var(--card-border);
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.10);
  flex: 0 0 auto;
}

.app-icon {
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.35);
}

.app-text {
  display: flex;
  flex-direction: column;
  gap: 4px;
  min-width: 0;
}

.app-link:hover {
  background: rgba(118, 118, 128, 0.10);
}

.app-link:focus-visible {
  outline: 3px solid rgba(10, 132, 255, 0.55);
  outline-offset: 2px;
}

.app-name {
  font-size: 17px;
  font-weight: 600;
  letter-spacing: -0.01em;
}

.app-meta {
  font-size: 13px;
  color: var(--muted);
}

.app--placeholder {
  padding: 16px 18px;
  text-align: center;
  color: var(--muted);
}

.footer {
  margin-top: 12px;
}

.footer-text {
  margin: 0;
  font-size: 13px;
  color: var(--muted);
}

@media (min-width: 720px) {
  .apps-list {
    grid-template-columns: 1fr;
  }
}
