/* Scoped to the addon's own routes; retain PeepSo's mobile overflow menu. */
.ps-focus--page .ps-focus__menu .ps-focus__menu-item:is([href$="/linkkilista/"],[href$="/linkkilista"]) {
    --ap-tab-color: #624395; --ap-tab-bg: #f1ebfa; --ap-tab-ink: #624395; --ap-tab-tint: #f1ebfa;
}
.ps-focus--page .ps-focus__menu .ps-focus__menu-item:is([href$="/kortinhaltijoille/"],[href$="/kortinhaltijoille"]) {
    --ap-tab-color: #80520d; --ap-tab-bg: #fff3cf; --ap-tab-ink: #80520d; --ap-tab-tint: #fff3cf;
}
.ps-focus--page .ps-focus__menu .ps-focus__menu-item:is([href$="/linkkilista/"],[href$="/linkkilista"],[href$="/kortinhaltijoille/"],[href$="/kortinhaltijoille"]) {
    color: var(--ap-tab-color); background: var(--ap-tab-bg); border-bottom: 3px solid var(--ap-tab-color);
}
.ps-focus--page .ps-focus__menu .ps-focus__menu-item:is([href$="/linkkilista/"],[href$="/linkkilista"],[href$="/kortinhaltijoille/"],[href$="/kortinhaltijoille"]):is(.active,.ps-focus__menu-item--active) {
    color: #fff; background: var(--ap-tab-color);
}
.ap-tags-linklist, .ap-tags-section { margin: 20px 0; border: 1px solid #e0e5ee; border-radius: 16px; overflow: hidden; background: #fff; color: #173755; }
.ap-tags-linklist > header, .ap-tags-section-heading { padding: clamp(22px,4vw,38px); background: linear-gradient(120deg,#102e4e,#234868); color: #fff; }
.ap-tags-linklist h2, .ap-tags-section-heading h2 { margin: 10px 0; color: inherit; font-size: clamp(26px,4vw,36px); line-height: 1.2; }
.ap-tags-linklist > header p, .ap-tags-section-heading p { margin: 12px 0 0; line-height: 1.65; color: #e1e9f3; }
.ap-tags-eyebrow { color: #f0c866; font-size: 12px; font-weight: 800; letter-spacing: .14em; }
.ap-tags-link-grid { display: grid; grid-template-columns: minmax(0,1fr); gap: 16px; padding: 24px; background: #f4f6f9; }
.ap-tags-linklist .ap-tags-link-card, .ap-tags-section .ap-tags-link-card { display: flex; align-items: center; gap: clamp(14px,3vw,24px); padding: 0 22px 0 0; border: 1px solid #e0e5ee; border-radius: 12px; overflow: hidden; background: #fff; color: #173755; text-decoration: none; min-height: 94px; box-shadow: 0 2px 8px #18345008; transition: border-color .15s,box-shadow .15s; }
.ap-tags-linklist .ap-tags-link-card:hover, .ap-tags-section .ap-tags-link-card:hover { border-color: #9ebcdc; box-shadow: 0 4px 16px #18345012; color: #102e4e; }
.ap-tags-link-thumbnail { position: relative; flex: 0 0 168px; width: 168px; min-height: 94px; align-self: stretch; overflow: hidden; background: #edf2fa; }
.ap-tags-link-thumbnail img { position: absolute; inset: 0; display: block; width: 100%; height: 100%; object-fit: cover; }
.ap-tags-link-placeholder { position: absolute; inset: 0; display: grid; place-items: center; width: 100%; height: 100%; font-size: 34px; font-weight: 700; color: #2672b7; }
.ap-tags-link-card--spotify .ap-tags-link-placeholder { background: #e7f5ec; color: #217145; }
.ap-tags-link-card--youtube .ap-tags-link-placeholder { background: #fbebed; color: #b8384c; }
.ap-tags-link-copy { flex: 1; min-width: 0; padding: 12px 0; text-align: left; }
.ap-tags-link-card strong { display: block; font-size: clamp(17px,2.3vw,22px); font-weight: 800; line-height: 1.35; overflow-wrap: anywhere; }
.ap-tags-link-card small { display: block; margin-top: 7px; font-size: 14px; font-weight: 600; color: #1965ac; overflow-wrap: anywhere; }
.ap-tags-link-card--spotify small { color: #267246; }
.ap-tags-link-summary { display: block; margin-top: 7px; font-size: 14px; line-height: 1.6; color: #425b73; }
.ap-tags-link-newtab { font-size: 11px; font-weight: 400; color: #52657b; }
.ap-tags-link-chevron { flex: 0 0 auto; color: #1976cc; font-size: 44px; line-height: 1; font-weight: 700; }
.ap-tags-link-notice { margin: 0; padding: 8px 24px 24px; color: #596b7d; font-size: 13px; line-height: 1.6; }
.ap-tags-linklist .ap-tags-post-card, .ap-tags-section .ap-tags-post-card { min-width: 0; border: 1px solid #e0e5ee; border-radius: 12px; overflow: hidden; background: #fff; color: #173755; box-shadow: 0 2px 8px #18345008; }
.ap-tags-post-image { display: block; width: 100%; height: auto; max-height: 400px; object-fit: cover; background: #edf2fa; }
[data-ap-focal=center] .ap-tags-link-thumbnail img, [data-ap-focal=center] .ap-tags-post-image { object-position: 50% 50%; }
[data-ap-focal=top] .ap-tags-link-thumbnail img, [data-ap-focal=top] .ap-tags-post-image { object-position: 50% 0%; }
[data-ap-focal=bottom] .ap-tags-link-thumbnail img, [data-ap-focal=bottom] .ap-tags-post-image { object-position: 50% 100%; }
.ap-tags-post-copy { padding: 22px 24px; }
.ap-tags-post-copy h3 { margin: 0 0 12px; font-size: clamp(20px,3vw,26px); line-height: 1.35; font-weight: 800; overflow-wrap: anywhere; color: inherit; }
.ap-tags-body { white-space: pre-wrap; overflow-wrap: anywhere; line-height: 1.7; }
.ap-tags-post-copy > .ap-tags-body { margin: 0; }
.ap-tags-section-heading { border-radius: 10px; }
.ap-tags-section .ap-tags-locked { margin-top: 22px; padding: 20px; border-left: 4px solid #d5a53f; background: #fff8e9; border-radius: 8px; }
.ap-tags-section .ap-tags-locked p { margin: 0 0 12px; line-height: 1.65; }
.ap-tags-setup-note { padding: 12px; background: #f1f4f8; color: #42556a; }
.ap-tags-link-card:focus-visible, .ap-tags-section button:focus-visible { outline: 3px solid #2478bf; outline-offset: 3px; }
@media (max-width: 640px) { .ap-tags-link-grid { padding: 12px; gap: 12px; } .ap-tags-linklist .ap-tags-link-card, .ap-tags-section .ap-tags-link-card { padding: 0 12px 0 0; min-height: 80px; gap: 12px; border-radius: 10px; } .ap-tags-link-thumbnail { flex-basis: 96px; width: 96px; min-height: 80px; } .ap-tags-link-newtab { display: block; margin-top: 3px; } .ap-tags-link-chevron { font-size: 30px; } .ap-tags-link-card strong { font-size: 16px; } .ap-tags-post-copy { padding: 18px 16px; } }
@media (prefers-reduced-motion: reduce) { .ap-tags-link-card { transition: none; } }
.ap-tags-breadcrumbs { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; padding: 14px 20px; font-size: 14px; overflow-wrap: anywhere; }
.ap-tags-breadcrumbs a { color: #245c93; text-decoration: underline; text-underline-offset: 3px; }
.ap-tags-breadcrumbs [aria-current=page] { font-weight: 700; }
.ap-tags-section-cover { display: block; width: 100%; max-height: 380px; aspect-ratio: 16 / 7; object-fit: cover; border-radius: 12px; margin: 0 0 20px; }
.ap-tags-subsections { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 240px), 1fr)); gap: 18px; padding: 20px; }
.ap-tags-subsection-card { display: flex; flex-direction: column; min-width: 0; overflow: hidden; border: 1px solid #dbe4ef; border-radius: 14px; color: #163958; background: #fff; text-decoration: none; box-shadow: 0 4px 16px #13365608; }
.ap-tags-subsection-card:hover { border-color: #77a9cf; box-shadow: 0 6px 20px #13365616; }
.ap-tags-subsection-cover { width: 100%; aspect-ratio: 16 / 9; object-fit: cover; display: block; }
.ap-tags-subsection-copy { display: grid; gap: 10px; padding: 20px; overflow-wrap: anywhere; }
.ap-tags-subsection-copy strong { font-size: 20px; line-height: 1.3; }
.ap-tags-subsection-copy > span { white-space: pre-wrap; line-height: 1.6; font-size: 15px; }
.ap-tags-subsection-copy small { font-weight: 700; color: #25618f; }
.ap-tags-section-cover[data-ap-focal=top], .ap-tags-subsection-cover[data-ap-focal=top] { object-position: 50% 0%; }
.ap-tags-section-cover[data-ap-focal=center], .ap-tags-subsection-cover[data-ap-focal=center] { object-position: 50% 50%; }
.ap-tags-section-cover[data-ap-focal=bottom], .ap-tags-subsection-cover[data-ap-focal=bottom] { object-position: 50% 100%; }
.ap-tags-subsection-card:focus-visible, .ap-tags-breadcrumbs a:focus-visible { outline: 3px solid #2478bf; outline-offset: 3px; }
@media (max-width: 640px) { .ap-tags-subsections { padding: 12px; gap: 12px; } .ap-tags-breadcrumbs { padding: 12px; } .ap-tags-section-cover { aspect-ratio: 16 / 9; } }
/* Public section navigation follows the same image/title/chevron rows as links.
   Premium's separately authorized renderer keeps its existing layout. */
.ap-tags-linklist > .ap-tags-subsections { grid-template-columns: minmax(0,1fr); gap: 16px; padding: 24px; background: #f4f6f9; }
.ap-tags-linklist .ap-tags-subsection-card { flex-direction: row; }
.ap-tags-linklist .ap-tags-subsection-copy { display: block; padding: 12px 0; }
.ap-tags-linklist .ap-tags-subsection-copy small { color: #624395; }
.ap-tags-linklist .ap-tags-subsection-copy strong { font-size: clamp(17px,2.3vw,22px); line-height: 1.35; }
.ap-tags-linklist > .ap-tags-section-cover { width: 100%; height: auto; max-height: none; aspect-ratio: auto; object-fit: contain; border-radius: 0; margin: 0; background: #f4f6f9; }
.ap-tags-linklist > .ap-tags-subsections + .ap-tags-link-grid:empty { display: none; }
@media (max-width: 640px) { .ap-tags-linklist > .ap-tags-subsections { padding: 12px; gap: 12px; } .ap-tags-linklist .ap-tags-subsection-copy strong { font-size: 16px; } }
