/* Portfolio additions use the approved site tokens without restyling R3.2 components. */
.selected-work-section{background:linear-gradient(180deg,#0b1423,#0b1220)}
.project-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:28px}
.project-card{display:flex;flex-direction:column;min-width:0;overflow:hidden;border:1px solid rgba(103,140,208,.3);border-radius:24px;background:linear-gradient(145deg,#13213a,#0d1728);box-shadow:0 16px 40px rgba(0,0,0,.13);transition:transform .25s,border-color .25s,box-shadow .25s}
.project-card:hover{transform:translateY(-4px);border-color:rgba(120,153,240,.58);box-shadow:0 20px 46px rgba(0,0,0,.23),0 0 24px rgba(83,59,189,.08)}
.project-card[hidden],.portfolio-filters[hidden]{display:none}
.project-shot{display:block;position:relative;flex:none;border-bottom:1px solid rgba(103,140,208,.25);background:#0a1425}
.project-shot:focus-visible{outline-offset:-4px}
.project-window-bar{display:flex;align-items:center;justify-content:space-between;gap:16px;height:35px;padding:0 18px;background:linear-gradient(100deg,#162441,#101c32);color:#a8bddb;font-size:.6875rem;letter-spacing:.035em}
.project-window-dots{display:flex;align-items:center;gap:5px}
.project-window-dots i{width:6px;height:6px;border-radius:50%;background:#7044d5}
.project-window-dots i:nth-child(2){background:#397fe3}
.project-window-dots i:nth-child(3){background:#16a6c5}
.project-image-wrap{display:block;aspect-ratio:16/9;overflow:hidden;background:#0c1527}
.project-image-wrap img{width:100%;height:100%;object-fit:cover;object-position:center top;transition:transform .4s}
.project-shot:hover img{transform:scale(1.018)}
.project-preview-hint{position:absolute;right:16px;bottom:16px;display:inline-flex;align-items:center;gap:7px;padding:8px 11px;border:1px solid rgba(171,198,241,.28);border-radius:100px;background:rgba(8,17,34,.9);color:#f4f8ff;box-shadow:0 4px 15px rgba(0,0,0,.2);font-size:.75rem;font-weight:600;line-height:1.4}
.project-preview-hint .icon{width:14px;height:14px;transform:rotate(-35deg)}
.project-card-body{display:flex;flex-direction:column;flex:1;padding:28px}
.project-category{display:block;color:#93bfff;font-size:.6875rem;letter-spacing:.12em;text-transform:uppercase;font-weight:750;line-height:1.5}
.project-card h3{font-size:1.625rem;line-height:1.25;letter-spacing:-.035em;margin:12px 0 0;font-weight:700}
.project-description{color:#b0c0d7;font-size:1rem;line-height:1.75;margin:16px 0 22px;max-width:55ch}
.project-actions{display:flex;align-items:center;flex-wrap:wrap;gap:10px 24px;margin-top:auto;padding-top:4px}
.project-action{display:inline-flex;align-items:center;gap:8px;min-height:44px;color:#9dd0ff;font-size:.9375rem;line-height:1.5;font-weight:650;transition:color .2s,gap .2s}
.project-action:hover{color:#d1e8ff;gap:11px}
.project-action .icon{width:16px;height:16px}
.project-action-external .icon{transform:rotate(-35deg)}
.portfolio-intro-note{max-width:780px;margin:20px 0 0;color:#9db1cf;font-size:.9375rem;line-height:1.75}
.portfolio-tools{display:flex;align-items:center;justify-content:space-between;gap:20px;flex-wrap:wrap;margin-bottom:30px}
.portfolio-work .portfolio-tools{margin-top:32px}
.portfolio-filters{display:flex;align-items:center;gap:10px;flex-wrap:wrap}
.portfolio-filter{display:inline-flex;align-items:center;justify-content:center;min-height:46px;padding:12px 18px;border:1px solid rgba(105,143,208,.3);border-radius:100px;background:#101c30;color:#bbcae0;font-size:.9375rem;font-weight:600;line-height:1.35;transition:background .2s,border-color .2s,color .2s}
.portfolio-filter:hover{color:#fff;border-color:rgba(136,170,236,.55)}
.portfolio-filter[aria-pressed="true"]{background:linear-gradient(110deg,rgba(124,58,237,.34),rgba(59,130,246,.24));border-color:rgba(138,126,247,.62);color:#f8faff}
.portfolio-count{margin:0;color:#9db1cf;font-size:.875rem;line-height:1.5}
.project-lightbox{width:min(1200px,calc(100vw - 48px));max-width:none;max-height:calc(100dvh - 48px);padding:0;border:1px solid rgba(117,152,222,.5);border-radius:22px;background:#0b1425;color:#f8fafc;box-shadow:0 25px 90px rgba(0,0,0,.5);overflow:auto}
.project-lightbox[open]{display:flex;flex-direction:column}
.project-lightbox::backdrop{background:rgba(3,8,18,.9);backdrop-filter:blur(7px)}
.project-preview-toolbar{display:flex;align-items:center;justify-content:space-between;gap:20px;padding:16px 20px;border-bottom:1px solid rgba(103,140,208,.22);background:#111e35}
.project-preview-toolbar h2{font-size:1.125rem;line-height:1.4;letter-spacing:-.02em;margin:0}
.project-preview-toolbar p{font-size:.8125rem;line-height:1.5;margin:4px 0 0;color:#a5b8d2}
.project-preview-close{display:grid;place-items:center;flex:none;width:44px;height:44px;padding:0;border:1px solid rgba(124,159,219,.35);border-radius:12px;background:#172741;color:#edf4ff}
.project-preview-close:hover{background:#22395c}
.project-preview-close .icon{width:21px;height:21px}
.project-lightbox-image{display:block;width:100%;height:auto;max-height:calc(100dvh - 160px);object-fit:contain;background:#080e18}
body.project-preview-open{overflow:hidden}
@media(max-width:950px){.project-grid{gap:24px}.project-card-body{padding:24px}.project-card h3{font-size:1.5rem}}
@media(max-width:720px){
  .project-grid{grid-template-columns:1fr;gap:24px}
  .project-card{border-radius:22px}
  .project-window-bar{height:32px;padding-inline:14px;font-size:.625rem}
  .project-card-body{padding:24px}
  .project-card h3{font-size:1.5rem}
  .project-description{margin:14px 0 18px}
  .project-actions{gap:10px 20px}
  .project-action{min-height:48px}
  .project-preview-hint{right:12px;bottom:12px;font-size:.6875rem}
  .portfolio-tools{align-items:flex-start;gap:16px;margin-bottom:26px}
  .portfolio-filters{gap:9px}
  .portfolio-filter{min-height:46px;padding:12px 16px;font-size:.875rem}
  .portfolio-count{width:100%}
  .portfolio-intro-note{font-size:.875rem}
  .project-lightbox{width:calc(100vw - 24px);max-height:calc(100dvh - 32px);border-radius:17px}
  .project-preview-toolbar{gap:12px;padding:14px}
  .project-preview-toolbar h2{font-size:1rem}
  .project-preview-toolbar p{font-size:.75rem}
  .project-lightbox-image{max-height:calc(100dvh - 150px)}
}
@media(prefers-reduced-motion:reduce){.project-card,.project-image-wrap img,.project-action,.portfolio-filter{transition:none}.project-card:hover,.project-shot:hover img{transform:none}}

/* R4.1: project status, flagship placement and genuine desktop/mobile galleries. */
.project-meta{display:flex;align-items:center;flex-wrap:wrap;gap:10px 16px}
.project-status{display:inline-flex;align-items:center;gap:7px;padding:6px 10px;border:1px solid rgba(107,196,195,.32);border-radius:100px;background:rgba(38,113,117,.13);color:#b0e6e1;font-size:.6875rem;font-weight:650;line-height:1.5}
.project-status::before{content:"";width:5px;height:5px;border-radius:50%;background:#7bd6cd;flex:none}
.project-card-featured{grid-column:1/-1;display:grid;grid-template-columns:minmax(0,1.2fr) minmax(0,1fr);border-color:rgba(124,126,226,.42)}
.project-card-featured .project-shot{display:flex;flex-direction:column;border-bottom:0;border-right:1px solid rgba(103,140,208,.25)}
.project-card-featured .project-image-wrap{flex:1;min-height:280px}
.project-card-featured .project-card-body{justify-content:center;padding:36px}
.project-card-featured h3{font-size:2rem}
.project-card-featured .project-actions{margin-top:0}
.project-detail-hero .project-status{margin-top:22px}
.project-detail-hero .hero-actions{display:flex;flex-wrap:wrap}
.project-detail-hero .hero-actions .button{width:auto}
.project-detail-summary{display:grid;grid-template-columns:minmax(0,1fr) minmax(0,1fr);gap:64px;align-items:start}
.project-detail-summary>div,.project-detail-summary aside{min-width:0}
.project-detail-summary h2{margin-top:12px}
.project-detail-facts{margin:0;padding:28px;border:1px solid rgba(103,140,208,.3);border-radius:22px;background:linear-gradient(145deg,#13213a,#0d1728)}
.project-detail-facts>div+div{margin-top:20px;padding-top:20px;border-top:1px solid rgba(103,140,208,.2)}
.project-detail-facts dt{color:#93bfff;font-size:.6875rem;letter-spacing:.12em;text-transform:uppercase;font-weight:750}
.project-detail-facts dd{margin:8px 0 0;color:#e0e9f7;font-size:1rem;line-height:1.7;overflow-wrap:anywhere}
.project-detail-facts a{color:#9dd0ff}
.project-detail-points{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:24px;margin-top:38px}
.project-detail-point{min-width:0;padding:28px;border:1px solid rgba(103,140,208,.25);border-radius:20px;background:linear-gradient(145deg,#13213a,#0d1728)}
.project-detail-point h3{margin:0 0 12px;font-size:1.1875rem;line-height:1.4;letter-spacing:-.02em}
.project-detail-point p{margin:0;font-size:1rem;line-height:1.8;color:#adbbcf}
.project-gallery{background:linear-gradient(180deg,#0b1423,#0b1220)}
.project-gallery .section-heading{margin-bottom:36px}
.project-gallery-grid{display:grid;grid-template-columns:minmax(0,1fr) 240px;gap:28px;align-items:start}
.project-capture{min-width:0;margin:0}
.project-capture .project-shot{overflow:hidden;border:1px solid rgba(103,140,208,.32);border-radius:20px;box-shadow:0 20px 50px rgba(0,0,0,.2)}
.project-capture img{display:block;width:100%;height:auto}
.project-capture figcaption{color:#9db1cf;font-size:.8125rem;line-height:1.7;margin-top:14px}
.project-gallery-note{margin-top:26px}
@media(max-width:950px){
  .project-card-featured{display:flex}
  .project-card-featured .project-shot{display:block;border-right:0;border-bottom:1px solid rgba(103,140,208,.25)}
  .project-card-featured .project-image-wrap{min-height:0}
  .project-card-featured .project-card-body{padding:28px}
  .project-detail-summary{gap:32px}
  .project-detail-points{gap:18px}
  .project-detail-point{padding:22px}
  .project-gallery-grid{grid-template-columns:minmax(0,1fr) 200px;gap:24px}
}
@media(max-width:720px){
  .project-card-featured .project-card-body{padding:24px}
  .project-card-featured h3{font-size:1.75rem}
  .project-detail-summary,.project-detail-points,.project-gallery-grid{grid-template-columns:minmax(0,1fr);gap:24px}
  .project-detail-facts,.project-detail-point{padding:24px}
  .project-capture-mobile{width:min(100%,320px);justify-self:center}
  .project-detail-hero .hero-actions{display:grid;grid-template-columns:1fr}
  .project-detail-hero .hero-actions .button{width:100%}
  .project-capture .project-window-bar{font-size:.6875rem}
}
