/**
 * 3Syxty Studio — Studio-Specific Styles
 *
 * Utility classes, component styles, animations, hotspot rendering,
 * and accessibility helpers that complement the core design system.
 *
 * Note: Design tokens live in tokens.css (single source of truth).
 * This file contains only studio-specific extensions.
 */

/* -----------------------------------------------------------------------
   Tailwind Extensions (custom utility classes for the design system)
   ----------------------------------------------------------------------- */

.bg-surface-850 { background-color: #161922; }
.bg-surface-900 { background-color: #0F1117; }
.bg-surface-950 { background-color: #0A0C12; }
.border-surface-800 { border-color: #1F2233; }
.border-surface-700 { border-color: #2A2E3D; }
.text-surface-200 { color: #E5E7EB; }
.text-surface-300 { color: #D1D5DB; }
.text-surface-400 { color: #9CA3AF; }
.text-surface-500 { color: #6B7280; }
.text-surface-600 { color: #4B5563; }
.text-surface-700 { color: #374151; }

.bg-brand-500 { background-color: #6C5CE7; }
.bg-brand-600 { background-color: #5B4BD5; }
.text-brand-400 { color: #8B7CF7; }
.text-brand-500 { color: #6C5CE7; }
.border-brand-400 { border-color: #8B7CF7; }
.border-brand-500 { border-color: #6C5CE7; }

/* -----------------------------------------------------------------------
   Component Styles
   ----------------------------------------------------------------------- */

/* Glass panel effect */
.glass {
    background: rgba(15, 17, 23, 0.75);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border: 1px solid rgba(255, 255, 255, 0.06);
}

/* Gradient accent border */
.gradient-border {
    position: relative;
    background: var(--surface-secondary);
    border-radius: var(--radius-lg);
}
.gradient-border::before {
    content: '';
    position: absolute;
    inset: -1px;
    border-radius: inherit;
    background: var(--accent-gradient);
    z-index: -1;
}

/* Accent glow */
.glow-brand {
    box-shadow: 0 0 20px rgba(108, 92, 231, 0.3), 0 0 60px rgba(108, 92, 231, 0.1);
}

/* Scrollbar styling (Webkit) */
.scrollbar-thin::-webkit-scrollbar {
    width: 6px;
    height: 6px;
}
.scrollbar-thin::-webkit-scrollbar-track {
    background: transparent;
}
.scrollbar-thin::-webkit-scrollbar-thumb {
    background: rgba(255, 255, 255, 0.1);
    border-radius: 3px;
}
.scrollbar-thin::-webkit-scrollbar-thumb:hover {
    background: rgba(255, 255, 255, 0.2);
}

/* Focus ring */
.focus-ring:focus-visible {
    outline: 2px solid var(--accent-primary);
    outline-offset: 2px;
}

/* -----------------------------------------------------------------------
   Animation Keyframes
   ----------------------------------------------------------------------- */

@keyframes fade-in {
    from { opacity: 0; }
    to { opacity: 1; }
}

@keyframes slide-up {
    from { opacity: 0; transform: translateY(8px); }
    to { opacity: 1; transform: translateY(0); }
}

@keyframes slide-down {
    from { opacity: 0; transform: translateY(-8px); }
    to { opacity: 1; transform: translateY(0); }
}

@keyframes scale-in {
    from { opacity: 0; transform: scale(0.95); }
    to { opacity: 1; transform: scale(1); }
}

@keyframes pulse-ring {
    0% { box-shadow: 0 0 0 0 rgba(108, 92, 231, 0.4); }
    70% { box-shadow: 0 0 0 8px rgba(108, 92, 231, 0); }
    100% { box-shadow: 0 0 0 0 rgba(108, 92, 231, 0); }
}

@keyframes hs-pulse {
    0% { opacity: 0.6; transform: translate(-50%, -50%) scale(0.6); }
    70% { opacity: 0; transform: translate(-50%, -50%) scale(1); }
    100% { opacity: 0; transform: translate(-50%, -50%) scale(1); }
}

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

.animate-fade-in { animation: fade-in var(--motion-fast); }
.animate-slide-up { animation: slide-up var(--motion-normal); }
.animate-slide-down { animation: slide-down var(--motion-normal); }
.animate-scale-in { animation: scale-in var(--motion-fast); }
.animate-pulse-ring { animation: pulse-ring 2s infinite; }

/* -----------------------------------------------------------------------
   Hotspot Styles (for published tour viewer)
   ----------------------------------------------------------------------- */

.hotspot-marker {
    position: absolute;
    cursor: pointer;
    transform: translate(-50%, -50%);
    transition: transform 150ms ease-out;
    z-index: 10;
}
.hotspot-marker:hover {
    transform: translate(-50%, -50%) scale(1.15);
}

.hotspot-icon {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    background: var(--accent-primary);
    border: 2px solid rgba(255, 255, 255, 0.9);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.3);
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 14px;
}
.hotspot-icon.pulse {
    animation: pulse-ring 2s infinite;
}

.hotspot-label {
    position: absolute;
    top: 100%;
    left: 50%;
    transform: translateX(-50%);
    margin-top: 6px;
    padding: 2px 8px;
    background: rgba(0, 0, 0, 0.75);
    backdrop-filter: blur(4px);
    border-radius: var(--radius-sm);
    color: white;
    font-size: 11px;
    font-weight: 500;
    white-space: nowrap;
    pointer-events: none;
    opacity: 0;
    transition: opacity 150ms ease-out;
}
.hotspot-marker:hover .hotspot-label,
.hotspot-marker:focus .hotspot-label {
    opacity: 1;
}

/* -----------------------------------------------------------------------
   Accessibility
   ----------------------------------------------------------------------- */

/* Respect reduced motion preference */
@media (prefers-reduced-motion: reduce) {
    *, *::before, *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
}

/* Screen reader only */
.sr-only {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}

/* Skip to content link */
.skip-link {
    position: absolute;
    top: -100%;
    left: 0;
    padding: 8px 16px;
    background: var(--accent-primary);
    color: white;
    z-index: 9999;
    transition: top 150ms ease-out;
}
.skip-link:focus {
    top: 0;
}

/* High contrast mode adjustments */
@media (forced-colors: active) {
    .hotspot-icon {
        forced-color-adjust: none;
    }
}
