/* registration.css - 比赛报名页面样式 */

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

body {
    font-family: 'Segoe UI', 'Microsoft YaHei', sans-serif;
    background: #0a0a0f;
    color: #f0f0f0;
    min-height: 100vh;
    line-height: 1.5;
}

/* 网格背景 */
.grid-bg {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-image: 
        linear-gradient(rgba(0, 212, 255, 0.1) 1px, transparent 1px),
        linear-gradient(90deg, rgba(0, 212, 255, 0.1) 1px, transparent 1px);
    background-size: 50px 50px;
    z-index: -1;
    opacity: 0.3;
}

/* 动态粒子效果 */
.particles {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -2;
    pointer-events: none;
}

.container {
    max-width: 800px;
    margin: 0 auto;
    padding: 10px;
}

/* 头部样式 */
.header {
    text-align: center;
    margin-bottom: 20px;
    padding-top: 10px;
}

.logo {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 15px;
    margin-bottom: 10px;
}

.logo img {
    object-fit: contain;
}

.title {
    font-size: 1.8rem;
    font-weight: 700;
    color: #00d4ff;
    margin-bottom: 5px;
}

.subtitle {
    font-size: 0.9rem;
    color: #a0a0b0;
}

/* 比赛信息卡片 */
.match-info {
    background: rgba(18, 18, 26, 0.9);
    border-radius: 12px;
    padding: 20px;
    margin-bottom: 20px;
    border: 1px solid rgba(0, 212, 255, 0.3);
    backdrop-filter: blur(10px);
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.3);
}

.match-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 15px;
}

.match-title {
    font-size: 1.3rem;
    font-weight: 600;
    color: #f0f0f0;
}

.match-status {
    padding: 5px 12px;
    border-radius: 20px;
    font-size: 0.85rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.status-open {
    background: linear-gradient(135deg, #28a745, #20c997);
    color: white;
}

.status-closed {
    background: linear-gradient(135deg, #dc3545, #fd7e14);
    color: white;
}

.match-details {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 15px;
    margin-top: 15px;
}

.match-detail {
    text-align: center;
    padding: 10px;
    background: rgba(0, 212, 255, 0.1);
    border-radius: 8px;
    border: 1px solid rgba(0, 212, 255, 0.2);
}

.detail-label {
    font-size: 0.75rem;
    color: #a0a0b0;
    margin-bottom: 5px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.detail-value {
    font-size: 1rem;
    font-weight: 600;
    color: #f0f0f0;
}

/* 创建比赛界面 */
.create-match {
    background: rgba(18, 18, 26, 0.9);
    border-radius: 12px;
    padding: 30px;
    margin-bottom: 20px;
    border: 1px solid rgba(0, 212, 255, 0.3);
    text-align: center;
    backdrop-filter: blur(10px);
}

.create-title {
    font-size: 1.5rem;
    margin-bottom: 15px;
    color: #f0f0f0;
    font-weight: 600;
}

.create-buttons {
    display: flex;
    gap: 20px;
    justify-content: center;
    margin-top: 25px;
}

.create-btn {
    padding: 20px 25px;
    border: none;
    border-radius: 10px;
    font-weight: 600;
    cursor: pointer;
    font-size: 1.1rem;
    min-width: 180px;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 10px;
    transition: all 0.3s ease;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
}

.create-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.3);
}

.btn-internal {
    background: linear-gradient(135deg, #0066cc, #0099ff);
    color: white;
}

.btn-external {
    background: linear-gradient(135deg, #e0e0e0, #ffffff);
    color: #0a0a0f;
}

/* 内容区域 */
.content-section {
    background: rgba(18, 18, 26, 0.9);
    border-radius: 12px;
    padding: 20px;
    margin-bottom: 20px;
    border: 1px solid rgba(0, 212, 255, 0.3);
    backdrop-filter: blur(10px);
}

.section-title {
    font-size: 1.3rem;
    margin-bottom: 15px;
    color: #f0f0f0;
    display: flex;
    align-items: center;
    gap: 10px;
    font-weight: 600;
}

/* 报名表单 */
.registration-form {
    background: rgba(10, 10, 15, 0.8);
    border-radius: 10px;
    padding: 20px;
    border: 1px solid rgba(0, 212, 255, 0.2);
}

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

.form-label {
    display: block;
    margin-bottom: 8px;
    color: #a0a0b0;
    font-weight: 500;
    font-size: 0.95rem;
}

.form-control {
    width: 100%;
    padding: 14px;
    background: rgba(18, 18, 26, 0.8);
    border: 1px solid rgba(0, 212, 255, 0.3);
    border-radius: 8px;
    color: #f0f0f0;
    font-size: 1rem;
    transition: border-color 0.3s ease;
}

.form-control:focus {
    outline: none;
    border-color: #00d4ff;
    box-shadow: 0 0 0 2px rgba(0, 212, 255, 0.2);
}

/* 球队选择 */
.team-selection {
    display: flex;
    gap: 15px;
    margin-bottom: 15px;
}

.team-option {
    flex: 1;
    text-align: center;
}

.team-radio {
    display: none;
}

.team-label {
    display: block;
    padding: 15px;
    background: rgba(18, 18, 26, 0.8);
    border: 2px solid rgba(0, 212, 255, 0.3);
    border-radius: 8px;
    cursor: pointer;
    font-size: 0.95rem;
    transition: all 0.3s ease;
}

.team-radio:checked + .team-label {
    border-color: #00d4ff;
    background: rgba(0, 212, 255, 0.15);
    box-shadow: 0 0 0 2px rgba(0, 212, 255, 0.1);
}

.home-team .team-label {
    border-left: 4px solid #0066cc;
}

.away-team .team-label {
    border-left: 4px solid #e0e0e0;
}

/* 外援选项 */
.checkbox-group {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 15px;
}

.guest-count {
    display: none;
    margin-left: 20px;
    animation: fadeIn 0.3s ease;
}

.guest-count.show {
    display: flex;
    align-items: center;
    gap: 10px;
}

.guest-select {
    padding: 8px 12px;
    background: rgba(18, 18, 26, 0.8);
    border: 1px solid rgba(0, 212, 255, 0.3);
    border-radius: 6px;
    color: #f0f0f0;
    font-size: 0.9rem;
    min-width: 100px;
}

/* 按钮 */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    padding: 14px 20px;
    background: linear-gradient(135deg, #00d4ff, #0099cc);
    color: #0a0a0f;
    border: none;
    border-radius: 8px;
    font-weight: 600;
    cursor: pointer;
    width: 100%;
    font-size: 1rem;
    transition: all 0.3s ease;
    box-shadow: 0 4px 15px rgba(0, 212, 255, 0.2);
}

.btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(0, 212, 255, 0.3);
}

.btn:disabled {
    background: #666;
    cursor: not-allowed;
    transform: none;
    box-shadow: none;
}

/* 报名名单 */
.teams-container {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
    margin-top: 20px;
}

.team-list {
    background: rgba(10, 10, 15, 0.8);
    border-radius: 10px;
    padding: 15px;
    border: 1px solid rgba(0, 212, 255, 0.2);
    min-height: 200px;
}

.team-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 15px;
    padding-bottom: 10px;
    border-bottom: 1px solid rgba(0, 212, 255, 0.2);
}

.team-title {
    font-size: 1.1rem;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 8px;
}

.team-count {
    background: #00d4ff;
    color: #0a0a0f;
    padding: 4px 10px;
    border-radius: 20px;
    font-size: 0.85rem;
    font-weight: 600;
}

/* 球员列表 */
.player-list {
    list-style: none;
    max-height: 550px;
    overflow-y: auto;
}

.player-item {
    padding: 10px;
    margin-bottom: 8px;
    background: rgba(18, 18, 26, 0.8);
    border-radius: 6px;
    border: 1px solid rgba(0, 212, 255, 0.2);
    animation: fadeIn 0.3s ease;
}

.guest-item {
    border-left: 3px solid #ff9800;
    background: rgba(255, 152, 0, 0.1);
}

.player-info {
    display: flex;
    align-items: center;
    gap: 10px;
}

.player-number {
    background: #00d4ff;
    color: #0a0a0f;
    width: 24px;
    height: 24px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.8rem;
    font-weight: 600;
    flex-shrink: 0;
}

.guest-number {
    background: #ff9800;
}

.player-no-number {
    background: #6c757d;
    color: #fff;
    width: 24px;
    height: 24px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.8rem;
    font-weight: 600;
    flex-shrink: 0;
}

.player-name {
    font-weight: 500;
    flex: 1;
}

.player-details {
    font-size: 0.8rem;
    color: #a0a0b0;
    margin-top: 3px;
}

/* 取消按钮 */
.cancel-btn {
    opacity: 0;
    visibility: hidden;
    background: rgba(220, 53, 69, 0.2);
    border: 1px solid rgba(220, 53, 69, 0.3);
    border-radius: 50%;
    color: #dc3545;
    width: 28px;
    height: 28px;    
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.2s ease;
    flex-shrink: 0;
    margin-left: 8px;
}

.cancel-btn:hover {
    background: rgba(220, 53, 69, 0.3);
    border-color: #dc3545;
    transform: scale(1.1);
}

.player-item:hover .cancel-btn {
    opacity: 1;
    visibility: visible;
}

/* 鼠标悬停效果 */
.player-item {
    position: relative;
    padding: 10px;
    margin-bottom: 8px;
    background: rgba(18, 18, 26, 0.8);
    border-radius: 6px;
    border: 1px solid rgba(0, 212, 255, 0.2);
    animation: fadeIn 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: space-between;
    transition: background-color 0.2s ease;
}

.player-item:hover {
    background: rgba(25, 25, 35, 0.9);
}

.player-info {
    display: flex;
    align-items: center;
    gap: 10px;
    flex: 1;
}

.guest-label {
    color: #ff9800;
    font-weight: 600;
}

/* 管理按钮 */
.admin-actions {
    display: flex;
    gap: 10px;
    margin-top: 20px;
}

.admin-btn {
    flex: 1;
    padding: 12px;
    border: none;
    border-radius: 8px;
    font-weight: 600;
    cursor: pointer;
    font-size: 0.9rem;
    transition: all 0.3s ease;
}

/* 页脚 */
footer {
    text-align: center;
    padding: 2rem;
    color: #a0a0b0;
    font-size: 0.9rem;
    border-top: 1px solid rgba(0, 212, 255, 0.1);
    margin-top: 3rem;
}

.social-links {
    display: flex;
    justify-content: center;
    gap: 1.5rem;
    margin-top: 1rem;
}

.social-link {
    color: #a0a0b0;
    font-size: 1.2rem;
    transition: color 0.3s ease;
}

.social-link:hover {
    color: #00d4ff;
}

.btn-end {
    background: linear-gradient(135deg, #dc3545, #c82333);
    color: white;
}

.btn-refresh {
    background: linear-gradient(135deg, #17a2b8, #138496);
    color: white;
}

.btn-clear {
    background: linear-gradient(135deg, #ffc107, #e0a800);
    color: #0a0a0f;
}

.btn-start {
    background: linear-gradient(135deg, #4caf50, #2e7d32);
    color: white;
}

.admin-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.2);
}

/* 加载动画 */
.loading {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 40px;
    text-align: center;
}

.loading-spinner {
    width: 40px;
    height: 40px;
    border: 3px solid rgba(0, 212, 255, 0.3);
    border-top-color: #00d4ff;
    border-radius: 50%;
    animation: spin 1s linear infinite;
    margin-bottom: 15px;
}

/* 消息提示 */
.message {
    position: fixed;
    top: 20px;
    right: 20px;
    padding: 15px 20px;
    border-radius: 8px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.3);
    z-index: 1000;
    max-width: 300px;
    animation: slideIn 0.3s ease;
    display: flex;
    align-items: center;
    gap: 10px;
}

.message-success {
    background: linear-gradient(135deg, #28a745, #218838);
    color: white;
}

.message-error {
    background: linear-gradient(135deg, #dc3545, #c82333);
    color: white;
}

.message-warning {
    background: linear-gradient(135deg, #ffc107, #e0a800);
    color: #0a0a0f;
}

.message-info {
    background: linear-gradient(135deg, #17a2b8, #138496);
    color: white;
}

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

@keyframes slideIn {
    from { opacity: 0; transform: translateX(20px); }
    to { opacity: 1; transform: translateX(0); }
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

/* 响应式设计 */
@media (max-width: 768px) {
    .container {
        padding: 5px;
    }
    
    .teams-container {
        grid-template-columns: 1fr;
    }
    
    .team-selection {
        flex-direction: column;
    }
    
    .create-buttons {
        flex-direction: column;
    }
    
    .create-btn {
        min-width: 100%;
    }
    
    .match-details {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .admin-actions {
        flex-direction: column;
    }
}

@media (max-width: 480px) {    
    .title {
        font-size: 1.5rem;
    }
    
    .match-title {
        font-size: 1.1rem;
    }
    
    .section-title {
        font-size: 1.1rem;
    }
}

/* ========== 初始加载界面样式 ========== */

.initial-loading {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(135deg, #0a0a0f 0%, #1a1a2e 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 1000;
    transition: opacity 0.5s ease;
}

.initial-loading.hidden {
    opacity: 0;
    pointer-events: none;
}

.welcome-container {
    text-align: center;
    max-width: 600px;
    padding: 2rem;
    animation: fadeIn 0.8s ease;
}

.welcome-logo {
    margin-bottom: 1.5rem;
    animation: float 3s ease-in-out infinite;
}

.welcome-title {
    font-size: 2.2rem;
    margin-bottom: 0.5rem;
    background: linear-gradient(90deg, #00d4ff, #ff6b6b);
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
    font-weight: 700;
}

.welcome-subtitle {
    font-size: 1.1rem;
    color: #a0a0b0;
    margin-bottom: 2rem;
    font-weight: 300;
}

.loading-container {
    margin: 2rem 0;
}

.initial-loading-spinner {
    width: 60px;
    height: 60px;
    border: 4px solid rgba(0, 212, 255, 0.1);
    border-top-color: #00d4ff;
    border-radius: 50%;
    margin: 0 auto 1rem;
    animation: spin 1.2s linear infinite;
}

.loading-text {
    color: #00d4ff;
    font-size: 1.1rem;
    font-weight: 500;
    letter-spacing: 1px;
}

.system-features {
    display: flex;
    justify-content: center;
    gap: 2rem;
    margin-top: 2rem;
    flex-wrap: wrap;
}

.feature-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.5rem;
    color: #a0a0b0;
    font-size: 0.9rem;
    transition: color 0.3s ease;
}

.feature-item i {
    font-size: 1.5rem;
    color: #00d4ff;
}

.feature-item:hover {
    color: #fff;
}

.feature-item:hover i {
    color: #ff6b6b;
}

/* 动画 */
@keyframes float {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-10px); }
}

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

/* 响应式设计 */
@media (max-width: 768px) {
    .welcome-title {
        font-size: 1.8rem;
    }
    
    .welcome-subtitle {
        font-size: 1rem;
    }
    
    .welcome-logo img {
        width: 100px;
        height: 100px;
    }
    
    .system-features {
        gap: 1.5rem;
    }
    
    .feature-item {
        font-size: 0.8rem;
    }
    
    .feature-item i {
        font-size: 1.2rem;
    }
}

@media (max-width: 480px) {
    .welcome-container {
        padding: 1rem;
    }
    
    .welcome-title {
        font-size: 1.5rem;
    }
    
    .system-features {
        gap: 1rem;
    }
}