:root {
    --color-primary-dark: #0A001A; /* Midnight Black */
    --color-secondary-dark: #1A0033; /* Deep Purple */
    --color-accent-magenta: #FF00FF; /* Neon Magenta */
    --color-accent-cyan: #00FFFF; /* Neon Cyan */
    --color-accent-blue: #0077FF; /* Electric Blue */
    --font-heading: 'Orbitron', sans-serif;
    --font-body: 'Exo', sans-serif;
    --border-glow: 0 0 8px var(--color-accent-magenta), 0 0 15px var(--color-accent-blue);
    --text-glow: 0 0 5px var(--color-accent-cyan);
    --section-padding: 80px 4%;
    --card-spacing: 20px;
    --header-height: 70px; /* Fixed header height */
}

/* Base Styles & Typography */
html {
    scroll-behavior: smooth;
}

body {
    margin: 0;
    font-family: var(--font-body);
    color: #E0E0E0;
    background-color: var(--color-primary-dark);
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
    text-rendering: optimizeLegibility;
    overflow-x: hidden;
}

h1, h2, h3, h4, h5, h6 {
    font-family: var(--font-heading);
    color: var(--color-accent-blue);
    margin-top: 0;
    line-height: 1.2;
    text-shadow: var(--text-glow);
}

h1 { font-size: 3.5em; text-transform: uppercase; }
h2 { font-size: 2.5em; text-transform: uppercase; color: var(--color-accent-magenta); }
h3 { font-size: 1.8em; color: var(--color-accent-cyan); }
p { margin-bottom: 1em; }

a {
    color: var(--color-accent-cyan);
    text-decoration: none;
    transition: color 0.3s ease, text-shadow 0.3s ease;
}

a:hover {
    color: var(--color-accent-magenta);
    text-shadow: 0 0 8px var(--color-accent-magenta);
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

.card {
    background-color: var(--color-secondary-dark);
    padding: 30px;
    border-radius: 8px;
    box-shadow: 0 0 15px rgba(0, 255, 255, 0.2), 0 0 30px rgba(255, 0, 255, 0.1);
    border: 1px solid rgba(0, 255, 255, 0.3);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.card:hover {
    transform: translateY(-5px);
    box-shadow: var(--border-glow);
}

.section-title {
    text-align: center;
    margin-bottom: 20px;
    padding-bottom: 10px;
    position: relative;
}

.section-title::after {
    content: '';
    display: block;
    width: 80px;
    height: 3px;
    background: linear-gradient(to right, var(--color-accent-cyan), var(--color-accent-magenta));
    margin: 10px auto 0;
    box-shadow: var(--border-glow);
}

.section-description {
    text-align: center;
    max-width: 800px;
    margin: 0 auto 50px auto;
    color: #B0B0B0;
    font-size: 1.1em;
}

.button {
    display: inline-block;
    padding: 12px 25px;
    border-radius: 5px;
    font-family: var(--font-heading);
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 1px;
    transition: all 0.3s ease;
    cursor: pointer;
    text-align: center;
    position: relative;
    overflow: hidden;
}

.button::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 0;
    height: 0;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 50%;
    transform: translate(-50%, -50%);
    transition: width 0.4s ease, height 0.4s ease;
    z-index: 0;
}

.button:hover::before {
    width: 300%;
    height: 300%;
}

.primary-button {
    background: linear-gradient(90deg, var(--color-accent-cyan) 0%, var(--color-accent-blue) 100%);
    color: var(--color-primary-dark);
    border: none;
    box-shadow: 0 0 15px rgba(0, 255, 255, 0.4);
}

.primary-button:hover {
    background: linear-gradient(90deg, var(--color-accent-blue) 0%, var(--color-accent-magenta) 100%);
    color: #FFF;
    box-shadow: var(--border-glow);
}

.secondary-button {
    background: none;
    border: 2px solid var(--color-accent-magenta);
    color: var(--color-accent-magenta);
    box-shadow: 0 0 10px rgba(255, 0, 255, 0.3);
}

.secondary-button:hover {
    background-color: var(--color-accent-magenta);
    color: var(--color-primary-dark);
    box-shadow: var(--border-glow);
}

.large-button {
    padding: 15px 35px;
    font-size: 1.1em;
}

.neon-line {
    position: relative;
    display: inline-block;
}
.neon-line::after {
    content: '';
    position: absolute;
    left: 0;
    bottom: -5px;
    width: 100%;
    height: 2px;
    background: linear-gradient(to right, var(--color-accent-cyan), var(--color-accent-magenta));
    box-shadow: 0 0 8px var(--color-accent-cyan), 0 0 15px var(--color-accent-magenta);
    transform: scaleX(0);
    transform-origin: bottom left;
    transition: transform 0.4s ease;
}
h3:hover .neon-line::after {
    transform: scaleX(1);
}


/* Header */
.main-header {
    background-color: rgba(10, 0, 26, 0.8); /* Semi-transparent midnight black */
    backdrop-filter: blur(10px);
    position: sticky;
    top: 0;
    left: 0;
    width: 100%;
    z-index: 1000;
    box-shadow: 0 2px 20px rgba(0, 255, 255, 0.2);
    height: var(--header-height);
    display: flex;
    align-items: center;
    border-bottom: 1px solid rgba(0, 255, 255, 0.1);
}

.header-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    width: 100%;
}

.logo {
    font-family: var(--font-heading);
    font-size: 1.8em;
    font-weight: 700;
    color: var(--color-accent-magenta);
    text-shadow: var(--text-glow);
    transition: transform 0.3s ease;
}

.logo:hover {
    transform: scale(1.05);
}

.main-nav ul {
    list-style: none;
    margin: 0;
    padding: 0;
    display: flex;
}

.main-nav li {
    margin-left: 30px;
}

.main-nav a {
    color: #E0E0E0;
    font-family: var(--font-body);
    font-weight: 500;
    position: relative;
    padding: 5px 0;
}

.main-nav a::after {
    content: '';
    position: absolute;
    left: 0;
    bottom: 0;
    width: 100%;
    height: 2px;
    background: linear-gradient(to right, var(--color-accent-cyan), var(--color-accent-magenta));
    transform: scaleX(0);
    transform-origin: bottom right;
    transition: transform 0.3s ease-out;
}

.main-nav a:hover::after,
.main-nav a.active::after {
    transform: scaleX(1);
    transform-origin: bottom left;
}

.menu-toggle {
    display: none; /* Hidden on desktop */
    background: none;
    border: none;
    cursor: pointer;
    padding: 10px;
    position: relative;
    z-index: 1001;
}

.menu-toggle span {
    display: block;
    width: 30px;
    height: 3px;
    background-color: var(--color-accent-cyan);
    margin: 6px 0;
    transition: all 0.3s ease;
    box-shadow: 0 0 5px var(--color-accent-cyan);
}

.menu-toggle.active span:nth-child(1) {
    transform: rotate(-45deg) translate(-6px, 6px);
}

.menu-toggle.active span:nth-child(2) {
    opacity: 1;
}

.menu-toggle.active span:nth-child(3) {
    transform: rotate(45deg) translate(-6px, -6px);
}


/* Sections */
section {
    padding: var(--section-padding);
    position: relative;
    overflow: hidden;
}

/* Hero Section */
.hero-section {
    position: relative;
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: left;
    overflow: hidden;
    padding-top: var(--header-height); /* Ensure content is below fixed header */
}

.hero-background img {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    z-index: 1;
    filter: brightness(0.4) contrast(1.2); /* Darken and enhance contrast */
}

.hero-grid-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    display: grid;
    grid-template-columns: 1fr 1fr; /* Two columns for background and content */
    gap: 0;
    z-index: 2;
    padding: var(--section-padding);
    box-sizing: border-box; /* Include padding in dimensions */
}

.hero-grid-overlay::before { /* Asymmetrical glowing grid */
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background:
        repeating-linear-gradient(0deg, rgba(0,255,255,0.05) 0, rgba(0,255,255,0.05) 1px, transparent 1px, transparent 100px),
        repeating-linear-gradient(90deg, rgba(0,255,255,0.05) 0, rgba(0,255,255,0.05) 1px, transparent 1px, transparent 100px);
    opacity: 1;.3;
    animation: grid-pulse 10s infinite alternate;
    z-index: 0;
}

@keyframes grid-pulse {
    0% { opacity: 1;.2; transform: scale(1); }
    100% { opacity: 1;.4; transform: scale(1.02); }
}

.hero-content {
    grid-column: 1 / 2; /* Content in the first column */
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: flex-start;
    position: relative;
    z-index: 3;
    padding-right: 50px; /* Offset from the right edge of its grid cell */
    max-width: 600px;
}

.hero-content h1 {
    font-size: 4.5em; /* Larger for impact */
    margin-bottom: 20px;
    font-weight: 700;
    animation: neon-flicker 1.5s infinite alternate;
}

.glitch-text {
    position: relative;
}

.glitch-text::before,
.glitch-text::after {
    content: attr(data-text);
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
}

.glitch-text::before {
    left: 2px;
    text-shadow: -2px 0 var(--color-accent-magenta);
    animation: glitch-left 1.5s infinite alternate-reverse;
}

.glitch-text::after {
    left: -2px;
    text-shadow: -2px 0 var(--color-accent-cyan);
    animation: glitch-right 1.5s infinite alternate-reverse;
}

@keyframes glitch-left {
    0% { transform: translate(0); }
    20% { transform: translate(-5px, 0); }
    40% { transform: translate(5px, 0); }
    60% { transform: translate(-5px, 0); }
    80% { transform: translate(5px, 0); }
    100% { transform: translate(0); }
}

@keyframes glitch-right {
    0% { transform: translate(0); }
    20% { transform: translate(5px, 0); }
    40% { transform: translate(-5px, 0); }
    60% { transform: translate(5px, 0); }
    80% { transform: translate(-5px, 0); }
    100% { transform: translate(0); }
}

.hero-content p {
    font-size: 1.2em;
    margin-bottom: 30px;
    color: #C0C0C0;
    max-width: 90%;
}

.hero-actions {
    display: flex;
    gap: 20px;
    flex-wrap: wrap;
}

/* Story Section - Timeline Layout */
.story-section {
    background-color: var(--color-primary-dark);
    padding: var(--section-padding);
}

.timeline {
    position: relative;
    max-width: 1000px;
    margin: 0 auto;
    padding: 40px 0;
}

.timeline::before {
    content: '';
    position: absolute;
    width: 4px;
    background: linear-gradient(to bottom, var(--color-accent-cyan), var(--color-accent-magenta));
    top: 0;
    bottom: 0;
    left: 50%;
    margin-left: -2px;
    box-shadow: var(--border-glow);
}

.timeline-item {
    padding: 10px 0;
    position: relative;
    width: 50%;
}

.timeline-item.left {
    left: 0;
}

.timeline-item.right {
    left: 50%;
}

.timeline-item::after {
    content: '';
    position: absolute;
    width: 15px;
    height: 15px;
    border-radius: 50%;
    right: -7px;
    background-color: var(--color-accent-blue);
    border: 3px solid var(--color-secondary-dark);
    top: 50%;
    transform: translateY(-50%);
    box-shadow: 0 0 10px var(--color-accent-blue);
    z-index: 1;
}

.timeline-item.right::after {
    left: -8px;
}

.timeline-content {
    padding: 20px 30px;
    position: relative;
    border-radius: 8px;
    border: 1px solid rgba(0, 255, 255, 0.3);
    background-color: var(--color-secondary-dark);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.timeline-content:hover {
    transform: translateY(-5px);
    box-shadow: var(--border-glow);
}

.timeline-item.left .timeline-content {
    margin-right: 45px;
    text-align: right;
}

.timeline-item.right .timeline-content {
    margin-left: 45px;
    text-align: left;
}

.timeline-content h3 {
    margin-bottom: 10px;
    color: var(--color-accent-cyan);
}
.timeline-content ul {
    list-style: none;
    padding: 0;
    margin-top: 10px;
    color: #C0C0C0;
}
.timeline-content ul li {
    margin-bottom: 5px;
    position: relative;
}
.timeline-content ul li::before {
    content: '→ ';
    color: var(--color-accent-magenta);
    margin-right: 5px;
    text-shadow: 0 0 5px var(--color-accent-magenta);
}

/* Products Section - Feature Highlights */
.products-section {
    background-color: var(--color-secondary-dark);
    padding: var(--section-padding);
}

.feature-highlights {
    display: flex;
    flex-direction: column;
    gap: 80px;
}

.feature-block {
    display: flex;
    align-items: center;
    gap: 50px;
    padding: 30px;
    border-radius: 10px;
    box-shadow: 0 0 20px rgba(255, 0, 255, 0.1), 0 0 40px rgba(0, 255, 255, 0.05);
    background-color: var(--color-primary-dark);
    border: 1px solid rgba(255, 0, 255, 0.2);
    transition: transform 0.4s ease, box-shadow 0.4s ease;
}

.feature-block:hover {
    transform: translateY(-10px);
    box-shadow: var(--border-glow);
}

.feature-block:nth-child(odd) { /* Alternating layout: text left, image right */
    flex-direction: row;
}

.feature-block:nth-child(even) { /* Alternating layout: image left, text right */
    flex-direction: row-reverse;
}

.feature-text {
    flex: 1;
    padding: 0; /* Card has its own padding */
    background-color: var(--color-secondary-dark); /* Card overrides */
    box-shadow: none; /* Card overrides */
    border: none;
    transform: none;
}
.feature-text:hover {
    transform: none; /* Override card hover */
    box-shadow: none; /* Override card hover */
}


.feature-image {
    flex: 1;
    min-width: 300px; /* Ensure image isn't too small */
}

.feature-image img {
    width: 100%;
    height: auto;
    border-radius: 8px;
    border: 2px solid var(--color-accent-blue);
    box-shadow: 0 0 15px rgba(0, 119, 255, 0.5), 0 0 30px rgba(0, 255, 255, 0.2);
    object-fit: cover;
    max-height: 400px;
}

.feature-text h3 {
    margin-bottom: 15px;
    color: var(--color-accent-cyan);
}

.feature-text p {
    margin-bottom: 15px;
    color: #D0D0D0;
}
.feature-text ul {
    list-style: none;
    padding: 0;
    margin-top: 15px;
    color: #C0C0C0;
}
.feature-text ul li {
    margin-bottom: 8px;
    position: relative;
    padding-left: 25px;
}
.feature-text ul li::before {
    content: '⚡'; /* Use text char instead of icon */
    color: var(--color-accent-magenta);
    position: absolute;
    left: 0;
    top: 0;
    text-shadow: 0 0 5px var(--color-accent-magenta);
}

/* Features Section - Visual Showcase */
.features-section {
    background-color: var(--color-primary-dark);
    padding: var(--section-padding);
}

.features-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); /* Responsive 3-card layout */
    gap: var(--card-spacing);
}

.feature-card {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    padding: 30px;
}

.feature-icon-placeholder {
    width: 80px;
    height: 80px;
    margin-bottom: 20px;
    border-radius: 50%;
    background: linear-gradient(45deg, var(--color-accent-cyan), var(--color-accent-magenta));
    display: flex;
    justify-content: center;
    align-items: center;
    box-shadow: 0 0 15px rgba(0, 255, 255, 0.5);
    overflow: hidden;
}
.feature-icon-placeholder img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: 50%;
    filter: brightness(0.7); /* Subtle filter to make them look like concept icons */
}


.feature-card h3 {
    margin-bottom: 15px;
    color: var(--color-accent-cyan);
}

.feature-card p {
    font-size: 0.95em;
    color: #D0D0D0;
    margin-bottom: 15px;
}
.feature-card ul {
    list-style: none;
    padding: 0;
    text-align: left;
    width: 100%;
    color: #C0C0C0;
}
.feature-card ul li {
    margin-bottom: 5px;
    padding-left: 20px;
    position: relative;
}
.feature-card ul li::before {
    content: '✓'; /* Plain text checkmark */
    color: var(--color-accent-blue);
    position: absolute;
    left: 0;
    top: 0;
    text-shadow: 0 0 5px var(--color-accent-blue);
}

/* Showcase Section - Featured Work */
.showcase-section {
    background-color: var(--color-secondary-dark);
    padding: var(--section-padding);
}

.featured-work-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr); /* Exactly 3 cards per row */
    gap: var(--card-spacing);
}

.work-item {
    text-align: center;
    position: relative;
    padding: 0; /* Card overrides */
    overflow: hidden;
    cursor: pointer;
    border-radius: 8px;
}
.work-item:hover {
    transform: translateY(-5px);
    box-shadow: var(--border-glow);
}

.work-item img {
    width: 100%;
    height: 280px;
    object-fit: cover;
    border-radius: 8px 8px 0 0;
    transition: transform 0.4s ease;
}

.work-item:hover img {
    transform: scale(1.05);
}

.work-item h3 {
    margin-top: 20px;
    margin-bottom: 10px;
    color: var(--color-accent-cyan);
    padding: 0 20px;
}

.work-item p {
    font-size: 0.95em;
    color: #D0D0D0;
    padding: 0 20px;
    margin-bottom: 15px;
}
.work-item ul {
    list-style: none;
    padding: 0 20px 20px;
    margin-top: 0;
    text-align: left;
    color: #C0C0C0;
}
.work-item ul li {
    margin-bottom: 5px;
    position: relative;
    padding-left: 20px;
}
.work-item ul li::before {
    content: '›'; /* Plain text indicator */
    color: var(--color-accent-magenta);
    position: absolute;
    left: 0;
    top: 0;
    text-shadow: 0 0 5px var(--color-accent-magenta);
}

/* Team Section - Circular Photos */
.team-section {
    background-color: var(--color-primary-dark);
    padding: var(--section-padding);
}

.team-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr); /* Exactly 3 cards per row */
    gap: var(--card-spacing);
    text-align: center;
}

.team-member {
    display: flex;
    flex-direction: column;
    align-items: center;
}

.team-member img {
    width: 180px;
    height: 180px;
    border-radius: 50%;
    object-fit: cover;
    margin-bottom: 20px;
    border: 4px solid var(--color-accent-blue);
    box-shadow: 0 0 15px rgba(0, 119, 255, 0.6), 0 0 25px rgba(0, 255, 255, 0.3);
    transition: border-color 0.3s ease, box-shadow 0.3s ease;
}

.team-member:hover img {
    border-color: var(--color-accent-magenta);
    box-shadow: 0 0 15px rgba(255, 0, 255, 0.6), 0 0 25px rgba(0, 255, 255, 0.3);
}

.team-member h3 {
    margin-bottom: 5px;
    color: var(--color-accent-cyan);
}

.team-member .role {
    color: var(--color-accent-magenta);
    font-weight: 500;
    margin-bottom: 15px;
    text-shadow: 0 0 5px rgba(255, 0, 255, 0.5);
}

.team-member .bio {
    font-size: 0.95em;
    color: #D0D0D0;
}

/* Reviews Section - Social Proof */
.reviews-section {
    background-color: var(--color-secondary-dark);
    padding: var(--section-padding);
}

.reviews-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr); /* Exactly 3 cards per row */
    gap: var(--card-spacing);
}

.review-card {
    display: flex;
    flex-direction: column;
    padding: 25px;
}

.reviewer-info {
    display: flex;
    align-items: center;
    margin-bottom: 20px;
}

.reviewer-info img {
    width: 60px;
    height: 60px;
    border-radius: 50%;
    object-fit: cover;
    margin-right: 15px;
    border: 2px solid var(--color-accent-cyan);
    box-shadow: 0 0 10px rgba(0, 255, 255, 0.5);
}

.reviewer-info .details h4 {
    margin: 0;
    color: var(--color-accent-cyan);
    font-size: 1.2em;
}

.reviewer-info .details p {
    margin: 0;
    font-size: 0.9em;
    color: #A0A0A0;
}

.review-text {
    font-style: italic;
    margin-bottom: 15px;
    color: #E0E0E0;
    position: relative;
    padding-left: 20px;
}
.review-text::before {
    content: '“'; /* Plain text quotation mark */
    font-size: 2em;
    color: var(--color-accent-magenta);
    position: absolute;
    left: 0;
    top: 0;
    line-height: 1;
    text-shadow: 0 0 5px var(--color-accent-magenta);
}

.review-date {
    font-size: 0.8em;
    color: #707070;
    text-align: right;
    display: block;
}

/* Location Section - Social Focus (Reinterpreted as Strategic Presence) */
.location-section {
    background-color: var(--color-primary-dark);
    padding: var(--section-padding);
    text-align: center;
}

.presence-info {
    max-width: 800px;
    margin: 40px auto 0;
    padding: 40px;
}

.presence-info h3 {
    margin-bottom: 20px;
    color: var(--color-accent-cyan);
}

.presence-info p {
    font-size: 1.1em;
    margin-bottom: 25px;
    color: #D0D0D0;
}

.stat-highlights {
    display: flex;
    justify-content: center;
    gap: 40px;
    margin-top: 30px;
    flex-wrap: wrap;
}

.stat-item {
    flex: 0 0 auto;
    text-align: center;
    min-width: 120px;
}

.stat-item span {
    display: block;
    font-family: var(--font-heading);
    font-size: 2.5em;
    font-weight: 700;
    color: var(--color-accent-magenta);
    text-shadow: var(--text-glow);
    margin-bottom: 5px;
}

.stat-item p {
    font-size: 0.95em;
    color: #C0C0C0;
    margin: 0;
}

/* Portfolio/Gallery - Interactive Showcase */
.portfolio-section {
    background-color: var(--color-secondary-dark);
    padding: var(--section-padding);
}

.tab-group {
    margin-top: 40px;
}

.tab-buttons {
    display: flex;
    justify-content: center;
    margin-bottom: 40px;
    flex-wrap: wrap;
    gap: 15px;
}

.tab-button {
    background: var(--color-secondary-dark);
    color: var(--color-accent-cyan);
    border: 1px solid var(--color-accent-blue);
    padding: 10px 20px;
    border-radius: 5px;
    cursor: pointer;
    font-family: var(--font-heading);
    font-size: 1em;
    transition: all 0.3s ease;
    box-shadow: 0 0 10px rgba(0, 119, 255, 0.2);
}

.tab-button:hover {
    background-color: var(--color-accent-blue);
    color: var(--color-primary-dark);
    box-shadow: var(--border-glow);
}

.tab-button.active {
    background: linear-gradient(90deg, var(--color-accent-blue) 0%, var(--color-accent-magenta) 100%);
    color: var(--color-primary-dark);
    border-color: var(--color-accent-magenta);
    box-shadow: var(--border-glow);
}

.tab-pane {
    display: none;
    animation: fadeIn 0.5s ease-out forwards;
}

.tab-pane.active {
    display: block;
}

@keyframes fadeIn {
    from { opacity: 1; transform: translateY(20px); }
    to { opacity: 1; transform: translateY(0); }
}

.portfolio-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr); /* Exactly 3 cards per row */
    gap: var(--card-spacing);
}

.portfolio-item {
    position: relative;
    overflow: hidden;
    border-radius: 8px;
    padding: 0;
    cursor: pointer;
}

.portfolio-item img {
    width: 100%;
    height: 250px;
    object-fit: cover;
    display: block;
    transition: transform 0.4s ease;
}

.portfolio-item .overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(26, 0, 51, 0.85); /* Deep purple overlay */
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    text-align: center;
    padding: 20px;
    opacity: 1;
    transition: opacity 0.4s ease;
    border-radius: 8px;
    border: 2px solid var(--color-accent-magenta);
    box-shadow: var(--border-glow);
}

.portfolio-item:hover .overlay {
    opacity: 1;
}

.portfolio-item:hover img {
    transform: scale(1.1);
    filter: brightness(0.5);
}

.portfolio-item .overlay h3 {
    margin-top: 0;
    color: var(--color-accent-cyan);
    text-shadow: 0 0 8px var(--color-accent-cyan);
    font-size: 1.4em;
    margin-bottom: 10px;
}

.portfolio-item .overlay p {
    color: #E0E0E0;
    font-size: 0.9em;
    margin-bottom: 0;
}

/* Call to Action Section */
.call-to-action-section {
    background-color: var(--color-primary-dark);
    padding: var(--section-padding);
    text-align: center;
}

.call-to-action-section .section-title {
    color: var(--color-accent-blue);
    text-shadow: var(--text-glow);
}

.call-to-action-section .section-description {
    max-width: 900px;
}

.call-to-action-section .button {
    margin: 10px;
}

/* Footer */
.main-footer {
    background-color: var(--color-secondary-dark);
    color: #A0A0A0;
    padding: 60px 0;
    border-top: 1px solid rgba(0, 255, 255, 0.1);
    box-shadow: 0 -2px 20px rgba(0, 255, 255, 0.2);
}

.footer-content {
    display: flex;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 30px;
}

.footer-brand, .footer-nav, .footer-info {
    flex: 1;
    min-width: 250px;
}

.footer-brand h3 {
    font-size: 1.8em;
    color: var(--color-accent-magenta);
    text-shadow: var(--text-glow);
    margin-bottom: 15px;
}

.footer-brand p {
    font-size: 0.95em;
    line-height: 1.6;
}

.footer-nav h4, .footer-info h4 {
    color: var(--color-accent-cyan);
    font-size: 1.2em;
    margin-bottom: 20px;
    text-shadow: 0 0 5px rgba(0, 255, 255, 0.3);
}

.footer-nav ul {
    list-style: none;
    padding: 0;
    margin: 0;
}

.footer-nav li {
    margin-bottom: 10px;
}

.footer-nav a {
    color: #C0C0C0;
    transition: color 0.3s ease;
}

.footer-nav a:hover {
    color: var(--color-accent-magenta);
    text-shadow: var(--text-glow);
}

.footer-info p {
    font-size: 0.95em;
    margin-bottom: 10px;
}

/* Responsive Design */
@media (max-width: 992px) {
    h1 { font-size: 3em; }
    h2 { font-size: 2em; }
    h3 { font-size: 1.5em; }

    .main-nav {
        display: none; /* Hide main nav by default on smaller screens */
        flex-direction: column;
        background-color: var(--color-secondary-dark);
        position: absolute;
        top: var(--header-height);
        right: 0;
        width: 100%;
        box-shadow: 0 5px 15px rgba(0, 255, 255, 0.3);
        border-top: 1px solid var(--color-accent-cyan);
        padding-bottom: 20px;
        opacity: 1;
        visibility: hidden;
        transform: translateY(-20px);
        transition: opacity 0.3s ease, visibility 0.3s ease, transform 0.3s ease;
    }

    .main-nav.active {
        display: flex;
        opacity: 1;
        visibility: visible;
        transform: translateY(0);
    }

    .main-nav ul {
        flex-direction: column;
        padding: 20px;
    }

    .main-nav li {
        margin: 10px 0;
        text-align: center;
    }

    .menu-toggle {
        display: block; /* Show hamburger icon */
    }

    .hero-content {
        grid-column: 1 / -1; /* Content spans full width */
        text-align: center;
        align-items: center;
        padding-right: 0;
    }

    .hero-content h1 {
        font-size: 3.5em;
    }

    .hero-actions {
        justify-content: center;
    }

    .timeline::before {
        left: 20px; /* Move timeline line to left */
    }

    .timeline-item {
        width: 100%;
        left: 0;
        padding-left: 50px; /* Space for the line and dot */
    }

    .timeline-item::after {
        left: 13px; /* Align dot to the left line */
        right: auto;
    }

    .timeline-item.left .timeline-content,
    .timeline-item.right .timeline-content {
        margin: 0;
        text-align: left;
    }

    .feature-block,
    .feature-block:nth-child(odd),
    .feature-block:nth-child(even) {
        flex-direction: column;
        gap: 30px;
    }

    .feature-image {
        order: -1; /* Image always on top for mobile */
    }
    .feature-image img {
        max-height: 300px;
    }

    .featured-work-grid,
    .team-grid,
    .reviews-grid,
    .portfolio-grid {
        grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); /* Allow wrapping to 1 column */
    }

    .footer-content {
        flex-direction: column;
        text-align: center;
    }
    .footer-nav ul {
        align-items: center;
    }
}

@media (max-width: 600px) {
    h1 { font-size: 2.5em; }
    h2 { font-size: 1.8em; }
    h3 { font-size: 1.3em; }

    .section-padding { padding: 60px 20px; }

    .hero-content h1 {
        font-size: 2.8em;
    }

    .hero-content p {
        font-size: 1em;
    }

    .hero-actions {
        flex-direction: column;
        gap: 15px;
    }

    .button {
        width: 100%;
    }

    .stat-highlights {
        flex-direction: column;
        gap: 20px;
    }

    .featured-work-grid,
    .team-grid,
    .reviews-grid,
    .portfolio-grid,
    .features-grid {
        grid-template-columns: 1fr; /* Single column layout */
    }

    .tab-buttons {
        flex-direction: column;
        align-items: center;
    }

    .tab-button {
        width: 80%;
    }
}

/* Visible state helpers */
+ .animate-fade-in-up.visible,
+ .animate-fade-in-left.visible,
+ .animate-fade-in-right.visible,
+ .animate-bounce-y.visible,
+ .section-scroll-animate.visible,
+ .text-animate-up.visible {
    opacity: 1;
    transform: translateY(0);
}

/* Universal Icon Fixes for Buttons */
button svg, .carousel-next svg, .carousel-prev svg, .slider-next svg, .slider-prev svg,
.next svg, .prev svg, .tab-button svg, .tab-btn svg {
    display: inline-block;
    vertical-align: middle;
    pointer-events: none;
    width: 1em;
    height: 1em;
    fill: currentColor;
}

button i, .carousel-next i, .carousel-prev i, .slider-next i, .slider-prev i,
.next i, .prev i, .tab-button i, .tab-btn i {
    display: inline-block;
    vertical-align: middle;
    pointer-events: none;
    font-style: normal;
}

button .icon, .carousel-next .icon, .carousel-prev .icon,
.slider-next .icon, .slider-prev .icon, .tab-button .icon {
    display: inline-block;
    vertical-align: middle;
    pointer-events: none;
}

/* Ensure carousel buttons are clickable even with icons */
.carousel-next, .carousel-prev, .slider-next, .slider-prev,
.next, .prev, .next-btn, .prev-btn {
    cursor: pointer;
    position: relative;
}

.carousel-next *, .carousel-prev *, .slider-next *, .slider-prev *,
.next *, .prev *, .next-btn *, .prev-btn * {
    pointer-events: none;
}

/* Tab button icon fixes */
.tab-button, .tab-btn, .tab {
    cursor: pointer;
    position: relative;
}

.tab-button *, .tab-btn *, .tab * {
    pointer-events: none;
}

/* Ensure icons don't block clicks */
button > svg, button > i, button > .icon,
.carousel-next > svg, .carousel-prev > svg,
.tab-button > svg, .tab-button > i {
    pointer-events: none !important;
}

/* Enhanced: Team grid stabilization */
+ .team-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px; }
+ @media (max-width: 900px) { .team-grid { grid-template-columns: repeat(2, 1fr); } }
+ @media (max-width: 600px) { .team-grid { grid-template-columns: 1fr; } }

/* Safe visibility overrides (auto-added) */
:root, html, body, main, header, footer, section, .container, .content {
  opacity: 1 !important;
  visibility: visible !important;
}

/* Accessibility focus outlines */
:focus{outline:2px solid #5ac8fa;outline-offset:2px;}
:focus:not(:focus-visible){outline:none;}
