/* ==============================================================================
   Di.Ar.De Studios - Premium WebGL Architectural Splash Screen Styles
   Engineered with React 19, Three.js, and GSAP
   Completely isolated & non-invasive (Zero impact on parent page styles/colors)
   ============================================================================== */

/* -----------------------------------------------------------------------------
   SPLASH SCREEN WRAPPER (100vw / 100vh)
----------------------------------------------------------------------------- */
.drd-splash-wrapper {
  --drd-splash-bg: #06080c;
  --drd-splash-gold: #FFC300;
  --drd-splash-gold-metal: #d4af37;
  --drd-splash-gold-glow: rgba(255, 195, 0, 0.45);
  --drd-splash-cyan: #00e5ff;
  --drd-splash-cyan-glow: rgba(0, 229, 255, 0.35);
  --drd-splash-text: #f0f3f8;
  --drd-splash-muted: #8892b0;
  --drd-splash-sans: 'Quicksand', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  --drd-splash-mono: 'SFMono-Regular', Consolas, 'Liberation Mono', Menlo, monospace;

  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  z-index: 999999;
  background-color: var(--drd-splash-bg);
  color: var(--drd-splash-text);
  font-family: var(--drd-splash-sans);
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  pointer-events: auto;
  user-select: none;
  transform-origin: center center;
  box-sizing: border-box;
}

.drd-splash-wrapper * {
  box-sizing: border-box;
}

/* Three.js Canvas Container */
.drd-splash-canvas-container {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: 1;
}

.drd-splash-canvas-container canvas {
  width: 100% !important;
  height: 100% !important;
  display: block;
  outline: none;
}

/* Vignette & Radial Edge Blur Layer */
.drd-splash-vignette {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: 2;
  pointer-events: none;
  background: radial-gradient(circle at center, transparent 35%, rgba(6, 8, 12, 0.7) 80%, rgba(6, 8, 12, 0.95) 100%);
  transition: opacity 0.5s ease;
}

/* Edge Motion Blur Overlay (Amplified during GSAP Zoom-Through) */
.drd-splash-blur-overlay {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: 3;
  pointer-events: none;
  opacity: 0;
  backdrop-filter: blur(0px);
  -webkit-backdrop-filter: blur(0px);
  background: radial-gradient(circle at center, transparent 20%, rgba(0, 229, 255, 0.08) 70%, rgba(255, 195, 0, 0.15) 100%);
  transition: backdrop-filter 0.3s ease, opacity 0.3s ease;
}

/* -----------------------------------------------------------------------------
   ARCHITECTURAL DRAWING SHEET FRAME & CAD TELEMETRY
----------------------------------------------------------------------------- */
.drd-splash-hud {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: 4;
  pointer-events: none;
  box-sizing: border-box;
  padding: 24px 28px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}

/* CAD Drafting Sheet Border */
.drd-splash-sheet-border {
  position: absolute;
  top: 14px;
  left: 14px;
  right: 14px;
  bottom: 14px;
  border: 1px solid rgba(255, 255, 255, 0.09);
  pointer-events: none;
  z-index: 3;
}

.drd-sheet-corner {
  position: absolute;
  width: 12px;
  height: 12px;
  border-color: rgba(255, 195, 0, 0.5);
}

.drd-sheet-corner.top-left {
  top: -1px;
  left: -1px;
  border-top: 2px solid #FFC300;
  border-left: 2px solid #FFC300;
}

.drd-sheet-corner.top-right {
  top: -1px;
  right: -1px;
  border-top: 2px solid #FFC300;
  border-right: 2px solid #FFC300;
}

.drd-sheet-corner.bottom-left {
  bottom: -1px;
  left: -1px;
  border-bottom: 2px solid #FFC300;
  border-left: 2px solid #FFC300;
}

.drd-sheet-corner.bottom-right {
  bottom: -1px;
  right: -1px;
  border-bottom: 2px solid #FFC300;
  border-right: 2px solid #FFC300;
}

.drd-hud-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  width: 100%;
}

.drd-hud-row.bottom-row {
  align-items: flex-end;
}

.drd-hud-item {
  font-family: var(--drd-splash-mono);
  font-size: 11px;
  letter-spacing: 1.2px;
  color: var(--drd-splash-muted);
  text-transform: uppercase;
  display: flex;
  align-items: center;
  gap: 10px;
}

.drd-hud-dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background-color: #FFC300;
  box-shadow: 0 0 8px rgba(255, 195, 0, 0.5);
  display: inline-block;
  animation: drd-pulse-glow 2.2s infinite ease-in-out;
}

.drd-hud-tag-pill {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: rgba(255, 195, 0, 0.08);
  border: 1px solid rgba(255, 195, 0, 0.25);
  color: #FFC300;
  padding: 3px 8px;
  border-radius: 3px;
  font-size: 10px;
  font-weight: 600;
  letter-spacing: 1px;
}

.drd-hud-skip-btn {
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.2);
  color: #f1f5f9;
  font-family: var(--drd-splash-mono);
  font-size: 10px;
  letter-spacing: 1.2px;
  text-transform: uppercase;
  padding: 7px 16px;
  border-radius: 4px;
  cursor: pointer;
  pointer-events: auto;
  transition: all 0.25s ease;
  line-height: 1.2;
}

.drd-hud-skip-btn:hover {
  background: #FFC300;
  color: #06080c;
  border-color: #FFC300;
  box-shadow: 0 0 14px rgba(255, 195, 0, 0.4);
}

/* Architectural Drawing Title Block (Bottom Right) */
.drd-arch-titleblock {
  background: rgba(11, 16, 26, 0.88);
  border: 1px solid rgba(255, 195, 0, 0.28);
  border-radius: 4px;
  padding: 12px 16px;
  display: flex;
  flex-direction: column;
  gap: 4px;
  min-width: 290px;
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.45);
}

.drd-titleblock-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
  padding-bottom: 6px;
  margin-bottom: 2px;
}

.drd-titleblock-studio {
  font-family: var(--drd-splash-sans);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 1.5px;
  color: #ffffff;
  text-transform: uppercase;
}

.drd-titleblock-stamp {
  font-family: var(--drd-splash-mono);
  font-size: 9px;
  color: #FFC300;
  border: 1px solid rgba(255, 195, 0, 0.4);
  padding: 1px 5px;
  border-radius: 2px;
  letter-spacing: 1px;
}

.drd-titleblock-row {
  display: flex;
  justify-content: space-between;
  font-family: var(--drd-splash-mono);
  font-size: 10px;
  color: #94a3b8;
  letter-spacing: 0.8px;
}

.drd-titleblock-row strong {
  color: #e2e8f0;
  font-weight: 500;
}

/* Architectural Viewport Coordinates (Bottom Left) */
.drd-arch-viewport-meta {
  display: flex;
  flex-direction: column;
  gap: 4px;
  background: rgba(11, 16, 26, 0.75);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 4px;
  padding: 10px 14px;
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
}

.drd-arch-viewport-meta span {
  font-family: var(--drd-splash-mono);
  font-size: 10px;
  letter-spacing: 1px;
  color: #8892b0;
  display: flex;
  align-items: center;
  gap: 6px;
}

.drd-arch-viewport-meta span strong {
  color: #FFC300;
}

/* -----------------------------------------------------------------------------
   CENTER TYPOGRAPHIC COUNTER & LOADER
----------------------------------------------------------------------------- */
.drd-splash-center-content {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  z-index: 5;
  text-align: center;
  pointer-events: none;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  width: 100%;
  max-width: 520px;
  padding: 0 20px;
}

/* Studio Branding Pill */
.drd-splash-brand-pill {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 6px 16px;
  border-radius: 30px;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.1);
  backdrop-filter: blur(8px);
  margin-bottom: 24px;
}

.drd-splash-brand-pill img {
  width: 18px;
  height: 18px;
  object-fit: contain;
}

.drd-splash-brand-pill span {
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 2px;
  text-transform: uppercase;
  color: #d1d8e6;
}

/* Minimalist Typographic Counter (0% to 100%) */
.drd-counter-wrapper {
  position: relative;
  margin-bottom: 20px;
}

.drd-counter-number {
  font-family: var(--drd-splash-sans);
  font-size: clamp(68px, 12vw, 110px);
  font-weight: 300;
  line-height: 1;
  letter-spacing: -2px;
  color: #ffffff;
  margin: 0;
  background: linear-gradient(180deg, #ffffff 20%, rgba(255, 255, 255, 0.8) 60%, var(--drd-splash-gold-metal) 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  text-shadow: 0 10px 40px rgba(0, 0, 0, 0.6);
  font-feature-settings: "tnum";
  font-variant-numeric: tabular-nums;
  display: flex;
  align-items: baseline;
  justify-content: center;
}

.drd-counter-percent {
  font-size: clamp(24px, 4vw, 36px);
  font-weight: 400;
  color: var(--drd-splash-gold);
  -webkit-text-fill-color: var(--drd-splash-gold);
  margin-left: 6px;
  letter-spacing: 0;
}

/* Sleek Horizontal Progress Line */
.drd-progress-track {
  width: 260px;
  height: 2px;
  background: rgba(255, 255, 255, 0.1);
  border-radius: 2px;
  overflow: hidden;
  position: relative;
  margin-bottom: 16px;
}

.drd-progress-bar {
  height: 100%;
  width: 0%;
  background: linear-gradient(90deg, var(--drd-splash-cyan), var(--drd-splash-gold));
  box-shadow: 0 0 14px var(--drd-splash-gold-glow);
  transition: width 0.15s cubic-bezier(0.16, 1, 0.3, 1);
}

/* Dynamic Asset Loading Status Ticker */
.drd-status-ticker {
  font-family: var(--drd-splash-mono);
  font-size: 11px;
  letter-spacing: 1.5px;
  color: var(--drd-splash-cyan);
  text-transform: uppercase;
  min-height: 16px;
  display: flex;
  align-items: center;
  gap: 8px;
}

.drd-status-spinner {
  display: inline-block;
  width: 10px;
  height: 10px;
  border: 1.5px solid rgba(0, 229, 255, 0.2);
  border-top-color: var(--drd-splash-cyan);
  border-radius: 50%;
  animation: drd-spin 0.8s linear infinite;
}

@keyframes drd-spin {
  to { transform: rotate(360deg); }
}

@media (max-width: 768px) {
  .drd-splash-hud {
    padding: 20px 24px;
  }
  .drd-hud-item:nth-child(2) {
    display: none;
  }
}
