@import url('https://fonts.googleapis.com/css2?family=Caveat:wght@400;700&family=Special+Elite&display=block');
@import url('https://fonts.googleapis.com/css2?family=Orbitron:wght@400;700&family=Inter:wght@400;600&family=Oswald:wght@500;700&display=block');

:root {
    --yellow-highlighter: rgba(255, 230, 0, 0.8);
    --font-hand: 'Caveat', cursive;
    --font-type: 'Special Elite', monospace;
    --font-sci: 'Orbitron', sans-serif;
    --font-ui: 'Inter', sans-serif;
    --font-compact: 'Oswald', sans-serif;
}

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

html {
    scroll-behavior: smooth;
}

body {
    line-height: 1.6;
    overflow-x: hidden;
    transition: background 0.3s, color 0.3s;
}

::selection {
    background: #FFE600;
    color: #000;
}

/* -----------------------------
   THEME: CINEMATIC (Index)
   ----------------------------- */
.theme-cinematic {
    background-color: #050505;
    color: #ffffff;
    font-family: var(--font-ui);
}

.top-video-wrapper {
    position: relative;
    width: 100%;
}

.theme-cinematic .video-bg {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    object-fit: cover;
    z-index: -2;
    opacity: 0.8;
}

.theme-cinematic .overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(to bottom, rgba(0, 0, 0, 0.4) 0px, rgba(0, 0, 0, 0) 400px, rgba(0, 0, 0, 0) calc(100% - 400px), #050505 100%);
    z-index: -1;
}

.theme-cinematic .navbar {
    background: transparent;
}

.theme-cinematic .nav-links a {
    color: #fff;
}

.theme-cinematic .nav-links a::after {
    background-color: #fff;
}

.theme-cinematic .nav-links .active-link {
    color: #FFE600;
}

.theme-cinematic .nav-links .active-link::after {
    background-color: #FFE600;
}

.theme-cinematic .logo {
    color: #FFE600;
}

.theme-cinematic .hero-section {
    min-height: 100vh;
    display: flex;
    justify-content: center;
    align-items: flex-end;
    padding-bottom: 15vh;
    position: relative;
}

.theme-cinematic .hero-content {
    text-align: center;
    width: 100%;
    padding: 0 2rem;
}

.theme-cinematic .hero-title-main {
    font-family: var(--font-compact);
    font-size: clamp(4rem, 10vw, 8rem);
    text-transform: uppercase;
    letter-spacing: 0px;
    line-height: 1;
    margin-bottom: 0.5rem;
    font-weight: 700;
    cursor: default;
}

.theme-cinematic #name-first {
    display: inline-block;
}

.theme-cinematic .highlight {
    color: #000;
    background-color: #FFE600;
    font-style: normal;
    position: relative;
    display: inline-block;
    z-index: 1;
    padding: 0 10px;
}

.theme-cinematic .highlight::after {
    display: none;
}

.theme-cinematic .hero-subtitle {
    font-family: var(--font-ui);
    font-size: 1.2rem;
    letter-spacing: 1px;
    color: #ccc;
    font-weight: 400;
    margin-bottom: 2rem;
}

/* --- Cinematic Showreel Sequence --- */
#cinema-curtain {
    position: fixed;
    top: 0; left: 0; width: 100vw; height: 100vh;
    background: #000;
    z-index: 9990;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.8s ease;
}

/* Phase 1: Darken everything */
body.cinema-transitioning #cinema-curtain {
    z-index: 9999;
    opacity: 1;
    pointer-events: all;
}

/* Phase 2: Video Setup */
body.showreel-active #cinema-curtain {
    z-index: 9990; /* Keep it black behind the video */
    opacity: 1;
    pointer-events: all;
}

body.showreel-active .video-bg {
    position: fixed;
    top: 0; left: 0; width: 100vw; height: 100vh;
    z-index: 9991;
    object-fit: contain;
    background: #000;
    opacity: 0; /* Hidden initially */
    transition: opacity 1s ease;
}

/* Phase 3: Brighten display */
body.showreel-active.video-ready .video-bg {
    opacity: 1;
}

#close-showreel-btn {
    position: fixed;
    top: 2rem;
    right: 3rem;
    z-index: 9999;
    background: transparent;
    border: none;
    color: #fff;
    font-family: var(--font-compact);
    font-size: 1.5rem;
    cursor: pointer;
    text-transform: uppercase;
    letter-spacing: 2px;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.5s ease, color 0.3s;
    text-shadow: 1px 1px 5px rgba(0,0,0,0.8);
}

#close-showreel-btn:hover {
    color: #FFE600;
}

body.showreel-active.video-ready #close-showreel-btn {
    opacity: 1;
    pointer-events: all;
}

.theme-cinematic .btn {
    border: none;
    color: #000;
    padding: 0.8rem 2rem;
    font-family: var(--font-compact);
    text-transform: uppercase;
    letter-spacing: 1px;
    font-size: 1.2rem;
    font-weight: 700;
    background: #FFE600;
    transition: 0.3s;
    display: inline-block;
    text-decoration: none;
}

.theme-cinematic .btn:hover {
    background: #fff;
    color: #000;
}

.theme-cinematic .btn-outline {
    background: rgba(0, 0, 0, 0.4);
    color: #FFE600;
    border: 2px solid #FFE600;
    padding: 0.7rem 1.9rem; /* Adjust padding to account for border */
    backdrop-filter: blur(5px);
    cursor: pointer;
}

.theme-cinematic .btn-outline:hover {
    background: #FFE600;
    color: #000;
}

.theme-cinematic .intro-card {
    background: transparent;
    border: none;
    color: #fff;
    border-radius: 12px;
    padding: 2rem 2.5rem;
    margin-bottom: 2rem;
    max-width: 900px;
}

.theme-cinematic .portfolio-section .gallery {
    grid-template-columns: repeat(3, 1fr);
    gap: 1.5rem;
}

.theme-cinematic .intro-alias {
    text-align: left;
    color: #FFE600;
    font-family: var(--font-compact);
    font-size: 1.2rem;
    text-transform: uppercase;
    margin-bottom: 1.5rem;
    letter-spacing: 0;
    text-shadow: 1px 1px 3px rgba(0, 0, 0, 0.9);
}

.theme-cinematic .intro-body {
    color: #fffae6;
    font-size: 1rem;
    line-height: 2; /* Increased line-height to accommodate blocky highlights */
    text-align: left;
    text-shadow: 1px 1px 4px rgba(0,0,0,0.9), 0 0 10px rgba(0,0,0,0.6);
    font-weight: 500;
}

.theme-cinematic .intro-body .highlight {
    display: inline;
    padding: 2px 0;
    box-decoration-break: clone;
    -webkit-box-decoration-break: clone;
    box-shadow: 6px 0 0 #FFE600, -6px 0 0 #FFE600; /* Create padding via box-shadow for inline elements */
    text-shadow: none;
    font-weight: 700;
}

.theme-cinematic .intro-body p+p {
    margin-top: 0.4rem;
}

.theme-cinematic .contact-info {
    margin-top: 2rem;
    display: flex;
    gap: 1.5rem;
}

.theme-cinematic .poem-preview {
    font-family: var(--font-hand);
    font-size: 1.5rem;
    line-height: 1.5;
    color: #ccc;
    font-style: italic;
    padding: 1rem;
}

.theme-cinematic .intro-photo {
    flex-shrink: 0;
    width: 220px;
    border-radius: 10px;
    overflow: hidden;
}

.theme-cinematic .polaroid-img {
    width: 100%;
    aspect-ratio: 4/5;
    object-fit: cover;
    transition: 0.3s;
}

.theme-cinematic .contact-link {
    color: #fff;
    text-decoration: none;
    margin-right: 1.5rem;
    border-bottom: 1px solid #ccc;
    transition: 0.3s;
    font-family: var(--font-compact);
    text-transform: uppercase;
    font-size: 1.1rem;
    letter-spacing: 0;
    text-shadow: 1px 1px 3px rgba(0, 0, 0, 0.9);
}

.theme-cinematic .contact-link:hover {
    color: #FFE600;
    border-color: #FFE600;
}

.theme-cinematic .tape {
    display: none;
}

.theme-cinematic .section-title {
    font-family: var(--font-compact);
    font-size: 2.5rem;
    line-height: 1.1;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0px;
    text-align: center;
    margin-bottom: 2rem;
}

.theme-cinematic .intro-text .section-title {
    text-align: left;
    margin-bottom: 0.2rem;
}

.theme-cinematic .polaroid {
    background: #111;
    border: 1px solid #333;
    padding: 1rem;
    border-radius: 10px;
    cursor: pointer;
    transition: 0.3s;
}

.theme-cinematic .polaroid:hover {
    transform: translateY(-5px);
    border-color: #fff;
    box-shadow: 0 10px 20px rgba(255, 255, 255, 0.05);
}

.theme-cinematic .placeholder-img {
    background: #222;
    color: #555;
    display: flex;
    align-items: center;
    justify-content: center;
    aspect-ratio: 4/5;
    font-family: var(--font-ui);
}

.theme-cinematic .caption {
    font-family: var(--font-ui);
    text-align: center;
    margin-top: 1rem;
}

.theme-cinematic .caption span,
.theme-cinematic .action-link {
    font-size: 0.85rem;
    color: #888;
    transition: 0.3s;
    display: inline-block;
    margin-top: 5px;
}

.theme-cinematic .polaroid:hover .action-link {
    color: #FFE600;
    transform: translateX(3px);
}

.theme-cinematic .poem-card {
    background: #111;
    border: 1px solid #333;
    padding: 2rem;
    border-radius: 10px;
}

/* -----------------------------
   THEME: HOLOGRAM (3D works)
   ----------------------------- */
.theme-hologram {
    background-color: #030b14;
    color: #FFE600;
    font-family: var(--font-sci);
    background-image: radial-gradient(rgba(255, 230, 0, 0.15) 2px, transparent 2px);
    background-size: 30px 30px;
}

.theme-hologram::before {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    background: radial-gradient(circle, transparent 20%, #030b14 100%);
    z-index: -1;
    pointer-events: none;
}

.theme-hologram::after {
    content: '';
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 80vw;
    height: 80vw;
    max-width: 800px;
    max-height: 800px;
    border: 2px dashed rgba(255, 230, 0, 0.1);
    border-radius: 50%;
    box-shadow: 0 0 100px rgba(255, 230, 0, 0.05), inset 0 0 100px rgba(255, 230, 0, 0.05);
    z-index: -1;
    pointer-events: none;
    animation: slow-spin 60s linear infinite;
}

@keyframes slow-spin {
    100% {
        transform: translate(-50%, -50%) rotate(360deg);
    }
}

.theme-hologram .navbar {
    background: rgba(3, 11, 20, 0.8);
    backdrop-filter: blur(10px);
    border-bottom: 1px solid rgba(255, 230, 0, 0.2);
}

.theme-hologram .logo,
.theme-hologram .nav-links a {
    color: #FFE600;
    text-shadow: 0 0 5px #FFE600;
}

.theme-hologram .nav-links a::after {
    background-color: #FFE600;
    box-shadow: 0 0 10px #FFE600;
}

/* HUD Modules & Depth of Field (DOF) */
.theme-hologram .gallery:has(.polaroid:hover) .polaroid:not(:hover),
.theme-hologram .project-gallery:has(.polaroid:hover) .polaroid:not(:hover) {
    filter: grayscale(100%) brightness(0.6);
    transition: filter 0.5s ease;
}

.theme-hologram .polaroid {
    position: relative;
    padding: 0;
    aspect-ratio: 16/9;
    transition: transform 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275), filter 0.3s;
    transform: perspective(1000px) scale(1) rotateX(0deg) rotateY(0deg);
}

body.cms-editing .polaroid {
    transform: none !important;
    transition: none !important;
}

body.cms-editing .project-gallery:has(.polaroid:hover) .polaroid:not(:hover) {
    filter: none !important;
}

.theme-hologram .polaroid-inner {
    width: 100%;
    height: 100%;
    position: relative;
    z-index: 3;
    overflow: hidden;
    clip-path: polygon(20px 0, 100% 0, 100% calc(100% - 20px), calc(100% - 20px) 100%, 0 100%, 0 20px);
}

.theme-hologram .polaroid:hover {
    box-shadow: 0 5px 15px rgba(255, 230, 0, 0.3);
    z-index: 20;
}

/* Corner Reticles */
.theme-hologram .hud-corners::before,
.theme-hologram .hud-corners::after {
    content: '';
    position: absolute;
    width: 30px;
    height: 30px;
    border: 2px solid #FFE600;
    z-index: 10;
    opacity: 1;
    pointer-events: none;
}

.theme-hologram .hud-corners::before {
    top: 15px;
    left: 15px;
    border-right: none;
    border-bottom: none;
    animation: corner-pulse-tl 2s infinite ease-in-out;
}

.theme-hologram .hud-corners::after {
    bottom: 15px;
    right: 15px;
    border-left: none;
    border-top: none;
    animation: corner-pulse-br 2s infinite ease-in-out;
}

@keyframes corner-pulse-tl {

    0%,
    100% {
        transform: translate(0, 0);
    }

    50% {
        transform: translate(4px, 4px);
    }
}

@keyframes corner-pulse-br {

    0%,
    100% {
        transform: translate(0, 0);
    }

    50% {
        transform: translate(-4px, -4px);
    }
}

/* HUD Top Data */
.theme-hologram .hud-name {
    position: absolute;
    top: 10px;
    right: 15px;
    font-size: 0.6rem;
    letter-spacing: 2px;
    color: #FFE600;
    z-index: 5;
    background: rgba(0, 0, 0, 0.6);
    padding: 2px 5px;
    border: 1px solid rgba(255, 230, 0, 0.3);
    text-align: right;
    transition: all 0.3s ease;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    transform: translateZ(0);
}

.theme-hologram .hud-role {
    position: absolute;
    bottom: 10px;
    left: 15px;
    font-size: 0.5rem;
    font-weight: bold;
    letter-spacing: 2px;
    color: #FFE600;
    z-index: 5;
    background: transparent;
    padding: 2px 5px 2px 8px;
    border: none;
    border-bottom: 1px solid rgba(255, 230, 0, 0.5);
    border-left: 2px solid #FFE600;
    text-align: left;
    transition: opacity 0.3s ease, clip-path 0s;
    opacity: 0;
    pointer-events: none;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    transform: translateZ(0);
    clip-path: polygon(-5px -5px, -5px -5px, -5px 110%, -5px 110%);
}

.theme-hologram .hud-role::before {
    content: 'SYS.TYPE // ';
    opacity: 1;
}

.theme-hologram .hud-year {
    position: absolute;
    bottom: 25px;
    left: 15px;
    font-size: 0.7rem;
    font-weight: bold;
    letter-spacing: 2px;
    color: #FFE600;
    z-index: 5;
    background: transparent;
    padding: 0 0 0 8px;
    border: none;
    border-left: 1px solid rgba(255, 230, 0, 0.5);
    display: flex;
    align-items: center;
    gap: 5px;
    transition: opacity 0.3s ease, clip-path 0s;
    opacity: 0;
    pointer-events: none;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    transform: translateZ(0);
    clip-path: polygon(-20px -5px, -20px -5px, -20px 110%, -20px 110%);
}

.theme-hologram .hud-year::before {
    content: 'LOG.DATE: ';
    opacity: 1;
}

.theme-hologram .hud-year::after {
    content: '';
    position: absolute;
    top: 50%;
    left: -15px;
    width: 15px;
    height: 1px;
    background: rgba(255, 230, 0, 0.5);
}

.rec-dot {
    width: 6px;
    height: 6px;
    background: red;
    border-radius: 50%;
    animation: pulse-dot 0.8s infinite;
}

@keyframes pulse-dot {
    0% {
        opacity: 1;
        box-shadow: 0 0 5px red;
    }

    50% {
        opacity: 0.2;
        box-shadow: none;
    }

    100% {
        opacity: 1;
        box-shadow: 0 0 5px red;
    }
}

/* CMS Tools */
.cms-edit-btn {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    background: rgba(255, 230, 0, 0.9);
    color: #000;
    font-family: 'Share Tech Mono', monospace;
    font-size: 1.2rem;
    font-weight: bold;
    border: none;
    padding: 10px 20px;
    cursor: pointer;
    z-index: 100;
    display: none;
    box-shadow: 0 0 20px rgba(255, 230, 0, 0.5);
}

.cms-edit-btn:hover {
    background: #fff;
}

.theme-hologram .polaroid:hover .hud-name {
    background: #FFE600;
    color: #000;
    font-weight: bold;
    border-color: #FFE600;
}

.theme-hologram .polaroid:hover .hud-name::before {
    content: 'PRJ: ';
    opacity: 0.7;
}

.theme-hologram .polaroid:hover .hud-role {
    opacity: 1;
    pointer-events: auto;
    clip-path: polygon(-5px -5px, 120% -5px, 120% 110%, -5px 110%);
    transition: opacity 0.1s ease, clip-path 0.4s steps(20) 0.1s;
}

.theme-hologram .polaroid:hover .hud-year {
    opacity: 1;
    pointer-events: auto;
    clip-path: polygon(-20px -5px, 120% -5px, 120% 110%, -20px 110%);
    transition: opacity 0.1s ease 0.4s, clip-path 0.4s steps(20) 0.5s;
}

/* Scanline */
.theme-hologram .scanline {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 1px;
    background: rgba(255, 230, 0, 0.3);
    box-shadow: 0 0 5px rgba(255, 230, 0, 0.4);
    pointer-events: none;
    z-index: 8;
    opacity: 0;
    transition: opacity 0.5s;
}

.theme-hologram .polaroid:hover .scanline {
    opacity: 1;
    animation: hud-scan 4s infinite linear;
}

@keyframes hud-scan {
    0% {
        top: 0;
        opacity: 0;
    }

    10% {
        opacity: 1;
    }

    90% {
        opacity: 1;
    }

    100% {
        top: 100%;
        opacity: 0;
    }
}

.theme-hologram .tape {
    display: none;
}

/* Stack Images Effect */
.theme-hologram .stack-img {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    z-index: 1;
    opacity: 0;
    transition: transform 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275), opacity 0.4s, filter 0.4s;
    clip-path: polygon(20px 0, 100% 0, 100% calc(100% - 20px), calc(100% - 20px) 100%, 0 100%, 0 20px);
    filter: grayscale(80%) brightness(0.8) sepia(50%) hue-rotate(10deg);
    mix-blend-mode: screen;
}

.theme-hologram .polaroid:hover .stack-img-1 {
    transform: translate(15%, -15%) rotate(6deg);
    opacity: 0.6;
}

.theme-hologram .polaroid:hover .stack-img-2 {
    transform: translate(-15%, 15%) rotate(-6deg);
    opacity: 0.3;
}

/* Image Styling */
.theme-hologram .polaroid-img,
.theme-hologram .placeholder-img {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    display: block;
    -webkit-user-drag: none;
    user-select: none;
}

.theme-hologram .polaroid:hover .polaroid-img {
    transform: scale(1.05);
}

.theme-hologram .placeholder-img {
    background: rgba(255, 230, 0, 0.1);
    color: #FFE600;
    font-family: var(--font-sci);
    display: flex;
    align-items: center;
    justify-content: center;
}

/* Artwork Painting Effect */
.paint-line {
    position: absolute;
    height: 10px;
    background: #FFE600;
    border-radius: 5px;
    transform-origin: 5px 5px;
    pointer-events: none;
    z-index: 5;
    animation: fade-line 1s forwards;
    transform: rotate(var(--angle));
}

@keyframes fade-line {
    0% {
        opacity: 1;
        transform: rotate(var(--angle)) scaleY(1);
    }

    100% {
        opacity: 0;
        transform: rotate(var(--angle)) scaleY(0);
    }
}

/* HUD Overlay Caption */
.theme-hologram .hud-overlay {
    position: absolute;
    bottom: 15px;
    left: 15px;
    right: 15px;
    background: rgba(0, 0, 0, 0.7);
    backdrop-filter: blur(2px);
    border-top: 1px solid #FFE600;
    padding: 10px;
    z-index: 5;
}

.theme-hologram .caption {
    font-size: 1rem;
    text-transform: uppercase;
    letter-spacing: 2px;
    margin: 0;
    text-align: left;
    color: #FFE600;
}

.theme-hologram .caption span {
    display: block;
    font-size: 0.65rem;
    opacity: 0.8;
    margin-top: 3px;
}

.theme-hologram .section-title {
    font-family: var(--font-sci);
    text-transform: uppercase;
    letter-spacing: 3px;
}

.theme-hologram .highlight {
    color: #fff;
}

.theme-hologram .filter-controls {
    text-align: center;
    margin-bottom: 3rem;
}

.theme-hologram .sub-filter-btn {
    background: rgba(0, 0, 0, 0.5);
    color: #FFE600;
    border: 1px solid rgba(255, 230, 0, 0.5);
    font-family: var(--font-sci);
    font-size: 0.8rem;
    letter-spacing: 2px;
    text-transform: uppercase;
    padding: 0.5rem 1rem;
    cursor: pointer;
    transition: 0.3s;
    clip-path: polygon(10px 0, 100% 0, 100% calc(100% - 10px), calc(100% - 10px) 100%, 0 100%, 0 10px);
    margin: 0 5px;
}

.theme-hologram .sub-filter-btn:hover,
.theme-hologram .sub-filter-btn.active {
    background: rgba(255, 230, 0, 0.2);
    box-shadow: 0 0 15px rgba(255, 230, 0, 0.5);
    border-color: #FFE600;
    text-shadow: 0 0 5px #FFE600;
}

/* -----------------------------
   THEME: WORKSPACE (2D & Directing)
   ----------------------------- */
.theme-workspace {
    background-color: transparent;
    color: #cccccc;
    font-family: var(--font-ui);
}

.theme-workspace .navbar {
    background: #252526;
    border-bottom: 1px solid #333;
}

.theme-workspace .logo,
.theme-workspace .nav-links a {
    color: #cccccc;
}

.theme-workspace .nav-links a::after {
    background-color: #007acc;
}

.theme-workspace .section-title {
    font-family: var(--font-ui);
    font-size: 2rem;
    text-align: left;
    margin-bottom: 1rem;
    color: #FFE600;
    text-shadow: 1px 1px 10px rgba(0, 0, 0, 0.8);
}

.theme-workspace .highlight {
    color: #fff;
}

.theme-workspace .filter-controls {
    background: transparent;
    padding: 10px 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 2rem;
}

.theme-workspace .sub-filter-btn {
    background: transparent;
    border: none;
    color: #fff;
    text-shadow: 1px 1px 3px rgba(0, 0, 0, 0.8);
    padding: 5px 15px;
    font-size: 0.95rem;
    border-radius: 3px;
    cursor: pointer;
    font-family: var(--font-compact);
    letter-spacing: 1px;
    text-transform: uppercase;
}

.theme-workspace .sub-filter-btn:hover {
    background: transparent;
    color: #fff;
}

.theme-workspace .sub-filter-btn.active {
    background: transparent;
    color: #FFE600;
    text-shadow: 1px 1px 3px rgba(0, 0, 0, 0.8);
    font-weight: bold;
}

.theme-workspace .gallery {
    gap: 30px;
    padding: 0;
    background: transparent;
    border: none;
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(400px, 1fr));
}

.theme-workspace .polaroid {
    background: #252526;
    border: 1px solid #333;
    border-radius: 4px;
    padding: 5px;
    padding-bottom: 15px;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.3);
    transition: 0.2s;
    cursor: pointer;
}

.theme-workspace .polaroid:hover {
    border-color: #555;
}

.theme-workspace .tape {
    display: none;
}

.theme-workspace .polaroid-img {
    width: 100%;
    border-radius: 2px;
    aspect-ratio: 16/9;
    object-fit: cover;
}

.theme-workspace .project-gallery .polaroid-img {
    aspect-ratio: auto;
    object-fit: contain;
}

.theme-workspace .placeholder-img {
    width: 100%;
    aspect-ratio: 16/9;
    background: #333;
    color: #888;
    display: flex;
    align-items: center;
    justify-content: center;
}

.theme-workspace .caption {
    font-size: 0.85rem;
    text-align: left;
    margin-left: 5px;
    margin-top: 8px;
    font-weight: 600;
    color: #e0e0e0;
}

.theme-workspace .caption span {
    font-size: 0.75rem;
    color: #888;
    display: block;
    font-weight: normal;
    margin-top: 2px;
}

/* -----------------------------
   THEME: NOTEBOOK (Poems)
   ----------------------------- */
.theme-notebook {
    background-color: #fffdf5;
    background-image:
        linear-gradient(rgba(0, 0, 0, 0.1) 1px, transparent 1px),
        url('assets/POEMS/resources/tiling_paper_texture.avif');
    background-size: 100% 2rem, auto;
    background-position: 0 0, 0 0;
    color: #2b3a4a;
    font-family: var(--font-hand);
    font-size: 1.5rem;
}

.theme-notebook h1,
.theme-notebook h2,
.theme-notebook h3 {
    font-family: var(--font-hand);
}

.theme-notebook .section-title {
    line-height: 4rem;
    margin-bottom: 2rem;
}

.theme-notebook .poems-layout {
    margin-top: 2rem;
}

.theme-notebook .poem-card {
    background: transparent;
    border: none;
    padding: 0;
    box-shadow: none;
    display: flex;
    gap: 4rem;
    align-items: flex-start;
    justify-content: center;
    margin-bottom: 6rem;
}

.theme-notebook .poem-card.row-reverse {
    flex-direction: row-reverse;
}

.theme-notebook .poem-card img {
    width: 100%;
    max-width: 400px;
    border-radius: 4px;
    border: 1px solid rgba(0, 0, 0, 0.1);
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.1);
}

.theme-notebook .poem-content {
    width: 100%;
    max-width: 500px;
}

.theme-notebook ::selection {
    background-color: rgba(255, 230, 0, 0.6);
    color: #000;
}

.theme-notebook .highlight {
    color: #000;
    background-color: transparent;
    background-image:
        linear-gradient(3deg, transparent 5%, rgba(255, 230, 0, 0.7) 8%, rgba(255, 230, 0, 0.5) 55%, transparent 60%),
        linear-gradient(-4deg, transparent 35%, rgba(255, 230, 0, 0.5) 40%, rgba(255, 230, 0, 0.6) 90%, transparent 95%),
        linear-gradient(1deg, transparent 20%, rgba(255, 230, 0, 0.4) 22%, rgba(255, 230, 0, 0.4) 75%, transparent 78%);
    mix-blend-mode: multiply;
    padding: 0 0.5rem;
    display: inline-block;
}

.theme-notebook .poem-title {
    font-family: var(--font-head);
    color: #000;
    background-color: transparent;
    background-image:
        linear-gradient(3deg, transparent 5%, rgba(255, 230, 0, 0.7) 8%, rgba(255, 230, 0, 0.5) 55%, transparent 60%),
        linear-gradient(-4deg, transparent 35%, rgba(255, 230, 0, 0.5) 40%, rgba(255, 230, 0, 0.6) 90%, transparent 95%),
        linear-gradient(1deg, transparent 20%, rgba(255, 230, 0, 0.4) 22%, rgba(255, 230, 0, 0.4) 75%, transparent 78%);
    mix-blend-mode: multiply;
    font-size: 1.8rem;
    line-height: 2rem;
    margin-top: 0;
    margin-bottom: 2rem;
    width: fit-content;
    padding: 0 0.5rem;
    margin-left: -0.5rem;
}

.theme-notebook .poem-subtitle {
    font-style: italic;
    font-size: 1.5rem;
    line-height: 2rem;
    opacity: 1;
    margin-top: 0;
    margin-bottom: 2rem;
    color: #000;
    font-weight: bold;
}

.theme-notebook .poem-text {
    line-height: 2rem;
    margin-top: 0;
    color: #000;
}

@media (max-width: 768px) {

    .theme-notebook .poem-card,
    .theme-notebook .poem-card.row-reverse {
        flex-direction: column;
        padding-left: 0;
        gap: 1.5rem;
    }
}

.theme-notebook .poem-date {
    color: #666;
    margin-top: 1rem;
}

.theme-notebook .logo {
    display: inline-block;
    width: 200px;
    height: 40px;
    background: url('assets/POEMS/resources/baji.digital_sketch.webp') no-repeat left center;
    background-size: contain;
    text-indent: -9999px;
    overflow: hidden;
}

.theme-notebook .nav-links a {
    color: #2b3a4a;
}

.theme-notebook .navbar {
    background: linear-gradient(to bottom, #fffdf5 80%, transparent);
}

.theme-notebook .nav-links a::after {
    background-color: #FFE600;
}

/* Poems Sidebar Layout */
.theme-notebook .poems-layout {
    display: flex;
    gap: 4rem;
    align-items: flex-start;
    margin-top: 2rem;
}

.theme-notebook .poems-sidebar {
    width: 320px;
    flex-shrink: 0;
    border-right: 2px solid #ff4d4d;
    padding-right: 2rem;
    position: sticky;
    top: 100px;
    height: calc(100vh - 120px);
    overflow-y: auto;
}

/* Custom scrollbar for sidebar */
.theme-notebook .poems-sidebar::-webkit-scrollbar {
    width: 6px;
}

.theme-notebook .poems-sidebar::-webkit-scrollbar-track {
    background: transparent;
}

.theme-notebook .poems-sidebar::-webkit-scrollbar-thumb {
    background: rgba(0, 0, 0, 0.2);
    border-radius: 4px;
}

.theme-notebook .poems-sidebar::-webkit-scrollbar-thumb:hover {
    background: rgba(0, 0, 0, 0.4);
}

.theme-notebook .sidebar-header {
    font-family: var(--font-hand);
    font-size: 1.8rem;
    margin-bottom: 1.5rem;
    color: #2b3a4a;
    border-bottom: 2px dashed rgba(0, 0, 0, 0.15);
    padding-bottom: 0.5rem;
}

.theme-notebook .sidebar-item {
    display: flex;
    align-items: center;
    gap: 15px;
    cursor: pointer;
    padding: 12px;
    border-radius: 8px;
    transition: 0.3s;
    position: relative;
}

.theme-notebook .sidebar-item:hover {
    background: rgba(0, 0, 0, 0.05);
    transform: translateX(5px);
}

.theme-notebook .sidebar-item.active {
    background: url('assets/POEMS/resources/tape.webp') no-repeat center center;
    background-size: 100% 100%;
    transform: translateX(5px);
    position: relative;
    filter: drop-shadow(0px 2px 3px rgba(0, 0, 0, 0.2));
}

.theme-notebook .sidebar-item img {
    width: 60px;
    height: 60px;
    object-fit: cover;
    border-radius: 4px;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.1);
    border: 1px solid rgba(0, 0, 0, 0.1);
}

.theme-notebook .sidebar-item-text h4 {
    font-family: var(--font-head);
    font-size: 1.1rem;
    margin: 0 0 5px 0;
    color: #2b3a4a;
    line-height: 1.2;
}

.theme-notebook .sidebar-item-text span {
    font-family: var(--font-body);
    font-size: 0.85rem;
    color: #666;
    font-style: italic;
}

.theme-notebook .poems-main {
    flex: 1;
}

section.poems-section {
    padding-top: 8rem;
}

@media (max-width: 900px) {
    .theme-notebook .poems-layout {
        flex-direction: column;
        gap: 2rem;
    }

    .theme-notebook .poems-sidebar {
        width: 100%;
        border-right: none;
        border-bottom: 2px dashed rgba(0, 0, 0, 0.15);
        padding-right: 0;
        padding-bottom: 2rem;
    }
}

/* -----------------------------
   ARTWORK DETAIL PAGES
   ----------------------------- */
.project-description {
    max-width: 800px;
    margin: 0 auto 3rem auto;
    text-align: center;
    font-size: 1.1rem;
    line-height: 1.8;
    color: #b0e0e6;
}

.project-description p {
    margin-bottom: 1rem;
}

.project-gallery {
    display: flex;
    flex-direction: column;
    gap: 2rem;
    align-items: center;
}

.project-gallery.grid-view {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
    gap: 2rem;
    width: 100%;
    max-width: 1200px;
    margin: 0 auto;
    align-items: stretch;
    grid-auto-flow: dense;
}

.project-gallery.grid-view .video-container {
    grid-column: 1 / -1;
    max-width: 1000px;
    margin: 0 auto 2rem auto;
}

.project-gallery .polaroid {
    width: 100%;
    max-width: 1000px;
    padding: 0;
}

.project-gallery.grid-view .polaroid {
    max-width: none;
}

.project-gallery .polaroid-inner {
    aspect-ratio: 16 / 9;
    background: #000;
    display: flex;
    align-items: center;
    justify-content: center;
}

.project-gallery .polaroid-img {
    border: none;
    margin: 0;
    box-shadow: none;
    max-width: 100%;
    max-height: 100%;
    object-fit: contain;
    aspect-ratio: auto;
}

/* -----------------------------
   FULLSCREEN HUD LIGHTBOX
   ----------------------------- */
.hud-lightbox {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    background: rgba(0, 0, 0, 0.95);
    z-index: 2000;
    display: flex;
    justify-content: center;
    align-items: center;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.3s;
}

.hud-lightbox.active {
    opacity: 1;
    pointer-events: auto;
}

.hud-lightbox-content {
    position: relative;
    max-width: 90vw;
    max-height: 90vh;
}

.hud-lightbox-content img {
    max-width: 100%;
    max-height: 90vh;
    object-fit: contain;
    -webkit-user-drag: none;
    user-select: none;
    border: 1px solid rgba(255, 230, 0, 0.3);
    box-shadow: 0 0 20px rgba(255, 230, 0, 0.2);
}

.hud-lightbox-close {
    position: absolute;
    top: 20px;
    right: 40px;
    color: #FFE600;
    font-size: 1.5rem;
    cursor: pointer;
    font-family: var(--font-sci);
    z-index: 2010;
    padding: 10px;
    text-shadow: 0 0 10px #FFE600;
    user-select: none;
    -webkit-user-select: none;
}

.hud-lightbox-close:hover {
    color: #fff;
    text-shadow: 0 0 15px #fff;
}

/* High-tech Navigation Buttons */
.hud-nav-btn {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    display: flex;
    align-items: center;
    gap: 15px;
    cursor: pointer;
    z-index: 2010;
    padding: 20px;
    transition: transform 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    user-select: none;
    -webkit-user-select: none;
}

.hud-nav-btn .chevron {
    width: 25px;
    height: 25px;
    border: 2px solid rgba(255, 230, 0, 0.3);
    transform: rotate(45deg);
    transition: 0.3s;
}

.hud-nav-btn .nav-text {
    font-family: var(--font-sci);
    font-size: 0.7rem;
    letter-spacing: 4px;
    color: rgba(255, 230, 0, 0.5);
    transition: 0.3s;
    background: rgba(0, 0, 0, 0.6);
    padding: 4px 8px;
    border: 1px solid rgba(255, 230, 0, 0.2);
}

.hud-lightbox-prev {
    left: 20px;
}

.hud-lightbox-prev .chevron {
    border-top: none;
    border-right: none;
}

.hud-lightbox-next {
    right: 20px;
}

.hud-lightbox-next .chevron {
    border-bottom: none;
    border-left: none;
}

.hud-nav-btn:hover {
    transform: translateY(-50%) scale(1.05);
}

.hud-nav-btn:hover .chevron {
    border-color: #FFE600;
    filter: drop-shadow(0 0 8px #FFE600);
}

.hud-nav-btn:hover .nav-text {
    color: #FFE600;
    text-shadow: 0 0 8px #FFE600;
    border-color: #FFE600;
    box-shadow: 0 0 10px rgba(255, 230, 0, 0.2);
}

/* -----------------------------
   COMMON STRUCTURE
   ----------------------------- */
.container {
    max-width: 92%;
    margin: 0 auto;
    padding: 4rem 2rem;
    position: relative;
}

.section-title {
    font-size: 3rem;
    margin-bottom: 2rem;
    text-align: center;
}

.navbar {
    position: fixed;
    top: 0;
    width: 100%;
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1.5rem 3rem;
    z-index: 1000;
}

.logo {
    font-family: var(--font-compact);
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1px;
    font-size: 2rem;
    text-decoration: none;
}

.nav-links {
    display: flex;
    list-style: none;
    gap: 2rem;
}

.nav-links a {
    font-family: var(--font-compact);
    font-size: 1.2rem;
    letter-spacing: 1px;
    font-weight: 500;
    text-transform: uppercase;
    text-decoration: none;
    position: relative;
    transition: 0.3s;
}

.nav-links a::after {
    content: '';
    position: absolute;
    bottom: -5px;
    left: 0;
    width: 100%;
    height: 2px;
    transform: scaleX(0);
    transition: 0.3s;
}

.nav-links a:hover::after,
.nav-links .active-link::after {
    transform: scaleX(1);
}

.gallery {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 5px;
}

.polaroid.hide {
    display: none !important;
}

.footer {
    text-align: center;
    padding: 2rem;
    opacity: 0.5;
    font-size: 0.9rem;
    margin-top: 5rem;
}

@media (max-width: 1024px) {

    .gallery,
    .theme-workspace .gallery {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 768px) {
    .theme-cinematic .intro-card {
        flex-direction: column;
    }

    .hero-title-main {
        font-size: 3rem !important;
    }

    .gallery,
    .theme-workspace .gallery {
        grid-template-columns: 1fr;
    }
}

/* --- CMS Actions --- */
.cms-layout-toolbar {
    position: absolute;
    top: 10px;
    left: 10px;
    display: none;
    gap: 5px;
    z-index: 50;
}

.cms-layout-btn {
    background: rgba(10, 10, 10, 0.8);
    color: #FFE600;
    border: 1px solid #FFE600;
    padding: 5px;
    cursor: pointer;
    font-family: 'Share Tech Mono', monospace;
    font-size: 1rem;
    line-height: 1;
    width: 30px;
    height: 30px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.cms-layout-btn.active {
    background: #FFE600;
    color: #000;
}

.cms-delete-btn {
    position: absolute;
    top: 10px;
    right: 10px;
    background: rgba(10, 10, 10, 0.8);
    color: #FFE600;
    border: 1px solid #FFE600;
    padding: 5px 10px;
    cursor: pointer;
    z-index: 50;
    display: none;
    font-family: 'Share Tech Mono', monospace;
    font-size: 0.9rem;
}

.project-gallery.grid-view .polaroid.featured-left {
    grid-column: span 2;
}

.project-gallery.grid-view .polaroid.featured-right {
    grid-column: span 2 / -1;
}

.project-gallery.grid-view .polaroid.featured-full {
    grid-column: 1 / span 3;
}

@media (max-width: 1100px) {
    .project-gallery.grid-view .polaroid.featured-full {
        grid-column: span 2;
    }
}

@media (max-width: 768px) {

    .project-gallery.grid-view .polaroid.featured-left,
    .project-gallery.grid-view .polaroid.featured-right,
    .project-gallery.grid-view .polaroid.featured-full {
        grid-column: span 1;
    }
}

/* --- CINEMATIC VIEWFINDER CONCEPT (2D) --- */
.cinematic-card {
    position: relative;
    border: none !important;
    background: #0a0a0a !important;
    border-radius: 12px !important;
    padding: 20px 20px 5px 20px !important;
    font-family: var(--font-type);
    color: #fff;
    cursor: pointer;
}

.cinematic-card .cinematic-frame {
    position: relative;
    overflow: hidden;
    filter: contrast(1);
    border-radius: 6px;
    border: 2px solid transparent;
    transition: border-color 0.3s, box-shadow 0.3s;
    transform: translateZ(0);
    /* Hardware acceleration */
    will-change: transform, filter;
}

@keyframes autofocus-hunt {
    0% {
        filter: contrast(1);
        opacity: 1;
    }

    50% {
        filter: contrast(1.1);
        opacity: 0.8;
    }

    100% {
        filter: contrast(1.05);
        opacity: 1;
    }
}

.cinematic-card:hover .cinematic-frame {
    border-color: #4ade80;
    box-shadow: 0 0 15px rgba(74, 222, 128, 0.4);
    animation: autofocus-hunt 0.2s cubic-bezier(0.1, 0.9, 0.2, 1) forwards;
}

.focus-status {
    position: absolute;
    top: 5px;
    left: 20px;
    color: #4ade80;
    font-size: 0.7rem;
    display: flex;
    gap: 10px;
    opacity: 0;
    transition: opacity 0.3s;
    pointer-events: none;
    z-index: 10;
}

.cinematic-card:hover .focus-status {
    opacity: 1;
}

.focus-status .tick {
    font-size: 0.5rem;
    margin-top: 2px;
}

.cinematic-card .polaroid-img {
    width: 100%;
    aspect-ratio: 16/9;
    object-fit: cover;
    transition: transform 0.4s cubic-bezier(0.1, 0.9, 0.2, 1) !important;
    display: block;
    border-radius: 0 !important;
    transform: scale(1) translateZ(0);
    will-change: transform;
}

.cinematic-card:hover .polaroid-img {
    transform: scale(1.05) translateZ(0) !important;
}

.camera-grid {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: 2;
    opacity: 0.3;
    transition: opacity 0.3s;
}

.cinematic-card:hover .camera-grid {
    opacity: 0.8;
}

.camera-grid .grid-line {
    position: absolute;
    background: rgba(255, 255, 255, 0.5);
}

.camera-grid .grid-line.h-top {
    top: 33.33%;
    left: 0;
    width: 100%;
    height: 1px;
}

.camera-grid .grid-line.h-bot {
    top: 66.66%;
    left: 0;
    width: 100%;
    height: 1px;
}

.camera-grid .grid-line.v-left {
    left: 33.33%;
    top: 0;
    width: 1px;
    height: 100%;
}

.camera-grid .grid-line.v-right {
    left: 66.66%;
    top: 0;
    width: 1px;
    height: 100%;
}

.camera-grid .crosshair {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 30px;
    height: 30px;
}

.camera-grid .crosshair::before,
.camera-grid .crosshair::after {
    content: '';
    position: absolute;
    background: rgba(255, 255, 255, 0.5);
    transition: background 0.2s;
}

.camera-grid .crosshair::before {
    top: 50%;
    left: 0;
    width: 100%;
    height: 1px;
    transform: translateY(-50%);
}

.camera-grid .crosshair::after {
    left: 50%;
    top: 0;
    width: 1px;
    height: 100%;
    transform: translateX(-50%);
}

.cinematic-card:hover .camera-grid .crosshair::before,
.cinematic-card:hover .camera-grid .crosshair::after {
    background: rgba(255, 0, 0, 0.8);
}

.rec-indicator {
    position: absolute;
    top: 15px;
    left: 15px;
    color: #fff;
    font-size: 0.8rem;
    font-weight: bold;
    display: flex;
    align-items: center;
    gap: 5px;
    z-index: 3;
    opacity: 0;
    transition: opacity 0.3s;
}

.cinematic-card:hover .rec-indicator {
    opacity: 1;
    animation: blink 1s infinite;
}

@keyframes blink {

    0%,
    100% {
        opacity: 1;
    }

    50% {
        opacity: 0;
    }
}

.rec-indicator .red-dot {
    width: 8px;
    height: 8px;
    background: red;
    border-radius: 50%;
    display: inline-block;
}

.metadata {
    position: absolute;
    font-size: 0.75rem;
    color: rgba(255, 255, 255, 0.8);
    z-index: 3;
    pointer-events: none;
    line-height: 1.4;
    text-shadow: 1px 1px 2px rgba(0, 0, 0, 0.8);
}

.metadata.bottom-left {
    bottom: 15px;
    left: 15px;
}

.metadata.bottom-right {
    bottom: 15px;
    right: 15px;
    text-align: right;
}

.cinematic-title {
    padding-top: 15px;
    padding-bottom: 5px;
    background: transparent;
    font-size: 1.4rem;
    font-weight: 700;
    letter-spacing: 2px;
    text-align: left;
    color: #fff;
    text-shadow: 1px 1px 3px rgba(0, 0, 0, 0.8);
    font-family: var(--font-compact);
    text-transform: uppercase;
    transition: color 0.3s;
}

.cinematic-card:hover .cinematic-title {
    color: #FFE600;
}

/* --- LIQUID GLASS (WebGL) --- */
.glass-container {
    position: relative;
    border-radius: 12px !important;
    background-color: transparent !important;
    border: none !important;
    box-shadow: none !important;
}

.glass-content {
    position: relative;
    z-index: 3;
}