/* ==========================================================================
   हरियाणवी वाइब — HARYANVI VIBE
   RESPONSIVE DESIGN & MOBILE TOUCH SYSTEM
   ========================================================================== */

/* Large Desktop (1440px - 1920px+) */
@media (min-width: 1440px) {
  .unified-panel {
    width: 680px;
    max-height: 80vh;
  }

  #main-title {
    font-size: 8.5rem;
  }
}

/* Medium Desktop & Tablet Landscape (1024px - 1439px) */
@media (max-width: 1280px) and (min-width: 769px) {
  #top-header {
    padding: 1rem 1.5rem;
  }

  #hero-section #btn-nav-about {
    left: 1.5rem;
  }
}

/* Tablet Portrait & Small Laptops (769px - 1023px) */
@media (max-width: 1023px) and (min-width: 769px) {
  #top-header {
    padding: 1rem;
    gap: 0.5rem;
  }

  #hero-section #btn-nav-about {
    left: 1rem;
  }

  .unified-panel {
    width: 90vw;
    max-height: 82vh;
  }

  #music-player-container {
    bottom: 1.2rem;
    width: 94%;
  }
}

/* Mobile Devices (320px - 768px) */
@media (max-width: 768px) {
  body {
    padding-bottom: 90px;
  }

  /* Top Navigation in Mobile */
  #top-header {
    padding: 0.75rem 0.85rem;
    flex-wrap: wrap;
    justify-content: space-between;
    gap: 0.5rem;
  }

  #live-clock {
    padding: 0.35rem 0.65rem;
    font-size: 0.75rem;
    min-height: 36px;
  }

  #highway-counter {
    padding: 0.35rem 0.65rem;
    font-size: 0.75rem;
    min-height: 36px;
  }

  .counter-label {
    display: none; /* Hide label on mobile to save space */
  }

  #btn-external-yt {
    width: 36px;
    height: 36px;
  }

  /* Mobile Control Hub — Includes [ PLAYER | PLAYLIST | EQUALIZER | SLEEP | ABOUT ] */
  #nav-control-hub {
    order: 3;
    width: 100%;
    justify-content: space-around;
    padding: 0.3rem 0.4rem;
    background: rgba(14, 20, 32, 0.92);
  }

  .hub-btn {
    padding: 0.4rem 0.55rem;
    font-size: 0.68rem;
    min-height: 32px;
  }

  .hub-btn span {
    font-size: 0.65rem;
  }

  /* Hero adjustments */
  #hero-section {
    padding: 6.5rem 1rem 7.5rem 1rem;
    justify-content: center;
  }

  .title-container {
    margin-top: -1rem;
  }

  #main-title {
    font-size: clamp(2.8rem, 13vw, 4.8rem);
    white-space: normal;
  }

  .sub-title-wrapper {
    flex-wrap: wrap;
    justify-content: center;
    gap: 0.4rem;
  }

  .sub-title-tag {
    font-size: 0.72rem;
  }

  .sub-title-text {
    font-size: 0.72rem;
  }

  #message-text {
    font-size: 1.1rem;
    padding: 0 0.5rem;
  }

  /* Mobile Bottom Sheet / Full-Screen Panels */
  .unified-panel {
    top: auto;
    bottom: 0;
    left: 0;
    transform: translateY(100%);
    width: 100vw;
    max-width: 100vw;
    height: 88vh;
    height: 88dvh;
    max-height: 88vh;
    max-height: 88dvh;
    border-radius: 24px 24px 0 0;
    border-bottom: none;
    border-left: none;
    border-right: none;
  }

  .unified-panel.open {
    transform: translateY(0);
  }

  .panel-header {
    padding: 1rem 1.2rem;
  }

  .panel-body-scroll {
    padding: 1rem 1.1rem;
    padding-bottom: 2rem;
  }





  /* Hide sleep presets on old eq references - keep sleep grid */
  .sleep-presets-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .company-creator-grid {
    grid-template-columns: 1fr;
  }

  .app-card-layout {
    flex-direction: column;
    text-align: center;
    gap: 0.8rem;
  }

  .app-header-line {
    justify-content: center;
  }

  .app-actions {
    justify-content: center;
    flex-direction: column;
  }

  /* Mobile Music Player */
  #music-player-container {
    bottom: 0.75rem;
    width: 95%;
  }

  #music-player {
    padding: 0.55rem 0.85rem;
    border-radius: 35px;
    gap: 0.65rem;
  }

  .player-thumb-wrapper {
    width: 44px;
    height: 44px;
  }

  #song-title {
    font-size: 0.85rem;
  }

  #song-artist {
    font-size: 0.7rem;
  }

  .player-controls {
    gap: 0.2rem;
  }

  .btn-ctrl {
    width: 32px;
    height: 32px;
  }

  .btn-ctrl svg {
    width: 15px;
    height: 15px;
  }

  #btn-play-pause {
    width: 38px;
    height: 38px;
  }

  #btn-play-pause svg {
    width: 17px;
    height: 17px;
  }

  /* Hide non-essential player controls on small screens */
  #btn-shuffle,
  .volume-popover-wrapper {
    display: none;
  }
}

/* Extra Small Mobile (320px - 375px) */
@media (max-width: 375px) {
  #top-header {
    padding: 0.5rem;
  }

  .hub-btn {
    padding: 0.35rem 0.4rem;
    font-size: 0.62rem;
  }

  #main-title {
    font-size: 2.6rem;
  }

  .card-duration {
    display: none;
  }

  .offline-card {
    padding: 2rem 1.2rem;
  }

  .offline-title {
    font-size: 1.3rem;
  }

  .btn-offline-retry {
    padding: 0.75rem 1.6rem;
    font-size: 0.8rem;
  }
}
