/**
 * DXCMS Page Skin — style.css v1.0.0
 */

/* ══ 본문 출력 영역 ══ */
.page-content-wrap {
    position: relative;
}

/* 에디터 본문 스타일 그대로 적용 */
.page-content {
    font-size: 1rem;
    line-height: 1.8;
    color: var(--text-main, #1e293b);
    word-break: break-word;
}
.page-content img { max-width: 100%; height: auto; }
.page-content table { width: 100%; border-collapse: collapse; }
.page-content td, .page-content th {
    border: 1px solid var(--border, #e2e8f0);
    padding: 8px 12px;
}
.page-content iframe { max-width: 100%; }

/* ══ 관리자 툴바 ══ */
.page-admin-bar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 8px;
    padding: 10px 16px;
    background: #f8fafc;
    border: 1px solid #e2e8f0;
    border-radius: 10px;
    margin-bottom: 16px;
}
.page-admin-badge {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    font-size: .72rem;
    font-weight: 700;
    color: #4f46e5;
    background: rgba(99,102,241,.1);
    border: 1px solid rgba(99,102,241,.2);
    padding: 3px 10px;
    border-radius: 99px;
}
.page-admin-actions {
    display: flex;
    align-items: center;
    gap: 6px;
}
.page-admin-btn {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    padding: 6px 14px;
    border-radius: 8px;
    font-size: .78rem;
    font-weight: 700;
    text-decoration: none;
    cursor: pointer;
    border: none;
    font-family: inherit;
    transition: filter .12s;
}
.page-admin-btn-write {
    background: var(--p, #1a73e8);
    color: #fff;
    box-shadow: 0 2px 8px rgba(26,115,232,.25);
}
.page-admin-btn-write:hover { filter: brightness(1.1); }
.page-admin-btn-edit {
    background: #f1f5f9;
    color: #374151;
    border: 1px solid #e2e8f0;
}
.page-admin-btn-edit:hover { background: #e2e8f0; }
.page-admin-btn-del {
    background: #fff1f2;
    color: #ef4444;
    border: 1px solid #fecdd3;
}
.page-admin-btn-del:hover { background: #fee2e2; }

/* ══ 콘텐츠 메타 ══ */
.page-content-meta {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-top: 20px;
    padding: 10px 14px;
    background: #f8fafc;
    border: 1px solid #e2e8f0;
    border-radius: 8px;
    font-size: .75rem;
    color: #64748b;
}
.page-meta-sep { color: #cbd5e1; }
.page-list-link {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    color: var(--p, #1a73e8);
    text-decoration: none;
    font-weight: 600;
}
.page-list-link:hover { text-decoration: underline; }

/* ══ 빈 상태 ══ */
.page-empty {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 12px;
    padding: 60px 20px;
    color: #94a3b8;
    text-align: center;
}
.page-empty i { font-size: 2.5rem; color: #cbd5e1; }
.page-empty p { font-size: .9rem; margin: 0; }

/* ══ 관리자 목록 ══ */
.page-admin-list-wrap {
    margin-top: 32px;
    background: var(--bg-card, #fff);
    border: 1px solid var(--border, #e2e8f0);
    border-radius: 14px;
    overflow: hidden;
    box-shadow: 0 2px 8px rgba(0,0,0,.04);
}
.page-admin-list-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 14px 20px;
    border-bottom: 1px solid var(--border, #e2e8f0);
    background: #f8fafc;
}
.page-admin-list-title {
    font-size: .9rem;
    font-weight: 700;
    color: var(--text-main, #374151);
    margin: 0;
    display: flex;
    align-items: center;
    gap: 8px;
}
.page-admin-list-cnt {
    font-size: .72rem;
    font-weight: 700;
    color: var(--p, #1a73e8);
    background: rgba(26,115,232,.08);
    padding: 1px 8px;
    border-radius: 99px;
}

.page-admin-table {
    width: 100%;
    border-collapse: collapse;
    font-size: .82rem;
}
.page-admin-table thead tr {
    background: #f8fafc;
}
.page-admin-table th {
    padding: 10px 14px;
    text-align: left;
    font-size: .72rem;
    font-weight: 700;
    color: #64748b;
    border-bottom: 1px solid var(--border, #e2e8f0);
    white-space: nowrap;
}
.page-admin-table tbody tr {
    border-bottom: 1px solid #f1f5f9;
    transition: background .1s;
}
.page-admin-table tbody tr:last-child { border-bottom: none; }
.page-admin-table tbody tr:hover { background: #f8fafc; }
.page-row-latest { background: rgba(26,115,232,.03); }

.page-td-num {
    padding: 10px 14px;
    text-align: center;
    color: #94a3b8;
    font-size: .75rem;
    width: 50px;
}
.page-td-title {
    padding: 10px 14px;
}
.page-td-title a {
    color: var(--text-main, #374151);
    text-decoration: none;
    font-weight: 600;
}
.page-td-title a:hover { color: var(--p, #1a73e8); }
.page-td-author, .page-td-date {
    padding: 10px 14px;
    color: #64748b;
    white-space: nowrap;
}
.page-td-actions {
    padding: 8px 14px;
    white-space: nowrap;
}
.page-latest-badge {
    display: inline-flex;
    align-items: center;
    font-size: .65rem;
    font-weight: 800;
    color: var(--p, #1a73e8);
    background: rgba(26,115,232,.1);
    padding: 1px 6px;
    border-radius: 4px;
}
.page-on-badge {
    display: inline-flex;
    align-items: center;
    font-size: .65rem;
    font-weight: 700;
    color: #059669;
    background: rgba(16,185,129,.1);
    padding: 1px 6px;
    border-radius: 4px;
    margin-left: 6px;
    border: 1px solid rgba(16,185,129,.2);
}
.page-tbl-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 28px;
    height: 28px;
    border-radius: 6px;
    text-decoration: none;
    font-size: .75rem;
    transition: all .12s;
    margin-right: 4px;
}
.page-tbl-btn-edit { background: #f1f5f9; color: #374151; }
.page-tbl-btn-edit:hover { background: #e2e8f0; }
.page-tbl-btn-view { background: rgba(26,115,232,.08); color: var(--p,#1a73e8); }
.page-tbl-btn-view:hover { background: rgba(26,115,232,.15); }

/* 페이지네이션 */
.page-pagination {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 4px;
    padding: 14px;
    border-top: 1px solid var(--border, #e2e8f0);
}
.page-pager {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 32px;
    height: 32px;
    border-radius: 8px;
    font-size: .8rem;
    font-weight: 600;
    color: #64748b;
    text-decoration: none;
    transition: all .12s;
    background: #f8fafc;
    border: 1px solid #e2e8f0;
}
.page-pager:hover { background: #f1f5f9; color: var(--text-main,#374151); }
.page-pager-cur {
    background: var(--p, #1a73e8);
    color: #fff !important;
    border-color: var(--p, #1a73e8);
}

/* ══ view.php ══ */
.page-view-wrap { display: flex; flex-direction: column; gap: 16px; }
.page-back-link {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    font-size: .78rem;
    color: #64748b;
    text-decoration: none;
    transition: color .12s;
}
.page-back-link:hover { color: var(--p, #1a73e8); }
.page-view-header {
    padding-bottom: 16px;
    border-bottom: 1px solid var(--border, #e2e8f0);
}
.page-view-title {
    font-size: 1.4rem;
    font-weight: 800;
    color: var(--text-main, #1e293b);
    margin: 0 0 8px;
    line-height: 1.4;
}
.page-view-meta {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: .78rem;
    color: #64748b;
}
.page-view-preview-info {
    display: flex;
    align-items: center;
    gap: 8px;
    flex-wrap: wrap;
    padding: 12px 16px;
    background: rgba(99,102,241,.05);
    border: 1px solid rgba(99,102,241,.15);
    border-radius: 10px;
    font-size: .78rem;
    color: #4f46e5;
}
.page-view-preview-info a {
    color: var(--p, #1a73e8);
    font-weight: 600;
    text-decoration: none;
}
.page-view-preview-info a:hover { text-decoration: underline; }
