/*
Theme Name: SleepBaby Miracle
Theme URI: https://sleepbaby.org/
Author: SleepBaby
Author URI: https://sleepbaby.org/
Description: A premium SleepBaby sales experience with a pay-what-you-can PayPal page, a separate after-article invitation, legal-page support, and destination-safe tracking.
Version: 1.1.1
Requires at least: 6.4
Requires PHP: 7.4
Text Domain: sleepbaby-miracle
*/

:root{
  --sb-ink:#29304c;--sb-night:#171a35;--sb-plum:#625266;--sb-lilac:#a98fa3;--sb-lilac-pale:#eae2ec;
  --sb-ivory:#fff8ea;--sb-paper:#f7f2e9;--sb-indigo:#293366;--sb-indigo-deep:#232a57;--sb-twilight:#394990;
  --sb-sage:#9ebaae;--sb-mist:#a9c9d8;--sb-moon:#e7d7b5;--sb-display:Georgia,"Times New Roman",Times,serif;
  --sb-ui:"Segoe UI",Tahoma,Arial,sans-serif;--sb-gutter:clamp(20px,4vw,72px);
}

*,*::before,*::after{box-sizing:border-box}
html{scroll-behavior:smooth;background:var(--sb-night)}
body{margin:0;overflow-x:hidden;color:var(--sb-ink);background:#fffdf8;font-family:var(--sb-ui);font-size:17px;line-height:1.75;text-rendering:optimizeLegibility}
a{color:inherit;text-decoration:none}
img{display:block;max-width:100%;height:auto}
:focus-visible{outline:3px solid var(--sb-ivory);outline-offset:2px;box-shadow:0 0 0 7px var(--sb-twilight)}

.site-header{position:absolute;z-index:30;top:0;left:0;display:flex;width:100%;align-items:center;justify-content:space-between;padding:24px var(--sb-gutter);color:#fff}
.site-header--inner{position:relative;background:linear-gradient(135deg,var(--sb-night),var(--sb-indigo));box-shadow:0 12px 34px rgba(19,22,49,.18)}
.brand{display:inline-flex;align-items:center;gap:11px;color:#fff;font-family:var(--sb-display);font-size:1.25rem;font-weight:700;letter-spacing:-.025em}
.custom-logo-link{display:inline-flex;align-items:center;line-height:1}.custom-logo{width:auto;max-width:min(260px,52vw);max-height:58px;object-fit:contain}.footer-custom-logo .custom-logo{max-height:68px}
.brand-moon{position:relative;width:34px;height:34px;border-radius:50%;background:var(--sb-moon);box-shadow:0 0 0 5px rgba(231,215,181,.13)}
.brand-moon::after{content:"";position:absolute;top:3px;left:11px;width:27px;height:27px;border-radius:50%;background:var(--sb-night)}
.header-link{display:inline-flex;align-items:center;gap:13px;padding:11px 18px;border:2px solid rgba(255,255,255,.76);border-radius:999px;color:#fff;background:rgba(37,41,70,.84);font-size:.76rem;font-weight:800;letter-spacing:.1em;text-transform:uppercase}
.header-navigation .header-menu,.footer-navigation .footer-menu{display:flex;flex-wrap:wrap;align-items:center;gap:14px 25px;margin:0;padding:0;list-style:none}
.header-navigation a,.footer-navigation a{font-size:.78rem;font-weight:750}
.header-navigation a:hover,.footer-navigation a:hover{color:var(--sb-moon)}

.site-main{min-height:62vh}
.content-shell{width:min(calc(100% - var(--sb-gutter)*2),1160px);margin-inline:auto;padding:clamp(70px,8vw,120px) 0 clamp(100px,11vw,165px)}
.content-shell--article{width:min(calc(100% - var(--sb-gutter)*2),880px)}
.entry-header{margin-bottom:58px}
.entry-kicker,.archive-kicker{margin:0 0 18px;color:var(--sb-plum);font-size:.73rem;font-weight:800;letter-spacing:.16em;text-transform:uppercase}
.entry-title,.archive-title{margin:0;color:var(--sb-ink);font-family:var(--sb-display);font-size:clamp(3rem,6vw,5.9rem);font-weight:700;letter-spacing:-.045em;line-height:1.01;text-wrap:balance}
.entry-meta{margin-top:24px;color:#6f7387;font-size:.78rem;letter-spacing:.04em}
.entry-featured{margin:0 0 60px}
.entry-featured img{width:100%;border-radius:42px 100px 42px 100px;box-shadow:0 24px 58px rgba(41,48,76,.15)}
.entry-content{font-size:1.05rem;line-height:1.86}
.entry-content>*{max-width:780px;margin-right:auto;margin-left:auto}
.entry-content>figure,.entry-content>.alignwide{max-width:1050px}
.entry-content>.alignfull{width:100vw;max-width:none;margin-left:calc(50% - 50vw)}
.entry-content p{margin-top:0;margin-bottom:1.45em}
.entry-content h2,.entry-content h3,.entry-content h4{margin:1.8em auto .65em;color:var(--sb-ink);font-family:var(--sb-display);font-weight:700;letter-spacing:-.03em;line-height:1.12}
.entry-content h2{font-size:clamp(2.15rem,4vw,3.6rem)}.entry-content h3{font-size:clamp(1.65rem,3vw,2.45rem)}
.entry-content a{color:var(--sb-indigo);font-weight:700;text-decoration:underline;text-decoration-color:var(--sb-mist);text-decoration-thickness:2px;text-underline-offset:3px}
.entry-content blockquote{margin:2.2em auto;padding:32px 36px;border-left:5px solid var(--sb-lilac);border-radius:0 34px 34px 0;background:#f1edf3;font-family:var(--sb-display);font-size:1.2em}
.entry-content ul,.entry-content ol{padding-left:1.35em}.entry-content li{margin:.55em 0}
.post-navigation{display:grid;grid-template-columns:1fr 1fr;gap:30px;margin-top:90px;padding-top:34px;border-top:1px solid rgba(41,51,102,.14)}
.post-navigation a{font-family:var(--sb-display);font-size:1.05rem;font-weight:700}.post-navigation .nav-next{text-align:right}
.archive-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:36px;margin-top:65px}
.archive-card{padding:38px;border:1px solid rgba(41,51,102,.12);border-radius:35px 75px 35px 75px;background:#fff;box-shadow:0 18px 44px rgba(41,48,76,.1)}
.archive-card h2{margin:0;font-family:var(--sb-display);font-size:2rem;line-height:1.15}.archive-card p{margin-bottom:0}

.site-footer{position:relative;padding:86px var(--sb-gutter) 100px;color:rgba(255,255,255,.82);background:var(--sb-night)}
.footer-top{display:flex;align-items:flex-start;justify-content:space-between;gap:55px}
.footer-brand{color:#fff}.footer-navigation{max-width:800px}.footer-navigation .footer-menu{justify-content:flex-end}
.footer-compliance{margin-top:50px;padding-top:28px;border-top:1px solid rgba(255,255,255,.15)}
.footer-compliance-links{display:flex;flex-wrap:wrap;gap:8px 22px;margin:0;padding:0;list-style:none}
.footer-compliance-links a{color:rgba(255,255,255,.78);font-size:.875rem;font-weight:650;text-decoration:underline;text-decoration-color:rgba(231,215,181,.34);text-underline-offset:4px}
.footer-compliance-links a:hover{color:#fff;text-decoration-color:var(--sb-moon)}
.footer-extra-links{margin-top:13px}
.footer-fine-print{margin:22px 0 0;color:rgba(255,255,255,.58);font-size:.79rem;line-height:1.55}

/* The article invitation is emitted by get_footer(), after content and before footer.php. */
.article-footer-promo{position:relative;width:100%;min-height:730px;overflow:hidden;color:#fff;background:radial-gradient(circle at 80% 35%,rgba(169,201,216,.2),transparent 24%),radial-gradient(circle at 68% 78%,rgba(169,143,163,.22),transparent 30%),linear-gradient(145deg,#171a35 0%,#293366 56%,#3d456f 100%);isolation:isolate}
.article-footer-promo::before{content:"";position:absolute;z-index:5;top:-1px;right:-4%;left:-4%;height:96px;border-radius:0 0 52% 48%/0 0 100% 100%;background:#fffdf8}
.article-footer-promo::after{content:"";position:absolute;z-index:0;right:-14%;bottom:-46%;width:62%;aspect-ratio:1;border-radius:50%;background:radial-gradient(circle,rgba(231,215,181,.26),rgba(169,201,216,.08) 48%,transparent 69%)}
.article-footer-glow{position:absolute;z-index:0;top:18%;right:9%;width:min(34vw,470px);aspect-ratio:1;border-radius:50%;background:radial-gradient(circle,rgba(231,215,181,.24),rgba(169,143,163,.12) 48%,transparent 72%);filter:blur(5px)}
.article-footer-stars i{position:absolute;z-index:1;width:8px;height:8px;border-radius:50%;background:var(--sb-mist);box-shadow:0 0 18px rgba(169,201,216,.8)}
.article-footer-stars i:nth-child(1){top:24%;left:7%}.article-footer-stars i:nth-child(2){top:18%;left:36%;width:5px;height:5px;background:var(--sb-lilac)}.article-footer-stars i:nth-child(3){top:62%;left:4%;width:6px;height:6px;background:var(--sb-moon)}.article-footer-stars i:nth-child(4){top:76%;left:42%;width:4px;height:4px}.article-footer-stars i:nth-child(5){top:34%;right:5%;width:5px;height:5px;background:var(--sb-moon)}
.article-footer-inner{position:relative;width:min(calc(100% - var(--sb-gutter)*2),1480px);min-height:730px;margin-inline:auto}
.article-footer-copy{position:relative;z-index:3;width:min(45%,610px);padding:clamp(150px,15vw,205px) 0 110px}
.article-footer-eyebrow{margin:0 0 22px;color:var(--sb-mist);font-size:.75rem;font-weight:800;letter-spacing:.17em;text-transform:uppercase}
.article-footer-copy h2{margin:0;max-width:650px;color:#fffdf8;font-family:var(--sb-display);font-size:clamp(3.15rem,5.3vw,5.8rem);font-weight:700;letter-spacing:-.045em;line-height:.98;text-wrap:balance}
.article-footer-copy>p:not(.article-footer-eyebrow){max-width:540px;margin:30px 0 0;color:#e3e8f0;font-size:clamp(1.05rem,1.5vw,1.25rem);line-height:1.68}
.article-footer-button{display:inline-flex;align-items:center;justify-content:space-between;gap:26px;min-width:min(100%,390px);margin-top:38px;padding:13px 14px 13px 24px;border:1px solid rgba(255,255,255,.5);border-radius:999px;color:var(--sb-indigo-deep);background:linear-gradient(135deg,#fff8ea,#e9e1d2);box-shadow:0 18px 42px rgba(8,11,35,.28);font-size:.8rem;font-weight:800;letter-spacing:.07em;line-height:1.2;text-transform:uppercase;transition:transform .2s ease,box-shadow .2s ease,background .2s ease}
.article-footer-button span:last-child{display:grid;flex:0 0 auto;width:42px;height:42px;place-items:center;border-radius:50%;color:#fff;background:linear-gradient(135deg,var(--sb-twilight),var(--sb-indigo));font-size:1.12rem}
.article-footer-button:hover{background:#fff;box-shadow:0 14px 32px rgba(8,11,35,.24);transform:translateY(-3px)}
.article-footer-copy small{display:block;margin-top:19px;color:rgba(233,237,244,.78);font-size:.72rem;letter-spacing:.035em}
.article-footer-art{position:absolute;z-index:2;right:-5%;bottom:-2%;width:min(100%,1672px);max-width:none;height:auto;filter:drop-shadow(0 30px 38px rgba(8,11,35,.32));pointer-events:none}

/* The purchase return is intentionally public and styled as a clear handoff. */
.sleepbaby-success-page{background:#fffaf0}.sleepbaby-success-main{overflow:hidden;background:#fffaf0}.sleepbaby-success-hero{position:relative;overflow:hidden;padding:clamp(95px,11vw,155px) var(--sb-gutter);color:#fff;background:radial-gradient(circle at 80% 24%,rgba(169,201,216,.22),transparent 25%),radial-gradient(circle at 17% 84%,rgba(169,143,163,.22),transparent 32%),linear-gradient(142deg,#171a35,#293366 60%,#4e5077);isolation:isolate}.sleepbaby-success-hero::after{content:"";position:absolute;right:-5%;bottom:-63px;left:-5%;height:110px;border-radius:50% 50% 0 0;background:#fffaf0}.sleepbaby-success-hero-inner{position:relative;z-index:2;width:min(100%,900px);margin-inline:auto;text-align:center}.sleepbaby-success-hero .entry-kicker{color:var(--sb-mist)}.sleepbaby-success-hero h1{margin:0;color:#fffaf0;font-family:var(--sb-display);font-size:clamp(3.25rem,7vw,6.5rem);font-weight:700;letter-spacing:-.055em;line-height:.95;text-wrap:balance}.sleepbaby-success-hero-inner>p:last-child{max-width:680px;margin:27px auto 0;color:#e5e8f1;font-size:clamp(1rem,1.4vw,1.18rem);line-height:1.65}.sleepbaby-success-stars i{position:absolute;width:7px;height:7px;border-radius:50%;background:var(--sb-moon);box-shadow:0 0 16px rgba(231,215,181,.78)}.sleepbaby-success-stars i:nth-child(1){top:22%;left:8%}.sleepbaby-success-stars i:nth-child(2){top:62%;left:17%;width:4px;height:4px;background:var(--sb-mist)}.sleepbaby-success-stars i:nth-child(3){top:18%;right:13%;width:5px;height:5px;background:var(--sb-lilac)}.sleepbaby-success-stars i:nth-child(4){right:5%;bottom:28%;width:4px;height:4px}.sleepbaby-success-stars i:nth-child(5){bottom:20%;left:48%;width:5px;height:5px;background:var(--sb-mist)}.sleepbaby-success-library{padding:clamp(80px,10vw,140px) var(--sb-gutter) clamp(100px,11vw,160px)}.sleepbaby-success-library-inner{width:min(100%,900px);margin-inline:auto;padding:clamp(32px,5vw,58px);border:1px solid rgba(41,51,102,.12);border-radius:42px 95px 42px 95px;background:#fff;box-shadow:0 28px 68px rgba(41,48,76,.13)}.sleepbaby-success-library h2{margin:0 0 30px;color:var(--sb-ink);font-family:var(--sb-display);font-size:clamp(2.7rem,5vw,4.8rem);letter-spacing:-.045em;line-height:1}.sleepbaby-success-content .entry-content>*{max-width:none}.sleepbaby-success-content .entry-content a{display:inline-flex;margin:7px 8px 7px 0;padding:13px 22px;border-radius:999px;color:#fff;background:linear-gradient(135deg,var(--sb-twilight),var(--sb-indigo));box-shadow:0 12px 24px rgba(41,51,102,.18);font-size:.78rem;font-weight:800;letter-spacing:.04em;text-decoration:none}.sleepbaby-success-content .entry-content a:hover{background:var(--sb-indigo-deep);transform:translateY(-2px)}

[hidden]{display:none!important}

@media(max-width:980px){
  .article-footer-promo,.article-footer-inner{min-height:920px}.article-footer-copy{width:min(100%,650px);padding:150px 0 0}.article-footer-art{right:-19%;bottom:-1%;width:125%;max-width:1400px}.article-footer-copy h2{font-size:clamp(3rem,7vw,5.2rem)}
  .archive-grid{grid-template-columns:1fr}
}
@media(max-width:760px){
  body{font-size:16px}.site-header--inner{align-items:flex-start;flex-direction:column;gap:20px}.header-navigation .header-menu{gap:10px 18px}.footer-top{flex-direction:column}.footer-navigation .footer-menu{justify-content:flex-start}.footer-compliance{margin-top:38px}.footer-compliance-links{gap:9px 18px}.footer-compliance-links a{font-size:.875rem}.post-navigation{grid-template-columns:1fr}.post-navigation .nav-next{text-align:left}
}
@media(max-width:660px){
  .content-shell{padding-top:70px}.entry-title{font-size:clamp(2.65rem,12vw,4rem)}.entry-header{margin-bottom:42px}.entry-featured{margin-bottom:42px}.entry-featured img{border-radius:28px 62px 28px 62px}
  .article-footer-promo{min-height:900px}.article-footer-promo::before{height:64px}.article-footer-inner{min-height:900px;width:calc(100% - 36px)}.article-footer-copy{width:100%;padding:112px 4px 0}.article-footer-copy h2{font-size:clamp(2.75rem,12.5vw,4.15rem);line-height:1}.article-footer-copy>p:not(.article-footer-eyebrow){font-size:1rem}.article-footer-button{width:100%;min-width:0;padding-left:18px;font-size:.72rem;letter-spacing:.055em}.article-footer-copy small{max-width:300px;line-height:1.5}.article-footer-art{right:-44%;bottom:0;width:170%;max-width:none}.site-footer{padding:70px 18px 100px}
  .sleepbaby-success-hero{padding:82px 18px 105px}.sleepbaby-success-hero h1{font-size:clamp(3rem,14vw,4.5rem)}.sleepbaby-success-library{padding:70px 18px 100px}.sleepbaby-success-library-inner{padding:30px 22px;border-radius:32px 68px 32px 68px}.sleepbaby-success-content .entry-content a{display:flex;justify-content:center;margin-right:0;text-align:center}
}
@media(prefers-reduced-motion:reduce){html{scroll-behavior:auto}*,*::before,*::after{animation-duration:.01ms!important;animation-iteration-count:1!important;scroll-behavior:auto!important;transition-duration:.01ms!important}}
