/* ======================================
   REBBLE PRIVATE STORE – STORE PAGE
   Grid, controls, cards
   ====================================== */

:root {
  --bg: #bcc8d9;
  --card: #ffffff;
  --text: #111827;
  --muted: #6b7280;
  --accent: #2563eb;
  --heart: #e25555;
  --radius: 18px;
  --shadow: 0 2px 8px rgba(0,0,0,0.08);
  --shadow-hover: 0 10px 22px rgba(0,0,0,0.14);
}

/* ---------- Page base ---------- */

body {
  margin: 0;
  padding: 18px;
  background: var(--bg);
  font-family: system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Ubuntu, Cantarell, Arial, sans-serif;
  color: var(--text);
}

h1 {
  text-align: center;
  font-size: 2.1rem;
  margin: 10px 0 26px;
  letter-spacing: -0.02em;
}

.page-logo {
    height: 115px;
    width: auto;
}


/* Gap between header and search controls (store.php) */
.controls {
  margin-top: 28px !important;
}


/* ---------- Controls ---------- */

.controls {
  display: flex;
  gap: 10px;
  max-width: 1200px;
  margin: 0 auto 22px;
}

.controls input,
.controls select {
  padding: 10px 14px;
  font-size: 14px;
  border-radius: 999px;
  border: 1px solid #ccc;
}

/* ---------- Grid ---------- */

.grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
  gap: 18px;
  max-width: 1200px;
  margin: 0 auto;
}

/* ---------- Cards ---------- */

.card {
  display: flex;
  align-items: center;
  gap: 14px;
  text-decoration: none;
  background: var(--card);
  border-radius: var(--radius);
  padding: 14px 16px;
  box-shadow: var(--shadow);
  transition: transform .18s ease, box-shadow .18s ease;
  color: var(--text);
}

.card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-hover);
}

.card {
  margin-bottom: 28px;    
}
/* ---------- Icon ---------- */

.icon {
  width: 64px;
  height: 64px;
  border-radius: 14px;
  overflow: hidden;
  background: #e5e7eb;
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
}

.icon img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

/* ---------- Text ---------- */

.info {
  flex: 1;
  min-width: 0;
}

.title {
  font-size: 15px;
  font-weight: 700;
  margin-bottom: 4px;
  color: var(--accent);
  text-decoration: underline;
  line-height: 1.2;
}

.dev {
  font-size: 13px;
  color: var(--muted);
  margin-bottom: 6px;
}

.hearts {
  font-size: 13px;
  color: var(--heart);
  font-weight: 700;
}

/* ---------- Rebble-style pill controls ---------- */

.controls input,
.controls select {
  border-radius: 999px;
  background: #ffffff;
  color: #000000 !important;
  border: none;
  font-weight: 600;
}

.controls input::placeholder {
  color: #000000;
}

.controls input:hover,
.controls select:hover {
  background: #ffffff;
  color: #b82418 !important;
}

/* ------------------------------------------------ */
/* Pagination Styling (matches Rebble Archive)      */
/* ------------------------------------------------ */

.rebble-pagination {
    margin: 30px 0;
    text-align: center;
}

.rebble-page-btns {
    display: inline-flex;
    gap: 6px;
    flex-wrap: wrap;
    justify-content: center;
    align-items: center;
}

.rebble-page-btn,
.rebble-page-current,
.rebble-page-ellipsis {
    padding: 6px 12px;
    border-radius: 8px;
    font-size: 15px;
    font-weight: 500;
    text-decoration: none;
}

.rebble-page-btn {
    background: #eef2ff;
    color: #1e3a8a;
    border: 1px solid #c7d2fe;
}

.rebble-page-btn:hover {
    background: #e0e7ff;
}

.rebble-page-current {
    background: #3b82f6;
    color: white;
}

.rebble-page-ellipsis {
    color: #6b7280;
    padding: 6px 4px;
}

/* ---------- Mobile ---------- */

@media (max-width: 720px) {

  body {
    padding: 14px;
  }

  h1 {
    font-size: 1.7rem;
  }

  .controls {
    flex-direction: column;
  }

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

  .card {
    padding: 14px 14px;
  }

  .icon {
    width: 56px;
    height: 56px;
  }
}

/* Extra mobile tuning */

@media (max-width: 640px) {
  h1 {
    font-size: 24px;
  }

  .controls {
    padding: 0 16px;
  }

  .grid {
    padding: 0 14px 30px;
    gap: 14px;
  }

  .card {
    padding: 14px;
  }

  .icon {
    width: 72px;
    height: 72px;
  }
}

/* Make search bar longer & aligned */
.global-search {
    width: 310px;     /* adjust length */
    max-width: 100%;  /* still mobile safe */
    padding: 14px 18px;
    font-size: 17px;
    border-radius: 14px;
    box-sizing: border-box;
}

/* Move ONLY the search bar left-right without affecting layout */
.controls input.global-search {
    margin-left: 100px !important;   /* adjust this number */
}

/* Community info paragraph */
section p.small.muted {
  text-align: left;     /* force left justification */
  margin-left: 40px;    /* indent from the left edge */
  margin-right: auto;   /* prevent centering */
}

/* Footer copyright text */
.site-footer .wrap p {
  font-size: 0.85em;    /* smaller font size */
  text-align: left;     /* keep left aligned */
  margin-left: 50px;    /* match the same left margin */
}

/* ============================================
   📱 MOBILE — FULL-WIDTH HEADER BACKGROUND
   WITHOUT MOVING CONTENT
============================================ */
@media (max-width: 640px) {

  /* Header background extension only */
  .page-header::before {
    content: "";
    position: absolute;
    top: 0;
    left: 50%;
    width: 100vw;
    height: 100%;
    transform: translateX(-50%);
    background: #000;
    z-index: -1;
  }

  /* Ensure header can host pseudo-element */
  .page-header {
    position: relative;
    background: transparent !important;
  }

  /* FULL-WIDTH RED DIVIDER (NO CONTENT MOVE) */
  .page-header-divider {
    width: 100vw !important;
    margin-left: calc(50% - 50vw) !important;
  }
}

/* ============================================
   📱 MOBILE — HEADER PADDING ALIGNMENT FIX
   Matches header content to card gutter
============================================ */
@media (max-width: 640px) {

  /* Tighten header inner padding to match cards */
  .page-header-inner {
    padding-left: 14px !important;
    padding-right: 0px !important;
  }
}

/* ============================================
   📱 MOBILE — FORCE HEADER BACKGROUND FULL WIDTH
   (visual extension ONLY, no layout changes)
============================================ */
@media (max-width: 640px) {

  .page-header {
    position: relative;
    background: none !important; /* prevent double layering */
  }

  .page-header::before {
    content: "";
    position: absolute;
    top: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 100vw;
    height: 100%;
    background: #000; /* header black */
    z-index: -1;
  }
}