/* bimbooo, a small, warm place for text.
   One display face does the talking; everything else stays quiet.
   No JavaScript in this service, so nothing here waits on a script. */

@font-face {
  font-family: "Fredoka";
  src: url("/static/fonts/fredoka.woff2") format("woff2");
  font-weight: 400 600;
  font-display: swap;
}

:root {
  /* The warm cream the whole page sits on. Surfaces (--paper) and panels stay
     lighter so they lift off it, which is what gives the rooms their depth. */
  --ground: #f8efd6;
  --paper: #fffdf6;
  --cream: #fbf3dd;
  --ink: #2b2422;
  --ink-soft: #7a6f66;

  --pink: #f4a9d4;
  --pink-deep: #db6db3;

  /* omg.lol-style pastels, used on the cards, the roster, section chips */
  --butter: #ffe6a1;
  --sky: #c7e6f2;
  --mint: #cdead0;
  --lilac: #e6d9f6;

  /* raised surface for the section panels */
  --panel: #ffffff;
  --line: #f0e8d4;

  /* button tints, chosen by meaning: go/approve, warn/take-down, tool/neutral.
     Each keeps ink text, which clears WCAG AA against these mid tones. */
  --go: #6fca97;
  --go-deep: #4fae78;
  --warn-btn: #ef9a7d;
  --warn-deep: #dd7351;
  --tool: #8ecfe8;
  --tool-deep: #6db8db;

  --soft: 0 2px 14px rgba(43, 36, 34, .07);
  --pop: 3px 3px 0 rgba(43, 36, 34, .14);

  --display: "Fredoka", "Segoe UI Rounded", ui-rounded, "Varela Round", system-ui, sans-serif;
  --body: "Segoe UI", system-ui, -apple-system, "Helvetica Neue", Arial, sans-serif;
  --mono: ui-monospace, "Cascadia Mono", "SFMono-Regular", Menlo, Consolas, monospace;
}

* { box-sizing: border-box; }

body {
  margin: 0;
  background: var(--ground);
  color: var(--ink);
  font: 400 16px/1.6 var(--body);
  -webkit-font-smoothing: antialiased;
}

a { color: var(--pink-deep); text-underline-offset: 3px; text-decoration-thickness: 1.5px; }
a:hover { color: var(--ink); }

code { font-family: var(--mono); font-size: .92em; background: var(--cream); padding: .1em .35em; border-radius: 5px; }

/* ---- top bar ---- */

.bar {
  display: flex; align-items: center; justify-content: flex-end;
  gap: 1rem; flex-wrap: wrap;
  padding: 1.1rem clamp(1rem, 5vw, 3rem);
}

.brand {
  display: inline-flex; align-items: center; gap: .5rem;
  font: 600 1.5rem/1 var(--display); color: var(--ink); text-decoration: none; letter-spacing: -.01em;
}
.brand:hover { color: var(--pink-deep); }
.brand img { display: block; }

.bar nav { display: flex; align-items: center; gap: 1.3rem; }
.bar nav a, .bar nav .link {
  font: 500 1rem/1 var(--display); color: var(--ink-soft); text-decoration: none;
}
.bar nav a:hover, .bar nav .link:hover { color: var(--pink-deep); }

.pip {
  display: inline-block; min-width: 1.35em; padding: .05em .35em; margin-left: .1em;
  background: var(--pink-deep); color: #fff; border-radius: 999px;
  font: 600 .72rem/1.5 var(--display); text-align: center;
}

main { padding: clamp(1rem, 4vw, 2.5rem) clamp(1rem, 5vw, 3rem) 4rem; max-width: 60rem; margin: 0 auto; width: 100%; }

footer {
  padding: 2rem 1rem 3rem; text-align: center;
  color: var(--ink-soft); font-size: .82rem;
}
footer p { margin: .2rem 0; }
footer .by { font-size: .72rem; opacity: .7; }

/* ---- type scale ---- */

h1, h2, h3 { font-family: var(--display); font-weight: 600; line-height: 1.12; letter-spacing: -.015em; margin: 0; }
h1 { font-size: clamp(2rem, 5vw, 2.9rem); color: var(--pink-deep); }
h2 { font-size: 1.35rem; margin: 2.4rem 0 .9rem; }
h3 { font-size: 1.1rem; }

.lede { font-size: 1.1rem; line-height: 1.55; color: var(--ink-soft); max-width: 42ch; margin: .7rem 0 0; }
.small { font-size: .85rem; color: var(--ink-soft); }
.hint { font-size: .8rem; color: var(--ink-soft); margin: .3rem 0 0; }
.tiny { font-size: .78rem; color: var(--ink-soft); font-weight: 400; }
a.tiny { color: var(--ink-soft); }
a.tiny:hover { color: var(--pink-deep); }
.totals { margin: .45rem 0 0; }

/* ---- landing ---- */

.hero { display: flex; gap: clamp(1.5rem, 5vw, 3.5rem); align-items: center; flex-wrap: wrap; padding: 1.5rem 0 1rem; }
.hero > div { flex: 1 1 20rem; }
.mascot { flex: none; filter: drop-shadow(0 6px 14px rgba(219, 109, 179, .22)); }
.hero h1 { font-size: clamp(2.4rem, 7vw, 3.6rem); }
.hero h1 em { font-style: normal; background: var(--butter); border-radius: 7px; padding: 0 .14em; }
.hero .lede { font-size: 1.2rem; max-width: 34ch; }

/* the elephant and its bubble are one figure, so the tail points down at it */
.hero-figure { flex: none; display: flex; flex-direction: column; align-items: center; gap: .1rem; }
.hero-figure .mascot { margin: 0; }
.hero-figure .says { margin: 0; }
.hero-figure .says::before {
  left: 50%; top: auto; bottom: -8px; transform: translateX(-50%);
  border: 8px solid transparent; border-bottom: 0; border-top-color: var(--sky); border-right-color: transparent;
}

.three { display: grid; gap: 1rem; margin-top: 3rem; grid-template-columns: repeat(auto-fit, minmax(14rem, 1fr)); }
.three article { border-radius: 20px; padding: 1.4rem 1.5rem; box-shadow: var(--soft); }
.three article:nth-child(1) { background: var(--butter); }
.three article:nth-child(2) { background: var(--pink); }
.three article:nth-child(3) { background: var(--sky); }
.three h2 { margin: 0 0 .4rem; font-size: 1.15rem; color: var(--ink); display: flex; align-items: center; gap: .45rem; }
.three h2 .ico { width: 18px; height: 18px; opacity: .85; }
.three p { margin: 0; font-size: .92rem; line-height: 1.5; color: #4a4038; }
.three code { background: rgba(255, 255, 255, .5); }

/* ---- buttons ---- */

button, .button {
  display: inline-block; cursor: pointer; font: 600 1rem/1 var(--display);
  padding: .75rem 1.4rem; color: var(--ink); background: var(--pink);
  border: none; border-radius: 999px; box-shadow: var(--pop); text-decoration: none;
  transition: transform .1s ease, box-shadow .1s ease, background .1s ease;
}
button:hover, .button:hover { background: var(--pink-deep); color: #fff; }
button:active, .button:active { transform: translate(2px, 2px); box-shadow: 1px 1px 0 rgba(43, 36, 34, .14); }

.button.quiet, button.quiet { background: var(--cream); box-shadow: none; }
.button.quiet:hover, button.quiet:hover { background: #f0e6c8; color: var(--ink); }

/* colour by meaning, not decoration: approve, take down, neutral tool */
.button.go, button.go { background: var(--go); }
.button.go:hover, button.go:hover { background: var(--go-deep); color: var(--ink); }
.button.warn, button.warn { background: var(--warn-btn); }
.button.warn:hover, button.warn:hover { background: var(--warn-deep); color: #fff; }
.button.tool, button.tool { background: var(--tool); }
.button.tool:hover, button.tool:hover { background: var(--tool-deep); color: var(--ink); }

:focus-visible { outline: 3px solid var(--pink-deep); outline-offset: 2px; }

.link { background: none; border: none; box-shadow: none; padding: 0; color: var(--pink-deep); text-decoration: underline; font: 500 .92rem/1 var(--display); cursor: pointer; }
.link:hover { color: var(--ink); }
.link.warn { color: #c2603f; }

.actions { display: flex; gap: .7rem; flex-wrap: wrap; margin: 1.6rem 0 .4rem; }
.buttons { display: flex; gap: .7rem; flex-wrap: wrap; align-items: center; margin-top: 1.4rem; }

/* ---- forms, kept plain ---- */

.narrow { max-width: 30rem; margin: 0 auto; }
.middle { text-align: center; }
.middle .lede, .middle .actions { margin-inline: auto; justify-content: center; }
.middle .mascot { margin: 0 auto 1rem; }

.stack { display: flex; flex-direction: column; margin: 1.6rem 0 2rem; }
.stack label { font: 500 .95rem/1.4 var(--display); margin: 1rem 0 .35rem; }
.stack > button { align-self: start; margin-top: 1.4rem; }

input, select, textarea {
  font: 400 1rem/1.5 var(--body); padding: .7rem .85rem; width: 100%;
  color: var(--ink); background: var(--paper);
  border: 1.5px solid #e7ddc4; border-radius: 12px;
}
input:hover, select:hover, textarea:hover { border-color: var(--pink); }
input:focus, select:focus, textarea:focus { outline: none; border-color: var(--pink-deep); box-shadow: 0 0 0 3px rgba(244, 169, 212, .3); }
textarea { resize: vertical; font-family: var(--mono); font-size: .92rem; line-height: 1.55; }
select { cursor: pointer; }

.row { display: flex; gap: 1rem; flex-wrap: wrap; }
.row > div { flex: 1 1 12rem; }

.trap { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }

.note, .problem {
  border-radius: 14px; padding: .8rem 1.1rem; margin: 0 0 1.4rem; font-size: .95rem;
}
.note { background: var(--mint); }
.problem { background: #fbdcd0; }

/* ---- the keeper: an elephant with something to say ---- */

.keeper { display: flex; align-items: center; gap: .9rem; margin: .4rem 0 1.6rem; }
.keeper-face { flex: none; filter: drop-shadow(0 4px 10px rgba(219, 109, 179, .2)); }
.says {
  position: relative; margin: 0; background: var(--sky);
  padding: .7rem 1.1rem; border-radius: 16px; box-shadow: var(--soft);
  font: 500 1.05rem/1.4 var(--display); color: var(--ink);
}
.says::before {
  content: ""; position: absolute; left: -8px; top: 50%; transform: translateY(-50%);
  border: 8px solid transparent; border-left: 0; border-right-color: var(--sky);
}
@media (max-width: 32rem) {
  .keeper { flex-direction: column; align-items: flex-start; gap: .6rem; }
  .says::before { left: 1.4rem; top: -7px; transform: none;
    border: 7px solid transparent; border-top: 0; border-bottom-color: var(--sky); }
}

/* ---- section panels: little rooms ---- */

.panel {
  background: var(--panel); border-radius: 18px; padding: 1.2rem 1.4rem;
  box-shadow: var(--soft); margin: 1.1rem 0;
}
.panel-head { display: flex; align-items: center; gap: .6rem; margin: 0 0 1rem; }
.panel-head h2 { margin: 0; font-size: 1.15rem; }
.panel-head .pip { margin-left: .1rem; }
.ico-chip {
  flex: none; display: inline-flex; align-items: center; justify-content: center;
  width: 2rem; height: 2rem; border-radius: 10px; color: var(--ink);
}
.ico-chip.c-butter { background: var(--butter); }
.ico-chip.c-sky { background: var(--sky); }
.ico-chip.c-mint { background: var(--mint); }
.ico-chip.c-pink { background: var(--pink); }
.ico-chip.c-lilac { background: var(--lilac); }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { transition: none !important; }
}

/* ---- the desk ---- */

.desk { display: flex; gap: 1rem; align-items: center; justify-content: space-between; flex-wrap: wrap; margin-bottom: .4rem; }
.desk-head h1 { margin-bottom: .15rem; }

.shelf { display: flex; align-items: center; gap: .7rem; font-size: .8rem; color: var(--ink-soft); margin: 1.4rem 0 2rem; }
.gauge { flex: 1; max-width: 14rem; height: 8px; background: var(--cream); border-radius: 999px; overflow: hidden; }
.fill { display: block; width: 0; height: 100%; background: var(--pink); border-radius: 999px; }
.fill.p0{width:0}.fill.p5{width:5%}.fill.p10{width:10%}.fill.p15{width:15%}.fill.p20{width:20%}
.fill.p25{width:25%}.fill.p30{width:30%}.fill.p35{width:35%}.fill.p40{width:40%}.fill.p45{width:45%}
.fill.p50{width:50%}.fill.p55{width:55%}.fill.p60{width:60%}.fill.p65{width:65%}.fill.p70{width:70%}
.fill.p75{width:75%}.fill.p80{width:80%}.fill.p85{width:85%}.fill.p90{width:90%}.fill.p95{width:95%}.fill.p100{width:100%}

.things { list-style: none; padding: 0; margin: 0; display: flex; flex-direction: column; gap: .5rem; }
.things li {
  display: flex; align-items: baseline; gap: .7rem; flex-wrap: wrap;
  padding: .85rem 1rem; border-radius: 14px; background: var(--paper); box-shadow: var(--soft);
}
.things li:hover { background: #fffef9; }
.thing-name { font: 600 1.05rem/1.3 var(--display); text-decoration: none; letter-spacing: -.01em; }
.thing-title { color: var(--ink-soft); font-size: .9rem; }
.thing-meta { margin-left: auto; font-size: .78rem; color: var(--ink-soft); white-space: nowrap; }

.tag { font: 500 .72rem/1 var(--display); padding: .32em .6em; border-radius: 999px; background: var(--cream); color: #6a5f4e; }
.tag.k-code { background: var(--sky); }
.tag.k-markdown { background: var(--mint); }
.tag.k-html { background: var(--pink); }
.tag.k-raw { background: var(--butter); }
.tag.burn, .tag.s-suspended, .tag.s-rejected { background: #fbdcd0; }
.tag.s-pending { background: var(--butter); }
.tag.s-active { background: var(--mint); }

.empty { text-align: center; padding: 3rem 1rem; color: var(--ink-soft); }
.empty .mascot { margin: 0 auto 1rem; opacity: .95; }

/* ---- editor: two fields and a row of small choices ---- */

.editor-head { margin-bottom: 1.2rem; }
.editor .live { font-size: .85rem; color: var(--ink-soft); margin-top: .35rem; }
.copylink { font: inherit; background: none; border: none; padding: 0; color: var(--pink-deep);
  text-decoration: underline; text-underline-offset: 3px; text-decoration-thickness: 1.5px; cursor: pointer; }
.copylink:hover { color: var(--ink); }
.copylink.copied { color: var(--go-deep); text-decoration: none; }
/* choices are pill toggles, not native selects: cosier, and no OS dropdown
   that ignores the theme. Radios and one checkbox, styled entirely in CSS. */
.picks { display: grid; grid-template-columns: max-content 1fr; gap: .8rem .9rem; align-items: center; margin: 1.4rem 0 0; }
.pick { display: contents; }
.pick-label { font: 500 .85rem/1 var(--display); color: var(--ink-soft); }
.segmented { display: inline-flex; flex-wrap: wrap; gap: .4rem; }
.pick label { display: inline-flex; margin: 0; cursor: pointer; }
.pick input { position: absolute; width: 1px; height: 1px; opacity: 0; }
.seg {
  padding: .5rem .95rem; border-radius: 999px; background: var(--cream);
  color: var(--ink-soft); font: 500 .9rem/1 var(--display); white-space: nowrap;
  transition: background .1s ease, color .1s ease;
}
.pick label:hover .seg { color: var(--ink); }
.pick input:checked + .seg { color: var(--ink); box-shadow: var(--pop); font-weight: 600; }
.pick input:checked + .pinkable { background: var(--pink); }
.pick input:focus-visible + .seg { outline: 3px solid var(--pink-deep); outline-offset: 2px; }

/* the kind row: each type its own cosy colour, soft until it is the chosen one */
.kinds .seg { color: var(--ink); opacity: .5; transition: opacity .1s ease; }
.kinds .k-code { background: var(--sky); }
.kinds .k-markdown { background: var(--mint); }
.kinds .k-html { background: var(--pink); }
.kinds .k-raw { background: var(--butter); }
.kinds input:checked + .seg { opacity: 1; }
.previous { margin-top: 2rem; }
.previous p { margin: 0 0 .3rem; }
.danger { margin-top: 1.5rem; }

/* ---- front desk ---- */

.door { border-radius: 16px; padding: 1rem 1.3rem; background: var(--cream); margin-bottom: 1rem; }
.door p { margin: 0 0 .7rem; }

.request { border-radius: 16px; padding: 1.2rem 1.4rem; background: var(--paper); box-shadow: var(--soft); margin-bottom: .9rem; }
.request dl { margin: .8rem 0 1rem; }
.request dt { font: 500 .82rem/1.5 var(--display); color: var(--ink-soft); margin-top: .5rem; }
.request dd { margin: 0; }

/* the admin search bars and their pagers */
.search { display: flex; gap: .5rem; flex-wrap: wrap; align-items: center; margin: 0 0 1.1rem; }
.search input { width: auto; flex: 0 1 13rem; padding: .5rem .7rem; }
.search .segmented { gap: .3rem; }
.search .seg { padding: .45rem .8rem; font-size: .85rem; }
.search button { padding: .5rem 1rem; }
.pager { display: flex; gap: 1.2rem; margin: 1rem 0 0; }
.pager a { font: 500 .9rem/1 var(--display); }

table { width: 100%; border-collapse: collapse; font-size: .88rem; }
th { text-align: left; font: 500 .78rem/1.5 var(--display); color: var(--ink-soft); padding: .4rem .6rem; }
td { padding: .55rem .6rem; border-top: 1px solid #f0e8d4; vertical-align: middle; }
.row-actions { display: flex; gap: .7rem; align-items: center; flex-wrap: wrap; }
.row-actions input { width: 3.6rem; padding: .25rem .4rem; font-size: .8rem; }
/* A megabyte count fits in four characters. Words do not. */
.row-actions input.wide { width: 9rem; }
.inline { display: inline-flex; gap: .35rem; align-items: center; }

.trail { list-style: none; padding: 0; font-size: .85rem; }
.trail li { padding: .35rem 0; border-top: 1px solid #f0e8d4; color: var(--ink-soft); }
.trail .when { display: inline-block; min-width: 6.5rem; }

@media (max-width: 32rem) {
  .thing-meta { margin-left: 0; width: 100%; }
}
