/* Global Styles */
:root {
    --primary-color: #8b5a2b;
    --secondary-color: #d4a76a;
    --dark-color: #212529;
    --light-color: #f8f9fa;
    --danger-color: #dc3545;
    --success-color: #28a745;
    --warning-color: #ffc107;
    --info-color: #17a2b8;
    --transition: all 0.3s ease;
}

body {
    font-family: 'Poppins', sans-serif;
    color: #333;
    line-height: 1.6;
    overflow-x: hidden;
}

a {
    color: var(--primary-color);
    text-decoration: none;
    transition: var(--transition);
}

a:hover {
    color: var(--secondary-color);
    text-decoration: none;
}

h1, h2, h3, h4, h5, h6 {
    font-weight: 700;
    color: var(--dark-color);
    margin-bottom: 1rem;
}

.section-title {
    position: relative;
    display: inline-block;
    margin-bottom: 2.5rem;
    text-transform: uppercase;
    font-weight: 700;
    color: var(--dark-color);
}

.section-title:after {
    content: '';
    position: absolute;
    width: 50%;
    height: 3px;
    background: var(--primary-color);
    bottom: -10px;
    left: 0;
}

.section-padding {
    padding: 80px 0;
}

.bg-light-gray {
    background-color: #f8f9fa;
}

/* Text Truncation */
.text-truncate-2 {
    display: -webkit-box;
    -webkit-box-orient: vertical;
    overflow: hidden;
    text-overflow: ellipsis;
}

.text-truncate-3 {
    display: -webkit-box;
    -webkit-box-orient: vertical;
    overflow: hidden;
    text-overflow: ellipsis;
}

/* Buttons */
.btn {
    padding: 10px 25px;
    border-radius: 0;
    font-weight: 500;
    text-transform: uppercase;
    font-size: 14px;
    letter-spacing: 1px;
    transition: var(--transition);
}

.btn-primary {
    background-color: var(--primary-color);
    border-color: var(--primary-color);
}

.btn-primary:hover, .btn-primary:focus {
    background-color: #6b4420;
    border-color: #6b4420;
    box-shadow: none;
}

.btn-outline-primary {
    color: var(--primary-color);
    border-color: var(--primary-color);
}

.btn-outline-primary:hover {
    background-color: var(--primary-color);
    border-color: var(--primary-color);
}

/* Navbar */
.navbar {
    padding: 15px 0;
    transition: var(--transition);
}

.navbar-brand img {
    max-height: 50px;
}

.navbar-nav .nav-link {
    font-weight: 500;
    padding: 10px 15px;
    text-transform: uppercase;
    font-size: 14px;
    letter-spacing: 1px;
}

.navbar-nav .nav-link.active,
.navbar-nav .nav-link:hover {
    color: var(--primary-color) !important;
}

/* Hero Section */
.hero-section {
    background: url('../images/background-1.jpg') no-repeat center center/cover;
    padding: 120px 0;
    position: relative;
    text-align: center;
}



.hero-content h1 {
    font-size: 3.5rem;
    font-weight: 800;
    margin: 0 auto 1.5rem auto;
    position: relative;
    display: inline-block;
    color: #fff;
    padding: 15px 25px;
    text-shadow: 
        2px 2px 5px rgba(0,0,0,0.8);
    line-height: 1.3;
    text-align: center;
    max-width: 90%;
    box-sizing: border-box;
}

.hero-content p.lead {
    font-size: 1.4rem;
    margin: 0 auto 2rem auto;
    color: #fff;
    position: relative;
    display: inline-block;
    padding: 12px 25px;
    text-shadow: 
        2px 2px 5px rgba(0,0,0,0.8);
    line-height: 1.6;
    text-align: center;
    max-width: 80%;
    box-sizing: border-box;
    letter-spacing: 0.5px;
}

.hero-btns .btn {
    box-shadow: 0 4px 6px rgba(0,0,0,0.2);
    position: relative;
    z-index: 1;
    transition: all 0.3s ease;
}

.hero-btns .btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 12px rgba(0,0,0,0.3);
}

/* Product Card */
.product-card {
    background: #fff;
    border: 1px solid #eee;
    border-radius: 5px;
    overflow: hidden;
    transition: var(--transition);
    margin-bottom: 30px;
}

.product-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.1);
}

.product-img {
    position: relative;
    overflow: hidden;
    padding-top: 75%; /* 4:3 Aspect Ratio */
    width: 90%;
    margin: 0 auto;
    background: #f8f9fa;
    border-radius: 5px 5px 0 0;
}

.product-img img {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: contain;
    transition: var(--transition);
    padding: 10px;
}

.product-card:hover .product-img img {
    transform: scale(1.05);
}

.product-badge {
    position: absolute;
    top: 10px;
    right: 10px;
    background: var(--primary-color);
    color: #fff;
    padding: 5px 15px;
    border-radius: 3px;
    font-size: 12px;
    font-weight: 600;
    text-transform: uppercase;
}

.product-content {
    padding: 20px;
}

.product-category {
    font-size: 13px;
    color: #777;
    margin-bottom: 5px;
    display: block;
}

.product-card-title {
    display: -webkit-box;
    -webkit-box-orient: vertical;
    overflow: hidden;
    text-overflow: ellipsis;
    min-height: 3em; /* Adjust based on your line height */
    font-size: 18px;
    font-weight: 600;
    margin-bottom: 10px;
}
.product-price {
    display: flex;
    align-items: center;
    margin-bottom: 15px;
}

.current-price {
    font-size: 18px;
    font-weight: 700;
    color: var(--primary-color);
    margin-right: 10px;
}

.old-price {
    font-size: 14px;
    color: #999;
    text-decoration: line-through;
}

/* Features Section */
.feature-box {
    text-align: center;
    padding: 30px 20px;
    border: 1px solid #eee;
    border-radius: 5px;
    transition: var(--transition);
    margin-bottom: 30px;
}

.feature-box:hover {
    background: #fff;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.05);
    transform: translateY(-5px);
}

.feature-icon {
    width: 70px;
    height: 70px;
    background: rgba(139, 90, 43, 0.1);
    border-radius: 50%;
    color: var(--primary-color);
    font-size: 30px;
    margin:0 auto 20px;
    transition: var(--transition);
    display: flex;
    align-items: center;
    justify-content: center;
}

.feature-box:hover .feature-icon {
    background: var(--primary-color);
    color: #fff;
}

/* Testimonials */
.testimonial-section {
    background: linear-gradient(rgba(0, 0, 0, 0.8), rgba(0, 0, 0, 0.8)), url('../images/testimonial-bg.jpg') no-repeat center center/cover;
    background-attachment: fixed;
    color: #fff;
    padding: 100px 0;
}

.testimonial-item {
    background: rgba(255, 255, 255, 0.1);
    padding: 30px;
    border-radius: 5px;
    margin: 15px;
    position: relative;
}

.testimonial-item:before {
    content: '\201C';
    position: absolute;
    top: 20px;
    left: 20px;
    font-size: 60px;
    font-family: Georgia, serif;
    color: rgba(255, 255, 255, 0.1);
    line-height: 1;
}

.testimonial-content {
    position: relative;
    z-index: 1;
    margin-bottom: 20px;
    font-style: italic;
}

.testimonial-author {
    display: flex;
    align-items: center;
}

.testimonial-author img {
    width: 60px;
    height: 60px;
    border-radius: 50%;
    margin-right: 15px;
    border: 3px solid rgba(255, 255, 255, 0.2);
}

.testimonial-author h5 {
    margin-bottom: 5px;
    color: #fff;
}

.testimonial-author p {
    margin: 0;
    font-size: 14px;
    color: #ddd;
}

/* Footer */
.footer-widget h5 {
    position: relative;
    padding-bottom: 15px;
    margin-bottom: 25px;
}

.footer-widget h5:after {
    content: '';
    position: absolute;
    left: 0;
    bottom: 0;
    width: 50px;
    height: 2px;
    background: var(--primary-color);
}

.footer-widget ul li {
    margin-bottom: 10px;
}

.footer-widget ul li a:hover {
    color: var(--secondary-color) !important;
    padding-left: 5px;
}

.contact-info li {
    margin-bottom: 15px;
    display: flex;
    align-items: flex-start;
}

.contact-info i {
    color: var(--primary-color);
    margin-top: 5px;
    margin-right: 15px;
}

.social-links a {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 35px;
    height: 35px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 50%;
    margin-right: 10px;
    color: #fff;
    transition: var(--transition);
}

.social-links a:hover {
    background: var(--primary-color);
    color: #fff;
    transform: translateY(-3px);
}

.back-to-top {
    position: fixed;
    bottom: 30px;
    right: 30px;
    width: 45px;
    height: 45px;
    line-height: 45px;
    text-align: center;
    border-radius: 50%;
    z-index: 99;
    display: none;
    transition: var(--transition);
}

/* Responsive Styles */
@media (max-width: 991.98px) {
    .section-padding {
        padding: 60px 0;
    }
    
    .hero-content h1 {
        font-size: 2.5rem;
    }
    
    .navbar-nav {
        padding: 15px 0;
    }
    
    .navbar-toggler {
        border: none;
        padding: 0;
    }
    
    .navbar-toggler:focus {
        box-shadow: none;
    }
}

@media (max-width: 767.98px) {
    .hero-section {
        padding: 100px 0;
    }
    
    .hero-content h1 {
        font-size: 2rem;
    }
    
    .section-title {
        font-size: 1.5rem;
    }
    
    .back-to-top {
        width: 40px;
        height: 40px;
        line-height: 40px;
        bottom: 20px;
        right: 20px;
    }
}

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

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

/* Custom Scrollbar */
::-webkit-scrollbar {
    width: 8px;
}

::-webkit-scrollbar-track {
    background: #f1f1f1;
}

::-webkit-scrollbar-thumb {
    background: var(--primary-color);
    border-radius: 10px;
}

::-webkit-scrollbar-thumb:hover {
    background: #6b4420;
}

/* Background Slideshow */
.background-slideshow {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    z-index: -1;
    opacity: 0;
    transition: opacity 1s ease-in-out;
}

/* Ensure content is above the slideshow */
body {
    position: relative;
    background-color: #f8f9fa;
}

.main-content {
    position: relative;
    background-color: rgba(255, 255, 255, 0.9);
    min-height: 100vh;
}

/* Brand Slider */
.brands-slider {
    width: 100%;
    overflow: hidden;
    position: relative;
    padding: 20px 0;
    background: #f8f9fa;
    border-radius: 8px;
    box-shadow: 0 2px 15px rgba(0,0,0,0.05);
}

.brands-slider::before,
.brands-slider::after {
    content: '';
    position: absolute;
    top: 0;
    width: 100px;
    height: 100%;
    z-index: 2;
    pointer-events: none;
}

.brands-slider::before {
    left: 0;
    background: linear-gradient(to right, #fff 0%, rgba(255, 255, 255, 0) 100%);
}

.brands-slider::after {
    right: 0;
    background: linear-gradient(to left, #fff 0%, rgba(255, 255, 255, 0) 100%);
}

.brands-slider-track {
    display: flex;
    width: max-content;
    animation: scroll 40s linear infinite;
    padding: 10px 0;
    white-space: nowrap; /* prevent wrapping */
}

/* Ensure each group of logos lays out horizontally */
.brands-slider-track .brand-logos {
    display: flex;
    flex-wrap: nowrap;
    align-items: center;
}


.brand-logo {
    display: flex !important;
    align-items: center;
    justify-content: center;
    height: 100px !important;
    min-width: 160px !important;
    padding: 15px !important;
    margin: 0 8px !important;
    background: white;
    border-radius: 8px;
    box-shadow: 0 4px 8px rgba(0,0,0,0.08);
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
    flex: 0 0 auto; /* keep items on one line */
}


/* Ensure all logos maintain aspect ratio */
.brand-logo img {
    width: auto !important;
    height: auto !important;
    max-width: 140px !important;
    max-height: 60px !important;
}

.brand-logo:hover img {
    transform: scale(1.15);
    opacity: 0.9;
}

@keyframes scroll {
    0% {
        transform: translateX(0);
    }
    100% {
        transform: translateX(-50%);
    }
}

/* Pause animation on hover */
.brands-slider:hover .brands-slider-track {
    animation-play-state: paused;
}

/* Responsive adjustments */
@media (max-width: 768px) {
    .brands-slider {
        padding: 8px 0;
    }
    
    .brands-slider-track {
        animation-duration: 30s;
    }
    
    .brand-logo {
        min-width: 120px !important;
        height: 80px !important;
        padding: 10px !important;
        margin: 0 6px !important;
    }
    
    .brand-logo img {
        max-width: 100px !important;
        max-height: 45px !important;
    }
    
    /* Mobile-specific adjustments */
    .brand-logo[title*="Sleepwell"] img,
    .brand-logo[title*="sujata"] img {
        max-height: 40px !important;
    }
    
    .brand-logo[title*="raggee"] img,
    .brand-logo[title*="Gomati"] img {
        max-height: 35px !important;
    }
}
