@import url(https://fonts.googleapis.com/css?family=Righteous);

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Microsoft YaHei', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    background:
        radial-gradient(at 50% 0, transparent, #080808),
        repeating-conic-gradient(
            hsla(0, 0%, 0%, .235) 0% 25%,
            transparent 0% 50%
        ) 0 0 / 0.375em 0.375em,
        #3b3b3b;
    min-height: 100vh;
    padding: 20px;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    position: relative;
    display: flex;
    flex-direction: column;
    align-items: center;
}

/* 移除网格线背景 wrapper，不再需要 */
#background-wrapper {
    display: none;
}

.page-container {
    max-width: 1200px;
    margin: 0 auto;
    width: 100%;
    position: relative;
    z-index: 2;
    flex: 1;
}

.back-btn {
    display: inline-block;
    margin-bottom: 1.5rem;
    color: hsl(0 0% 85%);
    text-decoration: none;
    transition: color 0.3s ease;
    font-size: 1rem;
}

.back-btn:hover {
    color: hsl(0 0% 100%);
}

/* 标题区域 */
.header {
    text-align: center;
    margin-bottom: 2rem;
}

.header h1 {
    display: inline-block;
    color: hsl(0 0% 90%);
    font-family: 'Righteous', 'Microsoft YaHei', serif;
    font-size: 3.5em;
    text-shadow: .03em .03em 0 hsla(230,40%,50%,1);
    position: relative;
    line-height: 1.2;
    margin-bottom: 1rem;
}

.header h1::after {
    content: attr(data-shadow);
    position: absolute;
    top: .06em;
    left: .06em;
    width: 100%;
    height: 100%;
    z-index: -1;
    text-shadow: none;
    background-image: linear-gradient(
        45deg,
        transparent 45%,
        hsla(48,20%,90%,1) 45%,
        hsla(48,20%,90%,1) 55%,
        transparent 0
    );
    background-size: .05em .05em;
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    display: flex;
    justify-content: center;
    align-items: center;
    white-space: nowrap;
    animation: shad-anim 60s linear infinite;
}

@keyframes shad-anim {
    0% { background-position: 0 0; }
    100% { background-position: 100% -100%; }
}

.subtitle {
    font-size: 1rem;
    color: hsl(0 0% 75%);
    margin-top: 0.5rem;
}

/* 容器 */
.container {
    background: rgba(255, 255, 255, 0.03);
    backdrop-filter: blur(20px) saturate(1.2);
    border-radius: 16px;
    border: 1px solid rgba(255, 255, 255, 0.1);
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.3);
    overflow: hidden;
}

/* 区块样式 */
.section {
    padding: 2rem;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.section:last-child {
    border-bottom: none;
}

.section h2 {
    color: hsl(0 0% 95%);
    font-size: 1.3rem;
    margin-bottom: 1.5rem;
    font-weight: 600;
    display: flex;
    align-items: center;
}

.section h2::before {
    content: '';
    display: inline-block;
    width: 4px;
    height: 20px;
    background: hsl(0 0% 80%);
    margin-right: 10px;
    border-radius: 2px;
}

.section h3 {
    color: hsl(0 0% 90%);
    font-size: 1.1rem;
    margin-bottom: 1rem;
    font-weight: 600;
}

/* 上传区域 */
.upload-area {
    display: flex;
    flex-direction: column;
    gap: 20px;
    margin-bottom: 20px;
}

.file-upload {
    text-align: center;
}

.file-upload-area {
    border: 3px dashed rgba(255, 255, 255, 0.2);
    border-radius: 12px;
    padding: 40px 20px;
    text-align: center;
    cursor: pointer;
    transition: all 0.3s;
    background: rgba(255, 255, 255, 0.03);
}

.file-upload-area:hover {
    border-color: rgba(255, 255, 255, 0.4);
    background: rgba(255, 255, 255, 0.05);
}

.file-upload-area.drag-over {
    border-color: rgba(255, 255, 255, 0.5);
    background: rgba(255, 255, 255, 0.08);
    transform: scale(1.02);
}

.upload-icon {
    font-size: 3rem;
    margin-bottom: 15px;
}

.upload-text {
    font-size: 1.1rem;
    color: hsl(0 0% 90%);
    margin-bottom: 8px;
    font-weight: 600;
}

.upload-hint {
    font-size: 0.9rem;
    color: hsl(0 0% 70%);
}

.file-name {
    display: block;
    margin-top: 15px;
    color: hsl(122 40% 70%);
    font-weight: 600;
    font-size: 0.95rem;
}
}

#encodingSelect {
    padding: 8px 12px;
    border: 1px solid rgba(255, 255, 255, 0.15);
    border-radius: 8px;
    background: rgba(255, 255, 255, 0.05);
    color: hsl(0 0% 90%);
    font-size: 0.9rem;
    cursor: pointer;
}

#encodingSelect option {
    background: #2a2a2a;
    color: white;
}

/* CSV编码格式 label 样式增强 */
.file-upload label {
    color: hsl(0 0% 90%);
    font-weight: 500;
}

.divider {
    text-align: center;
    color: hsl(0 0% 70%);
    position: relative;
    font-size: 0.9rem;
}

.divider::before,
.divider::after {
    content: '';
    position: absolute;
    top: 50%;
    width: 40%;
    height: 1px;
    background: rgba(255, 255, 255, 0.2);
}

.divider::before {
    left: 0;
}

.divider::after {
    right: 0;
}

.text-input textarea {
    width: 100%;
    min-height: 150px;
    padding: 15px;
    border: 1px solid rgba(255, 255, 255, 0.15);
    border-radius: 12px;
    font-size: 1rem;
    font-family: 'Consolas', 'Monaco', 'Courier New', monospace;
    resize: vertical;
    transition: all 0.3s;
    background: rgba(255, 255, 255, 0.05);
    color: hsl(0 0% 95%);
    backdrop-filter: blur(10px);
}

.text-input textarea::placeholder {
    color: hsl(0 0% 60%);
}

.text-input textarea:focus {
    outline: none;
    border-color: rgba(255, 255, 255, 0.3);
    box-shadow: 0 0 0 3px rgba(255, 255, 255, 0.1);
    background: rgba(255, 255, 255, 0.08);
}

/* 按钮样式 */
.btn {
    -webkit-tap-highlight-color: #0000;
    cursor: pointer;
    border-radius: 12px;
    padding: 12px 30px;
    font-size: 1rem;
    background: #0000;
    border: 1px solid #0000;
    position: relative;
    color: white;
    transition-property: translate, scale;
    transition-duration: 0.1s;
    transition-timing-function: ease-out;
    display: inline-block;
    font-weight: 500;
}

.btn:disabled {
    opacity: 0.6;
    cursor: not-allowed;
}

.btn:active:not(:disabled) {
    scale: 0.98;
    translate: 0 1px;
}

.btn::before,
.btn::after {
    content: '';
    position: absolute;
    inset: -1px;
    border-radius: inherit;
    pointer-events: none;
}

.btn::before {
    z-index: -1;
    background: linear-gradient(
        hsl(0 0% 100% / 0.18),
        hsl(0 0% 4% / 0.7)
    );
    backdrop-filter: saturate(2) contrast(1) blur(10px);
}

.btn::after {
    box-shadow: 0 0 1px 0.8px hsl(0 0% 100% / 0.8) inset;
    mask: linear-gradient(-35deg, #ffffff80, #ffffff30 30% 60%, #fff);
}

.btn:hover:not(:disabled) {
    scale: 1.02;
}

.btn-primary, .btn-success, .btn-secondary {
    /* 使用相同的毛玻璃效果 */
}

/* 单选选项 */
.logic-type {
    background: rgba(255, 255, 255, 0.03);
    backdrop-filter: blur(10px);
    padding: 15px;
    border-radius: 12px;
    margin-bottom: 20px;
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.logic-type > label:first-child {
    display: block;
    font-weight: 500;
    color: hsl(0 0% 90%);
    margin-bottom: 10px;
}

.radio-option {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 12px;
    border: 1px solid rgba(255, 255, 255, 0.15);
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.3s;
    color: hsl(0 0% 85%);
    user-select: none;
    margin-bottom: 10px;
}

.radio-option:hover {
    border-color: rgba(255, 255, 255, 0.3);
    background: rgba(255, 255, 255, 0.05);
}

.radio-option input[type="radio"] {
    width: 18px;
    height: 18px;
    cursor: pointer;
    accent-color: hsl(0 0% 80%);
}

.radio-option input[type="text"] {
    padding: 8px;
    border: 1px solid rgba(255, 255, 255, 0.15);
    border-radius: 5px;
    font-size: 0.9rem;
    width: 200px;
    background: rgba(255, 255, 255, 0.05);
    color: hsl(0 0% 95%);
}

.radio-option input[type="text"]:focus {
    outline: none;
    border-color: rgba(255, 255, 255, 0.3);
}

/* 表格预览 */
.table-preview {
    margin-top: 20px;
}

.table-info {
    background: rgba(255, 255, 255, 0.03);
    padding: 15px;
    border-radius: 12px;
    margin-bottom: 15px;
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.table-info p {
    margin: 8px 0;
    color: hsl(0 0% 85%);
}

.table-info label {
    color: hsl(0 0% 90%);
    font-weight: 500;
}

.column-tag {
    display: inline-block;
    background: rgba(255, 255, 255, 0.15);
    color: hsl(0 0% 95%);
    padding: 4px 10px;
    border-radius: 15px;
    font-size: 0.85rem;
    margin: 3px;
}

.table-wrapper {
    overflow-x: auto;
    margin: 15px 0;
    border-radius: 12px;
    background: rgba(0, 0, 0, 0.3);
}

.data-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 0.9rem;
}

.data-table thead {
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(10px);
}

.data-table th {
    padding: 12px;
    text-align: left;
    font-weight: 500;
    color: hsl(0 0% 95%);
    white-space: nowrap;
    border-bottom: 2px solid rgba(255, 255, 255, 0.2);
}

.data-table td {
    padding: 10px 12px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    color: hsl(0 0% 85%);
}

.data-table tbody tr:hover {
    background: rgba(255, 255, 255, 0.05);
}

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

.preview-note {
    color: hsl(0 0% 70%);
    font-size: 0.85rem;
    text-align: center;
    margin-top: 10px;
}

/* 搜索条件 */
.search-config {
    margin-bottom: 20px;
}

.search-conditions {
    margin: 15px 0;
}

.condition-item {
    margin-bottom: 15px;
}

.condition-row {
    display: flex;
    gap: 10px;
    align-items: center;
    padding: 15px;
    background: rgba(255, 255, 255, 0.03);
    border-radius: 12px;
    border: 1px solid rgba(255, 255, 255, 0.1);
    transition: border-color 0.3s;
}

.condition-row:hover {
    border-color: rgba(255, 255, 255, 0.2);
}

.column-select,
.keyword-input {
    padding: 10px;
    border: 1px solid rgba(255, 255, 255, 0.15);
    border-radius: 8px;
    font-size: 0.95rem;
    background: rgba(255, 255, 255, 0.05);
    color: hsl(0 0% 95%);
    cursor: pointer;
}

.column-select {
    flex: 1;
}

.keyword-input {
    flex: 2;
}

.column-select option {
    background: #2a2a2a;
    color: white;
}

.column-select:focus,
.keyword-input:focus {
    outline: none;
    border-color: rgba(255, 255, 255, 0.3);
    background: rgba(255, 255, 255, 0.08);
}

.btn-remove {
    padding: 8px 12px;
    background: rgba(244, 67, 54, 0.8);
    color: white;
    border: none;
    border-radius: 8px;
    cursor: pointer;
    font-size: 1.2rem;
    transition: all 0.3s;
}

.btn-remove:hover {
    background: rgba(244, 67, 54, 1);
}

/* 搜索结果 */
.search-results {
    margin-top: 20px;
}

.result-header {
    padding: 15px;
    background: rgba(255, 255, 255, 0.05);
    border-radius: 12px;
    margin-bottom: 15px;
    font-weight: 500;
    color: hsl(0 0% 90%);
}

.result-header.success {
    background: rgba(76, 175, 80, 0.15);
    color: hsl(122 40% 75%);
    border: 1px solid rgba(76, 175, 80, 0.3);
}

.result-header.error {
    background: rgba(244, 67, 54, 0.15);
    color: hsl(4 80% 75%);
    border: 1px solid rgba(244, 67, 54, 0.3);
}

.result-item {
    padding: 15px;
    margin: 10px 0;
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 12px;
    backdrop-filter: blur(10px);
}

.result-item-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 10px;
    color: hsl(0 0% 90%);
    font-weight: 500;
}

.result-item-content {
    color: hsl(0 0% 85%);
    line-height: 1.6;
    word-wrap: break-word;
}

.highlight {
    background: rgba(255, 193, 7, 0.3);
    padding: 2px 4px;
    border-radius: 3px;
    font-weight: 500;
    color: hsl(45 100% 80%);
}

/* 关键词分组 */
.keyword-group {
    margin: 20px 0;
    padding: 15px;
    background: rgba(255, 255, 255, 0.03);
    border-radius: 12px;
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.keyword-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 12px 15px;
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(10px);
    color: hsl(0 0% 95%);
    border-radius: 10px;
    margin-bottom: 15px;
    font-weight: 500;
}

.keyword-header.not-found {
    background: rgba(244, 67, 54, 0.2);
}

.keyword-text {
    font-size: 1rem;
}

.keyword-count {
    background: rgba(255, 255, 255, 0.2);
    padding: 4px 12px;
    border-radius: 20px;
    font-size: 0.85rem;
}

.keyword-group .result-item {
    margin-left: 0;
}

/* 导出区域 */
.export-area {
    margin-top: 20px;
    padding: 20px;
    background: rgba(76, 175, 80, 0.1);
    border-radius: 12px;
    border: 1px solid rgba(76, 175, 80, 0.3);
}

.export-area h3 {
    color: hsl(122 40% 75%);
    margin-bottom: 15px;
    font-size: 1.1rem;
}

.export-buttons {
    display: flex;
    gap: 15px;
}

/* 响应式设计 */
@media screen and (max-width: 768px) {
    body {
        padding: 10px;
    }

    .header h1 {
        font-size: 2.5em;
    }

    .section {
        padding: 1.5rem;
    }

    .condition-row {
        flex-direction: column;
        align-items: stretch;
    }

    .export-buttons {
        flex-direction: column;
    }

    .data-table {
        font-size: 0.8rem;
    }

    .data-table th,
    .data-table td {
        padding: 8px;
    }

    .column-tag {
        font-size: 0.75rem;
        padding: 3px 8px;
    }
}

@media screen and (max-width: 480px) {
    .header h1 {
        font-size: 2em;
    }

    .section {
        padding: 1rem;
    }

    .btn {
        width: 100%;
    }

    .file-label {
        width: 100%;
    }

    .data-table {
        font-size: 0.75rem;
    }

    .data-table th,
    .data-table td {
        padding: 6px;
    }
}

/* 滚动条样式 */
::-webkit-scrollbar {
    width: 8px;
    height: 8px;
}

::-webkit-scrollbar-track {
    background: rgba(255, 255, 255, 0.05);
    border-radius: 4px;
}

::-webkit-scrollbar-thumb {
    background: rgba(255, 255, 255, 0.2);
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: rgba(255, 255, 255, 0.3);
}

/* ===== 日间模式样式 ===== */
body.day-mode {
    background: #f0f4f8;
    background-image: url(../../../../assets/image/day-background.png);
    background-size: auto;
    background-repeat: repeat;
    font-family: 'Microsoft YaHei', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
}

body.day-mode #background-wrapper {
    background-color: transparent;
}


body.day-mode .back-btn {
    color: #4a5568;
}

body.day-mode .back-btn:hover {
    color: #1a202c;
}

body.day-mode .container {
    background: hsla(0, 0%, 100%, 0.4);
    border-color: rgba(200, 200, 200, 0.4);
    box-shadow: 5px 3px 30px rgba(0, 0, 0, 0.1);
}

body.day-mode .header h1 {
    color: #2d3748;
    text-shadow: .03em .03em 0 hsla(200, 60%, 60%, 1);
}

body.day-mode .subtitle {
    color: #4a5568;
}

body.day-mode .section h2,
body.day-mode .section h3 {
    color: #2d3748;
}

body.day-mode .file-upload-area {
    background: rgba(255, 255, 255, 0.6);
    border-color: rgba(0, 0, 0, 0.15);
}

body.day-mode .file-upload-area:hover {
    background: rgba(255, 255, 255, 0.8);
    border-color: rgba(0, 0, 0, 0.25);
}

body.day-mode .upload-text {
    color: #2d3748;
}

body.day-mode .upload-hint {
    color: #718096;
}

body.day-mode .file-name {
    color: #2d3748;
}

body.day-mode textarea,
body.day-mode select,
body.day-mode input[type="text"] {
    background: rgba(255, 255, 255, 0.7);
    border-color: rgba(0, 0, 0, 0.15);
    color: #1a202c;
}

body.day-mode textarea::placeholder {
    color: #a0aec0;
}

body.day-mode label {
    color: #1a202c;
    font-weight: 500;
}

body.day-mode select {
    color: #1a202c;
    font-weight: 500;
}

/* 1. 修改基础按钮样式 */
body.day-mode .btn {
    background: #ffffff; /* 改为纯白色 */
    color: #1a202c;
    border: 2px solid #cbd5e0; /* 稍微深一点的边框，让白色按钮在浅色背景下更清晰 */
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.05);
    transition: all 0.3s ease;
}

/* 2. 必须清除伪元素的背景渐变，否则白色会被遮盖 */
body.day-mode .btn::before {
    background: none; 
    backdrop-filter: none;
}

/* 3. 如果你的“载入文本”按钮使用了 btn-primary 等类，也要同步改为白色 */
body.day-mode .btn-primary,
body.day-mode .btn-success,
body.day-mode .btn-secondary {
    background: #ffffff;
    color: #1a202c;
}

/* 4. 悬停效果：增加一点灰色或加深边框 */
body.day-mode .btn:hover:not(:disabled) {
    background: #f7fafc; /* 悬停时微灰 */
    border-color: #a0aec0;
    transform: translateY(-1px);
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
}

body.day-mode .divider {
    color: #718096;
}

body.day-mode .divider::before,
body.day-mode .divider::after {
    background: rgba(0, 0, 0, 0.3);
}

body.day-mode .radio-option span {
    color: #2d3748;
}

body.day-mode .table-preview,
body.day-mode .search-results {
    background: rgba(255, 255, 255, 0.5);
    border-color: rgba(0, 0, 0, 0.1);
}

body.day-mode .data-table {
    background: rgba(255, 255, 255, 0.7);
}

body.day-mode .data-table th {
    background: rgba(59, 130, 246, 0.2);
    color: #1e40af;
}

body.day-mode .data-table td {
    color: #2d3748;
    border-color: rgba(0, 0, 0, 0.1);
}

body.day-mode .data-table tr:hover {
    background: rgba(59, 130, 246, 0.1);
}

body.day-mode .search-condition {
    background: rgba(255, 255, 255, 0.6);
    border-color: rgba(0, 0, 0, 0.1);
}

body.day-mode .condition-input,
body.day-mode .condition-select {
    background: rgba(255, 255, 255, 0.8);
    border-color: rgba(0, 0, 0, 0.15);
    color: #1a202c;
}

body.day-mode .export-area {
    background: rgba(255, 255, 255, 0.3);
    border-color: rgba(0, 0, 0, 0.1);
}

body.day-mode .table-info {
    background: rgba(255, 255, 255, 0.6);
    border-color: rgba(0, 0, 0, 0.15);
}

body.day-mode .table-info p {
    color: #1a202c;
    font-weight: 500;
}

body.day-mode .table-info label {
    color: #1a202c;
    font-weight: 600;
}

body.day-mode .column-tag {
    background: rgba(59, 130, 246, 0.2);
    color: #1e40af;
    font-weight: 500;
}

body.day-mode ::-webkit-scrollbar-track {
    background: rgba(0, 0, 0, 0.05);
}

body.day-mode ::-webkit-scrollbar-thumb {
    background: rgba(0, 0, 0, 0.2);
}

body.day-mode ::-webkit-scrollbar-thumb:hover {
    background: rgba(0, 0, 0, 0.3);
}

/* ===== 日夜切换器样式 ===== */
.theme-toggle {
  position: fixed;
  top: 20px;
  right: 20px;
  z-index: 1000;
  user-select: none;
  transform: scale(0.64);
  transform-origin: top right;
}

.theme-toggle__checkbox {
  display: none;
}

.theme-toggle__btn {
  display: block;
  position: relative;
  width: 125px;
  height: 70px;
  border-radius: 70px;
  border: 5px solid #1c1c1c;
  background-color: #3c4145;
  cursor: pointer;
  transition: all 350ms ease-in;
}

.theme-toggle__btn::before {
  content: '';
  position: absolute;
  top: 2px;
  left: 2px;
  width: 46px;
  height: 46px;
  border-radius: 50%;
  background-color: #fff;
  border: 5px solid #e3e3c7;
  transition: all 250ms ease-in;
}

.theme-toggle__btn::after {
  content: '';
  position: absolute;
  top: 62%;
  left: 39px;
  z-index: 10;
  width: 9.2px;
  height: 9.2px;
  opacity: 0;
  background-color: #fff;
  border-radius: 50%;
  box-shadow:
    #fff 0 0,
    #fff 2.5px 0,
    #fff 5px 0,
    #fff 7.5px 0,
    #fff 9px 0,
    #fff 11.5px 0,
    #fff 13px 0,
    #fff 17px -1px 0 1px,
    #fff 13px -6px 0 -2px,
    #fff 6px -6px 0 1px,
    #d3d3d3 0 0 0 3.5px,
    #d3d3d3 5px 0 0 3.5px,
    #d3d3d3 9px 0 0 3.5px,
    #d3d3d3 13px 0 0 3.5px,
    #d3d3d3 17px -1px 0 4.5px,
    #d3d3d3 13px -6px 0 1px,
    #d3d3d3 6px -6px 0 4.5px;
  transition: opacity 100ms ease-in;
}

.theme-toggle__feature {
  display: block;
  position: absolute;
  top: 9px;
  left: 52.5%;
  z-index: 20;
  width: 4px;
  height: 4px;
  border-radius: 50%;
  background-color: #fff;
  box-shadow:
    rgba(255,255,255,0.1) 30px -3px 0 0,
    rgba(255,255,255,0.1) 12px 10px 0 -1px,
    #fff 38px 18px 0 1px,
    rgba(255,255,255,0.1) 32px 34px 0 0,
    #fff 20px 24px 0 -1.5px,
    rgba(255,255,255,0.1) 5px 38px 0 1px;
  animation: starry_star 5s ease-in-out infinite;
}

.theme-toggle__feature::before {
  content: '';
  position: absolute;
  top: -2px;
  left: -25px;
  width: 15px;
  height: 15px;
  background-color: #fff;
  border-radius: 50%;
  border: 4px solid #e3e3c7;
  box-shadow:
    #e3e3c7 -28px 0 0 -3px,
    #e3e3c7 -8px 24px 0 -2px;
  transform-origin: -6px 130%;
  transition: all 250ms ease-in;
}

@keyframes starry_star {
  50% {
    background-color: rgba(255,255,255,0.1);
    box-shadow:
      #fff 30px -3px 0 0,
      #fff 12px 10px 0 -1px,
      rgba(255,255,255,0.1) 38px 18px 0 1px,
      #fff 32px 34px 0 0,
      rgba(255,255,255,0.1) 20px 24px 0 -1.5px,
      #fff 5px 38px 0 1px;
  }
}

@keyframes bounceIn {
  0% {
    opacity: 0;
    transform: scale(.3);
  }
  50% {
    opacity: 1;
    transform: scale(1.1);
  }
  55% {
    transform: scale(1.1);
  }
  75% {
    transform: scale(.9);
  }
  100% {
    opacity: 1;
    transform: scale(1);
  }
}

.theme-toggle__checkbox:checked + .theme-toggle__btn {
  background-color: #9ee3fb;
  border: 5px solid #86c3d7;
}

.theme-toggle__checkbox:checked + .theme-toggle__btn::before {
  left: 57px;
  background-color: #ffdf6d;
  border: 5px solid #e1c348;
}

.theme-toggle__checkbox:checked + .theme-toggle__btn::after {
  opacity: 1;
  animation-name: bounceIn;
  animation-duration: 0.60s;
  animation-delay: 0.10s;
  animation-fill-mode: backwards;
  animation-timing-function: ease-in-out;
}

.theme-toggle__checkbox:checked + .theme-toggle__btn .theme-toggle__feature {
  opacity: 0;
  box-shadow:
    rgba(255,255,255,0.1) 30px -3px 0 -4px,
    rgba(255,255,255,0.1) 12px 10px 0 -5px,
    #fff 38px 18px 0 -3px,
    rgba(255,255,255,0.1) 32px 34px 0 -4px,
    #fff 20px 24px 0 -5.5px,
    rgba(255,255,255,0.1) 5px 38px 0 -3px;
  animation: none;
}

.theme-toggle__checkbox:checked + .theme-toggle__btn .theme-toggle__feature::before {
  left: 25px;
  transform: rotate(70deg);
}

@media (max-width: 768px) {
  .theme-toggle {
    top: 10px;
    right: 10px;
    transform: scale(0.58);
  }
}

/* ===== 页脚样式 ===== */
.footer {
  position: relative;
  z-index: 1;
  width: 100%;
  padding: 2rem 1rem;
  text-align: center;
  margin-top: auto;
}

.footer p {
  margin: 0;
  font-size: 0.85rem;
  color: rgba(255, 255, 255, 0.4);
  transition: color 300ms ease-out;
}

/* 日间模式页脚样式 */
body.day-mode .footer p {
  color: rgba(0, 0, 0, 0.5);
}

/* 页脚响应式 */
@media (max-width: 768px) {
  .footer {
    padding: 1.5rem 1rem;
  }

  .footer p {
    font-size: 0.75rem;
  }
}
