/* ============================================================
   Asian Connection — Stylesheet
   Documentação técnica moderna, light theme, teal accent
   ============================================================ */

:root {
  --bg-primary: #FAFAF9;
  --bg-secondary: #FFFFFF;
  --bg-elevated: #FFFFFF;
  --brand-primary: #0F766E;
  --brand-accent: #14B8A6;
  --brand-soft: #CCFBF1;
  --text-primary: #18181B;
  --text-secondary: #52525B;
  --text-muted: #71717A;
  --border: #E4E4E7;
  --border-strong: #D4D4D8;
  --warning: #EA580C;
  --warning-soft: #FFEDD5;
  --info: #2563EB;
  --info-soft: #DBEAFE;
  --success: #16A34A;
  --success-soft: #DCFCE7;
  --tip: #16A34A;
  --tip-soft: #DCFCE7;
  --shadow-sm: 0 1px 2px rgba(0, 0, 0, 0.04);
  --shadow-md: 0 4px 12px rgba(0, 0, 0, 0.06);
  --shadow-lg: 0 12px 28px rgba(0, 0, 0, 0.08);
  --radius-sm: 6px;
  --radius-md: 10px;
  --radius-lg: 14px;
  --container: 1140px;
  --container-narrow: 820px;
  --font-display: "Space Grotesk", system-ui, sans-serif;
  --font-body: "IBM Plex Sans", system-ui, sans-serif;
  --font-mono: "JetBrains Mono", "SF Mono", Menlo, monospace;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }

body {
  margin: 0;
  font-family: var(--font-body);
  font-size: 16px;
  line-height: 1.65;
  color: var(--text-primary);
  background: var(--bg-primary);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-display);
  font-weight: 600;
  line-height: 1.2;
  letter-spacing: -0.02em;
  color: var(--text-primary);
  margin: 0 0 0.6em;
}

h1 { font-size: clamp(2rem, 4vw, 2.75rem); font-weight: 700; }
h2 { font-size: clamp(1.5rem, 2.6vw, 2rem); margin-top: 2.5rem; }
h3 { font-size: 1.25rem; margin-top: 2rem; }
h4 { font-size: 1.05rem; margin-top: 1.5rem; }

p { margin: 0 0 1rem; color: var(--text-secondary); }
p strong, li strong { color: var(--text-primary); font-weight: 600; }

a {
  color: var(--brand-primary);
  text-decoration: none;
  font-weight: 500;
  transition: color 0.18s ease;
}
a:hover { color: var(--brand-accent); text-decoration: underline; }

code, kbd, pre {
  font-family: var(--font-mono);
  font-size: 0.9em;
}
code {
  background: var(--brand-soft);
  color: #134E4A;
  padding: 0.1em 0.4em;
  border-radius: 4px;
  font-size: 0.88em;
}
pre {
  background: #18181B;
  color: #E4E4E7;
  padding: 1rem 1.2rem;
  border-radius: var(--radius-md);
  overflow-x: auto;
  margin: 1.5rem 0;
}
pre code { background: none; color: inherit; padding: 0; }

ul, ol { padding-left: 1.4rem; margin: 0 0 1rem; }
li { margin-bottom: 0.4rem; color: var(--text-secondary); }
li::marker { color: var(--brand-primary); }

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

/* ============================================================
   Layout
   ============================================================ */
.container {
  width: 100%;
  max-width: var(--container);
  margin: 0 auto;
  padding: 0 1.25rem;
}
.container-narrow {
  width: 100%;
  max-width: var(--container-narrow);
  margin: 0 auto;
  padding: 0 1.25rem;
}

section { padding: 3.5rem 0; }
@media (max-width: 640px) { section { padding: 2.5rem 0; } }

/* ============================================================
   Header
   ============================================================ */
.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(250, 250, 249, 0.92);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--border);
}
.site-header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0.85rem 0;
  gap: 1rem;
}
.brand-logo {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 1.15rem;
  color: var(--text-primary);
  text-decoration: none;
  letter-spacing: -0.01em;
}
.brand-logo:hover { color: var(--brand-primary); text-decoration: none; }
.brand-mark {
  width: 32px; height: 32px;
  background: var(--brand-primary);
  border-radius: 8px;
  display: grid;
  place-items: center;
  color: #fff;
  font-weight: 700;
  font-size: 0.95rem;
}

.nav-primary {
  display: flex;
  gap: 1.6rem;
  align-items: center;
}
.nav-primary a {
  color: var(--text-secondary);
  font-size: 0.94rem;
  font-weight: 500;
}
.nav-primary a:hover { color: var(--brand-primary); text-decoration: none; }
.nav-primary a.active { color: var(--brand-primary); }

.nav-cta {
  background: var(--brand-primary);
  color: #fff !important;
  padding: 0.55rem 1.1rem;
  border-radius: var(--radius-md);
  font-size: 0.9rem !important;
  font-weight: 600 !important;
  transition: background 0.18s;
}
.nav-cta:hover { background: var(--brand-accent); text-decoration: none !important; }

.nav-toggle {
  display: none;
  background: none;
  border: 1px solid var(--border-strong);
  border-radius: 8px;
  padding: 0.4rem 0.55rem;
  cursor: pointer;
}
.nav-toggle span {
  display: block;
  width: 20px; height: 2px;
  background: var(--text-primary);
  margin: 4px 0;
}

@media (max-width: 820px) {
  .nav-toggle { display: block; }
  .nav-primary {
    display: none;
    position: absolute;
    top: 100%; left: 0; right: 0;
    flex-direction: column;
    background: #fff;
    padding: 1rem 1.25rem 1.4rem;
    gap: 1rem;
    border-bottom: 1px solid var(--border);
    box-shadow: var(--shadow-md);
  }
  .nav-primary.open { display: flex; }
  .nav-primary a { font-size: 1rem; }
  .nav-cta { display: inline-block; align-self: flex-start; }
}

/* ============================================================
   Hero
   ============================================================ */
.hero {
  padding: 4.5rem 0 3.5rem;
  background:
    radial-gradient(ellipse at top right, var(--brand-soft) 0%, transparent 55%),
    var(--bg-primary);
  border-bottom: 1px solid var(--border);
}
.hero-eyebrow {
  display: inline-block;
  font-family: var(--font-mono);
  font-size: 0.78rem;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--brand-primary);
  background: var(--brand-soft);
  padding: 0.35rem 0.75rem;
  border-radius: 100px;
  margin-bottom: 1.25rem;
}
.hero h1 {
  font-size: clamp(2.1rem, 4.6vw, 3.2rem);
  font-weight: 700;
  letter-spacing: -0.03em;
  margin-bottom: 1rem;
  max-width: 22ch;
}
.hero .lead {
  font-size: 1.15rem;
  color: var(--text-secondary);
  max-width: 60ch;
  margin-bottom: 2rem;
}
.hero-actions { display: flex; flex-wrap: wrap; gap: 0.75rem; }

/* ============================================================
   Buttons
   ============================================================ */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.8rem 1.4rem;
  border-radius: var(--radius-md);
  font-family: var(--font-body);
  font-weight: 600;
  font-size: 0.96rem;
  text-decoration: none !important;
  border: 1px solid transparent;
  cursor: pointer;
  transition: all 0.18s;
  line-height: 1;
}
.btn-primary { background: var(--brand-primary); color: #fff; }
.btn-primary:hover { background: var(--brand-accent); color: #fff; }
.btn-secondary {
  background: var(--bg-secondary);
  color: var(--text-primary);
  border-color: var(--border-strong);
}
.btn-secondary:hover { border-color: var(--brand-primary); color: var(--brand-primary); }
.btn-whatsapp { background: var(--warning); color: #fff; }
.btn-whatsapp:hover { background: #C2410C; color: #fff; }

/* ============================================================
   Cards & grids
   ============================================================ */
.card {
  background: var(--bg-secondary);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 1.6rem;
  transition: border-color 0.18s, transform 0.18s, box-shadow 0.18s;
}
.card:hover { border-color: var(--brand-primary); transform: translateY(-2px); box-shadow: var(--shadow-md); }
.card h3 { margin-top: 0; margin-bottom: 0.5rem; font-size: 1.1rem; }
.card p { font-size: 0.94rem; margin-bottom: 0.6rem; }
.card-link {
  font-family: var(--font-mono);
  font-size: 0.82rem;
  color: var(--brand-primary);
  display: inline-block;
  margin-top: 0.4rem;
}

.grid {
  display: grid;
  gap: 1rem;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
}
.grid-2 { display: grid; gap: 1.25rem; grid-template-columns: repeat(2, 1fr); }
.grid-3 { display: grid; gap: 1.25rem; grid-template-columns: repeat(3, 1fr); }
.grid-4 { display: grid; gap: 1rem; grid-template-columns: repeat(4, 1fr); }
@media (max-width: 820px) {
  .grid-2, .grid-3, .grid-4 { grid-template-columns: 1fr; }
}
@media (max-width: 980px) and (min-width: 821px) {
  .grid-4 { grid-template-columns: repeat(2, 1fr); }
}

/* ============================================================
   Section heading
   ============================================================ */
.section-heading { margin-bottom: 2rem; }
.section-heading h2 { margin-top: 0; margin-bottom: 0.5rem; }
.section-heading .section-sub {
  color: var(--text-muted);
  font-size: 1rem;
  max-width: 60ch;
}

/* ============================================================
   Steps (numbered tutorial)
   ============================================================ */
.steps { counter-reset: step; list-style: none; padding-left: 0; margin: 2rem 0; }
.steps > li {
  counter-increment: step;
  position: relative;
  padding: 1.2rem 1.2rem 1.2rem 4rem;
  background: var(--bg-secondary);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  margin-bottom: 0.85rem;
}
.steps > li::before {
  content: counter(step);
  position: absolute;
  top: 1.3rem;
  left: 1.2rem;
  width: 32px; height: 32px;
  background: var(--brand-primary);
  color: #fff;
  border-radius: 50%;
  display: grid;
  place-items: center;
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 0.95rem;
}
.steps > li h4 {
  margin: 0 0 0.4rem;
  font-size: 1.05rem;
  color: var(--text-primary);
}
.steps > li p { margin-bottom: 0.4rem; font-size: 0.95rem; }
.steps img, .steps .img-placeholder {
  margin-top: 0.8rem;
  border-radius: var(--radius-sm);
  border: 1px solid var(--border);
}

.img-placeholder {
  width: 100%;
  aspect-ratio: 16 / 9;
  background:
    repeating-linear-gradient(45deg, #F4F4F5 0 10px, #FAFAF9 10px 20px);
  display: grid;
  place-items: center;
  color: var(--text-muted);
  font-size: 0.85rem;
  font-family: var(--font-mono);
  border: 1px dashed var(--border-strong);
}

/* ============================================================
   Callouts
   ============================================================ */
.callout {
  border-left: 3px solid var(--brand-primary);
  background: var(--brand-soft);
  padding: 1rem 1.2rem;
  border-radius: var(--radius-sm);
  margin: 1.5rem 0;
}
.callout p:last-child { margin-bottom: 0; }
.callout-info {
  border-left-color: var(--info);
  background: var(--info-soft);
}
.callout-warning {
  border-left-color: var(--warning);
  background: var(--warning-soft);
}
.callout-tip {
  border-left-color: var(--tip);
  background: var(--tip-soft);
}
.callout-title {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 0.85rem;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  margin-bottom: 0.4rem;
  color: var(--text-primary);
  display: flex; align-items: center; gap: 0.4rem;
}
.callout-info .callout-title { color: #1E40AF; }
.callout-warning .callout-title { color: #9A3412; }
.callout-tip .callout-title { color: #166534; }

/* ============================================================
   Tabela de compatibilidade
   ============================================================ */
.table-wrapper {
  overflow-x: auto;
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  background: var(--bg-secondary);
}
table.compat {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.93rem;
  min-width: 700px;
}
table.compat th,
table.compat td {
  text-align: left;
  padding: 0.85rem 1rem;
  border-bottom: 1px solid var(--border);
}
table.compat th {
  background: #F4F4F5;
  font-family: var(--font-display);
  font-weight: 600;
  color: var(--text-primary);
  font-size: 0.85rem;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}
table.compat tbody tr:last-child td { border-bottom: none; }
table.compat tbody tr:hover { background: #FAFAF9; }
.tag-easy { color: var(--success); font-weight: 600; }
.tag-med { color: var(--warning); font-weight: 600; }
.tag-hard { color: #DC2626; font-weight: 600; }
.check { color: var(--success); font-weight: 700; }
.cross { color: #DC2626; font-weight: 700; }
.dash { color: var(--text-muted); }

/* ============================================================
   FAQ accordion
   ============================================================ */
.faq-list { margin-top: 1.5rem; }
.faq-item {
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  margin-bottom: 0.6rem;
  background: var(--bg-secondary);
  overflow: hidden;
}
.faq-item summary {
  cursor: pointer;
  padding: 1.1rem 1.2rem;
  font-family: var(--font-display);
  font-weight: 500;
  font-size: 1rem;
  color: var(--text-primary);
  list-style: none;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 1rem;
}
.faq-item summary::-webkit-details-marker { display: none; }
.faq-item summary::after {
  content: "+";
  font-size: 1.4rem;
  color: var(--brand-primary);
  font-weight: 400;
  transition: transform 0.2s;
}
.faq-item[open] summary::after { transform: rotate(45deg); }
.faq-item .faq-body {
  padding: 0 1.2rem 1.2rem;
  color: var(--text-secondary);
}
.faq-item .faq-body p:last-child { margin-bottom: 0; }

/* ============================================================
   Device search (Home)
   ============================================================ */
.device-search {
  background: var(--bg-secondary);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 1.6rem;
  margin: 1.5rem 0 0;
}
.device-search label {
  display: block;
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 0.85rem;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  margin-bottom: 0.6rem;
  color: var(--text-muted);
}
.device-search input {
  width: 100%;
  padding: 0.85rem 1rem;
  border: 1px solid var(--border-strong);
  border-radius: var(--radius-md);
  font-family: var(--font-body);
  font-size: 1rem;
  background: #fff;
  transition: border-color 0.18s, box-shadow 0.18s;
}
.device-search input:focus {
  outline: none;
  border-color: var(--brand-primary);
  box-shadow: 0 0 0 3px var(--brand-soft);
}
.device-results {
  margin-top: 1rem;
  display: grid;
  gap: 0.5rem;
}
.device-results a {
  padding: 0.7rem 0.9rem;
  border-radius: var(--radius-sm);
  background: #FAFAF9;
  border: 1px solid var(--border);
  display: flex; justify-content: space-between; align-items: center;
  color: var(--text-primary);
  font-weight: 500;
  font-size: 0.95rem;
}
.device-results a:hover { background: var(--brand-soft); border-color: var(--brand-primary); text-decoration: none; }
.device-results a span.go { color: var(--brand-primary); font-family: var(--font-mono); font-size: 0.85rem; }
.device-empty { color: var(--text-muted); font-size: 0.92rem; padding: 0.8rem 0; }
.search-group { margin-bottom: 0.6rem; }
.search-group:last-child { margin-bottom: 0; }
.search-group-title {
  font-size: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: var(--text-muted);
  font-weight: 600;
  margin: 0.6rem 0 0.4rem;
  padding: 0 0.2rem;
}
.search-group-title .search-count {
  color: var(--brand-primary);
  font-weight: 500;
  font-family: var(--font-mono);
}
.search-group a {
  padding: 0.7rem 0.9rem;
  border-radius: var(--radius-sm);
  background: #FAFAF9;
  border: 1px solid var(--border);
  display: flex; justify-content: space-between; align-items: center;
  color: var(--text-primary);
  font-weight: 500;
  font-size: 0.95rem;
  margin-bottom: 0.4rem;
}
.search-group a:last-child { margin-bottom: 0; }
.search-group a:hover { background: var(--brand-soft); border-color: var(--brand-primary); text-decoration: none; }
.search-group a span.go { color: var(--brand-primary); font-family: var(--font-mono); font-size: 0.85rem; }

/* ============================================================
   Quick tips (Home)
   ============================================================ */
.tip-card {
  background: var(--bg-secondary);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  padding: 1.2rem;
  position: relative;
  padding-left: 3rem;
}
.tip-card::before {
  content: "💡";
  position: absolute;
  top: 1.25rem; left: 1rem;
  font-size: 1.2rem;
}
.tip-card p { font-size: 0.94rem; margin-bottom: 0; }

/* ============================================================
   Breadcrumbs
   ============================================================ */
.breadcrumbs {
  font-family: var(--font-mono);
  font-size: 0.82rem;
  color: var(--text-muted);
  margin-bottom: 0.5rem;
  padding-top: 2rem;
}
.breadcrumbs a { color: var(--text-muted); }
.breadcrumbs a:hover { color: var(--brand-primary); }
.breadcrumbs span.sep { margin: 0 0.4rem; opacity: 0.6; }

/* ============================================================
   Content/article
   ============================================================ */
.article-body { max-width: 740px; }
.article-body h2 { padding-top: 0.5rem; }
.article-body h2:first-child { padding-top: 0; margin-top: 0; }

/* ============================================================
   Footer
   ============================================================ */
.site-footer {
  background: #18181B;
  color: #D4D4D8;
  padding: 3.5rem 0 1.5rem;
  margin-top: 4rem;
}
.site-footer a { color: #A1A1AA; }
.site-footer a:hover { color: #fff; text-decoration: none; }
.footer-grid {
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr;
  gap: 2.5rem;
  margin-bottom: 2.5rem;
}
@media (max-width: 720px) {
  .footer-grid { grid-template-columns: 1fr; gap: 2rem; }
}
.footer-brand h3 {
  font-family: var(--font-display);
  color: #fff;
  font-size: 1.2rem;
  margin: 0.5rem 0 0.3rem;
}
.footer-brand p { color: #A1A1AA; font-size: 0.95rem; max-width: 32ch; }
.footer-col h4 {
  font-family: var(--font-display);
  font-size: 0.85rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: #fff;
  margin: 0 0 1rem;
}
.footer-col ul { list-style: none; padding: 0; margin: 0; }
.footer-col li { margin-bottom: 0.5rem; color: #A1A1AA; }
.footer-col li a { font-size: 0.94rem; }
.footer-bottom {
  border-top: 1px solid #27272A;
  padding-top: 1.5rem;
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 1rem;
  font-size: 0.83rem;
  color: #71717A;
}
.footer-bottom-links { display: flex; gap: 1rem; flex-wrap: wrap; }
.footer-bottom .meta { font-family: var(--font-mono); font-size: 0.78rem; }
.btn-whatsapp-footer {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  background: var(--warning);
  color: #fff !important;
  padding: 0.75rem 1.2rem;
  border-radius: var(--radius-md);
  font-weight: 600;
  margin-top: 0.4rem;
  font-size: 0.94rem;
}
.btn-whatsapp-footer:hover { background: #C2410C; text-decoration: none !important; }

/* ============================================================
   CTA section
   ============================================================ */
.cta-banner {
  background: linear-gradient(135deg, var(--brand-primary), #134E4A);
  color: #fff;
  border-radius: var(--radius-lg);
  padding: 2.5rem 2rem;
  text-align: center;
  margin: 3rem 0;
}
.cta-banner h2 { color: #fff; margin-top: 0; }
.cta-banner p { color: #CCFBF1; max-width: 50ch; margin: 0 auto 1.5rem; }
.cta-banner .btn {
  background: #fff; color: var(--brand-primary);
}
.cta-banner .btn:hover { background: var(--brand-soft); }

/* ============================================================
   Utility
   ============================================================ */
.text-center { text-align: center; }
.mt-0 { margin-top: 0; }
.mb-0 { margin-bottom: 0; }
.mt-2 { margin-top: 1rem; }
.mb-2 { margin-bottom: 1rem; }
.muted { color: var(--text-muted); }

/* ============================================================
   Skip link a11y
   ============================================================ */
.skip-link {
  position: absolute;
  top: -100px;
  left: 0;
  background: var(--brand-primary);
  color: #fff;
  padding: 0.6rem 1rem;
  text-decoration: none;
  z-index: 100;
}
.skip-link:focus { top: 0; }