/* Creative Image uses the same grid, cards, spacing, navigation and type as Hyper Motion. */
.creative-project-trigger{position:absolute;inset:0;width:100%;height:100%;padding:0;border:0;background:var(--card);color:#fff;cursor:pointer;text-align:left}
.creative-project-trigger img{width:100%;height:100%;object-fit:contain;display:block;transition:transform .3s ease}
.creative-project-card .ugc-media{aspect-ratio:4/5;transition:border-color .2s ease,box-shadow .2s ease}
.creative-project-card:hover .ugc-media,.creative-project-card:focus-within .ugc-media{border-color:var(--line-strong);box-shadow:0 12px 32px #0006}
.creative-project-card:hover img{transform:none}
.creative-project-badge,.creative-project-hint{position:absolute;z-index:1;background:#09090be6;border:1px solid #ffffff26;border-radius:30px;font-size:10px;color:#fff;padding:7px 10px}
.creative-project-badge{top:14px;left:14px}
.creative-project-hint{bottom:14px;right:14px;transition:background .2s ease}
.creative-project-card:hover .creative-project-hint,.creative-project-trigger:focus-visible .creative-project-hint{background:#fff;color:#09090b}
.creative-dialog{border:1px solid var(--line-strong);border-radius:16px;padding:0;background:#09090b;color:#fff;width:min(980px,calc(100vw - 32px));max-width:980px;max-height:min(90vh,920px);max-height:min(90dvh,920px);margin:auto;box-shadow:0 28px 100px #000b}
.creative-dialog::backdrop{background:#000d;backdrop-filter:blur(12px)}
.creative-dialog-shell{padding:clamp(16px,2.5vw,30px)}
.creative-dialog-head{display:flex;justify-content:space-between;align-items:flex-start;gap:24px;border-bottom:1px solid var(--line);padding-bottom:16px}
.creative-dialog-head .ugc-eyebrow{margin-bottom:7px}
.creative-dialog-head h2{font-size:clamp(20px,2.2vw,32px);line-height:1.25;font-weight:700;letter-spacing:-.02em}
#creative-gallery-count{font-size:11px;color:var(--fg-2);margin-top:6px}
.creative-dialog-close{flex:none;display:inline-flex;align-items:center;justify-content:center;width:40px;height:40px;border:1px solid var(--line-strong);border-radius:50%;background:var(--card);color:var(--fg);cursor:pointer;font-size:14px;line-height:1;transition:background .2s ease,border-color .2s ease,color .2s ease,transform .15s ease}
.creative-dialog-close:hover{background:var(--card-hover);border-color:#fff;transform:scale(1.05)}
.creative-gallery-arrow{flex:none;display:inline-flex;align-items:center;justify-content:center;width:44px;height:44px;border:1px solid var(--line-strong);border-radius:50%;background:var(--card);color:var(--fg);cursor:pointer;padding:0;margin:0;align-self:center;margin-bottom:28px;box-shadow:0 2px 10px rgba(0,0,0,.08);transition:background .2s ease,border-color .2s ease,color .2s ease,transform .15s ease,box-shadow .2s ease;z-index:5}
.creative-gallery-arrow svg{display:block;width:18px;height:18px;flex:none;pointer-events:none}
.creative-gallery-arrow:hover{background:var(--card-hover);border-color:#fff;transform:scale(1.06);box-shadow:0 4px 16px rgba(0,0,0,.14)}
.creative-gallery-arrow:active{transform:scale(0.96)}
.creative-viewer{position:relative;display:flex;align-items:center;justify-content:space-between;gap:clamp(10px,2vw,22px);min-height:240px;padding-top:14px}
.creative-viewer figure{min-width:0;flex:1;text-align:center;display:flex;flex-direction:column;align-items:center;justify-content:center;position:relative}
.creative-viewer figure img{display:block;width:auto;max-width:100%;height:auto;max-height:48vh;max-height:48dvh;object-fit:contain;margin:auto}
.creative-viewer figcaption{font-size:11px;color:var(--fg-2);padding-top:10px;min-height:28px;line-height:28px}
.creative-thumbnails{display:flex;justify-content:flex-start;gap:8px;overflow-x:auto;padding:18px 2px 2px;scrollbar-width:thin}
.creative-thumbnails::-webkit-scrollbar{display:none}
.creative-thumbnails button{flex:none;width:54px;height:62px;padding:0;border:1px solid var(--line);border-radius:7px;background:var(--card);overflow:hidden;cursor:pointer;opacity:.6}
.creative-thumbnails button[aria-current="true"]{border-color:#fff;opacity:1}
.creative-thumbnails button:hover{opacity:1}
.creative-thumbnails img{width:100%;height:100%;object-fit:contain}
@media(max-width:640px){
  .creative-dialog{width:calc(100vw - 16px);max-height:95dvh}
  .creative-dialog-shell{padding:14px}
  .creative-viewer{gap:0;padding-top:10px}
  .creative-viewer figure{width:100%;padding:0 4px}
  .creative-gallery-arrow{position:absolute;top:calc(50% - 14px);transform:translateY(-50%);margin-bottom:0;width:40px;height:40px;box-shadow:0 4px 16px rgba(0,0,0,.2);z-index:6}
  .creative-gallery-arrow[data-direction="-1"]{left:8px}
  .creative-gallery-arrow[data-direction="1"]{right:8px}
  .creative-gallery-arrow:hover{transform:translateY(-50%) scale(1.06)}
  .creative-gallery-arrow:active{transform:translateY(-50%) scale(0.96)}
  .creative-viewer figure img{max-height:52dvh}
  .creative-thumbnails{justify-content:flex-start}
}
@media(prefers-reduced-motion:reduce){.creative-project-trigger img,.creative-project-card .ugc-media,.creative-project-hint{transition:none}}
/* A fixed viewer stage prevents image-to-image layout shifts. */
.creative-dialog-shell{display:flex;flex-direction:column;max-height:inherit;overflow:auto}
.creative-dialog-actions{display:flex;align-items:center;justify-content:flex-end;flex-wrap:wrap;gap:8px}
.creative-fullscreen,.creative-original{display:inline-flex;align-items:center;justify-content:center;min-height:40px;border:1px solid var(--line-strong);border-radius:24px;padding:8px 12px;background:var(--card);color:var(--fg);font-size:11px;cursor:pointer}
.creative-fullscreen:hover,.creative-original:hover{border-color:var(--fg);background:var(--card-hover)}
.creative-dialog-head{flex:none;gap:16px}
.creative-viewer{min-height:0;flex:1}
.creative-viewer figure{height:52dvh;display:flex;flex-direction:column;justify-content:center}
.creative-viewer figure img{min-height:0;max-height:calc(100% - 28px);max-width:100%;flex-shrink:1}
.creative-viewer figcaption{flex:none;min-height:28px}
.creative-thumbnails{flex:none;min-height:80px}
.creative-dialog.is-expanded{width:100vw;max-width:100vw;height:100dvh;max-height:100dvh;border:0;border-radius:0}
.creative-dialog.is-expanded .creative-dialog-shell,.creative-dialog-shell:fullscreen{width:100%;height:100dvh;max-height:100dvh;background:var(--bg);padding:16px;box-sizing:border-box}
.creative-dialog.is-expanded .creative-viewer{min-height:0;overflow:hidden}
.creative-dialog.is-expanded .creative-viewer figure{height:100%;min-height:0}
#creative-gallery-error{padding:10px;font-size:12px;color:var(--fg-2)}
@media(max-width:560px){.creative-dialog-head{flex-wrap:wrap;gap:12px}.creative-dialog-actions{width:100%;justify-content:flex-start}.creative-dialog-close{margin-left:auto}.creative-viewer figure{height:48dvh}.creative-dialog.is-expanded .creative-dialog-head .ugc-eyebrow{display:none}.creative-dialog.is-expanded .creative-thumbnails{display:none}}

.creative-dialog.is-expanded .creative-gallery-arrow{position:absolute;top:50%;transform:translateY(-50%);margin-bottom:0;z-index:10}
.creative-dialog.is-expanded .creative-gallery-arrow[data-direction="-1"]{left:clamp(12px,3vw,32px)}
.creative-dialog.is-expanded .creative-gallery-arrow[data-direction="1"]{right:clamp(12px,3vw,32px)}
.creative-dialog.is-expanded .creative-gallery-arrow:hover{transform:translateY(-50%) scale(1.06)}
.creative-dialog.is-expanded .creative-gallery-arrow:active{transform:translateY(-50%) scale(0.96)}
