/* =========================================================
   Magic Picker — Mobile-first AI app redesign
   Inspired by the provided reference screenshot.
   ========================================================= */

:root {
  --text: #131826;
  --muted: #6b7588;
  --line: #eef1f6;
  --bg: #f7f7fb;
  --card: #ffffff;
  --primary: #6c5ce7;
  --primary-deep: #4b39c7;
  --accent: #ff7a59;
  --shadow-xs: 0 4px 12px rgba(20, 25, 50, 0.06);
  --shadow-sm: 0 10px 24px rgba(20, 25, 50, 0.08);
  --shadow-md: 0 18px 40px rgba(35, 25, 90, 0.12);
  --shadow-lg: 0 24px 60px rgba(35, 25, 90, 0.18);
  --radius-lg: 22px;
  --radius-md: 18px;
  --radius-sm: 14px;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }

body {
  margin: 0;
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  color: var(--text);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
}

a { color: inherit; text-decoration: none; }
button, input { font: inherit; }
button { cursor: pointer; }

/* ---------- App shell (phone-like centered column on desktop) ---------- */
.mp-app {
  width: 100%;
  max-width: 620px;
  margin: 0 auto;
  background: #ffffff;
  min-height: 100vh;
  padding: 0 0 110px;
  position: relative;
  box-shadow: 0 0 60px rgba(0,0,0,0.04);
}

/* ---------- Top App Bar ---------- */
.mp-appbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 18px 20px 12px;
  background: linear-gradient(180deg, #ffffff 0%, #f3f6ff 100%);
  border-bottom: 1px solid rgba(108, 92, 231, 0.08);
  box-shadow: 0 8px 24px rgba(32, 36, 77, 0.06);
  position: sticky;
  top: 0;
  z-index: 30;
}

.mp-appbar-title {
  margin: 0;
  font-size: 1.6rem;
  font-weight: 800;
  letter-spacing: -0.02em;
  color: #0f172a;
}

.mp-icon-btn {
  width: 42px;
  height: 42px;
  border-radius: 12px;
  background: transparent;
  border: 0;
  display: grid;
  place-items: center;
  color: #1a2236;
  font-size: 1.25rem;
  transition: background 0.2s ease;
}
.mp-icon-btn:hover { background: #f1f3f8; }

.mp-bell { position: relative; }
.mp-bell i { animation: bellBlink 1.6s infinite ease-in-out; }
.mp-bell-dot {
  position: absolute;
  top: 9px;
  right: 9px;
  width: 8px;
  height: 8px;
  border-radius: 999px;
  background: #ff4d6d;
  box-shadow: 0 0 0 0 rgba(255,77,109,0.55);
  animation: bellPulse 1.4s infinite;
}

@keyframes bellBlink { 0%,100% { opacity: 1; } 50% { opacity: 0.55; } }
@keyframes bellPulse {
  0% { transform: scale(0.9); box-shadow: 0 0 0 0 rgba(255,77,109,0.48); }
  70% { transform: scale(1.15); box-shadow: 0 0 0 8px rgba(255,77,109,0); }
  100% { transform: scale(0.9); box-shadow: 0 0 0 0 rgba(255,77,109,0); }
}

/* ---------- Gradient Search Bar ---------- */
.mp-search-wrap {
  padding: 6px 18px 4px;
  position: relative;
}

.mp-search {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 12px 10px 14px;
  border-radius: 16px;
  background:
    linear-gradient(135deg, rgba(255,255,255,0.18), rgba(255,255,255,0) 60%),
    linear-gradient(95deg, #7aa9d8 0%, #9aa5d2 35%, #c6a4d1 65%, #e7b3c4 100%);
  box-shadow: var(--shadow-sm);
  min-height: 62px;
  position: relative;
  overflow: hidden;
}
.mp-search::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(255,255,255,0.18), rgba(255,255,255,0) 60%);
  pointer-events: none;
}

.mp-search-icon {
  width: 38px;
  height: 38px;
  border-radius: 12px;
  background: rgba(255,255,255,0.55);
  display: grid;
  place-items: center;
  color: #2d3a5f;
  font-size: 0.95rem;
  flex: 0 0 auto;
  box-shadow: inset 0 1px 0 rgba(255,255,255,0.5);
}

.mp-search input {
  flex: 1;
  min-width: 0;
  border: 0;
  outline: 0;
  background: transparent;
  color: #ffffff;
  font-size: 0.92rem;
  font-weight: 500;
  text-shadow: 0 1px 1px rgba(0,0,0,0.08);
}
.mp-search input::placeholder { color: rgba(255,255,255,0.92); font-weight: 500; }

.mp-search-actions {
  display: flex;
  align-items: stretch;
  gap: 0;
  border-left: 1px solid rgba(255,255,255,0.35);
  padding-left: 6px;
  margin-left: 4px;
  position: relative;
  z-index: 1;
}

.mp-search-action {
  border: 0;
  background: transparent;
  color: #ffffff;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 4px;
  padding: 4px 8px;
  font-size: 0.66rem;
  font-weight: 600;
  line-height: 1.1;
  letter-spacing: 0.01em;
  min-width: 50px;
  border-radius: 10px;
  transition: background 0.15s ease, transform 0.15s ease;
}
.mp-search-action:hover { background: rgba(255,255,255,0.15); transform: translateY(-1px); }
.mp-search-action i { font-size: 1rem; }
.mp-search-action span { font-size: 0.66rem; }

.mp-pb-logo {
  width: 18px;
  height: 18px;
  border-radius: 5px;
  background: linear-gradient(135deg, #ff7a59 0%, #ffd166 35%, #9b6dff 70%, #5b8def 100%);
  color: #fff;
  font-weight: 900;
  font-size: 0.72rem;
  display: grid;
  place-items: center;
  line-height: 1;
  box-shadow: 0 2px 6px rgba(0,0,0,0.18);
}

/* Search suggestions dropdown */
.search-suggestions {
  position: absolute;
  left: 18px;
  right: 18px;
  top: calc(100% - 4px);
  background: #ffffff;
  border-radius: 16px;
  box-shadow: var(--shadow-md);
  padding: 8px;
  z-index: 25;
  border: 1px solid var(--line);
}
.search-suggestion-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 10px 12px;
  border-radius: 10px;
  color: #1a2236;
  font-weight: 600;
  font-size: 0.92rem;
}
.search-suggestion-item:hover { background: #f5f6fb; }
.search-suggestion-item i { color: var(--primary); }

/* ---------- Main content area ---------- */
.mp-main {
  padding: 6px 18px 24px;
}

body[data-page="all-tools"] .mp-main,
body[data-page="all-prompts"] .mp-main,
body[data-page="prompt-detail"] .mp-main {
  padding-top: 18px;
}

.mp-section { margin-top: 22px; }

.mp-section-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 12px;
}
.mp-section-head h2 {
  margin: 0;
  font-size: 0.98rem;
  font-weight: 800;
  letter-spacing: 0.06em;
  color: #131826;
  text-transform: uppercase;
}
.mp-chevron {
  width: 34px;
  height: 34px;
  border-radius: 10px;
  background: transparent;
  border: 0;
  color: #4a5675;
  display: grid;
  place-items: center;
  font-size: 0.95rem;
}
.mp-chevron:hover { background: #f1f3f8; color: var(--primary); }

/* ---------- AI Tools Cards (3 colorful cards) ---------- */
.mp-ai-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 12px;
}

.mp-ai-card {
  position: relative;
  aspect-ratio: 1 / 1.05;
  border-radius: 22px;
  overflow: hidden;
  padding: 14px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  color: #ffffff;
  box-shadow: var(--shadow-md);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
  isolation: isolate;
}
.mp-ai-card:hover { transform: translateY(-4px); box-shadow: var(--shadow-lg); }
.mp-ai-card::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(255,255,255,0.18), rgba(0,0,0,0.05) 70%, rgba(0,0,0,0.18));
  pointer-events: none;
  z-index: 0;
}

.mp-ai-illustration {
  position: relative;
  flex: 1;
  display: grid;
  place-items: center;
  z-index: 1;
}
.mp-ai-illustration > i:first-child {
  font-size: 2.6rem;
  filter: drop-shadow(0 6px 14px rgba(0,0,0,0.25));
}

.mp-ai-title {
  position: relative;
  z-index: 1;
  font-size: 0.95rem;
  font-weight: 700;
  letter-spacing: -0.01em;
  text-shadow: 0 2px 6px rgba(0,0,0,0.18);
}

/* Image Gen - purple to blue */
.mp-ai-image {
  background:
    radial-gradient(circle at 80% 15%, rgba(255,255,255,0.25), transparent 40%),
    linear-gradient(155deg, #7b5cf0 0%, #5b8def 55%, #3a5dd1 100%);
}
.mp-ai-illu-image > i.fa-paintbrush {
  background: linear-gradient(180deg, #ff9bd2, #ff5d8f 55%, #c247ff);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  color: transparent;
  filter: drop-shadow(0 6px 12px rgba(0,0,0,0.25));
}
.mp-spark {
  display: none;
}
.mp-spark-1 { top: 14%; right: 14%; font-size: 1rem; }
.mp-spark-2 { bottom: 18%; left: 12%; font-size: 0.75rem; animation-delay: 0.6s; }
@keyframes twinkle {
  0%,100% { opacity: 0.5; transform: scale(0.9); }
  50% { opacity: 1; transform: scale(1.15); }
}

/* Face Swap - orange */
.mp-ai-face {
  background:
    radial-gradient(circle at 80% 15%, rgba(255,255,255,0.25), transparent 40%),
    linear-gradient(160deg, #ffb14a 0%, #ff8a3d 55%, #f56a2c 100%);
}
.mp-ai-illu-face > i.fa-face-laugh-squint {
  color: #ffe34a;
  font-size: 3rem;
  filter: drop-shadow(0 6px 10px rgba(0,0,0,0.2));
}
.mp-bubble {
  position: absolute;
  top: 10%;
  right: 6%;
  color: #ffffff;
  font-size: 1.4rem;
  filter: drop-shadow(0 4px 8px rgba(0,0,0,0.18));
  transform: scaleX(-1);
}

/* Bill Generator - green & white POS theme */
.mp-ai-bill {
  background:
    radial-gradient(circle at 80% 15%, rgba(255,255,255,0.28), transparent 40%),
    linear-gradient(160deg, #34d399 0%, #10b981 55%, #047857 100%);
}
.mp-ai-illu-bill > i.fa-receipt {
  color: #ffffff;
  font-size: 2.9rem;
  filter: drop-shadow(0 6px 12px rgba(0,0,0,0.22));
}
.mp-bill-rupee {
  position: absolute;
  top: 12%;
  right: 10%;
  color: #fde68a;
  font-size: 1.35rem;
  filter: drop-shadow(0 4px 8px rgba(0,0,0,0.2));
  animation: twinkle 2.4s ease-in-out infinite;
}

/* Prompt Hub - dark navy w/ neon brain */
.mp-ai-brain {
  background:
    radial-gradient(circle at 70% 30%, rgba(180, 80, 220, 0.35), transparent 55%),
    linear-gradient(160deg, #181a4a 0%, #2a1d63 55%, #1c1740 100%);
}
.mp-ai-illu-brain > i.fa-brain {
  color: #ff5dd6;
  font-size: 2.8rem;
  text-shadow:
    0 0 8px rgba(255, 93, 214, 0.85),
    0 0 24px rgba(180, 80, 220, 0.65),
    0 0 40px rgba(120, 60, 220, 0.4);
  animation: neonPulse 2.4s ease-in-out infinite;
}
@keyframes neonPulse {
  0%,100% { filter: brightness(1); }
  50% { filter: brightness(1.25); }
}

/* ---------- YT Analytics card (replaces Prompt Lab) ---------- */
.mp-ai-yt {
  background:
    radial-gradient(circle at 70% 30%, rgba(255, 70, 70, 0.38), transparent 55%),
    linear-gradient(160deg, #2a0d0d 0%, #5a1414 55%, #2c0a0a 100%);
}
.mp-ai-illu-yt > i.fa-youtube {
  color: #ff3b3b;
  font-size: 2.9rem;
  text-shadow:
    0 0 8px rgba(255, 59, 59, 0.9),
    0 0 24px rgba(255, 40, 40, 0.65),
    0 0 40px rgba(220, 30, 30, 0.45);
  animation: neonPulse 2.4s ease-in-out infinite;
}

/* ---------- Mode Switcher Pills ---------- */
.switcher {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 10px;
  margin: 22px 0 4px;
}

.switch-pill {
  border: 1px solid #eceef5;
  min-height: 46px;
  border-radius: 14px;
  background: #ffffff;
  color: #3e4a66;
  font-weight: 700;
  font-size: 0.92rem;
  box-shadow: var(--shadow-xs);
  transition: transform 0.18s ease, box-shadow 0.18s ease, background 0.18s ease, color 0.18s ease;
}
.switch-pill:hover { transform: translateY(-1px); }
.switch-pill.is-active {
  background: linear-gradient(135deg, #7b5cf0, #5b8def);
  color: #ffffff;
  border-color: transparent;
  box-shadow: 0 10px 22px rgba(91, 141, 239, 0.32);
}

/* ---------- Featured Content carousel ---------- */
.mp-featured-track {
  position: relative;
  display: flex;
  gap: 12px;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  padding: 2px 2px 8px;
  scrollbar-width: none;
}
.mp-featured-track::-webkit-scrollbar { display: none; }

.mp-feat-card {
  position: relative;
  flex: 0 0 64%;
  max-width: 64%;
  aspect-ratio: 1 / 1;
  border-radius: 22px;
  overflow: hidden;
  scroll-snap-align: start;
  box-shadow: var(--shadow-md);
  color: #ffffff;
  isolation: isolate;
  background-size: cover;
  background-position: center;
}
.mp-feat-card::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(0,0,0,0) 40%, rgba(0,0,0,0.55) 100%);
  pointer-events: none;
}
.mp-feat-card.has-image::after {
  background: linear-gradient(180deg, rgba(0,0,0,0) 30%, rgba(0,0,0,0.75) 100%);
}
.mp-feat-card.has-image h3 {
  text-shadow: 0 2px 10px rgba(0, 0, 0, 0.55);
}
.mp-feat-card-inner {
  position: absolute;
  left: 14px;
  right: 14px;
  bottom: 14px;
  z-index: 1;
}
.mp-feat-badge {
  display: inline-block;
  padding: 4px 10px;
  font-size: 0.7rem;
  font-weight: 700;
  border-radius: 999px;
  background: rgba(255,255,255,0.2);
  border: 1px solid rgba(255,255,255,0.3);
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
  margin-bottom: 8px;
}
.mp-feat-card h3 {
  margin: 0;
  font-size: 1.02rem;
  line-height: 1.25;
  font-weight: 800;
  letter-spacing: -0.01em;
}

/* Themed gradient backgrounds (fallback when no image) */
.feat-theme-blue   { background: linear-gradient(135deg, #1f3a8a 0%, #4b7df3 55%, #93c4ff 100%); }
.feat-theme-violet { background: linear-gradient(135deg, #4b1d7a 0%, #7c3aed 55%, #f0a4d6 100%); }
.feat-theme-sunset { background: linear-gradient(135deg, #3a1b2a 0%, #8a3a2a 55%, #ffaa66 100%); }
.feat-theme-cyber  { background: linear-gradient(135deg, #0c1b2c 0%, #1b3d6e 55%, #6ad1ff 100%); }
.feat-theme-fire   { background: linear-gradient(135deg, #5a1a1a 0%, #c2410c 55%, #ffd166 100%); }

.banner-dots {
  display: flex;
  justify-content: center;
  gap: 6px;
  padding: 4px 0 0;
}
.dot {
  width: 7px;
  height: 7px;
  border: 0;
  border-radius: 999px;
  background: #d6dae5;
  transition: width 0.2s ease, background 0.2s ease;
}
.dot.is-active { width: 22px; background: var(--primary); }

/* ---------- Category Menu Strip ---------- */
.menu-strip {
  display: flex;
  gap: 22px;
  overflow-x: auto;
  padding: 18px 0 6px;
  scrollbar-width: none;
}
.menu-strip::-webkit-scrollbar { display: none; }

.menu-chip {
  border: 0;
  background: transparent;
  color: #5a6479;
  padding: 6px 0 10px;
  white-space: nowrap;
  font-weight: 600;
  font-size: 0.92rem;
  position: relative;
}
.menu-chip::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: 0;
  width: 100%;
  height: 3px;
  border-radius: 999px;
  transform: scaleX(0);
  transform-origin: center;
  transition: transform 0.2s ease;
  background: linear-gradient(90deg, #7b5cf0, #5b8def);
}
.menu-chip.is-selected { color: #131826; font-weight: 800; }
.menu-chip.is-selected::after { transform: scaleX(1); }

/* ---------- TOOLS grid (NEW TOOLS style: 3 per row, colorful icon cards) ---------- */
.mp-tools-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 12px;
}

.card-item {
  position: relative;
  aspect-ratio: 1 / 1.05;
  border-radius: 22px;
  overflow: hidden;
  padding: 14px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  color: #ffffff;
  box-shadow: var(--shadow-md);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
  isolation: isolate;
  text-decoration: none;
}
.card-item:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-lg);
}
.card-item::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(255,255,255,0.18), rgba(0,0,0,0.05) 70%, rgba(0,0,0,0.18));
  pointer-events: none;
  z-index: 0;
}

.card-illustration {
  position: relative;
  flex: 1;
  display: grid;
  place-items: center;
  z-index: 1;
}
.card-illustration > i:first-child {
  position: relative;
  z-index: 1;
  font-size: 2.6rem;
  color: #ffffff;
  filter: drop-shadow(0 6px 14px rgba(0,0,0,0.25));
}
.card-illustration .sp {
  display: none;
}
.card-illustration .sp-a { top: 14%; right: 14%; font-size: 1rem; }
.card-illustration .sp-b { bottom: 18%; left: 12%; font-size: 0.75rem; animation-delay: 0.6s; }

.card-title {
  position: relative;
  z-index: 1;
  font-size: 0.92rem;
  font-weight: 700;
  letter-spacing: -0.01em;
  text-shadow: 0 2px 6px rgba(0,0,0,0.22);
  color: #ffffff;
  line-height: 1.2;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

/* ---------- Per-category illustration gradients ---------- */
.illu-ai       { background: radial-gradient(circle at 75% 22%, rgba(255,255,255,0.28), transparent 45%), linear-gradient(150deg, #4f8bff 0%, #5468ff 55%, #2640c8 100%); }
.illu-face     { background: radial-gradient(circle at 75% 22%, rgba(255,255,255,0.28), transparent 45%), linear-gradient(150deg, #ffb14a 0%, #ff8a3d 55%, #f56a2c 100%); }
.illu-video    { background: radial-gradient(circle at 75% 22%, rgba(255,255,255,0.28), transparent 45%), linear-gradient(150deg, #1f1147 0%, #4b1d7a 55%, #b14fd6 100%); }
.illu-art      { background: radial-gradient(circle at 75% 22%, rgba(255,255,255,0.28), transparent 45%), linear-gradient(150deg, #ff5d8f 0%, #c247ff 55%, #6d3bf0 100%); }
.illu-text     { background: radial-gradient(circle at 75% 22%, rgba(255,255,255,0.28), transparent 45%), linear-gradient(150deg, #3a5dd1 0%, #5b8def 55%, #7aa9d8 100%); }
.illu-light    { background: radial-gradient(circle at 75% 22%, rgba(255,255,255,0.32), transparent 45%), linear-gradient(150deg, #f5c518 0%, #ff9f1c 55%, #ff4d6d 100%); }
.illu-qr       { background: radial-gradient(circle at 75% 22%, rgba(255,255,255,0.24), transparent 45%), linear-gradient(150deg, #2c3e50 0%, #3a4f6b 55%, #1a2236 100%); }
.illu-math     { background: radial-gradient(circle at 75% 22%, rgba(255,255,255,0.28), transparent 45%), linear-gradient(150deg, #ff8a3d 0%, #ffb14a 55%, #ffd166 100%); }
.illu-bmi      { background: radial-gradient(circle at 75% 22%, rgba(255,255,255,0.28), transparent 45%), linear-gradient(150deg, #ff7a8a 0%, #ff5a73 55%, #d6336c 100%); }
.illu-dice     { background: radial-gradient(circle at 75% 22%, rgba(255,255,255,0.28), transparent 45%), linear-gradient(150deg, #ffb800 0%, #ff8a3d 55%, #e94e1b 100%); }
.illu-color    { background: radial-gradient(circle at 75% 22%, rgba(255,255,255,0.28), transparent 45%), linear-gradient(150deg, #ff5dd6 0%, #c247ff 55%, #5b8def 100%); }
.illu-gradient { background: linear-gradient(150deg, #ff5dd6 0%, #ffb14a 30%, #6dd5ed 70%, #5b8def 100%); }
.illu-contrast { background: linear-gradient(150deg, #131826 0%, #131826 49%, #ffffff 51%, #ffffff 100%); }
.illu-convert  { background: radial-gradient(circle at 75% 22%, rgba(255,255,255,0.28), transparent 45%), linear-gradient(150deg, #0f8b6d 0%, #25c2a0 55%, #6fd8c2 100%); }
.illu-code     { background: radial-gradient(circle at 75% 22%, rgba(255,255,255,0.28), transparent 45%), linear-gradient(150deg, #1c1740 0%, #3b2080 55%, #5b3dd6 100%); }
.illu-link     { background: radial-gradient(circle at 75% 22%, rgba(255,255,255,0.28), transparent 45%), linear-gradient(150deg, #0066ff 0%, #00b4d8 55%, #48cae4 100%); }
.illu-table    { background: radial-gradient(circle at 75% 22%, rgba(255,255,255,0.28), transparent 45%), linear-gradient(150deg, #1665d8 0%, #4b8af0 55%, #9ec5ff 100%); }
.illu-lock     { background: radial-gradient(circle at 75% 22%, rgba(255,255,255,0.28), transparent 45%), linear-gradient(150deg, #1a2236 0%, #2a3a5f 55%, #4b6182 100%); }
.illu-shield   { background: radial-gradient(circle at 75% 22%, rgba(255,255,255,0.28), transparent 45%), linear-gradient(150deg, #0a8754 0%, #16a34a 55%, #4ade80 100%); }
.illu-tag      { background: radial-gradient(circle at 75% 22%, rgba(255,255,255,0.28), transparent 45%), linear-gradient(150deg, #ff8a3d 0%, #ffb14a 55%, #ffd166 100%); }
.illu-regex    { background: radial-gradient(circle at 75% 22%, rgba(255,255,255,0.28), transparent 45%), linear-gradient(150deg, #42516d 0%, #6b7a99 55%, #a4b1cc 100%); }
.illu-clock    { background: radial-gradient(circle at 75% 22%, rgba(255,255,255,0.28), transparent 45%), linear-gradient(150deg, #c0392b 0%, #e94e1b 55%, #ff8a3d 100%); }
.illu-globe    { background: radial-gradient(circle at 75% 22%, rgba(255,255,255,0.28), transparent 45%), linear-gradient(150deg, #015c92 0%, #2d82b5 55%, #88c5e4 100%); }
.illu-cake     { background: radial-gradient(circle at 75% 22%, rgba(255,255,255,0.28), transparent 45%), linear-gradient(150deg, #ff5dd6 0%, #ffb14a 55%, #ffd166 100%); }
.illu-coin     { background: radial-gradient(circle at 75% 22%, rgba(255,255,255,0.32), transparent 45%), linear-gradient(150deg, #c79100 0%, #ffd166 55%, #fff0a3 100%); }
.illu-notes    { background: radial-gradient(circle at 75% 22%, rgba(255,255,255,0.28), transparent 45%), linear-gradient(150deg, #f59f00 0%, #ffd166 55%, #fff3bf 100%); }
.illu-id       { background: radial-gradient(circle at 75% 22%, rgba(255,255,255,0.28), transparent 45%), linear-gradient(150deg, #5a6275 0%, #8893a8 55%, #c6cdd9 100%); }
.illu-image    { background: radial-gradient(circle at 75% 22%, rgba(255,255,255,0.28), transparent 45%), linear-gradient(150deg, #6d28d9 0%, #a855f7 55%, #f0abfc 100%); }
.illu-diff     { background: radial-gradient(circle at 75% 22%, rgba(255,255,255,0.28), transparent 45%), linear-gradient(150deg, #1e40af 0%, #3b82f6 55%, #93c5fd 100%); }
.illu-default  { background: radial-gradient(circle at 75% 22%, rgba(255,255,255,0.28), transparent 45%), linear-gradient(150deg, #6c5ce7 0%, #5b8def 55%, #7aa9d8 100%); }
.illu-grocery  { background: radial-gradient(circle at 75% 22%, rgba(255,255,255,0.30), transparent 45%), linear-gradient(150deg, #16a34a 0%, #22c55e 45%, #f59e0b 100%); }

/* Themes */
.theme-text       { background: linear-gradient(135deg, #eef3ff, #d9e6ff); color: #3459d1; }
.theme-math       { background: linear-gradient(135deg, #fff2df, #ffe0b3); color: #c26a00; }
.theme-color      { background: linear-gradient(135deg, #f6ebff, #ebdcff); color: #8a3ffc; }
.theme-converter  { background: linear-gradient(135deg, #e7fbf6, #d2f5ea); color: #0f8b6d; }
.theme-security   { background: linear-gradient(135deg, #e9f3ff, #d4e7ff); color: #1665d8; }
.theme-web        { background: linear-gradient(135deg, #eef1f7, #dfe6f2); color: #42516d; }
.theme-time       { background: linear-gradient(135deg, #fff0ef, #ffe0db); color: #d05a42; }
.theme-misc       { background: linear-gradient(135deg, #f3f4f8, #e5e8f0); color: #5a6275; }
.theme-prompt     { background: linear-gradient(135deg, #f6ecff, #ead9ff); color: #6f36d9; }
.theme-ai         { background: linear-gradient(135deg, #e6f6ff, #d5efff); color: #1472b9; }
.theme-growth     { background: linear-gradient(135deg, #fff2e9, #ffe4ce); color: #c66a1a; }
.theme-study      { background: linear-gradient(135deg, #edf8e8, #ddf1d1); color: #357a38; }

.empty-state {
  margin: 14px 0 0;
  padding: 16px 18px;
  border-radius: 14px;
  background: #f5f6fb;
  border: 1px dashed #d1d6e3;
  color: #5b6677;
  font-size: 0.9rem;
}

.mp-tool-sections {
  display: grid;
  gap: 18px;
}

.mp-tool-category {
  background: linear-gradient(180deg, rgba(255,255,255,0.96), rgba(245,247,252,0.96));
  border: 1px solid #edf0f7;
  border-radius: 24px;
  padding: 16px;
  box-shadow: var(--shadow-sm);
}

.mp-tool-category-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 14px;
}

.mp-tool-category-meta {
  display: flex;
  align-items: flex-start;
  gap: 12px;
}

.mp-tool-category-icon {
  width: 44px;
  height: 44px;
  border-radius: 14px;
  display: grid;
  place-items: center;
  color: #ffffff;
  background: linear-gradient(135deg, #7b5cf0 0%, #5b8def 100%);
  box-shadow: 0 10px 22px rgba(91, 141, 239, 0.22);
  flex-shrink: 0;
}

.mp-tool-category-icon i {
  font-size: 1.05rem;
}

.mp-tool-category h3 {
  margin: 0;
  font-size: 1rem;
  color: #131826;
  letter-spacing: -0.02em;
}

.mp-tool-category p {
  margin: 5px 0 0;
  color: #657089;
  font-size: 0.85rem;
  line-height: 1.45;
}

.mp-tool-category-count {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 82px;
  padding: 8px 12px;
  border-radius: 999px;
  background: #f2f5fb;
  color: #4a5675;
  font-size: 0.78rem;
  font-weight: 800;
  white-space: nowrap;
}

body[data-page="all-tools"] .mp-tool-category {
  padding: 18px;
}

@media (max-width: 640px) {
  .mp-tool-category-head {
    flex-direction: column;
  }

  .mp-tool-category-count {
    align-self: flex-start;
  }
}


/* ---------- Toast ---------- */
.copy-toast {
  position: fixed;
  left: 50%;
  bottom: 110px;
  transform: translateX(-50%) translateY(16px);
  background: rgba(20, 24, 38, 0.95);
  color: #fff;
  padding: 10px 18px;
  border-radius: 999px;
  font-size: 0.9rem;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.2s ease, transform 0.2s ease;
  z-index: 200;
}
.copy-toast.show { opacity: 1; transform: translateX(-50%) translateY(0); }

/* ---------- Bottom Fixed Navigation ---------- */
.mp-bottom-nav {
  position: fixed;
  left: 50%;
  bottom: 0;
  transform: translateX(-50%);
  width: 100%;
  max-width: 620px;
  background: #ffffff;
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  align-items: center;
  padding: 10px 8px 14px;
  box-shadow: 0 -8px 30px rgba(20, 25, 50, 0.08);
  z-index: 100;
  border-top: 1px solid #f0f2f7;
}

.mp-bn-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 4px;
  color: #8a93a8;
  font-size: 0.74rem;
  font-weight: 600;
  padding: 6px 4px;
  border-radius: 12px;
  transition: color 0.2s ease;
}
.mp-bn-item i { font-size: 1.15rem; }
.mp-bn-item.is-active { color: var(--primary); }
.mp-bn-item:hover { color: var(--primary); }

.mp-bn-fab {
  width: 56px;
  height: 56px;
  border-radius: 50%;
  background: linear-gradient(135deg, #7b5cf0 0%, #5b3dd6 100%);
  color: #ffffff;
  display: grid;
  place-items: center;
  font-size: 1.25rem;
  margin: -22px auto 0;
  box-shadow: 0 12px 24px rgba(91, 61, 214, 0.4), 0 0 0 6px #ffffff;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
  justify-self: center;
}
.mp-bn-fab:hover { transform: translateY(-2px); box-shadow: 0 14px 28px rgba(91, 61, 214, 0.5), 0 0 0 6px #ffffff; }

/* ---------- Footer (clean text-based, no box/border) ---------- */
.mp-global-footer {
  margin-top: 40px;
  padding: 28px 18px 26px;
  text-align: center;
  background: transparent;
  border: 0;
}
.mp-footer-inner {
  padding: 0;
  border-radius: 0;
  background: transparent;
  border: 0;
  box-shadow: none;
  text-align: center;
  backdrop-filter: none;
  -webkit-backdrop-filter: none;
}
.mp-footer-brand {
  display: inline-block;
  font-size: 1.15rem;
  font-weight: 800;
  letter-spacing: -0.02em;
  margin-bottom: 14px;
  color: #131826;
  background: linear-gradient(135deg, #7b5cf0, #5b8def);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
}
.mp-footer-links {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 26px;
  justify-content: center;
  margin: 8px 0 16px;
  padding: 0;
  list-style: none;
}
.mp-footer-links a {
  font-size: 0.88rem;
  font-weight: 600;
  color: #4a5675;
  position: relative;
  padding-bottom: 2px;
  transition: color 0.2s ease;
}
.mp-footer-links a::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  height: 2px;
  background: linear-gradient(90deg, #7b5cf0, #5b8def);
  transform: scaleX(0);
  transform-origin: center;
  transition: transform 0.25s ease;
  border-radius: 2px;
}
.mp-footer-links a:hover { color: var(--primary); }
.mp-footer-links a:hover::after { transform: scaleX(1); }
.mp-footer-copy {
  margin: 0;
  font-size: 0.8rem;
  color: var(--muted);
  letter-spacing: 0.01em;
}

/* ---------- Responsive ---------- */
@media (max-width: 420px) {
  .mp-search input { font-size: 0.85rem; }
  .mp-search-action { min-width: 44px; }
  .mp-search-action span { font-size: 0.6rem; }
  .mp-ai-title { font-size: 0.85rem; }
  .card-title { font-size: 0.78rem; }
  .card-illustration > i:first-child { font-size: 2.1rem; }
  .mp-feat-card { flex: 0 0 70%; max-width: 70%; }
  .prompt-card {
    grid-template-columns: 1fr;
    text-align: center;
  }
  .prompt-card img {
    width: 100%;
    height: auto;
    aspect-ratio: 16 / 10;
  }
}

@media (min-width: 768px) {
  .mp-tools-grid { grid-template-columns: repeat(4, 1fr); }
  .mp-feat-card { flex: 0 0 42%; max-width: 42%; }
  .mp-image-prompt-grid { grid-template-columns: repeat(2, 1fr); }
}

@media (min-width: 1024px) {
  .mp-tools-grid { grid-template-columns: repeat(5, 1fr); }
  .mp-feat-card { flex: 0 0 32%; max-width: 32%; }
}

/* Hide scrollbars cleanly */
::-webkit-scrollbar { width: 8px; height: 8px; }
::-webkit-scrollbar-thumb { background: #d6dae5; border-radius: 999px; }
::-webkit-scrollbar-track { background: transparent; }

/* ---------- Pagination ---------- */
.mp-pagination {
  display: flex;
  justify-content: center;
  align-items: center;
  flex-wrap: wrap;
  gap: 6px;
  margin: 22px 0 10px;
}
.mp-pagination .pg-btn {
  min-width: 36px;
  height: 36px;
  padding: 0 10px;
  border-radius: 10px;
  border: 1px solid #e2e6f1;
  background: #ffffff;
  color: #3e4a66;
  font-weight: 700;
  font-size: 0.85rem;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  transition: transform 0.15s ease, box-shadow 0.15s ease, background 0.15s ease, color 0.15s ease;
  box-shadow: var(--shadow-xs);
}
.mp-pagination .pg-btn:hover:not([disabled]) {
  transform: translateY(-1px);
  border-color: #c9d0e3;
}
.mp-pagination .pg-btn.is-active {
  background: linear-gradient(135deg, #7b5cf0, #5b8def);
  color: #ffffff;
  border-color: transparent;
  box-shadow: 0 6px 14px rgba(91, 141, 239, 0.32);
}
.mp-pagination .pg-btn[disabled] {
  opacity: 0.45;
  cursor: not-allowed;
}
.mp-pagination .pg-nav {
  font-size: 0.8rem;
}
.mp-pagination .pg-ellipsis {
  color: #8a93a8;
  padding: 0 4px;
  font-weight: 700;
}

/* Hide leftover legacy elements if any HTML still references them */
.switcher,
.menu-strip { display: none !important; }

/* ---------- Links + show more button ---------- */
.mp-chevron {
  text-decoration: none;
}

.mp-show-more-wrap {
  margin-top: 22px;
  display: flex;
  justify-content: center;
}

.mp-show-more {
  width: 100%;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  padding: 15px 18px;
  border-radius: 18px;
  background: linear-gradient(135deg, #7b5cf0 0%, #5b8def 100%);
  color: #ffffff;
  font-weight: 800;
  letter-spacing: 0.01em;
  box-shadow: 0 14px 30px rgba(91, 141, 239, 0.28);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.mp-show-more:hover {
  transform: translateY(-2px);
  box-shadow: 0 18px 34px rgba(91, 141, 239, 0.34);
}

.mp-show-more i {
  font-size: 0.95rem;
  animation: showMoreFloat 1.6s ease-in-out infinite;
}

@keyframes showMoreFloat {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(3px); }
}

/* ---------- Image Prompt Grid (Tools-style) ---------- */
.mp-image-prompt-section { margin-top: 26px; }

.mp-prompt-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 14px;
}

.prompt-tile {
  position: relative;
  display: flex;
  flex-direction: column;
  border-radius: 20px;
  background: #ffffff;
  border: 1px solid #eef0f6;
  box-shadow: var(--shadow-xs);
  overflow: hidden;
  transition: transform 0.22s ease, box-shadow 0.22s ease, border-color 0.22s ease;
  text-align: left;
  color: inherit;
}
.prompt-tile:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-md);
  border-color: #e2e6f1;
}

.prompt-tile-media {
  position: relative;
  width: 100%;
  aspect-ratio: 4 / 5;
  overflow: hidden;
  background: #eef1f8;
  border-radius: inherit;
}
.prompt-tile-media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: transform 0.4s ease;
}
.prompt-tile:hover .prompt-tile-media img { transform: scale(1.06); }

.prompt-tile-badge {
  position: absolute;
  top: 8px;
  left: 8px;
  padding: 4px 10px;
  background: rgba(20, 24, 38, 0.72);
  color: #fff;
  font-size: 0.66rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  border-radius: 999px;
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
}

/* Title removed from image prompt cards — only the image is shown. */
.prompt-tile-body { display: none; }

/* Show more (prompt) shares the same style as tools button via .mp-show-more */
.mp-show-more-prompt {
  background: linear-gradient(135deg, #ff5dd6 0%, #7b5cf0 100%) !important;
  box-shadow: 0 14px 30px rgba(123, 92, 240, 0.28) !important;
}
.mp-show-more-prompt:hover {
  box-shadow: 0 18px 34px rgba(123, 92, 240, 0.34) !important;
}

/* ---------- Image Prompt Detail Page ---------- */
.mp-prompt-detail-page { padding: 4px 18px 30px; }

.mp-back-bar {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 0 6px;
}
.mp-back-btn {
  width: 40px; height: 40px;
  border-radius: 12px;
  border: 1px solid #e7eaf3;
  background: #fff;
  display: grid; place-items: center;
  color: #1a2236;
  font-size: 1rem;
  box-shadow: var(--shadow-xs);
}
.mp-back-btn:hover { background: #f5f6fb; }
.mp-back-bar h2 {
  margin: 0;
  font-size: 1.05rem;
  font-weight: 800;
  color: #131826;
}

.mp-detail-hero {
  border-radius: 24px;
  overflow: hidden;
  background: #eef1f8;
  box-shadow: var(--shadow-md);
  margin: 8px 0 16px;
  position: relative;
}
.mp-detail-hero img {
  width: 100%;
  display: block;
  aspect-ratio: 4 / 5;
  object-fit: cover;
  max-height: 560px;
}
.mp-detail-badge {
  position: absolute;
  top: 14px;
  left: 14px;
  padding: 6px 12px;
  border-radius: 999px;
  background: rgba(20, 24, 38, 0.72);
  color: #fff;
  font-size: 0.72rem;
  font-weight: 700;
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
}

.mp-detail-title {
  margin: 4px 0 10px;
  font-size: 1.35rem;
  font-weight: 800;
  color: #131826;
  letter-spacing: -0.01em;
}

.mp-detail-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 16px;
}
.mp-detail-tags span {
  padding: 6px 12px;
  border-radius: 999px;
  background: #eef3ff;
  color: #3852a6;
  font-size: 0.76rem;
  font-weight: 700;
}

.mp-prompt-box {
  border-radius: 18px;
  background: #101828;
  color: #f8fafc;
  padding: 16px 16px 14px;
  box-shadow: 0 14px 30px rgba(16, 24, 40, 0.18);
  position: relative;
}
.mp-prompt-box-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 10px;
}
.mp-prompt-box-head span {
  color: #a5b4fc;
  font-size: 0.74rem;
  font-weight: 800;
  letter-spacing: 0.05em;
  text-transform: uppercase;
}
.mp-prompt-copy-btn {
  border: 0;
  background: linear-gradient(135deg, #7b5cf0, #5b8def);
  color: #fff;
  font-weight: 700;
  font-size: 0.78rem;
  padding: 8px 14px;
  border-radius: 999px;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  cursor: pointer;
  transition: transform 0.15s ease, box-shadow 0.15s ease;
}
.mp-prompt-copy-btn:hover { transform: translateY(-1px); box-shadow: 0 8px 18px rgba(91,141,239,0.4); }
.mp-prompt-copy-btn.is-copied { background: linear-gradient(135deg, #10b981, #059669); }

.mp-prompt-text {
  margin: 0;
  line-height: 1.7;
  font-size: 0.93rem;
  white-space: pre-wrap;
  word-break: break-word;
}

.mp-detail-actions {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 10px;
  margin: 18px 0 22px;
}
.mp-action-btn {
  border: 1px solid #e7eaf3;
  background: #fff;
  border-radius: 16px;
  padding: 12px 6px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
  color: #1a2236;
  font-size: 0.74rem;
  font-weight: 700;
  cursor: pointer;
  transition: transform 0.15s ease, box-shadow 0.15s ease, background 0.15s ease;
}
.mp-action-btn i { font-size: 1.1rem; color: var(--primary); }
.mp-action-btn:hover {
  transform: translateY(-2px);
  background: #f7f7fc;
  box-shadow: var(--shadow-xs);
}

.mp-detail-section {
  margin-top: 18px;
}
.mp-detail-section h3 {
  margin: 0 0 10px;
  font-size: 0.95rem;
  font-weight: 800;
  color: #131826;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.mp-related-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 10px;
}
.mp-related-grid a {
  display: block;
  aspect-ratio: 1 / 1;
  border-radius: 14px;
  overflow: hidden;
  background: #eef1f8;
  border: 1px solid #eef0f6;
}
.mp-related-grid img {
  width: 100%; height: 100%;
  object-fit: cover;
  display: block;
  transition: transform 0.3s ease;
}
.mp-related-grid a:hover img { transform: scale(1.08); }

@media (min-width: 480px) {
  .mp-prompt-grid { grid-template-columns: repeat(3, 1fr); }
}
@media (min-width: 768px) {
  .mp-prompt-grid { grid-template-columns: repeat(4, 1fr); }
  .mp-related-grid { grid-template-columns: repeat(4, 1fr); }
}
@media (min-width: 1024px) {
  .mp-prompt-grid { grid-template-columns: repeat(5, 1fr); }
}


/* ---------- Slide menu ---------- */
.mp-side-overlay {
  position: fixed;
  inset: 0;
  background: rgba(15, 23, 42, 0.42);
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.22s ease;
  z-index: 80;
}
.mp-side-overlay.open {
  opacity: 1;
  pointer-events: auto;
}
.mp-side-menu {
  position: fixed;
  top: 0;
  left: 0;
  width: min(82vw, 320px);
  height: 100vh;
  background: #ffffff;
  box-shadow: 18px 0 50px rgba(15, 23, 42, 0.16);
  transform: translateX(-105%);
  transition: transform 0.24s ease;
  z-index: 90;
  padding: 20px 16px 28px;
}
.mp-side-menu.open { transform: translateX(0); }
.mp-side-menu-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding-bottom: 14px;
  border-bottom: 1px solid var(--line);
  margin-bottom: 14px;
}
.mp-side-menu-head strong {
  font-size: 1.1rem;
  font-weight: 800;
  color: #111827;
}
.mp-side-menu-links {
  display: flex;
  flex-direction: column;
  gap: 8px;
}
.mp-side-menu-links a {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 14px;
  border-radius: 14px;
  color: #1f2937;
  font-weight: 700;
  background: #f8fafc;
  border: 1px solid transparent;
}
.mp-side-menu-links a:hover {
  background: #eef2ff;
  color: var(--primary);
  border-color: rgba(108, 92, 231, 0.15);
}
.mp-side-menu-links i {
  width: 18px;
  text-align: center;
  color: var(--primary);
}
body.mp-menu-open { overflow: hidden; }

/* ---------- Shared desktop polish ---------- */
body {
  background:
    radial-gradient(circle at top left, rgba(123, 92, 240, 0.08), transparent 26%),
    radial-gradient(circle at top right, rgba(91, 141, 239, 0.08), transparent 24%),
    var(--bg);
}

.mp-appbar-left {
  display: flex;
  align-items: center;
  gap: 12px;
}

.mp-desktop-nav {
  display: none;
  align-items: center;
  gap: 10px;
}

.mp-desktop-link {
  padding: 10px 14px;
  border-radius: 12px;
  color: #4a5675;
  font-weight: 700;
  transition: background 0.2s ease, color 0.2s ease, transform 0.2s ease;
}

.mp-desktop-link:hover,
.mp-desktop-link.is-active {
  background: #f2f5fb;
  color: var(--primary);
}

.mp-feat-link {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin-top: 12px;
  font-size: 0.8rem;
  font-weight: 800;
  letter-spacing: 0.01em;
  color: #ffffff;
  text-shadow: 0 2px 8px rgba(0, 0, 0, 0.35);
}

/* ---------- Featured post pages ---------- */
body[data-page="featured-post"] .mp-main,
body[data-page="featured-posts"] .mp-main {
  padding-top: 18px;
}

.mp-post-chip {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 6px 12px;
  border-radius: 999px;
  background: rgba(108, 92, 231, 0.12);
  color: var(--primary-deep);
  font-size: 0.76rem;
  font-weight: 800;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.mp-posts-hero-card {
  padding: 24px;
  border-radius: 28px;
  background: linear-gradient(135deg, #161b33 0%, #4b39c7 48%, #5b8def 100%);
  color: #ffffff;
  box-shadow: var(--shadow-lg);
}

.mp-posts-hero-card h1 {
  margin: 14px 0 10px;
  font-size: clamp(1.8rem, 4vw, 3rem);
  line-height: 1.05;
  letter-spacing: -0.04em;
}

.mp-posts-hero-card p {
  margin: 0;
  max-width: 70ch;
  color: rgba(255, 255, 255, 0.88);
  line-height: 1.7;
}

.mp-post-grid {
  display: grid;
  gap: 18px;
}

.mp-post-card {
  display: flex;
  flex-direction: column;
  border-radius: 24px;
  overflow: hidden;
  background: #ffffff;
  border: 1px solid #edf0f7;
  box-shadow: var(--shadow-sm);
}

.mp-post-card-media {
  position: relative;
  aspect-ratio: 16 / 10;
  overflow: hidden;
  background: #eef1f8;
}

.mp-post-card-media img,
.mp-related-card img,
.mp-post-hero-image {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.mp-post-card-media img,
.mp-related-card img {
  transition: transform 0.35s ease;
}

.mp-post-card:hover .mp-post-card-media img,
.mp-related-card:hover img {
  transform: scale(1.05);
}

.mp-post-card-media .mp-post-chip {
  position: absolute;
  top: 14px;
  left: 14px;
  background: rgba(255,255,255,0.92);
}

.mp-post-card-body {
  display: flex;
  flex-direction: column;
  gap: 12px;
  padding: 18px;
}

.mp-post-meta-row {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 14px;
  color: #5d6780;
  font-size: 0.82rem;
  font-weight: 700;
}

.mp-post-meta-row.is-light {
  color: rgba(255, 255, 255, 0.88);
}

.mp-post-card h2 {
  margin: 0;
  font-size: 1.2rem;
  line-height: 1.3;
  letter-spacing: -0.02em;
}

.mp-post-card p,
.mp-post-side-card p {
  margin: 0;
  color: #5f6981;
  line-height: 1.7;
}

.mp-post-card-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  color: #768099;
  font-size: 0.86rem;
  font-weight: 700;
}

.mp-post-link,
.mp-back-inline {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-weight: 800;
  color: var(--primary-deep);
}

.mp-post-hero {
  position: relative;
  min-height: 360px;
  border-radius: 30px;
  overflow: hidden;
  background: #111827;
  box-shadow: var(--shadow-lg);
}

.mp-post-hero-image {
  position: absolute;
  inset: 0;
}

.mp-post-hero-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(7, 10, 25, 0.18), rgba(7, 10, 25, 0.72) 58%, rgba(7, 10, 25, 0.92) 100%);
  z-index: 1;
}

.mp-post-hero-content {
  position: relative;
  z-index: 2;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  min-height: 360px;
  padding: 22px;
  color: #ffffff;
}

.mp-post-hero-content .mp-post-chip {
  align-self: flex-start;
  margin: 16px 0 10px;
  background: rgba(255,255,255,0.92);
}

.mp-post-hero-content h1 {
  margin: 0 0 10px;
  font-size: clamp(2rem, 5vw, 3.2rem);
  line-height: 1.02;
  letter-spacing: -0.05em;
  max-width: 12ch;
}

.mp-post-hero-content p {
  margin: 0 0 18px;
  max-width: 72ch;
  color: rgba(255, 255, 255, 0.9);
  line-height: 1.7;
}

.mp-post-layout {
  display: grid;
  gap: 20px;
  margin-top: 20px;
}

.mp-post-content,
.mp-post-side-card {
  background: #ffffff;
  border: 1px solid #edf0f7;
  border-radius: 24px;
  box-shadow: var(--shadow-sm);
}

.mp-post-content {
  padding: 22px;
}

.mp-post-content h2 {
  margin: 24px 0 10px;
  font-size: 1.28rem;
  color: #131826;
}

.mp-post-content p {
  margin: 0 0 16px;
  color: #4f596f;
  line-height: 1.82;
}

.mp-post-content blockquote {
  margin: 22px 0;
  padding: 18px 20px;
  border-left: 4px solid var(--primary);
  background: #f6f7fd;
  border-radius: 18px;
  color: #28324a;
  font-weight: 600;
}

.mp-post-sidebar {
  display: grid;
  gap: 18px;
  align-self: start;
}

.mp-post-side-card {
  padding: 20px;
}

.mp-post-side-card h3 {
  margin: 0 0 12px;
  font-size: 1rem;
  color: #131826;
}

.mp-related-list {
  display: grid;
  gap: 12px;
}

.mp-related-card {
  display: grid;
  grid-template-columns: 88px minmax(0, 1fr);
  gap: 12px;
  align-items: center;
  border-radius: 18px;
  padding: 8px;
  background: #f8f9fd;
}

.mp-related-card img {
  aspect-ratio: 1 / 1;
  border-radius: 14px;
}

.mp-related-card span {
  display: inline-block;
  margin-bottom: 6px;
  color: var(--primary-deep);
  font-size: 0.74rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.mp-related-card strong {
  display: block;
  color: #1d2435;
  line-height: 1.4;
}

@media (min-width: 768px) {
  .mp-post-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (min-width: 1024px) {
  body {
    padding: 20px;
  }

  .mp-app {
    max-width: 1380px;
    min-height: calc(100vh - 40px);
    border-radius: 32px;
    overflow: hidden;
    box-shadow: 0 28px 70px rgba(17, 24, 39, 0.12);
    padding-bottom: 44px;
  }

  .mp-appbar {
    padding: 20px 30px 16px;
  }

  .mp-search-wrap {
    padding: 16px 30px 6px;
  }

  .search-suggestions {
    left: 30px;
    right: 30px;
  }

  .mp-main {
    padding: 12px 30px 40px;
  }

  .mp-section {
    margin-top: 30px;
  }

  .mp-desktop-nav {
    display: flex;
  }

  #openMenuBtn,
  .mp-side-menu,
  .mp-side-overlay {
    display: none;
  }

  .mp-bottom-nav {
    display: none;
  }

  .mp-ai-grid {
    grid-template-columns: repeat(6, minmax(0, 1fr));
  }

  .mp-tool-sections {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    align-items: start;
  }

  .mp-feat-card {
    flex: 0 0 36%;
    max-width: 36%;
    aspect-ratio: 16 / 10;
    border-radius: 26px;
  }

  .mp-post-layout {
    grid-template-columns: minmax(0, 1.6fr) minmax(300px, 360px);
    align-items: start;
  }

  .mp-post-hero-content {
    min-height: 420px;
    padding: 28px;
  }

  .mp-post-hero {
    min-height: 420px;
  }

  .mp-posts-hero-card {
    padding: 34px 38px;
  }
}

@media (min-width: 1280px) {
  .mp-feat-card {
    flex: 0 0 31%;
    max-width: 31%;
  }

  .mp-post-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}

/* =========================================================
   PRO-LEVEL BLACK FOOTER  (Magic Picker)
   - Overrides legacy .mp-global-footer styles
   - Mobile-first, responsive multi-column layout
   ========================================================= */

.mp-global-footer.mp-footer-pro {
  position: relative;
  margin-top: 56px !important;
  padding: 0 !important;
  background: linear-gradient(180deg, #0a0a14 0%, #07070d 60%, #050509 100%) !important;
  color: #cdd3e1 !important;
  border: 0 !important;
  border-top: 1px solid rgba(124, 92, 240, 0.18) !important;
  overflow: hidden;
  text-align: left !important;
  width: 100%;
  box-shadow: 0 -20px 60px rgba(0, 0, 0, 0.35);
}

/* Subtle radial glow accents */
.mp-footer-pro .mp-footer-glow {
  position: absolute;
  inset: 0;
  pointer-events: none;
  background:
    radial-gradient(600px 240px at 12% 0%, rgba(123, 92, 240, 0.22), transparent 60%),
    radial-gradient(500px 200px at 88% 0%, rgba(91, 141, 239, 0.18), transparent 65%),
    radial-gradient(700px 260px at 50% 100%, rgba(255, 122, 89, 0.10), transparent 70%);
  z-index: 0;
}

.mp-footer-pro .mp-footer-inner {
  position: relative;
  z-index: 1;
  max-width: 1180px;
  margin: 0 auto;
  padding: 44px 22px 22px !important;
  background: transparent !important;
  border: 0 !important;
  border-radius: 0 !important;
  box-shadow: none !important;
  text-align: left !important;
}

/* ---------- TOP GRID ---------- */
.mp-footer-pro .mp-footer-top {
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr 1fr 1fr;
  gap: 36px 28px;
  align-items: start;
}

/* ---------- BRAND COLUMN ---------- */
.mp-footer-pro .mp-footer-brand-col {
  min-width: 0;
}
.mp-footer-pro .mp-footer-brand {
  display: inline-flex !important;
  align-items: center;
  gap: 10px;
  text-decoration: none;
  margin-bottom: 14px !important;
  background: none !important;
  -webkit-text-fill-color: initial !important;
  color: #fff !important;
}
.mp-footer-pro .mp-footer-logo-icon {
  display: inline-grid;
  place-items: center;
  width: 38px;
  height: 38px;
  border-radius: 11px;
  background: linear-gradient(135deg, #7b5cf0, #5b8def);
  color: #fff;
  font-size: 1.05rem;
  box-shadow: 0 8px 22px rgba(123, 92, 240, 0.5), inset 0 0 0 1px rgba(255,255,255,0.08);
}
.mp-footer-pro .mp-footer-logo-text {
  font-size: 1.35rem;
  font-weight: 800;
  letter-spacing: -0.02em;
  color: #ffffff;
  background: none !important;
  -webkit-text-fill-color: #fff !important;
}
.mp-footer-pro .mp-footer-logo-text span {
  background: linear-gradient(135deg, #a48bff, #6bb1ff);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
}
.mp-footer-pro .mp-footer-tagline {
  margin: 6px 0 18px;
  font-size: 0.9rem;
  line-height: 1.6;
  color: #9aa3b8;
  max-width: 320px;
}

/* Social icons */
.mp-footer-pro .mp-footer-socials {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}
.mp-footer-pro .mp-social {
  width: 38px;
  height: 38px;
  border-radius: 10px;
  display: inline-grid;
  place-items: center;
  font-size: 0.95rem;
  color: #d6dbeb !important;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.07);
  transition: transform 0.2s ease, background 0.25s ease, color 0.25s ease, border-color 0.25s ease, box-shadow 0.25s ease;
}
.mp-footer-pro .mp-social:hover {
  transform: translateY(-3px);
  color: #fff !important;
  border-color: transparent;
}
.mp-footer-pro .mp-social-yt:hover    { background: #ff0033; box-shadow: 0 10px 22px rgba(255, 0, 51, 0.45); }
.mp-footer-pro .mp-social-ig:hover    { background: linear-gradient(135deg, #f09433, #e6683c, #dc2743, #cc2366, #bc1888); box-shadow: 0 10px 22px rgba(220, 39, 67, 0.45); }
.mp-footer-pro .mp-social-tw:hover    { background: #111; box-shadow: 0 10px 22px rgba(0, 0, 0, 0.55); }
.mp-footer-pro .mp-social-fb:hover    { background: #1877f2; box-shadow: 0 10px 22px rgba(24, 119, 242, 0.45); }
.mp-footer-pro .mp-social-mail:hover  { background: linear-gradient(135deg, #7b5cf0, #5b8def); box-shadow: 0 10px 22px rgba(123, 92, 240, 0.45); }

/* ---------- LINK COLUMNS ---------- */
.mp-footer-pro .mp-footer-col { min-width: 0; }
.mp-footer-pro .mp-footer-heading {
  margin: 0 0 14px;
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: #ffffff;
  display: flex;
  align-items: center;
  gap: 8px;
  position: relative;
  padding-bottom: 10px;
}
.mp-footer-pro .mp-footer-heading i {
  font-size: 0.75rem;
  color: #a48bff;
  background: rgba(124, 92, 240, 0.12);
  padding: 5px;
  border-radius: 6px;
}
.mp-footer-pro .mp-footer-heading::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: 0;
  width: 28px;
  height: 2px;
  background: linear-gradient(90deg, #7b5cf0, #5b8def);
  border-radius: 2px;
}

.mp-footer-pro .mp-footer-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 8px;
}
.mp-footer-pro .mp-footer-list li { margin: 0; }
.mp-footer-pro .mp-footer-list a {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  font-size: 0.88rem;
  font-weight: 500;
  color: #aab2c5 !important;
  text-decoration: none;
  padding: 4px 0;
  transition: color 0.2s ease, transform 0.2s ease, padding-left 0.25s ease;
  position: relative;
}
.mp-footer-pro .mp-footer-list a i {
  font-size: 0.78rem;
  color: #7b5cf0;
  width: 16px;
  text-align: center;
  transition: color 0.2s ease, transform 0.25s ease;
}
.mp-footer-pro .mp-footer-list a::after { display: none !important; content: none !important; }
.mp-footer-pro .mp-footer-list a:hover {
  color: #ffffff !important;
  padding-left: 6px;
}
.mp-footer-pro .mp-footer-list a:hover i {
  color: #a48bff;
  transform: scale(1.15) rotate(-5deg);
}

/* ---------- DIVIDER ---------- */
.mp-footer-pro .mp-footer-divider {
  height: 1px;
  margin: 36px 0 20px;
  background: linear-gradient(90deg, transparent, rgba(124, 92, 240, 0.35), rgba(91, 141, 239, 0.35), transparent);
  border: 0;
}

/* ---------- BOTTOM BAR ---------- */
.mp-footer-pro .mp-footer-bottom {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 12px 22px;
  text-align: left;
}
.mp-footer-pro .mp-footer-copy {
  margin: 0 !important;
  font-size: 0.82rem !important;
  color: #8a93a8 !important;
  letter-spacing: 0.01em;
}
.mp-footer-pro .mp-footer-copy strong {
  color: #ffffff;
  font-weight: 700;
}
.mp-footer-pro .mp-footer-made {
  margin: 0;
  font-size: 0.82rem;
  color: #8a93a8;
}
.mp-footer-pro .mp-footer-made i {
  color: #ff4d6d;
  animation: mpHeartBeat 1.6s ease-in-out infinite;
  margin: 0 2px;
}
@keyframes mpHeartBeat {
  0%, 100% { transform: scale(1); }
  25%, 75% { transform: scale(1.18); }
}
.mp-footer-pro .mp-footer-mini {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}
.mp-footer-pro .mp-footer-mini a {
  font-size: 0.82rem;
  font-weight: 600;
  color: #aab2c5 !important;
  text-decoration: none;
  transition: color 0.2s ease;
}
.mp-footer-pro .mp-footer-mini a:hover { color: #a48bff !important; }
.mp-footer-pro .mp-footer-mini span { color: #3b4258; font-size: 0.7rem; }

/* ---------- RESPONSIVE ---------- */
@media (max-width: 1024px) {
  .mp-footer-pro .mp-footer-top {
    grid-template-columns: 1fr 1fr 1fr;
    gap: 32px 24px;
  }
  .mp-footer-pro .mp-footer-brand-col { grid-column: 1 / -1; }
}
@media (max-width: 640px) {
  .mp-footer-pro .mp-footer-inner { padding: 36px 18px 18px !important; }
  .mp-footer-pro .mp-footer-top {
    grid-template-columns: 1fr 1fr;
    gap: 28px 20px;
  }
  .mp-footer-pro .mp-footer-brand-col { grid-column: 1 / -1; text-align: left; }
  .mp-footer-pro .mp-footer-tagline { max-width: 100%; }
  .mp-footer-pro .mp-footer-bottom {
    flex-direction: column;
    align-items: flex-start;
    text-align: left;
    gap: 8px;
  }
}
@media (max-width: 400px) {
  .mp-footer-pro .mp-footer-top { grid-template-columns: 1fr; }
  .mp-footer-pro .mp-footer-heading { font-size: 0.74rem; }
  .mp-footer-pro .mp-footer-list a { font-size: 0.85rem; }
}

/* Make sure body / app shell doesn't clip the wide footer */
body { background: #050509; }
.mp-app { background: #ffffff; }
.mp-app > .mp-footer-pro,
.mp-footer-pro {
  max-width: none;
  margin-left: calc(50% - 50vw);
  margin-right: calc(50% - 50vw);
  width: 100vw;
}

/* Extra bottom space so fixed bottom nav doesn't overlap footer content */
.mp-footer-pro { padding-bottom: 110px !important; }
@media (min-width: 900px) {
  .mp-footer-pro { padding-bottom: 24px !important; }
}
