@font-face{font-family:'Vazirmatn';src:url('/fonts/Vazirmatn-Regular.woff2') format('woff2');font-weight:400;font-display:swap}
@font-face{font-family:'Vazirmatn';src:url('/fonts/Vazirmatn-Medium.woff2') format('woff2');font-weight:500;font-display:swap}
@font-face{font-family:'Vazirmatn';src:url('/fonts/Vazirmatn-Bold.woff2') format('woff2');font-weight:700 900;font-display:swap}
/* Shahr Qesse design system v13 — responsive storybook, accessible, RTL */
:root{
 --sq-ink:#254d49;--sq-ink-2:#376761;--sq-muted:#697d78;--sq-cream:#fffaf0;--sq-paper:#fffdf8;
 --sq-mint:#dff3e7;--sq-mint-strong:#bde8d1;--sq-coral:#ff866f;--sq-coral-soft:#fff0e9;
 --sq-sun:#ffd877;--sq-lavender:#eeebff;--sq-line:#e8e9dc;--sq-shadow:0 16px 45px rgba(43,76,65,.09);
 --sq-radius:26px;
}
html{scroll-behavior:smooth;scroll-padding-top:100px}
body{font-family:'Vazirmatn',Tahoma,sans-serif!important;background:radial-gradient(ellipse at 8% 8%,rgba(255,216,119,.18),transparent 28%),radial-gradient(ellipse at 92% 26%,rgba(190,232,209,.26),transparent 30%),var(--sq-cream)!important;color:var(--sq-ink)!important}
body.dark-mode,body.dark-theme{--sq-ink:#eef7f0;--sq-ink-2:#c8e7d9;--sq-muted:#b5c6bf;--sq-cream:#171f1e;--sq-paper:#202b29;--sq-mint:#253d34;--sq-mint-strong:#2d5245;--sq-coral-soft:#3a2a29;--sq-lavender:#29263b;--sq-line:#384641;background:radial-gradient(ellipse at 8% 8%,rgba(130,102,62,.10),transparent 28%),radial-gradient(ellipse at 92% 26%,rgba(55,103,89,.16),transparent 30%),var(--sq-cream)!important;color:var(--sq-ink)!important}
/* Navigation */
.header{padding:10px 22px!important;background:rgba(255,253,248,.9)!important;backdrop-filter:blur(18px);box-shadow:0 5px 22px rgba(43,76,65,.055)!important;border-bottom:1px solid rgba(232,233,220,.9)!important}
body.dark-mode .header,body.dark-theme .header{background:rgba(28,39,36,.93)!important;border-bottom-color:rgba(255,255,255,.08)!important}
.header-container{max-width:1280px!important;min-height:62px;gap:18px!important}
.logo{display:flex;align-items:center;justify-content:center;width:48px;height:48px;border-radius:17px;background:linear-gradient(135deg,#fff0c8,#d9f3e3);box-shadow:0 5px 15px rgba(43,76,65,.1);overflow:hidden}
.logo img{width:42px;height:42px;object-fit:contain}
.header-nav{gap:7px!important;align-items:center}
.nav-simple-btn,.nav-btn{display:inline-flex!important;align-items:center;justify-content:center;gap:8px;padding:11px 15px!important;min-height:42px;border-radius:14px!important;color:var(--sq-ink)!important;font-weight:800!important;text-decoration:none!important;transition:background .2s,transform .2s}
.nav-simple-btn:hover,.nav-btn:hover{background:var(--sq-mint)!important;transform:translateY(-1px)}
.nav-dropdown-content,.user-dropdown{border:1px solid var(--sq-line)!important;border-radius:17px!important;box-shadow:var(--sq-shadow)!important;overflow:hidden;background:var(--sq-paper)!important;padding:8px!important}
.nav-dropdown-content a,.user-dropdown-item{border-radius:11px!important;color:var(--sq-ink)!important;padding:10px 13px!important}
.nav-dropdown-content a:hover,.user-dropdown-item:hover{background:var(--sq-mint)!important}
.header-actions{gap:9px!important}
.login-btn,.header-btn{border:1px solid rgba(76,135,111,.12)!important;background:linear-gradient(135deg,#d7f2e2,#bde8d1)!important;color:#234d45!important;border-radius:15px!important;box-shadow:0 5px 13px rgba(48,109,82,.1)!important;font-weight:800!important}
.header-icon-btn{background:var(--sq-paper)!important;border:1px solid var(--sq-line)!important;color:var(--sq-ink)!important;box-shadow:none!important}
.mobile-menu{background:var(--sq-paper)!important;border:1px solid var(--sq-line)!important;border-radius:0 0 20px 20px;box-shadow:var(--sq-shadow)}
.mobile-menu-item{padding:13px 18px!important;color:var(--sq-ink)!important;border-bottom:1px solid var(--sq-line)!important}
/* Hero */
.hero.hero-redesign{position:relative;max-width:1280px!important;width:calc(100% - 40px)!important;margin:104px auto 34px!important;padding:0!important;overflow:hidden;border:1px solid rgba(222,232,215,.9);border-radius:36px;background:linear-gradient(115deg,#fff8e6 0%,#fffdf7 48%,#e4f5e9 100%)!important;box-shadow:0 18px 50px rgba(43,76,65,.08)}
body.dark-mode .hero.hero-redesign,body.dark-theme .hero.hero-redesign{background:linear-gradient(115deg,#302d25 0%,#202927 52%,#203b32 100%)!important;border-color:#354941}
.hero-redesign .hero-inner{min-height:400px;display:grid;grid-template-columns:minmax(0,1.15fr) minmax(260px,.8fr);align-items:center;gap:10px;padding:28px clamp(22px,5vw,70px);direction:rtl}
.hero-copy{position:relative;z-index:2;max-width:650px;padding:14px 0}
.hero-kicker{display:inline-flex;align-items:center;gap:8px;background:#fff0c8;color:#816322;font-size:.85rem;font-weight:900;padding:8px 13px;border-radius:99px;margin:0 0 17px}
.hero-copy h1{color:#264e48;font-size:clamp(2.1rem,4.4vw,3.65rem);line-height:1.35;font-weight:950;margin:0 0 14px;letter-spacing:-.7px}
.hero-copy h1 span{color:#e7765e;white-space:nowrap}
.hero-copy p{color:#62756f;font-size:1.05rem;line-height:2.1;max-width:590px;margin:0 0 22px}
body.dark-mode .hero-copy h1,body.dark-theme .hero-copy h1{color:#f0f7ee}body.dark-mode .hero-copy p,body.dark-theme .hero-copy p{color:#c3d4ca}
.hero-actions{display:flex;flex-wrap:wrap;gap:11px;align-items:center}
.hero-primary,.hero-secondary{display:inline-flex;align-items:center;justify-content:center;gap:9px;min-height:48px;padding:0 19px;border-radius:15px;text-decoration:none!important;font-weight:900;transition:transform .2s,box-shadow .2s}
.hero-primary{background:linear-gradient(135deg,#2c675a,#3d8772);color:white!important;box-shadow:0 8px 18px rgba(42,104,87,.2)}
.hero-secondary{background:rgba(255,255,255,.72);border:1px solid #e2eadb;color:#315b50!important}
.hero-primary:hover,.hero-secondary:hover{transform:translateY(-2px)}
.hero-note{display:flex;flex-wrap:wrap;gap:15px;margin-top:23px;color:#6b8178;font-size:.82rem;font-weight:700}
.hero-note span{display:inline-flex;align-items:center;gap:7px}.hero-note i{color:#3d8a70}
.hero-art{position:relative;min-height:330px;display:flex;align-items:center;justify-content:center;isolation:isolate}
.hero-art::before{content:'';position:absolute;width:min(90%,360px);aspect-ratio:1;border-radius:46% 54% 50% 50%;background:radial-gradient(circle at 40% 30%,#fff6cb,#f9dca0 62%,#f2c77f);z-index:-1;transform:rotate(-8deg)}
.hero-art::after{content:'✦   ✧   ✦';position:absolute;top:22px;right:14px;color:#c99a32;font-size:1.5rem;letter-spacing:13px}
.hero-art img{width:100%;max-width:330px;height:330px;object-fit:contain;border-radius:28px;mix-blend-mode:multiply;filter:drop-shadow(0 14px 16px rgba(94,75,36,.1))}
body.dark-mode .hero-art img,body.dark-theme .hero-art img{mix-blend-mode:normal;border-radius:26px;opacity:.96}
@media(max-width:760px){.hero.hero-redesign{width:calc(100% - 22px)!important;margin:86px auto 24px!important;border-radius:26px}.hero-redesign .hero-inner{grid-template-columns:1fr;padding:25px 20px 18px;gap:0}.hero-copy{padding:6px 0 0}.hero-copy h1{font-size:clamp(1.9rem,8vw,2.7rem)}.hero-copy p{font-size:.92rem}.hero-art{min-height:210px;margin-top:8px}.hero-art img{height:230px;max-width:250px}.hero-art::before{width:210px}.hero-note{gap:9px;font-size:.75rem}}
/* Section framework and headings */
.featured-section,.categories-section,.stories-section,.discovery-section{max-width:1240px!important;width:calc(100% - 40px)!important;margin:32px auto!important;padding:0!important}
.discovery-section{padding:30px!important;border-radius:30px;background:rgba(255,255,255,.54);border:1px solid rgba(223,229,214,.85);box-shadow:0 8px 28px rgba(43,76,65,.035)}
body.dark-mode .discovery-section,body.dark-theme .discovery-section{background:rgba(255,255,255,.035);border-color:var(--sq-line)}
.discovery-heading{margin-bottom:22px!important;align-items:end!important;gap:15px}
.discovery-heading h2{font-size:clamp(1.35rem,2.4vw,1.9rem)!important;letter-spacing:-.3px;color:var(--sq-ink)!important}
.discovery-heading p{color:var(--sq-muted)!important;line-height:1.9}
.discovery-eyebrow{border-radius:99px!important;background:var(--sq-mint)!important;color:#2e7561!important}
.discovery-all-link{border-radius:13px!important;border:1px solid var(--sq-line)!important;background:var(--sq-paper)!important;color:var(--sq-ink)!important;padding:10px 14px!important}
/* Newest stories: framed shelf */
#stories.featured-section{background:linear-gradient(135deg,#e6f5e9,#fff6e7 70%,#fffaf2)!important;padding:25px!important;margin:30px auto!important;width:calc(100% - 40px)!important;max-width:1240px!important;border:1px solid #e1ecdf!important;border-radius:30px!important;box-shadow:0 12px 32px rgba(43,76,65,.06)!important}
body.dark-mode #stories.featured-section,body.dark-theme #stories.featured-section{background:linear-gradient(135deg,#24382e,#282a27 70%,#302d25)!important;border-color:#39473d!important}
#stories .slider-container{padding:0!important}
#stories .slider{gap:0!important;padding:5px 0 13px!important;scrollbar-width:thin;scrollbar-color:#9dcab1 transparent}
#stories .custom-featured-slide{flex-basis:320px!important;width:320px!important;max-width:320px!important;padding:0 9px!important}
#stories .custom-featured-slide>div{height:405px!important;border:1px solid rgba(215,226,210,.9)!important;border-radius:21px!important;box-shadow:0 8px 21px rgba(38,77,62,.08)!important;transition:transform .25s,box-shadow .25s!important}
#stories .custom-featured-slide>div:hover{transform:translateY(-5px);box-shadow:0 15px 28px rgba(38,77,62,.13)!important}
#stories .custom-featured-slide>div>div:first-child{height:185px!important}
#stories .section-title{font-size:1.55rem!important;color:var(--sq-ink)!important}
#stories .slider-container>div:first-child{padding:0 8px!important}
#stories .slider-container>div:first-child button{width:40px!important;height:40px!important}
@media(max-width:760px){.featured-section,.categories-section,.stories-section,.discovery-section{width:calc(100% - 22px)!important;margin:20px auto!important}.discovery-section{padding:20px 15px!important;border-radius:23px}#stories.featured-section{width:calc(100% - 22px)!important;padding:18px 10px!important;margin:22px auto!important;border-radius:24px!important}#stories .custom-featured-slide{flex-basis:285px!important;width:285px!important;max-width:285px!important;padding:0 6px!important}#stories .custom-featured-slide>div{height:390px!important}#stories .custom-featured-slide>div>div:first-child{height:170px!important}#stories .section-title{font-size:1.15rem!important}}
/* Discovery tiles */
.discovery-card{border-radius:23px!important;box-shadow:0 9px 25px rgba(41,75,62,.055)!important;transition:transform .23s,box-shadow .23s!important}
.discovery-card:hover{transform:translateY(-5px)!important;box-shadow:0 17px 32px rgba(41,75,62,.12)!important}
.age-card{min-height:230px!important}
.age-card .discovery-card-icon{box-shadow:0 7px 16px rgba(37,77,73,.12)}
.genre-card{min-height:105px!important;border:1px solid var(--sq-line)!important;background:var(--sq-paper)!important}
.genre-card:hover{border-color:var(--tile-accent)!important}
/* Monthly top stories */
.monthly-top-inner{border-radius:30px!important;box-shadow:0 14px 38px rgba(85,69,24,.07)!important}
.monthly-story-card{border-radius:22px!important;box-shadow:0 9px 25px rgba(43,76,65,.075)!important}
/* Story cards, /stories and taxonomy */
.stories-grid,.seo-story-grid{align-items:stretch!important;gap:22px!important}
.seo-static-main{max-width:1240px!important;margin:105px auto 50px!important;padding:0 22px!important}
.seo-static-hero{position:relative;overflow:hidden;background:linear-gradient(120deg,#e0f2e6 0%,#fff8e8 52%,#f1edff 100%)!important;border:1px solid #e7eadf!important;border-radius:30px!important;padding:38px clamp(20px,4vw,54px)!important;text-align:right!important;box-shadow:0 12px 32px rgba(43,76,65,.06)!important}
.seo-static-hero::after{content:'✦';position:absolute;left:32px;bottom:18px;font-size:4rem;color:rgba(201,154,50,.19)}
.seo-static-hero h1{font-size:clamp(1.9rem,3vw,2.8rem)!important;font-weight:950!important;color:#254d49!important}
.seo-static-hero p{margin:0!important;max-width:820px!important;color:#586e66!important;line-height:2.1!important}
body.dark-mode .seo-static-hero,body.dark-theme .seo-static-hero{background:linear-gradient(120deg,#263d32,#302e26 52%,#2c2940)!important;border-color:#3a4b41!important}
body.dark-mode .seo-static-hero h1,body.dark-theme .seo-static-hero h1{color:#f1f7ee!important}body.dark-mode .seo-static-hero p,body.dark-theme .seo-static-hero p{color:#c1d4c8!important}
.seo-info-card{border-radius:24px!important;border-color:var(--sq-line)!important;box-shadow:0 8px 25px rgba(43,76,65,.045)!important}
.seo-link-grid a{border-radius:14px!important;background:var(--sq-paper)!important;border-color:var(--sq-line)!important}
.seo-static-main .seo-story-grid .seo-story-card{width:100%!important;max-width:none!important;min-width:0!important;border:1px solid var(--sq-line)!important;border-radius:23px!important;overflow:hidden!important;background:var(--sq-paper)!important;box-shadow:0 10px 25px rgba(43,76,65,.065)!important;transition:transform .22s,box-shadow .22s!important}
.seo-static-main .seo-story-grid .seo-story-card:hover{transform:translateY(-4px)!important;box-shadow:0 17px 32px rgba(43,76,65,.13)!important}
.seo-static-main .seo-story-grid .seo-story-card .story-header{height:190px!important;aspect-ratio:auto!important;background-color:#f4eee2}
.seo-static-main .seo-story-grid .seo-story-card .story-body,.seo-static-main .seo-story-grid .seo-story-card> a>div:last-child{background:var(--sq-paper)!important;padding:17px 18px!important}
.seo-static-main .seo-story-grid .seo-story-card h3{font-size:1.1rem!important;line-height:1.7!important;color:var(--sq-ink)!important}
.seo-static-main .seo-story-grid .seo-story-card .story-summary{min-height:3.4em;line-height:1.85!important;display:-webkit-box;-webkit-line-clamp:2;-webkit-box-orient:vertical;overflow:hidden}
.story-tags{gap:7px!important;flex-wrap:wrap!important}
.story-tag{border-radius:99px!important;padding:5px 10px!important;font-size:.76rem!important;font-weight:800!important}
.story-tag.age{background:#fff0d4!important;color:#946b16!important}.story-tag.genre{background:#eae7ff!important;color:#6552b5!important}
body.dark-mode .story-tag.age,body.dark-theme .story-tag.age{background:#453920!important;color:#f3d78c!important}body.dark-mode .story-tag.genre,body.dark-theme .story-tag.genre{background:#342f4e!important;color:#d4caff!important}
/* Reader: quiet book-like surface inspired by story reading products */
.story-page{max-width:1050px!important;margin:105px auto 44px!important;padding:0 22px!important}
.story-page .seo-breadcrumb{max-width:100%!important;padding:0 3px!important;margin:0 0 16px!important;color:var(--sq-muted)!important}
.story-page .seo-breadcrumb a{color:var(--sq-ink-2)!important}
.top-buttons{display:flex!important;gap:9px!important;justify-content:flex-start!important;margin:0 0 14px!important}
.top-buttons button{width:42px!important;height:42px!important;border:1px solid var(--sq-line)!important;background:var(--sq-paper)!important;color:var(--sq-ink)!important;border-radius:14px!important;box-shadow:0 5px 14px rgba(43,76,65,.05)!important}
.story-hero{display:grid!important;grid-template-columns:minmax(220px,.75fr) minmax(0,1.25fr)!important;align-items:center!important;gap:28px!important;background:linear-gradient(120deg,#e1f3e7,#fff8e8 72%)!important;border:1px solid #e3eadc!important;border-radius:30px!important;padding:24px!important;box-shadow:0 12px 33px rgba(43,76,65,.06)!important;margin-bottom:22px!important;overflow:hidden}
.story-hero-img{height:245px!important;min-height:220px!important;border-radius:23px!important;background-color:#efe8d6!important;background-size:cover!important;background-position:center!important;box-shadow:0 10px 22px rgba(49,65,48,.1)!important}
.story-hero-info{text-align:right!important;padding:5px 0!important;align-items:flex-start!important}
.story-hero-title{font-size:clamp(1.8rem,3.4vw,2.7rem)!important;line-height:1.45!important;color:#28554c!important;font-weight:950!important;margin:0 0 12px!important}
.story-hero-summary{font-size:1rem!important;line-height:2!important;color:#63776f!important;margin:12px 0 0!important;max-width:620px}
body.dark-mode .story-hero,body.dark-theme .story-hero{background:linear-gradient(120deg,#243b31,#302e27 72%)!important;border-color:#3a4a40!important}
body.dark-mode .story-hero-title,body.dark-theme .story-hero-title{color:#f0f7ed!important}body.dark-mode .story-hero-summary,body.dark-theme .story-hero-summary{color:#c0d1c7!important}
.story-content-card{background:var(--sq-paper)!important;border:1px solid var(--sq-line)!important;border-radius:28px!important;padding:clamp(22px,4vw,54px)!important;box-shadow:0 13px 35px rgba(43,76,65,.055)!important}
.story-view-content{max-width:770px!important;margin:0 auto!important;font-size:1.13rem!important;line-height:2.5!important;color:var(--sq-ink)!important;text-align:justify!important;overflow-wrap:anywhere}
.story-view-content p{margin:0 0 1.45em!important}
.story-view-content img{max-width:100%!important;height:auto!important;border-radius:20px!important;box-shadow:0 12px 25px rgba(43,76,65,.1)!important;margin:1.7rem auto!important}
.review-item{background:var(--sq-paper)!important;border:1px solid var(--sq-line)!important;border-radius:18px!important;padding:18px!important;margin:12px 0!important}
.review-textarea{border:1px solid var(--sq-line)!important;border-radius:15px!important;background:var(--sq-paper)!important;color:var(--sq-ink)!important;min-height:120px}
.story-page .seo-related-stories{max-width:none!important;padding:0!important;margin:24px 0!important}
.story-page .seo-related-card{border-radius:18px!important;box-shadow:0 8px 20px rgba(43,76,65,.055)}
@media(max-width:760px){.story-page{margin:88px auto 28px!important;padding:0 11px!important}.story-hero{grid-template-columns:1fr!important;gap:15px!important;padding:14px!important;border-radius:22px!important}.story-hero-img{height:205px!important;min-height:190px!important;border-radius:17px!important;order:0}.story-hero-info{order:1;padding:5px 3px 8px!important}.story-hero-title{font-size:1.7rem!important}.story-hero-summary{font-size:.9rem!important}.story-content-card{padding:22px 17px!important;border-radius:22px!important}.story-view-content{font-size:1rem!important;line-height:2.25!important;text-align:right!important}.story-view-content img{border-radius:14px!important}.seo-static-main{margin-top:89px!important;padding:0 12px!important}.seo-static-hero{border-radius:23px!important;padding:27px 20px!important}.seo-static-main .seo-story-grid{grid-template-columns:repeat(2,minmax(0,1fr))!important;gap:12px!important}.seo-static-main .seo-story-grid .seo-story-card .story-header{height:125px!important}.seo-static-main .seo-story-grid .seo-story-card .story-body{padding:12px!important}.seo-static-main .seo-story-grid .seo-story-card h3{font-size:.95rem!important}.seo-static-main .seo-story-grid .seo-story-card .story-summary{font-size:.78rem!important}.seo-static-main .seo-story-grid .seo-story-card .story-tag{font-size:.65rem!important;padding:4px 7px!important}}
@media(max-width:420px){.seo-static-main .seo-story-grid{grid-template-columns:1fr!important}.seo-static-main .seo-story-grid .story-header{height:170px!important}}
/* Footer — three-column information architecture */
.footer,.seo-static-footer,.seo-ssr-footer{margin-top:48px!important;background:linear-gradient(135deg,#254d49 0%,#2d6556 60%,#3b7868 100%)!important;color:#f6fbf5!important;padding:0!important;text-align:right!important;border-radius:30px 30px 0 0;overflow:hidden}
.footer-content{max-width:1240px!important;margin:0 auto!important;padding:38px 25px 20px!important;display:grid!important;grid-template-columns:1.25fr .8fr .8fr!important;gap:28px!important;text-align:right!important}
.footer-brand-mark{display:flex;align-items:center;gap:12px;font-weight:950;font-size:1.25rem;margin-bottom:12px}.footer-brand-mark img{width:48px;height:48px;background:#fff6dc;padding:4px;border-radius:16px}
.footer .footer-icon{display:none!important}.footer .footer-text{color:#d7e9df!important;line-height:2!important;max-width:380px;margin:0!important;font-size:.9rem}
.footer-col-title{font-size:1rem;font-weight:900;color:#fff4cf;margin:0 0 13px}.footer-links{display:flex!important;flex-direction:column!important;gap:8px!important;align-items:flex-start!important;justify-content:flex-start!important}
.footer-link{color:#e5f2e9!important;text-decoration:none!important;font-size:.9rem;padding:3px 0;transition:color .2s,transform .2s}.footer-link:hover{color:#ffe08b!important;transform:translateX(-2px)}
.footer-bottom{max-width:1240px;margin:0 auto;border-top:1px solid rgba(255,255,255,.18);padding:14px 25px 18px;color:#c6dfd2;font-size:.78rem;display:flex;justify-content:space-between;gap:12px;flex-wrap:wrap}
body.dark-mode .footer,body.dark-theme .footer{background:linear-gradient(135deg,#132a26,#1a3930 65%,#203b34)!important}
@media(max-width:700px){.footer{border-radius:22px 22px 0 0}.footer-content{grid-template-columns:1fr 1fr!important;padding:28px 20px 18px!important;gap:20px!important}.footer-brand-col{grid-column:1/-1}.footer-bottom{padding:13px 20px 20px;flex-direction:column}}
/* Shared standalone pages */
.page-shared-header{position:sticky;top:0;z-index:1100;display:flex;align-items:center;justify-content:space-between;gap:20px;padding:11px max(20px,calc((100vw - 1240px)/2));background:rgba(255,253,248,.92);backdrop-filter:blur(16px);border-bottom:1px solid var(--sq-line);box-shadow:0 5px 20px rgba(43,76,65,.05)}
.page-shared-brand{display:flex;align-items:center;gap:10px;color:var(--sq-ink);font-weight:950;text-decoration:none}.page-shared-brand img{width:42px;height:42px;object-fit:contain;background:var(--sq-mint);border-radius:14px;padding:3px}
.page-shared-nav{display:flex;gap:8px;flex-wrap:wrap}.page-shared-nav a{color:var(--sq-ink);text-decoration:none;font-weight:800;font-size:.88rem;padding:9px 13px;border-radius:12px}.page-shared-nav a:hover{background:var(--sq-mint)}
body.dark-mode .page-shared-header{background:rgba(28,39,36,.93)}
.standalone-footer{background:linear-gradient(135deg,#254d49,#367464);color:#e5f2e9;padding:28px 20px;text-align:center;margin-top:55px}.standalone-footer p{margin:0;color:#d6e8df;font-size:.86rem}.standalone-footer a{color:#ffe08b;font-weight:800;text-decoration:none;margin:0 8px}
.about-header{background:linear-gradient(120deg,#dff3e7,#fff8e5 60%,#efecff)!important;padding:47px 20px 40px!important;border-radius:0 0 34px 34px}
.about-header-icon{background:linear-gradient(135deg,#fff0c8,#d2f0df)!important;color:#28574c!important}
.about-container{max-width:1120px!important;margin:36px auto!important}
.about-card{border:1px solid var(--sq-line);border-radius:25px!important;box-shadow:0 12px 30px rgba(43,76,65,.055)!important}
.feature{border:1px solid #eceddf;background:linear-gradient(140deg,#fffaf0,#f2faf3)!important;border-radius:20px!important}
body.dark-mode .about-card,body.dark-mode .feature{background:var(--sq-paper)!important;border-color:var(--sq-line)!important}body.dark-mode .about-card p,body.dark-mode .feature p{color:var(--sq-muted)!important}
.page-static-main{max-width:1040px;margin:45px auto 60px;padding:0 22px}
.page-static-hero{background:linear-gradient(120deg,#e1f4e7,#fff7e6 64%,#eeeaff);border:1px solid var(--sq-line);border-radius:30px;padding:36px clamp(22px,4vw,50px);margin-bottom:22px;box-shadow:0 12px 30px rgba(43,76,65,.05)}
.page-static-hero .page-eyebrow{display:inline-block;padding:6px 11px;border-radius:99px;background:#fff0c8;color:#84651a;font-size:.8rem;font-weight:900;margin-bottom:10px}
.page-static-hero h1{font-size:clamp(1.8rem,4vw,2.6rem);font-weight:950;color:#254d49;margin:0 0 12px}.page-static-hero p{color:#5e7169;line-height:2;margin:0;max-width:760px}
.page-static-card{background:var(--sq-paper);border:1px solid var(--sq-line);box-shadow:0 10px 28px rgba(43,76,65,.045);border-radius:25px;padding:clamp(22px,4vw,40px);line-height:2.15;color:var(--sq-ink)}
.page-static-card h2{margin:0 0 12px;font-size:1.35rem}.page-static-card p{color:var(--sq-muted);line-height:2.1}
@media(max-width:700px){.page-shared-header{padding:9px 12px}.page-shared-nav{gap:2px}.page-shared-nav a{font-size:.76rem;padding:8px}.page-shared-brand span{display:none}.page-static-main{margin:28px auto 40px;padding:0 12px}.page-static-hero{border-radius:23px;padding:26px 20px}.page-static-card{border-radius:21px;padding:22px}}

.contact-method-card{display:flex;gap:16px;align-items:flex-start;margin-top:24px;padding:20px;border-radius:20px;border:1px solid var(--sq-line);background:linear-gradient(130deg,var(--sq-paper),rgba(223,243,231,.5))}.contact-method-icon{width:48px;height:48px;flex:0 0 48px;border-radius:16px;display:flex;align-items:center;justify-content:center;background:var(--sq-mint);color:#2e7561;font-size:1.2rem}.contact-method-card strong{font-size:1.05rem}.contact-method-card p{margin:4px 0 10px}.contact-return-link{display:inline-flex;gap:8px;align-items:center;text-decoration:none;color:var(--sq-ink);font-weight:900;background:var(--sq-mint);padding:9px 13px;border-radius:12px}


/* v12 stability and responsive refinements */
/* Mobile navigation: every item occupies its own row and menu scrolls independently. */
.mobile-menu {
  left: auto !important;
  right: 12px !important;
  width: min(320px, calc(100vw - 24px)) !important;
  max-height: calc(100dvh - 100px) !important;
  overflow-y: auto !important;
  overflow-x: hidden !important;
  overscroll-behavior: contain;
  padding: 8px !important;
  box-sizing: border-box !important;
}
.mobile-menu-item {
  display: flex !important;
  align-items: center !important;
  width: 100% !important;
  min-height: 46px !important;
  height: auto !important;
  flex: 0 0 auto !important;
  white-space: normal !important;
  line-height: 1.65 !important;
  box-sizing: border-box !important;
  position: relative !important;
  margin: 0 !important;
  border-radius: 11px !important;
}
.mobile-user-box { display:block!important; width:100%!important; box-sizing:border-box!important; margin-top:8px!important; }
.mobile-user-header { display:flex!important; align-items:center!important; gap:10px!important; width:100%!important; min-height:60px!important; box-sizing:border-box!important; }
.mobile-profile-menu { display:none!important; width:100%!important; position:static!important; }
.mobile-profile-menu.show { display:block!important; }
.mobile-profile-menu .mobile-menu-item { min-height:42px!important; }

/* Newest stories carousel: cards fit the available mobile width; controls never shrink into ovals. */
#stories.featured-section { overflow:hidden!important; }
#stories .slider-container { width:100%!important; min-width:0!important; overflow:hidden!important; }
#stories .slider { width:100%!important; min-width:0!important; max-width:100%!important; overflow-x:auto!important; overflow-y:hidden!important; display:flex!important; flex-wrap:nowrap!important; gap:0!important; scroll-snap-type:x mandatory!important; scrollbar-width:thin; overscroll-behavior-x:contain; }
#stories .custom-featured-slide { flex:0 0 340px!important; width:340px!important; max-width:340px!important; min-width:0!important; padding:0 8px!important; box-sizing:border-box!important; scroll-snap-align:start!important; }
#stories .featured-story-card { display:flex!important; flex-direction:column!important; width:100%!important; height:100%!important; min-width:0!important; min-height:380px!important; overflow:hidden!important; border-radius:21px!important; border:1px solid var(--sq-line)!important; background:var(--sq-paper)!important; color:var(--sq-ink)!important; text-decoration:none!important; box-shadow:0 8px 21px rgba(38,77,62,.08)!important; transition:transform .22s,box-shadow .22s!important; }
#stories .featured-story-card:hover { transform:translateY(-4px)!important; box-shadow:0 15px 28px rgba(38,77,62,.13)!important; }
#stories .featured-story-cover { position:relative!important; flex:0 0 185px!important; height:185px!important; width:100%!important; overflow:hidden!important; background:#eee8d8!important; }
#stories .featured-story-cover img { display:block!important; width:100%!important; height:100%!important; object-fit:cover!important; }
#stories .featured-premium-badge { position:absolute!important; top:10px!important; left:10px!important; background:#ffdf83!important; color:#624a0c!important; border-radius:99px!important; padding:5px 9px!important; font-size:.75rem!important; font-weight:900!important; }
#stories .featured-story-body { flex:1 1 auto!important; min-width:0!important; display:flex!important; flex-direction:column!important; justify-content:space-between!important; gap:12px!important; padding:16px!important; background:var(--sq-paper)!important; box-sizing:border-box!important; }
#stories .featured-story-main { min-width:0!important; }
#stories .featured-story-main h3 { color:var(--sq-ink)!important; font-size:1.12rem!important; line-height:1.7!important; font-weight:900!important; margin:0 0 8px!important; }
#stories .featured-story-summary { color:var(--sq-muted)!important; font-size:.87rem!important; line-height:1.75!important; margin:9px 0 0!important; display:-webkit-box!important; -webkit-line-clamp:2!important; -webkit-box-orient:vertical!important; overflow:hidden!important; }
#stories .featured-story-rating { display:flex!important; align-items:center!important; gap:8px!important; width:100%!important; padding-top:10px!important; border-top:1px dashed var(--sq-line)!important; box-sizing:border-box!important; }
#stories .featured-story-stars { display:inline-flex!important; gap:2px!important; color:#d7d7d0!important; }
#stories .featured-story-stars .filled { color:#e0ad31!important; }
#stories .featured-review-count { margin-right:auto!important; color:var(--sq-muted)!important; font-size:.77rem!important; }
#stories .featured-heading { display:flex!important; justify-content:space-between!important; align-items:center!important; gap:14px!important; padding:0 8px!important; margin:0 0 18px!important; direction:rtl!important; }
#stories .featured-heading .section-title { margin:0!important; min-width:0!important; line-height:1.5!important; }
#stories .featured-actions { display:flex!important; align-items:center!important; justify-content:flex-start!important; flex:0 0 auto!important; gap:8px!important; direction:ltr!important; min-width:0!important; }
#stories .featured-all-link { display:inline-flex!important; align-items:center!important; justify-content:center!important; flex:0 0 auto!important; min-height:40px!important; padding:0 12px!important; border-radius:13px!important; background:var(--sq-paper)!important; border:1px solid var(--sq-line)!important; color:var(--sq-ink)!important; text-decoration:none!important; font-size:.82rem!important; font-weight:800!important; white-space:nowrap!important; }
#stories .featured-empty { text-align:center; padding:2rem; }
@media (max-width:760px) {
  #stories .featured-heading { align-items:flex-start!important; flex-direction:column!important; gap:12px!important; }
  #stories .featured-heading .section-title { width:100%!important; font-size:1.25rem!important; white-space:normal!important; }
  #stories .featured-actions { width:100%!important; gap:8px!important; }
  #stories .featured-all-link { min-height:38px!important; font-size:.78rem!important; }
  #stories .custom-featured-slide { flex:0 0 100%!important; width:100%!important; max-width:100%!important; padding:0 5px!important; }
  #stories .featured-story-card { min-height:375px!important; }
  #stories .featured-story-cover { flex-basis:178px!important; height:178px!important; }
  #stories .featured-story-body { padding:14px!important; }
}

/* Monthly ranking: compact horizontal rows on desktop/tablet, preserve the well-liked mobile cards. */
@media (min-width:641px) {
  .monthly-ranking-grid { grid-template-columns:minmax(0,1fr)!important; max-width:860px!important; margin:0 auto!important; gap:12px!important; }
  .monthly-story-card { display:grid!important; grid-template-columns:170px minmax(0,1fr)!important; min-height:142px!important; border-radius:18px!important; }
  .monthly-story-cover { height:100%!important; min-height:142px!important; }
  .monthly-story-info { min-width:0!important; padding:13px 17px!important; }
  .monthly-story-info h3 { font-size:1.02rem!important; margin-bottom:4px!important; }
  .monthly-story-info p { min-height:0!important; -webkit-line-clamp:2!important; font-size:.8rem!important; line-height:1.7!important; }
  .monthly-story-score { margin-top:8px!important; padding-top:8px!important; }
  .monthly-read-link { margin-top:7px!important; }
  .monthly-story-skeleton { display:grid!important; grid-template-columns:170px minmax(0,1fr)!important; align-items:start!important; min-height:142px!important; }
  .monthly-story-skeleton span:first-child { height:112px!important; grid-row:1/4!important; }
}

/* Shared static-page header: aligned theme control and a real mobile menu. */
.page-shared-header { position:sticky!important; top:0!important; z-index:1200!important; overflow:visible!important; min-height:64px!important; box-sizing:border-box!important; }
.page-header-actions { display:flex!important; align-items:center!important; gap:8px!important; flex:0 0 auto!important; }
.page-theme-toggle,.page-mobile-nav-toggle { appearance:none!important; display:inline-flex!important; align-items:center!important; justify-content:center!important; flex:0 0 42px!important; width:42px!important; min-width:42px!important; height:42px!important; padding:0!important; border:1px solid var(--sq-line)!important; border-radius:50%!important; background:var(--sq-mint)!important; color:var(--sq-ink)!important; box-shadow:0 5px 14px rgba(43,76,65,.08)!important; font:inherit!important; font-size:1rem!important; cursor:pointer!important; line-height:1!important; }
.page-theme-toggle i,.page-mobile-nav-toggle i { pointer-events:none!important; }
.page-mobile-nav-toggle { display:none!important; }
.page-shared-nav { align-items:center!important; }
.page-shared-nav a { display:inline-flex!important; align-items:center!important; justify-content:center!important; min-height:40px!important; white-space:nowrap!important; }
.page-shared-nav .page-theme-toggle { margin-inline-start:4px!important; }
body.dark-mode .page-shared-nav a { color:var(--sq-ink)!important; }
body.dark-mode .page-static-hero, body.dark-mode .about-header { background:linear-gradient(120deg,#263d32,#302e26 58%,#2b2940)!important; border-color:var(--sq-line)!important; }
body.dark-mode .about-header h1,body.dark-mode .page-static-hero h1 { color:var(--sq-ink)!important; }
body.dark-mode .about-header p,body.dark-mode .page-static-hero p { color:var(--sq-muted)!important; }
body.dark-mode .about-card,body.dark-mode .feature,body.dark-mode .page-static-card { background:var(--sq-paper)!important; color:var(--sq-ink)!important; border-color:var(--sq-line)!important; }
body.dark-mode .about-card h2,body.dark-mode .about-card p,body.dark-mode .feature h3,body.dark-mode .feature p,body.dark-mode .page-static-card p { color:var(--sq-muted)!important; }
@media(max-width:700px) {
  .page-shared-header { display:flex!important; flex-wrap:nowrap!important; justify-content:space-between!important; align-items:center!important; gap:10px!important; padding:8px 12px!important; }
  .page-shared-brand { min-width:0!important; flex:1 1 auto!important; gap:8px!important; font-size:.98rem!important; }
  .page-shared-brand span { display:inline!important; white-space:nowrap!important; }
  .page-shared-brand img { flex:0 0 38px!important; width:38px!important; height:38px!important; }
  .page-header-actions { margin-inline-start:auto!important; }
  .page-theme-toggle,.page-mobile-nav-toggle { flex-basis:38px!important; width:38px!important; min-width:38px!important; height:38px!important; }
  .page-mobile-nav-toggle { display:inline-flex!important; }
  .page-shared-nav { display:none!important; position:absolute!important; top:calc(100% + 7px)!important; right:12px!important; left:12px!important; width:auto!important; max-height:calc(100dvh - 100px)!important; overflow:auto!important; flex-direction:column!important; align-items:stretch!important; gap:3px!important; padding:9px!important; border:1px solid var(--sq-line)!important; border-radius:18px!important; background:var(--sq-paper)!important; box-shadow:var(--sq-shadow)!important; }
  .page-shared-nav.is-open { display:flex!important; }
  .page-shared-nav a { justify-content:flex-start!important; width:100%!important; box-sizing:border-box!important; min-height:43px!important; padding:10px 13px!important; white-space:normal!important; border-radius:11px!important; }
  .page-static-main { margin-top:26px!important; }
  .about-header { padding:32px 18px 30px!important; border-radius:0 0 25px 25px!important; }
  .about-header-icon { width:82px!important; height:82px!important; font-size:34px!important; margin-bottom:17px!important; }
  .about-header h1 { font-size:1.7rem!important; line-height:1.55!important; }
  .about-header p { font-size:.95rem!important; }
  .about-container { padding:0 13px!important; margin:25px auto!important; }
  .about-card { padding:22px 19px!important; border-radius:21px!important; }
  .features { grid-template-columns:repeat(2,minmax(0,1fr))!important; gap:11px!important; }
  .feature { min-width:0!important; padding:17px 12px!important; }
  .feature i { font-size:27px!important; }
  .quote { padding:30px 17px!important; font-size:1.05rem!important; }
  .back-btn { padding:11px 17px!important; border-radius:14px!important; }
}


/* ==========================================================
   v13 — Unified modern header and resilient story hero
   ========================================================== */
:root { --sq-header-height: 78px; }
html { scroll-padding-top: calc(var(--sq-header-height) + 14px); }

/* Main SPA / server-rendered header */
body #app > header.header {
  position: fixed !important;
  inset: 0 0 auto 0 !important;
  z-index: 1400 !important;
  width: 100% !important;
  min-height: var(--sq-header-height) !important;
  box-sizing: border-box !important;
  padding: 9px clamp(12px, 2.7vw, 34px) !important;
  background: rgba(255, 253, 248, .94) !important;
  border: 0 !important;
  border-bottom: 1px solid rgba(209, 224, 213, .78) !important;
  border-radius: 0 !important;
  box-shadow: 0 8px 28px rgba(35, 77, 67, .075) !important;
  backdrop-filter: blur(18px) saturate(135%) !important;
  -webkit-backdrop-filter: blur(18px) saturate(135%) !important;
  overflow: visible !important;
}
body.dark-mode #app > header.header,
body.dark-theme #app > header.header {
  background: rgba(27, 40, 36, .94) !important;
  border-bottom-color: rgba(180, 220, 198, .13) !important;
  box-shadow: 0 8px 28px rgba(0, 0, 0, .2) !important;
}
body #app > header.header .header-container {
  display: flex !important;
  flex-direction: row !important;
  justify-content: space-between !important;
  align-items: center !important;
  gap: clamp(12px, 2vw, 28px) !important;
  width: 100% !important;
  max-width: 1320px !important;
  min-height: 58px !important;
  margin: 0 auto !important;
  padding: 0 !important;
  box-sizing: border-box !important;
  flex-wrap: nowrap !important;
}
body #app > header.header .header-brand {
  display: inline-flex !important;
  flex: 0 0 auto !important;
  align-items: center !important;
  justify-content: flex-start !important;
  gap: 10px !important;
  min-width: 0 !important;
  color: var(--sq-ink) !important;
  text-decoration: none !important;
  direction: rtl !important;
}
body #app > header.header .logo {
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
  flex: 0 0 48px !important;
  width: 48px !important;
  height: 48px !important;
  max-height: 48px !important;
  margin: 0 !important;
  padding: 3px !important;
  box-sizing: border-box !important;
  border: 1px solid rgba(197, 221, 202, .7) !important;
  border-radius: 16px !important;
  background: linear-gradient(145deg, #fff4d1, #d8f2e1) !important;
  box-shadow: 0 5px 14px rgba(36, 86, 67, .1) !important;
  overflow: hidden !important;
}
body #app > header.header .logo img,
body #app > header.header .logo .header-logo-light,
body #app > header.header .logo .header-logo-dark {
  display: block !important;
  width: 100% !important;
  height: 100% !important;
  max-width: 100% !important;
  max-height: 100% !important;
  object-fit: contain !important;
}
body #app > header.header .header-brand-copy {
  display: flex !important;
  flex-direction: column !important;
  align-items: flex-start !important;
  gap: 1px !important;
  min-width: 0 !important;
  line-height: 1.45 !important;
  white-space: nowrap !important;
}
body #app > header.header .header-brand-copy strong {
  color: var(--sq-ink) !important;
  font-size: 1.08rem !important;
  font-weight: 950 !important;
  letter-spacing: -.025em !important;
}
body #app > header.header .header-brand-copy small {
  color: var(--sq-muted) !important;
  font-size: .68rem !important;
  font-weight: 600 !important;
}
body.dark-mode #app > header.header .header-brand-copy strong,
body.dark-theme #app > header.header .header-brand-copy strong { color: var(--sq-ink) !important; }
body #app > header.header .header-nav {
  position: static !important;
  top: auto !important;
  right: auto !important;
  transform: none !important;
  display: flex !important;
  flex: 1 1 auto !important;
  justify-content: center !important;
  align-items: center !important;
  gap: clamp(3px, .65vw, 10px) !important;
  min-width: 0 !important;
  margin: 0 !important;
  padding: 0 !important;
}
body #app > header.header .nav-simple-btn,
body #app > header.header .nav-btn {
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  gap: 7px !important;
  min-height: 42px !important;
  height: 42px !important;
  margin: 0 !important;
  padding: 0 12px !important;
  border: 1px solid transparent !important;
  border-radius: 13px !important;
  background: transparent !important;
  color: var(--sq-ink) !important;
  font-family: inherit !important;
  font-size: .88rem !important;
  font-weight: 800 !important;
  line-height: 1.4 !important;
  white-space: nowrap !important;
  text-decoration: none !important;
  cursor: pointer !important;
  transition: background .18s ease, border-color .18s ease, transform .18s ease !important;
}
body #app > header.header .nav-simple-btn:hover,
body #app > header.header .nav-btn:hover,
body #app > header.header .nav-dropdown:focus-within > .nav-btn {
  background: #e8f6ed !important;
  border-color: #d5eadb !important;
  color: #24564b !important;
}
body.dark-mode #app > header.header .nav-simple-btn,
body.dark-mode #app > header.header .nav-btn,
body.dark-theme #app > header.header .nav-simple-btn,
body.dark-theme #app > header.header .nav-btn { color: var(--sq-ink) !important; }
body.dark-mode #app > header.header .nav-simple-btn:hover,
body.dark-mode #app > header.header .nav-btn:hover,
body.dark-theme #app > header.header .nav-simple-btn:hover,
body.dark-theme #app > header.header .nav-btn:hover { background: #2c463b !important; border-color: #3a5d4e !important; }
body #app > header.header .nav-dropdown {
  position: relative !important;
  display: flex !important;
  align-items: center !important;
  height: auto !important;
  padding: 0 !important;
  margin: 0 !important;
}
body #app > header.header .nav-dropdown-content {
  top: 100% !important;
  right: 0 !important;
  min-width: 195px !important;
  max-height: min(65vh, 480px) !important;
  overflow: auto !important;
  padding: 7px !important;
  border: 1px solid var(--sq-line) !important;
  border-radius: 16px !important;
  background: var(--sq-paper) !important;
  box-shadow: 0 18px 40px rgba(25, 63, 51, .15) !important;
}
body #app > header.header .nav-dropdown:hover .nav-dropdown-content,
body #app > header.header .nav-dropdown:focus-within .nav-dropdown-content { display: block !important; }
body #app > header.header .nav-dropdown-content a {
  display: flex !important;
  align-items: center !important;
  min-height: 39px !important;
  padding: 8px 12px !important;
  border-radius: 10px !important;
  color: var(--sq-ink) !important;
  font-size: .84rem !important;
  text-decoration: none !important;
}
body #app > header.header .nav-dropdown-content a:hover { background: var(--sq-mint) !important; }
body #app > header.header .header-actions {
  display: flex !important;
  align-items: center !important;
  justify-content: flex-start !important;
  flex: 0 0 auto !important;
  flex-wrap: nowrap !important;
  gap: 8px !important;
  min-width: 0 !important;
  margin: 0 !important;
}
body #app > header.header .header-icon-btn,
body #app > header.header .mobile-menu-btn {
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  flex: 0 0 42px !important;
  width: 42px !important;
  min-width: 42px !important;
  height: 42px !important;
  min-height: 42px !important;
  padding: 0 !important;
  border: 1px solid var(--sq-line) !important;
  border-radius: 14px !important;
  background: var(--sq-paper) !important;
  color: var(--sq-ink) !important;
  box-shadow: 0 4px 12px rgba(43, 76, 65, .055) !important;
  font-size: 1rem !important;
  cursor: pointer !important;
  line-height: 1 !important;
  transition: transform .18s ease, background .18s ease, box-shadow .18s ease !important;
}
body #app > header.header .header-icon-btn:hover,
body #app > header.header .mobile-menu-btn:hover { transform: translateY(-1px) !important; background: var(--sq-mint) !important; }
body #app > header.header .mobile-menu-btn { display: none !important; }
body #app > header.header .login-btn {
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  gap: 8px !important;
  min-height: 42px !important;
  padding: 0 15px !important;
  border: 1px solid #c6e7d2 !important;
  border-radius: 14px !important;
  background: linear-gradient(135deg, #dff4e6, #c8ecd7) !important;
  color: #24564b !important;
  box-shadow: 0 4px 12px rgba(44, 113, 83, .08) !important;
  font-family: inherit !important;
  font-size: .84rem !important;
  font-weight: 850 !important;
  white-space: nowrap !important;
  cursor: pointer !important;
}
body #app > header.header .login-btn:hover { transform: translateY(-1px) !important; box-shadow: 0 8px 17px rgba(44, 113, 83, .12) !important; }
body #app > header.header .user-menu { position: relative !important; flex: 0 0 auto !important; }
body #app > header.header .user-menu-btn {
  display: inline-flex !important; align-items: center !important; gap: 8px !important;
  min-height: 42px !important; padding: 4px 10px 4px 7px !important;
  border: 1px solid var(--sq-line) !important; border-radius: 14px !important;
  background: var(--sq-paper) !important; color: var(--sq-ink) !important;
  font-family: inherit !important; font-weight: 800 !important; cursor: pointer !important;
}
body #app > header.header .user-dropdown { top: calc(100% + 8px) !important; right: 0 !important; min-width: 205px !important; }
body #app > header.header .user-dropdown-item { display: flex !important; width: 100% !important; align-items: center !important; gap: 10px !important; box-sizing: border-box !important; border: 0 !important; background: transparent !important; font: inherit !important; text-align: right !important; cursor: pointer !important; }
body #app > header.header .mobile-menu {
  display: none !important;
  position: fixed !important;
  top: calc(var(--sq-header-height) + 8px) !important;
  right: 12px !important;
  left: 12px !important;
  width: min(380px, calc(100vw - 24px)) !important;
  max-width: calc(100vw - 24px) !important;
  max-height: calc(100dvh - var(--sq-header-height) - 22px) !important;
  overflow-x: hidden !important;
  overflow-y: auto !important;
  overscroll-behavior: contain !important;
  box-sizing: border-box !important;
  margin-inline-start: auto !important;
  padding: 8px !important;
  border: 1px solid var(--sq-line) !important;
  border-radius: 20px !important;
  background: rgba(255, 253, 248, .98) !important;
  box-shadow: 0 20px 48px rgba(32, 65, 54, .18) !important;
  backdrop-filter: blur(18px) !important;
  -webkit-backdrop-filter: blur(18px) !important;
}
body #app > header.header .mobile-menu.show { display: block !important; }
body.dark-mode #app > header.header .mobile-menu,
body.dark-theme #app > header.header .mobile-menu { background: rgba(31, 45, 40, .98) !important; border-color: var(--sq-line) !important; }
body #app > header.header .mobile-menu-item {
  display: flex !important;
  align-items: center !important;
  gap: 11px !important;
  width: 100% !important;
  min-height: 45px !important;
  box-sizing: border-box !important;
  padding: 10px 13px !important;
  margin: 0 !important;
  border: 0 !important;
  border-bottom: 1px solid rgba(220, 231, 219, .8) !important;
  border-radius: 11px !important;
  background: transparent !important;
  color: var(--sq-ink) !important;
  font-family: inherit !important;
  font-size: .9rem !important;
  font-weight: 750 !important;
  text-align: right !important;
  text-decoration: none !important;
  cursor: pointer !important;
}
body #app > header.header .mobile-menu-item:last-child { border-bottom: 0 !important; }
body #app > header.header .mobile-menu-item i { width: 20px !important; text-align: center !important; color: #498570 !important; }
body #app > header.header .mobile-menu-item:hover { background: #eaf6ee !important; }
body.dark-mode #app > header.header .mobile-menu-item,
body.dark-theme #app > header.header .mobile-menu-item { color: var(--sq-ink) !important; border-bottom-color: rgba(255,255,255,.07) !important; }
body.dark-mode #app > header.header .mobile-menu-item:hover,
body.dark-theme #app > header.header .mobile-menu-item:hover { background: #2a4439 !important; }
body #app > header.header .mobile-menu-login { margin-top: 6px !important; border: 1px solid #c6e7d2 !important; background: #e1f4e7 !important; }
body #app > header.header .mobile-menu-account { padding-top: 8px !important; }
body #app > header.header .mobile-menu-account-title { display:flex!important; align-items:center!important; gap:10px!important; padding:10px 12px 12px!important; color:var(--sq-ink)!important; }
body #app > header.header .mobile-menu-account-title > span:last-child { display:flex!important; flex-direction:column!important; gap:1px!important; }
body #app > header.header .mobile-menu-account-title small { color:var(--sq-muted)!important; font-size:.75rem!important; }
body #app > header.header .mobile-menu-account-title strong { font-size:.92rem!important; }

/* The story reading canvas is mint edge-to-edge, not mint inside a cream frame. */
body:has(#app > main.story-page) {
  background: #dff3e7 !important;
  background-image: none !important;
}
body.dark-mode:has(#app > main.story-page),
body.dark-theme:has(#app > main.story-page) {
  background: #1e3029 !important;
  background-image: none !important;
}

/* The page background stays mint; the story hero has no cream gradient break. */
body #app > main.story-page {
  display: block !important;
  width: 100% !important;
  max-width: 1050px !important;
  min-width: 0 !important;
  box-sizing: border-box !important;
  margin: calc(var(--sq-header-height) + 20px) auto 44px !important;
  padding: 0 clamp(12px, 2.1vw, 22px) !important;
  background: #dff3e7 !important;
  overflow: visible !important;
}
body.dark-mode #app > main.story-page,
body.dark-theme #app > main.story-page { background: #1e3029 !important; }
body #app > main.story-page .seo-breadcrumb {
  width: 100% !important; max-width: 100% !important; min-width: 0 !important;
  box-sizing: border-box !important; overflow-wrap: anywhere !important;
}
body #app > main.story-page .story-hero {
  display: grid !important;
  grid-template-columns: minmax(0, .9fr) minmax(0, 1.1fr) !important;
  align-items: center !important;
  gap: clamp(16px, 2.3vw, 28px) !important;
  width: 100% !important; max-width: 100% !important; min-width: 0 !important;
  box-sizing: border-box !important;
  padding: clamp(15px, 2.3vw, 25px) !important;
  border: 1px solid #cde8d5 !important;
  border-radius: 28px !important;
  background: #e7f6eb !important;
  box-shadow: 0 12px 30px rgba(43, 76, 65, .045) !important;
  overflow: hidden !important;
}
body.dark-mode #app > main.story-page .story-hero,
body.dark-theme #app > main.story-page .story-hero { background: #263d32 !important; border-color: #385246 !important; }
body #app > main.story-page .story-hero > * { min-width: 0 !important; max-width: 100% !important; box-sizing: border-box !important; }
body #app > main.story-page .story-hero-img {
  display: block !important; width: 100% !important; max-width: 100% !important;
  min-width: 0 !important; height: auto !important; aspect-ratio: 16 / 10 !important;
  min-height: 0 !important; max-height: 300px !important; box-sizing: border-box !important;
  border-radius: 22px !important; background-size: cover !important; background-position: center !important;
  overflow: hidden !important;
}
body #app > main.story-page .story-hero-info {
  display: flex !important; flex-direction: column !important; align-items: stretch !important;
  justify-content: center !important; width: 100% !important; max-width: 100% !important;
  min-width: 0 !important; padding: 3px 0 !important; text-align: right !important;
  overflow-wrap: anywhere !important; word-break: normal !important;
}
body #app > main.story-page .story-title-row {
  display: flex !important; align-items: flex-start !important; justify-content: flex-start !important;
  gap: 10px !important; width: 100% !important; max-width: 100% !important; min-width: 0 !important;
  box-sizing: border-box !important; margin: 0 0 12px !important;
}
body #app > main.story-page .story-hero-title {
  flex: 0 1 auto !important; min-width: 0 !important; max-width: calc(100% - 54px) !important;
  margin: 0 !important; color: #28554c !important;
  font-size: clamp(1.55rem, 3.3vw, 2.55rem) !important;
  line-height: 1.55 !important; font-weight: 950 !important;
  overflow-wrap: anywhere !important; word-break: normal !important;
}
body.dark-mode #app > main.story-page .story-hero-title,
body.dark-theme #app > main.story-page .story-hero-title { color: #eef8ef !important; }
body #app > main.story-page .story-tags { display:flex!important; flex-wrap:wrap!important; gap:7px!important; width:100%!important; max-width:100%!important; min-width:0!important; justify-content:flex-start!important; }
body #app > main.story-page .story-hero-summary {
  width: 100% !important; max-width: 100% !important; min-width: 0 !important;
  margin: 12px 0 0 !important; color: #587269 !important;
  font-size: clamp(.9rem, 1.25vw, 1rem) !important; line-height: 2 !important;
  overflow-wrap: anywhere !important; word-break: normal !important;
}
body.dark-mode #app > main.story-page .story-hero-summary,
body.dark-theme #app > main.story-page .story-hero-summary { color: #c0d1c7 !important; }
body #app > main.story-page .story-favorite-btn {
  display: inline-flex !important; align-items: center !important; justify-content: center !important;
  flex: 0 0 42px !important; width: 42px !important; min-width: 42px !important;
  height: 42px !important; min-height: 42px !important; margin: 2px 0 0 !important; padding: 0 !important;
  border: 1px solid #d4e7d8 !important; border-radius: 14px !important;
  background: rgba(255, 253, 248, .9) !important; color: #315e51 !important;
  box-shadow: 0 5px 13px rgba(43,76,65,.06) !important; cursor: pointer !important;
  transition: transform .18s ease, background .18s ease !important;
}
body #app > main.story-page .story-favorite-btn:hover { transform: translateY(-2px) !important; background: #fff !important; }
body #app > main.story-page .story-favorite-btn .fas.fa-heart { color: #e45e78 !important; }
body #app > main.story-page .story-favorite-btn .far.fa-heart { color: #426d5f !important; }
body #app > main.story-page .story-content-card {
  width: 100% !important; max-width: 100% !important; min-width: 0 !important;
  box-sizing: border-box !important; margin: 22px 0 0 !important;
  background: var(--sq-paper) !important; border-color: var(--sq-line) !important;
}
body #app > main.story-page .story-view-content { min-width: 0 !important; overflow-wrap: anywhere !important; }
body #app > main.story-page .top-buttons { display: none !important; }

/* The static information pages use the same glassy header language. */
html body header.page-shared-header {
  position: sticky !important; top: 0 !important; z-index: 1400 !important;
  display: flex !important; flex-direction: row !important; align-items: center !important;
  justify-content: space-between !important; gap: clamp(12px, 2vw, 26px) !important;
  width: 100% !important; min-height: var(--sq-header-height) !important;
  box-sizing: border-box !important; padding: 9px clamp(12px, 2.7vw, 34px) !important;
  background: rgba(255,253,248,.94) !important; border: 0 !important;
  border-bottom: 1px solid rgba(209,224,213,.78) !important;
  box-shadow: 0 8px 28px rgba(35,77,67,.075) !important;
  backdrop-filter: blur(18px) saturate(135%) !important;
  -webkit-backdrop-filter: blur(18px) saturate(135%) !important;
}
html body.dark-mode header.page-shared-header { background: rgba(27,40,36,.94) !important; border-bottom-color: rgba(180,220,198,.13) !important; }
html body header.page-shared-header .page-shared-brand { display:inline-flex!important;align-items:center!important;gap:10px!important;flex:0 0 auto!important;color:var(--sq-ink)!important;text-decoration:none!important; }
html body header.page-shared-header .page-shared-brand img { width:48px!important;height:48px!important;flex:0 0 48px!important;box-sizing:border-box!important;object-fit:contain!important;padding:3px!important;border:1px solid rgba(197,221,202,.7)!important;border-radius:16px!important;background:linear-gradient(145deg,#fff4d1,#d8f2e1)!important;box-shadow:0 5px 14px rgba(36,86,67,.1)!important; }
html body header.page-shared-header .page-shared-brand span { display:inline!important;color:var(--sq-ink)!important;font-size:1.08rem!important;font-weight:950!important;white-space:nowrap!important; }
html body header.page-shared-header .page-shared-nav { display:flex!important;flex:1 1 auto!important;align-items:center!important;justify-content:center!important;gap:clamp(2px,.6vw,9px)!important;min-width:0!important; }
html body header.page-shared-header .page-shared-nav a { display:inline-flex!important;align-items:center!important;justify-content:center!important;min-height:42px!important;padding:0 12px!important;border:1px solid transparent!important;border-radius:13px!important;color:var(--sq-ink)!important;font-size:.86rem!important;font-weight:800!important;text-decoration:none!important;white-space:nowrap!important;transition:background .18s ease,border-color .18s ease!important; }
html body header.page-shared-header .page-shared-nav a:hover { background:#e8f6ed!important;border-color:#d5eadb!important; }
html body header.page-shared-header .page-header-actions { display:flex!important;align-items:center!important;gap:8px!important;flex:0 0 auto!important;margin:0!important; }
html body header.page-shared-header .page-theme-toggle,
html body header.page-shared-header .page-mobile-nav-toggle { display:inline-flex!important;align-items:center!important;justify-content:center!important;flex:0 0 42px!important;width:42px!important;min-width:42px!important;height:42px!important;padding:0!important;border:1px solid var(--sq-line)!important;border-radius:14px!important;background:var(--sq-paper)!important;color:var(--sq-ink)!important;box-shadow:0 4px 12px rgba(43,76,65,.055)!important;font-family:inherit!important;cursor:pointer!important; }
html body header.page-shared-header .page-mobile-nav-toggle { display:none!important; }

@media (max-width: 980px) {
  :root { --sq-header-height: 72px; }
  body #app > header.header { padding: 7px 14px !important; }
  body #app > header.header .header-container { min-height: 56px !important; gap: 10px !important; }
  body #app > header.header .header-nav { display: none !important; }
  body #app > header.header .mobile-menu-btn { display: inline-flex !important; }
  body #app > header.header .login-btn,
  body #app > header.header .mobile-login-wrapper { display: none !important; }
  body #app > header.header .header-brand-copy small { display: none !important; }
  body #app > header.header .header-brand-copy strong { font-size: 1rem !important; }
  body #app > header.header .logo { flex-basis: 43px !important; width: 43px !important; height: 43px !important; max-height: 43px !important; border-radius: 14px !important; }
  body #app > header.header .user-menu-label { display: none !important; }
  body #app > header.header .user-menu-btn { min-width: 42px !important; padding: 3px 6px !important; }
  html body header.page-shared-header { position: sticky !important; padding: 7px 14px !important; gap: 10px !important; }
  html body header.page-shared-header .page-shared-brand img { width: 43px !important; height: 43px !important; flex-basis: 43px !important; }
  html body header.page-shared-header .page-shared-nav { display:none!important;position:absolute!important;top:calc(100% + 8px)!important;right:12px!important;left:12px!important;width:auto!important;max-width:460px!important;max-height:calc(100dvh - 100px)!important;overflow:auto!important;flex-direction:column!important;align-items:stretch!important;gap:3px!important;margin-inline-start:auto!important;padding:8px!important;border:1px solid var(--sq-line)!important;border-radius:20px!important;background:var(--sq-paper)!important;box-shadow:0 20px 48px rgba(32,65,54,.18)!important; }
  html body header.page-shared-header .page-shared-nav.is-open { display:flex!important; }
  html body header.page-shared-header .page-shared-nav a { justify-content:flex-start!important;width:100%!important;min-height:44px!important;box-sizing:border-box!important;padding:10px 13px!important;border-radius:11px!important;white-space:normal!important; }
  html body header.page-shared-header .page-mobile-nav-toggle { display:inline-flex!important;flex-basis:40px!important;width:40px!important;min-width:40px!important;height:40px!important; }
}
@media (max-width: 760px) {
  body #app > main.story-page { width:100%!important;max-width:100%!important;margin:calc(var(--sq-header-height) + 14px) auto 28px!important;padding:0 11px!important; }
  body #app > main.story-page .story-hero {
    grid-template-columns:minmax(0,1fr)!important;gap:13px!important;
    padding:12px!important;border-radius:22px!important;
  }
  body #app > main.story-page .story-hero-img {
    order:0!important;width:100%!important;max-width:100%!important;height:auto!important;
    min-height:0!important;max-height:none!important;aspect-ratio:16 / 9!important;border-radius:17px!important;
  }
  body #app > main.story-page .story-hero-info { order:1!important;width:100%!important;padding:4px 2px 8px!important; }
  body #app > main.story-page .story-title-row { align-items:flex-start!important;gap:10px!important;margin-bottom:8px!important; }
  body #app > main.story-page .story-hero-title { font-size:clamp(1.42rem,6vw,1.8rem)!important;line-height:1.55!important; }
  body #app > main.story-page .story-favorite-btn { flex-basis:40px!important;width:40px!important;min-width:40px!important;height:40px!important;min-height:40px!important;border-radius:13px!important; }
  body #app > main.story-page .story-tags { justify-content:flex-start!important; }
  body #app > main.story-page .story-hero-summary { font-size:.9rem!important;line-height:1.95!important;margin-top:9px!important; }
  body #app > main.story-page .story-content-card { margin-top:14px!important;padding:21px 16px!important;border-radius:21px!important; }
}
@media (max-width: 420px) {
  :root { --sq-header-height: 68px; }
  body #app > header.header { padding: 6px 10px !important; }
  body #app > header.header .header-container { gap: 7px !important; }
  body #app > header.header .header-brand { gap: 7px !important; }
  body #app > header.header .logo { flex-basis: 39px !important; width: 39px !important; height: 39px !important; max-height: 39px !important; border-radius: 13px !important; }
  body #app > header.header .header-brand-copy strong { font-size: .94rem !important; }
  body #app > header.header .header-actions { gap: 6px !important; }
  body #app > header.header .header-icon-btn,
  body #app > header.header .mobile-menu-btn { flex-basis: 38px !important;width:38px!important;min-width:38px!important;height:38px!important;min-height:38px!important;border-radius:13px!important; }
  html body header.page-shared-header { padding: 6px 10px !important; }
  html body header.page-shared-header .page-shared-brand { gap: 7px !important; }
  html body header.page-shared-header .page-shared-brand img { width: 39px !important;height:39px!important;flex-basis:39px!important;border-radius:13px!important; }
  html body header.page-shared-header .page-shared-brand span { font-size: .96rem !important; }
  html body header.page-shared-header .page-header-actions { gap: 6px !important; }
  html body header.page-shared-header .page-theme-toggle,
  html body header.page-shared-header .page-mobile-nav-toggle { flex-basis:38px!important;width:38px!important;min-width:38px!important;height:38px!important; }
}

/* Account + subscription redesign, aligned with the Shahr Qesse palette */
.account-shell{width:min(1120px,calc(100% - 36px));margin:34px auto 54px;direction:rtl;color:var(--sq-ink)}
.account-page-heading{margin:0 0 22px;padding:0 4px}
.account-eyebrow{display:inline-flex;align-items:center;padding:7px 13px;background:var(--sq-mint);color:var(--sq-ink-2);border-radius:999px;font-size:.82rem;font-weight:900}
.account-page-heading h1{font-size:clamp(1.65rem,3.5vw,2.5rem);line-height:1.45;margin:12px 0 4px;color:var(--sq-ink);font-weight:950}
.account-page-heading p{margin:0;color:var(--sq-muted);line-height:1.9}
.account-hero{position:relative;display:grid;grid-template-columns:auto minmax(0,1fr) auto;align-items:center;gap:18px;padding:28px;border-radius:30px;background:linear-gradient(115deg,#e4f7e8 0%,#fffaf0 75%);border:1px solid #d8eadb;box-shadow:0 16px 38px rgba(37,77,73,.08);overflow:hidden;margin-bottom:20px}
.account-avatar{width:92px;height:92px;display:grid;place-items:center;border-radius:30px;background:linear-gradient(135deg,#ffd877,#ffb16b);color:#2a4d4f;font-size:2.35rem;font-weight:950;box-shadow:0 9px 22px rgba(255,140,66,.18);z-index:1}
.account-hero-copy{z-index:1;min-width:0}.account-member-label{display:inline-block;font-weight:800;font-size:.82rem;color:#57836c}.account-hero-copy h2{margin:5px 0 10px;font-size:1.55rem;overflow-wrap:anywhere;color:#2a4d4f}.account-phone{display:flex;align-items:center;gap:8px;flex-wrap:wrap;color:#637977;font-size:.91rem}.verified-label{display:inline-flex;background:#d6f1dd;color:#307451;border-radius:999px;padding:4px 9px;font-size:.72rem;font-weight:800}.account-hero-decoration{font-size:4rem;opacity:.86;align-self:start;z-index:1}.account-stats{grid-column:1/-1;display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:12px;margin-top:2px;z-index:1}.account-stat{display:flex;align-items:center;gap:12px;padding:14px 17px;background:rgba(255,255,255,.78);border:1px solid rgba(216,234,219,.9);border-radius:17px}.account-stat strong{font-size:1.65rem;color:#e17b3c}.account-stat span{color:#637977;font-weight:800;font-size:.88rem}
.account-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:20px;margin-bottom:20px}.account-card{min-width:0;background:var(--sq-paper);border:1px solid var(--sq-line);border-radius:25px;padding:24px;box-shadow:0 12px 30px rgba(37,77,73,.055);margin-bottom:20px;color:var(--sq-ink)}.account-grid .account-card{margin-bottom:0}.account-card-heading{display:flex;align-items:center;gap:12px;margin-bottom:20px}.account-card-icon{flex:0 0 auto;width:47px;height:47px;display:grid;place-items:center;background:var(--sq-mint);border-radius:15px;font-size:1.35rem}.account-card-heading h2{font-size:1.12rem;margin:0 0 4px;color:var(--sq-ink)}.account-card-heading p{margin:0;color:var(--sq-muted);font-size:.82rem;line-height:1.8}.account-username-form label{display:block;margin-bottom:8px;font-size:.87rem;font-weight:900}.account-username-form input{width:100%;border:1px solid var(--sq-line);border-radius:14px;background:rgba(255,255,255,.75);color:var(--sq-ink);font:inherit;padding:13px 14px;outline:0}.account-username-form input:focus{border-color:#8bc6a4;box-shadow:0 0 0 4px rgba(139,198,164,.16)}.account-field-help{font-size:.77rem;color:var(--sq-muted);margin:7px 2px 13px;line-height:1.8}.account-button{display:inline-flex;align-items:center;justify-content:center;gap:9px;border:0;border-radius:14px;padding:12px 17px;background:linear-gradient(135deg,#ff9b4e,#ffd877);color:#2a4d4f;font:900 .91rem Vazirmatn,sans-serif;text-decoration:none;cursor:pointer;box-shadow:0 7px 16px rgba(255,140,66,.14);transition:transform .18s,box-shadow .18s}.account-button:hover{transform:translateY(-2px);box-shadow:0 11px 20px rgba(255,140,66,.22)}.account-button-outline{background:var(--sq-mint);box-shadow:none}.account-security-note{display:flex;align-items:flex-start;gap:9px;padding:12px 13px;margin:18px 0 12px;border-radius:15px;background:rgba(223,243,231,.62);color:var(--sq-muted);font-size:.8rem;line-height:1.85}.account-security-note p{margin:0}.account-text-link{display:inline-block;text-decoration:none;color:var(--sq-ink-2);font-weight:900;font-size:.86rem}.account-text-link:hover{text-decoration:underline}.account-membership-status{display:inline-flex;align-items:center;gap:8px;padding:8px 12px;border-radius:999px;background:#f4f0e5;color:#7b704d;font-weight:900;font-size:.82rem}.account-membership-status .status-dot,.subscription-status-pill span{width:8px;height:8px;display:inline-block;border-radius:50%;background:#d7a747}.account-membership-status.is-premium{background:#e0f5e5;color:#27774f}.account-membership-status.is-premium .status-dot,.subscription-status-pill.active span{background:#36a36c}.account-membership-desc{color:var(--sq-muted);line-height:2;font-size:.88rem;margin:15px 0 18px}.account-days{display:flex;align-items:baseline;gap:9px;margin:16px 0}.account-days strong{font-size:2.1rem;color:#e17b3c}.account-days span{color:var(--sq-muted);font-size:.85rem}.account-content-card .account-card-heading{margin-bottom:15px}.account-favorites .empty-state,.account-comments>p{padding:15px;border-radius:14px;background:rgba(223,243,231,.5);color:var(--sq-muted);line-height:1.9}.account-favorites .favorite-item,.account-comments .review-item{border:1px solid var(--sq-line);border-radius:15px;padding:14px 16px;background:rgba(255,255,255,.55);margin-bottom:10px;cursor:pointer}.account-favorites .favorite-title,.account-comments .review-story{font-weight:900;color:var(--sq-ink);margin-bottom:6px}.account-favorites .favorite-meta,.account-comments .review-date{color:var(--sq-muted);font-size:.78rem}.account-comments .review-content{white-space:pre-wrap;overflow-wrap:anywhere;line-height:1.95;margin:8px 0;color:var(--sq-ink)}.account-empty{text-align:center;padding:48px 24px;background:var(--sq-paper);border:1px solid var(--sq-line);border-radius:25px;box-shadow:var(--sq-shadow)}.account-empty-icon{font-size:3.2rem}.account-empty h2{margin:9px 0;color:var(--sq-ink)}.account-empty p{color:var(--sq-muted);line-height:1.9}.account-primary-link{display:inline-flex;justify-content:center;margin-top:10px;border-radius:14px;padding:12px 20px;text-decoration:none;font-weight:900;background:linear-gradient(135deg,#ff9b4e,#ffd877);color:#2a4d4f}
.subscription-overview{position:relative;padding:27px;border-radius:29px;background:linear-gradient(115deg,#e2f5e7,#fff9ed);border:1px solid #d7ebd9;box-shadow:0 15px 36px rgba(37,77,73,.075);margin-bottom:27px;overflow:hidden}.subscription-overview.is-premium{background:linear-gradient(115deg,#d5f0df,#fff0c7)}.subscription-overview-top{display:flex;justify-content:space-between;align-items:center;gap:20px}.subscription-small-label{font-size:.8rem;color:var(--sq-muted);font-weight:900}.subscription-overview h2{font-size:1.45rem;margin:6px 0;color:var(--sq-ink)}.subscription-overview p{color:var(--sq-muted);margin:0;line-height:1.9;font-size:.88rem}.subscription-big-icon{flex:0 0 auto;width:82px;height:82px;display:grid;place-items:center;border-radius:27px;background:rgba(255,255,255,.7);font-size:2.7rem}.subscription-status-pill{display:inline-flex;align-items:center;gap:8px;padding:7px 12px;margin-top:17px;border-radius:999px;background:#f3eddb;font-weight:900;font-size:.78rem;color:#837246}.subscription-status-pill.active{background:#d6f2de;color:#2b7950}.subscription-progress-area{margin-top:23px}.subscription-progress-meta{display:flex;justify-content:space-between;gap:12px;margin-bottom:9px;font-size:.84rem}.subscription-progress-meta strong{color:#e17b3c}.subscription-progress-track{height:10px;background:rgba(255,255,255,.8);border-radius:99px;overflow:hidden}.subscription-progress-track span{display:block;height:100%;border-radius:99px;background:linear-gradient(90deg,#63ba8b,#ffd877)}.subscription-progress-area>p{margin-top:10px;font-size:.8rem}.subscription-section-heading{display:flex;justify-content:space-between;align-items:end;gap:15px;margin:0 2px 15px}.subscription-section-heading h2{margin:0 0 5px;font-size:1.35rem}.subscription-section-heading p{margin:0;color:var(--sq-muted);font-size:.87rem}.subscription-coming-soon{background:var(--sq-lavender);padding:7px 12px;border-radius:99px;color:#625b8c;font-weight:900;font-size:.75rem}.subscription-plan-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:18px;margin-bottom:17px}.subscription-plan{position:relative;padding:24px;border-radius:23px;border:1px solid var(--sq-line);background:var(--sq-paper);box-shadow:0 11px 25px rgba(37,77,73,.045);text-align:center}.subscription-plan.featured-plan{border:2px solid #f4c56c;background:linear-gradient(155deg,rgba(255,216,119,.16),var(--sq-paper) 65%)}.subscription-plan-symbol{font-size:2rem;width:60px;height:60px;margin:0 auto 10px;display:grid;place-items:center;border-radius:20px;background:var(--sq-mint)}.subscription-plan h3{margin:7px 0;font-size:1.13rem}.subscription-plan-price{font-size:1.6rem;font-weight:950;color:#dc793b;margin:14px 0 7px}.subscription-plan-price small{font-size:.75rem;font-weight:700;color:var(--sq-muted)}.subscription-plan-copy{min-height:44px;margin:0 0 19px;color:var(--sq-muted);font-size:.83rem;line-height:1.9}.subscription-plan .account-button{width:100%}.subscription-popular{position:absolute;top:12px;left:12px;padding:5px 9px;background:#ffd877;color:#65552d;font-size:.72rem;font-weight:900;border-radius:99px}.subscription-payment-note{display:flex;gap:12px;align-items:flex-start;padding:15px 17px;border:1px dashed #d9e4d5;background:rgba(223,243,231,.42);border-radius:17px;margin-bottom:22px;color:var(--sq-muted);font-size:.84rem;line-height:1.9}.subscription-payment-note>span{font-size:1.3rem}.subscription-payment-note p{margin:0}.subscription-payment-note strong{color:var(--sq-ink)}.history-list{display:grid;gap:10px}.history-item{padding:15px 17px;border:1px solid var(--sq-line);border-radius:15px;background:rgba(255,255,255,.5);color:var(--sq-ink)}.history-item strong{display:inline-block;margin-bottom:7px}.history-item p{display:inline-block;margin:4px 12px 0 0;font-size:.82rem;color:var(--sq-muted)}.subscription-back-link{margin:0 2px 25px}
body.dark-mode .account-shell,body.dark-mode .account-shell *{--account-ink:var(--sq-ink)}body.dark-mode .account-hero,body.dark-mode .subscription-overview{background:linear-gradient(115deg,#253c32,#282d27);border-color:#3c5145}body.dark-mode .account-hero-copy h2,body.dark-mode .account-page-heading h1,body.dark-mode .subscription-overview h2,body.dark-mode .subscription-payment-note strong{color:var(--sq-ink)}body.dark-mode .account-avatar,body.dark-mode .account-stat,body.dark-mode .subscription-big-icon,body.dark-mode .account-username-form input,body.dark-mode .account-favorites .favorite-item,body.dark-mode .account-comments .review-item,body.dark-mode .history-item{background:#25332e;color:var(--sq-ink);border-color:#3e5147}body.dark-mode .account-card{background:#202b29;border-color:#384641;color:var(--sq-ink)}body.dark-mode .account-card-heading h2,body.dark-mode .account-stat span,body.dark-mode .account-comments .review-story,body.dark-mode .account-favorites .favorite-title{color:var(--sq-ink)}body.dark-mode .account-security-note,body.dark-mode .subscription-payment-note,body.dark-mode .account-favorites .empty-state,body.dark-mode .account-comments>p{background:#253d34;border-color:#384641}body.dark-mode .subscription-plan,body.dark-mode .subscription-plan.featured-plan{background:#202b29;border-color:#4b594c}body.dark-mode .account-membership-status{background:#3a3321;color:#f1d58b}body.dark-mode .account-membership-status.is-premium{background:#1f4736;color:#a5e4be}
@media(max-width:720px){.account-shell{width:calc(100% - 22px);margin:24px auto 36px}.account-hero{grid-template-columns:auto minmax(0,1fr);padding:21px;gap:13px;border-radius:24px}.account-avatar{width:70px;height:70px;border-radius:23px;font-size:1.9rem}.account-hero-copy h2{font-size:1.25rem}.account-hero-decoration{display:none}.account-stats{gap:9px}.account-stat{padding:12px;gap:8px;align-items:flex-start;flex-direction:column}.account-stat strong{font-size:1.45rem}.account-stat span{font-size:.76rem}.account-grid,.subscription-plan-grid{grid-template-columns:1fr;gap:13px}.account-card{padding:19px;border-radius:21px}.subscription-overview{padding:21px;border-radius:24px}.subscription-big-icon{width:64px;height:64px;border-radius:21px;font-size:2.1rem}.subscription-overview h2{font-size:1.2rem}.subscription-section-heading{align-items:center}.subscription-section-heading h2{font-size:1.15rem}.subscription-plan{padding:22px}.subscription-plan-copy{min-height:0}.history-item p{display:block;margin:5px 0 0}.account-hero-copy{overflow-wrap:anywhere}}
@media(max-width:380px){.account-hero{padding:16px}.account-phone{font-size:.78rem}.account-stats{grid-template-columns:1fr}.account-stat{flex-direction:row;align-items:center}.account-card-heading{gap:9px}.account-card-icon{width:41px;height:41px}.account-page-heading h1{font-size:1.5rem}}

/* AI Story Maker - Shahr Qesse */
.ai-story-shell{width:min(1040px,calc(100% - 36px));margin:34px auto 58px;direction:rtl;color:var(--sq-ink)}
.ai-story-intro{position:relative;display:flex;align-items:center;justify-content:space-between;gap:24px;overflow:hidden;padding:clamp(22px,4vw,42px);border:1px solid #d7e9dc;border-radius:30px;background:linear-gradient(120deg,#e2f4e7 0%,#f4f8eb 55%,#fff5df 100%);box-shadow:0 16px 38px rgba(42,77,73,.08)}
.ai-story-intro-copy{position:relative;z-index:1;max-width:660px}.ai-story-eyebrow{display:inline-flex;align-items:center;gap:7px;margin-bottom:9px;color:#4d8064;font-size:.82rem;font-weight:900}.ai-story-intro h1,.ai-my-stories-heading h1{margin:0 0 9px;color:#2a4d4f;font-size:clamp(1.8rem,4vw,2.65rem);font-weight:950;line-height:1.45}.ai-story-intro p,.ai-my-stories-heading p{margin:0;color:#627b70;font-size:.98rem;line-height:2}.ai-story-intro-links{display:flex;align-items:center;gap:17px;flex-wrap:wrap;margin-top:20px;color:#4d7660;font-size:.83rem;font-weight:800}.ai-story-intro-links span,.ai-story-intro-links a{display:inline-flex;align-items:center;gap:7px}.ai-story-intro-links a{text-decoration:none;color:#2a4d4f}.ai-story-intro-links a:hover{text-decoration:underline}
.ai-story-book-art{position:relative;flex:0 0 155px;width:155px;height:155px;display:grid;place-items:center;border-radius:44px;background:rgba(255,255,255,.58);border:1px solid rgba(255,255,255,.85);transform:rotate(3deg)}.ai-book-icon{width:104px;height:104px;display:grid;place-items:center;border-radius:31px;background:#2f6252;color:#fff9e9;box-shadow:0 14px 24px rgba(35,83,65,.18);font-size:3.15rem;transform:rotate(-5deg)}.ai-book-sparkle{position:absolute;color:#e9a044;font-size:1.6rem}.ai-book-sparkle.one{top:12px;right:17px}.ai-book-sparkle.two{bottom:16px;left:13px}.ai-book-leaf{position:absolute;bottom:5px;right:8px;color:#76a985;font-size:2.9rem;transform:rotate(-25deg)}
.ai-story-quota-panel{display:flex;align-items:center;gap:13px;margin:18px 0;padding:15px 18px;border:1px solid var(--sq-line);border-radius:20px;background:var(--sq-paper);box-shadow:0 9px 22px rgba(42,77,73,.045)}.ai-quota-symbol{width:44px;height:44px;flex:0 0 44px;display:grid;place-items:center;border-radius:14px;background:var(--sq-mint);color:#316a52;font-size:1.2rem}.ai-quota-copy{display:grid;gap:3px;min-width:0;flex:1}.ai-quota-copy strong{font-size:.95rem;color:var(--sq-ink)}.ai-quota-copy span{font-size:.82rem;color:var(--sq-muted)}.ai-quota-plan{font-size:.78rem;font-weight:900;color:#4d8064;background:rgba(223,243,231,.68);border-radius:999px;padding:8px 12px;white-space:nowrap}.ai-story-service-note{margin:-5px 0 17px;padding:12px 15px;border-radius:13px;background:#fff4dc;color:#765b25;border:1px solid #f1dfb4;font-size:.83rem;line-height:1.9}
.ai-story-builder-card{padding:clamp(19px,3vw,30px);border:1px solid var(--sq-line);border-radius:27px;background:var(--sq-paper);box-shadow:0 13px 32px rgba(42,77,73,.055)}.ai-story-section-heading{display:flex;justify-content:space-between;align-items:flex-end;gap:15px;margin-bottom:24px}.ai-story-section-heading>div>span{color:#6c9b79;font-weight:900;font-size:.78rem}.ai-story-section-heading h2{margin:4px 0 0;font-size:clamp(1.15rem,2.6vw,1.45rem);font-weight:950;color:var(--sq-ink)}.ai-story-section-heading>p{margin:0;color:var(--sq-muted);font-size:.82rem;line-height:1.8}.ai-story-form-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:20px}.ai-story-field{display:flex;flex-direction:column;gap:8px;min-width:0}.ai-story-field-wide{grid-column:1/-1}.ai-story-field label{font-size:.87rem;font-weight:900;color:var(--sq-ink)}.ai-story-field label em{color:#db8241;font-style:normal}.ai-story-field input,.ai-story-field select{box-sizing:border-box;width:100%;min-width:0;min-height:48px;padding:11px 13px;border:1px solid var(--sq-line);border-radius:13px;background:var(--sq-paper);color:var(--sq-ink);font:inherit;font-size:.9rem;outline:none;transition:border-color .18s,box-shadow .18s}.ai-story-field input::placeholder{color:#a0aaa2}.ai-story-field input:focus,.ai-story-field select:focus{border-color:#8bc6a4;box-shadow:0 0 0 4px rgba(139,198,164,.17)}.ai-story-field small{color:var(--sq-muted);font-size:.74rem;line-height:1.7}.ai-story-form-bottom{display:flex;align-items:center;justify-content:space-between;gap:15px;flex-wrap:wrap;margin-top:25px;padding-top:20px;border-top:1px solid var(--sq-line)}.ai-story-form-bottom p{display:flex;align-items:flex-start;gap:8px;max-width:520px;margin:0;color:var(--sq-muted);font-size:.8rem;line-height:1.9}.ai-story-form-bottom p i{margin-top:5px;color:#d78d3f}.ai-story-primary,.ai-story-secondary{display:inline-flex;align-items:center;justify-content:center;gap:9px;min-height:44px;padding:11px 17px;border:1px solid transparent;border-radius:13px;font:900 .88rem Vazirmatn,sans-serif;text-decoration:none;cursor:pointer;transition:transform .16s,box-shadow .16s,background .16s}.ai-story-primary{background:linear-gradient(135deg,#ff9b4e,#ffd877);color:#2a4d4f;box-shadow:0 7px 17px rgba(255,140,66,.15)}.ai-story-secondary{background:var(--sq-mint);border-color:#d6e8da;color:#2e5a49}.ai-story-primary:hover,.ai-story-secondary:hover{transform:translateY(-1px);box-shadow:0 9px 19px rgba(42,77,73,.1)}.ai-story-primary:disabled{opacity:.65;cursor:not-allowed;transform:none;box-shadow:none}.ai-story-error,.ai-story-error-inline{margin:18px 0;padding:13px 15px;border:1px solid #f1c9c4;border-radius:14px;background:#fff1ef;color:#9b3730;font-size:.87rem;line-height:1.9}.ai-generated-story-result{scroll-margin-top:30px}.ai-generated-story-card{margin-top:23px;padding:clamp(19px,3vw,32px);border:1px solid #d4e6d7;border-radius:27px;background:linear-gradient(180deg,rgba(223,243,231,.45),var(--sq-paper) 240px);box-shadow:0 15px 35px rgba(42,77,73,.07);color:var(--sq-ink)}.ai-generated-story-top{display:flex;align-items:flex-start;gap:15px;padding-bottom:20px;border-bottom:1px solid var(--sq-line)}.ai-generated-story-mark{display:grid;place-items:center;flex:0 0 55px;width:55px;height:55px;border-radius:18px;background:#2f6252;color:#fff8e7;font-size:1.5rem}.ai-generated-story-heading{min-width:0;flex:1}.ai-generated-story-heading .ai-story-eyebrow{margin:0 0 5px}.ai-generated-story-heading h2{margin:0 0 7px;font-size:clamp(1.35rem,3vw,1.9rem);font-weight:950;line-height:1.55;overflow-wrap:anywhere;color:var(--sq-ink)}.ai-generated-story-heading p{margin:0;color:var(--sq-muted);font-size:.92rem;line-height:2}.ai-generated-story-meta{margin-top:8px;color:#659174;font-size:.77rem;font-weight:800}.ai-generated-story-content{max-width:780px;margin:22px auto 10px;font-size:1rem;line-height:2.35;color:var(--sq-ink)}.ai-generated-story-content p{margin:0 0 18px}.ai-generated-story-actions{display:flex;justify-content:flex-start;align-items:center;gap:10px;flex-wrap:wrap;margin-top:23px;padding-top:18px;border-top:1px solid var(--sq-line)}.ai-story-generating,.ai-story-loading,.ai-story-empty,.ai-story-login{text-align:center;padding:35px 22px;border:1px solid var(--sq-line);border-radius:24px;background:var(--sq-paper);color:var(--sq-ink)}.ai-story-generating h2,.ai-story-empty h2,.ai-story-login h1{margin:12px 0 7px;color:var(--sq-ink);font-size:1.35rem}.ai-story-generating p,.ai-story-empty p,.ai-story-login p{color:var(--sq-muted);line-height:2}.ai-story-loader{width:43px;height:43px;margin:0 auto;border:4px solid var(--sq-line);border-top-color:#4f9471;border-radius:50%;animation:ai-story-spin .8s linear infinite}@keyframes ai-story-spin{to{transform:rotate(360deg)}}.ai-story-login{padding:clamp(28px,5vw,52px);background:linear-gradient(125deg,#e5f5e8,#fff8e7);border-color:#d7e9dc}.ai-story-login .ai-story-eyebrow{justify-content:center}.ai-story-login p{max-width:620px;margin:0 auto}.ai-story-actions{display:flex;justify-content:center;gap:10px;flex-wrap:wrap;margin-top:22px}.ai-my-stories-page{min-height:420px}.ai-my-stories-heading{display:flex;align-items:flex-end;justify-content:space-between;gap:20px;margin-bottom:23px}.ai-my-stories-heading .ai-story-eyebrow{margin-bottom:2px}.ai-my-stories-heading h1{margin-bottom:2px}.ai-my-stories-list{display:grid;gap:12px}.ai-my-story-item{display:flex;align-items:center;gap:15px;padding:17px;border:1px solid var(--sq-line);border-radius:20px;background:var(--sq-paper);box-shadow:0 8px 20px rgba(42,77,73,.035)}.ai-my-story-icon{display:grid;place-items:center;flex:0 0 48px;width:48px;height:48px;border-radius:15px;background:var(--sq-mint);color:#316a52;font-size:1.2rem}.ai-my-story-copy{flex:1;min-width:0}.ai-my-story-copy h2{margin:0 0 4px;color:var(--sq-ink);font-size:1rem;font-weight:950}.ai-my-story-copy p{margin:0;color:var(--sq-muted);font-size:.82rem;line-height:1.9}.ai-story-empty>i{font-size:2.3rem;color:#7aa986}.ai-story-empty .ai-story-primary{margin-top:8px}
body.dark-mode .ai-story-intro{background:linear-gradient(120deg,#223a30,#29342c 58%,#3a3324);border-color:#3b5243}body.dark-mode .ai-story-intro h1,body.dark-mode .ai-my-stories-heading h1{color:var(--sq-ink)}body.dark-mode .ai-story-intro p,body.dark-mode .ai-my-stories-heading p,body.dark-mode .ai-story-intro-links{color:#b5cbbd}body.dark-mode .ai-story-book-art{background:rgba(35,55,44,.68);border-color:#40574a}body.dark-mode .ai-story-quota-panel,body.dark-mode .ai-story-builder-card,body.dark-mode .ai-generated-story-card,body.dark-mode .ai-story-generating,body.dark-mode .ai-story-loading,body.dark-mode .ai-story-empty,body.dark-mode .ai-my-story-item{background:#202b29;border-color:#384941;color:var(--sq-ink)}body.dark-mode .ai-story-field input,body.dark-mode .ai-story-field select{background:#26342f;border-color:#40554a;color:var(--sq-ink)}body.dark-mode .ai-story-login{background:linear-gradient(125deg,#223a30,#303328);border-color:#3b5243}body.dark-mode .ai-story-service-note{background:#3a3321;color:#f4dca4;border-color:#5a4c2a}body.dark-mode .ai-quota-plan{background:#243f31;color:#b7e4c4}body.dark-mode .ai-generated-story-card{background:linear-gradient(180deg,#263b31,#202b29 240px)}body.dark-mode .ai-generated-story-heading h2,body.dark-mode .ai-my-story-copy h2{color:var(--sq-ink)}
.nav-ai-story-link,.mobile-ai-story-link{color:#397451!important}.nav-ai-story-link i,.mobile-ai-story-link i{color:#6c9a75!important}
@media(max-width:760px){.ai-story-shell{width:calc(100% - 22px);margin:22px auto 40px}.ai-story-intro{align-items:flex-start;padding:23px 20px;border-radius:24px}.ai-story-book-art{flex-basis:82px;width:82px;height:82px;border-radius:25px}.ai-book-icon{width:61px;height:61px;border-radius:19px;font-size:1.8rem}.ai-book-sparkle{font-size:1rem}.ai-book-sparkle.one{top:5px;right:8px}.ai-book-sparkle.two{bottom:7px;left:6px}.ai-book-leaf{font-size:1.8rem;bottom:0;right:2px}.ai-story-intro h1{font-size:1.75rem}.ai-story-intro p{font-size:.88rem}.ai-story-intro-links{gap:10px;font-size:.75rem}.ai-story-quota-panel{padding:12px;gap:9px}.ai-quota-plan{white-space:normal;text-align:center;font-size:.7rem;padding:7px 9px}.ai-story-section-heading{display:block}.ai-story-section-heading>p{margin-top:6px}.ai-story-form-grid{grid-template-columns:minmax(0,1fr);gap:16px}.ai-story-field-wide{grid-column:auto}.ai-story-form-bottom{align-items:stretch}.ai-story-form-bottom p{max-width:none}.ai-story-form-bottom .ai-story-primary{width:100%}.ai-generated-story-top{gap:11px}.ai-generated-story-mark{flex-basis:44px;width:44px;height:44px;border-radius:14px;font-size:1.2rem}.ai-generated-story-content{font-size:.93rem;line-height:2.25}.ai-generated-story-actions>*{flex:1}.ai-my-stories-heading{display:block}.ai-my-stories-heading .ai-story-primary{margin-top:15px}.ai-my-story-item{align-items:flex-start;flex-wrap:wrap;padding:13px;gap:11px}.ai-my-story-copy{flex-basis:calc(100% - 62px)}.ai-my-story-item>.ai-story-secondary{width:100%}}
@media(max-width:390px){.ai-story-intro{gap:9px;padding:19px 15px}.ai-story-book-art{flex-basis:65px;width:65px;height:65px}.ai-book-icon{width:49px;height:49px;font-size:1.45rem}.ai-story-intro h1{font-size:1.53rem}.ai-story-quota-panel{align-items:flex-start;flex-wrap:wrap}.ai-quota-copy{flex-basis:calc(100% - 65px)}.ai-quota-plan{margin-right:53px}.ai-story-primary,.ai-story-secondary{padding-inline:12px;font-size:.81rem}}

.account-ai-stories-actions{display:flex;gap:10px;flex-wrap:wrap}.account-ai-stories-actions .account-button{min-height:42px}.account-ai-stories-card .account-card-heading{margin-bottom:14px}
@media(max-width:720px){.account-ai-stories-actions>*{flex:1}}


/* AI story builder: per-character name and relationship fields */
.ai-characters-field{gap:12px!important}
.ai-characters-heading{display:flex;flex-direction:column;gap:5px}
.ai-characters-heading>label{font-size:.9rem;font-weight:950;color:var(--sq-ink)}
.ai-characters-heading>span,.ai-character-controls small{color:var(--sq-muted);font-size:.76rem;line-height:1.8}
.ai-characters-list{display:grid;gap:10px}
.ai-character-row{display:grid;grid-template-columns:minmax(0,.9fr) minmax(0,1.3fr) 42px;align-items:end;gap:12px;padding:13px;border:1px solid var(--sq-line);border-radius:16px;background:rgba(223,243,231,.22)}
.ai-character-input{display:flex;flex-direction:column;gap:7px;min-width:0}
.ai-character-input label{font-size:.77rem;font-weight:850;color:var(--sq-ink)}
.ai-character-input input{width:100%;min-width:0;box-sizing:border-box;min-height:45px;padding:10px 12px;border:1px solid var(--sq-line);border-radius:11px;background:var(--sq-paper);color:var(--sq-ink);font:inherit;font-size:.86rem;outline:none;transition:border-color .18s,box-shadow .18s}
.ai-character-input input:focus{border-color:#8bc6a4;box-shadow:0 0 0 4px rgba(139,198,164,.16)}
.ai-character-input input::placeholder{color:#a0aaa2}
.ai-character-remove{width:42px;height:45px;display:inline-flex;align-items:center;justify-content:center;border:1px solid #f0d6d2;border-radius:11px;background:#fff7f5;color:#a94b42;cursor:pointer;transition:background .18s,opacity .18s}
.ai-character-remove:hover:not(:disabled){background:#ffe9e5}
.ai-character-remove:disabled{opacity:.35;cursor:not-allowed}
.ai-character-controls{display:flex;align-items:center;gap:12px;flex-wrap:wrap}
.ai-character-add{min-height:38px;display:inline-flex;align-items:center;justify-content:center;gap:8px;padding:8px 12px;border:1px solid #d5e7d9;border-radius:11px;background:var(--sq-mint);color:#2e5a49;font:850 .8rem Vazirmatn,sans-serif;cursor:pointer}
.ai-character-add:hover:not(:disabled){background:#ddf0e2}
.ai-character-add:disabled{opacity:.55;cursor:not-allowed}
@media(max-width:640px){.ai-character-row{grid-template-columns:minmax(0,1fr);gap:10px;padding:11px}.ai-character-remove{width:auto;height:36px;justify-self:start;padding:0 13px}.ai-character-remove:after{content:' حذف شخصیت';font:800 .76rem Vazirmatn,sans-serif}.ai-character-remove i{font-size:.78rem}.ai-character-controls{align-items:flex-start;flex-direction:column;gap:7px}}


/* v17: shared social links, consistent AI navigation and initial-render stability */
.footer-content { grid-template-columns: minmax(0,1.15fr) minmax(0,.85fr) minmax(0,.85fr) minmax(0,.72fr) !important; }
.footer-social-links,.standalone-social-links { display:flex; align-items:center; gap:10px; flex-wrap:wrap; direction:rtl; margin-top:8px; }
.footer-social-link,.standalone-social-link { appearance:none; display:inline-flex; align-items:center; justify-content:center; width:42px; height:42px; flex:0 0 42px; border:1px solid rgba(255,255,255,.23); border-radius:14px; background:rgba(255,255,255,.12); color:#fff8df!important; text-decoration:none!important; font-size:1.15rem; box-sizing:border-box; transition:transform .18s ease,background .18s ease,opacity .18s ease; }
.footer-social-link:hover,.standalone-social-link:hover { transform:translateY(-2px); background:rgba(255,255,255,.22); }
.footer-social-link.social-eitaa,.standalone-social-link.social-eitaa { color:#c8f4df!important; }
.footer-social-link.social-telegram,.standalone-social-link.social-telegram { color:#b9e8ff!important; }
.footer-social-link.social-instagram,.standalone-social-link.social-instagram { color:#ffe0d9!important; }
.footer-social-link.is-disabled,.standalone-social-link.is-disabled { opacity:.48; cursor:not-allowed; filter:grayscale(.35); }
.footer-social-note { margin:10px 0 0; color:#c6dfd2; font-size:.76rem; line-height:1.8; }
.footer-content .footer-col { min-width:0; }
.page-ai-story-link { color:#397451!important; }
.page-ai-story-link i { color:#6c9a75!important; margin-left:6px; }
.page-ai-story-link:hover { background:#e8f6ed!important; }
.contact-social-grid { display:grid; grid-template-columns:repeat(2,minmax(0,1fr)); gap:14px; margin-top:24px; }
.contact-social-card { display:flex; align-items:center; gap:14px; min-width:0; min-height:92px; box-sizing:border-box; padding:17px; border:1px solid var(--sq-line); border-radius:19px; background:linear-gradient(135deg,var(--sq-paper),rgba(223,243,231,.45)); color:var(--sq-ink); text-decoration:none; transition:transform .18s ease,box-shadow .18s ease,border-color .18s ease; }
.contact-social-card[href]:hover { transform:translateY(-2px); box-shadow:0 10px 24px rgba(43,76,65,.09); border-color:#b8d9c5; }
.contact-social-icon { display:inline-flex; align-items:center; justify-content:center; flex:0 0 48px; width:48px; height:48px; border-radius:16px; background:#e4f4e9; color:#2e7561; font-size:1.28rem; }
.contact-social-telegram .contact-social-icon { background:#e3f3fb; color:#1888bd; }
.contact-social-instagram .contact-social-icon { background:#f8e9ee; color:#9e5f78; }
.contact-social-email .contact-social-icon { background:#fff1d0; color:#8b6b1d; }
.contact-social-copy { display:flex; flex:1 1 auto; min-width:0; flex-direction:column; gap:4px; }
.contact-social-copy strong { font-size:.96rem; font-weight:900; line-height:1.65; }
.contact-social-copy small { color:var(--sq-muted); font-size:.79rem; line-height:1.75; overflow-wrap:anywhere; }
.contact-social-copy bdi { direction:ltr; display:inline-block; font-size:.87rem; font-weight:800; }
.contact-social-arrow { flex:0 0 auto; margin-inline-start:auto; color:#729283; font-size:.82rem; }
.contact-social-card.is-disabled { opacity:.74; cursor:not-allowed; background:linear-gradient(135deg,var(--sq-paper),rgba(241,238,230,.65)); }
.contact-social-badge { flex:0 0 auto; padding:4px 8px; border-radius:999px; background:#f2ebd8; color:#7f6c3e; font-size:.72rem; font-weight:900; }
.standalone-social-note { margin-top:8px!important; color:#c6dfd2!important; font-size:.75rem!important; }
.featured-loading-card { display:flex; flex-direction:column; height:100%; min-height:380px; overflow:hidden; border-radius:21px; border:1px solid var(--sq-line); background:var(--sq-paper); box-shadow:0 8px 21px rgba(38,77,62,.05); }
.featured-loading-cover,.featured-loading-body span { display:block; background:linear-gradient(100deg,#edf1eb 20%,#f8f8f2 38%,#edf1eb 58%); background-size:220% 100%; animation:featured-skeleton-wave 1.25s ease-in-out infinite; }
.featured-loading-cover { height:185px; flex:0 0 185px; }
.featured-loading-body { display:flex; flex-direction:column; gap:13px; padding:18px; }
.featured-loading-body span { height:13px; border-radius:99px; }
.featured-loading-body span:nth-child(2) { width:82%; }
.featured-loading-body span:nth-child(3) { width:58%; }
@keyframes featured-skeleton-wave { to { background-position-x:-220%; } }
body.dark-mode .featured-loading-card { background:var(--sq-paper); border-color:var(--sq-line); }
body.dark-mode .featured-loading-cover,body.dark-mode .featured-loading-body span { background:linear-gradient(100deg,#293b34 20%,#33473f 38%,#293b34 58%); background-size:220% 100%; }
body.dark-mode .contact-social-card { background:var(--sq-paper); border-color:var(--sq-line); color:var(--sq-ink); }
body.dark-mode .contact-social-copy small { color:var(--sq-muted); }
@media(max-width:1000px) {
  .footer-content { grid-template-columns:repeat(2,minmax(0,1fr))!important; }
  .footer-brand-col { grid-column:1/-1; }
}
@media(max-width:700px) {
  .footer-content { grid-template-columns:repeat(2,minmax(0,1fr))!important; }
  .footer-social-links { gap:8px; }
  .footer-social-link { width:39px;height:39px;flex-basis:39px;border-radius:13px; }
  .contact-social-grid { grid-template-columns:1fr; gap:10px; }
  .contact-social-card { min-height:82px; padding:14px; gap:12px; }
  .contact-social-icon { width:43px;height:43px;flex-basis:43px;border-radius:14px; }
  .standalone-social-links { justify-content:center; }
}
@media(prefers-reduced-motion:reduce) {
  .featured-loading-cover,.featured-loading-body span { animation:none; }
  .footer-social-link,.standalone-social-link,.contact-social-card { transition:none; }
}


/* Branded startup state: never flash the plain SEO fallback before app hydration. */
html.app-pending, html.app-pending body { min-height:100%; }
html.app-pending body { margin:0!important; background:radial-gradient(circle at 50% 20%,#f3faef 0%,#fffdf7 58%,#f6f0e2 100%)!important; }
html.app-pending #app { min-height:100vh; min-height:100dvh; display:grid; place-items:center; box-sizing:border-box; padding:24px; }
html.app-pending #app > .seo-initial-content { display:none!important; }
html.app-pending #app::before { content:"📚  شهر قصه\A داریم دنیای قصه را آماده می‌کنیم…"; white-space:pre-line; display:flex; align-items:center; justify-content:center; min-height:132px; width:min(390px,100%); box-sizing:border-box; padding:30px 24px; text-align:center; line-height:2.2; font-family:Vazirmatn, sans-serif; font-size:1.04rem; font-weight:900; color:#2a4d4f; background:linear-gradient(135deg,#ffffff 0%,#eff9f0 55%,#fff5d9 100%); border:1px solid #d8e9d8; border-radius:28px; box-shadow:0 18px 48px rgba(42,77,79,.1); animation:shahrqesse-loader-breathe 1.4s ease-in-out infinite alternate; }
html.app-pending body.dark-mode { background:radial-gradient(circle at 50% 20%,#1d342b 0%,#151d1a 60%,#211f1b 100%)!important; }
html.app-pending body.dark-mode #app::before { color:#e4f6e7; background:linear-gradient(135deg,#20342b 0%,#1d2e27 55%,#352f20 100%); border-color:#385b4a; }
@keyframes shahrqesse-loader-breathe { from { transform:translateY(3px); box-shadow:0 14px 36px rgba(42,77,79,.08); } to { transform:translateY(-3px); box-shadow:0 20px 48px rgba(42,77,79,.14); } }
@media(prefers-reduced-motion:reduce) { html.app-pending #app::before { animation:none; } }


/* Shared signed-in account chip: same avatar + two-line identity across every page. */
.site-account-menu{position:relative;display:inline-flex;align-items:center;flex:0 0 auto;z-index:1450}
.site-account-trigger{appearance:none!important;display:inline-flex!important;align-items:center!important;justify-content:flex-start!important;gap:10px!important;min-height:48px!important;padding:3px 7px!important;border:1px solid transparent!important;border-radius:16px!important;background:transparent!important;color:var(--sq-ink,#2a4d4f)!important;box-shadow:none!important;cursor:pointer!important;font-family:inherit!important;text-align:right!important;white-space:nowrap!important;transition:background .18s ease,border-color .18s ease!important}
.site-account-trigger:hover,.site-account-menu.is-open .site-account-trigger,.site-account-menu:focus-within .site-account-trigger{background:rgba(223,243,231,.5)!important;border-color:rgba(197,221,202,.75)!important}
.site-account-avatar{display:inline-flex!important;align-items:center!important;justify-content:center!important;flex:0 0 42px!important;width:42px!important;height:42px!important;border-radius:50%!important;background:linear-gradient(145deg,#2a4d4f,#3d8170)!important;color:#fff!important;font-size:1rem!important;font-weight:950!important;line-height:1!important;box-shadow:0 4px 12px rgba(42,77,79,.16)!important}
.site-account-copy{display:flex!important;flex-direction:column!important;align-items:flex-start!important;justify-content:center!important;gap:2px!important;min-width:0!important;line-height:1.35!important}
.site-account-copy small{display:block!important;color:var(--sq-muted,#71817a)!important;font-size:.68rem!important;font-weight:800!important}
.site-account-copy strong{display:block!important;max-width:140px!important;overflow:hidden!important;text-overflow:ellipsis!important;color:var(--sq-ink,#2a4d4f)!important;font-size:.84rem!important;font-weight:950!important}
.site-account-chevron{font-size:.68rem!important;color:var(--sq-muted,#71817a)!important;margin-inline-start:1px!important}
.site-account-dropdown{position:absolute!important;top:calc(100% + 8px)!important;left:0!important;right:auto!important;display:block!important;width:220px!important;padding:7px!important;border:1px solid var(--sq-line,#dce8de)!important;border-radius:17px!important;background:var(--sq-paper,#fffdf7)!important;box-shadow:0 18px 42px rgba(34,65,53,.17)!important;opacity:0!important;visibility:hidden!important;transform:translateY(7px)!important;transition:opacity .16s ease,transform .16s ease,visibility .16s ease!important;z-index:1500!important}
.site-account-menu:hover .site-account-dropdown,.site-account-menu:focus-within .site-account-dropdown,.site-account-menu.is-open .site-account-dropdown{opacity:1!important;visibility:visible!important;transform:translateY(0)!important}
.site-account-dropdown a,.site-account-dropdown button{display:flex!important;align-items:center!important;gap:10px!important;width:100%!important;min-height:41px!important;padding:10px 12px!important;border:0!important;border-radius:11px!important;background:transparent!important;color:var(--sq-ink,#2a4d4f)!important;font:800 .82rem Vazirmatn,sans-serif!important;text-align:right!important;text-decoration:none!important;cursor:pointer!important;box-shadow:none!important;white-space:normal!important}
.site-account-dropdown a:hover,.site-account-dropdown button:hover{background:var(--sq-mint,#dff3e7)!important}
.site-account-dropdown .site-account-logout{color:#b64e49!important}
.site-account-divider{height:1px!important;margin:5px 4px!important;background:var(--sq-line,#dce8de)!important}
.site-account-login{display:inline-flex!important;align-items:center!important;justify-content:center!important;gap:8px!important;min-height:42px!important;padding:0 15px!important;border:1px solid #c6e7d2!important;border-radius:14px!important;background:linear-gradient(135deg,#dff4e6,#c8ecd7)!important;color:#24564b!important;font:850 .84rem Vazirmatn,sans-serif!important;text-decoration:none!important;white-space:nowrap!important;box-shadow:0 4px 12px rgba(44,113,83,.08)!important;transition:transform .18s ease,box-shadow .18s ease!important}
.site-account-login:hover{transform:translateY(-1px)!important;box-shadow:0 8px 17px rgba(44,113,83,.12)!important}
.site-mobile-account-mount{display:none}
.site-mobile-account-card{margin-top:7px;padding:12px;border:1px solid var(--sq-line,#dce8de);border-radius:16px;background:linear-gradient(135deg,rgba(223,243,231,.7),rgba(255,249,232,.75))}
.site-mobile-account-head{display:flex;align-items:center;gap:10px;padding:2px 3px 10px;margin-bottom:7px;border-bottom:1px solid var(--sq-line,#dce8de)}
.site-mobile-account-head .site-account-copy strong{max-width:210px;font-size:.88rem}
.site-mobile-account-card .mobile-menu-item{display:flex!important;width:100%!important;justify-content:flex-start!important;align-items:center!important;gap:10px!important;min-height:41px!important;padding:9px 11px!important;border-radius:10px!important;text-decoration:none!important;color:var(--sq-ink,#2a4d4f)!important;background:transparent!important;border:0!important;font:800 .83rem Vazirmatn,sans-serif!important;text-align:right!important;cursor:pointer!important}
.site-mobile-account-card .mobile-menu-item:hover{background:rgba(223,243,231,.75)!important}
body.dark-mode .site-account-trigger:hover,body.dark-mode .site-account-menu.is-open .site-account-trigger,body.dark-mode .site-account-menu:focus-within .site-account-trigger{background:rgba(68,112,92,.18)!important;border-color:rgba(140,187,158,.22)!important}
body.dark-mode .site-account-copy strong{color:var(--sq-ink,#f3f6ef)!important}
body.dark-mode .site-account-dropdown,body.dark-mode .site-mobile-account-card{background:#202b29!important;border-color:#384641!important}
body.dark-mode .site-account-dropdown a,body.dark-mode .site-account-dropdown button,body.dark-mode .site-mobile-account-card .mobile-menu-item{color:#edf4ee!important}
body.dark-mode .site-mobile-account-head{border-bottom-color:#384641!important}
@media(max-width:980px){
 .site-account-menu--header{display:none!important}
 .site-account-mount--static .site-account-menu--header{display:none!important}
 .site-mobile-account-mount{display:block!important}
 .site-mobile-account-mount .mobile-menu-item{box-sizing:border-box!important}
}
@media(max-width:420px){
 .site-account-login{min-height:38px!important;padding:0 10px!important;font-size:.76rem!important}
 .site-account-avatar{flex-basis:39px!important;width:39px!important;height:39px!important}
}
@media(max-width:980px){
  .site-account-mount--static{display:none!important}
  .site-mobile-account-mount{width:100%!important;box-sizing:border-box!important;flex:1 0 100%!important}
}


/* Hero asset refresh v21: optimized storybook art on the left, copy and actions on the right. */
.hero.hero-redesign .hero-inner{
  grid-template-columns:minmax(0,1.12fr) minmax(320px,.88fr);
  min-height:430px;
  gap:clamp(16px,2.2vw,30px);
  padding:26px clamp(22px,4.2vw,58px);
}
.hero.hero-redesign .hero-copy{max-width:660px;min-width:0;padding:10px 0}
.hero.hero-redesign .hero-art{
  width:100%;min-width:0;min-height:350px;align-self:stretch;
  display:flex;align-items:center;justify-content:center;overflow:visible;isolation:isolate;
}
.hero.hero-redesign .hero-art::before{
  width:min(82%,390px);opacity:.38;transform:rotate(-7deg);
}
.hero.hero-redesign .hero-art::after{content:none}
.hero.hero-redesign .hero-art img{
  display:block;width:100%;max-width:500px;height:auto;max-height:390px;
  aspect-ratio:1000 / 839;object-fit:cover;object-position:center;
  border:1px solid rgba(255,255,255,.78);border-radius:28px;
  background:transparent;mix-blend-mode:normal;opacity:1;filter:none;
  box-shadow:0 16px 34px rgba(42,77,63,.16);
}
body.dark-mode .hero.hero-redesign .hero-art img,
body.dark-theme .hero.hero-redesign .hero-art img{
  mix-blend-mode:normal;opacity:1;border-color:rgba(151,190,165,.24);
  box-shadow:0 16px 36px rgba(0,0,0,.32);
}
body.dark-mode .hero.hero-redesign .hero-secondary,
body.dark-theme .hero.hero-redesign .hero-secondary{
  background:rgba(37,61,52,.88);border-color:#496252;color:#e7f4eb!important;
}
body.dark-mode .hero.hero-redesign .hero-note,
body.dark-theme .hero.hero-redesign .hero-note{color:#c3d4ca}
body.dark-mode .hero.hero-redesign .hero-note i,
body.dark-theme .hero.hero-redesign .hero-note i{color:#a7dfc1}
@media(max-width:760px){
  .hero.hero-redesign{width:calc(100% - 22px)!important;margin:86px auto 24px!important;border-radius:25px}
  .hero.hero-redesign .hero-inner{grid-template-columns:minmax(0,1fr);gap:4px;padding:23px 18px 18px;min-height:0}
  .hero.hero-redesign .hero-copy{padding:5px 0 0;max-width:none}
  .hero.hero-redesign .hero-copy h1{font-size:clamp(1.85rem,7.8vw,2.55rem);line-height:1.45}
  .hero.hero-redesign .hero-actions{gap:9px}
  .hero.hero-redesign .hero-primary,.hero.hero-redesign .hero-secondary{min-height:44px;padding:0 13px;font-size:.82rem;border-radius:13px}
  .hero.hero-redesign .hero-art{min-height:0;margin:15px auto 0;width:100%;max-width:390px}
  .hero.hero-redesign .hero-art img{width:100%;height:auto;max-width:100%;max-height:none;aspect-ratio:1000 / 839;border-radius:20px}
  .hero.hero-redesign .hero-art::before{width:72%;max-width:270px}
  .hero.hero-redesign .hero-note{margin-top:17px;gap:9px;font-size:.75rem}
}
@media(max-width:380px){
  .hero.hero-redesign .hero-inner{padding:21px 14px 15px}
  .hero.hero-redesign .hero-primary,.hero.hero-redesign .hero-secondary{width:100%;}
}


/* Hero v22 — full-bleed illustrated background with real HTML content on the clear side. */
.hero.hero-redesign {
  position:relative!important;
  width:100%!important;
  max-width:none!important;
  min-height:clamp(500px,40vw,640px)!important;
  margin:98px 0 34px!important;
  padding:0!important;
  box-sizing:border-box!important;
  overflow:hidden!important;
  border:0!important;
  border-radius:0 0 32px 32px!important;
  background-color:#fffaf0!important;
  background-image:url('/hero-storybook-day.webp')!important;
  background-position:center center!important;
  background-repeat:no-repeat!important;
  background-size:cover!important;
  box-shadow:0 18px 42px rgba(42,77,63,.10)!important;
}
.hero.hero-redesign::before {
  content:"";
  position:absolute;
  inset:0;
  z-index:0;
  pointer-events:none;
  background:linear-gradient(to left,
    rgba(255,253,246,.98) 0%,
    rgba(255,253,246,.94) 25%,
    rgba(255,253,246,.72) 39%,
    rgba(255,253,246,.18) 56%,
    rgba(255,253,246,0) 68%);
}
.hero.hero-redesign .hero-inner {
  position:relative!important;
  z-index:1!important;
  display:flex!important;
  flex-direction:row!important;
  justify-content:flex-start!important;
  align-items:center!important;
  direction:rtl!important;
  width:100%!important;
  min-height:inherit!important;
  box-sizing:border-box!important;
  padding:clamp(34px,4.4vw,62px) clamp(24px,5.2vw,82px)!important;
  gap:0!important;
}
.hero.hero-redesign .hero-copy {
  width:min(45%,650px)!important;
  max-width:650px!important;
  min-width:0!important;
  margin:0!important;
  padding:12px 0!important;
  text-align:right!important;
}
.hero.hero-redesign .hero-copy h1 {
  color:#28544d!important;
  text-shadow:0 1px 0 rgba(255,255,255,.18);
  font-size:clamp(2rem,3.8vw,3.45rem)!important;
  line-height:1.42!important;
  margin-bottom:14px!important;
}
.hero.hero-redesign .hero-copy h1 span { color:#df7540!important; }
.hero.hero-redesign .hero-copy p {
  color:#506b63!important;
  max-width:620px!important;
  font-size:clamp(.96rem,1.25vw,1.08rem)!important;
  line-height:2.05!important;
}
.hero.hero-redesign .hero-kicker {
  color:#315b4d!important;
  background:rgba(255,255,255,.78)!important;
  border:1px solid rgba(62,131,104,.16)!important;
  box-shadow:0 4px 14px rgba(36,77,62,.05);
}
.hero.hero-redesign .hero-actions { gap:10px!important; }
.hero.hero-redesign .hero-primary {
  background:linear-gradient(135deg,#f28a38,#e66b2c)!important;
  box-shadow:0 8px 18px rgba(207,104,43,.22)!important;
  color:#fff!important;
}
.hero.hero-redesign .hero-secondary {
  background:rgba(255,255,255,.82)!important;
  border-color:rgba(62,122,100,.26)!important;
  color:#28594e!important;
  backdrop-filter:blur(6px);
}
.hero.hero-redesign .hero-note {
  color:#536e65!important;
  gap:12px 18px!important;
}
.hero.hero-redesign .hero-note i { color:#278c76!important; }

/* Dark theme uses a separate night illustration, not a black filter over the day image. */
html.hero-theme-dark .hero.hero-redesign,
body.dark-mode .hero.hero-redesign,
body.dark-theme .hero.hero-redesign {
  background-color:#071634!important;
  background-image:url('/hero-storybook-night.webp')!important;
  border-color:transparent!important;
  box-shadow:0 18px 48px rgba(0,0,0,.28)!important;
}
html.hero-theme-dark .hero.hero-redesign::before,
body.dark-mode .hero.hero-redesign::before,
body.dark-theme .hero.hero-redesign::before {
  background:linear-gradient(to left,
    rgba(6,17,43,.97) 0%,
    rgba(6,17,43,.92) 25%,
    rgba(6,17,43,.70) 40%,
    rgba(6,17,43,.22) 57%,
    rgba(6,17,43,0) 69%);
}
html.hero-theme-dark .hero.hero-redesign .hero-copy h1,
body.dark-mode .hero.hero-redesign .hero-copy h1,
body.dark-theme .hero.hero-redesign .hero-copy h1 { color:#f4f6ff!important; }
html.hero-theme-dark .hero.hero-redesign .hero-copy h1 span,
body.dark-mode .hero.hero-redesign .hero-copy h1 span,
body.dark-theme .hero.hero-redesign .hero-copy h1 span { color:#ffc15d!important; }
html.hero-theme-dark .hero.hero-redesign .hero-copy p,
body.dark-mode .hero.hero-redesign .hero-copy p,
body.dark-theme .hero.hero-redesign .hero-copy p { color:#d2def6!important; }
html.hero-theme-dark .hero.hero-redesign .hero-kicker,
body.dark-mode .hero.hero-redesign .hero-kicker,
body.dark-theme .hero.hero-redesign .hero-kicker {
  color:#e5edff!important;
  background:rgba(18,38,79,.86)!important;
  border-color:rgba(157,190,255,.22)!important;
}
html.hero-theme-dark .hero.hero-redesign .hero-secondary,
body.dark-mode .hero.hero-redesign .hero-secondary,
body.dark-theme .hero.hero-redesign .hero-secondary {
  color:#f4f6ff!important;
  background:rgba(16,35,75,.84)!important;
  border-color:rgba(172,198,255,.38)!important;
}
html.hero-theme-dark .hero.hero-redesign .hero-primary,
body.dark-mode .hero.hero-redesign .hero-primary,
body.dark-theme .hero.hero-redesign .hero-primary {
  color:#1c2742!important;
  background:linear-gradient(135deg,#ffd269,#f3a52f)!important;
}
html.hero-theme-dark .hero.hero-redesign .hero-note,
body.dark-mode .hero.hero-redesign .hero-note,
body.dark-theme .hero.hero-redesign .hero-note { color:#c8d8f4!important; }
html.hero-theme-dark .hero.hero-redesign .hero-note i,
body.dark-mode .hero.hero-redesign .hero-note i,
body.dark-theme .hero.hero-redesign .hero-note i { color:#70d9cf!important; }

@media (min-width:761px) and (max-width:1050px) {
  .hero.hero-redesign { min-height:510px!important; background-position:46% center!important; }
  .hero.hero-redesign .hero-inner { padding-inline:28px!important; }
  .hero.hero-redesign .hero-copy { width:49%!important; }
  .hero.hero-redesign .hero-copy h1 { font-size:clamp(1.9rem,4vw,2.7rem)!important; }
  .hero.hero-redesign .hero-actions { gap:8px!important; }
  .hero.hero-redesign .hero-primary,.hero.hero-redesign .hero-secondary { padding-inline:13px!important; font-size:.86rem!important; }
}
@media (max-width:760px) {
  .hero.hero-redesign {
    width:100%!important;
    min-height:0!important;
    margin:82px 0 26px!important;
    border-radius:0 0 24px 24px!important;
    background-color:#fffaf0!important;
    background-image:url('/hero-storybook-day.webp')!important;
    background-size:100% auto!important;
    background-position:center bottom!important;
    background-repeat:no-repeat!important;
    box-shadow:0 12px 32px rgba(42,77,63,.09)!important;
  }
  .hero.hero-redesign::before { background:none!important; }
  .hero.hero-redesign .hero-inner {
    display:block!important;
    min-height:0!important;
    padding:27px 18px calc(58vw + 18px)!important;
  }
  .hero.hero-redesign .hero-copy { width:100%!important; max-width:none!important; padding:0!important; }
  .hero.hero-redesign .hero-kicker { margin-bottom:13px!important; font-size:.78rem!important; }
  .hero.hero-redesign .hero-copy h1 { font-size:clamp(1.78rem,7.4vw,2.45rem)!important; line-height:1.48!important; }
  .hero.hero-redesign .hero-copy h1 span { white-space:normal!important; }
  .hero.hero-redesign .hero-copy p { font-size:.93rem!important; line-height:1.95!important; margin-bottom:17px!important; }
  .hero.hero-redesign .hero-actions { display:grid!important; grid-template-columns:1fr!important; gap:9px!important; }
  .hero.hero-redesign .hero-primary,.hero.hero-redesign .hero-secondary { width:100%!important; min-height:44px!important; font-size:.88rem!important; padding-inline:14px!important; border-radius:13px!important; }
  .hero.hero-redesign .hero-note { margin-top:15px!important; gap:8px 13px!important; font-size:.74rem!important; }
  html.hero-theme-dark .hero.hero-redesign,
  body.dark-mode .hero.hero-redesign,
  body.dark-theme .hero.hero-redesign {
    background-color:#071634!important;
    background-image:url('/hero-storybook-night.webp')!important;
  }
  html.hero-theme-dark .hero.hero-redesign::before,
  body.dark-mode .hero.hero-redesign::before,
  body.dark-theme .hero.hero-redesign::before { background:none!important; }
}
@media (prefers-reduced-motion:reduce) {
  .hero.hero-redesign .hero-primary,.hero.hero-redesign .hero-secondary { transition:none!important; }
}


/* Hero v23 — lock day/night composition, remove header gap and bottom rounding.
   Mobile uses a dedicated crop beneath the copy instead of a zoomed background behind text. */
.hero.hero-redesign {
  --sq-hero-image: url('/hero-storybook-day.webp');
  --sq-hero-mobile-image: url('/hero-storybook-mobile-day.webp');
  width:100%!important;
  max-width:none!important;
  min-height:clamp(500px,40vw,640px)!important;
  margin:82px 0 28px!important;
  padding:0!important;
  box-sizing:border-box!important;
  overflow:hidden!important;
  border:0!important;
  border-radius:0!important;
  background-color:#fffaf0!important;
  background-image:var(--sq-hero-image)!important;
  background-position:center center!important;
  background-repeat:no-repeat!important;
  background-size:cover!important;
  box-shadow:none!important;
}
html.hero-theme-dark .hero.hero-redesign,
body.dark-mode .hero.hero-redesign,
body.dark-theme .hero.hero-redesign {
  --sq-hero-image:url('/hero-storybook-night.webp');
  --sq-hero-mobile-image:url('/hero-storybook-mobile-night.webp');
  background-color:#071634!important;
  background-image:var(--sq-hero-image)!important;
}
.hero.hero-redesign .hero-inner {
  display:flex!important;
  flex-direction:row!important;
  align-items:center!important;
  justify-content:flex-start!important;
  width:100%!important;
  min-height:inherit!important;
  box-sizing:border-box!important;
  padding:clamp(34px,4.4vw,62px) clamp(24px,5.2vw,82px)!important;
  gap:0!important;
  direction:rtl!important;
}
.hero.hero-redesign .hero-copy {
  width:min(45%,650px)!important;
  max-width:650px!important;
  min-width:0!important;
  margin:0!important;
  padding:12px 0!important;
  text-align:right!important;
}
.hero.hero-redesign .hero-mobile-art { display:none!important; }
.hero.hero-redesign::before {
  background:linear-gradient(to left,
    rgba(255,253,246,.98) 0%,
    rgba(255,253,246,.94) 25%,
    rgba(255,253,246,.72) 39%,
    rgba(255,253,246,.18) 56%,
    rgba(255,253,246,0) 68%)!important;
}
html.hero-theme-dark .hero.hero-redesign::before,
body.dark-mode .hero.hero-redesign::before,
body.dark-theme .hero.hero-redesign::before {
  background:linear-gradient(to left,
    rgba(6,17,43,.97) 0%,
    rgba(6,17,43,.92) 25%,
    rgba(6,17,43,.70) 40%,
    rgba(6,17,43,.22) 57%,
    rgba(6,17,43,0) 69%)!important;
}

@media (min-width:761px) and (max-width:1050px) {
  .hero.hero-redesign { min-height:510px!important; background-position:center center!important; }
  .hero.hero-redesign .hero-inner { padding-inline:28px!important; }
  .hero.hero-redesign .hero-copy { width:49%!important; }
}

@media (max-width:760px) {
  .hero.hero-redesign {
    width:100%!important;
    min-height:0!important;
    margin:68px 0 22px!important;
    padding:0!important;
    border:0!important;
    border-radius:0!important;
    background-color:#fffaf0!important;
    background-image:none!important;
    box-shadow:none!important;
  }
  body.dark-mode .hero.hero-redesign,
  body.dark-theme .hero.hero-redesign,
  html.hero-theme-dark .hero.hero-redesign {
    background-color:#071634!important;
    background-image:none!important;
  }
  .hero.hero-redesign::before { display:none!important; content:none!important; }
  .hero.hero-redesign .hero-inner {
    display:flex!important;
    flex-direction:column!important;
    align-items:stretch!important;
    justify-content:flex-start!important;
    min-height:0!important;
    padding:24px 18px 0!important;
    gap:0!important;
  }
  .hero.hero-redesign .hero-copy {
    width:100%!important;
    max-width:none!important;
    padding:0!important;
    margin:0!important;
  }
  .hero.hero-redesign .hero-copy h1 {
    font-size:clamp(1.78rem,7.4vw,2.45rem)!important;
    line-height:1.48!important;
  }
  .hero.hero-redesign .hero-copy h1 span { white-space:normal!important; }
  .hero.hero-redesign .hero-copy p { font-size:.93rem!important; line-height:1.95!important; }
  .hero.hero-redesign .hero-actions { display:grid!important; grid-template-columns:1fr!important; gap:9px!important; }
  .hero.hero-redesign .hero-primary,
  .hero.hero-redesign .hero-secondary {
    width:100%!important;
    min-height:44px!important;
    font-size:.88rem!important;
    padding-inline:14px!important;
    border-radius:13px!important;
    box-sizing:border-box!important;
  }
  .hero.hero-redesign .hero-note { margin-top:15px!important; gap:8px 13px!important; font-size:.74rem!important; }
  .hero.hero-redesign .hero-mobile-art {
    display:block!important;
    flex:0 0 auto!important;
    width:calc(100% + 36px)!important;
    max-width:none!important;
    aspect-ratio:1230 / 820!important;
    margin:18px -18px 0!important;
    padding:0!important;
    border:0!important;
    border-radius:0!important;
    background-image:var(--sq-hero-mobile-image)!important;
    background-position:center center!important;
    background-size:100% 100%!important;
    background-repeat:no-repeat!important;
  }
  html.hero-theme-dark .hero.hero-redesign .hero-copy h1,
  body.dark-mode .hero.hero-redesign .hero-copy h1,
  body.dark-theme .hero.hero-redesign .hero-copy h1 { color:#f4f6ff!important; }
  html.hero-theme-dark .hero.hero-redesign .hero-copy h1 span,
  body.dark-mode .hero.hero-redesign .hero-copy h1 span,
  body.dark-theme .hero.hero-redesign .hero-copy h1 span { color:#ffc15d!important; }
  html.hero-theme-dark .hero.hero-redesign .hero-copy p,
  body.dark-mode .hero.hero-redesign .hero-copy p,
  body.dark-theme .hero.hero-redesign .hero-copy p { color:#d2def6!important; }
  html.hero-theme-dark .hero.hero-redesign .hero-kicker,
  body.dark-mode .hero.hero-redesign .hero-kicker,
  body.dark-theme .hero.hero-redesign .hero-kicker {
    color:#e5edff!important;
    background:rgba(18,38,79,.86)!important;
    border-color:rgba(157,190,255,.22)!important;
  }
  html.hero-theme-dark .hero.hero-redesign .hero-secondary,
  body.dark-mode .hero.hero-redesign .hero-secondary,
  body.dark-theme .hero.hero-redesign .hero-secondary {
    color:#f4f6ff!important;
    background:rgba(16,35,75,.84)!important;
    border-color:rgba(172,198,255,.38)!important;
  }
  html.hero-theme-dark .hero.hero-redesign .hero-primary,
  body.dark-mode .hero.hero-redesign .hero-primary,
  body.dark-theme .hero.hero-redesign .hero-primary {
    color:#1c2742!important;
    background:linear-gradient(135deg,#ffd269,#f3a52f)!important;
  }
  html.hero-theme-dark .hero.hero-redesign .hero-note,
  body.dark-mode .hero.hero-redesign .hero-note,
  body.dark-theme .hero.hero-redesign .hero-note { color:#c8d8f4!important; }
  html.hero-theme-dark .hero.hero-redesign .hero-note i,
  body.dark-mode .hero.hero-redesign .hero-note i,
  body.dark-theme .hero.hero-redesign .hero-note i { color:#70d9cf!important; }
}
@media (prefers-reduced-motion:reduce) {
  .hero.hero-redesign .hero-primary,.hero.hero-redesign .hero-secondary { transition:none!important; }
}


/* v25: hero typography/content polish; the day and night desktop images share the exact same source geometry. */
@media (min-width:761px) {
  .hero.hero-redesign {
    background-image:var(--sq-hero-image)!important;
    background-position:center center!important;
    background-size:cover!important;
    background-repeat:no-repeat!important;
  }
  html.hero-theme-dark .hero.hero-redesign,
  body.dark-mode .hero.hero-redesign,
  body.dark-theme .hero.hero-redesign {
    --sq-hero-image:url('/hero-storybook-night.webp');
    background-image:var(--sq-hero-image)!important;
    background-position:center center!important;
    background-size:cover!important;
    background-repeat:no-repeat!important;
  }
}
.hero.hero-redesign .hero-copy h1 {
  font-family:'Lalezar','Vazirmatn',Tahoma,sans-serif!important;
  font-weight:400!important;
  font-size:clamp(2.25rem,4vw,3.25rem)!important;
  line-height:1.55!important;
  letter-spacing:0!important;
  margin:0 0 15px!important;
  text-wrap:balance;
}
.hero.hero-redesign .hero-copy h1 span { font-family:inherit!important; font-weight:400!important; }
.hero.hero-redesign .hero-note {
  display:flex!important;
  flex-direction:column!important;
  align-items:flex-start!important;
  justify-content:flex-start!important;
  gap:8px!important;
  margin-top:18px!important;
  line-height:1.9!important;
}
.hero.hero-redesign .hero-note span {
  display:inline-flex!important;
  flex-direction:row!important;
  align-items:center!important;
  gap:8px!important;
}
.hero.hero-redesign .hero-note .hero-note-tagline {
  margin-top:1px!important;
  font-weight:800!important;
}
@media (max-width:760px) {
  .hero.hero-redesign .hero-copy h1 {
    font-family:'Lalezar','Vazirmatn',Tahoma,sans-serif!important;
    font-size:clamp(2rem,8vw,2.55rem)!important;
    line-height:1.55!important;
  }
  .hero.hero-redesign .hero-note { align-items:flex-start!important; }
}

/* AI story maker: render My Stories as a clear secondary action. */
.ai-story-intro-links .ai-my-stories-button{display:inline-flex;align-items:center;justify-content:center;gap:8px;padding:10px 16px;border:1px solid #c8dfcf;border-radius:13px;background:#fffdf7;color:#2a4d4f;text-decoration:none;font-weight:850;box-shadow:0 5px 14px rgba(42,77,79,.08);transition:transform .18s ease,box-shadow .18s ease}
.ai-story-intro-links .ai-my-stories-button:hover{transform:translateY(-1px);box-shadow:0 8px 18px rgba(42,77,79,.13);text-decoration:none}


/* AI Story Maker intro aligned with the native Android story-maker hero */
.ai-story-intro.ai-story-intro-app-style{
  min-height:214px; box-sizing:border-box; padding:24px 26px; border-radius:28px;
  align-items:center; justify-content:flex-start; position:relative; isolation:isolate;
  background-color:#eaf4df;
  background-image:linear-gradient(90deg,rgba(234,244,223,0) 0%,rgba(234,244,223,.18) 32%,rgba(234,244,223,.91) 61%,#eaf4df 100%),url('/hero-storybook-day.webp');
  background-size:cover; background-position:center; border-color:#d7e8c9;
}
.ai-story-intro.ai-story-intro-app-style .ai-story-intro-copy{width:57%;max-width:600px;margin-right:auto;}
.ai-story-intro.ai-story-intro-app-style .ai-story-eyebrow{color:#d18b35;margin-bottom:8px;font-size:.9rem;}
.ai-story-intro.ai-story-intro-app-style h1{color:#214e3c;font-size:clamp(1.45rem,3vw,2rem);line-height:1.55;margin:0 0 8px;}
.ai-story-intro.ai-story-intro-app-style p{color:#476b55;font-size:.9rem;line-height:1.9;}
.ai-story-intro.ai-story-intro-app-style .ai-story-intro-links{margin-top:13px;}
.ai-story-intro.ai-story-intro-app-style .ai-my-stories-button{background:#2d8067;color:#fff;border-color:transparent;}
body.dark-mode .ai-story-intro.ai-story-intro-app-style{
  background-color:#214a39; border-color:#426c55;
  background-image:linear-gradient(90deg,rgba(32,68,52,0) 0%,rgba(32,68,52,.28) 32%,rgba(32,68,52,.91) 61%,#204434 100%),url('/hero-storybook-night.webp');
}
body.dark-mode .ai-story-intro.ai-story-intro-app-style h1{color:#fff;}
body.dark-mode .ai-story-intro.ai-story-intro-app-style p{color:#d9f2e1;}
body.dark-mode .ai-story-intro.ai-story-intro-app-style .ai-story-eyebrow{color:#ffe4a3;}
body.dark-mode .ai-story-intro.ai-story-intro-app-style .ai-my-stories-button{background:#e6f0c7;color:#214e3c;}
@media(max-width:760px){
  .ai-story-intro.ai-story-intro-app-style{min-height:214px;padding:20px 17px;border-radius:24px;background-position:42% center;}
  .ai-story-intro.ai-story-intro-app-style .ai-story-intro-copy{width:59%;}
  .ai-story-intro.ai-story-intro-app-style h1{font-size:1.25rem;line-height:1.6;}
  .ai-story-intro.ai-story-intro-app-style p{font-size:.78rem;line-height:1.8;}
}
@media(max-width:390px){
  .ai-story-intro.ai-story-intro-app-style{padding:17px 13px;min-height:205px;}
  .ai-story-intro.ai-story-intro-app-style .ai-story-intro-copy{width:62%;}
  .ai-story-intro.ai-story-intro-app-style h1{font-size:1.12rem;}
}


/* Requested refinements — November 2026 */
#stories .featured-heading-copy{display:flex;flex:1;min-width:0;flex-direction:column;align-items:flex-start;gap:3px}
#stories .featured-heading-copy .section-title{margin:0!important}
#stories .featured-subtitle{margin:0!important;color:var(--sq-muted,#718078)!important;font-size:.82rem!important;font-weight:600!important;line-height:1.8!important}
@media(max-width:760px){
  #stories .featured-heading-copy{width:100%}
  #stories .featured-subtitle{font-size:.76rem!important}
}

/* Mobile hero CTA buttons: shift 2 mm to the right and give them a more tactile finish. */
@media(max-width:760px){
  .hero.hero-redesign .sq-mobile-hero-button{
    right:calc(25% - 2mm)!important;
    border:1px solid rgba(255,255,255,.9)!important;
    border-radius:999px!important;
    color:#fff!important;
    font-weight:900!important;
    letter-spacing:0!important;
    box-shadow:0 7px 18px rgba(31,55,43,.24),inset 0 1px 0 rgba(255,255,255,.28)!important;
    text-shadow:0 1px 2px rgba(0,0,0,.16)!important;
    transition:transform .18s ease,box-shadow .18s ease,filter .18s ease!important;
  }
  .hero.hero-redesign .sq-mobile-hero-button-1{background:linear-gradient(135deg,#f2a64f,#cc702d)!important}
  .hero.hero-redesign .sq-mobile-hero-button-2{background:linear-gradient(135deg,#42a9c9,#176f96)!important}
  .hero.hero-redesign .sq-mobile-hero-button-3{background:linear-gradient(135deg,#91ad4c,#536f29)!important}
  .hero.hero-redesign .sq-mobile-hero-button:active{filter:brightness(.97)!important;box-shadow:0 3px 9px rgba(31,55,43,.2)!important}
  .hero.hero-redesign .sq-mobile-hero-button:focus-visible{outline:3px solid rgba(255,255,255,.95)!important;outline-offset:3px!important}
}

/* Rebuild the Story Maker workshop banner: copy stays on the clear right side. */
.ai-story-intro.ai-story-intro-app-style{
  min-height:244px;
  padding:24px 28px;
  justify-content:flex-start;
  background-image:linear-gradient(270deg,rgba(247,250,239,.99) 0%,rgba(247,250,239,.95) 39%,rgba(247,250,239,.62) 57%,rgba(247,250,239,0) 78%),url('/hero-storybook-day.webp');
  background-position:center center;
  box-shadow:0 17px 38px rgba(42,77,73,.09);
}
.ai-story-intro.ai-story-intro-app-style .ai-story-intro-copy{
  width:54%;
  max-width:570px;
  margin-right:0;
  margin-left:auto;
  padding:16px 19px;
  box-sizing:border-box;
  text-align:right;
  border:1px solid rgba(255,255,255,.76);
  border-radius:22px;
  background:rgba(255,255,255,.64);
  box-shadow:0 10px 24px rgba(42,77,73,.07),inset 0 1px 0 rgba(255,255,255,.75);
  -webkit-backdrop-filter:blur(9px);
  backdrop-filter:blur(9px);
}
.ai-story-intro.ai-story-intro-app-style .ai-story-eyebrow{
  display:inline-flex;
  align-items:center;
  padding:5px 12px;
  margin:0 0 9px;
  border:1px solid rgba(209,139,53,.18);
  border-radius:999px;
  background:#fff5e4;
  color:#ad6a22;
  font-size:.8rem;
}
.ai-story-intro.ai-story-intro-app-style h1{font-size:clamp(1.42rem,2.65vw,1.9rem);line-height:1.55;margin:0 0 7px}
.ai-story-intro.ai-story-intro-app-style p{font-size:.87rem;line-height:1.9}
body.dark-mode .ai-story-intro.ai-story-intro-app-style{
  background-image:linear-gradient(270deg,rgba(29,53,41,.98) 0%,rgba(29,53,41,.93) 39%,rgba(29,53,41,.60) 58%,rgba(29,53,41,0) 80%),url('/hero-storybook-night.webp');
}
body.dark-mode .ai-story-intro.ai-story-intro-app-style .ai-story-intro-copy{
  background:rgba(24,44,34,.70);
  border-color:rgba(220,243,224,.18);
  box-shadow:0 10px 24px rgba(0,0,0,.18),inset 0 1px 0 rgba(255,255,255,.06);
}
body.dark-mode .ai-story-intro.ai-story-intro-app-style .ai-story-eyebrow{background:rgba(255,228,163,.12);border-color:rgba(255,228,163,.18)}
@media(max-width:760px){
  .ai-story-intro.ai-story-intro-app-style{
    min-height:236px;
    padding:14px;
    border-radius:24px;
    background-position:40% center;
    background-image:linear-gradient(270deg,rgba(247,250,239,.98) 0%,rgba(247,250,239,.93) 47%,rgba(247,250,239,.58) 66%,rgba(247,250,239,.04) 100%),url('/hero-storybook-day.webp');
  }
  .ai-story-intro.ai-story-intro-app-style .ai-story-intro-copy{width:65%;padding:12px 13px;border-radius:18px}
  .ai-story-intro.ai-story-intro-app-style h1{font-size:1.18rem;line-height:1.52}
  .ai-story-intro.ai-story-intro-app-style p{font-size:.75rem;line-height:1.75}
  .ai-story-intro.ai-story-intro-app-style .ai-story-eyebrow{font-size:.72rem;padding:4px 9px}
  body.dark-mode .ai-story-intro.ai-story-intro-app-style{
    background-image:linear-gradient(270deg,rgba(29,53,41,.98) 0%,rgba(29,53,41,.92) 47%,rgba(29,53,41,.58) 66%,rgba(29,53,41,.04) 100%),url('/hero-storybook-night.webp');
  }
}
@media(max-width:390px){
  .ai-story-intro.ai-story-intro-app-style{min-height:226px;padding:11px}
  .ai-story-intro.ai-story-intro-app-style .ai-story-intro-copy{width:67%;padding:10px 11px}
  .ai-story-intro.ai-story-intro-app-style h1{font-size:1.08rem}
  .ai-story-intro.ai-story-intro-app-style p{font-size:.71rem}
}


/* Story Maker workshop banner — image only, with the two requested lines over a soft glass blur. */
.ai-story-intro.ai-story-intro-app-style{
  position:relative!important;
  display:flex!important;
  align-items:center!important;
  justify-content:flex-start!important;
  direction:rtl!important;
  isolation:isolate!important;
  overflow:hidden!important;
  width:100%!important;
  min-height:250px!important;
  box-sizing:border-box!important;
  padding:28px clamp(24px,4vw,48px)!important;
  border:0!important;
  border-radius:28px!important;
  background-color:#eaf4df!important;
  background-image:url('/hero-storybook-day.webp')!important;
  background-size:cover!important;
  background-position:center center!important;
  box-shadow:none!important;
}
.ai-story-intro.ai-story-intro-app-style::before{
  content:"";
  position:absolute;
  z-index:0;
  top:0;
  right:0;
  bottom:0;
  width:56%;
  pointer-events:none;
  background:linear-gradient(to left,rgba(255,252,239,.38) 0%,rgba(255,252,239,.27) 66%,rgba(255,252,239,0) 100%);
  -webkit-backdrop-filter:blur(10px) saturate(1.08);
  backdrop-filter:blur(10px) saturate(1.08);
  -webkit-mask-image:linear-gradient(to left,#000 0%,rgba(0,0,0,.92) 68%,transparent 100%);
  mask-image:linear-gradient(to left,#000 0%,rgba(0,0,0,.92) 68%,transparent 100%);
}
.ai-story-intro.ai-story-intro-app-style .ai-story-intro-copy{
  position:relative!important;
  z-index:1!important;
  display:flex!important;
  flex-direction:column!important;
  align-items:flex-start!important;
  justify-content:center!important;
  width:47%!important;
  max-width:500px!important;
  margin:0!important;
  padding:0!important;
  border:0!important;
  border-radius:0!important;
  background:transparent!important;
  box-shadow:none!important;
  -webkit-backdrop-filter:none!important;
  backdrop-filter:none!important;
  text-align:right!important;
}
.ai-story-intro.ai-story-intro-app-style .ai-story-intro-copy h1{
  margin:0 0 9px!important;
  color:#214e3c!important;
  font-size:clamp(1.75rem,3.1vw,2.35rem)!important;
  font-weight:950!important;
  line-height:1.45!important;
  text-shadow:0 1px 2px rgba(255,255,255,.28)!important;
}
.ai-story-intro.ai-story-intro-app-style .ai-story-intro-copy p{
  margin:0!important;
  color:#42664d!important;
  font-size:clamp(.96rem,1.55vw,1.15rem)!important;
  font-weight:700!important;
  line-height:1.9!important;
  text-shadow:0 1px 2px rgba(255,255,255,.25)!important;
}
body.dark-mode .ai-story-intro.ai-story-intro-app-style{
  border-color:transparent!important;
  background-color:#17324a!important;
  background-image:url('/hero-storybook-night.webp')!important;
  box-shadow:none!important;
}
body.dark-mode .ai-story-intro.ai-story-intro-app-style::before{
  background:linear-gradient(to left,rgba(12,28,53,.44) 0%,rgba(12,28,53,.30) 66%,rgba(12,28,53,0) 100%);
}
body.dark-mode .ai-story-intro.ai-story-intro-app-style .ai-story-intro-copy h1{
  color:#fff!important;
  text-shadow:0 2px 8px rgba(0,0,0,.25)!important;
}
body.dark-mode .ai-story-intro.ai-story-intro-app-style .ai-story-intro-copy p{
  color:#e0eaff!important;
  text-shadow:0 2px 8px rgba(0,0,0,.25)!important;
}
@media(max-width:760px){
  .ai-story-intro.ai-story-intro-app-style{
    min-height:220px!important;
    padding:18px 17px!important;
    border-radius:23px!important;
    background-position:center center!important;
  }
  .ai-story-intro.ai-story-intro-app-style::before{width:59%;}
  .ai-story-intro.ai-story-intro-app-style .ai-story-intro-copy{width:51%!important;}
  .ai-story-intro.ai-story-intro-app-style .ai-story-intro-copy h1{
    margin-bottom:7px!important;
    font-size:clamp(1.25rem,5.1vw,1.65rem)!important;
    line-height:1.5!important;
  }
  .ai-story-intro.ai-story-intro-app-style .ai-story-intro-copy p{
    font-size:clamp(.78rem,3.25vw,.94rem)!important;
    line-height:1.8!important;
  }
}
@media(max-width:390px){
  .ai-story-intro.ai-story-intro-app-style{min-height:204px!important;padding:14px 12px!important;}
  .ai-story-intro.ai-story-intro-app-style .ai-story-intro-copy{width:53%!important;}
  .ai-story-intro.ai-story-intro-app-style .ai-story-intro-copy h1{font-size:1.17rem!important;}
  .ai-story-intro.ai-story-intro-app-style .ai-story-intro-copy p{font-size:.74rem!important;line-height:1.7!important;}
}


/* Monthly ranking cards: keep Persian copy firmly RTL on mobile. */
@media (max-width: 640px) {
  .monthly-story-info,
  .monthly-story-info .monthly-story-kicker,
  .monthly-story-info h3,
  .monthly-story-info p {
    direction: rtl !important;
    text-align: right !important;
    unicode-bidi: plaintext;
  }
  .monthly-story-info { align-items: stretch !important; }
  .monthly-story-score { direction: rtl !important; justify-content: flex-start !important; text-align: right !important; }
  .monthly-votes { margin-right: 0 !important; margin-left: auto !important; text-align: right !important; }
  .monthly-read-link { direction: rtl !important; text-align: right !important; }
}

/* AI story library: visual cards consistent with the public story catalogue. */
.ai-my-stories-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 19px;
  align-items: stretch;
}
.ai-my-story-card {
  min-width: 0;
  overflow: hidden;
  border: 1px solid var(--sq-line);
  border-radius: 23px;
  background: var(--sq-paper);
  box-shadow: 0 10px 25px rgba(43,76,65,.065);
  transition: transform .2s ease, box-shadow .2s ease, border-color .2s ease;
}
.ai-my-story-card:hover {
  transform: translateY(-4px);
  border-color: #c6dfcb;
  box-shadow: 0 16px 32px rgba(43,76,65,.11);
}
.ai-my-story-card-link {
  display: flex;
  height: 100%;
  min-width: 0;
  flex-direction: column;
  color: var(--sq-ink) !important;
  text-decoration: none !important;
}
.ai-my-story-cover {
  position: relative;
  height: 174px;
  overflow: hidden;
  background: linear-gradient(135deg,#dff3e7,#fff2d5);
}
.ai-my-story-cover::after {
  position: absolute;
  inset: 30% 0 0;
  background: linear-gradient(180deg,transparent,rgba(20,43,34,.35));
  content: '';
  pointer-events: none;
}
.ai-my-story-cover img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: 23% center;
  transition: transform .35s ease;
}
.ai-my-story-card:hover .ai-my-story-cover img { transform: scale(1.04); }
.ai-my-story-cover-label {
  position: absolute;
  z-index: 1;
  right: 12px;
  bottom: 11px;
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding: 6px 10px;
  border: 1px solid rgba(255,255,255,.35);
  border-radius: 99px;
  background: rgba(35,79,65,.78);
  color: #fff;
  font-size: .72rem;
  font-weight: 850;
  backdrop-filter: blur(8px);
}
.ai-my-story-card-body {
  display: flex;
  flex: 1;
  min-width: 0;
  flex-direction: column;
  padding: 16px 17px 15px;
  direction: rtl;
  text-align: right;
}
.ai-my-story-card-eyebrow {
  display: flex;
  align-items: center;
  gap: 6px;
  margin-bottom: 7px;
  color: #619274;
  font-size: .72rem;
  font-weight: 900;
}
.ai-my-story-card-body h2 {
  margin: 0 0 7px;
  color: var(--sq-ink);
  font-size: 1.04rem;
  font-weight: 950;
  line-height: 1.7;
  overflow-wrap: anywhere;
}
.ai-my-story-card-body p {
  display: -webkit-box;
  min-height: 3.5em;
  margin: 0;
  overflow: hidden;
  color: var(--sq-muted);
  font-size: .8rem;
  line-height: 1.8;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
}
.ai-my-story-card-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-top: 12px;
}
.ai-my-story-card-meta span {
  display: inline-flex;
  align-items: center;
  min-height: 25px;
  padding: 3px 8px;
  border-radius: 99px;
  background: rgba(223,243,231,.75);
  color: #47775e;
  font-size: .68rem;
  font-weight: 800;
}
.ai-my-story-read-link {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  margin-top: auto;
  padding-top: 13px;
  color: #2e7867;
  font-size: .82rem;
  font-weight: 900;
}
.ai-my-stories-empty { grid-column: 1 / -1; }
body.dark-mode .ai-my-story-card { background: var(--sq-paper); border-color: var(--sq-line); }
body.dark-mode .ai-my-story-card-meta span { background: #294538; color: #c2e6cc; }

/* AI story reader reuses the native story-reader hero and paper reading surface. */
.ai-generated-reader-page .ai-generated-reader-hero { align-items: center; }
.ai-story-reader-cover {
  position: relative;
  display: flex;
  align-items: flex-end;
  justify-content: flex-start;
  background-image: linear-gradient(0deg,rgba(26,55,42,.18),rgba(26,55,42,0)),url('/hero-storybook-day.webp') !important;
  background-position: 24% center !important;
  background-size: cover !important;
}
.ai-story-reader-cover-badge {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  margin: 0 12px 12px;
  padding: 7px 11px;
  border: 1px solid rgba(255,255,255,.35);
  border-radius: 99px;
  background: rgba(40,83,67,.82);
  color: #fff;
  font-size: .74rem;
  font-weight: 900;
  backdrop-filter: blur(8px);
}
.ai-reader-eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  margin-bottom: 8px;
  color: #609071;
  font-size: .8rem;
  font-weight: 900;
}
.ai-reader-tags { justify-content: flex-start !important; margin: 10px 0 3px; }
.ai-reader-tags .ai-reader-setting { background: #e8f3e9; color: #4d765c; }
.ai-reader-created {
  display: flex;
  align-items: center;
  gap: 7px;
  margin-top: 12px;
  color: var(--sq-muted);
  font-size: .78rem;
  font-weight: 750;
}
.ai-reader-content-card { margin-top: 22px !important; }
.ai-reader-content-heading {
  max-width: 770px;
  margin: 0 auto 20px;
  padding-bottom: 15px;
  border-bottom: 1px solid var(--sq-line);
  direction: rtl;
  text-align: right;
}
.ai-reader-content-heading .ai-story-eyebrow { margin: 0 0 3px; }
.ai-reader-content-heading h2 {
  margin: 0;
  color: var(--sq-ink);
  font-size: 1.22rem;
  font-weight: 950;
  line-height: 1.8;
}
.ai-reader-story-content { text-align: justify !important; }
.ai-reader-actions {
  display: flex;
  align-items: center;
  justify-content: flex-start;
  flex-wrap: wrap;
  gap: 10px;
  max-width: 770px;
  margin: 24px auto 0;
  padding-top: 17px;
  border-top: 1px solid var(--sq-line);
}
.ai-reader-actions > * { min-height: 43px; }
.ai-reader-error {
  padding: 34px 22px;
  border: 1px solid var(--sq-line);
  border-radius: 24px;
  background: var(--sq-paper);
  color: var(--sq-ink);
  text-align: center;
}
.ai-reader-error > span {
  display: grid;
  width: 58px;
  height: 58px;
  margin: 0 auto 12px;
  place-items: center;
  border-radius: 19px;
  background: var(--sq-mint);
  color: #397451;
  font-size: 1.4rem;
}
.ai-reader-error h1 { margin: 0 0 7px; font-size: 1.25rem; }
.ai-reader-error p { margin: 0 0 15px; color: var(--sq-muted); line-height: 1.9; }
body.dark-mode .ai-reader-tags .ai-reader-setting { background: #2a4135; color: #c4e3cc; }
@media (max-width: 760px) {
  .ai-my-stories-grid { grid-template-columns: repeat(2,minmax(0,1fr)); gap: 12px; }
  .ai-my-story-cover { height: 128px; }
  .ai-my-story-card-body { padding: 12px 12px 13px; }
  .ai-my-story-card-body h2 { font-size: .9rem; line-height: 1.6; }
  .ai-my-story-card-body p { min-height: 4.9em; font-size: .73rem; line-height: 1.7; }
  .ai-my-story-card-meta { gap: 4px; margin-top: 9px; }
  .ai-my-story-card-meta span { font-size: .62rem; padding: 3px 6px; }
  .ai-my-story-read-link { padding-top: 10px; font-size: .75rem; }
  .ai-generated-reader-page .story-hero { grid-template-columns: minmax(0,1fr) !important; }
  .ai-generated-reader-page .story-hero-img { aspect-ratio: 16 / 9 !important; min-height: 0 !important; height: auto !important; }
  .ai-reader-actions { align-items: stretch; }
  .ai-reader-actions > * { flex: 1 1 calc(50% - 8px); }
  .ai-reader-story-content { text-align: right !important; }
}
@media (max-width: 390px) {
  .ai-my-stories-grid { grid-template-columns: minmax(0,1fr); }
  .ai-my-story-cover { height: 165px; }
}
@media (prefers-reduced-motion: reduce) {
  .ai-my-story-card, .ai-my-story-cover img { transition: none !important; }
}


/* Subscription plans are acquired in the Android app while direct site payment is inactive. */
.subscription-plan-app-only {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  min-height: 36px;
  padding: 6px 12px;
  border: 1px solid #cde7d5;
  border-radius: 999px;
  background: #eff9f1;
  color: #34744e;
  font-size: .76rem;
  font-weight: 900;
  line-height: 1.6;
}
.subscription-app-note {
  align-items: center;
  gap: 15px;
  padding: 18px 19px;
  border: 1px solid #cfe5d4;
  border-style: solid;
  background: linear-gradient(110deg,rgba(223,243,231,.78),rgba(255,249,235,.82));
  color: var(--sq-ink);
  box-shadow: 0 9px 22px rgba(37,77,73,.045);
}
.subscription-app-note .subscription-bazaar-icon {
  display: flex;
  flex: 0 0 150px;
  width: 150px;
  min-height: 0;
  align-items: center;
  justify-content: center;
  box-sizing: border-box;
  padding: 0;
  border: 0;
  border-radius: 0;
  background: transparent;
  box-shadow: none;
}
.subscription-bazaar-icon img { display:block; width:100%; max-width:138px; max-height:48px; height:auto; object-fit:contain; }
.subscription-app-note-copy { flex:1 1 auto; min-width:0; }
.subscription-app-note-copy strong { display:block; margin:0 0 4px; color:#245d40; font-size:.94rem; font-weight:950; }
.subscription-app-note-copy p { margin:0; color:var(--sq-muted); font-size:.81rem; line-height:1.9; }
.subscription-market-link {
  display:inline-flex;
  flex:0 0 auto;
  align-items:center;
  justify-content:center;
  gap:8px;
  min-height:42px;
  padding:0 14px;
  border:1px solid #bfe3ca;
  border-radius:13px;
  background:linear-gradient(135deg,#e5f7e9,#c8efd7);
  color:#245b43 !important;
  text-decoration:none !important;
  font-size:.78rem;
  font-weight:950;
  white-space:nowrap;
  transition:transform .18s ease,box-shadow .18s ease;
}
.subscription-market-link:hover { transform:translateY(-2px); box-shadow:0 8px 17px rgba(9,43,28,.13); }
.subscription-app-note .subscription-bazaar-icon { box-shadow:none; }
body.dark-mode .subscription-plan-app-only { border-color:#385b45; background:#253e30; color:#c8ebd0; }
body.dark-mode .subscription-app-note { border-color:#3c5947; background:linear-gradient(110deg,#243b30,#302f27); }
body.dark-mode .subscription-app-note-copy strong { color:#c8e8ce; }
body.dark-mode .subscription-app-note .subscription-bazaar-icon { border:0; background:transparent; box-shadow:none; }
@media (max-width: 640px) {
  .subscription-app-note { align-items:stretch; flex-wrap:wrap; gap:11px; padding:14px; }
  .subscription-app-note .subscription-bazaar-icon { flex-basis:132px; width:132px; min-height:48px; height:auto; border-radius:13px; }
  .subscription-bazaar-icon img { max-width:120px; max-height:42px; }
  .subscription-app-note-copy { flex:1 1 calc(100% - 146px); }
  .subscription-app-note-copy strong { font-size:.85rem; }
  .subscription-app-note-copy p { font-size:.75rem; line-height:1.85; }
  .subscription-market-link { display:none!important; }
  .subscription-plan-app-only { font-size:.72rem; }
}

/* Premium story tags: one consistent crown badge across cards. */
.featured-premium-badge, .monthly-premium-badge { display:inline-flex!important; align-items:center!important; gap:6px!important; direction:rtl!important; }
