/* Rank the World: shared styles.
   White surfaces, near-black ink and one accent (Rausch), after the Airbnb
   design guide the product follows. The page behind them is space: dark,
   with stars. Controls and cards are white and float on it. */

:root{
  --rausch:#FF385C;--rausch-press:#E00B41;--rausch-soft:#FFEEF1;--rausch-off:#FFD1DA;
  --rausch-fill:linear-gradient(90deg,#E61E4D 0%,#E31C5F 50%,#D70466 100%);
  --canvas:#FFFFFF;--soft:#F7F7F7;--strong:#F2F2F2;--card:#FFFFFF;
  --ink:#222222;--body:#3F3F3F;--muted:#6A6A6A;--muted-2:#929292;
  --hair:#DDDDDD;--hair-soft:#EBEBEB;--line-strong:#C1C1C1;
  --bad:#C13515;--bad-line:#F0C9C0;--up:#008A05;--down:#C13515;
  --shadow:0 0 0 1px rgba(0,0,0,.02),0 2px 6px rgba(0,0,0,.04),0 4px 8px rgba(0,0,0,.1);
  --float:0 0 0 1px rgba(0,0,0,.04),0 8px 28px rgba(0,0,0,.18);
  --r-sm:8px;--r-md:14px;--r-lg:20px;--r-xl:32px;
  --ease:cubic-bezier(.2,.7,.2,1);--spring:cubic-bezier(.3,1.4,.5,1);
  --font:"DM Sans",-apple-system,BlinkMacSystemFont,system-ui,"Segoe UI",Roboto,"Helvetica Neue",sans-serif;
  --emoji:"Apple Color Emoji","Segoe UI Emoji","Noto Color Emoji",sans-serif;
  color-scheme:light;
  box-sizing:border-box;
}
*,*::before,*::after{box-sizing:inherit}
html{-webkit-text-size-adjust:100%;overflow-x:clip;background:var(--canvas)}
body{margin:0;background:var(--canvas);color:var(--body);font:400 16px/1.5 var(--font);-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale;overflow-x:clip}
h1,h2,h3,p{margin:0}
h1,h2,h3{color:var(--ink)}
button,input,select{font:inherit;color:inherit}
a{color:inherit}
[hidden]{display:none!important}
:focus-visible{outline:2px solid var(--ink);outline-offset:3px;border-radius:8px}
.wrap{width:100%;max-width:1240px;margin:0 auto;padding:0 clamp(20px,4vw,48px)}
.sr{position:absolute!important;width:1px;height:1px;padding:0;margin:-1px;overflow:hidden;clip:rect(0,0,0,0);white-space:nowrap;border:0}
.ic{width:20px;height:20px;fill:none;stroke:currentColor;stroke-width:1.7;stroke-linecap:round;stroke-linejoin:round;flex:none}
.logo{display:block;fill:currentColor}

/* A pick's category, as a small picture on a tinted square. */
.av{flex:none;display:grid;place-items:center;width:44px;height:44px;border-radius:12px;background:var(--strong);font:400 22px/1 var(--emoji)}
.av[data-cat="Food"]{background:#FFF1E3}
.av[data-cat="Games"]{background:#EFEBFF}
.av[data-cat="Songs"]{background:#FFE9F1}
.av[data-cat="Places"]{background:#E5F6EA}
.av[data-cat="Ideas"]{background:#FFF6D2}

/* brand */
.brand{display:inline-flex;align-items:center;gap:10px;text-decoration:none;color:var(--ink);flex:none}
.brand .logo{width:26px;height:34px;color:var(--rausch);transition:transform .5s var(--spring)}
.brand:hover .logo{transform:rotate(-8deg) scale(1.06)}
.brand-t{display:inline-flex;flex-direction:column;align-items:flex-start;white-space:nowrap;font:700 19px/.92 var(--font);letter-spacing:-.035em}
.wm-line{display:inline-flex;align-items:baseline;gap:.2em}
.wm-line:last-child{gap:.08em}
.wm-a{color:var(--ink)}
.wm-b{font-size:.74em;font-weight:500;font-style:italic;letter-spacing:-.01em;color:var(--muted)}
.wm-c{font-size:1.31em;color:var(--ink)}
.wm-s{width:.42em;height:.42em;fill:var(--rausch);align-self:flex-start;margin:.05em 0 0;transition:transform .7s var(--spring)}
.brand:hover .wm-s{transform:rotate(90deg) scale(1.25)}

/* buttons */
.btn{position:relative;display:inline-flex;align-items:center;justify-content:center;gap:8px;height:48px;padding:0 24px;border-radius:var(--r-sm);border:1px solid transparent;font:500 16px/1 var(--font);text-decoration:none;cursor:pointer;white-space:nowrap;transition:background .2s,border-color .2s,color .2s,transform .2s var(--ease)}
.btn:active{transform:scale(.97)}
.btn-main{background:var(--rausch);color:#fff}
.btn-main:hover{background:var(--rausch-press)}
.btn-ink{background:var(--ink);color:#fff}
.btn-ink:hover{background:#000}
.btn-line{background:var(--card);color:var(--ink);border-color:var(--ink)}
.btn-line:hover{background:var(--soft)}
.btn-bad{background:#fff;color:var(--bad);border-color:var(--bad-line)}
.btn-bad:hover{border-color:var(--bad)}
.btn-sm{height:40px;padding:0 16px;font-size:14px}
.btn[disabled]{background:var(--strong);border-color:transparent;color:var(--muted-2);cursor:not-allowed}
.btn-main[disabled]{background:var(--rausch-off);color:#fff}
.btn[disabled]:active{transform:none}
.w100{width:100%}
.tlink{background:none;border:0;padding:0;font:600 14px/1.4 var(--font);color:var(--ink);text-decoration:underline;text-underline-offset:3px;cursor:pointer}
.tlink:hover{color:#000}

/* fields */
.input,.sel{width:100%;min-width:0;height:48px;padding:0 14px;border:1px solid var(--line-strong);border-radius:var(--r-sm);background:#fff;font:400 16px/1 var(--font);color:var(--ink);transition:border-color .2s,box-shadow .2s}
.sel{font-weight:500;cursor:pointer}
.input:focus,.sel:focus{outline:none;border-color:var(--ink);box-shadow:inset 0 0 0 1px var(--ink)}
.input::placeholder{color:var(--muted-2)}
.msg{margin:10px 0 0;min-height:1.4em;font:400 14px/1.4 var(--font);color:var(--muted)}
.msg.err{color:var(--bad)}

.badge{display:inline-flex;align-items:center;height:20px;padding:0 8px;border-radius:999px;background:var(--strong);font:600 11px/1 var(--font);color:var(--body);white-space:nowrap}
.badge.mine{background:var(--ink);color:#fff}
.badge.backed{background:var(--rausch-soft);color:var(--rausch-press)}

/* dialogs */
.dlg{width:min(440px,calc(100vw - 32px));max-height:calc(100dvh - 32px);padding:0;border:0;border-radius:var(--r-xl);background:#fff;color:var(--body);box-shadow:var(--float);overflow:auto}
.dlg::backdrop{background:rgba(0,0,0,.5)}
.dlg[open]{animation:dlgin .35s var(--ease)}
@keyframes dlgin{from{opacity:0;transform:translateY(12px) scale(.98)}}
.dlg-in{position:relative;padding:36px 32px 28px}
.dlg-x{position:absolute;right:14px;top:14px;display:grid;place-items:center;width:32px;height:32px;border:0;border-radius:50%;background:var(--strong);color:var(--ink);cursor:pointer}
.dlg-x:hover{background:var(--hair-soft)}
.dlg-x .ic{width:14px;height:14px;stroke-width:2.2}
.dlg .logo{width:26px;height:34px;color:var(--rausch);margin-bottom:18px}
.dlg h2{font:600 24px/1.2 var(--font);letter-spacing:-.02em;text-wrap:balance;padding-right:28px}
.dlg-sub{margin:10px 0 0;font:400 15.5px/1.5 var(--font);color:var(--muted)}
.dlg-sub b{color:var(--ink);font-weight:600;overflow-wrap:anywhere}
.dlg-form{display:grid;gap:10px;margin:22px 0 0}
.dlg-form .dlg-form{margin:0}
.dlg-fine{margin:6px 0 0;font:400 13px/1.5 var(--font);color:var(--muted-2)}
.dlg-acts{display:flex;flex-wrap:wrap;align-items:center;gap:10px 18px;margin-top:22px}
.gbtn .g{width:18px;height:18px;flex:none}
.or{display:flex;align-items:center;gap:12px;margin:4px 0;font:400 13px/1 var(--font);color:var(--muted-2)}
.or::before,.or::after{content:"";flex:1;height:1px;background:var(--hair)}
.dots{display:flex;gap:6px;margin-bottom:22px}
.dots i{width:22px;height:4px;border-radius:4px;background:var(--hair-soft);transition:background .3s}
.dots i.on{background:var(--ink)}
.facts{list-style:none;margin:20px 0 0;padding:0;display:grid;gap:14px}
.facts li{display:flex;gap:14px;align-items:flex-start;font:400 15px/1.45 var(--font);color:var(--body)}
.facts b{flex:none;display:grid;place-items:center;width:52px;height:36px;border-radius:10px;background:var(--strong);color:var(--ink);font:700 15px/1 var(--font)}
/* The podium at the top of a dialog. Only its lower half is drawn, where the podium stands. */
.dlg-art{display:block;width:min(74%,270px);height:auto;aspect-ratio:1100/470;object-fit:cover;object-position:50% 96%;margin:-10px auto 14px;pointer-events:none;user-select:none}
.dlg-h{margin:22px 0 0;font:600 16px/1.3 var(--font);color:var(--ink)}
.plain{margin:8px 0 0;padding-left:18px;display:grid;gap:7px;font:400 14.5px/1.5 var(--font);color:var(--body)}
.note{margin:16px 0 0;padding:12px 14px;border-radius:var(--r-sm);background:var(--soft);font:400 14px/1.45 var(--font);color:var(--body)}

/* A message. It takes the place of the stepper above the dock, so it never
   covers the dock or the pick at the front. */
.toast{position:fixed;left:50%;bottom:calc(134px + env(safe-area-inset-bottom,0px));z-index:80;display:flex;align-items:center;gap:12px;width:max-content;max-width:min(460px,calc(100vw - 24px));padding:12px 14px 12px 18px;border-radius:22px;background:#fff;box-shadow:0 8px 28px rgba(0,0,0,.4);font:500 14.5px/1.4 var(--font);color:var(--ink);opacity:0;transform:translate(-50%,12px) scale(.97);transition:opacity .25s,transform .45s var(--spring),bottom .3s var(--ease);pointer-events:none}
.toast.show{opacity:1;transform:translate(-50%,0);pointer-events:auto}
.toast span{flex:1;padding:2px 4px 2px 0}
.toast button{flex:none;height:32px;padding:0 14px;border:0;border-radius:999px;background:var(--ink);color:#fff;font:600 13px/1 var(--font);cursor:pointer}

/* confetti for a new first place */
.confetti{position:fixed;inset:0;z-index:90;pointer-events:none;overflow:hidden}
.cf{position:absolute;width:8px;height:8px;border-radius:2px;animation:cf 1.4s cubic-bezier(.15,.7,.35,1) forwards}
.cf.round{border-radius:50%}
.cf.long{width:5px;height:12px}
@keyframes cf{to{transform:translate(var(--dx),var(--dy)) rotate(var(--r));opacity:0}}

@media (max-width:640px){.dlg-in{padding:32px 22px 24px}.dlg h2{font-size:22px}}
@media (prefers-reduced-motion:reduce){*,*::before,*::after{animation-duration:.01ms!important;animation-delay:0ms!important;animation-iteration-count:1!important;transition-duration:.01ms!important}}
