/* Экраны: главная, выбор игры, профиль, достижения, альбом, лидеры, пустые состояния, совёнок. */
#app { max-width: var(--maxw); margin: 0 auto; padding: 20px 16px 36px; outline: none; }
.route-play #app, #app.route-play { max-width: 1120px; }
.block { margin: 34px 0 10px; }
.block-head { display: flex; align-items: baseline; justify-content: space-between; flex-wrap: wrap; gap: 6px 18px; margin-bottom: 16px; }
.block-head h2 { font-size: 2.1rem; color: var(--amber-300); text-shadow: 0 2px 18px rgba(255, 184, 77, .3); }
.block-head p, .block-head .more { color: rgba(255, 244, 222, .68); }
.page-head { text-align: center; padding: 26px 0 10px; }
.page-head h1 { font-size: clamp(2.4rem, 6vw, 3.8rem); color: var(--amber-300); text-shadow: 0 3px 24px rgba(255, 184, 77, .35); }
.page-head p { max-width: 62ch; margin: 10px auto 0; color: rgba(255, 244, 222, .78); }
.center { text-align: center; display: flex; justify-content: center; flex-wrap: wrap; gap: 10px; }
.dim { color: rgba(255, 244, 222, .62); }
.row { display: flex; flex-wrap: wrap; gap: 10px; justify-content: center; margin-top: 14px; }

/* ---------- главная ---------- */
.hero { display: grid; grid-template-columns: minmax(0, 1.15fr) minmax(0, .85fr); align-items: center; gap: 12px 28px; padding: 24px 0 6px; min-height: min(68vh, 620px); }
.kicker { text-transform: uppercase; letter-spacing: .22em; font-weight: 900; font-size: .78rem; color: var(--amber-300); margin-bottom: 10px; }
.hero h1 { font-size: clamp(3.6rem, 8.4vw, 6.6rem); line-height: .95; background: linear-gradient(180deg, #fff3d6 0%, #ffd58a 38%, #ffb84d 70%, #f09a1f); -webkit-background-clip: text; background-clip: text; color: transparent; filter: drop-shadow(0 6px 34px rgba(255, 184, 77, .4)); margin-bottom: 18px; }
.lead { font-size: 1.14rem; max-width: 54ch; color: rgba(255, 244, 222, .88); }
.cta { display: flex; flex-wrap: wrap; gap: 14px; margin: 26px 0 22px; }
.hero-stats { list-style: none; padding: 0; margin: 0; display: flex; flex-wrap: wrap; gap: 6px 26px; color: rgba(255, 244, 222, .72); font-size: .95rem; }
.hero-stats b { color: var(--amber); font: 700 1.5rem var(--font-num); margin-right: 4px; }
.hero-owl { position: relative; display: grid; place-items: center; min-height: 340px; }
.hero-owl::before { content: ''; position: absolute; width: 86%; aspect-ratio: 1; border-radius: 50%; background: radial-gradient(circle, rgba(255, 184, 77, .28), rgba(255, 184, 77, 0) 68%); filter: blur(6px); }
.hero-owl .owl-bubble { left: 4%; bottom: 84%; transform-origin: bottom left; }
@media (max-width: 820px) {
  .hero { grid-template-columns: 1fr; text-align: center; min-height: 0; padding-top: 8px; }
  .hero-owl { order: -1; min-height: 0; margin-top: 18px; } .hero-owl .owl { --s: min(78vw, 300px) !important; }
  .hero .lead, .hero-stats, .cta { margin-left: auto; margin-right: auto; justify-content: center; }
  .hero-owl .owl-bubble { left: 50%; bottom: 96%; }
}
.today { display: grid; grid-template-columns: repeat(3, 1fr); gap: 14px; margin-top: 18px; }
.t-card { display: flex; align-items: center; gap: 14px; padding: 16px 18px; border-radius: var(--r-l); background: var(--glass); border: 1px solid var(--line); backdrop-filter: blur(6px); }
.t-card .t-ic { font-size: 2rem; flex: none; }
.t-card > div { flex: 1; min-width: 0; } .t-card strong { display: block; font-weight: 900; } .t-card p { font-size: .88rem; color: rgba(255, 244, 222, .72); line-height: 1.35; margin-top: 2px; }
.t-daily[data-solved="0"] { border-color: rgba(255, 184, 77, .7); box-shadow: 0 0 0 1px rgba(255, 184, 77, .25), var(--glow); }
@media (max-width: 920px) { .today { grid-template-columns: 1fr; } }

/* ---------- карточки ---------- */
.grid { display: grid; gap: 16px; }
.grid.kinds { grid-template-columns: repeat(auto-fill, minmax(270px, 1fr)); }
.grid.formats { grid-template-columns: repeat(auto-fill, minmax(230px, 1fr)); }
.grid.topics { grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); }
.card { --acc: var(--amber); position: relative; display: flex; align-items: flex-start; gap: 14px; padding: 18px 18px 16px; border-radius: var(--r-l); background: linear-gradient(160deg, rgba(62, 47, 140, .66), rgba(27, 20, 70, .78)); border: 1px solid var(--line); box-shadow: var(--shadow-1); text-decoration: none; color: var(--cream); transition: transform .35s var(--spring), box-shadow .3s, border-color .3s; overflow: hidden; isolation: isolate; }
.card::before { content: ''; position: absolute; left: 0; top: 0; bottom: 0; width: 5px; background: var(--acc); opacity: .9; }
.card::after { content: ''; position: absolute; inset: auto -20% -60% -20%; height: 90%; background: radial-gradient(closest-side, color-mix(in srgb, var(--acc) 35%, transparent), transparent); opacity: 0; transition: opacity .35s; z-index: -1; }
.card:hover { transform: translateY(-5px) rotate(-.35deg); border-color: color-mix(in srgb, var(--acc) 65%, transparent); box-shadow: var(--shadow-2), 0 0 0 1px color-mix(in srgb, var(--acc) 40%, transparent); color: var(--cream); }
.card:hover::after { opacity: 1; }
.card:active { transform: scale(.98); transition-duration: .1s; }
.card[data-group="words"], .card[data-color="amber"] { --acc: #ffb84d; } .card[data-group="logic"], .card[data-color="violet"] { --acc: #b39bff; }
.card[data-group="pictures"], .card[data-color="coral"] { --acc: #ff8e7a; } .card[data-group="numbers"], .card[data-color="cyan"] { --acc: #6fd8ff; }
.card[data-group="memory"], .card[data-color="green"] { --acc: #7ee0a2; }
.k-emoji { flex: none; font-size: 2.3rem; width: 62px; height: 62px; display: grid; place-items: center; border-radius: 18px; background: color-mix(in srgb, var(--acc) 18%, rgba(255, 255, 255, .06)); box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--acc) 40%, transparent); transition: transform .4s var(--spring); }
.card:hover .k-emoji { transform: scale(1.12) rotate(-6deg); }
.k-body { display: flex; flex-direction: column; gap: 3px; min-width: 0; } .k-body strong { font-size: 1.08rem; font-weight: 900; } .k-desc { font-size: .88rem; color: rgba(255, 244, 222, .72); line-height: 1.35; }
.k-meta { position: absolute; right: 12px; bottom: 9px; font-size: .74rem; font-weight: 800; color: color-mix(in srgb, var(--acc) 80%, #fff); opacity: .9; }
.card.kind { padding-bottom: 28px; }
.card.topic { flex-direction: column; justify-content: flex-end; gap: 2px; min-height: 160px; padding: 16px; --acc: var(--amber-300); }
.card.topic .t-emoji { position: absolute; left: 14px; top: 10px; font-size: 2.6rem; filter: drop-shadow(0 4px 10px rgba(0, 0, 0, .5)); }
.card.topic strong { font-family: var(--font-display); font-weight: 400; font-size: 1.35rem; line-height: 1.1; text-shadow: 0 2px 10px rgba(0, 0, 0, .7); }
.card.topic .k-meta { position: static; color: var(--amber-200); text-shadow: 0 1px 6px rgba(0, 0, 0, .8); }

/* ---------- пустые состояния, скелетоны ---------- */
.empty { text-align: center; padding: 8vh 18px; display: grid; gap: 12px; justify-items: center; }
.empty h2 { font-size: 2.2rem; color: var(--amber-300); } .empty p { max-width: 48ch; color: rgba(255, 244, 222, .78); }
.big-emoji { font-size: 4rem; filter: drop-shadow(0 6px 18px rgba(0, 0, 0, .4)); }
.sk { height: 18px; border-radius: 10px; margin: 12px 0; background: linear-gradient(90deg, rgba(255, 244, 222, .08), rgba(255, 244, 222, .2), rgba(255, 244, 222, .08)) 0 0 / 220% 100%; animation: shimmer 1.4s linear infinite; }
.sk1 { width: 80%; } .sk2 { width: 100%; height: 26px; } .sk3 { width: 55%; }
.sk-card { min-height: 130px; background: linear-gradient(90deg, rgba(255, 244, 222, .05), rgba(255, 244, 222, .13), rgba(255, 244, 222, .05)) 0 0 / 220% 100%; animation: shimmer 1.4s linear infinite; }
@keyframes shimmer { to { background-position: -220% 0; } }
.guest-note { display: flex; flex-wrap: wrap; align-items: center; justify-content: center; gap: 14px; padding: 14px 18px; border-radius: var(--r-l); background: rgba(255, 184, 77, .1); border: 1px dashed rgba(255, 184, 77, .5); margin: 14px auto; max-width: 760px; }
.guest-note p { flex: 1 1 260px; }

/* ---------- совёнок ---------- */
.owl { position: relative; width: var(--s, 220px); height: var(--s, 220px); flex: none; margin-top: calc(var(--s, 220px) * .1); }
.owl-float { position: absolute; inset: 0; display: grid; place-items: end center; }
.owl-float.on { animation: owl-float 5s ease-in-out infinite; }
.owl-in { position: relative; height: 100%; aspect-ratio: var(--ar, 1.07); transform: translate(var(--tx, 0), var(--ty, 0)) rotate(var(--rot, 0deg)); transition: transform .45s ease-out; transform-origin: 50% 90%; }
.owl-in.bounce { animation: owl-bounce .65s var(--spring); }
.owl-img { width: 100%; height: 100%; object-fit: contain; filter: drop-shadow(0 16px 20px rgba(0, 0, 0, .5)) drop-shadow(0 0 26px rgba(255, 184, 77, .22)); user-select: none; -webkit-user-drag: none; display: block; }
.owl-acc-box, .owl-acc, .owl-lids { position: absolute; inset: 0; width: 100%; height: 100%; pointer-events: none; }
.owl-acc { overflow: visible; filter: drop-shadow(0 3px 4px rgba(0, 0, 0, .35)); }
.lid { position: absolute; transform: translate(-50%, -50%); border-radius: 50%; background: radial-gradient(ellipse at 50% 30%, #fbefd9, #efd5aa 65%, #dcb67d); opacity: 0; transition: opacity .05s; box-shadow: 0 0 0 2px rgba(150, 100, 40, .25); }
.lid::after { content: ''; position: absolute; left: 16%; right: 16%; top: 50%; height: 24%; border-bottom: 4px solid #4a2c12; border-radius: 0 0 60% 60%; }
.owl-lids.blink .lid, .owl-lids.wink .lid:last-child { opacity: 1; }
.owl-bubble { position: absolute; left: 50%; bottom: 100%; transform: translate(-50%, 10px) scale(.85); opacity: 0; width: max-content; max-width: min(290px, 78vw); padding: 10px 16px; border-radius: 18px 18px 18px 4px; background: var(--cream); color: var(--ink); font-weight: 800; font-size: .95rem; line-height: 1.3; box-shadow: var(--shadow-2); pointer-events: none; transition: opacity .3s, transform .45s var(--spring); z-index: 3; }
.owl-bubble.show { opacity: 1; transform: translate(-50%, -2px) scale(1); }
.owl-bulb { position: absolute; left: 58%; top: -6%; width: 15%; opacity: 0; transform: translateY(14px) scale(.5); pointer-events: none; z-index: 2; filter: drop-shadow(0 0 12px rgba(255, 213, 138, .9)); }
.owl-bulb.on { animation: bulb 2.2s var(--ease); }
@keyframes owl-float { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-9px); } }
@keyframes owl-bounce { 0% { transform: translate(var(--tx, 0), 0) scale(.92, 1.08); } 40% { transform: translate(var(--tx, 0), -14px) scale(1.06, .94); } 100% { transform: translate(var(--tx, 0), 0) scale(1); } }
@keyframes bulb { 0% { opacity: 0; transform: translateY(14px) scale(.4) rotate(-12deg); } 20% { opacity: 1; transform: translateY(-4px) scale(1.15) rotate(6deg); } 35% { transform: translateY(0) scale(1) rotate(-3deg); } 80% { opacity: 1; } 100% { opacity: 0; transform: translateY(-10px) scale(.9); } }

/* ---------- профиль ---------- */
.profile { display: grid; gap: 18px; }
.pf-card { padding: 22px 24px; border-radius: var(--r-xl); background: linear-gradient(160deg, rgba(62, 47, 140, .62), rgba(24, 17, 62, .8)); border: 1px solid var(--line); box-shadow: var(--shadow-1); backdrop-filter: blur(6px); }
.pf-card h2 { font-size: 1.7rem; color: var(--amber-300); margin-bottom: 10px; } .pf-card h3 { font-size: 1.2rem; color: var(--amber-200); margin: 4px 0 8px; }
.pf-hero { display: grid; grid-template-columns: 380px 1fr; gap: 20px; align-items: center; }
.pf-owl { display: grid; place-items: center; min-height: 360px; padding-top: 34px; } .pf-owl .owl-bubble { bottom: 92%; }
.pf-info h1 { font-size: clamp(2.2rem, 5vw, 3.4rem); color: var(--amber-300); margin-bottom: 12px; }
.lvl-bar { height: 16px; border-radius: 999px; background: rgba(8, 5, 30, .6); border: 1px solid var(--line); overflow: hidden; margin: 8px 0; }
.lvl-bar i, .bar i, .progress i { display: block; height: 100%; border-radius: inherit; background: linear-gradient(90deg, var(--amber-600), var(--amber), var(--amber-300)); box-shadow: 0 0 14px rgba(255, 184, 77, .6); transition: width .8s var(--ease); }
.pf-chips { display: flex; flex-wrap: wrap; gap: 8px; margin: 14px 0; }
.nick-form { display: grid; gap: 8px; margin-top: 10px; } .nick-form label { font-weight: 800; font-size: .86rem; color: var(--amber-200); }
.nick-form input, .answer-row input, .settings select { height: 48px; padding: 0 14px; border-radius: 14px; border: 1.5px solid rgba(255, 213, 138, .3); background: rgba(8, 5, 30, .55); min-width: 0; }
.nick-form input { flex: 1; } .nick-form .logout { justify-self: start; margin-top: 6px; }
.wardrobe { display: grid; gap: 14px; grid-template-columns: repeat(3, 1fr); }
.slot-group { padding: 12px; border-radius: var(--r-m); background: rgba(8, 5, 30, .35); border: 1px solid rgba(255, 213, 138, .14); }
.acc-row { display: grid; gap: 8px; }
.acc { display: flex; justify-content: space-between; align-items: center; gap: 8px; min-height: 52px; padding: 8px 14px; border-radius: 14px; text-align: left; border: 1.5px solid rgba(255, 213, 138, .26); background: rgba(255, 244, 222, .06); transition: transform .3s var(--spring), background .2s, border-color .2s; }
.acc:hover:not(:disabled) { transform: translateY(-2px); background: rgba(255, 184, 77, .14); }
.acc.on { background: linear-gradient(180deg, rgba(255, 184, 77, .35), rgba(255, 184, 77, .15)); border-color: var(--amber); box-shadow: var(--glow); }
.acc.locked { opacity: .55; } .acc-n { font-weight: 800; } .acc small { color: rgba(255, 244, 222, .7); font-weight: 700; white-space: nowrap; }
.pf-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; }
.stat-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; }
.stat { padding: 12px 10px; text-align: center; border-radius: var(--r-m); background: rgba(8, 5, 30, .4); }
.stat b { display: block; font: 700 1.7rem var(--font-num); color: var(--amber); } .stat span { font-size: .8rem; color: rgba(255, 244, 222, .7); }
.records { list-style: none; margin: 0; padding: 0; display: grid; gap: 8px; } .records li { display: flex; justify-content: space-between; gap: 10px; padding: 10px 14px; border-radius: 14px; background: rgba(8, 5, 30, .4); } .records b { color: var(--amber-300); text-align: right; }
.bar-row { display: grid; grid-template-columns: minmax(110px, 1.1fr) 2fr 64px; gap: 10px; align-items: center; margin: 7px 0; font-size: .92rem; }
.bar { height: 11px; border-radius: 999px; background: rgba(8, 5, 30, .6); overflow: hidden; } .bn { text-align: right; color: rgba(255, 244, 222, .7); font-variant-numeric: tabular-nums; }
.settings { display: grid; gap: 8px; } .set-row { display: flex; align-items: center; justify-content: space-between; gap: 14px; padding: 12px 4px; border-bottom: 1px solid rgba(255, 213, 138, .12); } .set-row small { display: block; color: rgba(255, 244, 222, .6); }
.switch { width: 58px; height: 34px; border-radius: 999px; border: 0; padding: 4px; background: rgba(8, 5, 30, .7); box-shadow: inset 0 0 0 1.5px rgba(255, 213, 138, .35); transition: background .25s; flex: none; }
.switch i { display: block; width: 26px; height: 26px; border-radius: 50%; background: var(--cream); transition: transform .35s var(--spring); }
.switch[aria-checked="true"] { background: var(--amber-600); } .switch[aria-checked="true"] i { transform: translateX(24px); }
@media (max-width: 900px) { .pf-hero { grid-template-columns: 1fr; text-align: center; } .pf-owl { min-height: 280px; } .pf-owl .owl { --s: 280px !important; } .pf-chips { justify-content: center; } .wardrobe { grid-template-columns: 1fr; } .pf-grid { grid-template-columns: 1fr; } .nick-form .logout { justify-self: center; } }

/* ---------- достижения ---------- */
.ach-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); gap: 14px; margin-top: 18px; }
.ach { display: flex; align-items: center; gap: 14px; padding: 14px 16px; border-radius: var(--r-l); background: linear-gradient(160deg, rgba(62, 47, 140, .55), rgba(24, 17, 62, .75)); border: 1px solid var(--line); }
.ach.got { border-color: rgba(255, 213, 138, .55); box-shadow: 0 0 0 1px rgba(255, 213, 138, .15), 0 10px 28px rgba(0, 0, 0, .35); }
.ach-medal { flex: none; width: 84px; height: 94px; display: grid; place-items: center; }
.medal { filter: drop-shadow(0 6px 8px rgba(0, 0, 0, .45)); transition: transform .4s var(--spring); } .ach.got:hover .medal { transform: scale(1.1) rotate(-6deg); }
.medal.locked { filter: grayscale(1) brightness(.55) contrast(.9); opacity: .75; }
.ach-t { display: grid; gap: 1px; } .ach-t strong { font-weight: 900; } .ach-t span { font-size: .9rem; color: rgba(255, 244, 222, .78); } .ach-t small { color: rgba(255, 244, 222, .5); }

/* ---------- альбом ---------- */
.grid.album { grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); margin-top: 14px; }
.card.alb { flex-direction: column; gap: 8px; --acc: var(--amber); }
.alb-q { font-family: var(--font-script); font-size: 1.25rem; line-height: 1.3; color: var(--amber-200); display: -webkit-box; -webkit-line-clamp: 5; -webkit-box-orient: vertical; overflow: hidden; white-space: pre-line; } .alb-big { font: 2rem/1.2 var(--font-body); }
.alb-a { font-size: 1.1rem; } .alb-a b { color: var(--amber); font-weight: 900; } .alb-w { font-size: .88rem; color: rgba(255, 244, 222, .7); }
.chips { display: flex; flex-wrap: wrap; gap: 8px; margin: 12px 0; justify-content: center; }
.chip-n { min-height: 40px; padding: 4px 16px; border-radius: 999px; border: 1.5px solid rgba(255, 213, 138, .3); background: rgba(255, 244, 222, .06); font-weight: 800; }
.chip-n[aria-pressed="true"] { background: var(--amber); color: var(--ink); border-color: var(--amber); }

/* ---------- лидеры ---------- */
.lb { list-style: none; margin: 18px auto 0; padding: 0; max-width: 760px; display: grid; gap: 8px; }
.lb li { display: grid; grid-template-columns: 52px 1fr auto auto; align-items: center; gap: 12px; padding: 12px 18px; border-radius: var(--r-m); background: rgba(27, 20, 70, .7); border: 1px solid var(--line); }
.lb li:nth-child(-n+3) { background: linear-gradient(90deg, rgba(255, 184, 77, .22), rgba(27, 20, 70, .7)); border-color: rgba(255, 213, 138, .5); }
.lb li.you { outline: 2px solid var(--amber); box-shadow: var(--glow); }
.rk { font: 700 1.3rem var(--font-num); text-align: center; } .nm { font-weight: 800; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; } .nm em { color: var(--amber-300); font-style: normal; font-weight: 700; } .lv { color: rgba(255, 244, 222, .6); font-size: .86rem; } .sc { color: var(--amber-300); font-family: var(--font-num); white-space: nowrap; }
.lb-me { text-align: center; margin-top: 14px; color: var(--amber-200); font-weight: 800; }
@media (max-width: 520px) { .lb li { grid-template-columns: 40px 1fr auto; } .lv { display: none; } }
