/* Header without the old systems-operational pill */
.site-header {
  grid-template-columns: 1fr auto;
  padding-inline: 26px;
}

.site-header .nav {
  justify-self: end;
}

/* About page: reserved visual slot, ready for a real image later */
.profile-rail {
  display: grid;
  gap: 16px;
}

.profile-image-slot {
  position: relative;
  min-height: 170px;
  aspect-ratio: 16 / 7;
  overflow: hidden;
  border: 1px solid var(--panel-border);
  border-radius: 20px;
  background:
    radial-gradient(circle at 75% 20%, rgba(110, 231, 199, 0.08), transparent 32%),
    linear-gradient(145deg, rgba(20, 29, 42, 0.95), rgba(9, 14, 22, 0.95));
  box-shadow: 0 18px 50px rgba(0, 0, 0, 0.26);
}

.profile-image-grid {
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(rgba(255, 255, 255, 0.035) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.035) 1px, transparent 1px);
  background-size: 28px 28px;
  mask-image: linear-gradient(135deg, black, rgba(0, 0, 0, 0.26));
  pointer-events: none;
}

.profile-image-slot::before,
.profile-image-slot::after {
  content: "";
  position: absolute;
  width: 38px;
  height: 38px;
  pointer-events: none;
}

.profile-image-slot::before {
  top: 14px;
  left: 14px;
  border-top: 1px solid rgba(110, 231, 199, 0.5);
  border-left: 1px solid rgba(110, 231, 199, 0.5);
}

.profile-image-slot::after {
  right: 14px;
  bottom: 14px;
  border-right: 1px solid rgba(110, 231, 199, 0.3);
  border-bottom: 1px solid rgba(110, 231, 199, 0.3);
}

.profile-image-meta {
  position: absolute;
  left: 22px;
  bottom: 20px;
  display: grid;
  gap: 5px;
  z-index: 1;
}

.profile-image-meta span{
  font-family: "SFMono-Regular", Consolas, "Liberation Mono", monospace;
  letter-spacing: 0.12em;
}

.profile-image-meta span {
  color: #5f6d80;
  font-size: 9px;
}

.profile-image-meta strong {
  color: #cbd4df;
  font-size: 14px;
  font-weight: 600;
}

/* Stack page: keep the section label and focus on the automation controller */
.stack-layout {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 18px;
}

.stack-copy {
  display: block;
  width: min(900px, 100%);
}

.stack-copy > :not(.section-kicker) {
  display: none;
}

.stack-copy .section-kicker {
  margin: 0;
}

.stack-layout .automation-window {
  width: min(900px, 100%);
  margin-inline: auto;
}

/* Tools page: bottom CTA to the dedicated resume site */
.resume-cta {
  width: min(1220px, calc(100% - 48px));
  margin: 0 auto 18px;
  min-height: 74px;
  padding: 0 22px;
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: center;
  gap: 18px;
  border: 1px solid rgba(110, 231, 199, 0.14);
  border-radius: 14px;
  background: linear-gradient(90deg, rgba(110, 231, 199, 0.055), rgba(255, 255, 255, 0.018));
  transition: transform 180ms ease, border-color 180ms ease, background 180ms ease;
}

.resume-cta:hover {
  transform: translateY(-2px);
  border-color: rgba(110, 231, 199, 0.3);
  background: linear-gradient(90deg, rgba(110, 231, 199, 0.09), rgba(255, 255, 255, 0.028));
}

.resume-cta-kicker,
.resume-cta-arrow {
  font-family: "SFMono-Regular", Consolas, "Liberation Mono", monospace;
}

.resume-cta-kicker {
  color: #627084;
  font-size: 9px;
  font-weight: 700;
  letter-spacing: 0.14em;
}

.resume-cta strong {
  color: #dfe6ef;
  font-size: 16px;
  font-weight: 650;
}

.resume-cta-arrow {
  color: var(--accent);
  font-size: 18px;
  transition: transform 180ms ease;
}

.resume-cta:hover .resume-cta-arrow {
  transform: translate(2px, -2px);
}

@media (max-width: 1040px) {
  .profile-image-slot {
    min-height: 150px;
  }

  .stack-copy,
  .stack-layout .automation-window {
    width: min(860px, 100%);
  }
}

@media (max-width: 760px) {
  .site-header {
    grid-template-columns: 1fr auto;
    padding-inline: 16px;
  }

  .profile-rail {
    gap: 12px;
  }

  .profile-image-slot {
    min-height: 145px;
    aspect-ratio: 16 / 8;
    border-radius: 16px;
  }

  .stack-copy,
  .stack-layout .automation-window {
    width: 100%;
  }

  .resume-cta {
    width: min(100% - 32px, 1220px);
    min-height: 68px;
    padding: 0 16px;
    grid-template-columns: 1fr auto;
    gap: 10px;
  }

  .resume-cta-kicker {
    display: none;
  }

  .resume-cta strong {
    font-size: 14px;
  }
}
