/* 行程页面专用样式 */

.itinerary-header {
    background: linear-gradient(135deg, rgba(61, 178, 255, 0.1) 0%, rgba(255, 189, 57, 0.1) 100%);
    padding: 40px 20px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.2);
}

.itinerary-content {
    padding: 0;
    background: #f8f9fa;
    min-height: calc(100vh - 200px);
}

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

.header-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 20px;
}

.trip-info h1 {
    font-size: 2.5rem;
    font-weight: 700;
    color: #333;
    margin-bottom: 16px;
}

.trip-meta {
    display: flex;
    gap: 24px;
    flex-wrap: wrap;
}

.trip-meta span {
    display: flex;
    align-items: center;
    gap: 8px;
    color: #666;
    font-size: 14px;
}

.trip-meta i {
    color: #3DB2FF;
    font-size: 16px;
}

.trip-actions {
    display: flex;
    gap: 12px;
    flex-wrap: wrap;
}

.btn-action {
    background: rgba(255, 255, 255, 0.9);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.2);
    color: #333;
    padding: 12px 20px;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    gap: 8px;
    font-weight: 500;
}

.btn-action:hover {
    background: #3DB2FF;
    color: white;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(61, 178, 255, 0.3);
}

/* 内容布局 */
.content-layout {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 0;
    min-height: calc(100vh - 200px);
}

.timeline-panel,
.map-panel {
    background: white;
    border-radius: 0;
    overflow: hidden;
}

.timeline-panel {
    border-right: 1px solid #e1e5e9;
}

.panel-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 24px;
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    border-bottom: 1px solid #e1e5e9;
}

.panel-header h2 {
    font-size: 1.5rem;
    font-weight: 600;
    color: #333;
}

.timeline-controls,
.map-controls {
    display: flex;
    gap: 8px;
}

.btn-control {
    background: #f8f9fa;
    border: 1px solid #e1e5e9;
    color: #666;
    width: 36px;
    height: 36px;
    border-radius: 6px;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
}

.btn-control:hover {
    background: #3DB2FF;
    color: white;
    border-color: #3DB2FF;
}

/* 时间轴样式 */
.timeline-container {
    height: calc(100vh - 300px);
    overflow-y: auto;
    padding: 0;
}

.timeline {
    padding: 0;
}

.timeline-day {
    border-bottom: 1px solid #e1e5e9;
    transition: all 0.3s ease;
}

.timeline-day.active {
    background: rgba(61, 178, 255, 0.05);
}

.day-header {
    padding: 20px 24px;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.day-header:hover {
    background: rgba(61, 178, 255, 0.05);
}

.day-info {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.day-number {
    font-size: 1.1rem;
    font-weight: 600;
    color: #3DB2FF;
}

.day-date {
    font-size: 12px;
    color: #999;
}

.day-summary {
    flex: 1;
    margin: 0 20px;
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.day-title {
    font-size: 14px;
    color: #333;
    font-weight: 500;
}

.day-duration {
    font-size: 12px;
    color: #666;
}

.day-toggle {
    color: #999;
    transition: transform 0.3s ease;
}

.timeline-day.active .day-toggle {
    transform: rotate(180deg);
}

.day-content {
    display: none;
    padding: 0 24px 20px;
    background: rgba(248, 249, 250, 0.5);
}

.timeline-day.active .day-content {
    display: block;
}

.timeline-item {
    display: flex;
    gap: 16px;
    padding: 16px 0;
    border-bottom: 1px solid rgba(225, 229, 233, 0.5);
    transition: all 0.3s ease;
}

.timeline-item:hover {
    background: rgba(61, 178, 255, 0.05);
    border-radius: 8px;
    padding-left: 8px;
    padding-right: 8px;
}

.timeline-item:last-child {
    border-bottom: none;
}

.item-time {
    font-size: 12px;
    color: #666;
    font-weight: 500;
    min-width: 50px;
    text-align: center;
    padding-top: 4px;
}

.item-marker {
    position: relative;
    display: flex;
    flex-direction: column;
    align-items: center;
    min-width: 20px;
}

.marker-dot {
    width: 12px;
    height: 12px;
    background: #3DB2FF;
    border-radius: 50%;
    border: 3px solid white;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
    z-index: 2;
}

.marker-line {
    width: 2px;
    height: 40px;
    background: #e1e5e9;
    margin-top: 4px;
}

.timeline-item:last-child .marker-line {
    display: none;
}

.item-content {
    flex: 1;
}

.item-title {
    font-size: 1rem;
    font-weight: 600;
    color: #333;
    margin-bottom: 4px;
}

.item-description {
    font-size: 14px;
    color: #666;
    margin-bottom: 8px;
    line-height: 1.4;
}

.item-duration {
    font-size: 12px;
    color: #999;
    margin-bottom: 12px;
}

.item-actions {
    display: flex;
    gap: 8px;
}

.btn-small {
    background: #f8f9fa;
    border: 1px solid #e1e5e9;
    color: #666;
    padding: 6px 12px;
    border-radius: 6px;
    cursor: pointer;
    transition: all 0.3s ease;
    font-size: 12px;
    display: flex;
    align-items: center;
    gap: 4px;
}

.btn-small:hover {
    background: #3DB2FF;
    color: white;
    border-color: #3DB2FF;
}

/* 地图样式 */
.map-container {
    height: calc(100vh - 200px);
    position: relative;
}

#map {
    width: 100%;
    height: 100%;
}

/* 景点详情卡片 */
.attraction-details {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    border-top: 1px solid rgba(255, 255, 255, 0.2);
    transform: translateY(100%);
    transition: transform 0.3s ease;
    max-height: 50vh;
    overflow-y: auto;
}

.attraction-details.show {
    transform: translateY(0);
}

.details-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px 24px;
    border-bottom: 1px solid #e1e5e9;
}

.details-header h3 {
    font-size: 1.2rem;
    font-weight: 600;
    color: #333;
}

.close-details {
    background: none;
    border: none;
    color: #999;
    cursor: pointer;
    font-size: 18px;
    transition: color 0.3s ease;
}

.close-details:hover {
    color: #333;
}

.details-content {
    padding: 24px;
}

.attraction-image {
    margin-bottom: 16px;
}

.attraction-image img {
    width: 100%;
    height: 150px;
    object-fit: cover;
    border-radius: 8px;
}

.attraction-info {
    display: flex;
    flex-direction: column;
    gap: 8px;
    margin-bottom: 16px;
}

.info-item {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 14px;
    color: #666;
}

.info-item i {
    color: #3DB2FF;
    width: 16px;
}

.attraction-description {
    margin-bottom: 20px;
}

.attraction-description p {
    font-size: 14px;
    color: #666;
    line-height: 1.5;
}

.attraction-actions {
    display: flex;
    gap: 12px;
}

.btn-primary,
.btn-secondary {
    flex: 1;
    padding: 12px 16px;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    font-weight: 500;
}

.btn-primary {
    background: #3DB2FF;
    color: white;
    border: none;
}

.btn-primary:hover {
    background: #2A9BFF;
    transform: translateY(-1px);
}

.btn-secondary {
    background: rgba(255, 255, 255, 0.8);
    color: #666;
    border: 1px solid #e1e5e9;
}

.btn-secondary:hover {
    background: #f8f9fa;
    border-color: #3DB2FF;
    color: #3DB2FF;
}

/* 景点数据 */
.attractions-data {
    display: none;
}

/* 响应式设计 */
@media (max-width: 1024px) {
    .content-layout {
        grid-template-columns: 1fr;
        grid-template-rows: auto 1fr;
    }
    
    .timeline-panel {
        border-right: none;
        border-bottom: 1px solid #e1e5e9;
    }
    
    .timeline-container {
        height: 400px;
    }
    
    .map-container {
        height: 400px;
    }
}

@media (max-width: 768px) {
    .header-content {
        flex-direction: column;
        align-items: flex-start;
    }
    
    .trip-info h1 {
        font-size: 2rem;
    }
    
    .trip-meta {
        flex-direction: column;
        gap: 12px;
    }
    
    .trip-actions {
        width: 100%;
        justify-content: center;
    }
    
    .btn-action {
        flex: 1;
        justify-content: center;
    }
    
    .timeline-container {
        height: 300px;
    }
    
    .map-container {
        height: 300px;
    }
    
    .day-header {
        padding: 16px 20px;
    }
    
    .day-summary {
        margin: 0 12px;
    }
    
    .timeline-item {
        padding: 12px 0;
    }
    
    .item-actions {
        flex-direction: column;
    }
    
    .btn-small {
        justify-content: center;
    }
}

@media (max-width: 480px) {
    .container {
        padding: 0 10px;
    }
    
    .trip-info h1 {
        font-size: 1.5rem;
    }
    
    .panel-header {
        padding: 16px 20px;
    }
    
    .panel-header h2 {
        font-size: 1.2rem;
    }
    
    .timeline-container {
        height: 250px;
    }
    
    .map-container {
        height: 250px;
    }
    
    .day-header {
        padding: 12px 16px;
    }
    
    .timeline-item {
        padding: 8px 0;
    }
    
    .item-time {
        min-width: 40px;
        font-size: 11px;
    }
    
    .marker-dot {
        width: 10px;
        height: 10px;
    }
    
    .attraction-actions {
        flex-direction: column;
    }
}

/* 滚动条样式 */
.timeline-container::-webkit-scrollbar {
    width: 6px;
}

.timeline-container::-webkit-scrollbar-track {
    background: #f1f1f1;
}

.timeline-container::-webkit-scrollbar-thumb {
    background: #c1c1c1;
    border-radius: 3px;
}

.timeline-container::-webkit-scrollbar-thumb:hover {
    background: #a8a8a8;
}

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

.timeline-item {
    animation: fadeInUp 0.3s ease;
}

/* 地图标记样式 */
.attraction-marker {
    background: #3DB2FF;
    color: white;
    border-radius: 50%;
    width: 30px;
    height: 30px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 12px;
    font-weight: bold;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.2);
    cursor: pointer;
    transition: all 0.3s ease;
}

.attraction-marker:hover {
    transform: scale(1.1);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
}

.attraction-marker.active {
    background: #FFBD39;
    transform: scale(1.2);
}

/* 路线样式 */
.route-line {
    stroke: #3DB2FF;
    stroke-width: 4;
    stroke-dasharray: 10, 5;
    animation: dash 2s linear infinite;
}

@keyframes dash {
    to {
        stroke-dashoffset: -15;
    }
}
