:root {
    --bg-color: #0b0c10;
    --text-color: #f0f0f0;
    --accent: #ff4500;
    --steel: #8b9298;
    --dark-grey: #1a1a1a;
    
    --font-heading: 'Syne', sans-serif;
    --font-body: 'Inter', sans-serif;
    
    --transition: all 0.4s cubic-bezier(0.25, 1, 0.5, 1);
}

html {
    font-size: 16px;
}

@media (max-width: 768px) {
    html {
        font-size: 14px;
    }
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    cursor: none; /* Custom cursor */
}

body.loading,
body.modal-open,
body.menu-open {
    overflow: hidden !important;
}

body {
    background: var(--bg-color);
    color: var(--text-color);
    font-family: var(--font-body);
    overflow-x: hidden;
    line-height: 1.6;
}

/* Custom Cursor */
.cursor-dot,
.cursor-outline {
    position: fixed;
    top: 0;
    left: 0;
    transform: translate(-50%, -50%);
    border-radius: 50%;
    z-index: 9999;
    pointer-events: none;
}

.cursor-dot {
    width: 8px;
    height: 8px;
    background-color: var(--accent);
}

.cursor-outline {
    width: 40px;
    height: 40px;
    border: 1px solid rgba(255, 69, 0, 0.5);
    transition: width 0.2s, height 0.2s, background-color 0.2s;
}

/* Typography */
h1, h2, h3, h4 {
    font-family: var(--font-heading);
    font-weight: 800;
    line-height: 1.1;
    text-transform: capitalize;
    color: var(--accent);
}

.hero-title {
    font-size: clamp(1.8rem, 5vw, 4.5rem);
    letter-spacing: -1px;
}

.hero-title.indent {
    margin-left: 10vw;
    color: transparent;
    -webkit-text-stroke: 2px var(--text-color);
}

.section-title {
    font-size: clamp(1.8rem, 4vw, 3rem);
    margin-bottom: 2rem;
}

.huge-text {
    font-size: clamp(3rem, 6vw, 5.5rem);
    line-height: 1;
    letter-spacing: -2px;
    margin-bottom: 3rem;
}

.text-orange {
    color: var(--accent);
}

.container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 2rem;
}

/* Navbar */
.navbar {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    padding: 2rem 0;
    z-index: 100;
    transition: var(--transition);
}

.navbar.scrolled {
    padding: 1rem 0;
    background: rgba(11, 12, 16, 0.8);
    backdrop-filter: blur(10px);
    border-bottom: 1px solid rgba(255,255,255,0.05);
}

.nav-container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 2rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo {
    display: flex;
    align-items: center;
    gap: 1rem;
    text-decoration: none;
    color: var(--text-color);
}

.logo-img {
    height: 30px;
}

.logo-text {
    font-family: var(--font-heading);
    font-weight: 700;
    font-size: 1.2rem;
}

.nav-links {
    display: flex;
    gap: 3rem;
    align-items: center;
}

.nav-link {
    color: var(--text-color);
    text-decoration: none;
    font-size: 0.9rem;
    text-transform: capitalize;
    letter-spacing: 1px;
    position: relative;
    overflow: hidden;
}

.nav-link::after {
    content: '';
    position: absolute;
    bottom: -2px;
    left: 0;
    width: 0%;
    height: 2px;
    background: var(--accent);
    transition: var(--transition);
}

.nav-link:hover::after {
    width: 100%;
}

.menu-toggle {
    display: none;
    flex-direction: column;
    justify-content: space-between;
    width: 30px;
    height: 20px;
    cursor: none;
    z-index: 1000;
}

.menu-toggle span {
    width: 100%;
    height: 2px;
    background-color: var(--text-color);
    transition: var(--transition);
}

.menu-toggle.active span:nth-child(1) {
    transform: translateY(9px) rotate(45deg);
}

.menu-toggle.active span:nth-child(2) {
    transform: translateY(-9px) rotate(-45deg);
}

/* Mobile Menu Overlay */
.mobile-menu {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100vh;
    background: rgba(11, 12, 16, 0.98);
    backdrop-filter: blur(20px);
    z-index: 99;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    opacity: 0;
    pointer-events: none;
    transition: var(--transition);
}

.mobile-menu.active {
    opacity: 1;
    pointer-events: all;
}

.mobile-nav-links {
    display: flex;
    flex-direction: column;
    gap: 2rem;
    text-align: center;
}

.mobile-nav-links a {
    color: var(--text-color);
    text-decoration: none;
    font-family: var(--font-heading);
    font-size: 3rem;
    font-weight: 700;
    text-transform: capitalize;
    transition: var(--transition);
}

.mobile-nav-links a:hover {
    color: var(--accent);
}

/* Buttons */
.btn {
    display: inline-flex;
    align-items: center;
    gap: 1rem;
    padding: 1rem 2.5rem;
    font-family: var(--font-heading);
    font-weight: 600;
    text-transform: capitalize;
    text-decoration: none;
    border-radius: 50px;
    transition: var(--transition);
}

.btn-solid {
    background: var(--accent);
    color: var(--bg-color);
}

.btn-solid:hover {
    background: #fff;
}

.btn-outline {
    border: 1px solid rgba(255,255,255,0.2);
    color: var(--text-color);
}

.btn-outline:hover {
    border-color: var(--accent);
    color: var(--accent);
}

/* Hero */
.hero {
    height: 100vh;
    display: flex;
    align-items: flex-end;
    padding-bottom: 10vh;
    position: relative;
    overflow: hidden;
}

.hero-content {
    transition: transform 0.2s cubic-bezier(0.25, 1, 0.5, 1);
}

.hero-bg {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-size: cover;
    background-position: center;
    z-index: -2;
    transform: scale(1.1);
    transition: transform 0.2s cubic-bezier(0.25, 1, 0.5, 1);
}

.hero-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(0deg, var(--bg-color) 0%, rgba(11,12,16,0.3) 100%);
    z-index: -1;
}

/* 3D Floating Background Objects */
.floating-objects {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    overflow: hidden;
    z-index: 0;
    pointer-events: none;
    perspective: 1000px;
}

.shape {
    position: absolute;
    bottom: -100px;
    background: transparent;
    animation: float3D 15s linear infinite;
    transform-style: preserve-3d;
}

.shape-square {
    width: 40px;
    height: 40px;
    border: 2px solid rgba(255, 69, 0, 0.4);
    left: 10%;
    animation-duration: 20s;
}

.shape-circle {
    width: 30px;
    height: 30px;
    background: rgba(255, 69, 0, 0.2);
    border-radius: 50%;
    left: 30%;
    animation-duration: 25s;
    animation-delay: 2s;
}

.shape-ring {
    width: 50px;
    height: 50px;
    border: 3px solid rgba(255, 255, 255, 0.1);
    border-radius: 50%;
    left: 60%;
    animation-duration: 18s;
    animation-delay: 4s;
}

.shape-dot {
    width: 10px;
    height: 10px;
    background: var(--accent);
    border-radius: 50%;
    left: 80%;
    animation-duration: 12s;
    animation-delay: 1s;
    box-shadow: 0 0 10px var(--accent);
}

.shape.s-2 {
    left: 20%;
    animation-duration: 22s;
    animation-delay: 5s;
    opacity: 0.5;
    transform: scale(0.6);
}

.shape.s-2.shape-ring { left: 45%; animation-delay: 7s; }
.shape.s-2.shape-circle { left: 75%; animation-delay: 3s; }
.shape.s-2.shape-dot { left: 90%; animation-delay: 6s; }

.shape.s-3 {
    left: 85%;
    animation-duration: 28s;
    animation-delay: 8s;
    opacity: 0.3;
    transform: scale(1.5);
}

.shape.s-3.shape-ring { left: 15%; animation-delay: 10s; }

@keyframes float3D {
    0% {
        transform: translateY(0) rotateX(0deg) rotateY(0deg) rotateZ(0deg);
        opacity: 0;
    }
    10% {
        opacity: 1;
    }
    90% {
        opacity: 1;
    }
    100% {
        transform: translateY(-120vh) rotateX(360deg) rotateY(180deg) rotateZ(360deg);
        opacity: 0;
    }
}

/* Global Floating Background Objects */
.global-background-objects {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    overflow: hidden;
    z-index: -3;
    pointer-events: none;
    perspective: 1000px;
    background-color: var(--bg-color); /* Deep black base */
}

.g-shape {
    position: absolute;
    bottom: -120px;
    background: transparent;
    animation: floatGlobal3D 25s linear infinite;
    transform-style: preserve-3d;
    opacity: 0;
}

/* Base shapes and colors */
.g-shape-square {
    width: 60px;
    height: 60px;
    border: 2px solid rgba(255, 69, 0, 0.45); /* 45% opacity orange */
    left: 5%;
    animation-duration: 22s;
}

.g-shape-circle {
    width: 50px;
    height: 50px;
    background: rgba(255, 69, 0, 0.22); /* 22% opacity orange fill */
    border-radius: 50%;
    left: 25%;
    animation-duration: 28s;
    animation-delay: 2s;
}

.g-shape-ring {
    width: 70px;
    height: 70px;
    border: 2.5px solid rgba(255, 255, 255, 0.28); /* 28% opacity white ring */
    border-radius: 50%;
    left: 55%;
    animation-duration: 20s;
    animation-delay: 4s;
}

.g-shape-dot {
    width: 14px;
    height: 14px;
    background: rgba(255, 69, 0, 0.65); /* 65% opacity orange dot */
    border-radius: 50%;
    left: 75%;
    animation-duration: 15s;
    animation-delay: 1s;
    box-shadow: 0 0 10px rgba(255, 69, 0, 0.7);
}

/* Modifiers for variations (g-2, g-3, g-4) */
.g-shape.g-2 {
    animation-duration: 24s;
    animation-delay: 6s;
    transform: scale(0.85);
}
.g-shape.g-2.g-shape-square { left: 18%; border-color: rgba(255, 255, 255, 0.25); }
.g-shape.g-2.g-shape-ring { left: 40%; animation-delay: 8s; }
.g-shape.g-2.g-shape-circle { left: 70%; animation-delay: 4s; }
.g-shape.g-2.g-shape-dot { left: 88%; animation-delay: 7s; }

.g-shape.g-3 {
    animation-duration: 30s;
    animation-delay: 10s;
    transform: scale(1.4);
}
.g-shape.g-3.g-shape-square { left: 12%; }
.g-shape.g-3.g-shape-ring { left: 48%; border-color: rgba(255, 69, 0, 0.35); }
.g-shape.g-3.g-shape-circle { left: 82%; background: rgba(255, 255, 255, 0.18); }
.g-shape.g-3.g-shape-dot { left: 95%; animation-delay: 11s; }

.g-shape.g-4 {
    animation-duration: 26s;
    animation-delay: 13s;
    transform: scale(0.7);
}
.g-shape.g-4.g-shape-square { left: 32%; border-color: rgba(255, 69, 0, 0.45); }
.g-shape.g-4.g-shape-ring { left: 64%; }
.g-shape.g-4.g-shape-circle { left: 92%; }

@keyframes floatGlobal3D {
    0% {
        transform: translateY(0) rotateX(0deg) rotateY(0deg) rotateZ(0deg);
        opacity: 0;
    }
    10% {
        opacity: 0.8;
    }
    90% {
        opacity: 0.8;
    }
    100% {
        transform: translateY(-115vh) rotateX(360deg) rotateY(180deg) rotateZ(360deg);
        opacity: 0;
    }
}

.hero-meta {
    margin-top: 4rem;
    display: flex;
    justify-content: space-between;
    align-items: flex-end;
    border-top: 1px solid rgba(255,255,255,0.1);
    padding-top: 2rem;
}

/* MD Message */
.md-message {
    padding: 10rem 0;
    background: rgba(26, 26, 26, 0.45);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
}

.md-grid {
    display: grid;
    grid-template-columns: 1fr 2fr;
    gap: 6rem;
    align-items: center;
}

.md-image-col {
    position: relative;
}

.md-img {
    width: 100%;
    height: 500px;
    background-size: cover;
    background-position: center;
    border-radius: 15px;
    filter: grayscale(100%);
    transition: var(--transition);
}

.md-image-col:hover .md-img {
    filter: grayscale(0%);
    transform: scale(1.02);
}

.md-signature {
    margin-top: 2rem;
    padding-left: 1.5rem;
    border-left: 3px solid var(--accent);
}

.md-signature h3 {
    font-size: 1.5rem;
    margin-bottom: 0.2rem;
}

.md-signature p {
    color: var(--steel);
    font-family: var(--font-heading);
    text-transform: capitalize;
    font-size: 0.9rem;
    font-weight: 700;
}

.md-quote p {
    font-size: 1.05rem;
    color: var(--steel);
    margin-bottom: 1.5rem;
    line-height: 1.8;
}

.md-quote p:first-child {
    color: var(--text-color);
    font-size: 1.25rem;
    font-weight: 500;
}

/* Bento Section */
.bento-section {
    padding: 10rem 0;
}

.bento-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    grid-auto-rows: minmax(200px, auto);
    gap: 1.5rem;
    margin-top: 4rem;
}

.bento-item {
    border-radius: 20px;
    padding: 2.5rem;
    position: relative;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
}

.bento-large {
    grid-column: span 2;
    grid-row: span 2;
    background-size: cover;
    background-position: center;
}

.bento-overlay {
    position: absolute;
    bottom: 0; left: 0; width: 100%;
    padding: 2rem;
    background: linear-gradient(to top, rgba(0,0,0,0.8), transparent);
}

.bento-stats {
    grid-column: span 1;
    grid-row: span 1;
    justify-content: center;
    align-items: center;
    text-align: center;
}

.stat-number {
    font-size: 2.2rem;
    color: var(--accent);
}

.bento-service {
    grid-column: span 1;
    grid-row: span 1;
}

.bento-wide {
    grid-column: span 4;
    grid-row: span 1;
    align-items: center;
    justify-content: center;
}

.bg-dark { background: var(--dark-grey); }
.bg-orange { background: var(--accent); color: var(--bg-color); }
.bg-grey { background: var(--steel); color: var(--bg-color); }

.divider { color: var(--accent); }

.clients-marquee {
    display: flex;
    width: 200%; /* Enough width to hold two contents */
    animation: scrollMarquee 35s linear infinite;
    cursor: none;
}

.clients-marquee:hover {
    animation-play-state: paused;
}

.marquee-content {
    display: flex;
    gap: 2rem;
    font-family: var(--font-heading);
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--steel);
    white-space: nowrap;
    padding-right: 2rem;
    align-items: center;
}

.client-item {
    display: flex;
    align-items: center;
    gap: 1rem;
    cursor: pointer;
}

.client-icon {
    height: 70px;
    width: auto;
    object-fit: contain;
    filter: none;
    transition: var(--transition);
}

.client-item span {
    transition: color 0.3s;
}

.client-item:hover .client-icon {
    filter: grayscale(0%);
    box-shadow: 0 0 10px rgba(255, 69, 0, 0.5);
}

.client-item:hover span {
    color: var(--text-color);
}

@keyframes scrollMarquee {
    0% { transform: translateX(0); }
    100% { transform: translateX(-50%); }
}

/* Process Timeline */
.process-timeline {
    padding: 10rem 0;
    background: transparent;
    position: relative;
}

.timeline-container {
    position: relative;
    max-width: 1000px;
    margin: 0 auto;
    padding: 2rem 0;
}

.timeline-line {
    position: absolute;
    left: 50%;
    top: 0;
    bottom: 0;
    width: 2px;
    background: rgba(255, 255, 255, 0.1);
    transform: translateX(-50%);
}

.timeline-progress {
    position: absolute;
    left: 0;
    top: 0;
    width: 100%;
    background: var(--accent);
    height: 0%; /* Will be animated by GSAP */
    box-shadow: 0 0 10px var(--accent);
}

.timeline-step {
    position: relative;
    width: 100%;
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 6rem;
}

.timeline-step:last-child {
    margin-bottom: 0;
}

.timeline-dot {
    position: absolute;
    left: 50%;
    top: 50%;
    transform: translate(-50%, -50%);
    width: 20px;
    height: 20px;
    background: var(--bg-color);
    border: 3px solid rgba(255, 255, 255, 0.2);
    border-radius: 50%;
    z-index: 2;
    transition: var(--transition);
}

.timeline-dot.active {
    border-color: var(--accent);
    background: var(--accent);
    box-shadow: 0 0 15px rgba(255, 69, 0, 0.6);
}

.timeline-content {
    width: 45%;
    background: var(--dark-grey);
    padding: 3rem;
    border-radius: 20px;
    position: relative;
    border: 1px solid rgba(255, 255, 255, 0.05);
    transition: var(--transition);
}

.timeline-content:hover {
    border-color: rgba(255, 69, 0, 0.3);
    transform: translateY(-5px);
}

.step-left .timeline-content {
    margin-right: auto;
}

.step-right .timeline-content {
    margin-left: auto;
}

.step-number {
    font-family: var(--font-heading);
    font-size: 4rem;
    font-weight: 800;
    color: rgba(255, 255, 255, 0.05);
    position: absolute;
    top: 1rem;
    right: 2rem;
    line-height: 1;
}

.timeline-content h3 {
    font-size: 1.8rem;
    margin-bottom: 1rem;
    position: relative;
    z-index: 1;
}

.timeline-content p {
    color: var(--steel);
    font-size: 1rem;
    line-height: 1.8;
    position: relative;
    z-index: 1;
}

/* Responsive Timeline */
@media (max-width: 900px) {
    .timeline-line {
        left: 30px;
    }
    
    .timeline-dot {
        left: 30px;
    }
    
    .timeline-content {
        width: calc(100% - 80px);
        margin-left: 80px !important;
        margin-right: 0 !important;
    }
    
    .step-number {
        font-size: 3rem;
    }
}

/* Horizontal Projects */
.projects-horizontal {
    background: rgba(15, 16, 20, 0.65);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    padding: 3.5rem 0;
    overflow: hidden;
}

.horizontal-scroll-container {
    height: auto;
    padding: 1.5rem 0;
    overflow: hidden;
    position: relative;
}

.horizontal-scroll-wrapper {
    display: flex;
    flex-wrap: nowrap;
    width: max-content;
    height: auto;
    animation: scrollProjects 42s linear infinite;
    gap: 2rem;
}

.horizontal-scroll-wrapper:hover {
    animation-play-state: paused;
}

@keyframes scrollProjects {
    0% { transform: translateX(0); }
    100% { transform: translateX(-50%); }
}

/* Card Container with 3D Perspective */
.project-panel {
    width: 480px;
    flex: 0 0 480px;
    height: 380px;
    perspective: 1200px;
    background: transparent;
    border: none;
    padding: 0;
    margin: 0;
    box-shadow: none;
    cursor: default;
    border-radius: 22px;
}

.panel-flipper {
    position: relative;
    width: 100%;
    height: 100%;
    transition: transform 0.7s cubic-bezier(0.4, 0, 0.2, 1);
    transform-style: preserve-3d;
    border-radius: 22px;
}

.project-panel.is-flipped .panel-flipper {
    transform: rotateY(180deg);
}

/* Front & Back Faces */
.panel-front,
.panel-back {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    -webkit-backface-visibility: hidden;
    backface-visibility: hidden;
    border-radius: 22px;
    padding: 1.25rem;
    box-sizing: border-box;
    display: flex;
    flex-direction: column;
}

/* Front Side Styling with Orange Border */
.panel-front {
    background: rgba(22, 24, 28, 0.95);
    border: 2px solid var(--accent); /* Vibrant Orange Border! */
    box-shadow: 0 12px 30px rgba(0, 0, 0, 0.4), 0 0 22px rgba(255, 69, 0, 0.25);
    transition: box-shadow 0.4s ease, transform 0.4s ease;
    z-index: 2;
    transform: rotateY(0deg);
}

.project-panel:hover .panel-front {
    box-shadow: 0 18px 40px rgba(0, 0, 0, 0.5), 0 0 32px rgba(255, 69, 0, 0.45);
}

.panel-front .panel-img {
    width: 100%;
    height: 275px;
    background-size: cover;
    background-position: center;
    border-radius: 14px;
    margin-bottom: 0.85rem;
    position: relative;
    border: 1px solid rgba(255, 255, 255, 0.08);
    overflow: hidden;
}

/* Flip Trigger Button on Top-Right of Image */
.flip-trigger-btn {
    position: absolute;
    top: 12px;
    right: 12px;
    background: rgba(11, 12, 16, 0.88);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    border: 1.5px solid var(--accent);
    color: #ffffff;
    padding: 6px 14px;
    border-radius: 20px;
    font-size: 0.78rem;
    font-weight: 700;
    font-family: var(--font-heading);
    letter-spacing: 0.5px;
    display: flex;
    align-items: center;
    gap: 6px;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.2, 1, 0.3, 1);
    box-shadow: 0 4px 14px rgba(0, 0, 0, 0.5);
    z-index: 10;
}

.flip-trigger-btn svg {
    color: var(--accent);
    transition: transform 0.4s ease;
}

.flip-trigger-btn:hover {
    background: var(--accent);
    color: #ffffff;
    transform: scale(1.06);
    box-shadow: 0 6px 20px rgba(255, 69, 0, 0.5);
}

.flip-trigger-btn:hover svg {
    color: #ffffff;
    transform: rotate(180deg);
}

.panel-front .panel-info {
    padding: 0.25rem 0.5rem 0;
}

.panel-front .panel-info h2 {
    font-size: 1.35rem;
    font-weight: 700;
    color: #ffffff;
    margin: 0;
    font-family: var(--font-heading);
    letter-spacing: -0.01em;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

/* Back Side Styling with Orange Border */
.panel-back {
    background: linear-gradient(145deg, rgba(28, 30, 36, 0.98), rgba(16, 17, 22, 0.98));
    border: 2px solid var(--accent); /* Vibrant Orange Border! */
    box-shadow: 0 12px 30px rgba(0, 0, 0, 0.4), 0 0 22px rgba(255, 69, 0, 0.25);
    transform: rotateY(180deg);
    justify-content: space-between;
}

.panel-back-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding-bottom: 0.75rem;
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.project-tag {
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 1.2px;
    font-weight: 700;
    color: var(--accent);
    background: rgba(255, 69, 0, 0.12);
    padding: 4px 10px;
    border-radius: 12px;
    border: 1px solid rgba(255, 69, 0, 0.3);
}

.flip-back-btn {
    background: rgba(255, 255, 255, 0.08);
    border: 1px solid rgba(255, 255, 255, 0.15);
    color: #ffffff;
    padding: 5px 12px;
    border-radius: 16px;
    font-size: 0.78rem;
    font-weight: 700;
    font-family: var(--font-heading);
    display: flex;
    align-items: center;
    gap: 6px;
    cursor: pointer;
    transition: all 0.3s ease;
}

.flip-back-btn:hover {
    background: var(--accent);
    border-color: var(--accent);
    transform: scale(1.05);
}

.panel-back-body {
    padding: 1.25rem 0.5rem;
    flex-grow: 1;
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.panel-back-body h3 {
    font-size: 1.45rem;
    font-weight: 700;
    color: #ffffff;
    margin-bottom: 0.85rem;
    font-family: var(--font-heading);
}

.panel-back-body p {
    font-size: 0.98rem;
    color: rgba(255, 255, 255, 0.85);
    line-height: 1.7;
    margin: 0;
}

.panel-back-footer {
    padding-top: 0.75rem;
    border-top: 1px solid rgba(255, 255, 255, 0.08);
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.company-badge {
    font-size: 0.75rem;
    letter-spacing: 1.5px;
    font-weight: 700;
    color: var(--steel);
}

@media (max-width: 768px) {
    .projects-horizontal {
        padding: 2.5rem 0;
    }

    .horizontal-scroll-container {
        padding: 1rem 0;
    }

    .horizontal-scroll-wrapper {
        gap: 1.25rem;
        animation-duration: 35s;
    }

    .horizontal-scroll-wrapper:active {
        animation-play-state: paused;
    }

    .project-panel {
        width: 82vw;
        max-width: 340px;
        flex: 0 0 82vw;
        height: 360px;
        border-radius: 18px;
    }

    .panel-flipper {
        border-radius: 18px;
    }

    .panel-front,
    .panel-back {
        padding: 0.9rem;
        border-radius: 18px;
        -webkit-backface-visibility: hidden;
        backface-visibility: hidden;
        -webkit-transform-style: preserve-3d;
        transform-style: preserve-3d;
    }

    .panel-front .panel-img {
        height: 245px;
        border-radius: 12px;
        margin-bottom: 0.75rem;
    }

    .flip-trigger-btn {
        top: 10px;
        right: 10px;
        padding: 7px 13px;
        font-size: 0.76rem;
        touch-action: manipulation;
        -webkit-tap-highlight-color: transparent;
    }

    .panel-front .panel-info {
        padding: 0 0.25rem;
    }

    .panel-front .panel-info h2 {
        font-size: 1.15rem;
        line-height: 1.35;
        white-space: normal;
        display: -webkit-box;
        -webkit-line-clamp: 2;
        -webkit-box-orient: vertical;
        overflow: hidden;
    }

    .panel-back {
        padding: 1rem;
    }

    .panel-back-header {
        padding-bottom: 0.5rem;
    }

    .flip-back-btn {
        padding: 6px 12px;
        font-size: 0.76rem;
        touch-action: manipulation;
        -webkit-tap-highlight-color: transparent;
    }

    .panel-back-body {
        padding: 0.75rem 0.25rem;
    }

    .panel-back-body h3 {
        font-size: 1.2rem;
        margin-bottom: 0.5rem;
        line-height: 1.3;
    }

    .panel-back-body p {
        font-size: 0.88rem;
        line-height: 1.55;
        color: rgba(255, 255, 255, 0.85);
    }

    .panel-back-footer {
        padding-top: 0.5rem;
    }
}

/* Filterable Gallery */
.gallery {
    padding: 10rem 0;
    background: transparent;
}

.gallery-filters {
    display: flex;
    gap: 1rem;
    margin-bottom: 4rem;
    flex-wrap: wrap;
}

.filter-btn {
    background: transparent;
    border: 1px solid rgba(255,255,255,0.2);
    color: var(--text-color);
    padding: 0.8rem 2rem;
    border-radius: 50px;
    font-family: var(--font-heading);
    text-transform: capitalize;
    font-weight: 600;
    transition: var(--transition);
}

.filter-btn:hover, .filter-btn.active {
    background: var(--accent);
    border-color: var(--accent);
    color: var(--bg-color);
}

.gallery-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 2rem;
}

.gallery-item {
    position: relative;
    border-radius: 15px;
    height: 400px;
    perspective: 1500px;
    background: transparent;
}

.gallery-inner {
    position: relative;
    width: 100%;
    height: 100%;
    text-align: center;
    transition: transform 0.8s cubic-bezier(0.25, 1, 0.5, 1);
    transform-style: preserve-3d;
}

.gallery-item:hover .gallery-inner {
    transform: rotateY(180deg);
}

.gallery-front, .gallery-back {
    position: absolute;
    width: 100%;
    height: 100%;
    -webkit-backface-visibility: hidden;
    backface-visibility: hidden;
    border-radius: 15px;
    overflow: hidden;
}

.gallery-front {
    background-color: var(--dark-grey);
}

.gallery-back {
    background: var(--bg-color);
    border: 1px solid rgba(255, 69, 0, 0.3);
    color: var(--text-color);
    transform: rotateY(180deg);
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 2rem;
    text-align: left;
}

.gallery-img {
    width: 100%;
    height: 100%;
    background-size: cover;
    background-position: center;
    transition: transform 0.6s cubic-bezier(0.25, 1, 0.5, 1);
}

.gallery-item:hover .gallery-img {
    transform: scale(1.05);
}

.gallery-overlay {
    position: absolute;
    bottom: 0; left: 0; width: 100%;
    padding: 2rem;
    background: linear-gradient(to top, rgba(0,0,0,0.9), transparent);
}

.gallery-overlay h3 {
    font-size: 1.5rem;
    color: var(--accent);
    margin-bottom: 0;
}

.gallery-back-content {
    width: 100%;
}

.gallery-back-content h3 {
    font-family: var(--font-heading);
    font-size: 1.8rem;
    margin-bottom: 1rem;
    color: var(--accent);
}

.gallery-back-content p {
    font-family: var(--font-body);
    font-size: 1rem;
    line-height: 1.6;
    color: var(--steel);
    margin-bottom: 1.5rem;
}

.category-tag {
    display: inline-block;
    padding: 0.3rem 1rem;
    border: 1px solid var(--accent);
    border-radius: 50px;
    font-family: var(--font-heading);
    font-size: 0.8rem;
    font-weight: 700;
    text-transform: capitalize;
    color: var(--text-color);
}

/* Leadership */
.leadership {
    padding: 10rem 0;
}

.team-list {
    margin-top: 4rem;
    border-top: 1px solid rgba(255,255,255,0.1);
}

.team-row {
    display: grid;
    grid-template-columns: 2fr 1fr 1fr;
    padding: 3rem 0;
    border-bottom: 1px solid rgba(255,255,255,0.1);
    font-family: var(--font-heading);
    font-size: 1.5rem;
    transition: var(--transition);
}

.team-row:hover {
    color: var(--accent);
    padding-left: 2rem;
}

.team-exp {
    text-align: right;
    color: var(--steel);
}

/* Footer */
.footer-brutalist {
    padding: 10rem 0 2rem;
    background: rgba(26, 26, 26, 0.45);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
}

.footer-top {
    margin-bottom: 10rem;
}

.footer-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 2rem;
    border-top: 1px solid rgba(255,255,255,0.1);
    padding-top: 4rem;
}

.f-col h4 {
    color: var(--steel);
    margin-bottom: 1rem;
    font-size: 0.9rem;
}

.footer-logo {
    height: 40px;
    margin-bottom: 1rem;
}

/* Utils */
.reveal-text {
    clip-path: polygon(0 0, 100% 0, 100% 100%, 0% 100%);
}

/* Mobile & Touch Screen Optimizations */

/* Disable Custom Cursor on Touch and Mobile viewports */
@media (max-width: 1024px), (hover: none) {
    * {
        cursor: auto !important;
    }
    .cursor-dot,
    .cursor-outline {
        display: none !important;
        pointer-events: none !important;
    }
    /* Set pointer cursor back on clickable things */
    a, button, .btn, .magnet, .album-card, .modal-img-item, .modal-filter-btn, .modal-close, .fs-close, .menu-toggle {
        cursor: pointer !important;
    }
}

/* Base Mobile Layout adjustments */
@media (max-width: 992px) {
    /* Container Padding */
    .container {
        padding: 0 1.25rem !important;
    }

    /* Section Spacing */
    .md-message,
    .bento-section,
    .process-timeline,
    .gallery,
    .leadership,
    .footer-brutalist {
        padding: 4.5rem 0 !important;
    }

    /* Navbar & Logo */
    .nav-container {
        padding: 0 1.25rem !important;
    }
    .logo-text {
        font-size: 1.1rem;
    }
    .logo-img {
        height: 25px;
    }

    /* Hero section */
    .hero {
        padding-bottom: 8vh;
    }
    .hero-title {
        font-size: clamp(1.5rem, 7vw, 2.8rem) !important;
        white-space: nowrap !important;
    }
    .hero-title.indent {
        margin-left: 2vw !important;
        -webkit-text-stroke: 1.5px var(--text-color);
    }
    .section-title {
        font-size: clamp(1.2rem, 5vw, 1.8rem) !important;
    }
    .hero-subtitle {
        font-size: 1.1rem;
        line-height: 1.5;
    }
    .hero-subtitle br {
        display: none; /* Keep text flowing cleanly */
    }
    .hero-meta {
        margin-top: 2.5rem;
        flex-direction: column;
        align-items: flex-start;
        gap: 1.5rem;
        padding-top: 1.5rem;
    }

    /* Hide background floating clutter on mobile to enhance readability & performance */
    .global-background-objects,
    .floating-objects {
        display: none !important;
    }

    /* MD Message */
    .md-grid {
        grid-template-columns: 1fr;
        gap: 2.5rem;
    }
    .md-img {
        height: 320px;
    }
    .md-signature {
        margin-top: 1.5rem;
        padding-left: 1rem;
    }
    .md-quote p:first-child {
        font-size: 1.15rem;
    }
    .md-quote p {
        font-size: 0.95rem;
        margin-bottom: 1rem;
        line-height: 1.7;
    }

    /* Bento Grid */
    .bento-grid {
        grid-template-columns: 1fr !important;
        gap: 1.25rem;
        margin-top: 2.5rem;
    }
    .bento-grid > div {
        grid-column: 1 / -1 !important;
        grid-row: span 1 !important; /* Ensure they don't block height */
    }
    .bento-item {
        padding: 1.5rem !important;
        min-height: 180px;
    }
    .bento-large {
        height: 280px !important;
    }
    .bento-stats {
        min-height: 150px;
    }
    .stat-number {
        font-size: 2.8rem;
    }
    
    /* Client Partners & Marquee */
    .client-icon {
        height: 42px !important;
    }
    .marquee-content {
        gap: 1.5rem !important;
    }
    .clients-marquee {
        animation-duration: 25s; /* Slightly faster scroll since it's smaller */
    }

    /* Process Timeline */
    .process-timeline {
        padding: 4.5rem 0 !important;
    }
    .timeline-container {
        padding: 1rem 0;
    }
    .timeline-content {
        padding: 1.5rem !important;
    }
    .timeline-content h3 {
        font-size: 1.3rem;
    }
    .timeline-content p {
        font-size: 0.9rem;
        line-height: 1.6;
    }
    .step-number {
        font-size: 2.5rem;
        top: 0.5rem;
        right: 1.25rem;
    }

    /* Projects Horizontal Layout on Mobile (Fixed Full Height Cards) */
    .projects-horizontal {
        padding: 2.5rem 0;
        overflow: hidden;
    }
    .horizontal-scroll-container {
        height: auto;
        padding: 1rem 0;
        overflow: hidden;
        position: relative;
    }
    .horizontal-scroll-wrapper {
        display: flex !important;
        flex-direction: row !important;
        flex-wrap: nowrap !important;
        width: max-content !important;
        height: auto !important;
        gap: 1.25rem !important;
        animation: scrollProjects 35s linear infinite !important;
    }
    .horizontal-scroll-wrapper:active {
        animation-play-state: paused;
    }
    .project-panel {
        display: block !important;
        flex: 0 0 82vw !important;
        width: 82vw !important;
        max-width: 330px !important;
        height: 360px !important;
        padding: 0 !important;
        margin: 0 !important;
        position: relative !important;
        perspective: 1200px !important;
        border-radius: 18px !important;
    }
    .panel-flipper {
        position: relative !important;
        width: 100% !important;
        height: 100% !important;
        border-radius: 18px !important;
    }
    .panel-front,
    .panel-back {
        position: absolute !important;
        top: 0 !important;
        left: 0 !important;
        width: 100% !important;
        height: 100% !important;
        padding: 0.85rem !important;
        border-radius: 18px !important;
        display: flex !important;
        flex-direction: column !important;
        box-sizing: border-box !important;
    }
    .panel-front .panel-img {
        width: 100% !important;
        height: 245px !important;
        border-radius: 12px !important;
        margin-bottom: 0.65rem !important;
        position: relative !important;
        overflow: hidden !important;
    }
    .panel-front .panel-info {
        padding: 0 0.25rem !important;
    }
    .panel-front .panel-info h2 {
        font-size: 1.15rem !important;
        color: #ffffff !important;
        line-height: 1.35 !important;
        white-space: normal !important;
        display: -webkit-box !important;
        -webkit-line-clamp: 2 !important;
        -webkit-box-orient: vertical !important;
        overflow: hidden !important;
    }
    .panel-back {
        padding: 1rem !important;
    }
    .panel-back-header {
        padding-bottom: 0.5rem !important;
    }
    .panel-back-body {
        padding: 0.5rem 0.25rem !important;
    }
    .panel-back-body h3 {
        font-size: 1.2rem !important;
        margin-bottom: 0.4rem !important;
    }
    .panel-back-body p {
        font-size: 0.88rem !important;
        line-height: 1.55 !important;
    }
    .panel-back-footer {
        padding-top: 0.5rem !important;
    }

    /* Albums Portfolio Grid */
    .albums-grid {
        grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
        gap: 1.25rem;
    }
    .album-card {
        height: 250px !important;
    }
    .album-overlay {
        padding: 1.25rem !important;
    }
    /* Touch devices hover override: display labels clearly and fit texts within screen width */
    .album-overlay h3 {
        transform: translateY(0) !important;
        font-size: 1.3rem !important;
        line-height: 1.5 !important;
    }
    .album-overlay p {
        opacity: 1 !important;
        transform: translateY(0) !important;
        font-size: 0.8rem;
    }
    .album-img {
        filter: brightness(0.8) grayscale(10%);
    }

    /* Gallery Lightbox Modal */
    .gallery-modal {
        background: rgba(11, 12, 16, 0.99);
    }
    .modal-header {
        padding: 3.5rem 1.25rem 1rem !important;
        flex-direction: column;
        align-items: flex-start;
        gap: 1rem;
    }
    .modal-header h2 {
        font-size: 1.4rem !important;
        padding-right: 2.5rem;
        line-height: 1.3;
    }
    .modal-close {
        top: 0.75rem !important;
        right: 1.25rem !important;
        font-size: 2.2rem !important;
    }
    .modal-body {
        padding: 1.5rem 1.25rem !important;
    }
    .modal-gallery-grid {
        grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)) !important;
        gap: 1rem;
    }

    /* Fix touch browser collapsed card bugs: force block-like rendering without 3D flips */
    .modal-img-item {
        padding-bottom: 0 !important;
        height: 250px !important;
        cursor: pointer !important;
    }
    .modal-card-inner {
        position: relative !important;
        width: 100% !important;
        height: 100% !important;
        transform-style: flat !important;
        transform: none !important;
    }
    .modal-card-front {
        position: relative !important;
        width: 100% !important;
        height: 100% !important;
        transform: none !important;
        -webkit-backface-visibility: visible !important;
        backface-visibility: visible !important;
    }
    .modal-card-back {
        display: none !important; /* Touch taps image directly to view fullscreen */
    }
    
    /* Align option buttons (residential, locations etc.) vertically by group, horizontally scrollable */
    .modal-filters {
        width: 100% !important;
        display: flex !important;
        flex-direction: column !important;
        gap: 0.75rem !important;
        padding-bottom: 0.5rem;
    }
    .filter-group {
        display: flex !important;
        flex-direction: row !important;
        justify-content: flex-start !important;
        overflow-x: auto !important;
        white-space: nowrap;
        padding: 0.25rem !important;
        border-radius: 50px !important;
        width: 100% !important;
        background: rgba(255, 255, 255, 0.05) !important;
        -ms-overflow-style: none; /* Hide scrollbars */
        scrollbar-width: none;
    }
    .filter-group::-webkit-scrollbar {
        display: none;
    }
    .modal-filter-btn {
        flex: 1 0 auto !important;
        padding: 0.4rem 0.9rem !important;
        font-size: 0.75rem !important;
        border-radius: 50px !important;
    }

    /* Leadership Team Rows */
    .team-row {
        grid-template-columns: 1fr !important;
        padding: 1.5rem 0 !important;
        gap: 0.5rem;
        font-size: 1.15rem !important;
    }
    .team-row:hover {
        padding-left: 0 !important; /* Disable shift effect */
        color: var(--accent) !important;
    }
    .team-exp {
        text-align: left;
        margin-bottom: 0.5rem;
    }
    .team-desc {
        font-size: 0.85rem !important;
        line-height: 1.5 !important;
        margin-top: 0.5rem !important;
    }

    /* Brutalist Footer */
    .footer-brutalist {
        padding: 4.5rem 0 2rem !important;
    }
    .footer-top {
        margin-bottom: 2.5rem;
    }
    .huge-text {
        font-size: 1.8rem !important;
        margin-bottom: 1.5rem;
        line-height: 1.1;
    }
    .footer-grid {
        grid-template-columns: 1fr !important;
        gap: 1.5rem;
        padding-top: 2rem;
    }

    /* Navigation Overlay Menu */
    .mobile-nav-links a {
        font-size: 2.2rem !important;
    }
    .mobile-nav-links {
        gap: 1.5rem;
    }
    .nav-links {
        display: none;
    }
    .menu-toggle {
        display: flex;
    }
}

/* Small viewports extra adjustments */
@media (max-width: 480px) {
    .hero-title {
        font-size: 2.2rem !important;
    }
    .stat-number {
        font-size: 2.4rem;
    }
    .album-card {
        height: 220px !important;
    }
    .modal-gallery-grid {
        grid-template-columns: 1fr !important; /* Force single column on tiny screens */
    }
}

/* WhatsApp Float Button */
.whatsapp-float {
    position: fixed;
    width: 60px;
    height: 60px;
    bottom: 40px;
    right: 40px;
    background-color: #25d366;
    color: #FFF;
    border-radius: 50px;
    text-align: center;
    font-size: 30px;
    box-shadow: 2px 2px 3px #999;
    z-index: 1000;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: transform 0.3s cubic-bezier(0.25, 1, 0.5, 1), box-shadow 0.3s;
    text-decoration: none;
}

.whatsapp-float svg {
    width: 35px;
    height: 35px;
    fill: currentColor;
}

.whatsapp-float:hover {
    transform: scale(1.1);
    box-shadow: 2px 2px 10px rgba(37, 211, 102, 0.5);
    color: #FFF;
}

@media (max-width: 768px) {
    .whatsapp-float {
        width: 50px;
        height: 50px;
        bottom: 20px;
        right: 20px;
    }
    .whatsapp-float svg {
        width: 28px;
        height: 28px;
    }
}
/* ------------------------------- */
/* ALBUMS GALLERY & MODAL CSS */
/* ------------------------------- */

.albums-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 2rem;
    margin-top: 3rem;
}

.album-card {
    position: relative;
    border-radius: 20px;
    overflow: hidden;
    height: 400px;
    cursor: none; /* using our custom cursor */
}

.album-img {
    width: 100%;
    height: 100%;
    background-size: cover;
    background-position: center;
    transition: transform 0.6s cubic-bezier(0.25, 1, 0.5, 1), filter 0.6s;
    filter: brightness(0.7) grayscale(30%);
}

.album-card:hover .album-img {
    transform: scale(1.05);
    filter: brightness(1) grayscale(0%);
}

.album-overlay {
    position: absolute;
    bottom: 0; left: 0; width: 100%;
    padding: 2rem;
    background: linear-gradient(to top, rgba(0,0,0,0.9), transparent);
    pointer-events: none;
}

.album-overlay h3 {
    font-size: 2rem;
    line-height: 1.4;
    color: var(--text-color);
    margin-bottom: 0.5rem;
    transform: translateY(10px);
    transition: var(--transition);
}

.album-overlay p {
    color: var(--accent);
    font-family: var(--font-heading);
    font-size: 0.9rem;
    text-transform: capitalize;
    font-weight: 600;
    opacity: 0;
    transform: translateY(10px);
    transition: var(--transition);
}

.album-card:hover .album-overlay h3 {
    transform: translateY(0);
}

.album-card:hover .album-overlay p {
    opacity: 1;
    transform: translateY(0);
}

/* Gallery Modal (Lightbox) */
.gallery-modal {
    position: fixed;
    top: 0; left: 0; width: 100%; height: 100%;
    background: rgba(11, 12, 16, 0.98);
    backdrop-filter: blur(15px);
    z-index: 2000;
    display: flex;
    flex-direction: column;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.4s ease;
}

.gallery-modal.active {
    opacity: 1;
    pointer-events: all;
}

.modal-close, .fs-close {
    position: absolute;
    top: 2rem; right: 3rem;
    font-size: 3rem;
    color: var(--text-color);
    cursor: none;
    z-index: 2001;
    line-height: 1;
    transition: color 0.3s;
}

.modal-close:hover, .fs-close:hover {
    color: var(--accent);
}

.modal-header {
    padding: 3rem 5vw 1rem;
    border-bottom: 1px solid rgba(255,255,255,0.1);
    display: flex;
    flex-wrap: wrap;
    justify-content: space-between;
    align-items: flex-end;
    gap: 2rem;
}

.modal-header h2 {
    font-size: clamp(2rem, 4vw, 4rem);
    margin: 0;
    color: var(--text-color);
}

.modal-filters {
    display: flex;
    gap: 1.2rem;
    flex-wrap: wrap;
    align-items: center;
}

.modal-search-wrapper {
    position: relative;
    display: flex;
    align-items: center;
    min-width: 220px;
    flex: 1;
    max-width: 320px;
}

.modal-search-input {
    width: 100%;
    padding: 0.6rem 1rem 0.6rem 2.4rem;
    background: rgba(255, 255, 255, 0.06);
    border: 1px solid rgba(255, 255, 255, 0.15);
    border-radius: 50px;
    color: #fff;
    font-family: var(--font-body);
    font-size: 0.88rem;
    outline: none;
    transition: var(--transition);
}

.modal-search-input:focus {
    border-color: var(--accent);
    background: rgba(0, 0, 0, 0.7);
    box-shadow: 0 0 0 3px rgba(255, 69, 0, 0.2);
}

.modal-search-input::placeholder {
    color: var(--steel);
}

.modal-search-icon {
    position: absolute;
    left: 0.85rem;
    color: var(--steel);
    pointer-events: none;
    display: flex;
    align-items: center;
}

.filter-group {
    display: flex;
    gap: 0.5rem;
    background: rgba(255,255,255,0.05);
    padding: 0.3rem;
    border-radius: 50px;
}

.modal-filter-btn {
    background: transparent;
    border: none;
    color: var(--steel);
    padding: 0.5rem 1.2rem;
    border-radius: 50px;
    font-family: var(--font-heading);
    font-weight: 600;
    font-size: 0.85rem;
    text-transform: capitalize;
    transition: var(--transition);
    cursor: none;
}

.modal-filter-btn.active, .modal-filter-btn:hover {
    background: var(--accent);
    color: var(--bg-color);
}

.modal-body {
    flex: 1;
    overflow-y: auto;
    padding: 3rem 5vw;
}

.modal-gallery-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
    gap: 1.5rem;
}

.modal-img-item {
    position: relative;
    padding-bottom: 100%; /* 1:1 Aspect ratio */
    cursor: none;
    perspective: 1000px;
}

.modal-card-inner {
    position: absolute;
    top: 0; left: 0; width: 100%; height: 100%;
    transition: transform 0.6s cubic-bezier(0.25, 1, 0.5, 1);
    transform-style: preserve-3d;
}

.modal-img-item:hover .modal-card-inner {
    transform: rotateY(180deg);
}

.modal-card-front, .modal-card-back {
    position: absolute;
    width: 100%; height: 100%;
    -webkit-backface-visibility: hidden;
    backface-visibility: hidden;
    border-radius: 15px;
    overflow: hidden;
}

.modal-card-front img {
    width: 100%; height: 100%;
    object-fit: cover;
    transition: transform 0.4s ease;
}

.modal-card-front:hover img {
    transform: scale(1.05);
}

.modal-card-back {
    background: var(--dark-grey);
    transform: rotateY(180deg);
    padding: 1.5rem;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    text-align: center;
    border: 1px solid rgba(255,255,255,0.1);
}

.modal-card-back h3 {
    font-size: 1.3rem;
    color: var(--accent);
    margin-bottom: 0.5rem;
}

.modal-card-back p {
    font-size: 0.9rem;
    color: var(--steel);
    line-height: 1.5;
}

/* Fullscreen Viewer */
.fullscreen-viewer {
    position: fixed;
    top: 0; left: 0; width: 100%; height: 100%;
    background: rgba(0,0,0,0.95);
    z-index: 3000;
    display: flex;
    justify-content: center;
    align-items: center;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.3s ease;
}

.fullscreen-viewer.active {
    opacity: 1;
    pointer-events: all;
}

.fullscreen-viewer img {
    max-width: 90vw;
    max-height: 90vh;
    object-fit: contain;
    border-radius: 5px;
    box-shadow: 0 0 50px rgba(0,0,0,0.5);
    transform: scale(0.95);
    transition: transform 0.3s ease;
}

.fullscreen-viewer.active img {
    transform: scale(1);
}

/* Disable custom magnetic cursor on touch devices to avoid trailing artifacts */
@media (hover: none) and (pointer: coarse) {
    .cursor-dot,
    .cursor-outline {
        display: none !important;
        opacity: 0 !important;
        visibility: hidden !important;
    }
    * {
        cursor: auto !important;
    }
    .magnet, .btn, .album-card, .modal-img-item, a {
        cursor: pointer !important;
    }
}

/* Mobile Responsive Optimization for Gallery Lightbox Modal */
@media (max-width: 768px) {
    .modal-close, .fs-close {
        top: 1rem;
        right: 1.2rem;
        font-size: 2.4rem;
    }
    .modal-header {
        padding: 3.5rem 1.2rem 1rem;
        gap: 1rem;
        flex-direction: column;
        align-items: flex-start;
    }
    .modal-header h2 {
        font-size: 1.6rem;
    }
    .modal-filters {
        width: 100%;
        flex-direction: column;
        align-items: stretch;
        gap: 0.75rem;
    }
    .modal-search-wrapper {
        width: 100%;
        max-width: 100%;
        min-width: 0;
    }
    .filter-group {
        width: 100%;
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
        padding: 0.25rem;
        display: flex;
        flex-wrap: nowrap;
    }
    .modal-filter-btn {
        padding: 0.4rem 0.9rem;
        font-size: 0.78rem;
        white-space: nowrap;
        flex-shrink: 0;
    }
    .modal-body {
        padding: 1.2rem;
    }
    .modal-gallery-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 0.75rem;
    }
    .modal-card-back {
        padding: 0.8rem;
    }
    .modal-card-back h3 {
        font-size: 0.95rem;
        margin-bottom: 0.25rem;
    }
    .modal-card-back p {
        font-size: 0.75rem;
        line-height: 1.3;
    }
    .modal-card-back .btn {
        margin-top: 0.75rem !important;
        padding: 0.35rem 0.7rem !important;
        font-size: 0.72rem !important;
    }
}

@media (max-width: 420px) {
    .modal-header h2 {
        font-size: 1.35rem;
    }
    .modal-gallery-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 0.5rem;
    }
}

