body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, 'Open Sans', 'Helvetica Neue', sans-serif;
    margin: 0;
    padding: 0;
    background-color: #f5f5f7;
    color: #333;
}

a {
    color: #f38020;
    text-decoration: none;
}

a:hover {
    text-decoration: underline;
}

button, input[type="submit"] {
    background-color: #f38020;
    color: white;
    border: none;
    border-radius: 4px;
    padding: 8px 16px;
    cursor: pointer;
    font-size: 14px;
    transition: background-color 0.2s;
}

button:hover, input[type="submit"]:hover {
    background-color: #cf6a13;
}

button:disabled, input[type="submit"]:disabled {
    background-color: #ccc;
    cursor: not-allowed;
}

button.secondary {
    background-color: #6c757d;
}

button.secondary:hover {
    background-color: #5a6268;
}

button.danger {
    background-color: #dc3545;
}

button.danger:hover {
    background-color: #bd2130;
}

/* 布局样式 */
.layout {
    display: flex;
    min-height: 100vh;
}

/* 侧边栏样式 */
.sidebar {
    width: 250px;
    background-color: #1d1d1f;
    color: white;
    display: flex;
    flex-direction: column;
}

.logo {
    padding: 20px;
    display: flex;
    align-items: center;
    gap: 10px;
    border-bottom: 1px solid #2d2d2f;
}

.logo h1 {
    font-size: 18px;
    margin: 0;
}

.sidebar nav {
    flex: 1;
}

.sidebar nav ul {
    list-style: none;
    padding: 0;
    margin: 0;
}

.sidebar nav ul li a {
    display: block;
    padding: 12px 20px;
    color: #a1a1a6;
    text-decoration: none;
    transition: background-color 0.2s, color 0.2s;
}

.sidebar nav ul li a:hover {
    background-color: #2d2d2f;
    color: white;
}

.sidebar nav ul li.active a {
    background-color: #f38020;
    color: white;
}

.sidebar nav ul li a.disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

.sidebar nav ul li a.disabled:hover {
    background-color: transparent;
}

.sidebar-footer {
    padding: 20px;
    font-size: 12px;
    color: #a1a1a6;
    border-top: 1px solid #2d2d2f;
}

/* 内容区域样式 */
.content {
    flex: 1;
    overflow-y: auto;
    padding: 20px;
}

section {
    display: none;
}

section.active {
    display: block;
}

header {
    margin-bottom: 20px;
}

header h2 {
    margin: 0;
    color: #1d1d1f;
}

.content-section {
    display: none;
}

.content-section.active {
    display: block;
}

/* 卡片样式 */
.card {
    background-color: white;
    border-radius: 8px;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
    padding: 20px;
    margin-bottom: 20px;
}

/* 表单样式 */
.form-group {
    margin-bottom: 15px;
}

.form-group label {
    display: block;
    margin-bottom: 5px;
    font-weight: 500;
}

.form-group input[type="text"],
.form-group input[type="password"],
.form-group input[type="number"],
.form-group select,
.form-group textarea {
    width: 100%;
    padding: 8px;
    border: 1px solid #ccc;
    border-radius: 4px;
    box-sizing: border-box;
}

.form-group textarea {
    min-height: 80px;
    resize: vertical;
}

.form-group input[type="checkbox"] {
    margin-right: 8px;
}

/* 表格样式 */
table {
    width: 100%;
    border-collapse: collapse;
    margin-top: 10px;
}

thead tr {
    background-color: #f8f9fa;
}

th, td {
    text-align: left;
    padding: 8px 12px;
    border-bottom: 1px solid #dee2e6;
}

th {
    font-weight: 600;
}

/* 警告卡片样式 */
.alert-card {
    display: flex;
    border-left: 4px solid #f38020;
    background-color: #fff8f2;
}

.alert-card.danger {
    border-left-color: #dc3545;
    background-color: #fff0f0;
}

.alert-icon {
    margin-right: 15px;
    color: #f38020;
}

.alert-card.danger .alert-icon {
    color: #dc3545;
}

.alert-content h3 {
    margin-top: 0;
    margin-bottom: 5px;
}

.alert-content p {
    margin: 0;
}

/* 加载动画 */
.spinner {
    width: 40px;
    height: 40px;
    margin: 20px auto;
    border: 3px solid rgba(0, 0, 0, 0.1);
    border-radius: 50%;
    border-top-color: #f38020;
    animation: spin 1s ease-in-out infinite;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

/* 状态指示器 */
.status-badge {
    display: inline-block;
    padding: 2px 8px;
    border-radius: 12px;
    font-size: 12px;
    background-color: #6c757d;
    color: white;
}

.status-badge.success {
    background-color: #28a745;
}

.status-badge.warning {
    background-color: #ffc107;
    color: #212529;
}

.status-badge.danger {
    background-color: #dc3545;
}

.status-badge.info {
    background-color: #17a2b8;
}

/* 工具提示 */
.tooltip {
    position: relative;
    display: inline-block;
    cursor: pointer;
}

.tooltip .tooltip-content {
    visibility: hidden;
    width: 200px;
    background-color: #555;
    color: #fff;
    text-align: center;
    border-radius: 6px;
    padding: 5px;
    position: absolute;
    z-index: 1;
    bottom: 125%;
    left: 50%;
    margin-left: -100px;
    opacity: 0;
    transition: opacity 0.3s;
}

.tooltip:hover .tooltip-content {
    visibility: visible;
    opacity: 1;
}

/* 域名信息卡片 */
.domain-info-card {
    border-left: 4px solid #28a745;
}

.domain-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 10px;
}

.domain-header p {
    font-size: 18px;
    font-weight: 600;
    margin: 0;
}

.domain-status {
    margin-top: 5px;
    font-size: 14px;
}

/* 系统配置卡片 */
.system-config-card {
    border-left: 4px solid #17a2b8;
}

.system-config-status {
    display: flex;
    flex-direction: column;
    gap: 10px;
    margin-bottom: 15px;
}

.config-item {
    display: flex;
    align-items: center;
    gap: 10px;
}

.config-label {
    min-width: 100px;
    font-weight: 500;
}

.config-value {
    color: #555;
}

.config-note {
    font-size: 14px;
    color: #6c757d;
    margin-top: 10px;
    padding-top: 10px;
    border-top: 1px solid #eee;
}

/* 占位符样式 - 用于开发中功能 */
.placeholder-container {
    text-align: center;
    padding: 40px 20px;
    color: #6c757d;
}

.placeholder-container svg {
    margin-bottom: 15px;
    opacity: 0.5;
}

.placeholder-container h3 {
    margin-top: 0;
}

.placeholder-buttons {
    display: flex;
    justify-content: center;
    gap: 10px;
    margin-top: 20px;
}

.placeholder-form {
    opacity: 0.7;
}

.form-group.disabled label {
    color: #6c757d;
}

/* 响应式设计 */
@media (max-width: 768px) {
    .layout {
        flex-direction: column;
    }
    
    .sidebar {
        width: 100%;
        height: auto;
    }
    
    .content {
        padding: 15px;
    }
    
    .domain-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 10px;
    }
    
    table {
        display: block;
        overflow-x: auto;
    }

    .config-item {
        flex-direction: column;
        align-items: flex-start;
        gap: 5px;
    }
}

/* 域名选择器样式 */
.domain-selector-card {
    position: relative;
    border-left: 4px solid #5c6bc0;
    margin-bottom: 20px;
}

.domain-selector-container {
    display: flex;
    align-items: center;
    padding: 10px 15px;
}

.domain-selector {
    flex: 1;
    padding: 8px 12px;
    border: 1px solid #d1d5db;
    border-radius: 4px;
    font-size: 14px;
    margin-right: 10px;
    background-color: #f9fafb;
}

.domain-selection {
    background-color: #f0f2f5;
    padding: 12px 15px;
    border-radius: 4px;
    margin-top: 10px;
    border-left: 3px solid #5c6bc0;
}

.switch-domain-btn {
    margin-left: 10px;
}

/* DNS目标域名选择器 */
.target-domain-selector {
    margin-bottom: 15px;
}

.target-domain-selector select {
    width: 100%;
    padding: 8px 12px;
    border: 1px solid #d1d5db;
    border-radius: 4px;
    background-color: #f9fafb;
}

/* 临时邮件功能样式 */
.features-list {
    display: flex;
    flex-wrap: wrap;
    gap: 20px;
    margin-top: 20px;
}

.feature-item {
    display: flex;
    align-items: center;
    gap: 10px;
    background-color: #f9fafb;
    padding: 12px 15px;
    border-radius: 6px;
    flex: 1;
    min-width: 200px;
}

.feature-item svg {
    color: #f38020;
}

.mailbox-input-group {
    display: flex;
    align-items: center;
}

.mailbox-input-group input {
    flex: 1;
    border-radius: 4px 0 0 4px;
    border-right: none;
}

.input-separator {
    background-color: #e9ecef;
    border: 1px solid #ccc;
    border-left: none;
    border-right: none;
    padding: 8px 5px;
    color: #495057;
}

.mailbox-input-group select {
    min-width: 150px;
    border-radius: 0 4px 4px 0;
}

/* 邮件查看样式 */
.mailview-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.mailview-container {
    display: flex;
    height: 500px;
    border: 1px solid #dee2e6;
    border-radius: 4px;
    overflow: hidden;
}

.mail-list {
    width: 30%;
    border-right: 1px solid #dee2e6;
    overflow-y: auto;
    background-color: #f8f9fa;
}

.mail-item {
    padding: 12px 15px;
    border-bottom: 1px solid #dee2e6;
    cursor: pointer;
    transition: background-color 0.2s;
}

.mail-item:hover {
    background-color: #e9ecef;
}

.mail-item.selected {
    background-color: #e2e6ea;
    border-left: 3px solid #f38020;
}

.mail-item.unread {
    font-weight: 600;
}

.mail-item-header {
    display: flex;
    justify-content: space-between;
    margin-bottom: 5px;
}

.mail-item-subject {
    font-weight: 500;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.mail-item-time {
    font-size: 12px;
    color: #6c757d;
}

.mail-item-from {
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    font-size: 13px;
    color: #6c757d;
}

.mail-content {
    flex: 1;
    padding: 20px;
    overflow-y: auto;
}

.mail-header {
    margin-bottom: 20px;
    padding-bottom: 15px;
    border-bottom: 1px solid #dee2e6;
}

.mail-header h4 {
    margin-top: 0;
    margin-bottom: 10px;
}

.mail-meta {
    color: #6c757d;
    font-size: 14px;
}

.mail-body {
    line-height: 1.6;
}

.mail-attachments {
    margin-top: 20px;
    padding-top: 15px;
    border-top: 1px solid #dee2e6;
}

.mail-attachments h5 {
    margin-top: 0;
    margin-bottom: 10px;
}

.attachment-item {
    display: flex;
    align-items: center;
    background-color: #f8f9fa;
    padding: 8px 12px;
    border-radius: 4px;
    margin-bottom: 8px;
}

.attachment-item svg {
    margin-right: 10px;
    color: #6c757d;
}

.attachment-item-info {
    flex: 1;
}

.attachment-item-name {
    display: block;
    font-weight: 500;
}

.attachment-item-size {
    font-size: 12px;
    color: #6c757d;
}

.attachment-download {
    color: #f38020;
    margin-left: 10px;
}

/* 响应式调整 */
@media (max-width: 768px) {
    .mailview-container {
        flex-direction: column;
        height: auto;
    }
    
    .mail-list {
        width: 100%;
        height: 250px;
    }
    
    .mail-content {
        max-height: 400px;
    }
    
    .features-list {
        flex-direction: column;
    }
} 