/* =====================================================
   Islamic Flashcards v4.0 — style.css
   Islam Hashtag: navy #1e3a5f  pink #e91e8c
   ===================================================== */
:root {
  --afd-navy:     #1e3a5f;
  --afd-navy-dk:  #142847;
  --afd-navy-lt:  #2a4f7a;
  --afd-pink:     #e91e8c;
  --afd-pink-dk:  #c4187a;
  --afd-white:    #ffffff;
  --afd-bg:       #f8f9fc;
  --afd-border:   #e2e8f0;
  --afd-text:     #1e293b;
  --afd-muted:    #64748b;
  --afd-radius:   14px;
  --afd-shadow:   0 2px 12px rgba(30,58,95,.08);
  --afd-shadow-md:0 6px 28px rgba(30,58,95,.14);
  --afd-shadow-lg:0 16px 56px rgba(30,58,95,.24);
}

/* ─── GRID WRAPPER ─────────────────────────────── */
.afd-dashboard-wrap { width:100%; max-width:1100px; margin:0 auto; }

/* ─── SEARCH ────────────────────────────────────── */
.afd-dash-search  { margin:0 0 22px; }
.afd-search-input {
  width:100%; max-width:420px;
  padding:10px 18px;
  border:1.5px solid var(--afd-border);
  border-radius:999px;
  font-size:15px; color:var(--afd-text);
  background:var(--afd-white);
  outline:none;
  transition:border-color .2s;
}
.afd-search-input:focus { border-color:var(--afd-navy); }

/* ─── TILE GRID  3 → 2 → 1 ─────────────────────── */
.afd-dash-grid {
  display:grid;
  grid-template-columns:repeat(3,1fr);
  gap:20px;
}
@media(max-width:860px){ .afd-dash-grid{ grid-template-columns:repeat(2,1fr); gap:16px; } }
@media(max-width:520px){ .afd-dash-grid{ grid-template-columns:1fr; gap:12px; } }

/* ─── TILE CARD ─────────────────────────────────── */
.afd-tile {
  position:relative;
  background:var(--afd-white);
  border:1.5px solid var(--afd-border);
  border-radius:var(--afd-radius);
  box-shadow:var(--afd-shadow);
  overflow:hidden;
  display:flex;
  flex-direction:column;
  transition:transform .18s, box-shadow .18s, border-color .18s;
}
.afd-tile:hover { transform:translateY(-4px); box-shadow:var(--afd-shadow-md); border-color:#c8d8ea; }

/* coloured top bar */
.afd-tile::before {
  content:'';
  display:block;
  height:4px;
  background:linear-gradient(90deg, var(--afd-navy), var(--afd-pink));
  flex-shrink:0;
}

.afd-tile-inner {
  padding:18px 16px 22px;
  display:flex;
  flex-direction:column;
  align-items:center;
  text-align:center;
  flex:1;
}
.afd-tile-title { margin:0 0 6px; font-size:15.5px; font-weight:700; color:var(--afd-navy); line-height:1.35; }
.afd-tile-count { margin:0 0 10px; font-size:12px; color:var(--afd-muted); font-weight:500; }
.afd-tile-free-badge {
  display:inline-flex; align-items:center; gap:3px;
  background:#f0fdf4; color:#15803d; border:1px solid #bbf7d0;
  font-size:11px; font-weight:600; padding:3px 9px; border-radius:999px;
  margin-bottom:10px;
}

/* ─── BUTTONS ───────────────────────────────────── */
.afd-start-btn {
  display:inline-flex; align-items:center; justify-content:center;
  padding:9px 0; width:100%; max-width:190px;
  background:var(--afd-pink); color:var(--afd-white);
  border:none; border-radius:999px;
  font-size:13px; font-weight:600; cursor:pointer;
  text-decoration:none;
  transition:background .18s, transform .15s, box-shadow .15s;
  box-shadow:0 2px 8px rgba(233,30,140,.22);
  margin-top:auto;
}
.afd-start-btn:hover {
  background:var(--afd-pink-dk);
  transform:scale(1.04);
  box-shadow:0 4px 16px rgba(233,30,140,.32);
  color:var(--afd-white);
}
.afd-upgrade-btn {
  background:var(--afd-navy) !important;
  box-shadow:0 2px 8px rgba(30,58,95,.22) !important;
}
.afd-upgrade-btn:hover {
  background:var(--afd-navy-dk) !important;
  box-shadow:0 4px 16px rgba(30,58,95,.32) !important;
}

/* ─── LOCK / PREVIEW BADGE ──────────────────────── */
.afd-tile.is-locked::after,
.afd-tile.has-preview::after {
  position:absolute; top:12px; right:12px;
  font-size:10px; font-weight:700; letter-spacing:.2px;
  padding:3px 8px; border-radius:999px;
  pointer-events:none;
}
.afd-tile.is-locked::after  { content:'🔒 Members'; background:var(--afd-navy); color:#fff; }
.afd-tile.has-preview::after{ content:'✨ Preview';  background:var(--afd-pink); color:#fff; }

/* ─── MODAL OVERLAY ─────────────────────────────── */
.afd-modal {
  position:fixed; inset:0;
  background:rgba(15,23,42,.70);
  display:none; align-items:center; justify-content:center;
  z-index:99999; padding:20px;
}
.afd-modal.is-open { display:flex; }

.afd-modal-card {
  background:var(--afd-white);
  width:100%; max-width:600px;
  border-radius:20px;
  padding:24px 24px 28px;
  position:relative;
  box-shadow:var(--afd-shadow-lg);
  max-height:90vh;
  overflow-y:auto;
}
.afd-modal-title {
  margin:0 44px 20px 0;
  font-size:20px; font-weight:700; color:var(--afd-navy); line-height:1.3;
}
.afd-close {
  position:absolute; top:14px; right:14px;
  width:36px; height:36px;
  background:#f1f5f9; border:none; border-radius:999px;
  font-size:17px; cursor:pointer;
  display:flex; align-items:center; justify-content:center;
  color:var(--afd-text); transition:background .15s;
}
.afd-close:hover { background:#e2e8f0; }

/* ─── FLASHCARD PLAYER (inside modal) ───────────── */
.afd-player { display:flex; flex-direction:column; gap:0; }
.afd-card-wrap { margin-bottom:14px; }

.avf-card-front,
.avf-card-back {
  display:flex;
  align-items:center;
  justify-content:center;
  text-align:center;
  width:100%;
  min-height:160px;
  padding:24px 28px;
  border-radius:14px;
  font-size:clamp(20px, 4vw, 36px);
  font-weight:700;
  line-height:1.4;
  color:#0f172a;
  word-break:break-word;
  box-sizing:border-box;
  box-shadow:0 3px 12px rgba(0,0,0,.07);
}
.avf-card-front { background:#eef6ff; border:2px solid #bfdbfe; }
.avf-card-back  { background:#fffbeb; border:2px solid #fde68a; }

.avf-controls {
  display:flex; gap:10px; justify-content:center;
  flex-wrap:wrap; margin-bottom:12px;
}
.avf-controls button {
  padding:10px 28px;
  font-size:14px; font-weight:600;
  border-radius:999px; border:none; cursor:pointer;
  transition:transform .15s, box-shadow .15s;
}
.avf-controls .avf-flip {
  background:var(--afd-navy); color:#fff;
  box-shadow:0 2px 8px rgba(30,58,95,.22);
}
.avf-controls .avf-flip:hover  { background:var(--afd-navy-lt); transform:translateY(-1px); }
.avf-controls .avf-next {
  background:var(--afd-pink); color:#fff;
  box-shadow:0 2px 8px rgba(233,30,140,.22);
}
.avf-controls .avf-next:hover  { background:var(--afd-pink-dk); transform:translateY(-1px); }

.avf-score {
  text-align:center; font-size:13px;
  color:var(--afd-muted); font-weight:500;
}

/* ─── UPGRADE CTA (modal + inline) ─────────────── */
.afd-modal-cta { margin-top:16px; }
.afd-upgrade-cta {
  text-align:center; padding:22px 18px;
  background:linear-gradient(135deg,#fff8f0,#fff3e0);
  border:2px solid #f59e0b; border-radius:14px;
}
.afd-cta-icon     { font-size:30px; margin-bottom:8px; }
.afd-cta-headline { font-size:17px; font-weight:700; margin:0 0 6px; color:#1a1a1a; }
.afd-cta-sub      { font-size:13.5px; color:#555; margin:0 0 14px; }
.afd-cta-btn {
  display:inline-block;
  background:var(--afd-pink); color:#fff;
  padding:11px 24px; border-radius:999px;
  font-size:14px; font-weight:600; text-decoration:none;
}
.afd-cta-btn:hover { background:var(--afd-pink-dk); color:#fff; }
.afd-cta-note { font-size:11.5px; color:#888; margin:10px 0 0; }

/* ─── INLINE single-set flashcard (no modal) ────── */
.avf-flashcards {
  border:1.5px solid var(--afd-border);
  border-radius:var(--afd-radius);
  padding:20px;
  max-width:500px;
  margin:20px auto;
  background:var(--afd-white);
  box-shadow:var(--afd-shadow);
}
.avf-flashcards .avf-score { margin-top:10px; font-weight:600; }

/* ─── LANDING PAGE ──────────────────────────────── */
.afd-landing { max-width:1100px; margin:0 auto; font-family:inherit; }

/* Hero */
.afd-hero {
  text-align:center;
  padding:48px 24px 40px;
  background:linear-gradient(135deg,#f0f7ff,#e8f4ff);
  border-radius:20px; margin-bottom:32px;
}
.afd-hero-title { font-size:clamp(24px,4vw,40px); font-weight:800; color:var(--afd-navy); margin:0 0 12px; }
.afd-hero-sub   { font-size:clamp(14px,2vw,17px); color:var(--afd-muted); max-width:540px; margin:0 auto 20px; }
.afd-hero-stats { display:flex; justify-content:center; gap:32px; margin-bottom:22px; }
.afd-hero-stat  { display:flex; flex-direction:column; align-items:center; gap:2px; }
.afd-hero-stat strong { font-size:28px; font-weight:800; color:var(--afd-navy); }
.afd-hero-stat span   { font-size:12px; color:var(--afd-muted); text-transform:uppercase; letter-spacing:.5px; }
.afd-hero-actions { display:flex; gap:12px; justify-content:center; flex-wrap:wrap; margin-bottom:12px; }
.afd-hero-note    { font-size:12px; color:var(--afd-muted); margin:0; }

.afd-btn-primary {
  display:inline-block;
  background:var(--afd-pink); color:#fff;
  padding:12px 26px; border-radius:999px;
  font-size:15px; font-weight:600; text-decoration:none;
  box-shadow:0 3px 12px rgba(233,30,140,.25);
}
.afd-btn-primary:hover { background:var(--afd-pink-dk); color:#fff; }
.afd-btn-secondary {
  display:inline-block;
  background:#fff; color:var(--afd-navy);
  padding:12px 26px; border-radius:999px;
  font-size:15px; font-weight:600; text-decoration:none;
  border:2px solid var(--afd-navy);
}
.afd-btn-secondary:hover { background:#f0f7ff; }
.afd-btn-lg { padding:15px 34px; font-size:17px; }

/* How it works box */
.afd-membership-box { background:#fff; border:2px solid #bfdbfe; border-radius:18px; margin-bottom:32px; }
.afd-membership-box-inner { padding:28px 32px; text-align:center; }
.afd-mb-title { font-size:18px; font-weight:700; color:var(--afd-navy); margin:0 0 20px; }
.afd-mb-grid  { display:flex; align-items:center; justify-content:center; gap:20px; margin-bottom:16px; flex-wrap:wrap; }
.afd-mb-item  { background:var(--afd-bg); border:1.5px solid var(--afd-border); border-radius:12px; padding:16px 20px; text-align:center; min-width:150px; }
.afd-mb-item strong { display:block; font-size:17px; font-weight:700; color:var(--afd-navy); margin:6px 0 4px; }
.afd-mb-item p { font-size:13px; color:var(--afd-muted); margin:0; line-height:1.4; }
.afd-mb-paid  { border-color:var(--afd-pink); background:#fce7f3; }
.afd-mb-paid strong { color:var(--afd-pink-dk); }
.afd-mb-icon  { font-size:26px; }
.afd-mb-arrow { font-size:22px; color:var(--afd-muted); }
.afd-mb-note  { font-size:13px; font-weight:600; color:var(--afd-navy); margin:0 0 18px; }

/* Subjects section */
.afd-subjects-wrap  { margin-bottom:40px; }
.afd-subjects-title { font-size:22px; font-weight:700; color:var(--afd-navy); margin:0 0 20px; }

.afd-subject-section {
  margin-bottom:36px;
  background:var(--afd-white);
  border:1.5px solid var(--afd-border);
  border-radius:var(--afd-radius);
  overflow:hidden;
  box-shadow:var(--afd-shadow);
}
.afd-subject-header {
  display:flex; align-items:center; gap:14px;
  padding:18px 20px;
  background:linear-gradient(90deg,#f0f7ff,#fff);
  border-bottom:1px solid var(--afd-border);
}
.afd-subject-icon { font-size:28px; flex-shrink:0; }
.afd-subject-meta { flex:1; }
.afd-subject-name { font-size:18px; font-weight:700; color:var(--afd-navy); margin:0 0 3px; }
.afd-subject-desc { font-size:13px; color:var(--afd-muted); margin:0; }
.afd-subject-sets { padding:20px; }

/* Get Pro banner after each category */
.afd-cat-cta {
  display:flex; align-items:center; justify-content:center;
  gap:12px; flex-wrap:wrap;
  padding:14px 20px;
  background:#fff8f0; border-top:1px solid #fde8c8;
}
.afd-cat-cta-text { font-size:14px; color:#92400e; font-weight:500; }
.afd-cat-cta-btn  {
  display:inline-block;
  background:var(--afd-pink); color:#fff;
  padding:8px 20px; border-radius:999px;
  font-size:13px; font-weight:600; text-decoration:none;
  white-space:nowrap;
}
.afd-cat-cta-btn:hover { background:var(--afd-pink-dk); color:#fff; }

/* Bottom CTA banner */
.afd-cta-banner {
  background:linear-gradient(135deg,var(--afd-navy),var(--afd-navy-lt));
  border-radius:20px; padding:48px 24px; text-align:center; margin-top:12px;
}
.afd-cta-banner-title { font-size:clamp(20px,3vw,30px); font-weight:800; color:#fff; margin:0 0 10px; }
.afd-cta-banner-sub   { font-size:15px; color:#bfdbfe; max-width:560px; margin:0 auto 24px; }
.afd-cta-banner-note  { font-size:12px; color:#93c5fd; margin:14px 0 0; }

/* Locked msg (inline shortcode hard-lock) */
.afd-locked-msg { padding:14px; border:1px solid #f1d5d5; background:#fff6f6; border-radius:8px; }

/* ─── RESPONSIVE ────────────────────────────────── */
@media(max-width:680px) {
  .afd-hero          { padding:32px 16px; }
  .afd-hero-stats    { gap:20px; }
  .afd-membership-box-inner { padding:20px 16px; }
  .afd-mb-grid       { gap:10px; }
  .afd-mb-arrow      { display:none; }
  .afd-subject-header{ gap:10px; padding:14px 14px; }
  .afd-subject-sets  { padding:14px; }
  .afd-cat-cta       { flex-direction:column; gap:8px; }
}

/* =====================================================
   Islamic Education Store — [afd_woo_store]
   v5.0 — Islam Hashtag
   ===================================================== */

/* ─── STORE WRAPPER ─────────────────────────────────── */
.afd-store-wrap {
  max-width: 1140px;
  margin: 0 auto;
  font-family: inherit;
}

/* ─── STORE HEADER ──────────────────────────────────── */
.afd-store-header {
  background: linear-gradient(135deg, #6b0f1a 0%, #8b1a1a 50%, #6b0f1a 100%);
  border-radius: 18px;
  margin-bottom: 28px;
  padding: 48px 32px 40px;
  text-align: center;
  position: relative;
  overflow: hidden;
}
.afd-store-header::before {
  content: '';
  position: absolute;
  inset: 0;
  background: radial-gradient(ellipse at top, rgba(255,255,255,.08) 0%, transparent 70%);
  pointer-events: none;
}
.afd-store-bismillah {
  font-family: 'Scheherazade New', 'Amiri', serif;
  font-size: clamp(20px, 3vw, 28px);
  color: #f5c842;
  margin: 0 0 14px;
  letter-spacing: .5px;
}
.afd-store-title {
  font-size: clamp(22px, 4vw, 38px);
  font-weight: 800;
  color: #fff;
  margin: 0 0 10px;
  font-family: 'IM Fell English', Georgia, serif;
  letter-spacing: -.5px;
}
.afd-store-subtitle {
  font-size: clamp(13px, 2vw, 16px);
  color: rgba(255,255,255,.75);
  margin: 0;
  max-width: 500px;
  margin: 0 auto;
}

/* ─── FILTER BAR ─────────────────────────────────────── */
.afd-store-filters {
  background: #fff;
  border: 1.5px solid var(--afd-border);
  border-radius: 14px;
  padding: 18px 20px 14px;
  margin-bottom: 24px;
  box-shadow: var(--afd-shadow);
}
.afd-filter-row {
  display: flex;
  align-items: flex-start;
  gap: 14px;
  margin-bottom: 12px;
  flex-wrap: wrap;
}
.afd-filter-row:last-child { margin-bottom: 0; }

.afd-filter-label {
  font-size: 11px;
  font-weight: 700;
  letter-spacing: .8px;
  color: var(--afd-muted);
  text-transform: uppercase;
  min-width: 70px;
  padding-top: 8px;
  flex-shrink: 0;
}
.afd-filter-group {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}
.afd-filter-btn {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 6px 14px;
  font-size: 13px;
  font-weight: 500;
  border: 1.5px solid var(--afd-border);
  border-radius: 999px;
  background: #f8f9fc;
  color: var(--afd-text);
  cursor: pointer;
  transition: all .18s;
  white-space: nowrap;
}
.afd-filter-btn:hover {
  border-color: var(--afd-navy);
  color: var(--afd-navy);
  background: #eef4ff;
}
.afd-filter-btn.active {
  background: var(--afd-navy);
  border-color: var(--afd-navy);
  color: #fff;
  font-weight: 600;
}
/* Active chip pills */
.afd-active-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  min-height: 0;
  margin-top: 4px;
}
.afd-chip {
  display: inline-flex;
  align-items: center;
  background: #fce7f3;
  border: 1px solid #f9a8d4;
  color: #9d174d;
  font-size: 12px;
  font-weight: 600;
  padding: 4px 10px;
  border-radius: 999px;
  cursor: pointer;
  transition: background .15s;
}
.afd-chip:hover { background: #fbcfe8; }

/* ─── PRODUCT GRID  3 → 2 → 1 ───────────────────────── */
.afd-store-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 22px;
}
@media(max-width:900px){ .afd-store-grid{ grid-template-columns:repeat(2,1fr); gap:16px; } }
@media(max-width:540px){ .afd-store-grid{ grid-template-columns:1fr; gap:14px; } }

/* ─── STORE CARD ─────────────────────────────────────── */
.afd-store-card {
  position: relative;
  background: #fff;
  border: 1.5px solid var(--afd-border);
  border-radius: 14px;
  box-shadow: var(--afd-shadow);
  overflow: hidden;
  display: flex;
  flex-direction: column;
  transition: transform .18s, box-shadow .18s, border-color .18s;
}
.afd-store-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--afd-shadow-md);
  border-color: #c8d8ea;
}
/* dashed border style = standard card */
.afd-store-card {
  border-style: dashed;
}

/* card image area */
.afd-sc-img {
  width: 100%;
  height: 160px;
  overflow: hidden;
  background: linear-gradient(135deg, #f0f7ff, #e8f4ff);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}
.afd-sc-img img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}
.afd-sc-img-placeholder {
  font-size: 52px;
  opacity: .55;
}

/* Sale badge */
.afd-sc-badge {
  position: absolute;
  top: 10px;
  right: 10px;
  font-size: 11px;
  font-weight: 700;
  padding: 3px 9px;
  border-radius: 999px;
  z-index: 2;
  letter-spacing: .2px;
}
.afd-sc-badge-sale {
  background: var(--afd-pink);
  color: #fff;
}

/* card body */
.afd-sc-body {
  padding: 14px 16px 10px;
  flex: 1;
}
.afd-sc-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 5px;
  margin-bottom: 8px;
}
.afd-sc-subject-tag,
.afd-sc-for-tag {
  font-size: 11px;
  font-weight: 600;
  padding: 3px 9px;
  border-radius: 999px;
  line-height: 1.4;
}
.afd-sc-subject-tag {
  background: #e8f0fe;
  color: #1e3a5f;
}
.afd-sc-for-tag {
  background: #fce7f3;
  color: #9d174d;
}
.afd-sc-title {
  font-size: 15px;
  font-weight: 700;
  color: var(--afd-navy);
  margin: 0 0 5px;
  line-height: 1.35;
}
.afd-sc-title a {
  color: inherit;
  text-decoration: none;
}
.afd-sc-title a:hover { color: var(--afd-pink); }
.afd-sc-count {
  font-size: 12px;
  color: var(--afd-muted);
  margin: 0 0 8px;
}
.afd-sc-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 4px;
}
.afd-sc-tag {
  font-size: 11px;
  background: #f1f5f9;
  color: #475569;
  border-radius: 6px;
  padding: 2px 7px;
}

/* card footer */
.afd-sc-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 10px 16px 14px;
  border-top: 1px solid var(--afd-border);
  gap: 10px;
  background: #fafbfc;
}
.afd-sc-price {
  font-size: 17px;
  font-weight: 800;
  color: var(--afd-navy);
}
.afd-sc-price ins { text-decoration: none; }
.afd-sc-price del { font-size: 12px; color: var(--afd-muted); font-weight: 400; margin-right: 4px; }

.afd-sc-buy-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: var(--afd-pink);
  color: #fff;
  border: none;
  border-radius: 999px;
  padding: 8px 18px;
  font-size: 13px;
  font-weight: 600;
  text-decoration: none;
  cursor: pointer;
  transition: background .18s, transform .15s;
  white-space: nowrap;
}
.afd-sc-buy-btn:hover {
  background: var(--afd-pink-dk);
  color: #fff;
  transform: scale(1.04);
}

/* ─── RESPONSIVE ─────────────────────────────────────── */
@media(max-width:680px) {
  .afd-store-header { padding: 32px 16px 28px; }
  .afd-store-filters { padding: 14px 14px 12px; }
  .afd-filter-label { min-width: 55px; font-size: 10px; }
  .afd-filter-btn   { font-size: 12px; padding: 5px 10px; }
  .afd-sc-img       { height: 130px; }
}
