/*
 * BUILT BY KIA — RENDER REGRESSION LOCK v8
 * Loaded last on purpose. The production build fails if this file changes,
 * moves earlier in the cascade, or the protected rendered classes return.
 */

/* Kiki's Reset Room must always fill the same 16:10 card frame as its peers. */
.route-shell.route-home .featured-project-image.project-image-kikis-reset-room,
.route-shell.route-web-development .website-card-image.project-image-kikis-reset-room,
.route-shell.route-web-development-kikis-reset-room .project-detail-media.project-image-kikis-reset-room {
  box-sizing: border-box !important;
  display: block !important;
  width: 100% !important;
  aspect-ratio: 16 / 10 !important;
  padding: 0 !important;
  overflow: hidden !important;
  background: var(--media-frame) !important;
}

.route-shell.route-home .featured-project-image.project-image-kikis-reset-room img,
.route-shell.route-web-development .website-card-image.project-image-kikis-reset-room img,
.route-shell.route-web-development-kikis-reset-room .project-detail-media.project-image-kikis-reset-room img {
  display: block !important;
  width: 100% !important;
  height: 100% !important;
  max-width: none !important;
  object-fit: cover !important;
  object-position: center center !important;
}

/*
 * CMS cards repeated on Selected Work must use their own paper color instead
 * of inheriting white text from the navy section. Natural card height and
 * compact copy spacing prevent equal-height rows from creating dead space.
 */
.route-shell.route-web-development .web-cms-showcase {
  padding-block: clamp(3.5rem, 6vw, 5.5rem) !important;
}

.route-shell.route-web-development .web-cms-grid {
  align-items: start !important;
}

/* Selected Work cards size to content instead of stretching to the row. */
.route-shell.route-web-development .web-project-list {
  align-items: start !important;
  grid-auto-rows: auto !important;
}

.route-shell.route-web-development .web-project-list .website-card {
  align-self: start !important;
  height: auto !important;
  min-height: 0 !important;
}

.route-shell.route-web-development .web-project-list .website-card-copy {
  flex: 0 0 auto !important;
  justify-content: flex-start !important;
  min-height: 0 !important;
  padding: 1.45rem !important;
}

.route-shell.route-web-development .web-project-list .website-card-copy > p:not(.project-context) {
  margin-block: 0.8rem !important;
  line-height: 1.65 !important;
}

.route-shell.route-web-development .web-project-list .card-role {
  margin: 0.9rem 0 0 !important;
  padding: 0.8rem 0 !important;
}

.route-shell.route-web-development .web-project-list .project-actions {
  margin-top: 1rem !important;
  padding-top: 0 !important;
}

.route-shell.route-web-development .web-cms-grid .cms-project {
  height: auto !important;
  min-height: 0 !important;
  color: var(--ink) !important;
  background: var(--paper) !important;
}

.route-shell.route-web-development .web-cms-grid .cms-project-copy {
  flex: 0 0 auto !important;
  min-height: 0 !important;
  padding: 1.35rem 1.35rem 1rem !important;
  color: var(--ink) !important;
}

.route-shell.route-web-development .web-cms-grid .cms-project-copy h2 {
  min-height: 0 !important;
  margin: 0 0 0.65rem !important;
  color: var(--ink) !important;
}

.route-shell.route-web-development .web-cms-grid .cms-project-copy .project-context {
  margin-block: 0 0.85rem !important;
}

.route-shell.route-web-development .web-cms-grid .cms-project-copy .cms-meta {
  margin-block: 0.75rem !important;
}

.route-shell.route-web-development .web-cms-grid .cms-project-copy > p:not(.project-context, .cms-impact) {
  margin-block: 0.75rem !important;
  line-height: 1.65 !important;
}

.route-shell.route-web-development .web-cms-grid .cms-project-copy .cms-impact {
  margin-block: 0.85rem 0 !important;
  line-height: 1.6 !important;
}

.route-shell.route-web-development .web-cms-grid .cms-project-links {
  margin-top: 0 !important;
  padding: 0 1.35rem 1.35rem !important;
}

/*
 * Writing uses one compact card language throughout. PDF replacements stay at
 * their established URLs; this controls presentation without duplicate copy.
 */
.route-shell.route-writing .page-hero {
  gap: clamp(2rem, 5vw, 5rem) !important;
  padding-block: clamp(4rem, 6vw, 6rem) !important;
}

.route-shell.route-writing .writing-block {
  padding-block: clamp(3.5rem, 5vw, 5.5rem) !important;
}

/* Keep the first Writing collection clear of the sticky header in every engine. */
.route-shell.route-writing .page-hero + .writing-block {
  scroll-margin-top: 7rem;
  padding-top: clamp(4.5rem, 6vw, 6.5rem) !important;
}

.route-shell.route-writing .section-heading-row {
  margin-bottom: clamp(1.75rem, 3vw, 2.5rem) !important;
}

.route-shell.route-writing .section-heading-row h2 {
  max-width: 18ch;
  font-size: clamp(2.4rem, 4vw, 4.2rem) !important;
  line-height: 1.02 !important;
  overflow-wrap: break-word;
}

.route-shell.route-writing .document-grid,
.route-shell.route-writing .editorial-grid {
  align-items: start !important;
}

.route-shell.route-writing .case-study-document-grid {
  grid-template-columns: repeat(3, minmax(0, 1fr)) !important;
  align-items: stretch !important;
  gap: 1.25rem !important;
}

.route-shell.route-writing .case-study-document {
  display: grid !important;
  grid-template-rows: auto minmax(0, 1fr);
  height: auto !important;
  min-height: 0 !important;
  overflow: hidden;
}

.route-shell.route-writing .case-study-document > img {
  display: block !important;
  width: 100% !important;
  height: auto !important;
  min-height: 0 !important;
  aspect-ratio: 16 / 9 !important;
  padding: 0 !important;
  object-fit: cover !important;
}

.route-shell.route-writing .case-study-document > div {
  display: flex !important;
  flex-direction: column;
  gap: 0.75rem;
  min-height: 0;
  padding: 1.35rem !important;
}

.route-shell.route-writing .case-study-document h3 {
  font-size: clamp(1.8rem, 2.25vw, 2.6rem) !important;
}

.route-shell.route-writing .case-study-document > div > p {
  margin: 0 !important;
}

.route-shell.route-writing .case-study-document strong {
  margin-top: auto !important;
  padding-top: 0.85rem !important;
}

.route-shell.route-writing .document-grid {
  grid-template-columns: repeat(6, minmax(0, 1fr)) !important;
  align-items: stretch !important;
  gap: 1.25rem !important;
}

.route-shell.route-writing .document-card {
  display: flex !important;
  grid-column: span 2;
  flex-direction: column;
  height: 100% !important;
  min-height: 0 !important;
  overflow: hidden;
}

.route-shell.route-writing .document-card:nth-child(4) {
  grid-column: 2 / span 2;
}

.route-shell.route-writing .document-card:nth-child(5) {
  grid-column: 4 / span 2;
}

.route-shell.route-writing .document-card > img {
  width: 100% !important;
  aspect-ratio: 16 / 10 !important;
  padding: 0 !important;
  object-fit: cover !important;
  object-position: top center !important;
}

.route-shell.route-writing .document-card:nth-child(2) > img {
  object-position: left top !important;
}

.route-shell.route-writing .document-card > div {
  display: flex !important;
  flex: 1 1 auto !important;
  flex-direction: column;
  min-height: 0 !important;
  padding: 1.2rem !important;
}

.route-shell.route-writing .document-card h3 {
  font-size: clamp(1.35rem, 1.55vw, 1.9rem) !important;
  line-height: 1.06 !important;
}

.route-shell.route-writing .document-card strong {
  margin-top: auto !important;
  padding-top: 0.75rem !important;
  border-top: 1px solid var(--line);
}

.route-shell.route-writing .editorial-card {
  height: auto !important;
  min-height: 0 !important;
  overflow: hidden;
}

.route-shell.route-writing .editorial-card > div {
  padding: 1.3rem !important;
}

.route-shell.route-writing .editorial-card h3 {
  margin-bottom: 1rem !important;
  font-size: clamp(1.8rem, 2.4vw, 2.7rem) !important;
}

/* Cloudflare is a deliberate platform decision in both independent builds. */
.route-shell.route-web-development-mmorbit .project-context,
.route-shell.route-web-development-kikis-reset-room .project-context {
  color: var(--plum) !important;
  font-weight: 800 !important;
}

.route-shell .platform-rationale {
  display: grid;
  grid-template-columns: minmax(220px, 0.62fr) minmax(0, 1.38fr);
  gap: clamp(1.25rem, 3vw, 3rem);
  align-items: start;
  max-width: 1000px;
  margin: 2rem 0 2.75rem;
  padding: clamp(1.4rem, 3vw, 2.25rem);
  color: #fff;
  background: #132f46;
  border-left: 8px solid var(--gold);
  box-shadow: 0 16px 36px rgba(19, 47, 70, 0.18);
}

.route-shell .platform-rationale strong {
  display: block;
  margin-bottom: 0.65rem;
  color: #e6bd6d;
  font-size: 0.78rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.route-shell .platform-rationale h3 {
  margin: 0;
  color: #fff;
  font-size: clamp(1.65rem, 2.6vw, 2.65rem);
  line-height: 1.04;
}

.route-shell .platform-rationale p {
  max-width: 62ch;
  margin: 0;
  color: rgba(255, 255, 255, 0.82);
  line-height: 1.75;
}

/* A semantic, polished career timeline with a continuous visual rail. */
.route-shell.route-about .career-timeline-section {
  padding-block: clamp(4rem, 6vw, 6.5rem) !important;
}

.route-shell.route-about .career-timeline-heading {
  display: grid;
  grid-template-columns: minmax(0, 1.15fr) minmax(280px, 0.55fr);
  gap: clamp(2rem, 6vw, 6rem);
  align-items: end;
  margin-bottom: clamp(2.5rem, 5vw, 4.5rem);
}

.route-shell.route-about .career-timeline-heading h2 {
  max-width: 20ch;
  font-size: clamp(2.8rem, 5vw, 5rem);
  line-height: 0.98;
}

.route-shell.route-about .career-timeline-heading p {
  max-width: 58ch;
  margin: 0;
  color: var(--muted);
  line-height: 1.75;
}

.route-shell.route-about .career-timeline {
  position: relative;
  display: grid;
  gap: 1.35rem;
  margin: 0;
  padding: 0 0 0 4.75rem;
  list-style: none;
}

.route-shell.route-about .career-timeline::before {
  content: "";
  position: absolute;
  top: 1.5rem;
  bottom: 1.5rem;
  left: 1.35rem;
  width: 3px;
  background: linear-gradient(var(--gold), var(--plum));
}

.route-shell.route-about .career-entry {
  position: relative;
}

.route-shell.route-about .career-entry::before {
  content: "";
  position: absolute;
  top: 2.2rem;
  left: -4.1rem;
  width: 1.2rem;
  height: 1.2rem;
  border: 4px solid var(--cream);
  border-radius: 50%;
  background: var(--gold);
  box-shadow: 0 0 0 2px var(--plum);
}

.route-shell.route-about .career-entry article {
  display: grid;
  grid-template-columns: minmax(185px, 0.34fr) minmax(0, 1fr);
  min-height: 0;
  overflow: hidden;
  background: var(--paper);
  border: 1px solid var(--line);
  border-top: 6px solid var(--gold);
  box-shadow: 0 16px 38px rgba(35, 26, 32, 0.08);
}

.route-shell.route-about .career-entry-meta {
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  gap: 2rem;
  padding: 1.6rem;
  color: #fff;
  background: #132f46;
}

.route-shell.route-about .career-entry:nth-child(even) .career-entry-meta {
  background: var(--plum);
}

.route-shell.route-about .career-entry-meta time {
  color: #fff;
  font-family: var(--font-display), Georgia, serif;
  font-size: clamp(1.55rem, 2.1vw, 2.25rem);
  font-weight: 700;
  line-height: 1;
}

.route-shell.route-about .career-entry-meta span {
  color: #f2d18e;
  font-size: 0.68rem;
  font-weight: 800;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.route-shell.route-about .career-entry-copy {
  padding: clamp(1.5rem, 3vw, 2.4rem);
}

.route-shell.route-about .career-entry-copy h3 {
  max-width: 24ch;
  font-size: clamp(2rem, 3.25vw, 3.35rem);
  line-height: 1;
}

.route-shell.route-about .career-entry-copy .career-role {
  margin: 0.65rem 0 1rem;
  color: var(--plum);
  font-size: 0.76rem;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.route-shell.route-about .career-entry-copy > p:last-of-type {
  max-width: 78ch;
  margin-bottom: 1.25rem;
  color: var(--muted);
  line-height: 1.72;
}

.route-shell.route-about .career-focus {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin: 0;
  padding: 0;
  list-style: none;
}

.route-shell.route-about .career-focus li {
  padding: 0.48rem 0.7rem;
  color: var(--plum);
  background: var(--rose-light);
  border: 1px solid rgba(96, 43, 73, 0.12);
  font-size: 0.68rem;
  font-weight: 750;
}

/* A distinct, harmonious closing section with a compact introduction. */
.route-shell .site-footer {
  position: relative !important;
  isolation: isolate;
  color: rgba(255, 255, 255, 0.82) !important;
  background: #132f46 !important;
  border-top: 8px solid var(--gold) !important;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.12) !important;
  padding-block: clamp(2.75rem, 5vw, 4rem) !important;
}

.route-shell .site-footer::before {
  content: none !important;
  display: none !important;
}

.route-shell .site-footer .footer-intro {
  gap: 0.7rem !important;
  max-width: 34rem;
  padding-right: clamp(1rem, 3vw, 3rem);
}

.route-shell .site-footer .footer-intro strong {
  color: #fff !important;
  font-size: clamp(1.35rem, 2vw, 1.75rem) !important;
  line-height: 1.15 !important;
}

.route-shell .site-footer .footer-intro p {
  max-width: 46ch !important;
  margin: 0 !important;
  color: rgba(255, 255, 255, 0.78) !important;
  font-size: 0.88rem !important;
  line-height: 1.6 !important;
}

.route-shell .site-footer nav h2 {
  color: #e6bd6d !important;
}

.route-shell .site-footer nav a {
  display: inline-flex;
  align-items: center;
  width: fit-content;
  min-height: 44px;
  color: #fff !important;
  text-decoration-color: transparent;
  text-underline-offset: 0.25em;
  transition: color 0.15s ease, text-decoration-color 0.15s ease;
}

.route-shell .site-footer nav a:hover,
.route-shell .site-footer nav a:focus-visible {
  color: #f2d18e !important;
  text-decoration: underline;
  text-decoration-color: currentColor;
}

.route-shell .site-footer .footer-legal {
  color: rgba(255, 255, 255, 0.68) !important;
  border-top-color: rgba(255, 255, 255, 0.2) !important;
}

@media (width <= 1120px) {
  .route-shell.route-writing .case-study-document-grid {
    grid-template-columns: 1fr !important;
  }

  .route-shell.route-writing .document-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
  }

  .route-shell.route-writing .document-card,
  .route-shell.route-writing .document-card:nth-child(4),
  .route-shell.route-writing .document-card:nth-child(5) {
    grid-column: auto;
  }

  .route-shell.route-writing .document-card:last-child {
    grid-column: 1 / -1;
    justify-self: center;
    width: calc(50% - 0.625rem);
  }

  .route-shell.route-about .career-timeline-heading {
    grid-template-columns: 1fr;
    gap: 1.25rem;
  }
}

@media (width <= 760px) {
  .route-shell.route-web-development .web-cms-showcase {
    padding-block: 3rem !important;
  }

  .route-shell.route-writing .page-hero,
  .route-shell.route-writing .writing-block {
    padding-block: 3rem !important;
  }

  .route-shell.route-writing .document-grid,
  .route-shell.route-writing .editorial-grid {
    grid-template-columns: 1fr !important;
  }

  .route-shell.route-writing .document-card,
  .route-shell.route-writing .document-card:nth-child(4),
  .route-shell.route-writing .document-card:nth-child(5),
  .route-shell.route-writing .document-card:last-child {
    grid-column: auto;
    width: 100%;
  }

  .route-shell .platform-rationale {
    grid-template-columns: 1fr;
    margin-block: 1.5rem 2.25rem;
    border-left-width: 6px;
  }

  .route-shell.route-about .career-timeline {
    padding-left: 2.75rem;
  }

  .route-shell.route-about .career-timeline::before {
    left: 0.65rem;
  }

  .route-shell.route-about .career-entry::before {
    top: 1.5rem;
    left: -2.7rem;
  }

  .route-shell.route-about .career-entry article {
    grid-template-columns: 1fr;
  }

  .route-shell.route-about .career-entry-meta {
    flex-direction: row;
    align-items: baseline;
    gap: 1rem;
    padding: 1.15rem 1.25rem;
  }

  .route-shell .site-footer .footer-intro {
    padding-right: 0;
  }
}

@media (prefers-contrast: more) {
  .route-shell main a:not(.button),
  .route-shell .site-footer nav a {
    text-decoration: underline;
    text-decoration-thickness: 0.12em;
    text-underline-offset: 0.22em;
  }
}

@media (forced-colors: active) {
  .route-shell :where(a, button, summary, [tabindex]):focus-visible {
    outline: 3px solid CanvasText !important;
    outline-offset: 4px !important;
  }

  .route-shell .career-entry article,
  .route-shell .platform-rationale,
  .route-shell .site-footer {
    border: 2px solid CanvasText !important;
  }
}
