/* ==========================================================================
   Sexy Secrets Radio: accent layer
   Dividers, rules, edge trims, corner flourishes, icon medallions and rendered backgrounds.
   Every image here lives in /assets/img/accents, /icons and /backgrounds and is made by
   tools/make-accents.py (see docs/05-CUSTOMIZE.md). Delete this file's <link> in
   templates/partials/head.html to see the plain site.
   ========================================================================== */
:root {
  --dh: clamp(44px, 5vw, 78px);                              /* height of seam dividers */
  --trim: clamp(40px, calc((100vw - 1180px) / 2 - 16px), 110px);
}

/* ---- 1. heading rule: a short hairline flourish instead of a plain line ------------------ */
.rule { border: 0; height: 28px; margin-top: .7rem; background: url("/assets/img/accents/rule-ornament-light.svg") left center / 300px 23px no-repeat; }
.rule::before { display: none; }
.center .rule, .section-head.center .rule { background-position: center; }
.section-head, .page-hero .wrap > div:first-child { position: relative; }

/* ---- 2. dividers --------------------------------------------------------------------- */
.divider { display: block; height: clamp(56px, 7vw, 112px); background: center / auto 100% no-repeat; pointer-events: none; }
.divider-heart { background-image: url("/assets/img/accents/divider-heart-light.svg"); height: clamp(84px, 11vw, 150px); }
.divider-wave { background-image: url("/assets/img/accents/divider-wave-light.svg"); }
.divider-sparkle { background-image: url("/assets/img/accents/divider-sparkle-light.svg"); height: clamp(40px, 5vw, 64px); }
.divider.on-dark.divider-heart { background-image: url("/assets/img/accents/divider-heart-dark.svg"); }
.divider.on-dark.divider-wave { background-image: url("/assets/img/accents/divider-wave-dark.svg"); }
.divider.on-dark.divider-sparkle { background-image: url("/assets/img/accents/divider-sparkle-dark.svg"); }

/* ivory bands get a wave laid across their top and bottom seams */
.band-ivory { position: relative; }
.band-ivory::before, .band-ivory::after { content: ""; position: absolute; left: 0; right: 0; height: var(--dh); z-index: 1; pointer-events: none; background: url("/assets/img/accents/divider-wave-light.svg") center / auto 100% no-repeat; }
.band-ivory::before { top: calc(var(--dh) / -2); }
.band-ivory::after { bottom: calc(var(--dh) / -2); }
main > .band-ivory:last-child::after { display: none; }       /* the footer has its own */

/* ---- 3. edge trims on wide screens (only where the page has margins to show them) ------------- */
@media (min-width: 1280px) {
  .section, .listen {
    background-image: url("/assets/img/accents/trim-left-light.svg"), url("/assets/img/accents/trim-right-light.svg");
    background-repeat: repeat-y, repeat-y;
    background-position: left top, right top;
    background-size: var(--trim) auto, var(--trim) auto;
  }
}

/* ---- 4. corner flourishes on glass and audio cards -------------------------------------- */
.glass, .audio-card { position: relative; }
.glass::before, .glass::after, .audio-card::before, .audio-card::after {
  content: ""; position: absolute; width: clamp(64px, 8vw, 112px); aspect-ratio: 1; pointer-events: none;
  background: url("/assets/img/accents/corner-flourish-light.svg") center / contain no-repeat;
}
.glass::before, .audio-card::before { top: 5px; left: 5px; }
.glass::after, .audio-card::after { bottom: 5px; right: 5px; transform: rotate(180deg); }
.feature.glass::before, .feature.glass::after { z-index: 1; }

/* ---- 5. icon medallions ------------------------------------------------------------------ */
.medal { display: inline-grid; place-items: center; width: 56px; height: 56px; border-radius: 50%; margin-bottom: .8rem; position: relative;
  background: radial-gradient(circle at 32% 26%, #fff, var(--ivory) 78%); border: 1px solid rgba(189, 139, 83, .7);
  box-shadow: 0 8px 22px rgba(78, 31, 70, .12), inset 0 0 0 4px rgba(255, 252, 247, .9), inset 0 0 0 5px rgba(189, 139, 83, .3); }
.medal .icon { width: 30px; height: 30px; vertical-align: 0; }
.medal.sm { width: 44px; height: 44px; margin-bottom: .6rem; }
.medal.sm .icon { width: 24px; height: 24px; }
.section-head .medal, .page-hero .medal { display: grid; }
.center .medal, .section-head.center .medal { margin-inline: auto; }
.on-dark .medal, .quote-band .medal { background: radial-gradient(circle at 32% 26%, #6d275f, #3a1535 80%); border-color: rgba(236, 208, 164, .7); box-shadow: 0 8px 22px rgba(0, 0, 0, .3), inset 0 0 0 4px rgba(58, 21, 53, .9), inset 0 0 0 5px rgba(236, 208, 164, .3); }
.eyebrow .icon, .kicker .icon { width: 1.3em; height: 1.3em; vertical-align: -.3em; margin-right: .35em; }

/* ---- 6. inner-page heroes -------------------------------------------------------------- */
.page-hero { position: relative; border-bottom: 0; padding-bottom: clamp(48px, 6vw, 80px);
  background: linear-gradient(90deg, rgba(255, 252, 247, .7), rgba(255, 252, 247, .15) 65%), url("/assets/img/backgrounds/pearl-silk-1920.webp") center / cover no-repeat, var(--ivory); }
.page-hero::after { content: ""; position: absolute; left: 0; right: 0; bottom: calc(var(--dh) / -2); height: var(--dh); z-index: 1; pointer-events: none;
  background: url("/assets/img/accents/divider-wave-light.svg") center / auto 100% no-repeat; }
.page-hero .wrap { position: relative; z-index: 2; }

/* ---- 7. cards --------------------------------------------------------------------------- */
.card-media { position: relative; }
.card-media::after { content: ""; position: absolute; right: 18px; bottom: -22px; width: 44px; height: 44px; border-radius: 50%; z-index: 2;
  background: #fffcf7 url("/assets/img/icons/plum/play.svg") center / 26px no-repeat; border: 1px solid rgba(189, 139, 83, .75); box-shadow: 0 6px 16px rgba(78, 31, 70, .16); }
.card-body { padding-top: 30px; }
.net-card { position: relative; border-top-width: 1px; border-top-color: var(--rule); box-shadow: inset 0 3px 0 -1px var(--gold); }
.net-card .medal { align-self: flex-start; }
.net-card:hover { border-color: var(--gold); }

/* numbered threads sit in a gold ring */
.thread-n { display: grid; place-items: center; width: 48px; height: 48px; border: 1px solid rgba(189, 139, 83, .8); border-radius: 50%; font-size: 1.35rem; line-height: 1;
  background: radial-gradient(circle at 32% 26%, #fff, var(--ivory)); box-shadow: inset 0 0 0 3px #fffcf7, inset 0 0 0 4px rgba(189, 139, 83, .3); }
.part-n { color: var(--magenta); }

/* ---- 8. prose: ornament under h2, ornamental quote mark on pull quotes ----------------------- */
.prose h2::after { content: ""; display: block; height: 20px; width: 240px; margin-top: .3rem; background: url("/assets/img/accents/rule-ornament-light.svg") left center / 240px 18px no-repeat; }
.prose blockquote { position: relative; border-left: 0; padding: 2.6rem 0 .2rem 0; }
.prose blockquote::before { content: ""; position: absolute; top: 0; left: 0; width: 46px; height: 34px; background: url("/assets/img/accents/quote-mark-light.svg") left / contain no-repeat; }

/* ---- 9. quote band: rendered aubergine glass, trims, ornamental marks -------------------------- */
.quote-band { position: relative; overflow: hidden; padding: clamp(64px, 8vw, 108px) 0;
  background: url("/assets/img/backgrounds/aubergine-1920.webp") center / cover no-repeat, linear-gradient(135deg, var(--deep), var(--purple)); }
.quote-band::before, .quote-band::after { content: ""; position: absolute; left: 0; right: 0; height: 44px; pointer-events: none; background: url("/assets/img/accents/divider-sparkle-dark.svg") center / auto 100% no-repeat; }
.quote-band::before { top: 14px; }
.quote-band::after { bottom: 14px; }
.quote-band .wrap { position: relative; z-index: 1; }
.quotes blockquote::before { content: ""; display: block; width: 52px; height: 38px; margin-bottom: .9rem; background: url("/assets/img/accents/quote-mark-dark.svg") left / contain no-repeat; }

/* ---- 10. footer: plum glass, heart divider on top ------------------------------------------- */
.site-footer { padding-top: 0;
  background: linear-gradient(rgba(58, 21, 53, .5), rgba(58, 21, 53, .72)), url("/assets/img/backgrounds/plum-glass-1920.webp") center / cover no-repeat, var(--deep); }
.site-footer::before { content: ""; display: block; height: clamp(90px, 11vw, 156px); margin-bottom: 4px; background: url("/assets/img/accents/divider-heart-dark.svg") center / auto 100% no-repeat; }
.foot-base { border-top: 0; position: relative; }
.foot-base::before { content: ""; position: absolute; top: 0; left: 0; right: 0; height: 30px; background: url("/assets/img/accents/divider-sparkle-dark.svg") center / auto 100% no-repeat; }
.foot-base { padding-top: 44px; }

/* live strip + header get a jewel */
.live-strip { background: linear-gradient(90deg, var(--deep), #5a2152 50%, var(--deep)); }

/* ---- 11. buttons: a little more jewel ------------------------------------------------------- */
.btn:not(.btn-ghost):not(.btn-link) { background: linear-gradient(135deg, #7c2f6c, var(--purple) 55%, #5a2152); border-color: #8a3a7b; box-shadow: 0 1px 0 rgba(255, 255, 255, .25) inset, 0 6px 16px rgba(78, 31, 70, .22); }
.btn:not(.btn-ghost):not(.btn-link):hover { background: linear-gradient(135deg, #c41d80, var(--magenta)); }

/* ---- responsive & print -------------------------------------------------------------------- */
@media (max-width: 860px) {
  .page-hero { background-image: linear-gradient(rgba(255, 252, 247, .55), rgba(255, 252, 247, .2)), url("/assets/img/backgrounds/pearl-silk-mobile-1080.webp"); }
  .quote-band { background-image: url("/assets/img/backgrounds/aubergine-mobile-1080.webp"), linear-gradient(135deg, var(--deep), var(--purple)); }
  .site-footer { background-image: linear-gradient(rgba(58, 21, 53, .5), rgba(58, 21, 53, .72)), url("/assets/img/backgrounds/plum-glass-mobile-1080.webp"); }
  .rule { background-size: 240px 18px; }
  .medal { width: 50px; height: 50px; }
}
@media (max-width: 520px) {
  .glass::before, .glass::after, .audio-card::before, .audio-card::after { width: 56px; }
  .prose h2::after { width: 190px; background-size: 190px 15px; }
}
@media print {
  .divider, .band-ivory::before, .band-ivory::after, .page-hero::after, .glass::before, .glass::after, .audio-card::before, .audio-card::after, .quote-band::before, .quote-band::after { display: none; }
}

/* the episode "across the conversation" strip already sits between two waves */
.bridge + .band-ivory::before { display: none; }
