:root {
  --ink: #252b32;
  --muted: #67717d;
  --line: #e1e5e9;
  --red: #cf1530;
  --blue: #12699d;
  color: var(--ink);
  font-size: 15px;
  line-height: 1.5;
  letter-spacing: 0;
}
body { background: #fff; }
button, a, input { -webkit-tap-highlight-color: transparent; }
button, input { letter-spacing: 0; }
button:focus-visible, a:focus-visible, input:focus-visible {
  outline: 2px solid var(--blue);
  outline-offset: 3px;
}
.site-header { height: 120px; border-bottom: 1px solid var(--line); }
.site-clock { color: var(--muted); font-size: 13px; font-weight: 400; font-variant-numeric: tabular-nums; }
.primary-nav { height: 48px; border-bottom: 0; }
.primary-nav a:nth-child(n) { background: var(--blue); border-right: 1px solid #ffffff26; }
.primary-nav a.active { background: var(--red); color: #fff; filter: none; }
.primary-nav a:hover { filter: brightness(1.08); }
.main-content { padding-top: 24px; }
.section-title { font-size: 24px; line-height: 1.4; font-weight: 700; margin: 0 0 18px; }
.subtabs { border-radius: 0; background: #f4f6f8; border-bottom: 1px solid var(--line); margin: 0 0 24px; }
.subtabs a, .subtabs button { border-radius: 0; padding: 10px 22px; }
.subtabs .selected { background: transparent; color: var(--red); box-shadow: inset 0 -3px var(--red); }
.panel { border-color: var(--line); box-shadow: none; }
.panel-heading { background: #fff2f4; border: 0; border-bottom: 1px solid #f0cfd5; color: #a92237; padding: 12px 20px; }
.panel-heading small { line-height: 1.5; }
.home-panel { margin-top: 24px; }
.result-main, .draw-summary { padding: 28px 32px; }
.issue-title { line-height: 1.6; }
.upcoming-title { font-size: 13px; line-height: 1.6; }
.countdown { font-variant-numeric: tabular-nums; }
.digit { background: #f8f9fb; border-color: var(--line); border-radius: 3px; font-weight: 600; }
.home-live-buttons a { min-height: 36px; border-radius: 4px; box-shadow: none; }
.verify-entry { background: #a57908; border-color: #926900; }
.live-entry, .replay { background: var(--red); border-color: var(--red); }
.history-toolbar { padding: 16px 20px; border-bottom: 1px solid var(--line); gap: 16px; }
.history-toolbar h2, .video-history-panel .history-toolbar h2 { font-size: 16px; font-weight: 600; color: var(--ink); }
.history-actions, .video-history-panel .history-actions { gap: 16px; }
.year-filter { gap: 4px; }
.year-filter button, .video-history-panel .year-filter button { min-height: 40px; padding: 8px 16px; color: var(--muted); border-radius: 4px; }
.year-filter button.selected, .video-history-panel .year-filter button.selected { background: #fff0f3; color: #b71932; font-weight: 700; border-radius: 4px; }
.issue-search { height: 40px; font-size: 16px; border-radius: 4px; border-color: #cbd2d9; background: white; color: var(--ink); }
.issue-search::placeholder { color: #747e88; }
.video-search-button { min-height: 40px; height: 40px; padding: 0 12px; background: var(--red); border-color: var(--red); }
.draw-table th { background: #f4f6f8; color: #53606c; font-size: 13px; font-weight: 600; padding: 12px 8px; border-color: var(--line); }
.draw-table td { border-color: var(--line); padding: 14px 8px; font-variant-numeric: tabular-nums; }
.draw-table tbody tr:nth-child(even) { background: #fafbfc; }
.draw-table .replay { min-height: 34px; font-size: 13px; border-radius: 4px; }
.pagination { padding: 24px 12px; gap: 8px; }
.pagination button { min-height: 40px; border-radius: 4px; padding: 6px 12px; color: var(--ink); border-color: var(--line); }
.pagination button.active { background: var(--red); border-color: var(--red); color: #fff; }
.pagination button:disabled { color: #7c858e; background: #f5f6f8; cursor: not-allowed; }
.live-grid.video-gallery { padding: 20px; gap: 24px 20px; }
.video-card-poster { border-radius: 4px; }
.video-card-caption { color: #53606c; font-size: 13px; padding: 10px 4px 0; line-height: 1.6; }
.video-card-caption strong { font-weight: 700; color: #b71932; }
.video-play-icon { background: #161c26a6; box-shadow: 0 2px 10px #0003; }
.live-broadcast { margin: 0 0 24px; }
.live-announcement { line-height: 1.8; }
.live-broadcast-bar { background: #111820e6; padding: 12px 18px; }
.live-broadcast.is-live [data-live-status] { font-size: 28px; }
[data-live-open] { min-height: 48px; font-size: 18px; padding: 12px 28px; }
.content-page { padding: 24px 80px 64px; max-width: 920px; margin: 0 auto; line-height: 1.9; }
.content-page h1 { text-align: left; font-size: 26px; font-weight: 700; margin: 8px 0 28px; padding-bottom: 18px; border-bottom: 1px solid var(--line); }
.content-page h2 { font-size: 18px; margin: 28px 0 8px; }
.content-page p + h2 { border-top: 1px solid var(--line); padding-top: 24px; }
.content-page p, .faq-item dd { color: #535f6b; }
.faq-item { padding: 0 0 22px; margin: 0 0 22px; border-bottom: 1px solid var(--line); }
.faq-item dt { font-size: 16px; margin-bottom: 8px; }
.faq-item:last-child { border-bottom: 0; }
.contact-note { text-align: left; }
.contact-note a { color: var(--blue); text-decoration: underline; text-underline-offset: 4px; overflow-wrap: anywhere; }
.site-footer { border-top: 1px solid var(--line); margin-top: 32px; padding: 24px 0; color: var(--muted); }
.video-dialog { border-radius: 6px; box-shadow: 0 16px 60px #0006; }
.video-dialog-heading { min-height: 56px; padding: 8px 12px 8px 20px; gap: 12px; background: #202429; }
.video-dialog-heading strong { font-size: 15px; line-height: 1.5; }
#close-video { width: 40px; height: 40px; border-radius: 4px; flex: none; }
#close-video:hover { background: #ffffff14; }
.video-controls { background: #202429; padding: 12px 16px; }
.video-controls input[type=range] { accent-color: #ef4962; }
.video-control-button { border-radius: 4px; }
.video-error { padding: 12px 16px; background: #a82136; }
.empty, .status-message { line-height: 1.7; }
@media (min-width: 561px) {
  .draw-table .ball-row, .draw-table .zodiac-row { gap: 8px; flex-wrap: nowrap; }
  .draw-table .plus { width: 12px; flex: none; margin: 0; text-align: center; }
  .draw-table .zodiac-row span { width: 28px; flex: none; text-align: center; }
  .draw-table .zodiac-row span:nth-child(7) { width: 12px; visibility: hidden; }
}
@media (min-width: 561px) and (max-width: 900px) {
  .result-main, .draw-summary { padding: 24px; }
  .content-page { padding: 24px 32px 48px; }
}
@media (max-width: 560px) {
  body { background: #f3f5f7; }
  .site-header { height: 75px; border-bottom: 1px solid var(--line); }
  .primary-nav { height: calc(60px + env(safe-area-inset-bottom,0px)); border: 0; }
  .primary-nav a:nth-child(n) { border: 0; }
  .primary-nav a { gap: 4px; line-height: 1.2; }
  .primary-nav a:hover { filter: none; }
  .main-content { padding-top: 0; }
  .main-content > .section-title { font-size: 20px; margin: 20px 15px 14px; }
  .main-content > .subtabs { margin: 0 0 18px; }
  .subtabs a, .subtabs button { padding: 9px 18px; font-size: 14px; }
  .home-panel { margin-top: 14px; }
  .home-panel .panel-heading { padding: 8px; }
  .home-panel .draw-right { padding: 14px; }
  .home-live-buttons a { min-height: 32px; padding: 5px 10px; }
  .home-panel .draw-left { padding: 14px; }
  .mobile-history-row { border-color: var(--line); }
  #toggle-recent { height: 40px; font-weight: 600; }
  .draw-summary { padding: 20px 15px; }
  .draw-summary .draw-left { width: 100%; }
  .draw-summary .draw-left .ball-row { width: 100%; justify-content: space-between; }
  .draw-summary .draw-left .plus { margin: 0; }
  .draw-summary .issue-title, .draw-summary .upcoming-title {
    display: flex;
    width: 100%;
    justify-content: space-between;
    align-items: baseline;
    gap: 6px;
  }
  .draw-summary .issue-title > span, .draw-summary .upcoming-title > span { white-space: nowrap; }
  .draw-summary .issue-title { justify-content: flex-start; gap: 0; }
  .draw-summary .issue-title > span:nth-child(2) { margin-left: auto; }
  .draw-summary .upcoming-title { justify-content: flex-start; gap: 0; }
  .draw-summary .upcoming-title > span:nth-child(2) { margin-left: auto; }
  .draw-summary .draw-right { width: 100%; min-width: 0; }
  .draw-summary .countdown {
    display: grid;
    width: 100%;
    grid-template-columns: repeat(2,minmax(0,1fr)) 10px repeat(2,minmax(0,1fr)) 10px repeat(2,minmax(0,1fr));
    gap: 4px;
    align-items: center;
  }
  .draw-summary .digit { width: 100%; }
  .history-toolbar { padding: 14px 15px; gap: 12px; }
  .history-actions { width: 100%; gap: 8px; }
  .year-filter button, .video-history-panel .year-filter button { padding: 8px 12px; }
  #issue-search-form { width: 174px; }
  .history-toolbar .issue-search { height: 40px; font-size: 16px; }
  .video-search-button { min-width: 44px; padding: 0 7px; }
  .draw-table td { padding: 0; }
  .draw-table tbody tr { padding: 12px 15px; min-height: 126px; }
  .draw-table .replay { font-size: 0; background: transparent; border: 0; }
  .video-history-panel .history-toolbar { padding: 14px 10px; gap: 12px 8px; }
  .video-history-panel .history-toolbar h2 { font-size: 14px; }
  .live-grid.video-gallery { padding: 14px 10px; gap: 18px 10px; }
  .video-card-caption { font-size: 12px; padding-top: 8px; line-height: 1.6; }
  .live-broadcast { margin: 16px 12px 22px; }
  .live-announcement { padding: 16px; gap: 16px; }
  .live-broadcast.is-live [data-live-status] { font-size: 22px; }
  .live-broadcast-bar { padding: 10px 12px; font-size: 12px; }
  [data-live-open] { font-size: 16px; min-height: 44px; padding: 10px 20px; }
  .content-page { margin: 0; padding: 24px 20px 40px; }
  .content-page h1 { font-size: 22px; margin: 0 0 24px; }
  .content-page h2 { font-size: 17px; }
  .faq-item dt { font-size: 15px; }
  .site-footer { margin-top: 24px; padding: 22px 12px; }
  .video-dialog-heading { padding: 6px 8px 6px 14px; }
  .video-dialog-heading strong { font-size: 14px; }
  #close-video { width: 44px; height: 44px; }
  .video-controls { padding: 10px 14px 12px; }
}
@media (max-width: 350px) {
  .draw-summary { padding-left: 10px; padding-right: 10px; }
  .history-toolbar { padding-left: 10px; padding-right: 10px; }
  .year-filter button { padding-left: 8px; padding-right: 8px; }
  .draw-table tbody tr { padding-left: 10px; padding-right: 10px; }
}
