@import url("../mobile.css");

.project-layout {
  width: min(1180px, calc(100vw - 48px));
  margin: 0 auto;
  padding: 64px 0 80px;
  display: grid;
  grid-template-columns: 260px minmax(0, 780px);
  gap: 44px;
  align-items: start;
}

.project-sidebar {
  position: sticky;
  top: 32px;
  align-self: start;
  display: grid;
  gap: 28px;
}

.project-sidebar .back {
  width: fit-content;
  border: 0;
  background: transparent;
  padding: 0;
  color: rgba(222, 220, 215, 0.72);
}

.project-sidebar .back:hover {
  transform: none;
  color: #fff;
}

.project-sidebar-title {
  margin: 0 0 14px;
  color: rgba(222, 220, 215, 0.78);
  font-size: 0.78rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
}

.project-list {
  display: grid;
  gap: 0;
}

.project-list a {
  color: rgba(222, 220, 215, 0.68);
  text-decoration: none;
  line-height: 1.45;
  padding: 8px 0 8px 16px;
  border-left: 2px solid rgba(255, 255, 255, 0.14);
  transition: color .2s ease, border-color .2s ease, padding-left .2s ease;
}

.project-list a:hover {
  color: #fff;
  border-left-color: rgba(72, 155, 255, 0.65);
  padding-left: 20px;
}

.project-list a.is-active {
  color: #fff;
  font-weight: 800;
  border-left-color: #489bff;
}

.project-content {
  min-width: 0;
}

.project-eyebrow {
  margin: 0 0 12px;
  color: #489bff;
  font-weight: 800;
  font-size: 0.86rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.project-content h1 {
  margin: 0 0 16px;
  max-width: 13ch;
  font-size: clamp(36px, 6vw, 64px);
  line-height: 0.98;
  letter-spacing: 0;
}

.project-content h1 span {
  display: block;
}

.project-content .lede {
  margin: 0;
  max-width: 68ch;
  color: rgba(222, 220, 215, 0.76);
  font-size: clamp(1rem, 1.35vw, 1.2rem);
  line-height: 1.7;
}

.project-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 24px;
}

.project-tag {
  display: inline-flex;
  align-items: center;
  min-height: 22px;
  padding: 3px 10px;
  border-radius: 999px;
  color: #d8eaff;
  background: rgba(72, 155, 255, 0.16);
  border: 1px solid rgba(72, 155, 255, 0.28);
  font-size: 0.78rem;
  font-weight: 800;
}

.project-content .hero {
  margin-top: 48px;
  border-radius: 14px;
}

.key-details {
  margin-top: 34px;
  max-width: 76ch;
}

.key-details h2 {
  margin: 0 0 18px;
  color: #fff;
  font-size: 1.35rem;
  letter-spacing: 0;
}

.key-details ul {
  margin: 0;
  padding-left: 1.35rem;
  color: rgba(222, 220, 215, 0.78);
}

.key-details li {
  margin: 0 0 12px;
  line-height: 1.7;
}

.key-details strong {
  color: #fff;
}

.project-section {
  margin-top: 42px;
  max-width: 76ch;
}

.project-section h2 {
  margin: 0 0 14px;
  color: #fff;
  font-size: 1.35rem;
  letter-spacing: 0;
}

.project-section p {
  margin: 0 0 16px;
  color: rgba(222, 220, 215, 0.78);
  line-height: 1.8;
}

.project-section ul {
  margin: 0 0 16px 1.35rem;
  padding: 0;
  color: rgba(222, 220, 215, 0.78);
}

.project-section li {
  margin: 0 0 10px;
  line-height: 1.7;
}

.requirementsBox {
  margin: 32px 0 40px;
  max-width: 76ch;
  padding: 24px;
  border-radius: 16px;
  border: 1px solid rgba(255, 80, 80, 0.42);
  background: rgba(120, 20, 20, 0.18);
  box-shadow: 0 12px 32px rgba(255, 80, 80, 0.08);
}

.requirementsBox h2 {
  margin: 0 0 16px;
  color: #ff7a7a;
  font-size: 0.86rem;
  font-weight: 800;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.requirementsBox ul {
  margin: 0;
  padding-left: 1.2rem;
  color: rgba(238, 238, 238, 0.86);
}

.requirementsBox li {
  margin: 0 0 9px;
  line-height: 1.65;
}

.requirementsBox li:last-child {
  margin-bottom: 0;
}

.contributionBox {
  margin: 32px 0 40px;
  max-width: 76ch;
  padding: 24px;
  border-radius: 16px;
  border: 1px solid rgba(80, 160, 255, 0.35);
  background: rgba(20, 80, 140, 0.14);
  box-shadow: 0 12px 32px rgba(72, 155, 255, 0.08);
}

.contributionBox h2 {
  margin: 0 0 16px;
  color: #72b5ff;
  font-size: 0.86rem;
  font-weight: 800;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.contributionBox ul {
  margin: 0;
  padding-left: 1.2rem;
  color: rgba(238, 238, 238, 0.86);
}

.contributionBox li {
  margin: 0 0 9px;
  line-height: 1.65;
}

.contributionBox li:last-child {
  margin-bottom: 0;
}

.visual-card {
  margin-top: 18px;
  border-radius: 16px;
  border: 1px solid rgba(80, 160, 255, 0.25);
  background: rgba(255, 255, 255, 0.04);
  padding: 10px;
  box-shadow: 0 10px 28px rgba(0,0,0,.2);
}

.visual-card img {
  display: block;
  width: 100%;
  height: auto;
  border-radius: 12px;
  object-fit: contain;
}

.visual-card figcaption {
  margin-top: 10px;
  color: rgba(222, 220, 215, 0.68);
  font-size: 0.88rem;
  line-height: 1.55;
}

.drawing-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px;
  margin-top: 18px;
}

.drawing-card {
  border-radius: 16px;
  border: 1px solid rgba(80, 160, 255, 0.25);
  background: rgba(18, 22, 32, 0.72);
  padding: 16px;
  transition: transform .2s ease, border-color .2s ease;
}

.drawing-card:hover {
  transform: translateY(-2px);
  border-color: rgba(80, 160, 255, 0.5);
}

.drawing-card h3 {
  margin: 0 0 8px;
  color: #72b5ff;
  font-size: 0.78rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.drawing-card p {
  margin: 0;
  color: rgba(222, 220, 215, 0.74);
  font-size: 0.92rem;
  line-height: 1.6;
}

.techBox {
  margin: 32px 0 40px;
  max-width: 76ch;
  padding: 24px;
  border-radius: 16px;
  border: 1px solid rgba(140, 120, 255, 0.35);
  background: rgba(55, 45, 120, 0.16);
  box-shadow: 0 12px 32px rgba(140, 120, 255, 0.08);
}

.techBox h2 {
  margin: 0 0 16px;
  color: #b8adff;
  font-size: 0.86rem;
  font-weight: 800;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.techBox p,
.techBox li {
  color: rgba(238, 238, 238, 0.84);
  line-height: 1.7;
}

.techBox p {
  margin: 0 0 14px;
}

.techBox ul {
  margin: 0;
  padding-left: 1.2rem;
}

.failureBox {
  margin: 32px 0 40px;
  max-width: 76ch;
  padding: 24px;
  border-radius: 16px;
  border: 1px solid rgba(255, 120, 70, 0.45);
  background: rgba(140, 55, 20, 0.16);
  box-shadow: 0 12px 32px rgba(255, 120, 70, 0.08);
}

.failureBox h2 {
  margin: 0 0 16px;
  color: #ff9a72;
  font-size: 0.86rem;
  font-weight: 800;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.failureBox p {
  margin: 0 0 14px;
  color: rgba(238, 238, 238, 0.84);
  line-height: 1.75;
}

.workflow-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
  margin-top: 18px;
}

.workflow-step {
  border-radius: 12px;
  border: 1px solid rgba(80, 160, 255, 0.28);
  background: rgba(18, 22, 32, 0.72);
  padding: 12px 14px;
  color: rgba(222, 220, 215, 0.82);
  line-height: 1.45;
}

.workflow-step.is-warning {
  border-color: rgba(255, 120, 70, 0.48);
  background: rgba(140, 55, 20, 0.14);
}

.workflow-step strong {
  color: #fff;
}

.metric-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 14px;
  margin-top: 18px;
}

.metric-card {
  border-radius: 12px;
  border: 1px solid rgba(72, 155, 255, 0.26);
  background: rgba(18, 22, 32, 0.72);
  padding: 16px;
  box-shadow: 0 10px 28px rgba(0,0,0,.18);
}

.metric-card h3 {
  margin: 0 0 8px;
  color: rgba(222, 220, 215, 0.76);
  font-size: 0.78rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.metric-card .metric-value {
  margin: 0 0 8px;
  color: #fff;
  font-size: clamp(1.35rem, 2vw, 1.85rem);
  font-weight: 800;
  line-height: 1.1;
}

.metric-card p {
  margin: 0;
  color: rgba(222, 220, 215, 0.72);
  font-size: 0.9rem;
  line-height: 1.55;
}

@media (max-width: 900px) {
  .project-layout {
    width: min(100% - 32px, 780px);
    grid-template-columns: 1fr;
    gap: 32px;
    padding-top: 36px;
  }

  .project-sidebar {
    position: static;
    gap: 20px;
  }

  .project-list {
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
    gap: 8px 12px;
  }

  .project-list a {
    border-left: 0;
    border-bottom: 1px solid rgba(255, 255, 255, 0.16);
    padding: 8px 0;
  }

  .project-list a:hover,
  .project-list a.is-active {
    padding-left: 0;
  }

  .project-content h1 {
    max-width: 100%;
    font-size: clamp(32px, 11vw, 48px);
  }

  .metric-grid {
    grid-template-columns: 1fr;
  }

  .drawing-grid {
    grid-template-columns: 1fr;
  }

  .workflow-grid {
    grid-template-columns: 1fr;
  }
}

/* === Canonical shared project sidebar: original visual style === */
.project-layout > .project-sidebar[data-project-sidebar] {
  position: sticky;
  top: 32px;
  align-self: start;
  display: grid;
  gap: 28px;
  min-width: 0;
  font-family: 'JetBrains Mono', monospace;
}
.project-sidebar[data-project-sidebar] > .back {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  width: fit-content;
  margin: 0;
  padding: 0;
  border: 0;
  border-radius: 0;
  background: transparent;
  box-shadow: none;
  color: rgba(222, 220, 215, 0.72);
  font: inherit;
  text-decoration: none;
}
.project-sidebar[data-project-sidebar] > .back:hover {
  color: #fff;
  background: transparent;
  transform: none;
}
.project-sidebar-panel {
  min-width: 0;
  margin: 0;
  padding: 0;
  border: 0;
  border-radius: 0;
  background: transparent;
  box-shadow: none;
  backdrop-filter: none;
  -webkit-backdrop-filter: none;
}
.project-sidebar[data-project-sidebar] .project-sidebar-title {
  margin: 0 0 14px;
  color: rgba(222, 220, 215, 0.78);
  font-size: 0.78rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
}
.project-sidebar[data-project-sidebar] .project-list {
  display: grid;
  grid-template-columns: 1fr;
  gap: 0;
  margin: 0;
  padding: 0;
}
.project-sidebar[data-project-sidebar] .project-list a {
  display: block;
  min-width: 0;
  padding: 8px 0 8px 16px;
  border: 0;
  border-left: 2px solid rgba(255, 255, 255, 0.14);
  border-radius: 0;
  background: transparent;
  color: rgba(222, 220, 215, 0.68);
  font: inherit;
  font-size: inherit;
  font-weight: 400;
  line-height: 1.45;
  overflow-wrap: anywhere;
  text-decoration: none;
  transition: color .2s ease, border-color .2s ease, padding-left .2s ease;
}
.project-sidebar[data-project-sidebar] .project-list a:hover {
  padding-left: 20px;
  color: #fff;
  border-left-color: rgba(72, 155, 255, 0.65);
  background: transparent;
}
.project-sidebar[data-project-sidebar] .project-list a.is-active {
  color: #fff;
  font-weight: 800;
  border-left-color: #489bff;
  background: transparent;
}
.project-list-status {
  margin: 0;
  padding: 8px 0 8px 16px;
  color: rgba(222, 220, 215, 0.62);
}
@media (max-width: 900px) {
  .project-layout > .project-sidebar[data-project-sidebar] {
    position: static;
    gap: 20px;
  }
  .project-sidebar[data-project-sidebar] .project-list {
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
    gap: 8px 12px;
  }
  .project-sidebar[data-project-sidebar] .project-list a {
    padding: 8px 0;
    border-left: 0;
    border-bottom: 1px solid rgba(255, 255, 255, 0.16);
  }
  .project-sidebar[data-project-sidebar] .project-list a:hover,
  .project-sidebar[data-project-sidebar] .project-list a.is-active {
    padding-left: 0;
  }
}

/* === Site footer === */
.site-footer {
  width: 100%;
  padding: 0;
  margin-top: clamp(64px, 9vw, 104px);
  color: rgba(222, 220, 215, 0.68);
}
.footer-inner {
  width: min(calc(100% - 40px), 1100px);
  margin: 0 auto;
  padding: 28px 0 30px;
  border-top: 1px solid rgba(255, 255, 255, 0.14);
  display: grid;
  grid-template-columns: 150px minmax(240px, 1fr) minmax(150px, auto);
  grid-template-areas: "mark clock links" "bottom bottom bottom";
  gap: 28px 52px;
}
.footer-mark {
  grid-area: mark;
  display: block;
  width: 72px;
  height: 72px;
}
.footer-mark img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: contain;
  opacity: 0.72;
  filter: grayscale(1);
}
.footer-clock {
  grid-area: clock;
  align-self: start;
  display: grid;
  gap: 12px;
  max-width: 360px;
}
.footer-clock-label {
  color: rgba(222, 220, 215, 0.48);
  font-size: 0.74rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}
.footer-clock time {
  display: flex;
  align-items: center;
  gap: 12px;
  color: rgba(222, 220, 215, 0.78);
  font-size: 0.9rem;
  line-height: 1.5;
}
.footer-clock time::before {
  content: "";
  flex: 0 0 auto;
  width: 12px;
  height: 12px;
  border-radius: 50%;
  background: #489bff;
  box-shadow: inset -2px -2px 4px rgba(0, 0, 0, 0.25), 0 0 8px rgba(72, 155, 255, 0.35);
}
.footer-links {
  grid-area: links;
  display: grid;
  align-content: start;
  justify-items: start;
  gap: 4px;
}
.footer-links a,
.footer-bottom a {
  color: inherit;
  text-decoration: none;
  text-underline-offset: 4px;
}
.footer-links a {
  font-size: 0.9rem;
}
.footer-links a:hover,
.footer-links a:focus-visible,
.footer-bottom a:hover,
.footer-bottom a:focus-visible {
  color: #fff;
  text-decoration: underline;
}
.footer-bottom {
  grid-area: bottom;
  padding-top: 18px;
  border-top: 1px solid rgba(255, 255, 255, 0.08);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  font-size: 0.74rem;
}
@media (max-width: 700px) {
  .footer-inner {
    grid-template-columns: minmax(0, 1fr) minmax(130px, auto);
    grid-template-areas: "clock links" "mark links" "bottom bottom";
    gap: 28px 32px;
  }
  .footer-mark {
    width: 64px;
    height: 64px;
  }
  .footer-clock time {
    align-items: flex-start;
  }
  .footer-bottom {
    align-items: flex-start;
  }
}
