#stories[hidden] { display: none }
.pp-story-card-cover { display: block }
.pp-story-card-cover img { display: block; width: 100%; aspect-ratio: 2.1; object-fit: cover }
.pp-stories-all { margin-top: 2rem }
.pp-story-page .pp-guide-main { max-width: 1120px }
.pp-story-copy { max-width: 720px; margin-inline: auto }
.pp-story-page h1 { font-size: clamp(2.1rem, 5.2vw, 4.25rem) }
.pp-story-lead { color: #3f665e; font-size: clamp(1.15rem, 2.1vw, 1.4rem) }
.pp-story-cover { display: block; width: 100%; max-height: 520px; object-fit: cover; border-radius: 16px; margin-block: 1.5rem 2.5rem }
.pp-story-body { line-height: 1.75; font-size: clamp(1.03rem, 2vw, 1.19rem) }
.pp-story-body h2 { font-size: clamp(1.45rem, 3vw, 2rem); margin-block: 1.6em .4em }
.pp-story-body figure { margin: 2rem 0 }
.pp-story-body figure img { display: block; max-width: 100%; max-height: 650px; margin-inline: auto; border-radius: 12px }
.pp-story-body figcaption { color: #3f665e; font-size: .92rem; margin-top: .65rem; text-align: center }
.pp-story-body details { margin-top: 2rem }
.pp-story-route { margin-top: 2rem }
.pp-story-archive { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 2rem; margin-top: 2rem }
.pp-story-archive img, .pp-story-preview img { display: block; width: 100%; aspect-ratio: 2.1; object-fit: cover; border-radius: 10px }
.pp-story-archive h2, .pp-story-preview h3 { font-size: clamp(1.4rem, 2.8vw, 2rem) }
.pp-story-preview { max-width: 460px; margin-bottom: 2.5rem }
.pp-story-editor .pp-guide-main { max-width: 900px }
.pp-story-editor h1 { font-size: clamp(2rem, 6vw, 3.5rem) }
.pp-story-panel { border: 1px solid #c9dfd5; border-radius: 16px; background: #fff; padding: clamp(1rem, 3vw, 2rem); margin: 1rem 0 }
.pp-story-editor h2 { font-size: clamp(1.45rem, 4vw, 2rem); margin-top: 0 }
.pp-story-form { display: grid; gap: 1rem; margin-top: 1rem }
.pp-story-form label { display: grid; gap: .35rem; min-width: 0; font-weight: 600 }
.pp-story-form label small { font-weight: 400; color: #3f665e }
.pp-story-form input:not([type=checkbox]), .pp-story-form textarea, .pp-story-form select { width: 100%; min-width: 0; padding: .65rem .8rem; border: 1px solid #accbc0; border-radius: 8px; font: inherit; background: #fbfdfb; color: inherit; font-weight: 400 }
.pp-story-form textarea { resize: vertical }
.pp-story-form button { justify-self: start; padding: .65rem 1rem; border: 1px solid #accbc0; border-radius: 8px; background: #fff; color: #16443d; cursor: pointer; font: inherit; font-weight: 700 }
.pp-story-form .pp-story-primary { background: #16443d; border-color: #16443d; color: #fff }
.pp-story-form button:disabled { opacity: .55; cursor: default }
.pp-story-form .pp-story-check { display: flex; align-items: baseline; gap: .6rem; font-weight: 400 }
.pp-story-toolbar { display: flex; flex-wrap: wrap; gap: .85rem 1.4rem }
.pp-story-message { padding: .7rem 1rem; border-radius: 8px; background: #f6eed9 }
.pp-story-list { padding-left: 1.2rem }
.pp-story-list li { margin-block: .55rem }
.pp-story-insert { padding: .8rem; background: #eff7f2; border-radius: 8px }
.pp-story-page summary, .pp-story-editor summary { cursor: pointer }
@media (max-width: 620px) { .pp-story-archive { grid-template-columns: minmax(0, 1fr) } }

.pp-story-cover-field { border: 0; padding: 0; margin: 0; min-width: 0 }
.pp-story-cover-field legend { padding: 0; margin-bottom: .45rem; font-weight: 600 }
.pp-story-cover-sample { display: block; width: min(100%, 390px); aspect-ratio: 2.1; object-fit: cover; border-radius: 8px; margin-bottom: .65rem }
.pp-story-editor [hidden] { display: none !important }
.pp-story-picker {
    width: min(94vw, 880px); max-height: 92vh; max-height: 92dvh; padding: 0;
    background: #f4faf6; color: #153b33; border: 1px solid #accbc0; border-radius: 16px;
    box-shadow: 0 18px 70px #153b3340;
}
.pp-story-picker::backdrop { background: #102921a8 }
.pp-story-picker-layout { display: grid; grid-template-rows: auto auto minmax(0, 1fr) auto; max-height: 90vh; max-height: 90dvh }
.pp-story-picker-header, .pp-story-picker-filter, .pp-story-picker-footer { padding: .7rem clamp(.8rem, 3vw, 1.4rem) }
.pp-story-picker-header { display: flex; align-items: center; justify-content: space-between; gap: .6rem }
.pp-story-picker-header h2 { margin: 0; font-size: clamp(1.2rem, 4vw, 1.7rem) }
.pp-story-picker-filter { display: flex; flex-wrap: wrap; align-items: center; gap: .45rem .85rem; padding-top: 0 }
.pp-story-picker button, .pp-story-picker select, .pp-story-picker input {
    border: 1px solid #accbc0; border-radius: 8px; padding: .45rem .7rem; background: #fff; color: inherit; font: inherit;
}
.pp-story-picker button { cursor: pointer }
.pp-story-picker button:disabled { opacity: .5; cursor: default }
.pp-story-picker button:focus-visible, .pp-story-picker select:focus-visible, .pp-story-picker input:focus-visible {
    outline: 2px solid #075b56; outline-offset: 2px;
}
.pp-story-picker-scroll { overflow: auto; overscroll-behavior: contain; padding: .4rem clamp(.8rem, 3vw, 1.4rem) .9rem }
.pp-story-picker-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(120px, 1fr)); gap: .65rem }
.pp-story-picker button.pp-story-picker-tile { min-width: 0; padding: .3rem; text-align: left }
.pp-story-picker-tile[aria-pressed="true"] { outline: 2px solid #075b56; outline-offset: -1px; background: #dcefe5 }
.pp-story-picker-tile img { display: block; width: 100%; aspect-ratio: 4/3; object-fit: contain; background: #e5f1ea; border-radius: 5px }
.pp-story-picker-tile span { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: .76rem; padding: .15rem }
.pp-story-picker-preview { margin: 0; text-align: center }
.pp-story-picker-preview img { display: block; width: 100%; height: min(48vh, 440px); object-fit: contain }
.pp-story-picker-preview figcaption { overflow-wrap: anywhere; font-size: .85rem }
.pp-story-picker-footer { border-top: 1px solid #c9dfd5 }
.pp-story-picker-footer label { display: grid; gap: .25rem; margin-bottom: .65rem }
.pp-story-picker-footer input { width: 100% }
.pp-story-picker-footer .pp-story-toolbar { justify-content: flex-end; gap: .45rem }
.pp-story-picker-footer .pp-story-primary { color: #fff; background: #16443d; border-color: #16443d; font-weight: 700 }
#story-picker-error { color: #8b3426; margin: .3rem 0 }
@media (max-width: 480px) {
    .pp-story-picker-grid { grid-template-columns: repeat(2, minmax(0, 1fr)) }
    .pp-story-picker-footer .pp-story-toolbar { justify-content: flex-start }
}
