/**
 * AI Admin Frontend Styles
 */

/* Cotações */
.ai-cotacoes-wrapper {
    background: #fff;
    padding: 25px;
    margin: 20px 0;
}

.ai-cotacoes-wrapper h3 {
    color: #333;
    border-bottom: 2px solid #c0b24a;
    padding-bottom: 10px;
    margin-bottom: 20px;
    font-size: 1.5em;
}

.ai-cotacoes-list .cotacao-item {
    border: 1px solid #ddd;
    padding: 20px;
    margin-bottom: 20px;
    border-radius: 8px;
    background: #fafafa;
    transition: box-shadow 0.3s ease;
}

.ai-cotacoes-list .cotacao-item:hover {
    box-shadow: 0 4px 8px rgba(0,0,0,0.15);
}

.ai-cotacoes-list .cotacao-item h4 {
    margin: 0 0 10px 0;
    color: #333;
}

.ai-cotacoes-list .cotacao-item h4 a {
    text-decoration: none;
    color: #c0b24a;
}

.ai-cotacoes-list .cotacao-item h4 a:hover {
    text-decoration: underline;
}

.ai-cotacoes-list .cotacao-meta {
    color: #666;
    font-size: 0.9em;
    margin-bottom: 15px;
    padding: 8px 0;
    border-top: 1px solid #eee;
    border-bottom: 1px solid #eee;
}

.ai-cotacoes-list .cotacao-excerpt {
    margin-bottom: 15px;
    line-height: 1.6;
}

.ai-cotacoes-list .cotacao-actions {
    margin-top: 15px;
    text-align: right;
}

.ai-cotacoes-empty {
    text-align: center;
    padding: 40px 20px;
    background: #f9f9f9;
    border-radius: 8px;
    border: 1px dashed #ddd;
}

.ai-cotacoes-empty p {
    margin-bottom: 15px;
    color: #666;
}

.ai-cotacoes-empty p:first-child {
    font-size: 1.1em;
    color: #333;
}

.ai-cotacoes-empty em {
    color: #888;
    font-size: 0.95em;
}

.ai-cotacoes-empty a {
    color: #c0b24a;
    text-decoration: none;
    font-weight: bold;
}

.ai-cotacoes-empty a:hover {
    text-decoration: underline;
}

/* Cotacao Form Styles */
.cotacao-form-section {
    background: #fff;
    padding: 30px;
    margin-bottom: 30px;
}

.cotacao-form {
    max-width: none;
}

.cotacao-form .form-row {
    display: grid;
    grid-template-columns: 1fr;
    gap: 20px;
    margin-bottom: 20px;
}

.cotacao-form .form-row.two-col {
    grid-template-columns: 1fr 1fr;
}

.cotacao-form .form-group {
    display: flex;
    flex-direction: column;
}

.cotacao-form label {
    font-weight: 600;
    margin-bottom: 8px;
    color: #495057;
}

.cotacao-form .form-control {
    padding: 12px;
    border: 1px solid #ced4da;
    border-radius: 6px;
    font-size: 14px;
    transition: border-color 0.3s ease, box-shadow 0.3s ease;
}

.cotacao-form .form-control:focus {
    outline: none;
    border-color: #c0b24a;
    box-shadow: 0 0 0 0.2rem rgba(0, 124, 186, 0.25);
}

.cotacao-produtos-section {
    background: white;
    border: 1px solid #e9ecef;
    border-radius: 8px;
    padding: 25px;
    margin: 20px 0;
}

.cotacao-produtos-section h4 {
    color: #495057;
    margin: 0 0 20px 0;
    padding-bottom: 10px;
    border-bottom: 2px solid #e9ecef;
    font-size: 1.2em;
}

.produto-cotacao-item {
    background: #f8f9fa;
    border: 1px solid #e9ecef;
    border-radius: 8px;
    padding: 20px;
    margin-bottom: 20px;
    position: relative;
}

.produto-cotacao-item:last-of-type {
    margin-bottom: 0;
}

.produto-cotacao-item .form-row {
    margin-bottom: 15px;
}

.produto-cotacao-item .form-row:last-child {
    margin-bottom: 0;
}

.col-md-4 {
    grid-column: span 1;
}

.col-md-6 {
    grid-column: span 1;
}

.col-md-8 {
    grid-column: span 2;
}

@media (min-width: 768px) {
    .produto-cotacao-item .form-row {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .produto-cotacao-item .form-row:last-child {
        grid-template-columns: 1fr 2fr;
    }
}

#add-produto-cotacao-btn {
    background: #6c757d;
    color: white;
    border: none;
    padding: 10px 20px;
    border-radius: 6px;
    cursor: pointer;
    font-size: 14px;
    transition: background-color 0.3s ease;
}

#add-produto-cotacao-btn:hover {
    background: #5a6268;
}

.remove-produto-item {
    background: #dc3545;
    color: white;
    border: none;
    padding: 8px 16px;
    border-radius: 4px;
    cursor: pointer;
    font-size: 12px;
    position: absolute;
    top: 15px;
    right: 15px;
    transition: background-color 0.3s ease;
}

.remove-produto-item:hover {
    background: #c82333;
}

.form-actions {
    margin-top: 30px;
    padding-top: 20px;
    border-top: 1px solid #e9ecef;
    text-align: center;
}

.btn-lg {
    padding: 15px 30px;
    font-size: 16px;
    font-weight: 600;
    border-radius: 8px;
    transition: all 0.3s ease;
}

.cotacao-divider {
    border: none;
    margin: 30px 0;
}
.cotacao-login-notice {
    background: #fff;
    padding: 25px;
    text-align: center;
    margin-bottom: 30px;
}
.cotacao-login-notice {
    background: #fff;
    border: 1px solid #b8daff;
    border-radius: 8px;
    padding: 25px;
    text-align: center;
    margin-bottom: 30px;
}

.cotacao-login-notice p {
    margin-bottom: 15px;
    color: #394029;
    font-size: 1rem;
}

.cotacao-login-notice p:last-child {
    margin-bottom: 0;
}

.cotacoes-list-section h3 {
    color: #495057;
}

/* Cotacao status styling */
.cotacao-status {
    display: inline-block;
    padding: 4px 8px;
    border-radius: 12px;
    font-size: 12px;
    font-weight: 600;
    text-transform: uppercase;
    margin-left: 10px;
}

.cotacao-status.status-enviada {
    background: #cce5ff;
    color: #004085;
}

.cotacao-status.status-aprovada {
    background: #d4edda;
    color: #155724;
}

.cotacao-status.status-respondida {
    background: #d1ecf1;
    color: #394029;
}

.cotacao-status.status-rejeitada {
    background: #f8d7da;
    color: #721c24;
}

/* Form validation styles */
.cotacao-form .form-control:invalid {
    border-color: #dc3545;
}

.cotacao-form .form-control:valid {
    border-color: #28a745;
}

/* Loading state */
.cotacao-form.loading {
    opacity: 0.7;
    pointer-events: none;
}

/* Success message */
.cotacao-success {
    background: #d4edda;
    border: 1px solid #c3e6cb;
    color: #155724;
    padding: 20px;
    border-radius: 8px;
    margin: 20px 0;
    text-align: center;
}

/* Fornecedores */
.ai-fornecedores-list .fornecedor-item {
    display: flex;
    border: 1px solid #ddd;
    padding: 20px;
    margin-bottom: 20px;
    border-radius: 5px;
}

.ai-fornecedores-list .fornecedor-image {
    flex: 0 0 150px;
    margin-right: 20px;
}

.ai-fornecedores-list .fornecedor-content {
    flex: 1;
}

/* Guia de Fornecedores — legacy styles removed; template now uses Tailwind CSS */


/* Newsletter Styles */
.ai-newsletter-form {
    background: #f9f9f9;
    padding: 20px;
    border-radius: 5px;
    max-width: 500px;
}

.ai-newsletter-form .form-group {
    margin-bottom: 15px;
}

.ai-newsletter-form label {
    display: block;
    margin-bottom: 5px;
    font-weight: bold;
}

.ai-newsletter-form input[type="text"],
.ai-newsletter-form input[type="email"] {
    width: 100%;
    padding: 8px;
    border: 1px solid #ddd;
    border-radius: 3px;
}

.ai-newsletter-form .newsletter-success {
    background: #d4edda;
    color: #155724;
    padding: 10px;
    border: 1px solid #c3e6cb;
    border-radius: 3px;
}

/* Voting and Polls */
.ai-votacoes-list .votacao-item,
.ai-enquetes-list .enquete-item {
    border: 1px solid #ddd;
    padding: 20px;
    margin-bottom: 20px;
    border-radius: 5px;
}

.ai-enquetes-list .enquete-option {
    margin-bottom: 15px;
}

.ai-enquetes-list .option-bar {
    background: #eee;
    height: 20px;
    border-radius: 10px;
    margin: 5px 0;
    overflow: hidden;
}

.ai-enquetes-list .option-fill {
    background: #c0b24a;
    height: 100%;
    border-radius: 10px;
}

.ai-enquetes-list .option-percentage {
    font-size: 0.9em;
    color: #666;
}

/* Client Profile */
.ai-client-profile .tab-nav {
    border-bottom: 1px solid #ddd;
    margin-bottom: 20px;
}

.ai-client-profile .tab-link {
    display: inline-block;
    padding: 10px 15px;
    text-decoration: none;
    border-bottom: 2px solid transparent;
    margin-right: 10px;
}

.ai-client-profile .tab-link.active {
    border-bottom-color: #c0b24a;
    color: #c0b24a;
}

.ai-client-profile .tab-pane {
    display: none;
}

.ai-client-profile .tab-pane.active {
    display: block;
}

.ai-client-profile .client-data,
.ai-client-profile .client-users,
.ai-client-profile .client-products,
.ai-client-profile .client-cotacoes,
.ai-client-profile .client-vagas {
    background: #f9f9f9;
    padding: 15px;
    border-radius: 5px;
}

.ai-client-profile .user-item,
.ai-client-profile .product-item,
.ai-client-profile .cotacao-item,
.ai-client-profile .vaga-item {
    background: white;
    padding: 15px;
    margin-bottom: 15px;
    border-radius: 3px;
    border: 1px solid #ddd;
}

/* Buttons */
.btn {
    display: inline-block;
    padding: 8px 16px;
    text-decoration: none;
    border: none;
    border-radius: 3px;
    cursor: pointer;
}
.btn-primary {
    background: #c0b24a;
    color: #ffffff;
    font-size: 1rem;
}
.btn-primary:hover {
    background: #884c04;
    color: #fff;
}

/* AI Admin Company Profile */
.ai-admin-profile-wrapper {
	max-width: 1200px;
	margin: 0 auto;
	padding: 20px;
}

.ai-admin-profile-header {
	background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
	color: white;
	padding: 30px;
	border-radius: 12px;
	margin-bottom: 30px;
	box-shadow: 0 4px 20px rgba(0,0,0,0.1);
}

.profile-header-content {
	display: flex;
	align-items: center;
	gap: 20px;
}

.profile-avatar img {
	border-radius: 50%;
	border: 4px solid rgba(255,255,255,0.3);
}

.profile-info h2 {
	margin: 0 0 10px 0;
	font-size: 28px;
	font-weight: 300;
}

.profile-role {
	opacity: 0.9;
	font-size: 16px;
	margin: 0 0 5px 0;
}

.profile-last-login {
	opacity: 0.8;
	font-size: 14px;
	margin: 0;
}

/* Cotacao Online - New form */
.ai-cotacao-ingredientes {
	max-width: 1200px;
	margin: 0 auto;
	padding: 20px;
}

.ai-cotacao-header {
	margin-bottom: 24px;
}

.ai-cotacao-kicker {
	font-size: 12px;
	letter-spacing: 0.08em;
	color: #666;
	margin-bottom: 6px;
}

.ai-cotacao-title {
	font-size: 28px;
	margin: 0 0 12px;
}

.ai-cotacao-intro p {
	margin: 0 0 8px;
	color: #555;
}

.ai-cotacao-bar {
	display: grid;
	grid-template-columns: 1.5fr 0.7fr 1fr auto;
	gap: 12px;
	align-items: end;
	margin-bottom: 20px;
}

.ai-cotacao-bar-field {
	display: flex;
	flex-direction: column;
	gap: 6px;
}

.ai-label {
	font-size: 12px;
	font-weight: 600;
	color: #444;
}

.ai-select,
.ai-textarea,
.ai-qty {
	border: 1px solid #ddd;
	border-radius: 4px;
	padding: 8px 10px;
	font-size: 14px;
}

.ai-ingredientes-control {
	display: flex;
	flex-direction: column;
	gap: 8px;
}

.ai-ingredientes-chips {
	display: flex;
	flex-wrap: wrap;
	gap: 6px;
}

.ai-chip {
	display: inline-flex;
	align-items: center;
	gap: 6px;
	background: #f1f1f1;
	border-radius: 16px;
	padding: 4px 10px;
	font-size: 13px;
}

.ai-chip-remove {
	border: none;
	background: transparent;
	cursor: pointer;
	font-size: 14px;
}

.ai-icon-btn {
	border: 1px solid #ddd;
	background: #fff;
	padding: 8px 12px;
	border-radius: 6px;
	cursor: pointer;
}

.ai-cotacao-table {
	width: 100%;
	border-collapse: collapse;
}

.ai-cotacao-table th,
.ai-cotacao-table td {
	border-bottom: 1px solid #eee;
	padding: 10px;
	text-align: left;
	vertical-align: top;
}

.ai-empty-row td {
	color: #777;
	text-align: center;
	padding: 20px;
}

.ai-suppliers-list {
	display: flex;
	flex-direction: column;
	gap: 6px;
	list-style: none;
	margin: 0;
	padding-left: 0;
}

.ai-supplier-box {
	position: relative;
	min-height: 38px;
	padding: 8px 10px;
	border: 1px solid #e5e1d5;
	border-radius: 6px;
	background: #fff;
	box-sizing: border-box;
}

.ai-supplier-box--premium {
	border: 2px solid #c0a43b;
	border-radius: 10px;
	padding-right: 58px;
}

.ai-supplier-box__name {
	display: block;
	font-weight: 600;
	color: #394029;
	line-height: 1.25;
}

.ai-supplier-box__seal {
	position: absolute;
	top: 0;
	right: 0;
	width: 44px;
	height: 48px;
	object-fit: contain;
	display: block;
}

.ai-cotacao-message {
	margin-top: 20px;
}

.ai-textarea {
	width: 100%;
}

.ai-cotacao-footer {
	margin-top: 20px;
	display: flex;
	justify-content: flex-end;
}

.ai-btn-submit {
	background: #c0b24a;
	color: #fff;
	border: none;
	padding: 10px 20px;
	border-radius: 4px;
	cursor: pointer;
	font-weight: 600;
}

.ai-btn-submit:hover {
	background: #884c04;
}

@media (max-width: 900px) {
	.ai-cotacao-bar {
		grid-template-columns: 1fr 1fr;
	}
}

@media (max-width: 600px) {
	.ai-cotacao-bar {
		grid-template-columns: 1fr;
	}
}

.ai-admin-profile-content {
	display: grid;
	grid-template-columns: 250px 1fr;
	gap: 30px;
	align-items: start;
}

/* Profile Sidebar */
.ai-admin-profile-sidebar {
	background: #fff;
	border-radius: 8px;
	box-shadow: 0 2px 10px rgba(0,0,0,0.1);
	overflow: hidden;
}

.profile-nav ul {
	list-style: none;
	margin: 0;
	padding: 0;
}

.profile-nav .nav-header {
	background: #f8f9fa;
	padding: 15px 20px;
	font-weight: bold;
	color: #495057;
	border-bottom: 1px solid #e9ecef;
}

.profile-nav li {
	border-bottom: 1px solid #e9ecef;
}

.profile-nav li:last-child {
	border-bottom: none;
}

.profile-nav .nav-link {
	display: flex;
	align-items: center;
	gap: 10px;
	padding: 15px 20px;
	text-decoration: none;
	color: #495057;
	transition: all 0.3s ease;
}

.profile-nav .nav-link:hover {
	background: #f8f9fa;
	color: #c0b24a;
}

.profile-nav li.active .nav-link {
	background: #c0b24a;
	color: white;
}

.profile-nav .nav-icon {
	font-size: 16px;
}

/* Profile Main Content */
.ai-admin-profile-main {
	background: #fff;
	border-radius: 8px;
	box-shadow: 0 2px 10px rgba(0,0,0,0.1);
	overflow: hidden;
}

.ai-admin-profile-tabs {
	display: flex;
	background: #f8f9fa;
	border-bottom: 1px solid #e9ecef;
}

.profile-tab {
	padding: 15px 25px;
	text-decoration: none;
	color: #495057;
	border-bottom: 2px solid transparent;
	transition: all 0.3s ease;
	font-weight: 500;
}

.profile-tab:hover {
	background: #e9ecef;
	color: #c0b24a;
}

.profile-tab.active {
	background: #fff;
	color: #c0b24a;
	border-bottom-color: #c0b24a;
}

.ai-admin-profile-tab-content {
	padding: 30px;
}

.ai-admin-role-request .section-header {
	margin-bottom: 24px;
}

.ai-admin-role-request .section-header h3,
.ai-admin-company-request .section-header h3 {
	margin: 0 0 8px;
}

.ai-admin-company-request .section-header {
	margin-bottom: 24px;
}

.ai-role-choice-list {
	display: grid;
	grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
	gap: 10px;
	margin: 12px 0;
}

.ai-role-choice {
	display: flex;
	align-items: center;
	gap: 8px;
	border: 1px solid #dcdcde;
	border-radius: 6px;
	padding: 10px 12px;
	background: #fff;
}

.ai-role-request-summary {
	border: 1px solid #dcdcde;
	background: #f6f7f7;
	padding: 14px;
}

.ai-request-mode-choice {
	align-items: center;
	display: flex;
	gap: 8px;
	margin: 0 0 14px;
}

.ai-company-request-form datalist {
	display: none;
}

/* Status badges */
.status-badge {
	padding: 4px 12px;
	border-radius: 15px;
	font-size: 12px;
	font-weight: bold;
	text-transform: uppercase;
}

.status-active {
	background: #d4edda;
	color: #155724;
}

.status-pending {
	background: #fff3cd;
	color: #856404;
}

.status-publish {
/*
	background: #d4edda;
	color: #155724;
*/
}

.status-draft {
	background: #f8d7da;
	color: #721c24;
}

.status-private {
	background: #d1ecf1;
	color: #394029;
}

/* Form styles */
.ai-admin-form .form-section {
	margin-bottom: 30px;
}

.ai-admin-form .form-section h4 {
	margin: 0 0 20px 0;
	color: #495057;
	border-bottom: 2px solid #e9ecef;
	padding-bottom: 10px;
}

.ai-admin-form .form-row {
	display: grid;
	grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
	gap: 20px;
	margin-bottom: 20px;
}

.ai-admin-form .form-group {
	display: flex;
	flex-direction: column;
}

.ai-admin-form .form-group.full-width {
	grid-column: 1 / -1;
}

.ai-admin-form label {
	font-weight: 600;
	margin-bottom: 5px;
	color: #495057;
}

.ai-admin-form input,
.ai-admin-form textarea,
.ai-admin-form select {
	padding: 10px;
	border: 1px solid #ced4da;
	border-radius: 4px;
	transition: border-color 0.3s ease;
}

.ai-admin-form input:focus,
.ai-admin-form textarea:focus,
.ai-admin-form select:focus {
	outline: none;
	border-color: #c0b24a;
	box-shadow: 0 0 0 0.2rem rgba(0, 123, 255, 0.25);
}

.ai-admin-form .form-actions {
	padding-top: 20px;
	border-top: 1px solid #e9ecef;
	display: flex;
	gap: 10px;
}

/* Table styles */
.ai-admin-table {
	width: 100%;
	border-collapse: collapse;
	background: white;
	border-radius: 8px;
	overflow: hidden;
	box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

.ai-admin-table th,
.ai-admin-table td {
	padding: 15px;
	text-align: left;
	border-bottom: 1px solid #e9ecef;
}

.ai-admin-table th {
	background: #f8f9fa;
	font-weight: 600;
	color: #495057;
}

.ai-admin-table tbody tr:hover {
	background: #f8f9fa;
}

.ai-admin-table .section-separator th {
	background: #e9ecef;
	font-weight: bold;
	color: #495057;
}

.ai-admin-table .current-user {
	background: rgba(0, 123, 255, 0.05);
}

.current-user-badge {
	background: #c0b24a;
	color: white;
	padding: 2px 8px;
	border-radius: 10px;
	font-size: 11px;
	font-weight: bold;
	margin-left: 10px;
}

.avatar-cell {
	width: 50px;
}

.actions-cell {
	width: 150px;
}

.actions-cell .button {
	margin-right: 5px;
}

/* Notice styles */
.ai-admin-notice {
	padding: 15px;
	border-radius: 6px;
	margin: 20px 0;
}

.ai-admin-notice.notice-info {
	background: #fff;
	border-left: 4px solid #00a0d2;
	color: #0073aa;
}

.ai-admin-notice.notice-success {
	background: #f0f8f0;
	border-left: 4px solid #46b450;
	color: #155724;
}

.ai-admin-notice.notice-warning {
	background: #fff8e1;
	border-left: 4px solid #ffb900;
	color: #856404;
}

.ai-admin-notice.notice-error {
	background: #ffeaea;
	border-left: 4px solid #d63638;
	color: #721c24;
}

/* Responsive Design */
@media (max-width: 768px) {
	.ai-admin-profile-content {
		grid-template-columns: 1fr;
		gap: 20px;
	}
	
	.profile-header-content {
		flex-direction: column;
		text-align: center;
	}
	
	.ai-admin-profile-tabs {
		flex-wrap: wrap;
	}
	
	.profile-tab {
		flex: 1;
		min-width: 120px;
		text-align: center;
	}
	
	.ai-admin-form .form-row {
		grid-template-columns: 1fr;
	}
}
