/* =========================================================================
   DEEP DEV - ASSETS CORE CSS
   Motor unificado de Design Tokens + Layout Mobile-First
   ========================================================================= */

@import url("https://fonts.googleapis.com/css2?family=Fira+Code:wght@400;500;600&family=Lato:wght@300;400;700;900&display=swap");

:root {
  /* Cores - Deep Dev Vibe */
  --color-base: #0b1120;
  --color-surface: #1e293b;
  --color-surface-hover: #334155;
  --color-primary: #38bdf8;
  --color-primary-hover: #0ea5e9;
  --color-primary-glow: rgba(56, 189, 248, 0.4);
  --color-text: #f8fafc;
  --color-text-muted: #94a3b8;
  --color-border: #334155;

  /* Fontes */
  --font-main: "Lato", sans-serif;
  --font-mono: "Fira Code", monospace;

  /* Tipografia Fluida (Clamp) */
  --text-xs: clamp(0.75rem, 1vw, 0.875rem);
  --text-sm: clamp(0.875rem, 1.2vw, 1rem);
  --text-base: clamp(1rem, 1.5vw, 1.125rem);
  --text-lg: clamp(1.125rem, 2vw, 1.25rem);
  --text-xl: clamp(1.25rem, 2.5vw, 1.5rem);
  --text-2xl: clamp(1.5rem, 3vw, 2rem);
  --text-3xl: clamp(2rem, 5vw, 2.5rem);
  --text-4xl: clamp(2.5rem, 6vw, 3.5rem);

  /* Espaçamentos e Layout */
  --space-1: 0.25rem;
  --space-2: 0.5rem;
  --space-3: 0.75rem;
  --space-4: 1rem;
  --space-6: 1.5rem;
  --space-8: 2rem;
  --space-12: 3rem;
  --space-16: 4rem;

  --radius-sm: 8px;
  --radius-md: 12px;
  --radius-lg: 16px;
  --radius-full: 9999px;
  --min-touch: 48px;

  /* Transições suaves */
  --transition-fast: 150ms cubic-bezier(0.4, 0, 0.2, 1);
  --transition-normal: 300ms cubic-bezier(0.4, 0, 0.2, 1);
  --transition-bounce: 500ms cubic-bezier(0.34, 1.56, 0.64, 1);
}

/* =========================================================================
   2. RESETS E BASE
   ========================================================================= */
*,
*::before,
*::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}
html {
  scroll-behavior: smooth;
}
body {
  font-family: var(--font-main);
  background-color: var(--color-base);
  color: var(--color-text);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-x: hidden;
}

h1,
h2,
h3,
h4,
h5,
h6 {
  color: var(--color-text);
  line-height: 1.2;
  font-weight: 700;
}
a {
  color: var(--color-primary);
  text-decoration: none;
  transition: color var(--transition-fast);
}
a:hover {
  color: var(--color-primary-hover);
}

/* =========================================================================
   3. TIPOGRAFIA UTILITÁRIA
   ========================================================================= */
.text-4xl {
  font-size: var(--text-4xl);
  font-weight: 900;
  letter-spacing: -1px;
}
.text-3xl {
  font-size: var(--text-3xl);
  font-weight: 700;
}
.text-2xl {
  font-size: var(--text-2xl);
  font-weight: 700;
}
.text-xl {
  font-size: var(--text-xl);
  font-weight: 600;
}
.text-lg {
  font-size: var(--text-lg);
  font-weight: 300;
}
.text-base {
  font-size: var(--text-base);
  font-weight: 400;
}
.text-sm {
  font-size: var(--text-sm);
  font-weight: 400;
}
.text-xs {
  font-size: var(--text-xs);
  font-weight: 400;
}
.font-mono {
  font-family: var(--font-mono);
}
.text-primary {
  color: var(--color-primary);
}
.text-muted {
  color: var(--color-text-muted);
}

.tech-label {
  display: inline-flex;
  align-items: center;
  font-family: var(--font-mono);
  font-size: var(--text-xs);
  padding: var(--space-1) var(--space-3);
  background: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-full);
  color: var(--color-primary);
}

/* =========================================================================
   4. LAYOUT E GRIDS (Mobile First)
   ========================================================================= */
.container {
  width: 100%;
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 var(--space-4);
}
.section {
  padding: var(--space-12) 0;
}
.flex {
  display: flex;
}
.flex-col {
  flex-direction: column;
}
.items-center {
  align-items: center;
}
.justify-center {
  justify-content: center;
}
.justify-between {
  justify-content: space-between;
}
.gap-2 {
  gap: var(--space-2);
}
.gap-4 {
  gap: var(--space-4);
}
.gap-6 {
  gap: var(--space-6);
}
.gap-8 {
  gap: var(--space-8);
}

.grid {
  display: grid;
  gap: var(--space-6);
  grid-template-columns: 1fr;
}
@media (max-width: 640px) {
  .hidden-mobile {
    display: none !important;
  }
}
@media (min-width: 640px) {
  .sm\:grid-cols-2 {
    grid-template-columns: repeat(2, 1fr);
  }
}
@media (min-width: 768px) {
  .md\:grid-cols-2 {
    grid-template-columns: repeat(2, 1fr);
  }
  .md\:grid-cols-3 {
    grid-template-columns: repeat(3, 1fr);
  }
}
@media (min-width: 1024px) {
  .lg\:grid-cols-4 {
    grid-template-columns: repeat(4, 1fr);
  }
}

/* =========================================================================
   5. BACKGROUNDS E GLASSMORPHISM
   ========================================================================= */
.surface {
  background-color: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-lg);
}

.glass-panel {
  background: rgba(30, 41, 59, 0.4);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border: 1px solid rgba(255, 255, 255, 0.05);
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.3);
  border-radius: var(--radius-lg);
  padding: var(--space-6);
  transition:
    transform var(--transition-bounce),
    box-shadow var(--transition-normal);
}
.glass-panel:hover {
  transform: translateY(-4px);
  box-shadow:
    0 12px 40px rgba(0, 0, 0, 0.4),
    0 0 20px var(--color-primary-glow);
  border-color: rgba(56, 189, 248, 0.1);
}

.mesh-bg-wrapper {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  z-index: -1;
  pointer-events: none;
  overflow: hidden;
}
.mesh-bg-wrapper::before {
  content: "";
  position: absolute;
  top: -20%;
  right: -10%;
  width: 50vw;
  height: 50vw;
  background: radial-gradient(
    circle,
    rgba(56, 189, 248, 0.1) 0%,
    transparent 60%
  );
  filter: blur(80px);
  animation: pulse-bg 8s infinite alternate ease-in-out;
}

/* =========================================================================
   6. COMPONENTES DE UI
   ========================================================================= */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: var(--space-2);
  min-height: var(--min-touch);
  padding: 0 var(--space-6);
  font-family: var(--font-main);
  font-weight: 700;
  font-size: var(--text-base);
  border-radius: var(--radius-md);
  border: none;
  cursor: pointer;
  transition: all var(--transition-bounce);
}
.btn:active {
  transform: scale(0.96);
}
.btn-primary {
  background-color: var(--color-primary);
  color: var(--color-base);
  box-shadow: 0 4px 14px 0 rgba(56, 189, 248, 0.39);
}
a.btn-primary:hover,
.btn-primary:hover {
  background-color: var(--color-primary-hover);
  box-shadow: 0 6px 20px rgba(56, 189, 248, 0.6);
  transform: translateY(-2px);
  color: #000 !important;
}
.btn-outline {
  background-color: transparent;
  color: var(--color-text);
  border: 1px solid var(--color-border);
}
.btn-outline:hover {
  background-color: var(--color-surface);
  border-color: var(--color-primary);
  color: var(--color-text);
  transform: translateY(-2px);
}
.btn-ghost {
  background-color: transparent;
  color: var(--color-text);
}
.btn-ghost:hover {
  background-color: var(--color-surface);
  color: var(--color-primary);
}

/* =========================================================================
   7. ANIMAÇÕES (Motion Design)
   ========================================================================= */
@keyframes fadeIn {
  from {
    opacity: 0;
  }
  to {
    opacity: 1;
  }
}
@keyframes slideUpFade {
  from {
    opacity: 0;
    transform: translateY(30px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}
@keyframes pulse-bg {
  0% {
    transform: scale(1) translate(0, 0);
  }
  100% {
    transform: scale(1.1) translate(-20px, 20px);
  }
}

.animate-fade-in {
  animation: fadeIn 0.8s ease-out forwards;
  opacity: 0;
}
.animate-slide-up {
  animation: slideUpFade 0.8s cubic-bezier(0.2, 0.8, 0.2, 1) forwards;
  opacity: 0;
}
.animate-delay-1 {
  animation-delay: 150ms;
}
.animate-delay-2 {
  animation-delay: 300ms;
}
.animate-delay-3 {
  animation-delay: 450ms;
}

/* =========================================================================
   8. TICKER — Faixa de Rolagem Infinita (Hero Footer)
   ========================================================================= */

/* @keyframes da rolagem: move -50% porque temos 16 itens (8 originais × 2) */
@keyframes ticker-scroll {
  from {
    transform: translateX(0);
  }
  to {
    transform: translateX(-50%);
  }
}

.ticker-wrap {
  position: relative;
  z-index: 2;
  width: 100%;
  overflow: hidden;
  border-top: 1px solid var(--color-border);
  border-bottom: 1px solid var(--color-border);
  background: var(--color-surface);
  padding: var(--space-3) 0;
  /* Máscara de fade nas bordas */
  -webkit-mask-image: linear-gradient(
    to right,
    transparent 0%,
    black 8%,
    black 92%,
    transparent 100%
  );
  mask-image: linear-gradient(
    to right,
    transparent 0%,
    black 8%,
    black 92%,
    transparent 100%
  );
}

.ticker-track {
  display: inline-flex;
  align-items: center;
  white-space: nowrap;
  /* 35s = velocidade confortável; ajuste conforme necessário */
  animation: ticker-scroll 35s linear infinite;
  will-change: transform;
}

/* Pausa ao passar o mouse */
.ticker-wrap:hover .ticker-track {
  animation-play-state: paused;
}

.ticker-item {
  display: inline-block;
  font-family: var(--font-mono);
  font-size: var(--text-xs);
  font-weight: 400;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--color-text-muted);
  padding: 0 var(--space-6);
  transition: color var(--transition-fast);
  cursor: default;
}

/* Separador // entre itens */
.ticker-item::after {
  content: "//";
  margin-left: var(--space-6);
  color: var(--color-primary);
  opacity: 0.45;
  font-weight: 600;
}

/* Último item de cada metade sem separador duplicado (opcional visual) */
.ticker-item:nth-child(8)::after,
.ticker-item:last-child::after {
  opacity: 0;
}

/* Destaque ao hover no item */
.ticker-item:hover {
  color: var(--color-primary);
}

/* =========================================================================
   9. INTERATIVIDADE - TRAJETÓRIA STATS
   ========================================================================= */
.stat-card-deep {
  transition:
    transform var(--transition-bounce),
    background-color var(--transition-normal),
    box-shadow var(--transition-normal);
  cursor: default;
  position: relative;
  z-index: 1;
  border: 1px solid var(--color-border);
  margin-left: -1px;
  margin-top: -1px;
}

.stat-card-deep:hover {
  transform: translateY(-10px);
  background-color: var(--color-surface-hover) !important;
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.4);
  z-index: 10;
  border: 2px solid var(--color-primary);
  margin-left: -2px;
  margin-top: -2px;
}

/* --- Projetos 02--- */
.proj-row-deep {
  display: grid;
  grid-template-columns: 1fr;
  padding: var(--space-8) 0;
  border-bottom: 1px solid var(--color-border);
  transition: all var(--transition-normal);
  gap: var(--space-6);
  position: relative;
  text-decoration: none;
  color: inherit;
}

@media (min-width: 1024px) {
  .proj-row-deep {
    grid-template-columns: 200px 1fr 60px;
    align-items: center;
    gap: var(--space-12);
  }
}

.proj-row-deep:hover {
  border-color: var(--color-primary);
  background: rgba(56, 189, 248, 0.02);
  padding-left: var(--space-4);
  padding-right: var(--space-4);
}

.proj-meta-deep {
  display: flex;
  flex-direction: column !important;
  gap: var(--space-2);
  min-width: 180px;
}

.proj-center-deep h3 {
  font-size: var(--text-2xl);
  margin-bottom: var(--space-3);
  font-style: normal;
}

.proj-center-deep p {
  color: var(--color-text-muted);
  max-width: 700px;
  line-height: 1.7;
}

.proj-arrow-deep {
  color: var(--color-primary);
  display: flex;
  justify-content: flex-end;
  transition: transform var(--transition-bounce);
}

/* --- Oferta (Como posso ajudar) --- */
.offer-card-deep {
  display: flex;
  flex-direction: column;
  gap: var(--space-6);
  height: 100%;
  padding: var(--space-12);
  border: 1px solid var(--color-border);
  background: rgba(30, 41, 59, 0.3);
  border-radius: var(--radius-lg);
  transition: all var(--transition-bounce);
  position: relative;
  overflow: hidden;
}

.offer-card-deep:hover {
  border-color: var(--color-primary);
  transform: translateY(-8px);
  background: rgba(30, 41, 59, 0.5);
  box-shadow:
    0 20px 50px rgba(0, 0, 0, 0.5),
    0 0 30px var(--color-primary-glow);
}

.offer-card-tag-deep {
  font-family: var(--font-mono);
  font-size: 10px;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  color: var(--color-primary);
  opacity: 0.8;
}

.offer-card-deep h3 {
  font-size: var(--text-3xl);
  font-style: normal;
  font-weight: 700;
  margin-bottom: var(--space-1);
}

.offer-card-sub-deep {
  font-size: var(--text-sm);
  color: var(--color-primary);
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  margin-bottom: var(--space-4);
}

.offer-features-list-deep {
  list-style: none;
  padding: 0;
  margin: var(--space-4) 0;
  display: flex;
  flex-direction: column;
  gap: var(--space-3);
}

.offer-features-list-deep li {
  display: flex;
  align-items: center;
  gap: var(--space-3);
  font-size: var(--text-sm);
  color: var(--color-text-muted);
}

.offer-features-list-deep li i {
  color: var(--color-success);
  flex-shrink: 0;
}

/* --- Como Trabalho (Processo) --- */
.p-step-deep {
  position: relative;
  padding: var(--space-8);
  border-left: 2px solid var(--color-border);
  transition: all var(--transition-normal);
  display: flex;
  flex-direction: column;
  gap: var(--space-4);
}

.p-step-deep:hover {
  border-left-color: var(--color-primary);
  background: rgba(56, 189, 248, 0.02);
}

.p-num-deep {
  font-family: var(--font-mono);
  font-size: var(--text-4xl);
  font-weight: 700;
  color: var(--color-primary);
  opacity: 0.1;
  position: absolute;
  top: var(--space-4);
  right: var(--space-4);
  line-height: 1;
  pointer-events: none;
  transition: opacity var(--transition-normal);
}

.p-step-deep:hover .p-num-deep {
  opacity: 0.25;
}

.p-step-deep p {
  color: var(--color-text-muted);
  font-size: var(--text-sm);
  line-height: 1.7;
}

/* --- CTA Final (Acompanhe o Construtor) --- */
.cta-section-deep {
  text-align: center;
  padding: 120px 0;
  position: relative;
  overflow: hidden;
  background: radial-gradient(
    circle at center,
    rgba(56, 189, 248, 0.05) 0%,
    transparent 70%
  );
}

.cta-inner-deep {
  max-width: 800px;
  margin: 0 auto;
}

.cta-h-deep {
  font-size: var(--text-4xl);
  line-height: 1.1;
  margin-bottom: var(--space-6);
  font-style: normal;
}

.cta-p-deep {
  color: var(--color-text-muted);
  font-size: var(--text-lg);
  line-height: 1.7;
  margin-bottom: var(--space-10);
}

.cta-row-deep {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: var(--space-4);
  margin-bottom: var(--space-8);
}

.btn-instagram-deep {
  background: #e4405f;
  color: white;
  box-shadow: 0 4px 14px 0 rgba(228, 64, 95, 0.39);
}

.btn-instagram-deep:hover {
  background: #d62976;
  box-shadow: 0 6px 20px rgba(228, 64, 95, 0.6);
  transform: translateY(-2px);
  color: white;
}

.btn-whatsapp-deep {
  background: #25d366;
  color: white;
  box-shadow: 0 4px 14px 0 rgba(37, 211, 102, 0.39);
}

.btn-whatsapp-deep:hover {
  background: #128c7e;
  box-shadow: 0 6px 20px rgba(37, 211, 102, 0.6);
  transform: translateY(-2px);
  color: white;
}

.cta-note-deep {
  font-family: var(--font-mono);
  font-size: var(--text-xs);
  color: var(--color-text-muted);
  opacity: 0.6;
}

/* --- Footer Refinements --- */
.footer-social-link {
  color: var(--color-text-muted);
  font-size: 20px;
  transition: all var(--transition-bounce);
}

.footer-social-link.linkedin:hover { color: #0077b5; transform: translateY(-3px); }
.footer-social-link.github:hover { color: #ffffff; transform: translateY(-3px); }
.footer-social-link.instagram:hover { color: #e1306c; transform: translateY(-3px); }

.footer-nav-link {
  color: var(--color-text-muted);
  text-decoration: none;
  font-size: var(--text-sm);
  transition: color var(--transition-fast);
}

.footer-nav-link:hover {
  color: var(--color-primary);
}

.p-step-deep p {
  color: var(--color-text-muted);
  font-size: var(--text-sm);
  line-height: 1.7;
}

/* --- Menu Hamburger & Responsividade --- */
.navbar {
  z-index: 201 !important; /* Maior que o overlay (150) */
}

.hamburger-trigger {
  display: none;
  background: none;
  border: none;
  cursor: pointer;
  z-index: 210;
  padding: 10px;
}

@media (max-width: 1024px) {
  .nav-desktop { display: none !important; }
  .hamburger-trigger { display: block; }
}

.hamburger-box { width: 24px; height: 18px; position: relative; display: block; }

.hamburger-inner, 
.hamburger-inner::before, 
.hamburger-inner::after {
  width: 24px; 
  height: 2px; 
  background-color: var(--color-primary);
  position: absolute; 
  transition: all 0.3s ease-in-out;
  display: block;
}

.hamburger-inner { top: 50%; transform: translateY(-50%); }
.hamburger-inner::before { content: ""; top: -8px; left: 0; }
.hamburger-inner::after { content: ""; bottom: -8px; left: 0; }

/* Estado Ativo (X) */
.menu-is-open .hamburger-inner { background-color: transparent !important; }
.menu-is-open .hamburger-inner::before { 
  top: 0; 
  transform: rotate(45deg); 
  background-color: var(--color-primary); 
}
.menu-is-open .hamburger-inner::after { 
  top: 0; 
  transform: rotate(-45deg); 
  background-color: var(--color-primary); 
}

/* Overlay Mobile */
.nav-overlay {
  position: fixed; top: 0; right: 0; width: 100%; height: 100vh;
  background: rgba(11, 17, 32, 0.98); backdrop-filter: blur(15px);
  z-index: 150; transform: translateX(100%);
  transition: transform 0.5s cubic-bezier(0.77,0,0.175,1);
  display: flex; flex-direction: column; justify-content: center;
  align-items: center; padding: var(--space-12);
}

.menu-is-open .nav-overlay { transform: translateX(0); }

.nav-mobile-list {
  list-style: none; padding: 0; margin: 0;
  display: flex; flex-direction: column; gap: var(--space-8);
  text-align: center;
}

.nav-mobile-link {
  font-size: var(--text-xl); font-weight: 700; color: var(--color-text);
  text-decoration: none; transition: color 0.3s;
}
.nav-mobile-link span {
  font-family: var(--font-mono); font-size: 10px;
  color: var(--color-primary); display: block; margin-bottom: 4px;
  text-transform: uppercase; letter-spacing: 0.1em;
}
.nav-mobile-link:hover { color: var(--color-primary); }

.body-lock { overflow: hidden !important; }
