:root {
	--dc-primary: #2271b1;
	--dc-primary-dark: #135e96;
	--dc-danger: #c0392b;
	--dc-warning: #9a6700;
	--dc-border: #b9bcbf;
	--dc-bg: #f6f7f7;
	--dc-text: #1d2327;
}

.dc-wrapper {
	max-width: 100%;
	margin: 1.5em 0;
	font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
	color: var(--dc-text);
	box-sizing: border-box;
}
.dc-wrapper *, .dc-wrapper *::before, .dc-wrapper *::after { box-sizing: inherit; }
.dc-modal, .dc-modal *, .dc-modal *::before, .dc-modal *::after { box-sizing: border-box; }

.dc-status {
	display: flex;
	align-items: center;
	gap: 8px;
	color: var(--dc-text);
	margin-bottom: 12px;
	font-size: 14px;
	font-weight: 400;
	line-height: 1.2;
}
.dc-status strong { font-weight: 700; }
.dc-avatar {
	width: 28px;
	height: 28px;
	border-radius: 50%;
	display: block;
	flex-shrink: 0;
}
.dc-status.dc-status-inline {
	margin-bottom: 0;
	margin-left: auto;
	white-space: nowrap;
}

/* Applied via JS to the page's own H1 when we can find it, so the status
   line sits to the right of the page title instead of above the table. */
.dc-title-status-row {
	display: flex;
	align-items: center;
	justify-content: space-between;
	flex-wrap: wrap;
	gap: 12px;
}

.dc-toolbar {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	justify-content: space-between;
	gap: 10px;
	margin-bottom: 14px;
}
.dc-toolbar-left, .dc-toolbar-right { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }

.dc-btn {
	display: inline-block;
	padding: 8px 16px;
	font-size: 14px;
	line-height: 1.2;
	border-radius: 5px;
	border: 1px solid var(--dc-border);
	background: #fff;
	color: var(--dc-text);
	cursor: pointer;
	transition: background .15s ease, border-color .15s ease;
}
.dc-btn:hover { background: var(--dc-bg); }
.dc-btn:disabled { opacity: .5; cursor: not-allowed; }

.dc-btn-primary { background: var(--dc-primary); border-color: var(--dc-primary); color: #fff; }
.dc-btn-primary:hover { background: var(--dc-primary-dark); border-color: var(--dc-primary-dark); }

.dc-btn-danger { background: #fff; border-color: var(--dc-danger); color: var(--dc-danger); }
.dc-btn-danger:hover { background: var(--dc-danger); color: #fff; }

.dc-btn-small { padding: 5px 12px; font-size: 13px; }
.dc-btn-block { width: 100%; margin-top: 10px; }

#dc-search-input {
	padding: 7px 12px;
	border: 1px solid var(--dc-border) !important;
	border-radius: 5px;
	font-size: 14px;
	min-width: 220px;
	background: #fff;
}

#dc-tag-filter {
	padding: 7px 12px;
	border: 1px solid var(--dc-border) !important;
	border-radius: 5px;
	font-size: 14px;
	background: #fff;
	color: var(--dc-text);
	max-width: 180px;
}

table.dc-table {
	border-collapse: collapse;
	width: 100%;
}
table.dc-table thead th {
	background: var(--dc-bg);
	border-bottom: 2px solid var(--dc-border);
	padding: 10px 12px;
	text-align: left;
	font-size: 13px;
	text-transform: uppercase;
	letter-spacing: .03em;
}
table.dc-table tbody td {
	padding: 8px 12px;
	border-bottom: 1px solid var(--dc-border);
	font-size: 14px;
	vertical-align: middle;
}
table.dc-table tbody tr:hover { background: #fafafa; }
table.dc-table tbody tr.dc-row-selected { background: #eaf5ff; }
table.dc-table tbody tr.dc-row-pinned { background: #fff8e5; }
table.dc-table tbody tr.dc-row-pinned:hover { background: #fef2d0; }
table.dc-table tbody tr.dc-row-pinned.dc-row-selected { background: #eaf5ff; }

th.dc-col-check, td.dc-col-check { width: 34px; text-align: center; }
th.dc-col-check input,
td.dc-col-check input {
	display: block;
	margin: 0 auto;
}
th.dc-col-actions, td.dc-col-actions { width: 60px; text-align: center; }
th.dc-col-pin, td.dc-col-pin { width: 40px; text-align: center; }

.dc-wrapper.dc-hide-checkbox th.dc-col-check,
.dc-wrapper.dc-hide-checkbox td.dc-col-check {
	display: none !important;
}
.dc-wrapper.dc-hide-actions th.dc-col-actions,
.dc-wrapper.dc-hide-actions td.dc-col-actions {
	display: none !important;
}
th.dc-col-pin {
	cursor: default !important;
	background-image: none !important;
}
th.dc-col-pin.sorting:before,
th.dc-col-pin.sorting:after,
th.dc-col-pin.sorting_asc:before,
th.dc-col-pin.sorting_asc:after,
th.dc-col-pin.sorting_desc:before,
th.dc-col-pin.sorting_desc:after,
th.dc-col-pin span.dt-column-order {
	display: none !important;
	content: none !important;
}
td.dc-col-center { text-align: center; }
table.dc-table thead th.dc-col-center { text-align: center !important; }
td.dc-clickable { cursor: pointer; }

input.dc-row-checkbox, #dc-select-all {
	width: 16px;
	height: 16px;
	cursor: pointer;
}

.dc-pin-btn {
	width: 24px;
	height: 24px;
	opacity: 0.3;
	cursor: default;
	transition: opacity .15s ease, transform .15s ease;
	vertical-align: middle;
}
.dc-can-manage .dc-pin-btn { cursor: pointer; }
.dc-can-manage .dc-pin-btn:hover { opacity: 0.7; }
.dc-pin-btn.dc-pinned { opacity: 1; }
.dc-can-manage .dc-pin-btn.dc-pinned:hover { opacity: 0.85; transform: scale(1.08); }

.dc-edit-btn { padding: 4px 10px; font-size: 12px; }

.dc-title-cell { font-weight: 700; }

.dc-current-file {
	font-size: 13px;
	margin: 10px 0 4px;
	color: var(--dc-text);
}
.dc-current-file strong { font-weight: 700; }

.dc-choice-buttons {
	display: flex;
	gap: 8px;
	margin: 4px 0 6px;
}
.dc-choice-buttons .dc-btn { flex: 1; }
.dc-choice-buttons .dc-btn.dc-choice-selected {
	background: var(--dc-primary);
	border-color: var(--dc-primary);
	color: #fff;
}

.dc-table-footer { margin-top: 10px; font-size: 13px; }

/* Modals */
.dc-modal {
	position: fixed;
	inset: 0;
	background: rgba(0,0,0,.5);
	z-index: 100000;
	display: flex;
	align-items: center;
	justify-content: center;
	padding: 20px;
	font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
	color: var(--dc-text);
}
.dc-modal-content {
	background: #fff;
	border-radius: 8px;
	padding: 28px;
	width: 100%;
	max-width: 420px;
	max-height: calc(100vh - 40px);
	overflow-y: auto;
	position: relative;
	box-shadow: 0 10px 40px rgba(0,0,0,.2);
}
.dc-modal-content h2 { margin-top: 0; font-size: 20px; }
.dc-modal-content form { display: flex; flex-direction: column; gap: 4px; }
.dc-modal-content label { font-size: 13px; font-weight: 600; margin-top: 10px; }
.dc-modal-content input[type="text"],
.dc-modal-content input[type="password"] {
	padding: 9px 11px;
	border: 1px solid var(--dc-border) !important;
	border-radius: 5px;
	font-size: 14px;
	background: #fff;
	width: 100%;
}
.dc-modal-content input[type="text"]:focus,
.dc-modal-content input[type="password"]:focus,
#dc-search-input:focus {
	outline: none;
	border-color: var(--dc-primary) !important;
	box-shadow: 0 0 0 2px rgba(34,113,177,.15);
}

.dc-file-input-wrap {
	border: 1px dashed var(--dc-border);
	border-radius: 5px;
	padding: 10px 12px;
	background: var(--dc-bg);
}
.dc-file-input-wrap input[type="file"] { width: 100%; font-size: 13px; }

.dc-modal-close {
	position: absolute;
	top: 14px;
	right: 18px;
	cursor: pointer;
	font-size: 22px;
	line-height: 1;
	color: #666;
}
.dc-modal-close:hover { color: #000; }

.dc-field-error {
	background: #fdeaea;
	border: 1px solid #f3c6c6;
	color: var(--dc-danger);
	padding: 6px 10px;
	border-radius: 4px;
	font-size: 13px;
	margin: 0 0 6px;
}
.dc-field-warning {
	background: #fff8e5;
	border: 1px solid #f0ddab;
	color: var(--dc-warning);
	padding: 6px 10px;
	border-radius: 4px;
	font-size: 13px;
	margin: 0 0 6px;
}

@media (max-width: 640px) {
	.dc-toolbar { flex-direction: column; align-items: stretch; }
	.dc-toolbar-left, .dc-toolbar-right { width: 100%; }
	#dc-search-input { flex: 1; min-width: 0; }
}
