/* Public reading pages share the homepage's visual tokens, without app styles. */
.tp-editorial .tp-home {
    background: #fcfbfd;
}
.tp-editorial .tp-home a {
    color: inherit;
}
.tp-editorial .tp-nav-links {
    gap: 28px;
}
.tp-editorial .tp-home .tp-button {
    color: #fff;
}
.tp-editorial .language-dropdown summary {
    list-style: none;
}
.tp-editorial .tp-skip {
    text-decoration: underline;
}
.ed-breadcrumb {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    font-size: 12px;
    color: #817783;
    padding-block: 26px;
    line-height: 1.8;
    overflow-wrap: anywhere;
}
.ed-breadcrumb a:hover {
    color: var(--tp-pink);
    text-decoration: underline;
}
.ed-breadcrumb [aria-current] {
    color: #554a58;
}
.ed-hero {
    padding: 24px 0 40px;
    max-width: 1000px;
}
.ed-category {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    color: #ba2050;
    background: #ffedf3;
    padding: 7px 13px;
    border: 1px solid #f6dfe8;
    border-radius: 30px;
    font-size: 11px;
    font-weight: 600;
}
.tp-editorial .ed-category svg {
    width: 16px;
    height: 16px;
}
.tp-editorial .tp-home h1 {
    max-width: 960px;
    margin: 22px 0;
    font-size: clamp(32px, 3.7vw, 52px);
    line-height: 1.14;
    letter-spacing: -1.8px;
    text-wrap: balance;
    overflow-wrap: anywhere;
}
.tp-editorial .ed-intro {
    max-width: 800px;
    font-size: 16px;
    line-height: 1.85;
    color: #706774;
}
.ed-meta {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 12px 22px;
    margin-top: 25px;
    font-size: 11px;
    color: #817483;
}
.ed-author {
    display: inline-flex;
    align-items: center;
    gap: 9px;
    color: #403745;
    font-weight: 600;
}
.ed-author img {
    border-radius: 8px;
}
.ed-layout {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 280px;
    align-items: start;
    gap: 32px;
    padding-bottom: 32px;
}
.ed-paper {
    min-width: 0;
    overflow: hidden;
    border: 1px solid #eae3ec;
    background: #fff;
    border-radius: 24px;
}
.ed-cover {
    width: 100%;
    height: auto;
    aspect-ratio: 16/9;
    object-fit: cover;
    display: block;
    background: #f2edf5;
}
.ed-prose {
    padding: 38px 44px 44px;
    font-size: 16px;
    line-height: 1.9;
    color: #514959;
    overflow-wrap: anywhere;
}
.tp-editorial .ed-prose :is(p, ul, ol, blockquote, table, figure) {
    margin: 0 0 22px;
}
.tp-editorial .ed-prose :is(h2, h3, h4, h5, h6) {
    scroll-margin-top: 28px;
    color: #28222d;
    text-wrap: pretty;
    line-height: 1.35;
    letter-spacing: -0.5px;
}
.tp-editorial .ed-prose h2 {
    margin: 38px 0 18px;
    font-size: 27px;
}
.tp-editorial .ed-prose h3 {
    margin: 28px 0 14px;
    font-size: 21px;
}
.tp-editorial .ed-prose h4 {
    margin: 24px 0 12px;
    font-size: 18px;
}
.tp-editorial .ed-prose > :first-child {
    margin-top: 0;
}
.tp-editorial .ed-prose > :last-child {
    margin-bottom: 0;
}
.tp-editorial .ed-prose a {
    color: #cf1b51;
    text-decoration: underline;
    text-underline-offset: 3px;
}
.ed-prose :is(ul, ol) {
    padding-inline-start: 26px;
}
.ed-prose li {
    margin-block: 10px;
    padding-inline-start: 4px;
}
.ed-prose li::marker {
    color: #cc3764;
}
.ed-prose img,
.ed-prose video,
.ed-prose iframe {
    max-width: 100%;
    height: auto;
}
.ed-prose img {
    border-radius: 14px;
}
.ed-prose blockquote {
    padding: 20px 24px;
    background: #fff4f8;
    border-inline-start: 3px solid #e91955;
    border-radius: 0 14px 14px 0;
}
.ed-prose table {
    display: block;
    overflow-x: auto;
    border-collapse: collapse;
}
.ed-prose :is(th, td) {
    padding: 12px;
    border: 1px solid #eee5ed;
    text-align: start;
}
.ed-prose pre {
    overflow-x: auto;
    padding: 18px;
    background: #f8f5f9;
    border-radius: 12px;
}
.ed-sidebar {
    position: sticky;
    top: 24px;
    min-width: 0;
}
.ed-toc {
    border: 1px solid #eae3ec;
    border-radius: 20px;
    padding: 22px;
    background: #fff;
}
.ed-toc summary {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 12px;
    cursor: pointer;
    font-size: 14px;
    font-weight: 600;
    list-style: none;
}
.ed-toc summary::-webkit-details-marker {
    display: none;
}
.ed-toc summary > span {
    color: #d93c6a;
    font-size: 22px;
    transition: transform 0.2s;
}
.ed-toc[open] summary > span {
    transform: rotate(45deg);
}
.ed-toc nav {
    display: grid;
    gap: 3px;
    max-height: 42vh;
    overflow-y: auto;
    padding-top: 16px;
    scrollbar-width: thin;
}
.tp-editorial .ed-toc a {
    display: block;
    padding: 8px 10px;
    font-size: 12px;
    color: #7a6f7e;
    line-height: 1.55;
    border-inline-start: 2px solid #eee8ef;
    text-decoration: none;
    overflow-wrap: anywhere;
}
.tp-editorial .ed-toc a:hover,
.tp-editorial .ed-toc a[aria-current] {
    color: #c2174b;
    background: #fff4f8;
    border-color: #e91955;
}
.tp-editorial .ed-toc a.ed-toc-sub {
    padding-inline-start: 20px;
    font-size: 11px;
}
.ed-side-cta {
    margin-top: 20px;
    border: 1px solid #dcece6;
    background: #edf7f3;
    padding: 25px;
    border-radius: 20px;
}
.ed-side-icon {
    display: grid;
    place-items: center;
    width: 42px;
    height: 42px;
    border-radius: 13px;
    color: #40816c;
    background: #d9eee4;
    margin-bottom: 18px;
}
.tp-editorial .ed-side-cta h2 {
    font-size: 25px;
    line-height: 1.2;
    letter-spacing: -0.7px;
}
.tp-editorial .ed-side-cta p {
    margin: 14px 0 22px;
    font-size: 12px;
    line-height: 1.8;
    color: #6c7a73;
}
.tp-editorial .ed-side-cta .tp-button {
    display: flex;
    width: 100%;
    min-height: 48px;
    padding: 13px 10px;
    font-size: 12px;
}
.ed-side-cta small {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 10px;
    color: #667e72;
    margin-top: 16px;
}
.ed-side-cta small svg {
    width: 15px;
    height: 15px;
}
.ed-end-cta {
    padding-block: 28px 70px;
}
.ed-profile-form {
    width: 100%;
    max-width: 620px;
    margin-inline: auto;
    text-align: start;
}
.ed-profile-row {
    display: flex;
    gap: 10px;
}
.ed-profile-input {
    display: flex;
    align-items: center;
    direction: ltr;
    gap: 8px;
    flex: 1;
    min-width: 0;
    padding: 0 14px;
    border: 1px solid #e6dce4;
    border-radius: 13px;
    background: #fff;
    color: #9a8998;
}
.ed-profile-input:focus-within {
    border-color: #f01157;
    box-shadow: 0 0 0 3px #f0115714;
}
.ed-profile-input input {
    width: 100%;
    min-width: 0;
    min-height: 50px;
    padding: 10px 0;
    border: 0;
    outline: 0;
    background: transparent;
    color: #26242b;
    font: inherit;
    font-size: 16px;
}
.ed-profile-input input::placeholder {
    color: #8c7f8d;
    font-size: 12px;
}
.tp-editorial .ed-profile-form .tp-button {
    min-width: 0;
    margin: 0;
    padding: 14px 20px;
    flex-shrink: 0;
}
.ed-submit-label,
.ed-submit-loading {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
}
.ed-profile-form [hidden] {
    display: none !important;
}
.ed-side-cta .ed-profile-row {
    flex-direction: column;
}
.tp-editorial .ed-profile-form .ed-profile-error {
    margin: 10px 0 0;
    color: #b51243;
    font-size: 12px;
    line-height: 1.6;
    overflow-wrap: anywhere;
}
.ed-spinner {
    width: 18px;
    height: 18px;
    border: 2px solid #ffffff60;
    border-top-color: #fff;
    border-radius: 50%;
    animation: ed-spin 0.8s linear infinite;
}
@keyframes ed-spin {
    to {
        transform: rotate(360deg);
    }
}
@media (max-width: 560px) {
    .ed-profile-row {
        flex-direction: column;
    }
    .tp-editorial .ed-profile-form .tp-button {
        width: 100%;
        min-height: 50px;
    }
}
@media (prefers-reduced-motion: reduce) {
    .ed-spinner {
        animation: none;
    }
}
.ed-illustration {
    min-height: 270px;
    position: relative;
    display: flex;
    gap: 28px;
    align-items: center;
    justify-content: center;
    isolation: isolate;
    overflow: hidden;
    background: linear-gradient(120deg, #fff0f6, #f2effc 60%, #eaf8f3);
}
.ed-art-card {
    display: grid;
    gap: 9px;
    place-items: center;
    width: 115px;
    height: 140px;
    padding: 22px;
    border-radius: 20px;
    background: #ffffffdf;
    border: 1px solid #fff;
    box-shadow: 0 10px 30px #8b66991a;
    transform: rotate(-9deg);
}
.ed-art-card:nth-of-type(2) {
    transform: translateY(-14px) rotate(6deg);
}
.ed-art-card:nth-of-type(3) {
    transform: rotate(12deg);
}
.tp-editorial .ed-art-card svg {
    width: 38px;
    height: 38px;
    color: #d74c7a;
}
.ed-art-card:last-child svg {
    color: #6ca391;
}
.ed-art-card i {
    display: block;
    height: 4px;
    width: 48px;
    border-radius: 10px;
    background: #ece4f0;
}
.ed-art-card i:last-child {
    width: 30px;
}
.ed-art-orbit {
    position: absolute;
    width: 90%;
    height: 170px;
    border: 1px solid #fff;
    border-radius: 50%;
    transform: rotate(-14deg);
    z-index: -1;
    pointer-events: none;
}
.ed-art-spark {
    position: absolute;
    inset-inline-end: 35px;
    top: 18px;
    font-size: 44px;
    color: #caabd9;
    z-index: -1;
    pointer-events: none;
}
.ed-related {
    padding-bottom: 65px;
}
.ed-related-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 24px;
}
.ed-related-card {
    display: grid;
    grid-template-columns: 145px minmax(0, 1fr);
    border: 1px solid #e9e2ec;
    border-radius: 20px;
    overflow: hidden;
    background: #fff;
    transition: transform 0.2s, box-shadow 0.2s;
}
.ed-related-card:hover {
    transform: translateY(-3px);
    box-shadow: 0 10px 24px #5b2a6310;
}
.ed-related-card > img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}
.ed-related-card > div {
    padding: 24px;
}
.tp-editorial .ed-related-card h3 {
    font-size: 19px;
    line-height: 1.35;
}
.tp-editorial .ed-related-card p {
    font-size: 12px;
    line-height: 1.75;
    color: #85758a;
    margin-block: 12px 18px;
}
.ed-related-placeholder {
    display: grid;
    place-items: center;
    background: #ebf6f1;
    color: #66a58a;
}
.tp-editorial .ed-related-placeholder svg {
    width: 45px;
    height: 45px;
}
.tp-editorial [dir="rtl"] :is(.ed-hero h1, .ed-prose h2, .ed-prose h3) {
    letter-spacing: 0;
}
.tp-editorial .tp-guide-section {
    padding-bottom: 65px;
}
@media (max-width: 1000px) {
    .ed-layout {
        grid-template-columns: minmax(0, 1fr) 245px;
        gap: 24px;
    }
    .ed-prose {
        padding: 30px;
    }
    .ed-toc {
        padding: 18px;
    }
    .ed-side-cta {
        padding: 20px;
    }
    .ed-related-card {
        grid-template-columns: 110px minmax(0, 1fr);
    }
}
@media (max-width: 800px) {
    .ed-layout {
        display: flex;
        flex-direction: column;
        gap: 24px;
    }
    .ed-sidebar {
        position: static;
        order: -1;
        width: 100%;
    }
    .ed-paper {
        width: 100%;
    }
    .ed-side-cta {
        display: none;
    }
    .ed-toc nav {
        max-height: 330px;
    }
    .ed-related-grid {
        gap: 18px;
    }
    .ed-related-card {
        grid-template-columns: 1fr;
    }
    .ed-related-card > img {
        height: auto;
        aspect-ratio: 16/9;
    }
    .ed-related-placeholder {
        min-height: 160px;
    }
    .ed-hero {
        padding-top: 14px;
    }
}
@media (max-width: 560px) {
    .ed-breadcrumb {
        padding-block: 20px;
        font-size: 11px;
        gap: 6px;
    }
    .ed-hero {
        padding: 12px 0 28px;
    }
    .tp-editorial .tp-home h1 {
        font-size: 34px;
        margin-block: 20px;
        letter-spacing: -1px;
    }
    .tp-editorial .ed-intro {
        font-size: 14px;
        line-height: 1.85;
    }
    .ed-meta {
        gap: 12px 16px;
        font-size: 10px;
        margin-top: 22px;
    }
    .ed-meta .ed-author {
        width: 100%;
    }
    .ed-paper {
        border-radius: 20px;
    }
    .ed-prose {
        padding: 26px 22px;
        font-size: 15px;
        line-height: 1.9;
    }
    .tp-editorial .ed-prose h2 {
        font-size: 24px;
        margin-top: 32px;
    }
    .tp-editorial .ed-prose h3 {
        font-size: 20px;
    }
    .ed-illustration {
        min-height: 205px;
        gap: 16px;
    }
    .ed-art-card {
        width: 75px;
        height: 100px;
        padding: 14px;
        border-radius: 14px;
    }
    .tp-editorial .ed-art-card svg {
        width: 27px;
        height: 27px;
    }
    .ed-art-card i {
        width: 35px;
    }
    .ed-end-cta {
        padding-block: 10px 48px;
    }
    .ed-related-grid {
        grid-template-columns: 1fr;
    }
    .ed-related-card > div {
        padding: 24px;
    }
    .ed-related {
        padding-bottom: 48px;
    }
    .ed-related .tp-journal-heading {
        display: grid;
        gap: 18px;
    }
    .tp-editorial .tp-footer {
        margin-top: 0;
    }
}
@media (prefers-reduced-motion: reduce) {
    .ed-related-card,
    .ed-toc summary > span {
        transition: none;
    }
}

.ed-library {
    padding-bottom: 70px;
}
.ed-library-hero {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 220px;
    align-items: center;
    gap: 45px;
    padding: 45px 0 60px;
}
.tp-editorial .ed-library-hero h1 {
    max-width: 780px;
    margin-top: 16px;
    font-size: clamp(34px, 4.5vw, 58px);
    line-height: 1.12;
    letter-spacing: -1.8px;
}
.tp-editorial .ed-library-hero p {
    max-width: 650px;
    margin-top: 22px;
    color: #7a6f7e;
    font-size: 16px;
}
.ed-library-art {
    position: relative;
    height: 180px;
    display: grid;
    place-items: center;
    background: #f9eaf1;
    border-radius: 45px;
    rotate: -7deg;
}
.ed-library-art > svg {
    width: 110px;
    height: 110px;
    color: #e91955;
    stroke-width: 1;
}
.ed-library-art > span {
    position: absolute;
    inset-inline-start: -18px;
    top: -25px;
    font-size: 72px;
    color: #c99bc5;
}
.ed-library-art i {
    position: absolute;
    bottom: -15px;
    inset-inline-end: -15px;
    padding: 16px;
    background: #e5f5ee;
    border: 5px solid #fcfbfd;
    border-radius: 22px;
    color: #549a7b;
}
.ed-library-art i svg {
    width: 35px;
    height: 35px;
}
.ed-library-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 26px;
}
.ed-library-card {
    min-width: 0;
    border: 1px solid #eee7ee;
    border-radius: 24px;
    background: #fff;
    overflow: hidden;
    transition: box-shadow 0.2s, transform 0.2s;
}
.ed-library-card:hover {
    box-shadow: 0 14px 35px #4c2b5910;
    transform: translateY(-3px);
}
.ed-library-card > a {
    display: flex;
    flex-direction: column;
    height: 100%;
}
.ed-library-card .tp-article-cover {
    width: 100%;
    min-width: 0;
    aspect-ratio: auto;
    margin: 0;
    border: 0;
    border-radius: 0;
    height: 210px;
    flex-shrink: 0;
}
.ed-library-card:nth-child(3n + 2) .tp-article-cover {
    background: #eaf6f1;
    color: #579681;
}
.ed-library-card:nth-child(3n + 3) .tp-article-cover {
    background: #f1ebfa;
    color: #9a7bb6;
}
.ed-library-copy {
    min-width: 0;
    display: flex;
    flex-direction: column;
    flex: 1;
    align-items: flex-start;
    padding: 28px;
}
.tp-editorial .ed-library-copy h2 {
    margin-top: 12px;
    font-size: 22px;
    line-height: 1.3;
    letter-spacing: -0.5px;
}
.tp-editorial .ed-library-copy p {
    margin: 16px 0 24px;
    font-size: 13px;
    line-height: 1.8;
    color: #7a6f7e;
}
.ed-library-copy .tp-text-link {
    margin-top: auto;
}
.ed-library-featured {
    grid-column: 1 / -1;
}
.ed-library-featured > a {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
}
.ed-library-featured .tp-article-cover {
    height: 100%;
    min-height: 330px;
}
.ed-library-featured .ed-library-copy {
    padding: 45px;
}
.tp-editorial .ed-library-featured h2 {
    font-size: 32px;
}
@media (min-width: 801px) {
    .ed-sidebar {
        --sidebar-top: calc(var(--sticky-header-height, 0px) + 24px);
        top: var(--sidebar-top);
        display: flex;
        flex-direction: column;
        max-height: calc(100dvh - var(--sidebar-top) - 16px);
        overflow-y: auto;
        overscroll-behavior: contain;
        scrollbar-width: thin;
    }
    .ed-toc {
        flex: 0 1 auto;
        min-height: 110px;
        overflow-y: auto;
        overscroll-behavior: contain;
        scrollbar-width: thin;
    }
    .ed-toc:not([open]) {
        min-height: auto;
        flex-shrink: 0;
    }
    .ed-toc nav {
        max-height: none;
        overflow: visible;
    }
    .ed-side-cta {
        flex-shrink: 0;
        padding: 20px;
        margin-top: 16px;
    }
    .ed-side-icon {
        width: 32px;
        height: 32px;
        margin-bottom: 12px;
    }
    .tp-editorial .ed-side-cta h2 {
        font-size: 22px;
    }
    .tp-editorial .ed-side-cta p {
        margin-block: 10px 16px;
    }
    .ed-prose :is(h2, h3) {
        scroll-margin-top: calc(var(--sticky-header-height, 0px) + 24px);
    }
}
@media (max-width: 1000px) {
    .ed-library-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
    .ed-library-featured .ed-library-copy {
        padding: 28px;
    }
}
@media (max-width: 600px) {
    .ed-library-hero {
        grid-template-columns: 1fr;
        padding: 28px 0 38px;
        gap: 0;
    }
    .ed-library-art {
        display: none;
    }
    .tp-editorial .ed-library-hero h1 {
        letter-spacing: -1px;
    }
    .ed-library-grid {
        grid-template-columns: 1fr;
        gap: 20px;
    }
    .ed-library-featured > a {
        display: flex;
    }
    .ed-library-featured .tp-article-cover {
        height: 210px;
        min-height: 0;
    }
    .tp-editorial .ed-library-featured h2 {
        font-size: 24px;
    }
    .ed-library-copy,
    .ed-library-featured .ed-library-copy {
        padding: 24px;
    }
}
@media (prefers-reduced-motion: reduce) {
    .ed-library-card {
        transition: none;
    }
}
