/* 视频音乐投稿系统 - 主样式表 */
/* 浅蓝色主题 */

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

:root {
    --primary-blue: #87CEEB;
    --light-blue: #E0F4FF;
    --sky-blue: #6495ED;
    --deep-blue: #2c5282;
    --white: #ffffff;
    --gray-100: #f7fafc;
    --gray-200: #edf2f7;
    --gray-300: #e2e8f0;
    --gray-500: #718096;
    --gray-700: #4a5568;
    --success: #48bb78;
    --error: #f56565;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', 'PingFang SC', 
                 'Hiragino Sans GB', 'Microsoft YaHei', sans-serif;
    background: linear-gradient(180deg, #E0F4FF 0%, #F7FBFF 50%, #FFFFFF 100%);
    min-height: 100vh;
    color: var(--deep-blue);
    position: relative;
    overflow-x: hidden;
}

/* 云朵背景动画 */
.clouds {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: 0;
    overflow: hidden;
}

.cloud {
    position: absolute;
    background: white;
    border-radius: 50%;
    opacity: 0.6;
    filter: blur(1px);
    animation: cloudMove linear infinite;
}

.cloud::before,
.cloud::after {
    content: '';
    position: absolute;
    background: white;
    border-radius: 50%;
}

.cloud-1 {
    width: 120px;
    height: 60px;
    top: 10%;
    left: -150px;
    animation-duration: 35s;
}
.cloud-1::before {
    width: 50px;
    height: 50px;
    top: -25px;
    left: 20px;
}
.cloud-1::after {
    width: 40px;
    height: 40px;
    top: -20px;
    left: 60px;
}

.cloud-2 {
    width: 100px;
    height: 50px;
    top: 25%;
    left: -150px;
    animation-duration: 45s;
    animation-delay: -10s;
    opacity: 0.5;
}
.cloud-2::before {
    width: 40px;
    height: 40px;
    top: -20px;
    left: 15px;
}
.cloud-2::after {
    width: 35px;
    height: 35px;
    top: -15px;
    left: 50px;
}

.cloud-3 {
    width: 150px;
    height: 75px;
    top: 50%;
    left: -200px;
    animation-duration: 50s;
    animation-delay: -20s;
    opacity: 0.4;
}
.cloud-3::before {
    width: 60px;
    height: 60px;
    top: -30px;
    left: 30px;
}
.cloud-3::after {
    width: 50px;
    height: 50px;
    top: -25px;
    left: 75px;
}

.cloud-4 {
    width: 90px;
    height: 45px;
    top: 70%;
    left: -150px;
    animation-duration: 40s;
    animation-delay: -5s;
    opacity: 0.45;
}
.cloud-4::before {
    width: 35px;
    height: 35px;
    top: -18px;
    left: 12px;
}
.cloud-4::after {
    width: 30px;
    height: 30px;
    top: -15px;
    left: 45px;
}

.cloud-5 {
    width: 110px;
    height: 55px;
    top: 85%;
    left: -150px;
    animation-duration: 42s;
    animation-delay: -25s;
    opacity: 0.5;
}
.cloud-5::before {
    width: 45px;
    height: 45px;
    top: -22px;
    left: 20px;
}
.cloud-5::after {
    width: 38px;
    height: 38px;
    top: -18px;
    left: 55px;
}

@keyframes cloudMove {
    from {
        transform: translateX(0);
    }
    to {
        transform: translateX(calc(100vw + 300px));
    }
}

/* 主容器 */
.container {
    max-width: 600px;
    margin: 0 auto;
    padding: 40px 20px;
    position: relative;
    z-index: 1;
}

/* 头部 */
.header {
    text-align: center;
    margin-bottom: 40px;
}

.header h1 {
    font-size: 36px;
    color: var(--deep-blue);
    margin-bottom: 8px;
    text-shadow: 2px 2px 4px rgba(135, 206, 235, 0.3);
}

.header .subtitle {
    color: var(--gray-500);
    font-size: 16px;
}

/* 表单卡片样式 */
.submission-form {
    background: var(--white);
    border-radius: 20px;
    padding: 40px;
    box-shadow: 0 20px 60px rgba(100, 149, 237, 0.15);
}

/* 表单分组 */
.form-group {
    margin-bottom: 24px;
}

.form-group label {
    display: block;
    color: var(--deep-blue);
    font-weight: 500;
    margin-bottom: 8px;
    font-size: 14px;
}

.form-group .required {
    color: var(--error);
    margin-left: 4px;
}

.form-group .optional {
    color: var(--gray-500);
    font-weight: normal;
    font-size: 12px;
    margin-left: 4px;
}

.form-group input[type="text"],
.form-group input[type="email"],
.form-group input[type="password"],
.form-group select,
.form-group textarea {
    width: 100%;
    padding: 12px 16px;
    border: 2px solid var(--gray-300);
    border-radius: 12px;
    font-size: 15px;
    color: var(--deep-blue);
    background: var(--gray-100);
    transition: all 0.3s ease;
    font-family: inherit;
}

.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
    outline: none;
    border-color: var(--sky-blue);
    background: white;
    box-shadow: 0 0 0 4px rgba(100, 149, 237, 0.15);
}

.form-group input::placeholder,
.form-group textarea::placeholder {
    color: var(--gray-500);
}

/* 自定义下拉选择框组件样式 */
.custom-select {
    position: relative;
    width: 100%;
    margin-bottom: 24px;
}

.custom-select-trigger {
    display: flex;
    align-items: center;
    justify-content: space-between;
    width: 100%;
    padding: 12px 16px;
    background: var(--gray-100);
    border: 2px solid var(--gray-300);
    border-radius: 12px;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    font-size: 15px;
    color: var(--deep-blue);
    user-select: none;
}

.custom-select-trigger:hover {
    border-color: var(--sky-blue);
    background-color: #f0f8ff;
}

.custom-select.open .custom-select-trigger {
    border-color: var(--sky-blue);
    background-color: white;
    box-shadow: 0 0 0 4px rgba(100, 149, 237, 0.15);
}

.custom-select-text {
    flex: 1;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.custom-select-text.placeholder {
    color: var(--gray-500);
}

.custom-select-arrow {
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--sky-blue);
    margin-left: 10px;
    transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.custom-select.open .custom-select-arrow {
    transform: rotate(180deg);
}

.custom-select-options {
    position: absolute;
    background: white;
    border-radius: 14px;
    box-shadow: 0 12px 40px rgba(100, 149, 237, 0.2);
    max-height: 240px;
    overflow-y: auto;
    z-index: 1000;
    display: none;
    opacity: 0;
    transform-origin: top center;
    transition: opacity 0.25s ease, transform 0.25s ease;
    border: 1px solid #e8f4fd;
}

.custom-select-options.show {
    opacity: 1;
}

/* 初始状态的 transform 动画 */
.custom-select-options:not(.show) {
    transform: translateY(-10px) scale(0.98);
}

.custom-select-options.show {
    transform: translateY(0) scale(1);
}

.custom-select-option {
    padding: 14px 18px;
    cursor: pointer;
    color: var(--deep-blue);
    font-size: 15px;
    font-weight: 500;
    transition: all 0.2s ease;
    position: relative;
    display: flex;
    align-items: center;
    overflow: hidden;
}

.custom-select-option::before {
    content: '';
    position: absolute;
    left: 0;
    top: 0;
    width: 4px;
    height: 100%;
    background: linear-gradient(180deg, var(--sky-blue), var(--primary-blue));
    transform: scaleY(0);
    transition: transform 0.3s ease;
}

.custom-select-option:hover {
    background: linear-gradient(135deg, #f0f8ff 0%, #e0f4ff 100%);
    color: var(--sky-blue);
    padding-left: 24px;
}

.custom-select-option:hover::before {
    transform: scaleY(1);
}

.custom-select-option.selected {
    background: linear-gradient(135deg, #E0F4FF 0%, #c3e6f7 100%);
    color: var(--sky-blue);
    font-weight: 600;
    padding-left: 24px;
}

.custom-select-option.selected::before {
    transform: scaleY(1);
}

.custom-select-option.selected::after {
    content: '✓';
    position: absolute;
    right: 18px;
    color: var(--sky-blue);
    font-size: 18px;
    font-weight: bold;
    animation: checkmark 0.3s ease-out;
}

@keyframes checkmark {
    0% {
        opacity: 0;
        transform: scale(0);
    }
    50% {
        transform: scale(1.2);
    }
    100% {
        opacity: 1;
        transform: scale(1);
    }
}

/* 自定义滚动条 */
.custom-select-options::-webkit-scrollbar {
    width: 6px;
}

.custom-select-options::-webkit-scrollbar-track {
    background: #f1f8fd;
    border-radius: 3px;
}

.custom-select-options::-webkit-scrollbar-thumb {
    background: linear-gradient(180deg, #87CEEB, #6495ED);
    border-radius: 3px;
}

.custom-select-options::-webkit-scrollbar-thumb:hover {
    background: linear-gradient(180deg, #6495ED, #4169E1);
}

/* Firefox 支持 */
@supports (-moz-appearance: none) {
    .custom-select-options {
        scrollbar-width: thin;
        scrollbar-color: #87CEEB #f1f8fd;
    }
}

/* 下拉选项进入动画 */
.custom-select-option {
    animation: optionFadeIn 0.3s ease forwards;
    opacity: 0;
}

.custom-select-options.show .custom-select-option:nth-child(1) { animation-delay: 0.05s; }
.custom-select-options.show .custom-select-option:nth-child(2) { animation-delay: 0.08s; }
.custom-select-options.show .custom-select-option:nth-child(3) { animation-delay: 0.11s; }
.custom-select-options.show .custom-select-option:nth-child(4) { animation-delay: 0.14s; }
.custom-select-options.show .custom-select-option:nth-child(5) { animation-delay: 0.17s; }
.custom-select-options.show .custom-select-option:nth-child(6) { animation-delay: 0.20s; }
.custom-select-options.show .custom-select-option:nth-child(7) { animation-delay: 0.23s; }
.custom-select-options.show .custom-select-option:nth-child(8) { animation-delay: 0.26s; }

@keyframes optionFadeIn {
    from {
        opacity: 0;
        transform: translateX(-10px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

/* 验证码区域 */
.captcha-group .captcha-wrapper {
    display: flex;
    gap: 12px;
    align-items: center;
}

.captcha-group input {
    flex: 1;
}

.captcha-img {
    width: 120px;
    height: 40px;
    border-radius: 8px;
    cursor: pointer;
    border: 2px solid var(--gray-300);
    transition: all 0.3s ease;
}

.captcha-img:hover {
    border-color: var(--sky-blue);
}

.refresh-btn {
    width: 40px;
    height: 40px;
    border: 2px solid var(--gray-300);
    background: var(--gray-100);
    border-radius: 8px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 20px;
    color: var(--gray-700);
    transition: all 0.3s ease;
}

.refresh-btn:hover {
    background: var(--sky-blue);
    color: white;
    border-color: var(--sky-blue);
    transform: rotate(180deg);
}

/* 提交按钮 */
.btn-submit {
    width: 100%;
    padding: 16px 32px;
    background: linear-gradient(135deg, var(--sky-blue) 0%, var(--primary-blue) 100%);
    color: white;
    border: none;
    border-radius: 14px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    transition: all 0.3s ease;
    margin-top: 16px;
    font-family: inherit;
}

.btn-submit:hover {
    transform: translateY(-3px);
    box-shadow: 0 10px 30px rgba(100, 149, 237, 0.4);
}

.btn-submit:active {
    transform: translateY(-1px);
}

.btn-submit .arrow {
    width: 20px;
    height: 20px;
    transition: transform 0.3s ease;
}

.btn-submit:hover .arrow {
    transform: translateX(4px);
}

/* 提示框 */
.alert {
    padding: 16px 20px;
    border-radius: 12px;
    margin-bottom: 24px;
    font-size: 14px;
    font-weight: 500;
}

.alert-error {
    background: #fff5f5;
    color: var(--error);
    border: 1px solid #fed7d7;
}

.alert-success {
    background: #f0fff4;
    color: var(--success);
    border: 1px solid #c6f6d5;
}

/* 底部链接 */
.footer {
    text-align: center;
    margin-top: 32px;
}

.admin-link {
    color: var(--sky-blue);
    text-decoration: none;
    font-size: 14px;
    transition: color 0.3s ease;
}

.admin-link:hover {
    color: var(--deep-blue);
    text-decoration: underline;
}

/* 成功页面 */
.success-container {
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 100vh;
}

.success-content {
    text-align: center;
    padding: 40px;
    background: white;
    border-radius: 24px;
    box-shadow: 0 20px 60px rgba(72, 187, 120, 0.15);
    max-width: 400px;
    width: 100%;
}

.success-icon {
    width: 80px;
    height: 80px;
    margin: 0 auto 24px;
}

.success-icon svg {
    width: 100%;
    height: 100%;
    animation: successPop 0.5s ease-out;
}

@keyframes successPop {
    0% {
        transform: scale(0);
    }
    60% {
        transform: scale(1.1);
    }
    100% {
        transform: scale(1);
    }
}

.success-title {
    color: var(--deep-blue);
    font-size: 28px;
    margin-bottom: 16px;
}

.success-message {
    color: var(--gray-700);
    font-size: 16px;
    margin-bottom: 12px;
}

.success-id {
    color: var(--sky-blue);
    font-size: 18px;
    margin-bottom: 12px;
}

.success-id strong {
    font-size: 24px;
}

.success-hint {
    color: var(--gray-500);
    font-size: 14px;
    margin-bottom: 32px;
}

.success-actions {
    display: flex;
    justify-content: center;
    gap: 16px;
}

.btn-primary {
    padding: 12px 32px;
    background: linear-gradient(135deg, var(--sky-blue) 0%, var(--primary-blue) 100%);
    color: white;
    text-decoration: none;
    border-radius: 12px;
    font-weight: 600;
    transition: all 0.3s ease;
    display: inline-block;
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 24px rgba(100, 149, 237, 0.3);
}

/* 动画类 */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes fadeInDown {
    from {
        opacity: 0;
        transform: translateY(-30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes fadeIn {
    from {
        opacity: 0;
    }
    to {
        opacity: 1;
    }
}

.animate-fade-in-up {
    opacity: 0;
    animation: fadeInUp 0.6s ease-out forwards;
    animation-delay: var(--delay, 0s);
}

.animate-fade-in-down {
    opacity: 0;
    animation: fadeInDown 0.6s ease-out forwards;
    animation-delay: var(--delay, 0s);
}

.animate-fade-in {
    opacity: 0;
    animation: fadeIn 0.6s ease-out forwards;
    animation-delay: var(--delay, 0s);
}

/* 响应式设计 */
@media (max-width: 768px) {
    .container {
        padding: 20px 16px;
    }

    .header h1 {
        font-size: 28px;
    }

    .submission-form {
        padding: 28px 20px;
    }

    .form-group {
        margin-bottom: 20px;
    }

    .captcha-wrapper {
        flex-wrap: wrap;
    }

    .captcha-img {
        width: 100px;
    }

    .success-content {
        padding: 28px 20px;
    }

    .success-title {
        font-size: 24px;
    }
}

/* 打印样式 */
@media print {
    .clouds,
    .footer,
    .admin-link {
        display: none;
    }

    body {
        background: white;
    }

    .submission-form {
        box-shadow: none;
    }
}
