/* Desktop - remove margin-right */
@media (min-width: 769px) {
  .mobile-h1-small {
    margin-right: 0 !important;
  }
}

/* Mobile responsiveness */
@media (max-width: 768px) {
  .mobile-header {
    flex-direction: column !important;
    align-items: flex-start !important;
    gap: 1rem !important;
  }
  
  .mobile-title {
    max-width: 100% !important;
  }
  
  .mobile-h1 {
    font-size: 3rem !important; /* 48px instead of 88px */
    margin-bottom: 1rem !important;
  }
  
}

/* Small mobile devices */
@media (max-width: 480px) {
  .mobile-h1 {
    font-size: 2.5rem !important; /* 40px for very small screens */
  }
  
}

.vaso-switching {
  position: absolute !important;
  top: -15px;
  width: 66px;
  height: 66px;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  z-index: 3;
}

.vaso-left {
  left: -10px;
}

.vaso-right {
  left: 100%;
  transform: translateX(calc(-100% + 10px));
}

.vaso-slider [data-vaso] {
  border-radius: 999px;
}
.vaso-slider [data-vaso] {
  box-shadow: 0px -1px 8px rgba(55, 53, 45, 0.2) !important;
}
[data-theme="dark"] .vaso-slider [data-vaso] {
  box-shadow: 0px -1px 8px rgba(160, 183, 187, 0.2) !important;
}
/* Theme System */
.root {
  transition: background-color 500ms ease;
}

/* Light Theme (Default) */
.root {
  background-color: rgb(245 244 237);
}

.theme-title {
  color: #111827;
  transition: color 500ms ease;
}

.theme-subtitle {
  color: #374151;
  transition: color 500ms ease;
}

.theme-description {
  color: #4b5563;
  transition: color 500ms ease;
}

.theme-controls {
  background-color: rgba(236, 236, 236, 0.466);
  transition: background-color 500ms ease, border-color 500ms ease;
}

.theme-controls-title {
  color: #374151;
  transition: color 500ms ease;
}

.theme-controls-text {
  color: #4b5563;
  transition: color 500ms ease;
}

.theme-content {
  transition: background-color 500ms ease;
}

.theme-section {
  border-color: rgba(156, 163, 175, 0.3);
  transition: border-color 500ms ease;
}

.theme-heading {
  color: #111827;
  transition: color 500ms ease;
}

.theme-text {
  color: #374151;
  transition: color 500ms ease;
}

.theme-label {
  color: #4b5563;
  transition: color 500ms ease;
}

/* Dark Theme */
[data-theme="dark"] {
  background-color: #111827;
}

[data-theme="dark"] .theme-title {
  color: #ffffff;
}

[data-theme="dark"] .theme-subtitle {
  color: #d1d5db;
}

[data-theme="dark"] .theme-description {
  color: #d1d5db;
}

[data-theme="dark"] .theme-controls {
  background-color: rgba(31, 41, 55, 0.55);
  border-color: rgba(55, 65, 81, 0.5);
}

[data-theme="dark"] .theme-controls-title {
  color: #e5e7eb;
}

[data-theme="dark"] .theme-controls-text {
  color: #d1d5db;
}

[data-theme="dark"] .theme-content {
  background-color: #1f2937;
}

[data-theme="dark"] .theme-section {
  border-color: rgba(75, 85, 99, 0.5);
}

[data-theme="dark"] .theme-heading {
  color: #f3f4f6;
}

[data-theme="dark"] .theme-text {
  color: #d1d5db;
}

[data-theme="dark"] .theme-label {
  color: #9ca3af;
}

:root {
  --theme-border-color: rgba(156, 163, 175, 0.3);
}

[data-theme="dark"] {
  --theme-border-color: rgba(75, 85, 99, 0.5);
}

.theme-text-bg {
  background-color: #e2dfd2;
}

[data-theme="dark"] .theme-text-bg {
  background-color: #171f28;
}

.theme-text-bg-sample-text {
  color: #66717c;
}
[data-theme="dark"] .theme-text-bg-sample-text {
  color: #cccfc1;
}

.vaso-slider-thumb {
  background-color: #cdcfc1;
  border-radius: 999px;
}

.crystal-demo {
  max-width: 690px;
  padding-bottom: 48px;
}

.crystal-stage-wrap {
  display: grid;
  place-items: center;
  overflow: visible;
}

.crystal-stage {
  position: relative;
  width: 100%;
  height: 324px;
  overflow: visible;
  border-radius: 18px;
  background: linear-gradient(180deg, #dbe6e5 0%, #e8e9df 72%, #dadbd1 100%);
  border: 1px solid rgba(96, 111, 111, 0.12);
  transform-origin: center;
}

[data-theme="dark"] .crystal-stage {
  background: linear-gradient(180deg, #263743 0%, #35454b 72%, #273139 100%);
}

.crystal-corner {
  position: absolute;
  top: 8px;
  z-index: 4;
  width: 36px;
  height: 36px;
  border: 1px solid rgba(70, 91, 97, 0.35);
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.55);
  cursor: grab;
  touch-action: none;
}

.crystal-corner:active {
  cursor: grabbing;
}

.crystal-corner::after {
  content: '';
  display: block;
  width: 10px;
  height: 10px;
  margin: auto;
  border: 2px solid rgba(50, 70, 77, 0.55);
  border-radius: 50%;
}

.crystal-corner-left {
  left: 8px;
}

.crystal-corner-right {
  right: 8px;
}

@media (max-width: 600px) {
  .crystal-demo {
    padding-bottom: 32px;
  }

  .crystal-stage-wrap {
    height: 500px;
  }
}

.crystal-ball {
  position: absolute;
  bottom: 36px;
  left: 0;
  z-index: 2;
  visibility: hidden;
  overflow: visible;
  border-radius: 50%;
  cursor: grab;
  touch-action: none;
  will-change: transform;
}

.crystal-ball:active {
  cursor: grabbing;
}

.crystal-ball img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  border-radius: 50%;
  user-select: none;
}

.crystal-floor {
  border-top: 1px solid rgba(255, 255, 255, 0.65);
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.12);
}

.crystal-launch {
  position: absolute;
  bottom: -39px;
  left: 50%;
  z-index: 6;
  display: grid;
  place-items: center;
  width: 36px;
  height: 30px;
  transform: translateX(-50%);
  border: 1px solid rgba(90, 110, 116, 0.3);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.55);
  cursor: pointer;
}

.crystal-launch:hover {
  background: rgba(127, 145, 145, 0.12);
}

[data-theme="dark"] .vaso-slider-thumb {
  background-color: #e5e5e579;
}

/* Floating glass panel. Animate transform only: opacity < 1 would blank the glass backdrop */
.glass-panel {
  animation: glass-panel-in 200ms cubic-bezier(0.2, 0.9, 0.3, 1.15);
}

@keyframes glass-panel-in {
  from {
    transform: scale(0.85);
  }
  to {
    transform: scale(1);
  }
}

/* Long press opens the panel, so keep the native touch callout out of the way */
.root {
  -webkit-touch-callout: none;
}

/* Resize grip on the quick start glass: a solid chip so it reads over any text, nudging to hint at dragging */
.drag-hint {
  color: #374151;
  background-color: rgba(255, 255, 255, 0.85);
  animation: drag-hint-nudge 1.8s ease-in-out infinite;
  transition: background-color 200ms ease;
}

.drag-hint-active {
  background-color: #ffffff;
  animation: none;
}

[data-theme="dark"] .drag-hint {
  color: #e5e7eb;
  background-color: rgba(55, 65, 81, 0.9);
}

@keyframes drag-hint-nudge {
  /* transform, not translate: Tailwind's translate utilities center the icon with the translate property */
  0%, 60%, 100% {
    transform: translateX(0);
  }
  30% {
    transform: translateX(3px);
  }
}

@media (prefers-reduced-motion: reduce) {
  .drag-hint {
    animation: none;
  }
}

.hero-glow {
  position: absolute;
  top: -60px;
  left: -40px;
  width: 520px;
  max-width: 100%;
  height: 300px;
  background:
    radial-gradient(closest-side circle at 30% 40%, rgba(227, 167, 90, 0.22), transparent);
  pointer-events: none;
}

[data-theme="dark"] .hero-glow {
  background:
    radial-gradient(closest-side circle at 30% 40%, rgba(227, 167, 90, 0.12), transparent);
}

/* Segmented control: the same track as the theme switcher */
.segmented-track {
  background-color: #fff;
  border-color: #fff;
}
.segmented-tab {
  color: #6b7280;
}
.segmented-tab:hover {
  color: #374151;
}
.segmented-tab-active {
  color: #111827;
}
/* Same lift as the slider glass, so the pill reads over the white track */
.segmented-pill [data-vaso] {
  box-shadow: 0px 1px 8px rgba(55, 53, 45, 0.2) !important;
}
[data-theme="dark"] .segmented-pill [data-vaso] {
  box-shadow: 0px 1px 8px rgba(160, 183, 187, 0.2) !important;
}
[data-theme="dark"] .segmented-track {
  background-color: rgba(17, 24, 39, 0.8);
  border-color: rgba(55, 65, 81, 0.5);
}
[data-theme="dark"] .segmented-tab {
  color: #d1d5db;
}
[data-theme="dark"] .segmented-tab:hover {
  color: #f3f4f6;
}
[data-theme="dark"] .segmented-tab-active {
  color: #fff;
}

/* Color picker: hue around the wheel, fading to white at the center */
.color-wheel {
  background:
    radial-gradient(closest-side circle, #fff, rgba(255, 255, 255, 0)),
    conic-gradient(from 90deg, #f00, #ff0, #0f0, #0ff, #00f, #f0f, #f00);
}
.color-lens [data-vaso] {
  box-shadow: 0 0 0 1px rgba(255, 255, 255, 0.6), 0px 2px 10px rgba(55, 53, 45, 0.35) !important;
}

/* Code-like text and links under the floating glass: bold black, a step darker than body text */
.theme-code {
  color: #111827;
}
[data-theme="dark"] .theme-code {
  color: #fff;
}

/* On touch screens, pressing a floating glass target is its "hover", so it shouldn't start a text selection or
   the long-press callout. Mice keep normal selection, e.g. to copy the install command */
@media (pointer: coarse) {
  .floating-glass {
    -webkit-user-select: none;
    user-select: none;
    -webkit-touch-callout: none;
  }
}

/* Notifications: a photo behind the toast, so the clear glass has something to bend */
.toast-backdrop {
  background: url(/flower.jpg) 30% 20% / cover;
}
.toast-title,
.toast-body {
  color: #fff;
  text-shadow: 0 1px 6px rgba(0, 0, 0, 0.35);
}
.toast-body {
  opacity: 0.9;
}

/* Round icon button over media */
.glass-button {
  color: #fff;
}

/* Code block */
.code-block {
  background-color: #e2dfd2;
  color: #374151;
}
.code-block-bar {
  color: #66717c;
  border-bottom: 1px solid rgba(156, 163, 175, 0.3);
}
.code-comment {
  color: #9ca3af;
  font-style: italic;
}
.code-string,
.code-number {
  color: #b07b35;
}
.code-keyword {
  color: #66717c;
}
.code-tag {
  color: #111827;
  font-weight: 600;
}
.code-prop {
  color: #4b5563;
}
[data-theme="dark"] .code-block {
  background-color: #171f28;
  color: #e5e7eb;
}
[data-theme="dark"] .code-block-bar {
  color: #9ca3af;
  border-color: rgba(75, 85, 99, 0.5);
}
[data-theme="dark"] .code-string,
[data-theme="dark"] .code-number {
  color: #e3a75a;
}
[data-theme="dark"] .code-keyword {
  color: #9ca3af;
}
[data-theme="dark"] .code-tag {
  color: #f3f4f6;
}
[data-theme="dark"] .code-prop {
  color: #cccfc1;
}

