/* ============================================================
   Jared's Showcase — shared stylesheet
   Light theme, responsive, no frameworks.
   ============================================================ */

:root {
  --bg: #fafafa;
  --surface: #ffffff;
  --text: #1a1a2e;
  --muted: #5c6270;
  --accent: #2563eb;
  --accent-dark: #1d4ed8;
  --accent-soft: #eff6ff;
  --border: #e5e7eb;
  --radius: 12px;
  --shadow: 0 1px 3px rgba(0, 0, 0, 0.08), 0 4px 12px rgba(0, 0, 0, 0.05);
  --shadow-hover: 0 4px 8px rgba(0, 0, 0, 0.1), 0 8px 24px rgba(0, 0, 0, 0.08);
  --max-width: 1080px;
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  background: var(--bg);
  color: var(--text);
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
}

/* ---------- Skip link ---------- */

/* Parked off-screen until focused, then it drops in over the header. */
.skip-link {
  position: fixed;
  top: 0.75rem;
  left: 0.75rem;
  z-index: 200;
  padding: 0.6rem 1.1rem;
  border-radius: 8px;
  background: var(--accent);
  color: #fff;
  font-weight: 600;
  font-size: 0.9rem;
  text-decoration: none;
  box-shadow: var(--shadow-hover);
  transform: translateY(calc(-100% - 1.5rem));
  transition: transform 0.18s ease;
}

.skip-link:focus,
.skip-link:focus-visible {
  transform: translateY(0);
  outline: 2px solid #fff;
  outline-offset: 2px;
}

/* The skip target must not draw a focus ring when jumped to. */
main:focus {
  outline: none;
}

main {
  scroll-margin-top: 80px;
}

/* ---------- Header / Nav ---------- */

.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(255, 255, 255, 0.92);
  backdrop-filter: blur(8px);
  border-bottom: 1px solid var(--border);
}

.nav-inner {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 1.25rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 64px;
}

.brand {
  font-weight: 800;
  font-size: 1.15rem;
  color: var(--text);
  text-decoration: none;
  letter-spacing: -0.02em;
}

.brand span {
  color: var(--accent);
}

.nav-links {
  display: flex;
  gap: 0.25rem;
  list-style: none;
}

.nav-links a {
  display: block;
  padding: 0.5rem 0.9rem;
  border-radius: 8px;
  color: var(--muted);
  text-decoration: none;
  font-weight: 500;
  font-size: 0.95rem;
  transition: color 0.15s, background 0.15s;
}

.nav-links a:hover {
  color: var(--text);
  background: var(--accent-soft);
}

.nav-links a.active {
  color: var(--accent);
  background: var(--accent-soft);
  font-weight: 600;
}

.nav-toggle {
  display: none;
  background: none;
  border: none;
  cursor: pointer;
  padding: 0.5rem;
}

.nav-toggle svg {
  width: 26px;
  height: 26px;
  stroke: var(--text);
}

/* ---------- Layout ---------- */

.container {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 2.5rem 1.25rem 4rem;
}

.page-title {
  font-size: 2.2rem;
  font-weight: 800;
  letter-spacing: -0.03em;
  margin-bottom: 0.5rem;
}

.page-subtitle {
  color: var(--muted);
  font-size: 1.1rem;
  margin-bottom: 2.5rem;
  max-width: 640px;
}

/* ---------- Hero (home) ---------- */

.hero {
  padding: 4.5rem 0 3rem;
}

.hero h1 {
  font-size: clamp(2.2rem, 5vw, 3.2rem);
  font-weight: 800;
  letter-spacing: -0.03em;
  line-height: 1.15;
  margin-bottom: 1rem;
}

.hero h1 em {
  color: var(--accent);
  font-style: normal;
}

.hero .lead {
  font-size: 1.2rem;
  color: var(--muted);
  max-width: 680px;
  margin-bottom: 2rem;
}

.hero-actions {
  display: flex;
  gap: 0.75rem;
  flex-wrap: wrap;
}

/* ---------- Buttons ---------- */

.btn {
  display: inline-block;
  padding: 0.7rem 1.4rem;
  border-radius: 10px;
  font-weight: 600;
  font-size: 0.98rem;
  text-decoration: none;
  transition: transform 0.12s, box-shadow 0.12s, background 0.12s;
  border: 1px solid transparent;
}

.btn:active {
  transform: translateY(1px);
}

.btn-primary {
  background: var(--accent);
  color: #fff;
}

.btn-primary:hover {
  background: var(--accent-dark);
  box-shadow: var(--shadow-hover);
}

.btn-secondary {
  background: var(--surface);
  color: var(--text);
  border-color: var(--border);
}

.btn-secondary:hover {
  border-color: var(--accent);
  color: var(--accent);
}

/* ---------- Cards / grids ---------- */

.grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
  gap: 1.5rem;
}

.card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1.5rem;
  box-shadow: var(--shadow);
  transition: transform 0.15s, box-shadow 0.15s;
  display: flex;
  flex-direction: column;
}

.card:hover {
  transform: translateY(-3px);
  box-shadow: var(--shadow-hover);
}

.card h3 {
  font-size: 1.2rem;
  margin-bottom: 0.4rem;
  letter-spacing: -0.01em;
  text-align: center;
}

.card h3 a {
  color: var(--text);
  text-decoration: none;
}

.card h3 a:hover {
  color: var(--accent);
}

.card p {
  color: var(--muted);
  font-size: 0.95rem;
  flex-grow: 1;
  text-align: center;
}

.card .media-slot {
  margin: 0 0 1rem;
  border-radius: 8px;
  overflow: hidden;
  background: var(--accent-soft);
  border: 1px dashed var(--border);
  aspect-ratio: 16 / 9;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--muted);
  font-size: 0.85rem;
}

.card .media-slot img,
.card .media-slot video {
  width: 100%;
  height: 100%;
  object-fit: cover;
  border: none;
}

/* Logo variant for cards — contain instead of crop, with breathing room */
.card .media-slot.logo-slot img,
.media-slot.logo-slot img {
  object-fit: contain;
  background: #fafafa;
  padding: 1rem;
}

.tags {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
  margin-top: 1rem;
  justify-content: center;
}

.tag {
  font-size: 0.75rem;
  font-weight: 600;
  padding: 0.2rem 0.6rem;
  border-radius: 999px;
  background: var(--accent-soft);
  color: var(--accent-dark);
}

.card-links {
  margin-top: 1rem;
  display: flex;
  gap: 1rem;
  justify-content: center;
  flex-wrap: wrap;
}

.card-links a {
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--accent);
  text-decoration: none;
}

.card-links a:hover {
  text-decoration: underline;
}

/* ---------- Sections ---------- */

.section {
  margin-bottom: 3rem;
}

.section h2 {
  font-size: 1.6rem;
  font-weight: 700;
  letter-spacing: -0.02em;
  margin-bottom: 1rem;
}

.about-list {
  list-style: none;
  margin-top: 1rem;
}

.about-list li {
  padding: 0.6rem 0 0.6rem 1.75rem;
  position: relative;
  color: var(--muted);
  border-bottom: 1px solid var(--border);
}

.about-list li:last-child {
  border-bottom: none;
}

.about-list li::before {
  content: "→";
  position: absolute;
  left: 0;
  color: var(--accent);
  font-weight: 700;
}

.about-list li strong {
  color: var(--text);
}

/* ---------- Forms ---------- */

.form-group {
  margin-bottom: 1.25rem;
}

.form-group label {
  display: block;
  font-weight: 600;
  font-size: 0.92rem;
  margin-bottom: 0.35rem;
}

.form-group input,
.form-group textarea,
.form-group select {
  width: 100%;
  padding: 0.7rem 0.9rem;
  border: 1px solid var(--border);
  border-radius: 8px;
  font-size: 0.98rem;
  font-family: inherit;
  background: var(--surface);
  color: var(--text);
  transition: border-color 0.15s, box-shadow 0.15s;
}

.form-group input:focus,
.form-group textarea:focus,
.form-group select:focus {
  outline: none;
  border-color: var(--accent);
  box-shadow: 0 0 0 3px var(--accent-soft);
}

.form-group textarea {
  min-height: 140px;
  resize: vertical;
}

.form-note {
  font-size: 0.85rem;
  color: var(--muted);
  margin-top: 0.5rem;
}

/* ---------- Contact list ---------- */

.contact-list {
  list-style: none;
}

.contact-list li {
  padding: 1rem 0;
  border-bottom: 1px solid var(--border);
  display: flex;
  align-items: baseline;
  gap: 0.75rem;
}

.contact-list li:last-child {
  border-bottom: none;
}

.contact-list .label {
  font-weight: 700;
  min-width: 110px;
  color: var(--muted);
  font-size: 0.9rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.contact-list a {
  color: var(--accent);
  text-decoration: none;
  font-weight: 500;
}

.contact-list a:hover {
  text-decoration: underline;
}

/* ---------- Footer ---------- */

.site-footer {
  border-top: 1px solid var(--border);
  padding: 2rem 1.25rem;
  text-align: center;
  color: var(--muted);
  font-size: 0.88rem;
}

.site-footer a {
  color: var(--accent);
  text-decoration: none;
}

.site-footer a:hover {
  text-decoration: underline;
}

/* ---------- Mobile ---------- */

@media (max-width: 768px) {
  .nav-toggle {
    display: block;
  }

  .nav-links {
    display: none;
    position: absolute;
    top: 64px;
    left: 0;
    right: 0;
    background: var(--surface);
    border-bottom: 1px solid var(--border);
    flex-direction: column;
    padding: 0.5rem 1rem 1rem;
    box-shadow: var(--shadow-hover);
  }

  .nav-links.open {
    display: flex;
  }

  .nav-links a {
    padding: 0.85rem 1rem;
    font-size: 1.05rem;
  }

  .hero {
    padding: 3rem 0 2rem;
  }

  .page-title {
    font-size: 1.8rem;
  }

  .container {
    padding-top: 1.5rem;
  }
}

  /* ============================================================
     Project detail pages
     ============================================================ */

  .breadcrumb {
    font-size: 0.88rem;
    color: var(--muted);
    margin-bottom: 1.5rem;
    text-align: center;
  }

  .breadcrumb a {
    color: var(--accent);
    text-decoration: none;
  }

  .breadcrumb a:hover {
    text-decoration: underline;
  }

  .breadcrumb .sep {
    margin: 0 0.45rem;
    opacity: 0.45;
  }

  .detail-header {
    margin-bottom: 2rem;
    text-align: center;
  }

  .detail-header .eyebrow {
    display: inline-block;
    font-size: 0.72rem;
    font-weight: 700;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: var(--accent-dark);
    background: var(--accent-soft);
    padding: 0.28rem 0.75rem;
    border-radius: 999px;
    margin-bottom: 0.9rem;
  }

  .detail-header h1 {
    font-size: clamp(1.9rem, 4vw, 2.5rem);
    letter-spacing: -0.03em;
    line-height: 1.15;
    margin-bottom: 0.6rem;
  }

  .detail-header .tagline {
    font-size: 1.08rem;
    color: var(--muted);
    max-width: 64ch;
    margin-left: auto;
    margin-right: auto;
  }

  .detail-header .card-links {
    margin-top: 1.1rem;
    justify-content: center;
  }

  .hero-shot {
    margin: 0 0 2.5rem;
    border: 1px solid var(--border);
    border-radius: var(--radius);
    overflow: hidden;
    background: var(--surface);
    box-shadow: var(--shadow);
  }

  .hero-shot img {
    display: block;
    width: 100%;
    height: auto;
  }

  .hero-shot figcaption {
    padding: 0.7rem 1rem;
    font-size: 0.84rem;
    color: var(--muted);
    border-top: 1px solid var(--border);
    background: #fcfcfd;
    text-align: center;
  }

  /* Logo / artwork variant — never stretch, never crop */
  .hero-shot.logo-shot {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 2.25rem 1.5rem;
    background: #fafafa;
  }

  .hero-shot.logo-shot img {
    width: auto;
    height: auto;
    max-width: min(100%, 440px);
    max-height: 280px;
  }

  .meta-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
    gap: 1.15rem;
    margin: 0 0 2.5rem;
    padding: 1.35rem 1.5rem;
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    box-shadow: var(--shadow);
  }

  .meta-item {
    text-align: center;
  }

  .meta-item dt {
    font-size: 0.72rem;
    font-weight: 700;
    letter-spacing: 0.07em;
    text-transform: uppercase;
    color: var(--muted);
    margin-bottom: 0.3rem;
  }

  .meta-item dd {
    font-size: 0.95rem;
    font-weight: 600;
  }

  .prose {
    max-width: 74ch;
  }

  .prose h2 {
    font-size: 1.5rem;
    font-weight: 700;
    letter-spacing: -0.02em;
    margin: 2.5rem 0 0.9rem;
    scroll-margin-top: 80px;
  }

  .prose h3 {
    font-size: 1.12rem;
    font-weight: 700;
    margin: 1.8rem 0 0.6rem;
  }

  .prose p {
    margin-bottom: 1.05rem;
    color: var(--muted);
  }

  .prose p strong,
  .prose li strong {
    color: var(--text);
  }

  .prose a {
    color: var(--accent);
  }

  .prose ul,
  .prose ol {
    margin: 0 0 1.2rem 1.35rem;
    color: var(--muted);
  }

  .prose li {
    margin-bottom: 0.45rem;
  }

  .prose code {
    font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
    font-size: 0.88em;
    background: #f3f4f6;
    border: 1px solid var(--border);
    border-radius: 5px;
    padding: 0.1rem 0.35rem;
    color: #b91c1c;
  }

  .prose pre {
    background: #1a1a2e;
    color: #e8e8f0;
    border-radius: 10px;
    padding: 1.1rem 1.25rem;
    overflow-x: auto;
    margin: 0 0 1.4rem;
    font-size: 0.86rem;
    line-height: 1.6;
  }

  .prose pre code {
    background: none;
    border: none;
    color: inherit;
    padding: 0;
    font-size: inherit;
  }

  .callout {
    margin: 1.6rem 0;
    padding: 1.15rem 1.35rem;
    background: var(--accent-soft);
    border: 1px solid #dbeafe;
    border-left: 4px solid var(--accent);
    border-radius: 10px;
  }

  .callout p:last-child {
    margin-bottom: 0;
  }

  .callout .callout-title {
    display: block;
    font-weight: 700;
    color: var(--accent-dark);
    font-size: 0.78rem;
    letter-spacing: 0.07em;
    text-transform: uppercase;
    margin-bottom: 0.4rem;
  }

  .shot-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: 1.5rem;
    margin: 1.5rem 0 2.5rem;
  }

  .shot-grid .hero-shot {
    margin: 0;
  }

  .spec-table {
    width: 100%;
    border-collapse: collapse;
    margin: 0 0 2rem;
    font-size: 0.93rem;
    border: 1px solid var(--border);
    border-radius: 10px;
    overflow: hidden;
  }

  .spec-table th,
  .spec-table td {
    text-align: left;
    padding: 0.7rem 0.95rem;
    border-bottom: 1px solid var(--border);
    vertical-align: top;
  }

  .spec-table th {
    background: #fcfcfd;
    font-weight: 700;
    font-size: 0.78rem;
    letter-spacing: 0.05em;
    text-transform: uppercase;
    color: var(--muted);
    white-space: nowrap;
  }

  .spec-table tr:last-child th,
  .spec-table tr:last-child td {
    border-bottom: none;
  }

  .spec-table td {
    color: var(--muted);
  }

  .pager {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 2.5rem;
    flex-wrap: wrap;
    margin-top: 3.5rem;
    padding-top: 1.75rem;
    border-top: 1px solid var(--border);
  }

  .pager a {
    font-size: 0.92rem;
    font-weight: 600;
    color: var(--accent);
    text-decoration: none;
    max-width: 45%;
  }

  .pager a:hover {
    text-decoration: underline;
  }

  .pager .pager-label {
    display: block;
    font-size: 0.72rem;
    font-weight: 700;
    letter-spacing: 0.07em;
    text-transform: uppercase;
    color: var(--muted);
    margin-bottom: 0.2rem;
  }

  .pager .pager-next {
    text-align: right;
  }

  /* ---------- Hub groups ---------- */

  .hub-group {
    margin-bottom: 3rem;
  }

  .hub-group > h2 {
    font-size: 1.35rem;
    font-weight: 700;
    letter-spacing: -0.02em;
    margin-bottom: 0.35rem;
    text-align: center;
  }

  .hub-group > .hub-note {
    color: var(--muted);
    font-size: 0.94rem;
    margin-bottom: 1.35rem;
    max-width: 70ch;
    margin-left: auto;
    margin-right: auto;
    text-align: center;
  }

  .card .card-kind {
    font-size: 0.72rem;
    font-weight: 700;
    letter-spacing: 0.07em;
    text-transform: uppercase;
    color: var(--accent-dark);
    margin-bottom: 0.5rem;
    text-align: center;
  }

  /* ---------- Mobile (detail) ---------- */

  @media (max-width: 768px) {
    .meta-grid {
      grid-template-columns: 1fr 1fr;
    }

    .pager a {
      max-width: 100%;
    }

    .pager .pager-next {
      text-align: left;
    }
  }
