/* adambreznicky.com
   self-contained styles. no framework, no build step.

   NOTE: both pages link this file with a ?v= version string. bump it in
   index.html and resume.html whenever this file changes, otherwise browsers
   holding an old copy will keep rendering it. */

@font-face {
  font-family: "Source Sans Pro";
  src: url("fonts/sourcesanspro-regular-webfont.woff") format("woff");
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}

:root {
  --accent: #489ac1;
  --accent-dark: #2f7fa4;
  --accent-wash: #eaf4f9;
  --ink: #23292c;
  --ink-soft: #5f6b70;
  --ink-faint: #8a969b;
  --rule: #e2e6e8;
  --bg: #ffffff;
  --bg-soft: #f7f9fa;
  --band: linear-gradient(180deg, #f4f9fb 0%, #ffffff 100%);
  --shadow: 0 1px 2px rgba(20, 40, 50, 0.04), 0 6px 18px rgba(20, 40, 50, 0.05);
  --shadow-lift: 0 2px 4px rgba(20, 40, 50, 0.06), 0 12px 28px rgba(20, 40, 50, 0.09);
  --measure: 64rem;
  --copy: 46rem;
  --radius: 12px;
}

@media (prefers-color-scheme: dark) {
  :root {
    --accent: #6cb8d8;
    --accent-dark: #9ed3ea;
    --accent-wash: #1a2b33;
    --ink: #e9edef;
    --ink-soft: #a3b0b6;
    --ink-faint: #78868c;
    --rule: #2b3337;
    --bg: #15181a;
    --bg-soft: #1c2124;
    --band: linear-gradient(180deg, #1b2226 0%, #15181a 100%);
    --shadow: 0 1px 2px rgba(0, 0, 0, 0.3), 0 6px 18px rgba(0, 0, 0, 0.25);
    --shadow-lift: 0 2px 4px rgba(0, 0, 0, 0.35), 0 12px 28px rgba(0, 0, 0, 0.4);
  }
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  padding: 0;
  /* column layout so the footer sits at the bottom of the viewport on short
     pages (resume) instead of floating in the middle */
  display: flex;
  flex-direction: column;
  min-height: 100vh;
  background: var(--bg);
  color: var(--ink);
  font-family: "Source Sans Pro", Helvetica, Arial, Geneva, sans-serif;
  font-size: 17px;
  line-height: 1.65;
  text-transform: lowercase;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

.wrap {
  max-width: var(--measure);
  margin: 0 auto;
  padding: 0 1.5rem;
  width: 100%;
}

/* the content wrap (not the one nested in the masthead) takes the slack */
body > .wrap { flex: 1 0 auto; }

a { color: var(--accent); }
a:hover { color: var(--accent-dark); }

:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 3px;
  border-radius: 3px;
}

/* ---------- header ---------- */

.masthead {
  background: var(--band);
  border-bottom: 1px solid var(--rule);
}

.identity {
  display: flex;
  align-items: center;
  gap: 1.25rem;
  flex-wrap: wrap;
  padding: 2.75rem 0 2rem;
}

#gravatar {
  width: 84px;
  height: 84px;
  border-radius: 50%;
  flex: 0 0 auto;
  object-fit: cover;
  box-shadow: 0 0 0 4px var(--bg), 0 0 0 5px var(--rule), var(--shadow);
}

.identity-text { min-width: 0; }

#title-name {
  margin: 0;
  font-size: 2.4rem;
  font-weight: 600;
  line-height: 1.1;
  letter-spacing: -0.02em;
}

.tagline {
  margin: 0.35rem 0 0;
  color: var(--ink-soft);
  font-size: 1.05rem;
}

.availability {
  margin-left: auto;
  align-self: center;
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  background: var(--bg);
  border: 1px solid var(--rule);
  border-radius: 999px;
  padding: 0.4rem 0.9rem;
  font-size: 0.9rem;
  color: var(--ink-soft);
  box-shadow: var(--shadow);
  white-space: nowrap;
}

.availability::before {
  content: "";
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: #43b581;
  box-shadow: 0 0 0 3px rgba(67, 181, 129, 0.18);
  flex: 0 0 auto;
}

/* ---------- navigation ---------- */

nav {
  border-top: 1px solid var(--rule);
}

nav ul {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem 1.75rem;
}

nav a {
  display: inline-block;
  color: var(--ink-soft);
  text-decoration: none;
  padding: 0.85rem 0;
  border-bottom: 2px solid transparent;
  transition: color 0.15s ease, border-color 0.15s ease;
}

nav a:hover,
nav a:focus-visible {
  color: var(--accent);
  border-bottom-color: var(--accent);
}

nav a[aria-current="page"] {
  color: var(--ink);
  border-bottom-color: var(--accent);
  font-weight: 600;
}

/* ---------- content ---------- */

main { padding: 3rem 0 4rem; }

main > p { max-width: var(--copy); }

p { margin: 0 0 1.15rem; }

h2 {
  font-size: 1.6rem;
  font-weight: 600;
  letter-spacing: -0.01em;
  margin: 3.5rem 0 1.5rem;
  padding-top: 1.5rem;
  border-top: 1px solid var(--rule);
  position: relative;
}

h2::after {
  content: "";
  position: absolute;
  top: -1px;
  left: 0;
  width: 3.5rem;
  height: 3px;
  background: var(--accent);
  border-radius: 2px;
}

.lede {
  font-size: 1.3rem;
  line-height: 1.5;
  color: var(--ink);
  margin-bottom: 1.5rem;
}

.pitch {
  font-size: 1.15rem;
  color: var(--ink);
  font-style: italic;
  background: var(--accent-wash);
  border-left: 3px solid var(--accent);
  border-radius: 0 var(--radius) var(--radius) 0;
  padding: 1rem 1.25rem;
  margin: 2.25rem 0;
  max-width: var(--copy);
}

.cta { margin: 2rem 0 0; }

/* ---------- services ---------- */

.services {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(17rem, 1fr));
  gap: 1.25rem;
}

.services li {
  background: var(--bg-soft);
  border: 1px solid var(--rule);
  border-radius: var(--radius);
  padding: 1.35rem 1.4rem;
  position: relative;
  overflow: hidden;
  transition: transform 0.18s ease, box-shadow 0.18s ease, border-color 0.18s ease;
}

.services li::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 3px;
  background: var(--accent);
  opacity: 0;
  transition: opacity 0.18s ease;
}

.services li:hover {
  transform: translateY(-3px);
  box-shadow: var(--shadow-lift);
  border-color: transparent;
}

.services li:hover::before { opacity: 1; }

.services h3 {
  font-size: 1.05rem;
  font-weight: 600;
  color: var(--ink);
  margin: 0 0 0.6rem;
}

.services p {
  margin: 0;
  color: var(--ink-soft);
  font-size: 0.95rem;
  line-height: 1.6;
}

/* ---------- technology stack ---------- */

.stack {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(16rem, 1fr));
  gap: 2rem;
}

.stack h3 {
  font-size: 0.8rem;
  font-weight: 600;
  letter-spacing: 0.09em;
  text-transform: uppercase;
  color: var(--ink-faint);
  margin: 0 0 0.9rem;
}

.chips {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
}

.chips li {
  background: var(--bg-soft);
  border: 1px solid var(--rule);
  border-radius: 999px;
  padding: 0.25rem 0.7rem;
  font-size: 0.87rem;
  color: var(--ink-soft);
  line-height: 1.5;
}

/* ---------- buttons ---------- */

.button {
  display: inline-block;
  background: var(--accent);
  color: #fff;
  text-decoration: none;
  padding: 0.75rem 1.6rem;
  border-radius: 8px;
  font-size: 1.05rem;
  font-weight: 600;
  box-shadow: var(--shadow);
  transition: background 0.15s ease, transform 0.15s ease, box-shadow 0.15s ease;
}

.button:hover,
.button:focus-visible {
  background: var(--accent-dark);
  color: #fff;
  transform: translateY(-2px);
  box-shadow: var(--shadow-lift);
}

@media (prefers-color-scheme: dark) {
  .button { color: #10161a; }
  .button:hover, .button:focus-visible { color: #10161a; }
}

.contact-line {
  margin-top: 2.5rem;
  color: var(--ink-soft);
}

/* ---------- resume page ---------- */

.resume-card {
  max-width: 38rem;
  margin: 2rem auto 4rem;
  text-align: center;
  background: var(--bg-soft);
  border: 1px solid var(--rule);
  border-radius: var(--radius);
  padding: 3rem 2.5rem;
  box-shadow: var(--shadow);
}

.resume-card h2 {
  margin: 0 0 1.25rem;
  padding-top: 0;
  border-top: 0;
}

.resume-card h2::after {
  left: 50%;
  transform: translateX(-50%);
  top: auto;
  bottom: -0.6rem;
}

.resume-card .lede { margin-bottom: 1.25rem; }

.resume-card p {
  color: var(--ink-soft);
  max-width: none;
}

.resume-card .lede { color: var(--ink); }

.resume-card .cta { margin-top: 1.75rem; }

/* ---------- footer ---------- */

footer {
  margin-top: auto;
  background: var(--bg-soft);
  border-top: 1px solid var(--rule);
  color: var(--ink-soft);
  font-size: 0.92rem;
}

.footer-inner {
  display: flex;
  flex-wrap: wrap;
  gap: 1.5rem 2rem;
  justify-content: space-between;
  align-items: flex-start;
  padding: 2.5rem 0;
}

.footer-name {
  font-size: 1.15rem;
  font-weight: 600;
  color: var(--ink);
  margin: 0 0 0.2rem;
}

.footer-links {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem 1.25rem;
  text-align: right;
}

.footer-links a { text-decoration: none; }
.footer-links a:hover { text-decoration: underline; }

/* ---------- small screens ---------- */

@media only screen and (max-width: 700px) {
  body { font-size: 16px; }

  .identity {
    padding: 2rem 0 1.5rem;
    gap: 1rem;
  }

  #gravatar { width: 64px; height: 64px; }

  #title-name { font-size: 1.75rem; }

  .availability {
    margin-left: 0;
    width: auto;
  }

  .lede { font-size: 1.15rem; }

  h2 { font-size: 1.35rem; margin-top: 2.75rem; }

  nav ul { gap: 0.25rem 1.25rem; }

  .footer-links { text-align: left; }
}
