:root {
  color-scheme: light;
  --orange: #ff5a1f;
  --orange-dark: #ed4d18;
  --ink: #344153;
  --muted: #7d8997;
  --line: #e7eaee;
  --surface: #fff;
  --canvas: #fff;
  --green: #27b37d;
  --pink: #dc64a1;
  --blue: #538dea;
  --purple: #9473df;
  --teal: #43b5b1;
  --gold: #e7a544;
  font-synthesis: none;
}
* { box-sizing: border-box; }
[hidden] { display: none !important; }
html { scroll-behavior: smooth; scroll-padding-top: 18px; }
body { min-width: 320px; margin: 0; background: var(--canvas); color: var(--ink); font-family: Lato, Arial, sans-serif; -webkit-font-smoothing: antialiased; }
button, input, textarea { font: inherit; }
button, a { -webkit-tap-highlight-color: transparent; }
button { color: inherit; }
.site-header { position: relative; z-index: 10; height: 76px; background: var(--surface); border-bottom: 1px solid #f0f1f3; }
.header-inner { position: relative; width: min(1320px, calc(100% - 48px)); height: 100%; margin: 0 auto; display: grid; grid-template-columns: 1fr auto 1fr; align-items: center; }
.menu-toggle { justify-self: start; display: inline-flex; align-items: center; gap: 10px; padding: 10px 0; border: 0; background: transparent; color: #596575; font: 600 12px Poppins, sans-serif; cursor: pointer; }
.menu-lines { display: grid; gap: 4px; width: 19px; }
.menu-lines i { display: block; height: 2px; background: currentColor; border-radius: 2px; }
.brand, .footer-brand { display: inline-flex; align-items: center; gap: 9px; justify-self: center; color: var(--orange); text-decoration: none; }
.brand-mark { display: block; flex: none; width: 36px; height: 36px; fill: none; stroke: currentColor; stroke-width: 2.3; stroke-linecap: round; stroke-linejoin: round; }
.brand-word { display: flex; flex-direction: column; align-items: flex-end; color: var(--orange); font: 800 16px/.94 Poppins, sans-serif; letter-spacing: -.75px; }
.brand-word small { margin-top: 3px; font: 700 7px/1 Lato, sans-serif; letter-spacing: 2.1px; }
.header-tools { justify-self: end; display: flex; align-items: center; gap: 15px; }
.icon-button { display: grid; place-items: center; width: 32px; height: 32px; padding: 0; border: 0; border-radius: 50%; background: transparent; color: #758191; text-decoration: none; cursor: pointer; }
.icon-button:hover { background: #f4f6f8; color: var(--orange); }
.icon-button svg { width: 18px; height: 18px; fill: none; stroke: currentColor; stroke-width: 1.7; stroke-linecap: round; stroke-linejoin: round; }
.language-chip { display: inline-flex; align-items: center; gap: 5px; padding: 4px 7px; border: 1px solid #e8ebef; border-radius: 18px; background: var(--surface); cursor: pointer; }
.language-chip > span:first-child { font-size: 15px; }
.language-code { color: #697584; font: 700 9px Poppins, sans-serif; }
.header-popover { position: absolute; z-index: 15; top: 64px; right: max(calc((100vw - 1320px)/2), 24px); width: min(300px, calc(100vw - 32px)); padding: 16px; border: 1px solid var(--line); border-radius: 8px; background: var(--surface); box-shadow: 0 12px 32px #26314420; }
.search-panel { display: grid; gap: 8px; }
.search-panel label, .language-panel strong { color: #586576; font: 700 11px Poppins, sans-serif; }
.search-panel input { height: 39px; padding: 0 11px; border: 1px solid #e1e6eb; border-radius: 5px; color: var(--ink); outline: none; }
.search-panel input:focus { border-color: var(--orange); box-shadow: 0 0 0 3px #ff5a1f1c; }
.search-panel > span, .language-soon { color: #929daa; font-size: 11px; }
.language-panel { display: grid; gap: 12px; }
.language-current { display: flex; align-items: center; justify-content: space-between; padding: 10px; border-radius: 5px; background: #f7f8fa; font-size: 12px; }
.language-current b { color: #26936a; font: 700 9px Poppins, sans-serif; }
.side-panel { position: absolute; z-index: 16; top: 66px; left: max(calc((100vw - 1320px)/2), 24px); width: min(310px, calc(100vw - 32px)); max-height: min(80vh, 620px); overflow: auto; padding: 13px; border: 1px solid var(--line); border-radius: 8px; background: var(--surface); box-shadow: 0 16px 44px #26314426; }
.side-panel-head { display: flex; align-items: center; justify-content: space-between; padding: 4px 7px 11px; border-bottom: 1px solid var(--line); color: #8692a0; font: 700 10px Poppins, sans-serif; letter-spacing: 1px; }
.side-panel-head button { width: 30px; height: 30px; border: 0; border-radius: 50%; background: transparent; color: #778392; font-size: 23px; cursor: pointer; }
.side-panel > a, .side-disabled { display: flex; align-items: center; justify-content: space-between; padding: 11px 9px; border-radius: 5px; color: #4a5869; font-size: 13px; text-decoration: none; }
.side-panel > a:hover { background: #fff3ed; color: var(--orange-dark); }
.side-panel .side-primary { color: var(--orange-dark); font-weight: 700; }
.side-divider { height: 1px; margin: 7px 4px 12px; background: var(--line); }
.side-label { display: block; padding: 0 9px 4px; color: #929daa; font: 700 9px Poppins, sans-serif; letter-spacing: 1px; }
.side-disabled { color: #929daa; cursor: not-allowed; }
.side-disabled small { padding: 3px 6px; border-radius: 20px; background: #f3f5f7; color: #8b96a2; font: 600 8px Poppins, sans-serif; }
.category-nav { display: grid; grid-template-columns: repeat(7, minmax(0, 1fr)); min-height: 54px; background: var(--surface); border-bottom: 1px solid #e8e9ec; }
.category-link { position: relative; display: flex; align-items: center; justify-content: center; gap: 6px; min-width: 0; padding: 0 8px; border: 0; border-bottom: 3px solid var(--category); background: transparent; color: var(--category); text-align: center; text-decoration: none; white-space: nowrap; font: 500 11px Poppins, sans-serif; }
a.category-link { cursor: pointer; }
.category-link:hover, .category-link.is-current { background: color-mix(in srgb, var(--category) 5%, transparent); }
.category-link small { display: none; color: #9aa4b0; font: 600 8px Poppins, sans-serif; }
.category-link.upcoming { opacity: .83; cursor: not-allowed; }
.category-orange { --category: #fb6331; }.category-pink { --category: #df5d9c; }.category-blue { --category: #4e89ed; }.category-green { --category: #22a878; }.category-purple { --category: #8b67d3; }.category-teal { --category: #41a8a4; }.category-gold { --category: #d59a3c; }
.hero { position: relative; isolation: isolate; min-height: 600px; overflow: hidden; padding: 34px 22px 54px; background: radial-gradient(ellipse at 4% 66%, #e4f8d2 0%, #effbe8 15%, transparent 43%), radial-gradient(ellipse at 33% 105%, #d7f5e8 0%, transparent 42%), radial-gradient(ellipse at 72% 78%, #e0efff 0%, #edf5ff 23%, transparent 51%), radial-gradient(ellipse at 100% 53%, #e9e2ff 0%, transparent 37%), linear-gradient(112deg, #fbfff8 0%, #fff 38%, #f9fcff 74%, #fdfaff 100%); }
.paint-splatter { position: absolute; z-index: -1; inset: 0; pointer-events: none; opacity: .7; background-image: radial-gradient(circle at 3% 20%, #a9df63 0 3px, transparent 4px),radial-gradient(circle at 6% 39%, #8edb56 0 2px, transparent 3px),radial-gradient(circle at 9% 13%, #a8e35e 0 4px, transparent 5px),radial-gradient(circle at 12% 66%, #b6e967 0 3px, transparent 4px),radial-gradient(circle at 15% 27%, #7acb51 0 2px, transparent 3px),radial-gradient(circle at 18% 83%, #9bdc65 0 4px, transparent 5px),radial-gradient(circle at 22% 55%, #8ed9a4 0 3px, transparent 4px),radial-gradient(circle at 27% 90%, #6fd5bb 0 2px, transparent 3px),radial-gradient(circle at 32% 75%, #86dbbf 0 3px, transparent 4px),radial-gradient(circle at 38% 94%, #90e1d3 0 4px, transparent 5px),radial-gradient(circle at 65% 88%, #8ec9f8 0 3px, transparent 4px),radial-gradient(circle at 71% 64%, #9acafa 0 2px, transparent 3px),radial-gradient(circle at 76% 92%, #77baf4 0 4px, transparent 5px),radial-gradient(circle at 81% 72%, #91c9f8 0 3px, transparent 4px),radial-gradient(circle at 86% 48%, #b6a8fa 0 2px, transparent 3px),radial-gradient(circle at 91% 83%, #b5a1f5 0 4px, transparent 5px),radial-gradient(circle at 97% 36%, #b9aaf4 0 3px, transparent 4px); }
.paint-splatter::before, .paint-splatter::after { content: ""; position: absolute; width: min(42vw, 580px); height: 95%; top: 3%; border-radius: 50%; filter: blur(26px); opacity: .29; }
.paint-splatter::before { left: -18%; background: radial-gradient(ellipse, #8dd753 0%, #b6ec81 42%, transparent 72%); }
.paint-splatter::after { right: -18%; background: radial-gradient(ellipse, #83c5fa 0%, #c0b4fa 48%, transparent 75%); }
.hero-inner { position: relative; z-index: 1; width: min(760px, 100%); margin: 0 auto; text-align: center; }
.hero-brand { display: flex; align-items: center; justify-content: center; gap: 14px; margin: 1px auto 8px; color: var(--orange); }
.hero-brand-mark { width: 72px; height: 72px; fill: none; stroke: currentColor; stroke-width: 2.4; stroke-linecap: round; stroke-linejoin: round; filter: drop-shadow(0 4px 6px #df703320); }
.hero-brand-word { display: flex; flex-direction: column; align-items: flex-end; color: var(--orange); font: 800 clamp(34px, 5.2vw, 48px)/.94 Poppins, sans-serif; letter-spacing: -2.8px; }
.hero-brand-word small { margin-top: 6px; font: 800 11px/1 Lato, sans-serif; letter-spacing: 5.5px; }
.hero-title { margin: 0 0 30px; color: #687789; font: 600 17px/1.3 Poppins, sans-serif; }
.draw-card { width: min(680px, 100%); margin: 0 auto; padding: 0; background: transparent; text-align: center; }
.draw-sentence { display: flex; flex-direction: column; align-items: center; gap: 12px; margin: 0 auto 25px; color: #657284; font: 500 26px/1.3 Poppins, sans-serif; }
.draw-row { min-height: 52px; display: flex; align-items: center; justify-content: center; gap: 13px; }
.number-field { display: inline-grid; place-items: center; width: 82px; height: 50px; padding: 0 5px; border: 1px solid #e2e6eb; border-radius: 6px; background: #fafbfcdb; }
.number-field input { width: 100%; min-width: 0; border: 0; outline: 0; background: transparent; color: var(--orange); text-align: center; font: 500 20px Poppins, sans-serif; -moz-appearance: textfield; }
.number-field input::-webkit-inner-spin-button, .number-field input::-webkit-outer-spin-button { appearance: none; margin: 0; }
.number-field:focus-within { border-color: #ff9b73; box-shadow: 0 0 0 3px #fa5a2216; }
.quantity-field { width: 82px; }
.options-toggle { display: grid; grid-template-columns: 28px 1fr 28px; align-items: center; width: 100%; min-height: 48px; margin: 0 0 22px; padding: 0 15px; border: 1px solid #e7e9ed; border-radius: 5px; background: #ffffffd9; color: #3d4857; font: 600 13px Poppins, sans-serif; cursor: pointer; }
.settings-symbol { color: #83909e; font-size: 17px; }
.options-toggle > span:nth-child(2) { text-align: center; }
.options-toggle b { color: #697584; font-size: 18px; font-weight: 500; text-align: right; }
.options-toggle:hover { border-color: #d7dce2; background: #fff; }
.options-panel { margin: -12px 0 19px; padding: 18px 20px; border: 1px solid var(--line); border-radius: 7px; background: var(--surface); text-align: left; box-shadow: 0 8px 25px #26314412; }
.options-intro { display: flex; flex-direction: column; gap: 3px; padding-bottom: 13px; margin-bottom: 10px; border-bottom: 1px solid #f0f2f5; }
.options-intro strong { color: #4b5969; font: 600 13px Poppins, sans-serif; }
.options-intro span { color: #8793a1; font-size: 11px; }
.option-row { display: flex; align-items: center; justify-content: space-between; padding: 3px 0 14px; margin-bottom: 14px; border-bottom: 1px solid #f0f2f5; }
.option-row strong, .option-row small { display: block; }
.option-row strong { font-size: 13px; }
.option-row small, .field-label small { margin-top: 4px; color: #8793a1; font-size: 11px; }
.switch { position: relative; width: 40px; height: 23px; flex: none; }
.switch input { position: absolute; opacity: 0; width: 1px; height: 1px; }
.switch span { position: absolute; inset: 0; border-radius: 20px; background: #d9dfe6; transition: .2s; cursor: pointer; }
.switch span::before { content: ""; position: absolute; left: 3px; top: 3px; width: 17px; height: 17px; border-radius: 50%; background: #fff; box-shadow: 0 1px 4px #0002; transition: .2s; }
.switch input:checked + span { background: var(--orange); }
.switch input:checked + span::before { transform: translateX(17px); }
.field-label { display: block; margin: 13px 0; color: #4c5867; font: 700 10px Poppins, sans-serif; letter-spacing: .8px; }
.field-label small { display: block; font: 400 11px Lato, sans-serif; letter-spacing: 0; }
.field-label textarea { display: block; width: 100%; min-height: 42px; resize: vertical; margin-top: 7px; padding: 10px 11px; border: 1px solid #e5e9ee; border-radius: 6px; color: var(--ink); background: var(--surface); outline: none; font: 13px/1.5 Lato, sans-serif; }
.field-label textarea:focus { border-color: #ff9b73; box-shadow: 0 0 0 3px #fa5a2214; }
.privacy-note { display: flex; gap: 9px; margin-top: 15px; padding: 11px 12px; border-radius: 6px; background: #fff8f2; color: #895239; font-size: 11px; line-height: 1.55; }
.draw-button { position: relative; width: 100%; min-height: 54px; border: 0; border-radius: 7px; background: var(--orange); color: #fff; box-shadow: 0 3px 8px #f4541e22; font: 700 17px Poppins, sans-serif; cursor: pointer; transition: background .16s ease, transform .16s ease; }
.draw-button:hover { background: var(--orange-dark); transform: translateY(-1px); }
.draw-button:disabled { opacity: .65; cursor: wait; }
.error { margin-top: 12px; padding: 10px; border-radius: 6px; background: #fff0ed; color: #b43c21; font-size: 13px; text-align: left; }
.result { margin-top: 22px; padding: 16px; border: 1px solid #ffffffa8; border-radius: 8px; background: #ffffff82; text-align: left; }
.result-head { display: flex; align-items: center; justify-content: space-between; color: #758190; font: 700 10px Poppins, sans-serif; letter-spacing: 1.2px; }
.copy { padding: 7px 10px; border: 0; border-radius: 5px; background: #fff; color: #5b6674; cursor: pointer; }
.balls { display: flex; flex-wrap: wrap; justify-content: center; gap: 12px 10px; padding: 17px 0 10px; }
.ball-wrap { display: flex; min-width: 50px; flex-direction: column; align-items: center; gap: 4px; }
.ball { display: grid; place-items: center; width: 48px; height: 48px; border-radius: 50%; background: linear-gradient(145deg, #ff8659, #f4541e); color: #fff; box-shadow: 0 4px 12px #f4541e38; font: 700 17px Poppins, sans-serif; animation: pop .3s both; }
.ball.is-fixed { outline: 3px solid #ffd5c5; outline-offset: 2px; }
.ball-caption { color: #b45836; font: 700 8px Poppins, sans-serif; }
.disclosure { margin-top: 8px; padding: 10px 12px; border: 1px solid #ffd8c9; border-radius: 6px; background: #fff8f4; color: #9d482b; font-size: 12px; line-height: 1.5; }
@keyframes pop { from { transform: scale(.7); opacity: 0; } to { transform: scale(1); opacity: 1; } }
.history-wrap { width: min(1040px, calc(100% - 48px)); margin: 0 auto; padding: 36px 0 52px; }
.section-head { display: flex; align-items: end; justify-content: space-between; margin-bottom: 16px; }
.section-kicker { color: var(--orange); font: 700 10px Poppins, sans-serif; letter-spacing: 1.4px; }
.section-head h2 { margin: 6px 0 0; color: #354153; font: 600 21px Poppins, sans-serif; }
.history-caption { color: #9aa4b0; font-size: 11px; }
.history-list { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
.history-item { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 13px 15px; border: 1px solid var(--line); border-radius: 8px; background: var(--surface); }
.history-numbers { display: flex; flex-wrap: wrap; align-items: center; gap: 4px; color: #49586a; font: 600 13px Poppins, sans-serif; }
.history-number { white-space: nowrap; }
.history-number.is-fixed { color: #c64a24; text-decoration: underline dotted; text-underline-offset: 3px; }
.history-meta { display: flex; align-items: center; gap: 8px; color: #8793a0; font-size: 10px; white-space: nowrap; }
.tag-config { padding: 5px 8px; border-radius: 20px; background: #fff1ea; color: #ce4e25; font: 700 8px Poppins, sans-serif; }
.empty-history { grid-column: 1/-1; padding: 22px; border: 1px dashed #dfe4e9; border-radius: 8px; color: #9aa4af; font-size: 13px; text-align: center; }
footer { display: flex; align-items: center; justify-content: space-between; min-height: 68px; padding: 10px max(calc((100vw - 1040px)/2), 24px); border-top: 1px solid #edf0f2; color: #929daa; font-size: 11px; }
.footer-brand { justify-self: auto; gap: 6px; }
.footer-brand .brand-mark { width: 26px; height: 26px; }
.footer-brand .brand-word { font-size: 11px; }
.footer-brand .brand-word small { font-size: 6px; letter-spacing: 1.5px; }
body[data-theme="dark"] { --ink: #e8edf4; --muted: #aab5c2; --line: #39414b; --surface: #202832; --canvas: #1b232b; color-scheme: dark; }
body[data-theme="dark"] .site-header, body[data-theme="dark"] .category-nav { border-color: #37414b; }
body[data-theme="dark"] .hero { background: radial-gradient(ellipse at 4% 74%, #30452c 0%, transparent 42%),radial-gradient(ellipse at 71% 78%, #283e50 0%, transparent 50%),radial-gradient(ellipse at 100% 62%, #392f4c 0%, transparent 36%),linear-gradient(112deg, #202b29, #202832 52%, #292637); }
body[data-theme="dark"] .hero-title, body[data-theme="dark"] .options-intro strong, body[data-theme="dark"] .section-head h2 { color: #e8edf4; }
body[data-theme="dark"] .number-field, body[data-theme="dark"] .options-toggle, body[data-theme="dark"] .result { background: #ffffff10; }
body[data-theme="dark"] .options-panel, body[data-theme="dark"] .side-panel, body[data-theme="dark"] .header-popover { background: var(--surface); }
body[data-theme="dark"] .options-toggle, body[data-theme="dark"] .history-item, body[data-theme="dark"] .side-panel > a, body[data-theme="dark"] .side-disabled { color: #e8edf4; }
body[data-theme="dark"] .field-label textarea, body[data-theme="dark"] .search-panel input { background: #1b232b; color: var(--ink); }
body[data-theme="dark"] footer { border-color: #37414b; }
@media (max-width: 1050px) {
  .category-nav { grid-template-columns: repeat(7, max-content); justify-content: start; overflow-x: auto; overscroll-behavior-x: contain; scrollbar-width: none; }
  .category-nav::-webkit-scrollbar { display: none; }
  .category-link { min-width: 148px; }
  .category-link small { display: inline; }
  .hero { min-height: 580px; }
}
@media (max-width: 650px) {
  .site-header { height: 62px; }
  .header-inner { width: calc(100% - 22px); }
  .menu-toggle { gap: 6px; }
  .menu-lines { width: 17px; gap: 3px; }
  .menu-word { display: none; }
  .brand { gap: 5px; }
  .brand-mark { width: 27px; height: 27px; stroke-width: 2.6; }
  .brand-word { font-size: 11px; letter-spacing: -.35px; }
  .brand-word small { margin-top: 2px; font-size: 5px; letter-spacing: 1.6px; }
  .header-tools { gap: 3px; }
  .icon-button { width: 27px; height: 27px; }
  .icon-button svg { width: 16px; height: 16px; }
  .language-chip { gap: 3px; padding: 3px 5px; }
  .language-chip > span:first-child { font-size: 13px; }
  .language-code { font-size: 8px; }
  .category-nav { min-height: 45px; }
  .category-link { min-width: 150px; padding: 0 12px; font-size: 10px; }
  .header-popover { top: 54px; right: 10px; }
  .side-panel { top: 54px; left: 10px; }
  .hero { min-height: 540px; padding: 26px 14px 34px; }
  .paint-splatter::before, .paint-splatter::after { width: 55vw; filter: blur(25px); opacity: .22; }
  .hero-inner { width: min(470px, 100%); }
  .hero-brand { gap: 8px; margin-bottom: 5px; }
  .hero-brand-mark { width: 52px; height: 52px; stroke-width: 2.5; }
  .hero-brand-word { font-size: clamp(29px, 8.3vw, 39px); letter-spacing: -1.8px; }
  .hero-brand-word small { margin-top: 3px; font-size: 8px; letter-spacing: 3.4px; }
  .hero-title { margin-bottom: 22px; font-size: 14px; }
  .draw-sentence { gap: 5px; margin-bottom: 20px; font-size: 20px; line-height: 1.25; }
  .draw-row { min-height: 46px; gap: 9px; }
  .number-field, .quantity-field { width: 70px; height: 45px; }
  .number-field input { font-size: 18px; }
  .options-toggle { min-height: 44px; margin-bottom: 18px; font-size: 11px; }
  .options-panel { padding: 15px 13px; }
  .draw-button { min-height: 49px; font-size: 15px; }
  .history-wrap { width: calc(100% - 32px); padding: 28px 0 38px; }
  .section-head h2 { font-size: 18px; }
  .history-list { grid-template-columns: 1fr; }
  .history-item { align-items: flex-start; padding: 11px 12px; }
  .history-numbers { font-size: 11px; }
  .history-meta { gap: 5px; font-size: 9px; }
  footer { min-height: 58px; padding: 8px 16px; }
  footer > span { max-width: 180px; text-align: right; }
}
@media (max-width: 370px) {
  .header-inner { width: calc(100% - 14px); }
  .brand-word { font-size: 9px; }
  .brand-mark { width: 24px; height: 24px; }
  .header-tools { gap: 0; }
  .icon-button { width: 24px; }
  .language-chip { padding: 3px; }
  .draw-row { gap: 7px; font-size: 18px; }
  .number-field, .quantity-field { width: 65px; }
}
