/* ============================================================
   SOFIA PINTO — PORTFOLIO
   Sistema visual: neutro frio + 1 acento. Tom direto.
   Tipografia: Space Grotesk (display) + Inter (corpo).
   ============================================================ */

:root {
  /* Paleta de marca — branco/preto + lima (sinal) + roxo (acento) */
  --bg:        #FFFFFF;   /* branco */
  --bg-alt:    #F3F3F1;   /* secção alternada */
  --ink:       #000000;   /* preto — texto */
  --ink-soft:  #555555;   /* texto secundário */
  --line:      #E5E5E2;   /* linhas/bordas */
  --accent:    #6600CC;   /* roxo — acento de texto/links sobre branco */
  --accent-ink:#FFFFFF;
  --signal:    #DCFF00;   /* lima — CTAs e destaques sobre preto */
  --signal-ink:#000000;

  /* Tipografia */
  --display: "Space Grotesk", system-ui, sans-serif;
  --body:    "Inter", system-ui, sans-serif;

  /* Ritmo */
  --maxw: 1200px;
  --gut: clamp(20px, 5vw, 64px);
  --sec: clamp(64px, 11vw, 140px);
  --radius: 14px;
  --ease: cubic-bezier(.22,.61,.36,1);
}

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

html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }

body {
  font-family: var(--body);
  background: var(--bg);
  color: var(--ink);
  line-height: 1.55;
  font-size: 17px;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

img, video { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }

/* ---------- Layout ---------- */
.wrap { max-width: var(--maxw); margin: 0 auto; padding-inline: var(--gut); }
.section { padding-block: var(--sec); }
.section--alt { background: var(--bg-alt); }
.divider { height: 1px; background: var(--line); border: 0; }

/* ---------- Tipografia ---------- */
.display {
  font-family: var(--display);
  font-weight: 600;
  letter-spacing: -0.02em;
  line-height: 1.02;
}
h1.display { font-size: clamp(2.4rem, 7.5vw, 5.4rem); }
h2.display { font-size: clamp(1.9rem, 4.6vw, 3.2rem); }
h3.display { font-size: clamp(1.25rem, 2.4vw, 1.7rem); }

.eyebrow {
  font-family: var(--display);
  font-size: 0.78rem;
  font-weight: 500;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--ink-soft);
}
.lead { font-size: clamp(1.05rem, 2vw, 1.3rem); color: var(--ink-soft); max-width: 56ch; }
.muted { color: var(--ink-soft); }

/* ---------- Botões ---------- */
.btn {
  display: inline-flex; align-items: center; gap: .5em;
  font-family: var(--display); font-weight: 500; font-size: .98rem;
  padding: .85em 1.4em; border-radius: 999px;
  border: 1px solid var(--ink);
  transition: transform .25s var(--ease), background .25s var(--ease), color .25s var(--ease);
  cursor: pointer; background: transparent; color: var(--ink);
}
.btn:hover { transform: translateY(-2px); }
.btn--primary { background: var(--signal); border-color: var(--signal); color: var(--signal-ink); }
.btn--primary:hover { background: #C8E800; border-color: #C8E800; }
.btn--ghost:hover { background: var(--ink); color: var(--bg); }
.btn-row { display: flex; flex-wrap: wrap; gap: 14px; }

/* ---------- Header / Nav ---------- */
.site-header {
  position: sticky; top: 0; z-index: 100;
  background: color-mix(in srgb, var(--bg) 82%, transparent);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--line);
}
.nav {
  display: flex; align-items: center; justify-content: space-between;
  height: 64px;
}
.brand { font-family: var(--display); font-weight: 600; letter-spacing: -0.02em; font-size: 1.1rem; }
.brand span { color: var(--accent); }
.nav-links { display: none; gap: 28px; align-items: center; }
.nav-links a { font-size: .95rem; color: var(--ink-soft); transition: color .2s var(--ease); }
.nav-links a:hover, .nav-links a.active { color: var(--ink); }
.nav-right { display: flex; align-items: center; gap: 14px; }

.lang-toggle {
  display: inline-flex; border: 1px solid var(--line); border-radius: 999px; overflow: hidden;
  font-family: var(--display); font-size: .8rem;
}
.lang-toggle button {
  border: 0; background: transparent; cursor: pointer; padding: .35em .7em; color: var(--ink-soft);
}
.lang-toggle button.active { background: var(--ink); color: var(--bg); }

.menu-btn { display: inline-flex; flex-direction: column; gap: 4px; background: none; border: 0; cursor: pointer; padding: 8px; }
.menu-btn span { width: 22px; height: 2px; background: var(--ink); transition: .25s var(--ease); }
.mobile-menu {
  display: none; flex-direction: column; gap: 4px; padding: 8px var(--gut) 20px;
  border-bottom: 1px solid var(--line); background: var(--bg);
}
.mobile-menu.open { display: flex; }
.mobile-menu a { padding: 12px 0; border-bottom: 1px solid var(--line); font-family: var(--display); }

@media (min-width: 880px) {
  .nav-links { display: flex; }
  .menu-btn { display: none; }
  .mobile-menu { display: none !important; }
}

/* ---------- Hero ---------- */
.hero { padding-block: clamp(56px, 12vw, 120px); }
.hero h1 { max-width: 18ch; }
.hero .subline {
  font-family: var(--display); font-weight: 500;
  font-size: clamp(1rem, 2.1vw, 1.35rem);
  margin-top: 26px; color: var(--ink); letter-spacing: -0.01em;
}
.hero .subline b { color: var(--accent); font-weight: 500; }
.hero .btn-row { margin-top: 40px; }

/* ---------- Work sample (homepage) ---------- */
.work-grid { display: grid; gap: 18px; grid-template-columns: 1fr; margin-top: 44px; }
.work-card {
  display: block; border: 1px solid var(--line); border-radius: var(--radius);
  overflow: hidden; background: var(--bg);
  transition: transform .3s var(--ease), box-shadow .3s var(--ease), border-color .3s var(--ease);
}
.work-card:hover { transform: translateY(-4px); box-shadow: 0 18px 40px -24px rgba(0,0,0,.28); border-color: var(--ink); }
.work-card .thumb {
  aspect-ratio: 4/3; background: var(--bg-alt) center/cover no-repeat;
  display: flex; align-items: flex-end; position: relative;
}
.work-card .thumb .tag {
  position: absolute; top: 14px; left: 14px;
  font-family: var(--display); font-size: .72rem; letter-spacing: .12em; text-transform: uppercase;
  background: var(--ink); color: var(--bg); padding: .35em .7em; border-radius: 999px;
}
.work-card .body { padding: 22px 22px 26px; }
.work-card .body p { color: var(--ink-soft); margin-top: 6px; font-size: .98rem; }
.work-card .arrow { margin-top: 18px; font-family: var(--display); color: var(--accent); font-size: .95rem; }

@media (min-width: 720px) { .work-grid { grid-template-columns: repeat(3, 1fr); } }

/* ---------- Serviços ---------- */
.serv-grid { display: grid; gap: 28px; grid-template-columns: 1fr; margin-top: 44px; }
.serv {
  padding: 30px; border-radius: var(--radius); border: 1px solid var(--line); background: var(--bg);
}
.serv .eyebrow { color: var(--accent); }
.serv h3 { margin: 12px 0 18px; }
.serv .pp { font-size: .82rem; font-family: var(--display); letter-spacing: .08em; text-transform: uppercase; color: var(--ink-soft); margin-top: 18px; }
.serv .pp + p { margin-top: 4px; }
@media (min-width: 820px) { .serv-grid { grid-template-columns: repeat(3, 1fr); } }

/* ---------- Sobre ---------- */
.about-grid { display: grid; gap: 36px; grid-template-columns: 1fr; align-items: start; margin-top: 30px; }
.about-grid .bio p + p { margin-top: 18px; }
.about-photo { aspect-ratio: 3/4; background: var(--bg-alt); border-radius: var(--radius); }
@media (min-width: 820px) { .about-grid { grid-template-columns: 1.4fr 1fr; gap: 56px; } }

/* ---------- Contacto ---------- */
.contact h2 { max-width: 16ch; }
.contact-links { display: flex; flex-wrap: wrap; gap: 14px 32px; margin-top: 30px; font-family: var(--display); }
.contact-links a { border-bottom: 1px solid var(--line); padding-bottom: 3px; transition: border-color .2s; }
.contact-links a:hover { border-color: var(--accent); color: var(--accent); }

/* ---------- Footer ---------- */
.site-footer { border-top: 1px solid var(--line); padding-block: 40px; }
.site-footer .wrap { display: flex; flex-wrap: wrap; gap: 14px; justify-content: space-between; align-items: center; color: var(--ink-soft); font-size: .9rem; }

/* ---------- Páginas internas: cabeçalho ---------- */
.page-head { padding-block: clamp(48px, 9vw, 96px) var(--sec); }
.page-head h1 { max-width: 16ch; }
.page-head .lead { margin-top: 22px; }
.back { font-family: var(--display); font-size: .9rem; color: var(--ink-soft); display: inline-block; margin-bottom: 22px; }
.back:hover { color: var(--accent); }

/* ---------- UGC: grelha de vídeos por categoria ---------- */
.cat { margin-top: 56px; }
.cat h3 { margin-bottom: 18px; }
.video-grid { display: grid; gap: 16px; grid-template-columns: repeat(2, 1fr); }
.video-card {
  aspect-ratio: 9/16; border-radius: var(--radius); overflow: hidden;
  background: var(--bg-alt); position: relative; border: 1px solid var(--line);
  display: flex; align-items: center; justify-content: center; text-align: center;
}
.video-card .ph { padding: 16px; color: var(--ink-soft); font-size: .82rem; }
.video-card .play {
  width: 52px; height: 52px; border-radius: 50%; background: var(--bg);
  display: flex; align-items: center; justify-content: center; box-shadow: 0 6px 20px -8px rgba(0,0,0,.4);
  position: absolute; inset: 0; margin: auto;
}
.video-card .play::after { content: ""; border-left: 14px solid var(--accent); border-top: 9px solid transparent; border-bottom: 9px solid transparent; margin-left: 4px; }
.video-card iframe { width: 100%; height: 100%; border: 0; }
@media (min-width: 640px) { .video-grid { grid-template-columns: repeat(3, 1fr); } }
@media (min-width: 980px) { .video-grid { grid-template-columns: repeat(4, 1fr); } }

/* ---------- Marcas ---------- */
.brands { display: flex; flex-wrap: wrap; gap: 16px; margin-top: 24px; }
.brands .chip {
  font-family: var(--display); font-size: .95rem; color: var(--ink-soft);
  border: 1px solid var(--line); border-radius: 999px; padding: .55em 1.1em; background: var(--bg);
}

/* ---------- Depoimentos ---------- */
.quotes { display: grid; gap: 22px; grid-template-columns: 1fr; margin-top: 30px; }
.quote { border-left: 3px solid var(--accent); padding: 6px 0 6px 22px; }
.quote p { font-size: 1.08rem; }
.quote .who { font-family: var(--display); font-size: .85rem; color: var(--ink-soft); margin-top: 12px; letter-spacing: .02em; }
@media (min-width: 820px) { .quotes { grid-template-columns: repeat(2, 1fr); gap: 34px; } }

/* ---------- UX/UI case studies ---------- */
.case { display: grid; gap: 22px; grid-template-columns: 1fr; margin-top: 40px; padding-bottom: 40px; border-bottom: 1px solid var(--line); }
.case:last-of-type { border-bottom: 0; }
.case .shot { aspect-ratio: 16/10; background: var(--bg-alt); border-radius: var(--radius); border: 1px solid var(--line); }
.case h3 { margin-bottom: 10px; }
.case .meta { font-family: var(--display); font-size: .8rem; letter-spacing: .1em; text-transform: uppercase; color: var(--accent); margin-bottom: 8px; }
@media (min-width: 820px) { .case { grid-template-columns: 1.1fr 1fr; gap: 44px; align-items: center; } .case.reverse .shot { order: 2; } }

/* ---------- Timeline ---------- */
.timeline { margin-top: 40px; border-top: 1px solid var(--line); }
.tl-item { display: grid; grid-template-columns: 1fr; gap: 4px; padding: 22px 0; border-bottom: 1px solid var(--line); }
.tl-item .org { font-family: var(--display); font-size: 1.15rem; font-weight: 600; }
.tl-item .role { color: var(--ink-soft); }
@media (min-width: 720px) { .tl-item { grid-template-columns: 200px 1fr; gap: 30px; align-items: baseline; } }

/* ---------- Captação ---------- */
.capt-case { max-width: 60ch; }
.capt-case p { font-size: clamp(1.1rem, 2.2vw, 1.45rem); line-height: 1.5; }
.capt-case p + p { margin-top: 22px; }
.capt-video { aspect-ratio: 16/9; background: var(--bg-alt); border-radius: var(--radius); border: 1px solid var(--line); margin-top: 44px; display:flex; align-items:center; justify-content:center; }

/* ---------- Âncoras escuras (preto) — acento passa a lima ---------- */
.dark {
  --bg:       #141417;   /* superfícies/cartões elevados sobre preto */
  --bg-alt:   #1D1D20;
  --ink:      #FFFFFF;   /* texto branco */
  --ink-soft: #A0A0A6;   /* texto secundário claro */
  --line:     #2A2A2E;   /* bordas subtis no escuro */
  --accent:   var(--signal);  /* sobre preto, o acento é a lima */
  --accent-ink:#000000;
  background: #000000;   /* preto de marca */
  color: var(--ink);
}

/* ---------- Banda roxa (contacto / fecho) — acento lima ---------- */
.purple {
  --bg:       #7A29D6;   /* cartões elevados sobre roxo */
  --bg-alt:   #6600CC;
  --ink:      #FFFFFF;
  --ink-soft: #E6D6FA;
  --line:     rgba(255,255,255,.20);
  --accent:   var(--signal);  /* lima sobre roxo */
  --accent-ink:#000000;
  background: #6600CC;   /* roxo de marca */
  color: var(--ink);
}

/* ---------- Motion ---------- */
[data-reveal] { opacity: 0; transform: translateY(14px); transition: opacity .5s var(--ease), transform .5s var(--ease); }
[data-reveal].in { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) {
  [data-reveal] { opacity: 1; transform: none; transition: none; }
  html { scroll-behavior: auto; }
}

/* ---------- Idioma ---------- */
[data-en] { display: none; }
html[lang="en"] [data-pt] { display: none; }
html[lang="en"] [data-en] { display: revert; }
