/* Custom Styles for TRIYUN RV Toilet Website */

:root {
    --primary-color: #0d6efd;
    --secondary-color: #198754;
    --dark-color: #212529;
    --light-bg: #f8f9fa;
}

body {
    font-family: 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
    line-height: 1.6;
    color: #333;
    background-color: #fff;
}

/* Navbar */
.navbar {
    padding: 0.8rem 0;
    transition: all 0.3s ease;
    background-color: #fff !important;
}

.navbar-brand {
    font-size: 1.5rem;
    letter-spacing: 1px;
    display: flex;
    align-items: center;
}

/* Logo Image Optimization */
.navbar-brand img {
    max-height: 45px; /* 限制 Logo 最大高度 */
    width: auto;
    object-fit: contain;
}

.nav-link {
    font-weight: 500;
    margin: 0 8px;
    color: #555 !important;
    transition: color 0.3s;
}

.nav-link:hover, .nav-link.active {
    color: var(--primary-color) !important;
}

/* Hero Section */
.hero-section {
    background: linear-gradient(135deg, #0d6efd 0%, #0a58ca 100%);
    min-height: 85vh;
    position: relative;
    overflow: hidden;
    padding-top: 80px;
    color: white;
    display: flex;
    align-items: center;
}

.hero-section .overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    opacity: 0.1;
    z-index: 1;
    /* 如果有背景纹理图可以取消下面注释 */
    /* background: url('../assets/hero-pattern.png') repeat; */
}

.hero-section h1 {
    text-shadow: 2px 2px 4px rgba(0,0,0,0.3);
    line-height: 1.2;
}

.hero-section img {
    max-height: 500px;
    width: 100%;
    object-fit: contain;
    filter: drop-shadow(0 10px 20px rgba(0,0,0,0.3));
}

.floating-animation {
    animation: float 6s ease-in-out infinite;
}

@keyframes float {
    0% { transform: translateY(0px); }
    50% { transform: translateY(-15px); }
    100% { transform: translateY(0px); }
}

/* Feature Cards */
.feature-card {
    transition: transform 0.3s, box-shadow 0.3s;
    border: none;
    border-radius: 12px;
    background: #fff;
}

.feature-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 1rem 3rem rgba(0,0,0,0.12) !important;
}

.feature-card .card-body {
    padding: 2rem 1.5rem;
}

.feature-card i {
    background: -webkit-linear-gradient(#0d6efd, #0099ff);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

/* Page Header */
.page-header {
    background: linear-gradient(135deg, #212529 0%, #495057 100%);
    margin-top: 76px;
    color: white;
    padding: 100px 0 60px;
    text-align: center;
}

/* General Image Styling (Important!) */
img {
    max-width: 100%;
    height: auto;
    display: block;
}

/* Product Images Specifics */
.product-img, .hero-section img, .card-img-top {
    border-radius: 10px;
    box-shadow: 0 5px 15px rgba(0,0,0,0.08);
    background-color: #fff; /* 确保白色背景，防止透明图在某些浏览器显示异常 */
    padding: 10px; /* 给图片一点内边距，不要贴着边框 */
}

/* Table Styling */
.table th {
    width: 40%;
    font-weight: 600;
    color: var(--dark-color);
    background-color: #f8f9fa;
}

.table-hover tbody tr:hover {
    background-color: #f1f7ff;
}

/* Buttons */
.btn-primary {
    border-radius: 50px;
    padding: 0.75rem 2rem;
    font-weight: 600;
    border: none;
    background-color: var(--primary-color);
    transition: all 0.3s;
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(13, 110, 253, 0.4);
    background-color: #0b5ed7;
}

.btn-outline-primary {
    border-radius: 50px;
    padding: 0.75rem 2rem;
    font-weight: 600;
    border: 2px solid var(--primary-color);
    color: var(--primary-color);
    background: transparent;
}

.btn-outline-primary:hover {
    background-color: var(--primary-color);
    color: white;
}

.btn-light {
    border-radius: 50px;
    padding: 0.75rem 2rem;
    font-weight: 600;
}

/* Forms */
.form-control {
    border-radius: 8px;
    padding: 0.75rem;
    border: 1px solid #dee2e6;
    background-color: #fcfcfc;
}

.form-control:focus {
    border-color: var(--primary-color);
    box-shadow: 0 0 0 0.2rem rgba(13, 110, 253, 0.15);
    background-color: #fff;
}

/* Footer */
footer {
    background-color: #1a1d20;
    color: #adb5bd;
    padding: 50px 0 30px;
    font-size: 0.95rem;
}

footer h5 {
    color: white;
    margin-bottom: 15px;
}

footer a {
    color: #adb5bd;
    text-decoration: none;
    transition: color 0.2s;
}

footer a:hover {
    color: white;
}

/* Responsive Adjustments */
@media (max-width: 768px) {
    .hero-section {
        min-height: auto;
        padding: 120px 0 60px;
        text-align: center;
    }
    
    .hero-section .row {
        flex-direction: column-reverse; /* 手机上图片在上文字在下，或者保持原样看需求 */
    }

    .display-4 {
        font-size: 2.2rem;
    }
    
    .floating-animation {
        animation: none;
        margin-bottom: 30px;
        max-height: 300px;
    }
    
    .navbar-brand img {
        max-height: 35px;
    }
    
    .feature-card {
        margin-bottom: 20px;
    }
}

/* Utility Classes */
.z-2 { z-index: 2; }
.text-primary { color: var(--primary-color) !important; }
.bg-primary { background-color: var(--primary-color) !important; }
.shadow-sm { box-shadow: 0 0.125rem 0.25rem rgba(0, 0, 0, 0.075) !important; }
.shadow-lg { box-shadow: 0 1rem 3rem rgba(0, 0, 0, 0.175) !important; }
