/* The cat shop's web page: the app's pinks (desktop/ui/style.css) */
:root {
    --blush: #F8D1D4; --light-pink: #F1A3B5; --pink: #E76A8C; --deep-rose: #C63963;
    --crimson: #A12A4E; --dark-crimson: #8B1C3E; --deep-crimson: #6A0E2D;
    --stage: #2b2838;   /* behind previews, like a dark stream */
}
* { box-sizing: border-box; }
[hidden] { display: none !important; }
html { scroll-behavior: smooth; scroll-padding-top: 70px; }
body {
    margin: 0; background: var(--deep-crimson); color: var(--blush);
    font: 15px/1.5 "Segoe UI", system-ui, sans-serif;
}
a { color: #fff; }
code { background: rgba(0, 0, 0, 0.25); border-radius: 4px; padding: 1px 5px; color: #fff; }
.dim { color: var(--light-pink); }

.top { display: flex; align-items: center; gap: 18px; max-width: 1100px; margin: 0 auto; padding: 28px 20px 12px; }
.top .logo { width: 84px; height: 84px; flex: none; }
.top h1 { margin: 0; font-family: 'DynaPuff', cursive; font-size: 34px; color: #fff; text-shadow: 0 2px 0 var(--crimson); }
.top p { margin: 4px 0 0; max-width: 760px; }

.bar {
    position: sticky; top: 0; z-index: 5; background: var(--dark-crimson); border-bottom: 1px solid var(--deep-rose);
    display: flex; flex-wrap: wrap; align-items: center; gap: 8px 14px; padding: 10px max(20px, calc(50% - 530px));
}
.bar nav { display: flex; flex-wrap: wrap; gap: 4px 12px; flex: 1; }
.bar nav a { text-decoration: none; color: var(--blush); font-weight: 600; font-size: 14px; }
.bar nav a:hover { color: #fff; text-decoration: underline; }
.bar input { width: 220px; padding: 6px 10px; border-radius: 8px; border: 1px solid var(--deep-rose); background: var(--deep-crimson); color: #fff; font: inherit; }

main { max-width: 1100px; margin: 0 auto; padding: 8px 20px 30px; }
section h2 { font-family: 'DynaPuff', cursive; color: #fff; margin: 26px 0 2px; }
section > p { margin: 0 0 12px; }
.closed { background: var(--crimson); border-radius: 10px; padding: 10px 14px; font-weight: 600; }

.grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(230px, 1fr)); gap: 12px; }
section .group h3 { margin: 14px 0 8px; font-size: 15px; color: var(--light-pink); font-weight: 600; }
.grid.swatches { grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 8px; }
/* colours come in dozens: smaller cards */
.swatches .card .preview { min-height: 0; padding: 8px; }
.swatches .card .info { padding: 6px 10px 8px; gap: 2px; }
.swatches .card .name { font-size: 14px; }
.swatches .swatch { width: 40px; height: 40px; }
.card { display: flex; flex-direction: column; background: var(--dark-crimson); border: 1px solid var(--crimson); border-radius: 12px; overflow: hidden; }
.card .preview { display: flex; align-items: center; justify-content: center; min-height: 110px; background: var(--stage); padding: 10px; }
.card .info { display: flex; flex-direction: column; gap: 4px; padding: 10px 12px 12px; flex: 1; }
.card .name { color: #fff; font-size: 16px; }
.card .desc { color: var(--light-pink); font-size: 13px; }
.card .terms { display: flex; justify-content: space-between; gap: 8px; font-size: 13px; margin-top: auto; padding-top: 4px; }
.card .level { background: var(--crimson); border-radius: 999px; padding: 0 9px; }
.card .price { font-weight: 700; color: #fff; }
.card .buy {
    margin-top: 6px; padding: 5px 10px; border: 0; border-radius: 8px; cursor: pointer;
    background: #fff; color: var(--deep-crimson); font: 600 13px ui-monospace, Consolas, monospace; text-align: left;
    overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
}
.card .buy:hover { background: var(--blush); }

.item-img { max-width: 130px; max-height: 90px; }
.swatch { width: 64px; height: 64px; border-radius: 50%; border: 3px solid rgba(255, 255, 255, 0.85); box-shadow: 0 2px 8px rgba(0, 0, 0, 0.4); }
.big-emoji { font-size: 40px; }

/* a name tag, as on stream (name-tags.css does the looks) */
.tag-preview .cat-name {
    position: relative; display: inline-block;
    font-family: 'DynaPuff', cursive; font-size: calc(19px * var(--name-size, 1)); font-weight: 600; letter-spacing: 0.3px; white-space: nowrap;
    text-shadow: -2px -2px 0 #000, 2px -2px 0 #000, -2px 2px 0 #000, 2px 2px 0 #000;
}
.tag-preview .cat-name .tag-badge img { height: 1.4em; width: auto; vertical-align: -0.35em; }

/* cats, with sizes and cat effects (rough: the overlay draws the real ones) */
.catfx { position: relative; width: 120px; height: 96px; display: flex; align-items: flex-end; justify-content: center; }
.catfx img { width: 84px; height: 84px; margin-bottom: 6px; }
.catfx img.cat-size { width: auto; margin-bottom: 0; }
.catfx-glow img { filter: drop-shadow(0 0 calc(3px * var(--catfx-glow, 1)) #E76A8C) drop-shadow(0 0 calc(6px * var(--catfx-glow, 1)) #E76A8C); }
.catfx-aura img { animation: catfx-aura 3s linear infinite; }
@keyframes catfx-aura {
    0%, 100% { filter: drop-shadow(0 0 calc(4px * var(--catfx-aura, 1)) #ff3b3b); }
    33%      { filter: drop-shadow(0 0 calc(4px * var(--catfx-aura, 1)) #4dff88); }
    66%      { filter: drop-shadow(0 0 calc(4px * var(--catfx-aura, 1)) #6b6bff); }
}
.catfx-smoke img { filter: drop-shadow(0 0 calc(3px * var(--catfx-smoke, 1)) rgba(10, 4, 16, 0.9)) drop-shadow(0 0 calc(6px * var(--catfx-smoke, 1)) rgba(10, 4, 16, 0.8)); }
.catfx .catfx-tendril {
    position: absolute; width: 7px; border-radius: 50% 50% 40% 40%;
    background: linear-gradient(to top, rgba(8, 4, 14, 0.95), rgba(14, 7, 22, 0.6) 55%, rgba(20, 10, 30, 0));
    filter: blur(1.2px); transform-origin: 50% 100%; translate: -50% -100%;
    opacity: calc(0.55 + 0.25 * var(--catfx-smoke, 1));
    animation: catfx-tendril 2.6s ease-in-out infinite alternate;
}
@keyframes catfx-tendril {
    0%   { transform: rotate(calc(var(--lean) - 10deg)) scaleY(0.85) skewX(-8deg); }
    100% { transform: rotate(calc(var(--lean) + 10deg)) scaleY(1.1) skewX(8deg); }
}
.catfx .catfx-star { position: absolute; color: #fff6a8; font-size: 12px; text-shadow: 0 0 4px #fff; animation: tag-twinkle 1.6s ease-in-out infinite; }
.catfx-glitter {
    position: absolute; width: 84px; height: 84px; left: 18px; bottom: 6px; pointer-events: none;
    -webkit-mask-size: 100% 100%; mask-size: 100% 100%;
    background-image:
        radial-gradient(circle, #ffffff 0 0.8px, transparent 1.3px),
        radial-gradient(circle, #ffd973 0 0.8px, transparent 1.3px),
        radial-gradient(circle, #ff9edb 0 0.8px, transparent 1.3px);
    background-size: 5px 4px, 7px 6px, 9px 7px;
    background-position: 0 0, 3px 2px, 1px 4px;
    opacity: calc(0.2 + 0.2 * var(--catfx-sparkle, 1));
    animation: catfx-glitter 0.6s steps(2) infinite;
}
@keyframes catfx-glitter { 0%, 100% { background-position: 0 0, 3px 2px, 1px 4px; } 50% { background-position: 2px 1px, 0 4px, 4px 1px; } }
.catfx .catfx-dust { position: absolute; width: 3px; height: 3px; border-radius: 50%; opacity: 0; animation: catfx-dust 2s ease-out infinite; }
@keyframes catfx-dust {
    0%   { opacity: 0; transform: translateY(0); }
    20%  { opacity: 1; }
    100% { opacity: 0; transform: translateY(-34px); }
}

footer { max-width: 1100px; margin: 0 auto; padding: 0 20px 30px; color: var(--light-pink); font-size: 13px; }
#toast {
    position: fixed; left: 50%; bottom: 24px; translate: -50% 0; z-index: 10;
    background: #fff; color: var(--deep-crimson); font-weight: 600; padding: 8px 16px; border-radius: 10px; box-shadow: 0 4px 16px rgba(0, 0, 0, 0.4);
}

@media (max-width: 600px) {
    .top { padding-top: 18px; }
    .top .logo { width: 56px; height: 56px; }
    .top h1 { font-size: 26px; }
    .bar { position: static; }   /* a sticky bar would fill a phone screen */
    .bar input { width: 100%; }
}
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }

/* colour cards are narrow: long "!buy dark crimson" wraps instead of being cut off */
.swatches .card .buy { white-space: normal; overflow-wrap: anywhere; font-size: 12px; }
