/* css/admin.css - 後台管理介面 */
.admin-modal { width: 97vw; height: 90vh; max-width: none; background: #FDFDFD; border-radius: var(--radius-std); box-shadow: var(--shadow-float); display: flex; overflow: hidden; border: 1px solid var(--border-line); position: relative; }
.admin-sidebar { width: 15%; min-width: 180px; background: #F4F1EA; border-right: 1px solid var(--border-line); display: flex; flex-direction: column; padding: 20px 0; }
.adm-brand { padding: 0 20px 30px 20px; font-family: var(--font-serif); font-size: 1.1rem; font-weight: bold; color: var(--text-main); display: flex; align-items: center; gap: 10px; }
.adm-nav-item { padding: 12px 20px; cursor: pointer; color: var(--text-sub); font-weight: 500; display: flex; align-items: center; gap: 12px; transition: 0.2s; font-size: 0.95rem; border-left: 4px solid transparent; }
.adm-nav-item:hover { background: rgba(0,0,0,0.03); color: var(--text-main); }
.adm-nav-item.active { background: #fff; color: var(--accent-red); border-left-color: var(--accent-red); font-weight: bold; }
.admin-content { flex: 1; padding: 30px; overflow: hidden; background: #fff; position: relative; display: flex; flex-direction: column; }
.adm-header { display: flex; justify-content: space-between; align-items: center; margin-bottom: 30px; padding-bottom: 15px; border-bottom: 1px solid var(--border-line); flex-shrink: 0; }
.adm-title { font-size: 1.5rem; font-weight: 500; color: var(--text-main); font-family: var(--font-serif); }

/* Slide Panel */
.slide-panel { position: absolute; top: 0; right: 0; width: 360px; height: 100%; background: #FFFCF9; border-left: 1px solid var(--border-line); box-shadow: -5px 0 15px rgba(0,0,0,0.05); padding: 25px; transform: translateX(100%); transition: transform 0.3s ease; z-index: 20; display: flex; flex-direction: column; }
.slide-panel.open { transform: translateX(0); }
.sp-header { font-family: var(--font-serif); font-size: 1.2rem; font-weight: bold; margin-bottom: 20px; display: flex; justify-content: space-between; align-items: center; }
.sp-content { flex: 1; overflow-y: auto; }
.sp-close-btn { background: none; border: none; font-size: 1.2rem; color: var(--text-sub); cursor: pointer; }
.sp-close-btn:hover { color: var(--text-main); }

/* Admin Lists */
.clean-list { display: flex; flex-direction: column; gap: 8px; }
.clean-item { display: flex; justify-content: space-between; align-items: center; padding: 15px; border: 1px solid var(--border-line); border-radius: 4px; background: #fff; transition: 0.2s; }
.clean-item:hover { border-color: var(--text-sub); box-shadow: 0 2px 5px rgba(0,0,0,0.03); }
.clean-item.active { background: #F9F7F5; border-color: var(--text-main); }
.drag-handle { cursor: grab; color: var(--text-sub); padding: 5px; }

/* Tabs */
.tab-content { flex: 1; flex-direction: column; overflow-y: auto; min-height: 0; display: none; }
#tab-manage { overflow: hidden; }

/* Option Editing */
.opt-edit-row { display: flex; gap: 8px; margin-bottom: 8px; align-items: center; background: #fafafa; padding: 8px; border-radius: 4px; border: 1px solid #eee; }
.opt-edit-row input, .opt-edit-row select { margin-bottom: 0 !important; font-size: 0.9rem; padding: 6px; }

/* Order Status Badges */
.order-status-badge { font-size: 0.75rem; padding: 2px 6px; border-radius: 4px; margin-left: 5px; color: #fff; vertical-align: middle; display: inline-block; }
.status-deleted { background-color: var(--accent-red); }
.status-edited { background-color: var(--text-sub); }
.row-deleted { opacity: 0.6; background-color: #fcfcfc; }
.row-deleted .ord-content { text-decoration: line-through; color: var(--text-sub); }

/* Print Settings UI (Admin Panel) */
.print-setting-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 30px; height: 100%; }
.preview-pane { background: #555; border-radius: 8px; padding: 20px; display: flex; flex-direction: column; align-items: center; overflow-y: auto; }
.preview-tabs { display: flex; gap: 5px; width: 100%; max-width: 320px; margin-bottom: 10px; }
.pv-tab { flex: 1; padding: 8px; text-align: center; background: #444; color: #aaa; cursor: pointer; border-radius: 4px 4px 0 0; font-size: 0.9rem; transition: 0.2s; }
.pv-tab.active { background: #fff; color: #000; font-weight: bold; }
.preview-paper { 
    background: #fff; 
    width: var(--print-width); 
    padding: 10px var(--print-padding);
    min-height: 300px; 
    box-shadow: 0 0 10px rgba(0,0,0,0.3); 
    font-family: 'Courier New', monospace; 
    font-size: var(--print-font-size);
    color: #000;
    transition: all 0.3s;
}
.preview-paper img { filter: grayscale(100%) contrast(150%); }