/* =========================================================
   Wilson Family — Homepage
   ========================================================= */

/* Decorative gradient blobs */
.home-bg {
  position: fixed;
  inset: 0;
  pointer-events: none;
  overflow: hidden;
  z-index: 0;
}
.orb {
  position: absolute;
  border-radius: 50%;
  filter: blur(100px);
}
.orb-gold {
  width: 500px; height: 500px;
  background: var(--accent);
  top: -180px; right: -120px;
  opacity: 0.12;
}
.orb-green {
  width: 600px; height: 600px;
  background: var(--primary);
  bottom: -250px; left: -200px;
  opacity: 0.08;
}
.orb-rose {
  width: 350px; height: 350px;
  background: var(--rose);
  top: 50%; left: 50%;
  opacity: 0.04;
}

/* Header */
.home-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 20px 32px;
  position: relative;
  z-index: 2;
}

/* Hero */
.home-main {
  position: relative;
  z-index: 1;
  max-width: 1100px;
  margin: 0 auto;
  padding: 0 24px 96px;
}

.hero {
  text-align: center;
  padding: 60px 24px 80px;
  animation: rise 0.6s ease-out both;
}

.hero-photo-wrap {
  position: relative;
  width: 100%;
  max-width: 600px;
  margin: 0 auto 32px;
  border-radius: 28px;
  overflow: hidden;
  aspect-ratio: 16 / 9;
}
.hero-photo {
  width: 100%;
  height: 100%;
  display: block;
  object-fit: cover;
  object-position: center 30%;
}
/* Subtle vignette on edges */
.hero-photo-wrap::after {
  content: '';
  position: absolute;
  inset: 0;
  border-radius: 28px;
  background:
    radial-gradient(ellipse at center, transparent 60%, var(--bg) 100%);
  pointer-events: none;
}
/* Light bottom fade */
.hero-photo-wrap::before {
  content: '';
  position: absolute;
  bottom: 0; left: 0; right: 0;
  height: 25%;
  background: linear-gradient(to top, var(--bg) 0%, transparent 100%);
  z-index: 1;
  pointer-events: none;
  border-radius: 0 0 28px 28px;
}

.hero-title {
  font-size: clamp(56px, 10vw, 112px);
  font-weight: 800;
  margin: 12px 0 24px;
  letter-spacing: -0.04em;
  line-height: 1;
  background: linear-gradient(135deg, var(--ink) 0%, var(--primary) 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}
.hero-title em {
  font-style: italic;
}

.hero-sub {
  color: var(--ink-soft);
  font-size: clamp(15px, 2vw, 18px);
  line-height: 1.7;
  font-weight: 400;
  max-width: 520px;
  margin: 0 auto;
}

/* Section heading */
.section-heading {
  font-size: 13px;
  font-family: var(--font-body);
  font-weight: 700;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--ink-soft);
  margin-bottom: 28px;
  text-align: center;
  position: relative;
}
.section-heading::before,
.section-heading::after {
  content: '';
  display: inline-block;
  width: 40px;
  height: 1px;
  background: var(--rule);
  vertical-align: middle;
  margin: 0 16px;
}

/* Auth section */
.auth-section {
  max-width: 460px;
  margin: 0 auto 64px;
  animation: rise 0.6s ease-out both;
}
.auth-tabs {
  display: flex;
  background: var(--surface);
  border: 1px solid var(--rule);
  border-radius: 12px;
  padding: 4px;
  margin-bottom: 20px;
  box-shadow: var(--shadow-sm);
}
.auth-tab {
  flex: 1;
  padding: 10px 16px;
  border: none;
  background: none;
  font-family: var(--font-body);
  font-size: 14px;
  font-weight: 600;
  color: var(--ink-soft);
  cursor: pointer;
  border-radius: 8px;
  transition: all 0.15s ease;
}
.auth-tab:hover { color: var(--ink); }
.auth-tab.active {
  background: var(--primary);
  color: white;
  box-shadow: var(--shadow-sm);
}
.auth-card {
  background: var(--surface);
  border: 1px solid var(--rule);
  border-radius: var(--radius-lg);
  padding: 36px 32px 32px;
  box-shadow: var(--shadow-lg);
  text-align: center;
}
.join-title {
  font-size: 28px;
  font-weight: 800;
  margin: 12px 0 28px;
  letter-spacing: -0.02em;
}
.join-title em { color: var(--primary); }

.join-form {
  display: flex;
  flex-direction: column;
  gap: 16px;
  text-align: left;
}
.join-form label {
  display: flex;
  flex-direction: column;
  gap: 6px;
}
.join-form label > span {
  font-size: 13px;
  font-weight: 600;
  color: var(--ink-soft);
}
.join-form input {
  background: var(--bg);
  border: 1.5px solid var(--rule);
  border-radius: 10px;
  padding: 12px 14px;
  font-family: var(--font-body);
  font-size: 15px;
  color: var(--ink);
  transition: all 0.15s ease;
}
.join-form input:focus {
  outline: none;
  border-color: var(--primary);
  background: white;
  box-shadow: 0 0 0 3px var(--primary-light);
}
.join-form .btn-primary { margin-top: 8px; }

.join-error {
  color: var(--rose);
  font-size: 14px;
  font-weight: 500;
  margin: -4px 0;
  text-align: center;
}
.join-success {
  color: var(--emerald);
  font-size: 14px;
  font-weight: 600;
  margin: -4px 0;
  text-align: center;
}

/* Rooms grid */
.room-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 20px;
}

.room {
  background: var(--surface);
  border-radius: var(--radius-lg);
  padding: 32px 28px 28px;
  border: 1px solid var(--rule);
  position: relative;
  overflow: hidden;
  transition: all 0.25s ease;
  text-decoration: none;
  display: flex;
  flex-direction: column;
  min-height: 260px;
  animation: rise 0.5s ease-out both;
}
.room:nth-child(2) { animation-delay: 0.05s; }
.room:nth-child(3) { animation-delay: 0.1s; }
.room:nth-child(4) { animation-delay: 0.15s; }
.room:nth-child(5) { animation-delay: 0.2s; }
.room:nth-child(6) { animation-delay: 0.25s; }

.room-live {
  cursor: pointer;
}
.room-live::before {
  content: '';
  position: absolute;
  top: 0; left: 0; right: 0;
  height: 3px;
  background: linear-gradient(90deg, var(--primary) 0%, var(--accent) 100%);
}
.room-live:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-lg);
  border-color: var(--primary);
  text-decoration: none;
}

.room-soon {
  opacity: 0.55;
}
.room-soon .room-icon { filter: grayscale(0.3); }

.room-admin {
  border-color: rgba(109, 92, 255, 0.2);
}
.room-admin::before {
  background: linear-gradient(90deg, var(--primary) 0%, var(--emerald) 100%);
}
.room-admin .room-status { color: var(--primary); }

.room-icon {
  font-size: 36px;
  margin-bottom: 14px;
  line-height: 1;
}

.room-status {
  font-family: var(--font-body);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--primary);
  margin-bottom: 10px;
}
.room-soon .room-status { color: var(--ink-soft); }

.room-title {
  font-size: 22px;
  font-weight: 700;
  margin-bottom: 8px;
  letter-spacing: -0.015em;
  color: var(--ink);
}

.room-text {
  color: var(--ink-soft);
  font-size: 14px;
  line-height: 1.6;
  margin-bottom: 16px;
  flex-grow: 1;
}

.room-cta {
  font-family: var(--font-display);
  font-size: 14px;
  font-weight: 600;
  color: var(--primary);
  margin-top: auto;
}
.room-soon .room-cta {
  color: var(--ink-soft);
  opacity: 0.5;
}

/* Footer / verse */
.home-footer {
  margin-top: 80px;
  padding: 40px 24px;
  text-align: center;
  border-top: 1px solid var(--rule);
}
.verse {
  font-family: var(--font-display);
  font-size: 20px;
  font-style: italic;
  font-weight: 500;
  color: var(--ink);
  line-height: 1.5;
  max-width: 520px;
  margin: 0 auto;
}
.verse-cite {
  display: block;
  margin-top: 10px;
  font-size: 11px;
  font-style: normal;
  font-family: var(--font-body);
  font-weight: 700;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--primary);
}

@media (max-width: 720px) {
  .home-header { padding: 16px 20px; flex-wrap: wrap; gap: 12px; }
  .home-main { padding: 0 16px 64px; }
  .hero { padding: 40px 16px 56px; }
  .hero-title { margin: 8px 0 20px; }
  .room { padding: 24px 20px 20px; min-height: 220px; }
  .room-title { font-size: 20px; }
  .home-footer { margin-top: 56px; padding: 28px 16px; }
  .verse { font-size: 17px; }
}
