/* ========================================================
   sarkari hith - ADVANCED RESPONSIVE DESIGN SYSTEM
   Full Mobile, Tablet, Phablet & Ultra-Compact Support
   ======================================================== */

/* ========================================================
   GLOBAL MOBILE-FIRST ANTI-OVERFLOW RULES
   ======================================================== */
html,
body {
  overflow-x: hidden;
  width: 100%;
  max-width: 100%;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

img,
svg,
video,
canvas,
audio,
iframe,
embed,
object {
  max-width: 100%;
  height: auto;
}

/* Form input iOS zoom prevention (inputs < 16px trigger auto-zoom in Safari) */
@media (max-width: 768px) {

  input,
  select,
  textarea {
    font-size: 16px !important;
  }
}

/* ========================================================
   1. LAPTOPS & TABLET LANDSCAPE (Max-Width: 1024px)
   ======================================================== */
@media (max-width: 1024px) {
  .container {
    max-width: 100%;
    padding-left: 1.25rem;
    padding-right: 1.25rem;
  }

  /* Core Matrix: Switch to Tabbed View */
  .matrix-grid {
    grid-template-columns: 1fr;
    gap: 0;
  }

  .matrix-mobile-tabs {
    display: flex;
    position: sticky;
    top: 56px;
    z-index: 50;
    background: rgba(255, 255, 255, 0.92);
    border: 1px solid rgba(15, 23, 42, 0.08);
    border-radius: var(--radius-lg);
    padding: 0.35rem;
    margin-bottom: 1.25rem;
    box-shadow: 0 4px 20px rgba(15, 23, 42, 0.08);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
  }

  .matrix-tab-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.4rem;
    flex: 1 1 0;
    text-align: center;
    padding: 0.6rem 0.5rem;
    font-size: 0.85rem;
    border-radius: var(--radius-md);
  }

  /* Hide columns unless active tab */
  .matrix-column {
    display: none;
    border-radius: var(--radius-lg);
  }

  .matrix-column.is-mobile-active {
    display: flex;
    animation: fadeInTab 0.25s ease-out;
  }

  @keyframes fadeInTab {
    from {
      opacity: 0;
      transform: translateY(4px);
    }

    to {
      opacity: 1;
      transform: translateY(0);
    }
  }

  /* Secondary Items Grid */
  .secondary-items-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 1rem;
  }

  /* Footer Layout */
  .footer-top {
    grid-template-columns: repeat(2, 1fr);
    gap: 2rem;
  }

  .footer-about {
    grid-column: 1 / -1;
  }
}

/* ========================================================
   2. TABLETS & SMARTPHONES (Max-Width: 768px)
   ======================================================== */
@media (max-width: 768px) {

  /* Extra bottom padding on body for the fixed mobile bottom bar */
  body {
    padding-bottom: calc(58px + env(safe-area-inset-bottom, 0px));
  }

  .container {
    padding-left: 0.85rem;
    padding-right: 0.85rem;
  }

  /* Top Live Ticker Bar */
  .top-announcement-bar {
    padding: 0.25rem 0;
    font-size: 0.75rem;
  }

  .top-bar-inner {
    gap: 0.4rem;
  }

  .live-badge {
    padding: 0.12rem 0.4rem;
    font-size: 0.65rem;
    letter-spacing: 0.2px;
  }

  .ticker-wrapper {
    min-width: 0;
    flex: 1;
    overflow: hidden;
  }

  .ticker-content {
    font-size: 0.75rem;
  }

  /* Sleek Sticky Site Header */
  .site-header {
    padding: 0.45rem 0;
    position: sticky;
    top: 0;
    z-index: 100;
    background: rgba(255, 255, 255, 0.88);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border-bottom: 1px solid rgba(15, 23, 42, 0.08);
  }

  .header-inner {
    display: flex;
    flex-wrap: nowrap;
    align-items: center;
    justify-content: space-between;
    gap: 0.5rem;
    padding: 0;
  }

  .brand {
    gap: 0.45rem;
  }

  .brand-logo-frame {
    width: 32px;
    height: 32px;
    border-radius: 8px;
  }

  .brand-title {
    font-size: 1.15rem;
    letter-spacing: -0.3px;
    font-weight: 800;
  }

  .brand-subtitle {
    display: none !important;
    /* Hide subtitle to keep 1-row header */
  }

  /* Hide duplicate header navigation on mobile:
     Bottom navigation bar handles all primary app tabs */
  .header-nav {
    display: none !important;
  }

  /* Header Action Buttons */
  .header-actions {
    display: flex;
    align-items: center;
    gap: 0.35rem;
    margin-left: auto;
  }

  .btn-job-alerts {
    display: none !important;
    /* Job alerts accessible via bottom bar */
  }

  .btn-tracked-nav {
    display: inline-flex !important;
    width: 34px;
    height: 34px;
    padding: 0;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
  }

  .btn-tracked-nav span {
    display: none !important;
  }

  /* Clean Hero Gateway Card */
  .hero-gateway-card {
    padding: 1.25rem 1rem;
    margin: 0.65rem 0 0.85rem;
    border-radius: 20px;
    background: rgba(255, 255, 255, 0.85);
    border: 1px solid rgba(15, 23, 42, 0.08);
    box-shadow: 0 8px 30px rgba(15, 23, 42, 0.08);
  }

  /* Hide murky parliament background on mobile for high contrast */
  .hero-parliament-bg {
    display: none !important;
  }

  .hero-content-col {
    gap: 0.65rem;
    max-width: 100%;
  }

  .hero-eyebrow-tag {
    font-size: 0.68rem;
    padding: 2px 8px;
    margin-bottom: 0.2rem;
  }

  .hero-display-title {
    font-size: clamp(1.3rem, 5.2vw, 1.55rem);
    line-height: 1.25;
    letter-spacing: -0.02em;
    margin-bottom: 0.25rem;
  }

  .hero-display-subtitle {
    font-size: 0.78rem;
    line-height: 1.35;
    color: var(--text-muted);
  }

  /* Hero Search Bar */
  .hero-search-wrapper {
    max-width: 100%;
    width: 100%;
    margin-top: 0.25rem;
    margin-bottom: 0.25rem;
  }

  .hero-search-bar {
    padding: 0.2rem 0.25rem 0.2rem 0.75rem;
    height: 44px;
    border-radius: 999px;
  }

  .hero-search-icon {
    width: 17px;
    height: 17px;
    margin-right: 0.35rem;
  }

  .hero-search-input {
    font-size: 0.85rem;
    min-width: 0;
  }

  .search-badge-hint {
    display: none !important;
  }

  .hero-search-btn {
    padding: 0 0.9rem;
    height: 36px;
    font-size: 0.8rem;
    border-radius: 999px;
  }

  /* Quick Category Pills Swipe Row */
  .hero-quick-tags-row {
    width: 100%;
    overflow: hidden;
  }

  .hero-tags-list {
    flex-wrap: nowrap;
    overflow-x: auto;
    white-space: nowrap;
    padding-bottom: 0.2rem;
    gap: 0.35rem;
    scrollbar-width: none;
    -webkit-overflow-scrolling: touch;
    width: 100%;
  }

  .hero-tags-list::-webkit-scrollbar {
    display: none;
  }

  .quick-tag-pill {
    flex-shrink: 0;
    font-size: 0.72rem;
    padding: 0.22rem 0.65rem;
    border-radius: 999px;
  }

  .quick-tag-next {
    display: none !important;
  }

  /* Category Chips Horizontal Edge-to-Edge Scroll */
  .sector-chips-scroll {
    margin-left: -0.85rem;
    margin-right: -0.85rem;
    padding-left: 0.85rem;
    padding-right: 0.85rem;
    padding-bottom: 0.25rem;
    margin-bottom: 0.85rem;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
  }

  .sector-chips-scroll::-webkit-scrollbar {
    display: none;
  }

  .sector-chip {
    padding: 0.35rem 0.75rem;
    font-size: 0.78rem;
    border-radius: 999px;
    flex-shrink: 0;
  }

  /* ========================================================
     MOBILE QUICK FILTER ROW & COLLAPSIBLE CONTROLS
     Saves 350px+ vertical height; clean native experience
     ======================================================== */
  .filter-controls-bar {
    flex-direction: column;
    align-items: stretch;
    padding: 0.55rem 0.75rem;
    gap: 0;
    margin-bottom: 0.85rem;
    border-radius: 14px;
  }

  .mobile-filter-bar-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    width: 100%;
    gap: 0.5rem;
  }

  .btn-toggle-mobile-filters {
    display: inline-flex;
    align-items: center;
    gap: 0.45rem;
    background: var(--bg-surface-soft);
    border: 1px solid var(--border-color);
    padding: 0.42rem 0.75rem;
    border-radius: 999px;
    font-size: 0.78rem;
    font-weight: 600;
    color: var(--text-primary);
    cursor: pointer;
    transition: all var(--transition-fast);
  }

  .btn-toggle-mobile-filters:active {
    transform: scale(0.98);
  }

  .mobile-filter-icon {
    color: var(--primary-red);
  }

  .mobile-filter-chevron {
    color: var(--text-muted);
    transition: transform 0.25s ease;
  }

  .btn-toggle-mobile-filters[aria-expanded="true"] .mobile-filter-chevron {
    transform: rotate(180deg);
  }

  .mobile-filter-count-badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: var(--primary-red);
    color: var(--text-inverse);
    font-size: 0.65rem;
    font-weight: 700;
    min-width: 18px;
    height: 18px;
    border-radius: 999px;
    padding: 0 4px;
  }

  .mobile-filter-quick-actions {
    display: flex;
    align-items: center;
    gap: 0.35rem;
  }

  .mobile-active-toggle {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    background: var(--bg-surface-soft);
    border: 1px solid var(--border-color);
    padding: 0.32rem 0.65rem;
    border-radius: 999px;
    font-size: 0.72rem;
    font-weight: 600;
    color: var(--text-secondary);
    cursor: pointer;
    user-select: none;
  }

  .mobile-active-toggle input {
    display: none;
  }

  .mobile-active-track {
    width: 24px;
    height: 14px;
    background: var(--border-subtle);
    border-radius: 999px;
    position: relative;
    transition: background 0.2s ease;
  }

  .mobile-active-thumb {
    position: absolute;
    top: 2px;
    left: 2px;
    width: 10px;
    height: 10px;
    background: #ffffff;
    border-radius: 50%;
    transition: transform 0.2s ease;
    box-shadow: 0 1px 2px rgba(15, 23, 42, 0.08);
  }

  .mobile-active-toggle input:checked+.mobile-active-track {
    background: #16a34a;
  }

  .mobile-active-toggle input:checked+.mobile-active-track .mobile-active-thumb {
    transform: translateX(10px);
  }

  .btn-reset-filters-mobile {
    width: 30px;
    height: 30px;
    border-radius: 50%;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: var(--bg-surface-soft);
    border: 1px solid var(--border-color);
    color: var(--text-muted);
    cursor: pointer;
    transition: all var(--transition-fast);
  }

  .btn-reset-filters-mobile:hover {
    color: var(--primary-red);
    border-color: var(--primary-red);
  }

  /* Collapsible Filter Dropdowns Drawer on Mobile */
  .filter-group-dropdowns {
    flex-direction: column;
    align-items: stretch;
    width: 100%;
    gap: 0.45rem;
    max-height: 0;
    opacity: 0;
    overflow: hidden;
    pointer-events: none;
    transition: max-height 0.3s cubic-bezier(0.16, 1, 0.3, 1), opacity 0.25s ease, margin-top 0.25s ease;
  }

  .filter-group-dropdowns.is-mobile-expanded {
    max-height: 480px;
    opacity: 1;
    pointer-events: auto;
    margin-top: 0.65rem;
    padding-top: 0.65rem;
    border-top: 1px solid var(--border-color);
  }

  .select-filter-wrapper {
    width: 100%;
  }

  .select-filter {
    width: 100%;
    font-size: 0.84rem !important;
    padding: 0.55rem 2rem 0.55rem 0.75rem;
    border-radius: var(--radius-sm);
  }

  /* Hide Desktop-only redundant controls on mobile */
  .desktop-filter-toggle,
  .desktop-filter-meta {
    display: none !important;
  }

  /* Candidate Degree Match Scope Selector */
  .degree-scope-container {
    padding: 0.65rem;
    margin-top: 0.35rem;
    margin-bottom: 0.85rem;
    border-radius: 12px;
  }

  .degree-scope-header {
    flex-direction: column;
    align-items: flex-start;
    gap: 0.2rem;
    margin-bottom: 0.45rem;
  }

  .degree-scope-title {
    font-size: 0.82rem;
  }

  .scope-stat-summary {
    font-size: 0.7rem;
  }

  .degree-scope-pills {
    width: 100%;
    gap: 0.35rem;
  }

  .scope-pill {
    flex: 1 1 100%;
    width: 100%;
    justify-content: space-between;
    font-size: 0.75rem;
    padding: 0.4rem 0.65rem;
  }

  /* Hide pushy promotional callout banner on mobile to declutter */
  .job-alerts-banner {
    display: none !important;
  }

  /* Trending Spotlight Horizontal Carousel (Smooth native swipe) */
  .trending-section {
    margin-bottom: 1.25rem;
  }

  .section-heading-row {
    margin-bottom: 0.5rem;
  }

  .trending-title-main {
    font-size: 1.15rem;
  }

  .trending-subtitle {
    font-size: 0.75rem;
  }

  .trending-grid {
    display: flex !important;
    overflow-x: auto;
    scroll-snap-type: x mandatory;
    gap: 0.65rem;
    padding: 0.15rem 0.85rem 0.5rem;
    scrollbar-width: none;
    -webkit-overflow-scrolling: touch;
    margin-left: -0.85rem;
    margin-right: -0.85rem;
  }

  .trending-grid::-webkit-scrollbar {
    display: none;
  }

  .trending-card {
    flex: 0 0 74vw !important;
    max-width: 275px;
    min-height: 120px;
    scroll-snap-align: start;
    padding: 0.75rem 0.85rem;
    border-radius: 12px;
  }

  .trending-card-title {
    font-size: 0.84rem;
    line-height: 1.35;
    -webkit-line-clamp: 2;
  }

  .trending-card-footer {
    font-size: 0.72rem;
  }

  /* ========================================================
     CORE MATRIX MOBILE TABS & HIGH-DENSITY LISTINGS
     Fixes nested scroll trap; shows 5-6 jobs per screen
     ======================================================== */
  .matrix-section {
    margin-bottom: 1.5rem;
  }

  .matrix-mobile-tabs {
    position: sticky;
    top: 48px;
    z-index: 50;
    margin-bottom: 0.65rem;
    padding: 3px;
    gap: 3px;
    border-radius: 10px;
    background: var(--bg-surface);
    border: 1px solid var(--border-color);
    box-shadow: 0 4px 12px rgba(15, 23, 42, 0.08);
  }

  .matrix-tab-btn {
    padding: 0.45rem 0.25rem;
    font-size: 0.78rem;
    font-weight: 600;
    border-radius: 8px;
  }

  .matrix-tab-btn.is-active {
    background: var(--primary-red);
    color: var(--text-inverse);
    box-shadow: 0 2px 6px rgba(192, 27, 34, 0.35);
  }

  /* Eliminates mobile gesture traps: Page scrolls naturally */
  .column-items-list {
    max-height: none !important;
    overflow-y: visible !important;
    overflow-x: hidden;
  }

  /* High-density, clutter-free job cards */
  .matrix-item {
    padding: 0.65rem 0.85rem !important;
    gap: 0.45rem !important;
    align-items: flex-start !important;
    border-bottom: 1px solid var(--border-color);
  }

  /* Hide circular avatar emoji on mobile for maximum title width */
  .matrix-item-avatar {
    display: none !important;
  }

  .matrix-item-content {
    gap: 0.22rem;
    width: 100%;
    min-width: 0;
  }

  .matrix-item-title {
    font-size: 0.85rem !important;
    font-weight: 600 !important;
    line-height: 1.35 !important;
    color: var(--text-primary);
  }

  .matrix-badge-new {
    font-size: 0.58rem;
    padding: 1px 4px;
    vertical-align: 1px;
  }

  .matrix-item-badges {
    flex-wrap: wrap;
    gap: 0.25rem;
    margin-top: 0.1rem;
  }

  .matrix-item-badges .badge {
    font-size: 0.65rem !important;
    padding: 1.5px 5px !important;
    border-radius: 4px;
  }

  .matrix-item-meta-row {
    font-size: 0.7rem;
    gap: 0.35rem;
    color: var(--text-muted);
    margin-top: 0.1rem;
  }

  .matrix-item-action {
    padding-top: 0.15rem;
  }

  .matrix-circle-chevron {
    width: 20px;
    height: 20px;
    background: transparent;
    border: none;
    color: var(--text-muted);
  }

  /* Secondary Tabbed Section */
  .secondary-section {
    margin-bottom: 1.5rem;
  }

  .tab-nav-bar {
    display: flex;
    flex-wrap: nowrap;
    overflow-x: auto;
    white-space: nowrap;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
    gap: 0.25rem;
    margin-bottom: 0.65rem;
    border-bottom: 1px solid var(--border-color);
  }

  .tab-nav-bar::-webkit-scrollbar {
    display: none;
  }

  .tab-nav-item {
    flex-shrink: 0;
    padding: 0.45rem 0.65rem;
    font-size: 0.78rem;
  }

  .secondary-items-grid {
    grid-template-columns: 1fr;
    gap: 0.5rem;
  }

  .secondary-card {
    padding: 0.65rem 0.85rem;
    border-radius: 10px;
  }

  .secondary-card-title {
    font-size: 0.84rem;
  }

  /* ========================================================
     MODAL DIALOGS: NATIVE MOBILE BOTTOM SHEETS
  ======================================================== */
  .modal-overlay {
    padding: 0;
    align-items: flex-end;
  }

  .modal-dialog,
  .modal-container,
  .alerts-modal-dialog,
  .track-modal-dialog {
    width: 100% !important;
    max-width: 100% !important;
    height: 92vh !important;
    max-height: 92vh !important;
    border-radius: 20px 20px 0 0 !important;
    border-bottom: none !important;
    transform: translateY(100%);
    transition: transform 0.32s cubic-bezier(0.16, 1, 0.3, 1);
    box-shadow: 0 -10px 40px rgba(15, 23, 42, 0.08);
    background-color: var(--bg-surface);
  }

  .modal-overlay.is-open .modal-dialog,
  .modal-overlay.is-open .modal-container,
  .modal-overlay.is-open .alerts-modal-dialog,
  .modal-overlay.is-open .track-modal-dialog {
    transform: translateY(0);
  }

  .modal-header {
    padding: 0.75rem 1rem;
    position: sticky;
    top: 0;
    z-index: 10;
    background-color: var(--bg-surface);
    border-bottom: 1px solid var(--border-color);
  }

  .modal-title-group h3,
  .modal-item-title {
    font-size: 1.05rem;
    line-height: 1.3;
  }

  .modal-body,
  .alerts-modal-body {
    padding: 0.85rem 1rem;
    -webkit-overflow-scrolling: touch;
    overflow-y: auto;
  }

  .modal-meta-grid {
    grid-template-columns: 1fr;
    gap: 0.65rem;
  }

  .modal-info-box {
    padding: 0.75rem;
    border-radius: 8px;
  }

  .vacancy-table-wrapper {
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    border-radius: var(--radius-sm);
    border: 1px solid var(--border-color);
  }

  .modal-vacancy-table th,
  .modal-vacancy-table td {
    padding: 0.4rem 0.5rem;
    font-size: 0.78rem;
  }

  .modal-actions-row,
  .modal-actions,
  .alerts-modal-actions {
    flex-direction: column;
    gap: 0.55rem;
  }

  .btn-primary-action,
  .btn-secondary-action,
  .btn-primary-alert,
  .btn-secondary-alert,
  .btn-track-action {
    width: 100% !important;
    justify-content: center;
    padding: 0.75rem 1.15rem;
    font-size: 0.9rem;
  }

  /* SEO Guide & FAQ Section Mobile Adaptations */
  .seo-guide-card {
    padding: 1rem 0.85rem;
    margin: 1.25rem 0 1.5rem 0;
    border-radius: 12px;
  }

  .seo-guide-title {
    font-size: 1.05rem;
    line-height: 1.3;
  }

  .seo-guide-intro {
    font-size: 0.8rem;
    line-height: 1.4;
  }

  .seo-quick-grid-row {
    grid-template-columns: 1fr;
    gap: 0.75rem;
  }

  .seo-editorial-articles {
    grid-template-columns: 1fr;
    gap: 0.65rem;
  }

  .seo-article-card {
    padding: 0.75rem;
    border-radius: 8px;
  }

  .seo-article-card h3 {
    font-size: 0.85rem;
    margin-bottom: 0.3rem;
  }

  .seo-article-card p {
    font-size: 0.78rem;
    line-height: 1.4;
  }

  /* Footer Layout */
  .footer-top {
    grid-template-columns: 1fr;
    gap: 1.25rem;
  }

  .footer-bottom {
    flex-direction: column;
    gap: 0.5rem;
    text-align: center;
    font-size: 0.75rem;
  }
}

/* ========================================================
   3. MOBILE PHONES & PHABLETS (Max-Width: 640px)
   ======================================================== */
@media (max-width: 640px) {
  .header-actions .btn-job-alerts span:not(.alerts-badge) {
    display: none;
    /* Icon-only compact alerts button */
  }

  .header-actions .btn-job-alerts.btn-tracked-nav span {
    display: none;
    /* Icon-only compact tracked button */
  }

  .header-actions .btn-job-alerts {
    width: 38px;
    height: 38px;
    padding: 0;
    justify-content: center;
    border-radius: 50%;
  }

  .header-actions .alerts-badge {
    position: absolute;
    top: -3px;
    right: -3px;
    font-size: 0.6rem;
    padding: 1px 4px;
  }

  .header-actions {
    gap: 0.4rem;
  }
}

/* ========================================================
   4. COMPACT MOBILE PHONES (Max-Width: 480px)
   ======================================================== */
@media (max-width: 480px) {
  .container {
    padding-left: 0.65rem;
    padding-right: 0.65rem;
  }

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

  .brand-logo-frame {
    width: 30px;
    height: 30px;
  }

  .hero-gateway-card {
    padding: 0.95rem 0.75rem;
    margin: 0.5rem 0 0.75rem;
    border-radius: 12px;
  }

  .hero-display-title {
    font-size: 1.25rem;
    line-height: 1.25;
  }

  .hero-search-bar {
    height: 42px;
    padding: 0.15rem 0.2rem 0.15rem 0.65rem;
  }

  .hero-search-btn {
    height: 34px;
    padding: 0 0.75rem;
    font-size: 0.76rem;
  }

  .degree-scope-pills {
    flex-direction: column;
  }

  .scope-pill {
    flex: 1 1 100%;
    width: 100%;
  }

  .matrix-mobile-tabs {
    padding: 2px;
    gap: 2px;
  }

  .matrix-tab-btn {
    font-size: 0.75rem;
    padding: 0.42rem 0.15rem;
  }

  .modal-dialog,
  .modal-container,
  .alerts-modal-dialog,
  .track-modal-dialog {
    height: 95vh !important;
    max-height: 95vh !important;
    border-radius: 16px 16px 0 0 !important;
  }
}

/* ========================================================
   5. ULTRA-COMPACT / FOLDABLES (Max-Width: 360px)
   ======================================================== */
@media (max-width: 360px) {
  .container {
    padding-left: 0.5rem;
    padding-right: 0.5rem;
  }

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

  .brand-logo-frame {
    width: 28px;
    height: 28px;
  }

  .hero-gateway-card {
    padding: 0.85rem 0.65rem;
  }

  .hero-display-title {
    font-size: 1.15rem;
  }

  .matrix-tab-btn {
    font-size: 0.7rem;
    padding: 0.4rem 0.1rem;
  }

  .hero-search-btn {
    padding: 0 0.65rem;
    font-size: 0.74rem;
  }

  .btn-toggle-mobile-filters {
    padding: 0.35rem 0.55rem;
    font-size: 0.72rem;
  }

  .mobile-active-toggle {
    padding: 0.28rem 0.45rem;
    font-size: 0.68rem;
  }
}

/* ========================================================
   6. DEDICATED MOBILE BOTTOM NAVIGATION BAR
   App-like bottom touch bar for <= 768px screens
   ======================================================== */
.mobile-bottom-nav {
  display: none;
}

@media (max-width: 768px) {
  .mobile-bottom-nav {
    display: flex;
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    z-index: 999;
    height: 58px;
    background: rgba(255, 255, 255, 0.9);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border-top: 1px solid rgba(15, 23, 42, 0.08);
    box-shadow: 0 -4px 24px rgba(15, 23, 42, 0.08);
    align-items: center;
    justify-content: space-around;
    padding: 0 0.5rem;
    padding-bottom: env(safe-area-inset-bottom, 0px);
  }

  .mobile-nav-btn {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 3px;
    color: #64748b;
    font-size: 0.68rem;
    font-weight: 600;
    padding: 0.35rem 0.5rem;
    border-radius: var(--radius-sm);
    text-decoration: none;
    transition: all var(--transition-fast);
    flex: 1;
    cursor: pointer;
  }

  .mobile-nav-btn svg {
    color: #64748b;
    transition: transform var(--transition-fast), color var(--transition-fast);
  }

  .mobile-nav-btn:hover,
  .mobile-nav-btn.is-active {
    color: #b30000;
  }

  .mobile-nav-btn:hover svg,
  .mobile-nav-btn.is-active svg {
    color: #b30000;
    transform: translateY(-2px);
    filter: drop-shadow(0 0 6px rgba(255, 69, 58, 0.5));
  }
}
@media (max-width: 600px) {
  .modal-overview { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .modal-extended-details { grid-template-columns: minmax(0, 1fr); }
  #item-detail-modal .modal-header { padding: 1rem; }
  #item-detail-modal .modal-body { padding: 1rem; }
}

/* ========================================================
   Sarkari Radar Responsive Optimization
   ======================================================== */
@media (max-width: 768px) {
  .radar-card-wrapper {
    padding: 1.25rem 1rem;
    border-radius: 16px;
  }

  .radar-header {
    flex-direction: column;
    align-items: stretch;
    gap: 1rem;
  }

  .radar-header-actions {
    flex-direction: column;
    align-items: stretch;
  }

  .radar-search-wrapper {
    min-width: 100%;
    width: 100%;
  }

  .radar-total-badge {
    justify-content: center;
    width: 100%;
  }

  .radar-tabs-nav {
    gap: 0.35rem;
    padding-bottom: 0.5rem;
    margin-bottom: 1rem;
  }

  .radar-tab-btn {
    padding: 0.45rem 0.75rem;
    font-size: 0.78rem;
  }

  .radar-table th,
  .radar-table td {
    padding: 0.75rem 0.65rem;
    font-size: 0.8rem;
  }

  .radar-post-title {
    font-size: 0.82rem;
  }

  .radar-org-name {
    font-size: 0.78rem;
    max-width: 160px;
  }

  .radar-action-btn-group {
    flex-direction: column;
    gap: 0.3rem;
  }

  .btn-radar-details,
  .btn-radar-official {
    padding: 0.35rem 0.65rem;
    font-size: 0.72rem;
    width: 100%;
    text-align: center;
  }
}

