/**
 * Whitesand Beauty: inner pages (about, contact, journal index, article)
 *  1. Tokens and shared parts: page head, buttons, links, photo frames, closing call to action
 *  2. Contact: details list + message form
 *  3. About: portrait split, story, principles, image band, team
 *  4. Journal index: category filter, lead article, article grid, pagination, empty state
 *  5. Article: head, cover, table of contents, prose, review, sources, share, related
 *
 * Enqueued on every page except the front page (functions.php) and linked by the preview server.
 * Monochrome only; Persian is never set in mono, uppercase or tracked.
 */

/* ================================================================ 1. Tokens and shared parts */

.ws-page {
    color: var(--p-ink);
    padding: 0 var(--p-gutter) clamp(72px, 9vw, 128px);
}

.ws-wrap { max-width: 1280px; margin: 0 auto; }

.ws-page h1,
.ws-page h2,
.ws-page h3 { color: var(--p-ink); text-wrap: balance; }

.ws-page-head {
    padding: clamp(32px, 6vw, 88px) 0 clamp(40px, 5vw, 72px);
}
.ws-page-head__title {
    margin: 0;
    max-width: 16ch;
    font-size: clamp(2.25rem, 1.3rem + 3.4vw, 4.25rem);
    font-weight: 300;
    line-height: 1.15;
    letter-spacing: -0.02em;
}
.ws-page-head__title:lang(fa) { letter-spacing: 0; line-height: 1.4; }
.ws-page-head__lead {
    margin: clamp(18px, 2vw, 26px) 0 0;
    max-width: 50ch;
    font-size: clamp(1rem, 0.95rem + 0.3vw, 1.15rem);
    font-weight: 300;
    line-height: 1.9;
    color: var(--p-soft);
    text-wrap: pretty;
}

/* ================================================================ 2. Contact */

.ws-contact-intro {
    display: grid;
    grid-template-columns: minmax(0, 7fr) minmax(0, 5fr);
    gap: clamp(40px, 6vw, 96px);
    align-items: end;
    padding: clamp(32px, 6vw, 88px) 0 clamp(48px, 6vw, 88px);
}
.ws-contact-intro .ws-page-head { padding: 0; }
.ws-contact-intro .ws-frame { aspect-ratio: 4 / 5; }

.ws-contact {
    display: grid;
    grid-template-columns: minmax(0, 5fr) minmax(0, 7fr);
    gap: clamp(40px, 6vw, 96px);
    align-items: start;
}

.ws-details { margin: 0; border-top: 1px solid var(--p-line); }
.ws-details__row {
    display: grid;
    grid-template-columns: minmax(0, 8rem) minmax(0, 1fr);
    gap: 8px 24px;
    padding: 22px 0;
    border-bottom: 1px solid var(--p-line);
}
.ws-details dt { display: flex; align-items: center; gap: 10px; align-self: start; padding-top: 3px; font-size: 14px; color: var(--p-soft); }
.ws-details dt .ws-ico { color: var(--p-ink); }
.ws-details dd { margin: 0; font-size: 17px; line-height: 1.8; }
.ws-details address { font-style: normal; }
.ws-details dd a:not(.ws-link) { color: inherit; text-decoration: none; }
.ws-details dd a:not(.ws-link):hover { text-decoration: underline; text-underline-offset: 0.3em; text-decoration-thickness: 1px; }
.ws-details__note { display: block; margin-top: 4px; font-size: 14px; color: var(--p-soft); }
.ws-details__links { display: flex; flex-wrap: wrap; gap: 6px 20px; margin-top: 10px; font-size: 14px; }

.ws-hours { max-width: 26rem; margin: 0; padding: 0; list-style: none; }
.ws-hours li { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 16px; font-size: 16px; line-height: 2; }
.ws-hours li span:last-child { white-space: nowrap; }
.ws-hours li span:last-child { color: var(--p-ink); }
.ws-hours li.is-closed span:last-child { color: var(--p-soft); }

/* ================================================================ 3. About */

.ws-about-intro {
    display: grid;
    grid-template-columns: minmax(0, 7fr) minmax(0, 5fr);
    gap: clamp(40px, 6vw, 96px);
    align-items: end;
    padding-top: clamp(32px, 6vw, 88px);
}
.ws-about-intro .ws-page-head { padding: 0; }
.ws-about-intro .ws-frame { aspect-ratio: 4 / 5; }

.ws-story {
    position: relative;
    display: grid;
    grid-template-columns: minmax(0, 5fr) minmax(0, 7fr);
    gap: clamp(40px, 6vw, 96px);
    margin-top: clamp(80px, 10vw, 144px);
}
.ws-story .ws-watermark { inset-block-start: 84px; inset-inline-start: 0; width: clamp(110px, 12vw, 160px); aspect-ratio: 39 / 100; }
.ws-story > :not(.ws-watermark) { position: relative; }
.ws-story__body p {
    margin: 0 0 1.4em;
    max-width: 60ch;
    font-size: 17px;
    font-weight: 300;
    line-height: 2;
    color: var(--p-soft);
}
.ws-story__body p:first-child { font-size: clamp(1.15rem, 1rem + 0.5vw, 1.4rem); line-height: 1.9; color: var(--p-ink); }

.ws-values {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 0 clamp(40px, 6vw, 96px);
    margin: clamp(40px, 5vw, 64px) 0 0;
    padding: 0;
    list-style: none;
}
.ws-values li {
    display: grid;
    grid-template-columns: 52px minmax(0, 1fr);
    gap: 22px;
    padding: 30px 0;
    border-top: 1px solid var(--p-line);
}
.ws-values h3 { margin: 4px 0 8px; font-size: 20px; font-weight: 400; line-height: 1.5; }
.ws-values p { margin: 0; max-width: 46ch; font-size: 16px; font-weight: 300; line-height: 1.9; color: var(--p-soft); }

.ws-band {
    position: relative;
    margin: clamp(80px, 10vw, 144px) 0 0;
    aspect-ratio: 16 / 7;
    background: #F9FEFF;
}
.ws-band img { object-position: 50% 40%; }
/* The portrait leaves white space on its left in both languages, so the line sits there in ink */
.ws-band figcaption {
    position: absolute;
    top: 50%;
    left: clamp(24px, 4vw, 64px);
    transform: translateY(-50%);
    max-width: 11ch;
    font-size: clamp(1.25rem, 0.8rem + 1.5vw, 2.2rem);
    font-weight: 300;
    line-height: 1.4;
    color: #1E1E1E;
    text-wrap: balance;
}

.ws-team { margin-top: clamp(80px, 10vw, 144px); }
.ws-team__head { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); gap: clamp(40px, 6vw, 96px); align-items: end; }
.ws-team__head p { margin: 0; max-width: 50ch; color: var(--p-soft); line-height: 1.9; }
.ws-team__list { margin: clamp(32px, 4vw, 56px) 0 0; padding: 0; list-style: none; border-top: 1px solid var(--p-line); }
.ws-team__list li {
    display: grid;
    grid-template-columns: minmax(0, 5fr) minmax(0, 4fr) minmax(0, 3fr);
    gap: 6px clamp(24px, 4vw, 56px);
    align-items: baseline;
    padding: 26px 0;
    border-bottom: 1px solid var(--p-line);
}
.ws-team__name { margin: 0; font-size: clamp(1.15rem, 1rem + 0.5vw, 1.4rem); font-weight: 300; }
.ws-team__role { display: inline-flex; align-items: center; gap: 8px; font-size: 15px; }
.ws-team__role .ws-ico { width: 17px; height: 17px; color: var(--p-soft); }
.ws-team__focus { font-size: 15px; color: var(--p-soft); }

/* ================================================================ 4. Journal index */

.ws-filter {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin: 0 0 clamp(36px, 4vw, 56px);
    padding: 0;
    list-style: none;
}
.ws-filter a {
    display: inline-flex;
    align-items: center;
    min-height: 40px;
    padding: 0 18px;
    border: 1px solid var(--p-line);
    border-radius: 9999px;
    color: var(--p-ink);
    font-size: 14px;
    text-decoration: none;
    transition: border-color 0.3s ease, background-color 0.3s ease, color 0.3s ease;
}
.ws-filter a:hover { border-color: var(--p-ink); }
.ws-filter a[aria-current="page"] { background: var(--p-ink); border-color: var(--p-ink); color: var(--p-bg); }
.ws-filter a:focus-visible { outline: 1px solid var(--p-ink); outline-offset: 3px; }

.ws-meta {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 4px 0;
    font-size: 14px;
    color: var(--p-soft);
}
.ws-meta > * + *::before { content: "·"; margin: 0 10px; opacity: 0.7; }
.ws-meta__item { display: inline-flex; align-items: center; gap: 6px; }
.ws-meta__item .ws-ico { width: 16px; height: 16px; }
.ws-meta a { color: var(--p-ink); text-decoration: none; }
.ws-meta a:hover { text-decoration: underline; text-underline-offset: 0.3em; }

/* Lead article */
.ws-lead {
    display: grid;
    grid-template-columns: minmax(0, 7fr) minmax(0, 5fr);
    gap: clamp(28px, 5vw, 72px);
    align-items: center;
    padding-bottom: clamp(48px, 6vw, 88px);
    border-bottom: 1px solid var(--p-line);
}
.ws-lead .ws-frame { aspect-ratio: 3 / 2; border-radius: 24px; }
.ws-lead__title { margin: 14px 0 0; font-size: clamp(1.6rem, 1.1rem + 1.8vw, 2.6rem); font-weight: 300; line-height: 1.35; }
.ws-lead__excerpt { margin: 16px 0 0; max-width: 46ch; font-size: 16px; font-weight: 300; line-height: 1.9; color: var(--p-soft); }
.ws-lead__more { margin-top: 24px; font-size: 15px; }

/* Article grid */
.ws-posts {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: clamp(40px, 5vw, 64px) clamp(24px, 3vw, 40px);
    margin: clamp(48px, 6vw, 80px) 0 0;
    padding: 0;
    list-style: none;
}
.ws-post { position: relative; display: flex; flex-direction: column; }
.ws-post .ws-frame { aspect-ratio: 3 / 2; border-radius: 20px; margin-bottom: 20px; }
.ws-post .ws-frame img,
.ws-lead .ws-frame img { transition: transform 0.9s var(--p-ease); }
.ws-post:hover .ws-frame img,
.ws-lead:hover .ws-frame img { transform: scale(1.03); }
.ws-post__title { margin: 10px 0 0; font-size: clamp(1.1rem, 1rem + 0.4vw, 1.3rem); font-weight: 400; line-height: 1.55; }
.ws-post__title a,
.ws-lead__title a { color: inherit; text-decoration: none; }
/* Whole card is clickable through the title link */
.ws-post__title a::after { content: ""; position: absolute; inset: 0; border-radius: 20px; }
.ws-post__title a:focus-visible { outline: none; }
.ws-post__title a:focus-visible::after { outline: 1px solid var(--p-ink); outline-offset: 6px; }
.ws-lead__title a:focus-visible { outline: 1px solid var(--p-ink); outline-offset: 4px; }
.ws-post__excerpt {
    margin: 10px 0 0;
    font-size: 15px;
    font-weight: 300;
    line-height: 1.85;
    color: var(--p-soft);
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
}
.ws-post__meta { position: relative; z-index: 1; }

/* Placeholder when an article has no featured image */
.ws-post:hover .ws-frame--pattern::before,
.ws-lead:hover .ws-frame--pattern::before { transform: translateY(-12px); }

/* Pagination (the_posts_pagination) */
.ws-page .navigation.pagination { margin-top: clamp(56px, 7vw, 96px); }
.ws-page .nav-links { display: flex; flex-wrap: wrap; justify-content: center; gap: 8px; }
.ws-page .nav-links .page-numbers {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 44px;
    height: 44px;
    padding: 0 14px;
    border: 1px solid var(--p-line);
    border-radius: 9999px;
    color: var(--p-ink);
    font-size: 15px;
    text-decoration: none;
}
.ws-page .nav-links .page-numbers:hover { border-color: var(--p-ink); }
.ws-page .nav-links .page-numbers.current { background: var(--p-ink); border-color: var(--p-ink); color: var(--p-bg); }
.ws-page .nav-links .page-numbers.dots { border-color: transparent; }

/* Empty state */
.ws-empty .ws-watermark { position: static; width: 56px; aspect-ratio: 39 / 100; color: var(--p-soft); }
.ws-empty {
    display: grid;
    justify-items: start;
    gap: 14px;
    padding: clamp(40px, 6vw, 72px) 0;
    border-top: 1px solid var(--p-line);
}
.ws-empty h2 { margin: 0; font-size: 22px; font-weight: 400; }
.ws-empty p { margin: 0; max-width: 48ch; color: var(--p-soft); line-height: 1.9; }

/* ================================================================ 5. Article */

.ws-article { --a-measure: 680px; }

.ws-crumbs { max-width: var(--a-measure); margin: 0 auto; padding: clamp(28px, 5vw, 64px) 0 0; }
.ws-crumbs ol { display: flex; flex-wrap: wrap; gap: 4px 0; margin: 0; padding: 0; list-style: none; font-size: 14px; color: var(--p-soft); }
.ws-crumbs li + li::before { content: "/"; margin: 0 10px; opacity: 0.6; }
.ws-crumbs a { color: var(--p-soft); text-decoration: none; }
.ws-crumbs a:hover { color: var(--p-ink); }

.ws-article__head { max-width: var(--a-measure); margin: 0 auto; padding: clamp(28px, 4vw, 56px) 0 clamp(32px, 4vw, 48px); }
.ws-article__title {
    margin: 14px 0 0;
    font-size: clamp(2rem, 1.3rem + 2.4vw, 3.1rem);
    font-weight: 300;
    line-height: 1.2;
    letter-spacing: -0.02em;
}
.ws-article__title:lang(fa) { letter-spacing: 0; line-height: 1.45; }
.ws-article__deck {
    margin: 20px 0 0;
    max-width: 52ch;
    font-size: clamp(1.05rem, 0.95rem + 0.45vw, 1.3rem);
    font-weight: 300;
    line-height: 1.85;
    color: var(--p-soft);
    text-wrap: pretty;
}

.ws-byline {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 16px 32px;
    margin-top: clamp(28px, 3vw, 40px);
    padding-top: 22px;
    border-top: 1px solid var(--p-line);
}
.ws-byline__people { display: flex; align-items: center; gap: 14px; }
.ws-byline__avatar {
    flex: none;
    width: 44px;
    height: 44px;
    border-radius: 50%;
    overflow: hidden;
    background: #1E1E1E;
    color: #F9FEFF;
    display: grid;
    place-items: center;
}
html.dark .ws-byline__avatar { box-shadow: 0 0 0 1px rgba(249, 254, 255, 0.3); }
.ws-byline__avatar img { width: 100%; height: 100%; object-fit: cover; }
.ws-byline__avatar svg { width: 46%; height: auto; }
.ws-byline__name { display: block; font-size: 15px; color: var(--p-ink); }
.ws-byline__review { display: block; margin-top: 2px; font-size: 14px; color: var(--p-soft); }

.ws-article__cover { max-width: 1120px; margin: 0 auto; }
.ws-article__cover .ws-frame { aspect-ratio: 16 / 9; }
.ws-article__cover figcaption { margin-top: 12px; font-size: 13px; color: var(--p-soft); }

/* Body: table of contents | text | share */
.ws-article__layout {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(0, var(--a-measure)) minmax(0, 1fr);
    column-gap: clamp(32px, 4vw, 64px);
    margin-top: clamp(40px, 5vw, 72px);
}
.ws-article__layout > .ws-prose,
.ws-article__end { grid-column: 2; }

.ws-toc {
    grid-column: 1;
    grid-row: 1 / span 2;
    justify-self: end;
    align-self: start;
    position: sticky;
    top: 112px;
    width: 100%;
    max-width: 240px;
}
.ws-toc summary {
    list-style: none;
    font-size: 14px;
    color: var(--p-soft);
    cursor: default;
    pointer-events: none;
}
.ws-toc summary::-webkit-details-marker { display: none; }
.ws-toc ol { margin: 14px 0 0; padding: 0; list-style: none; border-inline-start: 1px solid var(--p-line); }
.ws-toc li a {
    display: block;
    margin-inline-start: -1px;
    padding: 7px 0 7px 0;
    padding-inline-start: 16px;
    border-inline-start: 1px solid transparent;
    color: var(--p-soft);
    font-size: 14px;
    line-height: 1.6;
    text-decoration: none;
    transition: color 0.25s ease, border-color 0.25s ease;
}
.ws-toc li.is-sub a { padding-inline-start: 30px; font-size: 13px; }
.ws-toc li a:hover { color: var(--p-ink); }
.ws-toc li a[aria-current="true"] { color: var(--p-ink); border-inline-start-color: var(--p-ink); }

.ws-share-rail {
    grid-column: 3;
    grid-row: 1;
    justify-self: start;
    align-self: start;
    position: sticky;
    top: 112px;
    display: grid;
    gap: 6px;
}

/* Share buttons (rail and end of article) */
.ws-share { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; }
.ws-share-rail .ws-share { flex-direction: column; align-items: stretch; }
.ws-share__label { font-size: 14px; color: var(--p-soft); margin-inline-end: 6px; }
.ws-share a,
.ws-share button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    min-height: 38px;
    padding: 0 14px;
    border: 1px solid var(--p-line);
    border-radius: 9999px;
    background: transparent;
    color: var(--p-ink);
    font: inherit;
    font-size: 13px;
    text-decoration: none;
    cursor: pointer;
    transition: border-color 0.25s ease;
}
.ws-share .ws-ico { width: 17px; height: 17px; }
.ws-share-rail .ws-share a,
.ws-share-rail .ws-share button { width: 42px; min-height: 42px; padding: 0; }
.ws-share a:hover,
.ws-share button:hover { border-color: var(--p-ink); }
.ws-share a:focus-visible,
.ws-share button:focus-visible { outline: 1px solid var(--p-ink); outline-offset: 2px; }

/* Prose: the article text */
.ws-prose {
    font-size: 18px;
    font-weight: 300;
    line-height: 1.85;
    color: var(--p-ink);
    overflow-wrap: break-word;
}
.ws-prose:lang(fa) { line-height: 2.05; }
.ws-prose > * { margin-top: 0; margin-bottom: 1.35em; }
.ws-prose > :last-child { margin-bottom: 0; }
.ws-prose h2,
.ws-prose h3 { font-weight: 400; scroll-margin-top: 112px; text-wrap: balance; }
.ws-prose h2 { margin: 2.3em 0 0.75em; font-size: clamp(1.45rem, 1.2rem + 0.9vw, 1.8rem); line-height: 1.45; }
.ws-prose h3 { margin: 1.9em 0 0.6em; font-size: 1.2rem; line-height: 1.6; }
/* h4 to h6 sit under h3 at the text size, set apart by weight (500 exists in Sora and Roshan Al). */
.ws-prose :is(h4, h5, h6) { margin: 1.6em 0 0.5em; font-size: 1em; font-weight: 500; line-height: 1.7; }
.ws-prose > :is(h2, h3, h4, h5, h6):first-child { margin-top: 0; }
.ws-prose strong, .ws-prose b { font-weight: 500; }
.ws-prose a { color: var(--p-ink); text-decoration: underline; text-decoration-thickness: 1px; text-underline-offset: 0.28em; }
.ws-prose a:hover { text-decoration-thickness: 2px; }
.ws-prose ul,
.ws-prose ol { padding-inline-start: 1.3em; }
.ws-prose ul { list-style: disc; }
.ws-prose ol { list-style: decimal; }
.ws-prose li { margin: 0.45em 0; padding-inline-start: 0.3em; }
.ws-prose li::marker { color: var(--p-soft); }
.ws-prose hr { height: 1px; margin: 3em 0; border: 0; background: var(--p-line); }

.ws-prose blockquote,
.ws-prose .wp-block-quote,
.ws-prose .wp-block-pullquote {
    margin: 2.2em 0;
    padding: 0;
    padding-inline-start: 26px;
    border: 0;
    border-inline-start: 2px solid var(--p-ink);
    font-size: clamp(1.2rem, 1.05rem + 0.6vw, 1.5rem);
    line-height: 1.75;
    text-align: start;
}
.ws-prose blockquote p { margin: 0; }
.ws-prose blockquote cite { display: block; margin-top: 12px; font-size: 14px; font-style: normal; color: var(--p-soft); }

.ws-prose figure,
.ws-prose .wp-block-image { margin: 2.4em 0; }
.ws-prose img { display: block; max-width: 100%; height: auto; border-radius: 18px; }
.ws-prose figcaption,
.ws-prose .wp-element-caption { margin-top: 12px; font-size: 14px; line-height: 1.7; color: var(--p-soft); text-align: start; }
.ws-prose .alignwide { margin-inline: clamp(-120px, -8vw, 0px); }

/* Tables scroll inside their own box on small screens */
.ws-prose .wp-block-table,
.ws-prose .ws-table { margin: 2.2em 0; overflow-x: auto; }
.ws-prose table { width: 100%; border-collapse: collapse; font-size: 15px; line-height: 1.7; }
.ws-prose th,
.ws-prose td { padding: 12px 14px; border-bottom: 1px solid var(--p-line); text-align: start; vertical-align: top; }
.ws-prose th { font-weight: 500; border-bottom-color: var(--p-ink); white-space: nowrap; }
.ws-prose td:first-child,
.ws-prose th:first-child { padding-inline-start: 0; }

/* Clinical note: core/group block style "ws-note" or <aside class="ws-note"> */
.ws-prose .ws-note,
.ws-prose .is-style-ws-note {
    margin: 2.2em 0;
    padding: 22px 26px;
    border-radius: 18px;
    background: var(--p-surface);
    font-size: 16px;
    line-height: 1.9;
}
.ws-prose .ws-note > :first-child,
.ws-prose .is-style-ws-note > :first-child { margin-top: 0; }
.ws-prose .ws-note > :last-child,
.ws-prose .is-style-ws-note > :last-child { margin-bottom: 0; }
.ws-prose .ws-note strong:first-child { display: block; margin-bottom: 6px; }

/* After the text */
.ws-article__end { margin-top: clamp(48px, 6vw, 72px); }

.ws-review {
    display: grid;
    grid-template-columns: 52px minmax(0, 1fr);
    align-items: center;
    column-gap: 18px;
    padding: 24px 0;
    border-block: 1px solid var(--p-line);
    font-size: 15px;
    line-height: 1.8;
}
.ws-review strong { display: block; font-weight: 500; }
.ws-review span { display: block; color: var(--p-soft); }

.ws-sources { margin-top: 32px; }
.ws-sources h2 { margin: 0 0 12px; font-size: 16px; font-weight: 500; }
.ws-sources ol { margin: 0; padding-inline-start: 1.3em; list-style: decimal; font-size: 14px; line-height: 1.8; color: var(--p-soft); }
.ws-sources li { margin: 6px 0; overflow-wrap: anywhere; }
.ws-sources a { color: inherit; }

.ws-disclaimer { margin: 32px 0 0; font-size: 13px; line-height: 1.9; color: var(--p-soft); }

.ws-tags { display: flex; flex-wrap: wrap; gap: 8px; margin: 28px 0 0; padding: 0; list-style: none; }
.ws-tags a { font-size: 14px; color: var(--p-soft); text-decoration: none; }
.ws-tags a::before { content: "#"; opacity: 0.6; }
.ws-tags a:hover { color: var(--p-ink); }

.ws-article__share-end { margin-top: 28px; }

.ws-article-cta {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    align-items: center;
    gap: 20px 32px;
    margin-top: 48px;
    padding: clamp(24px, 3vw, 36px);
    border: 1px solid var(--p-line);
    border-radius: 24px;
}
.ws-article-cta .ws-btn .ws-ico { width: 17px; height: 17px; }
.ws-article-cta h2 { margin: 0; font-size: 20px; font-weight: 400; line-height: 1.6; }
.ws-article-cta p { margin: 6px 0 0; font-size: 15px; color: var(--p-soft); line-height: 1.8; }

.ws-related { margin-top: clamp(80px, 10vw, 128px); padding-top: clamp(32px, 4vw, 48px); border-top: 1px solid var(--p-line); }
.ws-related .ws-posts { margin-top: clamp(28px, 3vw, 40px); }

/* Copy-link confirmation */
.ws-toast {
    position: fixed;
    inset-inline: 0;
    bottom: calc(110px + env(safe-area-inset-bottom, 0px));
    z-index: 70;
    width: max-content;
    max-width: calc(100vw - 32px);
    margin: 0 auto;
    padding: 12px 18px;
    border-radius: 9999px;
    background: #1E1E1E;
    color: #F9FEFF;
    font-size: 14px;
    opacity: 0;
    transform: translateY(8px);
    transition: opacity 0.3s ease, transform 0.4s cubic-bezier(0.16, 1, 0.3, 1);
    pointer-events: none;
}
html.dark .ws-toast { background: #F9FEFF; color: #1E1E1E; }
.ws-toast.is-on { opacity: 1; transform: none; }

/* ================================================================ Responsive */

@media (max-width: 1100px) {
    .ws-article__layout { grid-template-columns: minmax(0, 1fr); }
    .ws-article__layout > .ws-prose,
    .ws-article__end { grid-column: 1; }
    .ws-share-rail { display: none; }
    .ws-toc {
        grid-column: 1;
        grid-row: auto;
        position: static;
        justify-self: stretch;
        max-width: none;
        margin-bottom: 40px;
        padding: 4px 20px;
        border-radius: 18px;
        background: var(--p-surface);
    }
    .ws-toc summary {
        display: flex;
        justify-content: space-between;
        align-items: center;
        min-height: 52px;
        color: var(--p-ink);
        font-size: 15px;
        pointer-events: auto;
        cursor: pointer;
    }
    .ws-toc summary::after { content: "+"; font-size: 20px; font-weight: 300; }
    .ws-toc[open] summary::after { content: "−"; }
    .ws-toc ol { margin: 0 0 16px; }
    .ws-prose .alignwide { margin-inline: 0; }
}

@media (max-width: 1024px) {
    .ws-contact { grid-template-columns: minmax(0, 1fr); }
}

@media (max-width: 900px) {
    .ws-contact-intro,
    .ws-about-intro,
    .ws-story,
    .ws-team__head,
    .ws-lead { grid-template-columns: minmax(0, 1fr); }
    .ws-about-intro .ws-frame,
    .ws-contact-intro .ws-frame { aspect-ratio: 4 / 3; }
    .ws-contact-intro .ws-frame img { object-position: 50% 25%; }
    .ws-values { grid-template-columns: minmax(0, 1fr); }
    .ws-about-intro .ws-frame img { object-position: 50% 35%; }
    .ws-posts { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .ws-team__list li { grid-template-columns: minmax(0, 1fr); }
    /* Phones: the photo alone, the line below it */
    .ws-band { aspect-ratio: auto; background: none; overflow: visible; border-radius: 0; }
    .ws-band img { height: auto; aspect-ratio: 4 / 3; border-radius: 28px; }
    .ws-band figcaption { position: static; transform: none; max-width: 22ch; margin-top: 18px; color: var(--p-ink); }
}

@media (max-width: 640px) {
    .ws-posts { grid-template-columns: minmax(0, 1fr); }
    .ws-details__row { grid-template-columns: minmax(0, 1fr); gap: 4px; }
    .ws-article-cta { grid-template-columns: minmax(0, 1fr); align-items: start; }
    .ws-prose { font-size: 17px; }
}

@media (prefers-reduced-motion: reduce) {
    .ws-post .ws-frame img,
    .ws-lead .ws-frame img,
    .ws-toast { transition: none; }
    .ws-post:hover .ws-frame img,
    .ws-lead:hover .ws-frame img { transform: none; }
}

/* ================================================================ 6. Patient account (page-account.php) */

.ws-account__ways { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 380px), 1fr)); gap: clamp(24px, 3vw, 40px); align-items: start; }
.ws-account__list { margin: 20px 0 24px; padding: 0; list-style: none; border-top: 1px solid var(--p-line); }
.ws-account__appt { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 12px 24px; padding: 18px 0; border-bottom: 1px solid var(--p-line); }
.ws-account__when { margin: 0; font-size: 17px; color: var(--p-ink); }
.ws-account__what { margin: 4px 0 0; font-size: 15px; color: var(--p-ink); }
.ws-account__links { display: flex; flex-wrap: wrap; gap: 8px 20px; margin: 18px 0 0; font-size: 14px; }
.ws-login form { display: grid; gap: 16px; margin-top: 20px; }
.ws-login form p { display: grid; gap: 8px; margin: 0; }
.ws-login label { font-size: 14px; color: var(--p-soft); }
.ws-login input[type="text"],
.ws-login input[type="password"] { width: 100%; min-height: 52px; padding: 13px 16px; border: 1px solid var(--p-line); border-radius: 14px; background: var(--p-bg); color: var(--p-ink); font: inherit; }
.ws-login .login-remember label { display: flex; align-items: center; gap: 8px; }
.ws-login input[type="submit"] { min-height: 48px; padding: 0 26px; border: 1px solid var(--p-ink); border-radius: 9999px; background: var(--p-ink); color: var(--p-bg); font: inherit; cursor: pointer; }

/* ================================================================ 7. Language note, privacy, not found */

/* Persian text shown on the English site (an article without an English version yet) takes its face
   from the [lang] rule in components.css. */
.ws-lang-note {
    display: inline-flex;
    margin: 18px 0 0;
    padding: 6px 14px;
    border: 1px solid var(--p-line);
    border-radius: 9999px;
    font-size: 14px;
    color: var(--p-soft);
}

/* Privacy (page-privacy.php): page head, then numbered sections in the article measure */
.ws-legal { max-width: 720px; }
.ws-legal .ws-prose > h2 { margin-top: 2.2em; }
.ws-legal .ws-prose > h2:first-child { margin-top: 0; }
.ws-legal__updated { margin: 14px 0 0; font-size: 14px; color: var(--p-soft); }

/* Not found (404.php) */
.ws-notfound {
    display: grid;
    justify-items: start;
    gap: 18px;
    max-width: 640px;
    padding: clamp(48px, 10vw, 140px) 0 clamp(24px, 4vw, 48px);
}
.ws-notfound .ws-watermark { position: static; width: 48px; aspect-ratio: 39 / 100; color: var(--p-soft); }
.ws-notfound .ws-page-head__title { max-width: 14ch; }
.ws-notfound p { margin: 0; max-width: 46ch; font-size: clamp(1rem, 0.95rem + 0.3vw, 1.15rem); font-weight: 300; line-height: 1.9; color: var(--p-soft); }
.ws-notfound__actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 10px; }
