/* ==========================================================================
   iDominiqe Spatial OS v3 — VisionOS Smoked-Glass Single-Screen Dashboard
   Reference: Detached Address Bar + Left Pill Dock + Frosted Tiles + Weather
   ========================================================================== */

:root {
  --font-sans: "Plus Jakarta Sans", "Inter", system-ui, -apple-system, sans-serif;
  --font-display: "Space Grotesk", "Plus Jakarta Sans", system-ui, sans-serif;
  --font-mono: "JetBrains Mono", monospace;

  /* Vision Loft (Default — Warm Neutral Smoked Glass) */
  --room-bg:
    radial-gradient(62% 85% at 72% 38%, rgba(235, 224, 210, 0.72), transparent 62%),
    radial-gradient(48% 60% at 18% 72%, rgba(112, 108, 104, 0.55), transparent 65%),
    radial-gradient(40% 55% at 88% 82%, rgba(120, 114, 108, 0.62), transparent 65%),
    linear-gradient(125deg, #7f7b77 0%, #aba6a0 45%, #c9c3bb 74%, #8d8882 100%);

  --glass-shell: rgba(68, 66, 65, 0.44);
  --glass-pill: rgba(74, 72, 70, 0.48);
  --glass-tile: rgba(255, 255, 255, 0.08);
  --glass-tile-hover: rgba(255, 255, 255, 0.14);
  --glass-input: rgba(0, 0, 0, 0.24);
  --glass-border: rgba(255, 255, 255, 0.28);
  --glass-border-soft: rgba(255, 255, 255, 0.16);
  --glass-highlight: rgba(255, 255, 255, 0.52);

  --ink-1: #ffffff;
  --ink-2: rgba(255, 255, 255, 0.78);
  --ink-3: rgba(255, 255, 255, 0.56);
  --blur-strength: 32px;
  --shell-shadow: 0 32px 84px -18px rgba(0, 0, 0, 0.52);
}

html[data-vtheme="obsidian"] {
  --room-bg:
    radial-gradient(60% 70% at 22% 20%, rgba(56, 189, 248, 0.16), transparent 60%),
    radial-gradient(50% 60% at 80% 75%, rgba(139, 92, 246, 0.18), transparent 60%),
    linear-gradient(135deg, #090b12 0%, #141824 55%, #0a0c14 100%);
  --glass-shell: rgba(22, 26, 38, 0.62);
  --glass-pill: rgba(26, 30, 44, 0.72);
  --glass-tile: rgba(255, 255, 255, 0.06);
}

html[data-vtheme="aurora"] {
  --room-bg:
    radial-gradient(55% 75% at 20% 25%, rgba(139, 92, 246, 0.42), transparent 60%),
    radial-gradient(55% 75% at 80% 30%, rgba(56, 189, 248, 0.36), transparent 60%),
    radial-gradient(55% 75% at 50% 85%, rgba(244, 114, 182, 0.28), transparent 62%),
    linear-gradient(135deg, #101428 0%, #1c1b3a 55%, #0c162b 100%);
  --glass-shell: rgba(30, 32, 58, 0.46);
  --glass-pill: rgba(34, 36, 66, 0.56);
}

html[data-vtheme="flat-dark"] {
  --room-bg: #0b0f17;
  --glass-shell: #111622;
  --glass-pill: #161c2b;
  --glass-tile: rgba(255, 255, 255, 0.045);
  --glass-tile-hover: rgba(255, 255, 255, 0.09);
  --glass-border: rgba(255, 255, 255, 0.14);
  --glass-border-soft: rgba(255, 255, 255, 0.09);
  --blur-strength: 0px;
}

html[data-vtheme="flat-light"] {
  --room-bg: #e9edf3;
  --glass-shell: #ffffff;
  --glass-pill: #ffffff;
  --glass-tile: #f4f6fa;
  --glass-tile-hover: #eaeff7;
  --glass-input: #eef1f6;
  --glass-border: rgba(15, 23, 42, 0.12);
  --glass-border-soft: rgba(15, 23, 42, 0.08);
  --glass-highlight: rgba(255, 255, 255, 0.9);
  --ink-1: #0f172a;
  --ink-2: #475569;
  --ink-3: #64748b;
  --blur-strength: 0px;
  --shell-shadow: 0 24px 56px -18px rgba(15, 23, 42, 0.16);
}

*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

button, input, select {
  font-family: inherit;
  color: inherit;
}

button {
  background: none;
  border: none;
  cursor: pointer;
}

a {
  color: inherit;
  text-decoration: none;
}

body.vision-home-body {
  font-family: var(--font-sans);
  color: var(--ink-1);
  background: var(--room-bg);
  background-attachment: fixed;
  height: 100dvh;
  width: 100vw;
  overflow: hidden;
  position: relative;
  -webkit-font-smoothing: antialiased;
}

/* Blurred Spatial Loft Ambient Layer */
.room-backdrop {
  position: fixed;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  overflow: hidden;
}

.room-loft-shapes {
  position: absolute;
  inset: -4%;
  filter: blur(44px);
  opacity: 0.72;
  transition: opacity 0.35s ease;
}

html[data-vtheme="flat-dark"] .room-loft-shapes,
html[data-vtheme="flat-light"] .room-loft-shapes {
  display: none;
}

.loft-window-glow {
  position: absolute;
  right: 8%;
  top: -6%;
  width: 46vw;
  height: 78vh;
  background: linear-gradient(180deg, rgba(255, 250, 242, 0.65), rgba(220, 214, 206, 0.18));
  border-radius: 28px;
}

.loft-sofa-shadow {
  position: absolute;
  left: 6%;
  bottom: -6%;
  width: 66vw;
  height: 36vh;
  background: radial-gradient(ellipse at 40% 50%, rgba(56, 52, 48, 0.65), transparent 72%);
  border-radius: 999px;
}

.loft-custom-wallpaper {
  position: absolute;
  inset: 0;
  background-size: cover;
  background-position: center;
  opacity: 0;
  transition: opacity 0.4s ease;
}

.loft-custom-wallpaper.active {
  opacity: 1;
}

/* Reusable Smoked Glass Surface */
.v-glass {
  background: var(--glass-shell);
  backdrop-filter: blur(var(--blur-strength)) saturate(145%);
  -webkit-backdrop-filter: blur(var(--blur-strength)) saturate(145%);
  border: 1px solid var(--glass-border);
  box-shadow: inset 0 1px 0 var(--glass-highlight), var(--shell-shadow);
}

.v-pill-glass {
  background: var(--glass-pill);
  backdrop-filter: blur(var(--blur-strength)) saturate(145%);
  -webkit-backdrop-filter: blur(var(--blur-strength)) saturate(145%);
  border: 1px solid var(--glass-border);
  box-shadow: inset 0 1px 0 var(--glass-highlight), 0 14px 36px -10px rgba(0, 0, 0, 0.42);
}

/* Main Single-Screen Vertical Flex Shell */
.vision-root {
  position: relative;
  z-index: 2;
  height: 100dvh;
  width: 100%;
  padding: 14px 22px 12px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}

/* 1. DETACHED TOP ADDRESS BAR (matches top pill in reference) */
.vision-address-bar {
  position: relative;
  height: 40px;
  width: min(880px, 100%);
  border-radius: 999px;
  padding: 4px 10px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  flex-shrink: 0;
  overflow: hidden;
}

.address-progress {
  position: absolute;
  left: 24px;
  right: 24px;
  bottom: 0;
  height: 2px;
  border-radius: 99px;
  background: linear-gradient(90deg, transparent, #38bdf8, #ffffff, transparent);
  transform-origin: left center;
  transform: scaleX(0);
  opacity: 0;
  pointer-events: none;
}

.address-progress.running {
  animation: addrProgress 0.72s cubic-bezier(0.22, 1, 0.36, 1) forwards;
}

@keyframes addrProgress {
  0% { transform: scaleX(0); opacity: 1; }
  80% { transform: scaleX(1); opacity: 0.95; }
  100% { transform: scaleX(1); opacity: 0; }
}

.addr-group {
  display: flex;
  align-items: center;
  gap: 4px;
  flex-shrink: 0;
}

.v-icon-btn {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: var(--ink-2);
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.14);
  transition: transform 0.2s ease, background 0.2s ease, color 0.2s ease;
}

html[data-vtheme="flat-light"] .v-icon-btn {
  background: rgba(15, 23, 42, 0.06);
  border-color: rgba(15, 23, 42, 0.1);
}

.v-icon-btn:hover {
  background: rgba(255, 255, 255, 0.22);
  color: var(--ink-1);
  transform: translateY(-1px);
}

.v-icon-btn svg {
  width: 14px;
  height: 14px;
}

.address-form {
  flex: 1;
  min-width: 0;
  height: 30px;
  border-radius: 999px;
  background: var(--glass-input);
  border: 1px solid var(--glass-border-soft);
  padding: 0 10px;
  display: flex;
  align-items: center;
  gap: 7px;
}

.ssl-dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: #22c55e;
  box-shadow: 0 0 8px #22c55e;
  flex-shrink: 0;
}

.address-input {
  flex: 1;
  min-width: 0;
  border: none;
  background: transparent;
  outline: none;
  font-family: var(--font-mono);
  font-size: 0.74rem;
  font-weight: 500;
  color: var(--ink-1);
  text-align: center;
}

.address-input:focus {
  text-align: left;
}

.lang-mini-pill {
  display: inline-flex;
  align-items: center;
  background: rgba(0, 0, 0, 0.2);
  border-radius: 999px;
  padding: 2px;
  gap: 2px;
}

html[data-vtheme="flat-light"] .lang-mini-pill {
  background: rgba(15, 23, 42, 0.07);
}

.lang-mini-btn {
  font-size: 0.65rem;
  font-weight: 700;
  padding: 3px 6px;
  border-radius: 999px;
  color: var(--ink-3);
  transition: 0.2s ease;
}

.lang-mini-btn.active {
  background: #ffffff;
  color: #0f172a;
}

html[data-vtheme="flat-light"] .lang-mini-btn.active {
  background: #0f172a;
  color: #ffffff;
}

/* 2. CENTER WORKSPACE (Left Dock + Main Smoked Glass Window) */
.vision-stage {
  flex: 1;
  min-height: 0;
  width: min(1260px, 100%);
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 14px;
}

.vision-dock {
  width: 48px;
  padding: 10px 6px;
  border-radius: 999px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
  flex-shrink: 0;
}

.dock-item {
  position: relative;
  width: 34px;
  height: 34px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--ink-2);
  transition: transform 0.22s ease, background 0.22s ease, color 0.22s ease;
}

.dock-item svg {
  width: 17px;
  height: 17px;
}

.dock-item:hover {
  background: rgba(255, 255, 255, 0.16);
  color: var(--ink-1);
  transform: scale(1.08);
}

.dock-item.active {
  background: #ffffff;
  color: #111827;
  box-shadow: 0 4px 16px rgba(255, 255, 255, 0.36);
}

html[data-vtheme="flat-light"] .dock-item.active {
  background: #0f172a;
  color: #ffffff;
}

.dock-item[data-tip]::after {
  content: attr(data-tip);
  position: absolute;
  left: 46px;
  padding: 5px 10px;
  border-radius: 999px;
  background: rgba(15, 23, 42, 0.9);
  color: #fff;
  font-size: 0.7rem;
  font-weight: 600;
  white-space: nowrap;
  opacity: 0;
  transform: translateX(-6px);
  pointer-events: none;
  transition: 0.2s ease;
  z-index: 30;
}

.dock-item:hover::after {
  opacity: 1;
  transform: translateX(0);
}

/* Main Floating Smoked-Glass Window */
.vision-window {
  flex: 1;
  min-width: 0;
  height: 100%;
  border-radius: 30px;
  padding: 16px 18px;
  display: flex;
  flex-direction: column;
  gap: 12px;
  overflow: hidden;
  position: relative;
}

/* Window Internal Header */
.win-topbar {
  height: 40px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  flex-shrink: 0;
}

.win-search {
  width: 248px;
  height: 36px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.11);
  border: 1px solid rgba(255, 255, 255, 0.18);
  padding: 0 13px;
  display: flex;
  align-items: center;
  gap: 8px;
}

html[data-vtheme="flat-light"] .win-search {
  background: #f1f5f9;
  border-color: rgba(15, 23, 42, 0.1);
}

.win-search svg {
  width: 14px;
  height: 14px;
  color: var(--ink-2);
  flex-shrink: 0;
}

.win-search input {
  width: 100%;
  border: none;
  background: transparent;
  outline: none;
  font-size: 0.78rem;
  color: var(--ink-1);
}

.win-search input::placeholder {
  color: var(--ink-3);
}

.win-tabs {
  display: flex;
  align-items: center;
  gap: 4px;
  overflow-x: auto;
  scrollbar-width: none;
}

.win-tabs::-webkit-scrollbar { display: none; }

.win-tab {
  padding: 7px 14px;
  border-radius: 999px;
  font-size: 0.78rem;
  font-weight: 600;
  color: var(--ink-2);
  white-space: nowrap;
  transition: background 0.2s ease, color 0.2s ease;
}

.win-tab:hover {
  background: rgba(255, 255, 255, 0.11);
  color: var(--ink-1);
}

.win-tab.active {
  background: rgba(255, 255, 255, 0.22);
  color: #ffffff;
  border: 1px solid rgba(255, 255, 255, 0.26);
}

html[data-vtheme="flat-light"] .win-tab.active {
  background: #0f172a;
  color: #ffffff;
}

.win-user-group {
  display: flex;
  align-items: center;
  gap: 8px;
  position: relative;
}

.bell-btn {
  position: relative;
  width: 34px;
  height: 34px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.12);
  border: 1px solid rgba(255, 255, 255, 0.18);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: var(--ink-1);
}

html[data-vtheme="flat-light"] .bell-btn {
  background: #f1f5f9;
  border-color: rgba(15, 23, 42, 0.1);
}

.bell-dot {
  position: absolute;
  top: 7px;
  right: 7px;
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: #22c55e;
}

.profile-chip {
  height: 36px;
  padding: 3px 11px 3px 4px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.12);
  border: 1px solid rgba(255, 255, 255, 0.2);
  display: inline-flex;
  align-items: center;
  gap: 8px;
  transition: background 0.2s ease;
}

html[data-vtheme="flat-light"] .profile-chip {
  background: #f1f5f9;
  border-color: rgba(15, 23, 42, 0.1);
}

.profile-chip:hover {
  background: rgba(255, 255, 255, 0.2);
}

.profile-avatar {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  background: linear-gradient(135deg, #38bdf8, #8b5cf6);
  color: #fff;
  font-family: var(--font-display);
  font-size: 0.72rem;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
}

.profile-text {
  display: flex;
  flex-direction: column;
  text-align: left;
  line-height: 1.1;
}

.profile-text strong {
  font-size: 0.75rem;
  font-weight: 700;
}

.profile-text span {
  font-size: 0.62rem;
  color: var(--ink-3);
}

/* Social Profile Popover */
.profile-popover {
  position: absolute;
  top: 44px;
  right: 0;
  width: 240px;
  border-radius: 18px;
  padding: 10px;
  background: rgba(24, 24, 28, 0.92);
  backdrop-filter: blur(24px);
  border: 1px solid rgba(255, 255, 255, 0.24);
  box-shadow: 0 24px 48px rgba(0, 0, 0, 0.48);
  color: #fff;
  z-index: 40;
  display: none;
  flex-direction: column;
  gap: 4px;
}

.profile-popover.open {
  display: flex;
}

.pop-link {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 7px 10px;
  border-radius: 11px;
  font-size: 0.76rem;
  font-weight: 600;
  transition: background 0.18s ease;
}

.pop-link:hover {
  background: rgba(255, 255, 255, 0.12);
}

/* Window Main 2-Column Content */
.win-body {
  flex: 1;
  min-height: 0;
  display: grid;
  grid-template-columns: 256px minmax(0, 1fr);
  gap: 14px;
}

/* Left Rail: 2 Stacked Cards (Featured Builds + Quick Launch) */
.win-rail {
  display: flex;
  flex-direction: column;
  gap: 12px;
  min-height: 0;
}

.rail-card {
  border-radius: 20px;
  background: var(--glass-tile);
  border: 1px solid var(--glass-border-soft);
  padding: 12px;
  display: flex;
  flex-direction: column;
  gap: 8px;
  min-height: 0;
  overflow: hidden;
  position: relative;
}

.rail-card.featured-box {
  flex: 1.15;
}

.rail-card.queue-box {
  flex: 1;
}

.rail-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 0.78rem;
  font-weight: 700;
  flex-shrink: 0;
}

.rail-sort {
  font-size: 0.66rem;
  color: var(--ink-3);
  font-weight: 600;
}

.featured-thumbs {
  flex: 1;
  min-height: 0;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.featured-thumb-tile {
  flex: 1;
  min-height: 0;
  border-radius: 14px;
  padding: 10px;
  position: relative;
  overflow: hidden;
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 8px;
  border: 1px solid rgba(255, 255, 255, 0.18);
  cursor: pointer;
  transition: transform 0.22s ease, border-color 0.22s ease;
  color: #ffffff;
  text-align: left;
}

.featured-thumb-tile:hover {
  transform: scale(1.02);
  border-color: rgba(255, 255, 255, 0.45);
}

.featured-thumb-tile.active {
  box-shadow: 0 0 0 1.5px rgba(255, 255, 255, 0.85);
}

.thumb-scrim {
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, transparent 20%, rgba(0, 0, 0, 0.78) 100%);
  pointer-events: none;
}

.thumb-meta {
  position: relative;
  z-index: 1;
  min-width: 0;
}

.thumb-meta strong {
  display: block;
  font-size: 0.73rem;
  font-weight: 700;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.thumb-meta span {
  font-size: 0.62rem;
  opacity: 0.78;
}

.circle-play-sm {
  position: relative;
  z-index: 1;
  width: 24px;
  height: 24px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.24);
  backdrop-filter: blur(8px);
  color: #ffffff;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 0.62rem;
  flex-shrink: 0;
}

.queue-list {
  flex: 1;
  min-height: 0;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  gap: 6px;
}

.queue-row {
  flex: 1;
  min-height: 0;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  padding: 5px 7px;
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid transparent;
  cursor: pointer;
  transition: background 0.2s ease, border-color 0.2s ease;
  text-align: left;
}

html[data-vtheme="flat-light"] .queue-row {
  background: rgba(15, 23, 42, 0.04);
}

.queue-row:hover {
  background: var(--glass-tile-hover);
  border-color: var(--glass-border-soft);
}

.queue-icon {
  width: 30px;
  height: 30px;
  border-radius: 9px;
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.62rem;
  font-weight: 800;
  color: #fff;
}

.queue-info {
  flex: 1;
  min-width: 0;
}

.queue-info strong {
  display: block;
  font-size: 0.72rem;
  font-weight: 700;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.queue-info span {
  display: block;
  font-size: 0.62rem;
  color: var(--ink-3);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

/* Right Main Zone (Hero Banner + 4 Poster Tiles) */
.win-stage {
  display: flex;
  flex-direction: column;
  gap: 12px;
  min-height: 0;
}

/* Hero Spotlight Card */
.hero-banner {
  flex: 1.18;
  min-height: 0;
  border-radius: 22px;
  padding: 18px 22px;
  position: relative;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  color: #ffffff;
  border: 1px solid rgba(255, 255, 255, 0.24);
}

.hero-art-layer {
  position: absolute;
  inset: 0;
  z-index: 0;
  transition: background 0.55s ease;
}

.hero-motif-svg {
  position: absolute;
  right: 2%;
  top: 50%;
  transform: translateY(-50%);
  width: 44%;
  height: 112%;
  opacity: 0.42;
  pointer-events: none;
  z-index: 1;
}

.hero-scrim {
  position: absolute;
  inset: 0;
  z-index: 1;
  background: linear-gradient(90deg, rgba(6, 9, 18, 0.88) 0%, rgba(6, 9, 18, 0.58) 54%, rgba(6, 9, 18, 0.16) 100%);
  pointer-events: none;
}

.hero-top {
  position: relative;
  z-index: 2;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}

.hero-trending-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 5px 11px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.16);
  backdrop-filter: blur(10px);
  border: 1px solid rgba(255, 255, 255, 0.22);
  font-size: 0.7rem;
  font-weight: 700;
}

.hero-domain-chip {
  font-family: var(--font-mono);
  font-size: 0.68rem;
  padding: 5px 11px;
  border-radius: 999px;
  background: rgba(0, 0, 0, 0.36);
  border: 1px solid rgba(255, 255, 255, 0.18);
  color: rgba(255, 255, 255, 0.88);
}

.hero-body {
  position: relative;
  z-index: 2;
  max-width: 560px;
  display: flex;
  flex-direction: column;
  gap: 7px;
}

.hero-tag-row {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.hero-tag {
  font-size: 0.66rem;
  font-weight: 600;
  padding: 3px 9px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.14);
  border: 1px solid rgba(255, 255, 255, 0.18);
}

.hero-title {
  font-family: var(--font-display);
  font-size: clamp(1.35rem, 2.2vw, 1.95rem);
  font-weight: 700;
  line-height: 1.12;
  letter-spacing: -0.02em;
}

.hero-desc {
  font-size: 0.8rem;
  line-height: 1.45;
  color: rgba(255, 255, 255, 0.82);
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.hero-actions-row {
  position: relative;
  z-index: 2;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.hero-btn-group {
  display: flex;
  align-items: center;
  gap: 8px;
}

.btn-solid-white {
  height: 36px;
  padding: 0 18px;
  border-radius: 999px;
  background: #ffffff;
  color: #0f172a;
  font-size: 0.78rem;
  font-weight: 700;
  display: inline-flex;
  align-items: center;
  gap: 7px;
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.25);
  transition: transform 0.2s ease, opacity 0.2s ease;
}

.btn-solid-white:hover {
  transform: translateY(-1px);
  opacity: 0.94;
}

.btn-frosted {
  height: 36px;
  padding: 0 15px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.14);
  backdrop-filter: blur(10px);
  border: 1px solid rgba(255, 255, 255, 0.28);
  color: #ffffff;
  font-size: 0.76rem;
  font-weight: 600;
  display: inline-flex;
  align-items: center;
  gap: 7px;
  transition: background 0.2s ease, transform 0.2s ease;
}

.btn-frosted:hover {
  background: rgba(255, 255, 255, 0.24);
  transform: translateY(-1px);
}

.hero-nav-circle {
  width: 34px;
  height: 34px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.15);
  backdrop-filter: blur(10px);
  border: 1px solid rgba(255, 255, 255, 0.24);
  color: #ffffff;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  transition: background 0.2s ease, transform 0.2s ease;
}

.hero-nav-circle:hover {
  background: rgba(255, 255, 255, 0.28);
  transform: scale(1.06);
}

/* Bottom 4-Tile Poster Strip ("You might like" -> "Interactive Projects") */
.poster-section {
  flex: 0.98;
  min-height: 0;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.poster-section-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-shrink: 0;
}

.poster-section-head h2 {
  font-family: var(--font-display);
  font-size: 0.96rem;
  font-weight: 700;
}

.see-all-pill {
  font-size: 0.7rem;
  font-weight: 600;
  padding: 4px 12px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.13);
  border: 1px solid var(--glass-border-soft);
  transition: background 0.2s ease;
}

.see-all-pill:hover {
  background: rgba(255, 255, 255, 0.24);
}

.poster-grid {
  flex: 1;
  min-height: 0;
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px;
}

.poster-card {
  border-radius: 20px;
  padding: 12px;
  position: relative;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  border: 1px solid rgba(255, 255, 255, 0.22);
  color: #ffffff;
  cursor: pointer;
  transition: transform 0.25s cubic-bezier(0.22, 1, 0.36, 1), border-color 0.25s ease;
}

.poster-card:hover {
  transform: translateY(-3px);
  border-color: rgba(255, 255, 255, 0.56);
}

.poster-card-motif {
  position: absolute;
  right: -12px;
  top: 10px;
  width: 110px;
  height: 110px;
  opacity: 0.32;
  pointer-events: none;
}

.poster-card-scrim {
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(0, 0, 0, 0.1) 0%, rgba(0, 0, 0, 0.35) 45%, rgba(0, 0, 0, 0.88) 100%);
  pointer-events: none;
}

.poster-top {
  position: relative;
  z-index: 1;
  display: flex;
  justify-content: flex-end;
}

.poster-more-btn {
  width: 24px;
  height: 24px;
  border-radius: 50%;
  background: rgba(0, 0, 0, 0.38);
  color: #fff;
  font-size: 0.72rem;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.poster-bottom {
  position: relative;
  z-index: 1;
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 8px;
}

.poster-text {
  min-width: 0;
}

.poster-badge {
  display: inline-block;
  font-size: 0.6rem;
  font-weight: 700;
  padding: 2px 7px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.18);
  margin-bottom: 4px;
}

.poster-text h3 {
  font-family: var(--font-display);
  font-size: 0.82rem;
  font-weight: 700;
  line-height: 1.2;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.poster-text p {
  font-size: 0.67rem;
  color: rgba(255, 255, 255, 0.76);
  line-height: 1.3;
  margin-top: 2px;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.poster-play-btn {
  width: 34px;
  height: 34px;
  border-radius: 50%;
  background: #ffffff;
  color: #0f172a;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 0.76rem;
  flex-shrink: 0;
  box-shadow: 0 6px 16px rgba(0, 0, 0, 0.35);
  transition: transform 0.2s ease;
}

.poster-card:hover .poster-play-btn {
  transform: scale(1.08);
}

/* 3. BOTTOM FLOATING GOOGLE WEATHER DOCK */
.weather-dock {
  height: 44px;
  max-width: min(1060px, 100%);
  border-radius: 999px;
  padding: 0 14px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  flex-shrink: 0;
  font-size: 0.76rem;
  position: relative;
}

.weather-main {
  display: flex;
  align-items: center;
  gap: 8px;
}

.weather-svg-icon {
  width: 26px;
  height: 26px;
  flex-shrink: 0;
}

.weather-temp {
  font-family: var(--font-display);
  font-size: 1rem;
  font-weight: 700;
}

.weather-cond {
  color: var(--ink-2);
  font-weight: 600;
  white-space: nowrap;
}

.weather-city-wrap {
  display: flex;
  align-items: center;
  gap: 4px;
  background: rgba(255, 255, 255, 0.12);
  border: 1px solid var(--glass-border-soft);
  border-radius: 999px;
  padding: 3px 8px;
}

html[data-vtheme="flat-light"] .weather-city-wrap {
  background: rgba(15, 23, 42, 0.06);
}

.weather-city-select {
  border: none;
  background: transparent;
  outline: none;
  font-size: 0.72rem;
  font-weight: 600;
  cursor: pointer;
}

.weather-city-select option {
  color: #0f172a;
  background: #ffffff;
}

.weather-sep {
  width: 1px;
  height: 18px;
  background: var(--glass-border-soft);
  flex-shrink: 0;
}

.weather-metrics {
  display: flex;
  align-items: center;
  gap: 10px;
  color: var(--ink-2);
  font-size: 0.7rem;
  white-space: nowrap;
}

.weather-hourly {
  display: flex;
  align-items: center;
  gap: 10px;
}

.hour-slot {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  font-size: 0.69rem;
  color: var(--ink-2);
  white-space: nowrap;
}

.hour-slot strong {
  color: var(--ink-1);
}

.google-weather-link {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 4px 10px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.14);
  border: 1px solid var(--glass-border-soft);
  font-size: 0.69rem;
  font-weight: 700;
  white-space: nowrap;
  transition: background 0.2s ease;
}

.google-weather-link:hover {
  background: rgba(255, 255, 255, 0.26);
}

.g-dot-logo {
  display: inline-grid;
  grid-template-columns: 5px 5px;
  gap: 1.5px;
}

.g-dot-logo i {
  width: 5px;
  height: 5px;
  border-radius: 50%;
  display: block;
}

/* ==========================================================================
   ENTRANCE TILE PRELOAD & STAGGERED REVEAL ANIMATION
   ========================================================================== */
.vision-root .tile-reveal {
  position: relative;
  transition:
    opacity 0.56s cubic-bezier(0.22, 1, 0.36, 1),
    transform 0.6s cubic-bezier(0.22, 1, 0.36, 1),
    filter 0.45s ease;
  transition-delay: calc(var(--i, 0) * 52ms);
}

.vision-root.is-preloading .tile-reveal {
  opacity: 0.35;
  transform: translateY(14px) scale(0.975);
  filter: blur(5px);
}

.vision-root.is-preloading .tile-reveal::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 15;
  border-radius: inherit;
  background: linear-gradient(
    110deg,
    rgba(255, 255, 255, 0.04) 20%,
    rgba(255, 255, 255, 0.24) 48%,
    rgba(255, 255, 255, 0.04) 76%
  );
  background-size: 200% 100%;
  animation: tileShimmer 0.72s linear infinite;
  pointer-events: none;
}

@keyframes tileShimmer {
  0% { background-position: 200% 0; }
  100% { background-position: -200% 0; }
}

.vision-root.is-revealed .tile-reveal {
  opacity: 1;
  transform: none;
  filter: none;
}

/* ==========================================================================
   PROJECT 3D MODAL, STUDIO APPEARANCE DRAWER & TOAST
   ========================================================================== */
.v-toast {
  position: fixed;
  top: 62px;
  left: 50%;
  transform: translate(-50%, -14px);
  opacity: 0;
  pointer-events: none;
  padding: 8px 16px;
  border-radius: 999px;
  background: rgba(15, 23, 42, 0.9);
  color: #fff;
  font-size: 0.78rem;
  font-weight: 600;
  border: 1px solid rgba(255, 255, 255, 0.24);
  z-index: 90;
  transition: 0.28s cubic-bezier(0.22, 1, 0.36, 1);
}

.v-toast.show {
  opacity: 1;
  transform: translate(-50%, 0);
}

.v-modal-backdrop {
  position: fixed;
  inset: 0;
  z-index: 80;
  background: rgba(4, 7, 15, 0.65);
  backdrop-filter: blur(12px);
  display: none;
  align-items: center;
  justify-content: center;
  padding: 20px;
}

.v-modal-backdrop.open {
  display: flex;
}

.v-modal-card {
  width: min(940px, 100%);
  border-radius: 26px;
  padding: 20px;
  display: flex;
  flex-direction: column;
  gap: 14px;
  color: var(--ink-1);
}

.v-modal-frame {
  width: 100%;
  height: min(56vh, 460px);
  border-radius: 18px;
  overflow: hidden;
  border: 1px solid var(--glass-border);
  background: #070a14;
}

.v-modal-frame iframe {
  width: 100%;
  height: 100%;
  border: none;
}

.v-drawer-backdrop {
  position: fixed;
  inset: 0;
  z-index: 75;
  background: rgba(0, 0, 0, 0.38);
  display: none;
}

.v-drawer-backdrop.open {
  display: block;
}

.v-drawer {
  position: fixed;
  top: 14px;
  right: 14px;
  bottom: 14px;
  width: min(340px, calc(100vw - 28px));
  border-radius: 24px;
  padding: 20px;
  z-index: 78;
  display: flex;
  flex-direction: column;
  gap: 16px;
  overflow-y: auto;
  transform: translateX(115%);
  transition: transform 0.32s cubic-bezier(0.22, 1, 0.36, 1);
  color: var(--ink-1);
}

.v-drawer.open {
  transform: translateX(0);
}

.theme-chip-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 8px;
}

.theme-chip-btn {
  padding: 9px 10px;
  border-radius: 12px;
  background: var(--glass-tile);
  border: 1px solid var(--glass-border-soft);
  font-size: 0.76rem;
  font-weight: 600;
  text-align: left;
  display: flex;
  align-items: center;
  gap: 8px;
}

.theme-chip-btn.active {
  border-color: #ffffff;
  background: rgba(255, 255, 255, 0.22);
}

html[data-vtheme="flat-light"] .theme-chip-btn.active {
  border-color: #0f172a;
}

/* ==========================================================================
   RESPONSIVE: TABLET & MOBILE (Allow clean vertical scroll below 1024px)
   ========================================================================== */
@media (max-width: 1023px) {
  body.vision-home-body {
    height: auto;
    min-height: 100dvh;
    overflow-x: hidden;
    overflow-y: auto;
  }

  .vision-root {
    height: auto;
    padding: 12px;
    gap: 12px;
  }

  .vision-address-bar {
    height: auto;
    flex-wrap: wrap;
    border-radius: 20px;
    padding: 8px;
  }

  .vision-stage {
    flex-direction: column;
    height: auto;
  }

  .vision-dock {
    width: 100%;
    flex-direction: row;
    justify-content: center;
    padding: 6px 12px;
  }

  .dock-item::after {
    display: none;
  }

  .vision-window {
    width: 100%;
    height: auto;
    overflow: visible;
  }

  .win-topbar {
    height: auto;
    flex-wrap: wrap;
  }

  .win-search {
    width: 100%;
  }

  .win-body {
    grid-template-columns: 1fr;
  }

  .hero-banner {
    min-height: 270px;
  }

  .poster-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .poster-card {
    min-height: 165px;
  }

  .weather-dock {
    height: auto;
    flex-wrap: wrap;
    border-radius: 20px;
    padding: 10px 14px;
    width: 100%;
  }

  .weather-hourly,
  .weather-sep {
    display: none;
  }
}

@media (max-width: 560px) {
  .poster-grid {
    grid-template-columns: 1fr;
  }
}

@media (prefers-reduced-motion: reduce) {
  .vision-root .tile-reveal {
    transition: none;
  }
  .vision-root.is-preloading .tile-reveal::after {
    animation: none;
  }
}
