/* Samsung Mobile US Press — the stories (WordPress pages). The directory's own stylesheet (press.css, from the chrome) gives the tokens,
   type, masthead, folio, cards and chips; this adds the story page, the reading column, the rail and WordPress's own markup. */

/* the estate keeps WordPress mastheads from sticking (ads sit at the top of the screen); the directory's own pages keep theirs */
body.smup-wp .mast { position: relative; }
.smupt-adslot { margin: 0; padding: 0; }
.smupt-adslot > header:empty { display: none; }

/* a story */
.st { padding-top: clamp(18px, 3vw, 34px); }
.st-head { display: grid; gap: 12px; max-width: 900px; padding: 8px 0 22px; }
.st-head .hl { margin: 2px 0; max-width: 24ch; }
.st-head .dateline a { text-decoration: none; color: var(--red-ink); }
.st-by { margin: 0; display: flex; flex-wrap: wrap; align-items: center; gap: 6px 10px; font-size: 14.5px; color: var(--mute); }
.st-by a { color: var(--ink); font-weight: 700; text-decoration: none; }
.st-by .dot { width: 4px; height: 4px; border-radius: 50%; background: var(--rule-2); }
.st-hero { margin: 0 0 26px; border-radius: var(--r-lg); overflow: hidden; background: var(--sheet-3); }
.st-hero img { display: block; width: 100%; height: auto; max-height: 620px; object-fit: cover; }
.st-hero figcaption { font-size: 13px; color: var(--mute); padding: 10px 16px; background: var(--sheet); }
.st-body { display: grid; grid-template-columns: minmax(0, 1fr) 320px; gap: clamp(20px, 3vw, 44px); align-items: start; }
.st-body--full { grid-template-columns: minmax(0, 1fr); max-width: 820px; }
@media (max-width: 1000px) { .st-body { grid-template-columns: minmax(0, 1fr); } }
.st-col { min-width: 0; }
.st-paper { background: var(--sheet); border: 1px solid var(--rule); border-radius: var(--r-lg); padding: clamp(18px, 3.4vw, 40px); min-width: 0; }

/* the body: long reading, set for the phone first */
.entry-content { font-size: 18px; line-height: 1.75; color: var(--ink-2); overflow-wrap: break-word; }
.entry-content > :first-child { margin-top: 0; }
.entry-content p { margin: 0 0 1.1em; }
.entry-content h2, .entry-content h3, .entry-content h4 { font-family: var(--display); font-stretch: 85%; font-weight: 850; color: var(--ink); line-height: 1.12; letter-spacing: -.005em; margin: 1.6em 0 .55em; scroll-margin-top: 90px; }
.entry-content h2 { font-size: clamp(25px, 2.6vw, 32px); }
.entry-content h3 { font-size: clamp(21px, 2vw, 25px); }
.entry-content h4 { font-size: 19px; }
.entry-content a { color: var(--sky); text-decoration-thickness: 1px; }
.entry-content ul, .entry-content ol { padding-left: 1.3em; margin: 0 0 1.2em; }
.entry-content li { margin: .35em 0; }
.entry-content li::marker { color: var(--red-ink); }
.entry-content blockquote { margin: 1.4em 0; padding: 4px 0 4px 20px; border-left: 4px solid var(--red); font-size: 19px; color: var(--ink); }
.entry-content img { border-radius: var(--r-sm); height: auto; }
.entry-content figure { margin: 1.4em 0; }
.entry-content figcaption, .entry-content .wp-caption-text { font-size: 13.5px; color: var(--mute); margin-top: 6px; }
.entry-content table { width: 100%; border-collapse: collapse; font-size: 15.5px; margin: 1.2em 0; }
.entry-content th, .entry-content td { border-bottom: 1px solid var(--rule); padding: 10px 12px; text-align: left; vertical-align: top; }
.entry-content th { background: var(--sheet-2); color: var(--ink); font-weight: 750; }
.entry-content code { font-size: .9em; background: var(--sheet-3); padding: 2px 6px; border-radius: 6px; }
.entry-content pre { background: var(--sheet-3); padding: 16px; border-radius: var(--r-sm); overflow-x: auto; font-size: 14.5px; }
.entry-content hr { border: 0; border-top: 1px solid var(--rule); margin: 2em 0; }
.entry-content .alignleft { float: left; margin: .3em 1.4em 1em 0; }
.entry-content .alignright { float: right; margin: .3em 0 1em 1.4em; }
.entry-content .aligncenter { display: block; margin-left: auto; margin-right: auto; }
.entry-content::after { content: ''; display: table; clear: both; }
@media (max-width: 560px) {
  .entry-content { font-size: 17px; }
  .entry-content .alignleft, .entry-content .alignright { float: none; margin: 1em 0; }
  .st-paper { border-radius: var(--r); }
}
.page-links { margin: 1.4em 0 0; font-weight: 700; }
.st-tags { margin-top: 26px; }
.st-sponsor { margin: 26px 0 0; padding-top: 16px; border-top: 1px solid var(--rule); font-size: 14.5px; color: var(--mute); }
.st-sponsor a { color: var(--red-ink); font-weight: 750; }

/* the rail beside a story */
.st-rail { position: sticky; top: calc(var(--ym-p3-top-offset, 16px)); display: grid; gap: 16px; }
@media (max-width: 1000px) { .st-rail { position: static; } }
.st-rail .widget { background: var(--sheet); border: 1px solid var(--rule); border-radius: var(--r-lg); padding: 18px; }
.st-rail .widget-title { margin: 0 0 12px; }
.st-latest ul { list-style: none; margin: 0; padding: 0; display: grid; gap: 4px; }
.st-latest a { display: grid; grid-template-columns: 64px 1fr; gap: 12px; align-items: center; padding: 8px 0; border-top: 1px solid var(--rule); text-decoration: none; }
.st-latest li:first-child a { border-top: 0; }
.st-latest .pic { width: 64px; height: 48px; border-radius: 10px; }
.st-latest .pic img { object-fit: cover; }
.st-latest b { display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; font-size: 14.5px; line-height: 1.3; }
.st-latest small { display: block; color: var(--mute); font-size: 12.5px; margin-top: 2px; }
.st-latest a:hover b { text-decoration: underline; }
.st-latest li:not(:has(.pic)) a { grid-template-columns: 1fr; }

/* before and after */
.st-hop { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; margin: 26px 0 0; }
.st-hop a { display: grid; gap: 6px; background: var(--sheet); border: 1px solid var(--rule); border-radius: var(--r); padding: 16px 18px; text-decoration: none; }
.st-hop a:hover { border-color: var(--ink); }
.st-hop .nx { text-align: right; justify-items: end; }
.st-hop b { font-family: var(--display); font-stretch: 88%; font-weight: 800; font-size: 18px; line-height: 1.2; }
@media (max-width: 640px) { .st-hop { grid-template-columns: 1fr; } .st-hop .nx { text-align: left; justify-items: start; } }

/* listings: WordPress's own pager markup in the directory's pager look */
.pager .page-numbers { min-width: 44px; height: 44px; display: inline-grid; place-items: center; border-radius: 999px; border: 1px solid var(--rule-2); background: var(--sheet); font-weight: 700; text-decoration: none; padding: 0 14px; color: var(--ink); }
.pager .page-numbers.current { background: var(--ink); color: var(--paper); border-color: var(--ink); }
.pager .page-numbers.dots { border: 0; background: transparent; }
.story .pic img { width: 100%; height: 100%; object-fit: cover; }

/* pages and comments */
.st-page .st-paper { max-width: 860px; }
.st-comments { margin-top: 30px; padding-top: 20px; border-top: 1px solid var(--rule); }
.st-comment-list { list-style: none; padding: 0; margin: 14px 0; display: grid; gap: 14px; }
.st-comments .comment-body { background: var(--sheet-2); border-radius: var(--r); padding: 14px 16px; }
.st-comments textarea, .st-comments input[type='text'], .st-comments input[type='email'], .st-comments input[type='url'] { width: 100%; border: 1.5px solid var(--rule-2); border-radius: 12px; padding: 10px 12px; font: inherit; background: var(--sheet); color: var(--ink); }
.st-comments .submit { background: var(--ink); color: var(--paper); border: 0; border-radius: 999px; padding: 12px 20px; font-weight: 700; cursor: pointer; }
.st-search { margin-bottom: 30px; }

/* the estate's publisher line (printed after the folio by another plugin): part of the folio's night band, not a strip of paper */
.ym-publication-credit { background: var(--night); color: var(--night-mute); border-top: 1px solid var(--night-rule) !important; opacity: 1 !important; margin: 0; }
.ym-publication-credit a { color: var(--night-ink); }
