/* style.css - Resort Page Styles with 3D Canvas */
:root {
    --primary: #2ad4ff;
    --primary-dark: #1aa0c0;
    --secondary: #ffd966;
    --dark: #02121c;
    --dark-light: #0a2835;
    --text: #e6f3ff;
    --text-muted: #9bb7d4;
    --gradient: linear-gradient(135deg, #2ad4ff, #7b68ee);
    --card-bg: rgba(10, 40, 55, 0.7);
    --navbar-bg: rgba(2, 18, 28, 0.85);
    --border: rgba(255, 255, 255, 0.1);
}

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

body {
    font-family: 'Inter', sans-serif;
    background-color: var(--dark);
    color: var(--text);
    line-height: 1.6;
    overflow-x: hidden;
}

/* ========================================= */
/* 导航栏切换按钮 */
/* ========================================= */
.nav-toggle-btn {
    position: fixed;
    top: 20px;
    left: 20px;
    z-index: 1001;
    width: 44px;
    height: 44px;
    border-radius: 50%;
    background: var(--card-bg);
    backdrop-filter: blur(10px);
    border: 1px solid var(--border);
    color: var(--text);
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.2, 0.8, 0.2, 1);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
}

.nav-toggle-btn:hover {
    border-color: var(--primary);
    color: var(--primary);
    transform: scale(1.05);
}

/* ========================================= */
/* 侧边导航栏 */
/* ========================================= */
.sidebar {
    position: fixed;
    top: 0;
    left: 0;
    width: 280px;
    height: 100vh;
    background: var(--navbar-bg);
    backdrop-filter: blur(16px);
    border-right: 1px solid var(--border);
    padding: 80px 30px 30px 30px;
    display: flex;
    flex-direction: column;
    z-index: 1000;
    transition: transform 0.4s cubic-bezier(0.2, 0.8, 0.2, 1);
    transform: translateX(0);
}

.sidebar.hidden {
    transform: translateX(-100%);
}

.logo {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 1.5rem;
    font-weight: 600;
    color: var(--text);
    margin-bottom: 50px;
    transition: transform 0.3s cubic-bezier(0.2, 0.8, 0.2, 1);
}

.logo:hover {
    transform: scale(1.05) translateY(-2px);
    text-shadow: 0 4px 12px rgba(42, 212, 255, 0.4);
}

.logo-icon {
    font-size: 1.8rem;
    display: inline-block;
    animation: iconFloat 3.5s ease-in-out infinite;
}

.logo-highlight {
    color: var(--primary);
    margin-left: 4px;
}

@keyframes iconFloat {
    0%, 100% {
        transform: translateY(0) rotate(0deg);
    }
    50% {
        transform: translateY(-6px) rotate(5deg);
    }
}

.nav-links {
    display: flex;
    flex-direction: column;
    gap: 24px;
}

.nav-link {
    color: var(--text-muted);
    text-decoration: none;
    font-weight: 500;
    font-size: 1.1rem;
    position: relative;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
}

.nav-link:hover,
.nav-link.active {
    color: var(--primary);
    transform: translateX(8px);
}

.nav-link::after {
    content: '';
    position: absolute;
    bottom: -4px;
    left: 0;
    width: 0;
    height: 2px;
    background: var(--primary);
    transition: width 0.3s ease;
}

.nav-link:hover::after,
.nav-link.active::after {
    width: 20px;
}

/* ========================================= */
/* 主要内容区域 */
/* ========================================= */
.resort-main {
    margin-left: 280px;
    transition: margin-left 0.4s cubic-bezier(0.2, 0.8, 0.2, 1);
    min-height: 100vh;
}

.sidebar.hidden ~ .resort-main {
    margin-left: 0;
}

/* Hero 区域 - 3D画布 */
.hero-section {
    position: relative;
    height: 90vh;
    min-height: 600px;
    overflow: hidden;
}

.hero-canvas {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 0;
}

.hero-canvas canvas {
    display: block;
    width: 100%;
    height: 100%;
}

.hero-content {
    position: relative;
    z-index: 2;
    max-width: 700px;
    padding: 120px 60px 80px;
    background: linear-gradient(90deg, rgba(2, 18, 28, 0.85) 0%, rgba(2, 18, 28, 0.6) 50%, transparent 100%);
    height: 100%;
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.hero-title {
    font-size: clamp(3rem, 6vw, 5rem);
    line-height: 1.1;
    letter-spacing: -2px;
    margin-bottom: 1.5rem;
}

.hero-title .light-line {
    font-weight: 400;
    display: block;
    color: var(--text);
    opacity: 0.9;
}

.hero-title .heavy-line {
    font-weight: 800;
    display: block;
}

.gradient-text {
    background: var(--gradient);
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
}

.hero-subtitle {
    font-size: 1.1rem;
    color: var(--text-muted);
    margin-bottom: 2rem;
    max-width: 550px;
    line-height: 1.6;
}

.hero-stats {
    display: flex;
    gap: 48px;
}

.stat-item {
    display: flex;
    flex-direction: column;
}

.stat-number {
    font-size: 2.2rem;
    font-weight: 800;
    color: var(--primary);
    line-height: 1;
}

.stat-label {
    font-size: 0.85rem;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 1px;
    margin-top: 4px;
}

/* 筛选栏 */
.filter-section {
    background: var(--dark-light);
    border-bottom: 1px solid var(--border);
    padding: 20px 0;
    position: sticky;
    top: 0;
    z-index: 99;
    backdrop-filter: blur(10px);
}

.filter-bar {
    display: flex;
    gap: 20px;
    flex-wrap: wrap;
    justify-content: center;
}

.filter-group {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.filter-group label {
    font-size: 0.8rem;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 1px;
    font-weight: 500;
}

.filter-select {
    background: var(--card-bg);
    border: 1px solid var(--border);
    border-radius: 12px;
    padding: 10px 16px;
    color: var(--text);
    font-family: 'Inter', sans-serif;
    font-size: 0.9rem;
    cursor: pointer;
    transition: all 0.3s ease;
    min-width: 140px;
}

.filter-select:hover,
.filter-select:focus {
    border-color: var(--primary);
    outline: none;
}

/* 度假村列表 */
.resorts-section {
    padding: 60px 0;
}

.container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 24px;
}

.section-header {
    text-align: center;
    margin-bottom: 48px;
}

.section-header h2 {
    font-size: 2.5rem;
    font-weight: 600;
    margin-bottom: 12px;
}

.section-header p {
    color: var(--text-muted);
    font-size: 1rem;
}

/* 度假村网格 */
.resorts-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(350px, 1fr));
    gap: 30px;
}

/* 度假村卡片 */
.resort-card {
    background: var(--card-bg);
    backdrop-filter: blur(10px);
    border: 1px solid var(--border);
    border-radius: 24px;
    overflow: hidden;
    transition: all 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
    cursor: pointer;
}

.resort-card:hover {
    transform: translateY(-8px);
    border-color: var(--primary);
    box-shadow: 0 20px 40px rgba(42, 212, 255, 0.2);
}

.resort-image {
    width: 100%;
    height: 220px;
    object-fit: cover;
    transition: transform 0.5s ease;
}

.resort-card:hover .resort-image {
    transform: scale(1.05);
}

.resort-info {
    padding: 20px;
}

.resort-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 12px;
}

.resort-name {
    font-size: 1.3rem;
    font-weight: 600;
    color: var(--text);
}

.resort-rating {
    display: flex;
    align-items: center;
    gap: 4px;
    background: rgba(42, 212, 255, 0.2);
    padding: 4px 8px;
    border-radius: 20px;
}

.resort-rating span {
    font-size: 0.85rem;
    font-weight: 600;
    color: var(--primary);
}

.resort-location {
    font-size: 0.85rem;
    color: var(--text-muted);
    margin-bottom: 12px;
    display: flex;
    align-items: center;
    gap: 6px;
}

.resort-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-bottom: 16px;
}

.resort-tag {
    background: var(--dark-light);
    padding: 4px 12px;
    border-radius: 20px;
    font-size: 0.75rem;
    color: var(--primary);
}

.resort-price {
    font-size: 1.2rem;
    font-weight: 700;
    color: var(--primary);
    margin-bottom: 16px;
}

.resort-price small {
    font-size: 0.8rem;
    font-weight: 400;
    color: var(--text-muted);
}

.resort-description {
    font-size: 0.85rem;
    color: var(--text-muted);
    line-height: 1.5;
    margin-bottom: 16px;
}

.resort-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding-top: 12px;
    border-top: 1px solid var(--border);
}

.resort-features {
    display: flex;
    gap: 12px;
    font-size: 0.75rem;
    color: var(--text-muted);
}

.resort-features span {
    display: flex;
    align-items: center;
    gap: 4px;
}

.btn-book {
    background: transparent;
    border: 1px solid var(--primary);
    color: var(--primary);
    padding: 8px 20px;
    border-radius: 30px;
    font-size: 0.85rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
}

.btn-book:hover {
    background: var(--primary);
    color: var(--dark);
}

/* 加载动画 */
.loading-spinner {
    text-align: center;
    padding: 40px;
}

.spinner {
    width: 40px;
    height: 40px;
    border: 3px solid var(--border);
    border-top-color: var(--primary);
    border-radius: 50%;
    animation: spin 1s linear infinite;
    margin: 0 auto 16px;
}

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

/* 移动端响应式 */
@media (max-width: 768px) {
    .nav-toggle-btn {
        top: 12px;
        left: auto;
        right: 16px;
    }

    .sidebar {
        width: 100%;
        height: auto;
        padding: 16px 60px 16px 20px;
        border-right: none;
        border-bottom: 1px solid var(--border);
        transform: translateY(0);
    }

    .sidebar.hidden {
        transform: translateY(-100%);
    }

    .logo {
        margin-bottom: 16px;
        font-size: 1.3rem;
    }

    .nav-links {
        flex-direction: row;
        overflow-x: auto;
        gap: 20px;
        padding-bottom: 8px;
    }

    .nav-links::-webkit-scrollbar {
        display: none;
    }

    .nav-link {
        white-space: nowrap;
        font-size: 1rem;
    }

    .nav-link:hover,
    .nav-link.active {
        transform: translateX(0);
    }

    .resort-main {
        margin-left: 0;
    }

    .hero-section {
        height: 70vh;
        min-height: 500px;
    }

    .hero-content {
        padding: 100px 20px 60px;
        background: linear-gradient(90deg, rgba(2, 18, 28, 0.9) 0%, transparent 100%);
    }

    .hero-stats {
        gap: 24px;
        flex-wrap: wrap;
    }

    .filter-bar {
        gap: 12px;
        padding: 0 16px;
    }

    .filter-select {
        min-width: 120px;
        font-size: 0.8rem;
    }

    .resorts-grid {
        grid-template-columns: 1fr;
        gap: 20px;
    }

    .container {
        padding: 0 16px;
    }
}

/* 空状态 */
.no-results {
    text-align: center;
    padding: 60px 20px;
    color: var(--text-muted);
}

.no-results h3 {
    font-size: 1.5rem;
    margin-bottom: 12px;
    color: var(--text);
}

.no-results p {
    margin-bottom: 24px;
}

.reset-btn {
    background: var(--primary);
    border: none;
    color: var(--dark);
    padding: 10px 24px;
    border-radius: 30px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
}

.reset-btn:hover {
    background: var(--primary-dark);
    transform: translateY(-2px);
}