﻿body {
	font-family: 'Roboto', sans-serif;
	margin: 0;
	padding: 0;
	background-color: #f5f5f5;
}

.header {
	display: flex;
	justify-content: space-between;
	align-items: center;
	background: #1A237E;
	color: white;
	width: 100%;
	position: fixed;
	top: 0;
	left: 0;
	z-index: 1000;
}

.logo-container {
	display: flex;
	align-items: center;
	gap: 15px;
	padding-left: 30px;
}

.logo-container img {
	height: 50px;
}

.header-right {
	display: flex;
	align-items: center;
	gap: 20px;
	padding-right: 30px;
}

.language-selector {
	display: flex;
	align-items: center;
	gap: 10px;
}

.language-selector img {
	width: 40px;
	height: 30px;
	cursor: pointer;
	border-radius: 3px;
	border: 1px solid white;
}

/* User Menu Dropdown */
.user-menu {
	position: relative;
}

.user-avatar-btn {
	background: none;
	border: 2px solid rgba(255, 255, 255, 0.5);
	border-radius: 50%;
	padding: 2px;
	cursor: pointer;
	transition: border-color 0.2s ease;
}

.user-avatar-btn:hover {
	border-color: white;
}

.user-avatar {
	width: 36px;
	height: 36px;
	border-radius: 50%;
	display: block;
}

.user-dropdown {
	position: absolute;
	top: calc(100% + 10px);
	right: 0;
	background: white;
	border-radius: 12px;
	box-shadow: 0 4px 20px rgba(0, 0, 0, 0.15);
	min-width: 280px;
	opacity: 0;
	visibility: hidden;
	transform: translateY(-10px);
	transition: all 0.2s ease;
	z-index: 1001;
}

.user-dropdown.show {
	opacity: 1;
	visibility: visible;
	transform: translateY(0);
}

.user-info {
	display: flex;
	align-items: center;
	gap: 12px;
	padding: 16px;
}

.user-dropdown-avatar {
	width: 48px;
	height: 48px;
	border-radius: 50%;
}

.user-details {
	display: flex;
	flex-direction: column;
	gap: 2px;
	overflow: hidden;
}

.user-name {
	font-size: 15px;
	font-weight: 600;
	color: #333;
	white-space: nowrap;
	overflow: hidden;
	text-overflow: ellipsis;
}

.user-email {
	font-size: 13px;
	color: #666;
	white-space: nowrap;
	overflow: hidden;
	text-overflow: ellipsis;
}

.user-dropdown-divider {
	height: 1px;
	background: #E0E0E0;
	margin: 0;
}

.logout-form {
	margin: 0;
}

.logout-btn {
	display: flex;
	align-items: center;
	gap: 10px;
	width: 100%;
	padding: 14px 16px;
	background: none;
	border: none;
	cursor: pointer;
	font-size: 14px;
	color: #333;
	transition: background 0.2s ease;
	border-radius: 0 0 12px 12px;
}

.logout-btn:hover {
	background: #f5f5f5;
}

.logout-btn i {
	color: #666;
	font-size: 16px;
}

.container {
	display: flex;
	height: 100%;
	position: relative;
	transition: width 0.3s ease-in-out;
	padding: 100px 20px 20px 20px;
	box-sizing: border-box;
	gap: 30px;
}


.sidebar {
	position: fixed;
	right: 0;
	top: 70px;
	height: 100%;
	width: 10px;
	background: #1A237E;
	display: flex;
	flex-direction: column;
	align-items: center;
	justify-content: center;
	transition: width 0.3s ease-in-out;
	padding: 10px;
}

.sidebar.expanded {
	width: 40%;
	justify-content: flex-start;
}

.toggle-icon {
	position: absolute;
	left: -20px;
	background: #1A237E;
	padding: 8px;
	border-radius: 5px;
	color: white;
	cursor: pointer;
	top: 50%;
	transform: translateY(-50%);
}

.sidebar-content {
	width: 100%;
	display: none;
	overflow-y: auto;
}

.sidebar.expanded .sidebar-content {
	display: flex;
	flex-direction: column;
	align-items: center;
	width: 100%;
}

.case-summary {
	color: white;
	font-size: 16px;
	font-weight: bold;
	text-align: center;
	margin-bottom: 10px;
}

.details-panel {
	width: 80%;
	background: white;
	border-radius: 15px;
	padding: 20px;
	box-shadow: 0px 4px 8px rgba(0, 0, 0, 0.2);
	position: relative;
}

.panel-header {
	display: flex;
	justify-content: space-between;
	align-items: center;
	width: 80%;
	color: white;
}

.panel-icons {
	display: flex;
	gap: 10px;
}

.icon {
	cursor: pointer;
	font-size: 20px;
	color: #ffffff;
	transition: color 0.2s ease-in-out;
}

.icon:hover {
	color: #0D47A1;
}


.content {
	flex: 1;
	padding: 20px;
	margin-right: 1%;
	transition: margin-right 0.3s ease-in-out;
	display: flex;
	flex-direction: column;
	gap: 30px;
}

.content.shrunk {
	margin-right: 41%;
}

.break {
	flex-basis: 100%;
	height: 0;
}

.search-bar {
	display: flex;
	gap: 10px;
	background: white;
	padding: 15px;
	border-radius: 8px;
	box-shadow: 0px 4px 6px rgba(0, 0, 0, 0.1);
	flex-wrap: wrap;
	transition: margin-bottom 0.3s ease-in-out;
}

.search-input,
.search-button {
	padding: 15px;
	border: 1px solid #ccc;
	border-radius: 5px;
}

.search-input {
	flex: 1;
}

.search-button {
	background: #1A237E;
	color: white;
	border: none;
	cursor: pointer;
    transition: background 0.3s ease, cursor 0.3s ease;

}

.search-button:disabled {
    background: #B0BEC5;
    color: #ECEFF1;
    cursor: not-allowed;
    opacity: 0.6;
}

.filters {
	display: flex;
	flex-grow: 1;
	gap: 15px;
}


.loading-spinner {
	width: 50px;
	height: 50px;
	border: 5px solid rgba(0, 0, 0, 0.1);
	border-top-color: #1A237E;
	border-radius: 50%;
	animation: spin 1s linear infinite;
	margin: 50px auto;
}

.button-spinner {
	width: 20px;
	height: 20px;
	border: 3px solid rgba(0, 0, 0, 0.1);
	border-top-color: #1A237E;
	border-radius: 50%;
	animation: spin 0.8s linear infinite;
	display: inline-block;
}

@keyframes spin {
	from {
		transform: rotate(0deg);
	}

	to {
		transform: rotate(360deg);
	}
}

.show-more-btn {
	display: block;
	background-color: #1A237E;
	color: white;
	border: none;
	padding: 10px 15px;
	font-size: 16px;
	cursor: pointer;
	border-radius: 6px;
	text-align: center;
	margin: 20px auto;
	transition: background 0.3s ease;
}

.show-more-btn:hover {
	background-color: #3949AB;
}

.show-more-btn:disabled {
	background-color: #ccc;
	cursor: not-allowed;
}


/* Container for results */
.results {
	flex-grow: 1;
	margin-bottom: 15px;
	display: flex;
	flex-direction: column;
	gap: 15px;
}

/* Result card styling */
.result-card {
	background: white;
	padding: 20px;
	border-radius: 12px;
	box-shadow: 0px 4px 8px rgba(0, 0, 0, 0.08);
	margin-bottom: 15px;
	cursor: pointer;
	transition: 0.3s;
	border: 1px solid #E0E0E0;
}

/* Hover effect with scale */
.result-card:hover {
	transform: scale(1.02);
}

/* Case title and reference */
.case-header {
	display: flex;
	justify-content: space-between;
	align-items: center;
	margin-bottom: 10px;
}

.case-title {
	font-size: 18px;
	font-weight: bold;
	color: #1A237E;
	flex-grow: 1;
}

.case-reference {
	font-size: 14px;
	color: #555;
	display: flex;
	align-items: center;
	gap: 6px;
}

/* Case metadata */
.case-metadata {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	font-size: 14px;
	color: #555;
	margin-top: 8px;
	gap: 15px;
	padding-bottom: 15px;
	border-bottom: 1px solid #E0E0E0;
}

/* Judgment date aligned to the right */
.judgment-date {
	margin-left: auto;
	font-size: 14px;
	color: #333;
}

/* Case reasoning with typing effect */
.case-reasoning {
	font-size: 14px;
	color: #444;
	margin-top: 10px;
	padding-top: 8px;
	white-space: pre-wrap;
	word-wrap: break-word;
	overflow: hidden;
	display: inline-block;
}

.details-box {
	padding: 10px;
	margin-bottom: 10px;
	border-radius: 10px;
	box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}


.rhetorical-roles {
	margin-top: 10px;
	font-size: 16px;
	display: flex;
	flex-direction: column;
	gap: 10px;
	height: 100%;
}

.rhetorical-roles .rhetorical-role-title {
	font-size: 16px;
	padding-bottom: 10px;
}

.rhetorical-roles .rhetorical-role-text {

	font-size: 14px;
	line-height: 2;
}

.rhetorical-roles p {
	margin: 5px 0;
	padding: 8px;
	border-left: 4px solid #1A237E;
	opacity: 0;
	transform: translateY(10px);
	animation: fadeSlideIn 1s ease-in forwards;
}

.judgement-conclusion {
	margin: 5px 0;
	padding: 8px;
	font-size: 16px;
	display: flex;
	flex-direction: column;
	gap: 10px;
	border-left: 4px solid #1A237E;
	/* Extend border to include title */

	transform: translateY(10px);
	animation: fadeSlideIn 1s ease-in forwards;
}

.judgement-conclusion .judgement-conclusion-title {
	font-size: 16px;
	font-weight: bold;
}

.judgement-conclusion-text-wrapper {
	position: relative;
	padding: 10px 15px;
	font-size: 14px;
	line-height: 2;
	text-indent: 15px;
	display: inline-block;
	/* Prevents extra spacing */
}

.judgement-conclusion-text {
	display: inline;
	/* Ensures the quote follows text correctly */
	position: relative;
}

.quote-mark {
	font-size: 48px;
	font-weight: bold;
	color: #A0A02C;
}

.left {
	position: absolute;
	top: -30px;
	left: -15px;
}

.right {
	position: relative;
	float: right;
	height: 20px;
	margin-left: 10px;
	/* Spacing from text */
	bottom: 15px;
	align-self: flex-end;
	/* Ensures alignment to last line */
}


@keyframes fadeIn {
	from {
		opacity: 0;
	}

	to {
		opacity: 1;
	}
}

@keyframes fadeSlideIn {
	from {
		opacity: 0;
		transform: translateY(10px);
	}

	to {
		opacity: 1;
		transform: translateY(0);
	}
}

.underline {
	text-decoration: none;
	border-bottom: 3px solid black;
	padding-bottom: 2px;
}


/* Dropdown Button */
.dropdown {
	position: relative;
	display: inline-block;
	width: 100%;
}

.drop-down-button {
	display: flex;
	align-items: center;
	justify-content: space-between;
	width: 100%;
	padding: 7px 15px;
	font-size: 16px;
	background-color: #f8f9fa;
	border: 1px solid #ced4da;
	border-radius: 5px;
	cursor: pointer;
}

.drop-down-button:hover {
	background-color: #e9ecef;
}

/* Dropdown Menu */
.dropdown-menu {
	position: absolute;
	top: 100%;
	left: 0;
	z-index: 1000;
	display: none;
	/* Initially hidden */
	width: 100%;
	background-color: white;
	border: 1px solid #ced4da;
	border-radius: 5px;
	box-shadow: 0px 4px 6px rgba(0, 0, 0, 0.1);
	list-style: none;
	padding: 5px 0;
	margin: 0;
}

.dropdown-menu.show {
	display: block;
	/* Show when active */
}

/* Dropdown Items */
.dropdown-menu li {
	padding: 10px 15px;
	cursor: pointer;
}

.dropdown-menu li:hover {
	background-color: #f1f1f1;
}

.no-results-main {
    font-size: 11pt;
	color: #555;
	align-items: center;
	text-align: center;
    display: block;
    width: 100%;
    padding-top: 50px;
}

/* =============================================
   Login Page Styles
   ============================================= */

.login-page {
    height: 100vh;
    overflow: hidden;
    background: linear-gradient(135deg, #f5f5f5 0%, #e8eaf6 100%);
}

.login-container {
    display: flex;
    justify-content: center;
    align-items: center;
    height: calc(100vh - 70px);
    padding-top: 70px;
    box-sizing: border-box;
}

.login-card {
    background: white;
    border-radius: 16px;
    box-shadow: 0 8px 32px rgba(26, 35, 126, 0.15);
    padding: 48px 40px;
    width: 100%;
    max-width: 420px;
    text-align: center;
}

.login-header h2 {
    color: #1A237E;
    font-size: 32px;
    font-weight: 700;
    margin: 0 0 8px 0;
}

.login-subtitle {
    color: #666;
    font-size: 16px;
    margin: 0 0 32px 0;
}

.login-buttons {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.login-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
    padding: 14px 24px;
    border-radius: 8px;
    font-size: 16px;
    font-weight: 500;
    text-decoration: none;
    cursor: pointer;
    transition: all 0.2s ease;
    border: none;
}

.google-btn {
    background: white;
    color: #333;
    border: 2px solid #E0E0E0;
}

.google-btn:hover {
    background: #f8f9fa;
    border-color: #1A237E;
    box-shadow: 0 2px 8px rgba(26, 35, 126, 0.15);
}

.google-icon {
    flex-shrink: 0;
}

.login-divider {
    display: flex;
    align-items: center;
    margin: 8px 0;
}

.login-divider::before,
.login-divider::after {
    content: '';
    flex: 1;
    height: 1px;
    background: #E0E0E0;
}

.login-divider span {
    padding: 0 16px;
    color: #999;
    font-size: 14px;
}

.request-btn {
    background: #1A237E;
    color: white;
}

.request-btn:hover {
    background: #3949AB;
    box-shadow: 0 4px 12px rgba(26, 35, 126, 0.3);
}

.request-btn i {
    font-size: 18px;
}

.login-footer {
    margin-top: 32px;
    color: #888;
    font-size: 13px;
}

/* Justification Modal Styles */
.modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.5);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 2000;
    opacity: 0;
    visibility: hidden;
    transition: all 0.2s ease;
}

.modal-overlay.show {
    opacity: 1;
    visibility: visible;
}

.modal-content {
    background: white;
    border-radius: 16px;
    width: 100%;
    max-width: 480px;
    margin: 20px;
    transform: scale(0.9);
    transition: transform 0.2s ease;
    box-shadow: 0 8px 32px rgba(26, 35, 126, 0.2);
}

.modal-overlay.show .modal-content {
    transform: scale(1);
}

.modal-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 24px 24px 0 24px;
}

.modal-header h3 {
    margin: 0;
    font-size: 20px;
    font-weight: 600;
    color: #1A237E;
}

.modal-close {
    background: none;
    border: none;
    padding: 8px;
    cursor: pointer;
    color: #666;
    font-size: 18px;
    border-radius: 8px;
    transition: all 0.2s ease;
}

.modal-close:hover {
    background: #f5f5f5;
    color: #333;
}

.modal-body {
    padding: 20px 24px;
}

.modal-description {
    color: #555;
    font-size: 14px;
    line-height: 1.6;
    margin: 0 0 16px 0;
}

.justification-textarea {
    width: 100%;
    padding: 14px;
    border: 2px solid #E0E0E0;
    border-radius: 8px;
    font-family: inherit;
    font-size: 14px;
    line-height: 1.5;
    resize: vertical;
    min-height: 100px;
    transition: border-color 0.2s ease;
    box-sizing: border-box;
}

.justification-textarea:focus {
    outline: none;
    border-color: #1A237E;
}

.justification-textarea::placeholder {
    color: #999;
}

.textarea-counter {
    text-align: right;
    font-size: 12px;
    color: #999;
    margin-top: 8px;
}

.modal-footer {
    display: flex;
    gap: 12px;
    justify-content: flex-end;
    padding: 0 24px 24px 24px;
}

.modal-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 12px 20px;
    border-radius: 8px;
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s ease;
    border: none;
}

.modal-btn.cancel-btn {
    background: #f5f5f5;
    color: #666;
}

.modal-btn.cancel-btn:hover {
    background: #E0E0E0;
}

.modal-btn.continue-btn {
    background: #1A237E;
    color: white;
}

.modal-btn.continue-btn:hover {
    background: #3949AB;
}

.modal-btn .google-icon {
    flex-shrink: 0;
}

/* Pending Approval Page Styles */
.pending-card {
    max-width: 480px;
}

.pending-icon {
    margin-bottom: 24px;
}

.pending-icon i {
    font-size: 64px;
    color: #FFA726;
}

.pending-message {
    margin-bottom: 32px;
}

.pending-message p {
    color: #555;
    font-size: 15px;
    line-height: 1.6;
    margin: 0 0 16px 0;
}

.pending-message p:last-child {
    margin-bottom: 0;
    color: #888;
    font-size: 14px;
}

.back-btn {
    background: #f5f5f5;
    color: #333;
    border: 2px solid #E0E0E0;
}

.back-btn:hover {
    background: #e8eaf6;
    border-color: #1A237E;
}

.back-btn i {
    font-size: 14px;
}

/* Forbidden Page Styles */
.forbidden-card {
    max-width: 480px;
}

.forbidden-icon {
    margin-bottom: 24px;
}

.forbidden-icon i {
    font-size: 64px;
    color: #C62828;
}

.forbidden-message {
    margin-bottom: 32px;
}

.forbidden-message p {
    color: #555;
    font-size: 15px;
    line-height: 1.6;
    margin: 0 0 16px 0;
}

.forbidden-message p:last-child {
    margin-bottom: 0;
    color: #888;
    font-size: 14px;
}

/* =============================================
   Welcome Page Styles
   ============================================= */

.welcome-card {
    background: white;
    border-radius: 16px;
    box-shadow: 0 8px 32px rgba(26, 35, 126, 0.15);
    padding: 48px 40px;
    width: 100%;
    max-width: 700px;
    text-align: center;
}

.welcome-header h2 {
    color: #1A237E;
    font-size: 32px;
    font-weight: 700;
    margin: 0 0 8px 0;
}

.welcome-subtitle {
    color: #666;
    font-size: 18px;
    margin: 0 0 24px 0;
}

.welcome-description {
    color: #555;
    font-size: 15px;
    line-height: 1.6;
    margin: 0 0 32px 0;
    max-width: 500px;
    margin-left: auto;
    margin-right: auto;
}

.welcome-options {
    display: flex;
    gap: 24px;
    justify-content: center;
}

.welcome-option-card {
    flex: 1;
    max-width: 280px;
    background: #FAFAFA;
    border: 2px solid #E0E0E0;
    border-radius: 12px;
    padding: 32px 24px;
    text-decoration: none;
    transition: all 0.3s ease;
    cursor: pointer;
}

.welcome-option-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 8px 24px rgba(26, 35, 126, 0.15);
}

.welcome-option-card.try-system:hover {
    border-color: #1A237E;
    background: #E8EAF6;
}

.welcome-option-card.watch-demo:hover {
    border-color: #2E7D32;
    background: #E8F5E9;
}

.option-icon {
    width: 64px;
    height: 64px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 20px;
    background: white;
}

.option-icon i {
    font-size: 28px;
}

.try-system .option-icon {
    background: #E8EAF6;
}

.try-system .option-icon i {
    color: #1A237E;
}

.watch-demo .option-icon {
    background: #E8F5E9;
}

.watch-demo .option-icon i {
    color: #2E7D32;
}

.welcome-option-card h3 {
    color: #333;
    font-size: 18px;
    font-weight: 600;
    margin: 0 0 12px 0;
}

.welcome-option-card p {
    color: #666;
    font-size: 14px;
    line-height: 1.5;
    margin: 0;
}

.welcome-option-card.disabled {
    opacity: 0.6;
    cursor: not-allowed;
    pointer-events: none;
}

.welcome-option-card.disabled:hover {
    transform: none;
    box-shadow: none;
    border-color: #E0E0E0;
    background: #FAFAFA;
}

.welcome-option-card.disabled .option-icon {
    background: #F5F5F5;
}

.welcome-option-card.disabled .option-icon i {
    color: #999;
}

.welcome-option-card.disabled h3,
.welcome-option-card.disabled p {
    color: #999;
}

/* =============================================
   Demo Page Styles
   ============================================= */

.demo-container {
    max-width: 1000px;
    margin: 0 auto;
    padding: 100px 30px 30px 30px;
}

.demo-header {
    margin-bottom: 30px;
    padding-top: 20px;
    text-align: center;
}

.demo-header .back-link {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    color: #666;
    text-decoration: none;
    font-size: 14px;
    transition: color 0.2s ease;
    margin-bottom: 16px;
}

.demo-header .back-link:hover {
    color: #1A237E;
}

.demo-header h2 {
    color: #1A237E;
    font-size: 28px;
    font-weight: 600;
    margin: 0 0 8px 0;
}

.demo-subtitle {
    color: #666;
    font-size: 16px;
    margin: 0;
}

.video-wrapper {
    background: #000;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.2);
    margin-bottom: 32px;
}

.demo-video {
    width: 100%;
    display: block;
    max-height: 70vh;
}

.demo-actions {
    display: flex;
    gap: 16px;
    justify-content: center;
}

.demo-action-btn {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    padding: 14px 28px;
    border-radius: 8px;
    font-size: 15px;
    font-weight: 500;
    text-decoration: none;
    transition: all 0.2s ease;
}

.demo-action-btn.primary-btn {
    background: #1A237E;
    color: white;
}

.demo-action-btn.primary-btn:hover {
    background: #3949AB;
    box-shadow: 0 4px 12px rgba(26, 35, 126, 0.3);
}

.demo-action-btn.primary-btn.disabled {
    background: #B0BEC5;
    color: #ECEFF1;
    cursor: not-allowed;
    pointer-events: none;
}

.demo-action-btn.secondary-btn {
    background: #f5f5f5;
    color: #333;
    border: 2px solid #E0E0E0;
}

.demo-action-btn.secondary-btn:hover {
    background: #e8eaf6;
    border-color: #1A237E;
}

/* Responsive adjustments for welcome page */
@media (max-width: 600px) {
    .welcome-options {
        flex-direction: column;
        align-items: center;
    }

    .welcome-option-card {
        max-width: 100%;
    }

    .welcome-card {
        padding: 32px 24px;
    }

    .demo-actions {
        flex-direction: column;
    }

    .demo-action-btn {
        justify-content: center;
    }
}

/* =============================================
   Users Management Page Styles
   ============================================= */

.users-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 100px 30px 60px 30px;
}

.users-header {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 12px;
    margin-bottom: 30px;
}

.users-header h2 {
    color: #1A237E;
    font-size: 28px;
    font-weight: 600;
    margin: 16px 0 0 0;
    flex: 1;
}

.back-link {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    color: #666;
    text-decoration: none;
    font-size: 14px;
    transition: color 0.2s ease;
    width: 100%;
}

.back-link:hover {
    color: #1A237E;
}

.back-link i {
    font-size: 12px;
}

.users-section {
    background: white;
    border-radius: 12px;
    box-shadow: 0 2px 12px rgba(0, 0, 0, 0.08);
    margin-bottom: 24px;
    overflow: hidden;
}

.users-section:last-child {
    margin-bottom: 0;
}

.users-section:last-child .users-table-container {
    overflow-y: auto;
    max-height: 50vh;
}

.section-title {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 20px 24px;
    margin: 0;
    font-size: 18px;
    font-weight: 600;
    color: #333;
    border-bottom: 1px solid #E0E0E0;
}

.section-title i {
    color: #1A237E;
    font-size: 20px;
}

.badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 24px;
    height: 24px;
    padding: 0 8px;
    background: #FFA726;
    color: white;
    border-radius: 12px;
    font-size: 13px;
    font-weight: 600;
}

.badge-success {
    background: #66BB6A;
}

.users-table-container {
    overflow-x: auto;
}

.users-table {
    width: 100%;
    border-collapse: collapse;
}

.users-table th {
    text-align: left;
    padding: 14px 16px;
    font-size: 12px;
    font-weight: 600;
    color: #666;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    background: #FAFAFA;
    border-bottom: 1px solid #E0E0E0;
}

.users-table td {
    padding: 16px;
    border-bottom: 1px solid #F0F0F0;
    vertical-align: middle;
}

.users-table tbody tr:last-child td {
    border-bottom: none;
}

.users-table tbody tr:hover {
    background: #FAFAFA;
}

.avatar-cell {
    width: 48px;
}

.table-avatar {
    width: 40px;
    height: 40px;
    border-radius: 50%;
}

.name-cell {
    font-weight: 500;
    color: #333;
}

.email-cell {
    color: #666;
}

.justification-cell {
    max-width: 250px;
}

.justification-text {
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    text-overflow: ellipsis;
    color: #555;
    font-size: 13px;
    line-height: 1.4;
    cursor: help;
}

.date-cell {
    color: #888;
    font-size: 14px;
}

.actions-cell {
    white-space: nowrap;
}

.action-btn {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 8px 14px;
    border: none;
    border-radius: 6px;
    font-size: 13px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s ease;
    margin-right: 8px;
}

.action-btn:last-child {
    margin-right: 0;
}

.approve-btn {
    background: #E8F5E9;
    color: #2E7D32;
}

.approve-btn:hover {
    background: #C8E6C9;
}

.deny-btn {
    background: #FFEBEE;
    color: #C62828;
}

.deny-btn:hover {
    background: #FFCDD2;
}

.revoke-btn {
    background: #FFF3E0;
    color: #E65100;
}

.revoke-btn:hover {
    background: #FFE0B2;
}

.empty-state {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 48px 24px;
    color: #999;
}

.empty-state i {
    font-size: 48px;
    margin-bottom: 16px;
    opacity: 0.5;
}

.empty-state p {
    margin: 0;
    font-size: 15px;
}

.muted {
    color: #999;
    font-style: italic;
}

/* Confirmation Dialog */
.confirm-dialog-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.5);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 2000;
    opacity: 0;
    visibility: hidden;
    transition: all 0.2s ease;
}

.confirm-dialog-overlay.show {
    opacity: 1;
    visibility: visible;
}

.confirm-dialog {
    background: white;
    border-radius: 16px;
    padding: 32px;
    width: 100%;
    max-width: 400px;
    text-align: center;
    transform: scale(0.9);
    transition: transform 0.2s ease;
}

.confirm-dialog-overlay.show .confirm-dialog {
    transform: scale(1);
}

.confirm-dialog-icon {
    width: 64px;
    height: 64px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 20px;
}

.confirm-dialog-icon i {
    font-size: 32px;
}

.icon-approve {
    background: #E8F5E9;
}

.icon-approve i {
    color: #2E7D32;
}

.icon-deny {
    background: #FFEBEE;
}

.icon-deny i {
    color: #C62828;
}

.icon-revoke {
    background: #FFF3E0;
}

.icon-revoke i {
    color: #E65100;
}

.confirm-dialog-title {
    margin: 0 0 12px 0;
    font-size: 20px;
    font-weight: 600;
    color: #333;
}

.confirm-dialog-message {
    margin: 0 0 28px 0;
    color: #666;
    font-size: 15px;
    line-height: 1.5;
}

.confirm-dialog-actions {
    display: flex;
    gap: 12px;
    justify-content: center;
}

.confirm-dialog-btn {
    padding: 12px 28px;
    border: none;
    border-radius: 8px;
    font-size: 15px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s ease;
}

.confirm-dialog-btn.cancel-btn {
    background: #f5f5f5;
    color: #666;
}

.confirm-dialog-btn.cancel-btn:hover {
    background: #E0E0E0;
}

.confirm-dialog-btn.confirm-btn {
    background: #1A237E;
    color: white;
}

.confirm-dialog-btn.confirm-btn:hover {
    background: #3949AB;
}

.confirm-dialog-btn.confirm-btn.approve {
    background: #2E7D32;
}

.confirm-dialog-btn.confirm-btn.approve:hover {
    background: #388E3C;
}

.confirm-dialog-btn.confirm-btn.deny {
    background: #C62828;
}

.confirm-dialog-btn.confirm-btn.deny:hover {
    background: #D32F2F;
}

.confirm-dialog-btn.confirm-btn.revoke {
    background: #E65100;
}

.confirm-dialog-btn.confirm-btn.revoke:hover {
    background: #F57C00;
}

.confirm-dialog-btn.confirm-btn.role-confirm {
    background: #1A237E;
}

.confirm-dialog-btn.confirm-btn.role-confirm:hover {
    background: #3949AB;
}

.confirm-dialog-icon.icon-role {
    color: #1A237E;
}

/* Role Badge and Selector Styles */
.role-cell {
    min-width: 120px;
}

.role-selector {
    position: relative;
    display: inline-block;
}

.role-badge {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 6px 12px;
    border-radius: 20px;
    font-size: 13px;
    font-weight: 500;
    border: none;
    cursor: pointer;
    transition: all 0.2s ease;
}

.role-badge.no-action {
    cursor: default;
}

.role-badge.no-action i {
    display: none;
}

.role-badge i {
    font-size: 10px;
    transition: transform 0.2s ease;
}

.role-badge.role-admin {
    background: #E8EAF6;
    color: #1A237E;
}

.role-badge.role-admin:hover:not(.no-action) {
    background: #C5CAE9;
}

.role-badge.role-user {
    background: #E8F5E9;
    color: #2E7D32;
}

.role-badge.role-user:hover:not(.no-action) {
    background: #C8E6C9;
}

.role-dropdown {
    position: absolute;
    top: 100%;
    left: 0;
    z-index: 1000;
    min-width: 140px;
    background: white;
    border-radius: 8px;
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.15);
    padding: 8px 0;
    display: none;
    margin-top: 4px;
}

.role-dropdown.show {
    display: block;
}

.role-option {
    display: flex;
    align-items: center;
    justify-content: space-between;
    width: 100%;
    padding: 10px 16px;
    border: none;
    background: none;
    text-align: left;
    font-size: 14px;
    color: #333;
    cursor: pointer;
    transition: background 0.2s ease;
}

.role-option:hover {
    background: #f5f5f5;
}

.role-option.active {
    color: #1A237E;
    font-weight: 500;
}

.role-option i {
    color: #1A237E;
    font-size: 12px;
}

/* Dropdown menu item for Manage Users link */
.dropdown-menu-item {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 14px 16px;
    text-decoration: none;
    color: #333;
    font-size: 14px;
    transition: background 0.2s ease;
}

.dropdown-menu-item:hover {
    background: #f5f5f5;
}

.dropdown-menu-item i {
    color: #666;
    font-size: 16px;
}

/* Permissions Cell Styling */
.permissions-cell {
    text-align: center;
}

.permissions-badge {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 6px 12px;
    border-radius: 20px;
    font-size: 13px;
    font-weight: 500;
    background: #e0e0e0;
    color: #555;
    border: none;
    cursor: default;
}

.permissions-badge.editable {
    background: #E3F2FD;
    color: #1976D2;
    cursor: pointer;
    transition: all 0.2s ease;
}

.permissions-badge.editable:hover {
    background: #BBDEFB;
    transform: translateY(-1px);
}

.permissions-badge.all-permissions {
    background: #C8E6C9;
    color: #388E3C;
}

.permissions-badge i {
    font-size: 12px;
}

/* Permissions Dialog */
.permissions-dialog {
    background: white;
    border-radius: 16px;
    width: 90%;
    max-width: 500px;
    max-height: 80vh;
    overflow: hidden;
    display: flex;
    flex-direction: column;
}

.permissions-dialog-header {
    padding: 24px 24px 16px;
    border-bottom: 1px solid #e0e0e0;
}

.permissions-dialog-subtitle {
    margin: 8px 0 0;
    font-size: 14px;
    color: #666;
    font-weight: normal;
}

.permissions-dialog-content {
    padding: 24px;
    overflow-y: auto;
    flex: 1;
}

.permissions-list {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.permission-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 16px;
    border: 2px solid #e0e0e0;
    border-radius: 12px;
    cursor: pointer;
    transition: all 0.2s ease;
}

.permission-item:hover {
    border-color: #1976D2;
    background: #F5F9FF;
}

.permission-item input[type="checkbox"] {
    width: 20px;
    height: 20px;
    cursor: pointer;
    accent-color: #1976D2;
}

.permission-info {
    display: flex;
    align-items: center;
    gap: 12px;
    flex: 1;
}

.permission-info i {
    font-size: 20px;
    color: #1976D2;
    width: 24px;
    text-align: center;
}

.permission-label {
    font-size: 15px;
    font-weight: 500;
    color: #333;
}

.confirm-dialog-icon.icon-permissions {
    background: #E8EAF6;
}

.confirm-dialog-icon.icon-permissions i {
    color: #1A237E;
}

.confirm-dialog-btn.permissions-save {
    background: #1A237E;
}

.confirm-dialog-btn.permissions-save:hover {
    background: #3949AB;
}

/* Permission Options - matching role-option styling */
.permissions-options {
    display: flex;
    flex-direction: column;
    background: white;
    border: 1px solid #e0e0e0;
    border-radius: 8px;
    overflow: hidden;
    margin-bottom: 24px;
}

.permission-option {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 12px 16px;
    background: white;
    border: none;
    border-bottom: 1px solid #e0e0e0;
    cursor: pointer;
    font-size: 14px;
    color: #333;
    text-align: left;
    transition: background 0.2s ease;
}

.permission-option:last-child {
    border-bottom: none;
}

.permission-option:hover {
    background: #f5f5f5;
}

.permission-option.active {
    color: #1A237E;
    font-weight: 500;
}

.permission-option i {
    color: #1A237E;
    font-size: 12px;
    opacity: 0;
    transition: opacity 0.2s ease;
}

.permission-option.active i {
    opacity: 1;
}

/* Invite User */
.invite-btn {
    background: #1A237E;
    color: white;
    padding: 10px 20px;
    font-size: 14px;
}

.invite-btn:hover {
    background: #3949AB;
}

.invite-dialog {
    max-width: 440px;
    width: 100%;
}

.confirm-dialog-icon.icon-invite {
    background: #E8EAF6;
}

.confirm-dialog-icon.icon-invite i {
    color: #1A237E;
}

.invite-form {
    text-align: left;
    margin-bottom: 24px;
}

.invite-field {
    margin-bottom: 18px;
}

.invite-field:last-child {
    margin-bottom: 0;
}

.invite-field label {
    display: block;
    font-size: 13px;
    font-weight: 600;
    color: #333;
    margin-bottom: 6px;
}

.invite-input {
    width: 100%;
    padding: 10px 14px;
    border: 1px solid #ddd;
    border-radius: 8px;
    font-size: 14px;
    font-family: inherit;
    transition: border-color 0.2s ease;
    box-sizing: border-box;
}

.invite-input:focus {
    outline: none;
    border-color: #1A237E;
}

.invite-error {
    display: block;
    color: #C62828;
    font-size: 12px;
    margin-top: 4px;
    min-height: 16px;
}

.invite-role-options {
    display: flex;
    gap: 8px;
}

.invite-role-option {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 10px;
    border: 1px solid #ddd;
    border-radius: 8px;
    background: white;
    font-size: 14px;
    font-family: inherit;
    cursor: pointer;
    transition: all 0.2s ease;
}

.invite-role-option:hover {
    background: #f5f5f5;
}

.invite-role-option.active {
    border-color: #1A237E;
    background: #E8EAF6;
    color: #1A237E;
    font-weight: 500;
}

.invite-role-option i {
    font-size: 12px;
    opacity: 0;
    color: #1A237E;
    transition: opacity 0.2s ease;
}

.invite-role-option.active i {
    opacity: 1;
}

.invite-permissions-options {
    display: flex;
    flex-direction: column;
    border: 1px solid #eee;
    border-radius: 8px;
    overflow: hidden;
}

.invite-admin-permissions {
    padding: 8px 0;
}

.confirm-dialog-btn.invite-confirm {
    background: #1A237E;
}

.confirm-dialog-btn.invite-confirm:hover {
    background: #3949AB;
}

.confirm-dialog-btn:disabled {
    opacity: 0.6;
    cursor: not-allowed;
}

/* Search Quota (search page) */
.search-quota {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 6px 4px 0;
    margin-top: 4px;
    font-size: 12px;
    color: #888;
}

.search-quota i {
    color: #1A237E;
    font-size: 14px;
}

.search-quota.exhausted {
    color: #C62828;
}

.search-quota.exhausted i {
    color: #C62828;
}

.search-limit-banner {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 14px 20px;
    margin-top: 16px;
    background: #FFF3E0;
    border: 1px solid #FFE0B2;
    border-radius: 8px;
    color: #E65100;
    font-size: 14px;
    width: 100%;
}

.search-limit-banner i {
    font-size: 18px;
    flex-shrink: 0;
}

/* Search Limit Field (admin dialogs) */
.search-limit-field {
    text-align: left;
    margin-top: 16px;
    margin-bottom: 8px;
}

.search-limit-field label {
    display: block;
    font-size: 13px;
    font-weight: 600;
    color: #333;
    margin-bottom: 6px;
}

.search-limit-input {
    width: 100%;
    padding: 10px 14px;
    border: 1px solid #ddd;
    border-radius: 8px;
    font-size: 14px;
    font-family: inherit;
    transition: border-color 0.2s ease;
    box-sizing: border-box;
}

.search-limit-input:focus {
    outline: none;
    border-color: #1A237E;
}

.search-limit-hint {
    display: block;
    font-size: 12px;
    color: #888;
    margin-top: 4px;
}

/* Search Usage Badge (active users table) */
.search-usage-badge {
    display: inline-block;
    font-size: 11px;
    color: #666;
    background: #f0f0f0;
    padding: 2px 8px;
    border-radius: 10px;
    margin-left: 6px;
    vertical-align: middle;
}