@import url("https://fonts.googleapis.com/css2?family=Noto+Sans:wght@400;500;600;700&display=swap");

:root {
  --brand-navy: #0b2a52;
  --brand-blue: #123f79;
  --brand-red: #d63b2f;
  --brand-orange: #f28a1b;
  --brand-green: #158f57;
  --bg-light: #f3f6fa;
  --bg-soft: #eef2f7;
  --text-dark: #1a1f2c;
  --text-muted: #5d6675;
  --white: #ffffff;
  --border: #d5deea;
  --shadow: 0 12px 24px rgba(11, 42, 82, 0.12);
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: "Noto Sans", "Segoe UI", "Tahoma", sans-serif;
  font-weight: 400;
  color: var(--text-dark);
  background: linear-gradient(180deg, #f7f9fc 0%, #ffffff 30%);
  line-height: 1.6;
  overflow-x: hidden;
}

h1,
h2,
h3 {
  font-weight: 700;
  letter-spacing: 0.1px;
}

a {
  color: var(--brand-blue);
  text-decoration: none;
}

a:hover,
a:focus-visible {
  text-decoration: underline;
}

img {
  max-width: 100%;
  height: auto;
}

.container {
  width: min(1180px, 92%);
  margin-inline: auto;
}

.skip-link {
  position: absolute;
  left: -9999px;
}

.skip-link:focus {
  left: 16px;
  top: 12px;
  z-index: 1000;
  background: #000;
  color: #fff;
  padding: 0.5rem 0.75rem;
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

.top-bar {
  background: linear-gradient(90deg, var(--brand-red), var(--brand-orange));
  color: var(--white);
  font-size: 0.92rem;
  padding: 0.45rem 0;
}

.top-bar strong {
  margin-right: 0.45rem;
}

@keyframes ticker-scroll {
  0% {
    transform: translateX(100%);
  }
  100% {
    transform: translateX(-100%);
  }
}

.announcement-ticker {
  overflow: hidden;
  width: 100%;
  white-space: nowrap;
}

.ticker-content {
  display: inline-block;
  padding-left: 100%;
  animation: ticker-scroll 25s linear infinite;
}

.top-bar marquee {
  width: 100%;
}

.top-bar .announce-inline {
  margin: 0;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.site-header {
  background: radial-gradient(circle at top left, #143f78, #0b2a52 70%);
  color: var(--white);
  padding: 1rem 0;
}

.brand-wrap {
  display: flex;
  align-items: center;
  gap: 0.85rem;
}

.brand-wrap.brand-clickable {
  cursor: pointer;
}

.brand-wrap.brand-clickable:focus-visible {
  outline: 2px solid #cfe0fa;
  outline-offset: 4px;
  border-radius: 8px;
}

.brand-wrap img {
  width: 52px;
  height: 52px;
}

.brand-title {
  margin: 0;
  font-size: 1.38rem;
  font-weight: 700;
  letter-spacing: 0.2px;
}

.brand-tagline {
  margin: 0.1rem 0 0;
  color: #d6e6ff;
  font-size: 0.9rem;
  font-weight: 500;
}

.header-grid {
  display: grid;
  gap: 1rem;
}

.search-wrap {
  position: relative;
}

.search-wrap input {
  width: 100%;
  border: 1px solid #8eb4e6;
  border-radius: 10px;
  padding: 0.7rem 0.85rem;
  font-size: 0.95rem;
}

.search-results {
  background: var(--white);
  color: var(--text-dark);
  border-radius: 10px;
  margin-top: 0.35rem;
  border: 1px solid var(--border);
  box-shadow: var(--shadow);
  display: none;
  max-height: 300px;
  overflow: auto;
  position: absolute;
  width: 100%;
  max-width: 100%;
  z-index: 30;
}

.search-results.active {
  display: block;
}

.search-results ul {
  list-style: none;
  margin: 0;
  padding: 0;
}

.search-results li {
  border-bottom: 1px solid var(--bg-soft);
}

.search-results a {
  display: block;
  padding: 0.65rem 0.75rem;
  color: inherit;
}

.menu-toggle {
  border: 1px solid #8eb4e6;
  background: transparent;
  color: var(--white);
  border-radius: 8px;
  padding: 0.6rem 0.9rem;
  font-size: 0.9rem;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.45rem;
}

.menu-toggle-icon {
  width: 16px;
  height: 12px;
  display: inline-block;
  background:
    linear-gradient(currentColor, currentColor) 0 0/100% 2px no-repeat,
    linear-gradient(currentColor, currentColor) 0 5px/100% 2px no-repeat,
    linear-gradient(currentColor, currentColor) 0 10px/100% 2px no-repeat;
}

.main-nav {
  background: var(--white);
  border-bottom: 1px solid var(--border);
  position: sticky;
  top: 0;
  z-index: 25;
}

.main-nav ul {
  margin: 0;
  padding: 0;
  list-style: none;
  display: none;
  flex-direction: column;
}

.main-nav ul.open {
  display: flex;
}

.main-nav a {
  padding: 0.8rem 0.5rem;
  display: block;
  font-weight: 700;
  color: var(--brand-navy);
}

.quick-links {
  padding: 1.1rem 0;
}

.quick-grid,
.card-grid {
  display: grid;
  gap: 0.7rem;
}

.quick-link {
  display: block;
  background: linear-gradient(130deg, #f0f6ff, #ffffff);
  border: 1px solid var(--border);
  border-left: 4px solid var(--brand-blue);
  border-radius: 10px;
  padding: 0.7rem 0.75rem;
  color: var(--text-dark);
  font-weight: 700;
  text-align: center;
}

main section {
  margin: 1rem 0 1.35rem;
}

.section-card {
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: 12px;
  box-shadow: 0 6px 14px rgba(21, 40, 70, 0.06);
  padding: 0.95rem;
}

.section-title {
  margin: 0 0 0.9rem;
  font-size: 1.15rem;
  color: var(--brand-navy);
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.section-title span {
  font-size: 0.76rem;
  color: var(--brand-green);
  text-transform: uppercase;
}

.latest-result-live .section-title {
  margin-bottom: 0.65rem;
}

.blink-red-tag {
  color: #ffffff !important;
  background: #d63b2f;
  border-radius: 999px;
  padding: 0.2rem 0.55rem;
  font-size: 0.72rem !important;
  letter-spacing: 0.2px;
  animation: redBlink 1s infinite;
}

.coming-soon-alert {
  display: inline-block;
  margin-right: 0.45rem;
  vertical-align: middle;
}

.latest-result-blink-list li {
  padding: 0.3rem 0;
}

.latest-result-blink-list a {
  font-weight: 700;
  font-size: 0.92rem;
  line-height: 1.3;
}

.latest-result-blink-list .meta-row {
  display: none;
}

@keyframes redBlink {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.35; }
}

.category-page-title {
  margin: 0 0 0.7rem;
  color: #ffffff;
  border-radius: 9px;
  padding: 0.6rem 0.8rem;
  font-size: 1.26rem;
  letter-spacing: 0.2px;
  box-shadow: 0 6px 14px rgba(11, 42, 82, 0.14);
}

.category-page-title.category-results {
  background: linear-gradient(135deg, #0f3c78, #1b64b7);
}

.category-page-title.category-jobs {
  background: linear-gradient(135deg, #8c1f20, #c1392b);
}

.category-page-title.category-admit {
  background: linear-gradient(135deg, #0b4a72, #1479a8);
}

.category-page-title.category-answer {
  background: linear-gradient(135deg, #0e5b4e, #1f8a70);
}

.category-page-title.category-admission {
  background: linear-gradient(135deg, #355f0f, #4f8e16);
}

.updates-list,
.link-list {
  list-style: none;
  margin: 0;
  padding: 0;
}

.updates-list li,
.link-list li {
  border-bottom: 1px dashed var(--border);
  padding: 0.58rem 0;
}

.updates-list li:last-child,
.link-list li:last-child {
  border-bottom: 0;
}

.meta-row {
  display: flex;
  flex-wrap: wrap;
  gap: 0.55rem;
  margin-top: 0.3rem;
  font-size: 0.8rem;
}

#latest-updates-title {
  position: relative;
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 0.45rem;
  animation: latestHeadingBlink 2s ease-in-out infinite;
}

#latest-updates-title::before {
  content: "";
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: #d63b2f;
  box-shadow: 0 0 0 rgba(214, 59, 47, 0.65);
  animation: latestHeadingDotPulse 1.2s ease-out infinite;
}

#latest-updates-title .latest-count {
  margin-left: auto;
  animation: latestTagBlink 2.2s ease-in-out infinite;
}

#latest-updates-title .important-heading-chip {
  display: inline-block;
  background: #d63b2f;
  color: #ffffff;
  border-radius: 999px;
  padding: 0.18rem 0.6rem;
  font-size: 0.76rem;
  font-weight: 700;
  text-transform: none;
  letter-spacing: 0.1px;
  line-height: 1.2;
  animation: importantChipBlink 1.2s ease-in-out infinite;
}

#latest-updates-list li.important-update {
  border: 1px solid #f3d7b2;
  border-left: 4px solid #d97706;
  background: linear-gradient(90deg, #fffaf2 0%, #ffffff 70%);
  border-radius: 10px;
  padding: 0.62rem 0.72rem;
  margin: 0.42rem 0;
  box-shadow: 0 5px 12px rgba(217, 119, 6, 0.12);
  animation: importantPulse 1.8s ease-in-out infinite;
}

#latest-updates-list li.important-update .important-chip {
  display: inline-block;
  margin-top: 0.35rem;
  background: #d63b2f;
  color: #ffffff;
  border-radius: 999px;
  padding: 0.14rem 0.55rem;
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.1px;
  animation: importantChipBlink 1.2s ease-in-out infinite;
}

#latest-updates-list li.important-update .updated-dot {
  display: inline-block;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: #d63b2f;
  margin-right: 0.36rem;
  box-shadow: 0 0 0 rgba(214, 59, 47, 0.7);
  animation: updatedDotPulse 1.2s ease-out infinite;
}

@keyframes latestTagBlink {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.58; }
}

@keyframes latestHeadingBlink {
  0%, 100% { color: var(--brand-navy); text-shadow: 0 0 0 rgba(214, 59, 47, 0); }
  50% { color: #8c1f20; text-shadow: 0 2px 10px rgba(214, 59, 47, 0.18); }
}

@keyframes latestHeadingDotPulse {
  0% { box-shadow: 0 0 0 0 rgba(214, 59, 47, 0.55); }
  100% { box-shadow: 0 0 0 9px rgba(214, 59, 47, 0); }
}

@keyframes importantPulse {
  0%, 100% { box-shadow: 0 5px 12px rgba(217, 119, 6, 0.12); }
  50% { box-shadow: 0 10px 18px rgba(217, 119, 6, 0.2); }
}

@keyframes importantChipBlink {
  0%, 100% { background: #d63b2f; }
  50% { background: #ef4444; }
}

@keyframes updatedDotPulse {
  0% { box-shadow: 0 0 0 0 rgba(214, 59, 47, 0.6); }
  100% { box-shadow: 0 0 0 9px rgba(214, 59, 47, 0); }
}

@media (prefers-reduced-motion: reduce) {
  #latest-updates-title,
  #latest-updates-title::before,
  #latest-updates-title .latest-count,
  #latest-updates-title .important-heading-chip,
  #latest-updates-list li.important-update,
  #latest-updates-list li.important-update .important-chip,
  #latest-updates-list li.important-update .updated-dot {
    animation: none;
  }
}

.badge {
  border-radius: 999px;
  padding: 0.15rem 0.52rem;
  font-weight: 700;
  color: var(--white);
  font-size: 0.72rem;
}

.badge.result { background: var(--brand-green); }
.badge.admit-card { background: var(--brand-orange); }
.badge.jobs,
.badge.latest-jobs { background: var(--brand-red); }
.badge.admission { background: #7a34ad; }
.badge.university { background: #1f5b76; }
.badge.bihar-board,
.badge.board { background: #2d5fa8; }
.badge.answer-key { background: #006b8f; }
.badge.syllabus { background: #6a3f00; }
.badge.bihar-police { background: #3a4f8d; }
.badge.bpsc { background: #9a2e2b; }
.badge.bssc { background: #7a354f; }
.badge.btsc { background: #7a5f00; }
.badge.bceceb { background: #116d77; }

.status-badge {
  border-radius: 999px;
  padding: 0.15rem 0.52rem;
  font-weight: 700;
  color: var(--white);
  font-size: 0.72rem;
}

.status-released { background: #1f9d5e; }
.status-new { background: #d63b2f; }
.status-expected { background: #f28a1b; }
.status-latest-update { background: #1f61b2; }
.status-to-be-updated { background: #6b7280; }
.status-closed { background: #3e4652; }

.important-grid {
  display: grid;
  gap: 0.65rem;
}

.important-grid a {
  display: block;
  background: #fff7f6;
  border: 1px solid #f0ccc8;
  border-left: 4px solid var(--brand-red);
  border-radius: 10px;
  padding: 0.68rem;
  font-weight: 600;
  color: #7f251f;
}

.important-grid a span {
  display: inline-block;
  margin-left: 0.4rem;
}

.category-box {
  border: 1px solid var(--border);
  border-radius: 12px;
  background: #fcfdff;
  padding: 0.85rem;
}

.category-panels {
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0.45rem;
}

.category-panel {
  display: flex;
  flex-direction: column;
  padding: 0;
  overflow: hidden;
  border-width: 1px;
  border-radius: 8px;
}

.category-panel-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.28rem;
  padding: 0.34rem 0.3rem;
  background: #5f3fa5;
}

.category-panel-head h3 {
  margin: 0;
  color: #121212;
  background: rgba(255, 255, 255, 0.2);
  border-radius: 5px;
  padding: 0.2rem 0.28rem;
  font-size: 0.74rem;
  font-weight: 700;
}

.category-panel-head .inline-btn {
  background: #d12d2d;
  border: 1px solid #f4b0b0;
  min-height: 28px;
  font-size: 0.68rem;
  padding: 0.16rem 0.36rem;
}

.category-panel-list {
  flex: 1;
  padding: 0.2rem 0.26rem 0.28rem;
}

.category-panel-list li {
  padding: 0.26rem 0;
}

.category-panel-list a {
  color: #1a1f2c;
  font-weight: 600;
  line-height: 1.35;
  font-size: 0.72rem;
}

.category-panel .meta-row {
  margin-top: 0.12rem;
  font-size: 0.64rem;
}

.category-panel .meta-row span {
  display: inline-block;
  background: #fff3dd;
  border: 1px solid #f5d8a8;
  color: #c24c0b;
  border-radius: 999px;
  padding: 0.06rem 0.26rem;
  font-weight: 700;
}

.category-panel-foot {
  padding: 0.28rem 0.26rem 0.34rem;
  border-top: 1px solid #e9eef7;
  background: #ffffff;
}

.category-panel-foot .inline-btn {
  width: 100%;
  text-align: center;
  background: #d12d2d;
  border: 1px solid #f4b0b0;
  min-height: 26px;
  font-size: 0.68rem;
  padding: 0.14rem 0.34rem;
}

#latest-results.category-panel .category-panel-head { background: linear-gradient(135deg, #a57bd8, #8b63c9); }
#latest-jobs.category-panel .category-panel-head { background: linear-gradient(135deg, #f59e0b, #f97316); }
#admit-cards.category-panel .category-panel-head { background: linear-gradient(135deg, #1790b6, #1479a8); }
#answer-keys.category-panel .category-panel-head { background: linear-gradient(135deg, #1f8a70, #0e5b4e); }
#admissions.category-panel .category-panel-head { background: linear-gradient(135deg, #5b8e16, #355f0f); }
#syllabus.category-panel .category-panel-head { background: linear-gradient(135deg, #8a6d1f, #6a4c00); }
#bihar-board-updates.category-panel .category-panel-head { background: linear-gradient(135deg, #1b64b7, #0f3c78); }
#bihar-police-updates.category-panel .category-panel-head { background: linear-gradient(135deg, #2f4fa2, #1f3872); }
#bpsc-updates.category-panel .category-panel-head { background: linear-gradient(135deg, #c1392b, #8c1f20); }
#university-updates.category-panel .category-panel-head { background: linear-gradient(135deg, #3b7a78, #2a5755); }

.category-box h3 {
  margin: 0 0 0.7rem;
  font-size: 1.15rem;
  color: var(--brand-navy);
}

.category-box.focus-category h3 {
  color: #ffffff;
  border-radius: 8px;
  padding: 0.5rem 0.72rem;
  letter-spacing: 0.2px;
  box-shadow: 0 4px 10px rgba(11, 42, 82, 0.12);
}

#latest-results.focus-category h3 {
  background: linear-gradient(135deg, #0f3c78, #1b64b7);
}

#latest-jobs.focus-category h3 {
  background: linear-gradient(135deg, #8c1f20, #c1392b);
}

#admit-cards.focus-category h3 {
  background: linear-gradient(135deg, #0b4a72, #1479a8);
}

#answer-keys.focus-category h3 {
  background: linear-gradient(135deg, #0e5b4e, #1f8a70);
}

#admissions.focus-category h3 {
  background: linear-gradient(135deg, #355f0f, #4f8e16);
}

.inline-btn,
.action-btn {
  display: inline-block;
  background: var(--brand-blue);
  color: var(--white);
  border: 0;
  border-radius: 7px;
  font-size: 0.85rem;
  font-weight: 600;
  padding: 0.38rem 0.72rem;
  text-decoration: none;
}

.action-btn.alert {
  background: var(--brand-red);
}

.action-btn.success {
  background: var(--brand-green);
}

.bihar-focus {
  background: linear-gradient(135deg, #0d2f5e 0%, #184e94 100%);
  color: var(--white);
}

.bihar-focus p {
  margin: 0.5rem 0;
  color: #e8f0ff;
}

footer {
  background: #0a2042;
  color: #d6e2f8;
  padding: 1.5rem 0;
}

.footer-grid {
  display: grid;
  gap: 1rem;
}

footer h3 {
  margin-top: 0;
  color: #ffffff;
  font-size: 1rem;
}

footer ul {
  list-style: none;
  margin: 0;
  padding: 0;
}

footer li {
  margin-bottom: 0.4rem;
}

footer a {
  color: #d6e2f8;
}

.breadcrumb {
  font-size: 0.82rem;
  padding: 0.55rem 0;
}

.breadcrumb ol {
  list-style: none;
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem;
  margin: 0;
  padding: 0;
}

.breadcrumb li::after {
  content: "/";
  margin-left: 0.35rem;
  color: var(--text-muted);
}

.breadcrumb li:last-child::after {
  content: "";
}

.post-header h1 {
  margin-bottom: 0.3rem;
  font-size: 1.45rem;
}

.notice-box {
  border-left: 4px solid var(--brand-orange);
  background: #fff6ea;
  border-radius: 8px;
  padding: 0.8rem;
  margin: 0.8rem 0;
}

.highlight-grid {
  display: grid;
  gap: 0.5rem;
}

.highlight-item {
  background: #f8fbff;
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 0.58rem;
  display: grid;
  grid-template-columns: 150px minmax(0, 1fr);
  gap: 0.4rem;
  align-items: start;
}

.highlight-item strong {
  display: block;
  margin: 0;
  overflow-wrap: anywhere;
  word-break: break-word;
  line-height: 1.35;
}

.table-wrap {
  overflow-x: visible;
}

table {
  width: 100%;
  border-collapse: collapse;
  table-layout: fixed;
}

th,
td {
  border: 1px solid var(--border);
  padding: 0.58rem;
  text-align: left;
  font-size: 0.92rem;
  white-space: normal;
  overflow-wrap: anywhere;
  word-break: break-word;
}

th {
  background: #eaf2ff;
}

.steps {
  padding-left: 1rem;
}

.links-table a {
  font-weight: 700;
}

.faq-item {
  border: 1px solid var(--border);
  border-radius: 9px;
  margin-bottom: 0.55rem;
  overflow: hidden;
}

.faq-question {
  width: 100%;
  border: 0;
  background: #f8fbff;
  text-align: left;
  padding: 0.72rem;
  font-size: 0.95rem;
  font-weight: 700;
  cursor: pointer;
}

.faq-answer {
  padding: 0 0.72rem 0.72rem;
  display: none;
}

.faq-item.open .faq-answer {
  display: block;
}

.disclaimer-box {
  border: 1px solid #f4d2ce;
  background: #fff9f9;
  border-left: 4px solid var(--brand-red);
  border-radius: 8px;
  padding: 0.75rem;
}

.related-grid {
  display: grid;
  gap: 0.6rem;
}

.related-grid a {
  display: block;
  border: 1px solid var(--border);
  border-radius: 9px;
  padding: 0.65rem;
  background: #fcfdff;
}

.form-grid {
  display: grid;
  gap: 0.75rem;
}

input,
textarea,
select {
  width: 100%;
  padding: 0.68rem;
  border: 1px solid var(--border);
  border-radius: 8px;
  font: inherit;
}

button[type="submit"] {
  background: var(--brand-blue);
  color: var(--white);
  border: 0;
  border-radius: 8px;
  padding: 0.72rem;
  font-weight: 700;
}

.back-to-top {
  position: fixed;
  right: 14px;
  bottom: 14px;
  border: 0;
  border-radius: 999px;
  width: 44px;
  height: 44px;
  background: var(--brand-blue);
  color: var(--white);
  font-size: 1rem;
  display: none !important;
}

.back-to-top.show {
  display: none !important;
  align-items: center;
  justify-content: center;
}

.keyword-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
}

.keyword-chip {
  display: inline-block;
  background: #edf4ff;
  border: 1px solid #cfe0fa;
  border-radius: 999px;
  padding: 0.4rem 0.7rem;
  font-size: 0.84rem;
  font-weight: 700;
  color: #1f3f6e;
}

.official-links {
  display: grid;
  gap: 0.6rem;
}

.official-links a {
  display: block;
  border: 1px solid var(--border);
  background: #f8fbff;
  border-left: 4px solid var(--brand-blue);
  border-radius: 10px;
  padding: 0.65rem 0.7rem;
  font-weight: 700;
}

@media (min-width: 769px) {
  .header-grid {
    grid-template-columns: 1.4fr 1fr auto;
    align-items: center;
  }

  .main-nav ul,
  .main-nav ul.open {
    display: flex;
    flex-direction: row;
    flex-wrap: wrap;
    gap: 0.15rem;
  }

  .main-nav a {
    padding: 0.85rem 0.7rem;
  }

  .menu-toggle {
    display: none;
  }

  .quick-grid {
    grid-template-columns: repeat(4, minmax(0, 1fr));
  }

  .important-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .card-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .highlight-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .footer-grid {
    grid-template-columns: repeat(4, minmax(0, 1fr));
  }

  .official-links {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (min-width: 1000px) {
  .card-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .category-panels {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .important-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .official-links {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}

@media (max-width: 1024px) {
  .container {
    width: min(1200px, 94%);
  }

  .header-grid {
    grid-template-columns: 1fr;
    gap: 0.8rem;
  }

  .brand-title {
    font-size: 1.24rem;
  }

  .card-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .important-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 768px) {
  body {
    font-size: 15px;
  }

  .top-bar {
    font-size: 0.83rem;
    padding: 0.34rem 0;
  }

  .top-bar marquee {
    scrollamount: 3;
  }

  .brand-wrap {
    align-items: flex-start;
  }

  .brand-wrap img {
    width: 46px;
    height: 46px;
  }

  .brand-tagline {
    font-size: 0.8rem;
  }

  .menu-toggle {
    width: 100%;
    min-height: 44px;
    font-weight: 700;
  }

  .main-nav {
    position: static;
  }

  .main-nav ul.open {
    border-top: 1px solid #e8edf6;
    background: #fff;
    border-radius: 0 0 8px 8px;
  }

  .main-nav a {
    padding: 0.74rem 0.5rem;
    border-top: 1px solid #edf2f9;
    font-size: 0.92rem;
  }

  .search-wrap input {
    min-height: 44px;
    padding: 0.64rem 0.72rem;
    font-size: 0.92rem;
  }

  .search-results {
    left: 0;
    right: 0;
    width: auto;
    margin-top: 0.25rem;
    max-height: 240px;
    border-radius: 8px;
  }

  .quick-grid,
  .card-grid,
  .important-grid,
  .official-links {
    grid-template-columns: 1fr;
  }

  .category-panels {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .quick-links {
    display: none;
  }

  .quick-grid {
    gap: 0.5rem;
  }

  .quick-link {
    padding: 0.58rem 0.62rem;
    font-size: 0.9rem;
  }

  main section {
    margin: 0.7rem 0 0.9rem;
  }

  .inline-btn,
  .action-btn,
  button[type="submit"] {
    min-height: 44px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
  }

  .section-card {
    padding: 0.76rem;
    border-radius: 10px;
    box-shadow: 0 2px 8px rgba(20, 40, 70, 0.07);
  }

  .section-title {
    font-size: 0.98rem;
    gap: 0.4rem;
    margin-bottom: 0.58rem;
  }

  .section-title span {
    font-size: 0.68rem;
  }

  .latest-result-live .section-card,
  .latest-result-live {
    padding: 0.62rem;
  }

  .latest-result-blink-list li {
    padding: 0.26rem 0;
  }

  .latest-result-blink-list a {
    font-size: 0.86rem;
    line-height: 1.25;
  }

  .meta-row {
    gap: 0.35rem;
    font-size: 0.76rem;
  }

  .updates-list li,
  .link-list li {
    padding: 0.44rem 0;
  }

  .category-box {
    padding: 0.7rem;
    border-radius: 10px;
  }

  .important-grid a,
  .official-links a {
    padding: 0.56rem 0.62rem;
    font-size: 0.9rem;
  }

  .keyword-chip {
    font-size: 0.76rem;
    padding: 0.32rem 0.58rem;
  }

  .breadcrumb {
    font-size: 0.78rem;
    padding: 0.45rem 0;
  }

  table {
    table-layout: fixed;
  }

  .footer-grid {
    grid-template-columns: 1fr;
    gap: 0.8rem;
  }

  .hide-on-mobile {
    display: none;
  }
}

@media (max-width: 480px) {
  body {
    font-size: 14px;
  }

  .container {
    width: 95%;
  }

  .top-bar {
    padding: 0.32rem 0;
  }

  .top-bar marquee {
    font-size: 0.78rem;
  }

  .brand-title {
    font-size: 1.02rem;
  }

  .brand-tagline {
    font-size: 0.72rem;
  }

  .search-wrap input {
    font-size: 0.88rem;
    min-height: 42px;
  }

  .search-results a {
    padding: 0.52rem 0.58rem;
    font-size: 0.88rem;
  }

  .section-card {
    padding: 0.68rem;
  }

  .section-title {
    font-size: 0.93rem;
  }

  .section-title span {
    display: none;
  }

  .latest-result-live .section-title {
    margin-bottom: 0.45rem;
  }

  .latest-result-blink-list li {
    padding: 0.22rem 0;
  }

  .latest-result-blink-list a {
    font-size: 0.82rem;
    line-height: 1.2;
  }

  .updates-list li,
  .link-list li {
    padding: 0.4rem 0;
  }

  .quick-link {
    font-size: 0.86rem;
    padding: 0.52rem 0.56rem;
  }

  .category-panel-head {
    padding: 0.3rem 0.24rem;
  }

  .category-panel-head h3 {
    font-size: 0.7rem;
    padding: 0.18rem 0.24rem;
  }

  .category-panel-head .inline-btn {
    min-height: 25px;
    font-size: 0.66rem;
    padding: 0.14rem 0.28rem;
  }

  .category-panel-foot {
    padding: 0.22rem 0.2rem 0.28rem;
  }

  .category-panel-foot .inline-btn {
    min-height: 24px;
    font-size: 0.64rem;
  }

  .category-panel-list {
    padding: 0.18rem 0.2rem 0.2rem;
  }

  .category-panel-list a {
    font-size: 0.68rem;
  }

  .inline-btn {
    font-size: 0.8rem;
    min-height: 40px;
    padding: 0.35rem 0.6rem;
  }

  .highlight-item {
    grid-template-columns: 110px minmax(0, 1fr);
    gap: 0.32rem;
  }

  .post-header h1 {
    font-size: 1.12rem;
    line-height: 1.35;
  }

  .faq-question {
    font-size: 0.86rem;
    padding: 0.62rem;
  }

  .back-to-top {
    width: 40px;
    height: 40px;
    right: 10px;
    bottom: 10px;
  }
}
