.navbar-brand-box .logo-lg {
	font-size: 18px;
	letter-spacing: .08em;
}

.upload-dropzone {
	display: block;
	padding: 2.5rem 1.5rem;
	border: 2px dashed var(--bs-border-color);
	border-radius: .5rem;
	background: var(--bs-tertiary-bg);
	text-align: center;
	cursor: pointer;
	transition: border-color .2s ease, background-color .2s ease;
}

.upload-dropzone:hover {
	border-color: var(--bs-primary);
	background: rgba(var(--bs-primary-rgb), .05);
}

.tag-chip {
	display: inline-flex;
	align-items: center;
	gap: .35rem;
	padding: .3rem .65rem;
	border: 0;
	border-radius: 2rem;
	background: rgba(var(--bs-primary-rgb), .12);
	color: var(--bs-primary);
	font-size: .75rem;
	font-weight: 600;
}

.metric-value {
	font-size: 1.35rem;
	font-weight: 600;
	color: var(--bs-emphasis-color);
}

.tag-performance-table {
	min-width: 1540px;
}

.tag-performance-table th,
.tag-performance-table td {
	vertical-align: middle;
}

.tag-performance-table .tag-performance-heading {
	padding: .85rem .7rem;
	border-bottom-width: 3px;
	color: #495057;
	font-size: .78rem;
	font-weight: 700;
	letter-spacing: .03em;
	text-align: center;
	text-transform: uppercase;
}

.tag-performance-heading small {
	font-size: .68rem;
	font-weight: 500;
	letter-spacing: 0;
	text-transform: none;
}

.tag-performance-table .heading-tag {
	min-width: 320px;
	background: var(--bs-tertiary-bg);
	border-bottom-color: var(--bs-secondary);
	text-align: left;
}

.tag-performance-table .heading-ads {
	background: #f6f3ff;
	border-bottom-color: #b8a8ff;
	color: #6843de;
}

.tag-performance-table .heading-shop {
	background: #fff8ed;
	border-bottom-color: #f3c37f;
	color: #d66a13;
}

.tag-performance-table .heading-rate {
	background: #eef8ff;
	border-bottom-color: #9fd4f4;
	color: #237fbc;
}

.tag-performance-table .heading-profit {
	background: #effcf4;
	border-bottom-color: #9ce5b5;
	color: #278959;
}

.tag-performance-table .heading-stat {
	background: #f7f9fc;
	border-bottom-color: #dce3ed;
	color: #8290a6;
}

.tag-performance-identity {
	min-width: 320px;
	padding: 1rem !important;
	white-space: normal;
}

.tag-performance-table .metric-ads {
	background: rgba(117, 82, 230, .035);
}

.tag-performance-table .metric-shop {
	background: rgba(246, 161, 55, .045);
}

.tag-performance-table .metric-rate {
	background: rgba(61, 169, 226, .045);
}

.tag-performance-table .metric-profit {
	background: rgba(41, 180, 100, .045);
}

.tag-performance-table .metric-stat {
	min-width: 142px;
	font-size: .78rem;
}

.tag-performance-card {
	border: 0;
	border-radius: 1rem;
	box-shadow: 0 .5rem 1.5rem rgba(52, 73, 94, .06);
}

.tag-performance-card .card-body {
	padding: 1.5rem;
}

.tag-performance-summary {
	display: grid;
	grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
	gap: .8rem;
	margin-bottom: 1.25rem;
}

.tag-performance-summary-item {
	display: flex;
	align-items: center;
	gap: .8rem;
	min-width: 0;
	padding: .85rem 1rem;
	border: 1px solid transparent;
	border-radius: .85rem;
}

.tag-performance-summary-item > div {
	display: grid;
	gap: .12rem;
	min-width: 0;
}

.tag-performance-summary-item span:not(.tag-performance-summary-icon) {
	color: #6c7a90;
	font-size: .72rem;
	font-weight: 700;
	letter-spacing: .035em;
	text-transform: uppercase;
}

.tag-performance-summary-item strong {
	overflow: hidden;
	color: #33435f;
	font-size: 1.05rem;
	text-overflow: ellipsis;
	white-space: nowrap;
}

.tag-performance-summary-icon {
	display: inline-flex;
	flex: 0 0 auto;
	align-items: center;
	justify-content: center;
	width: 2.4rem;
	height: 2.4rem;
	border-radius: .7rem;
	font-size: 1.25rem;
}

.summary-spend { background: #f5f2ff; border-color: #e7e0ff; }
.summary-spend .tag-performance-summary-icon { background: #e6ddff; color: #6843de; }
.summary-commission { background: #fff8ed; border-color: #fce4bf; }
.summary-commission .tag-performance-summary-icon { background: #ffebca; color: #cf761a; }
.summary-profit { background: #effcf4; border-color: #d3f2de; }
.summary-profit .tag-performance-summary-icon { background: #d4f4df; color: #278959; }
.summary-profit strong { color: #278959; }
.summary-loss { background: #fff4f4; border-color: #ffdada; }
.summary-loss .tag-performance-summary-icon { background: #ffe0e0; color: #d64545; }
.summary-loss strong { color: #c73737; }

.tag-ai-analysis-card {
	margin-bottom: 1.25rem;
	padding: 1.25rem;
	border: 1px solid #dfe4ff;
	border-radius: 1rem;
	background: linear-gradient(115deg, #f6f7ff 0%, #fff 72%);
}

.tag-ai-analysis-heading {
	display: flex;
	align-items: center;
	gap: .85rem;
}

.tag-ai-analysis-mark {
	display: inline-flex;
	flex: 0 0 auto;
	align-items: center;
	justify-content: center;
	width: 2.85rem;
	height: 2.85rem;
	border-radius: .85rem;
	background: linear-gradient(135deg, #5e6ae5, #8a62ee);
	box-shadow: 0 .35rem .8rem rgba(94, 106, 229, .24);
	color: #fff;
	font-size: 1.4rem;
}

.tag-ai-analysis-heading span {
	color: #6d72bd;
	font-size: .72rem;
	font-weight: 700;
	letter-spacing: .08em;
	text-transform: uppercase;
}

.tag-ai-analysis-heading h5 {
	margin: .1rem 0 .2rem;
	color: #303c5d;
	font-size: 1rem;
	font-weight: 700;
}

.tag-ai-analysis-heading p {
	margin: 0;
	color: #8491a9;
	font-size: .86rem;
}

.tag-ai-analysis-form {
	margin-top: 1rem;
}

.tag-ai-analysis-button {
	display: inline-flex;
	align-items: center;
	gap: .45rem;
	min-width: 11.5rem;
	justify-content: center;
	border: 0;
	border-radius: .65rem;
	background: linear-gradient(135deg, #5e6ae5, #765ae8);
	box-shadow: 0 .3rem .75rem rgba(94, 106, 229, .25);
	font-weight: 600;
}

.tag-ai-analysis-button:hover,
.tag-ai-analysis-button:focus {
	background: linear-gradient(135deg, #4f5bd3, #6748d7);
	box-shadow: 0 .4rem .9rem rgba(94, 106, 229, .32);
}

.tag-ai-analysis-button:disabled {
	border: 0;
	box-shadow: none;
}

.tag-ai-analysis-setup {
	display: flex;
	align-items: flex-start;
	gap: .4rem;
	margin: .85rem 0 0;
	color: #8894aa;
	font-size: .78rem;
}

.tag-ai-analysis-setup i { color: #7482d8; font-size: 1rem; }

.tag-ai-analysis-result {
	margin-top: 1rem;
	padding: 1rem;
	border-radius: .8rem;
}

.tag-ai-analysis-result.is-success { border: 1px solid #dfe5ff; background: rgba(255, 255, 255, .8); }
.tag-ai-analysis-result.is-error { border: 1px solid #ffd8d8; background: #fff7f7; }

.tag-ai-analysis-result-heading,
.tag-ai-analysis-error {
	display: flex;
	align-items: flex-start;
	gap: .55rem;
}

.tag-ai-analysis-result-heading > i { color: #3da66d; font-size: 1.3rem; }
.tag-ai-analysis-error > i { color: #dc5e5e; font-size: 1.2rem; }

.tag-ai-analysis-result-heading div { display: grid; gap: .05rem; }
.tag-ai-analysis-result-heading strong { color: #30405c; }
.tag-ai-analysis-result-heading span,
.tag-ai-analysis-error span { color: #7d8ca4; font-size: .83rem; }

.tag-ai-analysis-summary {
	margin: .9rem 0 0;
	color: #52617a;
	font-size: .9rem;
	line-height: 1.65;
}

.tag-ai-recommendations {
	display: grid;
	grid-template-columns: repeat(auto-fit, minmax(15rem, 1fr));
	gap: .75rem;
	margin-top: 1rem;
}

.tag-ai-recommendation {
	padding: .9rem;
	border: 1px solid #e5eaf3;
	border-radius: .75rem;
	background: #fff;
}

.tag-ai-recommendation-top {
	display: flex;
	align-items: center;
	gap: .6rem;
}

.tag-ai-decision-icon {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 2.15rem;
	height: 2.15rem;
	border-radius: .65rem;
	font-size: 1.15rem;
}

.tag-ai-recommendation-top div { display: grid; min-width: 0; }
.tag-ai-recommendation-tag { overflow: hidden; color: #75839b; font-size: .76rem; text-overflow: ellipsis; white-space: nowrap; }
.tag-ai-recommendation strong { color: #34435e; font-size: .92rem; }
.tag-ai-recommendation p { margin: .75rem 0 .5rem; color: #596881; font-size: .82rem; line-height: 1.55; }
.tag-ai-recommendation ul { margin: 0; padding-left: 1.05rem; color: #67768e; font-size: .78rem; line-height: 1.55; }
.tag-ai-recommendation li + li { margin-top: .18rem; }

.tag-ai-recommendation.decision-continue { border-color: #d4eedf; }
.tag-ai-recommendation.decision-continue .tag-ai-decision-icon { background: #e5f7ec; color: #32965f; }
.tag-ai-recommendation.decision-pause { border-color: #ffdada; }
.tag-ai-recommendation.decision-pause .tag-ai-decision-icon { background: #fff0f0; color: #d65050; }
.tag-ai-recommendation.decision-improve { border-color: #ffe7bd; }
.tag-ai-recommendation.decision-improve .tag-ai-decision-icon { background: #fff6e5; color: #d28a16; }

.tag-order-distribution-button {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 1.75rem;
	height: 1.75rem;
	padding: 0;
	border: 0;
	border-radius: 50%;
	background: #f8c548;
	color: #fff;
	box-shadow: 0 .2rem .5rem rgba(208, 145, 18, .2);
	font-size: 1rem;
	transition: transform .18s ease, background-color .18s ease, box-shadow .18s ease;
}

.tag-order-distribution-button:hover {
	background: #e9ad24;
	box-shadow: 0 .3rem .7rem rgba(208, 145, 18, .3);
	color: #fff;
	transform: translateY(-1px);
}

.tag-order-distribution-button:focus-visible {
	outline: 3px solid rgba(248, 197, 72, .35);
	outline-offset: 2px;
}

.tag-order-distribution-button:disabled {
	background: #dce2eb;
	box-shadow: none;
	cursor: not-allowed;
}

.tag-click-distribution-modal {
	border: 0;
	border-radius: 1.5rem;
	overflow: hidden;
	box-shadow: 0 1.25rem 3.5rem rgba(39, 53, 80, .24);
}

.tag-click-distribution-modal .modal-header {
	align-items: flex-start;
	padding: 2rem 2.5rem 1.8rem;
	border-bottom-color: #edf0f5;
}

.tag-click-distribution-modal .modal-title {
	margin: .25rem 0 .35rem;
	color: #26364f;
	font-size: 1.5rem;
	font-weight: 700;
}

.tag-click-distribution-modal .modal-header p,
.tag-click-distribution-modal .modal-footer span {
	color: #9aa9c1;
}

.tag-click-distribution-modal .btn-close {
	width: 2.8rem;
	height: 2.8rem;
	margin: -.1rem 0 0 1rem;
	border-radius: 50%;
	background-color: #f2f5f9;
	background-size: .9rem;
	opacity: 1;
}

.tag-click-distribution-kicker {
	color: #db921c;
	font-size: .78rem;
	font-weight: 700;
	letter-spacing: .12em;
	text-transform: uppercase;
}

.tag-click-distribution-modal .modal-body {
	padding: 2.5rem;
}

.click-date-distribution-list {
	display: grid;
	gap: 1.35rem;
}

.click-date-distribution-row {
	display: grid;
	grid-template-columns: 5.25rem minmax(0, 1fr) 3.5rem;
	align-items: center;
	gap: 1rem;
}

.click-date-label {
	color: #52627c;
	font-size: .9rem;
	font-weight: 700;
	text-align: right;
}

.click-date-distribution-track {
	height: 3.5rem;
	overflow: hidden;
	border-radius: .9rem;
	background: #f0f3f7;
}

.click-date-distribution-fill {
	display: flex;
	align-items: center;
	justify-content: flex-end;
	min-width: 3.4rem;
	max-width: 100%;
	height: 100%;
	padding: 0 1rem;
	border-radius: .9rem;
	background: #f8c548;
	color: #fff;
	transition: width .25s ease;
}

.click-date-percentage {
	color: #c3cde0;
	font-size: .9rem;
	font-weight: 600;
}

.click-date-distribution-empty {
	display: flex;
	align-items: center;
	justify-content: center;
	gap: .65rem;
	min-height: 8rem;
	border: 1px dashed #d7deea;
	border-radius: 1rem;
	color: #8c9ab1;
	text-align: center;
}

.click-date-distribution-empty i {
	color: #c1cbdb;
	font-size: 1.5rem;
}

.tag-click-distribution-modal .modal-footer {
	justify-content: space-between;
	padding: 1.5rem 2.5rem;
	border-top-color: #edf0f5;
}

.tag-click-distribution-modal .modal-footer .btn {
	min-width: 7.5rem;
	border-radius: 2rem;
	font-weight: 700;
}

.tag-campaign-chip {
	display: inline-flex;
	align-items: center;
	gap: .2rem;
	max-width: 100%;
	padding: .23rem .45rem;
	border: 1px solid rgba(var(--bs-primary-rgb), .22);
	border-radius: 1rem;
	background: rgba(var(--bs-primary-rgb), .07);
	color: var(--bs-primary);
	font-size: .72rem;
	line-height: 1.2;
}

.tag-campaign-chip span {
	overflow: hidden;
	text-overflow: ellipsis;
	white-space: nowrap;
}

.tag-campaign-chip:hover {
	border-color: var(--bs-danger);
	background: rgba(var(--bs-danger-rgb), .07);
	color: var(--bs-danger);
}

.tag-stat {
	display: flex;
	justify-content: space-between;
	gap: .75rem;
	line-height: 1.65;
}

.tag-stat span {
	color: var(--bs-secondary-color);
}

.tag-performance-filter-card,
.tag-breakdown-card {
	border: 0;
	border-radius: 1rem;
	box-shadow: 0 .5rem 1.5rem rgba(52, 73, 94, .06);
}

.tag-performance-filter-card .card-body,
.tag-breakdown-card .card-body {
	padding: 1.5rem;
}

.tag-performance-filter-card .form-label {
	margin-bottom: .4rem;
	font-size: .78rem;
	font-weight: 700;
	letter-spacing: .02em;
	text-transform: uppercase;
	color: #53627a;
}

.tag-performance-filter-card .form-control,
.tag-performance-filter-card .form-select {
	min-height: 2.6rem;
	border-color: #d7deea;
}

.tag-performance-filter-card .btn-group .btn {
	min-width: 6.75rem;
}

.tag-breakdown-table {
	min-width: 950px;
}

.tag-breakdown-table thead th:nth-child(n+2),
.tag-breakdown-table tbody td:nth-child(n+2),
.tag-breakdown-table tfoot td {
	text-align: right;
}

.tag-breakdown-table tfoot {
	background: #f6f8fc;
}

.tag-breakdown-table thead th {
	background: #f6f8fc;
	color: #53627a;
	font-size: .76rem;
	letter-spacing: .03em;
	text-transform: uppercase;
}

.dashboard-performance-card {
	border: 0;
	border-radius: 1.25rem;
	box-shadow: 0 .5rem 1.75rem rgba(52, 73, 94, .07);
}

.dashboard-performance-card .card-body {
	padding: 2rem;
}

.dashboard-heading {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 1rem;
}

.dashboard-title-copy {
	display: flex;
	align-items: center;
	gap: .85rem;
}

.dashboard-title-copy p {
	color: #7887a0;
	font-size: .88rem;
}

.dashboard-heading h4,
.dashboard-trend h5,
.dashboard-daily-table h5 {
	font-weight: 700;
	color: #17335b;
}

.dashboard-heading-icon {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 2.75rem;
	height: 2.75rem;
	border-radius: .85rem;
	background: linear-gradient(135deg, #eeefff, #e8ebff);
	color: #5b5ce2;
	font-size: 1.5rem;
	line-height: 1;
}

.dashboard-filter-form {
	display: grid;
	grid-template-columns: minmax(0, 1.4fr) minmax(0, .55fr) minmax(0, .85fr) minmax(0, 1.1fr) minmax(0, .9fr) minmax(0, 1fr);
	align-items: end;
	gap: .85rem;
	padding: 1.1rem;
	border: 1px solid #e3e8f2;
	border-radius: 1rem;
	background: linear-gradient(135deg, #fbfcff 0%, #f7f9ff 50%, #fbfdff 100%);
	box-shadow: inset 0 1px 0 rgba(255, 255, 255, .9);
}

.dashboard-filter-field {
	display: flex;
	flex-direction: column;
	gap: .38rem;
	min-width: 0;
}

.dashboard-filter-field label {
	margin: 0;
	color: #536783;
	font-size: .76rem;
	font-weight: 700;
	letter-spacing: .02em;
	text-transform: uppercase;
}

.dashboard-filter-field label i {
	margin-right: .32rem;
	color: #6469df;
	font-size: .95rem;
	vertical-align: -1px;
}

.dashboard-filter-form .form-select,
.dashboard-filter-form .form-control {
	width: 100%;
	min-height: 2.9rem;
	border-color: #d7dfeb;
	border-radius: .65rem;
	background-color: #fff;
	box-shadow: 0 .15rem .35rem rgba(44, 67, 104, .03);
	color: #2f405b;
	font-weight: 600;
}

.dashboard-filter-form .form-select:focus,
.dashboard-filter-form .form-control:focus {
	border-color: #7478ed;
	box-shadow: 0 0 0 .2rem rgba(91, 92, 226, .13);
}

.dashboard-ppn .input-group {
	width: 100%;
	flex-wrap: nowrap;
}

.dashboard-ppn .form-control,
.dashboard-ppn .input-group-text {
	min-height: 2.7rem;
	border-color: #d7dfeb;
	font-weight: 700;
}

.dashboard-ppn .input-group .form-control {
	width: 1%;
	min-width: 0;
	flex: 1 1 auto;
	border-radius: .65rem 0 0 .65rem;
}

.dashboard-ppn .input-group-text {
	flex: 0 0 auto;
	border-radius: 0 .65rem .65rem 0;
	background: #eef0ff;
	color: #575dd6;
}

.dashboard-ppn .form-control {
	text-align: center;
}

.dashboard-range-inputs {
	display: flex;
	align-items: center;
	gap: .55rem;
}

.dashboard-range-inputs .form-control {
	width: 100%;
	min-height: 2.9rem;
	font-weight: 600;
}

.dashboard-range-inputs > span {
	color: #7888a1;
	font-weight: 700;
	white-space: nowrap;
}

.dashboard-metric {
	display: flex;
	align-items: center;
	gap: 1.15rem;
	min-height: 7.8rem;
	padding: 1.4rem 1.5rem;
	border: 1px solid;
	border-radius: 1rem;
}

.dashboard-metric .metric-icon {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 4rem;
	height: 4rem;
	border-radius: .75rem;
	font-size: 2rem;
}

.dashboard-metric span:not(.metric-icon) {
	display: block;
	margin-bottom: .3rem;
	font-weight: 600;
	color: #657590;
}

.dashboard-metric strong {
	display: block;
	font-size: 1.7rem;
	line-height: 1.15;
	color: #263d5a;
}

.metric-clicks { border-color: #f6dfba; background: #fffdfa; }
.metric-clicks .metric-icon { color: #ee633a; background: #fff0d8; }
.metric-orders { border-color: #d6e3ff; background: #fbfcff; }
.metric-orders .metric-icon { color: #4b73e7; background: #e1eaff; }
.metric-commission { border-color: #cff2df; background: #fafffc; }
.metric-commission .metric-icon { color: #37966e; background: #d8f8e5; }
.metric-commission strong { color: #2d9668; }
.metric-spend { border-color: #dce1ff; background: #fcfcff; }
.metric-spend .metric-icon { color: #565be5; background: #e1e5ff; }
.metric-spend strong { color: #4d48e5; }
.metric-profit { border-color: #afeccd; background: #effcf5; }
.metric-profit .metric-icon { color: #398a66; background: #d4f8e4; }
.metric-roi { border-color: #e3d4ff; background: #fffdff; }
.metric-roi .metric-icon { color: #7d36e8; background: #f0e4ff; }
.metric-roi strong { color: #7530db; }
.metric-roas { border-color: #f5d870; background: #fffdf8; }
.metric-roas .metric-icon { color: #d98a25; background: #fff3c7; }
.metric-roas strong { color: #bc661d; }

.dashboard-legend {
	display: inline-flex;
	flex-wrap: wrap;
	gap: 1rem;
	padding: .65rem 1rem;
	border-radius: .7rem;
	background: #f8fafc;
	font-size: .78rem;
	font-weight: 600;
}

.dashboard-legend span { display: inline-flex; align-items: center; gap: .4rem; }
.dashboard-legend i { width: 1rem; height: 1rem; border-radius: .15rem; }
.legend-commission, .bar-commission { background: #66cf9c; }
.legend-spend, .bar-spend { background: #7d86e9; }
.legend-loss, .bar-loss { background: #ed7389; }

.dashboard-chart {
	min-height: 20rem;
	overflow-x: auto;
	padding: .75rem .5rem 0;
}

.dashboard-chart-bars {
	display: flex;
	align-items: flex-end;
	gap: 1.25rem;
	min-width: max-content;
	min-height: 18rem;
	padding: 0 1.5rem;
	border-bottom: 1px solid #edf1f6;
}

.dashboard-chart-day {
	display: flex;
	flex-direction: column;
	align-items: center;
	justify-content: flex-end;
	width: 4.5rem;
	height: 18rem;
}

.dashboard-bars {
	display: flex;
	align-items: flex-end;
	justify-content: center;
	gap: .25rem;
	width: 100%;
	flex: 1;
}

.chart-bar { width: 1.15rem; min-height: .25rem; border-radius: .25rem .25rem 0 0; }
.chart-date { margin-top: .6rem; white-space: nowrap; font-size: .72rem; color: #62718b; }

.dashboard-empty-chart {
	display: flex;
	align-items: center;
	justify-content: center;
	gap: .6rem;
	min-height: 17rem;
	color: #8795ab;
}

.dashboard-empty-chart i { font-size: 2rem; }

.dashboard-daily-table .table {
	border: 1px solid #eef1f5;
	border-radius: 1rem;
	overflow: hidden;
}

.dashboard-daily-table thead th {
	padding: 1rem 1.15rem;
	border-bottom: 1px solid #edf1f5;
	background: #f8fafc;
	color: #344a6a;
	font-size: .76rem;
	text-transform: none;
}

.dashboard-daily-table tbody td { padding: 1rem 1.15rem; }

.dashboard-daily-table tfoot th,
.dashboard-daily-table tfoot td {
	padding: 1rem 1.15rem;
	text-align: right;
	border-top: 2px solid #edf1f5;
	background: #f8fafc;
	font-weight: 700;
}

.dashboard-daily-table thead th:nth-child(n+2),
.dashboard-daily-table tbody td:nth-child(n+2),
.dashboard-daily-table tfoot td {
	text-align: right;
}

@media (max-width: 1199.98px) {
	.dashboard-filter-form { grid-template-columns: repeat(3, minmax(0, 1fr)); }
	.dashboard-filter-date,
	.dashboard-filter-range { grid-column: auto; }
}

@media (max-width: 767.98px) {
	.tag-performance-filter-card .card-body,
	.tag-breakdown-card .card-body,
	.tag-performance-card .card-body {
		padding: 1rem;
	}
	.tag-performance-summary { grid-template-columns: 1fr; }
	.tag-ai-analysis-card { padding: 1rem; }
	.tag-ai-analysis-heading { align-items: flex-start; }
	.tag-ai-analysis-button { width: 100%; }
	.tag-ai-recommendations { grid-template-columns: 1fr; }
	.tag-click-distribution-modal .modal-header { padding: 1.5rem 1.5rem 1.35rem; }
	.tag-click-distribution-modal .modal-body { padding: 1.5rem; }
	.tag-click-distribution-modal .modal-footer { padding: 1.2rem 1.5rem; }
	.click-date-distribution-row { grid-template-columns: 3.75rem minmax(0, 1fr) 2.8rem; gap: .65rem; }
	.click-date-distribution-track { height: 3rem; }
	.click-date-distribution-fill { padding: 0 .75rem; }
	.dashboard-performance-card .card-body { padding: 1.15rem; }
	.dashboard-heading { align-items: flex-start; flex-direction: column; }
	.dashboard-filter-form { width: 100%; grid-template-columns: 1fr; }
	.dashboard-filter-date,
	.dashboard-filter-range { grid-column: auto; }
	.dashboard-range-inputs { width: 100%; }
	.dashboard-range-inputs .form-control { flex: 1 1 0; width: 0; }
}

.affiliate-filter-card {
	border: 0;
	border-radius: 1rem;
	box-shadow: 0 .5rem 1.5rem rgba(52, 73, 94, .06);
}

.affiliate-filter-card .card-body {
	padding: 1.5rem;
}

.affiliate-filter-grid {
	display: grid;
	grid-template-columns: repeat(12, minmax(0, 1fr));
	align-items: end;
	gap: 1rem;
}

.affiliate-filter-field { min-width: 0; }
.affiliate-filter-grid .affiliate-filter-field:nth-of-type(-n+3) { grid-column: span 4; }
.affiliate-filter-grid .affiliate-filter-field:nth-of-type(4),
.affiliate-filter-grid .affiliate-filter-field:nth-of-type(5) { grid-column: span 3; }
.affiliate-filter-grid .affiliate-filter-field:nth-of-type(6) { grid-column: span 4; }
.affiliate-filter-grid .affiliate-filter-field:nth-of-type(7) { grid-column: span 2; }
.affiliate-filter-grid .form-label { display: block; }
.affiliate-filter-grid .form-control,
.affiliate-filter-grid .form-select,
.affiliate-filter-grid .btn { min-height: 2.75rem; }

.affiliate-date-controls {
	display: flex;
	flex-wrap: wrap;
	align-items: end;
	gap: 1rem;
}

@media (max-width: 767.98px) {
	.affiliate-filter-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
	.affiliate-filter-grid .affiliate-filter-field:nth-of-type(n) { grid-column: auto; }
	.affiliate-date-controls { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); width: 100%; }
	.affiliate-date-controls > div { min-width: 0; }
	.affiliate-date-controls .affiliate-period-switch { grid-column: 1 / -1; }
}

@media (max-width: 479.98px) {
	.affiliate-filter-grid { grid-template-columns: minmax(0, 1fr); }
	.affiliate-filter-grid .affiliate-filter-field:last-child { grid-column: auto; }
}

.affiliate-period-switch .btn {
	min-width: 6.75rem;
	font-weight: 600;
}

.affiliate-summary-row {
	--bs-gutter-x: 1.25rem;
}

.affiliate-summary-card {
	--summary-color: #556ee6;
	--summary-rgb: 85, 110, 230;
	position: relative;
	height: 100%;
	min-height: 154px;
	overflow: hidden;
	border: 1px solid rgba(var(--summary-rgb), .15);
	border-radius: 1rem;
	background: linear-gradient(135deg, rgba(var(--summary-rgb), .13), rgba(var(--summary-rgb), .025) 72%);
	box-shadow: 0 .5rem 1.25rem rgba(52, 73, 94, .06);
	transition: transform .2s ease, box-shadow .2s ease;
}

.affiliate-summary-card::after {
	position: absolute;
	right: -2.8rem;
	bottom: -3.3rem;
	width: 8rem;
	height: 8rem;
	border-radius: 50%;
	background: rgba(var(--summary-rgb), .1);
	content: '';
}

.affiliate-summary-card:hover {
	box-shadow: 0 .8rem 1.7rem rgba(52, 73, 94, .11);
	transform: translateY(-3px);
}

.affiliate-summary-card .card-body {
	position: relative;
	z-index: 1;
	display: flex;
	flex-direction: column;
	justify-content: space-between;
	height: 100%;
	padding: 1.35rem;
}

.affiliate-summary-heading {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 1rem;
	color: #64748b;
	font-size: 1rem;
	font-weight: 600;
}

.affiliate-summary-icon {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	flex: 0 0 auto;
	width: 2.8rem;
	height: 2.8rem;
	border-radius: .85rem;
	background: rgba(var(--summary-rgb), .16);
	color: var(--summary-color);
	font-size: 1.55rem;
}

.affiliate-summary-value {
	margin-top: 1.25rem;
	color: #283b55;
	font-size: 1.75rem;
	font-weight: 700;
	letter-spacing: -.025em;
	line-height: 1.15;
	white-space: nowrap;
}

.affiliate-summary-card.summary-orders {
	--summary-color: #e77d22;
	--summary-rgb: 231, 125, 34;
}

.affiliate-summary-card.summary-products {
	--summary-color: #0c9b91;
	--summary-rgb: 12, 155, 145;
}

.affiliate-summary-card.summary-purchase {
	--summary-color: #178a51;
	--summary-rgb: 23, 138, 81;
}

.affiliate-summary-card.summary-commission {
	--summary-color: #8a53d3;
	--summary-rgb: 138, 83, 211;
}

@media (max-width: 1199.98px) {
	.affiliate-summary-value {
		font-size: 1.5rem;
	}
}

.table-actions {
	display: flex;
	justify-content: flex-end;
	gap: .5rem;
}

.auth-brand {
	font-size: 1.25rem;
	font-weight: 700;
	letter-spacing: .08em;
}

/* Advanced analytics */
.advanced-filter-card,
.advanced-insight-card,
.advanced-chart-card,
.advanced-performance-card {
	border: 1px solid #e8edf8;
	border-radius: 1.2rem;
	box-shadow: 0 3px 12px rgba(50, 72, 108, .045);
}

.advanced-filter-card .card-body,
.advanced-insight-card .card-body,
.advanced-chart-card .card-body,
.advanced-performance-card .card-body { padding: 1.45rem; }

.advanced-filter-heading,
.advanced-card-title,
.advanced-chart-header,
.advanced-chart-controls,
.advanced-period-control { display: flex; align-items: center; }

.advanced-filter-heading { gap: .85rem; margin-bottom: 1.2rem; }
.advanced-filter-heading h5,
.advanced-card-title h4 { margin: 0; color: #243754; font-size: 1.22rem; font-weight: 700; }
.advanced-filter-heading p,
.advanced-card-title p { margin: .2rem 0 0; color: #8d9cb7; }

.advanced-filter-icon,
.advanced-card-icon {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	flex: 0 0 auto;
	width: 2.75rem;
	height: 2.75rem;
	border-radius: .85rem;
	font-size: 1.55rem;
}

.advanced-filter-icon { background: #eef0ff; color: #625ee5; }
.advanced-card-title { gap: .7rem; margin-bottom: 1.25rem; }
.advanced-card-title p { font-size: .86rem; }
.advanced-card-icon.icon-purple { background: #f0efff; color: #706cf1; }
.advanced-card-icon.icon-blue { background: #edf5ff; color: #5f9bef; }
.advanced-card-icon.icon-violet { background: #f7efff; color: #9b6ae7; }
.advanced-card-icon.icon-red { background: #fff0f1; color: #ee6573; }
.advanced-card-icon.icon-orange { background: #fff5e9; color: #ed9939; }
.advanced-card-icon.icon-green { background: #edf9f3; color: #53ba87; }
.advanced-card-icon.icon-gold { background: #fff6dc; color: #e7a22d; }

.advanced-analytics-select {
	min-width: 0;
	border-color: #dbe3f0;
	border-radius: .75rem;
	box-shadow: 0 1px 3px rgba(33, 54, 88, .04);
}

.advanced-insight-card .advanced-analytics-select { margin-bottom: 1.25rem; }
.advanced-ranking-list,
.advanced-status-list { border-top: 1px solid #edf0f6; padding-top: 1.05rem; }
.advanced-ranking-item { margin-bottom: 1.15rem; }
.advanced-ranking-item:last-child,
.advanced-status-item:last-child { margin-bottom: 0; }

.advanced-ranking-item-header,
.advanced-status-item > div:first-child { display: flex; justify-content: space-between; gap: .75rem; color: #344560; font-size: .96rem; }
.advanced-ranking-item-header span { max-width: 66%; overflow: hidden; font-weight: 600; text-overflow: ellipsis; white-space: nowrap; }
.advanced-ranking-item-header strong { color: #37956d; font-weight: 700; white-space: nowrap; }
.advanced-ranking-item small { display: block; margin: .25rem 0 .42rem; color: #8998b2; font-size: .78rem; }

.advanced-ranking-bar,
.advanced-status-item .progress { overflow: hidden; height: .55rem; border-radius: 99px; background: #f0f3f8; }
.advanced-ranking-bar span { display: block; height: 100%; border-radius: inherit; background: linear-gradient(90deg, #7780ea, #8d95f3); }
.advanced-status-item { margin-bottom: 1.65rem; }
.advanced-status-item span,
.advanced-status-item strong { font-weight: 600; }
.advanced-status-item strong { color: #2f405d; }
.advanced-status-item strong small { color: #8290a9; font-weight: 600; }
.advanced-status-item .progress { margin-top: .5rem; }
.advanced-status-item .progress-bar { border-radius: inherit; background: #f4c244; }
.advanced-status-item:nth-child(2) .progress-bar { background: #6c9ce8; }
.advanced-status-item:nth-child(3) .progress-bar { background: #ee7280; }

.advanced-empty-state { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: .5rem; min-height: 10.6rem; color: #a0aec4; font-size: .95rem; text-align: center; }
.advanced-empty-state i { font-size: 1.85rem; color: #bac5d8; }

.advanced-chart-card .card-body,
.advanced-performance-card .card-body { padding: 1.55rem 1.7rem; }
.advanced-chart-header { justify-content: space-between; gap: 1rem; padding-bottom: 1.25rem; border-bottom: 1px solid #edf0f6; }
.advanced-chart-header .advanced-card-title { margin: 0; }
.advanced-chart-controls { justify-content: flex-end; flex-wrap: wrap; gap: .55rem; }
.advanced-chart-controls .advanced-analytics-select { width: 12rem; }
.advanced-legend { display: inline-flex; align-items: center; gap: .38rem; padding: .45rem .65rem; border-radius: .65rem; background: #f8fafc; color: #44546d; font-size: .8rem; font-weight: 600; white-space: nowrap; }
.advanced-legend i { width: .85rem; height: .85rem; border-radius: .2rem; }
.legend-blue { background: #6d9eea; }
.legend-orange { background: #f39b48; }
.legend-green { background: #66cda2; }

.advanced-trend-chart { min-height: 23rem; padding: 1.6rem .5rem .15rem; }
.advanced-trend-chart:has(.advanced-trend-bars) { overflow-x: auto; }
.advanced-trend-bars { display: flex; align-items: flex-end; gap: .8rem; min-width: max-content; min-height: 20rem; padding: 0 .65rem; border-bottom: 1px solid #e7ebf2; }
.advanced-trend-day { display: flex; flex: 0 0 3.55rem; flex-direction: column; align-items: center; gap: .55rem; height: 20rem; }
.advanced-trend-columns { display: flex; align-items: flex-end; justify-content: center; gap: .18rem; width: 100%; flex: 1; }
.advanced-trend-bar { display: block; min-height: 0; width: .9rem; border-radius: .35rem .35rem 0 0; transition: height .2s ease; }
.advanced-trend-bars.is-single .advanced-trend-bar { width: 2.25rem; }
.bar-clicks { background: #6c9de9; }
.bar-orders { background: #f29a47; }
.bar-commission { background: #67cda2; }
.advanced-trend-day small { color: #7d8da7; font-size: .75rem; font-weight: 600; white-space: nowrap; }

.advanced-period-control { gap: .55rem; color: #687995; font-weight: 600; white-space: nowrap; }
.advanced-period-control .form-select { width: 12.5rem; border-color: #7478f2; border-radius: .75rem; }
.advanced-performance-grid { margin-top: 1.55rem; }
.advanced-performance-item { height: 100%; padding: 1.35rem; border: 1px solid #e9edf5; border-radius: 1rem; background: #fff; box-shadow: 0 2px 8px rgba(51, 69, 98, .035); }
.advanced-performance-top { display: grid; grid-template-columns: auto minmax(0, 1fr) auto; align-items: center; gap: .65rem; }
.advanced-rank { display: inline-flex; align-items: center; justify-content: center; width: 2rem; height: 2rem; border-radius: 99px; background: #edf1f7; color: #667a98; font-size: .85rem; font-weight: 700; }
.advanced-rank.rank-1,
.advanced-rank.rank-2,
.advanced-rank.rank-3 { background: #fff3cf; color: #d99725; }
.advanced-rank.rank-2 { background: #f4f1df; color: #a58d47; }
.advanced-rank.rank-3 { background: #f9ead7; color: #c87e35; }
.advanced-performance-top h5 { margin: 0; overflow: hidden; color: #263955; font-size: 1.1rem; font-weight: 700; text-overflow: ellipsis; white-space: nowrap; }
.advanced-performance-commission { text-align: right; }
.advanced-performance-commission strong { display: block; color: #389a6d; font-size: 1.12rem; }
.advanced-performance-commission span { color: #94a2b9; font-size: .78rem; }
.advanced-performance-metrics { display: grid; grid-template-columns: 1fr 1fr; gap: .7rem; margin: 1rem 0; padding: .9rem 0; border-top: 1px solid #edf0f5; border-bottom: 1px solid #edf0f5; }
.advanced-performance-metrics div { padding: .65rem .75rem; border: 1px solid #edf0f6; border-radius: .65rem; background: #fbfcff; }
.advanced-performance-metrics span,
.advanced-performance-profit span { display: block; color: #95a2b7; font-size: .78rem; }
.advanced-performance-metrics strong { display: block; margin-top: .2rem; color: #594ee5; font-size: .92rem; }
.advanced-performance-profit { display: flex; align-items: center; justify-content: space-between; gap: .7rem; }
.advanced-performance-profit strong { color: #4dc08a; font-size: 1rem; }
.advanced-performance-item.is-negative .advanced-performance-profit strong { color: #e36d72; }

@media (max-width: 991.98px) {
	.advanced-chart-header { align-items: flex-start; flex-direction: column; }
	.advanced-chart-controls { justify-content: flex-start; }
}

@media (max-width: 575.98px) {
	.advanced-filter-card .card-body,
	.advanced-insight-card .card-body,
	.advanced-chart-card .card-body,
	.advanced-performance-card .card-body { padding: 1.1rem; }
	.advanced-chart-controls { width: 100%; }
	.advanced-chart-controls .advanced-analytics-select { width: 100%; }
	.advanced-period-control { width: 100%; justify-content: space-between; }
	.advanced-period-control .form-select { width: 10.5rem; }
	.advanced-performance-top { grid-template-columns: auto minmax(0, 1fr); }
	.advanced-performance-commission { grid-column: 2; text-align: left; }
}

/* Monthly report */
.monthly-filter-card,
.monthly-summary-card,
.monthly-breakdown-card {
	border: 1px solid #e8edf8;
	border-radius: 1.2rem;
	box-shadow: 0 3px 12px rgba(50, 72, 108, .045);
}

.monthly-filter-card .card-body { padding: 1.2rem 1.45rem; }
.monthly-summary-grid { margin-top: 1.35rem; }
.monthly-summary-card { overflow: hidden; }
.monthly-summary-card .card-body { min-height: 10.6rem; padding: 1.35rem; }

.monthly-summary-heading {
	display: flex;
	align-items: center;
	gap: .65rem;
	color: #5e6f8b;
	font-size: .93rem;
	font-weight: 700;
	letter-spacing: .02em;
	text-transform: uppercase;
}

.monthly-summary-icon {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 1.65rem;
	height: 1.65rem;
	border-radius: .5rem;
	font-size: 1.4rem;
}

.monthly-summary-value {
	display: block;
	margin-top: 1.25rem;
	color: #2d405d;
	font-size: 1.75rem;
	font-weight: 700;
	letter-spacing: -.025em;
	line-height: 1.1;
	white-space: nowrap;
}

.monthly-summary-card small { display: block; margin-top: .55rem; color: #99a7be; font-size: .9rem; }
.monthly-summary-card.summary-purple .monthly-summary-icon { color: #7a62ef; }
.monthly-summary-card.summary-green .monthly-summary-icon,
.monthly-summary-card.summary-green .monthly-summary-value { color: #43a774; }
.monthly-summary-card.summary-red .monthly-summary-icon,
.monthly-summary-card.summary-red .monthly-summary-value { color: #dd4358; }
.monthly-summary-card.summary-slate .monthly-summary-icon { color: #90a0ba; }
.monthly-summary-card.summary-orange .monthly-summary-icon { color: #ef9e2f; }
.monthly-summary-card.summary-violet .monthly-summary-icon,
.monthly-summary-card.summary-violet .monthly-summary-value { color: #6c3ee1; }

.monthly-breakdown-card { overflow: hidden; }
.monthly-breakdown-heading {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 1rem;
	padding: 1.5rem 1.7rem;
	border-bottom: 1px solid #edf0f6;
}

.monthly-breakdown-heading > div { display: flex; align-items: center; gap: .75rem; }
.monthly-breakdown-heading h4 { margin: 0; color: #263955; font-size: 1.28rem; font-weight: 700; }
.monthly-breakdown-heading > span { padding: .45rem .85rem; border: 1px solid #e0e6f0; border-radius: 99px; color: #94a2b9; font-size: .85rem; }
.monthly-breakdown-icon { display: inline-flex; align-items: center; justify-content: center; width: 2rem; height: 2rem; color: #7548e5; font-size: 1.75rem; }

.monthly-breakdown-table { min-width: 1100px; }
.monthly-breakdown-table thead th {
	padding: 1rem 1.2rem;
	border-bottom: 1px solid #e4eaf2;
	background: #fafbfd;
	color: #53647d;
	font-size: .86rem;
	font-weight: 700;
	text-transform: uppercase;
	white-space: nowrap;
}

.monthly-breakdown-table tbody td { padding: 1.8rem 1.2rem; border-color: #edf0f6; color: #344560; }
.monthly-breakdown-table tbody td:first-child { min-width: 17rem; }
.monthly-month-marker { display: inline-block; width: .75rem; height: .75rem; margin-right: .7rem; border-radius: 99px; background: #835cf0; vertical-align: middle; }
.monthly-order-count { color: #32435d; font-size: 1.25rem; }
.monthly-status-value { display: block; font-size: 1.1rem; }
.monthly-status-value.status-completed { color: #42a777; }
.monthly-status-value.status-failed { color: #df4359; }
.monthly-status-value.status-other { color: #4c5e78; }
.monthly-breakdown-table td small { display: block; margin-top: .25rem; color: #9aa8bd; font-size: .84rem; white-space: nowrap; }
.monthly-mini-progress { display: block; width: 6.3rem; height: .55rem; margin: .5rem auto 0; overflow: hidden; border-radius: 99px; background: #e8edf5; }
.monthly-mini-progress i { display: block; height: 100%; border-radius: inherit; background: #64c695; }
.monthly-breakdown-table td:nth-child(4) .monthly-mini-progress i { background: #ed7785; }
.monthly-breakdown-table td:nth-child(5) .monthly-mini-progress i { background: #9aa9bf; }
.monthly-real-commission { color: #6c3ee1; }
.monthly-difference-negative { display: block; color: #dc8129; }
.monthly-difference-positive { display: block; color: #40a978; }
.monthly-empty-state { display: flex; align-items: center; justify-content: center; gap: .6rem; min-height: 10rem; color: #9aa8bd; }
.monthly-empty-state i { font-size: 1.7rem; }
.monthly-note { display: flex; align-items: flex-start; gap: .65rem; padding: 1.15rem 1.7rem; border-top: 1px solid #edf0f6; color: #98a6bd; }
.monthly-note i { margin-top: .08rem; color: #8f9fb8; font-size: 1.1rem; }
.monthly-note strong { color: #71829f; }

@media (max-width: 767.98px) {
	.monthly-breakdown-heading { align-items: flex-start; flex-direction: column; padding: 1.2rem; }
	.monthly-breakdown-heading > span { padding: .35rem .65rem; }
	.monthly-note { padding: 1rem 1.2rem; }
}
