.portfolio-surface {
  left: 56%; top: 20%; width: 39%; height: auto;
  padding: 22px; border: 1px solid #ffffff22; border-radius: 20px;
  color: #f3f5fa; background: #131920f5;
}
.portfolio-heading { display: flex; flex-direction: column; gap: 7px; margin-bottom: 16px; }
.portfolio-heading > span { color: #99add0; font-size: 9px; font-weight: 600; letter-spacing: 1.4px; }
.portfolio-heading > strong { font-size: clamp(19px, 2vw, 30px); line-height: 1.08; font-weight: 800; letter-spacing: -.04em; }
.portfolio-grid { display: grid; grid-template-columns: repeat(2, minmax(0,1fr)); gap: 13px; }
.portfolio-grid { align-items: start; }
.project-group { min-width: 0; }
.project-group .project-card { display: block; width: 100%; }
.project-alternate { appearance: none; font: 600 10px/1.4 "Avenir Next", Arial, sans-serif; border: 0; border-bottom: 1px solid #8aaeff55; color: #b5cbf5; background: none; padding: 8px 0 5px; cursor: pointer; }
.project-alternate:focus-visible { outline: 2px solid #8aaeff; outline-offset: 3px; }
.project-card { appearance: none; border: 0; padding: 0; min-width: 0; text-align: left; font: inherit; color: inherit; background: transparent; cursor: pointer; }
.project-media { position: relative; aspect-ratio: 9/16; max-height: 42svh; overflow: hidden; border-radius: 9px; background: #080b10; }
.project-media video, .project-media img { display: block; width: 100%; height: 100%; object-fit: contain; }
.project-play { position: absolute; right: 9px; bottom: 9px; width: 30px; height: 30px; display: grid; place-items: center; background: #eef3ff; color: #111923; border-radius: 50%; font-size: 21px; transition: transform .2s; }
.project-card:hover .project-play { transform: rotate(45deg); }
.project-card:focus-visible { outline: 2px solid #89aaff; outline-offset: 5px; border-radius: 10px; }
.project-info { display: grid; gap: 4px; margin-top: 10px; }
.project-info strong { font-size: clamp(11px, 1.1vw, 16px); line-height: 1.2; font-weight: 700; }
.project-info > span { color: #a8b4c8; font-size: 10px; }
.portfolio-hint { display: block; text-align: center; margin-top: 17px; color: #9facbf; font-size: 10px; }
.scene-caption:empty { display: none; }
.project-dialog { width: min(740px, 94vw); max-height: 94svh; padding: 20px; background: #12171f; color: #f3f5fa; border: 1px solid #ffffff30; border-radius: 18px; box-shadow: 0 30px 100px #0008; }
.project-dialog::backdrop { background: #05070bdc; backdrop-filter: blur(12px); }
.project-dialog-top { display: flex; align-items: center; justify-content: space-between; gap: 20px; margin-bottom: 17px; }
.project-dialog h2 { font: 700 22px/1.2 "Avenir Next", Arial, sans-serif; letter-spacing: -.5px; }
#project-kind { display: block; color: #9facbf; font-size: 11px; margin-bottom: 5px; }
.project-close { font: 600 12px/1.2 "Avenir Next", Arial, sans-serif; color: #f3f5fa; border: 1px solid #ffffff30; background: #202936; padding: 11px 15px; border-radius: 25px; cursor: pointer; }
.project-close:focus-visible { outline: 2px solid #89aaff; outline-offset: 3px; }
.project-player { display: block; width: 100%; height: min(76svh, 900px); object-fit: contain; background: #06090e; border-radius: 8px; }
@media (max-width: 760px) {
  header nav { gap: 13px; }
  .portfolio-surface { left: 29%; top: 49%; width: 67%; padding: 14px; border-radius: 14px; }
  .portfolio-heading { gap: 5px; margin-bottom: 10px; }
  .portfolio-heading > span { font-size: 7px; letter-spacing: .8px; }
  .portfolio-heading > strong { font-size: 19px; }
  .portfolio-grid { gap: 8px; }
  .project-media { max-height: 27svh; border-radius: 6px; }
  .project-play { width: 23px; height: 23px; bottom: 6px; right: 6px; font-size: 17px; }
  .project-info { margin-top: 7px; gap: 3px; }
  .project-info strong { font-size: 10px; }
  .project-info > span { font-size: 8px; }
  .project-alternate { font-size: 8px; padding-top: 6px; }
  .portfolio-hint { margin-top: 10px; font-size: 9px; }
  .project-dialog { padding: 14px; }
  .project-dialog h2 { font-size: 18px; }
}
@media (max-width: 420px) {
  header { padding-left: 5%; padding-right: 5%; }
  header img { width: 85px; }
  header nav { gap: 10px; font-size: 10px; }
  .portal { padding: 9px 10px; }
  .portal span { margin-left: 5px; }
  .portfolio-surface { left: 24%; width: 72%; padding: 12px; }
}
@media (prefers-reduced-motion: reduce) {
  .portfolio-surface { display: block !important; position: relative; left: auto; top: auto; width: min(640px, 90%); margin: 45px auto; opacity: 1 !important; transform: none !important; }
  .project-card:hover .project-play { transform: none; }
}

