#crawler_dialog {
    position: fixed;
    margin-left: 50%;
    top: 100px;
    left: -30%;
    width: 60%;
    padding: 0;
    font-size: 13px;
    z-index: 9998;
    border: 1px solid #c3c4c7;
    max-width: unset;
    min-width: unset;
    border-radius: 5px;
}

#crawler_dialog div.card-block {
	height: 400px;
    overflow: hidden;
	padding: 10px;
}

#crawler_dialog label.analysis-labels {
	margin-bottom: .25rem; 
    min-width: 0;
    display: table;
    font-size: 14px;
}

#crawler_dialog label.analysis-labels.label-results {
	margin-top: 10px;
	display: block;
	cursor: auto;
}

#crawler_dialog label.analysis-labels.label-results.bg-danger {
	display: inline-block;
}

#crawler_dialog input.analysis-input {
	width: 54%;
	height: 40px;
	padding: 5px 5px 5px 40px;
	margin: 0 10px 15px 0 !important;
	font-size: 16px;
    color: #666;
    background: url(../images/key.png) 3px 6px no-repeat;
    box-sizing: border-box;
}

#crawler_dialog input.analysis-input:focus {
	border-color: rgb(82, 168, 236);
}

#crawler_dialog input.analysis-input.error,
#crawler_dialog input.analysis-input.error:focus {
	border: 2px solid #d9534f !important;
    box-shadow: none;
}

#start_analysis, #stop_analysis, #start_wizard {
    padding: 8px 10px;
	margin-top: -6px;
    line-height: normal;
}

#start_analysis, #stop_analysis {
	display: inline-flex;
	align-items: center;
}

#crawler_dialog #start_analysis span.crawler-cogicon,
#crawler_dialog #stop_analysis span.crawler-cogicon {
	margin-right: 4px;
    display: inline-block;
    width: 16px;
    height: 16px;
    background: url(../images/cog.png) 0 0 no-repeat;
	box-shadow: none;
	border-radius: 3px;
}

#crawler_dialog #start_analysis,
#crawler_dialog #stop_analysis {
	margin-right: 10px;
}

#crawler_dialog #start_wizard span.crawler-settingsicon {
	margin-right: 4px;
    display: inline-block;
    width: 16px;
    height: 16px;
    background: url(../images/cog.png) 0 0 no-repeat;
	box-shadow: none;
	border-radius: 3px;
}

#crawler_dialog #start_analysis span.crawler-cogicon.running,
#crawler_dialog #stop_analysis span.crawler-cogicon.running,
#crawler_dialog #start_wizard span.crawler-settingsicon.running,
#crawler_dialog span.crawler-url-spinner {
    animation: spin 2s infinite linear;
}

#crawler_dialog span.crawler-url-spinner {
	font-family: sans-serif;
    display: inline-block;
    font-size: 14px;
    line-height: 14px;
    transform-origin: 45% 52%;
}

#crawler_dialog #linkopener {
	cursor: pointer;
	border-radius: 2px;
}

#crawler_status.running {
	animation: textani .9s infinite linear;
}

#crawler_dialog ul.analysis-results-cookies,
#crawler_dialog ul.analysis-results-cookies li,
#crawler_dialog ul.analysis-results-domains,
#crawler_dialog ul.analysis-results-domains li {
	list-style-type: none;
	margin: 0;
    padding: 0;
}

#crawler_dialog ul.analysis-results-cookies li,
#crawler_dialog ul.analysis-results-domains li {
    padding: 5px;
	display: flex;
}

#crawler_dialog ul.analysis-results-cookies li > span,
#crawler_dialog ul.analysis-results-domains li > span {
	flex: 1 1 0;
}

#crawler_dialog ul.analysis-results-cookies li:first-child,
#crawler_dialog ul.analysis-results-domains li:first-child {
    background-color: #e4e4e4;
}

#crawler_dialog ul.analysis-results-cookies li:first-child span,
#crawler_dialog ul.analysis-results-domains li:first-child span {
	font-weight: bold;
}

#crawler_dialog ul.analysis-results-domains li > span a {
	display: inline-block;	
}

#crawler_dialog div.text-success {
	color: #457d54;
	font-size: 14px;
}

#crawler_dialog small.text-muted {
    color: #1c1c1c !important;
    opacity: .9;
    font-size: 12px;
}

#crawler_dialog .sitemap-language-filter {
	display: flex;
	align-items: center;
	gap: 8px;
	flex-shrink: 0;
}

#crawler_dialog .sitemap-language-filter label {
	font-size: 12px;
	font-weight: 600;
	color: #495057;
	white-space: nowrap;
	margin-bottom: 0;
}

#crawler_dialog .sitemap-language-filter select {
	font-size: 12px;
	border: 1px solid #8c8f94;
	border-radius: 4px;
	color: #495057;
	height: 30px;
	box-sizing: border-box;
	cursor: pointer;
}

#crawler_dialog .sitemap-language-filter select:focus {
	border-color: #2271b1;
	box-shadow: 0 0 0 1px #2271b1;
	outline: none;
}

#crawler_dialog .sitemap-actions-wrapper {
	display: flex;
	align-items: center;
	gap: 12px;
}

#crawler_dialog form.export-xml-sitemap {
	flex-shrink: 0;
}

#crawler_dialog .sitemap-url-section {
	display: flex;
	align-items: center;
	gap: 8px;
	flex: 1 1 0;
}

#crawler_dialog .sitemap-url-label {
	font-size: 12px;
	font-weight: 600;
	color: #495057;
	white-space: nowrap;
}

#crawler_dialog .sitemap-url-input-group {
	display: flex;
	align-items: center;
	gap: 0;
	flex: 1 1 auto;
}

#crawler_dialog .sitemap-url-input {
	width: 100%;
	padding: 4px 8px;
	font-size: 12px;
	border: 1px solid #8c8f94;
	border-radius: 4px 0 0 4px;
	background: #fff;
	color: #2271b1;
	cursor: text;
	height: 30px;
	box-sizing: border-box;
}

#crawler_dialog .sitemap-url-input:focus {
	border-color: #2271b1;
	box-shadow: 0 0 0 1px #2271b1;
	outline: none;
}

#crawler_dialog .sitemap-copy-btn,
#crawler_dialog .sitemap-open-btn {
	height: 30px;
	min-width: 30px;
	padding: 0 6px;
	border-radius: 0;
	display: flex;
	align-items: center;
	justify-content: center;
	border-left: none;
	border-color: #8c8f94;
}

#crawler_dialog .sitemap-open-btn {
	border-radius: 0 4px 4px 0;
}

#crawler_dialog .sitemap-copy-btn .dashicons,
#crawler_dialog .sitemap-open-btn .dashicons {
	font-size: 16px;
	width: 16px;
	height: 16px;
	line-height: 16px;
}

#crawler_dialog .sitemap-copy-btn.sitemap-copied {
	background: #00a32a;
	border-color: #00a32a;
	color: #fff;
}

div.text-muted.text-center {
	display:block;
	font-size:13px;
	font-weight:400;
	line-height:19.5px;
	opacity: 0.7;
	padding: 16px;
	text-align:center;
}

a.hasAuditTooltip:hover {
	text-decoration: none;
}

@media ( max-width:800px ) {
	#crawler_dialog input.analysis-input {
		width: 100%;	
	}
}

label.closedialog {
	position: absolute;
	right: 5px;
	top: 5px;
	font-size: 22px;
	cursor: pointer;
}

span.label-with-badge {
	line-height: unset;
    font-size: 14px;
    padding: 4px 10px;
}

span.label-with-badge span.badge {
	background-color: #FFF;
	color: #c47300;
}

span.label-with-badge.bg-success span.badge {
	background-color: #FFF;
	color: #2f7d32;
}

#crawler_status {
    margin: 2px 0 2px 5px;
    font-size: 14px;
    padding: 3px 6px;
    line-height: 14px;
    margin-inline-end: 0;
}

#crawler_dialog div.card-header {
    padding: 15px;
}

#crawler_dialog div.card-header h3 {
	margin: 0;
    color: #FFF;
}

#crawler_dialog div.card-header label.fas {
	color: #FFF;
}

div.trigger_dialog:not(.noduplicates), div.trigger_content_analysis {
	cursor: pointer;
}

div.trigger_content_analysis {
    border: 2px solid #6d6d6d;
    border-radius: 15px;
    width: 24px;
    height: 48px;
    box-sizing: content-box;
    padding: 4px 0 4px 0;
}

div.trigger_content_analysis_red {
	background-color: #d9534f;
	width: 16px;
	height: 16px;
	border-radius: 50%;
	margin: auto;
}

div.trigger_content_analysis_yellow {
	background-color: #f89406;
	width: 16px;
	height: 16px;
	border-radius: 50%;
	margin: auto;
}

div.trigger_content_analysis_green {
	background-color: #3c763d;
	width: 16px;
	height: 16px;
	border-radius: 50%;
	margin: auto;
}

div.trigger_content_analysis + div.tooltip {
	left: auto;
	right: 56px;
	left: -150px !important;
}

a[data-role=link] {
	display: block;
	padding-right: 15px;
}

/**
 * Flexbox results
 */
div.flexbox-container-analysis {
	display: flex;
}

#crawler_container {
	width: 100%;
}

#crawler_iframe {
	width: 100%;
    height: 100%;
}

#crawler_container div.text-primary {
	color: #d43900 !important;
	font-size: 14px;
}

#cookie_results_container, #domains_results_container {
    flex: 1 1 auto;
    background-color: #f8f8f8;
    border-radius: 4px;
}

#cookie_results_container {
	margin-right: 10px;
}

#cookie_results_container span.badge {
    font-size: 16px;
    font-weight: normal;
    padding: 15px 20px;
}

#cookie_results_container a.hasAuditTooltip,
#cookie_results_container span.hasCookieValue > span {
    display: inline-block;
    max-width: 300px;
    word-break: break-all;
}

#domains_results_container a.hasAuditTooltip {
    display: block;
    max-width: 400px;
    word-break: break-all;
}

#crawler_dialog.card div.card-header {
	color: #ffffff;
	background-color: #2271b1;
	border-color: #2271b1;
	border-top-right-radius: 5px;
	border-top-left-radius: 5px;
}

#crawler_dialog.card div.card-block {
	background-color: #FFF;
}

#crawler_dialog.card div.card-footer {
	padding: 10px 15px;
    background-color: #f5f5f5;
    border-top: 1px solid #dddddd;
    border-bottom-right-radius: 5px;
    border-bottom-left-radius: 5px;
    overflow: hidden;
}

#content *.bg-success, #crawler_dialog *.bg-success {
    color: #fff;
    background-color: #2f7d32 !important;
}

#content *.bg-warning, #crawler_dialog *.bg-warning {
    color: #fff;
    background-color: #d43900 !important;
}

#content *.bg-info, #crawler_dialog *.bg-info {
    color: #fff;
    background-color: #108193 !important;
}

#content *.bg-danger, #crawler_dialog *.bg-danger {
    color: #fff;
    background-color: #c52827 !important;
}

#crawler_dialog div.card-footer > span.badge {
	margin-bottom: 10px;
}

@media (max-width: 1024px) {
	#crawler_dialog {
		width: 90%;
		left: -45%;
	}
}

@media ( max-width:1280px ) {
	div.flexbox-container-analysis {
		display: block;	
	}
	#domains_results_container a.hasAuditTooltip {
	    max-width: 100%;
	}
}

@keyframes spin {
	0%  {transform: rotate(0deg);}
	100% {transform: rotate(360deg);}	
}

@keyframes textani {
	0%  {opacity: 1}
	50% {opacity: .8}
	100% {opacity: 1}
}

#crawl_single_url_label {
	display: inline-flex;
    align-items: center;
    margin-right: 5px;
    cursor: pointer;
    user-select: none;
    font-size: 14px;
    color: #495057;
    padding: 7.5px 12px;
    background: #ffffff;
    border-radius: 2px;
    border: 1px solid #376443;
    transition: all 0.2s ease;
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.05);
    position: relative;
    margin-top: -8.5px;
}

/* Hover effect */
#crawl_single_url_label:hover {
    background: #f8f9fa;
    border-color: #198754;
    box-shadow: 0 2px 4px rgba(25, 135, 84, 0.1);
}

/* Quando è checked - bordo verde */
#crawl_single_url:checked ~ #crawl_single_url_label,
#crawl_single_url_label:has(#crawl_single_url:checked),
#crawl_batch_urls:checked ~ #crawl_batch_label,
#crawl_batch_label:has(#crawl_batch_urls:checked) {
    background: #d1e7dd;
    border-color: #198754;
}

/* Checkbox custom */
#crawl_single_url {
    width: 18px;
    height: 18px;
    margin: 0 8px 0 0;
    cursor: pointer;
    border-color: #198754;
    flex-shrink: 0;
	background: #fff;
}

/* Testo label */
#crawl_single_url_label span {
    font-weight: 500;
    color: #495057;
    white-space: nowrap;
}

/* Testo quando checked */
#crawl_single_url:checked + span {
    color: #0f5132;
    font-weight: 600;
}

/* Focus accessibilità */
#crawl_single_url:focus {
    outline: 3px solid rgba(25, 135, 84, 0.3);
    outline-offset: 2px;
}

/* Active state */
#crawl_single_url_label:active {
    transform: translateY(0);
    box-shadow: 0 1px 2px rgba(0,0,0,0.1);
}

#crawl_single_url::before,
#crawl_batch_urls::before {
    filter: sepia(100%) saturate(500%) hue-rotate(130deg) brightness(0.9);
}

#crawl_single_url:focus,
#crawl_batch_urls:focus {
    outline: none !important;
    box-shadow: none !important;
}

/* Targetta ogni body che ha una classe 'branch-' seguita da un numero >= 7 */
body[class*="branch-7"] #crawler_dialog.card div.card-header,
body[class*="branch-8"] #crawler_dialog.card div.card-header,
body[class*="branch-9"] #crawler_dialog.card div.card-header {
	background-color: #3858e9;
	border-color: #3858e9;
}

/* Batch URLs label - same style as single URL */
#crawl_batch_label {
	display: inline-flex;
    align-items: center;
    cursor: pointer;
    user-select: none;
    font-size: 14px;
    color: #495057;
    padding: 7.5px 12px;
    background: #ffffff;
    border-radius: 2px;
    border: 1px solid #376443;
    transition: all 0.2s ease;
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.05);
    position: relative;
    margin-top: -8.5px;
}

#crawl_batch_label:hover {
    background: #f8f9fa;
    border-color: #198754;
    box-shadow: 0 2px 4px rgba(25, 135, 84, 0.1);
}

#crawl_batch_label:has(#crawl_batch_urls:checked) {
    background: #d1e7dd;
    border-color: #198754;
}

#crawl_batch_urls {
    width: 18px;
    height: 18px;
    margin: 0 8px 0 0;
    cursor: pointer;
    border-color: #198754;
    flex-shrink: 0;
	background: #fff;
}

#crawl_batch_urls:focus {
    outline: none !important;
    box-shadow: none !important;
}

#crawl_batch_label span {
    font-weight: 500;
    color: #495057;
    white-space: nowrap;
}

#crawl_batch_urls:checked + span {
    color: #0f5132;
    font-weight: 600;
}

/* Batch links textarea */
#batch_links_section {
	margin-top: 8px;
}

#batch_links_input {
	width: 100%;
	font-size: 12px;
	padding: 8px;
	border: 1px solid #8c8f94;
	border-radius: 4px;
	box-sizing: border-box;
	resize: vertical;
	font-family: monospace;
	line-height: 1.5;
}

#batch_links_input:focus {
	border-color: #2271b1;
	box-shadow: 0 0 0 1px #2271b1;
	outline: none;
}

/* Skipped URL style */
#crawler_container div.text-muted-skip {
	color: #6c757d !important;
	font-size: 14px;
	opacity: 0.8;
}

body[class*="branch-7"] #crawl_single_url:checked::before,
body[class*="branch-8"] #crawl_single_url:checked::before,
body[class*="branch-9"] #crawl_single_url:checked::before,
body[class*="branch-7"] #crawl_batch_urls:checked::before,
body[class*="branch-8"] #crawl_batch_urls:checked::before,
body[class*="branch-9"] #crawl_batch_urls:checked::before {
    content: url(data:image/svg+xml;utf8,%3Csvg%20xmlns%3D%27http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%27%20viewBox%3D%270%200%2020%2020%27%3E%3Cpath%20d%3D%27M14.83%204.89l1.34.94-5.81%208.38H9.02L5.78%209.67l1.34-1.25%202.57%202.4z%27%20fill%3D%27%233582c4%27%2F%3E%3C%2Fsvg%3E) / '';
}