/* ====== EDIT THESE TO FINE-TUNE THE LOOK ====== */
:root {
  --header-bg: #111821;
  --bg: #111821;
  --surface: #111821;      /* client logo band */
  --card: #1c2533;         /* project cards */
  --text: #ffffff;
  --muted: #9aa4b0;
  --accent: #4aa8e8;       /* scroll arrow, active filter */
  --available: #8cc63f;
  --busy: #e05252;
  --font-head: "Montserrat", Helvetica, Arial, sans-serif;
  --font-body: "Open Sans", Helvetica, Arial, sans-serif;
  --max: 1120px;
  --pad: clamp(20px, 5vw, 40px);
}

/* ====== BASE ====== */
*, *::before, *::after { box-sizing: border-box; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font: 400 16px/1.7 var(--font-body);
  -webkit-font-smoothing: antialiased;
}
img { max-width: 100%; height: auto; display: block; }
a { color: inherit; }
h1, h2 { font-family: var(--font-head); line-height: 1.1; margin: 0; }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; }
.container { max-width: var(--max); margin: 0 auto; padding: 0 var(--pad); }

.skip-link { position: absolute; left: -9999px; }
.skip-link:focus { left: 10px; top: 10px; background: #fff; color: #000; padding: 8px 12px; z-index: 100; }
.visually-hidden {
  position: absolute; width: 1px; height: 1px; overflow: hidden;
  clip: rect(0 0 0 0); white-space: nowrap;
}

/* ====== HEADER ====== */
.site-header { background: var(--header-bg); }
.header-inner {
  display: flex; justify-content: space-between; align-items: center;
  min-height: 80px;
}
.logo img { height: 38px; width: auto; }
.social { display: flex; gap: 22px; list-style: none; margin: 0; padding: 0; }
.social a { font-size: 19px; text-decoration: none; transition: opacity .2s; }
.social a:hover { opacity: .6; }

/* ====== HERO ====== */
.hero {
  position: relative;
  min-height: calc(100vh - 80px);
  display: flex; align-items: center;
  padding: 60px 0 100px;
  background: var(--bg);
}
.hero .container { width: 100%; }
.hero h1 {
  font-size: clamp(36px, 5.2vw, 62px);
  font-weight: 700;
  text-transform: uppercase;
  max-width: 820px;
  min-height: 3.3em;          /* stops the page jumping while words type */
}
.typed-line { display: block; min-height: 1.1em; }
.cursor {
  display: inline-block; width: .07em; height: .85em;
  margin-left: .08em; vertical-align: -.05em;
  background: rgba(255, 255, 255, .45);
  animation: blink 1s steps(1) infinite;
}
@keyframes blink { 50% { opacity: 0; } }

.intro {
  font: 300 clamp(17px, 1.7vw, 21px)/1.6 var(--font-head);
  max-width: 540px; margin: 36px 0 20px;
}
.intro strong { font-family: var(--font-body); font-weight: 600; }
.chat { font-size: 22px; font-weight: 700; margin: 0 0 34px; }

.email-btn {
  display: inline-block;
  padding: 14px 32px;
  border: 2px solid rgba(255, 255, 255, .85);
  border-radius: 3px;
  font-weight: 600; font-size: 16px; text-decoration: none;
  transition: background .2s, color .2s;
}
.email-btn:hover { background: #fff; color: var(--bg); }

.status {
  display: flex; align-items: center; gap: 10px;
  margin: 36px 0 0;
  font: 400 11px var(--font-head); letter-spacing: .15em; text-transform: uppercase;
}
.status::before { content: ""; width: 8px; height: 8px; border-radius: 50%; }
.status.available::before { background: var(--available); }
.status.busy::before { background: var(--busy); }

.scroll-down {
  position: absolute; left: 50%; bottom: 60px; transform: translateX(-50%);
  color: var(--accent); font-size: 18px; text-decoration: none;
}

/* ====== WORK ====== */
.work { padding: 70px clamp(20px, 3.3vw, 65px) 110px; }
.filters {
  display: flex; flex-wrap: wrap; justify-content: center;
  gap: 10px 36px; margin-bottom: 70px;
}
.filters button {
  position: relative;
  background: none; border: 0; padding: 4px 0; cursor: pointer;
  font: 400 17px var(--font-body); color: var(--text);
  opacity: .85;
}
.filters button:hover { opacity: 1; }
.filters button[aria-pressed="true"] { opacity: 1; }
.filters button[aria-pressed="true"]::after {
  content: ""; position: absolute; left: 0; right: 0; bottom: -6px;
  height: 2px; background: var(--accent);
}

.grid {
  display: grid; gap: 40px 38px;
  grid-template-columns: 1fr;
  max-width: 1900px; margin: 0 auto;
}
@media (min-width: 600px)  { .grid { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 950px)  { .grid { grid-template-columns: repeat(3, 1fr); } }
@media (min-width: 1300px) { .grid { grid-template-columns: repeat(4, 1fr); } }

.project {
  position: relative;
  background: var(--card);
  border-radius: 4px; overflow: hidden;
  text-align: center;
}
.project[hidden] { display: none; }
.thumb { aspect-ratio: 410 / 321; overflow: hidden; }
.thumb img { width: 100%; height: 100%; object-fit: cover; transition: transform .6s; }
.project:hover .thumb img { transform: scale(1.04); }

.card-body { padding: 26px clamp(20px, 2.2vw, 40px) 50px; }
.tags {
  display: flex; flex-wrap: wrap; justify-content: center; gap: 0 12px;
  margin: 0 0 8px; font-size: 16px;
}
.project h2 {
  font: 400 clamp(22px, 1.6vw, 28px)/1.25 var(--font-head);
  margin-bottom: 16px;
}
.project h2 a { text-decoration: none; }
/* Makes the whole card clickable */
.project h2 a::after { content: ""; position: absolute; inset: 0; }
.project h2 a:focus-visible { outline: none; }
.project:has(a:focus-visible) { outline: 2px solid var(--accent); outline-offset: 3px; }
.excerpt { margin: 0; font-size: 16px; line-height: 1.95; }

/* ====== CLIENTS ====== */
.clients { background: var(--surface); padding: 100px 0; text-align: center; }
.clients h2 { font-size: clamp(22px, 3vw, 30px); max-width: 24ch; margin: 0 auto 16px; }
.clients p { color: var(--muted); max-width: 40em; margin: 0 auto 60px; }
.marquee {
  overflow: hidden;
  -webkit-mask-image: linear-gradient(to right, transparent, #000 6%, #000 94%, transparent);
          mask-image: linear-gradient(to right, transparent, #000 6%, #000 94%, transparent);
}
.marquee-track {
  display: flex; width: max-content;
  animation: marquee 45s linear infinite;   /* bigger number = slower */
}
.marquee:hover .marquee-track,
.marquee:focus-within .marquee-track { animation-play-state: paused; }
@keyframes marquee { to { transform: translateX(-25%); } }
.logos {
  display: flex; align-items: center; flex-shrink: 0;
  gap: 90px; padding: 0 45px; margin: 0; list-style: none;
}
.logos img { max-height: 46px; width: auto; max-width: none; opacity: .85; }
@media (prefers-reduced-motion: reduce) {
  .marquee { -webkit-mask-image: none; mask-image: none; }
  .marquee-track { width: auto; justify-content: center; animation: none; }
  .marquee-track .logos { flex-wrap: wrap; justify-content: center; gap: 40px 60px; }
  .marquee-track .logos[aria-hidden] { display: none; }
}

/* ====== FOOTER ====== */
.site-footer { text-align: center; padding: 30px var(--pad); font-size: 13px; color: var(--muted); background: var(--header-bg); }
.site-footer p { margin: 0; }

/* ====== SMALL SCREENS ====== */
@media (max-width: 600px) {
  .logo img { height: 30px; }
  .social { gap: 16px; }
  .social a { font-size: 16px; }
  .scroll-down { display: none; }
}

@media (prefers-reduced-motion: reduce) {
  *, .cursor { transition: none !important; animation: none !important; }
}