/* Responsive Styles for Marvel Rivals Theme */

/* ========================================
   TABLET STYLES (768px - 1024px)
   ======================================== */
@media screen and (max-width: 1024px) and (min-width: 769px) {
  /* Header adjustments */
  .header-nav {
    min-width: 100%;
    height: 60px;
  }
  
  .header-nav .nav-logo {
    width: 100px;
    height: 45px;
    margin: 0 20px;
  }
  
  .header-nav .navs .nav {
    width: 120px;
    font-size: 18px;
  }
  
  .header-nav .nav-lr .btnGroup {
    margin-right: 20px;
  }
  
  /* Main content adjustments */
  .home {
    padding-top: 60px;
  }
  
  /* Banner section */
  .slogan {
    font-size: 14px;
  }
  
  .slogan3 {
    font-size: 16px;
  }
  
  /* Heroes section */
  .part-heroes {
    padding: 20px;
  }
  
  .heroes-nav-box {
    margin-top: 20px;
  }
  
  /* News section */
  .part-news {
    padding: 20px;
  }
  
  /* Media page */
  .inner .book-box {
    width: 12rem;
    height: 7.6rem;
  }
  
  .inner .book-box img {
    width: 12rem;
    height: 7.6rem;
  }
}

/* ========================================
   MOBILE LANDSCAPE (481px - 768px)
   ======================================== */
@media screen and (max-width: 768px) and (min-width: 481px) {
  /* Global adjustments */
  html {
    font-size: 500% !important;
  }
  
  /* Header - mobile menu */
  .header-nav {
    min-width: 100%;
    height: 50px;
    padding: 0 15px;
  }
  
  .header-nav .nav-lf {
    width: 100%;
    justify-content: space-between;
  }
  
  .header-nav .nav-logo {
    width: 80px;
    height: 35px;
    margin: 0;
  }
  
  .header-nav .navs {
    display: none; /* Hide desktop menu */
  }
  
  .header-nav .nav-lr {
    display: flex;
    align-items: center;
  }
  
  .header-nav .nav-lr .icons {
    margin-right: 10px;
  }
  
  .header-nav .nav-lr .btnGroup {
    margin-right: 0;
  }
  
  /* Login button styles */
  .login-box {
    display: flex;
    align-items: center;
    margin-right: 15px;
  }
  
  .btn-login {
    background: var(--saffron-yellow);
    color: var(--sapphire-blue);
    padding: 8px 16px;
    border-radius: 4px;
    font-size: 14px;
    font-weight: bold;
    text-decoration: none;
    transition: background 0.3s ease;
    border: none;
    cursor: pointer;
    font-family: var(--body-font);
  }
  
  .btn-login:hover {
    background: var(--brilliant-yellow);
  }
  
  .user-box {
    display: none;
  }
  
  /* Language switcher styles */
  .lang {
    position: relative;
    margin-right: 15px;
    cursor: pointer;
  }
  
  .lang img {
    width: 24px;
    height: 24px;
  }
  
  .lang .lans {
    position: absolute;
    top: 100%;
    right: 0;
    background: var(--sapphire-blue);
    border-radius: 4px;
    padding: 10px 0;
    min-width: 120px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
    display: none;
    z-index: 1000;
  }
  
  .lang:hover .lans {
    display: block;
  }
  
  .lang .lans li {
    list-style: none;
  }
  
  .lang .lans a {
    display: block;
    padding: 8px 15px;
    color: var(--silver-gray);
    text-decoration: none;
    font-size: 14px;
    transition: background 0.3s ease;
  }
  
  .lang .lans a:hover {
    background: var(--granite-gray);
    color: var(--color-white);
  }
  
  /* Mobile menu button */
  .mobile-menu-toggle {
    display: block;
    width: 30px;
    height: 30px;
    background: none;
    border: none;
    cursor: pointer;
    position: relative;
    z-index: 201;
  }
  
  .mobile-menu-toggle span {
    display: block;
    width: 100%;
    height: 2px;
    background: var(--silver-gray);
    margin: 6px 0;
    transition: 0.3s;
    transform-origin: center;
  }
  
  .mobile-menu-toggle.active span:nth-child(1) {
    transform: rotate(45deg) translate(5px, 5px);
  }
  
  .mobile-menu-toggle.active span:nth-child(2) {
    opacity: 0;
  }
  
  .mobile-menu-toggle.active span:nth-child(3) {
    transform: rotate(-45deg) translate(7px, -6px);
  }
  
  /* Mobile menu */
  .mobile-menu {
    position: fixed;
    top: 50px;
    left: 0;
    width: 100%;
    background: var(--sapphire-blue);
    z-index: 199;
    transform: translateY(-100%);
    transition: transform 0.3s ease;
    display: block;
  }
  
  .mobile-menu.active {
    transform: translateY(0);
  }
  
  .mobile-menu .nav {
    display: block;
    width: 100%;
    padding: 15px 20px;
    border-bottom: 1px solid var(--granite-gray);
    color: var(--silver-gray);
    font-size: 18px;
    text-align: left;
  }
  
  .mobile-menu .nav:hover {
    background: var(--granite-gray);
  }
  
  /* Main content */
  .home {
    padding-top: 50px;
  }
  
  /* Banner section */
  .slogan {
    font-size: 12px;
    text-align: center;
  }
  
  .slogan3 {
    font-size: 14px;
    margin-top: 10px;
  }
  
  .btns {
    text-align: center;
    margin-top: 20px;
  }
  
  .platforms {
    display: flex;
    justify-content: center;
    gap: 15px;
    margin-top: 20px;
  }
  
  .platforms a {
    width: 40px;
    height: 40px;
  }
  
  /* Heroes section */
  .part-heroes {
    padding: 15px;
  }
  
  .hero-info {
    text-align: center;
  }
  
  .heroes-nav-box {
    margin-top: 15px;
  }
  
  /* News section */
  .part-news {
    padding: 15px;
  }
  
  .swp-content {
    margin-top: 15px;
  }
  
  /* Media page */
  .inner .book-box {
    width: 10rem;
    height: 6.3rem;
  }
  
  .inner .book-box img {
    width: 10rem;
    height: 6.3rem;
  }
  
  .gallery-nav {
    flex-wrap: wrap;
    gap: 10px;
  }
  
  .gallery-nav .gnav {
    font-size: 14px;
    padding: 8px 12px;
  }
  
  /* Teamup page */
  .teamup-box {
    padding: 15px;
  }
  
  .teamup-detail {
    padding: 15px;
  }
  
  /* News page */
  .page-list {
    padding: 15px;
  }
  
  .list-tab {
    flex-wrap: wrap;
    gap: 10px;
  }
  
  .list-tab .tab {
    font-size: 14px;
    padding: 8px 12px;
  }
  
  .cont-box {
    margin-top: 15px;
  }
  
  .list-item {
    flex-direction: column;
    text-align: center;
  }
  
  .list-item .img {
    width: 100%;
    max-width: 300px;
    margin: 0 auto 10px;
  }
  
  /* Heroes page */
  .hero-details {
    padding: 15px;
  }
  
  .hero-info {
    text-align: center;
    margin-top: 20px;
  }
  
  .hero-select {
    padding: 15px;
  }
  
  .select-list {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    justify-content: center;
  }
  
  .select-list li {
    width: 60px;
    height: 60px;
  }
  
  /* Footer */
  .footer {
    padding: 20px 15px;
  }
  
  .footer-bottom {
    flex-direction: column;
    text-align: center;
    gap: 15px;
  }
  
  .foot-btn-box {
    flex-direction: column;
    gap: 10px;
  }
}

/* ========================================
   MOBILE PORTRAIT (320px - 480px)
   ======================================== */
@media screen and (max-width: 480px) {
  /* Global adjustments */
  html {
    font-size: 400% !important;
  }
  
  /* Header */
  .header-nav {
    height: 45px;
    padding: 0 10px;
  }
  
  .header-nav .nav-logo {
    width: 70px;
    height: 30px;
  }
  
  .header-nav .nav-lr .icons {
    display: none; /* Hide social icons on very small screens */
  }
  
  .header-nav .nav-lr .lang {
    margin-right: 10px;
  }
  
  .header-nav .nav-lr .login-box {
    margin-right: 10px;
  }
  
  .btn-login {
    padding: 6px 12px;
    font-size: 12px;
  }
  
  .mobile-menu {
    top: 45px;
  }
  
  /* Main content */
  .home {
    padding-top: 45px;
  }
  
  /* Banner section */
  .slogan {
    font-size: 10px;
    padding: 0 10px;
  }
  
  .slogan3 {
    font-size: 12px;
    padding: 0 10px;
  }
  
  .btns {
    margin-top: 15px;
  }
  
  .platforms {
    gap: 10px;
  }
  
  .platforms a {
    width: 35px;
    height: 35px;
  }
  
  /* Heroes section */
  .part-heroes {
    padding: 10px;
  }
  
  .hero-info {
    padding: 10px;
  }
  
  .heroes-nav-box {
    margin-top: 10px;
  }
  
  /* News section */
  .part-news {
    padding: 10px;
  }
  
  .swp-content {
    margin-top: 10px;
  }
  
  /* Media page */
  .inner .book-box {
    width: 8rem;
    height: 5rem;
  }
  
  .inner .book-box img {
    width: 8rem;
    height: 5rem;
  }
  
  .gallery-nav {
    flex-direction: column;
    gap: 5px;
  }
  
  .gallery-nav .gnav {
    font-size: 12px;
    padding: 6px 10px;
  }
  
  /* Teamup page */
  .teamup-box {
    padding: 10px;
  }
  
  .teamup-detail {
    padding: 10px;
  }
  
  /* News page */
  .page-list {
    padding: 10px;
  }
  
  .list-tab {
    flex-direction: column;
    gap: 5px;
  }
  
  .list-tab .tab {
    font-size: 12px;
    padding: 6px 10px;
  }
  
  .cont-box {
    margin-top: 10px;
  }
  
  .list-item {
    padding: 10px;
  }
  
  .list-item .img {
    max-width: 250px;
  }
  
  /* Heroes page */
  .hero-details {
    padding: 10px;
  }
  
  .hero-info {
    margin-top: 15px;
  }
  
  .hero-select {
    padding: 10px;
  }
  
  .select-list {
    gap: 8px;
  }
  
  .select-list li {
    width: 50px;
    height: 50px;
  }
  
  /* Footer */
  .footer {
    padding: 15px 10px;
  }
  
  .footer-bottom {
    gap: 10px;
  }
  
  .foot-btn-box {
    gap: 5px;
  }
  
  .foot-btn {
    font-size: 12px;
    padding: 8px 12px;
  }
}

/* ========================================
   LARGE DESKTOP (1400px+)
   ======================================== */
@media screen and (min-width: 1400px) {
  /* Ensure proper scaling for large screens */
  .header-nav {
    min-width: 1400px;
  }
  
  .wrap {
    min-width: 1400px;
  }
  
  /* Login button styles for desktop */
  .login-box {
    display: flex;
    align-items: center;
    margin-right: 20px;
  }
  
  .btn-login {
    background: var(--saffron-yellow);
    color: var(--sapphire-blue);
    padding: 10px 20px;
    border-radius: 4px;
    font-size: 16px;
    font-weight: bold;
    text-decoration: none;
    transition: background 0.3s ease;
    border: none;
    cursor: pointer;
    font-family: var(--body-font);
  }
  
  .btn-login:hover {
    background: var(--brilliant-yellow);
  }
  
  .user-box {
    display: none;
  }
  
  /* Language switcher styles for desktop */
  .lang {
    position: relative;
    margin-right: 20px;
    cursor: pointer;
  }
  
  .lang img {
    width: 28px;
    height: 28px;
  }
  
  .lang .lans {
    position: absolute;
    top: 100%;
    right: 0;
    background: var(--sapphire-blue);
    border-radius: 4px;
    padding: 10px 0;
    min-width: 140px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
    display: none;
    z-index: 1000;
  }
  
  .lang:hover .lans {
    display: block;
  }
  
  .lang .lans li {
    list-style: none;
  }
  
  .lang .lans a {
    display: block;
    padding: 10px 20px;
    color: var(--silver-gray);
    text-decoration: none;
    font-size: 16px;
    transition: background 0.3s ease;
  }
  
  .lang .lans a:hover {
    background: var(--granite-gray);
    color: var(--color-white);
  }
}

/* ========================================
   UTILITY CLASSES
   ======================================== */
.mobile-only {
  display: none;
}

.desktop-only {
  display: block;
}

.mobile-menu {
  display: none;
}

@media screen and (max-width: 768px) {
  .mobile-only {
    display: block;
  }
  
  .desktop-only {
    display: none;
  }
  
  .mobile-menu {
    display: block;
  }
}

/* ========================================
   TOUCH DEVICE OPTIMIZATIONS
   ======================================== */
@media (hover: none) and (pointer: coarse) {
  /* Increase touch targets */
  .header-nav .navs .nav,
  .mobile-menu .nav,
  .btn,
  .tab {
    min-height: 44px;
    min-width: 44px;
  }
  
  /* Remove hover effects on touch devices */
  .nav:hover,
  .btn:hover {
    background: none;
    color: inherit;
  }
}

/* ========================================
   HIGH DPI DISPLAYS
   ======================================== */
@media (-webkit-min-device-pixel-ratio: 2), (min-resolution: 192dpi) {
  /* Ensure crisp images on retina displays */
  .header-nav .nav-logo img,
  .platforms img {
    image-rendering: -webkit-optimize-contrast;
    image-rendering: crisp-edges;
  }
}

/* ========================================
   LOGIN POPUP STYLES
   ======================================== */
.pop-login.pop {
  display: none !important;
  position: fixed !important;
  top: 0 !important;
  left: 0 !important;
  width: 100% !important;
  height: 100% !important;
  z-index: 10001 !important;
  opacity: 0;
  transition: opacity 0.3s ease;
  transform: none !important;
}

.pop-login.pop.active {
  opacity: 1;
  display: block !important;
}

.pop-login .Layer {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.8);
  cursor: pointer;
  z-index: 1;
}

.pop-login-with {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%) scale(0.8);
  background: var(--sapphire-blue);
  border-radius: 10px;
  padding: 30px;
  min-width: 400px;
  max-width: 90vw;
  transition: transform 0.3s ease;
  z-index: 2;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.5);
}

.pop-login.pop.active .pop-login-with {
  transform: translate(-50%, -50%) scale(1);
}

.login-close {
  position: absolute;
  top: 15px;
  right: 15px;
  width: 30px;
  height: 30px;
  cursor: pointer;
  z-index: 1001;
  display: flex;
  align-items: center;
  justify-content: center;
}

.login-close s {
  display: block;
  width: 100%;
  height: 2px;
  background: var(--silver-gray);
  transform: rotate(45deg);
  position: relative;
}

.login-close s:after {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 2px;
  background: var(--silver-gray);
  transform: rotate(-90deg);
}

.with-tt {
  color: var(--color-white);
  font-size: 18px;
  font-weight: bold;
  text-align: center;
  margin-bottom: 20px;
  font-family: var(--heading-font);
}

.with-list {
  display: flex;
  flex-direction: column;
  gap: 15px;
  margin-bottom: 20px;
}

.with-item {
  display: flex;
  align-items: center;
  padding: 15px;
  background: var(--granite-gray);
  border-radius: 8px;
  cursor: pointer;
  transition: background 0.3s ease;
}

.with-item:hover {
  background: var(--anthracite);
}

.with-item-img {
  width: 40px;
  height: 40px;
  margin-right: 15px;
  background-size: contain;
  background-repeat: no-repeat;
  background-position: center;
}

.with-item-img.steam {
  background-image: url('../img/steam.svg');
}

.with-item-img.epic {
  background-image: url('../img/epic_1.png');
}

.with-item-img.xbox {
  background-image: url('../img/xbox_1.png');
}

.with-item-img.playstation {
  background-image: url('../img/ps5_1.png');
}

.with-item-img.netease {
  background-color: var(--saffron-yellow);
  border-radius: 50%;
}

.with-name {
  color: var(--color-white);
  font-size: 16px;
  font-weight: 500;
}

.btm-tips {
  display: block;
  text-align: center;
  color: var(--pale-gray);
  font-size: 12px;
  text-decoration: underline;
  margin-top: 15px;
}

.btm-tips:hover {
  color: var(--silver-gray);
}

/* Mobile styles for login popup */
@media screen and (max-width: 768px) {
  .pop-login-with {
    min-width: 320px;
    padding: 20px;
    margin: 20px;
  }
  
  .with-tt {
    font-size: 16px;
  }
  
  .with-item {
    padding: 12px;
  }
  
  .with-item-img {
    width: 35px;
    height: 35px;
    margin-right: 12px;
  }
  
  .with-name {
    font-size: 14px;
  }
}

@media screen and (max-width: 480px) {
  .pop-login-with {
    min-width: 280px;
    padding: 15px;
    margin: 15px;
  }
  
  .with-tt {
    font-size: 14px;
  }
  
  .with-item {
    padding: 10px;
  }
  
  .with-item-img {
    width: 30px;
    height: 30px;
    margin-right: 10px;
  }
  
  .with-name {
    font-size: 13px;
  }
}
