/* ==========================================================================
   MH DEV — WEBSITE PROFISSIONAL / PORTFÓLIO DE MARCOS HENRIQUE
   Full Stack & Backend Developer (PHP, Laravel, WordPress, Vue.js, APIs, n8n)

   --- PLANO DE DESIGN & IDENTIDADE VISUAL ---
   Paleta de Cores (Obsidian Tech & Electric Cyan):
     - --bg-dark:              #090d16 (Obsidian Dark Navy)
     - --bg-surface:           #111827 (Slate 900 Glass Card)
     - --bg-surface-elevated:  #1e293b (Slate 800 Elevado)
     - --accent-cyan:          #00f0ff (Ciano Elétrico)
     - --accent-indigo:        #6366f1 (Índigo para Botões & Highlights)
     - --accent-emerald:       #10b981 (Verde Esmeralda para Status & Checks)
     - --text-main:            #f8fafc (Texto Principal de Alta Legibilidade)
     - --text-muted:           #94a3b8 (Texto Secundário / Descrições)
     - --border-color:         rgba(255, 255, 255, 0.08)

   Tipografia:
     - Headings & UI: 'Plus Jakarta Sans', sans-serif
     - Body text: 'Inter', sans-serif
     - Tech/Code: 'JetBrains Mono', monospace

   Layout:
     - Dark Mode corporativo de alta performance inspirado em IDEs e estúdios SaaS.
     - Header sticky com blur, Hero assimétrico com foto do Marcos Henrique e Terminal Interativo,
       Seção Especial de Terceirização para Agências com Timeline 4-steps e Portfólio de 40 Projetos.

   Elemento-Assinatura:
     1. Interactive Developer Terminal Widget (Hero) com abas em tempo real.
     2. Hub de Portfólio Interativo com 40 Projetos Reais filtráveis e pesquisáveis.

   Autocrítica Anti-Clichês:
     - NÃO usa fundo bege/terracota editorial (Clichê 1).
     - NÃO usa fundo preto puro com neon apelativo sem hierarquia (Clichê 2).
     - NÃO usa layout jornal com bordas secas 0px (Clichê 3).
   ========================================================================== */

/* --------------------------------------------------------------------------
   1. VARIABLES & RESET
   -------------------------------------------------------------------------- */
:root {
  /* Colors */
  --bg-dark: #090d16;
  --bg-surface: #111827;
  --bg-surface-elevated: #1e293b;
  --bg-card: rgba(17, 24, 39, 0.85);
  
  --accent-cyan: #00f0ff;
  --accent-cyan-glow: rgba(0, 240, 255, 0.15);
  --accent-indigo: #6366f1;
  --accent-indigo-hover: #4f46e5;
  --accent-indigo-glow: rgba(99, 102, 241, 0.2);
  --accent-emerald: #10b981;
  --accent-emerald-glow: rgba(16, 185, 129, 0.15);
  
  --text-main: #f8fafc;
  --text-muted: #94a3b8;
  --text-dim: #64748b;
  
  --border-color: rgba(255, 255, 255, 0.08);
  --border-glow: rgba(99, 102, 241, 0.3);

  /* Fonts with Instant System Fallbacks */
  --font-heading: 'Plus Jakarta Sans', system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  --font-body: 'Inter', system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  --font-mono: 'JetBrains Mono', ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;

  /* Layout & Spacing */
  --container-width: 1240px;
  --header-height: 80px;
  --radius-sm: 8px;
  --radius-md: 14px;
  --radius-lg: 20px;

  /* Transitions */
  --transition-fast: 0.2s cubic-bezier(0.4, 0, 0.2, 1);
  --transition-normal: 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

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

html {
  scroll-behavior: smooth;
  font-size: 16px;
  background-color: var(--bg-dark);
  color: var(--text-main);
  font-family: var(--font-body);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

body {
  overflow-x: hidden;
  line-height: 1.6;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

/* Typography Defaults */
h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-heading);
  color: var(--text-main);
  line-height: 1.2;
  font-weight: 700;
}

a {
  color: inherit;
  text-decoration: none;
  transition: color var(--transition-fast);
}

ul {
  list-style: none;
}

img {
  max-width: 100%;
  height: auto;
  display: block;
}

button, input, select, textarea {
  font-family: inherit;
  font-size: inherit;
  color: inherit;
}

/* Accessibility Focus States */
:focus-visible {
  outline: 2px solid var(--accent-cyan);
  outline-offset: 3px;
}

/* --------------------------------------------------------------------------
   2. REUSABLE UTILITIES & LAYOUT CONTAINERS
   -------------------------------------------------------------------------- */
.container {
  width: 100%;
  max-width: var(--container-width);
  margin: 0 auto;
  padding: 0 1.5rem;
}

.section {
  padding: 6rem 0;
  position: relative;
}

.section-header {
  margin-bottom: 3.5rem;
}

.section-subtitle {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  font-family: var(--font-mono);
  font-size: 0.875rem;
  font-weight: 600;
  color: var(--accent-cyan);
  text-transform: uppercase;
  letter-spacing: 0.1em;
  margin-bottom: 0.75rem;
}

.section-title {
  font-size: clamp(2rem, 3.5vw, 2.75rem);
  font-weight: 800;
  letter-spacing: -0.02em;
}

.section-desc {
  font-size: 1.125rem;
  color: var(--text-muted);
  max-width: 650px;
  margin: 0.75rem auto 0;
}

.section-line {
  width: 60px;
  height: 4px;
  background: linear-gradient(90deg, var(--accent-cyan), var(--accent-indigo));
  border-radius: 2px;
  margin: 1.25rem auto 0;
}

.text-center { text-align: center; }
.text-gradient {
  background: linear-gradient(135deg, #ffffff 0%, var(--accent-cyan) 50%, var(--accent-indigo) 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

/* Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.625rem;
  font-family: var(--font-heading);
  font-weight: 600;
  border-radius: var(--radius-sm);
  padding: 0.875rem 1.75rem;
  font-size: 1rem;
  cursor: pointer;
  border: 1px solid transparent;
  transition: all var(--transition-fast);
}

.btn-sm {
  padding: 0.5rem 1.125rem;
  font-size: 0.875rem;
}

.btn-lg {
  padding: 1.125rem 2.25rem;
  font-size: 1.05rem;
  border-radius: var(--radius-md);
}

.btn-primary {
  background: linear-gradient(135deg, var(--accent-indigo) 0%, #4338ca 100%);
  color: #ffffff;
  box-shadow: 0 4px 20px var(--accent-indigo-glow);
}

.btn-primary:hover {
  background: linear-gradient(135deg, var(--accent-indigo-hover) 0%, #3730a3 100%);
  transform: translateY(-2px);
  box-shadow: 0 8px 25px rgba(99, 102, 241, 0.35);
}

.btn-outline {
  background: rgba(255, 255, 255, 0.03);
  border-color: var(--border-color);
  color: var(--text-main);
}

.btn-outline:hover {
  background: rgba(255, 255, 255, 0.08);
  border-color: var(--accent-cyan);
  color: var(--accent-cyan);
  transform: translateY(-2px);
}

.btn-whatsapp {
  background: #25d366;
  color: #ffffff;
  font-weight: 700;
}

.btn-whatsapp:hover {
  background: #1eb956;
  box-shadow: 0 6px 20px rgba(37, 211, 102, 0.3);
}

.w-full { width: 100%; }

/* --------------------------------------------------------------------------
   3. TOP ANNOUNCEMENT BAR & MAIN HEADER
   -------------------------------------------------------------------------- */
.top-bar {
  background: rgba(17, 24, 39, 0.95);
  border-bottom: 1px solid var(--border-color);
  font-size: 0.8125rem;
  padding: 0.4rem 0;
  color: var(--text-muted);
}

.top-bar-content {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 0.75rem;
}

.status-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  font-weight: 500;
  color: var(--text-main);
}

.status-dot {
  width: 8px;
  height: 8px;
  background-color: var(--accent-emerald);
  border-radius: 50%;
  box-shadow: 0 0 10px var(--accent-emerald);
  animation: pulse-dot 2s infinite;
}

@keyframes pulse-dot {
  0% { transform: scale(0.95); opacity: 1; }
  50% { transform: scale(1.3); opacity: 0.5; }
  100% { transform: scale(0.95); opacity: 1; }
}

.top-bar-contact {
  display: flex;
  align-items: center;
  gap: 1.25rem;
}

.top-bar-contact a {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  color: var(--text-muted);
}

.top-bar-contact a:hover {
  color: var(--accent-cyan);
}

.top-bar-contact i {
  width: 14px;
  height: 14px;
}

/* Main Header */
.main-header {
  position: sticky;
  top: 0;
  z-index: 1000;
  background: rgba(9, 13, 22, 0.85);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--border-color);
  transition: box-shadow var(--transition-normal), background var(--transition-normal);
}

.main-header.header-scrolled {
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.4);
}

.header-container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: var(--header-height);
}

/* Logo */
.brand-logo {
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.logo-icon {
  width: 42px;
  height: 42px;
  background: linear-gradient(135deg, var(--bg-surface-elevated), var(--bg-surface));
  border: 1px solid var(--border-glow);
  border-radius: var(--radius-sm);
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: var(--font-mono);
  font-weight: 700;
  color: var(--accent-cyan);
  box-shadow: 0 4px 15px rgba(0, 240, 255, 0.1);
}

.logo-text {
  display: flex;
  flex-direction: column;
}

.brand-name {
  font-family: var(--font-heading);
  font-weight: 800;
  font-size: 1.2rem;
  color: var(--text-main);
  letter-spacing: -0.01em;
}

.brand-sub {
  font-size: 0.75rem;
  color: var(--text-muted);
  font-weight: 500;
}

/* Navigation Links */
.desktop-nav ul {
  display: flex;
  align-items: center;
  gap: 1.75rem;
}

.nav-link {
  font-size: 0.9375rem;
  font-weight: 500;
  color: var(--text-muted);
  position: relative;
  padding: 0.5rem 0;
}

.nav-link:hover {
  color: var(--text-main);
}

.nav-link::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  width: 100%;
  height: 2px;
  background: var(--accent-cyan);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform var(--transition-fast);
}

.nav-link:hover::after {
  transform: scaleX(1);
}

.highlight-link {
  color: var(--accent-cyan);
  font-weight: 600;
}

.header-action {
  display: flex;
  align-items: center;
  gap: 1rem;
}

.mobile-toggle {
  display: none;
  background: transparent;
  border: 1px solid var(--border-color);
  color: var(--text-main);
  width: 42px;
  height: 42px;
  border-radius: var(--radius-sm);
  cursor: pointer;
  align-items: center;
  justify-content: center;
}

.mobile-toggle:hover {
  border-color: var(--accent-cyan);
  color: var(--accent-cyan);
}

/* Mobile Nav Drawer */
.mobile-nav {
  display: none;
  position: absolute;
  top: 100%;
  left: 0;
  width: 100%;
  background: var(--bg-surface);
  border-bottom: 1px solid var(--border-color);
  padding: 1.5rem;
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.5);
  flex-direction: column;
  gap: 1.5rem;
}

.mobile-nav.open {
  display: flex;
}

.mobile-nav ul {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.mobile-link {
  font-size: 1.05rem;
  font-weight: 600;
  color: var(--text-main);
  display: block;
  padding: 0.5rem 0;
  border-bottom: 1px solid rgba(255, 255, 255, 0.04);
}

/* --------------------------------------------------------------------------
   4. HERO SECTION
   -------------------------------------------------------------------------- */
.hero-section {
  position: relative;
  padding: 5rem 0 6rem;
  overflow: hidden;
  max-width: 100vw;
}

.hero-bg-grid {
  position: absolute;
  inset: 0;
  background-image: 
    linear-gradient(to right, rgba(255, 255, 255, 0.03) 1px, transparent 1px),
    linear-gradient(to bottom, rgba(255, 255, 255, 0.03) 1px, transparent 1px);
  background-size: 40px 40px;
  mask-image: radial-gradient(circle at 50% 30%, black 0%, transparent 75%);
  pointer-events: none;
}

.hero-glow-1 {
  position: absolute;
  top: -100px;
  left: 10%;
  width: 450px;
  height: 450px;
  background: radial-gradient(circle, rgba(99, 102, 241, 0.18) 0%, transparent 70%);
  filter: blur(80px);
  pointer-events: none;
}

.hero-glow-2 {
  position: absolute;
  bottom: 0;
  right: 10%;
  width: 500px;
  height: 500px;
  background: radial-gradient(circle, rgba(0, 240, 255, 0.12) 0%, transparent 70%);
  filter: blur(90px);
  pointer-events: none;
}

.hero-container {
  display: grid;
  grid-template-columns: 1.15fr 0.85fr;
  gap: 3.5rem;
  align-items: center;
  position: relative;
  z-index: 2;
  min-width: 0;
}

.hero-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  background: rgba(0, 240, 255, 0.08);
  border: 1px solid rgba(0, 240, 255, 0.25);
  border-radius: 50px;
  padding: 0.4rem 1rem;
  font-family: var(--font-mono);
  font-size: 0.8125rem;
  color: var(--accent-cyan);
  margin-bottom: 1.5rem;
}

.hero-title {
  font-size: clamp(2.2rem, 3.8vw, 3.25rem);
  font-weight: 800;
  letter-spacing: -0.02em;
  line-height: 1.15;
  margin-bottom: 1.5rem;
}

.hero-subtitle {
  font-size: 1.125rem;
  color: var(--text-muted);
  line-height: 1.7;
  margin-bottom: 2.25rem;
  max-width: 100%;
  word-wrap: break-word;
  overflow-wrap: break-word;
}

.hero-subtitle strong {
  color: var(--text-main);
}

.hero-actions {
  display: flex;
  align-items: center;
  gap: 1.25rem;
  flex-wrap: wrap;
  margin-bottom: 2.5rem;
}

.hero-meta {
  display: flex;
  align-items: center;
  gap: 1.75rem;
  flex-wrap: wrap;
  padding-top: 1.5rem;
  border-top: 1px solid var(--border-color);
}

.meta-item {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.875rem;
  color: var(--text-muted);
}

.meta-item i {
  color: var(--accent-cyan);
  width: 18px;
  height: 18px;
}

/* Hero Visual: Profile Card & Terminal Widget */
.hero-visual {
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
}

/* Profile Card */
.profile-card {
  background: var(--bg-card);
  border: 1px solid var(--border-glow);
  border-radius: var(--radius-md);
  padding: 1.25rem 1.5rem;
  display: flex;
  align-items: center;
  gap: 1.25rem;
  backdrop-filter: blur(12px);
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.4);
}

.profile-avatar-wrapper {
  position: relative;
  width: 72px;
  height: 72px;
  flex-shrink: 0;
}

.profile-avatar {
  width: 100%;
  height: 100%;
  border-radius: 50%;
  object-fit: cover;
  border: 2px solid var(--accent-indigo);
}

.avatar-ring {
  position: absolute;
  inset: -4px;
  border: 2px dashed var(--accent-cyan);
  border-radius: 50%;
  animation: spin-ring 25s linear infinite;
  pointer-events: none;
}

@keyframes spin-ring {
  0% { transform: rotate(0deg); }
  100% { transform: rotate(360deg); }
}

.profile-info {
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
}

.profile-name {
  font-size: 1.15rem;
  font-weight: 700;
  color: var(--text-main);
}

.profile-title {
  font-size: 0.85rem;
  color: var(--accent-cyan);
  font-family: var(--font-mono);
}

.profile-tags {
  display: flex;
  gap: 0.4rem;
  margin-top: 0.4rem;
  flex-wrap: wrap;
}

.profile-tags .tag {
  background: rgba(255, 255, 255, 0.06);
  border-radius: 4px;
  padding: 0.15rem 0.5rem;
  font-size: 0.725rem;
  color: var(--text-muted);
  font-family: var(--font-mono);
}

/* Terminal Widget (Signature Element) */
.terminal-widget {
  background: #0d1117;
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: var(--radius-md);
  overflow: hidden;
  box-shadow: 0 20px 50px rgba(0, 0, 0, 0.6);
  font-family: var(--font-mono);
}

.terminal-header {
  background: #161b22;
  padding: 0.75rem 1rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
  gap: 1rem;
  overflow-x: auto;
}

.terminal-controls {
  display: flex;
  gap: 0.4rem;
  flex-shrink: 0;
}

.dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
}
.dot.red { background-color: #ff5f56; }
.dot.yellow { background-color: #ffbd2e; }
.dot.green { background-color: #27c93f; }

.terminal-tabs {
  display: flex;
  gap: 0.5rem;
  flex-wrap: nowrap;
}

.terminal-tab {
  background: transparent;
  border: none;
  color: #8b949e;
  font-size: 0.775rem;
  padding: 0.3rem 0.75rem;
  border-radius: 6px;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  transition: all var(--transition-fast);
  white-space: nowrap;
}

.terminal-tab i {
  width: 13px;
  height: 13px;
}

.terminal-tab:hover {
  color: #c9d1d9;
  background: rgba(255, 255, 255, 0.05);
}

.terminal-tab.active {
  background: #0d1117;
  color: var(--accent-cyan);
  border: 1px solid rgba(0, 240, 255, 0.3);
}

.terminal-body {
  padding: 1.25rem;
  max-height: 240px;
  overflow-y: auto;
  font-size: 0.8125rem;
  line-height: 1.6;
}

.terminal-code {
  display: none;
  white-space: pre-wrap;
  word-break: break-all;
}

.terminal-code.active {
  display: block;
}

/* Syntax Highlighting */
.token-keyword { color: #ff7b72; font-weight: 600; }
.token-class { color: #79c0ff; font-weight: 600; }
.token-function { color: #d2a8ff; }
.token-string { color: #a5d6ff; }
.token-comment { color: #8b949e; font-style: italic; }
.token-type { color: #ffa657; }

.terminal-footer {
  background: #161b22;
  padding: 0.5rem 1rem;
  border-top: 1px solid rgba(255, 255, 255, 0.08);
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 0.75rem;
  color: #8b949e;
}

.terminal-status {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
}

.icon-green { color: var(--accent-emerald); width: 14px; height: 14px; }
.terminal-action { display: inline-flex; align-items: center; gap: 0.3rem; }
.terminal-action i { width: 12px; height: 12px; }

/* --------------------------------------------------------------------------
   5. SOBRE MIM SECTION
   -------------------------------------------------------------------------- */
.about-grid {
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  gap: 3.5rem;
  align-items: center;
}

.about-text-col p {
  color: var(--text-muted);
  font-size: 1.05rem;
  line-height: 1.75;
  margin-bottom: 1.25rem;
}

.about-text-col p.lead-text {
  color: var(--text-main);
  font-size: 1.15rem;
}

.about-text-col strong {
  color: var(--text-main);
}

.education-badge {
  display: flex;
  align-items: center;
  gap: 1rem;
  background: var(--bg-surface);
  border: 1px solid var(--border-glow);
  border-radius: var(--radius-sm);
  padding: 1rem 1.25rem;
  margin-top: 1.75rem;
}

.education-badge i {
  color: var(--accent-cyan);
  width: 28px;
  height: 28px;
  flex-shrink: 0;
}

.education-badge div {
  display: flex;
  flex-direction: column;
  font-size: 0.9rem;
}

.education-badge strong {
  color: var(--text-main);
}

.education-badge span {
  color: var(--text-muted);
}

/* Stats Cards */
.about-stats-col {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1.25rem;
}

.stat-card {
  background: var(--bg-surface);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  padding: 1.75rem 1.5rem;
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
  transition: all var(--transition-normal);
}

.stat-card:hover {
  transform: translateY(-4px);
  border-color: var(--accent-indigo);
  box-shadow: 0 10px 30px var(--accent-indigo-glow);
}

.stat-icon i {
  color: var(--accent-cyan);
  width: 26px;
  height: 26px;
}

.stat-number {
  font-family: var(--font-heading);
  font-size: 1.85rem;
  font-weight: 800;
  color: var(--text-main);
  background: linear-gradient(135deg, #ffffff 0%, var(--accent-cyan) 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

.stat-label {
  font-size: 0.85rem;
  color: var(--text-muted);
  line-height: 1.4;
}

/* --------------------------------------------------------------------------
   6. STACK TÉCNICA SECTION
   -------------------------------------------------------------------------- */
.stack-section {
  background: rgba(17, 24, 39, 0.4);
  border-top: 1px solid var(--border-color);
  border-bottom: 1px solid var(--border-color);
}

.stack-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 1.75rem;
  margin-bottom: 3rem;
}

.stack-card {
  background: var(--bg-surface);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  padding: 2rem 1.75rem;
  transition: all var(--transition-normal);
  display: flex;
  flex-direction: column;
}

.stack-card:hover {
  border-color: var(--accent-cyan);
  transform: translateY(-4px);
  box-shadow: 0 12px 35px rgba(0, 240, 255, 0.1);
}

.stack-card-icon {
  width: 48px;
  height: 48px;
  background: rgba(99, 102, 241, 0.1);
  border-radius: var(--radius-sm);
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 1.25rem;
}

.stack-card-icon i {
  color: var(--accent-indigo);
  width: 24px;
  height: 24px;
}

.stack-card h3 {
  font-size: 1.25rem;
  margin-bottom: 1.25rem;
  color: var(--text-main);
}

.stack-list {
  display: flex;
  flex-direction: column;
  gap: 0.85rem;
  font-size: 0.925rem;
  color: var(--text-muted);
}

.stack-list strong {
  color: var(--text-main);
}

/* Stack Pills Box */
.stack-pills-box {
  background: var(--bg-surface);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  padding: 1.5rem 2rem;
  display: flex;
  align-items: center;
  gap: 1.5rem;
  flex-wrap: wrap;
}

.pills-title {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  font-family: var(--font-mono);
  font-size: 0.9rem;
  color: var(--accent-cyan);
  white-space: nowrap;
}

.pills-title i { width: 18px; height: 18px; }

.pills-wrapper {
  display: flex;
  flex-wrap: wrap;
  gap: 0.6rem;
}

.tech-pill {
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid var(--border-color);
  border-radius: 50px;
  padding: 0.35rem 0.875rem;
  font-family: var(--font-mono);
  font-size: 0.8125rem;
  color: var(--text-main);
  transition: all var(--transition-fast);
}

.tech-pill:hover {
  background: rgba(0, 240, 255, 0.1);
  border-color: var(--accent-cyan);
  color: var(--accent-cyan);
}

/* --------------------------------------------------------------------------
   7. SERVIÇOS SECTION
   -------------------------------------------------------------------------- */
.services-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 1.75rem;
}

.service-card {
  background: var(--bg-surface);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  padding: 2.25rem;
  position: relative;
  overflow: hidden;
  transition: all var(--transition-normal);
  display: flex;
  flex-direction: column;
}

.service-card:hover {
  border-color: var(--accent-indigo);
  transform: translateY(-4px);
  box-shadow: 0 15px 40px rgba(0, 0, 0, 0.5);
}

.service-number {
  position: absolute;
  top: 1.5rem;
  right: 1.75rem;
  font-family: var(--font-mono);
  font-size: 2.5rem;
  font-weight: 800;
  color: rgba(255, 255, 255, 0.04);
}

.service-icon {
  width: 52px;
  height: 52px;
  background: rgba(0, 240, 255, 0.08);
  border: 1px solid rgba(0, 240, 255, 0.2);
  border-radius: var(--radius-sm);
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 1.5rem;
}

.service-icon i {
  color: var(--accent-cyan);
  width: 26px;
  height: 26px;
}

.service-card h3 {
  font-size: 1.35rem;
  margin-bottom: 1rem;
  line-height: 1.3;
}

.service-card p {
  color: var(--text-muted);
  font-size: 0.975rem;
  line-height: 1.65;
  margin-bottom: 1.75rem;
  flex-grow: 1;
}

.service-card strong {
  color: var(--text-main);
}

.service-link {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--accent-cyan);
}

.service-link i {
  width: 16px;
  height: 16px;
  transition: transform var(--transition-fast);
}

.service-card:hover .service-link i {
  transform: translateX(4px);
}

.service-card-wide {
  grid-column: span 2;
  background: linear-gradient(135deg, var(--bg-surface) 0%, rgba(30, 41, 59, 0.6) 100%);
  border: 1px solid rgba(99, 102, 241, 0.3);
}

/* --------------------------------------------------------------------------
   8. TERCEIRIZAÇÃO / OUTSOURCING SECTION (DESTAQUE VISUAL ÚNICO)
   -------------------------------------------------------------------------- */
.outsourcing-section {
  position: relative;
  padding: 6rem 0;
}

.outsourcing-glow {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 900px;
  height: 500px;
  background: radial-gradient(circle, rgba(99, 102, 241, 0.15) 0%, transparent 70%);
  filter: blur(100px);
  pointer-events: none;
}

.outsourcing-box {
  background: linear-gradient(135deg, rgba(17, 24, 39, 0.95) 0%, rgba(30, 41, 59, 0.85) 100%);
  border: 1px solid var(--border-glow);
  border-radius: var(--radius-lg);
  padding: 4rem 3.5rem;
  position: relative;
  z-index: 2;
  box-shadow: 0 25px 60px rgba(0, 0, 0, 0.5);
  backdrop-filter: blur(16px);
}

.outsourcing-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  background: linear-gradient(90deg, rgba(99, 102, 241, 0.2), rgba(0, 240, 255, 0.2));
  border: 1px solid var(--accent-indigo);
  border-radius: 50px;
  padding: 0.4rem 1.125rem;
  font-family: var(--font-mono);
  font-size: 0.85rem;
  color: var(--accent-cyan);
  margin-bottom: 1.5rem;
}

.outsourcing-badge i { width: 16px; height: 16px; }

.outsourcing-title {
  font-size: clamp(1.85rem, 3.2vw, 2.5rem);
  font-weight: 800;
  line-height: 1.25;
  margin-bottom: 1.25rem;
}

.highlight-text {
  color: var(--accent-cyan);
}

.outsourcing-subtitle {
  font-size: 1.1rem;
  color: var(--text-muted);
  margin-bottom: 3rem;
  max-width: 800px;
}

/* 3 Pillars Grid */
.outsourcing-pillars {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.75rem;
  margin-bottom: 3.5rem;
}

.pillar-card {
  background: rgba(13, 17, 23, 0.7);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  padding: 2rem 1.5rem;
  transition: all var(--transition-normal);
}

.pillar-card:hover {
  border-color: var(--accent-cyan);
  transform: translateY(-3px);
}

.pillar-icon {
  width: 44px;
  height: 44px;
  background: rgba(0, 240, 255, 0.1);
  border-radius: var(--radius-sm);
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 1.25rem;
}

.pillar-icon i {
  color: var(--accent-cyan);
  width: 22px;
  height: 22px;
}

.pillar-card h3 {
  font-size: 1.2rem;
  margin-bottom: 0.75rem;
}

.pillar-card p {
  color: var(--text-muted);
  font-size: 0.9rem;
  line-height: 1.6;
}

/* Workflow Timeline */
.workflow-wrapper {
  margin-bottom: 3rem;
  padding-top: 2rem;
  border-top: 1px solid var(--border-color);
}

.workflow-title {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 1.25rem;
  color: var(--text-main);
  margin-bottom: 2rem;
}

.workflow-title i { color: var(--accent-cyan); }

.timeline-steps {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1.25rem;
  position: relative;
}

.step-card {
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  padding: 1.5rem 1.25rem;
  position: relative;
}

.step-num {
  width: 32px;
  height: 32px;
  background: var(--accent-indigo);
  color: #ffffff;
  font-family: var(--font-mono);
  font-weight: 700;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 1rem;
  box-shadow: 0 0 15px var(--accent-indigo-glow);
}

.step-card h4 {
  font-size: 1rem;
  margin-bottom: 0.5rem;
}

.step-card p {
  font-size: 0.85rem;
  color: var(--text-muted);
  line-height: 1.5;
}

/* Ideal For Box */
.ideal-for-box {
  background: rgba(255, 255, 255, 0.02);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  padding: 1.5rem 1.75rem;
  margin-bottom: 2rem;
}

.ideal-for-box h4 {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 1.05rem;
  margin-bottom: 1rem;
  color: var(--text-main);
}

.ideal-for-box h4 i { color: var(--accent-emerald); }

.ideal-tags {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 0.75rem;
}

.ideal-tags span {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.9rem;
  color: var(--text-muted);
}

.ideal-tags i {
  color: var(--accent-emerald);
  width: 16px;
  height: 16px;
  flex-shrink: 0;
}

/* Contract Note */
.contract-note {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  background: rgba(16, 185, 129, 0.08);
  border: 1px solid rgba(16, 185, 129, 0.25);
  border-radius: var(--radius-sm);
  padding: 1rem 1.25rem;
  font-size: 0.9rem;
  color: var(--text-main);
  margin-bottom: 2.5rem;
}

.contract-note i {
  color: var(--accent-emerald);
  width: 22px;
  height: 22px;
  flex-shrink: 0;
}

.outsourcing-cta {
  text-align: center;
}

/* --------------------------------------------------------------------------
   9. POR QUE TRABALHAR COMIGO (DIFERENCIAIS)
   -------------------------------------------------------------------------- */
.why-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.75rem;
}

.why-card {
  background: var(--bg-surface);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  padding: 2rem 1.75rem;
  transition: all var(--transition-normal);
}

.why-card:hover {
  border-color: var(--accent-emerald);
  transform: translateY(-4px);
  box-shadow: 0 10px 30px rgba(16, 185, 129, 0.1);
}

.why-icon i {
  color: var(--accent-emerald);
  width: 32px;
  height: 32px;
  margin-bottom: 1.25rem;
}

.why-card h3 {
  font-size: 1.2rem;
  margin-bottom: 0.75rem;
}

.why-card p {
  color: var(--text-muted);
  font-size: 0.925rem;
  line-height: 1.6;
}

/* --------------------------------------------------------------------------
   10. PORTFÓLIO SECTION (40 PROJETOS REAIS FILTRÁVEIS)
   -------------------------------------------------------------------------- */
.portfolio-controls {
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
  margin-bottom: 3rem;
  align-items: center;
}

.portfolio-filters {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 0.6rem;
}

.filter-btn {
  background: var(--bg-surface);
  border: 1px solid var(--border-color);
  border-radius: 50px;
  padding: 0.6rem 1.25rem;
  font-size: 0.875rem;
  font-weight: 500;
  color: var(--text-muted);
  cursor: pointer;
  transition: all var(--transition-fast);
}

.filter-btn:hover {
  border-color: var(--accent-cyan);
  color: var(--text-main);
}

.filter-btn.active {
  background: var(--accent-indigo);
  border-color: var(--accent-indigo);
  color: #ffffff;
  font-weight: 600;
  box-shadow: 0 4px 15px var(--accent-indigo-glow);
}

.portfolio-search-box {
  position: relative;
  width: 100%;
  max-width: 450px;
}

.portfolio-search-box i {
  position: absolute;
  left: 1.25rem;
  top: 50%;
  transform: translateY(-50%);
  color: var(--text-muted);
  width: 18px;
  height: 18px;
}

.portfolio-search-box input {
  width: 100%;
  background: var(--bg-surface);
  border: 1px solid var(--border-color);
  border-radius: 50px;
  padding: 0.75rem 1.25rem 0.75rem 3rem;
  font-size: 0.9rem;
  color: var(--text-main);
  transition: all var(--transition-fast);
}

.portfolio-search-box input:focus {
  outline: none;
  border-color: var(--accent-cyan);
  box-shadow: 0 0 20px rgba(0, 240, 255, 0.15);
}

/* Portfolio Grid Cards */
.portfolio-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 1.75rem;
}

.project-card {
  background: var(--bg-surface);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  overflow: hidden;
  display: flex;
  flex-direction: column;
  transition: all var(--transition-normal);
}

.project-card:hover {
  border-color: var(--accent-cyan);
  transform: translateY(-5px);
  box-shadow: 0 15px 35px rgba(0, 0, 0, 0.5);
}

.project-header {
  background: #161b22;
  padding: 1.25rem 1.5rem;
  border-bottom: 1px solid var(--border-color);
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.project-domain {
  font-family: var(--font-mono);
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--text-main);
  word-break: break-all;
}

.project-badge {
  background: rgba(0, 240, 255, 0.1);
  border: 1px solid rgba(0, 240, 255, 0.2);
  border-radius: 4px;
  padding: 0.15rem 0.5rem;
  font-size: 0.7rem;
  font-family: var(--font-mono);
  color: var(--accent-cyan);
  white-space: nowrap;
}

.project-body {
  padding: 1.5rem;
  display: flex;
  flex-direction: column;
  gap: 1rem;
  flex-grow: 1;
}

.project-niche {
  font-size: 0.925rem;
  color: var(--text-muted);
  line-height: 1.5;
}

.project-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
  margin-top: auto;
}

.project-tag {
  background: rgba(255, 255, 255, 0.05);
  border-radius: 4px;
  padding: 0.15rem 0.5rem;
  font-size: 0.725rem;
  color: var(--text-muted);
  font-family: var(--font-mono);
}

.project-footer {
  padding: 1rem 1.5rem;
  background: rgba(0, 0, 0, 0.2);
  border-top: 1px solid var(--border-color);
}

.project-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  width: 100%;
  padding: 0.6rem;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-sm);
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--text-main);
  transition: all var(--transition-fast);
}

.project-btn:hover {
  background: var(--accent-indigo);
  border-color: var(--accent-indigo);
  color: #ffffff;
}

.project-btn i { width: 14px; height: 14px; }

/* --------------------------------------------------------------------------
   11. CONTATO SECTION
   -------------------------------------------------------------------------- */
.contact-wrapper {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 3.5rem;
  align-items: start;
}

.contact-title {
  font-size: clamp(1.8rem, 3vw, 2.3rem);
  font-weight: 800;
  line-height: 1.25;
  margin-bottom: 1.25rem;
}

.contact-text {
  font-size: 1.05rem;
  color: var(--text-muted);
  margin-bottom: 2.25rem;
  line-height: 1.7;
}

.contact-cards {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.contact-card {
  background: var(--bg-surface);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  padding: 1.25rem 1.5rem;
  display: flex;
  align-items: center;
  gap: 1.25rem;
  transition: all var(--transition-fast);

}

.contact-card:hover {
  border-color: var(--accent-cyan);
  transform: translateX(4px);
}

.contact-card-icon {
  width: 44px;
  height: 44px;
  border-radius: var(--radius-sm);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.card-wa .contact-card-icon { background: rgba(37, 211, 102, 0.1); color: #25d366; }
.card-email .contact-card-icon { background: rgba(0, 240, 255, 0.1); color: var(--accent-cyan); }
.card-linkedin .contact-card-icon { background: rgba(10, 102, 194, 0.15); color: #0a66c2; }
.card-loc .contact-card-icon { background: rgba(99, 102, 241, 0.1); color: var(--accent-indigo); }

.contact-card-icon i { width: 22px; height: 22px; }

.contact-card div {
  display: flex;
  flex-direction: column;
  flex-grow: 1;
}

.contact-card-label {
  font-size: 0.785rem;
  color: var(--text-muted);
}

.contact-card-val {
  font-size: 1.025rem;
  color: var(--text-main);
}

.card-arrow {
  color: var(--text-muted);
  width: 18px;
  height: 18px;
  transition: transform var(--transition-fast);
}

.contact-card:hover .card-arrow {
  color: var(--accent-cyan);
  transform: translateX(4px);
}

/* Contact Form */
.contact-form {
  background: var(--bg-surface);
  border: 1px solid var(--border-glow);
  border-radius: var(--radius-lg);
  padding: 2.5rem;
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.4);
}

.form-title {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  font-size: 1.35rem;
  margin-bottom: 1.75rem;
  padding-bottom: 1rem;
  border-bottom: 1px solid var(--border-color);
}

.form-title i { color: var(--accent-cyan); }

.form-group {
  margin-bottom: 1.25rem;
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
}

.form-group label {
  font-size: 0.875rem;
  font-weight: 600;
  color: var(--text-main);
}

.form-group input,
.form-group select,
.form-group textarea {
  width: 100%;
  background: rgba(13, 17, 23, 0.8);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-sm);
  padding: 0.85rem 1rem;
  font-size: 0.95rem;
  color: var(--text-main);
  transition: all var(--transition-fast);
}

.form-group select {
  cursor: pointer;
}

.form-group select option {
  background: var(--bg-surface);
  color: var(--text-main);
}

.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
  outline: none;
  border-color: var(--accent-cyan);
  box-shadow: 0 0 15px rgba(0, 240, 255, 0.15);
}

.error-msg {
  display: none;
  font-size: 0.785rem;
  color: #ff5f56;
}

.form-group.invalid input,
.form-group.invalid select,
.form-group.invalid textarea {
  border-color: #ff5f56;
}

.form-group.invalid .error-msg {
  display: block;
}

.btn-block { width: 100%; }

.form-footnote {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.4rem;
  font-size: 0.8rem;
  color: var(--text-muted);
  margin-top: 1rem;
}

.form-footnote i { width: 14px; height: 14px; }

/* --------------------------------------------------------------------------
   12. FOOTER & FLOATING WHATSAPP
   -------------------------------------------------------------------------- */
.main-footer {
  background: #060910;
  border-top: 1px solid var(--border-color);
  padding-top: 4rem;
  margin-top: auto;
}

.footer-container {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr;
  gap: 3rem;
  padding-bottom: 3.5rem;
}

.footer-brand {
  display: flex;
  flex-direction: column;
  gap: 1rem;
  max-width: 400px;
}

.footer-desc {
  font-size: 0.9rem;
  color: var(--text-muted);
  line-height: 1.6;
}

.footer-links h4,
.footer-contact h4 {
  font-size: 1.05rem;
  margin-bottom: 1.25rem;
  color: var(--text-main);
}

.footer-links ul {
  display: flex;
  flex-direction: column;
  gap: 0.6rem;
}

.footer-links a {
  font-size: 0.9rem;
  color: var(--text-muted);
}

.footer-links a:hover {
  color: var(--accent-cyan);
}

.footer-contact p {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.9rem;
  color: var(--text-muted);
  margin-bottom: 0.75rem;
}

.footer-contact i {
  color: var(--accent-cyan);
  width: 16px;
  height: 16px;
}

.footer-bottom {
  background: rgba(0, 0, 0, 0.4);
  border-top: 1px solid rgba(255, 255, 255, 0.05);
  padding: 1.25rem 0;
  font-size: 0.8125rem;
  color: var(--text-muted);
}

.footer-bottom-content {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 1rem;
}

.footer-credits {
  font-family: var(--font-mono);
  color: var(--text-dim);
}

/* Floating WhatsApp Button */
.whatsapp-float {
  position: fixed;
  bottom: 2rem;
  right: 2rem;
  width: 60px;
  height: 60px;
  background: #25d366;
  color: #ffffff;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 8px 25px rgba(37, 211, 102, 0.4);
  z-index: 999;
  transition: all var(--transition-fast);
  animation: pulse-wa 2.5s infinite;
}

.whatsapp-float i {
  width: 32px;
  height: 32px;
}

.whatsapp-float:hover {
  transform: scale(1.1);
  box-shadow: 0 12px 30px rgba(37, 211, 102, 0.6);
}

.whatsapp-tooltip {
  position: absolute;
  right: 70px;
  background: var(--bg-surface);
  border: 1px solid var(--border-color);
  color: var(--text-main);
  padding: 0.5rem 0.875rem;
  border-radius: var(--radius-sm);
  font-size: 0.8rem;
  font-weight: 600;
  white-space: nowrap;
  opacity: 0;
  pointer-events: none;
  transition: opacity var(--transition-fast);
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.3);
}

.whatsapp-float:hover .whatsapp-tooltip {
  opacity: 1;
}

@keyframes pulse-wa {
  0% { transform: scale(1); }
  50% { transform: scale(1.08); }
  100% { transform: scale(1); }
}

/* --------------------------------------------------------------------------
   13. ANIMATIONS & REVEAL EFFECTS
   -------------------------------------------------------------------------- */
.fade-in {
  opacity: 0;
  transform: translateY(20px);
  transition: opacity 0.6s ease-out, transform 0.6s ease-out;
}

.fade-in.visible {
  opacity: 1;
  transform: translateY(0);
}

@media (prefers-reduced-motion: reduce) {
  .fade-in {
    opacity: 1;
    transform: none;
    transition: none;
  }
  .avatar-ring, .status-dot, .whatsapp-float {
    animation: none;
  }
}

/* --------------------------------------------------------------------------
   14. RESPONSIVE BREAKPOINTS
   -------------------------------------------------------------------------- */
@media (max-width: 1024px) {
  .hero-container {
    grid-template-columns: 1fr;
    gap: 3rem;
  }
  .about-grid, .contact-wrapper {
    grid-template-columns: 1fr;
  }
  .outsourcing-pillars {
    grid-template-columns: 1fr;
  }
  .timeline-steps {
    grid-template-columns: repeat(2, 1fr);
  }
  .why-grid {
    grid-template-columns: repeat(2, 1fr);
  }
  .footer-container {
    grid-template-columns: 1fr;
    gap: 2rem;
  }
}



/* ── 768px — Tablet/Mobile Portrait ────────────────────────────────────────── */
@media (max-width: 768px) {
  /* Header: hide desktop nav, show hamburger; hide CTA button */
  .desktop-nav { display: none; }
  .mobile-toggle { display: flex; }
  .header-cta { display: none; }           /* hide 'Solicitar Orçamento' in header */
  .header-action { gap: 0.5rem; }
  .top-bar-content { justify-content: center; }
  .brand-sub { display: none; }             /* hide 'Marcos Henrique' sub-label to save space */

  /* Hero: single-column, hide visual column (photo+terminal) */
  .hero-section { padding: 3.5rem 0 4rem; }
  .hero-container {
    grid-template-columns: 1fr;
    gap: 2.5rem;
  }
  .hero-visual { display: none; }           /* hide photo card and terminal on mobile */
  .hero-content { min-width: 0; }           /* prevent overflow */
  .hero-title { font-size: clamp(1.75rem, 6.5vw, 2.4rem); }
  .hero-subtitle { font-size: 1rem; }
  .hero-actions {
    flex-direction: column;
    width: 100%;
  }
  .hero-actions .btn { width: 100%; justify-content: center; }
  .hero-meta { gap: 1rem; }

  /* Services */
  .services-grid { grid-template-columns: 1fr; }
  .service-card-wide { grid-column: span 1; }

  /* About */
  .about-stats-col { grid-template-columns: repeat(2, 1fr); }
  .ideal-tags { grid-template-columns: 1fr; }

  /* Outsourcing / Timeline */
  .timeline-steps { grid-template-columns: 1fr; }
  .why-grid { grid-template-columns: 1fr; }
  .outsourcing-box { padding: 2rem 1.25rem; }

  /* Contact */
  .contact-form { padding: 1.5rem; }

  /* Stack cards */
  .stack-grid { grid-template-columns: 1fr; }
}


/* ── 480px — Small phones ───────────────────────────────────────────────────── */
@media (max-width: 480px) {
  /* Global spacing */
  .section { padding: 3.5rem 0; }
  .container { padding: 0 1rem; }

  /* Top bar */
  .top-bar-contact { display: none; }
  .status-badge { font-size: 0.75rem; }

  /* Hero adjustments */
  .hero-section { padding: 2.5rem 0 3rem; }
  .hero-badge { font-size: 0.7rem; padding: 0.3rem 0.75rem; }
  .hero-title { font-size: clamp(1.5rem, 7vw, 1.9rem); }
  .hero-subtitle { font-size: 0.9375rem; }
  .meta-item { font-size: 0.8rem; }

  /* Stats */
  .stat-card { padding: 1.25rem 1rem; }
  .about-stats-col { grid-template-columns: repeat(2, 1fr); gap: 0.75rem; }

  /* Footer & WhatsApp float */
  .whatsapp-float { bottom: 1.25rem; right: 1.25rem; width: 50px; height: 50px; }
  .whatsapp-float i { width: 26px; height: 26px; }

  /* Terminal tabs — scrollable on narrow screens */
  .terminal-tabs { overflow-x: auto; padding-bottom: 2px; -webkit-overflow-scrolling: touch; }
  .terminal-tab { font-size: 0.7rem; padding: 0.25rem 0.5rem; white-space: nowrap; }

  /* Portfolio filters — horizontal scroll */
  .portfolio-filters {
    flex-wrap: nowrap;
    overflow-x: auto;
    justify-content: flex-start;
    padding-bottom: 6px;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
  }
  .portfolio-filters::-webkit-scrollbar { display: none; }
  .filter-btn { white-space: nowrap; flex-shrink: 0; }

  /* Section headers */
  .section-title { font-size: 1.6rem; }
  .contact-title { font-size: 1.5rem; }

  /* Outsourcing guarantee box */
  .guarantee-col {
    flex-direction: column;
    gap: 0.75rem;
  }

  /* Footer */
  .footer-container { gap: 1.5rem; }
  .footer-bottom-content { flex-direction: column; gap: 0.5rem; text-align: center; }
}

/* --------------------------------------------------------------------------
   PORTFOLIO — PAGINATION & LOAD MORE
   -------------------------------------------------------------------------- */
.portfolio-load-more-wrapper {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1.5rem;
  padding: 2.5rem 1.5rem 0;
}

/* Progress bar */
.portfolio-progress {
  width: 100%;
  max-width: 480px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.625rem;
}

.progress-bar {
  width: 100%;
  height: 4px;
  background: var(--bg-surface-elevated);
  border-radius: 2px;
  overflow: hidden;
}

.progress-fill {
  height: 100%;
  background: linear-gradient(90deg, var(--accent-indigo), var(--accent-cyan));
  border-radius: 2px;
  transition: width 0.4s ease;
}

.progress-label {
  font-size: 0.8125rem;
  color: var(--text-muted);
  font-family: var(--font-mono);
}

.progress-label.all-loaded {
  display: flex;
  align-items: center;
  gap: 0.4rem;
  color: var(--accent-emerald);
}

.progress-label.all-loaded i {
  width: 15px;
  height: 15px;
}

/* Load More Button */
.btn-load-more {
  display: inline-flex;
  align-items: center;
  gap: 0.625rem;
  background: var(--bg-surface);
  border: 1px solid var(--border-glow);
  border-radius: var(--radius-md);
  padding: 0.875rem 2.25rem;
  font-family: var(--font-heading);
  font-weight: 600;
  font-size: 1rem;
  color: var(--text-main);
  cursor: pointer;
  transition: all var(--transition-normal);
  position: relative;
  overflow: hidden;
}

.btn-load-more::before {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(135deg, rgba(99, 102, 241, 0.12), rgba(0, 240, 255, 0.08));
  opacity: 0;
  transition: opacity var(--transition-fast);
}

.btn-load-more:hover {
  border-color: var(--accent-cyan);
  color: var(--accent-cyan);
  transform: translateY(-2px);
  box-shadow: 0 8px 24px rgba(0, 240, 255, 0.15);
}

.btn-load-more:hover::before {
  opacity: 1;
}

.btn-load-more i {
  width: 20px;
  height: 20px;
  position: relative;
  z-index: 1;
}

.btn-load-more span {
  position: relative;
  z-index: 1;
}

/* Card animate-in for newly loaded cards */
@keyframes card-appear {
  from { opacity: 0; transform: translateY(18px) scale(0.97); }
  to   { opacity: 1; transform: translateY(0) scale(1); }
}

.project-card.animate-in {
  animation: card-appear 0.35s ease forwards;
}

/* Portfolio Empty State */
.portfolio-empty {
  grid-column: 1 / -1;
  text-align: center;
  padding: 4rem 2rem;
  background: var(--bg-surface);
  border-radius: var(--radius-lg);
  border: 1px dashed var(--border-color);
}

.portfolio-empty-icon {
  width: 64px;
  height: 64px;
  background: rgba(255, 255, 255, 0.04);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 1.25rem;
}

.portfolio-empty-icon i {
  color: var(--text-muted);
  width: 32px;
  height: 32px;
}

.portfolio-empty p {
  font-size: 1.1rem;
  font-weight: 600;
  color: var(--text-main);
  margin-bottom: 0.5rem;
}

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

/* Project title in card body */
.project-title {
  font-size: 1.05rem;
  font-weight: 700;
  color: var(--text-main);
  margin-bottom: 0.25rem;
}

/* --------------------------------------------------------------------------
   CONTACT FORM — INLINE CHANNEL PANEL (replaces browser confirm dialog)
   -------------------------------------------------------------------------- */
.form-channel-panel {
  display: none;
  flex-direction: column;
  gap: 1.25rem;
  background: var(--bg-surface-elevated);
  border: 1px solid var(--border-glow);
  border-radius: var(--radius-md);
  padding: 1.75rem;
  margin-top: 1.25rem;
  animation: card-appear 0.3s ease forwards;
}

.form-channel-panel.visible {
  display: flex;
}

.channel-panel-header {
  display: flex;
  align-items: center;
  gap: 0.625rem;
  font-size: 1.05rem;
  color: var(--text-main);
}

.channel-panel-header i {
  color: var(--accent-cyan);
  width: 20px;
  height: 20px;
}

.channel-panel-subtitle {
  font-size: 0.9rem;
  color: var(--text-muted);
  margin-top: -0.5rem;
}

.channel-panel-btns {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.875rem;
}

.channel-btn {
  flex-direction: column;
  gap: 0.5rem;
  padding: 1.25rem;
  border-radius: var(--radius-md);
  font-size: 0.9rem;
  font-weight: 600;
  transition: all var(--transition-fast);
}

.channel-btn i {
  width: 24px;
  height: 24px;
}

.channel-btn-email {
  background: rgba(0, 240, 255, 0.08);
  border: 1px solid rgba(0, 240, 255, 0.3);
  color: var(--accent-cyan);
}

.channel-btn-email:hover {
  background: rgba(0, 240, 255, 0.15);
  border-color: var(--accent-cyan);
  transform: translateY(-2px);
  box-shadow: 0 8px 20px rgba(0, 240, 255, 0.2);
}

.channel-btn-wa {
  background: rgba(37, 211, 102, 0.08);
  border: 1px solid rgba(37, 211, 102, 0.3);
  color: #25d366;
}

.channel-btn-wa:hover {
  background: rgba(37, 211, 102, 0.15);
  border-color: #25d366;
  transform: translateY(-2px);
  box-shadow: 0 8px 20px rgba(37, 211, 102, 0.2);
}

.channel-back-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  background: none;
  border: none;
  color: var(--text-muted);
  font-size: 0.85rem;
  cursor: pointer;
  padding: 0;
  align-self: center;
  transition: color var(--transition-fast);
}

.channel-back-btn:hover {
  color: var(--text-main);
}

.channel-back-btn i {
  width: 14px;
  height: 14px;
}

/* Success message toast */
.form-success-msg {
  display: none;
  align-items: center;
  justify-content: center;
  gap: 0.75rem;
  background: rgba(16, 185, 129, 0.1);
  border: 1px solid rgba(16, 185, 129, 0.35);
  border-radius: var(--radius-md);
  padding: 1.25rem;
  margin-top: 1.25rem;
  font-size: 0.95rem;
  animation: card-appear 0.3s ease forwards;
}

.form-success-msg.visible {
  display: flex;
}

.form-success-msg i {
  color: var(--accent-emerald);
  width: 22px;
  height: 22px;
  flex-shrink: 0;
}

.form-success-msg strong {
  color: var(--accent-emerald);
}

.form-success-msg span {
  color: var(--text-muted);
}

/* Error message (server/network failure) */
.form-error-msg {
  display: none;
  align-items: center;
  gap: 0.75rem;
  background: rgba(255, 95, 86, 0.1);
  border: 1px solid rgba(255, 95, 86, 0.35);
  border-radius: var(--radius-md);
  padding: 1.25rem;
  margin-top: 1.25rem;
  font-size: 0.95rem;
  animation: card-appear 0.3s ease forwards;
}

.form-error-msg.visible {
  display: flex;
}

.form-error-msg i {
  color: #ff5f56;
  width: 22px;
  height: 22px;
  flex-shrink: 0;
}

.form-error-msg strong {
  color: #ff5f56;
}

.form-error-msg span {
  color: var(--text-muted);
}

.form-error-msg a {
  color: var(--accent-cyan);
  font-weight: 600;
  text-decoration: underline;
}

/* Email button loading state */
.channel-btn-email.loading {
  opacity: 0.75;
  cursor: not-allowed;
  pointer-events: none;
}

.channel-btn-email.loading .btn-icon-slot i {
  animation: spin-loader 0.8s linear infinite;
}

@keyframes spin-loader {
  from { transform: rotate(0deg); }
  to   { transform: rotate(360deg); }
}

.btn-icon-slot {
  display: flex;
  align-items: center;
  justify-content: center;
}


/* Live validation: field gets green border when it had an error but is now valid */
.form-group input:not(:placeholder-shown):valid,
.form-group textarea:not(:placeholder-shown):valid {
  border-color: rgba(16, 185, 129, 0.4);
}

/* Channel panel responsive */
@media (max-width: 480px) {
  .channel-panel-btns {
    grid-template-columns: 1fr;
  }
  .channel-btn {
    flex-direction: row;
    padding: 1rem;
  }
}

