:root {
  --ink: #493746;
  --ink-soft: #695d67;
  --muted: #7d7279;
  --paper: #fffdfa;
  --cream: #faf7f2;
  --rose: #b66f83;
  --rose-dark: #98586c;
  --rose-pale: #f0dadd;
  --sage: #aeb49e;
  --lavender: #d8cedd;
  --line: #e4ddd8;
  --shadow: 0 12px 34px rgba(69, 49, 60, .08);
  --serif: Georgia, "Times New Roman", serif;
  --sans: Inter, ui-sans-serif, system-ui, -apple-system, "Segoe UI", sans-serif;
}
* { box-sizing: border-box; }
html { min-width: 320px; background: var(--cream); color: var(--ink); font-family: var(--sans); }
body { margin: 0; min-height: 100vh; background: var(--cream); }
a { color: inherit; }
img { max-width: 100%; }
button, input, select, textarea { font: inherit; }
:focus-visible { outline: 3px solid var(--rose-dark); outline-offset: 3px; }
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0, 0, 0, 0); white-space: nowrap; border: 0; }
.eyebrow { margin: 0 0 9px; color: var(--rose-dark); font-size: .69rem; font-weight: 750; letter-spacing: .31em; text-transform: uppercase; }
.primary-button, .secondary-button { display: inline-flex; align-items: center; justify-content: center; gap: 9px; min-height: 46px; padding: 11px 18px; border: 1px solid transparent; border-radius: 7px; text-decoration: none; font-weight: 700; cursor: pointer; }
.primary-button { background: linear-gradient(135deg, #bd798d, #aa657a); color: #fff; box-shadow: 0 10px 24px rgba(167, 93, 116, .22); }
.primary-button:hover { background: linear-gradient(135deg, #aa657a, #95546a); }
.secondary-button { border-color: var(--line); background: var(--paper); color: var(--ink); }

/* Vstopna stran */
.welcome-page { overflow: hidden; background: #f9f5ef; }
.welcome { --pointer-x: 0px; --pointer-y: 0px; position: relative; display: grid; min-height: 100svh; place-items: center; isolation: isolate; padding: 42px 24px; background: url('/assets/welcome-still-life.png') center / cover no-repeat; }
.welcome::before { content: ""; position: absolute; z-index: -1; inset: 0; background: radial-gradient(ellipse at center, rgba(255, 253, 248, .18), transparent 62%); transform: translate(var(--pointer-x), var(--pointer-y)) scale(1.025); transition: transform .7s ease-out; pointer-events: none; }
.welcome-content { width: min(680px, 56vw); margin-top: -1vh; text-align: center; animation: welcome-in 1s both cubic-bezier(.2, .8, .2, 1); }
.welcome-logo { display: block; width: 66px; height: 66px; margin: 0 auto 6px; object-fit: contain; }
.welcome-kicker { margin: 0 0 24px; color: var(--ink); font-size: clamp(.68rem, 1.15vw, .92rem); font-weight: 700; letter-spacing: .32em; text-transform: uppercase; }
.welcome h1 { margin: 0 0 20px; color: #4d3947; font: 400 clamp(5.1rem, 8.5vw, 8.7rem)/.78 var(--serif); letter-spacing: -.065em; }
.welcome h1 span { display: block; }
.welcome-lead { margin: 0 auto 30px; color: #6b5a65; font: 400 clamp(1rem, 1.55vw, 1.35rem)/1.45 var(--serif); }
.welcome-action { min-width: min(100%, 380px); min-height: 58px; padding-inline: 30px; border-radius: 999px; font-size: 1.03rem; }
.microsoft-mark { display: grid; grid-template-columns: repeat(2, 10px); gap: 2px; }
.microsoft-mark i { width: 10px; height: 10px; background: #f35325; }
.microsoft-mark i:nth-child(2) { background: #81bc06; }
.microsoft-mark i:nth-child(3) { background: #05a6f0; }
.microsoft-mark i:nth-child(4) { background: #ffba08; }
.privacy-note { margin: 19px 0 0; color: #847981; font-size: .79rem; }
.lock-mark { position: relative; display: inline-block; width: 9px; height: 8px; margin-right: 5px; border: 1.5px solid currentColor; border-radius: 2px; vertical-align: -1px; }
.lock-mark::before { content: ""; position: absolute; width: 5px; height: 5px; top: -6px; left: 1px; border: 1.5px solid currentColor; border-bottom: 0; border-radius: 5px 5px 0 0; }
.welcome-signature { display: grid; grid-template-columns: 74px 30px 74px; align-items: center; justify-content: center; gap: 7px; margin-top: 39px; color: #a39792; }
.welcome-signature > span { height: 1px; background: #cabdb5; }
.welcome-signature b { font: 400 1.65rem/1 var(--serif); }
.welcome-signature small { grid-column: 1 / -1; font-size: .56rem; line-height: 1.8; letter-spacing: .34em; text-transform: uppercase; }
.welcome-orbit { position: absolute; z-index: -1; inset: 0; pointer-events: none; }
.welcome-orbit i { position: absolute; width: 10px; height: 10px; border-radius: 50%; background: rgba(190, 119, 140, .48); animation: float-dot 7s ease-in-out infinite alternate; }
.welcome-orbit i:nth-child(1) { top: 33%; left: 24%; }
.welcome-orbit i:nth-child(2) { top: 14%; right: 21%; background: rgba(156, 167, 137, .48); animation-delay: -2s; }
.welcome-orbit i:nth-child(3) { bottom: 18%; left: 24%; background: rgba(174, 153, 183, .44); animation-delay: -4s; }
.welcome-orbit i:nth-child(4) { right: 14%; bottom: 25%; background: rgba(156, 167, 137, .45); animation-delay: -5s; }
@keyframes welcome-in { from { opacity: 0; transform: translateY(22px); } to { opacity: 1; transform: none; } }
@keyframes float-dot { to { transform: translateY(-9px) rotate(12deg); } }

/* Zasebna galerija */
.site-header { position: sticky; z-index: 20; top: 0; display: grid; grid-template-columns: minmax(230px, auto) 1fr auto; align-items: stretch; min-height: 72px; padding: 0 clamp(22px, 5.8vw, 92px); border-bottom: 1px solid rgba(224, 215, 210, .78); background: rgba(255, 253, 250, .91); backdrop-filter: blur(16px); }
.brand { display: inline-flex; align-items: center; gap: 8px; color: #453342; font: 400 1.78rem/1 var(--serif); text-decoration: none; }
.brand-mark { width: 34px; height: 34px; object-fit: contain; }
.main-navigation { display: flex; align-items: stretch; gap: 30px; }
.main-navigation a { position: relative; display: grid; place-items: center; padding: 0 8px; color: var(--ink-soft); font: 1rem var(--serif); text-decoration: none; }
.main-navigation a.is-active { color: var(--rose-dark); }
.main-navigation a.is-active::after { content: ""; position: absolute; right: 8px; bottom: 0; left: 8px; height: 2px; background: var(--rose); }
.user-navigation { display: flex; align-items: center; gap: 14px; color: var(--ink-soft); font: .92rem var(--serif); }
.user-navigation a { text-decoration: none; }
.user-navigation i { width: 1px; height: 24px; background: var(--line); }
.user-avatar { display: grid; width: 31px; height: 31px; place-items: center; border-radius: 50%; background: var(--rose-pale); color: var(--rose-dark); font: 700 .79rem var(--sans); }
.mobile-admin-menu { position: relative; display: none; }
.mobile-admin-menu > summary { display: grid; width: 44px; height: 44px; place-items: center; border: 1px solid var(--line); border-radius: 50%; background: var(--paper); color: var(--rose-dark); cursor: pointer; list-style: none; }
.mobile-admin-menu > summary::-webkit-details-marker { display: none; }
.mobile-admin-menu > nav { position: absolute; top: calc(100% + 9px); right: 0; display: grid; min-width: 220px; padding: 8px; border: 1px solid var(--line); border-radius: 9px; background: var(--paper); box-shadow: var(--shadow); }
.mobile-admin-menu > nav a { padding: 12px 14px; border-radius: 6px; color: var(--ink-soft); font: .95rem var(--serif); white-space: nowrap; }
.mobile-admin-menu > nav a:hover, .mobile-admin-menu > nav a[aria-current="page"] { background: var(--rose-pale); color: var(--rose-dark); }
.gallery-shell { width: min(1400px, calc(100% - clamp(30px, 11.8vw, 188px))); margin: 0 auto; padding: 42px 0 60px; }
.gallery-heading, .album-heading { display: flex; align-items: flex-end; justify-content: space-between; gap: 32px; margin-bottom: 28px; }
.gallery-heading h1, .album-heading h1 { margin: 0; color: #493646; font: 400 clamp(2.8rem, 4.8vw, 4.55rem)/.95 var(--serif); letter-spacing: -.045em; }
.gallery-heading p:last-child, .album-heading div > p:last-child { margin: 9px 0 0; color: var(--ink-soft); font: 1.08rem/1.55 var(--serif); }
.gallery-motto { display: grid; justify-items: end; gap: 17px; padding-right: 16px; color: #a88a86; text-align: right; }
.gallery-motto strong { font: italic 400 clamp(1.2rem, 2vw, 1.8rem)/1.12 var(--serif); }
.gallery-motto small { font-size: .59rem; font-weight: 700; letter-spacing: .28em; text-transform: uppercase; }
.gallery-toolbar { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 14px; margin: 24px 0 22px; }
.gallery-filters { display: grid; grid-column: 1; grid-row: 1; grid-template-columns: minmax(260px, 3fr) minmax(150px, 1fr) minmax(150px, 1fr) auto; gap: 14px; margin: 0; }
.gallery-filters input, .gallery-filters select, .album-form input, .album-form select, .album-form textarea, .photo-editor input, .form-panel input[type=file] { width: 100%; min-height: 48px; border: 1px solid var(--line); border-radius: 7px; background: rgba(255, 253, 250, .94); padding: 10px 15px; color: var(--ink); }
.gallery-filters input, .gallery-filters select { font: .94rem var(--serif); }
.search-field { position: relative; }
.search-field input { padding-left: 48px; }
.search-icon { position: absolute; z-index: 1; top: 50%; left: 18px; color: var(--ink-soft); font: 1.7rem/1 var(--serif); transform: translateY(-55%) rotate(-20deg); }
.filter-submit { min-width: 94px; }
.new-album-button { grid-column: 2; grid-row: 1; min-width: 168px; font: 1rem var(--serif); }
.new-album-button span { display: grid; width: 22px; height: 22px; place-items: center; border-radius: 50%; background: #fff; color: var(--rose-dark); font: 700 1rem/1 var(--sans); }
.mobile-filter-toggle { display: none; }
.hamburger-mark { display: grid; width: 18px; gap: 3px; }
.hamburger-mark i { display: block; height: 2px; border-radius: 2px; background: currentColor; }
.album-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 20px; }
.album-card, .photo-card, .form-panel, .empty-state { overflow: hidden; border: 1px solid var(--line); border-radius: 8px; background: rgba(255, 253, 250, .95); box-shadow: var(--shadow); }
.album-card { transition: transform .24s ease, box-shadow .24s ease; }
.album-card:hover { transform: translateY(-3px); box-shadow: 0 17px 38px rgba(69, 49, 60, .12); }
.album-card > a, .album-placeholder { display: block; aspect-ratio: 2.18 / 1; background: linear-gradient(145deg, var(--rose-pale), var(--lavender)); }
.album-card img { display: block; width: 100%; height: 100%; object-fit: cover; }
.album-placeholder { display: grid; place-items: center; color: rgba(255, 255, 255, .88); font: 3rem var(--serif); }
.album-card > div:last-child { padding: 11px 16px 15px; }
.album-card .eyebrow { margin: 0; color: #7e7078; font: .77rem var(--serif); letter-spacing: 0; text-transform: none; }
.album-card h2 { margin: 3px 0 5px; font: 400 1.35rem/1.08 var(--serif); }
.album-card h2 a { text-decoration: none; }
.album-card p:not(.eyebrow) { margin: 0; color: var(--muted); font: .82rem/1.45 var(--serif); }
.album-card small { float: right; margin-top: -44px; color: var(--muted); font: .73rem var(--serif); }
.photo-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 18px; }
.photo-card > a { display: block; aspect-ratio: 1 / 1; background: #f1ecee; }
.photo-card > a img { display: block; width: 100%; height: 100%; object-fit: contain; }
.video-card > video { display: block; width: 100%; aspect-ratio: 1 / 1; background: #241e22; object-fit: contain; }
.video-editor-actions { display: flex; flex-wrap: wrap; justify-content: flex-end; gap: 8px; }
.video-delete-button { color: #8b3445; }
.photo-copy { padding: 15px; }
.photo-copy > h3 { margin: 4px 0 6px; font: 600 1rem/1.3 var(--serif); }
.photo-copy > p { margin: 4px 0 12px; }
.photo-copy summary, .form-panel summary { cursor: pointer; font-weight: 700; }
.photo-card-tools { display: grid; grid-template-columns: 1fr auto auto; align-items: start; gap: 6px; min-height: 28px; }
.photo-editor { grid-column: 3; min-width: 28px; }
.photo-editor[open] { grid-column: 1 / -1; }
.photo-editor > summary { display: grid; width: 28px; height: 28px; margin-left: auto; place-items: center; border: 1px solid var(--line); border-radius: 50%; background: var(--paper); color: var(--rose-dark); list-style: none; }
.photo-editor > summary::-webkit-details-marker { display: none; }
.photo-editor > summary:hover { border-color: var(--rose); background: #fcf5f6; }
.photo-editor > summary span[aria-hidden="true"] { font: .88rem/1 var(--serif); }
.photo-editor form { display: grid; gap: 12px; margin-top: 12px; padding-top: 12px; border-top: 1px solid var(--line); }
.photo-order-controls { display: flex; grid-column: 2; align-items: center; gap: 5px; margin: 0; }
.photo-order-controls button { display: grid; width: 28px; height: 28px; min-height: 0; padding: 0; place-items: center; border: 1px solid var(--line); border-radius: 50%; background: var(--paper); color: var(--rose-dark); cursor: pointer; font-size: .88rem; font-weight: 750; }
.photo-order-controls button:hover:not(:disabled) { border-color: var(--rose); background: #fcf5f6; }
.photo-order-controls button:disabled { color: #b8afb4; cursor: default; opacity: .62; }
.milestone-badge { display: inline-block; border-radius: 99px; background: var(--rose-pale); color: var(--rose-dark); padding: 5px 9px; font-size: .72rem; font-weight: 800; letter-spacing: .08em; text-transform: uppercase; }
.photo-view-page { min-height: 100svh; background: #241e22; color: #fff; }
.photo-viewer { position: relative; display: grid; min-height: 100svh; place-items: center; padding: max(72px, calc(env(safe-area-inset-top) + 60px)) max(18px, env(safe-area-inset-right)) max(20px, env(safe-area-inset-bottom)) max(18px, env(safe-area-inset-left)); }
.photo-viewer figure { display: grid; max-width: min(1400px, 100%); max-height: calc(100svh - 110px); gap: 12px; margin: 0; place-items: center; }
.photo-viewer figure img { display: block; max-width: 100%; max-height: calc(100svh - 150px); object-fit: contain; }
.photo-viewer figcaption { max-width: 720px; color: #eadfe4; font: .95rem/1.5 var(--serif); text-align: center; }
.photo-viewer figcaption strong, .photo-viewer figcaption span { display: block; }
.upload-title-list { display: grid; gap: 10px; }
.upload-title-list:empty { display: none; }
.upload-title-list label { display: grid; gap: 6px; }
.photo-view-back { position: fixed; z-index: 2; top: max(14px, env(safe-area-inset-top)); left: max(14px, env(safe-area-inset-left)); display: inline-flex; min-height: 44px; align-items: center; gap: 9px; padding: 9px 14px; border: 1px solid rgba(255, 255, 255, .32); border-radius: 999px; background: rgba(36, 30, 34, .76); color: #fff; text-decoration: none; backdrop-filter: blur(12px); }
.photo-view-back span:first-child { font-size: 1.45rem; line-height: 1; }
.photo-view-back:hover { background: rgba(73, 55, 70, .92); }
.form-panel { margin: 28px 0; padding: 24px; }
.form-panel > summary { font-size: 1.1rem; }
.form-panel form { margin-top: 18px; }
.form-panel label, .album-form label, .photo-editor label { display: grid; gap: 7px; color: var(--muted); font-size: .88rem; font-weight: 700; }
.form-panel small { font-weight: 500; }
.album-form { display: grid; grid-template-columns: 2fr 1fr 1fr; gap: 16px; }
.album-form .wide { grid-column: 1 / -1; }
.check-row { display: flex !important; grid-auto-flow: column; justify-content: start; align-items: center; }
.check-row input { width: auto !important; min-height: 0 !important; }
.notice { margin: 0 0 18px; padding: 13px 16px; border-radius: 7px; }
.notice.success { background: #e4eee7; }
.notice.error { background: #f8dede; color: #742e3c; }
.empty-state { padding: 55px 24px; text-align: center; }
.empty-state > div { color: var(--rose); font-size: 3rem; }
.empty-state h2 { font: 400 2rem var(--serif); }
.empty-state p { color: var(--muted); }
.site-footer { display: grid; grid-template-columns: 1fr auto 1fr; align-items: center; gap: 18px; padding: 0 max(20px, 6vw) 35px; color: #aa7c88; font-size: .58rem; font-weight: 700; letter-spacing: .3em; text-align: center; text-transform: uppercase; }
.site-footer > span { justify-self: end; }
.site-footer small { justify-self: end; color: #9f9297; font-size: .54rem; }

/* Administracija in zasebna analitika */
.admin-shell { width: min(1380px, calc(100% - clamp(30px, 8vw, 120px))); margin: 0 auto; padding: 42px 0 72px; }
.admin-heading { display: flex; align-items: flex-end; justify-content: space-between; gap: 28px; margin-bottom: 28px; }
.admin-heading h1 { margin: 0; font: 400 clamp(2.8rem, 4.8vw, 4.4rem)/.95 var(--serif); letter-spacing: -.045em; }
.admin-heading p:last-child { margin: 10px 0 0; color: var(--muted); font: 1.03rem/1.5 var(--serif); }
.period-switcher { display: flex; overflow: hidden; flex: 0 0 auto; border: 1px solid var(--line); border-radius: 8px; background: var(--paper); }
.period-switcher a { padding: 10px 14px; border-right: 1px solid var(--line); color: var(--muted); font-size: .78rem; font-weight: 700; text-decoration: none; }
.period-switcher a:last-child { border-right: 0; }
.period-switcher a.is-active { background: var(--rose-dark); color: #fff; }
.admin-kpis { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 14px; margin-bottom: 20px; }
.admin-kpis article { display: grid; gap: 7px; min-height: 142px; align-content: start; padding: 20px; border: 1px solid var(--line); border-radius: 9px; background: rgba(255, 253, 250, .95); box-shadow: 0 8px 26px rgba(69, 49, 60, .045); }
.admin-kpis span { color: var(--muted); font-size: .72rem; font-weight: 800; letter-spacing: .08em; text-transform: uppercase; }
.admin-kpis strong { font: 400 2.7rem/1 var(--serif); }
.admin-kpis small { color: var(--muted); font-size: .73rem; line-height: 1.4; }
.admin-dashboard-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 20px; }
.admin-panel { min-width: 0; margin-bottom: 20px; padding: 24px; border: 1px solid var(--line); border-radius: 9px; background: rgba(255, 253, 250, .95); box-shadow: var(--shadow); }
.admin-panel-wide { grid-column: 1 / -1; }
.admin-panel > header { display: flex; align-items: flex-start; justify-content: space-between; gap: 16px; margin-bottom: 20px; }
.admin-panel h2 { margin: 0; font: 400 1.55rem/1.2 var(--serif); }
.admin-panel header a { color: var(--rose-dark); font-size: .8rem; font-weight: 700; }
.analytics-bars { display: grid; gap: 13px; }
.analytics-bar-row { display: grid; grid-template-columns: minmax(105px, 180px) minmax(100px, 1fr) 52px; align-items: center; gap: 12px; font-size: .79rem; }
.analytics-bar-row > span { overflow: hidden; color: var(--ink-soft); text-overflow: ellipsis; white-space: nowrap; }
.analytics-bar-row svg { width: 100%; height: 12px; overflow: visible; }
.analytics-bar-track { fill: #f0eae7; }
.analytics-bar-fill { fill: var(--rose); }
.analytics-bar-row strong { text-align: right; }
.audit-list, .member-usage-list { display: grid; gap: 0; margin: 0; padding: 0; list-style: none; }
.audit-list li, .member-usage-list li { display: flex; align-items: flex-start; justify-content: space-between; gap: 18px; padding: 12px 0; border-top: 1px solid var(--line); }
.audit-list li:first-child, .member-usage-list li:first-child { border-top: 0; }
.audit-list p { margin: 4px 0 0; color: var(--muted); font-size: .8rem; }
.audit-list time, .member-usage-list small { color: var(--muted); font-size: .7rem; white-space: nowrap; }
.member-usage-list span { display: grid; gap: 4px; }
.member-usage-list b { color: var(--rose-dark); font-size: .77rem; white-space: nowrap; }
.privacy-panel { display: flex; align-items: baseline; gap: 18px; margin-top: 2px; padding: 18px 22px; border: 1px solid #dedfd2; border-radius: 9px; background: #f3f4ed; color: #626656; }
.privacy-panel strong { flex: 0 0 auto; font: 400 1.05rem var(--serif); }
.privacy-panel p { margin: 0; font-size: .77rem; line-height: 1.55; }
.admin-empty { padding: 28px 0; color: var(--muted); text-align: center; }
.admin-empty p { margin: 0; }
.admin-table-wrap { overflow-x: auto; }
.admin-table-wrap table { width: 100%; border-collapse: collapse; font-size: .76rem; }
.admin-table-wrap th { padding: 10px 12px; border-bottom: 2px solid var(--line); color: var(--muted); font-size: .65rem; letter-spacing: .08em; text-align: left; text-transform: uppercase; }
.admin-table-wrap td { max-width: 320px; padding: 12px; border-bottom: 1px solid var(--line); vertical-align: top; }
.admin-table-wrap tbody tr:hover { background: #fcf7f6; }
.admin-table-wrap details summary { color: var(--rose-dark); cursor: pointer; font-weight: 700; }
.audit-filters { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.audit-filters label { display: grid; gap: 6px; color: var(--muted); font-size: .76rem; font-weight: 700; }
.audit-filters select { width: 100%; min-height: 44px; padding: 8px 11px; border: 1px solid var(--line); border-radius: 7px; background: var(--paper); color: var(--ink); }
.audit-filters > a { align-self: center; color: var(--rose-dark); font-size: .78rem; font-weight: 700; }
.audit-metadata { margin: 8px 0 0; }
.audit-metadata div { display: grid; grid-template-columns: 80px 1fr; gap: 6px; padding: 3px 0; }
.audit-metadata dt { color: var(--muted); }
.audit-metadata dd { margin: 0; overflow-wrap: anywhere; }

/* Enotna galerija in sekcije */
.continuous-gallery { display: grid; gap: 58px; }
.gallery-section { scroll-margin-top: 94px; }
.favorites-section { padding: clamp(18px, 2.4vw, 30px); border: 1px solid #e7cfd5; border-radius: 12px; background: linear-gradient(145deg, rgba(255, 253, 250, .98), rgba(240, 218, 221, .3)); box-shadow: var(--shadow); }
.favorites-section .section-divider { border-bottom-color: #dfc1ca; }
.section-divider { display: flex; align-items: flex-end; justify-content: space-between; gap: 28px; margin-bottom: 20px; padding: 0 2px 17px; border-bottom: 1px solid var(--line); cursor: pointer; list-style: none; }
.section-divider::-webkit-details-marker { display: none; }
.section-divider > div { max-width: 820px; }
.section-divider h2 { margin: 0; color: var(--ink); font: 400 clamp(2rem, 3.2vw, 3rem)/1 var(--serif); letter-spacing: -.035em; }
.section-divider p:last-child { margin: 9px 0 0; color: var(--ink-soft); font: .98rem/1.55 var(--serif); }
.section-divider > span { flex: 0 0 auto; color: var(--muted); font: .78rem var(--serif); white-space: nowrap; }
.section-summary-meta { display: flex; align-items: center; gap: 13px; }
.section-summary-meta i { width: 10px; height: 10px; border-right: 2px solid var(--rose-dark); border-bottom: 2px solid var(--rose-dark); transform: rotate(-45deg); transition: transform .2s ease; }
.gallery-section[open] > .section-divider .section-summary-meta i { transform: rotate(45deg); }
.gallery-section:not([open]) > .section-divider { margin-bottom: 0; border-bottom-color: transparent; }
.section-empty { padding: 24px; border: 1px dashed var(--line); border-radius: 8px; color: var(--muted); text-align: center; }
.section-empty p { margin: 0; }
.upload-dialog { width: min(680px, calc(100% - 32px)); max-height: calc(100svh - 32px); padding: 0; border: 0; border-radius: 12px; background: transparent; color: var(--ink); box-shadow: 0 24px 80px rgba(69, 49, 60, .24); }
.upload-dialog::backdrop { background: rgba(57, 43, 53, .42); backdrop-filter: blur(4px); }
.upload-dialog-panel { padding: 26px; background: var(--paper); }
.upload-dialog-panel > header { display: flex; align-items: flex-start; justify-content: space-between; gap: 20px; margin-bottom: 22px; }
.upload-dialog-panel h2 { margin: 0; font: 400 2rem/1 var(--serif); }
.upload-dialog-close { display: grid; flex: 0 0 auto; width: 34px; height: 34px; padding: 0; place-items: center; border: 1px solid var(--line); border-radius: 50%; background: var(--paper); color: var(--ink-soft); cursor: pointer; font-size: 1.35rem; line-height: 1; }
.upload-dialog-close:hover { border-color: var(--rose); color: var(--rose-dark); }
.upload-form { display: grid; grid-template-columns: 1fr; gap: 18px; }
.upload-form label, .section-form label { display: grid; gap: 7px; color: var(--ink-soft); font-size: .78rem; font-weight: 700; }
.upload-form select, .upload-form input[type=file], .upload-form input[type=text], .section-form input, .section-form select, .section-form textarea { width: 100%; min-height: 46px; padding: 10px 13px; border: 1px solid var(--line); border-radius: 7px; background: var(--paper); color: var(--ink); }
.upload-form small, .section-form small { color: var(--muted); font-size: .68rem; font-weight: 400; line-height: 1.4; }
.upload-dialog-actions { display: flex; justify-content: flex-end; gap: 10px; padding-top: 4px; }
.section-form { display: grid; grid-template-columns: minmax(220px, 2fr) repeat(3, minmax(120px, 1fr)); align-items: start; gap: 16px; }
.section-form .wide { grid-column: 1 / -1; }
.section-form textarea { resize: vertical; }
.section-form .check-row { display: flex; align-items: center; }
.section-form .check-row input { width: auto; min-height: auto; }
.section-admin-list { display: grid; gap: 12px; }
.section-admin-list > article { padding: 17px 18px; border: 1px solid var(--line); border-radius: 8px; background: var(--paper); scroll-margin-top: 94px; }
.section-admin-list > article > header { display: flex; align-items: center; justify-content: space-between; gap: 16px; }
.section-admin-list > article > header div { display: grid; gap: 4px; }
.section-admin-list > article > header strong { font: 400 1.17rem var(--serif); }
.section-admin-list > article > header span, .admin-count { color: var(--muted); font-size: .72rem; }
.section-admin-list > article > header b { padding: 5px 9px; border-radius: 999px; background: var(--rose-pale); color: var(--rose-dark); font-size: .64rem; letter-spacing: .08em; text-transform: uppercase; }
.section-admin-list details { margin-top: 12px; border-top: 1px solid var(--line); padding-top: 12px; }
.section-admin-list summary { color: var(--rose-dark); cursor: pointer; font-size: .78rem; font-weight: 750; }
.section-admin-list .section-form { margin-top: 16px; }
.delete-section-form { margin-top: 14px; padding-top: 14px; border-top: 1px solid var(--line); }
.delete-section-form button { padding: 0; border: 0; background: transparent; color: #995465; cursor: pointer; font-size: .75rem; font-weight: 750; text-decoration: underline; }
.bulk-photo-toolbar { position: sticky; z-index: 10; top: 86px; display: grid; grid-template-columns: minmax(220px, 1fr) minmax(260px, 420px) auto; align-items: end; gap: 18px; }
.bulk-photo-toolbar h2 { margin: 0; }
.bulk-photo-toolbar label { display: grid; gap: 7px; color: var(--muted); font-size: .76rem; font-weight: 750; }
.bulk-photo-toolbar select { width: 100%; min-height: 46px; padding: 9px 12px; border: 1px solid var(--line); border-radius: 7px; background: var(--paper); color: var(--ink); }
.photo-move-sections { display: grid; gap: 20px; }
.photo-move-section { margin-bottom: 0; }
.photo-move-grid { display: grid; grid-template-columns: repeat(6, minmax(0, 1fr)); gap: 12px; }
.photo-move-card { position: relative; overflow: hidden; display: grid; align-content: start; border: 1px solid var(--line); border-radius: 8px; background: var(--paper); cursor: pointer; transition: border-color .18s ease, box-shadow .18s ease, transform .18s ease; }
.photo-move-card:hover { border-color: var(--rose); transform: translateY(-1px); }
.photo-move-card:has(input:checked) { border-color: var(--rose-dark); box-shadow: 0 0 0 2px rgba(182, 111, 131, .18); }
.photo-move-card > label { display: grid; align-content: start; cursor: pointer; }
.photo-move-card input { position: absolute; z-index: 1; top: 9px; left: 9px; width: 20px; height: 20px; margin: 0; accent-color: var(--rose-dark); }
.photo-move-card img { width: 100%; aspect-ratio: 1 / 1; object-fit: contain; background: #f1ecee; }
.photo-move-card label > span { display: grid; gap: 4px; padding: 9px 42px 11px 10px; }
.photo-move-card strong { overflow: hidden; font-size: .72rem; line-height: 1.35; text-overflow: ellipsis; white-space: nowrap; }
.photo-move-card small { color: var(--muted); font-size: .65rem; }
.photo-delete-button { position: absolute; right: 8px; bottom: 8px; display: grid; width: 28px; height: 28px; padding: 0; place-items: center; border: 1px solid #e4bcc5; border-radius: 50%; background: #fff8f8; color: #995465; cursor: pointer; font-size: 1.1rem; line-height: 1; }
.photo-delete-button:hover { border-color: #995465; background: #f8dede; }
.photo-order-tools { display: flex; flex-wrap: wrap; align-items: center; justify-content: flex-end; gap: 10px; }
.photo-order-status { padding: 5px 10px; border-radius: 999px; background: #eef0e8; color: #5c6650; font-size: .72rem; font-weight: 750; }
.photo-order-status[data-state="saving"] { background: var(--rose-pale); color: var(--rose-dark); }
.photo-order-status[data-state="error"] { background: #f8dede; color: #8a3b4d; }
.photo-order-undo { min-height: 32px; padding: 0 12px; font-size: .74rem; }
.photo-order-undo[hidden], .photo-order-status[hidden] { display: none; }
.photo-order-hint { margin: -8px 0 14px; color: var(--muted); font-size: .74rem; }
.photo-order-position { position: absolute; z-index: 1; top: 9px; left: 36px; min-width: 22px; padding: 2px 7px; border-radius: 999px; background: rgba(73, 55, 70, .74); color: #fff; font-size: .64rem; font-weight: 800; line-height: 16px; text-align: center; }
.photo-order-handle { position: absolute; z-index: 2; top: 7px; right: 7px; display: grid; width: 32px; height: 32px; padding: 0; place-items: center; border: 1px solid var(--line); border-radius: 7px; background: rgba(255, 253, 250, .94); color: var(--rose-dark); cursor: grab; touch-action: none; }
.photo-order-handle:hover { border-color: var(--rose); background: #fcf5f6; }
.photo-order-handle:active { cursor: grabbing; }
.photo-order-handle svg { width: 16px; height: 16px; fill: currentColor; }
.photo-move-card.is-keyboard-grabbed { border-color: var(--rose-dark); box-shadow: 0 0 0 3px var(--rose-dark); transform: scale(1.03); }
.photo-move-card.sortable-ghost { border: 2px dashed var(--rose); background: var(--rose-pale); opacity: .45; }
.photo-move-card.sortable-ghost > * { visibility: hidden; }
.photo-move-card.sortable-chosen { box-shadow: 0 18px 40px rgba(69, 49, 60, .25); }
.photo-move-grid.is-saving .photo-order-handle { cursor: progress; }
@media (prefers-reduced-motion: reduce) { .photo-move-card.is-keyboard-grabbed { transform: none; } }
.photo-delete-form { display: none; }
/* Passkeys: the welcome button and Moji ključi (passkeys.php). */
.welcome-action + .passkey-button { margin-top: 12px; }
.passkey-button[hidden] { display: none; }
.key-mark { position: relative; display: inline-block; width: 7px; height: 7px; margin-right: 12px; border: 1.5px solid currentColor; border-radius: 50%; }
.key-mark::after { content: ""; position: absolute; top: 2px; left: 7px; width: 9px; height: 1.5px; background: currentColor; }
.passkey-status:empty { display: none; }
.passkeys-shell { width: min(760px, calc(100% - 32px)); margin: 0 auto; padding: 42px 0 72px; }
.passkeys-panel h1 { margin: 0 0 12px; font: 400 clamp(2rem, 5vw, 2.6rem)/1.1 var(--serif); }
.passkeys-lead, .passkeys-empty { color: var(--ink-soft); line-height: 1.6; }
.passkey-list { margin: 20px 0 0; padding: 0; border-top: 1px solid var(--line); list-style: none; }
.passkey-list li { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 13px 0; border-bottom: 1px solid var(--line); }
.passkey-list strong { overflow-wrap: anywhere; }
.passkey-list small { display: block; margin-top: 3px; color: var(--muted); font-size: .8rem; }
.passkey-list .text-button { padding: 6px 0; border: 0; background: none; color: var(--rose-dark); font: inherit; font-size: .85rem; font-weight: 700; text-decoration: underline; cursor: pointer; }
.passkey-form { display: flex; align-items: end; gap: 12px; margin-top: 22px; }
.passkey-form label { display: grid; flex: 1; gap: 7px; color: var(--muted); font-size: .88rem; font-weight: 700; }
.passkey-form input { min-height: 46px; padding: 0 12px; border: 1px solid var(--line); border-radius: 7px; background: var(--paper); color: var(--ink); font: inherit; }
.passkey-reauth { margin-top: 22px; border: 1px solid var(--line); background: var(--cream); }
#passkey-status { margin-top: 16px; }
#passkey-status[hidden] { display: none; }

@media (max-width: 1050px) {
  .site-header { grid-template-columns: auto 1fr auto; padding-inline: 24px; }
  .gallery-shell { width: min(100% - 40px, 1100px); }
  .gallery-filters { grid-template-columns: minmax(220px, 2fr) 1fr 1fr auto; }
  .admin-kpis { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .section-form { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .photo-move-grid { grid-template-columns: repeat(4, minmax(0, 1fr)); }
}
@media (max-width: 820px) {
  .welcome { align-items: start; padding-top: max(13vh, 74px); background-position: 47% center; }
  .welcome::after { content: ""; position: absolute; z-index: -1; inset: 0; background: rgba(255, 252, 247, .56); backdrop-filter: blur(2px); }
  .welcome-content { width: min(580px, 92vw); }
  .welcome h1 { font-size: clamp(4.6rem, 17vw, 7.2rem); }
  .welcome-signature { margin-top: 28px; }
  .site-header { grid-template-columns: 1fr auto; min-height: 64px; }
  .main-navigation { display: none; }
  .mobile-admin-menu { display: block; }
  .user-navigation > span:not(.user-avatar) { display: none; }
  .gallery-heading, .album-heading { align-items: flex-start; flex-direction: column; }
  .gallery-motto { display: none; }
  .gallery-toolbar { grid-template-columns: 1fr; }
  .gallery-toolbar.has-upload-action { grid-template-columns: minmax(82px, .7fr) minmax(168px, 1.3fr); }
  .mobile-filter-toggle { display: inline-flex; grid-column: 1; grid-row: 1; min-width: 0; }
  .new-album-button { grid-column: 2; grid-row: 1; min-width: 0; justify-self: stretch; }
  .gallery-filters { grid-column: 1 / -1; grid-row: 2; grid-template-columns: 1fr 1fr; }
  .has-js .gallery-filters:not(.is-open) { display: none; }
  .search-field { grid-column: 1 / -1; }
  .filter-submit { justify-self: stretch; }
  .album-grid, .photo-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .album-form { grid-template-columns: 1fr 1fr; }
  .album-form label:first-of-type { grid-column: 1 / -1; }
  .site-footer { grid-template-columns: 1fr; }
  .site-footer > span, .site-footer small { justify-self: center; }
  .admin-shell { width: min(100% - 32px, 900px); padding-top: 32px; }
  .admin-heading { align-items: flex-start; flex-direction: column; }
  .admin-dashboard-grid { grid-template-columns: 1fr; }
  .admin-panel-wide { grid-column: auto; }
  .admin-kpis { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .privacy-panel { align-items: flex-start; flex-direction: column; gap: 6px; }
  .upload-dialog-panel { padding: 22px; }
  .bulk-photo-toolbar { position: static; grid-template-columns: 1fr 1fr; }
  .bulk-photo-toolbar > div { grid-column: 1 / -1; }
  .photo-move-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}
@media (max-width: 560px) {
  .passkey-form { display: grid; align-items: stretch; }
  .brand { font-size: 1.35rem; }
  .site-header { padding-inline: 15px; }
  .gallery-shell { width: min(100% - 24px, 1240px); padding-top: 30px; }
  .gallery-heading h1, .album-heading h1 { font-size: clamp(2.6rem, 13vw, 3.5rem); }
  .album-grid, .photo-grid, .gallery-filters, .album-form { grid-template-columns: 1fr; }
  .album-form label, .search-field { grid-column: auto !important; }
  .new-album-button { width: auto; padding-inline: 12px; font-size: .92rem; }
  .album-card > a, .album-placeholder { aspect-ratio: 1.72 / 1; }
  .site-footer { line-height: 1.8; }
  .welcome { padding-inline: 16px; background-position: 43% center; }
  .welcome-logo { width: 54px; height: 54px; }
  .welcome-kicker { margin-bottom: 18px; letter-spacing: .2em; }
  .welcome h1 { font-size: clamp(4.35rem, 22vw, 6rem); }
  .welcome-lead br { display: none; }
  .welcome-action { font-size: .92rem; }
  .privacy-note { font-size: .72rem; }
  .admin-site-header .user-navigation { gap: 9px; }
  .admin-heading h1 { font-size: clamp(2.6rem, 13vw, 3.5rem); }
  .period-switcher { display: grid; width: 100%; grid-template-columns: repeat(4, 1fr); }
  .period-switcher a { padding-inline: 6px; text-align: center; }
  .admin-kpis { grid-template-columns: 1fr; }
  .admin-kpis article { min-height: 116px; }
  .analytics-bar-row { grid-template-columns: minmax(82px, 120px) minmax(74px, 1fr) 42px; gap: 8px; }
  .admin-panel { padding: 18px; }
  .audit-filters { grid-template-columns: 1fr; }
  .upload-dialog-actions { align-items: stretch; flex-direction: column-reverse; }
  .upload-dialog-actions .primary-button, .upload-dialog-actions .secondary-button { width: 100%; }
  .continuous-gallery { gap: 42px; }
  .section-divider { align-items: flex-start; flex-direction: column; gap: 8px; }
  .section-form { grid-template-columns: 1fr; }
  .section-form .wide { grid-column: auto; }
  .bulk-photo-toolbar, .photo-move-grid { grid-template-columns: 1fr 1fr; }
  .bulk-photo-toolbar > div, .bulk-photo-toolbar label, .bulk-photo-toolbar button { grid-column: 1 / -1; }
  .photo-view-back { width: 44px; padding: 0; justify-content: center; }
  .photo-view-back span:last-child { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0, 0, 0, 0); white-space: nowrap; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { scroll-behavior: auto !important; animation: none !important; transition: none !important; }
  .welcome::before { transform: none; }
}
