/* YasGod: phones, tablets, desktops, any browser */
html {
  overflow-x: hidden;
  max-width: 100%;
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
}
body {
  overflow-x: hidden;
  max-width: 100%;
}
img, video, canvas, svg, iframe {
  max-width: 100%;
  height: auto;
}
#yasgod-minimal,
.yg-cosmos-header,
.yg-qdash,
#yg-feed,
.yg-shell-law,
#yg-disaster-stats {
  max-width: 100%;
  box-sizing: border-box;
}

.yg-qdash-actions button,
.yg-overlay-card button,
.yg-corner button,
.yg-jump {
  min-height: 44px;
}

.yg-overlay {
  padding: max(12px, env(safe-area-inset-top)) max(12px, env(safe-area-inset-right)) max(16px, env(safe-area-inset-bottom)) max(12px, env(safe-area-inset-left));
  -webkit-overflow-scrolling: touch;
}
.yg-overlay-card {
  max-width: min(820px, 100%);
  max-height: none;
}

.yg-corner {
  right: max(12px, env(safe-area-inset-right));
  bottom: max(12px, env(safe-area-inset-bottom));
}

@media (max-width: 1100px) {
  .yg-qdash {
    padding: 10px 8px 14px;
  }
  .yg-qdash-inner {
    border-radius: 18px;
    padding: 12px 10px 12px;
  }
  .yg-qdash-top {
    grid-template-columns: 1fr;
  }
  .yg-qdash-sun img,
  .yg-qdash-moonface {
    width: 88px;
    height: 88px;
  }
  .yg-qdash-clockwrap {
    width: min(240px, 78vw);
  }
  .yg-qdash-salah {
    grid-template-columns: repeat(3, 1fr) !important;
  }
  .yg-qdash-actions {
    gap: 8px;
  }
  .yg-qdash-actions button {
    flex: 1 1 calc(50% - 8px);
    min-width: 140px;
  }
  #yg-feed {
    padding: 12px 10px 20px;
  }
  .yg-shell-law {
    padding: 22px 16px 28px;
  }
  .yg-shell-law h2 {
    font-size: clamp(22px, 7vw, 32px);
  }
  .yg-shell-law p {
    font-size: clamp(16px, 4.4vw, 20px);
  }
}

@media (max-width: 520px) {
  .yg-qdash-salah {
    grid-template-columns: repeat(2, 1fr) !important;
  }
  .yg-qdash-actions button {
    flex: 1 1 100%;
  }
  .yg-qibla-splash-grid {
    grid-template-columns: 1fr !important;
  }
  .yg-cosmos-moon-img,
  .yg-islam-img {
    width: min(42vw, 160px);
    height: min(42vw, 160px);
  }
}

@media (max-width: 900px) {
  html, body {
    background-attachment: scroll;
  }
}

@media (hover: none) and (pointer: coarse) {
  .yg-qdash-actions button,
  .yg-auth-btn,
  .yg-jump {
    min-height: 44px;
  }
}

@media (orientation: landscape) and (max-height: 500px) {
  .yg-cosmos-header {
    padding: 6px 10px;
  }
  .yg-qdash {
    padding: 8px;
  }
  .yg-overlay-card {
    margin: 4px auto 12px;
  }
}
