/*--- START OF FILE admin/admin.css ---
设计理念: 简洁、精致、高效
*/

/* 基础变量定义 */
:root {
--primary-green: #4a9f6b;
--secondary-green: #6fb58d;
--warm-bg: #faf7f2;
--text-color: #2c3e50;
--light-gray: #eee8e1;
--link-hover: #367952;
--border-color: var(--light-gray);
--shadow-color: rgba(74, 159, 107, 0.15);
--warm-card-bg: #fff;
--danger-color: #dc3545;
--info-color: #17a2b8;
--warning-color: #ffc107;
}

/* 全局重置 */
* {
box-sizing: border-box;
margin: 0;
padding: 0;
}

body {
font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Oxygen, Ubuntu, Cantarell, "Fira Sans", "Droid Sans", "Helvetica Neue", sans-serif;
background-color: var(--warm-bg);
color: var(--text-color);
padding: 20px;
min-height: 100vh;

}

/* 确保基础元素继承颜色并移除默认样式 */
body, h1, h2, h3, p, a, div, span, form, button, input, select, textarea, table, th, td {
color: var(--text-color);
text-decoration: none;
}

a {
color: var(--primary-green);
}

a:hover {
color: var(--link-hover);
text-decoration: underline;
}

/* 主容器布局 */
.container {
max-width: 960px;
margin: 0 auto;
}

/* 侧边栏和内容容器 */
.main-wrapper {
display: flex;
flex-grow: 1;
}

/* 侧边栏样式 */
.sidebar {
width: 200px;
flex-shrink: 0;
background: var(--warm-card-bg);
border-radius: 8px;
box-shadow: 0 4px 12px var(--shadow-color);
padding: 20px 0;
position: sticky;
top: 20px;
height: fit-content;
}

.sidebar h2 {
font-size: 1.1em;
font-weight: 600;
padding: 15px 20px;
margin-bottom: 10px;
color: var(--text-color);
border-bottom: 1px solid var(--border-color);
}

.sidebar h2 a {
color: var(--primary-green);
text-decoration: none;
}

.sidebar h2 a:hover {
color: var(--link-hover);
text-decoration: none;
}

.sidebar nav {
padding: 0 15px;
}

.sidebar nav a {
display: block;
padding: 5px 15px;
color: var(--text-color);
text-decoration: none;
transition: all 0.2s ease;
border-radius: 4px;
}

.sidebar nav a:hover {
background-color: rgba(74, 159, 107, 0.1);
color: var(--primary-green);
}

.sidebar nav a.active {
background-color: var(--primary-green);
color: white;
font-weight: 500;
}

.sidebar nav a.active:hover {
background-color: var(--link-hover);
color: white;
}

.sidebar hr {
margin: 15px 20px;
border: none;
border-top: 1px solid var(--light-gray);
height: 0;
}

/* 主内容区域 */
.content {
flex: 1;
background-color: var(--warm-card-bg);
border-radius: 8px;
box-shadow: 0 4px 12px var(--shadow-color);
padding: 30px;
margin-bottom: 0;
}

.content h1 {
font-size: 2em;
margin-bottom: 20px;
padding-bottom: 15px;
color: var(--primary-green);
border-bottom: 1px solid var(--border-color);
}

.content h2 {
font-size: 1.5em;
margin-top: 20px;
margin-bottom: 15px;
color: var(--text-color);
}

/* 表单样式 */
.form-group {
margin-bottom: 20px;
}

label {
display: block;
margin-bottom: 8px;
color: var(--text-color);
font-weight: 500;
font-size: 0.95em;
}

input[type="text"],
input[type="email"],
input[type="password"],
textarea,
select {
display: block;
width: 100%;
padding: 12px 15px;
border: 1px solid var(--border-color);
border-radius: 6px;
background-color: #fff;
transition: border-color 0.3s ease, box-shadow 0.3s ease;
font-size: 1em;
}

input[type="text"]:focus,
input[type="email"]:focus,
input[type="password"]:focus,
textarea:focus,
select:focus {
outline: none;
border-color: var(--primary-green);
box-shadow: 0 0 0 3px rgba(74, 159, 107, 0.2);
}

textarea {
resize: vertical;
}

/* Radio/Checkbox Group */
.radio-group,
.checkbox-group {
display: flex;
flex-direction: column;
gap: 8px;
padding: 10px 15px;
border: 1px solid var(--border-color);
border-radius: 6px;
background-color: #f9f9f9;
max-height: 200px;
overflow-y: auto;
}

.radio-group label,
.checkbox-group label {
display: flex;
align-items: center;
margin-bottom: 0;
font-weight: normal;
cursor: pointer;
}

.radio-group input[type="radio"],
.checkbox-group input[type="checkbox"] {
margin-right: 8px;
width: auto;
padding: 0;
display: inline-block;
vertical-align: middle;
}

/* 描述文本 */
.description {
font-size: 0.85em;
color: #666;
margin-top: 5px;
line-height: 1.4;
}

.option-description {
margin-top: 5px;
margin-left: 25px;
font-size: 0.85em;
color: #666;
line-height: 1.4;
}

/* 按钮样式 */
.button, .btn {
display: inline-flex;
align-items: center;
justify-content: center;
padding: 5px 10px;
border-radius: 6px;
border: none;
cursor: pointer;
transition: all 0.2s ease;
font-size: 1em;
text-decoration: none;
min-width: 80px;
text-align: center;
}

.button {
background-color: var(--primary-green);
color: white;
}

.button:hover {
background-color: var(--link-hover);
}

/* 特定按钮颜色 */
.btn-primary {
background-color: var(--primary-green);
color: white;
}

.btn-primary:hover {
background-color: var(--link-hover);
}

.btn-success {
background: #28a745;
color: white;
}

.btn-success:hover {
background: #218838;
}

.btn-success:disabled {
background: var(--secondary-green);
cursor: not-allowed;
opacity: 0.8;
}

.btn-info {
background: var(--info-color);
color: white;
}

.btn-info:hover {
background: #138496;color: white;
}

.btn-danger {
background: var(--danger-color);
color: white;
}

.btn-danger:hover {
background: #c82333;
}

.button-link {
background: none;
border: none;
padding: 0;
font-size: inherit;
color: var(--primary-green);
cursor: pointer;
text-decoration: underline;
transition: color 0.2s ease;
display: inline;
min-width: auto;
}

.button-link:hover {
color: var(--link-hover);
}

.button-link.delete-tag-button {
color: var(--danger-color);
text-decoration: none;
font-size: 1.1em;
margin-left: 5px;
}

.button-link.delete-tag-button:hover {
color: #c82333;
text-decoration: none;
}

/* 表格样式 */
table {
width: 100%;
border-collapse: separate;
border-spacing: 0;
margin: 20px 0;
background: var(--warm-card-bg);
border-radius: 8px;
overflow: hidden;
box-shadow: 0 2px 8px var(--shadow-color);
}

th, td {
padding: 5px 15px;
border-bottom: 1px solid var(--light-gray);
text-align: left;
}

th {
background-color: var(--secondary-green);
color: white;
font-weight: 600;
font-size: 0.9em;
}

/* 圆角样式 */
table thead tr:first-child th:first-child { border-top-left-radius: 8px; }
table thead tr:first-child th:last-child { border-top-right-radius: 8px; }
table tbody tr:last-child td:first-child { border-bottom-left-radius: 8px; }
table tbody tr:last-child td:last-child { border-bottom-right-radius: 8px; }

tr:hover {
background-color: rgba(74, 159, 107, 0.05);
}

tbody tr:last-child td {
border-bottom: none;
}

/* 插件表格特殊样式 */
.plugins tr.active { background-color: #f0fff8; }
.plugins tr.plugin-error { 
background-color: #ffe9e9; 
border-left: 4px solid var(--danger-color); 
}

.plugin-error-notice {
color: var(--danger-color);
font-size: 0.8em;
font-weight: 500;
margin-top: 5px;
}

/* 表格中的行操作链接/按钮 */
.row-actions {
opacity: 0;
transition: opacity 0.2s ease-in-out;
font-size: 0.9em;
margin-top: 5px;
}

tr:hover .row-actions {
opacity: 1;
}

.row-actions form {
display: inline;
margin: 0;
padding: 0;
}

.row-actions form button {
background: none;
border: none;
padding: 0 5px 0 0;
font-size: inherit;
cursor: pointer;
color: #666;
text-decoration: none;
transition: color 0.2s ease;
}

.row-actions form button:hover {
color: var(--primary-green);
text-decoration: underline;
}

.row-actions .deactivate-link { color: var(--warning-color); }
.row-actions .deactivate-link:hover { color: #d39e00; }
.row-actions .activate-link { color: var(--primary-green); }
.row-actions .activate-link:hover { color: var(--link-hover); }

/* 筛选器样式 */
.filters {
background: var(--warm-card-bg);
padding: 20px;
border-radius: 8px;
box-shadow: 0 2px 8px var(--shadow-color);
margin-bottom: 20px;
}

.filter-form {
display: flex;
gap: 20px;

}

.filter-form .form-group {
flex: 1;
min-width: 150px;
margin-bottom: 0;
}

.filter-form label {
margin-bottom: 5px;
font-weight: normal;
font-size: 0.9em;
color: #555;
}

.filter-form select {
width: 100%;
padding: 8px 12px;
font-size: 0.95em;
}

/* 页面信息样式 */
.page-info {
margin: 20px 0;
color: #666;
font-size: 0.9em;
text-align: right;
}

/* 分页导航样式 */
.pagination {
display: flex;
justify-content: center;
align-items: center;
gap: 6px;
margin-top: 30px;
padding-bottom: 20px;
}

.pagination a {
display: inline-flex;
align-items: center;
justify-content: center;
min-width: 32px;
height: 32px;
padding: 0 8px;
background-color: var(--warm-card-bg);
border: 1px solid var(--border-color);
border-radius: 4px;
color: var(--text-color);
text-decoration: none;
transition: all 0.2s ease;
font-size: 0.9em;
}

.pagination a:hover {
background-color: rgba(74, 159, 107, 0.1);
border-color: var(--primary-green);
color: var(--primary-green);
}

.pagination a.active {
background-color: var(--primary-green);
border-color: var(--primary-green);
color: white;
font-weight: 500;
}

.pagination .prev,
.pagination .next {
padding: 0 12px;
min-width: 70px;
}

.pagination .dots {
color: #999;
padding: 0 4px;
}

/* 页脚样式 */
footer {
text-align: center;
padding: 20px;
color: #777;
flex-shrink: 0;
}

footer a {
color: #777;
text-decoration: none;
}

footer a:hover {
color: var(--primary-green);
text-decoration: underline;
}

/* 主题管理样式 */
.themes-grid {
display: grid;
grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
gap: 0.5rem;

}

.theme-card {
border: 1px solid var(--border-color);
border-radius: 8px;
overflow: hidden;
transition: all 0.3s ease;
background: var(--warm-card-bg);
position: relative;
display: flex;
flex-direction: column;
}

.theme-card:hover {
box-shadow: 0 6px 16px var(--shadow-color);
transform: translateY(-3px);
}

.theme-card.active {
border-color: var(--primary-green);
box-shadow: 0 0 0 2px var(--primary-green);
}

.theme-card.active::before {
content: '当前主题';
position: absolute;
top: 10px;
right: 10px;
background: var(--primary-green);
color: white;
padding: 4px 10px;
border-radius: 15px;
font-size: 0.8em;
font-weight: 600;
z-index: 1;
}

.theme-card.invalid {
border-color: var(--danger-color);
opacity: 0.9;
}
.active-theme-badge {
display: none;
}
.theme-screenshot {
width: 100%;
height: 220px;
flex-shrink: 0;
border-bottom: 1px solid var(--border-color);
background: var(--light-gray);
display: flex;
align-items: center;
justify-content: center;
font-size: 0.9em;
color: #777;
}

.theme-card img {
width: 100%;
height: 100%;
object-fit: cover;
display: block;
}

.no-screenshot {
width: 100%;
height: 100%;
background: var(--light-gray);
display: flex;
align-items: center;
justify-content: center;
color: #777;
font-size: 0.9em;
}

.theme-info {
padding: 15px 20px;
flex-grow: 1;
display: flex;
flex-direction: column;
}

.theme-info h3 {
margin: 0 0 8px 0;
color: var(--primary-green);
font-size: 1.1em;
font-weight: 600;
}

.theme-info p {
margin: 5px 0;
color: #555;
font-size: 0.9em;
line-height: 1.5;
}

.theme-name .theme-version {
font-size: 0.8em;
color: #888;
font-weight: normal;
margin-left: 5px;
}

.theme-author, .theme-uri {
font-size: 0.85em;
color: #666;
margin-right: 15px;
display: block;
margin-top: 4px;
margin-bottom: 4px;
}

.theme-author a, .theme-uri a {
color: #666;
text-decoration: none;
}

.theme-author a:hover, .theme-uri a:hover {
color: var(--primary-green);
text-decoration: underline;
}

.theme-actions {
margin-top: 15px;
padding: 0 20px 15px;
display: flex;
gap: 10px;
justify-content: flex-start;
flex-shrink: 0;
}

.theme-card.invalid .theme-actions {
justify-content: center;
}

/* Alert/Notification Messages */
.alert {
margin: 15px 0;
padding: 15px 20px;
border-radius: 6px;
font-size: 0.95em;
line-height: 1.5;
border: 1px solid transparent;
}

.alert-success {
background: #d4edda;
border-color: #c3e6cb;
color: #155724;
}

.alert-danger {
background: #f8d7da;
border-color: #f5c6cb;
color: #721c24;
}

.alert-warning {
background: #fff3cd;
border-color: #ffeeba;
color: #856404;
}

.alert-info {
background: #d1ecf1;
border-color: #bee5eb;
color: #0c5460;
}

.alert ul {
margin: 10px 0 0 25px;
padding: 0;
list-style-type: disc;
}

/* Rich Text Editor Styles */
.toolbar {
background-color: #f8f9fa;
border: 1px solid var(--border-color);
border-bottom: none;
border-top-left-radius: 6px;
border-top-right-radius: 6px;
padding: 8px 10px;
display: flex;
flex-wrap: wrap;
gap: 5px;
}

.toolbar button {
background: none;
border: 1px solid transparent;
padding: 4px 8px;
cursor: pointer;
font-size: 1em;
transition: all 0.1s ease;
border-radius: 4px;
}

.toolbar button:hover {
background-color: #e9ecef;
border-color: #ced4da;
}

.toolbar button:active {
background-color: #dee2e6;
border-color: #adb5bd;
}

#editor {
border: 1px solid var(--border-color);
border-bottom-left-radius: 6px;
border-bottom-right-radius: 6px;
padding: 15px;
min-height: 300px;
background-color: #fff;
outline: none;
line-height: 1.6;
font-size: 1em;
word-wrap: break-word;
}

#editor:focus {
border-color: var(--primary-green);
box-shadow: 0 0 0 3px rgba(74, 159, 107, 0.2);
}

#editor img {
max-width: 100%;
height: auto;
display: block;
margin: 10px 0;
}

/* Widget Management Styles */
.widget-item {
margin: 15px 0;
padding: 15px;
border: 1px solid var(--border-color);
background-color: #fff;
border-radius: 8px;
transition: all 0.2s ease;
position: relative;
}

.widget-item:first-child { margin-top: 0; }
.widget-item:last-child { margin-bottom: 0; }

.widget-item.dragging {
opacity: 0.6;
background-color: #f8f9fa;
border: 1px dashed var(--primary-green);
box-shadow: 0 4px 12px var(--shadow-color);
}

.drag-handle {
cursor: grab;
margin-right: 10px;
color: #666;
user-select: none;
font-size: 1.2em;
line-height: 1;
padding: 5px;
display: flex;
align-items: center;
justify-content: center;
}

.widget-item.dragging .drag-handle {
cursor: grabbing;
}

.widget-header {
display: flex;
align-items: center;
margin-bottom: 10px;
gap: 10px;
}

.widget-header .widget-title-input {
padding: 8px 10px;
font-size: 0.95em;
}

.widget-header .widget-type-select {
padding: 8px 10px;
font-size: 0.95em;
}

.widget-header .remove-widget {
margin-left: auto;
padding: 8px 12px;
font-size: 0.9em;
}

.widget-content-input {
width: 100%;
min-height: 80px;
margin-top: 5px;
resize: vertical;
padding: 10px 12px;
font-size: 1em;
}

/* Drag over indicators */
.drag-over-indicator-top,
.drag-over-indicator-bottom {
position: absolute;
left: 0;
right: 0;
height: 3px;
background-color: var(--primary-green);
z-index: 10;
}

.drag-over-indicator-top { top: -2px; }
.drag-over-indicator-bottom { bottom: -2px; }

#no-widgets-placeholder {
color: #666;
text-align: center;
padding: 30px;
border: 2px dashed var(--border-color);
border-radius: 8px;
margin: 20px 0;
}

/* Categories/Tags List */
.tags-container, .categories-container {
display: flex;
gap: 30px;
flex-wrap: wrap;
}

.add-tag, .add-category {
flex: 1;
min-width: 300px;
}

.tags-list, .categories-list {
flex: 2;
min-width: 300px;
}

.tags-cloud {
display: flex;
flex-wrap: wrap;
gap: 8px 15px;
margin-top: 20px;
}

.tag-item, .category-item {
display: inline-flex;
align-items: center;
background-color: #e9e9eb;
border-radius: 15px;
padding: 4px 10px;
font-size: 0.9em;
color: var(--text-color);
transition: background-color 0.2s ease;
}

.tag-item:hover, .category-item:hover {
background-color: #dcdcdc;
}

.tag-item a, .category-item a {
color: var(--text-color);
text-decoration: none;
}

.tag-item a:hover, .category-item a:hover {
color: var(--primary-green);
}

.tag-count, .category-count {
font-size: 0.85em;
color: #555;
margin-left: 5px;
}

.tag-item form, .category-item form {
display: inline;
margin-left: 5px;
}

.tag-item .delete-tag-button, .category-item .delete-button {
background: none;
border: none;
color: #999;
cursor: pointer;
padding: 0 0 0 5px;
font-size: 1em;
transition: color 0.2s ease;
}

.tag-item .delete-tag-button:hover, .category-item .delete-button:hover {
color: var(--danger-color);
}

/* Menu Item Styles */
#menu-items-container {
margin-top: 20px;
}

.menu-item {
display: flex;
align-items: center;
gap: 10px;
margin-bottom: 10px;
padding: 10px 15px;
border: 1px solid var(--border-color);
border-radius: 6px;
background: var(--warm-card-bg);
box-shadow: 0 1px 4px rgba(0,0,0,0.05);
cursor: grab;
transition: all 0.2s ease;
}

.menu-item:hover {
box-shadow: 0 2px 6px rgba(0,0,0,0.1);
background-color: #fcfcfc;
}

.menu-item.dragging {
opacity: 0.6;
background-color: #f8f9fa;
border: 1px dashed var(--primary-green);
}

.menu-item input[type="text"] {
flex: 1;
padding: 8px 12px;
font-size: 0.95em;
width: auto;
}

.menu-item input[name="menu_name[]"] {
min-width: 150px;
}

.menu-item input[name="menu_url[]"] {
min-width: 200px;
}

.menu-item .drag-handle {
flex-shrink: 0;
display: flex;
align-items: center;
padding: 0 5px;
cursor: grab;
}

.menu-item .remove-item {
flex-shrink: 0;
padding: 8px 12px;
font-size: 0.9em;
min-width: auto;
}

#add-item {
margin-top: 10px;
}

#no-menu-items-placeholder {
color: #666;
text-align: center;
padding: 20px;
border: 1px dashed var(--border-color);
border-radius: 8px;
margin-top: 20px;
}

/* Profile Page Sections */
.profile-edit-section,
.password-change-section {
margin-bottom: 30px;
padding-bottom: 20px;
border-bottom: 1px solid var(--border-color);
}

.password-change-section {
border-bottom: none;
padding-bottom: 0;
}

.profile-edit-section h2,
.password-change-section h2 {
margin-top: 0;
margin-bottom: 20px;
padding-bottom: 10px;
border-bottom: 1px dashed var(--light-gray);
}

.
.profile-edit-section .form-group:last-of-type,
.password-change-section .form-group:last-of-type {
margin-bottom: 25px; /* Space before button */
}
/* Settings Page Specifics */
.permalink-structure {
margin-top: 25px;
padding: 15px;
border: 1px solid var(--border-color);
border-radius: 8px;
background-color: #f9f9f9;
}
.permalink-structure label strong {
display: block;
margin-bottom: 10px;
font-size: 1.1em;
color: var(--text-color);
}
.permalink-option {
margin-bottom: 15px;
}
.permalink-option label {
display: flex; /* Align radio and text */
align-items: center;
margin-bottom: 5px;
font-weight: normal;
cursor: pointer;
}
.permalink-option input[type="radio"] {
margin-right: 8px;
width: auto;
padding: 0;
display: inline-block;
vertical-align: middle;
}
.permalink-example {
margin-left: 25px;
font-style: italic;
color: #666;
font-size: 0.9em;
}
.comment-option label {
display: flex; /* Align checkbox and text */
align-items: center;
margin-bottom: 5px;
font-weight: normal;
cursor: pointer;
}
.comment-option input[type="checkbox"] {
margin-right: 8px;
width: auto;
padding: 0;
display: inline-block;
vertical-align: middle;
}
/* Other minor adjustments */
.view { /* (查看) link next to title in lists */
font-size: 0.85em;
margin-left: 8px;
color: #777;
text-decoration: none;
}
.view:hover {
color: var(--primary-green);
text-decoration: underline;
}
.header { /* Header div used in index.php */
display: flex;
justify-content: space-between;
align-items: center;
margin-bottom: 20px; /* Space below header */
padding-bottom: 15px;
border-bottom: 1px solid var(--border-color);
}
.header h1 { /* Adjust h1 within header */
margin: 0;
padding: 0;
border-bottom: none;
}
.header .button { /* Style button within header */
margin-left: 20px;
flex-shrink: 0; /* Prevent shrinking if title is very long */
}
/* 响应式设计 */
@media (max-width: 992px) { /* Adjust breakpoint slightly */
.container {
flex-direction: column; /* Stack sidebar and content */
gap: 20px; /* Reduced gap */
padding: 0 15px; /* Adjust container padding */
}
body {
padding: 15px; /* Adjust body padding */
}
.main-wrapper {
flex-direction: column;
margin-top: 0;
gap: 20px; /* Space between stacked sidebar and content */
}
.sidebar {
width: auto; /* Auto width */
position: static; /* Static position */
margin-bottom: 0; /* Gap handled by main-wrapper */
padding: 15px 0; /* Adjust padding */
}
.sidebar h2 {
padding: 10px 15px; /* Adjust padding */
margin-bottom: 15px;
}
.sidebar nav {
padding: 0 10px; /* Adjust nav padding */
display: flex; /* Horizontal layout for nav links */
flex-wrap: wrap;
gap: 5px 10px; /* Link间距 */
}
.sidebar nav a {
display: inline-block; /* Inline display for links */
text-align: center; /* Center text */
padding: 8px 12px; /* Adjust padding */
margin-bottom: 0; /* Gap handles spacing */
border-left: none; /* Remove left border */
border-bottom: 2px solid transparent; /* Use bottom border for indicator */
border-radius: 4px; /* Keep border radius */
}
.sidebar nav a:hover {
background-color: rgba(74, 159, 107, 0.1);
color: var(--primary-green);
border-bottom-color: var(--primary-green); /* Hover indicator */
}
.sidebar nav a.active {
border-bottom-color: var(--primary-green); /* Active indicator */
background-color: rgba(74, 159, 107, 0.1); /* Active background */
color: var(--primary-green); /* Active color */
font-weight: 500;
}
.sidebar nav a.active:hover {
background-color: rgba(74, 159, 107, 0.2);
}
.sidebar hr {
display: none; /* Hide hr in mobile nav */
}
.content {
margin-left: 0; /* Remove left margin */
padding: 20px; /* Adjust padding */
}
.content h1 {
font-size: 1.8em;
margin-bottom: 15px;
padding-bottom: 10px;
}
.content h2 {
font-size: 1.3em;
margin-top: 15px;
margin-bottom: 10px;
}
.themes-grid {
grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); /* Smaller cards on smaller screens */
gap: 20px;
}
.theme-card {
margin-bottom: 0; /* Gap handles spacing */
}
.filter-form {
flex-direction: column; /* Stack filters vertically */
gap: 15px; /* Adjust gap */
}
.filter-form .form-group {
flex: auto; /* Remove flex-grow */
width: 100%; /* Full width */
}
.filter-form select {
width: 100%;
}
.tags-container, .categories-container {
flex-direction: column; /* Stack add form and list */
gap: 20px;
}
.add-tag, .add-category, .tags-list, .categories-list {
min-width: auto; /* Remove min-width */
width: 100%; /* Full width */
}
.menu-item {
flex-direction: column; /* Stack menu item inputs */
align-items: stretch; /* Stretch items */
}
.menu-item input[type="text"] {
width: 100%; /* Full width */
min-width: auto; /* Remove min-width */
}
.menu-item .drag-handle, .menu-item .remove-item {
align-self: flex-end; /* Align handle/remove to the right */
}
.menu-item .drag-handle {
margin-right: 0; /* Remove right margin */
}
.header {
flex-direction: column; /* Stack header items */
align-items: flex-start; /* Align left */
}
.header h1 { margin-bottom: 10px; }
.header .button { margin-left: 0; margin-top: 10px; align-self: stretch; } /* Button takes full width */
}

/*登录注册页面*/
.men {
max-width: 360px;
width: 100%;
background-color: #fff;
padding: 30px;
margin: 0 auto;
border-radius: 8px;
box-shadow: 0 2px 8px var(--shadow-color);
}

.men h1 {
color: var(--primary-green);
text-align: center;
margin-bottom: 20px;
padding-bottom: 15px;
border-bottom: 2px solid var(--border-color);
}


.men input:focus {
outline: none;
border-color: var(--primary-green);
box-shadow: 0 0 0 3px var(--shadow-color);
}

/* 按钮样式 */
.men button {
width: 100%;
padding: 10px;
background-color: var(--primary-green);
color: white;
border-radius: 6px;
border: none;
cursor: pointer;
transition: background-color 0.3s;
font-size: 1.1em;
}

.men button:hover {
background-color: var(--link-hover);
}


.men .alert-success {
background: #d4edda;
border-color: #c3e6cb;
color: #155724;
}

/* 登录链接样式 */
.login-link {
text-align: center;
}



/* Further adjustments for very small screens */
@media (max-width: 576px) {
  body {
    padding: 1rem; /* 使用 rem 单位 */
  }
  .container {
    max-width: 100%;
    margin: 0 auto;
    padding: 0 1rem;
  }
  .themes-grid {
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  }
  .pagination a {
    min-width: 32px;
    height: 32px;
    padding: 8px;
    font-size: 1rem;
  }
  .pagination .prev,
  .pagination .next {
    min-width: 60px;
  }
  .content h1 {
    font-size: 1.6rem;
  }
}
/*--- END OF FILE admin/admin.css ---*/