/* ==================================================
   PROJETOS PAGE - Korx Solutions Portfolio
   ================================================== */

:root {
    --primary-blue: #2A6EA7;
    --secondary-blue: #57D4CA;
    --neon-blue: #00D4FF;
    --neon-red: #FF0055;
    --dark-bg: #05070a;
    --glass-bg: rgba(255, 255, 255, 0.03);
    --glass-border: rgba(255, 255, 255, 0.08);
    --glass-stroke: rgba(255, 255, 255, 0.08);
}

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

body {
    font-family: 'Inter', sans-serif;
    background: var(--dark-bg);
    color: #fff;
    overflow-x: hidden;
    position: relative;
    min-height: 100vh;
}

/* ========== COSMIC BACKGROUND ========== */
/* Base importado de /shared/cosmic-bg.css */

/* Particles (local) */
.particles {
    position: absolute;
    width: 100%;
    height: 100%;
    overflow: hidden;
}

.particle {
    position: absolute;
    width: 2px;
    height: 2px;
    background: var(--neon-blue);
    border-radius: 50%;
    animation: float 20s infinite linear;
    opacity: 0.5;
}

@keyframes float {
    from { transform: translateY(100vh) translateX(0); }
    to { transform: translateY(-100px) translateX(100px); }
}

/* ========== SCROLL PROGRESS ========== */
#scroll-progress {
    position: fixed;
    top: 0;
    left: 0;
    width: 0%;
    height: 2px;
    background: linear-gradient(90deg, #00D4FF, #00FF88);
    z-index: var(--z-loading, 10000);
    transition: width 0.1s ease;
}

/* ========== NAVBAR ========== */
.navbar {
    position: fixed;
    top: 20px;
    left: 50%;
    transform: translateX(-50%);
    width: 90%;
    max-width: 1200px;
    padding: 20px 40px;
    background: rgba(10, 14, 26, 0.6);
    backdrop-filter: blur(15px);
    -webkit-backdrop-filter: blur(15px);
    border: 1px solid var(--glass-stroke);
    border-radius: 50px;
    z-index: var(--z-modal, 1000);
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.37);
    transition: all 0.3s ease;
}

.navbar-container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 20px;
    flex-wrap: wrap;
}

.navbar-left {
    display: flex;
    align-items: center;
    gap: 15px;
}

.page-name {
    font: 600 1.1rem 'Orbitron', monospace;
    color: rgba(255, 255, 255, 0.6);
    letter-spacing: 1px;
    text-transform: uppercase;
    padding-left: 15px;
    border-left: 1px solid rgba(255, 255, 255, 0.2);
}

.navbar-right {
    display: flex;
    gap: 15px;
    align-items: center;
}

.logo-section {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 5px;
}

.logo {
    font: 900 1.5rem 'Orbitron', monospace;
    background: linear-gradient(135deg, #00D4FF, #0077FF);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    letter-spacing: 2px;
    margin: 0;
    text-align: center;
}

.logo-subtitle {
    font-size: 0.7rem;
    font-family: 'Inter', sans-serif;
    font-weight: 500;
    color: rgba(0, 212, 255, 0.7);
    letter-spacing: 3px;
    text-transform: uppercase;
    text-align: center;
}

.btn-nav {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    padding: 0.5rem 1rem;
    height: 36px;
    background: transparent;
    color: #e0e0e0;
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 25px;
    font-size: 0.9rem;
    line-height: 1;
    cursor: pointer;
    transition: all 0.3s;
    text-decoration: none;
    font-family: 'Inter', sans-serif;
    white-space: nowrap;
    box-sizing: border-box;
}

.btn-nav i {
    font-size: 0.9rem;
    width: 1rem;
    text-align: center;
    line-height: 1;
}

.btn-nav:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 15px rgba(0, 212, 255, 0.3);
    border-color: #00D4FF;
}

.btn-orcamento {
    background: linear-gradient(135deg, #00D4FF, #0077FF);
    color: white !important;
    border: 1px solid #00D4FF;
}

.btn-orcamento:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 30px rgba(0, 212, 255, 0.5);
}

/* ========== HERO PROJETOS ========== */
.hero-projetos {
    padding: 180px 20px 80px;
    text-align: center;
    max-width: 800px;
    margin: 0 auto;
}

.breadcrumb {
    margin-bottom: 30px;
}

.breadcrumb ol {
    display: flex;
    justify-content: center;
    gap: 10px;
    list-style: none;
    font-size: 0.9rem;
}

.breadcrumb li {
    color: #94a3b8;
}

.breadcrumb li::after {
    content: '/';
    margin-left: 10px;
    color: rgba(148, 163, 184, 0.5);
}

.breadcrumb li:last-child::after {
    display: none;
}

.breadcrumb a {
    color: #00D4FF;
    text-decoration: none;
    transition: color 0.3s;
}

.breadcrumb a:hover {
    color: #00FF88;
}

.page-title {
    font-family: 'Orbitron', sans-serif;
    font-size: 3rem;
    font-weight: 800;
    background: linear-gradient(135deg, #fff, #00D4FF);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    margin-bottom: 20px;
}

.page-subtitle {
    color: #94a3b8;
    font-size: 1.1rem;
    line-height: 1.6;
    max-width: 600px;
    margin: 0 auto;
}

/* ========== FILTER SECTION ========== */
.filter-section {
    padding: 140px 20px 40px;
    max-width: 1200px;
    margin: 0 auto;
}

.filter-scroll-wrapper {
    width: 100%;
}

.filter-container {
    display: flex;
    justify-content: center;
    gap: 10px;
    flex-wrap: wrap;
}

.filter-btn {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 12px 20px;
    background: var(--glass-bg);
    border: 1px solid var(--glass-stroke);
    border-radius: 50px;
    color: #94a3b8;
    font-size: 0.9rem;
    font-family: 'Inter', sans-serif;
    cursor: pointer;
    transition: all 0.3s ease;
}

.filter-btn:hover {
    background: rgba(0, 212, 255, 0.1);
    border-color: rgba(0, 212, 255, 0.3);
    color: #00D4FF;
}

.filter-btn.active {
    background: linear-gradient(135deg, rgba(0, 212, 255, 0.2), rgba(0, 119, 255, 0.2));
    border-color: #00D4FF;
    color: #00D4FF;
    box-shadow: 0 0 20px rgba(0, 212, 255, 0.3);
}

.filter-btn i {
    font-size: 0.85rem;
}

/* ========== PROJETOS SECTION ========== */
.projetos-section {
    padding: 0 20px 80px;
    max-width: 1400px;
    margin: 0 auto;
}

.projetos-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 30px;
}

/* ========== PROJECT CARD ========== */
.projeto-card {
    background: rgba(15, 23, 42, 0.8);
    border-radius: 16px;
    overflow: hidden;
    border: 1px solid rgba(0, 212, 255, 0.1);
    transition: all 0.4s ease;
    cursor: pointer;
}

.projeto-card:hover {
    transform: translateY(-10px);
    border-color: rgba(0, 212, 255, 0.4);
    box-shadow: 0 20px 40px rgba(0, 212, 255, 0.15);
}

.projeto-card:hover .projeto-image img {
    transform: scale(1.1);
    filter: brightness(1.1);
}

.projeto-overlay {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    padding: 10px 15px;
    background: linear-gradient(transparent 0%, rgba(0, 0, 0, 0.7) 100%);
    pointer-events: none;
}

/* Overlay de hover */
.projeto-hover-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(10, 14, 26, 0.92);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 25px;
    opacity: 0;
    transition: opacity 0.3s ease;
    z-index: var(--z-raised, 2);
    gap: 15px;
}

.projeto-card:hover .projeto-hover-overlay {
    opacity: 1;
}

.projeto-hover-desc {
    color: #d0d0d0;
    font-size: 0.9rem;
    line-height: 1.6;
    text-align: center;
    margin: 0;
}

.projeto-hover-cta {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    color: #00D4FF;
    font-size: 0.85rem;
    font-weight: 500;
    padding: 10px 18px;
    border: 1px solid rgba(0, 212, 255, 0.4);
    border-radius: 25px;
    background: rgba(0, 212, 255, 0.1);
    transition: all 0.3s ease;
}

.projeto-card:hover .projeto-hover-cta {
    animation: pulse-cta 2s infinite;
}

@keyframes pulse-cta {
    0%, 100% { box-shadow: 0 0 0 0 rgba(0, 212, 255, 0.4); }
    50% { box-shadow: 0 0 20px 5px rgba(0, 212, 255, 0.2); }
}

.projeto-category {
    display: inline-block;
    padding: 5px 12px;
    background: rgba(0, 212, 255, 0.2);
    border: 1px solid #00D4FF;
    border-radius: 20px;
    font-size: 0.8rem;
    color: #00D4FF;
    font-weight: 500;
}

.projeto-logo-overlay {
    position: absolute;
    top: 15px;
    right: 15px;
    width: 50px;
    height: 50px;
    background: rgba(255, 255, 255, 0.95);
    border-radius: 8px;
    padding: 5px;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.3);
    transition: all 0.3s ease;
    z-index: var(--z-raised, 3);
}

.projeto-card:hover .projeto-logo-overlay {
    transform: scale(1.1);
    box-shadow: 0 6px 20px rgba(0, 212, 255, 0.4);
}

.projeto-logo-img {
    max-width: 100%;
    max-height: 100%;
    object-fit: contain;
}

.projeto-info {
    padding: 20px;
}

.projeto-info h3 {
    font-family: 'Orbitron', sans-serif;
    font-size: 1.1rem;
    color: #fff;
    margin-bottom: 12px;
}

.projeto-specs {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
}

.spec-badge {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    padding: 5px 12px;
    background: rgba(0, 212, 255, 0.1);
    border: 1px solid rgba(0, 212, 255, 0.3);
    border-radius: 12px;
    font-size: 0.75rem;
    color: #00D4FF;
    font-weight: 500;
    white-space: nowrap;
}

.spec-badge i {
    font-size: 0.7rem;
}

/* Badge de quantidade de fotos */
.projeto-photo-count {
    position: absolute;
    bottom: 12px;
    right: 12px;
    display: flex;
    align-items: center;
    gap: 5px;
    padding: 6px 10px;
    background: rgba(0, 0, 0, 0.7);
    backdrop-filter: blur(5px);
    -webkit-backdrop-filter: blur(5px);
    border-radius: 20px;
    color: rgba(255, 255, 255, 0.9);
    font-size: 0.75rem;
    font-weight: 500;
    z-index: var(--z-raised, 3);
    transition: all 0.3s ease;
}

.projeto-photo-count i {
    font-size: 0.7rem;
    color: #00D4FF;
}

.projeto-card:hover .projeto-photo-count {
    background: rgba(0, 212, 255, 0.2);
    border: 1px solid rgba(0, 212, 255, 0.4);
}

/* ========== IMAGE LOADING (Nubank Style Shimmer) ========== */
@keyframes shimmer-loading {
    0% { background-position: 200% 0; }
    100% { background-position: -200% 0; }
}

/* Image loading state */
.projeto-image {
    position: relative;
    aspect-ratio: 4 / 3;
    overflow: hidden;
    background: rgba(15, 23, 42, 0.9);
}

.projeto-image.loading {
    background: linear-gradient(
        90deg,
        rgba(255, 255, 255, 0.03) 0%,
        rgba(255, 255, 255, 0.08) 50%,
        rgba(255, 255, 255, 0.03) 100%
    );
    background-size: 200% 100%;
    animation: shimmer-loading 1.5s ease-in-out infinite;
}

.projeto-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s ease, filter 0.5s ease, opacity 0.4s ease;
    opacity: 0;
}

.projeto-image.loaded img {
    opacity: 1;
}

/* ========== LOADING STATE (fallback) ========== */
.loading-state {
    grid-column: 1 / -1;
    text-align: center;
    padding: 60px 20px;
    color: #94a3b8;
    display: none;
}

.loading-spinner {
    width: 50px;
    height: 50px;
    border: 3px solid rgba(0, 212, 255, 0.1);
    border-top-color: #00D4FF;
    border-radius: 50%;
    margin: 0 auto 20px;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

/* ========== EMPTY STATE ========== */
.empty-state {
    text-align: center;
    padding: 80px 20px;
    color: #94a3b8;
}

.empty-state i {
    font-size: 4rem;
    margin-bottom: 20px;
    opacity: 0.3;
}

.empty-state h3 {
    font-family: 'Orbitron', sans-serif;
    font-size: 1.5rem;
    color: #fff;
    margin-bottom: 10px;
}

/* ========== CTA SECTION ========== */
.cta-section {
    padding: 80px 20px;
    background: linear-gradient(135deg, rgba(0, 212, 255, 0.05) 0%, rgba(138, 43, 226, 0.05) 100%);
    border-top: 1px solid var(--glass-stroke);
    border-bottom: 1px solid var(--glass-stroke);
}

.cta-content {
    max-width: 600px;
    margin: 0 auto;
    text-align: center;
}

.cta-content h2 {
    font-family: 'Orbitron', sans-serif;
    font-size: 2rem;
    color: #fff;
    margin-bottom: 15px;
}

.cta-content p {
    color: #94a3b8;
    font-size: 1.1rem;
    margin-bottom: 30px;
}

.btn-cta {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    padding: 16px 40px;
    background: linear-gradient(135deg, #25D366, #128C7E);
    color: white;
    border: none;
    border-radius: 50px;
    font-size: 1.1rem;
    font-weight: 600;
    text-decoration: none;
    transition: all 0.3s ease;
    box-shadow: 0 10px 30px rgba(37, 211, 102, 0.3);
}

.btn-cta:hover {
    transform: translateY(-3px);
    box-shadow: 0 15px 40px rgba(37, 211, 102, 0.4);
}

/* ========== VISUALIZACAO FULLSCREEN ========== */
.modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(10, 14, 26, 0.85);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    z-index: var(--z-loading, 10000);
    display: none;
    overflow-y: auto;
    overflow-x: hidden;
}

.modal-overlay.active {
    display: block;
}

/* Scrollbar estilizado do modal */
.modal-overlay::-webkit-scrollbar {
    width: 8px;
}

.modal-overlay::-webkit-scrollbar-track {
    background: rgba(255, 255, 255, 0.05);
}

.modal-overlay::-webkit-scrollbar-thumb {
    background: linear-gradient(180deg, #00D4FF, #0077FF);
    border-radius: 4px;
}

.modal-overlay::-webkit-scrollbar-thumb:hover {
    background: linear-gradient(180deg, #00E5FF, #0088FF);
}

/* Firefox */
.modal-overlay {
    scrollbar-width: thin;
    scrollbar-color: #00D4FF rgba(255, 255, 255, 0.05);
}

.modal-content {
    background: transparent;
    border: none;
    width: 100%;
    min-height: 100%;
    position: relative;
    animation: modalFadeIn 0.3s ease;
    padding: 40px;
    max-width: 1400px;
    margin: 0 auto;
}

.modal-close {
    position: fixed;
    top: 20px;
    right: 20px;
    width: 42px;
    height: 42px;
    border-radius: 50%;
    background: rgba(15, 23, 42, 0.85);
    border: 1px solid rgba(255, 255, 255, 0.15);
    color: #fff;
    font-size: 1.1rem;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: var(--z-popover, 1001);
    transition: all 0.2s ease;
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
}

.modal-close:hover {
    background: rgba(239, 68, 68, 0.85);
    border-color: rgba(239, 68, 68, 0.5);
    transform: scale(1.1);
}

@keyframes modalFadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

/* Layout fluido - foto e texto lado a lado */
.modal-layout {
    display: flex;
    gap: 50px;
    align-items: flex-start;
}

/* Lado esquerdo - Foto */
.modal-left {
    flex: 0 0 55%;
    max-width: 55%;
    position: sticky;
    top: 20px;
}

/* Container principal da imagem - TAMANHO FIXO mas invisivel */
.modal-image-container {
    position: relative;
    width: 100%;
    height: 70vh;
    min-height: 400px;
    max-height: 700px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: transparent;
}

/* Imagem sempre centralizada dentro do container fixo */
.modal-image-container img,
.modal-image-container #modal-image {
    max-width: 100%;
    max-height: 100%;
    width: auto;
    height: auto;
    object-fit: contain;
    border-radius: 12px;
}

/* Botoes de navegacao - estilo minimalista (so a seta) */
.modal-nav {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background: transparent;
    border: none;
    color: rgba(255, 255, 255, 0.7);
    font-size: 2rem;
    cursor: pointer;
    z-index: var(--z-raised, 10);
    transition: all 0.3s ease;
    padding: 15px;
    width: 55px;
    height: 55px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.modal-nav:hover {
    color: #00D4FF;
    transform: translateY(-50%) scale(1.15);
}

.modal-prev { left: 15px; }
.modal-next { right: 15px; }

/* Contador de fotos */
.modal-photo-counter {
    position: absolute;
    bottom: 12px;
    left: 50%;
    transform: translateX(-50%);
    background: rgba(0, 0, 0, 0.5);
    padding: 6px 14px;
    border-radius: 15px;
    color: rgba(255, 255, 255, 0.85);
    font-size: 0.8rem;
    font-weight: 500;
    z-index: var(--z-raised, 10);
}

/* Miniaturas */
.modal-thumbnails {
    display: flex;
    gap: 8px;
    padding: 12px 0;
    overflow-x: auto;
    justify-content: center;
    margin-top: 12px;
}

.modal-thumbnail {
    width: 50px;
    height: 50px;
    border-radius: 6px;
    overflow: hidden;
    cursor: pointer;
    border: 2px solid transparent;
    transition: all 0.3s ease;
    flex-shrink: 0;
    opacity: 0.6;
}

.modal-thumbnail:hover {
    opacity: 0.8;
}

.modal-thumbnail.active {
    border-color: #00D4FF;
    opacity: 1;
    box-shadow: 0 0 15px rgba(0, 212, 255, 0.5);
}

.modal-thumbnail img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

/* Lado direito - Informacoes fluindo */
.modal-right {
    flex: 1;
    padding-top: 10px;
}

.modal-info {
    padding: 0;
}

.modal-info h3 {
    font-family: 'Orbitron', sans-serif;
    font-size: 1.8rem;
    color: #fff;
    margin-bottom: 20px;
    line-height: 1.3;
}

.modal-specs {
    display: flex;
    gap: 12px;
    flex-wrap: wrap;
    margin-bottom: 25px;
}

.modal-specs .spec-badge {
    background: rgba(0, 212, 255, 0.15);
    border-color: rgba(0, 212, 255, 0.3);
    padding: 8px 16px;
    font-size: 0.85rem;
}

.modal-description-container {
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    padding-top: 25px;
    margin-top: 10px;
}

.modal-description-container h4 {
    display: none;
}

.modal-description {
    color: #d0d8e0;
    font-size: 1.05rem;
    line-height: 1.9;
    margin: 0;
    white-space: pre-line;
    text-align: justify;
}

/* CTA e compartilhamento */
.modal-cta {
    margin-top: 35px;
    padding-top: 25px;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.modal-cta p {
    color: #94a3b8;
    font-size: 0.95rem;
    margin-bottom: 15px;
}

.modal-cta .btn-whatsapp {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    padding: 14px 32px;
    background: linear-gradient(135deg, #25D366, #128C7E);
    color: white;
    border: none;
    border-radius: 50px;
    font-size: 1rem;
    font-weight: 600;
    text-decoration: none;
    transition: all 0.3s ease;
    box-shadow: 0 8px 25px rgba(37, 211, 102, 0.3);
}

.modal-cta .btn-whatsapp:hover {
    transform: translateY(-3px);
    box-shadow: 0 12px 35px rgba(37, 211, 102, 0.45);
}

/* Outros Projetos Relacionados */
.modal-related {
    margin-top: 60px;
    padding-top: 40px;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.modal-related h4 {
    font-family: 'Orbitron', sans-serif;
    font-size: 1.3rem;
    color: #fff;
    margin-bottom: 25px;
    text-align: center;
}

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

.related-card {
    background: rgba(15, 23, 42, 0.6);
    border-radius: 12px;
    overflow: hidden;
    border: 1px solid rgba(0, 212, 255, 0.1);
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    flex-direction: column;
}

.related-card:hover {
    transform: translateY(-5px);
    border-color: rgba(0, 212, 255, 0.4);
    box-shadow: 0 10px 25px rgba(0, 212, 255, 0.15);
}

.related-card-image {
    width: 100%;
    aspect-ratio: 4 / 3;
    overflow: hidden;
    background: rgba(0, 0, 0, 0.3);
}

.related-card-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s ease;
}

.related-card:hover .related-card-image img {
    transform: scale(1.1);
}

.related-card-info {
    padding: 12px;
    flex: 1;
}

.related-card-info h5 {
    font-family: 'Orbitron', sans-serif;
    font-size: 0.85rem;
    color: #fff;
    margin: 0;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.related-card-info span {
    font-size: 0.75rem;
    color: #00D4FF;
    display: block;
    margin-top: 5px;
}

/* Responsivo */
@media (max-width: 1024px) {
    .modal-content {
        padding: 30px 25px;
    }

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

    .modal-layout {
        flex-direction: column;
        gap: 30px;
    }

    .modal-left {
        flex: none;
        max-width: 100%;
        width: 100%;
        position: relative;
        top: 0;
    }

    .modal-image-container {
        height: 55vh;
        min-height: 300px;
        max-height: 500px;
    }

    .modal-nav {
        width: 50px;
        height: 50px;
        font-size: 1.8rem;
    }

    .modal-prev { left: 10px; }
    .modal-next { right: 10px; }

    .modal-right {
        width: 100%;
    }

    .modal-info h3 {
        font-size: 1.4rem;
    }
}

@media (max-width: 600px) {
    .modal-content {
        padding: 20px 15px;
    }

    .modal-image-container {
        height: 45vh;
        min-height: 250px;
        max-height: 400px;
    }

    .modal-nav {
        width: 45px;
        height: 45px;
        font-size: 1.5rem;
    }

    .modal-prev { left: 5px; }
    .modal-next { right: 5px; }

    .modal-thumbnails {
        gap: 6px;
    }

    .modal-thumbnail {
        width: 40px;
        height: 40px;
    }

    .modal-info h3 {
        font-size: 1.2rem;
    }

    .modal-description {
        font-size: 1rem;
        line-height: 1.8;
    }
}

/* ========== FOOTER (identico ao site principal) ========== */
footer {
    background: rgba(6, 12, 26, 0.9);
    border-top: 1px solid rgba(77, 166, 255, 0.15);
    padding: 60px 40px 40px;
}

.footer-content {
    max-width: 1200px;
    margin: 0 auto;
}

.footer-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 40px;
    margin-bottom: 40px;
}

.footer-logo {
    font-family: 'Rajdhani', 'Orbitron', monospace;
    font-size: 1.8rem;
    font-weight: 700;
    background: linear-gradient(135deg, #4da6ff, #1a4fa3);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    margin-bottom: 15px;
    text-transform: uppercase;
    letter-spacing: 2px;
}

.footer-tagline {
    color: #94a3b8;
    font-size: 0.95rem;
    margin-bottom: 20px;
    line-height: 1.5;
}

.social-links {
    display: flex;
    gap: 12px;
}

.social-link {
    width: 40px;
    height: 40px;
    border-radius: 10px;
    background: rgba(77, 166, 255, 0.1);
    border: 1px solid rgba(77, 166, 255, 0.2);
    display: flex;
    align-items: center;
    justify-content: center;
    color: #4da6ff;
    text-decoration: none;
    transition: all 0.3s ease;
    font-size: 1rem;
}

.social-link:hover {
    background: rgba(77, 166, 255, 0.25);
    border-color: #4da6ff;
    transform: translateY(-3px);
    box-shadow: 0 5px 15px rgba(77, 166, 255, 0.3);
}

.footer-title {
    font-family: 'Rajdhani', 'Orbitron', monospace;
    font-size: 1rem;
    font-weight: 700;
    color: #4da6ff;
    margin-bottom: 20px;
    text-transform: uppercase;
    letter-spacing: 1px;
}

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

.footer-list li {
    display: flex;
    align-items: center;
    gap: 10px;
    color: #94a3b8;
    font-size: 0.9rem;
    margin-bottom: 12px;
}

.footer-list li i {
    color: #4da6ff;
    width: 16px;
}

.footer-list a {
    color: #94a3b8;
    text-decoration: none;
    transition: color 0.3s ease;
}

.footer-list a:hover {
    color: #4da6ff;
}

.footer-bottom {
    border-top: 1px solid rgba(77, 166, 255, 0.1);
    padding-top: 25px;
    text-align: center;
}

.footer-bottom p {
    color: #64748b;
    font-size: 0.9rem;
}

@media (max-width: 768px) {
    footer { padding: 40px 20px 25px; }
    .footer-grid { grid-template-columns: 1fr; gap: 30px; text-align: center; }
    .footer-brand { align-items: center; }
    .social-links { justify-content: center; }
    .footer-list { align-items: center; }
    .footer-bottom { padding-top: 20px; }
}

@media (max-width: 480px) {
    .footer-logo { font-size: 1.3rem; }
    .footer-tagline { font-size: 0.85rem; }
    .footer-list li { font-size: 0.85rem; }
}

/* ========== FAB ========== */
.fab-container {
    position: fixed;
    bottom: 20px;
    right: 20px;
    display: flex;
    flex-direction: column;
    gap: 12px;
    z-index: var(--z-overlay, 9999);
}

.fab-btn {
    width: 56px;
    height: 56px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    text-decoration: none;
    transition: all 0.3s ease;
    position: relative;
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
}

.fab-whatsapp {
    background: rgba(37, 211, 102, 0.2);
    color: #25d366;
    border: 1px solid rgba(37, 211, 102, 0.4);
    box-shadow: 0 8px 32px rgba(37, 211, 102, 0.3);
}

.fab-whatsapp:hover {
    background: rgba(37, 211, 102, 0.3);
    border-color: rgba(37, 211, 102, 0.6);
    box-shadow: 0 12px 40px rgba(37, 211, 102, 0.5);
    transform: scale(1.1);
}

.fab-instagram {
    background: rgba(77, 166, 255, 0.15);
    color: #4da6ff;
    border: 1px solid rgba(77, 166, 255, 0.3);
    box-shadow: 0 8px 32px rgba(77, 166, 255, 0.2);
}

.fab-instagram:hover {
    background: rgba(77, 166, 255, 0.25);
    border-color: rgba(77, 166, 255, 0.5);
    box-shadow: 0 12px 40px rgba(77, 166, 255, 0.4);
    transform: scale(1.1);
}

.fab-btn:hover {
    transform: scale(1.1);
}

.fab-tooltip {
    position: absolute;
    right: 65px;
    background: rgba(0, 0, 0, 0.8);
    color: #fff;
    padding: 6px 12px;
    border-radius: 8px;
    font-size: 0.8rem;
    white-space: nowrap;
    opacity: 0;
    transition: opacity 0.3s ease;
    pointer-events: none;
}

.fab-btn:hover .fab-tooltip {
    opacity: 1;
}

/* ========== RESPONSIVE ========== */
@media (max-width: 992px) {
    .projetos-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .page-title {
        font-size: 2.5rem;
    }
}

@media (max-width: 768px) {
    /* Navbar compacta - apenas icones */
    .navbar {
        padding: 10px 15px;
        border-radius: 25px;
        width: 95%;
        overflow: hidden;
    }

    .navbar-container {
        flex-direction: row;
        flex-wrap: nowrap;
        gap: 8px;
        overflow: hidden;
    }

    .navbar-left {
        flex-shrink: 0;
        width: auto;
        overflow: hidden;
    }

    .navbar-right {
        flex: 1;
        justify-content: flex-end;
        gap: 6px;
        width: auto;
        flex-wrap: nowrap;
        overflow: hidden;
    }

    .logo-subtitle,
    .page-name {
        display: none;
    }

    /* Botoes viram icones */
    .btn-nav {
        padding: 8px 10px;
        border-radius: 10px;
        min-width: 40px;
        justify-content: center;
    }

    .btn-nav span {
        display: none;
    }

    .btn-nav i {
        font-size: 1rem;
        margin: 0;
    }

    .btn-orcamento span {
        display: none;
    }

    /* ===== FILTROS MOBILE - GRID RESPONSIVO ===== */
    .filter-section {
        padding: 100px 15px 15px;
        width: 100%;
        box-sizing: border-box;
    }

    .filter-scroll-wrapper {
        width: 100%;
    }

    .filter-container {
        display: flex;
        flex-wrap: wrap;
        gap: 8px;
        justify-content: center;
        width: 100%;
    }

    .filter-btn {
        padding: 8px 12px;
        font-size: 0;
        white-space: nowrap;
        border-radius: 25px;
        min-width: 42px;
        height: 42px;
        display: flex;
        align-items: center;
        justify-content: center;
        flex: 0 0 auto;
    }

    .filter-btn i {
        font-size: 1rem;
        margin: 0;
    }

    .filter-btn.active {
        box-shadow: 0 0 15px rgba(0, 212, 255, 0.4);
    }

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

@media (max-width: 480px) {
    .navbar {
        padding: 8px 12px;
        border-radius: 20px;
    }

    .navbar-container {
        gap: 6px;
    }

    .logo {
        font-size: 1rem;
    }

    .btn-nav {
        padding: 6px 8px;
        min-width: 34px;
    }

    .btn-nav i {
        font-size: 0.9rem;
    }

    .filter-section {
        padding-top: 85px;
    }

    .filter-container {
        gap: 6px;
        padding: 5px 10px;
    }

    .filter-btn {
        min-width: 40px;
        height: 40px;
        padding: 8px 14px;
    }

    .filter-btn i {
        font-size: 0.9rem;
    }

    .page-title {
        font-size: 1.8rem;
    }

    .cta-content h2 {
        font-size: 1.5rem;
    }

    .fab-btn {
        width: 50px;
        height: 50px;
        font-size: 1.2rem;
    }
}

/* ==================================================
   OTIMIZACOES MOBILE - PERFORMANCE E UX
   Baseado nas melhorias implementadas em /dev
   ================================================== */

/* ========== 1. PREFERS-REDUCED-MOTION ========== */
@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }

    .cosmic-bg::before,
    .cosmic-bg::after {
        animation: none !important;
    }

    .particle {
        animation: none !important;
    }
}

/* ========== 2. PERFORMANCE MOBILE ========== */
@media (max-width: 768px) {
    /* Simplificar orbes de luz em mobile */
    .cosmic-bg::before,
    .cosmic-bg::after {
        width: 300px;
        height: 300px;
        filter: blur(80px);
        animation-duration: 30s;
    }
}

@media (max-width: 480px) {
    /* Desabilitar particulas em mobile pequeno */
    .particles {
        display: none !important;
    }

    /* Simplificar ainda mais os orbes */
    .cosmic-bg::before,
    .cosmic-bg::after {
        width: 200px;
        height: 200px;
        filter: blur(60px);
        opacity: 0.5;
    }

    /* Remover backdrop-filter em mobile muito pequeno */
    .projeto-card,
    .filter-btn {
        backdrop-filter: none !important;
        -webkit-backdrop-filter: none !important;
    }
}

/* ========== 3. ASPECT-RATIO PARA PREVENIR LAYOUT SHIFT ========== */
/* projeto-image ja tem aspect-ratio definido no CSS principal */

/* Fallback para navegadores antigos */
@supports not (aspect-ratio: 4 / 3) {
    .projeto-image {
        height: 220px !important;
    }
    .related-card-image {
        height: 140px !important;
    }
}

/* ========== 4. TEXT TRUNCATION COM LINE-CLAMP ========== */
.projeto-title {
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    text-overflow: ellipsis;
}

.projeto-hover-desc {
    display: -webkit-box;
    -webkit-line-clamp: 4;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

@media (max-width: 480px) {
    .projeto-hover-desc {
        -webkit-line-clamp: 3;
    }
}

/* ========== 5. MODAL FULLSCREEN EM MOBILE ========== */
@media (max-width: 768px) {
    .modal-overlay {
        padding: 0;
        overflow-y: auto;
        -webkit-overflow-scrolling: touch;
    }

    .modal-content {
        max-width: 100%;
        min-height: 100%;
        height: auto;
        border-radius: 0;
        display: block;
        padding: 0;
        padding-top: 60px;
        padding-bottom: 30px;
    }

    .modal-close {
        position: fixed;
        top: 15px;
        right: 15px;
        z-index: var(--z-popover, 1001);
        background: rgba(0, 0, 0, 0.7);
        width: 44px;
        height: 44px;
    }

    .modal-layout {
        flex-direction: column;
        height: auto;
        overflow: visible;
    }

    .modal-left {
        flex: none;
        max-width: 100%;
        width: 100%;
        position: relative;
        top: auto;
    }

    .modal-image-container {
        height: 45vh;
        min-height: 250px;
        max-height: 350px;
    }

    .modal-right {
        flex: none;
        padding: 20px;
        overflow: visible;
    }

    .modal-info {
        padding: 0;
    }

    .modal-info h3 {
        font-size: 1.3rem;
        margin-bottom: 15px;
    }

    .modal-description-container {
        margin-top: 15px;
        padding-top: 15px;
    }

    .modal-description {
        font-size: 1rem;
        line-height: 1.7;
        color: #d0d8e0;
        white-space: pre-line;
    }

    .modal-cta {
        margin-top: 25px;
        padding-top: 20px;
    }

    .modal-thumbnails {
        padding: 10px 15px;
        gap: 8px;
        justify-content: flex-start;
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
    }

    .modal-thumbnail {
        flex-shrink: 0;
    }

    .modal-related {
        padding: 20px;
        margin-top: 20px;
    }

    .related-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 12px;
    }
}

@media (max-width: 480px) {
    .modal-image-container {
        height: 35vh;
        min-height: 200px;
        max-height: 280px;
    }

    .modal-nav {
        width: 40px;
        height: 40px;
        font-size: 1.2rem;
    }

    .modal-prev { left: 5px; }
    .modal-next { right: 5px; }

    .modal-right {
        padding: 15px;
    }

    .modal-info h3 {
        font-size: 1.1rem;
    }

    .modal-description {
        font-size: 0.95rem;
        line-height: 1.65;
    }

    .modal-cta {
        margin-top: 20px;
        padding-top: 15px;
    }

    .modal-cta .btn-whatsapp {
        width: 100%;
        justify-content: center;
        padding: 12px 20px;
    }

    .related-grid {
        grid-template-columns: 1fr;
        gap: 15px;
    }
}

/* ========== 6. TIPOGRAFIA OTIMIZADA PARA MOBILE ========== */
@media (max-width: 768px) {
    body {
        font-size: 16px; /* Previne zoom automatico no iOS */
        -webkit-text-size-adjust: 100%;
        text-size-adjust: 100%;
    }

    .page-subtitle {
        font-size: 1rem;
        line-height: 1.6;
    }

    .projeto-hover-desc,
    .modal-description {
        font-size: 0.95rem;
        line-height: 1.55;
    }

    /* Espacamento entre secoes */
    .projetos-section {
        padding: 40px 15px;
    }

    .cta-section {
        padding: 50px 15px;
    }

    footer {
        padding: 30px 15px;
    }
}

@media (max-width: 480px) {
    .page-title {
        font-size: 1.6rem !important;
        line-height: 1.3;
    }

    .page-subtitle {
        font-size: 0.9rem;
    }

    .projetos-section {
        padding: 30px 12px;
    }

    .cta-section {
        padding: 40px 12px;
    }
}

/* ========== 7. HOVER STATES PARA TOUCH ========== */
@media (hover: none) and (pointer: coarse) {
    /* Dispositivos touch - remover hover effects que causam "sticky hover" */
    .projeto-card:hover {
        transform: none;
        box-shadow: none;
    }

    .projeto-card:hover .projeto-image img {
        transform: none;
        filter: none;
    }

    /* Esconder hover overlay em touch - clique direto */
    .projeto-hover-overlay {
        display: none !important;
    }

    /* Manter apenas transform no active state */
    .projeto-card:active {
        transform: scale(0.98);
        transition: transform 0.1s ease;
    }

    .filter-btn:hover {
        transform: none;
    }

    .filter-btn:active {
        transform: scale(0.97);
    }

    .btn-cta:hover,
    .btn-whatsapp:hover {
        transform: none;
    }

    .btn-cta:active,
    .btn-whatsapp:active {
        transform: scale(0.97);
    }

    /* FABs */
    .fab-btn:hover {
        transform: none;
    }

    .fab-btn:active {
        transform: scale(0.95);
    }

    /* Related cards */
    .related-card:hover {
        transform: none;
    }

    .related-card:active {
        transform: scale(0.98);
    }
}

/* ========== 8. CARDS RESPONSIVOS ========== */
@media (max-width: 768px) {
    .projeto-card {
        border-radius: 16px;
    }

    .projeto-overlay {
        padding: 12px;
    }

    .projeto-title {
        font-size: 1rem;
    }

    .projeto-logo-overlay {
        width: 40px;
        height: 40px;
        top: 10px;
        right: 10px;
    }

    .projeto-photo-count {
        bottom: 8px;
        right: 8px;
        left: auto;
        padding: 4px 8px;
        font-size: 0.7rem;
        width: auto;
    }
}

@media (max-width: 480px) {
    .projeto-card {
        border-radius: 12px;
    }

    .projeto-category {
        font-size: 0.7rem;
        padding: 4px 10px;
    }

    .projeto-title {
        font-size: 0.9rem;
    }

    .projeto-logo-overlay {
        width: 35px;
        height: 35px;
    }
}

/* Filtros responsivos consolidados na secao RESPONSIVE principal (linha ~1275) */

/* ========== 10. CTA SECTION RESPONSIVO ========== */
@media (max-width: 768px) {
    .cta-content {
        padding: 30px 20px;
    }

    .cta-content h2 {
        font-size: 1.4rem;
        margin-bottom: 10px;
    }

    .cta-content p {
        font-size: 0.95rem;
        margin-bottom: 20px;
    }

    .btn-cta {
        padding: 14px 28px;
        font-size: 0.95rem;
    }
}

@media (max-width: 480px) {
    .cta-content {
        padding: 25px 15px;
    }

    .cta-content h2 {
        font-size: 1.2rem;
    }

    .cta-content p {
        font-size: 0.9rem;
    }

    .btn-cta {
        width: 100%;
        justify-content: center;
        padding: 14px 20px;
    }
}

/* Navbar mobile styles consolidados na secao RESPONSIVE principal (linha ~1218) */

/* ========== 12. FAB OTIMIZADO MOBILE ========== */
@media (max-width: 768px) {
    .fab-container {
        bottom: 20px;
        right: 20px;
    }

    .fab-btn {
        width: 54px;
        height: 54px;
        font-size: 1.3rem;
    }

    .fab-tooltip {
        display: none;
    }
}

/* ========== 13. EMPTY STATE MOBILE ========== */
@media (max-width: 768px) {
    .empty-state {
        padding: 40px 20px;
    }

    .empty-state i {
        font-size: 3rem;
    }

    .empty-state h3 {
        font-size: 1.2rem;
    }

    .empty-state p {
        font-size: 0.9rem;
    }
}

/* ========== 14. SCROLLBAR CUSTOMIZADO EM MOBILE ========== */
@media (max-width: 768px) {
    .modal-layout::-webkit-scrollbar,
    .modal-thumbnails::-webkit-scrollbar {
        width: 4px;
        height: 4px;
    }

    .modal-layout::-webkit-scrollbar-thumb,
    .modal-thumbnails::-webkit-scrollbar-thumb {
        background: rgba(0, 212, 255, 0.5);
        border-radius: 2px;
    }
}

/* ========== 15. SAFE AREA PARA IPHONE X+ ========== */
@supports (padding-bottom: env(safe-area-inset-bottom)) {
    .fab-container {
        bottom: calc(20px + env(safe-area-inset-bottom));
        right: calc(20px + env(safe-area-inset-right));
    }

    .modal-content {
        padding-bottom: env(safe-area-inset-bottom);
    }

    footer {
        padding-bottom: calc(30px + env(safe-area-inset-bottom));
    }
}

/* ========== 16. LANDSCAPE MOBILE ========== */
@media (max-width: 768px) and (orientation: landscape) {
    .filter-section {
        padding-top: 100px;
    }

    .modal-image-container {
        height: 60vh;
        max-height: none;
    }

    .modal-layout {
        flex-direction: row;
    }

    .modal-left {
        width: 50%;
    }

    .modal-right {
        width: 50%;
    }
}
