/* CSS变量定义 */
:root {
    --primary-color: #e74c3c;
    --secondary-color: #3498db;
    --dark-color: #333;
    --light-color: #f9f9f9;
    --white: #fff;
    --transition: all 0.3s ease;
    --shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
    --shadow-hover: 0 5px 15px rgba(0, 0, 0, 0.1);
}

/* 顶部联系信息 */
.top-contact {
    background-color: #333;
    color: white;
    text-align: right;
    padding: 8px 20px;
}

.top-contact a {
    color: white;
    text-decoration: none;
}

.top-contact p {
    font-size: 16px;
    width: 1200px;
    margin: 0 auto;
}

.top-contact i {
    margin: 0 8px 0 15px;
    color: var(--primary-color);
}

.top-contact i:first-child {
    margin-left: 0;
}

/* 全局样式 */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: ui-sans-serif, system-ui, sans-serif, Apple Color Emoji, Segoe UI Emoji, Segoe UI Symbol, Noto Color Emoji;
    line-height: 1.6;
    color: var(--dark-color);
}

/* 侧边栏导航 */
.side-navigation {
    position: fixed;
    right: 20px;
    top: 50%;
    transform: translateY(-50%);
    z-index: 9999;
    display: flex;
    flex-direction: column;
    gap: 15px;
    transition: transform 0.3s ease, opacity 0.3s ease;
}

.side-nav-item {
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 50px;
    height: 50px;
    background-color: var(--primary-color);
    border-radius: 50%;
    color: white;
    text-decoration: none;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.2);
    transition: all 0.3s ease;
    overflow: hidden;
}

.side-nav-item.whatsapp {
    background-color: #25D366;
}

.side-nav-item.email {
    background-color: #3498db;
}

.side-nav-item.top {
    background-color: #95a5a6;
}

.side-nav-item:hover {
    transform: scale(1.1);
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.3);
}

.side-nav-item i {
    font-size: 20px;
    z-index: 2;
}

.tooltip {
    position: absolute;
    right: 100%;
    margin-right: 15px;
    background-color: rgba(0, 0, 0, 0.8);
    color: white;
    padding: 8px 12px;
    border-radius: 4px;
    font-size: 14px;
    white-space: nowrap;
    transform: translateX(20px);
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
}

.side-nav-item:hover .tooltip {
    transform: translateX(0);
    opacity: 1;
    visibility: visible;
}

/* 平滑滚动 */
html {
    scroll-behavior: smooth;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
}

/* 导航栏样式 */
.navbar {
    background-color: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    box-shadow: var(--shadow);
    position: sticky;
    top: 0;
    z-index: 1000;
    transition: var(--transition);
}

.navbar.scrolled {
    background-color: var(--white);
    box-shadow: var(--shadow-hover);
    padding: 0.5rem 0;
}

.navbar .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1rem 0;
}

.navbar.scrolled .container {
    padding: 0.8rem 0;
}

.logo h1 {
    color: var(--primary-color);
    font-size: 1.8rem;
    transition: var(--transition);
}

.logo img {
  width: 120px;
}

.menu {
    display: flex;
    gap: 2rem;
}

.menu a {
    text-decoration: none;
    color: var(--dark-color);
    font-weight: 700;
    transition: var(--transition);
    position: relative;
    padding: 0.5rem 0;
    font-size: 20px;
}

.menu a::after {
    content: '';
    position: absolute;
    width: 0;
    height: 2px;
    bottom: 0;
    left: 0;
    background-color: var(--primary-color);
    transition: var(--transition);
}

.menu a:hover {
    color: var(--primary-color);
}

.menu a:hover::after {
    width: 100%;
}

.mobile-menu-btn {
    display: none;
    font-size: 1.5rem;
    cursor: pointer;
}

.mobile-menu {
    display: none;
    position: fixed;
    top: 0;
    right: -300px;
    width: 300px;
    height: 100vh;
    background-color: #fff;
    box-shadow: -2px 0 4px rgba(0, 0, 0, 0.1);
    z-index: 1001;
    transition: right 0.3s;
    padding: 2rem;
}

.mobile-menu.active {
    display: block;
    right: 0;
}

/* 菜单蒙层样式 */
.mobile-menu-overlay {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.5);
    z-index: 1000;
    transition: opacity 0.3s;
}

.mobile-menu-overlay.active {
    display: block;
}

.mobile-menu a {
    display: block;
    margin-bottom: 1.5rem;
    text-decoration: none;
    color: #333;
    font-size: 1.2rem;
}

/* 英雄区域轮播图 */
.hero {
    height: 80vh;
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #fff;
    text-align: center;
    overflow: hidden;
}

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

.slide {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    opacity: 0;
    transition: opacity 1s ease-in-out;
    background-size: cover;
    background-position: center;
}

.slide.active {
    opacity: 1;
}

.slide::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(rgba(0, 0, 0, 0.5), rgba(0, 0, 0, 0.7));
}



.hero-content h2 {
    font-size: 60px;
    margin-bottom: 1rem;
    color: #88CDFD;
}

.hero-content p {
    font-size: 30px;
    margin-bottom: 2rem;
}

.btn-primary {
    display: inline-block;
    background-color: var(--primary-color);
    color: var(--white);
    padding: 0.8rem 1.5rem;
    text-decoration: none;
    border-radius: 4px;
    font-weight: 500;
    transition: var(--transition);
    position: relative;
    overflow: hidden;
    z-index: 1;
}

.btn-primary::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background-color: rgba(255, 255, 255, 0.2);
    transition: var(--transition);
    z-index: -1;
}

.btn-primary:hover {
    transform: translateY(-3px);
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.2);
}

.btn-primary:hover::before {
    left: 100%;
}

/* CTA区域 */
.cta-section {
    padding: 4rem 0;
}

.cta-section .container {
    display: flex;
    gap: 2rem;
}

.cta-left, .cta-right {
    flex: 1;
    height: 300px;
    background-size: cover;
    background-position: center;
    display: flex;
    flex-direction: column;
    justify-content: center;
    padding: 2rem;
    color: var(--white);
    cursor: pointer;
    transition: var(--transition);
    border-radius: 8px;
    position: relative;
    overflow: hidden;
    z-index: 1;
}

.cta-left::before, .cta-right::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(rgba(0, 0, 0, 0.2), rgba(0, 0, 0, 0.3));
    transition: var(--transition);
    z-index: -1;
}

.cta-left:hover, .cta-right:hover {
    transform: translateY(-10px);
    box-shadow: 0 15px 30px rgba(0, 0, 0, 0.2);
}

.cta-left:hover::before, .cta-right:hover::before {
    background: linear-gradient(rgba(0, 0, 0, 0.1), rgba(0, 0, 0, 0.2));
}

.cta-left {
    background-image: url('images/rands.webp');
}

.cta-right {
    background-image: url('images/search-cars.webp');
}

.cta-left h3, .cta-right h3 {
    transition: var(--transition);
}

.cta-left:hover h3, .cta-right:hover h3 {
    transform: translateX(10px);
}

.cta-left i, .cta-right i {
    transition: var(--transition);
}

.cta-left:hover i, .cta-right:hover i {
    transform: translateX(10px);
}

.cta-left h3, .cta-right h3 {
    font-size: 2.6rem;
    margin-bottom: 0.5rem;
}

.cta-left i, .cta-right i {
    margin-top: auto;
    font-size: 1.5rem;
    align-self: flex-end;
}

/* 新的按钮样式 */
.btn-outline {
    background-color: transparent;
    color: var(--white);
    padding: 0.8rem 1.5rem;
    text-decoration: none;
    border: 1px solid var(--primary-color);
    border-radius: 8px;
    font-weight: 500;
    transition: var(--transition);
    position: relative;
    overflow: hidden;
    z-index: 1;
    font-size: 16px;
    height: 50px;
    margin-top: 40px;
    box-sizing: border-box;
    text-align: center;
    flex: 0 0 auto;
    width: fit-content;
}

.btn-outline:hover {
    background-color: var(--primary-color);
    color: var(--white);
    border-color: var(--primary-color);
    transform: translateY(-3px);
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.2);
}

/* 推荐汽车 */
.featured-cars {
    padding: 4rem 0;
    background-color: #f9f9f9;
}

.featured-cars h2 {
    text-align: center;
    margin-bottom: 2rem;
    font-size: 2rem;
}

.car-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 2rem;
}

.car-card {
    background-color: var(--white);
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
    transition: var(--transition);
    cursor: pointer;
    position: relative;
    display: flex;
    flex-direction: column;
}

.car-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.1);
}

.car-card .car-image-container {
    position: relative;
    width: 100%;
    padding-top: 75%; /* 4:3 aspect ratio */
    overflow: hidden;
}

.car-card img {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: var(--transition);
}

.car-card:hover img {
    transform: scale(1.03);
}

.car-brand-tag {
    position: absolute;
    top: 15px;
    left: 15px;
    background-color: #f5a623;
    color: white;
    padding: 6px 12px;
    border-radius: 4px;
    font-size: 12px;
    font-weight: bold;
    z-index: 2;
}

.car-model-type {
    position: absolute;
    bottom: 15px;
    left: 15px;
    color: white;
    font-size: 14px;
    font-weight: bold;
    z-index: 2;
    background-color: rgba(0, 0, 0, 0.5);
    padding: 4px 8px;
    border-radius: 4px;
}

.car-card .car-content {
    padding: 15px;
    flex-grow: 1;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
}

.car-card h3 {
    font-size: 18px;
    font-weight: bold;
    color: #333;
    margin-bottom: 8px;
    line-height: 1.4;
}

.car-card h3 {
    font-size: 18px;
    font-weight: bold;
    color: #333;
    margin-bottom: 8px;
    line-height: 1.4;
}

.car-card .price {
    font-size: 20px;
    font-weight: bold;
    color: #e74c3c;
    margin-top: 10px;
}

.car-arrow-btn {
    position: absolute;
    right: 15px;
    bottom: 15px;
    width: 36px;
    height: 36px;
    border: 2px solid #333;
    border-radius: 4px;
    background-color: white;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.3s ease;
}

.car-arrow-btn:hover {
    background-color: #333;
    color: white;
}

.car-arrow-btn i {
    font-size: 14px;
}

/* 汽车卡片样式已更新 */

/* 关于我们 */
.about-us {
    padding: 4rem 0;
}

.about-us h2 {
    text-align: center;
    margin-bottom: 2rem;
    font-size: 2rem;
}

.about-content {
    display: flex;
    gap: 2rem;
}

.about-text {
    flex: 1;
}

.about-text p {
    margin-bottom: 1rem;
}

.about-image {
    flex: 1;
}

.about-image img {
    width: 100%;
    height: auto;
    border-radius: 8px;
}



/* 页脚 */
footer {
    background-color: #333;
    color: #fff;
    padding: 3rem 0;
}

.footer-content {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 2rem;
}

.footer-column h3 {
    margin-bottom: 1.5rem;
    font-size: 1.2rem;
}

.footer-column ul {
    list-style: none;
}

.footer-column ul li {
    margin-bottom: 0.5rem;
}

.footer-column a {
    text-decoration: none;
    color: #ddd;
    transition: color 0.3s;
}

.footer-column a:hover {
    color: #e74c3c;
}

.social-links {
    display: flex;
    gap: 1rem;
}

.social-links a {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    background-color: #444;
    border-radius: 50%;
    color: var(--white);
    transition: var(--transition);
    position: relative;
    overflow: hidden;
}

.social-links a::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: var(--primary-color);
    transform: scale(0);
    border-radius: 50%;
    transition: var(--transition);
    z-index: -1;
}

.social-links a:hover {
    transform: rotate(360deg) scale(1.1);
    color: var(--white);
}

.social-links a:hover::before {
    transform: scale(1);
}

.footer-bottom {
    text-align: center;
    padding-top: 2rem;
    margin-top: 2rem;
    border-top: 1px solid #444;
}

/* 语言切换器样式 */
.language-switcher {
    position: relative;
    display: inline-block;
    margin-left: 20px;
    cursor: pointer;
    font-size: 14px;
    z-index: 1001;
}

.current-language {
    display: flex;
    align-items: center;
    padding: 5px 10px;
    border-radius: 4px;
    background-color: #333;
    transition: background-color 0.3s;
}

.current-language:hover {
    background-color: #e0e0e0;
    color: #333;
}

.language-options {
    position: absolute;
    top: 100%;
    right: 0;
    background-color: #333;
    border: 1px solid #ddd;
    border-radius: 4px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    z-index: 1000;
    min-width: 150px;
    overflow-y: auto;
}

.language-option {
    padding: 10px;
    border-bottom: 1px solid #eee;
}

.language-option:last-child {
    border-bottom: none;
}

.language-option:hover {
    background-color: #f5f5f5;
    color: #333;
}

.language-option.active {
    background-color: #e3f2fd;
    color: #333;
    font-weight: bold;
}

@media (max-width: 768px) {
    .language-switcher {
        margin-left: 10px;
        font-size: 12px;
    }

    .current-language {
        padding: 3px 8px;
    }

    .language-options {
        min-width: 120px;
        font-size: 12px;
    }

    .language-option {
        padding: 8px;
    }
}

/* 滚动动画样式 */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes slideInLeft {
    from {
        opacity: 0;
        transform: translateX(-30px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

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

@keyframes zoomIn {
    from {
        opacity: 0;
        transform: scale(0.9);
    }
    to {
        opacity: 1;
        transform: scale(1);
    }
}

.fadeInUp {
    animation: fadeInUp 0.6s ease-out forwards;
}

.slideInLeft {
    animation: slideInLeft 0.6s ease-out forwards;
}

.slideInRight {
    animation: slideInRight 0.6s ease-out forwards;
}

.zoomIn {
    animation: zoomIn 0.6s ease-out forwards;
}

/* 初始隐藏动画元素 */
.animate-on-scroll {
    opacity: 0;
    transition: opacity 0.3s, transform 0.6s;
}

/* 响应式设计 */
@media (max-width: 992px) {
    .about-content {
        flex-direction: column;
    }

    .car-detail-content {
        flex-direction: column;
    }
}

@media (max-width: 768px) {
    .menu {
        display: none;
    }

    .mobile-menu-btn {
        display: block;
        margin-right: 20px;
    }

    .cta-section .container {
        flex-direction: column;
    }

    .cta-left, .cta-right {
        height: 200px;
    }

    .hero-content h2 {
        font-size: 2rem;
    }

    .main-content-wrapper {
        flex-direction: column;
    }

    .top-contact p {
        width: 100%;
    }

    .top-contact p {
        display: flex;
        flex-direction: column;
    }

    .side-navigation {
        right: 0;
    }
}

@media (max-width: 576px) {
    .hero-content h2 {
        font-size: 1.8rem;
    }

    .hero-content p {
        font-size: 1rem;
    }

    .footer-content {
        grid-template-columns: 1fr;
    }
}

.radio-group {
  display: flex;
  gap: 1rem;
  align-items: center;
}

.radio-group input[type="radio"] {
  width: auto !important;
}

.radio-group label {
  margin: 0 !important;
  font-weight: normal !important;
}


