/* ==========================================================================
   PixProof — elegant client galleries
   ========================================================================== */
/* Brand: Moniek Aansorgh Fotografie (moniekaansorgh.nl) */
@font-face {
  font-family: 'Recline';
  src: url('../fonts/Recline-Light.ttf') format('truetype');
  font-weight: 100 900;
  font-style: normal;
  font-display: swap;
}

:root {
  --sage: #bbc2b9;
  --sage-light: var(--soft);
  --sand: #e3dcd2;
  --sand-light: #e3dcd2;
  --green: #637c6d;
  --green-dark: #2b4d3e;

  --bg: var(--sand);
  --soft: var(--sage);  /* boxes on the page: the other brand colour */
  --surface: #ffffff;
  --surface-2: var(--soft);
  --ink: var(--green-dark);
  --ink-2: #4b4f58;
  --muted: #7c807a;
  --line: #e3dcd2;
  --line-2: #cbd0c8;
  --accent: var(--green);
  --accent-2: var(--green-dark);
  --accent-soft: var(--sage-light);
  --gold: #c9a24f;
  --heart: #b8574b;
  --success: var(--green);
  --success-soft: var(--soft);
  --danger: #b2433a;
  --radius: 2px;
  --radius-sm: 2px;
  --shadow-sm: 0 1px 2px rgba(43, 77, 62, .05);
  --shadow: 0 1px 2px rgba(43, 77, 62, .04), 0 12px 30px -16px rgba(43, 77, 62, .2);
  --shadow-lg: 0 30px 80px -20px rgba(20, 35, 28, .4);
  --serif: 'Recline', 'Cormorant Garamond', Georgia, serif;
  --sans: 'Montserrat', system-ui, -apple-system, 'Segoe UI', Roboto, sans-serif;
  --ease: cubic-bezier(.2, .8, .2, 1);
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
body {
  margin: 0; background: var(--bg); color: var(--ink);
  font: 400 15px/1.55 var(--sans);
  -webkit-font-smoothing: antialiased; -moz-osx-font-smoothing: grayscale;
}
body.no-scroll { overflow: hidden; }
img { display: block; max-width: 100%; }
a { color: inherit; }
button { font: inherit; color: inherit; cursor: pointer; }
h1, h2, h3 { margin: 0; font-weight: 500; line-height: 1.15; }
p { margin: 0; }
[hidden] { display: none !important; }
.serif { font-family: var(--serif); letter-spacing: -.01em; }
.muted { color: var(--muted); }
.small { font-size: 13px; }
.mono { font-family: ui-monospace, 'Cascadia Code', Consolas, monospace; letter-spacing: .04em; }
.eyebrow { font-size: 11px; letter-spacing: .22em; text-transform: uppercase; color: var(--accent); font-weight: 600; margin-bottom: 8px; }
.eyebrow.light { color: rgba(255, 255, 255, .82); }

.i { width: 18px; height: 18px; fill: none; stroke: currentColor; stroke-width: 1.75; stroke-linecap: round; stroke-linejoin: round; flex: none; }
.i.inline { width: 14px; height: 14px; vertical-align: -2px; }

/* ---------------------------------------------------------------- buttons */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  padding: 10px 18px; border-radius: 999px; border: 1px solid transparent;
  font-size: 14px; font-weight: 500; text-decoration: none; white-space: nowrap;
  transition: background .2s, border-color .2s, color .2s, transform .15s, box-shadow .2s;
}
.btn:active { transform: translateY(1px); }
.btn:disabled { opacity: .55; pointer-events: none; }
.btn .i { width: 16px; height: 16px; }
.btn-lg { padding: 13px 24px; font-size: 15px; }
.btn-sm { padding: 7px 13px; font-size: 13px; }
.btn-block { width: 100%; }
.btn-primary { background: var(--ink); color: #fff; box-shadow: 0 6px 18px -8px rgba(28, 27, 25, .6); }
.btn-primary:hover { background: #000; box-shadow: 0 10px 24px -10px rgba(28, 27, 25, .7); }
.btn-accent { background: var(--accent); color: #fff; box-shadow: 0 6px 18px -8px rgba(168, 129, 74, .8); }
.btn-accent:hover { background: var(--accent-2); }
.btn-ghost { background: var(--surface); border-color: var(--line-2); color: var(--ink); }
.btn-ghost:hover { border-color: var(--ink); }
.btn-danger { background: #fff; border-color: #f0c9c9; color: var(--danger); }
.btn-danger:hover { background: var(--danger); color: #fff; border-color: var(--danger); }

.icon-btn {
  display: inline-grid; place-items: center; width: 38px; height: 38px; border-radius: 50%;
  border: 1px solid transparent; background: transparent; color: var(--ink-2); text-decoration: none;
  transition: background .2s, color .2s, border-color .2s, transform .15s;
}
.icon-btn:hover { background: var(--surface-2); color: var(--ink); }
.icon-btn-sm { width: 32px; height: 32px; }
.icon-btn-sm .i { width: 16px; height: 16px; }
.icon-btn.glass { background: rgba(255, 255, 255, .92); backdrop-filter: blur(6px); box-shadow: var(--shadow-sm); }
.icon-btn.glass:hover { background: #fff; transform: scale(1.06); }
.icon-btn.glass.danger:hover { color: var(--danger); }

/* ---------------------------------------------------------------- forms */
.stack { display: grid; gap: 16px; margin-top: 22px; }
.field { display: grid; gap: 7px; }
.field > span { font-size: 12px; font-weight: 600; letter-spacing: .04em; color: var(--ink-2); }
.field > span em { font-style: normal; font-weight: 400; color: var(--muted); letter-spacing: 0; }
input:not([type=checkbox]):not([type=file]), textarea, select {
  width: 100%; padding: 12px 14px; border-radius: var(--radius-sm);
  border: 1px solid var(--line-2); background: #fff; color: var(--ink);
  font: inherit; font-size: 15px; transition: border-color .2s, box-shadow .2s; outline: none;
}
textarea { resize: vertical; line-height: 1.5; }
input:focus, textarea:focus, select:focus { border-color: var(--accent); box-shadow: 0 0 0 4px rgba(168, 129, 74, .14); }
input::placeholder, textarea::placeholder { color: #b0a99e; }
.input-group { display: flex; gap: 8px; align-items: center; }
.input-group .icon-btn { border-color: var(--line-2); width: 46px; height: 46px; border-radius: var(--radius-sm); }
.copy-row { display: flex; gap: 8px; }
.copy-row input { background: var(--surface-2) !important; }

.toggle-field { display: flex; align-items: center; gap: 14px; cursor: pointer; padding: 12px 0; }
.toggle-field input { position: absolute; opacity: 0; pointer-events: none; }
.toggle { width: 44px; height: 26px; border-radius: 999px; background: var(--line-2); position: relative; flex: none; transition: background .2s; }
.toggle::after { content: ''; position: absolute; top: 3px; left: 3px; width: 20px; height: 20px; border-radius: 50%; background: #fff; box-shadow: 0 1px 3px rgba(0, 0, 0, .2); transition: transform .25s var(--ease); }
.toggle-field input:checked + .toggle { background: var(--accent); }
.toggle-field input:checked + .toggle::after { transform: translateX(18px); }
.toggle-field input:focus-visible + .toggle { box-shadow: 0 0 0 4px rgba(168, 129, 74, .2); }

/* ---------------------------------------------------------------- toast */
.toast {
  position: fixed; left: 50%; bottom: 28px; z-index: 1000; display: flex; align-items: center; gap: 10px;
  padding: 12px 18px; border-radius: 999px; background: var(--ink); color: #fff; font-size: 14px;
  box-shadow: var(--shadow-lg); transform: translate(-50%, 24px); opacity: 0; pointer-events: none;
  transition: transform .35s var(--ease), opacity .35s var(--ease); max-width: calc(100vw - 32px);
}
.toast.show { transform: translate(-50%, 0); opacity: 1; }
.toast .i { width: 16px; height: 16px; color: #8fd6ad; }
.toast-error .i { color: #ff9b9b; }

/* ---------------------------------------------------------------- brand / topbar */
.brand { display: inline-flex; align-items: center; gap: 10px; text-decoration: none; }
.brand-mark { width: 34px; height: 34px; border-radius: 10px; background: var(--ink); color: #d9b77e; display: grid; place-items: center; }
.brand-mark .i { width: 19px; height: 19px; }
.brand-name { font-family: var(--serif); font-size: 25px; font-weight: 600; letter-spacing: -.01em; }
.brand-light .brand-mark { background: rgba(255, 255, 255, .14); color: #f3d9a8; }
.brand-light .brand-name { color: #fff; }

.topbar { position: sticky; top: 0; z-index: 50; background: rgba(248, 246, 242, .82); backdrop-filter: saturate(1.6) blur(14px); border-bottom: 1px solid var(--line); }
.topbar-inner { max-width: 1320px; margin: 0 auto; padding: 12px 28px; display: flex; align-items: center; gap: 36px; }
.topnav { display: flex; gap: 6px; flex: 1; }
.topnav a { text-decoration: none; padding: 8px 14px; border-radius: 999px; font-size: 14px; font-weight: 500; color: var(--muted); transition: .2s; }
.topnav a:hover { color: var(--ink); }
.topnav a.active { color: var(--ink); background: var(--surface); box-shadow: var(--shadow-sm); }
.topbar-user { display: flex; align-items: center; gap: 12px; }
.topbar-user form { margin: 0; }
.user-meta { display: grid; line-height: 1.25; }
.user-meta strong { font-size: 13px; font-weight: 600; }
.user-meta span { font-size: 12px; color: var(--muted); }
.avatar { width: 36px; height: 36px; border-radius: 50%; display: grid; place-items: center; flex: none; background: linear-gradient(135deg, #d8b98a, #a8814a); color: #fff; font-weight: 600; font-size: 14px; }
.avatar-sm { width: 30px; height: 30px; font-size: 12px; }
.avatar.all { background: var(--ink); }
.avatar .i { width: 15px; height: 15px; }

/* ---------------------------------------------------------------- layout */
.container { max-width: 1320px; margin: 0 auto; padding: 36px 28px 80px; }
.page-head { display: flex; align-items: flex-end; justify-content: space-between; gap: 24px; margin-bottom: 32px; flex-wrap: wrap; }
.page-title { font-size: clamp(36px, 4.4vw, 52px); margin-bottom: 8px; }
.head-actions { display: flex; gap: 10px; flex-wrap: wrap; }
.back-link { display: inline-flex; align-items: center; gap: 6px; font-size: 13px; color: var(--muted); text-decoration: none; margin-bottom: 18px; transition: color .2s, gap .2s; }
.back-link:hover { color: var(--ink); gap: 9px; }
.back-link .i { width: 15px; height: 15px; }
.meta-row { display: flex; gap: 18px; flex-wrap: wrap; font-size: 14px; }
.meta-row span { display: inline-flex; align-items: center; gap: 6px; }
.meta-row .i { width: 15px; height: 15px; }
.chip { display: inline-flex; align-items: center; gap: 5px; padding: 3px 10px; border-radius: 999px; font-size: 11.5px; font-weight: 500; background: var(--surface-2); color: var(--muted); }
.chip .i { width: 12px; height: 12px; stroke-width: 2.4; }
.chip-success { background: var(--success-soft); color: var(--success); }

/* ---------------------------------------------------------------- auth */
.auth { display: grid; grid-template-columns: 1.05fr 1fr; min-height: 100vh; }
.auth-art { position: relative; overflow: hidden; background: #1a1714; color: #fff; display: flex; align-items: flex-end; padding: 56px; }
.auth-art::after { content: ''; position: absolute; inset: 0; background: linear-gradient(180deg, rgba(20, 17, 14, .1) 20%, rgba(20, 17, 14, .92) 88%); }
.auth-art-mosaic { position: absolute; inset: -40px; display: grid; grid-template-columns: repeat(3, 1fr); grid-template-rows: 1.2fr 1fr; gap: 14px; transform: rotate(-6deg) scale(1.08); opacity: .9; }
.auth-art-mosaic span { border-radius: 18px; animation: float 14s ease-in-out infinite; }
.auth-art-mosaic span:nth-child(1) { background: radial-gradient(circle at 30% 30%, #f0c98e, #b4774a 60%, #5d3a28); }
.auth-art-mosaic span:nth-child(2) { background: radial-gradient(circle at 70% 20%, #e7dccb, #9aa59a 55%, #3e4b47); animation-delay: -3s; }
.auth-art-mosaic span:nth-child(3) { background: radial-gradient(circle at 40% 70%, #f6e3c7, #d49c7c 50%, #7a4b45); animation-delay: -6s; }
.auth-art-mosaic span:nth-child(4) { background: radial-gradient(circle at 60% 40%, #c8d3dc, #7c8ea0 55%, #2f3a48); animation-delay: -9s; }
.auth-art-mosaic span:nth-child(5) { background: radial-gradient(circle at 30% 60%, #f4d7b3, #c49264 55%, #5a4130); animation-delay: -2s; }
.auth-art-mosaic span:nth-child(6) { background: radial-gradient(circle at 50% 30%, #e9e2d6, #b3a48c 55%, #5c5040); animation-delay: -7s; }
@keyframes float { 50% { transform: translateY(-14px); } }
.auth-art-copy { position: relative; z-index: 1; max-width: 460px; }
.auth-art-copy h2 { font-size: clamp(40px, 4.5vw, 60px); margin: 28px 0 16px; font-weight: 500; }
.auth-art-copy h2 em { color: #f0cf98; }
.auth-art-copy p { color: rgba(255, 255, 255, .75); font-size: 16px; }
.auth-main { display: grid; place-items: center; padding: 40px 24px; }
.auth-card { width: 100%; max-width: 400px; }
.auth-card h1 { font-size: 44px; margin-bottom: 8px; }
.auth-card .btn-block { margin-top: 8px; }
.auth-switch { margin-top: 26px; font-size: 14px; color: var(--muted); text-align: center; }
.auth-switch a { color: var(--accent-2); font-weight: 500; }

/* ---------------------------------------------------------------- dashboard cards */
.gallery-cards { display: grid; grid-template-columns: repeat(auto-fill, minmax(290px, 1fr)); gap: 26px; }
.gcard { display: flex; flex-direction: column; background: var(--surface); border-radius: var(--radius); overflow: hidden; text-decoration: none; box-shadow: var(--shadow); border: 1px solid var(--line); transition: transform .35s var(--ease), box-shadow .35s var(--ease); text-align: left; padding: 0; }
.gcard:hover { transform: translateY(-4px); box-shadow: 0 2px 4px rgba(28, 22, 12, .04), 0 24px 50px -18px rgba(28, 22, 12, .28); }
.gcard-cover { position: relative; aspect-ratio: 4 / 3; background: var(--surface-2); overflow: hidden; }
.gcard-cover img { width: 100%; height: 100%; object-fit: cover; transition: transform .8s var(--ease); }
.gcard:hover .gcard-cover img { transform: scale(1.045); }
.gcard-cover .chip { position: absolute; left: 12px; top: 12px; box-shadow: var(--shadow-sm); }
.gcard-empty { position: absolute; inset: 0; display: grid; place-content: center; justify-items: center; gap: 8px; color: var(--muted); font-size: 13px; background: repeating-linear-gradient(45deg, var(--surface-2), var(--surface-2) 12px, #fff 12px, #fff 24px); }
.gcard-empty .i { width: 30px; height: 30px; stroke-width: 1.3; }
.gcard-body { padding: 18px 20px 20px; }
.gcard-body h3 { font-size: 25px; margin-bottom: 2px; }
.gcard-stats { display: flex; gap: 16px; margin-top: 14px; padding-top: 14px; border-top: 1px solid var(--line); font-size: 13px; color: var(--muted); }
.gcard-stats span { display: inline-flex; align-items: center; gap: 6px; }
.gcard-stats .i { width: 15px; height: 15px; }
.gcard-new { border: 1.5px dashed var(--line-2); background: transparent; box-shadow: none; align-items: center; justify-content: center; gap: 14px; min-height: 300px; color: var(--muted); font-size: 14px; font-weight: 500; }
.gcard-new:hover { border-color: var(--accent); color: var(--accent-2); background: var(--accent-soft); box-shadow: none; }
.gcard-new .plus { width: 54px; height: 54px; border-radius: 50%; display: grid; place-items: center; background: var(--surface); box-shadow: var(--shadow); }

.empty-state { text-align: center; padding: 70px 20px; background: var(--surface); border-radius: 22px; border: 1px solid var(--line); box-shadow: var(--shadow); }
.empty-state h2 { font-size: 36px; margin-bottom: 10px; }
.empty-state p { margin-bottom: 28px; line-height: 1.7; }
.empty-illustration { position: relative; width: 220px; height: 150px; margin: 0 auto 30px; }
.empty-illustration span { position: absolute; width: 120px; height: 140px; border-radius: 12px; border: 6px solid #fff; box-shadow: var(--shadow); left: 50px; top: 0; }
.empty-illustration span:nth-child(1) { background: linear-gradient(160deg, #e9d3b0, #b98f5d); transform: rotate(-12deg) translateX(-44px); }
.empty-illustration span:nth-child(2) { background: linear-gradient(160deg, #cfd7d4, #7e928c); transform: rotate(10deg) translateX(44px); }
.empty-illustration span:nth-child(3) { background: linear-gradient(160deg, #f3dfd1, #c8957f); }
.small-empty { box-shadow: none; padding: 60px 20px; grid-column: 1 / -1; }
.empty-icon { width: 64px; height: 64px; border-radius: 50%; display: grid; place-items: center; margin: 0 auto 18px; background: var(--accent-soft); color: var(--accent-2); }
.empty-icon .i { width: 26px; height: 26px; }

/* ---------------------------------------------------------------- modal */
.modal { position: fixed; inset: 0; z-index: 200; display: grid; place-items: center; padding: 20px; }
.modal-backdrop { position: absolute; inset: 0; background: rgba(22, 18, 12, .45); backdrop-filter: blur(4px); opacity: 0; transition: opacity .25s; }
.modal-card { position: relative; width: 100%; max-width: 500px; max-height: calc(100vh - 40px); overflow: auto; background: var(--surface); border-radius: 20px; padding: 32px; box-shadow: var(--shadow-lg); opacity: 0; transform: translateY(16px) scale(.98); transition: opacity .25s var(--ease), transform .3s var(--ease); }
.modal.open .modal-backdrop { opacity: 1; }
.modal.open .modal-card { opacity: 1; transform: none; }
.modal-card h2 { font-size: 34px; margin-bottom: 6px; }
.modal-x { position: absolute; top: 16px; right: 16px; }
.modal-actions { display: flex; justify-content: flex-end; gap: 10px; margin-top: 26px; flex-wrap: wrap; }
.modal-card .field { margin-top: 0; }
.modal-card > .field { margin-top: 18px; }

/* ---------------------------------------------------------------- tabs */
.tabs { display: flex; gap: 4px; border-bottom: 1px solid var(--line); margin-bottom: 28px; overflow-x: auto; scrollbar-width: none; }
.tab { display: inline-flex; align-items: center; gap: 8px; padding: 12px 16px; background: none; border: 0; border-bottom: 2px solid transparent; margin-bottom: -1px; font-size: 14px; font-weight: 500; color: var(--muted); white-space: nowrap; transition: color .2s, border-color .2s; }
.tab .i { width: 16px; height: 16px; }
.tab:hover { color: var(--ink); }
.tab.active { color: var(--ink); border-bottom-color: var(--ink); }
.tab-count { background: var(--surface-2); border-radius: 999px; padding: 1px 8px; font-size: 12px; }
.tab-panel { animation: fadeUp .35s var(--ease); }
@keyframes fadeUp { from { opacity: 0; transform: translateY(6px); } }

/* ---------------------------------------------------------------- dropzone & admin grid */
.dropzone { display: grid; justify-items: center; gap: 8px; text-align: center; padding: 64px 24px; border-radius: 20px; border: 1.5px dashed var(--line-2); background: var(--surface); cursor: pointer; transition: border-color .2s, background .2s, padding .3s var(--ease); }
.dropzone:hover, .dropzone.drag { border-color: var(--accent); background: var(--accent-soft); }
.dropzone.drag { transform: scale(1.005); }
.dz-icon { width: 64px; height: 64px; border-radius: 50%; display: grid; place-items: center; background: var(--accent-soft); color: var(--accent-2); margin-bottom: 8px; transition: transform .3s var(--ease); }
.dropzone:hover .dz-icon, .dropzone.drag .dz-icon { transform: translateY(-4px); background: #fff; }
.dz-icon .i { width: 26px; height: 26px; }
.dz-title { font-family: var(--serif); font-size: 26px; font-weight: 500; }
.dz-sub { font-size: 13px; color: var(--muted); }
.dropzone.compact { grid-template-columns: auto 1fr; justify-items: start; text-align: left; padding: 18px 22px; column-gap: 16px; row-gap: 0; }
.dropzone.compact .dz-icon { grid-row: span 2; width: 46px; height: 46px; margin: 0; }
.dropzone.compact .dz-icon .i { width: 20px; height: 20px; }
.dropzone.compact .dz-title { font-size: 20px; }
.photo-toolbar { margin: 18px 0 14px; }

.admin-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(190px, 1fr)); gap: 16px; }
.aphoto { position: relative; margin: 0; border-radius: 12px; overflow: hidden; background: var(--surface); border: 1px solid var(--line); box-shadow: var(--shadow-sm); transition: box-shadow .3s, transform .3s var(--ease), opacity .3s; animation: fadeUp .4s var(--ease); }
.aphoto:hover { box-shadow: var(--shadow); transform: translateY(-2px); }
.aphoto.removing { opacity: .3; transform: scale(.96); }
.aphoto img { width: 100%; aspect-ratio: 1; object-fit: cover; background: var(--surface-2); opacity: 0; transition: opacity .5s; }
.aphoto img.loaded { opacity: 1; }
.aphoto.is-cover { outline: 2px solid var(--accent); outline-offset: -2px; }
.cover-tag { position: absolute; left: 8px; top: 8px; display: inline-flex; gap: 4px; align-items: center; background: var(--accent); color: #fff; font-size: 11px; font-weight: 600; padding: 3px 9px 3px 7px; border-radius: 999px; }
.cover-tag .i { width: 12px; height: 12px; fill: currentColor; }
.aphoto-actions { position: absolute; right: 8px; top: 8px; display: flex; gap: 6px; opacity: 0; transform: translateY(-4px); transition: .25s var(--ease); }
.aphoto:hover .aphoto-actions, .aphoto:focus-within .aphoto-actions { opacity: 1; transform: none; }
.aphoto figcaption { display: flex; align-items: center; justify-content: space-between; gap: 8px; padding: 9px 11px; font-size: 12px; min-height: 38px; }
.fname { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; color: var(--ink-2); min-width: 0; }
.pstats { display: flex; gap: 8px; color: var(--muted); flex: none; }
.pstats span { display: inline-flex; align-items: center; gap: 3px; font-weight: 500; }
.pstats .i { width: 13px; height: 13px; }
.st-heart { color: var(--heart); } .st-heart .i { fill: currentColor; }
.st-star { color: #b98a2c; } .st-star .i { fill: var(--gold); stroke: var(--gold); }

/* upload panel */
.upload-panel { position: fixed; right: 24px; bottom: 24px; z-index: 120; width: 340px; max-width: calc(100vw - 32px); background: var(--surface); border-radius: 16px; box-shadow: var(--shadow-lg); border: 1px solid var(--line); overflow: hidden; animation: fadeUp .3s var(--ease); }
.up-head { display: flex; align-items: center; justify-content: space-between; padding: 12px 12px 10px 18px; font-size: 14px; }
.progress { height: 3px; background: var(--surface-2); }
.progress-bar { height: 100%; width: 0; background: linear-gradient(90deg, var(--accent), var(--gold)); transition: width .3s; }
.upload-panel.finished .progress-bar { background: var(--success); }
.up-list { list-style: none; margin: 0; padding: 6px 0; max-height: 220px; overflow: auto; }
.up-list li { display: flex; justify-content: space-between; gap: 12px; padding: 6px 18px; font-size: 12.5px; color: var(--muted); }
.up-list li.active { color: var(--ink); }
.up-list li.ok .up-state { color: var(--success); }
.up-list li.err { color: var(--danger); }
.up-name { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.up-state { flex: none; display: inline-flex; }
.up-state .i { width: 15px; height: 15px; stroke-width: 2.4; }

/* ---------------------------------------------------------------- selections */
.selections { display: grid; grid-template-columns: 300px 1fr; gap: 28px; align-items: start; }
.client-list { display: grid; gap: 8px; position: sticky; top: 90px; }
.client-item { display: flex; gap: 12px; align-items: flex-start; width: 100%; text-align: left; padding: 14px; background: var(--surface); border: 1px solid var(--line); border-radius: 14px; transition: border-color .2s, box-shadow .2s; }
.client-item:hover { border-color: var(--line-2); }
.client-item.active { border-color: var(--ink); box-shadow: var(--shadow); }
.ci-body { display: grid; gap: 4px; min-width: 0; }
.ci-body strong { font-size: 14px; font-weight: 600; }
.ci-email { font-size: 12px; color: var(--muted); overflow: hidden; text-overflow: ellipsis; }
.ci-stats { display: inline-flex; align-items: center; gap: 4px; font-size: 12px; color: var(--muted); }
.ci-stats .i { width: 12px; height: 12px; }
.ci-body .chip { justify-self: start; margin-top: 2px; }
.ci-note { font-size: 12.5px; font-style: italic; color: var(--ink-2); background: var(--surface-2); border-radius: 8px; padding: 6px 9px; margin-top: 4px; }
.sel-toolbar { display: flex; justify-content: space-between; gap: 12px; flex-wrap: wrap; margin-bottom: 10px; }
.sel-actions { display: flex; gap: 8px; }
#selSummary { margin-bottom: 14px; min-height: 18px; }
.sel-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 16px; }
.sel-card { background: var(--surface); border: 1px solid var(--line); border-radius: 12px; overflow: hidden; box-shadow: var(--shadow-sm); animation: fadeUp .35s var(--ease); }
.sel-thumb img { width: 100%; aspect-ratio: 4 / 3; object-fit: cover; background: var(--surface-2); opacity: 0; transition: opacity .4s; }
.sel-thumb img.loaded { opacity: 1; }
.sel-info { padding: 10px 12px 12px; display: grid; gap: 8px; font-size: 12.5px; }
.sel-grade { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; padding-top: 8px; border-top: 1px solid var(--line); }
.sel-grade .who { font-weight: 600; margin-right: auto; }
.mini-stars { display: inline-flex; }
.mini-stars span { color: #d8d2c6; display: inline-flex; }
.mini-stars .i { width: 13px; height: 13px; fill: currentColor; stroke: none; }
.mini-stars span.on { color: var(--gold); }
.mini-heart { color: var(--heart); display: inline-flex; } .mini-heart .i { width: 14px; height: 14px; fill: currentColor; }
.sel-comment { width: 100%; display: flex; gap: 6px; color: var(--ink-2); background: var(--surface-2); padding: 7px 9px; border-radius: 8px; line-height: 1.4; }
.sel-comment .i { width: 13px; height: 13px; margin-top: 2px; color: var(--muted); }
.sel-empty { grid-column: 1 / -1; display: grid; justify-items: center; gap: 10px; padding: 50px 0; background: var(--surface); border-radius: 14px; border: 1px dashed var(--line-2); }
.sel-empty .i { width: 28px; height: 28px; stroke-width: 1.3; }

/* pills (shared by admin & client) */
.pills { display: flex; gap: 6px; flex-wrap: wrap; align-items: center; }
.pill { display: inline-flex; align-items: center; gap: 6px; padding: 7px 14px; border-radius: 999px; border: 1px solid var(--line-2); background: var(--surface); font-size: 13px; font-weight: 500; color: var(--ink-2); transition: .2s; white-space: nowrap; }
.pill .i { width: 14px; height: 14px; }
.pill b { font-weight: 500; color: var(--muted); font-size: 12px; }
.pill:hover { border-color: var(--ink); }
.pill.active { background: var(--ink); border-color: var(--ink); color: #fff; }
.pill.active b { color: rgba(255, 255, 255, .7); }

/* ---------------------------------------------------------------- settings */
.settings-card { background: var(--surface); border: 1px solid var(--line); border-radius: 18px; padding: 30px; box-shadow: var(--shadow-sm); max-width: 860px; }
.settings-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 20px 24px; align-items: end; }
.span-2 { grid-column: 1 / -1; }
.settings-foot { display: flex; justify-content: flex-end; margin-top: 24px; padding-top: 20px; border-top: 1px solid var(--line); }
.danger-zone { display: flex; justify-content: space-between; align-items: center; gap: 20px; margin-top: 24px; max-width: 860px; padding: 22px 30px; border: 1px solid #f2d4d4; border-radius: 18px; background: #fffafa; flex-wrap: wrap; }
.danger-zone form { margin: 0; }

.error-page { min-height: 100vh; display: grid; place-content: center; justify-items: center; gap: 14px; text-align: center; }
.error-code { font-size: 120px; line-height: 1; color: var(--accent); }

/* ==========================================================================
   CLIENT: password page
   ========================================================================== */
.access { display: grid; grid-template-columns: 1.35fr 1fr; min-height: 100vh; }
.access-cover { position: relative; background: radial-gradient(circle at 30% 20%, #4b3d2f, #1b1612 70%); color: #fff; display: flex; align-items: flex-end; padding: 56px; overflow: hidden; }
.access-cover-img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; animation: kenburns 24s ease-out both; }
@keyframes kenburns { from { transform: scale(1.12); } to { transform: scale(1); } }
.access-cover::after { content: ''; position: absolute; inset: 0; background: linear-gradient(180deg, rgba(0, 0, 0, 0) 40%, rgba(0, 0, 0, .65)); }
.access-cover-inner { position: relative; z-index: 1; }
.access-cover h1 { font-size: clamp(44px, 5.5vw, 76px); font-weight: 500; text-shadow: 0 2px 30px rgba(0, 0, 0, .25); }
.access-date { margin-top: 10px; letter-spacing: .2em; text-transform: uppercase; font-size: 12px; color: rgba(255, 255, 255, .85); }
.access-main { display: grid; place-items: center; padding: 40px 28px; }
.access-card { width: 100%; max-width: 400px; }
.access-card h2 { font-size: 40px; margin: 18px 0 8px; }
.lock-badge { width: 52px; height: 52px; border-radius: 50%; display: grid; place-items: center; background: var(--accent-soft); color: var(--accent-2); }
.lock-badge .i { width: 22px; height: 22px; }
.access-foot { margin-top: 28px; font-size: 12px; color: var(--muted); text-align: center; letter-spacing: .04em; }

/* ==========================================================================
   CLIENT: gallery
   ========================================================================== */
.client-page { background: var(--bg); }
html:not([data-tint]) .client-page { --bg: var(--sage); --soft: var(--sand); }
.preview-banner { position: fixed; top: 0; left: 0; right: 0; z-index: 90; display: flex; justify-content: center; align-items: center; gap: 10px; flex-wrap: wrap; padding: 9px 16px; background: var(--ink); color: #fff; font-size: 13px; }
.preview-banner a { color: #f0cf98; font-weight: 500; }
.preview-banner .i { width: 15px; height: 15px; }

.hero { position: relative; height: 100vh; min-height: 520px; display: grid; place-items: center; overflow: hidden; background: radial-gradient(circle at 30% 20%, #4b3d2f, #1b1612 70%); color: #fff; text-align: center; }
.hero-img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; animation: kenburns 20s ease-out both; }
.hero-shade { position: absolute; inset: 0; background: linear-gradient(180deg, rgba(0, 0, 0, .25), rgba(0, 0, 0, .15) 40%, rgba(0, 0, 0, .55)); }
.hero-content { position: relative; z-index: 1; padding: 24px; animation: heroIn 1.4s var(--ease) both .2s; }
@keyframes heroIn { from { opacity: 0; transform: translateY(18px); } }
.hero h1 { font-size: clamp(48px, 8vw, 104px); font-weight: 400; letter-spacing: .01em; line-height: 1; text-shadow: 0 2px 40px rgba(0, 0, 0, .3); }
.hero-date { margin-top: 18px; font-size: 12.5px; letter-spacing: .3em; text-transform: uppercase; color: rgba(255, 255, 255, .88); }
.btn-hero { margin-top: 36px; padding: 13px 34px; border: 1px solid rgba(255, 255, 255, .8); color: #fff; letter-spacing: .2em; text-transform: uppercase; font-size: 12px; background: rgba(255, 255, 255, .06); backdrop-filter: blur(4px); }
.btn-hero:hover { background: #fff; color: var(--ink); }
.hero-scroll { position: absolute; bottom: 26px; left: 50%; transform: translateX(-50%); color: rgba(255, 255, 255, .8); z-index: 1; animation: bob 2.2s ease-in-out infinite; }
.hero-scroll .i { width: 28px; height: 28px; stroke-width: 1.3; }
@keyframes bob { 50% { transform: translate(-50%, 6px); } }

.gnav { position: sticky; top: 0; z-index: 60; background: var(--bg); border-bottom: 1px solid transparent; transition: border-color .3s, box-shadow .3s; }
.gnav.stuck { border-bottom-color: var(--line); box-shadow: 0 6px 24px -18px rgba(0, 0, 0, .3); }
.gnav-inner { max-width: 1600px; margin: 0 auto; padding: 12px 28px; display: flex; align-items: center; gap: 20px; }
.gnav-title { display: grid; line-height: 1.2; min-width: 0; max-width: 240px; }
.gnav-title strong { font-size: 22px; font-weight: 500; overflow: hidden; white-space: nowrap; text-overflow: ellipsis; }
.gnav-title span { overflow: hidden; white-space: nowrap; text-overflow: ellipsis; font-size: 11px; letter-spacing: .16em; text-transform: uppercase; color: var(--muted); }
.gnav-right { margin-left: auto; }
.gnav-bar { max-width: 1600px; margin: 0 auto; padding: 0 28px 10px; display: flex; align-items: center; justify-content: space-between; gap: 10px 20px; flex-wrap: wrap; }
.gnav-bar .pills { flex: 1 1 auto; min-width: 0; }
.gnav-tools { display: flex; align-items: center; gap: 10px; margin-left: auto; }
.gnav-right { display: flex; align-items: center; gap: 12px; }
.star-filter { display: inline-flex; padding: 4px 8px; border-radius: 999px; border: 1px solid var(--line-2); margin-left: 4px; }
.star-filter button { border: 0; background: none; padding: 2px 1px; color: #d4cdc0; display: inline-flex; transition: color .15s, transform .15s; }
.star-filter button .i { width: 16px; height: 16px; fill: currentColor; stroke: none; }
.star-filter button:hover { transform: scale(1.15); }
.star-filter button.on { color: var(--gold); }
.star-filter.active { border-color: var(--gold); background: #fffaf0; }
.star-filter:hover button { color: #c7bfb1; }
.star-filter:hover button.on { color: var(--gold); }

.progress-ring { position: relative; width: 50px; height: 50px; display: grid; place-items: center; }
.progress-ring svg { position: absolute; inset: 0; transform: rotate(-90deg); }
.progress-ring circle { fill: none; stroke-width: 2.6; }
.ring-bg { stroke: var(--line); }
.ring-fg { stroke: var(--accent); stroke-linecap: round; transition: stroke-dashoffset .5s var(--ease); }
.progress-ring span { font-size: 10.5px; font-weight: 600; color: var(--ink-2); letter-spacing: -.02em; }
#submitBtn.sent { background: var(--success); box-shadow: 0 6px 18px -8px rgba(47, 138, 91, .8); }
.client-chip { display: flex; align-items: center; gap: 8px; }
.client-chip a { color: var(--muted); text-decoration: none; }
.client-chip a:hover { color: var(--ink); text-decoration: underline; }

.gallery-wrap { max-width: 1600px; margin: 0 auto; padding: 28px 28px 0; scroll-margin-top: 120px; }
.welcome { max-width: 720px; margin: 36px auto 40px; text-align: center; }
.welcome p { font-size: 26px; line-height: 1.45; font-style: italic; color: var(--ink-2); white-space: pre-line; }
.welcome span { display: block; margin-top: 14px; font-size: 12px; letter-spacing: .2em; text-transform: uppercase; color: var(--accent); }
.howto { position: relative; display: grid; grid-template-columns: repeat(4, 1fr); gap: 16px; margin: 0 0 26px; padding: 16px 56px 16px 22px; background: var(--bg); border-radius: 14px; font-size: 13px; color: var(--ink-2); }
.howto > div { display: flex; align-items: center; gap: 10px; }
.howto b { font-weight: 600; }
.howto-ic { width: 32px; height: 32px; border-radius: 50%; display: grid; place-items: center; background: #fff; flex: none; box-shadow: var(--shadow-sm); }
.howto-ic .i { width: 15px; height: 15px; }
.howto-ic.heart { color: var(--heart); } .howto-ic.heart .i { fill: currentColor; }
.howto-ic.star { color: var(--gold); } .howto-ic.star .i { fill: currentColor; }
.howto > .icon-btn { position: absolute; right: 10px; top: 50%; transform: translateY(-50%); }

/* justified grid */
.jgrid { width: 100%; }
.jrow { display: flex; gap: 10px; margin-bottom: 10px; }
.tile { position: relative; margin: 0; flex: none; overflow: hidden; background: var(--surface-2); cursor: zoom-in; border-radius: 3px; container-type: inline-size; }
@container (max-width: 175px) { .tile-overlay .stars { display: none; } .tile-overlay { justify-content: flex-end; } }
.tile img { width: 100%; height: 100%; object-fit: cover; opacity: 0; transform: scale(1.02); transition: opacity .6s var(--ease), transform .8s var(--ease); }
.tile img.loaded { opacity: 1; transform: scale(1); }
.tile:hover img { transform: scale(1.025); }
.tile::after { content: ''; position: absolute; inset: 0; background: linear-gradient(180deg, transparent 55%, rgba(0, 0, 0, .55)); opacity: 0; transition: opacity .3s; pointer-events: none; }
.tile:hover::after { opacity: 1; }
.tile-badges { position: absolute; top: 10px; right: 10px; display: flex; gap: 6px; z-index: 2; pointer-events: none; }
.badge { width: 28px; height: 28px; border-radius: 50%; display: grid; place-items: center; background: rgba(255, 255, 255, .94); color: var(--ink-2); box-shadow: 0 2px 8px rgba(0, 0, 0, .15); }
.badge .i { width: 14px; height: 14px; }
.badge-heart { color: var(--heart); animation: pop .35s var(--ease); }
.badge-heart .i { fill: currentColor; }
.tile-rating { position: absolute; left: 10px; top: 12px; display: flex; gap: 3px; z-index: 2; transition: opacity .2s; }
.tile-rating i { width: 7px; height: 7px; border-radius: 50%; background: var(--gold); box-shadow: 0 0 0 1.5px rgba(255, 255, 255, .9); }
.tile:hover .tile-rating { opacity: 0; }
.tile-overlay { position: absolute; left: 0; right: 0; bottom: 0; z-index: 2; display: flex; align-items: center; justify-content: space-between; padding: 10px 10px 10px 12px; opacity: 0; transform: translateY(8px); transition: opacity .25s var(--ease), transform .3s var(--ease); }
.tile:hover .tile-overlay, .tile:focus-within .tile-overlay { opacity: 1; transform: none; }
.stars { display: inline-flex; gap: 1px; }
.star { border: 0; background: none; padding: 3px; display: inline-flex; color: rgba(255, 255, 255, .85); transition: transform .15s var(--ease), color .15s; }
.star .i { width: 19px; height: 19px; filter: drop-shadow(0 1px 2px rgba(0, 0, 0, .35)); }
.star.on { color: var(--gold); }
.star.on .i { fill: currentColor; }
.stars:hover .star { color: var(--gold); }
.stars:hover .star .i { fill: currentColor; }
.stars .star:hover ~ .star { color: rgba(255, 255, 255, .85); }
.stars .star:hover ~ .star .i { fill: none; }
.star:hover { transform: scale(1.2); }
.tile-heart { border: 0; background: rgba(255, 255, 255, .16); backdrop-filter: blur(6px); width: 36px; height: 36px; border-radius: 50%; display: grid; place-items: center; color: #fff; transition: transform .2s var(--ease), background .2s; }
.tile-heart:hover { transform: scale(1.12); background: rgba(255, 255, 255, .3); }
.tile-heart .i { width: 19px; height: 19px; }
.tile-heart.on { color: var(--heart); background: #fff; }
.tile-heart.on .i { fill: currentColor; }
.heart-pop { position: absolute; inset: 0; display: grid; place-items: center; color: #fff; pointer-events: none; z-index: 3; animation: heartPop .8s var(--ease) forwards; }
.heart-pop .i { width: 84px; height: 84px; fill: currentColor; stroke: none; filter: drop-shadow(0 6px 20px rgba(0, 0, 0, .35)); }
@keyframes heartPop { 0% { opacity: 0; transform: scale(.4); } 30% { opacity: 1; transform: scale(1.1); } 60% { transform: scale(1); opacity: 1; } 100% { opacity: 0; transform: scale(1.05); } }
@keyframes pop { 0% { transform: scale(.4); } 70% { transform: scale(1.15); } }

.grid-empty { display: grid; justify-items: center; gap: 12px; padding: 90px 20px; color: var(--muted); text-align: center; }
.grid-empty .i { width: 40px; height: 40px; stroke-width: 1.2; }
.gfoot { display: grid; justify-items: center; gap: 4px; padding: 70px 0 60px; }
.gfoot .serif { font-size: 26px; }

/* ---------------------------------------------------------------- lightbox */
.lb { position: fixed; inset: 0; z-index: 300; background: #0d0c0b; color: #fff; display: grid; grid-template-rows: auto 1fr auto; opacity: 0; transition: opacity .25s; }
.lb.open { opacity: 1; }
.lb-top { display: flex; align-items: center; gap: 16px; padding: 14px 18px 14px 26px; font-size: 13px; color: rgba(255, 255, 255, .7); z-index: 2; }
.lb-count { font-variant-numeric: tabular-nums; letter-spacing: .06em; }
.lb-name { flex: 1; text-align: center; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.lb-top-actions { display: flex; gap: 4px; }
.lb-btn { position: relative; width: 42px; height: 42px; border-radius: 50%; display: grid; place-items: center; background: transparent; border: 0; color: rgba(255, 255, 255, .85); transition: background .2s, color .2s; text-decoration: none; }
.lb-btn:hover { background: rgba(255, 255, 255, .1); color: #fff; }
.lb-btn .i { width: 21px; height: 21px; }
.lb-stage { position: relative; display: grid; place-items: center; min-height: 0; overflow: hidden; }
.lb-stage img { position: absolute; inset: 4px 84px; margin: auto; max-width: calc(100% - 168px); max-height: calc(100% - 8px); object-fit: contain; opacity: 0; transform: scale(.985); transition: opacity .35s var(--ease), transform .45s var(--ease); box-shadow: 0 30px 80px -30px rgba(0, 0, 0, .8); user-select: none; -webkit-user-drag: none; }
.lb-stage img.shown { opacity: 1; transform: none; }
.lb-spinner { position: absolute; width: 34px; height: 34px; border-radius: 50%; border: 2px solid rgba(255, 255, 255, .15); border-top-color: rgba(255, 255, 255, .8); animation: spin .8s linear infinite; opacity: 0; transition: opacity .2s .15s; }
.lb.loading .lb-spinner { opacity: 1; }
@keyframes spin { to { transform: rotate(360deg); } }
.lb-nav { position: absolute; top: 50%; transform: translateY(-50%); z-index: 2; width: 56px; height: 56px; border-radius: 50%; display: grid; place-items: center; background: rgba(255, 255, 255, .06); border: 0; color: #fff; transition: background .2s, opacity .2s; }
.lb-nav:hover { background: rgba(255, 255, 255, .16); }
.lb-nav:disabled { opacity: 0; pointer-events: none; }
.lb-nav .i { width: 26px; height: 26px; stroke-width: 1.5; }
.lb-prev { left: 16px; } .lb-next { right: 16px; }
.lb-bottom { display: grid; justify-items: center; gap: 8px; padding: 10px 20px 18px; }
.lb-grade { display: flex; align-items: center; gap: 10px; padding: 6px 8px 6px 14px; border-radius: 999px; background: rgba(255, 255, 255, .08); }
.stars-lg .star .i { width: 26px; height: 26px; filter: none; }
.stars-lg .star { color: rgba(255, 255, 255, .45); padding: 4px; }
.stars-lg .star.on, .stars-lg:hover .star { color: var(--gold); }
.stars-lg .star:hover ~ .star { color: rgba(255, 255, 255, .45); }
.lb.open ~ .toast { bottom: auto; top: 18px; transform: translate(-50%, -24px); background: rgba(255, 255, 255, .96); color: var(--ink); }
.lb.open ~ .toast.show { transform: translate(-50%, 0); }
.lb.open ~ .toast .i { color: var(--success); }
.lb-sep { width: 1px; height: 26px; background: rgba(255, 255, 255, .18); }
.lb-heart { width: 46px; height: 46px; border-radius: 50%; border: 0; background: transparent; display: grid; place-items: center; color: rgba(255, 255, 255, .85); transition: transform .2s var(--ease), color .2s; }
.lb-heart:hover { transform: scale(1.12); color: #fff; }
.lb-heart .i { width: 26px; height: 26px; }
.lb-heart.on { color: var(--heart); }
.lb-heart.on .i { fill: currentColor; animation: pop .35s var(--ease); }
.lb-comment-btn .dot { position: absolute; top: 9px; right: 9px; width: 8px; height: 8px; border-radius: 50%; background: var(--gold); display: none; }
.lb-comment-btn.has .dot { display: block; }
.lb-hint { font-size: 11.5px; color: rgba(255, 255, 255, .42); }
.lb-hint kbd { font: inherit; font-size: 10.5px; padding: 1px 6px; border-radius: 4px; border: 1px solid rgba(255, 255, 255, .2); margin: 0 1px; }
.lb-comment { display: flex; gap: 10px; align-items: flex-end; width: min(620px, 100%); }
.lb-comment textarea { background: rgba(255, 255, 255, .08) !important; border-color: rgba(255, 255, 255, .15) !important; color: #fff !important; font-size: 14px; }
.lb-comment textarea::placeholder { color: rgba(255, 255, 255, .4); }
.lb-comment { position: relative; }
.lb-comment-status { position: absolute; right: 10px; bottom: 8px; font-size: 11.5px; color: rgba(255, 255, 255, .5); pointer-events: none; transition: opacity .3s; }
.lb-comment-status.ok { color: #a9c4b1; }
.lb-comment-status.ok::before { content: '✓ '; }
.lb-comment-status.err { color: #f0a59b; }
.lb-comment-status:empty { opacity: 0; }
.lb-comment textarea { padding-right: 110px; }

.summary { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; margin: 22px 0; }
.summary div { display: grid; justify-items: center; gap: 2px; padding: 16px 8px; border-radius: 14px; background: var(--bg); }
.summary b { font-family: var(--serif); font-size: 36px; font-weight: 500; line-height: 1; }
.summary span { display: inline-flex; align-items: center; gap: 5px; font-size: 12.5px; color: var(--muted); }
.summary .i { width: 13px; height: 13px; }

/* ==========================================================================
   BRAND LAYER — Moniek Aansorgh: sage & sand, square corners, Recline + Montserrat
   ========================================================================== */
body { color: var(--ink-2); }
h1, h2, h3, .serif { font-weight: 400; letter-spacing: 0; color: var(--ink); }
.eyebrow { color: var(--green); font-weight: 500; letter-spacing: .2em; }

/* square, outlined buttons like the website */
.btn { border-radius: 0; font-weight: 400; letter-spacing: .03em; }
.btn-primary { background: var(--green-dark); color: var(--sand-light); box-shadow: none; }
.btn-primary:hover { background: #1f3a2e; box-shadow: none; }
.btn-accent { background: var(--green); color: #fff; box-shadow: none; }
.btn-accent:hover { background: var(--green-dark); }
.btn-ghost { background: transparent; border: 1px solid var(--green); color: var(--green-dark); }
.btn-ghost:hover { background: var(--green-dark); border-color: var(--green-dark); color: var(--sand-light); }
.btn-danger { border-radius: 0; }
.pill { border-radius: 0; font-weight: 400; border-color: var(--line-2); }
.pill:hover { border-color: var(--green); }
.pill.active { background: var(--green-dark); border-color: var(--green-dark); color: var(--sand-light); }
.star-filter { border-radius: 0; }
.chip { border-radius: 0; }
.chip-success { background: var(--sage-light); color: var(--green-dark); }
input:not([type=checkbox]):not([type=file]), textarea, select { border-radius: 0; font-weight: 400; }
input:focus, textarea:focus, select:focus { border-color: var(--green); box-shadow: 0 0 0 3px rgba(99, 124, 109, .18); }
.input-group .icon-btn { border-radius: 0; }
.toggle-field input:checked + .toggle { background: var(--green); }
.toast { background: var(--green-dark); color: var(--sand-light); border-radius: 0; }

/* header: sage band with the logo, uppercase nav */
.topbar { background: var(--sage); border-bottom: 0; backdrop-filter: none; }
.topbar-inner { padding: 12px 28px; }
.brand-logo { height: 58px; width: auto; }
.topnav a { text-transform: uppercase; letter-spacing: .06em; font-size: 13px; color: var(--green-dark); border-radius: 0; padding: 8px 12px; }
.topnav a:hover { color: #000; }
.topnav a.active { background: transparent; box-shadow: none; border-bottom: 1px solid var(--green-dark); }
.topbar-user .icon-btn { color: var(--green-dark); }
.topbar-user .icon-btn:hover { background: rgba(255, 255, 255, .35); }
.user-meta strong { color: var(--green-dark); }
.user-meta span { color: var(--green-dark); opacity: .75; }
.avatar { background: var(--green); color: var(--sand-light); font-weight: 500; }
.avatar.all { background: var(--green-dark); }

/* cards and panels: flat, square */
.gcard, .empty-state, .modal-card, .dropzone, .aphoto, .settings-card, .danger-zone, .client-item, .sel-card,
.upload-panel, .howto, .summary div, .sel-empty, .ci-note, .sel-comment, .cover-tag { border-radius: var(--radius); }
.gcard { box-shadow: none; }
.gcard:hover { box-shadow: var(--shadow); }
.gcard-body h3 { font-size: 26px; }
.gcard-new:hover { background: var(--sage-light); border-color: var(--green); color: var(--green-dark); }
.gcard-new .plus { border-radius: 0; }
.empty-state { box-shadow: none; }
.empty-illustration span { border-radius: 0; }
.empty-illustration span:nth-child(1) { background: var(--sage); }
.empty-illustration span:nth-child(2) { background: var(--green); }
.empty-illustration span:nth-child(3) { background: var(--sand); }
.dropzone { border-color: var(--sage); background: #fff; }
.dropzone:hover, .dropzone.drag { background: var(--sage-light); border-color: var(--green); }
.dz-icon, .empty-icon { background: var(--sage-light); color: var(--green-dark); }
.dz-title { font-size: 28px; color: var(--ink); }
.aphoto.is-cover { outline-color: var(--green); }
.cover-tag { background: var(--green-dark); }
.tab.active { border-bottom-color: var(--green-dark); color: var(--green-dark); }
.client-item.active { border-color: var(--green-dark); }
.progress-bar { background: var(--green); }
.danger-zone { border-color: #ead1cc; background: #fff; }
.modal-backdrop { background: rgba(43, 77, 62, .45); }
.modal-card h2 { font-size: 36px; }

/* login */
.auth-art { background: var(--sage); color: var(--green-dark); align-items: center; }
.auth-art::after { display: none; }
.auth-art .leaf { position: absolute; left: -40px; bottom: -110px; width: 105%; fill: var(--green-dark); opacity: .9; pointer-events: none; }
.auth-logo { position: absolute; top: 56px; left: 50%; transform: translateX(-50%); z-index: 1; width: 220px; height: auto; }
.auth-art-copy { margin-bottom: 140px; }
.auth-art-copy h2 { color: var(--green-dark); font-size: clamp(36px, 3.6vw, 50px); }
.auth-art-copy p { color: var(--green-dark); opacity: .85; font-weight: 300; }
.auth-card h1 { font-size: 46px; }
.auth-switch a { color: var(--green-dark); }

/* client password page */
.access-cover { background: var(--green-dark); }
.access-cover h1, .hero h1 { font-weight: 400; color: #fff; }
.access-logo { width: 150px; height: auto; margin-bottom: 8px; }
.access-card h2 { font-size: 38px; }
.access-foot a { color: var(--green); text-decoration: none; }

/* client gallery */
.hero { background: var(--green-dark); }
.hero-shade { background: linear-gradient(180deg, rgba(20, 35, 28, .35), rgba(20, 35, 28, .15) 40%, rgba(20, 35, 28, .6)); }
.hero-logo { width: 170px; height: auto; margin: 0 auto 26px; opacity: .95; }
.btn-hero { border-radius: 0; letter-spacing: .18em; }
.gnav-brand { display: flex; align-items: center; gap: 14px; min-width: 0; text-decoration: none; }
.gnav-brand img { height: 38px; width: auto; flex: none; }
.gnav-title { display: block; font-size: 22px; color: var(--ink); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; max-width: 260px; padding-left: 14px; border-left: 1px solid var(--line-2); }
.ring-fg { stroke: var(--green); }
#submitBtn.sent { background: var(--green-dark); box-shadow: none; }
.welcome p { font-style: normal; font-size: 28px; color: var(--ink); }
.welcome span { color: var(--green); }
.howto { background: var(--soft); }
.howto-ic { border-radius: 50%; }
.tile { border-radius: 0; }
.gfoot-logo { width: 130px; height: auto; margin-bottom: 8px; }
.gfoot a { text-decoration: none; letter-spacing: .06em; }
.lb { background: #121915; }
.summary b { color: var(--ink); }
.error-logo { width: 150px; height: auto; margin-bottom: 10px; }
.error-code { color: var(--green); }

/* admins & invites */
.container.narrow { max-width: 900px; }
.panel { background: var(--surface); border: 1px solid var(--line); padding: 8px 24px 12px; margin-bottom: 22px; }
.panel-title { font-family: var(--sans); font-size: 13px; font-weight: 500; letter-spacing: .12em; text-transform: uppercase; color: var(--green); padding: 16px 0 6px; display: flex; align-items: center; gap: 8px; }
.admin-list { list-style: none; margin: 0; padding: 0; }
.admin-list li { display: flex; align-items: center; gap: 14px; padding: 14px 0; border-top: 1px solid var(--line); }
.admin-list li:first-child { border-top: 0; }
.admin-list form { margin: 0; }
.al-body { display: grid; flex: 1; min-width: 0; }
.al-body strong { font-weight: 500; color: var(--ink); }
.al-body em { font-style: normal; font-weight: 400; }
.invite-box { background: var(--sage-light); border: 1px solid var(--sage); padding: 22px 24px; margin-bottom: 22px; animation: fadeUp .35s var(--ease); }
.invite-box h2 { font-size: 28px; margin-bottom: 4px; }
.invite-box .copy-row { margin-top: 14px; }
.invite-box .copy-row input { background: #fff !important; }
.invite-note { display: flex; gap: 10px; align-items: flex-start; margin-top: 10px; padding: 12px 14px; background: var(--sage-light); color: var(--green-dark); font-size: 14px; }
.invite-note .i { margin-top: 2px; }
.invite-form { display: flex; gap: 8px; align-items: stretch; flex-wrap: wrap; margin: 0; }
.invite-form input { width: 240px !important; }
.mail-status { display: flex; align-items: center; justify-content: space-between; gap: 16px; flex-wrap: wrap; padding: 6px 0 14px; }
.mail-status p { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; max-width: 600px; }
.mail-status form { margin: 0; }
.mail-status code { font-size: 12px; background: var(--surface-2); padding: 1px 5px; }
.share-mail { display: grid; gap: 16px; margin-top: 20px; padding-top: 20px; border-top: 1px solid var(--line); }
.share-mail-off { margin-top: 16px; }

/* ---------------------------------------------------------------- view controls: rows/columns + number of columns */
.photo-toolbar { display: flex; align-items: center; justify-content: space-between; gap: 16px; flex-wrap: wrap; }
.view-ctl { display: inline-flex; align-items: center; gap: 8px; }
.seg-ctl { display: inline-flex; border: 1px solid var(--line-2); }
.seg-ctl button { border: 0; background: none; min-width: 32px; height: 32px; padding: 0 8px; display: inline-grid; place-items: center; color: var(--muted); font-size: 13px; font-weight: 500; transition: color .2s, background .2s; }
.seg-ctl button + button { border-left: 1px solid var(--line-2); }
.seg-ctl button:hover { color: var(--ink); }
.seg-ctl button.on { background: var(--green-dark); color: var(--sand-light); }
.seg-ctl .i { width: 17px; height: 17px; }
[data-theme="dark"] .seg-ctl button.on { background: var(--accent); color: #12201a; }
.jcols { display: flex; gap: 10px; align-items: flex-start; }
.jcol { display: flex; flex-direction: column; gap: 10px; flex: none; }
.admin-grid { grid-template-columns: repeat(var(--cols, 4), minmax(0, 1fr)); }
.admin-grid[data-layout="columns"] { display: block; columns: var(--cols, 4); column-gap: 16px; }
.admin-grid[data-layout="columns"] .aphoto { break-inside: avoid; margin-bottom: 16px; animation: none; }
.admin-grid[data-layout="columns"] .aphoto img { aspect-ratio: auto; height: auto; }
/* photo protection: no long-press "save image" on phones, no selecting or dragging */
.protect img { -webkit-touch-callout: none; -webkit-user-select: none; user-select: none; -webkit-user-drag: none; }
.protect .lb-stage { -webkit-touch-callout: none; }

/* ---------------------------------------------------------------- theme toggle */
.theme-toggle .i-sun { display: none; }
[data-theme="dark"] .theme-toggle .i-sun { display: block; }
[data-theme="dark"] .theme-toggle .i-moon { display: none; }
.theme-ctl { display: inline-flex; align-items: center; gap: 6px; }
.theme-float { position: fixed; top: 16px; right: 16px; z-index: 80; padding: 2px 2px 2px 10px; background: var(--surface); border: 1px solid var(--line); box-shadow: var(--shadow-sm); border-radius: 999px; }
.tint-ctl { display: inline-flex; gap: 6px; }
.tint-swatch { width: 18px; height: 18px; padding: 0; border-radius: 50%; border: 1px solid rgba(43, 77, 62, .35); cursor: pointer; transition: transform .15s, box-shadow .15s; }
.tint-swatch:hover { transform: scale(1.12); }
.tint-swatch.on { box-shadow: 0 0 0 2px var(--surface), 0 0 0 3.5px var(--green-dark); }
.tint-sage { background: #bbc2b9; }
.tint-sand { background: #e3dcd2; }
[data-theme="dark"] .tint-ctl { display: none; }
[data-theme="dark"] .theme-float { padding-left: 2px; }

/* background colour choice (light theme): sage green or sand */
[data-tint="sage"] { --bg: var(--sage); --soft: var(--sand); }
[data-tint="sand"] { --bg: var(--sand); --soft: var(--sage); }
[data-tint="sage"] .topbar-user .tint-swatch.on, [data-tint="sand"] .topbar-user .tint-swatch.on { box-shadow: 0 0 0 2px var(--sage), 0 0 0 3.5px var(--green-dark); }
.gnav-tools .theme-toggle, .gnav-tools .fs-btn { color: var(--ink-2); }
.fs-btn .i-min, .is-fullscreen .fs-btn .i-max { display: none; }
.aphoto img { cursor: zoom-in; }
.lb-stats { display: flex; gap: 18px; font-size: 13px; color: rgba(255, 255, 255, .75); min-height: 20px; }
.lb-stats span { display: inline-flex; align-items: center; gap: 6px; }
.lb-stats .i { width: 15px; height: 15px; }
.lb-stats .st-heart { color: #e8958a; }
#lbCover.on { color: var(--gold); }
#lbCover.on .i { fill: currentColor; }
.is-fullscreen .fs-btn .i-min { display: block; }

/* ==========================================================================
   DARK THEME — deep green-black with sage accents
   ========================================================================== */
[data-theme="dark"] {
  color-scheme: dark;
  --bg: #141a17;
  --surface: #1c2420;
  --surface-2: #252f2a;
  --ink: #e9ede6;
  --ink-2: #c3cbc2;
  --muted: #8d978f;
  --line: #2b3530;
  --line-2: #3c4842;
  --accent: #93ad9c;
  --accent-2: #b9cbbd;
  --accent-soft: #233029;
  --sage-light: #233029;
  --success: #93ad9c;
  --success-soft: #233029;
  --heart: #e07f72;
  --danger: #e07a6e;
  --shadow-sm: 0 1px 2px rgba(0, 0, 0, .3);
  --shadow: 0 1px 2px rgba(0, 0, 0, .3), 0 12px 30px -16px rgba(0, 0, 0, .6);
}
[data-theme="dark"] .eyebrow, [data-theme="dark"] .panel-title, [data-theme="dark"] .welcome span,
[data-theme="dark"] .error-code, [data-theme="dark"] .access-foot a { color: var(--accent); }
[data-theme="dark"] .btn-primary, [data-theme="dark"] .pill.active { background: var(--accent); border-color: var(--accent); color: #12201a; }
[data-theme="dark"] .btn-primary:hover { background: var(--accent-2); }
[data-theme="dark"] .pill.active b { color: rgba(18, 32, 26, .65); }
[data-theme="dark"] .pill:hover { border-color: var(--accent); }
[data-theme="dark"] .btn-ghost { border-color: var(--line-2); color: var(--ink); }
[data-theme="dark"] .btn-ghost:hover { background: var(--surface-2); border-color: var(--accent); color: var(--ink); }
[data-theme="dark"] .btn-danger { background: transparent; border-color: #5a302b; }
[data-theme="dark"] .btn-hero:hover { color: #2b4d3e; }
[data-theme="dark"] input:not([type=checkbox]):not([type=file]):not([type=range]), [data-theme="dark"] textarea, [data-theme="dark"] select { background: #121815; }
[data-theme="dark"] input::placeholder, [data-theme="dark"] textarea::placeholder { color: #66726a; }
[data-theme="dark"] .invite-box .copy-row input { background: #121815 !important; }

/* header */
[data-theme="dark"] .topbar { background: var(--surface); border-bottom: 1px solid var(--line); }
[data-theme="dark"] .topnav a { color: var(--ink-2); }
[data-theme="dark"] .topnav a:hover { color: #fff; }
[data-theme="dark"] .topnav a.active { border-bottom-color: var(--accent); color: var(--ink); }
[data-theme="dark"] .user-meta strong, [data-theme="dark"] .user-meta span { color: var(--ink); }
[data-theme="dark"] .topbar-user .icon-btn { color: var(--ink-2); }
[data-theme="dark"] .topbar-user .icon-btn:hover { background: var(--surface-2); color: var(--ink); }
[data-theme="dark"] .preview-banner { background: #2b4d3e; }

/* dark-green logo → light on dark backgrounds */
[data-theme="dark"] .brand-logo, [data-theme="dark"] .auth-logo, [data-theme="dark"] .access-logo,
[data-theme="dark"] .gnav-brand img, [data-theme="dark"] .gfoot-logo, [data-theme="dark"] .error-logo { filter: brightness(0) invert(.9); }

/* surfaces */
[data-theme="dark"] .gcard-empty { background: repeating-linear-gradient(45deg, var(--surface-2), var(--surface-2) 12px, #212a25 12px, #212a25 24px); }
[data-theme="dark"] .dropzone { background: var(--surface); border-color: var(--line-2); }
[data-theme="dark"] .dropzone:hover, [data-theme="dark"] .dropzone.drag { background: var(--accent-soft); border-color: var(--accent); }
[data-theme="dark"] .dropzone:hover .dz-icon, [data-theme="dark"] .dropzone.drag .dz-icon { background: var(--surface-2); }
[data-theme="dark"] .dz-icon, [data-theme="dark"] .empty-icon, [data-theme="dark"] .lock-badge { background: var(--accent-soft); color: var(--accent-2); }
[data-theme="dark"] .gcard-new:hover { background: var(--accent-soft); border-color: var(--accent); color: var(--ink); }
[data-theme="dark"] .empty-illustration span { border-color: var(--surface-2); }
[data-theme="dark"] .tab.active { border-bottom-color: var(--accent); color: var(--ink); }
[data-theme="dark"] .client-item.active { border-color: var(--accent); }
[data-theme="dark"] .chip-success { background: var(--accent-soft); color: var(--accent-2); }
[data-theme="dark"] .danger-zone { background: #211a18; border-color: #4a2e29; }
[data-theme="dark"] .modal-backdrop { background: rgba(0, 0, 0, .6); }
[data-theme="dark"] .invite-box { background: var(--accent-soft); border-color: var(--line-2); }
[data-theme="dark"] .invite-note { background: var(--accent-soft); color: var(--ink); }
[data-theme="dark"] .mini-stars span { color: #3c4842; }
[data-theme="dark"] .icon-btn.glass, [data-theme="dark"] .badge { color: #4b4f58; }
[data-theme="dark"] .icon-btn.glass:hover { color: #2b4d3e; }
[data-theme="dark"] .lb.open ~ .toast { color: #2b4d3e; }

/* login & password page */
[data-theme="dark"] .auth-art { background: #1d2a24; }
[data-theme="dark"] .auth-art .leaf { fill: #2b4d3e; }
[data-theme="dark"] .auth-art-copy h2, [data-theme="dark"] .auth-art-copy p { color: var(--ink); }
[data-theme="dark"] .auth-switch a { color: var(--accent-2); }

/* client gallery */
[data-theme="dark"] .client-page { background: var(--bg); }
[data-theme="dark"] .gnav { background: rgba(20, 26, 23, .92); }
[data-theme="dark"] .gnav-title, [data-theme="dark"] .welcome p { color: var(--ink); }
[data-theme="dark"] .howto { background: var(--accent-soft); }
[data-theme="dark"] .howto-ic { background: var(--surface); }
[data-theme="dark"] .star-filter button { color: #4a554e; }
[data-theme="dark"] .star-filter:hover button { color: #5d6962; }
[data-theme="dark"] .star-filter button.on, [data-theme="dark"] .star-filter:hover button.on { color: var(--gold); }
[data-theme="dark"] .star-filter.active { background: rgba(201, 162, 79, .1); }

/* ---------------------------------------------------------------- gallery menu: big logo over two lines, album name centred */
.gnav-inner { position: relative; display: grid; grid-template-columns: auto minmax(0, 1fr) auto; grid-template-areas: "logo title right" "logo bar bar"; align-items: center; gap: 6px 28px; padding: 10px 28px; }
.gnav-brand { grid-area: logo; align-self: center; }
.gnav-brand img { height: 92px; width: auto; }
.gnav-title { grid-area: title; position: absolute; left: 50%; top: 10px; height: 52px; transform: translateX(-50%); display: flex; align-items: center; justify-content: center;
  max-width: min(40vw, 640px); margin: 0; padding: 0; border: 0; font-size: 30px; font-weight: 400; color: var(--ink); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.gnav-right { grid-area: right; min-height: 52px; margin-left: 0; justify-content: flex-end; }
.gnav-bar { grid-area: bar; max-width: none; margin: 0; padding: 0; }
.preview-banner ~ .gnav { top: 37px; }

/* ---------------------------------------------------------------- touch devices: always show grading controls */
@media (hover: none) {
  .tile-overlay { opacity: 1; transform: none; padding: 6px; }
  .tile::after { opacity: .9; background: linear-gradient(180deg, transparent 62%, rgba(0, 0, 0, .55)); }
  .badge-heart { display: none; }
  .star .i { width: 16px; height: 16px; }
  .star { padding: 2px; }
  .tile-heart { width: 30px; height: 30px; }
  .tile-heart .i { width: 16px; height: 16px; }
  .aphoto-actions { opacity: 1; transform: none; }
}

/* ---------------------------------------------------------------- responsive */
@media (max-width: 1100px) {
  .howto { grid-template-columns: 1fr 1fr; }
  .gnav-title { position: static; transform: none; height: auto; justify-content: flex-start; max-width: none; font-size: 24px; }
  .gnav-brand img { height: 76px; }
}
@media (max-width: 900px) {
  .auth, .access { grid-template-columns: 1fr; }
  .auth-art { min-height: 300px; padding: 150px 32px 32px; }
  .auth-art-copy { margin-bottom: 60px; }
  .auth-logo { top: 32px; width: 160px; }
  .auth-art-copy h2 { font-size: 34px; margin-top: 18px; }
  .brand-logo { height: 38px; }
  .access-cover { min-height: 46vh; padding: 32px; }
  .selections { grid-template-columns: 1fr; }
  .client-list { position: static; grid-auto-flow: column; grid-auto-columns: minmax(240px, 1fr); overflow-x: auto; padding-bottom: 4px; }
  .settings-grid { grid-template-columns: 1fr; }
  .user-meta { display: none; }
}
@media (max-width: 640px) {
  .container { padding: 24px 16px 60px; }
  .topbar-inner { padding: 10px 16px; gap: 14px; }
  .topnav { display: none; }
  .topbar-user { margin-left: auto; }
  .page-head { align-items: flex-start; }
  .page-head > .btn, .head-actions { width: 100%; }
  .head-actions .btn { flex: 1; }
  .admin-grid { gap: 8px; }
  .admin-grid[data-layout="columns"] { column-gap: 8px; }
  .admin-grid[data-layout="columns"] .aphoto { margin-bottom: 8px; }

  .theme-float { top: 10px; right: 10px; }
  .modal-card { padding: 26px 20px; }
  .gnav-inner { padding: 8px 16px; gap: 8px 12px; grid-template-areas: "logo title right" "bar bar bar"; }
  .gnav-bar { padding: 0; }
  .gnav-bar .pills { flex-basis: 100%; overflow-x: auto; flex-wrap: nowrap; padding-bottom: 2px; scrollbar-width: none; }
  .gnav-title { display: none; }
  .gnav-brand img { height: 46px; }
  .gnav-right { min-height: 0; }
  #submitBtn span { display: none; }
  #submitBtn { padding: 10px 12px; }
  .client-chip a { display: none; }
  .gallery-wrap { padding: 16px 6px 0; }
  .jrow { gap: 4px; margin-bottom: 4px; }
  .jcols, .jcol { gap: 4px; }
  .cols-ctl { display: none; }

  .howto { grid-template-columns: 1fr; margin: 0 10px 16px; padding-right: 48px; }
  .welcome { padding: 0 16px; }
  .welcome p { font-size: 21px; }
  .lb-stage img { inset: 4px 0; max-width: 100%; }
  .lb-nav { display: none; }
  .lb-hint { display: none; }
  .lb-top { padding-left: 16px; }
  .danger-zone, .settings-card { padding: 20px; }
}
