/* ==========================================================
   Portfolio template
   Change the colors and fonts here: everything else follows.
   ========================================================== */
:root {
  --paper:   #F4F6F3;
  --mint:    #E3EFE8;
  --ink:     #17262B;
  --muted:   #55666B;
  --accent:  #2C4BFF;
  --accent-dark: #1F37CC;
  --sun:     #FFC93C;
  --line:    #CBD6D1;

  --font-display: "Bricolage Grotesque", system-ui, sans-serif;
  --font-body:    "Public Sans", system-ui, sans-serif;

  --radius: 14px;
  --section-space: clamp(4rem, 8vw, 7rem);
}

html { scroll-behavior: smooth; scroll-padding-top: 80px; }
body {
  font-family: var(--font-body);
  background: var(--paper);
  color: var(--ink);
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
}
h1, h2, h3, .navbar-brand { font-family: var(--font-display); letter-spacing: -0.02em; }
a { color: var(--accent); }
a:hover { color: var(--accent-dark); }
:focus-visible { outline: 3px solid var(--accent); outline-offset: 3px; border-radius: 4px; }

.skip-link {
  position: absolute; left: 1rem; top: -4rem; z-index: 2000;
  background: var(--ink); color: #fff; padding: .6rem 1rem; border-radius: 8px;
}
.skip-link:focus { top: 1rem; color: #fff; }

/* ---------- Buttons ---------- */
.btn { font-weight: 600; border-radius: 10px; }
.btn-accent { background: var(--accent); border-color: var(--accent); color: #fff; }
.btn-accent:hover, .btn-accent:focus { background: var(--accent-dark); border-color: var(--accent-dark); color: #fff; }
.btn-outline-ink { border: 2px solid var(--ink); color: var(--ink); background: transparent; }
.btn-outline-ink:hover { background: var(--ink); color: #fff; }

/* ---------- Navigation ---------- */
.site-nav { background: rgba(244, 246, 243, .92); backdrop-filter: blur(8px); border-bottom: 1px solid transparent; transition: border-color .2s; }
.site-nav.scrolled { border-bottom-color: var(--line); }
.navbar-brand { display: flex; align-items: center; gap: .6rem; font-weight: 700; color: var(--ink); }
.brand-mark {
  display: inline-grid; place-items: center; width: 2.2rem; height: 2.2rem;
  background: var(--ink); color: var(--sun); border-radius: 10px; font-size: .95rem;
}
.site-nav .nav-link { color: var(--ink); font-weight: 500; }
.site-nav .nav-link.active { color: var(--accent); }
.navbar-toggler { border: 0; padding: 0; }
.navbar-toggler:focus { box-shadow: none; }

/* ---------- Hero ---------- */
.hero { padding: clamp(3rem, 7vw, 6rem) 0 var(--section-space); }
.status-badge {
  display: inline-flex; align-items: center; gap: .6rem;
  background: #fff; border: 1px solid var(--line); border-radius: 999px;
  padding: .35rem 1rem; font-size: .9rem; font-weight: 500; margin-bottom: 1.5rem;
}
.status-badge .dot { width: .6rem; height: .6rem; border-radius: 50%; background: #1FA463; }
.hero-title {
  font-size: clamp(3.2rem, 9vw, 7rem);
  font-weight: 800; line-height: .95; letter-spacing: -0.04em; margin-bottom: 1rem;
}
.hero-role { font-family: var(--font-display); font-size: clamp(1.25rem, 2.6vw, 1.75rem); font-weight: 600; margin-bottom: .75rem; }
.hero-lead { font-size: 1.15rem; color: var(--muted); max-width: 34rem; }

.portrait { position: relative; max-width: 420px; margin-left: auto; }
.portrait::before {
  content: ""; position: absolute; inset: 1.25rem -1.25rem -1.25rem 1.25rem;
  background: var(--sun); border-radius: 28px;
}
.portrait img { position: relative; width: 100%; height: auto; border-radius: 28px; display: block; background: var(--mint); }

/* ---------- Sections ---------- */
.section { padding: var(--section-space) 0; }
.section-alt { background: var(--mint); }
.section-dark { background: var(--ink); color: #E6EDEA; }
.section-title { font-size: clamp(2rem, 4.5vw, 3rem); font-weight: 800; margin-bottom: 1rem; }
.prose { font-size: 1.1rem; max-width: 40rem; }
.lead-light { color: #B7C5C0; font-size: 1.1rem; }
.section-dark a.link-light { text-decoration-color: var(--sun); }

.skill-group { font-size: 1.05rem; font-weight: 700; margin-bottom: .5rem; }
.skill-list li { padding: .3rem 0; border-top: 1px solid var(--line); color: var(--muted); }

/* ---------- Work grid ---------- */
.filters { display: flex; flex-wrap: wrap; gap: .5rem; }
.filter-btn {
  border: 1.5px solid var(--ink); background: transparent; color: var(--ink);
  border-radius: 999px; padding: .3rem 1rem; font-weight: 500; font-size: .95rem; cursor: pointer;
}
.filter-btn:hover { background: #fff; }
.filter-btn.active { background: var(--ink); color: #fff; }

.project-card { display: block; text-decoration: none; color: inherit; height: 100%; background: #fff; border-radius: var(--radius); overflow: hidden; border: 1px solid var(--line); }
.project-card:hover { color: inherit; border-color: var(--ink); }
.project-thumb { aspect-ratio: 16 / 11; overflow: hidden; background: var(--mint); }
.project-thumb img { width: 100%; height: 100%; object-fit: cover; transition: transform .35s ease; }
.project-card:hover .project-thumb img { transform: scale(1.04); }
.project-body { padding: 1.25rem 1.4rem 1.5rem; }
.project-meta { display: flex; justify-content: space-between; font-size: .85rem; color: var(--muted); margin-bottom: .4rem; }
.project-title { font-size: 1.35rem; font-weight: 700; margin-bottom: .35rem; }
.project-summary { margin: 0; color: var(--muted); font-size: .98rem; }
.project-item.is-hidden { display: none; }

/* ---------- Timeline (a real sequence, so it is ordered) ---------- */
.timeline { list-style: none; padding: 0; margin: 2rem 0 0; max-width: 46rem; }
.timeline li { display: grid; grid-template-columns: 9.5rem 1fr; gap: 1.5rem; padding: 1.5rem 0; border-top: 1px solid var(--line); }
.timeline li:last-child { border-bottom: 1px solid var(--line); }
.timeline-years { font-weight: 600; color: var(--muted); }
.timeline-title { font-size: 1.2rem; font-weight: 700; margin-bottom: .25rem; }

/* ---------- Contact form ---------- */
.section-dark .form-label { font-weight: 500; }
.section-dark .form-control {
  background: #213439; border: 1px solid #36505A; color: #fff; border-radius: 10px; padding: .75rem 1rem;
}
.section-dark .form-control:focus { background: #213439; color: #fff; border-color: var(--sun); box-shadow: 0 0 0 .2rem rgba(255, 201, 60, .25); }
.section-dark .btn-accent { background: var(--sun); border-color: var(--sun); color: var(--ink); }
.section-dark .btn-accent:hover { background: #ffd966; border-color: #ffd966; }
.section-dark .socials a { color: #fff; }

/* ---------- Project page ---------- */
.back-link { display: inline-block; margin-bottom: 1.5rem; font-weight: 600; text-decoration: none; }
.project-h1 { font-size: clamp(2.6rem, 7vw, 5rem); }
.gallery-item { display: block; border-radius: var(--radius); overflow: hidden; border: 1px solid var(--line); background: var(--mint); }
.gallery-item img { width: 100%; height: auto; display: block; }
.facts { margin: 1.5rem 0; }
.facts dt { font-weight: 700; margin-top: 1rem; }
.facts dd { margin: 0; color: var(--muted); }
.tag { display: inline-block; background: #fff; border: 1px solid var(--line); border-radius: 999px; padding: .1rem .7rem; font-size: .88rem; margin: 0 .35rem .35rem 0; color: var(--ink); }
.project-nav { display: flex; justify-content: space-between; gap: 1rem; margin-top: 4rem; padding-top: 2rem; border-top: 1px solid var(--line); }
.project-nav a { text-decoration: none; color: var(--ink); }
.project-nav small { display: block; color: var(--muted); }
.project-nav span { font-family: var(--font-display); font-size: 1.4rem; font-weight: 700; }

/* ---------- Footer ---------- */
.site-footer { background: var(--ink); color: #B7C5C0; padding: 1.75rem 0; border-top: 1px solid #2B4249; }
.site-footer .socials a { color: #fff; font-size: 1.3rem; }
.site-footer .socials a:hover { color: var(--sun); }

/* ---------- Small screens ---------- */
@media (max-width: 767.98px) {
  .timeline li { grid-template-columns: 1fr; gap: .25rem; }
  .portrait { margin: 0 1.25rem 0 0; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  * { transition: none !important; }
}
