.project-page-body{margin:0;background:#f7f8fa;color:#101820}.project-page-header{position:sticky;top:0;z-index:20;height:68px;padding:0 clamp(18px,4vw,62px);display:grid;grid-template-columns:1fr auto 1fr;align-items:center;border-bottom:1px solid #dfe4ea;background:rgba(247,248,250,.94);backdrop-filter:blur(16px)}.project-page-header a{text-decoration:none;color:inherit}.project-back{font-size:12px}.project-brand{font-size:11px;letter-spacing:.18em;font-weight:700}.project-page-header button{justify-self:end;border:1px solid #cad2db;background:transparent;padding:7px 10px;cursor:pointer}.project-page{max-width:1500px;margin:0 auto;padding:clamp(32px,6vw,90px) clamp(18px,4vw,62px) 100px}.project-hero{display:grid;grid-template-columns:minmax(0,1.25fr) minmax(320px,.75fr);gap:clamp(28px,5vw,80px);align-items:end;margin-bottom:clamp(42px,7vw,90px)}.project-hero-media img{display:block;width:100%;height:auto;max-height:78vh;object-fit:contain;background:#eef1f4}.project-kicker{font-size:9px;letter-spacing:.14em;color:#697584;text-transform:uppercase}.project-copy h1{font-size:clamp(42px,6vw,92px);line-height:.94;margin:14px 0 20px;font-weight:500}.project-meta{display:flex;flex-wrap:wrap;gap:8px 16px;font-size:11px;color:#66717e;margin-bottom:24px}.project-description{font-size:clamp(14px,1.4vw,18px);line-height:1.9;color:#3d4854;max-width:660px}.project-gallery-page{display:grid;grid-template-columns:repeat(12,1fr);gap:clamp(10px,1.6vw,22px)}.project-gallery-page figure{margin:0;grid-column:span 6;background:#eef1f4;cursor:zoom-in}.project-gallery-page figure:nth-child(3n+1){grid-column:span 7}.project-gallery-page figure:nth-child(3n+2){grid-column:span 5}.project-gallery-page img{display:block;width:100%;height:auto;object-fit:contain}.project-footer-nav{margin-top:80px;padding-top:24px;border-top:1px solid #d9e0e7;display:flex;justify-content:space-between;gap:20px}.project-lightbox{position:fixed;inset:0;z-index:100;background:rgba(7,10,14,.96);display:none;align-items:center;justify-content:center;padding:30px}.project-lightbox.open{display:flex}.project-lightbox img{max-width:96vw;max-height:92vh;object-fit:contain}.project-lightbox button{position:absolute;top:18px;right:22px;border:0;background:transparent;color:#fff;font-size:34px;cursor:pointer}.project-loading{padding:80px 0;color:#6b7682}@media(max-width:850px){.project-hero{grid-template-columns:1fr}.project-copy{order:-1}.project-gallery-page figure,.project-gallery-page figure:nth-child(n){grid-column:1/-1}.project-page-header{grid-template-columns:1fr auto}.project-brand{display:none}.project-copy h1{font-size:44px}}

/* Inline project editor — admin only */
.project-admin-bar{margin:-20px 0 34px;padding:12px 14px;border:1px solid #cdd7df;background:#fff;display:flex;align-items:center;justify-content:space-between;gap:20px;position:relative;z-index:5}.project-admin-bar>div{display:flex;align-items:center;gap:10px}.project-admin-bar b{font-size:9px;letter-spacing:.15em;background:#101820;color:#fff;padding:5px 7px}.project-admin-bar span{font-size:11px;color:#687583}.project-admin-bar button,.editor-card button,.file-action{border:1px solid #aebbc6;background:#fff;color:#101820;padding:9px 13px;cursor:pointer;font:inherit}.project-editor{margin:0 0 70px;padding:clamp(18px,3vw,34px);background:#edf1f3;border:1px solid #d2dbe2;scroll-margin-top:90px}.editor-head,.gallery-editor-head{display:flex;justify-content:space-between;align-items:flex-start;gap:24px;margin-bottom:22px}.editor-head span{font-size:8px;letter-spacing:.18em;color:#71808d}.editor-head h2{margin:5px 0 0;font-size:24px}.editor-head p,.gallery-editor-head p,.editor-card>p{font-size:11px;color:#6c7883;line-height:1.7;margin:5px 0}.editor-head p[data-kind="ok"]{color:#237455}.editor-head p[data-kind="error"]{color:#a63232}.editor-grid{display:grid;grid-template-columns:1.15fr .85fr;gap:20px}.editor-card{background:#fff;border:1px solid #d5dde3;padding:18px}.editor-card h3{margin:0 0 6px;font-size:15px}.cover-crop-editor{position:relative;aspect-ratio:16/9;overflow:hidden;background:#dfe5e9;touch-action:none;cursor:grab;margin-top:14px}.cover-crop-editor.dragging{cursor:grabbing}.cover-crop-editor img{position:absolute;inset:0;width:100%;height:100%;object-fit:cover;user-select:none;pointer-events:none}.cover-crop-editor i{position:absolute;left:50%;top:50%;width:22px;height:22px;border:1px solid #fff;border-radius:50%;transform:translate(-50%,-50%);box-shadow:0 0 0 1px #0005;pointer-events:none}.cover-crop-editor i:before,.cover-crop-editor i:after{content:"";position:absolute;background:#fff;box-shadow:0 0 1px #000}.cover-crop-editor i:before{width:30px;height:1px;left:-5px;top:10px}.cover-crop-editor i:after{height:30px;width:1px;top:-5px;left:10px}.crop-controls{display:flex;align-items:center;gap:9px;flex-wrap:wrap;margin-top:12px}.crop-controls label:first-child{display:flex;align-items:center;gap:8px;font-size:10px;flex:1;min-width:160px}.crop-controls input[type="range"]{width:100%}.file-action{display:inline-flex;align-items:center;justify-content:center;font-size:11px}.file-action.primary,.editor-save{background:#101820!important;color:#fff!important;border-color:#101820!important}.file-action input{position:absolute;width:1px;height:1px;opacity:0;pointer-events:none}.project-meta-form{display:grid;grid-template-columns:1fr 1fr;gap:10px}.project-meta-form label{font-size:9px;color:#6b7883;display:flex;flex-direction:column;gap:5px}.project-meta-form input,.project-meta-form textarea{border:1px solid #d4dce2;background:#fafbfb;padding:9px;color:#101820;font:inherit;width:100%}.project-meta-form .wide{grid-column:1/-1}.gallery-editor-card{margin-top:20px}.gallery-manager{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:14px}.gallery-manage-item{position:relative;background:#eef2f4;border:1px solid #d6dee4;aspect-ratio:16/10;overflow:hidden;cursor:grab}.gallery-manage-item.dragging{opacity:.42}.gallery-manage-item>img{width:100%;height:100%;object-fit:cover;display:block}.drag-handle{position:absolute;top:7px;right:7px;background:#fff;color:#111;padding:3px 7px;font-size:12px;box-shadow:0 2px 10px #0002}.gallery-manage-actions{position:absolute;left:6px;right:6px;bottom:6px;display:flex;gap:4px;justify-content:center}.gallery-manage-actions button,.gallery-manage-actions label{border:0;background:rgba(255,255,255,.94);padding:6px 7px;font-size:9px;cursor:pointer;color:#111}.gallery-manage-actions label input{position:absolute;width:1px;height:1px;opacity:0}.gallery-manage-actions .danger{color:#9b2828}.project-danger-zone{margin-top:20px;padding:16px 18px;border:1px solid #e2baba;background:#fff8f8;display:flex;align-items:center;justify-content:space-between;gap:20px}.project-danger-zone div{display:flex;flex-direction:column;gap:3px}.project-danger-zone strong{font-size:12px;color:#8d2020}.project-danger-zone span{font-size:10px;color:#8b6b6b}.project-danger-zone button{border:1px solid #b83838;background:#a92727;color:#fff;padding:9px 13px;cursor:pointer}.project-hero-media{overflow:hidden;aspect-ratio:16/9;background:#eef1f4}.project-hero-media img{width:100%;height:100%;max-height:none;object-fit:cover}
@media(max-width:900px){.editor-grid{grid-template-columns:1fr}.gallery-manager{grid-template-columns:repeat(2,minmax(0,1fr))}.editor-head,.gallery-editor-head{flex-direction:column}.project-admin-bar span{display:none}}
@media(max-width:520px){.gallery-manager{grid-template-columns:1fr}.project-meta-form{grid-template-columns:1fr}.project-meta-form .wide{grid-column:auto}.project-danger-zone{align-items:flex-start;flex-direction:column}}


/* WYSIWYG project editor: editing happens on the published composition itself */
.wysiwyg-admin{position:sticky;top:78px;z-index:30;box-shadow:0 10px 30px rgba(16,24,32,.08)}
.wysiwyg-admin-actions{display:flex;align-items:center;gap:7px;flex-wrap:wrap;justify-content:flex-end}
.wysiwyg-admin .save-layout{background:#101820;color:#fff;border-color:#101820}
.wysiwyg-admin .save-layout:disabled{opacity:.34;cursor:default}
.wysiwyg-admin [data-kind="dirty"]{color:#9a6815}.wysiwyg-admin [data-kind="ok"]{color:#237455}.wysiwyg-admin [data-kind="error"]{color:#a63232}
.admin-add-render{border:1px solid #aebbc6;background:#fff;color:#101820;padding:9px 13px;cursor:pointer;font-size:11px}
.admin-add-render input,.visual-edit-tools input,.inline-add-tile input{position:absolute;width:1px;height:1px;opacity:0;pointer-events:none}
.inline-meta-panel{margin:-12px 0 34px;padding:18px;background:#fff;border:1px solid #cfd8df;box-shadow:0 16px 44px rgba(16,24,32,.08);display:grid;grid-template-columns:1fr auto;gap:18px;align-items:end}
.inline-delete-project{border:1px solid #b83838;background:#fff;color:#a92727;padding:10px 13px;cursor:pointer}
.editable-media{position:relative;outline:1px dashed #81909c;outline-offset:5px}
.visual-edit-tools{position:absolute;z-index:8;display:flex;align-items:center;gap:5px;padding:5px;background:rgba(12,19,25,.82);backdrop-filter:blur(8px);border-radius:2px;box-shadow:0 5px 20px rgba(0,0,0,.15)}
.visual-edit-tools button,.visual-edit-tools label{border:0;background:#fff;color:#101820;padding:6px 8px;font:inherit;font-size:9px;cursor:pointer;white-space:nowrap}
.visual-edit-tools .danger{color:#a92727}.cover-tools{top:10px;right:10px}
.inline-cover-crop{position:absolute;z-index:9;left:10px;right:10px;bottom:10px;padding:9px 11px;background:rgba(255,255,255,.94);display:flex;align-items:center;gap:12px;box-shadow:0 5px 20px rgba(0,0,0,.12)}
.inline-cover-crop[hidden]{display:none}.inline-cover-crop span{font-size:9px;color:#53606b}.inline-cover-crop label{display:flex;align-items:center;gap:8px;font-size:9px;flex:1}.inline-cover-crop input{width:100%}.inline-cover-crop button{border:0;background:#101820;color:#fff;padding:7px 10px;cursor:pointer;font:inherit;font-size:9px}
.editable-media.crop-active{cursor:grabbing}.editable-media:not(.crop-active){cursor:default}
.project-gallery-page.is-editing{align-items:start}
.project-gallery-page.is-editing figure{position:relative;cursor:grab;outline:1px dashed rgba(70,88,103,.45);outline-offset:3px;transition:grid-column .08s linear,opacity .16s ease,transform .16s ease;min-width:0}
.project-gallery-page.is-editing figure:hover{outline-color:#101820}
.project-gallery-page.is-editing figure.dragging{opacity:.36;transform:scale(.985)}
.project-gallery-page.is-editing figure.drag-over{outline:2px solid #101820;outline-offset:4px}
.project-gallery-page.is-editing figure.resizing{cursor:ew-resize;outline:2px solid #101820;z-index:6}
.gallery-tools{top:8px;left:8px}.move-grip{color:#fff;font-size:15px;line-height:1;padding:0 4px;cursor:grab;user-select:none}
.resize-handle{position:absolute;right:-5px;bottom:-5px;width:28px;height:28px;z-index:10;cursor:ew-resize;background:#101820;border:3px solid #f7f8fa;box-shadow:0 2px 12px rgba(0,0,0,.18);touch-action:none}
.resize-handle i:before,.resize-handle i:after{content:"";position:absolute;right:5px;bottom:5px;background:#fff}.resize-handle i:before{width:10px;height:1px}.resize-handle i:after{height:10px;width:1px}
.size-badge{position:absolute;right:8px;top:8px;z-index:7;background:rgba(255,255,255,.92);padding:5px 7px;font:600 9px/1 system-ui;color:#101820}
.inline-add-tile{grid-column:span 6;min-height:180px;border:1px dashed #9aa8b3;background:#f1f4f6;display:grid;place-items:center;color:#566572;font-size:11px;cursor:pointer}
@media(max-width:850px){
  .wysiwyg-admin{top:72px}.wysiwyg-admin{align-items:flex-start}.wysiwyg-admin-actions{width:100%}
  .inline-meta-panel{grid-template-columns:1fr}
  .inline-add-tile{grid-column:1/-1}
  .resize-handle,.size-badge{display:none}
}

/* Per-image visual crop + pointer reorder. Editing never changes the published composition. */
.gallery-media-frame{position:relative;overflow:hidden;width:100%;line-height:0}
.gallery-media-frame img{display:block;width:100%;height:auto;will-change:transform;transition:transform .12s ease}
.project-gallery-page.is-editing .gallery-media-frame.crop-active{cursor:grab;touch-action:none;outline:2px solid rgba(255,255,255,.9);outline-offset:-2px}
.project-gallery-page.is-editing .gallery-media-frame.crop-active.dragging-crop{cursor:grabbing}
.gallery-crop-panel{position:absolute;z-index:11;left:8px;right:8px;bottom:8px;padding:8px 10px;background:rgba(255,255,255,.96);box-shadow:0 6px 24px rgba(0,0,0,.14);display:flex;align-items:center;gap:9px}
.gallery-crop-panel[hidden]{display:none}.gallery-crop-panel span{font-size:9px;color:#53606b;white-space:nowrap}.gallery-crop-panel label{display:flex;align-items:center;gap:7px;flex:1;font-size:9px}.gallery-crop-panel input{width:100%;min-width:70px}.gallery-crop-panel button{border:0;background:#101820;color:#fff;padding:6px 8px;font:inherit;font-size:9px;cursor:pointer}
.move-grip{touch-action:none;cursor:grab!important}.move-grip:active{cursor:grabbing!important}
body.gallery-reordering{user-select:none;cursor:grabbing}
.project-gallery-page.is-editing figure{cursor:default}
.project-gallery-page.is-editing figure[style]{min-width:0}
@media(max-width:850px){
 .gallery-tools{max-width:calc(100% - 16px);overflow-x:auto}
 .gallery-crop-panel{flex-wrap:wrap}
 .gallery-crop-panel span{width:100%}
}

/* WYSIWYG editor readability + reliable click controls */
.visual-edit-tools{gap:7px;padding:7px;background:rgba(12,19,25,.9);border-radius:8px;pointer-events:auto}
.visual-edit-tools button,.visual-edit-tools label{font-size:11px;line-height:1.2;font-weight:600;padding:8px 10px;border-radius:6px;min-height:32px;display:inline-flex;align-items:center;justify-content:center;pointer-events:auto}
.visual-edit-tools button:hover,.visual-edit-tools label:hover{background:#eef7f7}
.gallery-tools{max-width:calc(100% - 16px);overflow-x:auto;scrollbar-width:thin}
.move-grip{min-width:30px;height:32px;display:grid;place-items:center;background:rgba(255,255,255,.12);border-radius:6px;color:#fff;font-size:16px}
.gallery-size-tools{position:absolute;z-index:9;left:8px;bottom:8px;display:flex;align-items:center;gap:5px;flex-wrap:wrap;padding:6px 7px;background:rgba(255,255,255,.96);border:1px solid #d8e0e6;border-radius:8px;box-shadow:0 4px 18px rgba(0,0,0,.1)}
.gallery-size-tools span{font-size:10px;font-weight:700;color:#53606b;margin-inline-end:2px}
.gallery-size-tools button{border:1px solid #cad5dc;background:#fff;color:#101820;border-radius:6px;padding:6px 8px;font:600 10px/1 system-ui;cursor:pointer}
.gallery-size-tools button:hover{border-color:#50AFB1;color:#368f91;background:#eef9f9}
.gallery-crop-panel{z-index:12;left:8px;right:8px;bottom:52px;padding:11px 12px;gap:10px;border:1px solid #cfd8df;border-radius:8px;flex-wrap:wrap}
.gallery-crop-panel strong{font-size:11px;color:#101820}
.gallery-crop-panel span{font-size:10px;color:#53606b;white-space:normal}
.gallery-crop-panel label{font-size:10px;min-width:180px}
.gallery-crop-panel button{font-size:10px;border-radius:6px;padding:7px 9px}
.crop-nudges{display:flex;gap:5px}
.crop-nudges button{min-width:30px}
.size-badge{top:auto;bottom:8px;right:8px;font-size:10px;border-radius:6px}
.inline-cover-crop span,.inline-cover-crop label,.inline-cover-crop button{font-size:11px}
.wysiwyg-admin{font-size:12px}
.wysiwyg-admin button,.admin-add-render{font-size:11px;min-height:34px}
@media(max-width:850px){
 .gallery-tools{left:6px;right:6px;max-width:none}
 .gallery-size-tools{left:6px;right:6px;bottom:6px;overflow-x:auto;flex-wrap:nowrap}
 .gallery-crop-panel{bottom:54px}
}

/* Match the resize edge and pointer direction to the gallery writing direction. */
[dir="rtl"] .project-gallery-page .resize-handle{right:auto;left:-5px}
[dir="rtl"] .project-gallery-page .resize-handle i{display:block;transform:scaleX(-1);width:100%;height:100%}
[dir="rtl"] .project-gallery-page .size-badge{right:auto;left:8px}

/* Mobile is single-column; keep saved desktop spans without letting inline styles override it. */
@media(max-width:850px){
 .project-gallery-page figure[style]{grid-column:1/-1!important}
}

.project-story{max-width:860px;margin:clamp(28px,5vw,72px) auto;padding:clamp(20px,4vw,48px);background:#fff;border:1px solid #e2ebeb;border-radius:20px;line-height:2.15;color:#3d4854}.project-story h2{font-size:clamp(23px,3vw,34px);line-height:1.65;color:#214e50;margin:0 0 28px}.project-story h3{font-size:clamp(18px,2vw,23px);color:#214e50;margin:34px 0 12px}.project-story p{font-size:clamp(15px,1.3vw,18px);margin:0 0 22px}.project-story p:last-child{margin-bottom:0}

.project-films{margin:0 0 clamp(42px,7vw,90px)}.project-films h2{font-size:clamp(22px,3vw,32px);margin:0 0 24px}.project-films-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:24px}.project-films figure{margin:0;min-width:0}.project-films video{display:block;width:100%;aspect-ratio:16/9;object-fit:contain;background:#101820;border-radius:8px}.project-films figcaption{padding-top:12px;font-size:14px;color:#3d4854}@media(max-width:850px){.project-films-grid{grid-template-columns:1fr}}
