/* ==========================================================================
   CrystalDFW.com - 3D Clear Glass Window & Flying Winged Sticky Notes
   Gold Standard Aesthetic: Fortnite / Unreal Engine 5 AAA Game Fidelity
   ========================================================================== */

#glass-reviews-overlay {
  position: fixed;
  inset: 0;
  z-index: 99999;
  width: 100vw;
  height: 100vh;
  overflow: hidden;
  background-color: #0b1320;
  background-image: 
    radial-gradient(ellipse at 80% 25%, rgba(251, 191, 36, 0.28) 0%, transparent 55%),
    linear-gradient(180deg, rgba(15, 23, 42, 0.15) 0%, rgba(15, 23, 42, 0.45) 100%),
    url('/assets/images/custom/dfw-sunset-penthouse-bg.jpg');
  background-position: center center;
  background-size: cover;
  background-repeat: no-repeat;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  opacity: 1;
  visibility: visible;
  transition: opacity 0.75s cubic-bezier(0.16, 1, 0.3, 1), visibility 0.75s ease;
  user-select: none;
  -webkit-user-select: none;
}

body.welcome-active { overflow: hidden; }

.crystal-welcome iframe {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  border: 0;
}

.crystal-welcome > .glass-enter-btn {
  position: absolute;
  z-index: 4;
  top: 22px;
  right: 22px;
  min-height: 44px;
  padding: 10px 18px;
  font-size: .88rem;
  background: rgba(10, 24, 16, .74);
  backdrop-filter: blur(10px);
}

#glass-reviews-overlay.is-dismissed {
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
}

/* Penthouse Architectural Window Frame & Metallic Mullions */
.glass-window-frame {
  position: absolute;
  inset: 0;
  pointer-events: none;
  z-index: 2;
  box-shadow: inset 0 0 120px rgba(0, 0, 0, 0.65),
              inset 0 0 40px rgba(251, 191, 36, 0.15);
  border: 14px solid #1a222d;
  outline: 2px solid rgba(255, 255, 255, 0.12);
  outline-offset: -14px;
}

@media (min-width: 900px) {
  .glass-window-frame::before {
    content: '';
    position: absolute;
    top: 0;
    bottom: 0;
    left: 33.333%;
    width: 10px;
    background: linear-gradient(90deg, #151c24 0%, #2a3441 50%, #0d131a 100%);
    box-shadow: 0 0 16px rgba(0, 0, 0, 0.6), inset 1px 0 0 rgba(255, 255, 255, 0.2);
  }
  .glass-window-frame::after {
    content: '';
    position: absolute;
    top: 0;
    bottom: 0;
    left: 66.666%;
    width: 10px;
    background: linear-gradient(90deg, #151c24 0%, #2a3441 50%, #0d131a 100%);
    box-shadow: 0 0 16px rgba(0, 0, 0, 0.6), inset 1px 0 0 rgba(255, 255, 255, 0.2);
  }
}

/* Glass Refractive Sheen & Sunset Glare */
.glass-glare-layer {
  position: absolute;
  inset: 0;
  pointer-events: none;
  z-index: 3;
  background: 
    linear-gradient(125deg, rgba(255, 255, 255, 0.22) 0%, rgba(255, 255, 255, 0.04) 24%, transparent 48%, rgba(255, 255, 255, 0.06) 78%, rgba(255, 255, 255, 0.16) 100%),
    radial-gradient(ellipse at 82% 18%, rgba(253, 230, 138, 0.35) 0%, rgba(245, 158, 11, 0.12) 35%, transparent 65%);
  mix-blend-mode: screen;
}

/* Three.js 3D WebGL Canvas */
#glass-webgl-canvas {
  position: absolute;
  inset: 0;
  width: 100% !important;
  height: 100% !important;
  z-index: 1;
  display: block;
}

/* HUD Top Bar */
.glass-hud-top {
  position: relative;
  z-index: 10;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 18px 28px;
  gap: 16px;
  flex-wrap: wrap;
}

.glass-hud-left {
  display: inline-flex;
  align-items: center;
  gap: 10px;
}

.glass-brand-pill {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  padding: 10px 24px;
  border-radius: 999px;
  background: rgba(15, 23, 42, 0.6);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border: 1px solid rgba(255, 255, 255, 0.28);
  box-shadow: 0 12px 36px rgba(0, 0, 0, 0.4), inset 0 1px 1px rgba(255, 255, 255, 0.45);
  color: #ffffff;
  font-family: 'Antonio', 'Archivo Narrow', sans-serif;
  font-size: 1.22rem;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  text-shadow: 0 2px 8px rgba(0, 0, 0, 0.5);
}

.glass-brand-pill .stars-glow {
  color: #fbbf24;
  letter-spacing: 3px;
  font-size: 1.05rem;
  text-shadow: 0 0 14px rgba(251, 191, 36, 0.95);
}

.glass-hud-center {
  display: inline-flex;
  align-items: center;
  gap: 10px;
}

.glass-pill-badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 8px 20px;
  border-radius: 999px;
  background: rgba(15, 23, 42, 0.65);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border: 1px solid rgba(255, 255, 255, 0.22);
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.35);
  color: #f8fafc;
  font-family: 'Archivo Narrow', sans-serif;
  font-size: 0.98rem;
  font-weight: 700;
  letter-spacing: 0.02em;
}

.glass-hud-actions {
  display: inline-flex;
  align-items: center;
  gap: 10px;
}

.glass-btn-icon {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: rgba(15, 23, 42, 0.6);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border: 1px solid rgba(255, 255, 255, 0.25);
  color: #ffffff;
  font-size: 1.15rem;
  cursor: pointer;
  transition: all 0.22s cubic-bezier(0.16, 1, 0.3, 1);
  box-shadow: 0 6px 18px rgba(0, 0, 0, 0.35);
}

.glass-btn-icon:hover {
  background: rgba(255, 255, 255, 0.25);
  transform: translateY(-2px) scale(1.08);
  box-shadow: 0 8px 26px rgba(255, 255, 255, 0.3);
}

.glass-btn-icon:active {
  transform: scale(0.95);
}

/* Filter Group */
.glass-filter-group {
  display: inline-flex;
  background: rgba(0, 0, 0, 0.5);
  padding: 4px;
  border-radius: 999px;
  border: 1px solid rgba(255, 255, 255, 0.18);
  backdrop-filter: blur(12px);
}

.glass-filter-btn {
  padding: 6px 14px;
  border-radius: 999px;
  background: transparent;
  border: none;
  color: rgba(255, 255, 255, 0.78);
  font-family: 'Archivo Narrow', sans-serif;
  font-size: 0.9rem;
  font-weight: 700;
  cursor: pointer;
  transition: all 0.2s ease;
}

.glass-filter-btn.is-active,
.glass-filter-btn:hover {
  background: rgba(255, 255, 255, 0.28);
  color: #ffffff;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.3);
}

/* Floating "Peel & Read" Visual Annotations (Matching Gold Standard Mockup 3) */
.glass-callout-annotation {
  position: absolute;
  z-index: 8;
  display: inline-flex;
  flex-direction: column;
  align-items: center;
  pointer-events: none;
  opacity: 0;
  transform: translateY(10px);
  transition: opacity 0.8s ease 1.5s, transform 0.8s ease 1.5s;
}

.glass-callout-annotation.is-visible {
  opacity: 1;
  transform: translateY(0);
}

.glass-callout-badge {
  padding: 6px 16px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.92);
  color: #1e293b;
  font-family: 'Archivo Narrow', sans-serif;
  font-size: 0.88rem;
  font-weight: 700;
  box-shadow: 0 6px 20px rgba(0, 0, 0, 0.35);
  border: 1px solid rgba(0, 0, 0, 0.08);
}

.glass-callout-arrow {
  width: 24px;
  height: 24px;
  stroke: #ffffff;
  stroke-width: 2.5;
  fill: none;
  filter: drop-shadow(0 2px 4px rgba(0,0,0,0.5));
}

/* Bottom Controls */
.glass-hud-bottom {
  position: relative;
  z-index: 10;
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 20px 28px 32px;
  gap: 14px;
}

.glass-hint-text {
  color: #ffffff;
  font-family: 'Archivo Narrow', sans-serif;
  font-size: 1rem;
  font-weight: 700;
  letter-spacing: 0.02em;
  text-shadow: 0 2px 8px rgba(0, 0, 0, 0.8);
  display: inline-flex;
  align-items: center;
  gap: 8px;
  animation: pulseGlow 2.5s infinite ease-in-out;
}

@keyframes pulseGlow {
  0%, 100% { opacity: 0.85; transform: scale(1); }
  50% { opacity: 1; transform: scale(1.03); }
}

.glass-enter-btn {
  display: inline-flex;
  align-items: center;
  gap: 14px;
  padding: 16px 42px;
  border-radius: 999px;
  background: linear-gradient(135deg, #0284c7 0%, #0369a1 50%, #075985 100%);
  border: 1.5px solid rgba(255, 255, 255, 0.5);
  color: #ffffff;
  font-family: 'Antonio', 'Archivo Narrow', sans-serif;
  font-size: 1.35rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  font-weight: 700;
  cursor: pointer;
  box-shadow: 0 12px 36px rgba(2, 132, 199, 0.55), 0 0 35px rgba(56, 189, 248, 0.5), inset 0 1px 2px rgba(255, 255, 255, 0.7);
  transition: all 0.28s cubic-bezier(0.16, 1, 0.3, 1);
  text-decoration: none;
}

.glass-enter-btn:hover {
  transform: translateY(-3px) scale(1.04);
  box-shadow: 0 16px 48px rgba(2, 132, 199, 0.75), 0 0 45px rgba(56, 189, 248, 0.7);
  background: linear-gradient(135deg, #38bdf8 0%, #0284c7 50%, #0369a1 100%);
}

.glass-enter-btn:active {
  transform: scale(0.97);
}

/* Modal Reader Card */
#glass-review-modal {
  position: fixed;
  inset: 0;
  z-index: 100000;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
  background: rgba(15, 23, 42, 0.8);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  opacity: 0;
  visibility: hidden;
  transition: all 0.32s cubic-bezier(0.16, 1, 0.3, 1);
}

#glass-review-modal.is-open {
  opacity: 1;
  visibility: visible;
}

.glass-modal-card {
  position: relative;
  width: 100%;
  max-width: 560px;
  border-radius: 28px;
  background: linear-gradient(145deg, rgba(255, 255, 255, 0.98) 0%, rgba(254, 249, 231, 0.98) 100%);
  padding: 36px 34px 30px;
  box-shadow: 0 30px 70px rgba(0, 0, 0, 0.5), 0 0 50px rgba(251, 191, 36, 0.4);
  border: 2px solid rgba(255, 255, 255, 0.9);
  transform: translateY(20px) scale(0.95);
  transition: all 0.35s cubic-bezier(0.16, 1, 0.3, 1);
  color: #1e293b;
}

#glass-review-modal.is-open .glass-modal-card {
  transform: translateY(0) scale(1);
}

.glass-modal-close {
  position: absolute;
  top: 20px;
  right: 20px;
  width: 38px;
  height: 38px;
  border-radius: 50%;
  background: rgba(0, 0, 0, 0.07);
  border: none;
  font-size: 1.3rem;
  color: #475569;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.2s ease;
}

.glass-modal-close:hover {
  background: rgba(0, 0, 0, 0.15);
  color: #0f172a;
  transform: rotate(90deg);
}

.glass-modal-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 18px;
}

.glass-modal-source {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 7px 16px;
  border-radius: 999px;
  font-weight: 700;
  font-size: 0.92rem;
  font-family: 'Archivo Narrow', sans-serif;
  letter-spacing: 0.03em;
}

.glass-modal-source.is-google {
  background: #e8f0fe;
  color: #1a73e8;
}

.glass-modal-source.is-zillow {
  background: #e0f2fe;
  color: #0284c7;
}

.glass-modal-stars {
  color: #f59e0b;
  font-size: 1.4rem;
  letter-spacing: 3px;
}

.glass-modal-quote {
  font-family: 'Archivo Narrow', sans-serif;
  font-size: 1.25rem;
  line-height: 1.5;
  font-weight: 600;
  color: #1e293b;
  margin-bottom: 22px;
  font-style: italic;
}

.glass-modal-author-wrap {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-top: 18px;
  border-top: 1px solid rgba(0, 0, 0, 0.08);
  margin-bottom: 22px;
}

.glass-modal-name {
  font-weight: 700;
  font-size: 1.1rem;
  color: #0f172a;
}

.glass-modal-tag {
  font-size: 0.9rem;
  color: #64748b;
  font-weight: 600;
}

.glass-modal-actions {
  display: flex;
  gap: 14px;
}

.glass-modal-btn-primary {
  flex: 1;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 14px 20px;
  border-radius: 14px;
  background: #314f3d;
  color: #ffffff;
  font-family: 'Archivo Narrow', sans-serif;
  font-weight: 700;
  font-size: 1rem;
  text-decoration: none;
  transition: all 0.2s ease;
  text-align: center;
}

.glass-modal-btn-primary:hover {
  background: #1f3327;
  transform: translateY(-2px);
  box-shadow: 0 6px 18px rgba(49, 79, 61, 0.35);
}

.glass-modal-btn-secondary {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 14px 20px;
  border-radius: 14px;
  background: rgba(0, 0, 0, 0.06);
  color: #334155;
  font-family: 'Archivo Narrow', sans-serif;
  font-weight: 700;
  font-size: 1rem;
  text-decoration: none;
  transition: all 0.2s ease;
}

.glass-modal-btn-secondary:hover {
  background: rgba(0, 0, 0, 0.12);
  color: #0f172a;
}

/* Floating Badge to Re-open Glass Experience from Main Site */
.glass-reopen-trigger {
  position: fixed;
  bottom: 24px;
  right: 24px;
  z-index: 9999;
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 12px 24px;
  border-radius: 999px;
  background: linear-gradient(135deg, #0284c7 0%, #314f3d 100%);
  border: 1px solid rgba(255, 255, 255, 0.35);
  color: #ffffff;
  font-family: 'Antonio', 'Archivo Narrow', sans-serif;
  font-size: 1.1rem;
  letter-spacing: 0.04em;
  font-weight: 700;
  cursor: pointer;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.35), 0 0 24px rgba(56, 189, 248, 0.4);
  transition: all 0.25s cubic-bezier(0.16, 1, 0.3, 1);
  opacity: 0;
  transform: translateY(20px);
  pointer-events: none;
}

.glass-reopen-trigger.is-visible {
  opacity: 1;
  transform: translateY(0);
  pointer-events: auto;
}

.glass-reopen-trigger:hover {
  transform: translateY(-3px) scale(1.05);
  box-shadow: 0 14px 40px rgba(0, 0, 0, 0.45), 0 0 32px rgba(56, 189, 248, 0.6);
}

/* Mobile Adjustments */
@media (max-width: 640px) {
  .glass-hud-top {
    padding: 12px 14px;
  }
  .glass-brand-pill {
    font-size: 0.95rem;
    padding: 6px 14px;
  }
  .glass-pill-badge {
    font-size: 0.82rem;
    padding: 5px 12px;
  }
  .glass-enter-btn {
    font-size: 1.15rem;
    padding: 14px 28px;
    width: 92%;
    justify-content: center;
  }
  .crystal-welcome > .glass-enter-btn {
    width: auto;
    max-width: calc(100% - 32px);
    top: 16px;
    right: 16px;
    padding: 10px 16px;
    font-size: .78rem;
  }
  .glass-modal-card {
    padding: 24px 20px 20px;
  }
  .glass-modal-quote {
    font-size: 1.08rem;
  }
}
