:root {
    --primary-color: #007bff;
    --secondary-color: #6c757d;
    --dark-color: #333;
    --light-color: #fff;
    --gray-color: #666;
    --light-gray: #f8f9fa;
    --border-color: #ddd;
    --border-light: #e9ecef;
    --shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    --shadow-lg: 0 5px 15px rgba(0, 0, 0, 0.1);
}

body.dark-mode {
    --primary-color: #4a90e2;
    --secondary-color: #7f8c8d;
    --dark-color: #ecf0f1;
    --light-color: #2c3e50;
    --gray-color: #bdc3c7;
    --light-gray: #34495e;
    --border-color: #4a5568;
    --border-light: #4a5568;
    --shadow: 0 2px 10px rgba(0, 0, 0, 0.3);
    --shadow-lg: 0 5px 15px rgba(0, 0, 0, 0.3);
}

.crontab-section {
    padding: 40px 0;
}

.crontab-header {
    text-align: center;
    margin-bottom: 40px;
}

.crontab-title {
    font-size: 2.5rem;
    font-weight: 700;
    color: var(--dark-color);
    margin-bottom: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.crontab-title i {
    margin-right: 15px;
    color: var(--primary-color);
}

.crontab-subtitle {
    font-size: 1.2rem;
    color: var(--gray-color);
    margin-bottom: 20px;
}

.crontab-badge {
    display: flex;
    justify-content: center;
    gap: 10px;
    flex-wrap: wrap;
}

.badge-item {
    background-color: var(--light-gray);
    color: var(--dark-color);
    padding: 5px 15px;
    border-radius: 20px;
    font-size: 0.9rem;
    font-weight: 500;
}

.crontab-main {
    background-color: var(--light-color);
    border-radius: 10px;
    box-shadow: var(--shadow);
    padding: 30px;
    margin-bottom: 40px;
}

.input-section {
    margin-bottom: 30px;
}

.section-title {
    font-size: 1.5rem;
    font-weight: 600;
    color: var(--dark-color);
    margin-bottom: 20px;
    display: flex;
    align-items: center;
}

.section-title i {
    margin-right: 10px;
    color: var(--primary-color);
}

.cron-fields {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 20px;
    margin-bottom: 30px;
}

.cron-field {
    margin-bottom: 20px;
}

.cron-field label {
    display: block;
    margin-bottom: 8px;
    font-weight: 500;
    color: var(--gray-color);
}

.form-control {
    width: 100%;
    padding: 12px;
    border: 1px solid var(--border-color);
    border-radius: 6px;
    font-size: 1rem;
    background-color: var(--light-color);
    color: var(--dark-color);
    transition: border-color 0.3s ease;
}

.form-control:focus {
    border-color: var(--primary-color);
    box-shadow: 0 0 0 0.2rem rgba(74, 144, 226, 0.25);
    outline: none;
}

.command-section {
    margin-bottom: 30px;
}

.command-section label {
    display: block;
    margin-bottom: 8px;
    font-weight: 500;
    color: var(--gray-color);
    display: flex;
    align-items: center;
}

.command-section label i {
    margin-right: 8px;
    color: var(--primary-color);
}

.btn {
    padding: 10px 20px;
    border: none;
    border-radius: 6px;
    font-size: 1rem;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.3s ease;
}

.btn-primary {
    background-color: var(--primary-color);
    color: #fff;
}

.btn-primary:hover {
    background-color: #0069d9;
    transform: translateY(-2px);
}

.btn-secondary {
    background-color: var(--secondary-color);
    color: #fff;
}

.btn-secondary:hover {
    background-color: #5a6268;
    transform: translateY(-2px);
}

.action-buttons {
    display: flex;
    gap: 15px;
    margin-top: 20px;
}

.presets-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 20px;
}

.preset-card {
    background-color: var(--light-gray);
    border-radius: 8px;
    padding: 20px;
    text-align: center;
    cursor: pointer;
    transition: all 0.3s ease;
}

.preset-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-lg);
}

.preset-icon {
    font-size: 2rem;
    margin-bottom: 10px;
    color: var(--primary-color);
}

.preset-title {
    font-weight: 600;
    color: var(--dark-color);
    margin-bottom: 5px;
}

.preset-desc {
    font-size: 0.9rem;
    color: var(--gray-color);
    font-family: monospace;
}

.crontab-results {
    margin-top: 30px;
}

.result-header {
    margin-bottom: 20px;
}

.result-card {
    background-color: var(--light-gray);
    border-radius: 8px;
    padding: 20px;
    margin-bottom: 20px;
    display: flex;
    align-items: center;
    gap: 20px;
}

.result-icon {
    width: 60px;
    height: 60px;
    background-color: var(--primary-color);
    color: #fff;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
}

.result-content {
    flex: 1;
}

.result-title {
    font-size: 1.2rem;
    font-weight: 600;
    color: var(--dark-color);
    margin-bottom: 5px;
}

.result-value {
    font-size: 1.2rem;
    font-weight: 500;
    color: var(--primary-color);
    font-family: monospace;
    background-color: var(--light-color);
    padding: 10px;
    border-radius: 4px;
    border: 1px solid var(--border-light);
}

.quick-actions {
    margin-bottom: 20px;
}

.details-title {
    font-size: 1.2rem;
    font-weight: 600;
    color: var(--dark-color);
    margin-bottom: 15px;
    display: flex;
    align-items: center;
}

.details-title i {
    margin-right: 10px;
    color: var(--primary-color);
}

.action-buttons-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
    gap: 10px;
}

.btn-sm {
    padding: 8px 16px;
    font-size: 0.9rem;
}

.btn-outline {
    background-color: transparent;
    border: 1px solid var(--primary-color);
    color: var(--primary-color);
}

.btn-outline:hover {
    background-color: var(--primary-color);
    color: #fff;
}

.history-section {
    background-color: var(--light-gray);
    border-radius: 8px;
    padding: 20px;
}

.history-list {
    max-height: 300px;
    overflow-y: auto;
}

.no-history {
    text-align: center;
    color: var(--gray-color);
    padding: 20px 0;
}

.history-item {
    background-color: var(--light-color);
    border-radius: 6px;
    padding: 15px;
    margin-bottom: 10px;
    box-shadow: var(--shadow);
}

.history-item-header {
    display: flex;
    justify-content: space-between;
    margin-bottom: 10px;
    border-bottom: 1px solid var(--border-light);
    padding-bottom: 10px;
}

.history-item-expression {
    font-weight: 600;
    color: var(--dark-color);
    font-family: monospace;
}

.history-item-time {
    font-size: 0.8rem;
    color: var(--gray-color);
}

.history-item-command {
    font-size: 0.9rem;
    color: var(--gray-color);
    font-family: monospace;
    word-break: break-all;
}

.crontab-info {
    background-color: var(--light-gray);
    border-radius: 10px;
    padding: 30px;
    margin-bottom: 40px;
}

.info-section {
    margin-bottom: 20px;
}

.info-section:last-child {
    margin-bottom: 0;
}

.info-title {
    font-size: 1.2rem;
    font-weight: 600;
    color: var(--dark-color);
    margin-bottom: 15px;
    display: flex;
    align-items: center;
}

.info-title i {
    margin-right: 10px;
    color: var(--primary-color);
}

.info-list {
    list-style: none;
    padding: 0;
    margin: 0;
}

.info-list li {
    padding: 8px 0;
    color: var(--gray-color);
    position: relative;
    padding-left: 20px;
}

.info-list li:before {
    content: "•";
    position: absolute;
    left: 0;
    color: var(--primary-color);
    font-weight: bold;
}

.crontab-syntax {
    background-color: var(--light-color);
    border-radius: 6px;
    padding: 15px;
}

.syntax-item {
    padding: 10px 0;
    color: var(--gray-color);
    border-bottom: 1px solid var(--border-light);
}

.syntax-item:last-child {
    border-bottom: none;
}

/* 响应式设计 */
@media (max-width: 768px) {
    .cron-fields {
        grid-template-columns: 1fr;
    }

    .action-buttons {
        flex-direction: column;
    }

    .btn {
        width: 100%;
    }

    .result-card {
        flex-direction: column;
        text-align: center;
    }

    .presets-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}