/* =====================================================================
   v30 look — calm, glassy, modern. Loaded last. Colours still come from
   Admin › Look (--primary / --surf), so every theme preset keeps working.
   ===================================================================== */
:root{
  --r-sm:10px;--r-md:14px;--r-lg:20px;--r-xl:28px;
  --c-border:rgba(17,19,24,.07);
  --c-border-strong:rgba(17,19,24,.12);
  --c-surface:#fff;
  --c-surface-2:color-mix(in oklab,var(--primary) 4%,#F2F3F6);
  --c-hover:transparent;
  --glass:rgba(255,255,255,.72);
  --glass-line:rgba(255,255,255,.7);
  --e-1:0 1px 2px rgba(17,19,24,.05);
  --e-2:0 1px 2px rgba(17,19,24,.04),0 8px 24px -6px rgba(17,19,24,.10);
  --e-3:0 2px 6px rgba(17,19,24,.06),0 24px 48px -12px rgba(17,19,24,.22);
  --ease:cubic-bezier(.2,.8,.2,1);
}
html.dark{
  --c-border:rgba(255,255,255,.07);
  --c-border-strong:rgba(255,255,255,.13);
  --glass:rgba(22,24,30,.72);
  --glass-line:rgba(255,255,255,.06);
}

/* ---------------- type ---------------- */
body{font-feature-settings:"ss01","cv11";text-rendering:optimizeLegibility}
.h1,.hero .h1,.hero.big .h1{letter-spacing:-.035em;font-weight:750}
.h2,.headline{letter-spacing:-.02em;font-weight:700}
.kicker,.label{letter-spacing:.01em;font-weight:650}

/* ---------------- glass top bar ---------------- */
/* the blur sits on a layer behind the bar: blur on the bar itself would pin the phone bottom bar to the top */
.top{background:transparent!important;box-shadow:0 1px 0 var(--c-border)!important;isolation:isolate}
.top::before{content:"";position:absolute;inset:0;z-index:-1;background:var(--glass);-webkit-backdrop-filter:saturate(1.6) blur(18px);backdrop-filter:saturate(1.6) blur(18px);pointer-events:none}
.reqhd,.adminhd,.menu-btn,.srchhd{transition:background .2s var(--ease),color .2s}
.reqhd:hover,.adminhd:hover,.menu-btn:hover,.srchhd:hover{background:color-mix(in oklab,var(--primary) 8%,transparent)}
@media(min-width:960px){
  .tabs .nav-main a{height:38px;padding:0 15px;font-weight:600}
  .tabs .nav-main a:hover{background:color-mix(in oklab,var(--primary) 7%,transparent)}
  .tabs .nav-main a[aria-current]{background:var(--c-text);color:var(--c-surface)}
  html.dark .tabs .nav-main a[aria-current]{background:#fff;color:#111}
}

/* ---------------- phones: floating glass bottom bar ---------------- */
@media(max-width:959px){
  body.authed{--tabh:76px;padding-bottom:calc(92px + env(safe-area-inset-bottom))}
  .tabs .nav-main{left:12px;right:12px;bottom:calc(10px + env(safe-area-inset-bottom));height:66px;padding:6px;border-radius:26px;border:1px solid var(--glass-line)!important;
    background:var(--glass)!important;-webkit-backdrop-filter:saturate(1.6) blur(20px);backdrop-filter:saturate(1.6) blur(20px);box-shadow:0 10px 30px -8px rgba(17,19,24,.28)}
  .tabs .nav-main a{font-size:.7rem;font-weight:600;gap:3px;border-radius:20px!important}
  .tabs .nav-main a svg{padding:4px 14px;width:22px;height:22px}
  .tabs .nav-main a[aria-current]{color:var(--c-text)}
  .tabs .nav-main a[aria-current] svg{background:var(--c-text);color:var(--c-surface)}
  html.dark .tabs .nav-main a[aria-current] svg{background:#fff;color:#111}
}

/* ---------------- buttons ---------------- */
.btn{border-radius:999px;font-weight:650;transition:background .2s var(--ease),transform .12s var(--ease),box-shadow .2s}
.btn:active{transform:scale(.97)}
.btn.primary{background:var(--primary)!important;border-color:transparent!important;box-shadow:0 6px 16px -6px color-mix(in oklab,var(--primary) 70%,transparent)!important}
.btn.primary:hover{background:color-mix(in oklab,var(--primary) 88%,#000)!important}
.btn:not(.primary):not(.danger){border-color:var(--c-border-strong)}
#tabs .fab-add{background:var(--c-text)!important;color:var(--c-surface)!important;box-shadow:0 12px 28px -8px rgba(17,19,24,.45)!important;border-radius:20px}
html.dark #tabs .fab-add{background:#fff!important;color:#111!important}

/* ---------------- cards, sheets, fields ---------------- */
.card,.admin-sec,.fixbox,.devbox,.notice{border:1px solid var(--c-border);border-radius:var(--r-lg);box-shadow:var(--e-1)}
.sheet{border-radius:var(--r-xl) var(--r-xl) 0 0;box-shadow:var(--e-3)}
@media(min-width:700px){.sheet{border-radius:var(--r-xl)}}
.sheet-wrap{background:rgba(10,12,16,.38);-webkit-backdrop-filter:blur(6px);backdrop-filter:blur(6px)}
.field input,.field select,.field textarea{background:var(--c-surface-2);border:1px solid transparent;border-radius:var(--r-md);min-height:50px;transition:border-color .2s,background .2s,box-shadow .2s}
.field input:hover,.field select:hover,.field textarea:hover{border-color:var(--c-border-strong)}
.field input:focus,.field select:focus,.field textarea:focus{background:var(--c-surface);border-color:var(--primary);outline:0;box-shadow:0 0 0 4px color-mix(in oklab,var(--primary) 16%,transparent)}
.toast{border-radius:18px}

/* ---------------- login ---------------- */
.login-card{border-radius:32px;border:1px solid var(--glass-line);background:var(--glass);-webkit-backdrop-filter:saturate(1.5) blur(24px);backdrop-filter:saturate(1.5) blur(24px);box-shadow:var(--e-3);padding:36px 28px}
.login .btn.primary,.login button[type=submit]{min-height:52px}

/* ---------------- password eye ---------------- */
.pw-wrap{position:relative;display:block}
.pw-wrap>input{width:100%;padding-inline-end:52px!important}
.pw-eye{position:absolute;top:50%;inset-inline-end:6px;transform:translateY(-50%);width:40px;height:40px;border:0;border-radius:12px;background:transparent;color:var(--c-text-2);display:grid;place-items:center;cursor:pointer}
.pw-eye:hover{background:color-mix(in oklab,var(--primary) 9%,transparent);color:var(--c-text)}
.pw-eye svg{width:22px;height:22px}

/* ---------------- photos: calm, no shine or zoom on hover ---------------- */
.tile{border-radius:12px;overflow:hidden}
@media(min-width:640px){.tile{border-radius:14px}}
.grid{gap:6px}
@media(min-width:640px){.grid{gap:8px}}
html .tile:hover,html.an-hover .tile:hover{transform:none!important;box-shadow:none!important;scale:none!important}
.tile::after,.tile:hover::after{background:transparent!important}
.tile:focus-visible{outline:3px solid var(--primary);outline-offset:2px}
.album:hover img,html.an-hover .album:hover img{transform:none!important}
html.an-hover .album:hover,.album:hover{transform:none!important}
.album{border-radius:24px;box-shadow:var(--e-2)}

/* ---------------- people: no highlight when the mouse goes over a face ---------------- */
.person:hover,html.an-hover .person:hover{background:transparent!important;transform:none!important;box-shadow:none!important}
.person img,.person .noface{transition:none}
.fface:hover img{border-color:var(--line,var(--c-border-strong))}
.face-chip.glow-on{outline:0}
.face-chip.glow-on img{box-shadow:0 0 0 2px var(--c-surface),0 0 0 4px var(--primary)}
/* tapping a name in the photo view: a thin clean frame around that face instead of a yellow glow */
.fv-glow{border-radius:18%;background:transparent!important;box-shadow:0 0 0 2px rgba(255,255,255,.95),0 0 0 3px rgba(0,0,0,.25)!important}
html.an-glow .fv-glow{animation:v30frame .25s var(--ease) both}
@keyframes v30frame{from{opacity:0}to{opacity:1}}

/* ---------------- the new icon set (6): line + soft tinted shape ---------------- */
svg.ix-d{fill:none;stroke:currentColor;stroke-width:1.75;stroke-linecap:round;stroke-linejoin:round}
svg.ix-d .du{fill:currentColor;stroke:none;opacity:.16}
svg.ix-d .dot,svg.ix-d .fillc{fill:currentColor;stroke:none}
.tabs .nav-main a[aria-current] svg.ix-d .du{opacity:.28}
.btn.primary svg.ix-d .du,#tabs .fab-add svg.ix-d .du{opacity:.3}

/* ---------------- smart search chips + "On this day" (v30 features) ---------------- */
.otd{margin:18px 0 6px;border-radius:24px;overflow:hidden;position:relative;background:var(--c-surface-2)}
.otd-h{display:flex;align-items:center;justify-content:space-between;gap:12px;padding:16px 18px 10px}
.otd-h b{font-size:1.05rem;letter-spacing:-.01em}
.otd-row{display:flex;gap:8px;overflow-x:auto;padding:0 18px 16px;scroll-snap-type:x mandatory}
.otd-row a{flex:0 0 auto;width:132px;aspect-ratio:3/4;border-radius:16px;overflow:hidden;scroll-snap-align:start;background:var(--c-border)}
.otd-row img{width:100%;height:100%;object-fit:cover;display:block}
@media(prefers-reduced-motion:reduce){*{scroll-behavior:auto}}
