/* ==========================================================================
   MacSeeds — Fiche individuelle d'une app (single-app.php)
   ========================================================================== */

:root{
  --ms-bg: #FAFAF9;
  --ms-ink: #17181A;
  --ms-ink-soft: #55585E;
}

.macseeds-single-app{
  font-family: -apple-system, BlinkMacSystemFont, "SF Pro Text", "Helvetica Neue", Arial, sans-serif;
  color: var(--ms-ink);
  position: relative;
}
.macseeds-single-app h1,
.macseeds-single-app .ms-price{
  font-family: "Bricolage Grotesque", -apple-system, sans-serif;
}

.ms-mesh{
  position: fixed; inset: 0; z-index: -1;
  background:
    radial-gradient(circle at 12% 18%, rgba(27,107,123,0.14), transparent 38%),
    radial-gradient(circle at 85% 10%, rgba(224,92,58,0.12), transparent 42%),
    radial-gradient(circle at 70% 80%, rgba(107,63,160,0.12), transparent 40%),
    var(--ms-bg);
  filter: blur(40px) saturate(115%);
}

.ms-single-wrap{ max-width: 880px; margin: 0 auto; padding: 40px 28px 100px; }

.ms-back-link,
.ms-back-link:visited{
  display:inline-flex; align-items:center; gap:6px;
  color: var(--ms-ink-soft) !important; text-decoration:none; font-size:14px; font-weight:600;
  margin-bottom: 32px;
}
.ms-back-link:hover{ color: var(--ms-ink) !important; }

.ms-single-header{
  display:flex; align-items:flex-start; gap:26px;
  margin-bottom: 40px;
}
.ms-single-icon{
  flex:none; width:112px; height:112px; border-radius:26px;
  display:flex; align-items:center; justify-content:center;
  overflow:hidden;
  background:#E4E2DE;
  box-shadow: inset 0 1px 1px rgba(255,255,255,0.35), 0 10px 24px rgba(0,0,0,0.16);
}
.ms-single-icon img{ width:100%; height:100%; object-fit:cover; }

.ms-single-header-body h1{
  font-size: 34px; font-weight:700; letter-spacing:-0.02em; margin: 10px 0 8px;
}
.ms-single-tagline{ color: var(--ms-ink-soft); font-size:16px; margin: 0 0 20px; line-height:1.5; }

.ms-card-meta{ display:flex; gap:8px; align-items:center; font-size:12.5px; flex-wrap:wrap; }
.ms-price{ font-weight:700; font-size:13px; }
.ms-dot{ color: rgba(0,0,0,0.2); }

.ms-platform-badge{
  display:inline-flex; align-items:center; gap:5px;
  font-size:11.5px; font-weight:600; color: var(--ms-ink-soft);
  background: rgba(0,0,0,0.05);
  border: 1px solid rgba(0,0,0,0.06);
  border-radius: 7px;
  padding: 4px 8px 4px 6px;
}
.ms-platform-badge svg{ width:13px; height:13px; flex:none; }

.ms-status-badge{
  font-size:11.5px; font-weight:700;
  color: #9A6A00;
  background: rgba(255,178,0,0.14);
  border: 1px solid rgba(255,178,0,0.28);
  border-radius: 7px;
  padding: 4px 9px;
}

.ms-cta-row{ display:flex; align-items:center; gap:14px; flex-wrap:wrap; margin-top:6px; }

.ms-appstore-badge{ display:inline-block; line-height:0; }
.ms-appstore-badge img{ height:48px; width:auto; display:block; }

.ms-store-button{
  display:inline-flex; align-items:center; gap:8px;
  background: #007AFF; color:#fff; text-decoration:none;
  font-size:14.5px; font-weight:700;
  padding: 11px 22px; border-radius: 100px;
}
.ms-store-button:hover{ background:#0068DB; }

/* galerie de captures d'écran */
.ms-screens{
  display:flex; gap:16px; overflow-x:auto;
  padding-bottom: 8px; margin-bottom: 44px;
  scroll-snap-type: x proximity;
  height: 420px; /* hauteur commune : chaque capture garde son propre ratio */
}
.ms-screen{
  flex:none; height:100%; width:auto; border-radius:18px; overflow:hidden;
  box-shadow: 0 10px 30px rgba(0,0,0,0.12);
  scroll-snap-align: start;
  position:relative; padding:0; border:none; cursor:pointer; display:block;
}
.ms-screen img{ height:100%; width:auto; display:block; }

.ms-screen-overlay{
  position:absolute; inset:0;
  display:flex; align-items:center; justify-content:center;
  background: rgba(0,0,0,0.28);
  opacity:0; transition: opacity .22s ease;
}
.ms-screen:hover .ms-screen-overlay{ opacity:1; }
.ms-screen-overlay svg{ width:34px; height:34px; }

@media (max-width: 600px){
  .ms-screens{ height: 320px; }
}

/* lightbox plein écran */
.ms-lightbox{
  position:fixed; inset:0; z-index:999;
  background: rgba(10,10,11,0.92);
  display:none; align-items:center; justify-content:center;
  padding: 40px;
}
.ms-lightbox.is-open{ display:flex; }
.ms-lightbox img{
  max-width: 90vw; max-height: 88vh;
  border-radius: 16px;
  box-shadow: 0 30px 80px rgba(0,0,0,0.5);
}
.ms-lightbox-close{
  position:absolute; top:24px; right:28px;
  background: rgba(255,255,255,0.12); color:#fff; border:none;
  width:40px; height:40px; border-radius:100px;
  display:flex; align-items:center; justify-content:center;
  font-size:20px; line-height:1; padding:0;
  cursor:pointer;
}
.ms-lightbox-close span{ display:block; transform: translateY(-1px); }
.ms-lightbox-close:hover{ background: rgba(255,255,255,0.22); }

/* description / contenu de l'article */
.ms-single-content{
  font-size: 16px; line-height:1.7; color: var(--ms-ink);
  max-width: 680px;
}
.ms-single-content p{ margin: 0 0 1.2em; }
.ms-single-content h2{ font-size:22px; font-weight:700; margin: 1.6em 0 0.6em; }

.ms-changelog{
  margin-top: 44px; padding-top: 32px;
  border-top: 1px solid rgba(0,0,0,0.08);
  max-width: 680px;
}
.ms-changelog h3{ font-size:17px; font-weight:700; margin:0 0 12px; }
.ms-changelog-text{ font-size:14.5px; line-height:1.6; color: var(--ms-ink-soft); }
.ms-changelog-text p{ margin:0 0 0.8em; }

@media (max-width: 600px){
  .ms-single-header{ flex-direction:column; align-items:flex-start; }
  .ms-single-icon{ width:88px; height:88px; border-radius:20px; }
}

/* mode sombre */
html[data-theme="dark"] .ms-single-icon{ background:#2A2A2E; }
html[data-theme="dark"] .ms-dot{ color: rgba(255,255,255,0.25); }
html[data-theme="dark"] .ms-platform-badge{
  background: rgba(255,255,255,0.08);
  border-color: rgba(255,255,255,0.1);
}
html[data-theme="dark"] .ms-status-badge{
  color:#FFC24D;
  background: rgba(255,178,0,0.16);
  border-color: rgba(255,178,0,0.3);
}
html[data-theme="dark"] .ms-changelog{ border-top-color: rgba(255,255,255,0.09); }
