/* 基础样式 */
:root {
    --primary-color: #FF9A8B;
    --secondary-color: #FF6B95;
    --accent-color: #4CC9F0;
    --light-color: #FFF5F5;
    --dark-color: #333;
    --shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
}

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

body {
    font-family: 'Comic Neue', cursive;
    line-height: 1.6;
    color: var(--dark-color);
    background-color: var(--light-color);
}

.container {
    width: 90%;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 15px;
}

/* 标题使用卡通中文字体 */
h1, h2, h3 {
    font-family: 'Ma Shan Zheng', cursive;
    font-weight: normal;
}

/* 头部样式 */
header {
    background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
    color: white;
    text-align: center;
    padding: 2rem 0;
    box-shadow: var(--shadow);
}

header h1 {
    font-size: 2.5rem;
    margin-bottom: 0.5rem;
}

/* 导航栏 */
nav {
    background-color: white;
    box-shadow: var(--shadow);
    position: sticky;
    top: 0;
    z-index: 100;
}

nav ul {
    display: flex;
    list-style: none;
    justify-content: center;
}

nav li {
    margin: 0 1rem;
}

nav a {
    display: block;
    padding: 1rem;
    text-decoration: none;
    color: var(--dark-color);
    font-weight: bold;
    transition: all 0.3s ease;
}

nav a:hover, nav a.active {
    color: var(--secondary-color);
    transform: translateY(-3px);
}

/* 筛选区域 */
.filter-section {
    text-align: center;
    margin: 2rem 0;
}

.filter-options {
    margin-top: 1rem;
}

select {
    padding: 0.5rem;
    border-radius: 20px;
    border: 2px solid var(--primary-color);
    font-family: inherit;
    background-color: white;
    cursor: pointer;
}

/* 猫猫卡片网格 */
.cats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
    gap: 2rem;
    margin: 2rem 0;
}

.cat-card {
    background-color: white;
    border-radius: 15px;
    overflow: hidden;
    box-shadow: var(--shadow);
    transition: transform 0.3s ease;
    cursor: pointer;
}

.cat-card:hover {
    transform: translateY(-10px) scale(1.03);
}

.cat-avatar {
    width: 100%;
    height: 200px;
    object-fit: cover;
}

.cat-info {
    padding: 1rem;
}

.cat-info h3 {
    color: var(--secondary-color);
    margin-bottom: 0.5rem;
}

.cat-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    margin-bottom: 0.5rem;
}

.cat-meta span {
    background-color: var(--light-color);
    padding: 0.2rem 0.5rem;
    border-radius: 15px;
    font-size: 0.8rem;
}

/* 模态框样式 */
.cat-modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.8);
    z-index: 1000;
    overflow-y: auto;
}

.modal-content {
    background-color: white;
    margin: 2rem auto;
    width: 90%;
    max-width: 800px;
    border-radius: 15px;
    overflow: hidden;
    animation: modalFadeIn 0.3s;
}

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

.close-modal {
    position: absolute;
    top: 1rem;
    right: 1.5rem;
    font-size: 2rem;
    color: var(--dark-color);
    cursor: pointer;
    transition: transform 0.3s ease;
}

.close-modal:hover {
    transform: rotate(90deg);
    color: var(--secondary-color);
}

.modal-header {
    display: flex;
    align-items: center;
    padding: 1.5rem;
    background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
    color: white;
}

.modal-header img {
    width: 100px;
    height: 100px;
    border-radius: 50%;
    object-fit: cover;
    border: 3px solid white;
    margin-right: 1.5rem;
}

.modal-body {
    padding: 1.5rem;
}

.gallery {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
    gap: 1rem;
    margin-top: 1rem;
}

.gallery img {
    width: 100%;
    height: 150px;
    object-fit: cover;
    border-radius: 10px;
    transition: transform 0.3s ease;
    cursor: pointer;
}

.gallery img:hover {
    transform: scale(1.05);
}

/* 页脚样式 */
footer {
    background-color: var(--dark-color);
    color: white;
    text-align: center;
    padding: 2rem 0;
    margin-top: 2rem;
}

/* 响应式设计 */
@media (max-width: 768px) {
    .cats-grid {
        grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    }
    
    .modal-header {
        flex-direction: column;
        text-align: center;
    }
    
    .modal-header img {
        margin-right: 0;
        margin-bottom: 1rem;
    }
}

@media (max-width: 480px) {
    nav ul {
        flex-direction: column;
        align-items: center;
    }
    
    .cats-grid {
        grid-template-columns: 1fr;
    }
}

/* 关于我们页面特定样式 */
.about-section {
    padding: 2rem 0;
}

.mission-card {
    background-color: white;
    padding: 1.5rem;
    border-radius: 15px;
    margin: 1.5rem 0;
    box-shadow: var(--shadow);
}

.mission-card ul {
    margin-top: 1rem;
    padding-left: 1.5rem;
}

.mission-card li {
    margin-bottom: 0.5rem;
}

.tips-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
    gap: 1.5rem;
    margin: 1.5rem 0;
}

.tip-card {
    background-color: white;
    padding: 1.2rem;
    border-radius: 15px;
    box-shadow: var(--shadow);
}

.tip-card h3 {
    color: var(--secondary-color);
    margin-bottom: 0.5rem;
}

.contact-info {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
    gap: 1.5rem;
    margin: 1.5rem 0;
}

.contact-card {
    background-color: white;
    padding: 1.2rem;
    border-radius: 15px;
    box-shadow: var(--shadow);
    text-align: center;
}

.contact-card h3 {
    color: var(--secondary-color);
    margin-bottom: 0.5rem;
}

.highlight {
    font-weight: bold;
    color: var(--primary-color);
    font-size: 1.1rem;
    margin: 0.5rem 0;
}

/* 领养指南页面特定样式 */
.adoption-section {
    padding: 2rem 0;
}

.preparation-steps {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
    gap: 1.5rem;
    margin: 1.5rem 0;
}

.step {
    background-color: white;
    padding: 1.2rem;
    border-radius: 15px;
    box-shadow: var(--shadow);
}

.step h3 {
    color: var(--secondary-color);
    margin-bottom: 0.5rem;
}

.adoption-process {
    background-color: white;
    padding: 1.5rem 2rem;
    border-radius: 15px;
    box-shadow: var(--shadow);
    margin: 1.5rem 0;
}

.adoption-process li {
    margin-bottom: 0.8rem;
}

.contact-person {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
    gap: 1.5rem;
    margin: 1.5rem 0;
}

.person-card {
    background-color: white;
    padding: 1.2rem;
    border-radius: 15px;
    box-shadow: var(--shadow);
    text-align: center;
}

.person-card h3 {
    color: var(--secondary-color);
    margin-bottom: 0.5rem;
}

.note-box {
    background-color: #FFF5E0;
    border-left: 4px solid var(--primary-color);
    padding: 1rem;
    margin: 2rem 0;
}

/* 捐助支持页面特定样式 */
.donation-section {
    padding: 2rem 0;
}

.usage-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
    gap: 1.5rem;
    margin: 1.5rem 0;
}

.usage-card {
    background-color: white;
    padding: 1.2rem;
    border-radius: 15px;
    box-shadow: var(--shadow);
}

.usage-card h3 {
    color: var(--secondary-color);
    margin-bottom: 0.5rem;
}

.progress-bar {
    width: 100%;
    height: 20px;
    background-color: #f0f0f0;
    border-radius: 10px;
    margin-top: 0.8rem;
    overflow: hidden;
}

.progress {
    height: 100%;
    background: linear-gradient(90deg, var(--primary-color), var(--secondary-color));
    color: white;
    font-size: 0.7rem;
    text-align: center;
    line-height: 20px;
}

.merchandise {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    gap: 1.5rem;
    margin: 1.5rem 0;
}

.product-card {
    background-color: white;
    padding: 1rem;
    border-radius: 15px;
    box-shadow: var(--shadow);
    text-align: center;
}

.product-card img {
    width: 100%;
    height: 180px;
    object-fit: cover;
    border-radius: 10px;
    margin-bottom: 0.8rem;
}

.product-card h3 {
    color: var(--secondary-color);
    margin-bottom: 0.3rem;
}

.price {
    color: var(--primary-color);
    font-weight: bold;
    margin-top: 0.5rem;
}

.payment-methods {
    display: flex;
    justify-content: center;
    gap: 2rem;
    margin: 1.5rem 0;
    flex-wrap: wrap;
}

.qrcode {
    text-align: center;
}

.qrcode img {
    width: 150px;
    height: 150px;
    margin-bottom: 0.5rem;
}

.donation-note {
    text-align: center;
    font-style: italic;
    color: #666;
}

.cooperation {
    background-color: white;
    padding: 1.5rem;
    border-radius: 15px;
    box-shadow: var(--shadow);
    margin: 1.5rem 0;
}

.cooperation ul {
    margin: 1rem 0 1.5rem 1.5rem;
}

.cooperation li {
    margin-bottom: 0.5rem;
}

/* 响应式调整 */
@media (max-width: 768px) {
    .tips-grid, .contact-info, .preparation-steps, 
    .contact-person, .usage-grid, .merchandise {
        grid-template-columns: 1fr;
    }
    
    .payment-methods {
        flex-direction: column;
        align-items: center;
    }
}