/* ══════════════════════════════════════
   DEMOS — Project subtab iframe viewer
   ══════════════════════════════════════ */

/* Wrapper fills the subtab panel */
.pd-demo-wrap {
  display: flex;
  flex-direction: column;
  height: 100%;
  min-height: 400px;
}

.pd-demo-placeholder {
  display: flex;
  align-items: center;
  justify-content: center;
  height: 100%;
}

.pd-demo-viewer {
  display: flex;
  flex-direction: column;
  flex: 1;
  min-height: 0;
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 12px;
  overflow: hidden;
  background: rgba(10, 10, 12, 0.5);
}

/* Toolbar */
.demos-frame-toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 10px 20px;
  background: rgba(0, 0, 0, 0.35);
  border-bottom: 2px solid rgba(255, 255, 255, 0.15);
  flex-shrink: 0;
}

.demos-frame-title {
  font-family: "Electrolize", "Rajdhani", sans-serif;
  font-size: 1.15rem;
  color: var(--ll-off-white);
}

.demos-frame-actions {
  display: flex;
  align-items: center;
  gap: 6px;
}

.demos-device-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 34px;
  height: 34px;
  border-radius: 8px;
  border: 1px solid rgba(255, 255, 255, 0.1);
  background: rgba(255, 255, 255, 0.04);
  color: rgba(255, 255, 255, 0.4);
  cursor: pointer;
  transition: all 0.2s;
}

.demos-device-btn .material-symbols-outlined {
  font-size: 18px;
}

.demos-device-btn:hover {
  background: rgba(255, 255, 255, 0.08);
  color: rgba(255, 255, 255, 0.7);
}

.demos-device-btn--active {
  background: rgba(255, 180, 0, 0.12);
  border-color: rgba(255, 180, 0, 0.3);
  color: var(--ll-gold);
}

.demos-open-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 34px;
  height: 34px;
  border-radius: 8px;
  border: 1px solid rgba(255, 255, 255, 0.1);
  background: rgba(255, 255, 255, 0.04);
  color: rgba(255, 255, 255, 0.4);
  text-decoration: none;
  margin-left: 6px;
  transition: all 0.2s;
}

.demos-open-btn .material-symbols-outlined {
  font-size: 18px;
}

.demos-open-btn:hover {
  background: rgba(255, 255, 255, 0.08);
  color: rgba(255, 255, 255, 0.7);
  text-decoration: none;
}

/* iframe container — responsive sizing */
.demos-frame-container {
  flex: 1;
  display: flex;
  align-items: flex-start;
  justify-content: center;
  padding: 16px;
  overflow: auto;
  background:
    repeating-conic-gradient(rgba(255,255,255,0.02) 0% 25%, transparent 0% 50%)
    50% / 20px 20px;
}

.demos-iframe {
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 10px;
  background: #fff;
  box-shadow: 0 8px 40px rgba(0, 0, 0, 0.4);
  transition: width 0.3s ease, height 0.3s ease;
}

/* Device presets */
.demos-iframe--desktop {
  width: 100%;
  height: 100%;
  border-radius: 10px;
}

.demos-iframe--tablet {
  width: 768px;
  height: 100%;
  border-radius: 12px;
}

.demos-iframe--mobile {
  width: 375px;
  height: 100%;
  border-radius: 20px;
}

@media (max-width: 768px) {
  .pd-demo-wrap {
    min-height: 300px;
  }
  .demos-frame-container {
    padding: 4px;
    flex: 1;
    min-height: 0;
  }
  .demos-iframe,
  .demos-iframe--desktop,
  .demos-iframe--tablet,
  .demos-iframe--mobile {
    width: 100% !important;
    height: 100% !important;
    border-radius: 6px;
  }
}

/* Toast for mobile device-switch hint */
.demos-toast {
  position: fixed;
  bottom: 28px;
  left: 50%;
  transform: translateX(-50%) translateY(20px);
  background: rgba(10, 10, 14, 0.92);
  border: 1px solid rgba(255, 180, 0, 0.25);
  color: var(--ll-off-white);
  font-family: "Share Tech Mono", monospace;
  font-size: 0.88rem;
  padding: 12px 22px;
  border-radius: 12px;
  backdrop-filter: blur(16px);
  box-shadow: 0 6px 24px rgba(0, 0, 0, 0.5);
  opacity: 0;
  pointer-events: none;
  z-index: 600;
  text-align: center;
  max-width: 90vw;
  transition: opacity 0.3s, transform 0.3s;
}

.demos-toast--visible {
  opacity: 1;
  transform: translateX(-50%) translateY(0);
}
