/* =========================================================
   Components - Game Cards (Alostaz)
   File: components.css
========================================================= */

/* Grid for games (and any cards section) */
.games-grid{
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 16px;
  margin-top: 24px;
}

/* Tablets */
@media (max-width: 1100px){
  .games-grid{ grid-template-columns: repeat(3, minmax(0, 1fr)); }
}

/* Mobile: 2 cards side by side */
@media (max-width: 768px){
  .games-grid{ grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
}

/* Very small phones: 1 column */
@media (max-width: 360px){
  .games-grid{ grid-template-columns: 1fr; }
}

/* Card */
.game-card{
  background: var(--surface);
  border: 1px solid var(--border-color);
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: var(--shadow-sm);
  display: flex;
  flex-direction: column;
  transition: transform .18s ease, box-shadow .18s ease, border-color .18s ease;
}

.game-card:hover{
  transform: translateY(-3px);
  box-shadow: var(--shadow);
  border-color: rgba(37, 99, 235, .25); /* primary tint */
}

/* Image wrapper (16:9) */
.game-image{
  position: relative;
  aspect-ratio: 16/9;
  background: linear-gradient(135deg, rgba(37,99,235,.10), rgba(249,115,22,.10));
  overflow: hidden;
}

.game-image a{ display:block; height:100%; }

.game-image img{
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform .25s ease, filter .25s ease;
  display:block;
}

.game-card:hover .game-image img{
  transform: scale(1.04);
  filter: saturate(1.05);
}

/* Platform badge on image */
.platform-badge{
  position: absolute;
  top: 10px;
  right: 10px;
  padding: 6px 10px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 800;
  letter-spacing: .2px;
  color: #fff;
  background: rgba(15,23,42,.75);
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
  box-shadow: 0 10px 22px rgba(0,0,0,.15);
}

.platform-badge.android-badge{ background: rgba(34,197,94,.90); }
.platform-badge.ios-badge{ background: rgba(15,23,42,.85); }
.platform-badge.windows-badge{ background: rgba(59,130,246,.90); }

/* Content */
.game-content{
  padding: 14px 14px 12px;
  display: flex;
  flex-direction: column;
  gap: 10px;
  flex: 1;
}

/* Category pill */
.game-category a{
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 6px 10px;
  border-radius: 999px;
  text-decoration: none;
  font-weight: 800;
  font-size: 12px;
  color: var(--primary-color);
  background: rgba(37,99,235,.10);
  border: 1px solid rgba(37,99,235,.15);
}

.game-category a:hover{
  background: rgba(37,99,235,.14);
}

/* Title */
.game-title{
  margin: 0;
  font-size: 15px;
  line-height: 1.35;
  font-weight: 900;
  color: var(--dark-color);
}

.game-title a{
  text-decoration: none;
  color: inherit;
  display: block;
}

.game-title a:hover{ color: var(--primary-color); }

/* Description */
.game-description{
  margin: 0;
  color: var(--gray-color);
  font-size: 13px;
  line-height: 1.65;
  min-height: 44px; /* keeps cards aligned */
}

/* Meta row */
.game-meta{
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin-top: 2px;
}

/* Platform icons */
.game-platform{
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

.platform-icon{
  width: 30px;
  height: 30px;
  border-radius: 10px;
  background: rgba(15,23,42,.06);
  border: 1px solid rgba(15,23,42,.08);
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.platform-icon i{ font-size: 16px; }

/* Icon colors (optional, subtle) */
.platform-icon i.android{ color: #22c55e; }
.platform-icon i.ios{ color: #111827; }
.platform-icon i.windows{ color: #3b82f6; }

/* Size */
.game-size{
  font-weight: 900;
  font-size: 12px;
  color: var(--dark-color);
  background: rgba(249,115,22,.12);
  border: 1px solid rgba(249,115,22,.18);
  padding: 6px 10px;
  border-radius: 999px;
  white-space: nowrap;
}

/* Footer */
.game-footer{
  margin-top: auto;
  padding-top: 6px;
}

.download-btn{
  width: 100%;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  text-decoration: none;
  border-radius: 14px;
  padding: 12px 12px;
  font-weight: 900;
  font-size: 14px;
  color: #fff;
  background: linear-gradient(135deg, var(--primary-color), var(--primary-dark));
  box-shadow: 0 10px 22px rgba(37,99,235,.22);
  transition: transform .18s ease, filter .18s ease, box-shadow .18s ease;
}

.download-btn:hover{
  transform: translateY(-1px);
  filter: brightness(1.02);
  box-shadow: 0 14px 28px rgba(37,99,235,.28);
}

/* Touch-friendly */
@media (max-width: 768px){
  .game-content{ padding: 12px; }
  .platform-badge{ top: 8px; right: 8px; font-size: 11px; padding: 5px 9px; }
  .game-title{ font-size: 14px; }
  .game-description{ font-size: 12.5px; min-height: 40px; }
  .platform-icon{ width: 28px; height: 28px; border-radius: 9px; }
  .download-btn{ padding: 11px; border-radius: 13px; }
}

/* Reduce motion (accessibility) */
@media (prefers-reduced-motion: reduce){
  .game-card,
  .game-image img,
  .download-btn{ transition: none !important; }
}


/* =========================================================
   Sticker 3D Game Card
========================================================= */

/* Sticker center */
.game-sticker-wrap{
  display: flex;
  justify-content: center;
  margin-top: 12px;
}

.download-sticker{
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 10px 16px;
  border-radius: 999px;
  background: linear-gradient(135deg, var(--primary-color), var(--primary-dark));
  color: #fff;
  text-decoration: none;
  font-weight: 900;
  font-size: 14px;
  box-shadow: 0 14px 28px rgba(37,99,235,.30);

  transform: translateY(-8px); /* ✅ يرفع الاستيكر كله لأعلى */
}









/* تكبير صورة الكارت */
.games-grid .game-image{
  height: 220px; /* كانت أقل */
  border-radius: 18px 18px 0 0;
  overflow: hidden;
}

/* اجعل الصورة تملأ المساحة */
.games-grid .game-image img{
  width: 100%;
  height: 100%;
  object-fit: cover; /* تعبي الصورة */
  display: block;
}

/* للموبايل */
@media (max-width: 768px){
  .games-grid .game-image{
    height: 170px;
  }
}

/* شاشات صغيرة جدا */
@media (max-width: 360px){
  .games-grid .game-image{
    height: 150px;
  }
}




/* =======================
   Post Card (News)
======================= */
.post-card{
  background:#fff;
  border:1px solid rgba(0,0,0,.06);
  border-radius:18px;
  overflow:hidden;
  box-shadow:0 10px 26px rgba(0,0,0,.06);
  transition:transform .2s ease, box-shadow .2s ease;
  display:flex;
  flex-direction:column;
  height:100%;
}

.post-card:hover{
  transform:translateY(-4px);
  box-shadow:0 16px 40px rgba(0,0,0,.10);
}

.post-card__thumb{
  position:relative;
  display:block;
  height:200px;
  background:#f3f6ff;
  overflow:hidden;
}

.post-card__thumb img{
  width:100%;
  height:100%;
  object-fit:cover;
  display:block;
  transform:scale(1.02);
  transition:transform .25s ease;
}

.post-card:hover .post-card__thumb img{
  transform:scale(1.06);
}

.post-card__thumb--ph{
  width:100%;
  height:100%;
  display:flex;
  align-items:center;
  justify-content:center;
  font-size:40px;
  color:rgba(0,0,0,.25);
}

.post-card__badge{
  position:absolute;
  top:12px;
  right:12px;
  background:rgba(255,255,255,.92);
  border:1px solid rgba(0,0,0,.08);
  padding:6px 10px;
  border-radius:999px;
  font-weight:800;
  font-size:12px;
  backdrop-filter: blur(6px);
}

.post-card__body{
  padding:16px 16px 14px;
  display:flex;
  flex-direction:column;
  gap:10px;
  flex:1;
}

.post-card__meta{
  display:flex;
  gap:10px;
  color:rgba(0,0,0,.55);
  font-size:12px;
  font-weight:700;
}

.post-card__date i{
  margin-left:6px;
}

.post-card__title{
  margin:0;
  font-size:16px;
  line-height:1.55;
  font-weight:900;
  color:#111;
}

.post-card__title a{
  color:inherit;
  text-decoration:none;
  display:block;
}

.post-card__btn{
  margin-top:auto;
  display:inline-flex;
  align-items:center;
  gap:10px;
  align-self:flex-start;
  padding:10px 14px;
  border-radius:12px;
  background:rgba(13,110,253,.10);
  color:#0d6efd;
  font-weight:900;
  text-decoration:none;
  transition:transform .2s ease, background .2s ease;
}

.post-card__btn:hover{
  transform:translateY(-2px);
  background:rgba(13,110,253,.14);
}

.post-card__btn i{
  transition:transform .2s ease;
}

.post-card__btn:hover i{
  transform:translateX(-4px);
}

/* Mobile */
@media (max-width: 768px){
  .post-card__thumb{ height:170px; }
  .post-card__title{ font-size:15px; }
}






/* =========================
   Footer (Alostaz)
========================= */

footer{
  background: #0b1220;
  color: rgba(255,255,255,.88);
  margin-top: 70px;
  padding: 55px 0 25px;
  position: relative;
  overflow: hidden;
}

footer::before{
  content:"";
  position:absolute;
  inset: 0;
  background:
    radial-gradient(700px 300px at 80% -10%, rgba(13,110,253,.18), transparent 60%),
    radial-gradient(700px 300px at 10% 0%, rgba(118,75,162,.16), transparent 60%);
  pointer-events:none;
}

footer .container{
  position: relative;
  z-index: 2;
}

/* ---- Footer Header ---- */
.footer-header{
  margin-bottom: 35px;
  padding-bottom: 25px;
  border-bottom: 1px solid rgba(255,255,255,.08);
}

.footer-logo-section{
  display:flex;
  align-items:center;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
}

.footer-logo-section .logo{
  display:flex;
  align-items:center;
  gap: 10px;
}

/* Join button */
.footer-join-btn{
  display:inline-flex;
  align-items:center;
  gap: 10px;
  padding: 12px 18px;
  border-radius: 999px;
  text-decoration:none;
  font-weight: 900;
  color: #fff;
  background: linear-gradient(135deg, var(--primary-color, #0d6efd), #6f42c1);
  box-shadow: 0 12px 30px rgba(0,0,0,.25);
  transition: transform .2s ease, opacity .2s ease;
  white-space: nowrap;
}

.footer-join-btn:hover{
  transform: translateY(-2px);
  opacity: .96;
}

/* ---- Footer Content Columns ---- */
.footer-content{
  display:grid;
  grid-template-columns: 1.2fr 1fr 1fr 1.2fr;
  gap: 28px;
  padding: 25px 0 10px;
}

.footer-column{
  background: rgba(255,255,255,.03);
  border: 1px solid rgba(255,255,255,.06);
  border-radius: 16px;
  padding: 20px 18px;
  backdrop-filter: blur(10px);
}

.footer-column h3{
  margin: 0 0 14px 0;
  color: #fff;
  font-size: 16px;
  font-weight: 900;
  position: relative;
  padding-bottom: 10px;
}

.footer-column h3::after{
  content:"";
  position:absolute;
  bottom: 0;
  right: 0;
  width: 55px;
  height: 3px;
  border-radius: 99px;
  background: linear-gradient(135deg, var(--primary-color, #0d6efd), var(--secondary-color, #764ba2));
}

.footer-links{
  list-style:none;
  padding: 0;
  margin: 0;
  display:flex;
  flex-direction: column;
  gap: 10px;
}

.footer-links li{
  color: rgba(255,255,255,.78);
  line-height: 1.7;
  font-size: 14px;
}

.footer-links li a{
  color: rgba(255,255,255,.84);
  text-decoration:none;
  display:flex;
  align-items:center;
  gap: 10px;
  padding: 8px 10px;
  border-radius: 12px;
  transition: background .2s ease, transform .2s ease;
}

.footer-links li a:hover{
  background: rgba(255,255,255,.06);
  transform: translateX(-2px);
}

.footer-links li i{
  color: rgba(255,255,255,.75);
}

/* Social icons wrapper inside last column */
.footer-column a i.fab,
.footer-column a i.fas{
  transition: transform .2s ease, opacity .2s ease;
}

.footer-column a:hover i.fab,
.footer-column a:hover i.fas{
  transform: translateY(-2px);
  opacity: .92;
}

/* ---- Copyright ---- */
.copyright{
  margin-top: 35px;
  padding-top: 22px;
  border-top: 1px solid rgba(255,255,255,.08);
  text-align: center;
}

.copyright p{
  margin: 0;
  font-size: 14px;
  color: rgba(255,255,255,.78);
}

.copyright a{
  text-decoration:none;
  transition: opacity .2s ease;
}

.copyright a:hover{
  opacity: .9;
}

/* =========================
   Responsive
========================= */

@media (max-width: 992px){
  .footer-content{
    grid-template-columns: 1fr 1fr;
  }
}

@media (max-width: 640px){
  footer{
    padding: 45px 0 18px;
  }

  .footer-content{
    grid-template-columns: 1fr;
    gap: 14px;
  }

  .footer-logo-section{
    justify-content: center;
    text-align: center;
  }

  .footer-join-btn{
    width: 100%;
    justify-content: center;
  }

  .footer-column{
    padding: 18px 16px;
  }
}
