/* =====================================================
   ROOT / RESET
   ===================================================== */
:root {
  --bg: #050a14;
  --indigo: #0d2154;
  --sky: #1a3a80;
  --sky-light: #4a7bd4;
  --text: #F4F4F8;
  --muted: #CBD5E1;
  --muted-dim: #94A3B8;
  --glass-bg: rgba(10, 20, 35, 0.55);
  --glass-border: rgba(255, 255, 255, 0.08);
  --glass-hover: rgba(255, 255, 255, 0.12);
  --shadow-glow: rgba(26, 58, 128, 0.25);
  --transition-smooth: cubic-bezier(0.34, 1.56, 0.64, 1);
  --transition-bounce: cubic-bezier(0.34, 1.56, 0.64, 1);
}

* { margin: 0; padding: 0; box-sizing: border-box; }

html {
  scroll-behavior: smooth;
  -webkit-tap-highlight-color: transparent;
}

body {
  background: radial-gradient(ellipse at 30% 10%, #0a1c3d 0%, var(--bg) 55%);
  color: var(--text);
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  min-height: 100vh;
  min-height: 100dvh;
}

#bg-mesh {
  position: fixed;
  inset: 0;
  width: 100vw;
  height: 100vh;
  z-index: -2;
  display: block;
  pointer-events: none;
  will-change: transform;
}

.veil {
  position: fixed;
  inset: 0;
  z-index: -1;
  pointer-events: none;
  background: linear-gradient(180deg,
    rgba(5, 10, 20, 0.15) 0%,
    rgba(5, 10, 20, 0.55) 55%,
    rgba(5, 10, 20, 0.92) 100%);
}

main {
  position: relative;
  max-width: 1120px;
  margin: 0 auto;
  padding: 0 clamp(1.5rem, 6vw, 4rem);
}

.section {
  min-height: 100vh;
  min-height: 100dvh;
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: 6rem 0;
  opacity: 0;
  transform: translateY(30px);
  transition: opacity 0.6s ease, transform 0.6s ease;
}

.section.is-visible { opacity: 1; transform: translateY(0); }
.no-js .section { opacity: 1; transform: none; }

.eyebrow {
  font-family: 'Space Mono', monospace;
  font-size: 0.75rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--sky-light);
  margin-bottom: 0.9rem;
}

h1, h2, h3 { font-family: 'Space Grotesk', sans-serif; }

/* HERO */
.hero {
  display: grid;
  grid-template-columns: 1.15fr 0.85fr;
  gap: 3rem;
  align-items: center;
}

.hero h1 {
  font-weight: 700;
  font-size: clamp(2.4rem, 6vw, 4.2rem);
  line-height: 1.05;
  letter-spacing: -0.02em;
  margin-bottom: 1.1rem;
  background: linear-gradient(120deg, #ffffff 30%, var(--sky-light) 100%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.hero .tagline {
  color: var(--muted);
  font-size: 1.05rem;
  line-height: 1.65;
  max-width: 460px;
  margin-bottom: 2.1rem;
}

.cta-row { display: flex; gap: 1rem; flex-wrap: wrap; }

.btn {
  font-family: 'Inter', sans-serif;
  font-weight: 600;
  font-size: 0.9rem;
  padding: 0.8rem 1.6rem;
  border-radius: 999px;
  cursor: pointer;
  border: none;
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  transition: transform 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
  position: relative;
  overflow: hidden;
}

.btn::after {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(120deg, transparent, rgba(255,255,255,0.1), transparent);
  transform: translateX(-100%);
  transition: transform 0.6s ease;
}
.btn:hover::after { transform: translateX(100%); }

.btn-primary {
  background: linear-gradient(120deg, var(--indigo), var(--sky));
  color: #fff;
  box-shadow: 0 12px 30px rgba(26, 58, 128, 0.45);
}
.btn-primary:hover { transform: translateY(-2px); box-shadow: 0 16px 36px rgba(26, 58, 128, 0.6); }
.btn-primary:active { transform: translateY(0px) scale(0.98); }

.btn-ghost {
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid var(--glass-border);
  color: var(--text);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
}
.btn-ghost:hover { background: rgba(255, 255, 255, 0.07); border-color: var(--glass-hover); }

.btn:focus-visible { outline: 2px solid var(--sky-light); outline-offset: 3px; }

/* TILE */
.hero-visual { display: flex; justify-content: center; }

.elastic-tile {
  position: relative;
  width: min(420px, 90vw);
  aspect-ratio: 1 / 1;
  border-radius: 26px;
  overflow: hidden;
  border: 1px solid var(--glass-border);
  box-shadow: 0 30px 70px rgba(0, 0, 0, 0.5);
  cursor: grab;
  touch-action: none;
  background: linear-gradient(140deg, rgba(13, 33, 84, 0.35), rgba(26, 58, 128, 0.25));
  will-change: transform;
}
.elastic-tile:active { cursor: grabbing; }
.elastic-tile canvas { width: 100%; height: 100%; display: block; }

.elastic-tile-loading {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(5, 10, 20, 0.8);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  z-index: 1;
  transition: opacity 0.5s ease;
}
.elastic-tile-loading.hidden { opacity: 0; pointer-events: none; }

.spinner {
  width: 40px;
  height: 40px;
  border: 3px solid rgba(255,255,255,0.1);
  border-top-color: var(--sky-light);
  border-radius: 50%;
  animation: spin 0.8s linear infinite;
}
@keyframes spin { to { transform: rotate(360deg); } }

/* PROJECTS */
h2 {
  font-weight: 600;
  font-size: clamp(1.8rem, 4vw, 2.6rem);
  letter-spacing: -0.01em;
}

.project-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 1.5rem;
  margin-top: 2.5rem;
}

.project-card {
  background: var(--glass-bg);
  border: 1px solid var(--glass-border);
  border-radius: 20px;
  padding: 1.85rem;
  backdrop-filter: blur(24px) saturate(1.6);
  -webkit-backdrop-filter: blur(24px) saturate(1.6);
  transition: transform 0.25s var(--transition-bounce), border-color 0.25s ease, box-shadow 0.25s ease;
}
.project-card:hover {
  transform: translateY(-5px);
  border-color: rgba(26, 58, 128, 0.6);
  box-shadow: 0 12px 40px rgba(0, 0, 0, 0.3);
}
.project-card:active { transform: translateY(-2px) scale(0.98); }
.project-card .card-top { display: flex; align-items: center; justify-content: space-between; margin-bottom: 0.6rem; }
.project-card h3 { font-size: 1.2rem; }

.status {
  font-family: 'Space Mono', monospace;
  font-size: 0.6rem;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--sky-light);
  border: 1px solid rgba(74, 123, 212, 0.5);
  padding: 0.2rem 0.55rem;
  border-radius: 999px;
  white-space: nowrap;
}

.project-card p {
  color: var(--muted-dim);
  font-size: 0.9rem;
  line-height: 1.6;
  margin-bottom: 1.1rem;
}

.tag-row { display: flex; flex-wrap: wrap; gap: 0.4rem; }

.tag {
  font-family: 'Space Mono', monospace;
  font-size: 0.63rem;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  padding: 0.28rem 0.65rem;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid var(--glass-border);
  color: var(--text);
  transition: all 0.2s ease;
}
.tag:hover { background: rgba(255, 255, 255, 0.1); border-color: var(--glass-hover); }

/* ABOUT */
.about-text {
  max-width: 640px;
  color: var(--muted-dim);
  font-size: 1.02rem;
  line-height: 1.75;
  margin: 1.5rem 0 2rem;
}

.skill-tags { display: flex; flex-wrap: wrap; gap: 0.55rem; }
.skill-tags .tag { font-size: 0.7rem; padding: 0.4rem 0.85rem; }

/* TECH GRID */
.tech-section-title {
  font-family: 'Space Mono', monospace;
  font-size: 0.85rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--sky-light);
  margin-top: 3rem;
  margin-bottom: 1.2rem;
  display: flex;
  align-items: center;
  gap: 0.8rem;
}
.tech-section-title::before {
  content: '';
  display: inline-block;
  width: 30px;
  height: 2px;
  background: var(--sky-light);
  flex-shrink: 0;
}

.skills-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(130px, 1fr));
  gap: 1.5rem;
  margin-bottom: 2rem;
}

.skill-item {
  background: rgba(10, 20, 35, 0.7);
  border: 1px solid rgba(255, 255, 255, 0.05);
  border-radius: 16px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 1.5rem 0.8rem;
  transition: all 0.3s var(--transition-bounce);
  cursor: default;
  position: relative;
  overflow: hidden;
}
.skill-item::before {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(120deg, transparent, rgba(74, 123, 212, 0.06), transparent);
  transform: translateX(-100%);
  transition: transform 0.6s ease;
}
.skill-item:hover::before { transform: translateX(100%); }
.skill-item:hover {
  background: rgba(13, 33, 84, 0.45);
  border-color: rgba(74, 123, 212, 0.35);
  transform: translateY(-4px);
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
}

.skill-icon { width: 48px; height: 48px; margin-bottom: 0.8rem; object-fit: contain; }
.skill-name {
  font-family: 'Space Mono', monospace;
  font-size: 0.75rem;
  color: var(--muted-dim);
  text-align: center;
  letter-spacing: 0.03em;
}

/* CERTIFICADOS */
.certificates-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
  gap: 1.25rem;
  margin-top: 2.5rem;
}

.certificate-card {
  background: var(--glass-bg);
  border: 1px solid var(--glass-border);
  border-radius: 20px;
  overflow: hidden;
  cursor: pointer;
  backdrop-filter: blur(24px) saturate(1.6);
  -webkit-backdrop-filter: blur(24px) saturate(1.6);
  transition: transform .25s var(--transition-bounce), border-color .25s ease, box-shadow .25s ease;
}
.certificate-card:hover,
.certificate-card:focus-visible {
  transform: translateY(-5px);
  border-color: rgba(74, 123, 212, 0.55);
  box-shadow: 0 12px 40px rgba(0, 0, 0, .3);
  outline: none;
}
.certificate-card:focus-visible { box-shadow: 0 0 0 2px rgba(74, 123, 212, .85), 0 12px 40px rgba(0, 0, 0, .3); }
.certificate-card:active { transform: translateY(-2px) scale(0.98); }

.certificate-image { aspect-ratio: 16 / 11; overflow: hidden; background: rgba(0, 0, 0, .2); }
.certificate-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: transform .4s ease;
}
.certificate-card:hover .certificate-image img { transform: scale(1.04); }

.certificate-info {
  padding: 1rem 1.15rem 1.25rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: .75rem;
}
.certificate-info h3 { font-size: .95rem; font-weight: 600; line-height: 1.3; }

.cert-badge {
  font-family: 'Space Mono', monospace;
  font-size: .6rem;
  text-transform: uppercase;
  letter-spacing: .06em;
  color: var(--sky-light);
  border: 1px solid rgba(74, 123, 212, .5);
  padding: .2rem .55rem;
  border-radius: 999px;
  white-space: nowrap;
  flex-shrink: 0;
}

/* LIGHTBOX */
.lightbox {
  position: fixed;
  inset: 0;
  z-index: 3000;
  background: rgba(5, 10, 20, .92);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 2rem;
  opacity: 0;
  pointer-events: none;
  transition: opacity .25s ease;
}
.lightbox.show { opacity: 1; pointer-events: auto; }
.lightbox img {
  max-width: min(90vw, 1000px);
  max-height: 88vh;
  border-radius: 12px;
  box-shadow: 0 30px 80px rgba(0, 0, 0, .6);
  transform: scale(.96);
  transition: transform .3s var(--transition-bounce);
}
.lightbox.show img { transform: scale(1); }

.lightbox-close {
  position: absolute;
  top: 1.5rem;
  right: 1.5rem;
  width: 44px;
  height: 44px;
  border-radius: 50%;
  border: 1px solid rgba(255, 255, 255, .1);
  background: rgba(255, 255, 255, .05);
  color: #fff;
  font-size: 1.5rem;
  line-height: 1;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background .2s ease, transform .2s ease;
}
.lightbox-close:hover { background: rgba(255, 255, 255, .12); transform: scale(1.05); }
.lightbox-close:focus-visible { outline: 2px solid var(--sky-light); outline-offset: 3px; }

/* CONTACT */
#contact { align-items: flex-start; text-align: left; }
#contact .tagline {
  color: var(--muted-dim);
  max-width: 460px;
  margin: 1rem 0 1.8rem;
  line-height: 1.6;
}

.social-row { display: flex; gap: 1.4rem; margin-top: 1.6rem; flex-wrap: wrap; }
.social-row a {
  font-family: 'Space Mono', monospace;
  font-size: 0.8rem;
  color: var(--muted-dim);
  text-decoration: none;
  border-bottom: 2px solid transparent;
  transition: color 0.2s ease, border-color 0.2s ease, transform 0.2s ease;
  padding-bottom: 2px;
}
.social-row a:hover { color: var(--text); border-color: var(--sky-light); transform: translateY(-1px); }

/* FOOTER */
footer {
  text-align: center;
  padding: 2rem 0 160px;
  font-family: 'Space Mono', monospace;
  font-size: 0.7rem;
  color: rgba(156, 163, 175, 0.6);
}

/* TOAST */
.dock-toast {
  position: fixed;
  bottom: 122px;
  left: 50%;
  transform: translateX(-50%) translateY(10px);
  background: rgba(13, 25, 48, 0.92);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border: 1px solid rgba(74, 123, 212, 0.15);
  color: #fff;
  font-size: 0.8rem;
  font-weight: 500;
  padding: 0.55rem 1.1rem;
  border-radius: 12px;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.4);
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.25s ease, transform 0.25s ease;
  z-index: 2000;
  white-space: nowrap;
  user-select: none;
}
.dock-toast.show { opacity: 1; transform: translateX(-50%) translateY(0); }

/* DOCK */
.dock-wrapper {
  position: fixed;
  bottom: 28px;
  left: 0;
  right: 0;
  display: flex;
  justify-content: center;
  pointer-events: none;
  z-index: 1000;
}

.dock-outer {
  display: flex;
  max-width: 100%;
  align-items: flex-end;
  pointer-events: auto;
  transition: height 0.2s var(--transition-bounce);
  height: 80px;
  padding: 0 12px;
}

.dock-panel {
  position: relative;
  display: flex;
  align-items: flex-end;
  justify-content: center;
  width: fit-content;
  gap: 0.5rem;
  border-radius: 24px;
  background: rgba(8, 15, 30, 0.85);
  backdrop-filter: blur(30px) saturate(1.8);
  -webkit-backdrop-filter: blur(30px) saturate(1.8);
  border: 1px solid rgba(255, 255, 255, 0.05);
  padding: 0 1rem 0.6rem;
  height: 80px;
  transition: height 0.25s var(--transition-bounce), padding 0.25s var(--transition-bounce);
  box-shadow: 0 8px 40px rgba(0, 0, 0, 0.5), 0 0 60px rgba(13, 33, 84, 0.15), inset 0 1px 0 rgba(255, 255, 255, 0.05);
  min-width: 180px;
}
.dock-panel.expanded { height: 130px; padding-bottom: 0.8rem; }

.dock-item {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 16px;
  background: transparent;
  border: none;
  cursor: pointer;
  outline: none;
  width: 58px;
  height: 58px;
  transition: width 0.08s var(--transition-bounce), height 0.08s var(--transition-bounce);
  flex-shrink: 0;
  padding: 0;
  color: #fff;
  -webkit-tap-highlight-color: transparent;
}

.dock-item::before {
  content: '';
  position: absolute;
  inset: 2px;
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.02);
  border: 1px solid rgba(255, 255, 255, 0.03);
  transition: all 0.25s ease;
}
.dock-item:hover::before { background: rgba(255, 255, 255, 0.04); border-color: rgba(255, 255, 255, 0.06); }
.dock-item:focus-visible::before {
  background: rgba(255, 255, 255, 0.06);
  border-color: rgba(74, 123, 212, 0.6);
  box-shadow: 0 0 0 2px rgba(74, 123, 212, 0.85);
}
.dock-item:active { transform: scale(0.92); transition-duration: 0.05s; }
.dock-item.magnified { z-index: 10; }
.dock-item.magnified::before {
  background: rgba(255, 255, 255, 0.05);
  border-color: rgba(255, 255, 255, 0.08);
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.3);
}

.dock-icon {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  height: 100%;
  position: relative;
  z-index: 1;
}

.dock-icon svg {
  width: 26px;
  height: 26px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.8;
  stroke-linecap: round;
  stroke-linejoin: round;
  transition: width 0.08s var(--transition-bounce), height 0.08s var(--transition-bounce);
  filter: drop-shadow(0 1px 2px rgba(0, 0, 0, 0.2));
}
.dock-item.magnified .dock-icon svg { width: 36px; height: 36px; }

.dock-label {
  position: absolute;
  bottom: calc(100% + 16px);
  left: 50%;
  transform: translateX(-50%) scale(0.9) translateY(8px);
  white-space: nowrap;
  border-radius: 8px;
  background: rgba(0, 0, 0, 0.8);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  padding: 0.35rem 0.9rem;
  font-size: 0.7rem;
  font-weight: 500;
  color: #fff;
  letter-spacing: 0.2px;
  opacity: 0;
  pointer-events: none;
  transition: all 0.2s var(--transition-bounce);
  border: 1px solid rgba(255, 255, 255, 0.06);
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.4);
}
.dock-item:hover .dock-label,
.dock-item:focus-visible .dock-label {
  opacity: 1;
  transform: translateX(-50%) scale(1) translateY(0);
}

.dock-separator {
  width: 1px;
  height: 36px;
  background: linear-gradient(180deg, transparent, rgba(255, 255, 255, 0.05), transparent);
  align-self: center;
  flex-shrink: 0;
  margin: 0 2px;
}

.dock-item .active-dot {
  position: absolute;
  bottom: 2px;
  left: 50%;
  transform: translateX(-50%) scale(0.5);
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: rgba(74, 123, 212, 0.7);
  opacity: 0;
  transition: all 0.3s var(--transition-bounce);
}
.dock-item.active .active-dot { opacity: 1; transform: translateX(-50%) scale(1); }

.dock-item::after {
  content: '';
  position: absolute;
  bottom: -4px;
  left: 30%;
  right: 30%;
  height: 2px;
  border-radius: 1px;
  background: rgba(74, 123, 212, 0.4);
  opacity: 0;
  transition: opacity 0.3s ease;
}
.dock-item.active::after { opacity: 1; }

/* =====================================================
   RESPONSIVE — TABLET
   ===================================================== */
@media (max-width: 900px) {
  #home.section {
    min-height: auto;
    padding: 3rem 0 3.5rem;
  }

  .hero h1 {
    font-size: clamp(2.2rem, 9vw, 3rem);
  }

  #contact {
    align-items: center;
    text-align: center;
  }

  #contact .tagline {
    margin-left: auto;
    margin-right: auto;
  }

  .social-row { justify-content: center; }
}

/* =====================================================
   RESPONSIVE — CELULAR
   Hero empilhado: imagem em cima, texto embaixo, centralizado
   ===================================================== */
@media (max-width: 640px) {
  main {
    padding-left: max(1.25rem, env(safe-area-inset-left));
    padding-right: max(1.25rem, env(safe-area-inset-right));
  }

  .section {
    min-height: auto;
    padding: 3rem 0 2.5rem;
  }

  #home.section {
    padding: 1.75rem 0 2rem;
  }

  /* HERO — empilhado e centralizado */
  .hero {
    grid-template-columns: 1fr;
    gap: 1.5rem;
    text-align: center;
    align-items: center;
  }

  .hero-visual {
    order: -1;
    display: flex;
    justify-content: center;
  }

  .hero-text { min-width: 0; }

  .elastic-tile {
    width: min(260px, 70vw);
    border-radius: 20px;
  }

  .eyebrow {
    font-size: 0.62rem;
    margin-bottom: 0.5rem;
    letter-spacing: 0.11em;
  }

  .hero h1 {
    font-size: clamp(2.4rem, 12vw, 3rem);
    line-height: 1;
    margin-bottom: 0.75rem;
  }

  .hero .tagline {
    font-size: 0.85rem;
    line-height: 1.55;
    margin-bottom: 1.4rem;
    max-width: 100%;
  }

  .cta-row {
    gap: 0.6rem;
    justify-content: center;
  }

  .cta-row .btn {
    padding: 0.7rem 1.15rem;
    font-size: 0.8rem;
  }

  /* Tipografia geral */
  h2 {
    font-size: clamp(1.55rem, 7.5vw, 2rem);
  }

  .about-text {
    font-size: 0.92rem;
    line-height: 1.7;
    margin: 1rem 0 1.5rem;
  }

  .tech-section-title {
    margin-top: 1.8rem;
    font-size: 0.72rem;
  }

  .skills-grid {
    grid-template-columns: repeat(auto-fill, minmax(90px, 1fr));
    gap: 0.7rem;
  }
  .skill-item { padding: 1rem 0.5rem; border-radius: 14px; }
  .skill-icon { width: 36px; height: 36px; margin-bottom: 0.5rem; }
  .skill-name { font-size: 0.62rem; }

  .project-grid {
    grid-template-columns: 1fr;
    gap: 1rem;
    margin-top: 1.6rem;
  }
  .project-card { padding: 1.3rem; border-radius: 18px; }
  .project-card h3 { font-size: 1.02rem; }
  .project-card p { font-size: 0.83rem; }

  .certificates-grid {
    grid-template-columns: 1fr;
    gap: 1rem;
    margin-top: 1.6rem;
  }

  #contact .btn-primary {
    width: 100%;
    justify-content: center;
    font-size: 0.8rem;
    padding: 0.85rem 1rem;
    word-break: break-all;
  }

  /* DOCK */
  .dock-wrapper {
    bottom: max(10px, env(safe-area-inset-bottom));
  }

  .dock-outer {
    height: 58px;
    padding: 0 6px;
  }

  .dock-panel {
    gap: 0.1rem;
    padding: 0 0.45rem 0.4rem;
    border-radius: 15px;
    height: 58px;
    min-width: 0;
  }
  .dock-panel.expanded {
    height: 96px;
    padding-bottom: 0.45rem;
  }

  .dock-item {
    width: 42px;
    height: 42px;
    border-radius: 12px;
  }
  .dock-item .dock-icon svg { width: 19px; height: 19px; }
  .dock-item.magnified .dock-icon svg { width: 26px; height: 26px; }

  .dock-separator { height: 20px; margin: 0 1px; }

  .dock-label {
    font-size: 0.56rem;
    padding: 0.18rem 0.5rem;
    bottom: calc(100% + 8px);
  }

  /* Lightbox */
  .lightbox { padding: 0.75rem; }
  .lightbox-close {
    top: 0.6rem;
    right: 0.6rem;
    width: 38px;
    height: 38px;
    font-size: 1.3rem;
  }

  /* Toast */
  .dock-toast {
    bottom: 82px;
    font-size: 0.72rem;
    padding: 0.45rem 0.85rem;
  }

  /* Footer */
  footer {
    padding: 1.4rem 0 100px;
    font-size: 0.62rem;
  }
}

/* =====================================================
   CELULARES BEM PEQUENOS (≤ 400px)
   ===================================================== */
@media (max-width: 400px) {
  .elastic-tile {
    width: min(220px, 68vw);
  }

  .hero h1 {
    font-size: 2.2rem;
  }

  .hero .tagline {
    font-size: 0.8rem;
  }

  .cta-row .btn {
    padding: 0.6rem 1rem;
    font-size: 0.75rem;
  }

  .dock-item {
    width: 38px;
    height: 38px;
  }
  .dock-item .dock-icon svg { width: 17px; height: 17px; }
}

/* UTILITÁRIOS */
.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

.reveal-left, .reveal-right {
  opacity: 0;
  transform: translateY(20px);
  animation: reveal 0.6s ease forwards;
}
.reveal-left  { animation-delay: 0.1s; }
.reveal-right { animation-delay: 0.2s; }
@keyframes reveal { to { opacity: 1; transform: translateY(0); } }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  * { animation: none !important; transition: none !important; }
  .section { opacity: 1; transform: none; }
  .reveal-left, .reveal-right { opacity: 1; transform: none; animation: none; }
  .btn::after { display: none; }
  .skill-item::before { display: none; }
  .lightbox, .lightbox img { transition: none; }
}

::-webkit-scrollbar { display: none; }
* { scrollbar-width: none; }