:root {
    --primary-color: #6f42c1;
    /*--secondary-color: #e83e8c;*/
    --light-color: #f8f9fa;
    --dark-color: #343a40;
}

.content-area {
    background-color: white;
    border-radius: 8px;
    box-shadow: 0 0 15px rgba(0,0,0,0.05);
    /*padding: 30px;*/
}

.content-area h1 {
    color: var(--primary-color);
    margin-bottom: 20px;
    padding-bottom: 10px;
    border-bottom: 2px solid #e9ecef;
}

.content-area h2 {
    color: var(--primary-color);
    margin-top: 30px;
    margin-bottom: 15px;
}

.content-area h3 {
    color: var(--dark-color);
    margin-top: 25px;
}

.content-area p {
    color: #6c757d;
}

.content-area .card {
    margin-bottom: 20px;
    border: none;
    box-shadow: 0 4px 6px rgba(0,0,0,0.1);
    transition: transform 0.3s;
}

.content-area .card:hover {
    transform: translateY(-5px);
}

.content-area .card-header {
    background-color: var(--primary-color);
    color: white;
    font-weight: bold;
}

.feature-list li {
    margin-bottom: 10px;
    padding-left: 10px;
}

.feature-list li i {
    color: var(--primary-color);
    margin-right: 8px;
}

.code-example {
    background-color: #f8f9fa;
    border-left: 4px solid var(--primary-color);
    padding: 15px;
    margin: 20px 0;
    border-radius: 0 5px 5px 0;
    font-family: 'Courier New', monospace;
    overflow-x: auto;
}


.hero-section {
    background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
    color: white;
    padding: 40px 0;
    border-radius: 8px;
    margin-bottom: 30px;
    text-align: center;
}

.hero-section h1 {
    color: white;
    border: none;
}

.example-container {
    background-color: #f8f9fa;
    padding: 20px;
    border-radius: 5px;
    margin: 20px 0;
}

.example-title {
    font-weight: bold;
    margin-bottom: 10px;
    color: var(--primary-color);
}

.form-example {
    background-color: white;
    padding: 20px;
    border-radius: 5px;
    border: 1px solid #e9ecef;
}

.method-card {
    border-left: 4px solid var(--primary-color);
    transition: all 0.3s;
}

.method-card:hover {
    border-left-color: var(--secondary-color);
}

/* 自定义表单控件样式 */
.custom-control-input:checked ~ .custom-control-label::before {
    border-color: var(--primary-color);
    background-color: var(--primary-color);
}

.custom-switch .custom-control-input:checked ~ .custom-control-label::before {
    background-color: var(--primary-color);
}

.custom-range::-webkit-slider-thumb {
    background: var(--primary-color);
}

.custom-range::-moz-range-thumb {
    background: var(--primary-color);
}

.custom-range::-ms-thumb {
    background: var(--primary-color);
}

.custom-file-input:focus ~ .custom-file-label {
    border-color: var(--primary-color);
    box-shadow: 0 0 0 0.2rem rgba(111, 66, 193, 0.25);
}

.custom-file-input:focus ~ .custom-file-label::after {
    border-color: var(--primary-color);
}

.custom-select:focus {
    border-color: var(--primary-color);
    box-shadow: 0 0 0 0.2rem rgba(111, 66, 193, 0.25);
}

/* 高级自定义样式 */
.custom-checkbox-lg .custom-control-label::before,
.custom-checkbox-lg .custom-control-label::after {
    top: 0.2rem;
    width: 1.5rem;
    height: 1.5rem;
}

.custom-checkbox-lg .custom-control-label {
    padding-left: 0.5rem;
    line-height: 1.7;
}

.custom-radio-outline .custom-control-input:checked ~ .custom-control-label::before {
    background-color: transparent;
    border-width: 2px;
}

.custom-radio-outline .custom-control-input:checked ~ .custom-control-label::after {
    background-image: none;
    background-color: var(--primary-color);
    border-radius: 50%;
    transform: scale(0.5);
}

.custom-switch-lg .custom-control-label::before {
    width: 3rem;
    height: 1.5rem;
    border-radius: 1rem;
}

.custom-switch-lg .custom-control-label::after {
    width: calc(1.5rem - 4px);
    height: calc(1.5rem - 4px);
}

.custom-switch-lg .custom-control-input:checked ~ .custom-control-label::after {
    transform: translateX(1.5rem);
}
