/* Logičke zagonetke Razbibrige: krune, sunce i mjesec, nit, šatori, točan broj (zagonetke.js) */
.lg { position:relative; display:grid; width:min(100%,440px); aspect-ratio:1; background:var(--paper); border:3px solid var(--ink); border-radius:14px; overflow:hidden; touch-action:none; user-select:none; -webkit-user-select:none; }
.lg > button { position:relative; border:0; padding:0; margin:0; min-width:0; min-height:0; background:none; display:grid; place-items:center; cursor:pointer; color:var(--ink); font:600 clamp(16px,5vw,24px) Poppins,sans-serif; -webkit-tap-highlight-color:transparent; }
.lg > button svg { width:62%; height:auto; max-height:62%; aspect-ratio:1; pointer-events:none; }
.lg .x { font-size:clamp(11px,3vw,15px); color:var(--muted); font-weight:500; }
.lgtools { display:grid; grid-template-columns:1fr 1fr; gap:8px; width:min(100%,440px); }
.lgtools .btn { min-height:44px; padding:9px 6px; font-size:14px; }
.lghint { font-size:13px; color:var(--muted); max-width:440px; }
@keyframes pop { 0% { transform:scale(.4); } 70% { transform:scale(1.12); } }
.lg .pop svg, .lg .pop .tent { animation:pop .22s var(--ease-out, ease-out); }

/* krune */
.kr > button { color:#1d1a1a; border-right:1px solid rgba(29,26,26,.14); border-bottom:1px solid rgba(29,26,26,.14); }
.kr > button .x { color:rgba(29,26,26,.55); }
.kr > button.bad { color:#c8202b; }
.kr > button.bad::after { content:''; position:absolute; inset:0; background:repeating-linear-gradient(135deg,rgba(200,32,43,.18) 0 4px,transparent 4px 9px); pointer-events:none; }

/* sunce i mjesec */
.sm > button { border-right:1px solid var(--line); border-bottom:1px solid var(--line); }
.sm > button.fix { background:var(--soft); cursor:default; }
.sm > button.bad::after { content:''; position:absolute; inset:0; background:repeating-linear-gradient(135deg,rgba(200,32,43,.2) 0 4px,transparent 4px 9px); pointer-events:none; }
.sm .sg { position:absolute; z-index:2; width:clamp(16px,4.4vw,22px); height:clamp(16px,4.4vw,22px); transform:translate(-50%,-50%); border-radius:50%; background:var(--paper); border:1.5px solid var(--ink); display:grid; place-items:center; font:700 clamp(10px,2.8vw,13px)/1 Poppins,sans-serif; pointer-events:none; }
.sm .sg.bad { background:var(--accent); color:#fff; border-color:var(--accent); }

/* nit */
.nt2 > button { z-index:1; border-right:1px solid var(--line); border-bottom:1px solid var(--line); }
.nt2 > button.on { background:rgba(227,178,60,.22); }
.nt2 .num { width:62%; height:62%; border-radius:50%; background:var(--ink); color:var(--paper); display:grid; place-items:center; font-size:clamp(13px,4vw,20px); pointer-events:none; }
.nt2 > button.on .num { box-shadow:0 0 0 3px #e3b23c; }
.nt2 svg.pth, .nt2 svg.wl { position:absolute; inset:0; width:100%; height:100%; pointer-events:none; }
.nt2 svg.pth { z-index:0; }
.nt2 svg.wl { z-index:2; }
.nt2 svg.wl g { stroke:var(--ink); }

/* šatori */
.tg { display:grid; width:min(100%,440px); gap:0; user-select:none; -webkit-user-select:none; touch-action:none; }
.tg .cl { display:grid; place-items:center; font:600 clamp(12px,3.4vw,16px) Poppins,sans-serif; color:var(--muted); }
.tg .cl.ok { color:var(--ok); } .tg .cl.over { color:var(--accent); }
.tg > button { aspect-ratio:1; border:1px solid var(--line); margin:0 -1px -1px 0; background:var(--paper); padding:0; display:grid; place-items:center; cursor:pointer; font-size:clamp(17px,5.4vw,28px); line-height:1; -webkit-tap-highlight-color:transparent; }
.tg > button.grass { background:var(--ok-soft); }
.tg > button.grass::before { content:''; width:16%; height:16%; border-radius:50%; background:var(--ok); opacity:.7; }
.tg > button.tree { background:var(--soft); cursor:default; }
.tg > button.bad { background:var(--bad-soft); box-shadow:inset 0 0 0 2px var(--accent); }

/* točan broj */
.cilj { display:flex; flex-direction:column; align-items:center; gap:2px; }
.cilj small { font-size:13px; font-weight:600; color:var(--muted); text-transform:uppercase; letter-spacing:.1em; }
.cilj b { font-size:clamp(48px,14vw,72px); font-weight:600; letter-spacing:-.04em; line-height:1; padding:6px 22px; background:var(--ink); color:var(--bg); border-radius:18px; box-shadow:5px 5px 0 var(--accent); }
.tiles { display:grid; grid-template-columns:repeat(3,1fr); gap:10px; width:min(100%,380px); }
.tiles .btn { padding:14px 0; font-size:clamp(22px,6.4vw,28px); font-weight:600; }
.tiles .btn.sel { background:#ffc933; color:#161414; box-shadow:3px 3px 0 var(--ink); transform:translate(-1px,-1px); }
.tiles .btn.new { border-style:dashed; }
.ops { display:grid; grid-template-columns:repeat(4,1fr); gap:10px; width:min(100%,380px); }
.ops .btn { padding:10px 0; font-size:26px; font-weight:600; }
.ops .btn.sel { background:var(--ink); color:var(--bg); }
.steps { display:flex; flex-direction:column; gap:4px; min-height:24px; font-weight:500; color:var(--muted); }

/* izbornik: sve današnje zagonetke na vrhu */
.today { width:100%; display:flex; flex-direction:column; gap:10px; text-align:left; }
.todayhead { display:flex; justify-content:space-between; align-items:baseline; font-size:17px; }
.todayhead span { font-size:14px; font-weight:600; color:var(--ok); }
.todaygrid { display:grid; grid-template-columns:repeat(3,1fr); gap:8px; }
@media (min-width:560px) { .todaygrid { grid-template-columns:repeat(5,1fr); } }
.tday { display:flex; flex-direction:column; align-items:center; gap:2px; padding:10px 4px 8px; min-width:0; background:var(--paper); color:var(--ink); border:2px solid var(--ink); border-radius:14px; box-shadow:3px 3px 0 var(--ink); cursor:pointer; font-family:inherit; transition:transform .15s var(--ease-out, ease-out); }
.tday:active { transform:translate(2px,2px); box-shadow:1px 1px 0 var(--ink); }
.tday i { font-style:normal; font-size:24px; line-height:1.2; }
.tday b { font-size:13px; font-weight:600; line-height:1.15; text-align:center; overflow-wrap:anywhere; }
.tday small { font-size:11px; font-weight:500; color:var(--muted); }
.tday.solved { background:var(--ok-soft); border-color:var(--ok); box-shadow:3px 3px 0 var(--ok); }
.tday.solved small { color:var(--ok); font-weight:600; }
