/* Homepage action buttons + overlays (Photos / Movie / Chat) */

.home-actions {
  display: flex;
  flex-direction: column;
  align-items: stretch;
  gap: 14px;
  width: min(100%, 420px);
  margin: 0 auto;
  animation: fadeInUp 1s ease-out 0.35s both;
}

.home-action-btn {
  appearance: none;
  -webkit-appearance: none;
  display: grid;
  grid-template-columns: 52px 1fr;
  align-items: center;
  gap: 14px;
  width: 100%;
  padding: 14px 16px;
  border-radius: 10px;
  border: 2px solid rgba(212, 165, 116, 0.75);
  background: rgba(255, 255, 255, 0.42);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  box-shadow: 0 4px 18px rgba(0, 0, 0, 0.12);
  color: #1a1a1a;
  cursor: pointer;
  text-align: left;
  transition: transform 0.25s ease, box-shadow 0.25s ease, background 0.25s ease, border-color 0.25s ease;
}

.home-action-btn:hover,
.home-action-btn:focus-visible {
  transform: translateY(-3px);
  background: rgba(255, 255, 255, 0.58);
  border-color: rgba(212, 165, 116, 1);
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.18);
  outline: none;
}

.home-action-btn:active {
  transform: translateY(-1px) scale(0.99);
}

.home-action-icon {
  width: 52px;
  height: 52px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  background: linear-gradient(145deg, rgba(212, 165, 116, 0.95), rgba(184, 140, 80, 0.95));
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.35), 0 2px 8px rgba(0, 0, 0, 0.15);
  color: #fff;
  flex-shrink: 0;
}

.home-action-icon svg {
  width: 26px;
  height: 26px;
  display: block;
}

.home-action-labels {
  display: flex;
  align-items: center;
  min-width: 0;
}

.home-action-label {
  font-family: 'Playfair Display', serif;
  font-weight: 700;
  font-size: clamp(1.15rem, 4vw, 1.45rem);
  letter-spacing: 0.02em;
  color: #111;
  text-shadow: 0 1px 2px rgba(255, 255, 255, 0.45);
  line-height: 1.2;
}

/* Overlays */
.home-overlay[hidden] {
  display: none !important;
}

.home-overlay {
  position: fixed;
  inset: 0;
  z-index: 10040;
  display: flex;
  align-items: flex-end;
  justify-content: center;
  padding: max(12px, env(safe-area-inset-top)) 12px max(12px, env(safe-area-inset-bottom));
  background: rgba(20, 16, 12, 0.55);
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
  animation: homeOverlayIn 0.28s ease both;
}

@keyframes homeOverlayIn {
  from { opacity: 0; }
  to { opacity: 1; }
}

.home-overlay-dialog {
  width: min(100%, 560px);
  max-height: min(92vh, 820px);
  overflow: auto;
  -webkit-overflow-scrolling: touch;
  border-radius: 14px;
  border: 2px solid rgba(212, 165, 116, 0.85);
  background: linear-gradient(180deg, #fffdf8 0%, #f7f1e6 100%);
  box-shadow: 0 18px 50px rgba(0, 0, 0, 0.35);
  padding: 18px 16px 16px;
  position: relative;
  animation: homeDialogIn 0.32s cubic-bezier(0.22, 1, 0.36, 1) both;
}

@keyframes homeDialogIn {
  from { opacity: 0; transform: translateY(24px) scale(0.98); }
  to { opacity: 1; transform: translateY(0) scale(1); }
}

.home-overlay-close {
  position: absolute;
  top: 10px;
  right: 10px;
  width: 40px;
  height: 40px;
  border: none;
  border-radius: 50%;
  background: rgba(212, 165, 116, 0.2);
  color: #3b2d04;
  font-size: 1.4rem;
  line-height: 1;
  cursor: pointer;
  display: grid;
  place-items: center;
}

.home-overlay-close:hover,
.home-overlay-close:focus-visible {
  background: rgba(212, 165, 116, 0.4);
  outline: none;
}

.home-overlay-title {
  font-family: 'Great Vibes', 'Dancing Script', cursive;
  font-size: clamp(2rem, 7vw, 2.6rem);
  color: #d4a574;
  text-align: center;
  margin: 4px 28px 12px;
  line-height: 1.1;
}

.home-overlay-message {
  font-family: 'Playfair Display', serif;
  font-size: clamp(1rem, 3.4vw, 1.2rem);
  color: #3b2d04;
  text-align: center;
  line-height: 1.55;
  margin: 0 8px 10px;
}

/* Movie */
.movie-lang-row {
  display: flex;
  gap: 8px;
  justify-content: center;
  flex-wrap: wrap;
  margin: 8px 0 14px;
}

.movie-lang-btn {
  appearance: none;
  border: 2px solid rgba(212, 165, 116, 0.55);
  background: rgba(255, 255, 255, 0.7);
  color: #3b2d04;
  font-family: 'Playfair Display', serif;
  font-size: 0.92rem;
  font-weight: 600;
  padding: 8px 14px;
  border-radius: 999px;
  cursor: pointer;
  transition: background 0.2s, border-color 0.2s, transform 0.15s;
}

.movie-lang-btn[aria-pressed="true"],
.movie-lang-btn.is-active {
  background: linear-gradient(135deg, #d4a574, #c49660);
  border-color: #c49660;
  color: #fff;
}

.movie-lang-btn:hover {
  transform: translateY(-1px);
}

.movie-player-shell {
  position: relative;
  width: 100%;
  aspect-ratio: 16 / 9;
  border-radius: 10px;
  overflow: hidden;
  background: #1a1510;
  border: 1px solid rgba(212, 165, 116, 0.45);
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.04);
}

.movie-player-shell video,
.movie-player-shell iframe {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  border: 0;
  background: #000;
}

.movie-player-shell video {
  object-fit: contain;
}

.movie-status {
  margin-top: 10px;
  text-align: center;
  font-family: 'Playfair Display', serif;
  font-size: 0.95rem;
  color: #5a4630;
  min-height: 1.3em;
}

.movie-status.is-error {
  color: #a33;
}

/* Chat panel height on homepage */
.home-chat-panel .home-overlay-dialog {
  width: min(100%, 640px);
  padding-bottom: 12px;
}

.home-chat-panel .chat-section {
  margin-top: 0;
}

body.home-overlay-open {
  overflow: hidden;
}

@media (min-width: 640px) {
  .home-overlay {
    align-items: center;
  }

  .home-actions {
    width: min(100%, 480px);
    gap: 16px;
  }

  .home-action-btn {
    padding: 16px 18px;
  }
}

@media (max-width: 380px) {
  .home-action-btn {
    grid-template-columns: 46px 1fr;
    gap: 10px;
    padding: 12px 12px;
  }

  .home-action-icon {
    width: 46px;
    height: 46px;
  }

  .home-action-icon svg {
    width: 22px;
    height: 22px;
  }
}
