/**
 * Neskici — mobile override for game INFO pages (/{slug}.html e.g. /tetris.html)
 * Theme: temalar/default4/
 *
 * NOT for /oyna/ play pages (those use mobile-oyna.css). Safe if both load:
 * this file does not touch #game / #ikinci / EmulatorJS.
 *
 * Header rules duplicated from mobile-oyna (info page may load alone).
 * CF caches CSS 7d — bump ?v= in ust.tpl when this file changes.
 */

@media only screen and (max-width: 768px) {

  html,
  body {
    width: 100% !important;
    max-width: 100% !important;
    overflow-x: hidden !important;
  }

  body .wrapper,
  body .footer,
  body .footerwrapper {
    width: 100% !important;
    max-width: 100% !important;
    margin-left: auto !important;
    margin-right: auto !important;
    box-sizing: border-box !important;
    overflow-x: hidden !important;
  }

  /* ---- Header (theme 960×138 + floats) ---- */

  body .headerbg,
  body div.headerbg {
    width: 100% !important;
    max-width: 100% !important;
    height: auto !important;
    min-height: 0 !important;
    max-height: none !important;
    margin: 0 !important;
    padding: 0 !important;
    position: relative !important;
    box-sizing: border-box !important;
    overflow: hidden !important;
    border-bottom: 1px solid #313131 !important;
    background: #eeeeee !important;
    background-image: none !important;
  }

  body .headerwrapper,
  body div.headerwrapper {
    width: 100% !important;
    max-width: 100% !important;
    height: auto !important;
    min-height: 0 !important;
    max-height: none !important;
    margin: 0 !important;
    padding: 0 !important;
    position: relative !important;
    box-sizing: border-box !important;
    overflow: hidden !important;
  }

  body .topblackwrapper,
  body div.topblackwrapper {
    display: block !important;
    width: 100% !important;
    height: auto !important;
    min-height: 0 !important;
    max-height: none !important;
    margin: 0 !important;
    padding: 8px 10px 10px 10px !important;
    box-sizing: border-box !important;
    overflow: hidden !important;
    text-align: center !important;
    background: #444444 !important;
    background-image: none !important;
  }

  /*
   * Guest/member links were a full-width column (ANA SAYFA / ÜYE GİRİŞİ / ÜYE OL).
   * Keep theme colors + icon backgrounds; sit them as compact chips in one row.
   */
  body .login,
  body .topblackwrapper .login {
    float: none !important;
    clear: both !important;
    display: -webkit-box !important;
    display: -webkit-flex !important;
    display: flex !important;
    -webkit-box-orient: horizontal !important;
    -webkit-box-direction: normal !important;
    -webkit-flex-direction: row !important;
    flex-direction: row !important;
    -webkit-flex-wrap: wrap !important;
    flex-wrap: wrap !important;
    -webkit-box-pack: center !important;
    -webkit-justify-content: center !important;
    justify-content: center !important;
    -webkit-box-align: center !important;
    -webkit-align-items: center !important;
    align-items: center !important;
    width: 100% !important;
    margin: 0 0 8px 0 !important;
    padding: 0 !important;
    box-sizing: border-box !important;
  }

  body .login a,
  body .login a.main,
  body .login a.lgn,
  body .login a.rgst,
  body .login a.lbtn,
  body .login a.fcbk,
  body .login a.exit,
  body .login a.dashboard,
  body .login a.admn {
    float: none !important;
    clear: none !important;
    display: block !important;
    -webkit-box-flex: 0 !important;
    -webkit-flex: 0 0 auto !important;
    flex: 0 0 auto !important;
    -webkit-align-self: center !important;
    align-self: center !important;
    width: auto !important;
    max-width: 100% !important;
    margin: 3px !important;
    padding: 8px 12px 8px 28px !important;
    min-height: 36px !important;
    font-size: 11px !important;
    line-height: 20px !important;
    white-space: nowrap !important;
    text-align: left !important;
    border-radius: 6px !important;
    box-sizing: border-box !important;
  }

  body #search,
  body .topblackwrapper #search {
    float: none !important;
    clear: both !important;
    display: block !important;
    width: 100% !important;
    max-width: 100% !important;
    margin: 0 !important;
    box-sizing: border-box !important;
  }

  body #search form {
    width: 100% !important;
    max-width: 100% !important;
    margin: 0 !important;
    box-sizing: border-box !important;
  }

  body #search input[type="text"],
  body #search input.query,
  body #search #ara {
    width: 100% !important;
    max-width: 100% !important;
    height: 36px !important;
    margin: 0 !important;
    padding: 0 36px 0 12px !important;
    border-radius: 6px !important;
    font-size: 14px !important;
    box-sizing: border-box !important;
  }

  body #search .search-button,
  body #search button.search-button {
    top: 8px !important;
    right: 8px !important;
  }

  body .header,
  body div.header {
    display: -webkit-box !important;
    display: -webkit-flex !important;
    display: flex !important;
    -webkit-flex-wrap: wrap !important;
    flex-wrap: wrap !important;
    -webkit-box-pack: center !important;
    -webkit-justify-content: center !important;
    justify-content: center !important;
    width: 100% !important;
    height: auto !important;
    min-height: 0 !important;
    max-height: none !important;
    margin: 0 !important;
    padding: 8px 6px 6px 6px !important;
    text-align: center !important;
    overflow: hidden !important;
    clear: both !important;
    box-sizing: border-box !important;
    background: #eeeeee !important;
    background-image: none !important;
  }

  body .header > .clearfix {
    display: none !important;
  }

  body .logo,
  body .header .logo {
    float: none !important;
    clear: both !important;
    display: block !important;
    -webkit-box-flex: 1 !important;
    -webkit-flex: 1 0 100% !important;
    flex: 1 0 100% !important;
    width: 100% !important;
    margin: 0 auto 2px auto !important;
    text-align: center !important;
  }

  body .logo img,
  body .header .logo img {
    max-width: 168px !important;
    width: auto !important;
    height: auto !important;
  }

  /* Four shortcuts share one row — not a 2×2 of wide blocks */
  body a.headeritem,
  body .header a.headeritem {
    float: none !important;
    display: block !important;
    -webkit-box-flex: 1 !important;
    -webkit-flex: 1 1 0 !important;
    flex: 1 1 0 !important;
    vertical-align: top !important;
    width: auto !important;
    min-width: 0 !important;
    max-width: 92px !important;
    margin: 2px 2px 4px 2px !important;
    padding: 4px 2px !important;
    font-size: 11px !important;
    line-height: 1.15 !important;
    color: #414141 !important;
    box-sizing: border-box !important;
    text-align: center !important;
  }

  body a.headeritem img {
    width: 28px !important;
    height: 28px !important;
    display: block !important;
    margin: 0 auto 2px auto !important;
  }

  body a.headeritem .clearfix {
    display: none !important;
  }

  /* ---- Categories + main column ---- */

  body .catarea {
    width: 100% !important;
    max-width: 100% !important;
    box-sizing: border-box !important;
    margin-top: 6px !important;
  }

  body .cats li {
    width: 46% !important;
    margin: 2px 2% 2px 0 !important;
    box-sizing: border-box !important;
  }

  body .container {
    width: 100% !important;
    max-width: 100% !important;
    margin-top: 6px !important;
    padding: 8px !important;
    box-sizing: border-box !important;
    /* keep theme min-height — do not collapse ad/content intent */
  }

  body h2.blocktitleredbig {
    margin: 0 0 6px 0 !important;
    box-sizing: border-box !important;
  }

  /*
   * Info layout (theme):
   *   .gameinfo_left  { width:550px; float:left }
   *   .gameinfo_right { width:380px; float:right }
   *   .commentdetailright { min-width:400px }
   *   .item { float:left; width:108px }
   */
  body .gameinfo_left,
  body .gameinfo_right {
    width: 100% !important;
    max-width: 100% !important;
    float: none !important;
    clear: both !important;
    margin: 0 0 12px 0 !important;
    padding: 0 !important;
    box-sizing: border-box !important;
  }

  body .gameinfo_left .speedbar,
  body .speedbar {
    word-wrap: break-word !important;
    overflow-wrap: break-word !important;
    box-sizing: border-box !important;
  }

  /* Cover + “Oyna” CTA (link wrapping cover + h1) */
  body .gameinfo_left > a {
    display: block !important;
    width: 100% !important;
    max-width: 100% !important;
    text-align: center !important;
    margin: 8px 0 !important;
    box-sizing: border-box !important;
  }

  body .gameinfo_left img {
    max-width: 100% !important;
    width: auto !important;
    height: auto !important;
  }

  body .gameinfo_left h1 {
    font-size: 18px !important;
    line-height: 1.3 !important;
    margin: 0 !important;
    padding: 10px 8px !important;
  }

  body .gameinfo_left .speedbar h1 {
    font-size: 18px !important;
  }

  body .gameinfo_left ins.adsbygoogle {
    max-width: 100% !important;
  }

  /* Description text under cover */
  body .gameinfo_left > span {
    display: block !important;
    max-width: 100% !important;
    box-sizing: border-box !important;
    word-wrap: break-word !important;
    overflow-wrap: break-word !important;
  }

  /* Comments */
  body .commentdetailright {
    float: none !important;
    width: 100% !important;
    max-width: 100% !important;
    min-width: 0 !important;
    box-sizing: border-box !important;
  }

  body .commentdetail {
    width: auto !important;
    max-width: 100% !important;
    box-sizing: border-box !important;
  }

  body .commentarea {
    max-width: 100% !important;
    box-sizing: border-box !important;
  }

  body #addcomment_form input,
  body #addcomment_form textarea {
    max-width: 100% !important;
    box-sizing: border-box !important;
  }

  body #addcomment_form input[name="name"],
  body #addcomment_form input[name="captcha_answer"] {
    float: none !important;
    width: 100% !important;
    margin: 4px 0 !important;
  }

  body .fb-comments,
  body .fb-comments span,
  body .fb-comments iframe {
    max-width: 100% !important;
  }

  /* Similar games grid */
  body .gameinfo_right .similiarheader {
    margin-bottom: 8px !important;
  }

  body .gameinfo_right .item,
  body .gameinfo_right span.item {
    float: left !important;
    width: 46% !important;
    max-width: 140px !important;
    height: auto !important;
    min-height: 0 !important;
    margin: 4px 2% 8px 0 !important;
    box-sizing: border-box !important;
    background-size: contain !important;
  }

  body .gameinfo_right .item img,
  body .gameinfo_right span.item img {
    max-width: 94px !important;
    width: 100% !important;
    height: auto !important;
  }

  body .gameinfo_right .item h2,
  body .gameinfo_right span.item h2 {
    font-size: 11px !important;
    line-height: 1.2 !important;
    word-wrap: break-word !important;
  }

  body .gameinfo_right .itembg {
    max-width: 100% !important;
  }

  body .gameinfo_right ins.adsbygoogle,
  body .adv300x250 {
    float: none !important;
    width: 100% !important;
    max-width: 100% !important;
    height: auto !important;
    box-sizing: border-box !important;
  }

  body .footerblock {
    width: 100% !important;
    float: none !important;
    box-sizing: border-box !important;
  }
}

@media screen and (min-width: 769px) and (max-width: 980px) {
  body .headerbg,
  body .headerwrapper,
  body .wrapper,
  body .footer {
    width: 100% !important;
    max-width: 100% !important;
    box-sizing: border-box !important;
  }

  body .headerbg,
  body .headerwrapper {
    height: auto !important;
  }

  body .gameinfo_left,
  body .gameinfo_right {
    width: 100% !important;
    float: none !important;
  }
}
