:root {
    /* Futuristic Tech Palette (Dark) */
    --bg-main: #050505;
    --bg-secondary: #0a0a0a;
    --bg-tertiary: #121212;
    --text-main: #f8fafc;
    --text-muted: #8b949e;

    --primary: #00f0ff;
    --primary-glow: rgba(0, 240, 255, 0.5);
    --secondary: #6366f1;
    --accent: #f43f5e;
    --success: #3fb950;

    --border: rgba(255, 255, 255, 0.08);
    --border-hover: rgba(255, 255, 255, 0.15);

    --font-heading: 'Space Grotesk', sans-serif;
    --font-body: 'Inter', sans-serif;

    --transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    --header-height: 80px;
    --top-bar-height: 40px;
}

/* Light Theme Variables */
body.light-theme {
    --bg-main: #f8fafc;
    --bg-secondary: #ffffff;
    --bg-tertiary: #f1f5f9;
    --text-main: #0f172a;
    --text-muted: #64748b;
    --primary: #0ea5e9;
    --primary-glow: rgba(14, 165, 233, 0.2);
    --secondary: #4f46e5;
    --border: rgba(15, 23, 42, 0.1);
    --border-hover: rgba(15, 23, 42, 0.2);
}

body {
    background-color: var(--bg-main);
    transition: background-color 0.5s ease, color 0.5s ease;
}


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

html {
    scroll-behavior: smooth;
}

body {
    font-family: var(--font-body);
    color: var(--text-main);
    line-height: 1.6;
    overflow-x: hidden;
    -webkit-font-smoothing: antialiased;
}

/* Typography */
h1,
h2,
h3,
h4,
h5,
h6,
.logo {
    font-family: var(--font-heading);
    font-weight: 700;
    line-height: 1.1;
    letter-spacing: -0.02em;
}

.section-title span {
    background: linear-gradient(135deg, var(--primary), var(--secondary));
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
}

/* Utilities */
.container {
    max-width: 1280px;
    margin: 0 auto;
    padding: 0 24px;
}

.reveal {
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 0.8s ease, transform 0.8s cubic-bezier(0.16, 1, 0.3, 1);
}

.reveal.active {
    opacity: 1;
    transform: translateY(0);
}

/* Buttons */
.btn {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    padding: 14px 28px;
    border-radius: 8px;
    font-weight: 600;
    text-decoration: none;
    transition: var(--transition);
    cursor: pointer;
    border: none;
    font-family: var(--font-heading);
    text-transform: uppercase;
    letter-spacing: 0.05em;
    font-size: 0.9rem;
    position: relative;
    overflow: hidden;
    z-index: 1;
}

.btn-glow {
    background: transparent;
    color: var(--primary);
    border: 1px solid var(--primary);
    box-shadow: 0 0 15px rgba(0, 240, 255, 0.1), inset 0 0 10px rgba(0, 240, 255, 0.1);
}

.btn-glow::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 0;
    height: 100%;
    background: rgba(0, 240, 255, 0.1);
    z-index: -1;
    transition: var(--transition);
}

.btn-glow:hover {
    box-shadow: 0 0 25px rgba(0, 240, 255, 0.3), inset 0 0 15px rgba(0, 240, 255, 0.2);
    text-shadow: 0 0 8px rgba(0, 240, 255, 0.5);
}

.btn-glow:hover::before {
    width: 100%;
}

.btn-large {
    padding: 18px 40px;
    font-size: 1rem;
}

.badge {
    display: inline-block;
    padding: 6px 14px;
    background: rgba(0, 240, 255, 0.1);
    border: 1px solid rgba(0, 240, 255, 0.2);
    color: var(--primary);
    border-radius: 20px;
    font-size: 0.8rem;
    font-weight: 600;
    letter-spacing: 1px;
    text-transform: uppercase;
    margin-bottom: 20px;
    backdrop-filter: blur(4px);
}

.badge-alert {
    background: rgba(244, 63, 94, 0.1);
    border-color: rgba(244, 63, 94, 0.2);
    color: var(--accent);
}

/* Header & Nav */
header {
    position: fixed;
    top: 0;
    width: 100%;
    padding: 24px 0;
    z-index: 1000;
    transition: var(--transition);
}

header.scrolled {
    background: var(--bg-main);
    opacity: 0.95;
    backdrop-filter: blur(12px);
    padding: 16px 0;
    border-bottom: 1px solid var(--border);
}

.nav-container {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo {
    font-size: 1.5rem;
    color: var(--text-main);
    text-decoration: none;
    display: flex;
    align-items: center;
    gap: 12px;
}

.logo span {
    color: var(--primary);
}

/* 3D Logo Cube */
.logo-cube {
    width: 24px;
    height: 24px;
    position: relative;
    transform-style: preserve-3d;
    animation: rotateCube 10s infinite linear;
}

.logo-cube .face {
    position: absolute;
    width: 24px;
    height: 24px;
    border: 2px solid var(--primary);
    background: rgba(0, 240, 255, 0.1);
}

.logo-cube .front {
    transform: translateZ(12px);
}

.logo-cube .back {
    transform: rotateY(180deg) translateZ(12px);
}

.logo-cube .right {
    transform: rotateY(90deg) translateZ(12px);
}

.logo-cube .left {
    transform: rotateY(-90deg) translateZ(12px);
}

.logo-cube .top {
    transform: rotateX(90deg) translateZ(12px);
}

.logo-cube .bottom {
    transform: rotateX(-90deg) translateZ(12px);
}

@keyframes rotateCube {
    0% {
        transform: rotateX(0deg) rotateY(0deg);
    }

    100% {
        transform: rotateX(360deg) rotateY(360deg);
    }
}

.nav-links {
    display: flex;
    gap: 32px;
    list-style: none;
    align-items: center;
}

.nav-links a:not(.btn-nav) {
    color: var(--text-muted);
    text-decoration: none;
    font-size: 0.95rem;
    font-weight: 500;
    transition: var(--transition);
}

.nav-links a:not(.btn-nav):hover,
.nav-links a:not(.btn-nav).active {
    color: #fff;
    text-shadow: 0 0 10px rgba(255, 255, 255, 0.3);
}

.btn-nav {
    background: #fff;
    color: #000;
    padding: 8px 16px;
    border-radius: 4px;
    text-decoration: none;
    font-weight: 600;
    font-size: 0.9rem;
    transition: var(--transition);
}

.btn-nav:hover {
    background: var(--primary);
    box-shadow: 0 0 15px var(--primary-glow);
}

/* Mobile Toggle Hamburger */
.mobile-toggle {
    display: none;
    background: transparent;
    border: none;
    cursor: pointer;
    flex-direction: column;
    gap: 6px;
    z-index: 1001;
}

.mobile-toggle span {
    display: block;
    width: 28px;
    height: 2px;
    background: var(--text-main);
    transition: 0.3s;
}

.mobile-toggle.active span:nth-child(1) {
    transform: translateY(8px) rotate(45deg);
}

.mobile-toggle.active span:nth-child(2) {
    opacity: 0;
}

.mobile-toggle.active span:nth-child(3) {
    transform: translateY(-8px) rotate(-45deg);
}

/* Hero Section */
.hero {
    min-height: 100vh;
    display: flex;
    align-items: center;
    position: relative;
    padding-top: 80px;
}

#hero-canvas {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -1;
}

.hero-content {
    max-width: 800px;
    z-index: 2;
    position: relative;
}

.hero-content h1 {
    font-size: clamp(3rem, 6vw, 5rem);
    margin-bottom: 24px;
    color: var(--text-main);
}

/* Glitch Effect on Hover/Load */
.glitch {
    position: relative;
}

.glitch::before,
.glitch::after {
    content: attr(data-text);
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    opacity: 0.8;
}

.glitch::before {
    color: var(--primary);
    z-index: -1;
    animation: glitch-anim 3s infinite linear alternate-reverse;
}

.glitch::after {
    color: var(--secondary);
    z-index: -2;
    animation: glitch-anim-2 2s infinite linear alternate-reverse;
}

@keyframes glitch-anim {
    0% {
        clip-path: inset(20% 0 80% 0);
        transform: translate(-2px, 1px);
    }

    20% {
        clip-path: inset(60% 0 10% 0);
        transform: translate(2px, -1px);
    }

    40% {
        clip-path: inset(40% 0 50% 0);
        transform: translate(-2px, 2px);
    }

    60% {
        clip-path: inset(80% 0 5% 0);
        transform: translate(2px, -2px);
    }

    80% {
        clip-path: inset(10% 0 70% 0);
        transform: translate(-1px, 1px);
    }

    100% {
        clip-path: inset(30% 0 50% 0);
        transform: translate(1px, -1px);
    }
}

@keyframes glitch-anim-2 {
    0% {
        clip-path: inset(10% 0 60% 0);
        transform: translate(2px, 1px);
    }

    20% {
        clip-path: inset(80% 0 5% 0);
        transform: translate(-2px, 2px);
    }

    40% {
        clip-path: inset(30% 0 20% 0);
        transform: translate(2px, -1px);
    }

    60% {
        clip-path: inset(50% 0 30% 0);
        transform: translate(-1px, 2px);
    }

    80% {
        clip-path: inset(5% 0 80% 0);
        transform: translate(2px, -2px);
    }

    100% {
        clip-path: inset(40% 0 40% 0);
        transform: translate(-2px, 1px);
    }
}

.hero-content p {
    font-size: 1.15rem;
    color: var(--text-muted);
    margin-bottom: 40px;
    max-width: 600px;
}

.hero-cta {
    display: flex;
    align-items: center;
    gap: 32px;
    flex-wrap: wrap;
}

.tech-stack {
    display: flex;
    gap: 16px;
    align-items: center;
    font-size: 1.5rem;
    color: var(--text-muted);
    padding-left: 24px;
    border-left: 1px solid var(--border);
}

@media (max-width: 600px) {
    .tech-stack {
        border-left: none;
        padding-left: 0;
        justify-content: center;
        width: 100%;
    }
}

.tech-stack i {
    transition: var(--transition);
}

.tech-stack i:hover {
    color: #fff;
    transform: translateY(-3px);
    filter: drop-shadow(0 0 5px rgba(255, 255, 255, 0.5));
}

.scroll-indicator {
    position: absolute;
    bottom: 40px;
    left: 50%;
    transform: translateX(-50%);
}

.mouse {
    display: block;
    width: 26px;
    height: 42px;
    border: 2px solid var(--text-muted);
    border-radius: 14px;
    position: relative;
}

.wheel {
    display: block;
    width: 4px;
    height: 6px;
    background: var(--primary);
    border-radius: 2px;
    position: absolute;
    top: 6px;
    left: 50%;
    transform: translateX(-50%);
    animation: scrollMouse 1.5s infinite;
}

@keyframes scrollMouse {
    0% {
        top: 6px;
        opacity: 1;
    }

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

/* Stats Section */
.stats-section {
    padding: 80px 0;
    background: var(--bg-secondary);
    border-top: 1px solid var(--border);
    border-bottom: 1px solid var(--border);
}

.stats-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 40px;
    text-align: center;
}

.stat-number {
    font-family: var(--font-heading);
    font-size: 3.5rem;
    font-weight: 700;
    color: #fff;
    text-shadow: 0 0 20px rgba(255, 255, 255, 0.1);
    margin-bottom: 8px;
}

.stat-label {
    color: var(--primary);
    font-size: 1.1rem;
    font-weight: 600;
    letter-spacing: 1px;
    text-transform: uppercase;
    margin-bottom: 8px;
}

.stat-desc {
    color: var(--text-muted);
    font-size: 0.9rem;
}

/* Services */
.services {
    padding: 120px 0;
}

.section-header {
    margin-bottom: 64px;
    max-width: 600px;
}

.section-title {
    font-size: clamp(2rem, 4vw, 3rem);
    margin-bottom: 16px;
}

/* ── Carousel ─────────────────────────────────────── */
.carousel-wrapper {
    display: flex;
    align-items: center;
    gap: 16px;
    position: relative;
}

.carousel-viewport {
    overflow: hidden;
    flex: 1;
    border-radius: 16px;
}

.carousel-track {
    display: flex;
    transition: transform 0.5s cubic-bezier(0.4, 0, 0.2, 1);
    will-change: transform;
}

.carousel-slide {
    flex: 0 0 100%;
    padding: 4px;
    /* room for card border-glow */
    box-sizing: border-box;
}

/* On desktop show 3 cards at once */
@media (min-width: 900px) {
    .carousel-slide {
        flex: 0 0 33.333%;
    }
}

/* On tablet show 2 cards */
@media (min-width: 600px) and (max-width: 899px) {
    .carousel-slide {
        flex: 0 0 50%;
    }
}

/* Make cards fill the slide height */
.carousel-slide .glass-card {
    height: 100%;
}

/* Nav Buttons */
.carousel-btn {
    flex-shrink: 0;
    width: 48px;
    height: 48px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.04);
    border: 1px solid var(--border);
    color: var(--text-muted);
    font-size: 1rem;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: var(--transition);
    backdrop-filter: blur(8px);
}

.carousel-btn:hover {
    background: rgba(0, 240, 255, 0.1);
    border-color: var(--primary);
    color: var(--primary);
    box-shadow: 0 0 16px rgba(0, 240, 255, 0.2);
}

.carousel-btn:disabled {
    opacity: 0.25;
    cursor: not-allowed;
    pointer-events: none;
}

/* Dot Indicators */
.carousel-dots {
    display: flex;
    justify-content: center;
    gap: 8px;
    margin-top: 28px;
}

.carousel-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: var(--border);
    border: 1px solid rgba(255, 255, 255, 0.15);
    cursor: pointer;
    transition: var(--transition);
    padding: 0;
}

.carousel-dot.active {
    background: var(--primary);
    box-shadow: 0 0 10px var(--primary-glow);
    width: 24px;
    border-radius: 4px;
}

/* Tech Tags (IaC card) */
.tech-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-top: 20px;
}

.tech-tag {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 5px 12px;
    border-radius: 6px;
    font-size: 0.8rem;
    font-weight: 600;
    font-family: var(--font-heading);
    background: rgba(0, 240, 255, 0.08);
    border: 1px solid rgba(0, 240, 255, 0.25);
    color: var(--primary);
    letter-spacing: 0.03em;
    transition: var(--transition);
}

.tech-tag:hover {
    background: rgba(0, 240, 255, 0.15);
    box-shadow: 0 0 10px rgba(0, 240, 255, 0.2);
}

.tech-tag--dim {
    background: rgba(255, 255, 255, 0.04);
    border-color: var(--border);
    color: var(--text-muted);
}

/* Glass Card with Mouse Tracking Effect */
.glass-card {
    background: rgba(255, 255, 255, 0.02);
    border: 1px solid var(--border);
    border-radius: 16px;
    position: relative;
    overflow: hidden;
    backdrop-filter: blur(10px);
}

.glass-card::before {
    content: "";
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    border-radius: inherit;
    padding: 1px;
    background: linear-gradient(135deg, rgba(255, 255, 255, 0.1) 0%, rgba(255, 255, 255, 0) 100%);
    -webkit-mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
    -webkit-mask-composite: xor;
    mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
    mask-composite: exclude;
    pointer-events: none;
}

.card-glow {
    position: absolute;
    width: 300px;
    height: 300px;
    background: radial-gradient(circle, var(--primary-glow) 0%, transparent 70%);
    border-radius: 50%;
    pointer-events: none;
    opacity: 0;
    transition: opacity 0.3s ease;
    transform: translate(-50%, -50%);
    z-index: 0;
}

.glass-card:hover .card-glow {
    opacity: 0.15;
}

.service-card .card-content {
    position: relative;
    z-index: 1;
    padding: 40px;
    height: 100%;
}

.service-card .icon-wrapper {
    width: 56px;
    height: 56px;
    background: rgba(0, 240, 255, 0.05);
    border: 1px solid rgba(0, 240, 255, 0.1);
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    color: var(--primary);
    margin-bottom: 24px;
    transition: var(--transition);
}

.service-card:hover .icon-wrapper {
    background: var(--primary);
    color: #000;
    box-shadow: 0 0 20px var(--primary-glow);
    transform: scale(1.05);
}

.service-card h3 {
    font-size: 1.3rem;
    margin-bottom: 12px;
    color: #fff;
}

.service-card p {
    color: var(--text-muted);
    font-size: 0.95rem;
}

/* Security Section (Terminal Mockup) */
.security {
    padding: 120px 0;
    background: var(--bg-tertiary);
    position: relative;
    overflow: hidden;
}

.security-bg-grid {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-image:
        linear-gradient(rgba(255, 255, 255, 0.03) 1px, transparent 1px),
        linear-gradient(90deg, rgba(255, 255, 255, 0.03) 1px, transparent 1px);
    background-size: 40px 40px;
    z-index: 1;
    opacity: 0.5;
    perspective: 1000px;
    transform: rotateX(60deg) scale(2);
    transform-origin: top center;
}

/* ── Details Sections (Generic) ──────────────────── */
.details-section {
    padding: 120px 0;
    position: relative;
    overflow: hidden;
}

.details-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 80px;
    align-items: center;
}

.details-grid.reverse {
    direction: rtl;
}

.details-grid.reverse>* {
    direction: ltr;
    /* Reset text direction inside */
}

@media (max-width: 900px) {

    .details-grid,
    .details-grid.reverse {
        grid-template-columns: 1fr;
        gap: 40px;
    }
}

.glass-mockup {
    position: relative;
    background: rgba(13, 17, 23, 0.4);
    backdrop-filter: blur(10px);
    border: 1px solid var(--border);
    border-radius: 20px;
    overflow: hidden;
    box-shadow: 0 40px 100px rgba(0, 0, 0, 0.5), 0 0 40px rgba(0, 240, 255, 0.05);
}

.glass-mockup img {
    display: block;
    width: 100%;
    height: auto;
    filter: brightness(0.9) contrast(1.1);
}

.glass-mockup::after {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(135deg, rgba(255, 255, 255, 0.05) 0%, transparent 100%);
    pointer-events: none;
}

/* ── Security (Reusing Grid) ───────────────────────── */
.security {
    padding: 120px 0;
    position: relative;
    background: var(--bg-primary);
}

.security-wrapper {
    position: relative;
    z-index: 2;
}

.feature-list {
    list-style: none;
    margin-top: 32px;
}

.feature-list li {
    display: flex;
    gap: 20px;
    margin-bottom: 24px;
}

.feature-icon {
    width: 48px;
    height: 48px;
    flex-shrink: 0;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid var(--border);
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--accent);
    font-size: 1.2rem;
}

.feature-list strong {
    display: block;
    font-size: 1.1rem;
    color: #fff;
    margin-bottom: 4px;
}

.feature-list span {
    color: var(--text-muted);
    font-size: 0.9rem;
}

.terminal-mockup {
    background: #0d1117;
    border-radius: 12px;
    border: 1px solid #30363d;
    overflow: hidden;
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.5), 0 0 40px rgba(0, 240, 255, 0.1);
}

.terminal-header {
    background: #161b22;
    padding: 12px 16px;
    display: flex;
    align-items: center;
    border-bottom: 1px solid #30363d;
}

.dot {
    display: inline-block;
    width: 12px;
    height: 12px;
    border-radius: 50%;
    margin-right: 8px;
}

.dot.red {
    background: #ff5f56;
}

.dot.yellow {
    background: #ffbd2e;
}

.dot.green {
    background: #27c93f;
}

.terminal-header .title {
    margin-left: auto;
    margin-right: auto;
    color: var(--text-muted);
    font-size: 0.85rem;
    font-family: monospace;
}

.terminal-body {
    padding: 24px;
    font-family: 'JetBrains Mono', 'Courier New', Courier, monospace;
    font-size: 0.9rem;
    color: var(--success);
    min-height: 250px;
    line-height: 1.5;
}

.cursor {
    display: inline-block;
    width: 8px;
    height: 15px;
    background: var(--success);
    animation: blink 1s infinite;
    vertical-align: middle;
}

@keyframes blink {

    0%,
    100% {
        opacity: 1;
    }

    50% {
        opacity: 0;
    }
}

/* Contact */
.contact {
    padding: 120px 0;
}

.contact-box {
    padding: 80px 40px;
    text-align: center;
    background: linear-gradient(135deg, rgba(30, 41, 59, 0.3), rgba(15, 23, 42, 0.5));
}

.contact-box h2 {
    font-size: clamp(2rem, 4vw, 3rem);
    margin-bottom: 16px;
    color: #fff;
}

.contact-box p {
    color: var(--text-muted);
    font-size: 1.1rem;
    max-width: 600px;
    margin: 0 auto 40px;
}

/* Footer */
footer {
    background: #000;
    border-top: 1px solid var(--border);
    padding: 80px 0 24px;
}

.footer-grid {
    display: grid;
    grid-template-columns: 2fr 1fr 1fr;
    gap: 40px;
    margin-bottom: 60px;
}

.footer-brand p {
    color: var(--text-muted);
    margin-top: 16px;
    max-width: 300px;
}

.footer-links h4,
.footer-social h4 {
    color: #fff;
    margin-bottom: 20px;
    font-size: 1.1rem;
}

.footer-links ul {
    list-style: none;
}

.footer-links li {
    margin-bottom: 12px;
    color: var(--text-muted);
}

.social-icons {
    display: flex;
    gap: 16px;
}

.social-icons a {
    width: 40px;
    height: 40px;
    background: rgba(255, 255, 255, 0.05);
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #fff;
    text-decoration: none;
    transition: var(--transition);
    border: 1px solid var(--border);
}

.social-icons a:hover {
    background: var(--primary);
    color: #000;
    transform: translateY(-3px);
    border-color: var(--primary);
    box-shadow: 0 5px 15px var(--primary-glow);
}

.footer-bottom {
    text-align: center;
    padding-top: 24px;
    border-top: 1px solid var(--border);
    color: var(--text-muted);
    font-size: 0.85rem;
}

/* Responsive */
@media (max-width: 992px) {
    .stats-grid {
        grid-template-columns: 1fr;
        gap: 24px;
    }

    .security-wrapper {
        grid-template-columns: 1fr;
        gap: 40px;
    }

    .footer-grid {
        grid-template-columns: 1fr 1fr;
    }
}

@media (max-width: 768px) {
    .nav-links {
        position: fixed;
        top: 0;
        right: -100%;
        width: 100%;
        height: 100vh;
        background: rgba(5, 5, 5, 0.98);
        backdrop-filter: blur(20px);
        flex-direction: column;
        justify-content: center;
        transition: var(--transition);
    }

    .nav-links.active {
        right: 0;
    }

    .mobile-toggle {
        display: flex;
    }

    .footer-grid {
        grid-template-columns: 1fr;
    }

    .terminal-body {
        font-size: 0.8rem;
    }
}

/* ── Top Bar & Switcher ──────────────────────────── */
.top-bar {
    height: var(--top-bar-height);
    background: rgba(0, 0, 0, 0.4);
    border-bottom: 1px solid var(--border);
    display: flex;
    align-items: center;
    font-size: 0.85rem;
    color: var(--text-muted);
    position: sticky;
    top: 0;
    z-index: 1001;
    backdrop-filter: blur(10px);
}

body.light-theme .top-bar {
    background: rgba(15, 23, 42, 0.05);
}

header {
    top: var(--top-bar-height);
}

.top-bar-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    width: 100%;
}

.top-bar-info {
    display: flex;
    gap: 20px;
}

.top-bar-info a {
    color: inherit;
    text-decoration: none;
    display: flex;
    align-items: center;
    gap: 8px;
    transition: var(--transition);
}

.top-bar-info a:hover {
    color: var(--primary);
}

.top-bar-actions {
    display: flex;
    gap: 15px;
    align-items: center;
}

.lang-switcher {
    display: flex;
    align-items: center;
    gap: 0;
}

.switcher-btn {
    background: transparent;
    border: none;
    color: inherit;
    cursor: pointer;
    font-size: 0.8rem;
    padding: 2px 4px;
    transition: var(--transition);
    font-weight: 500;
}

.switcher-btn:hover {
    color: var(--primary);
}

.switcher-btn.active {
    color: var(--primary);
    font-weight: 700;
}

.switcher-sep {
    opacity: 0.3;
    font-size: 0.7rem;
    margin: 0 4px;
    user-select: none;
}

/* ── Language Toggles ───────────────────────────── */
[data-lang="pt"] .lang-en {
    display: none !important;
}

[data-lang="en"] .lang-pt {
    display: none !important;
}

@media (max-width: 768px) {
    .top-bar-info span:not(.phone-visible) {
        display: none;
    }

    .top-bar {
        font-size: 0.75rem;
    }
}