@charset "utf-8";

:root{
  --pb-bg:#f6f4f2;
  --pb-card:#fff;
  --pb-line:#222;
  --pb-muted:#777;
  --pb-soft:#e8e3df;
  --pb-radius:15px;
}

.pb-wrap{max-width:500px;margin:0 auto;padding:20px;font-size:13px;color:#111;line-height:1.8;box-sizing:border-box;}
.pb-card{background:var(--pb-card);border:1px solid #ddd;border-radius:var(--pb-radius);box-sizing:border-box;margin:0 0 14px;padding:20px;}
#pbApp > .pb-card,
#pbBlocksView > .pb-card,
#pbBlocksView > .pb-text-toggle {
  transition: transform .34s cubic-bezier(.2,.9,.2,1), box-shadow .34s ease, border-color .34s ease;
  transform-origin: center center;
}
#pbApp > .pb-card:hover,
#pbBlocksView > .pb-card:hover,
#pbBlocksView > .pb-text-toggle:hover {
  transform: scale(1.008);
  box-shadow: 0 8px 20px rgba(0,0,0,.045);
}
.pb-edit-mode #pbApp > .pb-card:hover,
.pb-edit-mode #pbBlocksView > .pb-card:hover,
.pb-edit-mode #pbBlocksView > .pb-text-toggle:hover {
  transform: none;
}
.pb-center{text-align:center;}
.pb-muted{color:var(--pb-muted);font-size:12px;}
.pb-divider{border:0;border-top:1px solid #ccc;margin:18px 0;}

/* 상단 고정 프로필 */
.pb-profile{display:flex;align-items:center;gap:20px;min-height:92px;}
.pb-avatar{position:relative;width:82px;height:82px;border:1px solid #ddd;border-radius:50%;display:flex;align-items:center;justify-content:center;overflow:hidden;flex:0 0 auto;background:#fff;}
.pb-avatar img{width:100%;height:100%;object-fit:cover;display:block;}
.pb-name{font-size:18px;font-weight:500;line-height:1.3;}
.pb-idline{font-size:12px;color:#aaa;margin-top:2px;}
.pb-catch{font-size:14px;color:#555;margin-top:3px;}

/* 공지 */
.pb-notice-title{font-size:15px;font-weight:700;letter-spacing:.04em;margin-bottom:18px;}
.pb-notice-title:before{content:'📌';font-size:12px;margin-right:2px;}
.pb-notice-body{white-space:pre-line;text-align:center;}

ruby {ruby-align: center;}
.ra0-content {font-size: 13px;}
.ra0-content h2, .ra0-content h3, .ra0-content h4 {margin: 0.4em 0;}

/* 블럭 공통 */
.pb-image-block{position:relative;display:flex;align-items:center;justify-content:center;text-align:center;overflow:hidden;min-height:260px;padding:0;}
.pb-image-block img{max-width:100%;max-height:100%;width:auto;height:auto;display:block;object-fit:contain;}
.pb-empty-img{color:#222;white-space:pre-line;}

.pb-toggle{padding:0;overflow:hidden;}
.pb-toggle-head{display:flex;align-items:center;justify-content:space-between;gap:12px;width:100%;padding:14px 18px;background:#fff;border:0;cursor:pointer;text-align:left;font-weight:600;color:#111;}
.pb-toggle-icon{font-size:18px;line-height:1;display:inline-flex;transition:transform .55s cubic-bezier(.2,1.35,.35,1);transform-origin:center;}
.pb-toggle-body{
  border-top:1px solid transparent;
  padding:0 18px;
  white-space:pre-line;
  display:block;
  max-height:0;
  opacity:0;
  overflow:hidden;
  visibility:hidden;
  transform:translateY(-4px);
  transition:max-height .58s cubic-bezier(.2,1,.25,1), opacity .28s ease, padding .58s cubic-bezier(.2,1,.25,1), border-color .28s ease, transform .42s ease, visibility 0s linear .58s;
}
.pb-toggle.is-open .pb-toggle-body{
  max-height:var(--pb-toggle-open-height, 1200px);
  opacity:1;
  visibility:visible;
  border-top-color:#ddd;
  padding:22px 18px;
  transform:translateY(0);
  transition:max-height .62s cubic-bezier(.2,1,.25,1), opacity .32s ease .05s, padding .62s cubic-bezier(.2,1,.25,1), border-color .25s ease, transform .42s ease, visibility 0s;
}
.pb-toggle.is-open .pb-toggle-icon{transform:rotate(180deg);}

/* 리스트 토글 본문에만 폰트 적용 */
.pb-list-toggle .pb-list-toggle-body,
.pb-list-toggle .pb-list-toggle-body * {
  font-family: "JoseonGulim", sans-serif !important;
}

.pb-text-toggle{border:0;background:transparent;padding:0;margin:10px 0 18px;text-align:center;}
.pb-text-toggle-head{display:inline-flex;flex-direction:column;align-items:center;gap:4px;border:0;background:transparent;cursor:pointer;font-size:15px;color:#111;}
.pb-text-toggle-icon{font-size:18px;line-height:1;display:inline-flex;transition:transform .55s cubic-bezier(.2,1.35,.35,1);transform-origin:center;}
.pb-text-toggle-body{display:none;margin-top:16px;text-align:left;}
.pb-text-toggle.is-open .pb-text-toggle-body{display:block;}
.pb-text-toggle.is-open .pb-text-toggle-icon{transform:rotate(180deg);}

.pb-dday{display:grid;grid-template-columns:1fr 1fr 1fr;align-items:center;text-align:center;min-height:120px;padding:0;border-radius: var(--pb-radius);}
.pb-dday-side{position:relative;display:flex;align-items:center;justify-content:center;min-height:80px;overflow:hidden;}
.pb-dday-side img{max-width:100%;max-height:100%;object-fit:contain;display:block;}
.pb-dday-main strong{font-size:22px;display:block;line-height:1.3;}
.pb-dday-main .pb-date{font-size:12px;color:#333;margin-top:6px;}
/* 디데이 블럭 좌우 이미지도 카드 모서리에 맞춰 둥글게 표시 */
.pb-dday { overflow: hidden; }
/* 왼쪽 이미지는 왼쪽 모서리만 둥글게 */
.pb-dday-side:first-child img { border-radius: var(--pb-radius) 0 0 var(--pb-radius); }
/* 오른쪽 이미지는 오른쪽 모서리만 둥글게 */
.pb-dday-side:last-child img { border-radius: 0 var(--pb-radius) var(--pb-radius) 0; }
/* 디데이 좌우 이미지 빈틈 없이 꽉 채우기 */
.pb-dday {    overflow: hidden;}
.pb-dday-side {    align-self: stretch;    height: auto;    min-height: 130px;    overflow: hidden;}
.pb-dday-side img {    width: 100%;    height: 100%;    max-width: none;    max-height: none;    object-fit: cover;    display: block;}
/* 혹시 브라우저 소수점 계산 때문에 1px 틈이 남을 때 보정 */
.pb-dday-side:first-child {    margin-left: -1px;}
.pb-dday-side:last-child {    margin-right: -1px;}
/* 바깥쪽 모서리만 카드에 맞춰 둥글게 */
.pb-dday-side:first-child img {    border-radius: var(--pb-radius) 0 0 var(--pb-radius);}
.pb-dday-side:last-child img {    border-radius: 0 var(--pb-radius) var(--pb-radius) 0;}

.pb-fandom{text-align:center;}
.pb-fandom-origin{font-size:13px;color:#333;line-height:1.4;}
.pb-fandom-title{font-size:22px;line-height:1.25;margin:2px 0;}
.pb-fandom-row{display:grid;grid-template-columns:1fr 1fr;margin-top:18px;margin-bottom:30px;align-items:end; grid-template-columns: 1fr auto 1fr; align-items: center;}
.pb-fandom-label{font-size:12px;color:#555;line-height:1.4;}
.pb-fandom-name{font-size:24px;line-height:1.25;}
.pb-pill-row{display:flex;justify-content:flex-start;align-items:center;gap:6px;margin:12px 0;text-align:left;}
.pb-pill{display:inline-flex;align-items:center;justify-content:center;min-width:48px;padding:2px 10px;border-radius:8px;background:#888;color:#fff;font-size:12px;line-height:1.6;}
.pb-fandom-section{text-align:left;margin:12px 0;white-space:pre-line;}
.pb-fandom-section-title{font-weight:700;border-top:1px solid #222;padding-top:12px;margin-top:12px;}
.pb-fandom-section-sub{color:#444;font-size:13px;margin-bottom:4px;}
.pb-free-text{border-top:1px solid #222;margin-top:16px;padding-top:16px;white-space:pre-line;text-align:left;}

/* 목록 */
.pb-list{max-width:980px;margin:0 auto;padding:20px 12px;}
.pb-list-grid{display:grid;grid-template-columns:repeat(auto-fill,minmax(260px,1fr));gap:14px;}
.pb-list-item{text-decoration:none;color:inherit;display:block;transition:transform .15s ease;}
.pb-list-item:hover{transform:translateY(-2px);}
.pb-list-card{height:100%;}

/* 글쓰기 */
.pb-editor{max-width:980px;margin:0 auto;padding:20px 12px;}
.pb-editor fieldset{border:1px solid #ddd;border-radius:8px;padding:16px;margin:0 0 16px;background:#fff;}
.pb-editor legend{padding:0 8px;font-weight:700;}
.pb-form-grid{display:grid;grid-template-columns:140px 1fr;gap:10px 12px;align-items:center;}
.pb-editor input[type=text],.pb-editor input[type=date],.pb-editor input[type=number],.pb-editor textarea,.pb-editor select{width:100%;box-sizing:border-box;border:1px solid #bbb;border-radius:4px;padding:8px;font-size:14px;background:#fff;}
.pb-editor textarea{min-height:90px;resize:vertical;line-height:1.6;}
.pb-editor-actions{display:flex;gap:8px;flex-wrap:wrap;margin:10px 0;}
.pb-btn{border:1px solid #333;background:#fff;color:#111;border-radius:6px;padding:7px 12px;cursor:pointer;font-size:13px;text-decoration:none;display:inline-flex;align-items:center;justify-content:center;}
.pb-btn.dark{background:#222;color:#fff;}
.pb-block-editor{border:1px solid #aaa;border-radius:8px;background:#fff;margin:12px 0;padding:12px;}
.pb-block-top{display:flex;justify-content:space-between;gap:8px;align-items:center;border-bottom:1px solid #eee;padding-bottom:8px;margin-bottom:10px;}
.pb-block-title{font-weight:700;}
.pb-mini-actions{display:flex;gap:4px;flex-wrap:wrap;}
.pb-mini-actions button{border:1px solid #aaa;background:#fafafa;border-radius:4px;padding:4px 7px;cursor:pointer;font-size:12px;}
.pb-submit-row{display:flex;justify-content:flex-end;gap:8px;margin-top:16px;}

@media (max-width:640px){
  .pb-wrap{padding:16px 10px 40px;}
  .pb-profile{gap:14px;}
  .pb-avatar{width:68px;height:68px;}
  .pb-name{font-size:14px;}
  .pb-idline{font-size:10px;}
  .pb-catch{font-size:12px;}
  .pb-form-grid{grid-template-columns:1fr;gap:6px;}
}
/* 모바일에서도 디데이/덕질블럭 배치를 유지 */
@media (max-width:640px){
    .pb-dday {        grid-template-columns: 1fr 1fr 1fr;        gap: clamp(6px, 2vw, 14px);        min-height: clamp(86px, 26vw, 130px);    }
    .pb-dday-side {        min-height: clamp(86px, 26vw, 130px);    }
    .pb-dday-main {        min-width: 0;        line-height: 1.4;    }
    .pb-dday-main > div:first-child {        font-size: clamp(0.7rem, 3vw, 0.9rem);        white-space: nowrap;    }
    .pb-dday-main strong {        font-size: clamp(1rem, 5vw, 1.4rem);        white-space: nowrap;    }
    .pb-dday-main .pb-date {        font-size: clamp(0.65rem, 2.8vw, 0.75rem);        white-space: nowrap;    }
    .pb-fandom-row {        grid-template-columns: 1fr 1fr;        gap: clamp(8px, 3vw, 20px);    }
    .pb-fandom-title {        font-size: clamp(1rem, 5vw, 1.4rem);    }
    .pb-fandom-name {        font-size: clamp(1rem, 5vw, 1.5rem);    }
    .pb-fandom-label {        font-size: clamp(0.65rem, 2.8vw, 0.75rem);    }
}

/* dream inline editor */
.pb-admin-toolbar {
    position: sticky;
    top: 0;
    z-index: 999;
    max-width: 760px;
    margin: 0 auto 12px;
    padding: 10px;
    background: rgba(255,255,255,.94);
    border: 1px solid #ddd;
    border-radius: 12px;
    box-shadow: 0 8px 24px rgba(0,0,0,.08);
    display: flex;
    gap: 8px;
    align-items: center;
    flex-wrap: wrap;
}
.pb-toolbar-help {
    font-size: 12px;
    color: #777;
}
.pb-edit-mode .pb-card,
.pb-edit-mode .pb-text-toggle {
    cursor: pointer;
}
.pb-edit-mode .pb-editable-block:hover,
.pb-edit-mode [data-fixed]:hover {
    outline: 2px dashed #999;
    outline-offset: 4px;
}
.pb-selected-block {
    outline: 2px solid #111 !important;
    outline-offset: 4px;
}
.pb-inline-editor {
    max-width: 100%;
    margin: 10px 0 18px;
    padding: 14px;
    border: 1px solid #111;
    border-radius: 10px;
    background: #fff;
    box-shadow: 0 10px 24px rgba(0,0,0,.08);
}
.pb-inline-editor .pb-form-grid {
    display: grid;
    grid-template-columns: 120px 1fr;
    gap: 8px 10px;
    align-items: start;
}
.pb-inline-editor label {
    font-size: 12px;
    line-height: 32px;
    color: #333;
}
.pb-inline-editor input,
.pb-inline-editor textarea {
    width: 100%;
    box-sizing: border-box;
    border: 1px solid #ccc;
    border-radius: 6px;
    padding: 8px;
    font-size: 13px;
    background: #fff;
}
.pb-inline-editor textarea {
    min-height: 90px;
    resize: vertical;
}
.pb-editor-head {
    grid-column: 1 / -1;
    display: flex;
    justify-content: space-between;
    gap: 8px;
    align-items: center;
    padding-bottom: 8px;
    border-bottom: 1px solid #eee;
}
.pb-editor-head button {
    border: 1px solid #aaa;
    background: #f8f8f8;
    border-radius: 6px;
    padding: 4px 7px;
    font-size: 12px;
}
.pb-editor-foot {
    margin-top: 10px;
    display: flex;
    justify-content: flex-end;
    gap: 8px;
}
.pb-add-zone {
    margin: 18px 0 30px;
    padding: 18px;
    border: 1px dashed #aaa;
    border-radius: 12px;
    background: #fafafa;
    text-align: center;
}
.pb-add-title {
    margin-bottom: 10px;
    font-size: 14px;
    font-weight: 700;
}
.pb-add-buttons {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 8px;
}
.pb-btn[disabled] {
    opacity: .45;
    cursor: not-allowed;
}
@media (max-width: 520px) {
    .pb-inline-editor .pb-form-grid {
        grid-template-columns: 1fr;
    }
    .pb-inline-editor label {
        line-height: 1.4;
        margin-top: 6px;
    }
}

/* dream 단일 페이지 안내 */
.pb-empty-single p { margin: 8px 0; }


/* dream rich text editor */
.pb-rich-content { white-space: normal; }
.pb-rich-content p { margin: 0 0 .7em; }
.pb-rich-content p:last-child { margin-bottom: 0; }
.pb-rich-content ul, .pb-rich-content ol { margin: .4em 0 .8em 1.4em; padding: 0; }
.pb-rich-content b, .pb-rich-content strong { font-weight: 700; }
.pb-rich-content u { text-underline-offset: 3px; }
.pb-rich-box {
    width: 100%;
    min-width: 0;
}
.pb-rich-toolbar {
    display: flex;
    flex-wrap: wrap;
    gap: 4px;
    padding: 6px;
    border: 1px solid #ccc;
    border-bottom: 0;
    border-radius: 6px 6px 0 0;
    background: #f8f8f8;
}
.pb-rich-toolbar button,
.pb-rich-toolbar .pb-color-label {
    min-height: 28px;
    border: 1px solid #aaa;
    border-radius: 5px;
    background: #fff;
    padding: 3px 7px;
    font-size: 12px;
    line-height: 1.2;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    gap: 4px;
}
.pb-rich-toolbar input[type="color"] {
    width: 28px;
    height: 20px;
    padding: 0;
    border: 0;
    background: transparent;
}
.pb-rich-editor {
    min-height: 120px;
    width: 100%;
    box-sizing: border-box;
    border: 1px solid #ccc;
    border-radius: 0 0 6px 6px;
    padding: 10px;
    font-size: 13px;
    line-height: 1.7;
    background: #fff;
    outline: none;
    overflow: auto;
}
.pb-rich-editor:focus {
    border-color: #111;
    box-shadow: 0 0 0 2px rgba(0,0,0,.08);
}
.pb-rich-editor:empty:before {
    content: '내용을 입력하세요';
    color: #aaa;
}

/* RA0 에디터를 dream 블럭 편집창 안에서 사용할 때 보정 */
.pb-ra0-field{grid-column:1 / -1;margin:0 0 12px;}
.pb-inline-editor .ra0-editor-wrapper{background:#fff;border:1px solid #ddd;border-radius:8px;overflow:hidden;margin-bottom:14px;}
.pb-inline-editor .ra0-editor-toolbar{max-height:220px;overflow:auto;}
.pb-inline-editor .ra0-editor-viewer{min-height:180px !important;max-height:420px;overflow:auto;background:#fff;}
.pb-inline-editor .ra0-editor-footer{font-size:12px;}
.pb-ra0-fallback{width:100%;min-height:180px;box-sizing:border-box;}


/* RA0 드롭다운이 편집 영역에 가려지지 않도록 보정 */
.pb-inline-editor,
.pb-ra0-field,
.pb-inline-editor .ra0-editor-wrapper,
.pb-inline-editor .ra0-editor-toolbar,
.pb-inline-editor .toolbar-group,
.pb-inline-editor .color-picker-wrapper {
    overflow: visible !important;
}
.pb-inline-editor .ra0-editor-wrapper {
    position: relative;
    z-index: 1;
}
.pb-inline-editor .ra0-editor-toolbar {
    position: relative;
    z-index: 20;
}
.pb-inline-editor .ra0-editor-viewer {
    position: relative;
    z-index: 1;
}
.pb-inline-editor .dropdown-menu,
.pb-inline-editor .color-palette.dropdown-menu {
    z-index: 99999 !important;
}
.pb-rich-text-block {
    text-align: left;
    min-height: 80px;
}
.pb-rich-text-block .pb-rich-content:empty:before {
    content: '자유롭게 글을 입력할 수 있음';
    color: #888;
}


/* RA0 에디터로 작성한 본문은 dream 카드의 중앙정렬 영향을 받지 않도록 함 */
.pb-rich-content {
    white-space: normal;
}

.pb-rich-content .ra0-content {
    text-align: initial;
    white-space: normal;
}

/* 공지 카드가 pb-center 안에 있어도 RA0 본문은 왼쪽 기준으로 출력 */
.pb-notice-body.pb-rich-content {
    text-align: left;
    white-space: normal;
}

/* 일반글 블럭도 본문 기준 정렬 */
.pb-rich-text-block,
.pb-rich-text-block .pb-rich-content,
.pb-rich-text-block .ra0-content {
    text-align: left;
}

/* 덕질 블럭 안의 긴 본문도 중앙정렬되지 않게 함 */
.pb-fandom-section.pb-rich-content,
.pb-free-text.pb-rich-content,
.pb-fandom-section .ra0-content,
.pb-free-text .ra0-content {
    text-align: left;
    white-space: normal;
}
/* 덕질 블럭 내부 라공에디션 반복 입력 영역 */
.pb-fandom-section-tools {
    grid-column: 1 / -1;
    display: flex;
    align-items: center;
    gap: 8px;
    flex-wrap: wrap;
    margin: 8px 0 4px;
    padding-top: 10px;
    border-top: 1px solid #eee;
}
.pb-fandom-section-tools span {
    font-size: 12px;
    color: #777;
}
.pb-fandom-sections-box {
    grid-column: 1 / -1;
    display: grid;
    gap: 12px;
}
.pb-fandom-section-editor {
    display: grid;
    grid-template-columns: 120px 1fr;
    gap: 8px 10px;
    align-items: start;
    padding: 12px;
    border: 1px solid #ddd;
    border-radius: 8px;
    background: #fafafa;
}
.pb-fandom-section-head {
    grid-column: 1 / -1;
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 8px;
    padding-bottom: 8px;
    border-bottom: 1px solid #eee;
}
.pb-fandom-section-head button {
    border: 1px solid #aaa;
    background: #fff;
    border-radius: 6px;
    padding: 4px 8px;
    font-size: 12px;
    cursor: pointer;
}
@media (max-width: 520px) {
    .pb-fandom-section-editor {
        grid-template-columns: 1fr;
    }
}


/* 라공에디션 구분선 스타일 */
/* 드림게시판 안의 라공에디션 구분선만 덮어쓰기 */
.pb-wrap .ra0-content hr.divider-full {
    margin: 1.5rem 0 !important;
    height: 1px !important;
    border: 0 !important;
    background: #bbb !important;
}

.pb-wrap .ra0-content hr.divider-short {
    margin: 1.5rem auto !important;
    height: 1px !important;
    border: 0 !important;
    background: #bbb !important;
}

.pb-wrap .ra0-content hr.divider-dot-full {
    margin: 1.5rem 0 !important;
    height: 2px !important;
    border: 0 !important;
    background-image: radial-gradient(circle, rgb(from var(--content-font-color) r g b / 80%) 1px, transparent 1px) !important;
    background-size: 10px 5px !important;
}

.pb-wrap .ra0-content hr.divider-dot-short {
    margin: 1.5rem auto !important;
    height: 2px !important;
    border: 0 !important;
    background-image: radial-gradient(circle, rgb(from var(--content-font-color) r g b / 80%) 1px, transparent 1px) !important;
    background-size: 10px 5px !important;
}


/* 드림게시판 출력용 RA0 본문만 폰트 크기 상속 */
.pb-notice-body .ra0-content,
.pb-rich-text-block .ra0-content,
.pb-fandom-section .ra0-content,
.pb-free-text .ra0-content {
    font-size: inherit !important;
}
@media (max-width: 640px) {
    .pb-wrap .ra0-content blockquote.blockquote-type1::before {
        font-family: Georgia, serif !important;
    }
}

/* 디데이/덕질블럭 와인색 하트 */
.pb-heart,
.pb-fandom-heart {    color: #ae5d5c;    font-weight: 600;}
.pb-heart {    padding: 0 0.22em;}

.pb-fandom-heart {
    display: flex;
    align-items: center;
    justify-content: center;
    align-self: center;
    font-size: clamp(1rem, 4vw, 1.35rem);
    line-height: 1;
    padding: 0 0.05em;
}

@media (max-width:640px){
    .pb-fandom-row {
        grid-template-columns: 1fr auto 1fr;
        gap: clamp(5px, 2vw, 12px);
    }

    .pb-fandom-heart {
        font-size: clamp(0.85rem, 4vw, 1.15rem);
    }
}


/* 이미지/동영상 위 저작권 닉네임 */
/* 기본: 단일 이미지 / 동영상 = 아래 가운데 */
.pb-media-credit {
    position: absolute;
    left: 50%;
    right: auto;
    top: auto;
    bottom: 8px;
    transform: translateX(-50%);
    z-index: 5;

    max-width: 80%;
    padding: 1px 7px;
    border-radius: 999px;
    background: rgba(255,255,255,.45);
    color: rgba(80,80,80,.75);
    font-size: 10px;
    line-height: 1.5;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    pointer-events: none;
    font-family: "pretendard", sans-serif;
}

/* 프사 = 아래 가운데 */
.pb-avatar .pb-media-credit {
    top: auto;
    bottom: 6px;
    left: 50%;
    right: auto;
    transform: translateX(-50%);
    max-width: 72px;
    font-size: 9px;
    padding: 0 5px;
    font-family: "pretendard", sans-serif;
}

/* 디데이 왼쪽 이미지 = 좌측 아래 */
.pb-dday-side:first-child .pb-media-credit {
    top: auto;
    bottom: 6px;
    left: 6px;
    right: auto;
    transform: none;
}

/* 디데이 오른쪽 이미지 = 우측 아래 */
.pb-dday-side:last-child .pb-media-credit {
    top: auto;
    bottom: 6px;
    left: auto;
    right: 6px;
    transform: none;
}

/* 동영상 블럭: GIF처럼 보이는 자동재생 영상 */
.pb-video-block {
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    padding: 0;
    min-height: 260px;
    border-radius: var(--pb-radius);
    background: #f2f2f2;
}
.pb-video-block video {
    width: 100%;
    height: 100%;
    min-height: inherit;
    display: block;
    object-fit: cover;
    border-radius: inherit;
}
.pb-video-mute {
    position: absolute;
    right: 10px;
    bottom: 10px;
    z-index: 5;
    width: 34px;
    height: 34px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border: 1px solid rgba(255,255,255,.65);
    border-radius: 999px;
    background: rgba(0,0,0,.45);
    color: #fff;
    font-size: 16px;
    line-height: 1;
    cursor: pointer;
    backdrop-filter: blur(4px);
    -webkit-backdrop-filter: blur(4px);
}
.pb-video-mute:hover {
    background: rgba(0,0,0,.65);
}
.pb-help-text {
    margin: 6px 0 0;
    color: #777;
    font-size: 12px;
    line-height: 1.5;
}
.pb-inline-editor input[type="file"] {
    width: 100%;
    box-sizing: border-box;
    border: 1px solid #ccc;
    border-radius: 6px;
    padding: 8px;
    font-size: 13px;
    background: #fff;
}


/* 리스트 토글 블럭 */
.pb-list-toggle-heading {
    display: inline-flex;
    align-items: baseline;
    gap: 6px;
    flex-wrap: wrap;
}
.pb-list-toggle-heading small {
    font-size: 11px;
    color: #777;
    font-weight: 400;
}
.pb-list-toggle-body {
    white-space: normal;
    text-align: left;
}
.pb-list-toggle-note {
    margin: 0 0 14px;
    font-size: 13px;
    color: #555;
}
.pb-list-toggle-rich {
    margin: 12px 0;
}
.pb-list-toggle-row {
    display: grid;
    grid-template-columns: var(--pb-list-genre-width, 7.5em) 1fr;
    gap: 6px;
    align-items: start;
    font-size: 13px;
    line-height: 1.7;
    margin: 2px 0;
}
.pb-list-toggle-genre {
    font-weight: 600;
    word-break: keep-all;
}
.pb-list-toggle-character {
    position: relative;
    min-width: 0;
    word-break: keep-all;
}
.pb-list-toggle-row:not(.is-child) .pb-list-toggle-character:before {
    content: ': ';
}
.pb-list-toggle-row.is-child .pb-list-toggle-genre {
    min-height: 1px;
}
.pb-list-toggle-row.is-child .pb-list-toggle-character {
    padding-left: 0.7em;
}

.pb-list-toggle-row.is-initial-break {
    margin-top: 12px;
    padding-top: 8px;
}
.pb-list-toggle-child-help {
    grid-column: 1 / -1;
    font-size: 12px;
    color: #777;
    margin: -4px 0 4px;
}
.pb-list-toggle-tools {
    grid-column: 1 / -1;
    display: flex;
    align-items: center;
    gap: 8px;
    flex-wrap: wrap;
    margin: 8px 0 4px;
    padding-top: 10px;
    border-top: 1px solid #eee;
}
.pb-list-toggle-tools span {
    font-size: 12px;
    color: #777;
}
.pb-list-toggle-items-box {
    grid-column: 1 / -1;
    display: grid;
    gap: 12px;
}
.pb-list-toggle-item-editor {
    display: grid;
    grid-template-columns: 120px 1fr;
    gap: 8px 10px;
    align-items: start;
    padding: 12px;
    border: 1px solid #ddd;
    border-radius: 8px;
    background: #fafafa;
}
.pb-list-toggle-item-head {
    grid-column: 1 / -1;
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 8px;
    padding-bottom: 8px;
    border-bottom: 1px solid #eee;
}
.pb-list-toggle-item-head div {
    display: flex;
    gap: 4px;
    flex-wrap: wrap;
}
.pb-list-toggle-item-head button {
    border: 1px solid #aaa;
    background: #fff;
    border-radius: 6px;
    padding: 4px 8px;
    font-size: 12px;
    cursor: pointer;
}
.pb-list-toggle-rich-only-label {
    grid-column: 1 / -1;
    font-size: 12px;
    color: #555;
}
@media (max-width: 520px) {
    .pb-list-toggle-row {
        grid-template-columns: minmax(6.5em, 40%) 1fr;
        font-size: 12px;
    }
    .pb-list-toggle-item-editor {
        grid-template-columns: 1fr;
    }
}

/* 2026-05-13 리스트 토글 편집창 정렬 보정 */
.pb-list-toggle-row {
    align-items: center;
}
.pb-list-toggle-genre,
.pb-list-toggle-character {
    white-space: nowrap;
}
.pb-list-toggle-line-editor {
    grid-column: 1 / -1;
    display: grid;
    grid-template-columns: minmax(120px, 0.95fr) minmax(150px, 1.05fr);
    gap: 8px 10px;
    align-items: end;
}
.pb-list-toggle-edit-cell {
    min-width: 0;
}
.pb-list-toggle-edit-cell span {
    display: block;
    margin-bottom: 4px;
    font-size: 12px;
    color: #555;
    line-height: 1.4;
}
.pb-list-toggle-edit-cell input {
    width: 100%;
}
.pb-list-toggle-child-editor {
    margin-top: -12px;
    border-top-style: dashed;
    border-radius: 0 0 8px 8px;
    background: #fff;
}
.pb-list-toggle-child-editor .pb-list-toggle-item-head {
    padding-bottom: 4px;
    border-bottom: 0;
}
.pb-list-toggle-child-title {
    min-height: 1px;
}
.pb-list-toggle-edit-blank {
    min-height: 1px;
}
@media (max-width: 520px) {
    .pb-list-toggle-line-editor {
        grid-template-columns: minmax(6.5em, 40%) 1fr;
    }
}


/* 글자만 있는 토글: 클릭 전 ▼가 살짝 둥실둥실 */
.pb-text-toggle:not(.is-open) .pb-text-toggle-icon {
    animation: pbTextToggleFloat 1.4s ease-in-out infinite;
}

/* 열렸을 때는 둥실 효과 멈추고 부드럽게 회전 */
.pb-text-toggle.is-open .pb-text-toggle-icon {
    animation: none;
    transform: rotate(180deg);
}

/* ▼ 위아래 움직임 */
@keyframes pbTextToggleFloat {
    0%, 100% {
        transform: translateY(0);
    }
    50% {
        transform: translateY(4px);
    }
}

/* 글자 토글 아래 블럭들이 부드럽게 나타나고 사라지도록 */
#pbBlocksView > .pb-editable-block.pb-text-toggle-hidden {
    overflow: hidden;
    max-height: 0 !important;
    min-height: 0 !important;
    opacity: 0;
    transform: translateY(-8px) scale(.985);

    margin-top: 0 !important;
    margin-bottom: 0 !important;
    padding-top: 0 !important;
    padding-bottom: 0 !important;

    border-width: 0 !important;
    pointer-events: none;

    transition:
        max-height .55s cubic-bezier(.22, 1, .36, 1),
        opacity .35s ease,
        transform .45s cubic-bezier(.22, 1, .36, 1),
        margin .45s ease,
        padding .45s ease,
        border-width .45s ease;
}

#pbBlocksView > .pb-editable-block.pb-text-toggle-visible {
    overflow: hidden;
    max-height: 1200px;
    min-height: var(--pb-original-min-height, initial);
    opacity: 1;
    transform: translateY(0) scale(1);

    transition:
        max-height .65s cubic-bezier(.22, 1, .36, 1),
        opacity .35s ease,
        transform .45s cubic-bezier(.22, 1, .36, 1),
        margin .45s ease,
        padding .45s ease;
}

/* 외부인용 상단 프로필/공지 display ON/OFF 버튼 */
.pb-top-toggle-wrap {
    display: flex;
    justify-content: flex-end;
    margin: 0 0 8px;
}

.pb-top-toggle-btn {
    border: 1px solid #ddd;
    border-radius: 999px;
    background: rgba(255,255,255,.75);
    color: #777;
    padding: 3px 9px;
    font-size: 11px;
    line-height: 1.5;
    cursor: pointer;
    font-family: inherit;
}

.pb-top-toggle-btn:hover {
    background: #fff;
    color: #333;
}

/* hover 미세 확대 최종 보정: 아래쪽 transform 선언이 덮어써도 마지막에 다시 적용 */
body:not(.pb-edit-mode) #pbApp > .pb-card:hover,
body:not(.pb-edit-mode) #pbBlocksView > .pb-card:hover,
body:not(.pb-edit-mode) #pbBlocksView > .pb-text-toggle:hover,
body:not(.pb-edit-mode) #pbBlocksView > .pb-editable-block.pb-text-toggle-visible:hover {
    transform: scale(1.008) !important;
    box-shadow: 0 8px 20px rgba(0,0,0,.045);
}

body:not(.pb-edit-mode) #pbBlocksView > .pb-editable-block.pb-text-toggle-hidden:hover {
    transform: translateY(-8px) scale(.985) !important;
    box-shadow: none !important;
}

.pb-edit-mode #pbApp > .pb-card:hover,
.pb-edit-mode #pbBlocksView > .pb-card:hover,
.pb-edit-mode #pbBlocksView > .pb-text-toggle:hover,
.pb-edit-mode #pbBlocksView > .pb-editable-block.pb-text-toggle-visible:hover {
    transform: none !important;
}


/* 관리자 편집창: 외부인 표시 여부 선택 */
.pb-visible-select {
    width: 100%;
    box-sizing: border-box;
    border: 1px solid #ccc;
    border-radius: 6px;
    padding: 8px;
    font-size: 13px;
    background: #fff;
}


/* 디데이 배너 블럭: 이미지 1장 + 좌상단 이름 + 우하단 D-day */
.pb-dday-banner {
    position: relative;
    width: 70%;
    min-height: 110px;
    margin-left: auto;
    margin-right: auto;
    padding: 0;
    overflow: hidden;
    border-radius: var(--pb-radius);
    color: var(--pb-dday-banner-color, #fff);
    background: #f2f2f2;
}
.pb-dday-banner img {
    width: 100%;
    height: 100%;
    min-height: inherit;
    display: block;
    object-fit: cover;
    border-radius: inherit;
}
.pb-dday-banner-name,
.pb-dday-banner-date {
    position: absolute;
    z-index: 4;
    color: var(--pb-dday-banner-color, #fff);
    text-shadow:
        0 1px 2px rgba(0,0,0,.45),
        0 0 8px rgba(0,0,0,.28);
    pointer-events: none;
}
.pb-dday-banner-name {
    top: 8px;
    left: 10px;
    max-width: calc(100% - 20px);
    font-size: 13px;
    font-weight: 700;
    line-height: 1.3;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}
.pb-dday-banner-date {
    right: 10px;
    bottom: 8px;
    text-align: right;
    line-height: 1.1;
}
.pb-dday-banner-date strong {
    display: block;
    font-size: 20px;
    font-weight: 700;
    letter-spacing: .02em;
}
.pb-dday-banner-date span {
    display: block;
    margin-top: 2px;
    font-size: 11px;
    opacity: .95;
    font-weight: 700;
}
@media (max-width:640px){
    .pb-dday-banner {
        width: 70%;
        min-height: 90px;
    }
    .pb-dday-banner-name {
        top: 7px;
        left: 8px;
        font-size: 11px;
    }
    .pb-dday-banner-date {
        right: 8px;
        bottom: 7px;
    }
    .pb-dday-banner-date strong {
        font-size: 16px;
    }
    .pb-dday-banner-date span {
        font-size: 9px;
    }
}


/* 배경 없는 라공에디션 글 블럭 */
.pb-plain-rich-text-block {
    box-sizing: border-box;
    margin: 0 0 14px;
    padding: 4px 2px;
    background: transparent;
    border: 0;
    border-radius: 0;
    text-align: left;
}
.pb-plain-rich-text-block .pb-rich-content,
.pb-plain-rich-text-block .ra0-content {
    text-align: left;
    white-space: normal;
}
.pb-plain-rich-text-block .pb-rich-content:empty:before {
    content: '배경 없이 자유롭게 글을 입력할 수 있음';
    color: #888;
}

/* 배경 없는 글 블럭도 hover 시 아주 살짝 확대 */
#pbBlocksView > .pb-plain-rich-text-block {
    transition: transform .34s cubic-bezier(.2,.9,.2,1), opacity .35s ease;
    transform-origin: center center;
}
#pbBlocksView > .pb-plain-rich-text-block:hover {
    transform: scale(1.008);
}
.pb-edit-mode #pbBlocksView > .pb-plain-rich-text-block:hover,
#pbBlocksView > .pb-plain-rich-text-block.pb-text-toggle-hidden:hover {
    transform: none;
}

/* 글자 토글 숨김/표시 상태에서도 배경 없는 글 블럭이 높이 문제 없이 접히도록 보정 */
#pbBlocksView > .pb-plain-rich-text-block.pb-text-toggle-hidden {
    max-height: 0 !important;
    min-height: 0 !important;
    margin-top: 0 !important;
    margin-bottom: 0 !important;
    padding-top: 0 !important;
    padding-bottom: 0 !important;
    overflow: hidden;
    opacity: 0;
    pointer-events: none;
}

/* 배경없는 글 블럭: 촘촘한 안내문용 */
.pb-plain-rich-text-block,
.pb-plain-rich-text-block .pb-rich-content,
.pb-plain-rich-text-block .ra0-content {
    line-height: 1.25 !important;
}

/* RA0 안에서 div가 여러 겹 생겨도 여백 제거 */
.pb-plain-rich-text-block .ra0-content div,
.pb-plain-rich-text-block .ra0-content p,
.pb-plain-rich-text-block .ra0-content span {
    margin-top: 0 !important;
    margin-bottom: 0 !important;
}

/* 문단 사이 기본 여백 제거 */
.pb-plain-rich-text-block .pb-rich-content p {
    margin: 0 !important;
}
