/* Awwab — Guidance Cards (/cards). Immersive swipe-through microlearning,
   layered on the shared tokens in styles.css. Scoped under .cards-main. */

.cards-main { min-height: calc(100vh - 64px); color: #f3efe6; background:
  radial-gradient(1000px 520px at 80% -10%, rgba(216,183,96,0.14), transparent 60%),
  linear-gradient(165deg, var(--emerald-900, #0a2017), var(--emerald-800, #0f2c20) 60%, #0b2419); }
.cards-wrap { max-width: 720px; margin: 0 auto; padding: 30px 20px 90px; }

.cards-head { text-align: center; margin-bottom: 18px; }
.cards-head .eyebrow { justify-content: center; }
.cards-head h1 { font-family: var(--serif); font-weight: 600; font-size: clamp(30px, 6vw, 46px); margin: 6px 0 8px; color: #fbf7ee; }
.cards-head p { color: #c9d3c9; font-size: 15px; margin: 0; }

/* gamification chips */
.cg-row { display: flex; gap: 10px; justify-content: center; flex-wrap: wrap; margin: 16px 0 4px; }
.cg-chip { display: inline-flex; align-items: center; gap: 7px; padding: 8px 15px; border-radius: 999px;
  background: rgba(255,255,255,0.05); border: 1px solid rgba(216,183,96,0.3); font-size: 13.5px; font-weight: 600; color: #f0e6cf; }
.cg-chip b { color: var(--gold-bright); }
.cg-chip svg { width: 15px; height: 15px; stroke: var(--gold-bright); fill: none; stroke-width: 1.8; }

.cards-label { text-transform: uppercase; letter-spacing: 1.4px; font-size: 12px; font-weight: 700; color: var(--gold-bright); margin: 30px 0 12px; }

/* deck grid */
.deck-grid { display: grid; grid-template-columns: 1fr 1fr 1fr; gap: 14px; }
.deck-card { text-align: left; cursor: pointer; color: inherit; border-radius: 18px; padding: 20px;
  background: linear-gradient(160deg, rgba(255,255,255,0.06), rgba(255,255,255,0.02));
  border: 1px solid rgba(237,224,191,0.18); transition: transform .16s ease, border-color .16s ease; display: flex; flex-direction: column; gap: 10px; }
.deck-card:hover { transform: translateY(-3px); border-color: rgba(216,183,96,0.5); }
.deck-ic { width: 46px; height: 46px; border-radius: 13px; display: grid; place-items: center; background: var(--gold); color: #20170a; }
.deck-ic svg { width: 24px; height: 24px; stroke: currentColor; fill: none; stroke-width: 1.7; }
.deck-card h3 { font-family: var(--serif); font-size: 18px; font-weight: 600; margin: 0; }
.deck-card .dc-meta { font-size: 12.5px; color: #aab6ab; }
.deck-prog { height: 6px; border-radius: 99px; background: rgba(255,255,255,0.1); overflow: hidden; margin-top: auto; }
.deck-prog i { display: block; height: 100%; background: linear-gradient(90deg, var(--gold), var(--gold-bright)); border-radius: 99px; transition: width .6s ease; }

/* ===== flashcard ===== */
.fc-stage { perspective: 1400px; margin: 8px 0 16px; }
.fc { position: relative; border-radius: 22px; padding: 30px 26px; min-height: 280px;
  background: linear-gradient(165deg, #143024, #0c2218); border: 1px solid rgba(216,183,96,0.34);
  box-shadow: 0 40px 80px -50px rgba(0,0,0,0.7); transform-style: preserve-3d;
  transition: transform .2s cubic-bezier(.4,.0,.2,1); will-change: transform; }
.fc .fc-topic { font-size: 12px; letter-spacing: 1px; text-transform: uppercase; font-weight: 700; color: var(--gold-bright); margin-bottom: 14px; }
.fc .fc-front-q { font-family: var(--serif); font-size: clamp(20px, 3.4vw, 26px); line-height: 1.4; color: #fbf7ee; }
.fc .fc-hint { position: absolute; left: 0; right: 0; bottom: 18px; text-align: center; font-size: 12.5px; color: #9fb0a4; }
.fc .fc-hint span { display: inline-flex; align-items: center; gap: 6px; }

/* back content */
.fc-entry { padding: 14px 0; border-top: 1px solid rgba(216,183,96,0.18); }
.fc-entry:first-child { border-top: 0; padding-top: 0; }
.fc-ar { font-family: "Amiri Quran", "Amiri", "Scheherazade New", serif; font-size: 24px; line-height: 2; text-align: right; color: #f7f0dd; margin-bottom: 8px; }
.fc-en { font-size: 15.5px; line-height: 1.6; color: #e7ece4; }
.fc-note { font-size: 13.5px; line-height: 1.55; color: #aebcae; margin-top: 8px; font-style: italic; }
.fc-src { display: inline-flex; align-items: center; gap: 6px; margin-top: 10px; font-size: 12.5px; color: var(--gold-bright); text-decoration: none; }
.fc-src:hover { text-decoration: underline; }
.fc-listen { margin-top: 10px; display: inline-flex; align-items: center; gap: 8px; cursor: pointer;
  background: rgba(216,183,96,0.12); border: 1px solid rgba(216,183,96,0.34); color: #f0e6cf;
  padding: 8px 13px; border-radius: 10px; font-size: 13px; font-weight: 600; font-family: var(--sans); }
.fc-listen svg { width: 15px; height: 15px; color: var(--gold-bright); }
.fc-audio { width: 100%; height: 38px; margin-top: 10px; display: block; }

/* controls */
.fc-controls { display: flex; align-items: center; gap: 12px; margin-top: 6px; }
.fc-nav { width: 46px; height: 46px; border-radius: 50%; border: 1px solid rgba(237,224,191,0.22); background: rgba(255,255,255,0.05);
  color: #f3efe6; cursor: pointer; font-size: 20px; flex: none; transition: border-color .15s ease, transform .1s ease; }
.fc-nav:hover:not(:disabled) { border-color: rgba(216,183,96,0.55); }
.fc-nav:active:not(:disabled) { transform: scale(.92); }
.fc-nav:disabled { opacity: .35; cursor: default; }
.fc-flip { flex: 1; justify-content: center; border: 0; cursor: pointer; }
.fc-count { text-align: center; font-size: 13px; color: #c9d3c9; margin: 14px 0 0; }
.fc-dots { display: flex; flex-wrap: wrap; gap: 6px; justify-content: center; margin-top: 12px; max-width: 420px; margin-left: auto; margin-right: auto; }
.fc-dot { width: 7px; height: 7px; border-radius: 50%; background: rgba(255,255,255,0.18); transition: background .2s ease, transform .2s ease; }
.fc-dot.on { background: var(--gold-bright); transform: scale(1.25); }
.fc-dot.seen { background: rgba(216,183,96,0.5); }

.cards-back { display: inline-flex; align-items: center; gap: 7px; color: #c4b58f; background: none; border: 0; cursor: pointer; font-size: 14px; margin-bottom: 8px; }
.cards-back:hover { color: #f4efe3; }

.deck-done { text-align: center; padding: 30px 10px; }
.deck-done .g-medal, .cards-done-medal { width: 84px; height: 84px; border-radius: 50%; margin: 0 auto 14px; display: grid; place-items: center;
  background: radial-gradient(circle at 50% 35%, rgba(216,183,96,0.4), rgba(216,183,96,0.08)); }
.cards-done-medal svg { width: 44px; height: 44px; stroke: var(--gold-bright); fill: none; stroke-width: 1.4; }

@media (max-width: 560px) { .deck-grid { grid-template-columns: 1fr; } }
@media (prefers-reduced-motion: reduce) { .fc { transition: none; } }

@keyframes spin { to { transform: rotate(360deg); } }
