/* garlicoin.org: Block Lotto, the bakery and the miner.
   Loaded after /assets/site.css by the pages that need it (their <head> links it). Split out of site.css on
   2026-10-21: keep a rule here only if just these pages use it; anything shared goes in site.css. */

/* bakery */
.oven-card { display: flex; align-items: center; gap: 28px; }
.oven-window { position: relative; border-radius: 12px; background: #1d150b; overflow: hidden; border: 3px solid #8a7351; }
.oven-glow { position: absolute; inset: 0; background: radial-gradient(ellipse at 50% 100%, rgba(255,140,30,.85), rgba(255,90,0,.15) 60%, transparent 75%); animation: glow 2.4s ease-in-out infinite alternate; }
@keyframes glow { from { opacity: .65; } to { opacity: 1; } }
.oven-loaf { position: absolute; left: 22%; right: 22%; bottom: 14%; height: 34%; border-radius: 50% 50% 18% 18%; background: linear-gradient(#f6c15b, #c47d1a); animation: rise 3s ease-in-out infinite alternate; transform-origin: bottom; }
@keyframes rise { from { transform: scaleY(.85); } to { transform: scaleY(1.05); } }
.oven-dial { display: flex; justify-content: center; }
.oven-ring { --p: 0; width: 26px; height: 26px; border-radius: 50%; background: conic-gradient(var(--gold) calc(var(--p) * 360deg), #6d5a3f 0); box-shadow: inset 0 0 0 5px #3d3122; transition: background .9s linear; }
.oven-text p { margin: 0; }
.oven-height { font-size: 1.15rem; margin-top: 4px !important; }
.oven-timer { font-size: clamp(2rem, 6vw, 2.8rem); font-weight: 800; font-variant-numeric: tabular-nums; line-height: 1.15; }
.oven-timer .muted { font-size: 1rem; font-weight: 600; }
.shelf { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(230px, 1fr)); gap: 12px; }
.loaf-text { display: grid; min-width: 0; font-size: .9rem; color: var(--muted); }
.loaf-height { font-weight: 800; font-size: 1.05rem; color: var(--ink); text-decoration: none; font-variant-numeric: tabular-nums; }
.loaf-height:hover { color: var(--gold-text); text-decoration: underline; }
.loaf-pool { color: var(--ink); font-weight: 600; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.loaf.fresh { animation: fresh 1.2s ease-out; border-color: var(--gold); }
@media (max-width: 640px) {
  .oven-card { gap: 18px; }
  .shelf { grid-template-columns: minmax(0, 1fr); }
}
@media (prefers-reduced-motion: reduce) {
  .oven-glow, .oven-loaf, .loaf.fresh { animation: none; }
}
.shelf { grid-template-columns: repeat(auto-fill, minmax(255px, 1fr)); gap: 10px; }
.loaf-text { font-size: .85rem; line-height: 1.4; }
.loaf-meta, .loaf-when { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.loaf.halving-loaf { outline: 3px solid var(--gold); outline-offset: 2px; border-radius: 12px; }
table.kv { width: 100%; border-collapse: collapse; font-size: .92rem; }
table.kv th { text-align: left; font-weight: 700; color: var(--muted); padding: 7px 14px 7px 0; white-space: nowrap; vertical-align: top; width: 1%; border-top: 1px solid var(--line); }
table.kv td { padding: 7px 0; border-top: 1px solid var(--line); word-break: break-all; }
table.kv tr:first-child th, table.kv tr:first-child td { border-top: 0; }
.field { display: grid; gap: 6px; font-weight: 600; font-size: .9rem; }
.field input:not([type="range"]) { padding: 10px 12px; border: 1px solid var(--line); border-radius: 10px; font: inherit; font-size: 1rem; background: var(--card); color: var(--ink); width: 100%; }
.field input[type="range"] { width: 100%; accent-color: var(--gold-deep); }
.art-feature { display: grid; grid-template-columns: 180px 1fr; gap: 20px; align-items: center; margin-bottom: 16px; }
.art-big { padding: 0; border: 0; background: none; cursor: pointer; border-radius: 22px; width: 180px; }
.art-big:hover .garlic-art { filter: brightness(1.04); }
.art-text p { margin: 0 0 4px; }
.art-name { font-size: 1.35rem; font-weight: 800; }
.art-hash { font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; font-size: .75rem; color: var(--muted); word-break: break-all; margin-top: 8px !important; }
.art-strip { display: grid; grid-template-columns: repeat(auto-fill, minmax(64px, 1fr)); gap: 8px; }
.art-tile { padding: 2px; border: 2px solid transparent; border-radius: 16px; background: none; cursor: pointer; display: grid; gap: 2px; font: inherit; color: var(--muted); font-size: .7rem; font-variant-numeric: tabular-nums; transition: transform .15s; }
.art-tile[aria-pressed="true"] { border-color: var(--gold); }
.art-tile.rare .garlic-art { box-shadow: 0 0 0 2px var(--gold-deep); }
.art-tile:hover { transform: translateY(-2px); }
@media (max-width: 640px) {
  .art-feature { grid-template-columns: 120px 1fr; gap: 14px; }
  .art-big { width: 120px; }
  .art-name { font-size: 1.1rem; }
}
/* garden */
.garden-clock { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 28px; }
.garden-clock p { margin: 0; max-width: 60ch; }
.garden-height { font-size: clamp(1.6rem, 5vw, 2.2rem); font-weight: 800; font-variant-numeric: tabular-nums; }
.plots { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 14px; }
.plot { display: grid; gap: 10px; padding: 14px; border: 1px solid var(--line); border-radius: 16px; background: var(--bg); text-align: center; align-content: start; }
.plot-art svg { width: 100%; max-width: 160px; margin: 0 auto; display: block; }
.plot-art.ready .garlic-art { animation: pop .6s ease-out; }
.plot-text { display: grid; gap: 4px; }
.plot-text strong { font-size: 1.05rem; }
.plot-meter { display: block; height: 8px; border-radius: 999px; background: var(--line); overflow: hidden; margin: 4px auto; width: 100%; }
.plot-meter i { display: block; height: 100%; background: linear-gradient(90deg, #5a9a4a, var(--gold)); border-radius: 999px; transition: width .6s; }
.plot-actions { display: grid; gap: 4px; justify-items: center; }
.plot .btn { justify-self: center; }
.pantry li .garlic-art { width: 56px; flex: none; }
@keyframes pop { from { transform: scale(.85); } to { transform: none; } }
/* miner */
.mine-controls { display: grid; grid-template-columns: 1fr 1.2fr auto; gap: 14px 18px; align-items: end; margin-bottom: 16px; }
.mine-stats { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 10px; margin: 0 0 12px; }
.mine-stats div, .lotto-facts div { background: var(--bg); border: 1px solid var(--line); border-radius: 12px; padding: 10px 12px; min-width: 0; }
.mine-stats dt, .lotto-facts dt { font-size: .72rem; text-transform: uppercase; letter-spacing: .07em; color: var(--muted); font-weight: 800; }
.mine-stats dd, .lotto-facts dd { margin: 2px 0 0; font-weight: 800; font-size: 1.1rem; font-variant-numeric: tabular-nums; overflow-wrap: anywhere; }
.mine-progress { --p: 0; height: 10px; border-radius: 999px; background: var(--line); overflow: hidden; }
.mine-progress i { display: block; height: 100%; width: calc(var(--p) * 100%); background: linear-gradient(90deg, var(--gold), var(--gold-deep)); transition: width .3s; }
.mine-rig.mining .mine-progress i { animation: pulse 1s ease-in-out infinite alternate; }
.mine-hash { font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; font-size: .8rem; word-break: break-all; margin: 10px 0 0; color: var(--ink); background: var(--bg); border: 1px solid var(--line); border-radius: 10px; padding: 8px 10px; }
.found-card { display: grid; grid-template-columns: 200px 1fr; gap: 20px; align-items: center; border-color: var(--gold); background: var(--gold-soft); }
.found-text p { margin: 0 0 8px; }
@media (max-width: 720px) {
  .mine-controls { grid-template-columns: minmax(0, 1fr); }
  .mine-stats { grid-template-columns: 1fr 1fr; }
  .found-card { grid-template-columns: minmax(0, 1fr); }
  .found-art { max-width: 200px; }
}
@media (prefers-reduced-motion: reduce) {
  .mine-rig.mining .mine-progress i, .plot-art.ready .garlic-art { animation: none; }
}
/* lotto */
.lotto-top { display: grid; grid-template-columns: auto 1fr; gap: 16px 32px; align-items: center; margin-bottom: 16px; }
.lotto-amount { font-size: clamp(2rem, 7vw, 3rem); font-weight: 800; line-height: 1.1; }
.lotto-amount .unit { font-size: .45em; color: var(--muted); font-weight: 700; }
.lotto-facts { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 10px; margin: 0; }
.lotto-msg { margin: 10px 0 6px; font-weight: 600; min-height: 1.4em; }
.lotto-msg.ok { color: var(--ok); }
.lotto-msg.warn { color: var(--bad); }
.lotto-scheduled { border-color: var(--gold); background: var(--gold-soft); }
.lotto-result { display: grid; grid-template-columns: 180px 1fr; gap: 20px; align-items: center; }
.lotto-result-text p { margin: 0 0 8px; }
.lotto-winner { font-weight: 700; word-break: break-all; }
.lotto-hash { font-size: .75rem; color: var(--muted); }
#history tr.you td { background: var(--gold-soft); }
@media (max-width: 720px) {
  .lotto-top { grid-template-columns: minmax(0, 1fr); }
  .lotto-result { grid-template-columns: minmax(0, 1fr); }
  .lotto-result-art { max-width: 180px; }
}
@media (max-width: 480px) {
  .lotto-facts { grid-template-columns: minmax(0, 1fr); }
  .lotto-facts div { display: flex; justify-content: space-between; align-items: baseline; gap: 10px; }
  .lotto-facts dd { font-size: 1rem; text-align: right; }
}
.lotto-form .g-recaptcha { flex: 0 0 auto; }
/* already in the open draw: the form is there but switched off (assets/lotto.js) */
.lotto-form.locked input, .lotto-form.locked .btn { opacity: .5; cursor: not-allowed; }
/* lotto: prize on its own row, the three facts as equal cards underneath (they were squeezed beside a long prize note) */
.lotto-top { grid-template-columns: minmax(0, 1fr); gap: 14px; }
/* under the prize: the usual range, then the jackpot as a small gold tag (assets/lotto.js) */
#prize-note { margin-top: .5rem; line-height: 1.5; }
.lotto-jp-tag { display: inline-block; margin-top: .4rem; padding: .15rem .6rem; border-radius: 999px; background: var(--gold-soft, #fbeec7); color: inherit; border: 1px solid var(--gold); font-size: .85em; font-weight: 600; white-space: nowrap; }
.lotto-facts dt { white-space: nowrap; }
.lotto-facts dd { white-space: nowrap; font-size: 1.2rem; }
@media (min-width: 1000px) {
  .lotto-top { grid-template-columns: minmax(0, 1fr) 480px; align-items: center; }
}
.digit.picked { border-color: var(--gold-deep); background: var(--gold); color: var(--on-gold); box-shadow: var(--shadow); }
.digit.picked::after { background: rgba(0,0,0,.08); }
.roulette-name { max-width: 320px; margin-top: 6px; }
.art-adopt { margin-top: 8px; }
.art-adopt a { font-weight: 700; }
/* ---------- /bakery/ shout-outs ---------- */
.oven-card { flex-wrap: wrap; }
.shout { flex: 1 1 100%; border-top: 1px dashed var(--line); padding-top: 14px; margin-top: 4px; }
.shout-coming { margin: 0 0 12px; display: flex; flex-wrap: wrap; gap: 6px; align-items: center; }
.shout-coming .label { flex-basis: 100%; margin: 0; }
.shout-bubble { display: inline-block; padding: 6px 12px; border-radius: 14px 14px 14px 4px; background: var(--gold-soft); border: 1px solid var(--gold); font-weight: 600; overflow-wrap: anywhere; animation: wall-wait 1.6s ease-in-out infinite; }
.loaf-shouts { display: flex; flex-direction: column; gap: 4px; }
.loaf-shouts:empty { display: none; }
.loaf-shout { display: inline-block; align-self: flex-start; margin-top: 4px; padding: 4px 10px; border-radius: 12px 12px 12px 3px; background: var(--gold); color: #2b2416; font-weight: 700; font-size: .85rem; text-decoration: none; overflow-wrap: anywhere; max-width: 100%; }
.loaf.has-shout { box-shadow: inset 4px 0 0 var(--gold); }
.lotto-cheers { display: flex; flex-wrap: wrap; gap: 6px; margin: 10px 0 12px; }
.lotto-cheers.past { margin-top: 14px; }
.lotto-cheers .label { flex-basis: 100%; margin: 0; }
.shout-bubble.still { animation: none; }
/* lotto facts: values like "~6:30 PM CDT" overflowed their boxes; let them wrap between words and size to the space */
.lotto-facts dd { white-space: normal; overflow-wrap: normal; font-size: clamp(1rem, 1.5vw, 1.2rem); line-height: 1.25; }
@media (max-width: 480px) {
  .lotto-facts dt { flex: none; }
  .lotto-facts dd { font-size: 1rem; min-width: 0; }
}
@media (max-width: 720px) {
  /* Block Lotto on phones: the entry form right under today's prize, the draw's numbers after it */
  .lotto-open { display: flex; flex-direction: column; }
  .lotto-open > .lotto-top { display: contents; }
  .lotto-open > .jackpot-hit { order: 0; }
  .lotto-open .lotto-prize { order: 1; }
  .lotto-open > .lotto-form { order: 2; margin-top: 14px; }
  .lotto-open > .lotto-msg { order: 3; }
  .lotto-open > p.muted.small { order: 4; }
  .lotto-open .lotto-facts { order: 5; margin-top: 16px; }
}
#prize-note { min-height: 56px; }
/* /lotto/: the prize range and the jackpot tag */
#lotto-lead { min-height: 4lh; }
/* the lead is rewritten with the visitor's own closing time */
:root[lang="pt-BR"] #lotto-lead, :root[lang="de"] #lotto-lead { min-height: 5lh; }
@media (min-width: 1000px) {
  :root[lang="en"] .lotto-facts dd { min-height: 2lh; }
}
@media (max-width: 600px) {
  #lotto-lead { min-height: 8lh; }
  :root[lang="en"] #lotto-lead { min-height: 7lh; }
}
/* Block Lotto facts: labels may wrap so a long one ("Winner announced") never pushes past its box */
.lotto-facts dt { white-space: normal; line-height: 1.3; }
@media (max-width: 480px) {
  .lotto-facts dt { white-space: nowrap; }
}
