/* ============================================================
   Lottery.qtool.io — Free Lottery Tools
   Dark premium theme inspired by luck.fyi & lotterycalculators.com
   ============================================================ */

:root {
  --ink: #080F13;
  --ink-2: #0E1A21;
  --ink-3: #14262E;
  --line: rgba(46, 217, 232, 0.13);
  --line-2: rgba(46, 217, 232, 0.22);
  --gold: #2ED9E8;
  --gold-deep: #21C7D6;
  --crimson: #d4194f;
  --crimson-2: #7a1733;
  --mint: #4ade9b;
  --paper: #f4f0e6;
  --text: #E6F2F5;
  --muted: #93AAB4;
  --radius: 18px;
  --radius-sm: 12px;
  --radius-xs: 8px;
  --shadow: 0 24px 60px -20px rgba(0, 0, 0, 0.7);
  --maxw: 1120px;
  --display: "Hanken Grotesk", system-ui, sans-serif;
  --body: "Hanken Grotesk", system-ui, sans-serif;
}

/* Light mode overrides */
:root.light {
  --ink: #f5f7fa;
  --ink-2: #ffffff;
  --ink-3: #eef1f5;
  --line: rgba(8, 15, 19, 0.12);
  --line-2: rgba(8, 15, 19, 0.20);
  --gold: #0f7e8a;
  --gold-deep: #0c6a73;
  --crimson: #c41e4a;
  --crimson-2: #8a1a36;
  --mint: #0d9f6e;
  --paper: #f4f0e6;
  --text: #1a2c33;
  --muted: #5a737d;
  --shadow: 0 24px 60px -20px rgba(0, 0, 0, 0.15);
}

:root.light body {
  background: var(--ink);
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }

body {
  margin: 0;
  background:
    radial-gradient(1200px 700px at 80% -10%, rgba(212, 25, 79, 0.16), transparent 60%),
    radial-gradient(900px 600px at 0% 0%, rgba(46, 217, 232, 0.05), transparent 55%),
    var(--ink);
  color: var(--text);
  font-family: var(--body);
  font-size: 16px;
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

a { color: inherit; text-decoration: none; }
a:hover { color: var(--gold); }
h1, h2, h3, h4 { font-family: var(--display); line-height: 1.1; margin: 0; font-weight: 700; }

.wrap { max-width: var(--maxw); margin: 0 auto; padding: 0 22px; }

/* --- Skip link --- */
.skip-link {
  position: absolute; left: -9999px; top: 0;
  background: var(--gold); color: #221b07; font-weight: 700;
  padding: 0.7em 1.2em; border-radius: 0 0 10px 0; z-index: 10000;
}
.skip-link:focus { left: 0; }

/* --- Eyebrow --- */
.eyebrow {
  font-family: var(--display); font-size: 0.72rem; font-weight: 600;
  letter-spacing: 0.22em; text-transform: uppercase;
  color: var(--gold); display: inline-flex; gap: 0.6em; align-items: center;
}
.eyebrow::before {
  content: ""; width: 26px; height: 1px; background: var(--gold); opacity: 0.6;
}

/* --- Buttons --- */
.btn {
  --bg: var(--gold); --fg: #221b07;
  display: inline-flex; align-items: center; gap: 0.55em; justify-content: center;
  font-family: var(--display); font-weight: 600; font-size: 0.95rem;
  padding: 0.85em 1.4em; border-radius: 999px; border: 0; cursor: pointer;
  background: var(--bg); color: var(--fg);
  transition: transform 0.15s ease, box-shadow 0.2s ease, filter 0.2s ease;
  box-shadow: 0 10px 24px -10px rgba(46, 217, 232, 0.5);
  min-height: 44px;
}
.btn:hover { transform: translateY(-2px); filter: brightness(1.05); }
.btn:active { transform: translateY(0); }
.btn.crimson { --bg: linear-gradient(135deg, var(--crimson), var(--crimson-2)); --fg: #fff; box-shadow: 0 10px 24px -10px rgba(212, 25, 79, 0.6); }
.btn.ghost { --bg: transparent; --fg: var(--text); border: 1px solid var(--line-2); box-shadow: none; }
.btn.ghost:hover { border-color: var(--gold); color: var(--gold); }
.btn.small { padding: 0.5em 1em; font-size: 0.85rem; min-height: 36px; }
.btn:focus-visible { outline: 3px solid var(--gold); outline-offset: 3px; }

/* --- Top Bar --- */
.topbar {
  position: sticky; top: 0; z-index: 40;
  backdrop-filter: blur(12px); background: rgba(8, 15, 19, 0.72);
  border-bottom: 1px solid var(--line);
}
:root.light .topbar {
  background: rgba(255, 255, 255, 0.85);
}
.topbar .wrap { display: flex; align-items: center; justify-content: space-between; height: 64px; }
.logo { font-family: var(--display); font-weight: 700; font-size: 1.15rem; letter-spacing: -0.01em; display: flex; align-items: center; gap: 0.5em; }
.logo .dot { width: 11px; height: 11px; border-radius: 50%; background: var(--gold); box-shadow: 0 0 14px var(--gold); flex: 0 0 auto; }
.logo b { color: var(--gold); }

.topnav { display: flex; align-items: center; gap: 8px; }
.chip {
  font-family: var(--display); font-weight: 500; font-size: 0.85rem;
  padding: 0.5em 0.95em; border-radius: 999px; border: 1px solid var(--line);
  color: var(--text); display: inline-flex; align-items: center; gap: 0.45em; transition: 0.18s;
}
.chip:hover { border-color: var(--gold); color: var(--gold); }
.chip.solid { background: var(--gold); color: #221b07; border-color: transparent; }
.chip.solid:hover { filter: brightness(1.05); color: #221b07; }

/* Theme toggle button */
.theme-toggle {
  background: none; border: 1px solid var(--line); border-radius: 999px;
  width: 38px; height: 38px; display: flex; align-items: center; justify-content: center;
  cursor: pointer; color: var(--text); font-size: 1.1rem; padding: 0;
  transition: 0.2s; margin-left: 6px; flex-shrink: 0;
}
.theme-toggle:hover { border-color: var(--gold); color: var(--gold); }
:root.light .site-footer { background: #e2e8ed; color: #1a2c33; }
:root.light .site-footer a { color: #1a2c33; }
:root.light .site-footer a:hover { color: var(--gold); }
:root.light .site-footer strong { color: #1a2c33 !important; }
:root.light .footer-bottom { color: #33464d; border-top: 1px solid rgba(8, 15, 19, 0.18); }

/* --- Hero --- */
.hero { padding: 84px 0 40px; text-align: center; }
.hero h1 {
  font-size: clamp(2.4rem, 7vw, 4.6rem); font-weight: 700; letter-spacing: -0.02em;
  margin: 0.35em 0 0.25em;
}
.hero h1 .em { color: var(--gold); }
.hero h1 .lk-grad {
  background: linear-gradient(100deg, var(--gold), #ffb24d 42%, var(--gold) 82%);
  -webkit-background-clip: text; background-clip: text;
  -webkit-text-fill-color: transparent; color: transparent;
  background-size: 220% 100%; animation: lkShine 6s ease-in-out infinite;
}
@keyframes lkShine { 0%, 100% { background-position: 0% 50%; } 50% { background-position: 100% 50%; } }
.hero p.lead { font-size: 1.12rem; color: var(--muted); max-width: 66ch; margin: 0 auto 1.6em; line-height: 1.7; }
.heroCtas { display: flex; flex-wrap: wrap; gap: 12px; justify-content: center; margin-bottom: 14px; }
.trust {
  display: flex; flex-wrap: wrap; gap: 18px; justify-content: center;
  margin-top: 26px; color: var(--muted); font-size: 0.85rem;
}
.trust span { display: inline-flex; align-items: center; gap: 0.5em; }
.trust .tick { color: var(--mint); }

/* --- Ball display --- */
.ballrow {
  display: flex; flex-wrap: wrap; gap: 12px; justify-content: center;
  min-height: 12px; align-items: center;
}
.ball {
  --c: #cdd3e6;
  width: 58px; height: 58px; border-radius: 50%; flex: 0 0 auto;
  display: flex; align-items: center; justify-content: center;
  font-family: var(--display); font-weight: 700; font-size: 1.35rem; color: #0E1A21;
  background:
    radial-gradient(circle at 32% 28%, #fff 0 6%, transparent 38%),
    radial-gradient(circle at 70% 75%, rgba(0, 0, 0, 0.28), transparent 55%),
    radial-gradient(circle at 50% 50%, var(--c), color-mix(in srgb, var(--c) 62%, #000) 100%);
  box-shadow: 0 8px 16px -6px rgba(0, 0, 0, 0.6), inset 0 -3px 6px rgba(0, 0, 0, 0.25);
  animation: drop 0.5s cubic-bezier(0.2, 1.3, 0.5, 1) backwards;
}
.ball.special { color: #fff; --c: var(--crimson); box-shadow: 0 8px 20px -6px rgba(212, 25, 79, 0.6), inset 0 -3px 6px rgba(0, 0, 0, 0.3); }
.ball.star { color: #221b07; --c: var(--gold); }
.ball.blue { color: #fff; --c: #3b82f6; }
.ball.green { color: #eafff2; --c: #149a53; }
.ball.yellow { color: #3a2e05; --c: #ffd633; }
.ball.small { width: 42px; height: 42px; font-size: 1rem; }
@keyframes drop { from { opacity: 0; transform: translateY(-16px) scale(0.6); } }

/* --- Machine (draw machine display) --- */
.machine {
  margin-top: 48px; padding: 26px 22px 30px; border-radius: var(--radius);
  background: linear-gradient(180deg, var(--ink-2), rgba(14, 26, 33, 0.4));
  border: 1px solid var(--line); box-shadow: var(--shadow);
  position: relative; overflow: hidden;
}
.machine::before {
  content: ""; position: absolute; inset: 0; pointer-events: none;
  background: radial-gradient(420px 160px at 50% -40px, rgba(46, 217, 232, 0.18), transparent 70%);
}
.machine .label {
  display: flex; justify-content: space-between; align-items: center;
  font-family: var(--display); font-size: 0.78rem; letter-spacing: 0.14em;
  text-transform: uppercase; color: var(--muted); margin-bottom: 18px;
}
.machine .label .live { display: inline-flex; align-items: center; gap: 0.5em; color: var(--mint); }
.machine .label .live::before {
  content: ""; width: 8px; height: 8px; border-radius: 50%;
  background: var(--mint); box-shadow: 0 0 10px var(--mint); animation: pulse 1.8s infinite;
}
@keyframes pulse { 50% { opacity: 0.35; } }

/* --- Sections --- */
.section { padding: 64px 0; }
.section h2.title {
  font-size: clamp(1.6rem, 4vw, 2.4rem); max-width: 24ch;
  margin-bottom: 0.4em; letter-spacing: -0.01em;
}
.section .sub { color: var(--muted); max-width: 60ch; margin: 0 0 8px; }
.section.centered { text-align: center; }
.section.centered .sub { margin: 0 auto 8px; }

/* --- Generator grid --- */
.genGrid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; margin-top: 34px; }
.gen {
  background: linear-gradient(180deg, var(--ink-2), rgba(14, 26, 33, 0.55));
  border: 1px solid var(--line); border-radius: var(--radius); padding: 26px 22px;
  display: flex; flex-direction: column; transition: border-color 0.2s, transform 0.2s;
}
.gen:hover { border-color: var(--line-2); transform: translateY(-3px); }
.gen .flag { font-size: 1.5rem; line-height: 1; }
.gen h3 { font-size: 1.5rem; margin: 0.3em 0 0.1em; }
.gen .game { color: var(--muted); font-size: 0.85rem; margin-bottom: 18px; }
.gen .meta { display: flex; flex-wrap: wrap; gap: 6px; margin-top: auto; }
.gen .meta span {
  font-size: 0.75rem; background: rgba(46, 217, 232, 0.1);
  border: 1px solid var(--line); border-radius: 999px; padding: 3px 10px; color: var(--muted);
}

/* --- Quick-pick mini generator card (home grid) --- */
.qp-card {
  background: linear-gradient(180deg, var(--ink-2), rgba(14, 26, 33, 0.55));
  border: 1px solid var(--line); border-radius: var(--radius);
  padding: 20px 20px 18px; display: flex; flex-direction: column; gap: 8px;
  transition: border-color 0.2s, transform 0.2s;
}
.qp-card:hover { border-color: var(--line-2); transform: translateY(-3px); }
.qp-card .head { display: flex; align-items: center; gap: 8px; }
.qp-card .head .flag { font-size: 1.25rem; line-height: 1; }
.qp-card .head h3 { font-size: 1.12rem; margin: 0; letter-spacing: -0.01em; }
.qp-format { color: var(--muted); font-size: 0.8rem; line-height: 1.4; margin: 0; }
.qp-actions { display: flex; gap: 8px; }
.qp-actions .btn { flex: 1; padding: 0.5em 0.8em; font-size: 0.85rem; min-height: 38px; white-space: nowrap; }
.qp-balls {
  display: flex; flex-wrap: wrap; gap: 6px; min-height: 44px; align-items: center;
  border: 1px dashed var(--line-2); border-radius: 10px;
  padding: 6px 10px; background: rgba(14, 26, 33, 0.35);
}
.qp-ball {
  --c: #c7ceed;
  width: 31px; height: 31px; border-radius: 50%; flex: 0 0 auto;
  display: flex; align-items: center; justify-content: center;
  font-family: var(--display); font-weight: 700; font-size: 0.82rem; color: #0E1A21;
  background:
    radial-gradient(circle at 32% 27%, #fff 0 6%, transparent 38%),
    radial-gradient(circle at 70% 75%, rgba(0, 0, 0, 0.28), transparent 55%),
    radial-gradient(circle at 50% 50%, var(--c), color-mix(in srgb, var(--c) 62%, #000) 100%);
  box-shadow: 0 4px 8px -3px rgba(0, 0, 0, 0.5), inset 0 -2px 4px rgba(0, 0, 0, 0.25);
  animation: drop 0.5s cubic-bezier(0.2, 1.3, 0.5, 1) backwards;
}
.qp-ball.crimson { --c: var(--crimson); color: #fff; }
.qp-ball.gold { --c: var(--gold); color: #221b07; }
.qp-ball.blue { --c: #3b82f6; color: #fff; }
.qp-ball.green { --c: #149a53; color: #eafff2; }
.qp-ball.alt { display: inline-flex; }
.qp-notice { color: var(--muted); font-size: 0.72rem; line-height: 1.4; }
.qp-links { display: flex; align-items: center; justify-content: space-between; gap: 8px; margin-top: 4px; font-size: 0.82rem; }
.qp-links a { color: var(--gold); font-weight: 500; }
.qp-links a:hover { text-decoration: underline; }
.qp-links .btn { flex: 0 0 auto; min-height: 30px; padding: 0.4em 1em; font-size: 0.78rem; }

/* --- Generator tool --- */
.tool-section { padding: 40px 0 64px; }
.tool-layout { display: grid; grid-template-columns: 1fr 320px; gap: 20px; align-items: start; }
.generator-card {
  background: linear-gradient(180deg, var(--ink-2), rgba(14, 26, 33, 0.55));
  border: 1px solid var(--line); border-radius: var(--radius); padding: 26px 22px; box-shadow: var(--shadow);
}
.controls-grid { display: grid; grid-template-columns: 1fr 120px auto; gap: 12px; align-items: end; }
/* Single-lottery generator pages have no lottery dropdown (only Lines + Generate
   button), so collapse the 3-column template to 2 balanced columns. */
.controls-grid:not(:has([data-lottery])) { grid-template-columns: 1fr auto; }
label { font-weight: 600; color: var(--text); font-size: 0.9rem; }
select, input, textarea {
  width: 100%; display: block; margin-top: 6px;
  border: 1px solid var(--line); border-radius: var(--radius-xs);
  padding: 12px; font: inherit; background: var(--ink-3); color: var(--text);
  min-height: 48px;
}
select:focus, input:focus, textarea:focus { outline: 3px solid rgba(46, 217, 232, 0.28); outline-offset: 2px; border-color: var(--gold); }
.lottery-pills { display: flex; gap: 8px; flex-wrap: wrap; margin: 14px 0 4px; }
.lottery-pill {
  min-height: 42px; border: 1px solid var(--line); border-radius: 999px;
  background: transparent; color: var(--text); font: inherit; font-weight: 600;
  padding: 8px 12px; cursor: pointer; transition: 0.18s;
}
.lottery-pill:hover { border-color: var(--gold); color: var(--gold); }
.lottery-pill.active { background: var(--gold); border-color: var(--gold); color: #221b07; }
.button-row { display: flex; gap: 10px; flex-wrap: wrap; margin: 16px 0; }
.helper { color: var(--muted); font-size: 0.85rem; }

/* --- Results --- */
.results { margin-top: 16px; }
.result-line {
  display: flex; justify-content: space-between; gap: 14px; align-items: center;
  border-top: 1px solid var(--line); padding: 14px 0;
}
.result-line:first-child { border-top: 0; }
.result-line p { margin: 0; color: var(--muted); font-size: 0.85rem; }
.balls { display: flex; gap: 8px; flex-wrap: wrap; margin: 8px 0; }

/* --- Saved panel --- */
.saved-panel { margin-top: 18px; }
.saved-line {
  display: grid; grid-template-columns: 160px 1fr; gap: 10px;
  border-top: 1px solid var(--line); padding: 10px 0;
}

/* --- Explainer --- */
.explainer {
  border: 1px solid var(--line); border-radius: var(--radius-sm);
  background: var(--ink-2); padding: 14px; margin-top: 14px;
}
.explainer summary { cursor: pointer; font-weight: 600; color: var(--gold); }
.explainer p { color: var(--muted); font-size: 0.9rem; margin: 10px 0 0; }

/* --- Trust panel --- */
.trust-panel {
  background: var(--ink-2); border: 1px solid var(--line);
  border-radius: var(--radius); padding: 22px; position: sticky; top: 84px;
}
.trust-panel h2 { font-size: 1.2rem; margin-bottom: 14px; }
.check-list { list-style: none; padding: 0; display: flex; flex-direction: column; gap: 9px; }
.check-list li {
  background: rgba(46, 217, 232, 0.08); border: 1px solid var(--line);
  border-radius: 999px; padding: 8px 12px; font-weight: 600; color: var(--text);
  font-size: 0.9rem;
}
.notice {
  border-left: 4px solid var(--gold); background: rgba(46, 217, 232, 0.08);
  padding: 12px 14px; border-radius: var(--radius-xs); color: var(--muted); font-size: 0.85rem;
  margin-top: 16px;
}
.notice.warning { border-left-color: #ffb24d; background: rgba(255, 178, 77, 0.08); }

/* --- Content section --- */
.content-section { padding: 42px 0; }
.content-section.alt { background: rgba(14, 26, 33, 0.3); }
.two-col { display: grid; grid-template-columns: minmax(0, 1fr) 360px; gap: 28px; }
.cards { display: grid; grid-template-columns: repeat(3, 1fr); gap: 18px; }
.cards article {
  background: var(--ink-2); border: 1px solid var(--line);
  border-radius: var(--radius); padding: 22px; box-shadow: var(--shadow);
}
.cards article h2 { font-size: 1.3rem; margin-bottom: 8px; }
.cards article p { color: var(--muted); font-size: 0.9rem; }
.cards article a { color: var(--gold); font-weight: 600; display: inline-block; margin-top: 12px; }
.info-box {
  background: var(--ink-2); border: 1px solid var(--line);
  border-radius: var(--radius); padding: 22px;
}
.info-box h3 { font-size: 1.1rem; margin-bottom: 12px; }
.info-box ul { list-style: none; padding: 0; margin: 0; }
.info-box ul li { padding: 8px 0; border-top: 1px solid var(--line); font-size: 0.9rem; color: var(--muted); }
.info-box ul li:first-child { border-top: 0; }
.info-box ul li a { color: var(--gold); }

/* --- FAQ --- */
.faq details {
  border: 1px solid var(--line); border-radius: var(--radius-sm);
  background: var(--ink-2); padding: 14px; margin-top: 10px;
}
.faq details summary { cursor: pointer; font-weight: 600; color: var(--text); }
.faq details p { color: var(--muted); font-size: 0.9rem; margin: 10px 0 0; }

/* --- Breadcrumb --- */
.breadcrumb {
  padding: 16px 0; font-size: 0.85rem; color: var(--muted);
  text-align: left;
}
.breadcrumb a { color: var(--muted); }
.breadcrumb a:hover { color: var(--gold); }
.breadcrumb span { color: var(--text); }

/* --- Page hero --- */
.page-hero { padding: 40px 0 20px; }
.page-hero h1 { font-size: clamp(2rem, 5vw, 3.2rem); }

/* --- Article / Legal pages --- */
.article { max-width: 860px; }
.article h2 { font-size: 1.5rem; margin-top: 36px; margin-bottom: 12px; }
.article h3 { font-size: 1.2rem; margin-top: 28px; margin-bottom: 8px; }
.article p { color: var(--muted); font-size: 1rem; margin: 14px 0; }
.article ul { color: var(--muted); }
.article ul li { margin: 6px 0; }
.article strong { color: var(--text); }

/* --- Contact form --- */
.contact-form { margin-top: 24px; }
.contact-form label { display: block; margin-bottom: 16px; }
.contact-form .form-status { color: var(--mint); font-size: 0.9rem; margin-top: 12px; }

/* --- Footer --- */
.site-footer {
  background: #10201d; color: #d7e5e1;
  padding: 34px 0 20px; margin-top: auto;
}
.site-footer a { color: #d7e5e1; }
.site-footer a:hover { color: var(--gold); }
.footer-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 22px; }
.footer-grid nav { display: grid; grid-template-columns: repeat(2, 1fr); gap: 8px; }
.footer-bottom {
  display: flex; justify-content: space-between; gap: 16px;
  border-top: 1px solid rgba(255, 255, 255, 0.18);
  margin-top: 22px; padding-top: 18px; color: #b8cbc6; font-size: 14px;
}
.footer-bottom .legal-notice { text-align: center; width: 100%; }

/* --- Cookie consent --- */
.cookie-consent {
  position: fixed; left: 16px; right: 16px; bottom: 16px; z-index: 20;
  max-width: 980px; margin: auto;
  background: var(--ink-3); border: 1px solid var(--line);
  border-radius: var(--radius); box-shadow: var(--shadow);
  padding: 16px; display: flex; gap: 16px; align-items: center; justify-content: space-between;
}
.cookie-consent[hidden] { display: none; }
.cookie-consent p { margin: 4px 0; color: var(--muted); font-size: 14px; }
.cookie-actions { display: flex; gap: 10px; flex-wrap: wrap; justify-content: flex-end; }

/* --- Tool grid on homepage --- */
.tool-grid {
  display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; margin-top: 34px;
}
.tool-card {
  background: linear-gradient(180deg, var(--ink-2), rgba(14, 26, 33, 0.55));
  border: 1px solid var(--line); border-radius: var(--radius); padding: 26px 22px;
  display: flex; flex-direction: column; transition: border-color 0.2s, transform 0.2s;
  text-align: center;
}
.tool-card:hover { border-color: var(--line-2); transform: translateY(-3px); }
.tool-card .icon { font-size: 2.5rem; margin-bottom: 12px; }
.tool-card h3 { font-size: 1.2rem; margin: 0.3em 0 0.1em; }
.tool-card p { color: var(--muted); font-size: 0.85rem; margin: 8px 0 16px; flex: 1; }

/* --- 18+ badge --- */
.age-badge {
  display: inline-flex; align-items: center; gap: 8px;
  background: rgba(212, 25, 79, 0.15); border: 1px solid rgba(212, 25, 79, 0.3);
  border-radius: 999px; padding: 8px 14px; font-size: 0.85rem; color: var(--crimson);
}
.age-badge strong {
  display: flex; align-items: center; justify-content: center;
  width: 28px; height: 28px; background: var(--crimson); color: #fff;
  border-radius: 50%; font-size: 0.75rem;
}

/* --- Responsive --- */
@media (max-width: 860px) {
  .topnav { display: none; }
  .topnav.open { display: flex; flex-direction: column; position: absolute; top: 64px; left: 0; right: 0; background: var(--ink-2); border-bottom: 1px solid var(--line); padding: 16px 22px; }
  .menuToggle { display: inline-flex; background: none; border: 0; color: var(--text); font-size: 1.5rem; cursor: pointer; padding: 8px; }
  .genGrid, .tool-grid, .cards { grid-template-columns: 1fr; }
  .tool-layout, .two-col, .footer-grid { grid-template-columns: 1fr; }
  .controls-grid { grid-template-columns: 1fr; }
  .controls-grid:not(:has([data-lottery])) { grid-template-columns: 1fr; }
  .lottery-pills { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .lottery-pill { width: 100%; font-size: 14px; }
  .result-line { flex-direction: column; align-items: flex-start; }
  .saved-line { grid-template-columns: 1fr; }
  .footer-bottom { flex-direction: column; text-align: center; }
  .cookie-consent { left: 10px; right: 10px; bottom: 10px; flex-direction: column; align-items: stretch; }
  .cookie-actions { justify-content: stretch; }
  .cookie-actions .btn { width: 100%; }
  .trust-panel { position: static; }
}

@media (max-width: 520px) {
  .hero h1 { font-size: 10.9vw; }
  .heroCtas { flex-wrap: nowrap; gap: 9px; }
  .heroCtas .btn { flex: 1; justify-content: center; white-space: nowrap; font-size: clamp(0.7rem, 3.4vw, 0.86rem); padding: 0.8em 0.25em; }
}