/* ================================
   PORTFÓLIO — FOLHA DE ESTILOS
   Tudo neste ficheiro é editável.
================================ */

:root {
  --bg: #f5f4f0;
  --surface: #ffffff;
  --text: #171717;
  --muted: #686868;
  --line: #deddd7;
  --accent: #d9ff45;
  --dark: #111111;
  --max-width: 1180px;
  --radius: 18px;
}

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

html { scroll-behavior: smooth; }

body {
  font-family: "Inter", Arial, sans-serif;
  background: var(--bg);
  color: var(--text);
  line-height: 1.6;
}

body.dark {
  --bg: #0f0f0f;
  --surface: #181818;
  --text: #f5f5f5;
  --muted: #a8a8a8;
  --line: #303030;
}

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

.container {
  width: min(calc(100% - 48px), var(--max-width));
  margin-inline: auto;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: color-mix(in srgb, var(--bg) 92%, transparent);
  backdrop-filter: blur(14px);
  border-bottom: 1px solid var(--line);
}

.nav {
  min-height: 76px;
  display: flex;
  align-items: center;
  gap: 28px;
}

.logo { font-size: 14px; font-weight: 800; letter-spacing: .12em; margin-right: auto; }
.logo span { color: #8ca800; }

.nav-links { display: flex; gap: 26px; }
.nav-links a { font-size: 13px; color: var(--muted); transition: color .2s; }
.nav-links a:hover { color: var(--text); }

.theme-toggle, .menu-toggle {
  border: 1px solid var(--line);
  background: var(--surface);
  color: var(--text);
  width: 40px;
  height: 40px;
  border-radius: 50%;
  cursor: pointer;
}

.menu-toggle { display: none; font-size: 18px; }

.hero {
  min-height: calc(100vh - 76px);
  display: grid;
  grid-template-columns: 1.35fr .65fr;
  align-items: center;
  gap: 70px;
  padding-block: 90px;
}

.eyebrow {
  font-size: 11px;
  font-weight: 800;
  letter-spacing: .14em;
  color: var(--muted);
  margin-bottom: 20px;
}

.hero h1 {
  font-size: clamp(48px, 7vw, 88px);
  line-height: .98;
  letter-spacing: -.065em;
  max-width: 850px;
}

.hero h1 span { color: #91ad00; }

.hero-role {
  margin-top: 24px;
  font-weight: 700;
  font-size: 18px;
}

.hero-text {
  max-width: 590px;
  color: var(--muted);
  margin-top: 14px;
  font-size: 17px;
}

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

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 48px;
  padding: 0 22px;
  border-radius: 999px;
  font-size: 13px;
  font-weight: 700;
  transition: transform .2s, opacity .2s;
}
.btn:hover { transform: translateY(-2px); }
.btn-primary { background: var(--text); color: var(--bg); }
.btn-secondary { border: 1px solid var(--line); background: var(--surface); }

.profile-card {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 28px;
  padding: 14px;
  box-shadow: 0 20px 70px rgba(0,0,0,.07);
}

.profile-photo {
  aspect-ratio: 4 / 5;
  border-radius: 20px;
  overflow: hidden;
  background: #d8d8d3;
}

.profile-photo img { width: 100%; height: 100%; object-fit: cover; }
.photo-placeholder {
  width: 100%; height: 100%;
  display: grid; place-items: center;
  text-align: center;
  font-weight: 800; font-size: 22px;
  letter-spacing: .08em;
  color: #777;
}

.profile-meta { padding: 18px 6px 7px; display: grid; gap: 3px; }
.profile-meta strong { font-size: 13px; }
.profile-meta span { font-size: 12px; color: var(--muted); }

.section { padding-block: 120px; }
.section-muted { background: #ebeae5; }
.dark .section-muted { background: #151515; }

.section-heading { margin-bottom: 55px; }
.section-heading h2, .contact-section h2 {
  font-size: clamp(38px, 5vw, 64px);
  line-height: 1;
  letter-spacing: -.055em;
}

.about-grid {
  display: grid;
  grid-template-columns: 1.1fr .9fr;
  gap: 100px;
}

.large-copy { font-size: clamp(22px, 3vw, 34px); line-height: 1.3; letter-spacing: -.025em; }

.info-list { border-top: 1px solid var(--line); }
.info-list div {
  display: flex;
  justify-content: space-between;
  gap: 20px;
  padding: 17px 0;
  border-bottom: 1px solid var(--line);
  font-size: 13px;
}
.info-list span { color: var(--muted); }

.timeline { border-top: 1px solid var(--line); }
.timeline-item {
  display: grid;
  grid-template-columns: 190px 1fr;
  gap: 50px;
  padding: 36px 0;
  border-bottom: 1px solid var(--line);
}
.timeline-date { font-size: 11px; font-weight: 800; color: var(--muted); letter-spacing: .08em; }
.timeline-content h3 { font-size: 25px; letter-spacing: -.03em; }
.company { color: #849e00; font-weight: 700; font-size: 13px; margin: 4px 0 14px; }
.timeline-content p:not(.company), .timeline-content li { color: var(--muted); font-size: 14px; }
.timeline-content ul { margin: 14px 0 0 18px; }

.heading-row { display: flex; justify-content: space-between; align-items: end; gap: 30px; }
.hint { color: var(--muted); font-size: 12px; max-width: 250px; }

.projects-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; }
.project-card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; }
.project-image { aspect-ratio: 16 / 10; padding: 20px; display: flex; align-items: end; }
.project-image span { font-size: 70px; font-weight: 800; color: rgba(255,255,255,.75); letter-spacing: -.08em; }
.gradient-one { background: linear-gradient(135deg, #1d1d1d, #8ca800); }
.gradient-two { background: linear-gradient(135deg, #b6c9d7, #353535); }
.gradient-three { background: linear-gradient(135deg, #e4d8bc, #7b7b72); }
.project-body { padding: 24px; }
.project-type { font-size: 10px; letter-spacing: .12em; font-weight: 800; color: var(--muted); }
.project-body h3 { font-size: 22px; margin: 7px 0; }
.project-body p:not(.project-type) { color: var(--muted); font-size: 13px; margin-bottom: 18px; }
.project-body a { font-size: 12px; font-weight: 800; }

.section-dark { background: var(--dark); color: white; }
.section-dark .eyebrow { color: #9a9a9a; }
.skills-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 0; border-top: 1px solid #383838; }
.skill { padding: 30px 24px 10px 0; border-right: 1px solid #383838; margin-right: 24px; min-height: 180px; }
.skill:last-child { border-right: 0; margin-right: 0; }
.skill span { font-size: 11px; color: #8fa800; font-weight: 800; }
.skill h3 { font-size: 21px; margin: 24px 0 8px; }
.skill p { color: #a3a3a3; font-size: 13px; }

.contact-section { display: grid; grid-template-columns: 1fr 1fr; gap: 100px; align-items: end; }
.contact-copy p:last-child { color: var(--muted); max-width: 440px; margin-top: 20px; }
.contact-links { border-top: 1px solid var(--line); }
.contact-links a {
  display: flex; justify-content: space-between; gap: 20px;
  padding: 18px 0; border-bottom: 1px solid var(--line);
  font-size: 13px; font-weight: 600;
}
.contact-links span { color: var(--muted); font-weight: 400; }

.footer { border-top: 1px solid var(--line); padding: 24px 0; }
.footer-inner { display: flex; justify-content: space-between; color: var(--muted); font-size: 11px; }
.footer a { color: var(--text); }

@media (max-width: 850px) {
  .nav-links {
    display: none;
    position: absolute;
    left: 24px; right: 24px; top: 68px;
    background: var(--surface);
    border: 1px solid var(--line);
    border-radius: 16px;
    padding: 18px;
    flex-direction: column;
    gap: 16px;
  }
  .nav-links.open { display: flex; }
  .menu-toggle { display: block; }
  .hero, .about-grid, .contact-section { grid-template-columns: 1fr; }
  .hero { gap: 45px; padding-block: 70px; }
  .profile-card { max-width: 420px; }
  .projects-grid { grid-template-columns: 1fr; }
  .skills-grid { grid-template-columns: 1fr 1fr; }
  .skill { border-right: 0; border-bottom: 1px solid #383838; padding-bottom: 25px; margin-right: 15px; }
  .about-grid { gap: 45px; }
  .timeline-item { grid-template-columns: 1fr; gap: 10px; }
}

@media (max-width: 520px) {
  .container { width: min(calc(100% - 30px), var(--max-width)); }
  .hero h1 { font-size: 50px; }
  .hero-actions { flex-direction: column; align-items: stretch; }
  .section { padding-block: 80px; }
  .skills-grid { grid-template-columns: 1fr; }
  .heading-row { display: block; }
  .hint { margin-top: -30px; margin-bottom: 40px; }
}
