/**
 * Public styles for DAO File Manager
 *
 * @package    DAO_File_Manager
 * @subpackage DAO_File_Manager/public/css
 */

/* Login Container */
.dao-login-container {
	max-width: 450px;
	margin: 40px auto;
	padding: 20px;
}

.dao-login-box {
	background: #fff;
	padding: 40px;
	border-radius: 8px;
	box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.dao-login-box h2 {
	margin-top: 0;
	margin-bottom: 25px;
	text-align: center;
	color: #333;
	font-size: 24px;
}

/* Login Messages */
.dao-login-error,
.dao-login-success {
	padding: 12px 15px;
	margin-bottom: 20px;
	border-radius: 4px;
	border-left: 4px solid;
}

.dao-login-error {
	background-color: #fef7f7;
	border-left-color: #d63638;
	color: #d63638;
}

.dao-login-success {
	background-color: #f0f6fc;
	border-left-color: #2271b1;
	color: #2271b1;
}

.dao-login-error p,
.dao-login-success p {
	margin: 0;
}

/* Login Form Fields */
.dao-login-field {
	margin-bottom: 20px;
}

.dao-login-field label {
	display: block;
	margin-bottom: 8px;
	font-weight: 600;
	color: #333;
}

.dao-input {
	width: 100%;
	padding: 12px;
	border: 1px solid #ddd;
	border-radius: 4px;
	font-size: 16px;
	transition: border-color 0.2s;
}

.dao-input:focus {
	outline: none;
	border-color: #2271b1;
	box-shadow: 0 0 0 1px #2271b1;
}

/* Remember Me */
.dao-login-remember {
	margin-bottom: 20px;
}

.dao-login-remember label {
	display: flex;
	align-items: center;
	font-weight: normal;
	cursor: pointer;
}

.dao-login-remember input[type="checkbox"] {
	margin-right: 8px;
}

/* Login Submit */
.dao-login-submit {
	margin-bottom: 15px;
}

.dao-button {
	display: inline-block;
	padding: 12px 24px;
	border: none;
	border-radius: 4px;
	font-size: 16px;
	font-weight: 600;
	text-decoration: none;
	cursor: pointer;
	transition: background-color 0.2s, transform 0.1s;
}

.dao-button:active {
	transform: translateY(1px);
}

.dao-button-primary {
	width: 100%;
	background-color: #2271b1;
	color: #fff;
}

.dao-button-primary:hover {
	background-color: #135e96;
	color: #fff;
}

.dao-button-secondary {
	background-color: #f0f0f1;
	color: #2c3338;
}

.dao-button-secondary:hover {
	background-color: #dcdcde;
	color: #2c3338;
}

/* Login Links */
.dao-login-links {
	text-align: center;
	margin-top: 20px;
}

.dao-login-links a {
	color: #2271b1;
	text-decoration: none;
}

.dao-login-links a:hover {
	text-decoration: underline;
}

/* File Browser */
.dao-file-browser {
	max-width: 1200px;
	margin: 0 auto;
	padding: 20px;
}

/* Browser Body Layout */
.dao-browser-body {
	display: grid;
	grid-template-columns: 280px 1fr;
	gap: 24px;
	align-items: start;
}

/* Browser Header */
.dao-browser-header {
	display: flex;
	justify-content: space-between;
	align-items: center;
	padding: 20px;
	background: #fff;
	border-radius: 8px;
	box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
	margin-bottom: 30px;
}

.dao-user-welcome h2 {
	margin: 0 0 10px 0;
	font-size: 24px;
	color: #333;
}

.dao-user-stats {
	margin: 0;
	color: #666;
	font-size: 14px;
}

/* Folder Navigation */
.dao-folder-nav {
	background: #fff;
	padding: 20px;
	border-radius: 8px;
	box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
	position: sticky;
	top: 20px;
}

.dao-folder-nav h3 {
	margin-top: 0;
	margin-bottom: 15px;
	color: #333;
	font-size: 18px;
}

.dao-folder-list {
	list-style: none;
	margin: 0;
	padding: 0;
}

.dao-folder-list li {
	margin-bottom: 5px;
}

.dao-folder-list li a {
	display: flex;
	align-items: center;
	padding: 12px 15px;
	background: #f8f9fa;
	border-radius: 6px;
	text-decoration: none;
	color: #333;
	transition: background-color 0.2s, transform 0.1s;
}

.dao-folder-list li a:hover {
	background: #e9ecef;
	transform: translateX(5px);
}

.dao-folder-list li.active a {
	background: #2271b1;
	color: #fff;
}

.folder-icon {
	font-size: 20px;
	margin-right: 10px;
}

.folder-name {
	flex: 1;
	font-weight: 600;
}

.folder-count {
	background: #e9ecef;
	border-radius: 999px;
	color: #4d5966;
	font-size: 12px;
	font-weight: 600;
	padding: 2px 8px;
}

.dao-folder-list li.active .folder-count {
	background: rgba(255, 255, 255, 0.2);
	color: rgba(255, 255, 255, 0.9);
}

/* Files Content */
.dao-files-content {
	background: #fff;
	padding: 30px;
	border-radius: 8px;
	box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.dao-folder-header {
	display: flex;
	justify-content: space-between;
	align-items: center;
	gap: 20px;
	margin-bottom: 20px;
	padding-bottom: 16px;
	border-bottom: 2px solid #f0f0f1;
}

.dao-folder-header h3 {
	margin: 0 0 10px 0;
	font-size: 22px;
	color: #333;
}

.dao-folder-description {
	margin: 0;
	color: #666;
	font-size: 14px;
}

.dao-folder-count {
	background: #f0f0f1;
	border-radius: 999px;
	color: #333;
	font-size: 12px;
	font-weight: 700;
	padding: 6px 10px;
}

/* Files List */
.dao-files-list {
	display: flex;
	flex-direction: column;
	gap: 14px;
}

.dao-file-card {
	display: flex;
	align-items: center;
	gap: 16px;
	background: #f8f9fa;
	border: 1px solid #e9ecef;
	border-radius: 10px;
	padding: 16px 18px;
	transition: transform 0.2s, box-shadow 0.2s;
}

.dao-file-card:hover {
	transform: translateY(-4px);
	box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

.dao-file-icon {
	flex: 0 0 auto;
	color: #d63638;
}

.dao-file-icon svg {
	width: 32px;
	height: 32px;
}

.dao-file-info {
	flex: 1;
	min-width: 0;
}

.dao-file-name {
	margin: 0 0 6px 0;
	font-size: 16px;
	font-weight: 600;
	color: #333;
	overflow: hidden;
	text-overflow: ellipsis;
	white-space: nowrap;
}

.dao-file-meta {
	margin: 0;
	font-size: 13px;
	color: #666;
}

.dao-file-size::after {
	content: " • ";
	margin: 0 5px;
}

.dao-file-actions {
	flex: 0 0 auto;
}

.dao-file-actions .dao-button {
	width: auto;
	padding: 10px 16px;
}

/* Empty States */
.dao-no-access,
.dao-no-files,
.dao-select-folder,
.dao-access-denied {
	text-align: center;
	padding: 60px 20px;
	color: #666;
}

.dao-no-access p,
.dao-no-files p,
.dao-select-folder p,
.dao-access-denied p {
	margin: 10px 0;
	font-size: 16px;
}

.dao-access-denied h2 {
	color: #333;
	margin-bottom: 15px;
}

/* Responsive Design */
@media screen and (max-width: 768px) {
	.dao-browser-body {
		grid-template-columns: 1fr;
	}

	.dao-browser-header {
		flex-direction: column;
		align-items: flex-start;
		gap: 15px;
	}

	.dao-user-actions {
		width: 100%;
	}

	.dao-user-actions .dao-button {
		width: 100%;
	}

	.dao-folder-nav {
		position: static;
	}

	.dao-file-card {
		flex-direction: column;
		align-items: flex-start;
	}

	.dao-file-actions {
		width: 100%;
	}

	.dao-file-actions .dao-button {
		width: 100%;
	}

	.dao-login-container {
		padding: 10px;
	}

	.dao-login-box {
		padding: 30px 20px;
	}
}

@media screen and (max-width: 480px) {
	.dao-browser-header {
		padding: 15px;
	}

	.dao-user-welcome h2 {
		font-size: 20px;
	}

	.dao-files-content {
		padding: 20px 15px;
	}

	.dao-folder-nav {
		padding: 15px;
	}
}

/* Loading Animation */
.dao-loading {
	text-align: center;
	padding: 60px 20px;
	color: #666;
}

.dao-loading::before {
	content: "";
	display: inline-block;
	width: 30px;
	height: 30px;
	border: 4px solid rgba(0, 0, 0, 0.1);
	border-radius: 50%;
	border-top-color: #2271b1;
	animation: dao-spin 1s linear infinite;
	margin-bottom: 15px;
}

@keyframes dao-spin {
	to {
		transform: rotate(360deg);
	}
}

/* Print Styles */
@media print {
	.dao-browser-header,
	.dao-folder-nav,
	.dao-file-actions,
	.dao-user-actions {
		display: none;
	}

	.dao-file-browser {
		padding: 0;
	}

	.dao-files-content {
		box-shadow: none;
		border: 1px solid #ddd;
	}
}
