/* ══════════════════════════════════════════════════════
   PINKNOISESLEEP.COM — Deferred Stylesheet (style.css)
   Non-critical styles loaded after first paint.
   Critical CSS is inlined in each HTML <head>.
   ══════════════════════════════════════════════════════ */


/* ═══ CATEGORY PILLS ═══ */
.pills {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  justify-content: center;
  margin-bottom: 40px;
}

.pill {
  font-family: 'Sora', sans-serif;
  font-weight: 600;
  font-size: 13px;
  padding: 8px 20px;
  border-radius: 100px;
  border: 1px solid var(--border);
  background: transparent;
  color: var(--muted);
  transition: all 0.25s var(--ease);
}
.pill:hover {
  border-color: var(--border-h);
  color: var(--cream);
}

.p-pk { border-color: rgba(196, 112, 126, 0.2); }
.p-pk:hover,
.p-pk.on { color: var(--pink); border-color: var(--pink); background: rgba(196, 112, 126, 0.06); }

.p-br { border-color: rgba(160, 120, 80, 0.2); }
.p-br:hover,
.p-br.on { color: var(--brown); border-color: var(--brown); background: rgba(160, 120, 80, 0.06); }

.p-wh { border-color: rgba(232, 228, 220, 0.1); }
.p-wh:hover,
.p-wh.on { color: var(--cream); border-color: var(--cream); background: rgba(232, 228, 220, 0.04); }

.p-gr { border-color: rgba(122, 158, 110, 0.2); }
.p-gr:hover,
.p-gr.on { color: var(--green); border-color: var(--green); background: rgba(122, 158, 110, 0.06); }


/* ═══ ARTICLE CARDS — text only ═══ */
.grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(min(100%, 340px), 1fr));
  gap: 20px;
}

.card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--rl);
  padding: 28px 24px;
  transition: border-color 0.25s var(--ease), transform 0.3s var(--ease);
  display: flex;
  flex-direction: column;
  gap: 12px;
}
.card:hover {
  border-color: var(--border-h);
  transform: translateY(-3px);
}

.tag {
  font-family: 'Sora', sans-serif;
  font-weight: 600;
  font-size: 10px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  padding: 4px 12px;
  border-radius: 100px;
  display: inline-block;
  align-self: flex-start;
}
.tag-pk { color: var(--pink); background: rgba(196, 112, 126, 0.1); }
.tag-br { color: var(--brown); background: rgba(160, 120, 80, 0.1); }
.tag-gr { color: var(--green); background: rgba(122, 158, 110, 0.1); }
.tag-wh { color: var(--cream); background: rgba(232, 228, 220, 0.05); }

.card h3 {
  font-size: 1.1rem;
  line-height: 1.35;
}

.card-m {
  font-family: 'DM Sans', sans-serif;
  font-size: 12px;
  color: var(--muted);
}


/* ═══ FEATURED SECTIONS ═══ */
.feat {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 40px;
  align-items: center;
}

.feat-t h2 {
  margin-bottom: 12px;
}
.feat-t p {
  color: var(--body);
  line-height: 1.7;
  font-size: 0.95rem;
}

.feat-l {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  margin-top: 20px;
  font-family: 'Sora', sans-serif;
  font-weight: 600;
  font-size: 13px;
  color: var(--pink);
  transition: opacity 0.25s var(--ease);
}
.feat-l:hover { opacity: 0.75; }
.feat-l-s { color: #1DB954; }

/* YouTube embed */
.e-yt {
  position: relative;
  aspect-ratio: 16 / 9;
  border-radius: var(--rl);
  overflow: hidden;
  background: var(--card);
  border: 1px solid var(--border);
}
.e-yt iframe {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  border: none;
}

/* Spotify embed */
.e-sp {
  border-radius: var(--rl);
  overflow: hidden;
  border: 1px solid var(--border);
  background: var(--card);
}
.e-sp iframe {
  border: none;
  width: 100%;
  display: block;
}


/* ═══ NEWSLETTER ═══ */
.nl {
  text-align: center;
}
.nl h2 {
  margin-bottom: 8px;
}
.nl .ctr > p {
  color: var(--muted);
  max-width: 400px;
  margin: 0 auto;
  font-size: 0.9rem;
}

.nl-f {
  display: flex;
  gap: 8px;
  max-width: 420px;
  margin: 28px auto 0;
}
.nl-f input[type="email"] {
  flex: 1;
  padding: 12px 16px;
  font-family: 'DM Sans', sans-serif;
  font-size: 14px;
  color: var(--cream);
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--r);
  outline: none;
  transition: border-color 0.25s var(--ease);
}
.nl-f input[type="email"]::placeholder {
  color: var(--muted);
}
.nl-f input[type="email"]:focus {
  border-color: var(--pink);
}

.nl-f button {
  padding: 12px 24px;
  font-family: 'Sora', sans-serif;
  font-weight: 600;
  font-size: 13px;
  color: var(--bg);
  background: var(--pink);
  border: none;
  border-radius: var(--r);
  transition: transform 0.2s var(--ease), box-shadow 0.2s var(--ease);
  white-space: nowrap;
}
.nl-f button:hover {
  transform: translateY(-1px);
  box-shadow: 0 4px 16px rgba(196, 112, 126, 0.18);
}


/* ═══ FOOTER ═══ */
.foot {
  border-top: 1px solid var(--border);
  padding: 48px 0 32px;
  font-size: 13px;
  color: var(--muted);
}

.f-grid {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 1fr 1fr;
  gap: 40px;
}

.f-brand p {
  margin-top: 14px;
  max-width: 280px;
  line-height: 1.65;
  font-size: 13px;
}

.f-col h4 {
  font-family: 'Sora', sans-serif;
  font-weight: 600;
  font-size: 11px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--cream);
  margin-bottom: 14px;
}
.f-col a {
  display: block;
  padding: 5px 0;
  color: var(--muted);
  transition: color 0.2s var(--ease);
  font-size: 13px;
}
.f-col a:hover {
  color: var(--cream);
}

.f-bot {
  margin-top: 40px;
  padding-top: 20px;
  border-top: 1px solid var(--border);
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 12px;
  font-size: 12px;
  color: var(--muted);
}


/* ═══ MOBILE NAV OVERLAY ═══ */
.mob {
  display: none;
  position: fixed;
  inset: var(--nav-h) 0 0 0;
  background: var(--bg);
  z-index: 99;
  padding: 32px 24px;
  flex-direction: column;
}
.mob.open {
  display: flex;
}

.mob a {
  font-family: 'Sora', sans-serif;
  font-weight: 600;
  font-size: 18px;
  color: var(--cream);
  padding: 16px 0;
  border-bottom: 1px solid var(--border);
}
.mob .m-pk { color: var(--pink); }
.mob .m-br { color: var(--brown); }
.mob .m-gr { color: var(--green); }

.mob .m-sp {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  margin-top: 24px;
  padding: 14px 24px;
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: 100px;
  font-size: 14px;
}
.mob .m-sp svg {
  width: 18px;
  height: 18px;
  flex-shrink: 0;
}


/* ═══ RESPONSIVE ═══ */
@media (max-width: 768px) {
  .nav-c,
  .nav-sp { display: none; }
  .nav-h  { display: flex; }
  .feat   { grid-template-columns: 1fr; gap: 28px; }
  .f-grid { grid-template-columns: 1fr 1fr; gap: 32px; }
}

@media (max-width: 480px) {
  .nl-f   { flex-direction: column; }
  .f-grid { grid-template-columns: 1fr; }
}

/* Global mobile overflow protection */
html, body { overflow-x: hidden; max-width: 100vw; }
.ctr, .nav, .foot, .grid, .feat, .pills { max-width: 100%; }
iframe { max-width: 100%; }


/* ═══ REDUCED MOTION ═══ */
@media (prefers-reduced-motion: reduce) {
  .hero-ey,
  .hero h1,
  .hero-p,
  .hero-btn {
    animation: none;
    opacity: 1;
  }
}
