/* RC1.3-L — Final Project Map Lock × approved L0.2 desktop rail.
   This layer is isolated from K's Hero, Profile, closing, motion, loading and mobile shell. */
:root { --l-ink:#e9e8e2; --l-muted:#9b9b94; --l-line:rgba(233,232,226,.16); --l-row-gap:28px; }
[data-rc1-3l-legacy-portfolio] { display:none !important; }
.l-portfolio { background:#090909; color:var(--l-ink); }
.l-section { padding:clamp(84px,9vw,148px) 0 clamp(96px,10vw,168px); }
.l-section__inner { width:min(100% - 40px, 1120px); margin:auto; }
.l-section__header { display:grid; grid-template-columns:150px minmax(0,1fr); gap:28px; margin:0 0 72px; padding-bottom:20px; border-bottom:1px solid var(--l-line); }
.l-section__kicker,.l-project__number,.l-project__level3,.l-project__role-label,.l-more { font-size:10px; font-weight:550; letter-spacing:.15em; line-height:1.5; text-transform:uppercase; }
.l-section__kicker,.l-project__number,.l-project__level3,.l-project__role-label { color:var(--l-muted); }
.l-section__header h2 { margin:0; font-size:clamp(38px,5vw,72px); font-weight:470; letter-spacing:-.05em; line-height:.96; }
.l-project-list { display:grid; gap:104px; }
.l-project { min-width:0; }
.l-project__header { width:min(900px,100%); display:grid; grid-template-columns:56px minmax(0,1fr); gap:20px; margin:0 0 32px; padding-top:14px; border-top:1px solid var(--l-line); }
.l-project__title { margin:0; font-size:clamp(25px,3.2vw,42px); font-weight:470; letter-spacing:-.035em; line-height:1.12; }
.l-project__level3 { margin:10px 0 0; }
.l-project__role { margin:16px 0 0; color:#c7c7bf; font-size:12px; line-height:1.7; }
.l-project__role-label { display:block; margin-bottom:4px; }
.l-project__subgroup { margin:0; padding:0; border:0; }
.l-project__subgroup + .l-project__subgroup { margin-top:56px; }
.l-project__subgroup > header { margin:0 0 22px; }
.l-project__sublevel3,.l-project__subnote { margin:0; font-size:10px; font-weight:550; letter-spacing:.15em; line-height:1.5; text-transform:uppercase; }
.l-project__sublevel3 { color:var(--l-muted); }
.l-project__subnote { margin-top:6px; color:#c7c7bf; font-size:9px; }
.l-rows { display:grid; gap:48px; }
.l-row { display:grid; justify-content:center; gap:var(--l-row-gap); width:max-content; max-width:100%; margin-inline:auto; }
.l-row--single { grid-template-columns:minmax(0,720px); }
.l-row--double { grid-template-columns:repeat(2,minmax(0,520px)); }
.l-row--three { grid-template-columns:repeat(3,minmax(0,380px)); }
.l-media { margin:0; min-width:0; background:#050505; }
.l-media img { display:block; width:100%; max-width:100%; height:auto; max-height:min(680px,70vh); object-fit:contain; background:#050505; }
.l-row--single .l-media[data-orientation="VERTICAL"] { width:clamp(420px,34vw,535px); justify-self:center; }
.l-row--double .l-media[data-orientation="VERTICAL"] { width:100%; }
.l-more { display:inline-flex; align-items:center; gap:10px; margin-top:28px; padding:0; color:var(--l-ink); border:0; border-top:1px solid var(--l-line); background:transparent; cursor:pointer; }
.l-more span { padding-top:11px; }
.l-more strong { padding-top:11px; font-weight:500; }
.l-more-stills[hidden] { display:none; }
.l-more-stills { margin-top:42px; }
@media (min-width:1180px) {
  .l-section__inner { width:var(--desktop-rail, min(1120px,calc(100vw - 96px))); max-width:none; }
  .l-section { padding-top:148px; padding-bottom:158px; }
  .l-section__header { grid-template-columns:170px minmax(0,1fr); }
  .l-project__header { margin-bottom:34px; }
  .l-row--single { grid-template-columns:var(--l-single-landscape,clamp(550px,calc(14.583vw + 340px),620px)); }
  .l-row--double { grid-template-columns:repeat(2,var(--l-pair,clamp(500px,calc(10.417vw + 350px),550px))); }
  .l-row--three { grid-template-columns:repeat(3,var(--l-triple,clamp(380px,calc(8.333vw + 260px),420px))); }
}
@media (min-width:1180px) and (max-width:1279px) { :root { --desktop-rail:calc(100vw - 96px); } .l-row--double { --l-pair:min(500px,calc((var(--desktop-rail) - var(--l-row-gap))/2)); } }
@media (min-width:1280px) and (max-width:1439px) { :root { --desktop-margin:clamp(64px,calc(35vw - 384px),120px); --desktop-rail:calc(100vw - (var(--desktop-margin)*2)); } .l-row--double { --l-pair:min(540px,calc((var(--desktop-rail) - var(--l-row-gap))/2)); } }
@media (min-width:1440px) { :root { --desktop-rail:min(1440px,calc(100vw - 240px)); } }
@media (min-width:1180px) and (max-width:1439px) { .l-row--three { grid-template-columns:repeat(2,var(--l-triple,clamp(380px,calc(8.333vw + 260px),420px))); row-gap:48px; } .l-row--three > .l-media:nth-child(3) { grid-column:1 / -1; width:var(--l-triple,clamp(380px,calc(8.333vw + 260px),420px)); justify-self:center; } }
@media (min-width:1180px) and (max-width:1439px) {
  /* Vertical sets stay as a measured 3-up block instead of collapsing to a
     dangling single below a pair. The L0.2 2+1 rule remains for landscapes. */
  .l-row--three.l-row--vertical-group { grid-template-columns:repeat(3,minmax(320px,calc((var(--desktop-rail) - (var(--l-row-gap) * 2)) / 3))); row-gap:0; }
  .l-row--three.l-row--vertical-group > .l-media:nth-child(3) { grid-column:auto; width:auto; justify-self:stretch; }
}
@media (min-width:821px) and (max-width:1120px) { .hero-portrait { width:min(48vw,400px); min-width:240px; } }
@media (min-width:1121px) { .hero-portrait { width:min(31vw,420px); min-width:240px; } }
@media (max-width:820px) {
  /* Mobile deliberately remains the RC1.3-K shell: only final copy and
     additions in collapsed More Stills are synchronised by the L script. */
  .l-portfolio { display:none; }
  [data-rc1-3l-legacy-portfolio] { display:block !important; }
  .rc1-3l-mobile-level3 { margin:8px 0 0; color:#aaa9a2; font-size:10px; font-weight:550; letter-spacing:.15em; line-height:1.5; text-transform:uppercase; }
  .rc1-3l-mobile-extra { margin-top:22px; }
  [data-rc1-3l-mobile-extra-control] { margin-top:20px; }

  /* RC1.3-N point fixes: retain K's mobile system while normalising the
     reconciled Level 2 wrappers and complete small-project presentation. */
  .rc1-3n-level2-title {
    display:block !important;
    width:auto !important;
    max-width:100% !important;
    margin:0 !important;
    padding:0 !important;
    color:#edf5f7 !important;
    font-family:Inter,"SF Pro Display","PingFang SC","Microsoft YaHei",Arial,sans-serif !important;
    font-size:clamp(24px,7vw,30px) !important;
    font-weight:470 !important;
    line-height:1.12 !important;
    letter-spacing:-.035em !important;
    text-transform:none !important;
    opacity:1 !important;
    white-space:normal !important;
    overflow-wrap:anywhere;
  }
  [data-rc1-3l-legacy-portfolio] .selected-work > header {
    grid-template-columns:28px minmax(0,1fr) !important;
    gap:10px !important;
  }
  .rc1-3n-complete-by-default > [hidden]:not(template),
  .rc1-3n-unified-more-project > [hidden]:not(template),
  .rc1-3n-unified-more[hidden] { display:none !important; }
  .rc1-3n-default-grid,
  .rc1-3n-unified-more {
    display:grid;
    width:100%;
    gap:12px 8px;
    margin-top:22px;
  }
  .rc1-3n-default-grid figure,
  .rc1-3n-unified-more figure { min-width:0; margin:0; }
  .rc1-3n-default-grid picture,
  .rc1-3n-default-grid img,
  .rc1-3n-unified-more picture,
  .rc1-3n-unified-more img { display:block; width:100%; max-width:100%; height:auto; object-fit:contain; background:#050505; }
  .rc1-3n-default-grid--film-three,
  .rc1-3n-default-grid--live-three { grid-template-columns:repeat(2,minmax(0,1fr)); }
  .rc1-3n-default-grid--film-three > :first-child,
  .rc1-3n-default-grid--live-three > :first-child { grid-column:1 / -1 !important; width:min(84%,520px) !important; justify-self:center !important; }
  .rc1-3n-default-grid--film-two { grid-template-columns:1fr; gap:18px; }
  .rc1-3n-default-grid--film-two > figure { width:min(76%,300px) !important; }
  .rc1-3n-default-grid--film-two > figure:nth-child(even) { justify-self:end !important; }
  .rc1-3n-default-grid--live-four,
  .rc1-3n-unified-more { grid-template-columns:repeat(2,minmax(0,1fr)); }
  .rc1-3n-unified-more-control { margin-top:20px; }

  /* The previous gap was the sum of Identity bottom padding, Profile
     padding, and the first chapter's 76px top padding. Reduce only that
     transition; later chapter rhythm and Hero composition stay untouched. */
  .identity { padding-bottom:24px; }
  .mobile-identity__lead { min-height:min(100svh,780px); }
  .profile-section { padding-top:20px; padding-bottom:22px; }
  [data-project-section="people"].portfolio-chapter--adaptive { padding-top:56px; }
}

@media (min-width:821px) {
  /* Profile already ends the Hero transition; only the first desktop
     portfolio entry needs a slightly shorter lead-in. */
  .l-section:first-child { padding-top:112px; }
}
