/* 
   Vendo.sg Styles
   Color Scheme:
   - Main Blue: #6F9DD7
   - Green Accent: #92D4A3
   - Yellow Accent: #F4D35E
*/

/* Base Styles */
:root {
    --primary-color: #6F9DD7;
    --secondary-color: #92D4A3;
    --accent-color: #F4D35E;
    --text-color: #333333;
    --light-gray: #f5f5f5;
    --medium-gray: #e0e0e0;
    --dark-gray: #666666;
    --white: #ffffff;
    --shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
    --border-radius: 8px;
}

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

html {
    scroll-behavior: smooth;
}

body {
    font-family: 'Poppins', sans-serif;
    color: var(--text-color);
    line-height: 1.6;
    background-color: var(--white);
}

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

a:hover {
    color: #5a80b0;
}

img {
    max-width: 100%;
    height: auto;
}

ul {
    list-style: none;
}

.container {
    width: 100%;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

.text-center {
    text-align: center;
}

/* Button Styles */
.btn {
    display: inline-block;
    padding: 10px 20px;
    border-radius: var(--border-radius);
    font-weight: 600;
    text-align: center;
    cursor: pointer;
    transition: all 0.3s ease;
    border: none;
    font-size: 14px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

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

.btn-primary:hover {
    background-color: #5a80b0;
    color: var(--white);
}

.btn-secondary {
    background-color: var(--secondary-color);
    color: var(--white);
}

.btn-secondary:hover {
    background-color: #7ab88a;
    color: var(--white);
}

.btn-outline {
    background-color: transparent;
    border: 2px solid var(--primary-color);
    color: var(--primary-color);
    padding: 8px 18px;
}

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

/* Header Styles */
.main-header {
    background-color: var(--white);
    box-shadow: var(--shadow);
    position: sticky;
    top: 0;
    z-index: 100;
    padding: 15px 0;
    width: 100%;
    left: 0;
    right: 0;
}

.header-container {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo img {
    height: 40px;
}

.search-container {
    flex-grow: 1;
    max-width: 500px;
    margin: 0 20px;
}

.search-form {
    display: flex;
    position: relative;
}

.search-input {
    width: 100%;
    padding: 10px 15px;
    border: 1px solid var(--medium-gray);
    border-radius: 50px;
    font-size: 14px;
}

.search-button {
    position: absolute;
    right: 5px;
    top: 50%;
    transform: translateY(-50%);
    background-color: var(--primary-color);
    color: var(--white);
    border: none;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
}

.mobile-menu-toggle {
    display: none;
    font-size: 24px;
    color: var(--primary-color);
    cursor: pointer;
}

.hamburger-menu {
    font-size: 24px;
    color: var(--primary-color);
    cursor: pointer;
    margin-left: 15px;
}

/* Dropdown Menu Styles */
.dropdown-menu {
    position: absolute;
    top: 100%;
    right: 20px;
    background-color: var(--white);
    border-radius: var(--border-radius);
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
    width: 200px;
    z-index: 100;
    overflow: hidden;
    opacity: 0;
    visibility: hidden;
    transform: translateY(-10px);
    transition: all 0.3s ease;
}

.dropdown-menu.active {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.dropdown-menu ul {
    list-style: none;
    padding: 0;
    margin: 0;
}

.dropdown-menu ul li {
    border-bottom: 1px solid var(--medium-gray);
}

.dropdown-menu ul li:last-child {
    border-bottom: none;
}

.dropdown-menu ul li a {
    display: block;
    padding: 12px 15px;
    color: var(--text-color);
    transition: background-color 0.3s ease;
}

.dropdown-menu ul li a:hover {
    background-color: var(--light-gray);
    color: var(--primary-color);
}

/* Navigation Styles */
.main-nav {
    background-color: var(--primary-color);
    padding: 10px 0;
    overflow-x: auto;
    overflow-y: hidden;
    white-space: nowrap;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none; /* Firefox */
    position: relative;
    width: 100%;
    left: 0;
    right: 0;
}

.nav-scroll-indicator {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    width: 30px;
    height: 30px;
    background-color: rgba(255, 255, 255, 0.2);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    cursor: pointer;
    z-index: 10;
    transition: background-color 0.3s ease;
}

.nav-scroll-indicator:hover {
    background-color: rgba(255, 255, 255, 0.4);
}

.nav-scroll-indicator.left {
    left: 10px;
}

.nav-scroll-indicator.right {
    right: 10px;
}

.main-nav::-webkit-scrollbar {
    display: none; /* Chrome, Safari, Edge */
}

.main-nav::before, .main-nav::after {
    content: '';
    position: absolute;
    top: 0;
    height: 100%;
    width: 30px;
    z-index: 1;
    pointer-events: none;
}

.main-nav::before {
    left: 0;
    background: linear-gradient(to right, var(--primary-color), transparent);
}

.main-nav::after {
    right: 0;
    background: linear-gradient(to left, var(--primary-color), transparent);
}

.nav-list {
    display: flex;
    gap: 15px;
    position: relative;
    z-index: 2;
    padding: 0 10px;
}

.nav-list li a {
    color: var(--white);
    padding: 8px 15px;
    border-radius: var(--border-radius);
    display: inline-block;
    font-size: 14px;
    transition: background-color 0.3s ease;
    position: relative;
    z-index: 3;
    white-space: nowrap;
}

.nav-list li a:hover {
    background-color: rgba(255, 255, 255, 0.2);
}

.nav-list li a i {
    margin-right: 5px;
}

/* Hero Section */
.hero-section {
    color: var(--white);
    padding: 80px 0;
    text-align: left;
    position: relative;
    overflow: hidden;
}

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

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

.hero-banner.active {
    opacity: 1;
}

.hero-banner::before {
    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.5));
}

.hero-content {
    max-width: 600px;
}

.hero-content h1 {
    font-size: 2.5rem;
    margin-bottom: 10px;
    font-weight: 700;
}

.hero-content h2 {
    font-size: 2rem;
    margin-bottom: 20px;
    font-weight: 600;
}

.hero-tagline {
    font-size: 1.2rem;
    margin-bottom: 10px;
    font-weight: 500;
}

.hero-subtext {
    font-size: 1rem;
    margin-bottom: 30px;
    opacity: 0.9;
}

/* Section Styles */
.section-title {
    font-size: 1.8rem;
    margin-bottom: 30px;
    text-align: left;
    position: relative;
    padding-bottom: 10px;
}

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

.featured-section, .deals-section {
    padding: 60px 0;
    position: relative;
}

.deals-section {
    background-color: var(--light-gray);
}

/* Carousel Styles */
.carousel-controls {
    position: absolute;
    top: 10px;
    right: 20px;
    display: flex;
    gap: 10px;
}

.carousel-control {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background-color: var(--white);
    border: 1px solid var(--medium-gray);
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.3s ease;
}

.carousel-control:hover {
    background-color: var(--primary-color);
    color: var(--white);
}

.carousel {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 20px;
    margin-top: 20px;
}

/* Program Card Styles */
.program-card {
    background-color: var(--white);
    border-radius: var(--border-radius);
    overflow: hidden;
    box-shadow: var(--shadow);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    cursor: pointer;
}

.programs-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 24px;
  margin-top: 20px;
}

.program-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
}

.program-image {
    height: 180px;
    overflow: hidden;
    background-color: var(--accent-color);
}

.program-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s ease;
}

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

.program-details {
    padding: 15px;
}

.program-title {
    font-size: 1.1rem;
    margin-bottom: 10px;
    font-weight: 600;
    color: var(--text-color);
}

.vendor-info {
    display: flex;
    align-items: center;
    margin-bottom: 15px;
}

.vendor-logo {
    width: 30px;
    height: 30px;
    border-radius: 50%;
    margin-right: 10px;
    object-fit: cover;
}

.vendor-name {
    font-size: 0.9rem;
    color: var(--dark-gray);
}

.program-actions {
    display: flex;
    gap: 10px;
    flex-wrap: nowrap;
    width: 100%;
}

.program-actions .btn {
    flex: 1;
    font-size: 0.8rem;
    white-space: nowrap;
    text-overflow: ellipsis;
    overflow: hidden;
    min-width: 0;
    padding: 8px 10px;
}

.program-actions .btn-contact {
    white-space: nowrap;
    overflow: visible;
    text-overflow: clip;
    min-width: fit-content;
}

/* Category Tag Styles */
.category-tag {
    display: inline-block;
    background-color: var(--primary-color);
    color: var(--white);
    padding: 4px 10px;
    border-radius: 4px;
    font-size: 0.8rem;
    margin-right: 8px;
    margin-bottom: 8px;
    font-weight: 500;
    text-transform: capitalize;
}

.secondary-category {
    background-color: var(--secondary-color);
}

/* Program Meta Styles */
.program-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-bottom: 15px;
}

.meta-item {
    display: flex;
    align-items: center;
    font-size: 0.85rem;
    color: var(--dark-gray);
}

.meta-item i {
    margin-right: 5px;
    color: var(--primary-color);
}

/* Stats Section */
.stats-section {
    background-color: var(--secondary-color);
    padding: 60px 0;
    color: var(--white);
    text-align: center;
    position: relative;
    overflow: hidden;
}

.stats-section .container {
    position: relative;
    z-index: 5; /* Ensure container content is above falling icons */
}

.stats-section::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-image: url("data:image/svg+xml,%3Csvg width='100' height='100' viewBox='0 0 100 100' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M11 18c3.866 0 7-3.134 7-7s-3.134-7-7-7-7 3.134-7 7 3.134 7 7 7zm48 25c3.866 0 7-3.134 7-7s-3.134-7-7-7-7 3.134-7 7 3.134 7 7 7zm-43-7c1.657 0 3-1.343 3-3s-1.343-3-3-3-3 1.343-3 3 1.343 3 3 3zm63 31c1.657 0 3-1.343 3-3s-1.343-3-3-3-3 1.343-3 3 1.343 3 3 3zM34 90c1.657 0 3-1.343 3-3s-1.343-3-3-3-3 1.343-3 3 1.343 3 3 3zm56-76c1.657 0 3-1.343 3-3s-1.343-3-3-3-3 1.343-3 3 1.343 3 3 3zM12 86c2.21 0 4-1.79 4-4s-1.79-4-4-4-4 1.79-4 4 1.79 4 4 4zm28-65c2.21 0 4-1.79 4-4s-1.79-4-4-4-4 1.79-4 4 1.79 4 4 4zm23-11c2.76 0 5-2.24 5-5s-2.24-5-5-5-5 2.24-5 5 2.24 5 5 5zm-6 60c2.21 0 4-1.79 4-4s-1.79-4-4-4-4 1.79-4 4 1.79 4 4 4zm29 22c2.76 0 5-2.24 5-5s-2.24-5-5-5-5 2.24-5 5 2.24 5 5 5zM32 63c2.76 0 5-2.24 5-5s-2.24-5-5-5-5 2.24-5 5 2.24 5 5 5zm57-13c2.76 0 5-2.24 5-5s-2.24-5-5-5-5 2.24-5 5 2.24 5 5 5zm-9-21c1.105 0 2-.895 2-2s-.895-2-2-2-2 .895-2 2 .895 2 2 2zM60 91c1.105 0 2-.895 2-2s-.895-2-2-2-2 .895-2 2 .895 2 2 2zM35 41c1.105 0 2-.895 2-2s-.895-2-2-2-2 .895-2 2 .895 2 2 2zM12 60c1.105 0 2-.895 2-2s-.895-2-2-2-2 .895-2 2 .895 2 2 2z' fill='%23ffffff' fill-opacity='0.05' fill-rule='evenodd'/%3E%3C/svg%3E");
}

/* Falling Icons Animation */
.falling-icon {
    position: absolute;
    width: 40px;
    height: 40px;
    opacity: 0.5;
    z-index: 0;
    animation-name: falling;
    animation-timing-function: linear;
    animation-iteration-count: infinite;
}

@keyframes falling {
    0% {
        transform: translateY(-100px) rotate(0deg);
        opacity: 0;
    }
    10% {
        opacity: 0.5;
    }
    90% {
        opacity: 0.5;
    }
    100% {
        transform: translateY(500px) rotate(360deg);
        opacity: 0;
    }
}

/* First set of icons - faster animations */
.icon1 { left: 5%; animation-duration: 5s; animation-delay: 0s; }
.icon2 { left: 15%; animation-duration: 6s; animation-delay: 0.2s; }
.icon3 { left: 25%; animation-duration: 4s; animation-delay: 0.4s; }
.icon4 { left: 35%; animation-duration: 5.5s; animation-delay: 0.1s; }
.icon5 { left: 45%; animation-duration: 4.5s; animation-delay: 0.3s; }
.icon6 { left: 55%; animation-duration: 6s; animation-delay: 0.5s; }
.icon7 { left: 65%; animation-duration: 4s; animation-delay: 0s; }
.icon8 { left: 75%; animation-duration: 5.5s; animation-delay: 0.2s; }
.icon9 { left: 85%; animation-duration: 4.5s; animation-delay: 0.4s; }
.icon10 { left: 95%; animation-duration: 6s; animation-delay: 0.1s; }

/* Second set of icons with different positions and timings */
.stats-section .icon1:nth-of-type(2) { left: 10%; animation-duration: 5.5s; animation-delay: 1s; }
.stats-section .icon2:nth-of-type(2) { left: 20%; animation-duration: 4s; animation-delay: 0.8s; }
.stats-section .icon3:nth-of-type(2) { left: 30%; animation-duration: 6s; animation-delay: 1.2s; }
.stats-section .icon4:nth-of-type(2) { left: 40%; animation-duration: 4.5s; animation-delay: 1.1s; }
.stats-section .icon5:nth-of-type(2) { left: 50%; animation-duration: 5s; animation-delay: 0.9s; }
.stats-section .icon6:nth-of-type(2) { left: 60%; animation-duration: 4s; animation-delay: 1.3s; }
.stats-section .icon7:nth-of-type(2) { left: 70%; animation-duration: 6s; animation-delay: 1s; }
.stats-section .icon8:nth-of-type(2) { left: 80%; animation-duration: 4.5s; animation-delay: 0.8s; }
.stats-section .icon9:nth-of-type(2) { left: 90%; animation-duration: 5s; animation-delay: 1.2s; }
.stats-section .icon10:nth-of-type(2) { left: 3%; animation-duration: 4s; animation-delay: 1.1s; }

/* Third set of icons for even more frequency */
.stats-section .icon1:nth-of-type(3) { left: 8%; animation-duration: 6s; animation-delay: 2s; }
.stats-section .icon2:nth-of-type(3) { left: 18%; animation-duration: 4.5s; animation-delay: 1.8s; }
.stats-section .icon3:nth-of-type(3) { left: 28%; animation-duration: 5s; animation-delay: 2.2s; }
.stats-section .icon4:nth-of-type(3) { left: 38%; animation-duration: 4s; animation-delay: 2.1s; }
.stats-section .icon5:nth-of-type(3) { left: 48%; animation-duration: 6s; animation-delay: 1.9s; }
.stats-section .icon6:nth-of-type(3) { left: 58%; animation-duration: 4.5s; animation-delay: 2.3s; }
.stats-section .icon7:nth-of-type(3) { left: 68%; animation-duration: 5s; animation-delay: 2s; }
.stats-section .icon8:nth-of-type(3) { left: 78%; animation-duration: 4s; animation-delay: 1.8s; }
.stats-section .icon9:nth-of-type(3) { left: 88%; animation-duration: 6s; animation-delay: 2.2s; }
.stats-section .icon10:nth-of-type(3) { left: 98%; animation-duration: 4.5s; animation-delay: 2.1s; }

/* Fourth set of icons for maximum frequency */
.stats-section .icon1:nth-of-type(4) { left: 7%; animation-duration: 5s; animation-delay: 3s; }
.stats-section .icon2:nth-of-type(4) { left: 17%; animation-duration: 4s; animation-delay: 2.8s; }
.stats-section .icon3:nth-of-type(4) { left: 27%; animation-duration: 6s; animation-delay: 3.2s; }
.stats-section .icon4:nth-of-type(4) { left: 37%; animation-duration: 4.5s; animation-delay: 3.1s; }
.stats-section .icon5:nth-of-type(4) { left: 47%; animation-duration: 5s; animation-delay: 2.9s; }
.stats-section .icon6:nth-of-type(4) { left: 57%; animation-duration: 4s; animation-delay: 3.3s; }
.stats-section .icon7:nth-of-type(4) { left: 67%; animation-duration: 6s; animation-delay: 3s; }
.stats-section .icon8:nth-of-type(4) { left: 77%; animation-duration: 4.5s; animation-delay: 2.8s; }
.stats-section .icon9:nth-of-type(4) { left: 87%; animation-duration: 5s; animation-delay: 3.2s; }
.stats-section .icon10:nth-of-type(4) { left: 97%; animation-duration: 4s; animation-delay: 3.1s; }

/* Fifth set of icons for continuous rain effect */
.stats-section .icon1:nth-of-type(5) { left: 12%; animation-duration: 6s; animation-delay: 0.5s; }
.stats-section .icon2:nth-of-type(5) { left: 22%; animation-duration: 4.5s; animation-delay: 0.3s; }
.stats-section .icon3:nth-of-type(5) { left: 32%; animation-duration: 5s; animation-delay: 0.7s; }
.stats-section .icon4:nth-of-type(5) { left: 42%; animation-duration: 4s; animation-delay: 0.6s; }
.stats-section .icon5:nth-of-type(5) { left: 52%; animation-duration: 6s; animation-delay: 0.4s; }
.stats-section .icon6:nth-of-type(5) { left: 62%; animation-duration: 4.5s; animation-delay: 0.8s; }
.stats-section .icon7:nth-of-type(5) { left: 72%; animation-duration: 5s; animation-delay: 0.5s; }
.stats-section .icon8:nth-of-type(5) { left: 82%; animation-duration: 4s; animation-delay: 0.3s; }
.stats-section .icon9:nth-of-type(5) { left: 92%; animation-duration: 6s; animation-delay: 0.7s; }
.stats-section .icon10:nth-of-type(5) { left: 2%; animation-duration: 4.5s; animation-delay: 0.6s; }

.stats-section .section-title {
    text-align: center;
    color: var(--white);
}

.stats-section .section-title::after {
    left: 50%;
    transform: translateX(-50%);
    background-color: var(--white);
}

.stats-container {
    display: flex;
    justify-content: center;
    gap: 40px;
    margin-bottom: 30px;
    position: relative;
    z-index: 1;
    flex-wrap: wrap;
}

.stat-box {
    padding: 20px;
    background-color: rgba(58, 74, 93, 0.7);
    border-radius: var(--border-radius);
    min-width: 150px;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
    transition: transform 0.3s ease;
    position: relative;
    z-index: 2;
}

.stat-box:hover {
    transform: translateY(-5px);
}

.stat-number {
    font-size: 2.5rem;
    font-weight: 700;
    margin-bottom: 5px;
}

.stat-label {
    font-size: 0.9rem;
    opacity: 0.9;
}

/* Footer Styles */
.main-footer {
    background-color: #3a4a5d;
    color: var(--white);
    padding: 60px 0 20px;
}

.footer-content {
    display: flex;
    flex-wrap: wrap;
    gap: 40px;
    margin-bottom: 40px;
}

.footer-logo {
    flex: 1;
    min-width: 250px;
}

.footer-logo img {
    height: 40px;
    margin-bottom: 15px;
}

.footer-logo p {
    font-size: 0.9rem;
    opacity: 0.8;
    line-height: 1.6;
}

.footer-links {
    flex: 2;
    display: flex;
    justify-content: space-around;
}

.footer-column h3 {
    font-size: 1rem;
    margin-bottom: 20px;
    font-weight: 600;
}

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

.footer-column ul li a {
    color: var(--white);
    opacity: 0.8;
    font-size: 0.9rem;
    transition: opacity 0.3s ease;
}

.footer-column ul li a:hover {
    opacity: 1;
}

.footer-bottom {
    text-align: center;
    padding-top: 20px;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    font-size: 0.8rem;
    opacity: 0.7;
}

/* Copy Link Icon Styles */
.copy-link-icon {
    position: absolute;
    top: 15px;
    right: 50px;
    background-color: var(--white);
    border: 1px solid var(--medium-gray);
    border-radius: 50%;
    padding: 8px;
    cursor: pointer;
    box-shadow: var(--shadow);
    transition: background-color 0.3s ease, transform 0.2s ease;
    z-index: 2;
}

.copy-link-icon i {
    color: var(--primary-color);
    font-size: 16px;
}

.copy-link-icon:hover {
    background-color: var(--primary-color);
    transform: scale(1.05);
}

.copy-link-icon:hover i {
    color: var(--white);
}

.program-profile {
    position: relative;
}

/* Contact Popup Styles */
.contact-popup {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 1000;
}

@media (max-width: 768px) {
    .stats-container {
        flex-direction: column;
        align-items: center;
        gap: 20px;
    }

    .stat-box {
        width: 80%;
        max-width: 300px;
    }
}

.main-nav .container {
    position: relative;
    overflow-y: hidden; /* prevents arrow drop from container */
}

.program-card .program-description {
  font-size: 0.9rem;
  color: #444;
  margin: 0.5rem 0 1rem;
  line-height: 1.4;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.vendor-tagline {
  font-size: 0.95rem;
  color: #666;
  margin: 4px 0 12px;
  font-weight: 400;
}

.vendor-link {
  display: flex;
  align-items: center;
  gap: 10px;
  text-decoration: underline;
  color: inherit;
}

.vendor-logo {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  object-fit: cover;
}