@import url('https://fonts.googleapis.com/css2?family=Rajdhani:wght@500;600;700&display=swap');

/* 1. KEEP THIS: Fixes the full-screen white flash */
html {
    background-color: #0B0A21 !important;
}

body {
    background-color: #0B0A21 !important;
    margin: 0;
}

/* 2. CHANGE THIS: Make the container Transparent again */
.header-logo-3d-container {
    background: transparent !important;
    /* Fixes the "Blue Box" blocking stars */
    z-index: 100000;
}

/* 3. CHANGE THIS: Make the canvas Transparent again */
.header-logo-3d-container canvas {
    background: transparent !important;
    /* Fixes the "Blue Box" blocking stars */
    outline: none !important;
}

/* Header 3D Logo Container */
.header-logo-3d-container {

    z-index: 100000;
    pointer-events: auto;
    cursor: pointer;
}

.header-logo-3d-container canvas {
    display: block;
    width: 100%;
    height: 100%;
}

/* Hide original logo when 3D logo is present */
.site-header:has(.header-logo-3d-container) .site-logo img {
    opacity: 0.3;
}

/* Mobile Landscape Overlay Scaling */
@media (orientation: landscape) and (max-width: 900px) and (max-height: 500px) {

    #reset-view-btn,
    .vertical-selector-component {
        transition: transform 0.2s !important;
        will-change: transform;
    }

    /* Force logo visibility in mobile landscape - fixes disappearing on some devices */
    .site-logo,
    .site-logo-img {
        display: block !important;
        visibility: visible !important;
        opacity: 1 !important;
        position: absolute !important;
        top: 10px !important;
        left: 10px !important;
        z-index: 10000 !important;
        min-width: 80px;
    }
}

/*!
Theme Name: MA
Theme URI: https://medhatalkadry.com/
Author: Medhat Alkadri
Author URI: https://medhatalkadry.com/
Description: My Personal Theme
Version: 1.0.0
Tested up to: 5.4
Requires PHP: 5.6
License: GNU General Public License v2 or later
License URI: LICENSE
Text Domain: ma
Tags: custom-background, custom-logo, custom-menu, featured-images, threaded-comments, translation-ready

This theme, like WordPress, is licensed under the GPL.
Use it to make something cool, have fun, and share what you've learned.

Normalizing styles have been helped along thanks to the fine work of
Nicolas Gallagher and Jonathan Neal https://necolas.github.io/normalize.css/
*/

/*--------------------------------------------------------------
>>> TABLE OF CONTENTS:
----------------------------------------------------------------
# Generic
	- Normalize
	- Box sizing
# Base
	- Typography
	- Elements
	- Links
	- Forms
## Layouts
# Components
	- Navigation
	- Posts and pages
	- Comments
	- Widgets
	- Media
	- Captions
	- Galleries
# plugins
	- Jetpack infinite scroll
# Utilities
	- Accessibility
	- Alignments

--------------------------------------------------------------*/

/*--------------------------------------------------------------
# Generic
--------------------------------------------------------------*/

/* Normalize
--------------------------------------------- */

/*! normalize.css v8.0.1 | MIT License | github.com/necolas/normalize.css */

/* Document
	 ========================================================================== */

/**
 * 1. Correct the line height in all browsers.
 * 2. Prevent adjustments of font size after orientation changes in iOS.
 */
html {
    line-height: 1.15;
    -webkit-text-size-adjust: 100%;
    /* Prevent pull-to-refresh on mobile */
    overscroll-behavior-y: none;
}

/* Sections
	 ========================================================================== */

/**
 * Remove the margin in all browsers.
 */
body {
    margin: 0;
    /* Prevent pull-to-refresh and overscroll bounce on mobile */
    overscroll-behavior: none;
    overscroll-behavior-y: none;
    -webkit-overflow-scrolling: touch;
}

/**
 * Render the `main` element consistently in IE.
 */
main {
    display: block;
}

/**
 * Correct the font size and margin on `h1` elements within `section` and
 * `article` contexts in Chrome, Firefox, and Safari.
 */
h1 {
    font-size: 2em;
    margin: 0.67em 0;
}

/* Grouping content
	 ========================================================================== */

/**
 * 1. Add the correct box sizing in Firefox.
 * 2. Show the overflow in Edge and IE.
 */
hr {
    box-sizing: content-box;
    height: 0;
    overflow: visible;
}

/**
 * 1. Correct the inheritance and scaling of font size in all browsers.
 * 2. Correct the odd `em` font sizing in all browsers.
 */
pre {
    font-family: monospace, monospace;
    font-size: 1em;
}

/* Text-level semantics
	 ========================================================================== */

/**
 * Remove the gray background on active links in IE 10.
 */
a {
    background-color: transparent;
}

/**
 * 1. Remove the bottom border in Chrome 57-
 * 2. Add the correct text decoration in Chrome, Edge, IE, Opera, and Safari.
 */
abbr[title] {
    border-bottom: none;
    text-decoration: underline;
    text-decoration: underline dotted;
}

/**
 * Add the correct font weight in Chrome, Edge, and Safari.
 */
b,
strong {
    font-weight: bolder;
}

/**
 * 1. Correct the inheritance and scaling of font size in all browsers.
 * 2. Correct the odd `em` font sizing in all browsers.
 */
code,
kbd,
samp {
    font-family: monospace, monospace;
    font-size: 1em;
}

/**
 * Add the correct font size in all browsers.
 */
small {
    font-size: 80%;
}

/**
 * Prevent `sub` and `sup` elements from affecting the line height in
 * all browsers.
 */
sub,
sup {
    font-size: 75%;
    line-height: 0;
    position: relative;
    vertical-align: baseline;
}

sub {
    bottom: -0.25em;
}

sup {
    top: -0.5em;
}

/* Embedded content
	 ========================================================================== */

/**
 * Remove the border on images inside links in IE 10.
 */
img {
    border-style: none;
}

/* Forms
	 ========================================================================== */

/**
 * 1. Change the font styles in all browsers.
 * 2. Remove the margin in Firefox and Safari.
 */
button,
input,
optgroup,
select,
textarea {
    font-family: inherit;
    font-size: 100%;
    line-height: 1.15;
    margin: 0;
}

/**
 * Show the overflow in IE.
 * 1. Show the overflow in Edge.
 */
button,
input {
    overflow: visible;
}

/**
 * Remove the inheritance of text transform in Edge, Firefox, and IE.
 * 1. Remove the inheritance of text transform in Firefox.
 */
button,
select {
    text-transform: none;
}

/**
 * Correct the inability to style clickable types in iOS and Safari.
 */
button,
[type="button"],
[type="reset"],
[type="submit"] {
    -webkit-appearance: button;
    appearance: button;
}

/**
 * Remove the inner border and padding in Firefox.
 */
button::-moz-focus-inner,
[type="button"]::-moz-focus-inner,
[type="reset"]::-moz-focus-inner,
[type="submit"]::-moz-focus-inner {
    border-style: none;
    padding: 0;
}

/**
 * Restore the focus styles unset by the previous rule.
 */
button:-moz-focusring,
[type="button"]:-moz-focusring,
[type="reset"]:-moz-focusring,
[type="submit"]:-moz-focusring {
    outline: 1px dotted ButtonText;
}

/**
 * Correct the padding in Firefox.
 */
fieldset {
    padding: 0.35em 0.75em 0.625em;
}

/**
 * 1. Correct the text wrapping in Edge and IE.
 * 2. Correct the color inheritance from `fieldset` elements in IE.
 * 3. Remove the padding so developers are not caught out when they zero out
 *		`fieldset` elements in all browsers.
 */
legend {
    box-sizing: border-box;
    color: inherit;
    display: table;
    max-width: 100%;
    padding: 0;
    white-space: normal;
}

/**
 * Add the correct vertical alignment in Chrome, Firefox, and Opera.
 */
progress {
    vertical-align: baseline;
}

/**
 * Remove the default vertical scrollbar in IE 10+.
 */
textarea {
    overflow: auto;
}

/**
 * 1. Add the correct box sizing in IE 10.
 * 2. Remove the padding in IE 10.
 */
[type="checkbox"],
[type="radio"] {
    box-sizing: border-box;
    padding: 0;
}

/**
 * Correct the cursor style of increment and decrement buttons in Chrome.
 */
[type="number"]::-webkit-inner-spin-button,
[type="number"]::-webkit-outer-spin-button {
    height: auto;
}

/**
 * 1. Correct the odd appearance in Chrome and Safari.
 * 2. Correct the outline style in Safari.
 */
[type="search"] {
    -webkit-appearance: textfield;
    appearance: textfield;
    outline-offset: -2px;
}

/**
 * Remove the inner padding in Chrome and Safari on macOS.
 */
[type="search"]::-webkit-search-decoration {
    -webkit-appearance: none;
}

/**
 * 1. Correct the inability to style clickable types in iOS and Safari.
 * 2. Change font properties to `inherit` in Safari.
 */
::-webkit-file-upload-button {
    -webkit-appearance: button;
    font: inherit;
}

/* Interactive
	 ========================================================================== */

/*
 * Add the correct display in Edge, IE 10+, and Firefox.
 */
details {
    display: block;
}

/*
 * Add the correct display in all browsers.
 */
summary {
    display: list-item;
}

/* Misc
	 ========================================================================== */

/**
 * Add the correct display in IE 10+.
 */
template {
    display: none;
}

/**
 * Add the correct display in IE 10.
 */
[hidden] {
    display: none;
}

/* Box sizing
--------------------------------------------- */

/* Inherit box-sizing to more easily change it's value on a component level.
@link http://css-tricks.com/inheriting-box-sizing-probably-slightly-better-best-practice/ */
*,
*::before,
*::after {
    box-sizing: inherit;
}

html {
    box-sizing: border-box;
}

/*--------------------------------------------------------------
# Base
--------------------------------------------------------------*/

/* Typography
--------------------------------------------- */
body,
button,
input,
select,
optgroup,
textarea {
    color: #404040;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Oxygen-Sans, Ubuntu, Cantarell, "Helvetica Neue", sans-serif;
    font-size: 1rem;
    line-height: 1.5;
}

h1,
h2,
h3,
h4,
h5,
h6 {
    clear: both;
}

p {
    margin-bottom: 1.5em;
}

dfn,
cite,
em,
i {
    font-style: italic;
}

blockquote {
    margin: 0 1.5em;
}

address {
    margin: 0 0 1.5em;
}

pre {
    background: #eee;
    font-family: "Courier 10 Pitch", courier, monospace;
    line-height: 1.6;
    margin-bottom: 1.6em;
    max-width: 100%;
    overflow: auto;
    padding: 1.6em;
}

code,
kbd,
tt,
var {
    font-family: monaco, consolas, "Andale Mono", "DejaVu Sans Mono", monospace;
}

abbr,
acronym {
    border-bottom: 1px dotted #666;
    cursor: help;
}

mark,
ins {
    background: #fff9c0;
    text-decoration: none;
}

big {
    font-size: 125%;
}

/* Elements
--------------------------------------------- */
body {
    background: #fff;
}

hr {
    background-color: #ccc;
    border: 0;
    height: 1px;
    margin-bottom: 1.5em;
}

ul,
ol {
    margin: 0 0 1.5em 3em;
}

ul {
    list-style: disc;
}

ol {
    list-style: decimal;
}

li>ul,
li>ol {
    margin-bottom: 0;
    margin-left: 1.5em;
}

dt {
    font-weight: 700;
}

dd {
    margin: 0 1.5em 1.5em;
}

/* Make sure embeds and iframes fit their containers. */
embed,
iframe,
object {
    max-width: 100%;
}

img {
    height: auto;
    max-width: 100%;
}

figure {
    margin: 1em 0;
}

table {
    margin: 0 0 1.5em;
    width: 100%;
}

/* Links
--------------------------------------------- */
a {
    color: #F2D555;
}

a:visited {
    color: #B8930A;
}

a:hover,
a:focus,
a:active {
    color: #FFD700;
}

a:focus {
    outline: thin dotted;
}

a:hover,
a:active {
    outline: 0;
}

/* Forms
--------------------------------------------- */
button,
input[type="button"],
input[type="reset"],
input[type="submit"] {
    border: 1px solid;
    border-color: #ccc #ccc #bbb;
    border-radius: 3px;
    background: #e6e6e6;
    color: rgba(0, 0, 0, 0.8);
    line-height: 1;
    padding: 0.6em 1em 0.4em;
}

button:hover,
input[type="button"]:hover,
input[type="reset"]:hover,
input[type="submit"]:hover {
    border-color: #ccc #bbb #aaa;
}

button:active,
button:focus,
input[type="button"]:active,
input[type="button"]:focus,
input[type="reset"]:active,
input[type="reset"]:focus,
input[type="submit"]:active,
input[type="submit"]:focus {
    border-color: #aaa #bbb #bbb;
}

input[type="text"],
input[type="email"],
input[type="url"],
input[type="password"],
input[type="search"],
input[type="number"],
input[type="tel"],
input[type="range"],
input[type="date"],
input[type="month"],
input[type="week"],
input[type="time"],
input[type="datetime"],
input[type="datetime-local"],
input[type="color"],
textarea {
    color: #666;
    border: 1px solid #ccc;
    border-radius: 3px;
    padding: 3px;
}

input[type="text"]:focus,
input[type="email"]:focus,
input[type="url"]:focus,
input[type="password"]:focus,
input[type="search"]:focus,
input[type="number"]:focus,
input[type="tel"]:focus,
input[type="range"]:focus,
input[type="date"]:focus,
input[type="month"]:focus,
input[type="week"]:focus,
input[type="time"]:focus,
input[type="datetime"]:focus,
input[type="datetime-local"]:focus,
input[type="color"]:focus,
textarea:focus {
    color: #111;
}

select {
    border: 1px solid #ccc;
}

textarea {
    width: 100%;
}

/*--------------------------------------------------------------
# Layouts
--------------------------------------------------------------*/

/*--------------------------------------------------------------
# Components
--------------------------------------------------------------*/

/* Navigation
--------------------------------------------- */
.main-navigation {
    display: block;
    width: 100%;
}

.main-navigation ul {
    display: none;
    list-style: none;
    margin: 0;
    padding-left: 0;
}

.main-navigation ul ul {
    box-shadow: 0 3px 3px rgba(0, 0, 0, 0.2);
    float: left;
    position: absolute;
    top: 100%;
    left: -999em;
    z-index: 99999;
}

.main-navigation ul ul ul {
    left: -999em;
    top: 0;
}

.main-navigation ul ul li:hover>ul,
.main-navigation ul ul li.focus>ul {
    display: block;
    left: auto;
}

.main-navigation ul ul a {
    width: 200px;
}

.main-navigation ul li:hover>ul,
.main-navigation ul li.focus>ul {
    left: auto;
}

.main-navigation li {
    position: relative;
}

.main-navigation a {
    display: block;
    text-decoration: none;
}

/* Small menu. */
.menu-toggle,
.main-navigation.toggled ul {
    display: block;
}

@media screen and (min-width: 37.5em) {

    .menu-toggle {
        display: none;
    }

    .main-navigation ul {
        display: flex;
    }
}

.site-main .comment-navigation,
.site-main .posts-navigation,
.site-main .post-navigation {
    margin: 0 0 1.5em;
}

.comment-navigation .nav-links,
.posts-navigation .nav-links,
.post-navigation .nav-links {
    display: flex;
}

.comment-navigation .nav-previous,
.posts-navigation .nav-previous,
.post-navigation .nav-previous {
    flex: 1 0 50%;
}

.comment-navigation .nav-next,
.posts-navigation .nav-next,
.post-navigation .nav-next {
    text-align: end;
    flex: 1 0 50%;
}

/* Posts and pages
--------------------------------------------- */
.sticky {
    display: block;
}

.post,
.page {
    margin: 0 0 1.5em;
}

.updated:not(.published) {
    display: none;
}

.page-content,
.entry-content,
.entry-summary {
    margin: 1.5em 0 0;
}

.page-links {
    clear: both;
    margin: 0 0 1.5em;
}

/* Comments
--------------------------------------------- */
.comment-content a {
    word-wrap: break-word;
}

.bypostauthor {
    display: block;
}

/* Widgets
--------------------------------------------- */
.widget {
    margin: 0 0 1.5em;
}

.widget select {
    max-width: 100%;
}

/* Media
--------------------------------------------- */
.page-content .wp-smiley,
.entry-content .wp-smiley,
.comment-content .wp-smiley {
    border: none;
    margin-bottom: 0;
    margin-top: 0;
    padding: 0;
}

/* Make sure logo link wraps around logo image. */
.custom-logo-link {
    display: inline-block;
}

/* Theme logo styling (responsive image / custom logo fallback) */
.site-logo {
    display: inline-flex;
    align-items: center;
    text-decoration: none;
}

.site-logo-img {
    display: block;
    max-height: 120px;
    /* Adjust header vertical space */
    height: auto;
    width: auto;
    position: absolute;
    z-index: 10000;
    image-rendering: -webkit-optimize-contrast;
    pointer-events: none;
}

@media (max-width: 640px) {
    .site-logo-img {
        max-height: 100px;
    }
}

@media (max-width: 480px) {
    .site-logo-img {
        max-height: 90px;
    }
}

/* Ensure site title doesn't collide with logo visually */
.site-branding .site-title {
    margin-top: 0.25rem;
}

/* DEBUG: Visual helpers to make the logo obvious while testing visibility issues.



/* Captions
--------------------------------------------- */
.wp-caption {
    margin-bottom: 1.5em;
    max-width: 100%;
}

.wp-caption img[class*="wp-image-"] {
    display: block;
    margin-left: auto;
    margin-right: auto;
}

.wp-caption .wp-caption-text {
    margin: 0.8075em 0;
}

.wp-caption-text {
    text-align: center;
}

/* Galleries
--------------------------------------------- */
.gallery {
    margin-bottom: 1.5em;
    display: grid;
    grid-gap: 1.5em;
}

.gallery-item {
    display: inline-block;
    text-align: center;
    width: 100%;
}

.gallery-columns-2 {
    grid-template-columns: repeat(2, 1fr);
}

.gallery-columns-3 {
    grid-template-columns: repeat(3, 1fr);
}

.gallery-columns-4 {
    grid-template-columns: repeat(4, 1fr);
}

.gallery-columns-5 {
    grid-template-columns: repeat(5, 1fr);
}

.gallery-columns-6 {
    grid-template-columns: repeat(6, 1fr);
}

.gallery-columns-7 {
    grid-template-columns: repeat(7, 1fr);
}

.gallery-columns-8 {
    grid-template-columns: repeat(8, 1fr);
}

.gallery-columns-9 {
    grid-template-columns: repeat(9, 1fr);
}

.gallery-caption {
    display: block;
}

/*--------------------------------------------------------------
# Plugins
--------------------------------------------------------------*/

/* Jetpack infinite scroll
--------------------------------------------- */

/* Hide the Posts Navigation and the Footer when Infinite Scroll is in use. */
.infinite-scroll .posts-navigation,
.infinite-scroll.neverending .site-footer {
    display: none;
}

/* Re-display the Theme Footer when Infinite Scroll has reached its end. */
.infinity-end.neverending .site-footer {
    display: block;
}

/*--------------------------------------------------------------
# Utilities
--------------------------------------------------------------*/

/* Accessibility
--------------------------------------------- */

/* Text meant only for screen readers. */
.screen-reader-text {
    border: 0;
    clip: rect(1px, 1px, 1px, 1px);
    clip-path: inset(50%);
    height: 1px;
    margin: -1px;
    overflow: hidden;
    padding: 0;
    position: absolute !important;
    width: 1px;
    word-wrap: normal !important;
}

.screen-reader-text:focus {
    background-color: #f1f1f1;
    border-radius: 3px;
    box-shadow: 0 0 2px 2px rgba(0, 0, 0, 0.6);
    clip: auto !important;
    clip-path: none;
    color: #21759b;
    display: block;
    font-size: 0.875rem;
    font-weight: 700;
    height: auto;
    left: 5px;
    line-height: normal;
    padding: 15px 23px 14px;
    text-decoration: none;
    top: 5px;
    width: auto;
    z-index: 100000;
}

/* Do not show the outline on the skip link target. */
#primary[tabindex="-1"]:focus {
    outline: 0;
}

/* Alignments
--------------------------------------------- */
.alignleft {

    /*rtl:ignore*/
    float: left;

    /*rtl:ignore*/
    margin-right: 1.5em;
    margin-bottom: 1.5em;
}

.alignright {

    /*rtl:ignore*/
    float: right;

    /*rtl:ignore*/
    margin-left: 1.5em;
    margin-bottom: 1.5em;
}

.aligncenter {
    clear: both;
    display: block;
    margin-left: auto;
    margin-right: auto;
    margin-bottom: 1.5em;
}

/* Performance Optimization: Frozen Grayscale Transition */
.transition-frozen #canvas-container,
.transition-frozen canvas {
    filter: grayscale(100%) brightness(0.9);
    transition: filter 0.3s ease;
    /* Optional: reduce rendering quality/overhead if possible via CSS for some browsers */
    will-change: filter;
}

/* Base styles */
.project-popup {
    position: absolute;
    z-index: 1000;
    background: rgba(0, 0, 0, 0.9);
    color: white;
    border-radius: 8px;
    padding: 15px;
    width: 280px;
    box-shadow: 0 0 20px rgba(0, 0, 0, 0.7);
    display: none;
    opacity: 0;
    transform: scale(0.9);
    transition: opacity 0.3s, transform 0.3s;
}

.project-popup.active {
    opacity: 1;
    transform: scale(1);
}

.project-popup .popup-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 10px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.3);
}

.project-popup h3 {
    margin: 0;
    font-size: 18px;
}

.project-popup .close-popup {
    background: none;
    border: none;
    color: #F2D555;
    font-size: 20px;
    cursor: pointer;
}

.project-popup .project-texture img {
    width: 100%;
    border-radius: 4px;
    margin-bottom: 10px;
}

.project-popup .view-project {
    display: inline-block;
    margin-top: 10px;
    padding: 5px 10px;
    background: #F2D555;
    color: #0B0A21;
    text-decoration: none;
    border-radius: 4px;
    font-weight: 600;
}

.project-popup {
    position: fixed;
    background: rgba(0, 0, 0, 0.9);
    color: white;
    padding: 20px;
    border-radius: 8px;
    pointer-events: all;
    z-index: 1000;
    min-width: 250px;
    max-width: 400px;
    box-shadow: 0 0 15px rgba(0, 0, 0, 0.5);
    transform-origin: top center;
    animation: popupFadeIn 0.3s ease-out;
}

@keyframes popupFadeIn {
    from {
        opacity: 0;
        transform: translate(-50%, -20px);
    }

    to {
        opacity: 1;
        transform: translate(-50%, 0);
    }
}

.project-popup::before {
    content: '';
    position: absolute;
    top: -10px;
    left: 50%;
    transform: translateX(-50%);
    border-left: 10px solid transparent;
    border-right: 10px solid transparent;
    border-bottom: 10px solid rgba(0, 0, 0, 0.9);
}

.project-popup h3 {
    margin: 0 0 10px 0;
    color: #fff;
    font-size: 1.2em;
}

.project-popup p {
    margin: 0 0 15px 0;
    line-height: 1.4;
}

.project-popup .project-meta {
    border-top: 1px solid rgba(255, 255, 255, 0.2);
    border-bottom: 1px solid rgba(255, 255, 255, 0.2);
    padding: 10px 0;
    margin: 10px 0;
}

.project-popup .project-meta p {
    margin: 5px 0;
    font-size: 0.9em;
    color: rgba(255, 255, 255, 0.9);
}

.project-popup .description {
    margin: 15px 0;
    line-height: 1.4;
}

.project-popup .view-project {
    display: inline-block;
    margin-top: 10px;
    color: #fff;
    text-decoration: none;
    border-bottom: 1px solid rgba(255, 255, 255, 0.3);
}

.project-popup .project-meta {
    border-top: 1px solid rgba(255, 255, 255, 0.2);
    padding-top: 10px;
}

.project-popup::after {
    content: '';
    position: absolute;
    bottom: -10px;
    left: 50%;
    transform: translateX(-50%);
    border-left: 10px solid transparent;
    border-right: 10px solid transparent;
    border-top: 10px solid rgba(0, 0, 0, 0.8);
}

.project-popup .close-popup {
    position: absolute;
    top: 5px;
    right: 5px;
    background: none;
    border: none;
    color: #F2D555;
    font-size: 20px;
    cursor: pointer;
    padding: 5px;
    width: 30px;
    height: 30px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    transition: background 0.3s;
}

.project-popup .close-popup:hover {
    background: rgba(255, 255, 255, 0.1);
}

.project-popup .project-texture {
    margin: 10px 0;
    text-align: center;
}

.project-popup .project-texture img {
    max-width: 100%;
    height: auto;
    border-radius: 4px;
    margin-bottom: 15px;
}

#satellite-tooltip {
    z-index: 1000;
    transition: all 0.2s ease;
    font-family: Arial, sans-serif;
    font-size: 14px;
    letter-spacing: 0.5px;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
    pointer-events: none;
    white-space: nowrap;
    background: rgba(0, 0, 0, 0.8);
    color: white;
    padding: 5px 10px;
    border-radius: 4px;
}

/* VOS Tooltip styles */
#vos-tooltip {
    position: absolute;
    background: rgba(25, 25, 35, 0.9);
    color: white;
    padding: 6px 12px;
    border-radius: 6px;
    font-size: 14px;
    pointer-events: none;
    z-index: 9999;
    opacity: 0;
    transition: opacity 0.2s;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.3);
    border: 1px solid rgba(255, 255, 255, 0.2);
    white-space: nowrap;
}

.satellite-popup {
    min-width: 300px;
    max-width: 500px;
    background: rgba(0, 0, 0, 0.95) !important;
}

.satellite-popup .contact-form-container {
    margin-top: 20px;
    min-height: 200px;
}

.satellite-popup .loading {
    text-align: center;
    padding: 20px;
    color: rgba(255, 255, 255, 0.7);
}

.satellite-popup .forminator-ui {
    background: transparent !important;
}

.satellite-popup .forminator-label {
    color: white !important;
}

.satellite-popup .forminator-input,
.satellite-popup .forminator-textarea {
    background-color: rgba(255, 255, 255, 0.1) !important;
    color: white !important;
    border: 1px solid rgba(255, 255, 255, 0.2) !important;
}

.satellite-popup .forminator-button {
    background-color: #F2D555 !important;
    color: #0B0A21 !important;
}

.satellite-popup .forminator-row {
    margin-bottom: 20px !important;
}

.vertical-selector-container {
    position: fixed;
    left: 0;
    right: auto;
    z-index: 1000;
    background-color: rgba(0, 0, 0, 0.5);
    color: white;
    border-radius: 4px;
    padding: 8px;
    min-width: 120px;
    width: auto;
    display: none;
    /* Hidden by default */
    flex-direction: column;
    align-items: center;
    box-shadow: 0 0 10px rgba(0, 0, 0, 0.5);
}

.v-menu-title {
    margin-top: 0;
    margin-bottom: 10px;
    font-size: 16px;
    font-weight: bold;
    text-transform: uppercase;
    letter-spacing: 1px;
    opacity: 0.8;
    text-align: center;
}

.v-menu-up,
.v-menu-down {
    background: rgba(40, 40, 40, 0.8);
    border: 1px solid rgba(255, 255, 255, 0.3);
    color: white;
    width: 30px;
    height: 30px;
    border-radius: 50%;
    margin: 5px 0;
    cursor: pointer;
    transition: background 0.2s;
    font-size: 16px;
    padding: 5px;
    opacity: 0.7;
}

.v-menu-up:hover,
.v-menu-down:hover {
    opacity: 1;
    background: rgba(60, 60, 60, 0.8);
}

.v-menu-up[disabled],
.v-menu-down[disabled],
.v-menu-up:disabled,
.v-menu-down:disabled {
    opacity: 0.3;
    cursor: default;
}

.v-menu-name {
    margin: 5px 0;
    padding: 2px 5px;
    min-height: 20px;
    text-align: center;
    width: 100%;
    font-size: 12px;
    cursor: pointer;
    transition: all 0.2s ease;
    border-radius: 4px;
}

.v-menu-name:hover {
    background: rgba(255, 255, 255, 0.2);
}

.v-menu-name.selected {
    background-color: rgba(51, 153, 255, 0.3);
    box-shadow: 0 0 8px rgba(51, 153, 255, 0.5);
    font-weight: bold;
    color: #3399ff;
}

.v-menu-name.changing {
    transform: scale(1.1);
}

#vos-containers {
    left: 20px !important;
    top: 70px !important;
    transform: none !important;
    right: auto !important;
}

#solar-system-selector-container {
    left: 20px !important;
    right: auto !important;
    display: flex;
    flex-direction: column;
    align-items: center;
    position: fixed;
    top: 50%;
    transform: translateY(-50%);
    z-index: 100;
    background-color: rgba(0, 0, 0, 0.7);
    padding: 10px;
    border-radius: 5px;
    color: white;
    min-width: 150px;
    opacity: 0;
    transition: opacity 0.3s ease-out;
}

/* Position classes for VOS containers */
.vos-top-left {
    left: 20px;
    top: 70px;
    transform: none;
    right: auto;
}

/* Styles to hide UI elements during the intro sequence */
body.intro-active #solar-system-selector-container,
body.intro-active .vertical-selector-component,
body.intro-active #floating-nav-menu {
    display: none !important;
    opacity: 0 !important;
    pointer-events: none !important;
}

/* Vertical Object Selector (VOS) Styles */
.vertical-selector-container {
    position: absolute;
    left: 20px;
    top: 70px;
    z-index: 1000;
    width: 200px;
    display: none;
    flex-direction: column;
    background-color: rgba(0, 0, 0, 0.7);
    border-radius: 8px;
    padding: 12px;
    color: white;
    user-select: none;
    transition: opacity 0.3s ease, transform 0.3s ease;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.3);
    backdrop-filter: blur(5px);
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.vertical-selector-container.active {
    display: flex;
}

/* Prevent pull-to-refresh on VOS panels (mobile fix) */
.vertical-selector-container {
    touch-action: pan-y;
    overscroll-behavior: contain;
    -webkit-overflow-scrolling: touch;
}

/* Experience view specific VOS styling */
body[data-active-view="experience"] .vertical-selector-container {
    padding: 10px !important;
}

/* Disable canvas interactions in Experience view - VOS only */
body[data-active-view="experience"] canvas {
    pointer-events: none !important;
}

.v-menu-title {
    margin: 0 0 10px 0;
    font-size: 14px;
    text-transform: uppercase;
    letter-spacing: 1px;
    opacity: 0.8;
    font-weight: bold;
    text-align: center;
}

.v-menu-up,
.v-menu-down {
    background: rgba(40, 40, 40, 0.8);
    border: 1px solid rgba(255, 255, 255, 0.3);
    color: white;
    width: 30px;
    height: 30px;
    border-radius: 50%;
    margin: 5px 0;
    cursor: pointer;
    transition: background 0.2s;
    font-size: 12px;
    padding: 5px;
    opacity: 0.7;
}

.v-menu-up:hover,
.v-menu-down:hover {
    opacity: 1;
    background: rgba(60, 60, 60, 0.8);
}

.v-menu-up[disabled],
.v-menu-down[disabled],
.v-menu-up:disabled,
.v-menu-down:disabled {
    opacity: 0.3;
    cursor: default;
}

.v-menu-name {
    background: rgba(0, 0, 0, 0.3);
    padding: 8px 10px;
    margin: 5px 0;
    border-radius: 4px;
    text-align: center;
    font-size: 14px;
    cursor: pointer;
    transition: background-color 0.2s;
    min-height: 18px;
}

.v-menu-name.highlighted {
    background: rgba(0, 120, 255, 0.4);
}

.v-menu-name.selected {
    background: rgba(0, 180, 255, 0.6);
    font-weight: bold;
}

.v-menu-name:hover {
    background: rgba(0, 140, 255, 0.5);
}

/* Animation classes for changing items */
.v-menu-name.changing-up {
    animation: slideUp 0.3s ease-out;
}

.v-menu-name.changing-down {
    animation: slideDown 0.3s ease-out;
}

@keyframes slideUp {
    0% {
        transform: translateY(5px);
        opacity: 0.5;
    }

    100% {
        transform: translateY(0);
        opacity: 1;
    }
}

@keyframes slideDown {
    0% {
        transform: translateY(-5px);
        opacity: 0.5;
    }

    100% {
        transform: translateY(0);
        opacity: 1;
    }
}

/* Experience View Radio Button Selector Styles */
.radio-button-selector {
    max-width: 250px;
    min-width: 200px;
    border-left: 1px solid rgba(227, 182, 0, 0.3);
}

.radio-button-container {
    display: flex;
    flex-direction: column;
    width: 100%;
    margin-top: 10px;
}

.radio-item-wrapper {
    display: flex;
    align-items: center;
    padding: 8px 12px;
    border-radius: 4px;
    margin-bottom: 5px;
    transition: all 0.2s ease;
    border-left: 3px solid transparent;
}

.radio-item-wrapper:hover {
    background-color: rgba(227, 182, 0, 0.15);
}

.radio-item-wrapper.active {
    background-color: rgba(227, 182, 0, 0.2);
    border-left: 3px solid #F2D555;
}

.radio-item-wrapper input[type="radio"] {
    accent-color: #F2D555;
    margin-right: 8px;
}

.radio-item-wrapper label {
    cursor: pointer;
    font-size: 14px;
    font-weight: normal;
    flex-grow: 1;
    color: rgba(255, 255, 255, 0.9);
}

.radio-item-wrapper:hover label {
    color: #F2D555;
}

.radio-button-selector .v-menu-title {
    margin-top: 0;
    margin-bottom: 10px;
    text-align: center;
    border-bottom: 1px solid rgba(227, 182, 0, 0.3);
    padding-bottom: 8px;
    color: #F2D555;
}

/* Custom Moon Popup Styles */
.project-popup-floating.custom-moon-popup {
    background: #0B0A21;
    color: #fff;
    border-radius: 12px;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.45);
    padding: 24px 18px 18px 18px;
    min-width: 340px;
    max-width: 370px;
    font-family: 'Inter', Arial, sans-serif;
    z-index: 20000;
    /* Exit state/Base state */
    opacity: 0;
    pointer-events: none;
    transform: translateY(-60%) scale(0.95);
    transition: transform 0.3s cubic-bezier(0.16, 1, 0.3, 1), opacity 0.3s ease-out;
}

/* Fixed Left Aligned Panel for Desktop/Tablet */
.project-popup-floating.custom-moon-popup.left-aligned-panel {
    position: fixed;
    left: 40px;
    top: 50%;
    transform: translateY(-60%) scale(0.95);
}

.project-popup-floating.custom-moon-popup.left-aligned-panel.active {
    transform: translateY(-50%) translateX(0) scale(1);
    opacity: 1;
    pointer-events: auto;
}

/* Tablet optimization: slight adjustment for narrower screens */
@media screen and (min-width: 768px) and (max-width: 1024px) {
    .project-popup-floating.custom-moon-popup.left-aligned-panel {
        left: 20px;
    }
}





.project-popup-floating .popup-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 12px;
}

.project-popup-floating .popup-title {
    font-size: 1.35rem;
    font-weight: 600;
    color: #4ea1ff;
}

.project-popup-floating .close-popup {
    background: none;
    border: none;
    color: #F2D555;
    font-size: 1.4rem;
    cursor: pointer;
    padding: 0 6px;
    line-height: 1;
}

.project-popup-floating .popup-image-row {
    display: flex;
    justify-content: center;
    margin-bottom: 16px;
}

.project-popup-floating .popup-image {
    border-radius: 8px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15);
    background: #222;
}

.project-popup-floating .popup-section {
    margin-bottom: 12px;
}

.project-popup-floating .popup-label {
    color: #5faaff;
    font-weight: 600;
    font-size: 1rem;
    margin-bottom: 2px;
}

.project-popup-floating .popup-value {
    color: #e0e6f3;
    font-size: 0.98rem;
    margin-bottom: 2px;
}

.project-popup-floating .popup-divider {
    border: none;
    border-top: 1px solid #22304a;
    margin: 18px 0 12px 0;
}

.project-popup-floating .popup-action {
    width: 100%;
    background: #4ea1ff;
    color: #fff;
    border: none;
    border-radius: 6px;
    display: block;
    text-align: center;
    padding: 10px 0;
    font-size: 1.08rem;
    font-weight: 600;
    margin-bottom: 10px;
    cursor: pointer;
    transition: background 0.2s;
}

.project-popup-floating .popup-action:hover {
    background: #3578c6;
}

.project-popup-floating .popup-close-details {
    width: 100%;
    background: #232c3d;
    color: #F2D555;
    border: none;
    border-radius: 6px;
    padding: 10px 0;
    font-size: 1.08rem;
    font-weight: 600;
    cursor: pointer;
    transition: background 0.2s;
}

.project-popup-floating .popup-close-details:hover {
    background: #1a2233;
}

/* New Compact VOS Styles for Projects View - now GLOBAL (not just mobile) */
#vertical-selector-projects,
.vertical-selector-container {
    position: fixed !important;
    right: 10px !important;
    left: auto !important;
    top: 50% !important;
    bottom: auto !important;
    transform: translateY(-50%) !important;
    width: auto !important;
    min-width: auto !important;
    max-width: none !important;
    padding: 0 !important;
    z-index: 2001;
    align-items: center !important;
    transition: all 0.3s ease-out !important;
    display: flex;
    flex-direction: column;
}

.compact-vos-row {
    flex-direction: column;
    width: auto;
    margin: 0;
    padding: 10px 5px;
    background-color: rgba(30, 30, 40, 0.95);
    border: 1px solid rgba(255, 255, 255, 0.15);
    border-radius: 20px;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.3);
    display: flex;
    align-items: center;
}

.vos-nav-button {
    padding: 8px 0;
    margin: 5px 0;
    background: none;
    border: none;
    color: #b0b8c7;
    cursor: pointer;
    font-size: 18px;
    line-height: 1;
    transition: color 0.2s;
}

.vos-nav-button:hover {
    color: #ffffff;
}

/* Fallback: Hide WordPress emoji images if they are still inserted */
.vos-nav-button img.emoji {
    display: none !important;
}

.vos-nav-button.no-emoji::after {
    display: none !important;
}

.vos-current-project,
.vos-current-item {
    margin: 8px 0;
    width: 34px;
    height: 34px;
    border-radius: 50%;
    background: rgba(50, 50, 70, 0.7);
    display: flex;
    justify-content: center;
    align-items: center;
}

.vos-project-name-display {
    max-width: none;
    font-size: 14px;
    font-weight: 600;
    letter-spacing: 0.5px;
}

.vos-expand-icon {
    display: none;
}

/* Filters Component */
.vos-projects-filters {
    position: absolute;
    top: 50%;
    right: 100%;
    transform: translateY(-50%);
    margin-right: 10px;
    /* Offset to the left of the root toggle */
    width: 140px;
    border-radius: 12px;
    background-color: rgba(35, 35, 45, 0.95);
    z-index: 10;
    padding: 0;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
    border: 1px solid rgba(255, 255, 255, 0.1);
    flex-direction: column;
    overflow: hidden;
}

.vos-filter-btn {
    position: relative;
    background: transparent;
    border: none;
    color: #c5cde0;
    padding: 9px 12px;
    font-size: 13px;
    text-align: left;
    cursor: pointer;
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
    transition: background-color 0.2s, color 0.2s;
    font-family: inherit;
    width: 100%;
    outline: none;
    box-sizing: border-box;
}

.vos-filter-btn:last-child {
    border-bottom: none;
}

.vos-filter-btn:hover {
    background-color: rgba(255, 255, 255, 0.1);
    color: #ffffff;
}

.vos-filter-btn.active {
    color: #66bb6a;
    font-weight: 600;
}

.vos-filter-btn.active::after {
    content: "✓";
    color: #66bb6a;
    font-size: 14px;
    min-width: 1em;
    text-align: right;
}

.vos-project-list {
    position: absolute;
    top: 50%;
    right: 100%;
    left: auto;
    transform: translateY(-50%);
    margin-right: 10px;
    /* Default space without filters */
    margin-bottom: 0;
    width: 180px;
    max-width: 70vw;
    border-radius: 12px;
    background-color: rgba(35, 35, 45, 0.95);
    z-index: 10;
    list-style: none;
    padding: 0;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
    border: 1px solid rgba(255, 255, 255, 0.1);
    display: none;
    max-height: 60vh;
    overflow-y: auto;
}

.vos-project-list.has-filters {
    margin-right: 160px;
    /* Space between filter list and dropdown */
}

.vos-project-list.expanded {
    display: block;
}

@keyframes vosItemFadeIn {
    from {
        opacity: 0;
        transform: translateY(-5px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.vos-project-item {
    padding: 9px 12px;
    color: #c5cde0;
    cursor: pointer;
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 13px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
    transition: background-color 0.2s;
    opacity: 0;
    /* Starts hidden for animation */
    animation: vosItemFadeIn 0.3s ease forwards;
}

.vos-project-item:last-child {
    border-bottom: none;
}

.vos-project-item:hover {
    background-color: rgba(255, 255, 255, 0.1);
    color: #ffffff;
}

.vos-project-item .vos-project-item-name {
    flex-grow: 1;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.vos-project-item .vos-checkmark {
    margin-left: auto;
    margin-left: 10px;
    font-size: 14px;
    color: #66bb6a;
    /* Greenish checkmark */
    min-width: 1em;
    /* Reserve space for checkmark */
    text-align: right;
}

/* Hide old VOS elements if they are still somehow rendered or for other views */
#vertical-selector-projects .v-menu-title,
#vertical-selector-projects #vos-projects-dropdown,
#vertical-selector-projects .v-menu-up,
#vertical-selector-projects .v-menu-down {
    display: none !important;
    /* Legacy elements hidden; explicit rule prevents empty ruleset */
}

/* Custom scrollbar for the list (optional) */
.vos-project-list::-webkit-scrollbar {
    width: 6px;
}

.vos-project-list::-webkit-scrollbar-track {
    background: rgba(0, 0, 0, 0.1);
    border-radius: 6px;
}

.vos-project-list::-webkit-scrollbar-thumb {
    background: rgba(255, 255, 255, 0.2);
    border-radius: 6px;
}

.vos-project-list::-webkit-scrollbar-thumb:hover {
    background: rgba(255, 255, 255, 0.3);
}

/* Mobile Project Details Slider */
.project-details-slider {
    position: fixed;
    bottom: 0;
    left: 0;
    width: 100%;
    background-color: #0B0A21;
    color: #e0e6f3;
    box-shadow: 0 -4px 20px rgba(0, 0, 0, 0.3);
    z-index: 20000;
    transform: translateY(100%);
    transition: transform 0.3s cubic-bezier(0.16, 1, 0.3, 1);
    height: 100% !important;
    display: flex !important;
    flex-direction: column !important;
    overflow: hidden !important;
    border-top-left-radius: 16px;
    border-top-right-radius: 16px;
    font-family: 'Inter', Arial, sans-serif;
    touch-action: pan-y;
    overscroll-behavior: contain;
    padding-bottom: env(safe-area-inset-bottom, 16px);
}

.project-details-slider::-webkit-scrollbar {
    display: none;
    /* WebKit (Chrome, Safari) */
}

.project-details-slider.active {
    transform: translateY(0);
}

.project-details-slider .slider-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 12px 16px;
    border-bottom: 1px solid #22304a;
    flex-shrink: 0;
}

/* Inline VOS navigation inside the mobile slider - sits on the 'Project Overview' label row */
.slider-label-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 4px;
}

.slider-label-row.slider-label-vos-wrapper {
    display: flex;
    align-items: baseline;
}

.panel-vos-nav {
    display: flex;
    align-items: center;
    gap: 4px;
    flex-shrink: 0;
}

.panel-vos-nav .vos-nav-button {
    writing-mode: initial;
    width: 35px;
    height: 35px;
    color: #F2D555;
    padding: 0;
    font-size: 20px;
    line-height: 1;
    display: flex;
    align-items: center;
    justify-content: center;
}

.panel-vos-nav .vos-current-project {
    width: 34px;
    height: 34px;
    border-radius: 50%;
    background: rgba(50, 50, 70, 0.85);
    border: 1px solid rgba(78, 161, 255, 0.4);
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: not-allowed;
    flex-shrink: 0;
    opacity: 0.5;
    pointer-events: none;
    position: relative;
}

/* Hide dot and tooltip for inline panel VOS */
.panel-vos-nav .vos-current-project:before,
.panel-vos-nav .vos-current-project:after {
    display: none !important;
}

.panel-vos-nav .vos-project-name-display {
    font-size: 14px;
    font-weight: 700;
    color: #F2D555;
    letter-spacing: 0.5px;
    line-height: 1;
}

.project-details-slider .slider-title {
    font-size: 1.2rem;
    font-weight: 600;
    color: #4ea1ff;
}

.project-details-slider .close-slider {
    background: none;
    border: none;
    color: #F2D555;
    font-size: 1.5rem;
    cursor: pointer;
    padding: 0 8px;
    line-height: 1;
}

.project-details-slider .slider-content {
    padding: 16px;
    display: flex;
    flex-direction: column;
    flex-grow: 1;
    min-height: 0;
    overflow: hidden;
}

.project-details-slider .slider-image {
    width: 100%;
    max-height: 200px;
    object-fit: cover;
    border-radius: 8px;
    background: #222;
    /* Placeholder background for image */
}

/* Archived Project Media Container */
.project-media-container {
    position: relative;
    width: 100%;
    margin-bottom: 16px;
    min-height: 200px;
    /* Prevent collapse during transition */
    background: #111;
    /* Dark background for smooth fade */
    border-radius: 8px;
    overflow: hidden;
}

.project-hero-wrapper,
.project-archived-slider-wrapper {
    width: 100%;
    transition: opacity 0.3s ease-in-out;
    opacity: 0;
}

/* Initially visible one should have active class or be handled via JS adding active */
.project-hero-wrapper {
    display: block;
    /* Default visible */
    opacity: 1;
    /* Default visible */
}

.project-hero-wrapper.active,
.project-archived-slider-wrapper.active {
    opacity: 1;
}

/* Ensure hidden elements are truly hidden/transparent for transition */
.project-hero-wrapper:not(.active),
.project-archived-slider-wrapper:not(.active) {
    opacity: 0;
}

.gallery-toggle-btn.showing-gallery {
    background: #555 !important;
    color: #fff !important;
}

/* Button Icon Styling */
.btn-icon {
    font-size: 1.2em;
    vertical-align: middle;
    margin-right: 6px;
    line-height: 1;
    display: inline-block;
}

/* Gold Icon for Live Projects */
.live-project-btn .btn-icon {
    color: #F2D555;
    text-shadow: 0 0 5px rgba(242, 213, 85, 0.4);
}

/* Unified Media Container for Top Hero */
.project-media-container {
    position: relative;
    width: 100%;
    /* Consistent ratio ensures labels don't move */
    background: #111;
    border-radius: 8px;
    overflow: hidden;
    margin-bottom: 16px;
}

.project-media-container img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

/* Bottom Gallery Styling */
.project-archived-slider-wrapper.bottom-gallery {
    margin-top: 16px;
    background: #111;
    border-radius: 8px;
    padding: 0;
    border: 1px solid rgba(242, 213, 85, 0.2);
    /* Transition for sliding in/out */
    transition: opacity 0.3s ease-in-out, transform 0.3s ease-out;
    transform: translateY(10px);
}

.project-archived-slider-wrapper.bottom-gallery.active {
    opacity: 1;
    transform: translateY(0);
}

/* Ensure Popup Width stays consistent */
.project-popup-floating.custom-moon-popup {
    width: 450px !important;
    max-width: 90vw;
}

.project-details-slider .slider-section {
    margin-bottom: 12px;
}

.project-details-slider .slider-label {
    color: #5faaff;
    /* Match existing popup label color */
    font-weight: 600;
    font-size: 1.1rem;
    margin-bottom: 8px;
    font-family: 'Rajdhani', sans-serif !important;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.project-details-slider .slider-value {
    color: #e0e6f3;
    /* Match existing popup value color */
    font-size: 1rem;
    line-height: 1.6;
}

/* Project Details Layout Refinement */
div#project-details-popup {
    height: 90vh !important;
    max-height: 90vh !important;
    display: flex !important;
    flex-direction: column !important;
    overflow: hidden !important;
}

div#project-details-popup::-webkit-scrollbar {
    display: none;
    /* WebKit (Chrome, Safari) */
}

#project-details-slider {
    height: 100%;
}



/* Drag to Scroll Interaction */
.drag-to-scroll {
    cursor: grab;
    user-select: none;
    /* Prevent text selection during drag */
    -webkit-user-select: none;
    -moz-user-select: none;
    -ms-user-select: none;
}

.drag-to-scroll.grabbing {
    cursor: grabbing !important;
}

.drag-to-scroll * {
    /* Ensure children don't interfere with grab cursor, but keep buttons/links interactive */
    pointer-events: auto;
}

.drag-to-scroll a,
.drag-to-scroll button {
    cursor: pointer;
}

/* Project Key Features List */
.ma-key-features-list {
    margin: 10px 0 0 0;
    padding: 0;
    list-style: none;
}

.ma-key-features-list li {
    position: relative;
    padding-left: 20px;
    margin-bottom: 8px;
    color: #e0e6f3;
    font-size: 0.9rem;
    line-height: 1.4;
}

.ma-key-features-list li::before {
    content: "▹";
    position: absolute;
    left: 0;
    color: var(--hud-gold);
    font-weight: bold;
}

.project-details-slider .slider-divider {
    border: none;
    border-top: 1px solid #22304a;
    /* Match existing popup divider */
    margin: 16px 0;
}

.project-details-slider .slider-action {
    width: 100%;
    background: #4ea1ff;
    /* Match existing popup action button */
    color: #fff;
    border: none;
    border-radius: 6px;
    padding: 12px 0;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: background 0.2s;
    text-align: center;
    display: block;
    /* Ensure it takes full width */
    text-decoration: none;
    /* If used as a link */
}

.project-details-slider .slider-action:hover {
    background: #3578c6;
    /* Match existing popup action button hover */
}

/* Skills view: ensure the details panel close button is visible (white) */
.skills-view-details-panel .details-close-button {
    color: #F2D555;
    background: none;
    border: none;
    text-shadow: 0 1px 0 rgba(0, 0, 0, 0.25);
}

.skills-view-details-panel .details-close-button:hover,
.skills-view-details-panel .details-close-button:focus {
    color: #FFD700;
    opacity: 0.95;
}

div#floating-nav-menu button.nav-item {
    min-width: 50px;
}

/* Helper class to hide FNM when slider is active */
body.fnm-hidden-by-slider #floating-nav-menu {
    opacity: 0 !important;
    pointer-events: none !important;
    transition: opacity 0.3s ease-in-out !important;
}

/* Helper class to hide FNM when sub-skills popup is active */
body.fnm-hidden-by-skills-popup #floating-nav-menu {
    opacity: 0 !important;
    pointer-events: none !important;
    transition: opacity 0.3s ease-in-out !important;
}

/* Mobile VOS Bar (shown above FNM) */
@media (max-width: 767px) {

    /* Default VOS position (vertical, right side, vertically centered) */
    #vertical-selector-projects {
        right: 10px !important;
        left: auto !important;
        top: 50% !important;
        bottom: auto !important;
        transform: translateY(-50%) !important;
        width: auto !important;
        min-width: auto !important;
        max-width: none !important;
        padding: 0 !important;
        z-index: 20000 !important;
        /* Above slider (1999) */
        align-items: center !important;
        transition: all 0.3s ease-out !important;
    }

    /* Vertical arrangement for compact VOS row */
    .compact-vos-row {
        flex-direction: column;
        width: auto;
        margin: 0;
        padding: 10px 5px;
        background-color: rgba(30, 30, 40, 0.95);
        border: 1px solid rgba(255, 255, 255, 0.15);
        border-radius: 20px;
        /* More rounded */
        box-shadow: 0 4px 10px rgba(0, 0, 0, 0.3);
    }

    /* Adjust nav buttons to be up/down */
    .vos-nav-button {
        padding: 8px 0;
        margin: 5px 0;
    }

    /* Center project initial display */
    .vos-current-project,
    .vos-current-item {
        margin: 8px 0;
        width: 34px;
        height: 34px;
        border-radius: 50%;
        background: rgba(50, 50, 70, 0.7);
        display: flex;
        justify-content: center;
        align-items: center;
    }

    /* Project initials style */
    .vos-project-name-display {
        max-width: none;
        font-size: 14px;
        font-weight: 600;
        letter-spacing: 0.5px;
    }

    /* Hide the expand icon when in vertical mode */
    .vos-expand-icon {
        display: none;
    }

    /* Position dropdown to the left of the selector */
    .vos-project-list {
        position: absolute;
        top: 50%;
        right: 100%;
        /* Position to the left */
        left: auto;
        transform: translateY(-50%);
        margin-right: 10px;
        /* Space between selector and dropdown */
        margin-bottom: 0;
        width: 180px;
        max-width: 70vw;
        border-radius: 12px;
    }

    /* Move VOS when slider is active */
    body.slider-open #vertical-selector-projects {
        right: 10px !important;
        left: auto !important;
        top: auto !important;
        bottom: 90px !important;
        transform: none !important;
    }

    /* Combined fix: VOS height restriction */
    body.slider-open .compact-vos-row {
        max-height: 140px;
        justify-content: center;
    }
}

/* Solar System VOS Dropdown Styling */
#vertical-selector-solar .vos-item-list {
    display: none !important;
}

/* Improve the central button style for solar view */
#vertical-selector-solar .vos-current-item {
    cursor: pointer;
    background-color: rgba(60, 60, 80, 0.8);
    transition: background-color 0.2s;
}

#vertical-selector-solar .vos-current-item:hover {
    background-color: rgba(80, 80, 100, 0.9);
}

/* Add tooltip styling for better UX */
#vertical-selector-solar .vos-current-item:after {
    content: 'Click to navigate';
    position: absolute;
    background: rgba(0, 0, 0, 0.7);
    color: white;
    padding: 5px 8px;
    border-radius: 4px;
    font-size: 12px;
    right: 120%;
    top: 50%;
    transform: translateY(-50%);
    white-space: nowrap;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.2s, visibility 0.2s;
}

#vertical-selector-solar .vos-current-item:hover:after {
    opacity: 1;
    visibility: visible;
}

/* Add this to your theme's CSS */
#vertical-selector-about {
    display: none !important;
}

/* Experience View Company Detail Panel */
.company-detail-panel {
    z-index: 10000 !important;
    /* Prevent pull-to-refresh on mobile */
    touch-action: pan-y;
    overscroll-behavior: contain;
}

@media screen and (orientation: landscape) {
    .company-detail-panel {
        transform: translateX(-50%) translateY(0px) scale(0.8) !important;
    }
}

/* Ensure FNM has lower z-index when experience details are shown */
body:has(.company-detail-panel) #floating-nav-menu {
    z-index: 10000 !important;
}

/* Alternative approach if :has() is not supported in older browsers */
.experience-details-active #floating-nav-menu {
    z-index: 10000 !important;
}

/* Add these styles to enhance visibility of VOS middle button interactivity */
.vos-current-item,
.v-menu-name {
    /* Add a subtle but visible border glow - Cosmic Gold (STATIC OPTIMIZATION) */
    /* Was animating box-shadow infinitely, causing 7% CPU load. Replaced with static nice glow. */
    box-shadow: 0 0 0 1px rgba(227, 182, 0, 0.6),
        0 0 12px rgba(227, 182, 0, 0.4);

    /* More prominent background gradient to suggest interactivity */
    background: linear-gradient(to bottom, rgba(11, 10, 33, 0.9), rgba(20, 18, 50, 0.9));

    /* Removed expensive pulse-glow animation */
    /* animation: pulse-glow 2s infinite ease-in-out; */

    /* Add a subtle icon to indicate clickability */
    position: relative;
}

/* Add a small clickable indicator icon - Cosmic Gold */
.vos-current-item:before,
.v-menu-name:before {
    content: "⊙";
    /* Using a dot/target symbol */
    position: absolute;
    right: -4px;
    top: -4px;
    background: rgba(227, 182, 0, 0.9);
    color: rgba(11, 10, 33, 0.95);
    width: 16px;
    height: 16px;
    font-size: 10px;
    line-height: 16px;
    text-align: center;
    border-radius: 50%;
    animation: blink-subtle 3s infinite;
}

/* Enhance hover state - Cosmic Gold */
.vos-current-item:hover,
.v-menu-name:hover {
    transform: scale(1.08);
    box-shadow: 0 0 0 2px rgba(227, 182, 0, 0.6), 0 0 12px rgba(227, 182, 0, 0.4);
    background: linear-gradient(to bottom, rgba(30, 28, 60, 0.95), rgba(20, 18, 50, 0.95));
}

/* Pulse animation - Cosmic Gold (REMOVED FOR PERFORMANCE) */
/* @keyframes pulse-glow { ... } */


/* Blinking indicator animation */
@keyframes blink-subtle {

    0%,
    80%,
    100% {
        opacity: 0.7;
    }

    40% {
        opacity: 1;
    }
}

/* Explicit "Click for details" tooltip - Cosmic Gold */
.vos-current-item:after,
.v-menu-name:after {
    content: 'Click for details';
    position: absolute;
    background: rgba(11, 10, 33, 0.95);
    color: #F2D555;
    padding: 6px 10px;
    border-radius: 4px;
    font-size: 12px;
    font-weight: 500;
    right: 120%;
    top: 50%;
    transform: translateY(-50%);
    white-space: nowrap;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.2s, visibility 0.2s;
    box-shadow: 0 0 8px rgba(0, 0, 0, 0.3), 0 0 0 1px rgba(227, 182, 0, 0.3);
    z-index: 1010;
}

.vos-current-item:hover:after,
.v-menu-name:hover:after {
    opacity: 1;
    visibility: visible;
}

/* Enhanced interactivity for Projects View VOS middle button - Cosmic Gold */
.vos-current-project,
#vertical-selector-projects .vos-current-item {
    /* Add a subtle but visible border glow */
    box-shadow: 0 0 0 1px rgba(227, 182, 0, 0.4), 0 0 8px rgba(227, 182, 0, 0.2);

    /* More prominent background gradient to suggest interactivity */
    background: linear-gradient(to bottom, rgba(11, 10, 33, 0.9), rgba(20, 18, 50, 0.9));

    /* Removed expensive pulse-glow animation */
    /* animation: pulse-glow 2s infinite ease-in-out; */

    /* Add a subtle icon to indicate clickability */
    position: relative;
}

/* Add a small clickable indicator icon - Cosmic Gold */
.vos-current-project:before,
#vertical-selector-projects .vos-current-item:before {
    content: "⊙";
    position: absolute;
    right: -4px;
    top: -4px;
    background: rgba(227, 182, 0, 0.9);
    color: rgba(11, 10, 33, 0.95);
    width: 16px;
    height: 16px;
    font-size: 10px;
    line-height: 16px;
    text-align: center;
    border-radius: 50%;
    animation: blink-subtle 3s infinite;
}

/* Enhance hover state - Cosmic Gold */
.vos-current-project:hover,
#vertical-selector-projects .vos-current-item:hover {
    transform: scale(1.08);
    box-shadow: 0 0 0 2px rgba(227, 182, 0, 0.6), 0 0 12px rgba(227, 182, 0, 0.4);
    background: linear-gradient(to bottom, rgba(30, 28, 60, 0.95), rgba(20, 18, 50, 0.95));
}

/* Add Projects View specific tooltip - Cosmic Gold */
.vos-current-project:after,
#vertical-selector-projects .vos-current-item:after {
    content: 'View project details';
    position: absolute;
    background: rgba(11, 10, 33, 0.95);
    color: #F2D555;
    padding: 6px 10px;
    border-radius: 4px;
    font-size: 12px;
    font-weight: 500;
    right: 120%;
    top: 50%;
    transform: translateY(-50%);
    white-space: nowrap;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.2s, visibility 0.2s;
    box-shadow: 0 0 8px rgba(0, 0, 0, 0.3), 0 0 0 1px rgba(227, 182, 0, 0.3);
    z-index: 1010;
}

/* Show tooltip on hover */
.vos-current-project:hover:after,
#vertical-selector-projects .vos-current-item:hover:after {
    opacity: 1;
    visibility: visible;
}

/* Hide tooltip when the projects list is expanded */
#vos-projects-compact-row:has(+ .vos-project-list.expanded) .vos-current-project:hover:after,
#vos-projects-compact-row:has(+ .vos-project-list.expanded) .vos-current-item:hover:after {
    opacity: 0;
    visibility: hidden;
}

/* Alternative solution using parent selector logic for broader browser support */
.vos-project-list.expanded~#vos-projects-compact-row .vos-current-project:after,
.vos-project-list.expanded~#vos-projects-compact-row .vos-current-item:after,
.compact-vos-row:has(+ .vos-project-list.expanded) .vos-current-project:after,
.compact-vos-row:has(+ .vos-project-list.expanded) .vos-current-item:after {
    display: none;
}

/* For browsers that don't support :has selector, add this class via JavaScript */
.tooltip-disabled .vos-current-project:hover:after,
.tooltip-disabled .vos-current-item:hover:after {
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
}

/* Re-center view button */
.reset-view-btn {
    position: absolute;
    bottom: 80px;
    right: 20px;
    z-index: 1001;
    background: rgba(11, 10, 33, 0.85);
    color: #F2D555;
    border: 2px solid #F2D555;
    border-radius: 50%;
    width: 60px;
    height: 60px;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 0 20px rgba(227, 182, 0, 0.3);
    cursor: pointer;
    opacity: 0;
    transform: scale(0.8);
    pointer-events: none;
    transition: opacity 0.3s ease, transform 0.3s ease, box-shadow 0.2s;
    animation: pulse-glow-gold 2s infinite ease-in-out;
    backdrop-filter: blur(10px);
}

/* Enhance reset camera button to match VOS middle button */
.reset-view-btn {
    /* Existing styles... */
    position: absolute;
    bottom: 80px;
    right: 20px;
    z-index: 1001;
    background: rgba(11, 10, 33, 0.85);
    color: #F2D555;
    border: 2px solid #F2D555;
    border-radius: 50%;
    width: 60px;
    height: 60px;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 0 20px rgba(227, 182, 0, 0.3);
    cursor: pointer;
    opacity: 0;
    transform: scale(0.8);
    pointer-events: none;
    transition: opacity 0.3s ease, transform 0.3s ease, box-shadow 0.2s;
    animation: pulse-glow-gold 2s infinite ease-in-out;
    backdrop-filter: blur(10px);
}


/* Pulse animation - Cosmic Gold */
@keyframes pulse-glow-gold {
    0% {
        box-shadow: 0 0 15px rgba(227, 182, 0, 0.3);
    }

    50% {
        box-shadow: 0 0 25px rgba(227, 182, 0, 0.5);
    }

    100% {
        box-shadow: 0 0 15px rgba(227, 182, 0, 0.3);
    }
}

/* Blinking indicator animation (already defined, but ensure it's present) */
@keyframes blink-subtle {

    0%,
    80%,
    100% {
        opacity: 0.7;
    }

    40% {
        opacity: 1;
    }
}

.reset-view-btn.visible {
    opacity: 1;
    transform: scale(1);
    pointer-events: auto;
}

.reset-view-btn:hover {
    background: rgba(227, 182, 0, 0.2);
    box-shadow: 0 0 35px rgba(227, 182, 0, 0.6);
    border-color: #F2D555;
}

.reset-view-btn:active {
    transform: scale(0.95);
}

/* Hide reset button in Experience view */
body[data-active-view="experience"] .reset-view-btn,
body[data-active-view="experience"] #reset-view-btn {
    display: none !important;
}

/* Improved FNM label display for mobile */
@media (max-width: 767px) {

    /* Increase nav-item width when expanded */
    #floating-nav-menu .nav-item:hover {
        min-width: 50px;
        max-width: none;
        /* Allow natural expansion */
    }

    /* Ensure labels have enough space on mobile */
    #floating-nav-menu .nav-label {
        max-width: 0;
        transition: opacity 0.3s, max-width 0.3s;
    }

    #floating-nav-menu .nav-item:hover .nav-label,
    #floating-nav-menu .nav-item:focus .nav-label {
        max-width: 200px !important;
        /* Force override any inline styles */
    }
}

/* FNM Touch Screen Enhancements - Permanent labels below buttons */
@media (hover: none) and (pointer: coarse),
(max-width: 768px) {

    /* Restructure FNM items to stack icon and label vertically */
    #floating-nav-menu .nav-item {
        flex-direction: column;
        padding: 8px 6px !important;
        min-width: auto !important;
        width: auto !important;
        gap: 4px !important;
        align-items: center;
        justify-content: center;
    }

    /* Show labels permanently */
    #floating-nav-menu .nav-label {
        opacity: 1 !important;
        max-width: none !important;
        font-size: 10px !important;
        letter-spacing: 0.2px;
        font-weight: 500;
        white-space: nowrap;
        text-align: center;
        color: #dde4ff;
    }

    /* Adjust icon spacing */
    #floating-nav-menu .nav-item span:first-child {
        margin: 0 !important;
    }

    /* Adjust container sizing for the new layout */
    #floating-nav-menu {
        padding: 8px 10px !important;
        gap: 8px !important;
        /* Prevent pull-to-refresh on mobile */
        touch-action: manipulation;
        overscroll-behavior: contain;
    }

    /* Disable hover effects since they don't apply on touch devices */
    #floating-nav-menu .nav-item:hover {
        transform: none !important;
    }

    /* Make active state more visible with a glow effect */
    #floating-nav-menu .nav-item[style*="background-color: rgba(255, 255, 255, 0.3)"] {
        background-color: rgba(78, 161, 255, 0.3) !important;
        box-shadow: 0 0 8px rgba(78, 161, 255, 0.4) !important;
    }

    /* Set explicit width for better spacing */
    #floating-nav-menu .nav-item {
        width: auto !important;
        min-width: 48px !important;
    }
}

/* Desktop Contact CTA (scoped to the button only) */
#desktop-contact-button {
    position: fixed;
    bottom: 24px;
    right: 24px;
    background: linear-gradient(90deg, rgba(227, 182, 0, 0.1), transparent);
    border: 1px solid var(--hud-gold);
    color: var(--hud-gold);
    font-size: 18px;
    padding: 12px 22px;
    border-radius: 30px;
    cursor: pointer;
    box-shadow: 0 0 20px rgba(227, 182, 0, 0.2);
    z-index: 10000;
    display: flex;
    align-items: center;
    gap: 10px;
    transition: background .2s, transform .2s, box-shadow .2s;
    /* Prevent pull-to-refresh on mobile */
    touch-action: manipulation;
}

#desktop-contact-button:hover {
    background: rgba(227, 182, 0, 0.2);
    box-shadow: 0 0 30px var(--hud-gold-glow);
    color: #ffffff;
    border-color: #ffffff;
    transform: scale(1.06);
}

/* Visibility rules: desktop shows CTA, mobile hides CTA and uses FNM contact */
@media (min-width: 769px) {
    #floating-nav-menu .fnm-contact-button {
        display: none !important;
    }
}

@media (max-width: 768px) {
    #desktop-contact-button {
        display: none !important;
    }

    #floating-nav-menu .fnm-contact-button {
        display: flex !important;
    }
}

/* Safety: if the panel ever gets the contact-button class by mistake, keep it visible */
.contact-panel.contact-button {
    display: block !important;
}

/* FNM 2-Row Layout for Small/Narrow Screens */
@media (max-width: 365px) {
    #floating-nav-menu {
        width: 90%;
        flex-wrap: wrap !important;
        /* Enable wrapping */
        justify-content: center !important;
        padding: 8px 12px !important;
        gap: 12px 10px !important;
        /* row-gap column-gap */
    }

    #floating-nav-menu .nav-item {
        width: calc(33% - 8px) !important;
        /* 3 items per row (33% width each) */
        min-width: 0 !important;
        /* Override min-width */
        margin: 0 !important;
        padding: 6px 2px !important;
    }

    #floating-nav-menu .nav-item span:first-child {
        font-size: 18px !important;
        /* Slightly smaller icons */
    }

    #floating-nav-menu .nav-label {
        font-size: 9px !important;
        /* Smaller text */
    }

    #floating-nav-menu {
        padding: 6px 10px !important;
    }

    #floating-nav-menu .nav-item {
        width: calc(33% - 6px) !important;
        padding: 5px 0 !important;
    }
}

/*--------------------------------------------------------------
# Hardware Acceleration Modal
--------------------------------------------------------------*/
.hardware-accel-modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 999999;
    display: flex;
    align-items: center;
    justify-content: center;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
    animation: hardwareAccelFadeIn 0.3s ease-out;
}

@keyframes hardwareAccelFadeIn {
    from {
        opacity: 0;
    }

    to {
        opacity: 1;
    }
}

.hardware-accel-modal.hardware-accel-fade-out {
    animation: hardwareAccelFadeOut 0.3s ease-out;
}

@keyframes hardwareAccelFadeOut {
    from {
        opacity: 1;
    }

    to {
        opacity: 0;
    }
}

.hardware-accel-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.92);
    backdrop-filter: blur(8px);
    pointer-events: none;
    /* Prevent overlay from blocking button clicks */
}

.hardware-accel-content {
    position: relative;
    background: linear-gradient(135deg, #0B0A21 0%, #161530 100%);
    border: 2px solid rgba(227, 182, 0, 0.3);
    border-radius: 20px;
    max-width: 600px;
    width: 90%;
    max-height: 90vh;
    overflow-y: auto;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.5),
        0 0 40px rgba(77, 208, 225, 0.15);
    animation: hardwareAccelSlideUp 0.4s ease-out;
}

@keyframes hardwareAccelSlideUp {
    from {
        transform: translateY(30px);
        opacity: 0;
    }

    to {
        transform: translateY(0);
        opacity: 1;
    }
}

.hardware-accel-header {
    text-align: center;
    padding: 2rem 2rem 1rem;
    border-bottom: 1px solid rgba(77, 208, 225, 0.2);
}

.hardware-accel-icon {
    font-size: 4rem;
    margin-bottom: 1rem;
    filter: drop-shadow(0 4px 12px rgba(255, 193, 7, 0.3));
}

.hardware-accel-header h2 {
    margin: 0;
    font-size: 1.8rem;
    font-weight: 700;
    color: #fff;
    text-shadow: 0 2px 8px rgba(0, 0, 0, 0.3);
}

.hardware-accel-body {
    padding: 2rem;
}

.hardware-accel-message {
    font-size: 1.1rem;
    line-height: 1.6;
    color: #e0e0e0;
    margin: 0 0 1rem;
    text-align: center;
}

.hardware-accel-submessage {
    font-size: 1rem;
    line-height: 1.5;
    color: #4dd0e1;
    margin: 0 0 2rem;
    text-align: center;
    font-weight: 500;
}

.hardware-accel-instructions {
    background: rgba(0, 0, 0, 0.3);
    border-radius: 12px;
    padding: 1.5rem;
    margin-bottom: 2rem;
}

.hardware-accel-instructions h3 {
    margin: 0 0 1rem;
    font-size: 1.2rem;
    color: #4dd0e1;
    font-weight: 600;
}

.hardware-accel-instructions ol {
    margin: 0;
    padding-left: 1.5rem;
    color: #e0e0e0;
}

.hardware-accel-instructions li {
    margin-bottom: 0.8rem;
    line-height: 1.6;
}

.hardware-accel-instructions li strong {
    color: #4dd0e1;
    font-weight: 600;
}

.hardware-accel-quick-link {
    margin-top: 1.5rem;
    padding-top: 1.5rem;
    border-top: 1px solid rgba(77, 208, 225, 0.2);
}

.hardware-accel-quick-link p {
    margin: 0 0 0.5rem;
    color: #e0e0e0;
    font-weight: 600;
}

.hardware-accel-quick-link code {
    display: block;
    background: rgba(0, 0, 0, 0.5);
    border: 1px solid rgba(77, 208, 225, 0.3);
    border-radius: 6px;
    padding: 0.8rem;
    color: #4dd0e1;
    font-family: "Courier New", monospace;
    font-size: 0.9rem;
    margin-bottom: 0.8rem;
    word-break: break-all;
}

.hardware-accel-copy-btn {
    background: rgba(77, 208, 225, 0.15);
    border: 1px solid rgba(77, 208, 225, 0.4);
    color: #4dd0e1;
    padding: 0.6rem 1.2rem;
    border-radius: 6px;
    cursor: pointer;
    font-size: 0.9rem;
    font-weight: 600;
    transition: all 0.2s;
}

.hardware-accel-copy-btn:hover {
    background: rgba(77, 208, 225, 0.25);
    border-color: #4dd0e1;
    transform: translateY(-2px);
}

.hardware-accel-actions {
    display: flex;
    gap: 1rem;
    margin-bottom: 1.5rem;
}

.hardware-accel-btn {
    flex: 1;
    padding: 1rem 1.5rem;
    border-radius: 10px;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s;
    border: none;
}

.hardware-accel-btn-primary {
    background: linear-gradient(135deg, #F2D555 0%, #C99D00 100%);
    color: #0B0A21;
    box-shadow: 0 4px 15px rgba(227, 182, 0, 0.3);
}

.hardware-accel-btn-primary:hover {
    transform: translateY(-3px);
    box-shadow: 0 6px 20px rgba(227, 182, 0, 0.4);
}

.hardware-accel-btn-secondary {
    background: rgba(255, 255, 255, 0.1);
    color: #e0e0e0;
    border: 1px solid rgba(255, 255, 255, 0.2);
}

.hardware-accel-btn-secondary:hover {
    background: rgba(255, 255, 255, 0.15);
    border-color: rgba(255, 255, 255, 0.3);
}

.hardware-accel-footer {
    text-align: center;
    padding-top: 1rem;
    border-top: 1px solid rgba(77, 208, 225, 0.2);
}

.hardware-accel-footer small {
    color: rgba(255, 255, 255, 0.5);
    font-size: 0.85rem;
}

/* Mobile Responsive */
@media (max-width: 600px) {
    .hardware-accel-content {
        width: 95%;
        max-height: 95vh;
    }

    .hardware-accel-header {
        padding: 1.5rem 1.5rem 1rem;
    }

    .hardware-accel-header h2 {
        font-size: 1.5rem;
    }

    .hardware-accel-body {
        padding: 1.5rem;
    }

    .hardware-accel-actions {
        flex-direction: column;
    }

    .hardware-accel-btn {
        width: 100%;
    }

    .hardware-accel-instructions {
        padding: 1rem;
    }

    .hardware-accel-instructions li {
        font-size: 0.95rem;
    }
}


/* ==========================================================================
   COMPLETE HOLOGRAPHIC THEME: "SOLAR GOLD" (Refined)
   Paste this at the VERY BOTTOM of style.css
   ========================================================================== */

/* 0. SETUP & VARIABLES */

:root {
    /* GLASS: Deep Space Blue with High Transparency for Blur */
    --hud-glass: rgba(11, 10, 33, 0.60);
    /* Reduced from 0.85 to 0.60 */
    --hud-blur: blur(16px) saturate(180%);

    /* BRAND: Cosmic Gold (Bright "White Gold") */
    --hud-gold: #F2D555;
    --hud-gold-glow: rgba(227, 182, 0, 0.4);

    /* TECH: Structure */
    --hud-border: rgba(242, 213, 85, 0.3);
    /* Gold border */
    --hud-grid: rgba(242, 213, 85, 0.05);
    --hud-text-main: #ffffff;
    --hud-text-muted: #d0d0d0;
}

/* ==========================================================================
   1. MASTER CONTAINER (Glassmorphism)
   Apply to ALL panels: Projects, Skills, Experience, Contact, Tutorials
   ========================================================================== */
.project-popup-floating.custom-moon-popup,
.project-details-slider,
.skills-view-details-panel,
/* Added Skills Panel */
.company-detail-panel,
/* Added Experience Panel */
.vertical-selector-container,
.vos-project-list,
.compact-vos-row,
#floating-nav-menu,
#solar-system-selector-container,
.contact-panel,
.tutorial-dropdown,
.subskills-tutorial-instruction,
.celestial-tutorial-instruction,
.vos-projects-filters,
#camera-tutorial-overlay>div {

    /* The Glass Effect */
    background:
        linear-gradient(var(--hud-glass), var(--hud-glass)),
        repeating-linear-gradient(0deg, transparent, transparent 19px, var(--hud-grid) 20px),
        repeating-linear-gradient(90deg, transparent, transparent 19px, var(--hud-grid) 20px) !important;

    backdrop-filter: var(--hud-blur) !important;
    -webkit-backdrop-filter: var(--hud-blur) !important;

    border: 1px solid var(--hud-border) !important;
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.5), inset 0 0 20px rgba(227, 182, 0, 0.05) !important;

    border-radius: 12px !important;
    color: var(--hud-text-main) !important;
}

/* 2. TYPOGRAPHY & GOLD ACCENTS */
.popup-title,
.slider-title,
.v-menu-title,
.contact-panel h2,
.company-detail-panel h2,
.skill-details-header h2 {
    font-family: 'Rajdhani', sans-serif !important;
    font-weight: 700 !important;
    text-transform: uppercase;
    letter-spacing: 2px;
    color: var(--hud-gold) !important;
    text-shadow: 0 0 20px var(--hud-gold-glow);
    border-bottom: 1px solid var(--hud-border);
    padding-bottom: 10px;
    margin-bottom: 15px;
}

.popup-label,
.slider-label,
h4 {
    font-family: 'Rajdhani', sans-serif !important;
    color: var(--hud-gold) !important;
    /* Changed from muted to Gold for labels */
    font-weight: 600 !important;
    text-transform: uppercase;
    letter-spacing: 1.5px;
    opacity: 0.9;
    font-size: 1.1rem !important;
    margin-bottom: 10px !important;
    display: block;
}

.popup-value strong,
.slider-value strong {
    font-family: 'Rajdhani', sans-serif !important;
    color: var(--hud-gold) !important;
    font-weight: 600 !important;
    text-transform: uppercase;
    letter-spacing: 1.2px;
    font-size: 1.05rem !important;
    display: inline;
    /* Stay with leading bullets */
}

.popup-value strong::after,
.slider-value strong::after {
    content: "";
    display: block;
    margin-bottom: 5px;
}

.popup-value,
.slider-value {
    font-size: 1rem !important;
    line-height: 1.6 !important;
    color: #e0e6f3 !important;
}

/* HUD helper utilities for tutorial components */
.hud-overlay {
    background: rgba(0, 0, 0, 0.6);
    backdrop-filter: none;
}

.hud-glass {
    background: linear-gradient(var(--hud-glass), var(--hud-glass));
    backdrop-filter: var(--hud-blur);
    -webkit-backdrop-filter: var(--hud-blur);
    border: 1px solid var(--hud-border);
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.45), inset 0 0 18px var(--hud-gold-glow);
    border-radius: 12px;
    color: var(--hud-text-main);
}

.hud-gold-text {
    color: var(--hud-gold);
    text-shadow: 0 0 12px var(--hud-gold-glow);
}

.subskills-tutorial-test-probe {
    background: linear-gradient(90deg, rgba(242, 213, 85, 0.12), rgba(242, 213, 85, 0.06));
    color: #000;
    font-weight: 700;
    letter-spacing: .5px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, .15);
}

.celestial-tutorial-arrows {
    pointer-events: none;
}

.celestial-tutorial-arrows line {
    transition: opacity 0.5s ease-out;
}


/* 3. BUTTONS */
.popup-action,
.slider-action,
.wpcf7-submit,
#desktop-contact-button,
#skip-intro-button,
.resume-download-button,
.mobile-resume-button {
    background: linear-gradient(90deg, rgba(227, 182, 0, 0.1), transparent) !important;
    border: 1px solid var(--hud-gold) !important;
    color: var(--hud-gold) !important;
    border-radius: 6px !important;
    transition: all 0.3s ease !important;
    box-shadow: 0 0 10px rgba(227, 182, 0, 0.1) !important;
    font-family: 'Rajdhani', sans-serif !important;
    font-weight: 700 !important;
    text-transform: uppercase;
}

.project-details-slider .slider-action,
.project-popup-floating .popup-action {
    display: block !important;
    width: 100% !important;
    text-align: center;
    padding: 10px 0 !important;
    margin-bottom: 8px;
}

.project-action-buttons {
    display: flex;
    gap: 15px;
    flex-wrap: wrap;
    align-items: center;
    margin-top: auto;
    /* Push to bottom of flex container */
    padding: 16px;
    flex-shrink: 0;
    border-top: 1px solid rgba(227, 182, 0, 0.15);
}

.popup-action:hover,
.slider-action:hover,
.wpcf7-submit:hover,
#desktop-contact-button:hover,
#skip-intro-button:hover,
.resume-download-button:hover,
.mobile-resume-button:hover {
    background: var(--hud-gold) !important;
    color: #0b0a21 !important;
    box-shadow: 0 0 30px var(--hud-gold-glow) !important;
    transform: translateY(-2px);
}

/* Special state for "Back to Details" button */
.popup-action.showing-gallery,
.slider-action.showing-gallery {
    background: var(--hud-gold) !important;
    color: #0b0a21 !important;
    box-shadow: 0 4px 15px rgba(242, 213, 85, 0.4) !important;
    border-color: var(--hud-gold) !important;
    font-weight: 800 !important;
}

.popup-action.showing-gallery:hover,
.slider-action.showing-gallery:hover {
    box-shadow: 0 0 30px var(--hud-gold-glow) !important;
    transform: translateY(-2px);
}

/* Floating Nav Menu (HUD) - Solar Gold Glassmorphism */
#floating-nav-menu.hud-floating-nav,
.hud-floating-nav {
    background: linear-gradient(rgba(11, 10, 33, 0.60), rgba(11, 10, 33, 0.60));
    backdrop-filter: blur(16px) saturate(180%);
    -webkit-backdrop-filter: blur(16px) saturate(180%);
    border: 1px solid rgba(242, 213, 85, 0.25);
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.45);
    border-radius: 50px;
    transition: opacity 0.25s ease, transform 0.2s ease;
    -webkit-font-smoothing: antialiased;
}

#floating-nav-menu {
    transform: translateX(-50%);
}

#floating-nav-menu.visible {
    opacity: 1;
    pointer-events: all;
}

#floating-nav-menu {
    opacity: 0.98;
}

#floating-nav-menu .nav-item,
.nav-item {
    display: flex;
    align-items: center;
    justify-content: center;
    min-width: 44px;
    height: 44px;
    padding: 0 12px;
    border-radius: 50px;
    border: 1px solid transparent;
    background: rgba(255, 255, 255, 0.02);
    color: #ffffff;
    font-size: 20px;
    cursor: pointer;
    transition: all 0.25s ease;
    overflow: hidden;
}

#floating-nav-menu .nav-label,
.nav-label {
    max-width: 0;
    opacity: 0;
    margin-left: 0;
    font-size: 14px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 1px;
    color: inherit;
    transition: max-width 0.3s ease, opacity 0.2s ease, margin-left 0.25s ease;
    white-space: nowrap;
    overflow: hidden;
}

#floating-nav-menu .nav-item.expanded,
.nav-item.expanded {
    background: rgba(242, 213, 85, 0.08);
    color: #F2D555;
    border-color: rgba(242, 213, 85, 0.25);
    box-shadow: 0 6px 18px rgba(242, 213, 85, 0.06);
}

#floating-nav-menu .nav-item.expanded .nav-label,
.nav-item.expanded .nav-label {
    max-width: 140px;
    opacity: 1;
    margin-left: 10px;
}

#floating-nav-menu .nav-item.active,
.nav-item.active {
    color: #F2D555;
    border-color: #F2D555;
    background: rgba(242, 213, 85, 0.12);
    box-shadow: 0 0 18px rgba(242, 213, 85, 0.35);
    transform: scale(1.08);
}

/* Contact button visibility helpers */
#desktop-contact-button {
    visibility: hidden;
    opacity: 0;
    pointer-events: none;
    transition: opacity .25s ease;
}

#desktop-contact-button.visible {
    visibility: visible;
    opacity: 1;
    pointer-events: auto;
}

/* FNM contact (mobile) */
#floating-nav-menu .fnm-contact-button {
    display: none;
    opacity: 0;
    pointer-events: none;
}

#floating-nav-menu .fnm-contact-button.visible {
    display: flex;
    opacity: 1;
    pointer-events: auto;
}

/* Hiding rules moved to end of file for precedence */

/* VOS runtime containers/selectors used by ViewSelectorManager / VerticalObjectSelector */
:is(body.preloader-active, body.view-transition-active) #vos-containers,
:is(body.preloader-active, body.view-transition-active) .vertical-selector-container,
:is(body.preloader-active, body.view-transition-active) .vertical-selector-component,
/* Experience details panel (experience view) */
:is(body.preloader-active, body.view-transition-active) .company-detail-panel,
:is(body.preloader-active, body.view-transition-active) .experience-details-active,
/* About view resume download buttons */
:is(body.preloader-active, body.view-transition-active) .resume-download-button,
:is(body.preloader-active, body.view-transition-active) .mobile-resume-button {
    visibility: hidden !important;
    opacity: 0 !important;
    pointer-events: none !important;
    display: none !important;
}

/* Accessibility: reduce motion preference */
@media (prefers-reduced-motion: reduce) {

    #floating-nav-menu .nav-item,
    .nav-item {
        transition: none;
    }

    #floating-nav-menu .nav-label,
    .nav-label {
        transition: none;
    }
}

/* Hide the sidebar VOS completely when the project slider is open on mobile */
body.slider-open .vertical-selector-container {
    display: none !important;
}

body.slider-open #vos-projects-current-project-name {
    color: #888 !important;
}

/* Ensure hover state doesn't bring back glow/scale */
body.slider-open .vos-current-project:hover {
    transform: none !important;
    box-shadow: none !important;
    background: linear-gradient(to bottom, rgba(11, 10, 33, 0.9), rgba(20, 18, 50, 0.9)) !important;
}

/* =========================================
   Inactive Project Styles
   ========================================= */

/* Grayscale images for inactive projects */
.project-archived .slider-image,
.project-archived .popup-image {
    transition: filter 0.3s, opacity 0.3s;
}



/* Status Badges */
.project-status-badge {
    display: inline-block;
    padding: 2px 8px;
    border-radius: 12px;
    font-size: 0.75rem;
    font-weight: 700;
    text-transform: uppercase;
    margin-left: 10px;
    vertical-align: middle;
    letter-spacing: 0.5px;
}

.status-live {
    background-color: rgba(76, 175, 80, 0.2);
    color: #4caf50;
    border: 1px solid rgba(76, 175, 80, 0.4);
}

.status-offline {
    background-color: rgba(158, 158, 158, 0.2);
    color: #9e9e9e;
    border: 1px solid rgba(158, 158, 158, 0.4);
}

/* Disabled Action Buttons */
.slider-action.disabled,
.popup-action.disabled {
    background-color: #333;
    color: #777;
    cursor: not-allowed;
    border: 1px solid #444;
    pointer-events: none;
}

.slider-action.disabled:hover,
.popup-action.disabled:hover {
    background-color: #333;
}


/* =========================================
   Rich Not Active Project Styles
   ========================================= */

/* Rich Popup Layout Override */
.project-popup-floating.project-archived-rich {
    width: 500px;
    /* Wider for rich content */
    max-width: 90vw;
    border-color: rgba(158, 158, 158, 0.4);
    /* Matching inactive status color */
}

/* Showcase Grid */
.project-showcase-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 12px;
    margin-bottom: 24px;
    width: 100%;
}

.showcase-item {
    position: relative;
    border-radius: 8px;
    overflow: hidden;
    background: rgba(0, 0, 0, 0.3);
    border: 1px solid rgba(255, 255, 255, 0.05);
    transition: all 0.3s cubic-bezier(0.25, 0.46, 0.45, 0.94);
    aspect-ratio: 16 / 9;
}

.showcase-item.hero-item {
    grid-column: span 2;
    aspect-ratio: 16 / 8;
    border-color: rgba(242, 213, 85, 0.15);
}

.showcase-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.6s cubic-bezier(0.165, 0.84, 0.44, 1);
}

.showcase-item:hover {
    border-color: rgba(242, 213, 85, 0.4);
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.5), 0 0 12px rgba(242, 213, 85, 0.1);
    transform: translateY(-4px);
    z-index: 2;
}

.showcase-item:hover img {
    transform: scale(1.05);
}

.showcase-item::after {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(to top, rgba(0, 0, 0, 0.5), transparent);
    opacity: 0;
    transition: opacity 0.3s ease;
}

.showcase-item:hover::after {
    opacity: 1;
}

.project-showcase-grid-wrapper {
    width: 100%;
    padding-bottom: 20px;
}


/* Tech Chips */
.tech-chip-container {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    margin-top: 4px;
}

.tech-chip {
    background: rgba(255, 255, 255, 0.1);
    color: #e0e6f3;
    padding: 4px 8px;
    border-radius: 4px;
    font-size: 0.8rem;
    border: 1px solid rgba(255, 255, 255, 0.15);
}

/* Expanded Text */
.expanded-text {
    white-space: pre-wrap;
    /* Preserve newlines */
    max-height: 200px;
    overflow-y: auto;
    padding-right: 8px;
    font-size: 0.95rem;
    /* Slightly larger for reading */
    line-height: 1.6;
    color: #ccc;
}

/* Status Badge Styles */
.project-status-badge {
    font-size: 0.75rem;
    padding: 2px 8px;
    border-radius: 4px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    margin-left: 10px;
    vertical-align: middle;
}

.project-status-badge.status-live {
    background: rgba(46, 204, 113, 0.2);
    color: #2ecc71;
    border: 1px solid rgba(46, 204, 113, 0.4);
}

.project-status-badge.status-offline {
    background: #343434;
    color: #e0e6f3;
    border: 1px solid #343434;
}

/* Disabled button style */
button.disabled {
    opacity: 0.6;
    cursor: not-allowed;
    background: #333 !important;
    color: #aaa !important;
    border-color: #555 !important;
}

/* Updated Live Project Icon */
.live-project-btn .btn-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 24px;
    height: 24px;
    background: rgba(242, 213, 85, 0.2);
    /* Golden background with low opacity */
    border: 1px solid rgba(242, 213, 85, 0.5);
    border-radius: 4px;
    margin-right: 8px;
    color: #F2D555;
    /* Gold arrow */
}

.live-project-btn .btn-icon svg {
    width: 16px;
    height: 16px;
    stroke-width: 2.5;
}

.live-project-btn:hover .btn-icon {
    background: #F2D555;
    color: #0b0a21;
    /* Dark text on gold */
}

/* Grayscale effect */
/* .grayscale {
    filter: grayscale(100%);
    opacity: 0.8;
} */

/* --------------------------------------------------------------
   # Standardized Project Details (Scrollable Description)
-------------------------------------------------------------- */



/* Consolidate .project-detail-rich with legacy .project-archived-rich */
/* .project-detail-rich currently relying on shared classes like .custom-moon-popup */


/* --------------------------------------------------------------
   # Full-Cover Gallery Swap & Phase Shift Animation
-------------------------------------------------------------- */

/* --------------------------------------------------------------
   # Full-Cover Gallery Swap & Phase Shift Animation
-------------------------------------------------------------- */

/* GRID STACK: Overlap Default View and Gallery View */
.project-swap-stack {
    display: grid !important;
    grid-template-areas: "stack";
    width: 100%;
    flex: 1 !important;
    height: auto !important;
    /* Reverted from height: 0 to restore visibility */
    min-height: 0 !important;
    overflow-y: auto !important;
    scrollbar-width: none;
    -ms-overflow-style: none;
}

.project-swap-stack::-webkit-scrollbar {
    display: none;
    /* WebKit (Chrome, Safari) */
}

.project-view-default,
.project-view-gallery {
    grid-area: stack;
    width: 100%;
    /* Transitions for Phase Shift */
    transition: opacity 1.2s cubic-bezier(0.22, 1, 0.36, 1), transform 1.2s cubic-bezier(0.22, 1, 0.36, 1), filter 1.2s ease;
    backface-visibility: hidden;
    transform-origin: center center;
}

.project-view-default {
    z-index: 2;
    position: relative;
    opacity: 1 !important;
    visibility: visible !important;
    min-height: 100%;
}

.project-view-gallery {
    z-index: 1;
    opacity: 0;
    pointer-events: none;
    min-height: 100%;
}

.project-view-gallery.active-view {
    opacity: 1 !important;
    visibility: visible !important;
    z-index: 10 !important;
    pointer-events: auto !important;
}

/* Perspective container */
.phase-animating {
    perspective: 1000px;
    overflow: hidden;
}

/* Phase Out (Scale Down + Blur + Fade Out) */
.phase-out {
    animation: phaseOut 1.0s cubic-bezier(0.4, 0, 0.2, 1) forwards;
    pointer-events: none;
}

/* Phase In (Scale Up + Unblur + Fade In) */
.phase-in {
    animation: phaseIn 1.2s cubic-bezier(0.22, 1, 0.36, 1) forwards;
    pointer-events: auto;
    /* Re-enable pointer events */
}

@keyframes phaseOut {
    0% {
        opacity: 1;
        transform: scale(1);
        filter: blur(0px);
    }

    100% {
        opacity: 0;
        transform: scale(0.95);
        filter: blur(8px);
    }
}

@keyframes phaseIn {
    0% {
        opacity: 0;
        transform: scale(0.95);
        /* Harmonized with phaseOut scale */
        filter: blur(10px);
    }

    100% {
        opacity: 1;
        transform: scale(1);
        filter: blur(0px);
    }
}

/* Ensure gallery wrapper matches details height/style */
.project-showcase-grid-wrapper {
    margin-top: 0 !important;
    margin-bottom: 20px;
    border-top: none !important;
    padding-top: 0 !important;
    min-height: 200px;
}

.project-view-gallery {
    /* Removed max-height; handled by parent scroll */
    overflow-y: auto;
    padding-right: 12px;
}

/* Missing Slider CSS */
.project-archived-slider-wrapper {
    position: relative;
    overflow: hidden;
    width: 100%;
    height: 100%;
}

.archived-slider-track {
    display: flex;
    transition: transform 0.5s ease-in-out;
    width: 100%;
    height: 100%;
}

.archived-slider-slide {
    min-width: 100%;
    flex: 0 0 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
}

.archived-slider-slide img {
    max-width: 100%;
    max-height: 100%;
    object-fit: contain;
    border-radius: 8px;
}

/* User Fix: Ensure opacity is 1 by default for these wrappers unless active */
.project-hero-wrapper:not(.active),
.project-archived-slider-wrapper:not(.active) {
    opacity: 1;
}

/* --------------------------------------------------------------
   # Gallery Swap Interaction
-------------------------------------------------------------- */

.project-details-text-wrapper {
    display: block;
    /* Default state */
    /* Ensure it takes up space so popup doesn't collapse */
    min-height: 200px;
}

/* Fade In Animation for Swap */
.fade-in {
    animation: fadeIn 0.4s ease-in-out;
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(5px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Ensure gallery wrapper matches details height/style */
.project-archived-slider-wrapper.bottom-gallery {
    margin-top: 0 !important;
    /* Remove top margin when swapped */
    margin-bottom: 20px;
    border-top: none !important;
    /* Remove separator if any */
    padding-top: 0 !important;
    min-height: 200px;
}


span.project-status-badge.status-live,
span.project-status-badge.status-offline {
    right: 5px;
    position: absolute;
    top: 2px;
}

button.archived-slider-nav {
    border-color: unset;
}

#skill-details-panel {
    scrollbar-width: thin !important;
    scrollbar-color: rgba(255, 215, 0, 0.4) transparent !important;
}

/* "Sci-Fi" Scrollbar Styling */
.vertical-selector-container,
.vos-project-list.expanded,
.project-view-gallery,
.tutorial-dropdown,
.company-detail-panel,
.contact-panel,
#skill-details-panel {
    /* Firefox Support */
    scrollbar-width: thin !important;
    scrollbar-color: rgba(255, 215, 0, 0.4) transparent !important;

    /* Reset Mask (if previously applied) */
    -webkit-mask-image: none !important;
    mask-image: none !important;
}

/* WebKit (Chrome, Safari, Edge) Support */
.company-detail-panel::-webkit-scrollbar,
#skill-details-panel::-webkit-scrollbar {
    width: 4px !important;
    /* Razor thin */
    display: block !important;
    /* Force display if previously hidden */
    height: 4px !important;
}

.company-detail-panel::-webkit-scrollbar-track,
#skill-details-panel::-webkit-scrollbar-track {
    background: rgba(255, 255, 255, 0.02) !important;
    /* Barely visible track */
    border-radius: 10px !important;
}

.company-detail-panel::-webkit-scrollbar-thumb,
#skill-details-panel::-webkit-scrollbar-thumb {
    background: rgba(255, 215, 0, 0.4) !important;
    /* Subtle yellow matching theme */
    border-radius: 10px !important;
}

.company-detail-panel::-webkit-scrollbar-thumb:hover,
#skill-details-panel::-webkit-scrollbar-thumb:hover {
    background: rgba(255, 215, 0, 0.8) !important;
    /* Glows brighter when interacted with */
}

/* =========================================
   Project Lightbox Styles
   ========================================= */
.project-lightbox {
    position: fixed;
    inset: 0;
    z-index: 99999;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(0, 0, 0, 0.4) !important;
    /* Lighter overlay to show blur through */
    backdrop-filter: var(--hud-blur) !important;
    -webkit-backdrop-filter: var(--hud-blur) !important;
    transition: opacity 0.4s cubic-bezier(0.165, 0.84, 0.44, 1), backdrop-filter 0.4s ease;
    animation: lightboxFadeIn 0.4s cubic-bezier(0.165, 0.84, 0.44, 1);
}

.project-lightbox.fade-out {
    opacity: 0;
    backdrop-filter: blur(0) !important;
    pointer-events: none;
}

.lightbox-overlay {
    position: absolute;
    inset: 0;
}

.lightbox-container {
    position: relative;
    width: 60%;
    /* Desktop Default */
    max-width: 1400px;
    height: 85vh;
    display: flex;
    flex-direction: column;
    z-index: 10;
    transition: transform 0.4s cubic-bezier(0.165, 0.84, 0.44, 1), width 0.3s ease;

    /* The Glass Effect */
    background:
        linear-gradient(var(--hud-glass), var(--hud-glass)),
        repeating-linear-gradient(0deg, transparent, transparent 19px, var(--hud-grid) 20px),
        repeating-linear-gradient(90deg, transparent, transparent 19px, var(--hud-grid) 20px) !important;
    backdrop-filter: var(--hud-blur) !important;
    -webkit-backdrop-filter: var(--hud-blur) !important;
    border: 1px solid var(--hud-border) !important;
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.5), inset 0 0 20px rgba(227, 182, 0, 0.05) !important;
    border-radius: 12px !important;
    padding: 20px;
    overflow: hidden;
}

@media (max-width: 1024px) {
    .lightbox-container {
        width: 70%;
    }
}

@media (max-width: 767px) {
    .lightbox-container {
        width: 100%;
        height: 100vh;
        border-radius: 0 !important;
        border-left: none !important;
        border-right: none !important;
    }
}

.project-lightbox.fade-out .lightbox-container {
    transform: scale(0.95);
}

.lightbox-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 15px 0;
    border-bottom: 1px solid rgba(242, 213, 85, 0.2);
    margin-bottom: 20px;
}

.lightbox-title {
    font-family: 'Rajdhani', sans-serif;
    font-size: 1.5rem;
    font-weight: 700;
    color: #f2d555;
    text-transform: uppercase;
    letter-spacing: 2px;
}

.lightbox-counter {
    color: rgba(255, 255, 255, 0.6);
    font-size: 0.9rem;
    letter-spacing: 1px;
}

.close-lightbox {
    background: none;
    border: none;
    color: #F2D555;
    font-size: 2.5rem;
    cursor: pointer;
    line-height: 1;
    transition: all 0.3s ease;
    padding: 0 10px;
}

.close-lightbox:hover {
    color: #f2d555;
    transform: scale(1.1);
}

.lightbox-content {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    overflow: hidden;
    touch-action: none;
    /* Prevent native zoom/pan interference */
}

.lightbox-rail {
    display: flex;
    width: 300%;
    height: 100%;
    position: absolute;
    top: 0;
    left: 0;
    transform: translateX(-33.333%);
    will-change: transform;
    touch-action: none;
}

.rail-slide {
    width: 33.333%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0 15px;
    box-sizing: border-box;
}

.lightbox-image {
    max-width: 100%;
    max-height: 100%;
    object-fit: contain;
    border-radius: 4px;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.9);
    transition: transform 0.3s cubic-bezier(0.165, 0.84, 0.44, 1);
    will-change: transform;
    backface-visibility: hidden;
    -webkit-backface-visibility: hidden;
}

.lightbox-nav {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background: rgba(11, 10, 33, 0.6);
    color: #f2d555;
    border: 1px solid rgba(242, 213, 85, 0.3);
    width: 60px;
    height: 60px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 28px;
    cursor: pointer;
    z-index: 20;
    transition: all 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    backdrop-filter: blur(8px);
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.3);
}

@media (max-width: 767px) {
    .lightbox-nav {
        display: none !important;
    }
}

.lightbox-nav:hover {
    background: #f2d555;
    color: #0b0a21;
    box-shadow: 0 0 30px rgba(242, 213, 85, 0.6);
    transform: translateY(-50%) scale(1.15);
}

.lightbox-nav:active {
    transform: translateY(-50%) scale(0.95);
}

.lightbox-nav.prev {
    left: 20px;
}

.lightbox-nav.next {
    right: 20px;
}

@keyframes lightboxFadeIn {
    from {
        opacity: 0;
        backdrop-filter: blur(0);
    }

    to {
        opacity: 1;
        backdrop-filter: blur(10px);
    }
}

.fade-in {
    animation: imageFadeIn 0.5s cubic-bezier(0.165, 0.84, 0.44, 1);
}

@keyframes imageFadeIn {
    from {
        opacity: 0;
        transform: translateY(10px) scale(0.98);
    }

    to {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

/* Mobile Adjustments */
@media screen and (max-width: 768px) {
    .lightbox-container {
        width: 100%;
        height: 100vh;
        border-radius: 0;
    }

    .lightbox-header {
        padding: 10px 20px;
    }

    .lightbox-nav {
        width: 45px;
        height: 45px;
        font-size: 20px;
        background: rgba(11, 10, 33, 0.8);
    }

    .lightbox-nav.prev {
        left: 10px;
    }

    .lightbox-nav.next {
        right: 10px;
    }

    .lightbox-title {
        font-size: 1.1rem;
        max-width: 60%;
        overflow: hidden;
        text-overflow: ellipsis;
        white-space: nowrap;
    }
}

/* Video Expand Button */
.video-container {
    position: relative;
    width: 100%;
}

.ma-video-expand-btn {
    position: absolute;
    top: 15px;
    right: 15px;
    background: rgba(11, 10, 33, 0.7) !important;
    border: 1px solid var(--hud-gold) !important;
    color: var(--hud-gold) !important;
    width: 40px;
    height: 40px;
    border-radius: 6px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    z-index: 10;
    transition: all 0.3s ease;
    backdrop-filter: blur(8px);
    opacity: 0;
    visibility: hidden;
}

.video-container:hover .ma-video-expand-btn {
    opacity: 1;
    visibility: visible;
}

.ma-video-expand-btn:hover {
    background: var(--hud-gold) !important;
    color: #000 !important;
    box-shadow: 0 0 15px var(--hud-gold-glow) !important;
    transform: scale(1.1);
}

.ma-video-expand-btn svg {
    width: 20px;
    height: 20px;
}

.lightbox-video-wrapper {
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #000;
    border-radius: 4px;
    overflow: hidden;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.9);
}

.lightbox-video {
    width: 100%;
    height: 100%;
    max-height: 85vh;
    object-fit: contain;
}

iframe.lightbox-video {
    border: none;
    aspect-ratio: 16 / 9;
    max-width: 100%;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.9);
    border-radius: 8px;
    background: #000;
}

/* Adjust wrapper for iframe if needed */
.lightbox-video-wrapper:has(iframe) {
    background: transparent;
    padding: 0;
}

/* Custom HUD Pagination for Lightbox */
.pswp__custom-pagination {
    position: absolute;
    bottom: 25px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    gap: 10px;
    z-index: 20;
}

.pswp__dot {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.2);
    border: 1px solid rgba(255, 255, 255, 0.1);
    transition: all 0.3s cubic-bezier(0.165, 0.84, 0.44, 1);
    box-shadow: 0 0 5px rgba(0, 0, 0, 0.5);
    cursor: pointer;
}

.pswp__dot.active {
    background: var(--hud-gold);
    box-shadow: 0 0 15px var(--hud-gold-glow);
    transform: scale(1.3);
}

/* Mobile Swipe Hint Rendering */
.pswp__swipe-hint {
    position: absolute;
    bottom: 60px;
    left: 50%;
    transform: translateX(-50%);
    background: rgba(11, 10, 33, 0.9);
    color: var(--hud-gold);
    padding: 12px 24px;
    border-radius: 40px;
    font-size: 0.9rem;
    font-weight: 600;
    backdrop-filter: blur(15px);
    border: 1px solid rgba(242, 213, 85, 0.4);
    pointer-events: none;
    display: none;
    align-items: center;
    justify-content: center;
    gap: 12px;
    transition: opacity 1s cubic-bezier(0.4, 0, 0.2, 1), transform 1s cubic-bezier(0.4, 0, 0.2, 1), visibility 1s;
    z-index: 25;
    text-transform: uppercase;
    letter-spacing: 1.5px;
    white-space: nowrap;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.5);
}

.pswp__swipe-hint.fade-out {
    opacity: 0;
    transform: translateX(-50%) translateY(20px);
    visibility: hidden;
}

@media (max-width: 767px) {
    .pswp__swipe-hint {
        display: flex;
        animation: hintPulse 2s infinite ease-in-out;
    }

    .lightbox-nav {
        display: none !important;
        opacity: 0 !important;
        visibility: hidden !important;
        pointer-events: none !important;
    }
}

@keyframes hintPulse {

    0%,
    100% {
        transform: translate(-50%, 0);
        opacity: 0.8;
    }

    50% {
        transform: translate(-50%, -8px);
        opacity: 1;
    }
}

.hint-icon {
    font-size: 1.4rem;
}


/*mobile landscape mode*/

@media screen and (orientation: landscape) {
    div#skill-details-panel {
        max-width: 50%;
        transform: translate(-50%, -50%) scale(0.8) !important;
    }

    body.mobile-landscape-mode #project-details-slider {
        max-width: 50% !important;
        zoom: 0.8 !important;
    }
}

/* ==========================================================================
   GLOBAL UI VISIBILITY MANAGEMENT (HIGH PRECEDENCE - SYNCHRONIZED)
   Ensures help/contact/FNM/VOS elements are hidden during focused interactions
   with a unified 0.4s subtle animation.
   ========================================================================== */

/* 1. Base Transition for all target UI elements */
#floating-nav-menu,
.vertical-selector-container,
#tutorial-help-button,
#desktop-contact-button,
.contact-button,
.fnm-contact-button,
.reset-view-btn {
    transition: opacity 0.4s ease-in-out, visibility 0.4s ease-in-out, transform 0.4s ease-in-out !important;
}

/* 2. Unified Hiding Rule (Elements that ALWAYS hide in these states) */
:is(body.slider-open,
    body.project-details-open,
    body.experience-details-active,
    body.skills-details-active,
    body.fnm-hidden-by-skills-popup) :is(#floating-nav-menu,
    #tutorial-help-button,
    #desktop-contact-button,
    .contact-button,
    .fnm-contact-button,
    .help-btn,
    .reset-view-btn,
    [class*="help-btn"]) {
    opacity: 0 !important;
    visibility: hidden !important;
    pointer-events: none !important;
}

/* 2b. Conditional VOS Hiding 
   VOS is hidden on mobile (slider-open) or during focused skills/exp views, 
   but stays visible on desktop during project-details-open view. */
:is(body.slider-open,
    body.experience-details-active,
    body.skills-details-active,
    body.fnm-hidden-by-skills-popup) .vertical-selector-container {
    opacity: 0 !important;
    visibility: hidden !important;
    pointer-events: none !important;
}

/* 3. Preloader & Transition Hiding (Reinforced) */
:is(body.preloader-active, body.view-transition-active) :is(#desktop-contact-button,
    #tutorial-help-button,
    .vos,
    .vertical-selector-container) {
    display: none !important;
    opacity: 0 !important;
    visibility: hidden !important;
}

div#floating-nav-menu button.nav-item {
    height: 50px !important;
}