:root {
    --primary-dark: #1a1a2e;
    --primary-light: #16213e;
    --accent-gold: #c8a971;
    --accent-red: #9d3b3b;
    --text-light: #f1f1f1;
    --text-gray: #b1b1b1;
    --card-bg: #222235;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Noto Sans SC', 'Microsoft YaHei', sans-serif;
}

body {
    background: linear-gradient(to bottom, var(--primary-dark), var(--primary-light));
    color: var(--text-light);
    min-height: 100vh;
    line-height: 1.6;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

/* 导航栏样式 */
header {
    background-color: rgba(26, 26, 46, 0.9);
    backdrop-filter: blur(10px);
    position: sticky;
    top: 0;
    z-index: 100;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
}

.navbar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 15px 0;
}

.logo {
    display: flex;
    align-items: center;
    font-size: 1.8rem;
    font-weight: bold;
    color: var(--accent-gold);
}

.logo-icon {
    margin-right: 10px;
    font-size: 2rem;
}

.nav-links {
    display: flex;
    list-style: none;
}

.nav-links li {
    margin-left: 30px;
}

.nav-links a {
    color: var(--text-light);
    text-decoration: none;
    font-weight: 500;
    transition: color 0.3s;
}

.nav-links a:hover {
    color: var(--accent-gold);
}

.auth-buttons {
    display: flex;
    align-items: center;
}

.btn {
    padding: 10px 20px;
    border-radius: 30px;
    text-decoration: none;
    font-weight: 500;
    transition: all 0.3s;
    display: inline-block;
    cursor: pointer;
}

.btn-login {
    color: var(--text-light);
    margin-right: 15px;
}

.btn-register {
    background-color: var(--accent-gold);
    color: var(--primary-dark);
}

.btn-register:hover {
    background-color: #d6ba88;
    transform: translateY(-2px);
}

/* 英雄区域样式 */
.hero {
    padding: 80px 0;
    text-align: center;
    background: url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" width="100" height="100" viewBox="0 0 100 100"><rect fill="%231a1a2e" width="100" height="100"/><path fill="%2316213e" d="M0 0L100 100"/></svg>');
    background-size: 200%;
}

.hero h1 {
    font-size: 3.5rem;
    margin-bottom: 2px;
    background: linear-gradient(to right, var(--accent-gold), #fff);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.hero h2 {
    font-size: 2rem;
    margin-bottom: 5px;
    background: linear-gradient(to right, var(--accent-gold), #fff);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.hero p {
    font-size: 1.2rem;
    max-width: 700px;
    margin: 0 auto 40px;
    color: var(--text-gray);
}

.hero-buttons {
    display: flex;
    justify-content: center;
    gap: 20px;
}

.btn-primary {
    background-color: var(--accent-red);
    color: var(--text-light);
}

.btn-primary:hover {
    background-color: #b34a4a;
    transform: translateY(-2px);
}

.btn-outline {
    border: 2px solid var(--accent-gold);
    color: var(--accent-gold);
}

.btn-outline:hover {
    background-color: var(--accent-gold);
    color: var(--primary-dark);
}

/* 功能区域样式 */
.section-title {
    text-align: center;
    margin: 60px 0 40px;
    font-size: 2.2rem;
    color: var(--accent-gold);
}

.features {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 30px;
    margin-bottom: 60px;
}

.feature-card {
    background-color: var(--card-bg);
    border-radius: 15px;
    padding: 30px;
    text-align: center;
    transition: transform 0.3s;
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.1);
}

.feature-card:hover {
    transform: translateY(-5px);
}

.feature-icon {
    font-size: 3rem;
    margin-bottom: 20px;
    color: var(--accent-gold);
}

.feature-card h3 {
    margin-bottom: 15px;
    font-size: 1.5rem;
}

/* 投稿表单样式 */
.submission-form {
    background-color: var(--card-bg);
    border-radius: 15px;
    padding: 40px;
    margin-bottom: 60px;
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.1);
}

.form-group {
    margin-bottom: 25px;
}

.form-group label {
    display: block;
    margin-bottom: 8px;
    font-weight: 500;
}

.form-control {
    width: 100%;
    padding: 15px;
    background-color: var(--card-bg);
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 8px;
    color: var(--text-light);
    font-size: 1rem;
}

.form-control:focus {
    outline: none;
    border-color: var(--accent-gold);
}

textarea.form-control {
    min-height: 200px;
    resize: vertical;
}

.form-actions {
    display: flex;
    justify-content: flex-end;
    gap: 15px;
}

/* 酒品展示样式 */
.liquor-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 25px;
    margin-bottom: 60px;
}

.liquor-card {
    background-color: var(--card-bg);
    border-radius: 15px;
    overflow: hidden;
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.1);
    transition: transform 0.3s;
    display: flex;
    flex-direction: column;
}

.liquor-card:hover {
    transform: translateY(-5px);
}

.liquor-image {
    height: 200px;
    background-color: #2a2a40;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--text-gray);
    font-size: 4rem;
    overflow: hidden;
}

.liquor-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.liquor-info {
    padding: 20px;
    flex-grow: 1;
    display: flex;
    flex-direction: column;
}

.liquor-info h3 {
    margin-bottom: 10px;
    font-size: 1.3rem;
    color: var(--accent-gold);
}

.liquor-info p {
    margin-bottom: 15px;
    color: var(--text-gray);
    flex-grow: 1;
}

.liquor-points {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: 15px;
    padding-top: 15px;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.points-value {
    color: var(--accent-gold);
    font-weight: bold;
    font-size: 1.2rem;
}

.liquor-action {
    margin-top: 15px;
}

.liquor-action .btn {
    width: 100%;
    text-align: center;
}

.no-liquors {
    grid-column: 1 / -1;
    text-align: center;
    padding: 60px 20px;
    color: var(--text-gray);
}

.no-liquors i {
    font-size: 4rem;
    margin-bottom: 20px;
    display: block;
}

/* 响应式设计 */
@media (max-width: 768px) {
    .liquor-grid {
        grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
        gap: 20px;
    }

    .liquor-image {
        height: 180px;
        font-size: 3rem;
    }

    .liquor-info {
        padding: 15px;
    }
}

/* 用户积分样式 */
.user-points {
    background: linear-gradient(to right, var(--primary-light), var(--primary-dark));
    border-radius: 15px;
    padding: 30px;
    margin-bottom: 60px;
    text-align: center;
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.1);
}

.points-display {
    font-size: 3rem;
    color: var(--accent-gold);
    margin: 20px 0;
    font-weight: bold;
}

/* 页脚样式 */
footer {
    background-color: var(--primary-dark);
    padding: 60px 0 30px;
    margin-top: 60px;
}

.footer-content {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 40px;
    margin-bottom: 40px;
}

.footer-column h3 {
    color: var(--accent-gold);
    margin-bottom: 20px;
    font-size: 1.3rem;
}

.footer-links {
    list-style: none;
}

.footer-links li {
    margin-bottom: 10px;
}

.footer-links a {
    color: var(--text-gray);
    text-decoration: none;
    transition: color 0.3s;
}

.footer-links a:hover {
    color: var(--accent-gold);
}

.copyright {
    text-align: center;
    color: var(--text-gray);
    padding-top: 30px;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
}

/* 响应式设计 */
@media (max-width: 768px) {
    .navbar {
        flex-direction: column;
        padding: 15px 0;
    }

    .nav-links {
        margin-top: 20px;
        flex-wrap: wrap;
        justify-content: center;
    }

    .nav-links li {
        margin: 0 10px 10px;
    }

    .auth-buttons {
        margin-top: 20px;
    }

    .hero h1 {
        font-size: 2.5rem;
    }

    .hero-buttons {
        flex-direction: column;
        align-items: center;
    }

    .submission-form {
        padding: 25px;
    }
}

.user-welcome {
    color: var(--accent-gold);
    margin-right: 15px;
    font-weight: 500;
}

/* 登录提示样式 */
.login-prompt {
    text-align: center;
    padding: 40px;
    background-color: var(--card-bg);
    border-radius: 15px;
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.1);
}

.login-prompt p {
    font-size: 1.2rem;
    margin-bottom: 20px;
}

.login-prompt a {
    color: var(--accent-gold);
    text-decoration: none;
    font-weight: bold;
}

.login-prompt a:hover {
    text-decoration: underline;
}

/* 消息提示样式 */
.messages {
    margin-bottom: 20px;
}

.alert {
    padding: 15px;
    border-radius: 5px;
    margin-bottom: 10px;
}

.alert-success {
    background-color: #d4edda;
    color: #155724;
    border: 1px solid #c3e6cb;
}

.alert-error {
    background-color: #f8d7da;
    color: #721c24;
    border: 1px solid #f5c6cb;
}

.alert-warning {
    background-color: #fff3cd;
    color: #856404;
    border: 1px solid #ffeeba;
}

.alert-info {
    background-color: #d1ecf1;
    color: #0c5460;
    border: 1px solid #bee5eb;
}

/* 确保模态框默认隐藏 */
.modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.7);
    z-index: 1000;
    overflow-y: auto;
    padding: 20px;
}

/* 筛选栏样式 */
.filters {
    background-color: var(--card-bg);
    border-radius: 15px;
    padding: 20px;
    margin-bottom: 30px;
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.1);
}

.filter-group {
    display: flex;
    flex-wrap: wrap;
    gap: 15px;
    align-items: center;
}

.filter-item {
    display: flex;
    align-items: center;
}

.filter-item label {
    margin-right: 8px;
    color: var(--text-gray);
}

.filter-select {
    padding: 10px 15px;
    background-color: var(--card-bg);
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 8px;
    color: var(--text-light);
    min-width: 150px;
}

/* 模态框内容样式 */
.modal-content {
    background-color: var(--card-bg);
    border-radius: 15px;
    max-width: 600px;
    margin: 50px auto;
    box-shadow: 0 15px 30px rgba(0, 0, 0, 0.3);
    animation: modalFadeIn 0.3s;
}

@keyframes modalFadeIn {
    from { opacity: 0; transform: translateY(-50px); }
    to { opacity: 1; transform: translateY(0); }
}

.modal-header {
    padding: 20px 25px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.modal-header h2 {
    color: var(--accent-gold);
    font-size: 1.5rem;
}

.close-modal {
    background: none;
    border: none;
    color: var(--text-light);
    font-size: 1.5rem;
    cursor: pointer;
}

.modal-body {
    padding: 25px;
}

.exchange-info {
    display: flex;
    margin-bottom: 25px;
}

.exchange-image {
    width: 120px;
    height: 120px;
    background-color: #2a2a40;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--text-gray);
    font-size: 2.5rem;
    border-radius: 10px;
    margin-right: 20px;
    overflow: hidden; /* 添加溢出隐藏 */
    position: relative;
}

.exchange-image i {
    transition: all 0.3s ease;
}

.exchange-details {
    flex: 1;
}

.exchange-details h3 {
    font-size: 1.4rem;
    margin-bottom: 10px;
}

.exchange-points {
    color: var(--accent-gold);
    font-size: 1.2rem;
    font-weight: bold;
    margin-bottom: 15px;
}

.user-points-remaining {
    color: var(--text-gray);
    font-size: 0.9rem;
}

.form-row {
    display: flex;
    gap: 15px;
}

.form-row .form-group {
    flex: 1;
}

.modal-footer {
    padding: 20px 25px;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    text-align: right;
}

.btn-confirm {
    background-color: var(--accent-red);
    color: var(--text-light);
    padding: 12px 25px;
    font-size: 1rem;
}

.btn-confirm:hover {
    background-color: #b34a4a;
}

/* 酒品标签样式 */
.liquor-tag {
    position: absolute;
    top: 15px;
    right: 15px;
    background-color: var(--accent-gold);
    color: var(--primary-dark);
    padding: 5px 10px;
    border-radius: 20px;
    font-size: 0.8rem;
    font-weight: bold;
}

/* 响应式设计 */
@media (max-width: 768px) {
    .filter-group {
        flex-direction: column;
        align-items: flex-start;
    }

    .filter-item {
        width: 100%;
    }

    .filter-select {
        width: 100%;
    }

    .exchange-info {
        flex-direction: column;
        text-align: center;
    }

    .exchange-image {
        width: 100%;
        height: 100px;
        margin-right: 0;
        margin-bottom: 15px;
        font-size: 2rem;
    }

    .form-row {
        flex-direction: column;
        gap: 0;
    }
}

/* 兑换按钮样式 */
.btn-exchange {
    background-color: var(--accent-red);
    color: var(--text-light);
    padding: 8px 15px;
    border-radius: 20px;
    font-size: 0.9rem;
    border: none;
    cursor: pointer;
    text-decoration: none;
    display: inline-block;
    text-align: center;
}

.btn-exchange:disabled {
    background-color: #6c757d;
    cursor: not-allowed;
}

.btn-exchange:hover:not(:disabled) {
    background-color: #b34a4a;
}

/* 字数计数器样式 */
.character-count {
    text-align: right;
    font-size: 0.8rem;
    color: var(--text-gray);
    margin-top: 5px;
}

.character-count span {
    font-weight: bold;
}

/* 超过字数限制时的样式 */
.character-count.over-limit {
    color: var(--accent-red);
}

.character-count.over-limit span {
    color: var(--accent-red);
}

/* 导航栏用户头像样式 */
.user-profile-nav {
    display: flex;
    align-items: center;
    margin-right: 15px;
}

.user-profile-link {
    display: flex;
    align-items: center;
    text-decoration: none;
    color: var(--text-light);
    transition: all 0.3s ease;
    padding: 5px 10px;
    border-radius: 20px;
}

/* 添加点击反馈 */
.user-profile-link:active {
    transform: scale(0.95);
}

.user-profile-link:hover {
    background-color: rgba(200, 169, 113, 0.1);
    color: var(--accent-gold);
    transform: translateY(-2px);
}

.user-profile-link:hover .user-name-nav {
    color: var(--text-light);
}

.user-profile-link:hover .user-avatar-nav {
    transform: scale(1.1);
    box-shadow: 0 0 10px rgba(200, 169, 113, 0.5);
}

.user-avatar-nav {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    overflow: hidden;
    margin-right: 8px;
    border: 2px solid var(--accent-gold);
    transition: all 0.3s ease;
}

.nav-avatar {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.user-name-nav {
    font-weight: 500;
    color: var(--accent-gold);
    transition: color 0.3s;
}



/* 响应式设计 */
@media (max-width: 768px) {
    .user-profile-nav {
        margin-right: 10px;
    }

    .user-profile-link {
        padding: 3px 8px;
    }

    .user-avatar-nav {
        width: 28px;
        height: 28px;
        margin-right: 6px;
    }

    .user-name-nav {
        font-size: 0.9rem;
    }
}

/* 投稿次数提示样式 */
.contribution-limit-info {
    margin-bottom: 25px;
}

.limit-header {
    display: flex;
    align-items: center;
    margin-bottom: 15px;
}

.limit-header i {
    font-size: 1.5rem;
    color: var(--accent-gold);
    margin-right: 10px;
}

.limit-header h4 {
    margin: 0;
    color: var(--accent-gold);
    font-size: 1.1rem;
}

.limit-count {
    font-size: 2rem;
    font-weight: bold;
    margin-bottom: 10px;
}

.current-count {
    color: var(--text-light);
}

.separator {
    color: var(--text-gray);
    margin: 0 5px;
}

.max-count {
    color: var(--accent-gold);
}

.limit-text {
    color: var(--text-gray);
    font-size: 0.9rem;
    margin-bottom: 10px;
}

.limit-warning {
    color: var(--accent-red);
    font-size: 0.9rem;
    background-color: rgba(157, 59, 59, 0.2);
    padding: 8px 12px;
    border-radius: 5px;
    display: inline-flex;
    align-items: center;
    gap: 5px;
}

/* 禁用状态样式 */
.form-control:disabled,
.form-control[disabled] {
    background-color: rgba(26, 26, 46, 0.3);
    color: var(--text-gray);
    cursor: not-allowed;
    opacity: 0.6;
}

.btn:disabled,
.btn[disabled] {
    background-color: #6c757d;
    cursor: not-allowed;
    opacity: 0.6;
}

.btn:disabled:hover,
.btn[disabled]:hover {
    transform: none;
    box-shadow: none;
}

/* 响应式设计 */
@media (max-width: 768px) {
    .limit-count {
        font-size: 1.5rem;
    }

    .limit-header {
        flex-direction: column;
        text-align: center;
        gap: 10px;
    }

    .limit-header i {
        margin-right: 0;
    }
}

.remaining-text {
    color: var(--text-gray);
    font-size: 0.9rem;
    margin-top: 5px;
}

.remaining-count {
    color: var(--accent-gold);
    font-weight: bold;
}