/* Effigraph Gallery: the PW Media look. Montserrat for headings, Roboto for text, calm greys,
   the accent only as a thin line. Light theme per gallery. */
@font-face { font-family: 'Montserrat'; font-weight: 600; font-display: swap; src: url('fonts/montserrat-600.woff2') format('woff2'); }
@font-face { font-family: 'Montserrat'; font-weight: 700; font-display: swap; src: url('fonts/montserrat-700.woff2') format('woff2'); }
@font-face { font-family: 'Roboto'; font-weight: 400; font-display: swap; src: url('fonts/roboto-400.woff2') format('woff2'); }
@font-face { font-family: 'Roboto'; font-weight: 500; font-display: swap; src: url('fonts/roboto-500.woff2') format('woff2'); }

:root {
  --deep: #111111; --bg: #161616; --surface: #1f1f1f; --field: #242424; --border: #333333; --hair: #2a2a2a;
  --text: #e6e6e6; --hi: #ffffff; --dim: #8a8a8a; --accent: #afffac; --warn: #ffc46b; --err: #ff8a8a;
  --heart: #ffffff; --shade: rgba(0, 0, 0, .55);
  --head: "Montserrat", -apple-system, "Segoe UI", sans-serif; --body: "Roboto", -apple-system, "Segoe UI", sans-serif;
}
[data-theme="light"] {
  --deep: #ffffff; --bg: #fafafa; --surface: #f2f2f2; --field: #ffffff; --border: #dcdcdc; --hair: #e8e8e8;
  --text: #2a2a2a; --hi: #111111; --dim: #7a7a7a; --heart: #ffffff; --shade: rgba(0, 0, 0, .35);
}
* { box-sizing: border-box; -webkit-tap-highlight-color: transparent; }
html, body { margin: 0; background: var(--deep); color: var(--text); font: 14px/1.5 var(--body); -webkit-font-smoothing: antialiased; }
button, input, textarea, select { font: inherit; color: inherit; }
button { cursor: pointer; }
button:focus { outline: none; }
button:focus-visible, a:focus-visible { outline: 1px solid var(--dim); outline-offset: 2px; }
[hidden] { display: none !important; }
a { color: inherit; }

.eyebrow { font: 600 10px/1 var(--head); letter-spacing: 1.6px; text-transform: uppercase; color: var(--dim); }
.line { height: 1px; width: 48px; background: var(--accent); }
.btn { display: inline-flex; align-items: center; gap: 8px; background: var(--field); border: 1px solid var(--border); border-radius: 3px;
  color: var(--text); font: 600 12px/1 var(--head); letter-spacing: .3px; padding: 10px 14px; text-decoration: none; white-space: nowrap;
  transition: border-color .12s, color .12s; }
.btn:hover { border-color: var(--dim); color: var(--hi); }
.btn.primary { background: var(--hi); color: var(--deep); border-color: var(--hi); }
.btn.primary:hover { opacity: .9; color: var(--deep); }
.btn.ghost { background: transparent; }
.btn.small { padding: 7px 10px; font-size: 11px; }
.btn:disabled { opacity: .35; cursor: default; }
.btn svg { width: 15px; height: 15px; }
.field { width: 100%; background: var(--field); border: 1px solid var(--border); border-radius: 3px; padding: 10px 12px; }
.field:focus { outline: none; border-color: var(--dim); }
textarea.field { resize: vertical; min-height: 84px; }
label.lbl { display: block; font: 600 10px/1 var(--head); letter-spacing: 1.4px; text-transform: uppercase; color: var(--dim); margin: 16px 0 7px; }
.dim { color: var(--dim); }
.small { font-size: 12px; }

/* ---- client gallery */
.g-head { max-width: 1600px; margin: 0 auto; padding: 56px 24px 22px; display: flex; flex-wrap: wrap; gap: 18px; align-items: flex-end; }
.g-head h1 { margin: 10px 0 6px; font: 700 30px/1.15 var(--head); color: var(--hi); letter-spacing: -.2px; }
.g-head .meta { color: var(--dim); font-size: 13px; }
.g-head .line { margin-top: 14px; }
.g-tools { position: sticky; top: 0; z-index: 5; background: color-mix(in srgb, var(--deep) 92%, transparent); backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px); border-bottom: 1px solid var(--hair); }
.g-tools .in { max-width: 1600px; margin: 0 auto; padding: 10px 24px; display: flex; gap: 8px; align-items: center; flex-wrap: wrap; }
.tabs { display: flex; gap: 2px; align-self: stretch; }
.tabs button { background: transparent; border: 0; border-bottom: 1px solid transparent; color: var(--dim); font: 600 12px/1 var(--head);
  padding: 10px 10px 9px; letter-spacing: .3px; }
.tabs button:hover { color: var(--text); }
.tabs button.on { color: var(--hi); border-bottom-color: var(--accent); }
.spacer { flex: 1; }
.who { font-size: 12px; color: var(--dim); margin-right: 4px; }
.who button { background: none; border: 0; color: var(--dim); text-decoration: underline; text-underline-offset: 2px; padding: 0; font-size: 12px; }
.banner { max-width: 1600px; margin: 14px auto 0; padding: 0 24px; }
.banner div { border: 1px solid var(--border); border-left: 1px solid var(--accent); border-radius: 3px; padding: 11px 14px; color: var(--text); font-size: 13px; }

.grid { max-width: 1600px; margin: 0 auto; padding: 18px 24px 80px; }
.row { display: flex; gap: 6px; margin-bottom: 6px; }
.tile { position: relative; background: var(--surface); overflow: hidden; cursor: zoom-in; flex: none; }
.tile img { width: 100%; height: 100%; object-fit: cover; display: block; opacity: 0; transition: opacity .16s; }
.tile img.in { opacity: 1; }
.tile .acts { position: absolute; right: 6px; bottom: 6px; display: flex; gap: 4px; opacity: 0; transition: opacity .12s; }
.tile:hover .acts, .tile .acts.keep { opacity: 1; }
@media (hover: none) { .tile .acts { opacity: 1; } }
.icon-btn { width: 34px; height: 34px; display: inline-flex; align-items: center; justify-content: center; border: 0; border-radius: 3px;
  background: var(--shade); color: #fff; position: relative; }
.icon-btn svg { width: 17px; height: 17px; }
.icon-btn.fav svg path { fill: transparent; stroke: #fff; transition: fill .12s; }
.icon-btn.fav.on svg path { fill: var(--accent); stroke: var(--accent); }
.icon-btn .n { position: absolute; top: 3px; right: 3px; font: 600 9px/1 var(--head); }
.empty { text-align: center; color: var(--dim); padding: 80px 20px; }

/* lightbox */
.lb { position: fixed; inset: 0; z-index: 40; background: #0a0a0a; display: grid; grid-template-columns: 1fr auto; }
.lb[hidden] { display: none; }
.lb .stage { position: relative; display: flex; align-items: center; justify-content: center; min-width: 0; touch-action: pan-y; }
.lb .stage img { max-width: calc(100% - 120px); max-height: calc(100vh - 110px); max-height: calc(100dvh - 110px); display: block; user-select: none; -webkit-user-drag: none; }
.lb .nav { position: absolute; top: 50%; transform: translateY(-50%); background: none; border: 0; color: #cfcfcf; padding: 20px; }
.lb .nav svg { width: 26px; height: 26px; }
.lb .nav:hover { color: #fff; }
.lb .prev { left: 4px; } .lb .next { right: 4px; }
.lb .top { position: absolute; top: 0; left: 0; right: 0; display: flex; align-items: center; gap: 8px; padding: 12px 14px; color: #bdbdbd; font-size: 12px; }
.lb .top .name { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.lb .bottom { position: absolute; bottom: 0; left: 0; right: 0; display: flex; justify-content: center; gap: 8px; padding: 14px; }
.lb .icon-btn { background: rgba(255, 255, 255, .08); }
.lb .icon-btn:hover { background: rgba(255, 255, 255, .14); }
.lb .side { width: 340px; background: #141414; border-left: 1px solid #262626; display: flex; flex-direction: column; color: #e6e6e6; min-height: 0; }
.lb .side[hidden] { display: none; }
.side .hd { padding: 16px 16px 12px; border-bottom: 1px solid #262626; display: flex; align-items: center; }
.side .list { flex: 1; overflow: auto; padding: 8px 16px; }
.side .c { padding: 10px 0; border-bottom: 1px solid #222; }
.side .c b { font: 600 11.5px/1.2 var(--head); color: #fff; }
.side .c .t { white-space: pre-wrap; margin-top: 4px; font-size: 13px; }
.side .c.admin { border-left: 1px solid var(--accent); padding-left: 10px; }
.side form { padding: 12px 16px 16px; border-top: 1px solid #262626; display: grid; gap: 8px; }
.side .field { background: #1c1c1c; border-color: #333; color: #e6e6e6; }
@media (max-width: 760px) {
  .g-head { padding: 34px 16px 16px; } .g-head h1 { font-size: 24px; }
  .g-tools .in, .grid, .banner { padding-left: 12px; padding-right: 12px; }
  .lb { grid-template-columns: 1fr; }
  .lb .side { position: absolute; left: 0; right: 0; bottom: 0; width: auto; max-height: 62vh; border-left: 0; border-top: 1px solid #262626; }
  .lb .stage img { max-width: 100%; }
  .lb .nav { display: none; }
}

/* dialogs */
.dlg { position: fixed; inset: 0; z-index: 60; background: rgba(0, 0, 0, .6); display: flex; align-items: center; justify-content: center; padding: 16px; }
.dlg[hidden] { display: none; }
.dlg .box { width: 100%; max-width: 420px; background: var(--bg); border: 1px solid var(--border); border-radius: 4px; padding: 22px; }
.dlg h2 { margin: 6px 0 6px; font: 700 18px/1.25 var(--head); color: var(--hi); }
.dlg .acts { display: flex; justify-content: flex-end; gap: 8px; margin-top: 18px; }
.err { color: var(--err); font-size: 12px; min-height: 16px; margin-top: 8px; }
.menu { position: absolute; z-index: 20; background: var(--bg); border: 1px solid var(--border); border-radius: 3px; padding: 6px; min-width: 220px;
  box-shadow: 0 10px 30px rgba(0, 0, 0, .35); }
.menu a, .menu button { display: block; width: 100%; text-align: left; background: none; border: 0; padding: 9px 10px; border-radius: 2px; text-decoration: none; font-size: 13px; }
.menu a:hover, .menu button:hover { background: var(--surface); }

/* lock screen */
.lock { min-height: 100vh; min-height: 100dvh; display: flex; align-items: center; justify-content: center; padding: 20px; }
.lock .box { width: 100%; max-width: 360px; }
.lock .acts { display: flex; justify-content: flex-end; margin-top: 16px; }
.lock h1 { font: 700 24px/1.2 var(--head); color: var(--hi); margin: 10px 0 18px; }
.foot { max-width: 1600px; margin: 0 auto; padding: 0 24px 40px; color: var(--dim); font-size: 12px; display: flex; gap: 16px; flex-wrap: wrap; }
.foot a { color: var(--dim); }
.toast { position: fixed; left: 50%; bottom: 22px; transform: translateX(-50%); z-index: 80; background: var(--hi); color: var(--deep);
  border-radius: 3px; padding: 10px 14px; font-size: 13px; opacity: 0; transition: opacity .16s; pointer-events: none; }
.toast.on { opacity: 1; }
.logos { display: flex; align-items: center; gap: 16px; margin-bottom: 22px; }
.logos img { max-height: 44px; max-width: 200px; object-fit: contain; display: block; }
.logos .sep { width: 1px; height: 30px; background: var(--border); }
.foot .credit { opacity: .7; }
.g-head .kind { margin-top: 2px; }
.g-head .intro { margin: 14px 0 0; color: var(--dim); font-size: 13px; max-width: 560px; }
