/* ==========================================================================
   Prática Solutions Informática — stylesheet
   Light enterprise theme, mobile-first, no external framework.
   ========================================================================== */

:root {
  --bg-primary: #f8fafc;
  --bg-secondary: #eef2f7;
  --bg-elevated: #ffffff;
  --accent: #2563eb;
  --accent-dark: #1e40af;
  --accent-light: #7ea8f5;
  --accent-rgb: 37, 99, 235;
  --text-primary: #0f172a;
  --text-secondary: #55607a;
  --border: rgba(15, 23, 42, 0.1);
  --border-strong: rgba(var(--accent-rgb), 0.45);
  --radius: 14px;
  --ease: 0.3s ease;
  --container: 1180px;
}

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

html {
  scroll-behavior: smooth;
  scroll-padding-top: 84px;
}

body {
  background: var(--bg-primary);
  color: var(--text-primary);
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

img, svg { display: block; max-width: 100%; }

a { color: inherit; text-decoration: none; }

.container {
  width: 100%;
  max-width: var(--container);
  margin: 0 auto;
  padding: 0 24px;
}

h1, h2, h3 { font-weight: 800; letter-spacing: -0.02em; line-height: 1.15; }
h1 { font-size: clamp(2.1rem, 5vw, 3.4rem); }
h2 { font-size: clamp(1.7rem, 3.5vw, 2.4rem); }
h3 { font-size: 1.15rem; font-weight: 700; }

p { color: var(--text-secondary); }

.section-tag {
  display: inline-block;
  color: var(--accent);
  font-weight: 600;
  font-size: 0.82rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  margin-bottom: 12px;
}

.section-lead {
  max-width: 620px;
  margin-top: 14px;
  font-size: 1.02rem;
}

.icon-inline { width: 20px; height: 20px; }

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

.section-cta { display: flex; justify-content: center; margin-top: 44px; }

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  border-radius: 999px;
  font-weight: 600;
  font-size: 0.95rem;
  padding: 14px 28px;
  border: 1px solid transparent;
  cursor: pointer;
  transition: transform var(--ease), box-shadow var(--ease), background var(--ease), border-color var(--ease);
  white-space: nowrap;
}

.btn-primary {
  background: var(--accent);
  color: #ffffff;
}
.btn-primary:hover { transform: translateY(-2px); background: var(--accent-dark); }

.btn-ghost {
  background: transparent;
  border-color: var(--border);
  color: var(--text-primary);
}
.btn-ghost:hover { border-color: var(--border-strong); background: rgba(var(--accent-rgb), 0.06); }

.btn-lg { padding: 16px 34px; font-size: 1rem; }
.btn-sm { padding: 10px 20px; font-size: 0.85rem; }

.glow { box-shadow: 0 6px 16px -6px rgba(var(--accent-rgb), 0.5); }
.glow:hover, .glow:focus-visible { box-shadow: 0 10px 22px -8px rgba(var(--accent-rgb), 0.6); }

/* ---------- Header ---------- */
.site-header {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 100;
  background: #ffffff;
  border-bottom: 1px solid transparent;
  transition: border-color var(--ease), box-shadow var(--ease);
}
.site-header.scrolled {
  border-color: var(--border);
  box-shadow: 0 1px 3px rgba(15, 23, 42, 0.06);
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 76px;
}

.logo { display: flex; align-items: center; gap: 10px; }
.logo-icon { height: 38px; width: auto; }
.logo-wordmark { height: 26px; width: auto; }

.footer-logo-icon { height: 52px; width: auto; margin-bottom: 12px; }
.footer-logo-wordmark { height: 30px; width: auto; margin-bottom: 14px; }
.footer-contact { margin-top: 12px; font-size: 0.9rem; line-height: 1.7; }

.nav {
  display: flex;
  align-items: center;
  gap: 32px;
}

.nav-link {
  color: var(--text-secondary);
  font-weight: 500;
  font-size: 0.95rem;
  position: relative;
  transition: color var(--ease);
}
.nav-link::after {
  content: '';
  position: absolute;
  left: 0; bottom: -6px;
  width: 0; height: 2px;
  background: var(--accent);
  transition: width var(--ease);
}
.nav-link:hover { color: var(--text-primary); }
.nav-link:hover::after { width: 100%; }

.menu-toggle {
  display: none;
  background: none;
  border: none;
  color: var(--text-primary);
  cursor: pointer;
  padding: 6px;
}
.menu-toggle .icon-menu, .menu-toggle .icon-close { width: 26px; height: 26px; }
.menu-toggle .icon-close { display: none; }
.menu-toggle[aria-expanded="true"] .icon-menu { display: none; }
.menu-toggle[aria-expanded="true"] .icon-close { display: block; }

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

.hero-overlay {
  position: absolute;
  inset: 0;
  background:
    radial-gradient(60% 50% at 50% 30%, rgba(var(--accent-rgb), 0.08), transparent 70%),
    linear-gradient(180deg, rgba(255, 255, 255, 0.5) 0%, var(--bg-primary) 92%);
  pointer-events: none;
}

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

.eyebrow {
  display: inline-block;
  color: var(--accent);
  font-weight: 600;
  font-size: 0.85rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  border: 1px solid var(--border-strong);
  border-radius: 999px;
  padding: 6px 16px;
  margin-bottom: 22px;
}

.hero-lead {
  margin-top: 20px;
  font-size: 1.1rem;
  max-width: 560px;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 16px;
  margin-top: 34px;
}

.hero-stats {
  display: flex;
  flex-wrap: wrap;
  gap: 24px;
  margin-top: 48px;
}

.hero-stat {
  display: flex;
  align-items: center;
  gap: 10px;
  color: var(--text-secondary);
  font-size: 0.88rem;
}

.dot {
  width: 8px; height: 8px;
  border-radius: 50%;
  background: var(--accent);
  flex-shrink: 0;
}

/* ---------- Sections ---------- */
.section { padding: 100px 0; }
.section-alt { background: var(--bg-secondary); }
.section-head { max-width: 640px; margin-bottom: 56px; }

/* ---------- Sobre ---------- */
#sobre {
  position: relative;
  background:
    linear-gradient(180deg, rgba(15, 23, 42, 0.88), rgba(15, 23, 42, 0.9)),
    url('../assets/img/manutencao.jpg') center / cover no-repeat;
  color: #e2e8f0;
}
#sobre .section-lead { color: #cbd5e1; }
#sobre h2,
#sobre .check-list li { color: #fff; }
#sobre .about-panel {
  background: rgba(255, 255, 255, 0.06);
  border-color: rgba(255, 255, 255, 0.15);
  backdrop-filter: blur(8px);
}
#sobre .panel-label { color: #94a3b8; }
#sobre .panel-value { color: var(--accent-light); }
#sobre .panel-row { border-color: rgba(255, 255, 255, 0.1); }
#sobre .check-list svg { color: var(--accent-light); }

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

.check-list { list-style: none; margin-top: 26px; display: flex; flex-direction: column; gap: 14px; }
.check-list li { display: flex; align-items: center; gap: 12px; color: var(--text-primary); font-weight: 500; }
.check-list svg { width: 20px; height: 20px; color: var(--accent); flex-shrink: 0; }

.about-panel {
  position: relative;
  background: var(--bg-elevated);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 32px;
  overflow: hidden;
  box-shadow: 0 1px 3px rgba(15, 23, 42, 0.04);
}

.panel-line {
  position: absolute;
  top: 0; left: 0; right: 0; height: 2px;
  background: var(--accent);
}

.panel-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 16px 0;
  border-bottom: 1px solid var(--border);
}
.panel-row:last-child { border-bottom: none; }
.panel-label { color: var(--text-secondary); font-size: 0.92rem; }
.panel-value { color: var(--accent); font-weight: 700; font-size: 1.05rem; }

/* ---------- Serviços ---------- */
.services-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 24px;
}

.card {
  position: relative;
  background: var(--bg-elevated);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 30px;
  overflow: hidden;
  box-shadow: 0 1px 3px rgba(15, 23, 42, 0.04);
  transition: transform var(--ease), border-color var(--ease), box-shadow var(--ease);
}

.card::before {
  content: '';
  position: absolute;
  top: 0; left: 0;
  width: 100%; height: 2px;
  background: var(--accent);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 0.4s ease;
}

.card:hover {
  transform: translateY(-6px);
  border-color: var(--border-strong);
  box-shadow: 0 16px 32px -20px rgba(15, 23, 42, 0.28);
}
.card:hover::before { transform: scaleX(1); }

/* Faceted hexagon icon frame, echoing the hexagonal logo mark instead of a
   generic rounded-square template icon. */
.card-icon,
.process-icon {
  --hex: polygon(25% 3%, 75% 3%, 100% 50%, 75% 97%, 25% 97%, 0% 50%);
  position: relative;
  width: 52px; height: 52px;
  display: flex; align-items: center; justify-content: center;
  color: var(--accent);
  margin-bottom: 20px;
  transition: transform 0.4s ease;
}
.card-icon::before,
.process-icon::before {
  content: '';
  position: absolute;
  inset: 0;
  clip-path: var(--hex);
  background: linear-gradient(135deg, var(--accent-light), var(--accent) 55%, var(--accent-dark));
  transition: filter var(--ease);
}
.card-icon::after,
.process-icon::after {
  content: '';
  position: absolute;
  inset: 3px;
  clip-path: var(--hex);
  /* Opaque — this masks the gradient behind it down to a thin faceted rim.
     A translucent fill here would just blend into the gradient instead. */
  background: #eef3ff;
}
.card-icon svg,
.process-icon svg {
  position: relative;
  z-index: 1;
  width: 24px; height: 24px;
  transition: transform 0.4s ease;
}
.card:hover .card-icon,
.process-step:hover .process-icon { transform: rotate(30deg); }
.card:hover .card-icon svg,
.process-step:hover .process-icon svg { transform: rotate(-30deg); }
.card:hover .card-icon::before,
.process-step:hover .process-icon::before {
  filter: drop-shadow(0 0 10px rgba(var(--accent-rgb), 0.5));
}

.card h3 { margin-bottom: 10px; }
.card p { font-size: 0.94rem; }

/* ---------- Problemas que resolvemos ---------- */
.services-grid.problems-grid { grid-template-columns: 1fr; }
@media (min-width: 640px) { .services-grid.problems-grid { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 900px) { .services-grid.problems-grid { grid-template-columns: repeat(3, 1fr); } }
@media (min-width: 1140px) { .services-grid.problems-grid { grid-template-columns: repeat(5, 1fr); } }

/* ---------- Processo de Desenvolvimento ---------- */
.process-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 24px;
  position: relative;
}
.process-step {
  position: relative;
  z-index: 1;
  text-align: center;
  padding: 28px 20px;
  background: var(--bg-elevated);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: 0 1px 3px rgba(15, 23, 42, 0.04);
  transition: transform var(--ease), border-color var(--ease);
}
.process-step:hover { transform: translateY(-4px); border-color: var(--border-strong); }
.process-number {
  display: block;
  font-size: 0.78rem;
  font-weight: 700;
  color: var(--accent);
  letter-spacing: 0.08em;
  margin-bottom: 14px;
}
.process-icon { margin: 0 auto 18px; }
.process-step h3 { margin-bottom: 8px; }
.process-step p { font-size: 0.9rem; }

.process-line {
  display: none;
  position: absolute;
  top: 84px;
  left: 8%; right: 8%;
  height: 2px;
  background: linear-gradient(90deg, var(--border-strong), var(--border), var(--border-strong));
  transform-origin: left center;
  transform: scaleX(1);
  z-index: 0;
}

@media (min-width: 900px) {
  .process-grid { grid-template-columns: repeat(5, 1fr); gap: 20px; }
  .process-line { display: block; }
}

/* ---------- Manutenção e Montagem de PCs ---------- */
#pcs {
  position: relative;
  background:
    linear-gradient(180deg, rgba(15, 23, 42, 0.88), rgba(15, 23, 42, 0.9)),
    url('../assets/img/pc-gamer.jpg') center / cover no-repeat;
  color: #e2e8f0;
}
#pcs .section-lead { color: #cbd5e1; }
#pcs h2 { color: #fff; }
#pcs .card {
  background: rgba(255, 255, 255, 0.06);
  border-color: rgba(255, 255, 255, 0.15);
  backdrop-filter: blur(8px);
}
#pcs .card h3 { color: #fff; }
#pcs .card p { color: #cbd5e1; }
#pcs .card-icon::after { background: #101a2e; }

/* Portfolio cards */
.browser-bar { display: flex; gap: 6px; margin-bottom: 20px; }
.browser-bar span { width: 9px; height: 9px; border-radius: 50%; background: var(--border); }
.browser-bar span:nth-child(1) { background: #f87171; opacity: 0.6; }
.browser-bar span:nth-child(2) { background: #facc15; opacity: 0.6; }
.browser-bar span:nth-child(3) { background: #4ade80; opacity: 0.6; }

.portfolio-link {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  margin-top: 18px;
  color: var(--accent);
  font-weight: 600;
  font-size: 0.9rem;
  transition: gap var(--ease);
}
.portfolio-link svg { width: 16px; height: 16px; }
.portfolio-link:hover { gap: 10px; }

/* ---------- Diferenciais ---------- */
#diferenciais {
  position: relative;
  background:
    linear-gradient(180deg, rgba(15, 23, 42, 0.86), rgba(15, 23, 42, 0.92)),
    url('../assets/img/servidor.jpg') center / cover no-repeat;
  color: #e2e8f0;
}
#diferenciais h2 { color: #fff; }

.metrics-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 24px;
}

.metric {
  background: var(--bg-elevated);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 28px 22px;
  text-align: center;
  transition: border-color var(--ease);
}
.metric:hover { border-color: var(--border-strong); }
#diferenciais .metric {
  background: rgba(255, 255, 255, 0.06);
  border-color: rgba(255, 255, 255, 0.15);
  backdrop-filter: blur(8px);
}
#diferenciais .metric-value { color: #fff; }
#diferenciais .metric-label { color: #94a3b8; }
#diferenciais .metric svg { color: var(--accent-light); }
.metric svg { width: 30px; height: 30px; color: var(--accent); margin: 0 auto 14px; }

.metric-value {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  font-size: 1.9rem;
  font-weight: 800;
  color: var(--text-primary);
}

.metric-label { display: block; margin-top: 8px; color: var(--text-secondary); font-size: 0.88rem; }

/* ---------- CTA Final ---------- */
.cta-final {
  position: relative;
  padding: 110px 0;
  text-align: center;
  overflow: hidden;
  background:
    linear-gradient(180deg, rgba(15, 23, 42, 0.92), rgba(15, 23, 42, 0.95)),
    url('../assets/img/codigo.jpg') center / cover no-repeat;
  color: #e2e8f0;
}
.cta-final-content { position: relative; z-index: 2; max-width: 640px; margin: 0 auto; }
.cta-final h2 { margin-bottom: 16px; color: #fff; }
.cta-final p { font-size: 1.05rem; margin-bottom: 32px; color: #cbd5e1; }
.cta-alt { margin-top: 24px; font-size: 0.88rem; color: #94a3b8; }

/* ---------- Footer ---------- */
.site-footer {
  background: var(--bg-primary);
  border-top: 1px solid var(--border);
  padding: 56px 0 0;
}
.footer-inner {
  display: flex;
  flex-direction: column;
  gap: 24px;
  padding-bottom: 40px;
}
.footer-tagline { margin-top: 10px; font-size: 0.9rem; max-width: 340px; }
.footer-links { display: flex; flex-wrap: wrap; gap: 20px; }
.footer-links a { color: var(--text-secondary); font-size: 0.9rem; transition: color var(--ease); }
.footer-links a:hover { color: var(--accent); }
.footer-bottom {
  border-top: 1px solid var(--border);
  padding: 22px 24px;
  text-align: center;
}
.footer-bottom p { font-size: 0.82rem; }

/* ---------- Reveal on scroll ---------- */
/* Base hidden state (also the no-JS/fallback starting point). Once GSAP
   claims an element (.gsap-handled) it owns `transform` entirely via inline
   styles and clears them after animating in — no resting transform here, so
   :hover rules on cards/icons aren't fought by a leftover inline value. */
.reveal { opacity: 0; }
.reveal:not(.gsap-handled) { transform: translateY(24px); }
.reveal.is-visible { opacity: 1; transform: none; transition: opacity 0.6s ease, transform 0.6s ease; }

/* ---------- Responsive ---------- */
@media (min-width: 640px) {
  .services-grid { grid-template-columns: repeat(2, 1fr); }
  .metrics-grid { grid-template-columns: repeat(4, 1fr); }
}

@media (min-width: 900px) {
  .about-grid { grid-template-columns: 1.1fr 0.9fr; }
  .services-grid { grid-template-columns: repeat(3, 1fr); }
}

@media (max-width: 860px) {
  .menu-toggle { display: block; }
  .nav {
    position: fixed;
    top: 76px; right: 0;
    height: calc(100vh - 76px);
    width: min(78vw, 320px);
    background: var(--bg-secondary);
    border-left: 1px solid var(--border);
    flex-direction: column;
    align-items: flex-start;
    padding: 32px 28px;
    gap: 22px;
    transform: translateX(100%);
    transition: transform 0.35s ease;
  }
  .nav.open { transform: translateX(0); }
  .nav-cta { width: 100%; justify-content: center; margin-top: 8px; }
}

@media (prefers-reduced-motion: reduce) {
  .reveal { animation: none !important; transition: none !important; opacity: 1; transform: none; }
}
