/* Dark, no-scroll landing + slide-up panels */

:root {
  --bg-deep: #08080f;
  --bg-mid: #12101c;
  --text: #f4efe8;
  --text-muted: rgba(244, 239, 232, 0.62);
  --accent: #e8a87c;
  --accent-glow: #e07a5f;
  --accent-cool: #7eb8da;
  --accent-purple: #9b7ec8;
  --glass: rgba(255, 255, 255, 0.06);
  --glass-border: rgba(255, 255, 255, 0.1);
  --panel-bg: #14121f;
  --focus: #e8a87c;
}

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

html {
  -webkit-text-size-adjust: 100%;
}

body {
  margin: 0;
  font-family: "DM Sans", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  font-size: 1rem;
  line-height: 1.6;
  color: var(--text);
  background: var(--bg-deep);
  overflow: hidden;
  height: 100%;
  height: 100dvh;
  padding-left: env(safe-area-inset-left, 0);
  padding-right: env(safe-area-inset-right, 0);
}

body.panel-open {
  overflow: hidden;
}

img {
  max-width: 100%;
  height: auto;
  display: block;
}

a {
  color: var(--accent);
}

button {
  font-family: inherit;
}

a:focus-visible,
button:focus-visible {
  outline: 3px solid var(--focus);
  outline-offset: 3px;
}

/* ─── Landing (fixed, no scroll) ─── */

.landing {
  position: fixed;
  inset: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  z-index: 1;
}

.landing-bg {
  position: absolute;
  inset: 0;
  background:
    radial-gradient(ellipse 80% 60% at 20% 80%, rgba(224, 122, 95, 0.18) 0%, transparent 55%),
    radial-gradient(ellipse 70% 50% at 85% 15%, rgba(155, 126, 200, 0.22) 0%, transparent 50%),
    radial-gradient(ellipse 60% 45% at 50% 50%, rgba(126, 184, 218, 0.1) 0%, transparent 60%),
    linear-gradient(165deg, #08080f 0%, #12101c 45%, #0d0b14 100%);
}

/* Animated aurora ribbons */
.landing-bg::before {
  content: "";
  position: absolute;
  inset: -20%;
  background:
    conic-gradient(from 200deg at 30% 70%,
      transparent 0deg,
      rgba(224, 122, 95, 0.12) 60deg,
      transparent 120deg,
      rgba(155, 126, 200, 0.15) 200deg,
      transparent 280deg);
  animation: aurora-drift 18s ease-in-out infinite alternate;
  opacity: 0.9;
}

.landing-bg::after {
  content: "";
  position: absolute;
  inset: 0;
  background-image:
    radial-gradient(1px 1px at 10% 20%, rgba(255, 255, 255, 0.5) 0%, transparent 100%),
    radial-gradient(1px 1px at 25% 65%, rgba(255, 255, 255, 0.35) 0%, transparent 100%),
    radial-gradient(1.5px 1.5px at 40% 15%, rgba(255, 255, 255, 0.45) 0%, transparent 100%),
    radial-gradient(1px 1px at 55% 80%, rgba(255, 255, 255, 0.3) 0%, transparent 100%),
    radial-gradient(1px 1px at 70% 35%, rgba(255, 255, 255, 0.4) 0%, transparent 100%),
    radial-gradient(1.5px 1.5px at 85% 55%, rgba(255, 255, 255, 0.35) 0%, transparent 100%),
    radial-gradient(1px 1px at 92% 12%, rgba(255, 255, 255, 0.5) 0%, transparent 100%),
    radial-gradient(1px 1px at 15% 88%, rgba(255, 255, 255, 0.25) 0%, transparent 100%),
    radial-gradient(1px 1px at 48% 48%, rgba(255, 255, 255, 0.2) 0%, transparent 100%),
    radial-gradient(1px 1px at 78% 72%, rgba(255, 255, 255, 0.3) 0%, transparent 100%);
  animation: stars-twinkle 6s ease-in-out infinite alternate;
}

@keyframes aurora-drift {
  0% { transform: rotate(0deg) scale(1); }
  100% { transform: rotate(8deg) scale(1.08); }
}

@keyframes stars-twinkle {
  0% { opacity: 0.6; }
  100% { opacity: 1; }
}

.blob {
  position: absolute;
  border-radius: 50%;
  filter: blur(70px);
  opacity: 0.55;
  animation: blob-float 14s ease-in-out infinite;
}

.blob-1 {
  width: 320px;
  height: 320px;
  background: #e07a5f;
  top: -8%;
  left: -5%;
  animation-delay: 0s;
}

.blob-2 {
  width: 280px;
  height: 280px;
  background: #9b7ec8;
  bottom: 5%;
  right: -8%;
  animation-delay: -5s;
}

.blob-3 {
  width: 200px;
  height: 200px;
  background: #7eb8da;
  top: 40%;
  left: 55%;
  animation-delay: -9s;
  opacity: 0.35;
}

@keyframes blob-float {
  0%, 100% { transform: translate(0, 0) scale(1); }
  33% { transform: translate(20px, -25px) scale(1.05); }
  66% { transform: translate(-15px, 15px) scale(0.95); }
}

.grain {
  position: absolute;
  inset: 0;
  opacity: 0.35;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 256 256' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.85' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)' opacity='0.5'/%3E%3C/svg%3E");
  background-size: 180px;
  pointer-events: none;
  mix-blend-mode: overlay;
}

/* Floating polaroids */
.polaroids {
  position: absolute;
  inset: 0;
  pointer-events: none;
  z-index: 1;
}

.polaroid {
  position: absolute;
  padding: 10px 10px 34px;
  background: rgba(255, 255, 255, 0.92);
  box-shadow:
    0 16px 48px rgba(0, 0, 0, 0.5),
    0 0 0 1px rgba(255, 255, 255, 0.08);
  border-radius: 2px;
  animation: polaroid-float 9s ease-in-out infinite;
}

.polaroid img {
  width: clamp(150px, 34vw, 240px);
  height: clamp(150px, 34vw, 240px);
  object-fit: cover;
  border-radius: 1px;
}

.polaroid-1 { top: 8%; left: 2%; transform: rotate(-12deg); animation-delay: 0s; }
.polaroid-2 { top: 10%; right: 2%; transform: rotate(8deg); animation-delay: -2s; }
.polaroid-3 { bottom: 14%; left: 2%; transform: rotate(6deg); animation-delay: -4s; }
.polaroid-4 { bottom: 11%; right: 2%; transform: rotate(-7deg); animation-delay: -6s; }

@keyframes polaroid-float {
  0%, 100% { margin-top: 0; }
  50% { margin-top: -10px; }
}

@media (max-width: 480px) {
  .polaroid {
    padding: 9px 9px 30px;
  }

  .polaroid img {
    width: clamp(140px, 44vw, 190px);
    height: clamp(140px, 44vw, 190px);
  }

  .polaroid-1 { top: 5%; left: 0; }
  .polaroid-2 { top: 6%; right: 0; }
  .polaroid-3 { bottom: 12%; left: 0; }
  .polaroid-4 { bottom: 9%; right: 0; }
}

@media (min-width: 768px) {
  .polaroid img {
    width: clamp(200px, 20vw, 280px);
    height: clamp(200px, 20vw, 280px);
  }

  .polaroid-1 { top: 9%; left: 3%; }
  .polaroid-2 { top: 11%; right: 3%; }
  .polaroid-3 { bottom: 13%; left: 4%; }
  .polaroid-4 { bottom: 10%; right: 3%; }
}

@media (max-height: 640px) {
  .polaroid img {
    width: clamp(120px, 32vw, 165px);
    height: clamp(120px, 32vw, 165px);
  }
}

/* Landing content */
.landing-content {
  position: relative;
  z-index: 2;
  text-align: center;
  padding: 1.5rem 1.25rem;
  max-width: 520px;
}

.landing-eyebrow {
  font-size: 0.75rem;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--accent);
  margin: 0 0 1rem;
  opacity: 0.9;
}

.landing-title {
  font-family: "Playfair Display", Georgia, serif;
  font-size: clamp(2.4rem, 9vw, 3.75rem);
  font-weight: 600;
  line-height: 1.05;
  margin: 0 0 1rem;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.1rem;
}

.title-line {
  display: block;
  background: linear-gradient(135deg, #f4efe8 30%, #e8c4a8 100%);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
}

.title-line--accent {
  background: linear-gradient(135deg, #e8a87c 0%, #e07a5f 50%, #c9a0dc 100%);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
}

.title-amp {
  font-family: "Playfair Display", Georgia, serif;
  font-style: italic;
  font-size: 0.45em;
  color: var(--accent);
  -webkit-text-fill-color: var(--accent);
  opacity: 0.85;
  margin: 0.1em 0;
}

.landing-tagline {
  font-size: clamp(0.95rem, 3vw, 1.1rem);
  color: var(--text-muted);
  margin: 0 0 2rem;
  line-height: 1.55;
}

/* Portal buttons */
.portals {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 0.75rem;
}

.portal {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 0.35rem;
  min-width: 96px;
  min-height: 88px;
  padding: 0.875rem 1.25rem;
  border: 1px solid var(--glass-border);
  border-radius: 18px;
  background: var(--glass);
  -webkit-backdrop-filter: blur(12px);
  backdrop-filter: blur(12px);
  color: var(--text);
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
  transition: background 0.2s ease, border-color 0.2s ease, transform 0.15s ease, box-shadow 0.2s ease;
  box-shadow: 0 4px 24px rgba(0, 0, 0, 0.2);
}

.portal:hover,
.portal:active {
  background: rgba(255, 255, 255, 0.1);
  border-color: rgba(232, 168, 124, 0.35);
  box-shadow: 0 8px 32px rgba(224, 122, 95, 0.15);
}

.portal:active {
  transform: scale(0.96);
}

.portal-icon {
  font-size: 1.35rem;
  line-height: 1;
  color: var(--accent);
}

.portal-icon svg {
  display: block;
  fill: var(--accent);
}

.portal-label {
  font-size: 0.8rem;
  font-weight: 600;
  letter-spacing: 0.04em;
}

.landing-footer {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  z-index: 2;
  text-align: center;
  font-size: 0.75rem;
  color: var(--text-muted);
  margin: 0;
  padding: 1rem 1.25rem;
  padding-bottom: calc(1rem + env(safe-area-inset-bottom, 0));
}

/* ─── Slide-up panels ─── */

.panel {
  position: fixed;
  inset: 0;
  z-index: 50;
  background: var(--panel-bg);
  display: flex;
  flex-direction: column;
  transform: translateY(100%);
  transition: transform 0.4s cubic-bezier(0.32, 0.72, 0, 1);
  visibility: hidden;
}

.panel.is-open {
  transform: translateY(0);
  visibility: visible;
}

.panel-header {
  flex-shrink: 0;
  display: flex;
  align-items: center;
  gap: 1rem;
  padding: 0.875rem 1.25rem;
  padding-top: calc(0.875rem + env(safe-area-inset-top, 0));
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
  background: rgba(8, 8, 15, 0.6);
  -webkit-backdrop-filter: blur(10px);
  backdrop-filter: blur(10px);
}

.panel-back {
  min-height: 44px;
  padding: 0.5rem 0.875rem;
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 999px;
  background: transparent;
  color: var(--text);
  font-size: 0.9rem;
  font-weight: 500;
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
  white-space: nowrap;
}

.panel-back:hover,
.panel-back:active {
  background: rgba(255, 255, 255, 0.06);
}

.panel-title {
  font-family: "Playfair Display", Georgia, serif;
  font-size: 1.25rem;
  font-weight: 600;
  margin: 0;
  color: var(--text);
}

.panel-body {
  flex: 1;
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
  padding: 1.25rem;
  padding-bottom: calc(1.25rem + env(safe-area-inset-bottom, 0));
  max-width: 960px;
  width: 100%;
  margin: 0 auto;
}

.section-desc {
  color: var(--text-muted);
  margin: 0 0 1.5rem;
}

.gallery-empty {
  text-align: center;
  color: var(--text-muted);
  padding: 2rem 1rem;
  margin: 0;
  background: rgba(255, 255, 255, 0.04);
  border-radius: 14px;
  border: 1px dashed rgba(255, 255, 255, 0.12);
}

/* Link cards (dark) */
.links-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 0.75rem;
}

@media (min-width: 480px) {
  .links-grid { grid-template-columns: 1fr 1fr; }
}

.link-card {
  display: flex;
  align-items: center;
  gap: 1rem;
  min-height: 72px;
  padding: 1rem 1.25rem;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 14px;
  text-decoration: none;
  color: var(--text);
  -webkit-tap-highlight-color: transparent;
  transition: background 0.2s ease, transform 0.15s ease;
}

.link-card:hover,
.link-card:active {
  background: rgba(255, 255, 255, 0.09);
}

.link-card:active { transform: scale(0.99); }

.link-card.is-disabled {
  opacity: 0.45;
  pointer-events: none;
}

.link-icon {
  flex-shrink: 0;
  width: 44px;
  height: 44px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.08);
}

.link-icon svg {
  width: 22px;
  height: 22px;
  fill: var(--accent);
}

.link-icon--instagram {
  background: linear-gradient(135deg, #fdf497, #fd5949, #d6249f);
}

.link-icon--instagram svg { fill: #fff; }

.link-text strong { display: block; font-size: 1rem; }
.link-text span { font-size: 0.85rem; color: var(--text-muted); }

/* Gallery carousel */
.panel-body--gallery {
  display: flex;
  flex-direction: column;
}

.gallery-carousel {
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 1rem;
  min-height: 0;
}

.carousel-main {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  width: 100%;
}

.carousel-viewport {
  flex: 1;
  overflow: hidden;
  border-radius: 16px;
  background: rgba(0, 0, 0, 0.25);
  touch-action: pan-y pinch-zoom;
  cursor: grab;
  user-select: none;
  -webkit-user-select: none;
}

.carousel-viewport.is-dragging {
  cursor: grabbing;
}

.carousel-track {
  display: flex;
  transition: transform 0.35s cubic-bezier(0.32, 0.72, 0, 1);
  will-change: transform;
}

.carousel-track.no-transition {
  transition: none;
}

.carousel-slide {
  flex: 0 0 100%;
  min-width: 100%;
  margin: 0;
  padding: 0;
}

.carousel-slide img {
  width: 100%;
  aspect-ratio: 1;
  object-fit: cover;
  display: block;
  border-radius: 16px;
  -webkit-tap-highlight-color: transparent;
}

.carousel-btn {
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  min-width: 48px;
  min-height: 48px;
  width: 48px;
  height: 48px;
  padding: 0;
  border: 1px solid rgba(255, 255, 255, 0.15);
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.08);
  color: var(--text);
  font-size: 1.75rem;
  line-height: 1;
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
  transition: background 0.2s ease, transform 0.15s ease;
}

.carousel-btn:hover,
.carousel-btn:active {
  background: rgba(255, 255, 255, 0.15);
}

.carousel-btn:active {
  transform: scale(0.94);
}

.carousel-meta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 0 0.25rem;
}

.carousel-caption {
  margin: 0;
  font-weight: 600;
  font-size: 1rem;
  color: var(--text);
}

.carousel-counter {
  margin: 0;
  font-size: 0.85rem;
  color: var(--text-muted);
  white-space: nowrap;
}

.carousel-dots {
  display: flex;
  justify-content: center;
  flex-wrap: nowrap;
  gap: 0.5rem;
  padding: 0.5rem 0.25rem;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none;
}

.carousel-dots::-webkit-scrollbar {
  display: none;
}

.carousel-thumb {
  flex-shrink: 0;
  width: 52px;
  height: 52px;
  min-width: 52px;
  min-height: 52px;
  padding: 0;
  border: 2px solid rgba(255, 255, 255, 0.15);
  border-radius: 10px;
  background: rgba(0, 0, 0, 0.2);
  cursor: pointer;
  overflow: hidden;
  -webkit-tap-highlight-color: transparent;
  transition: border-color 0.2s ease, transform 0.15s ease, opacity 0.2s ease;
  opacity: 0.65;
}

.carousel-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  pointer-events: none;
}

.carousel-thumb:hover,
.carousel-thumb:active {
  opacity: 0.9;
}

.carousel-thumb.is-active {
  border-color: var(--accent);
  opacity: 1;
  transform: scale(1.08);
}

.carousel-thumb:focus-visible {
  outline: 3px solid var(--focus);
  outline-offset: 2px;
}

@media (min-width: 640px) {
  .carousel-thumb {
    width: 60px;
    height: 60px;
    min-width: 60px;
    min-height: 60px;
    border-radius: 12px;
  }
}

@media (min-width: 640px) {
  .carousel-slide img {
    max-height: min(60vh, 520px);
    aspect-ratio: auto;
    object-fit: contain;
    background: rgba(0, 0, 0, 0.2);
  }
}

/* Instagram panel */
.instagram-wrap {
  background: rgba(255, 255, 255, 0.04);
  border-radius: 14px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  padding: 1rem;
  overflow: hidden;
}

.instagram-profile {
  display: flex;
  align-items: center;
  gap: 1rem;
  margin-bottom: 1.25rem;
  flex-wrap: wrap;
}

.instagram-avatar {
  width: 64px;
  height: 64px;
  border-radius: 50%;
  background: linear-gradient(135deg, #fdf497, #fd5949, #d6249f);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.instagram-avatar svg {
  width: 32px;
  height: 32px;
  fill: #fff;
}

.instagram-handle { flex: 1; min-width: 0; }
.instagram-handle strong { display: block; font-size: 1.1rem; }
.instagram-handle span { color: var(--text-muted); font-size: 0.9rem; }

.instagram-follow {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 44px;
  padding: 0.625rem 1.25rem;
  background: #0095f6;
  color: #fff;
  font-weight: 600;
  text-decoration: none;
  border-radius: 8px;
  -webkit-tap-highlight-color: transparent;
}

.instagram-embed {
  min-height: 200px;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
}

.instagram-embed blockquote {
  margin: 0 auto !important;
  max-width: 100% !important;
}

.instagram-fallback {
  text-align: center;
  padding: 2rem 1rem;
  color: var(--text-muted);
  font-size: 0.9rem;
}

/* Lightbox */
.lightbox {
  display: none;
  position: fixed;
  inset: 0;
  z-index: 200;
  background: rgba(0, 0, 0, 0.94);
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 1rem;
  padding-top: calc(3.5rem + env(safe-area-inset-top, 0));
  padding-bottom: calc(3rem + env(safe-area-inset-bottom, 0));
  touch-action: manipulation;
}

.lightbox.is-open { display: flex; }

.lightbox img {
  max-width: 100%;
  max-height: calc(100vh - 8rem);
  max-height: calc(100dvh - 8rem);
  border-radius: 8px;
  object-fit: contain;
}

.lightbox-close {
  position: absolute;
  top: calc(1rem + env(safe-area-inset-top, 0));
  right: 1rem;
  min-width: 48px;
  min-height: 48px;
  border: none;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.12);
  color: #fff;
  font-size: 1.5rem;
  line-height: 1;
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
  z-index: 2;
}

.lightbox-nav {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  min-width: 48px;
  min-height: 48px;
  width: 48px;
  height: 48px;
  padding: 0;
  border: none;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.12);
  color: #fff;
  font-size: 1.75rem;
  line-height: 1;
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
  z-index: 2;
}

.lightbox-prev { left: 0.75rem; }
.lightbox-next { right: 0.75rem; }

.lightbox-caption {
  position: absolute;
  bottom: calc(1rem + env(safe-area-inset-bottom, 0));
  left: 1rem;
  right: 1rem;
  margin: 0;
  text-align: center;
  color: rgba(255, 255, 255, 0.85);
  font-size: 0.95rem;
}

/* Respect reduced motion */
@media (prefers-reduced-motion: reduce) {
  .blob,
  .landing-bg::before,
  .landing-bg::after,
  .polaroid,
  .panel,
  .carousel-track {
    animation: none;
    transition: none;
  }
}
