/* ============================================
   KarCMS v2.0 - Frontend Theme CSS
   Customizable theme - override with site-specific CSS
   ============================================ */

/* --- CSS Custom Properties (Easy theming) --- */
:root {
    --primary: #0d6efd;
    --primary-dark: #0a58ca;
    --primary-light: #6ea8fe;
    --secondary: #1a1a2e;
    --accent: #e94560;
    --success: #198754;
    --warning: #ffc107;
    --danger: #dc3545;
    --text-color: #333;
    --text-muted: #6c757d;
    --bg-light: #f8f9fa;
    --bg-dark: #1a1a2e;
    --border-color: #dee2e6;
    --white: #fff;
    --shadow-sm: 0 1px 3px rgba(0,0,0,0.08);
    --shadow-md: 0 4px 12px rgba(0,0,0,0.1);
    --shadow-lg: 0 8px 24px rgba(0,0,0,0.12);
    --radius-sm: 6px;
    --radius-md: 10px;
    --radius-lg: 16px;
    --transition: all 0.3s ease;
    --font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    --navbar-height: 70px;
}

/* --- Base --- */
body {
    font-family: var(--font-family);
    color: var(--text-color);
    line-height: 1.7;
}

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

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

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

/* --- Top Bar --- */
.top-bar {
    background: var(--secondary);
    color: rgba(255,255,255,0.8);
    padding: 8px 0;
    font-size: 0.85rem;
}

.top-bar a {
    color: rgba(255,255,255,0.8);
    margin-right: 20px;
}

.top-bar a:hover {
    color: var(--white);
}

.top-bar .social-links a {
    margin-right: 10px;
    font-size: 1rem;
}

/* --- Navbar --- */
#mainNavbar {
    background: var(--white);
    box-shadow: var(--shadow-sm);
    padding: 10px 0;
    z-index: 1000;
    transition: var(--transition);
}

#mainNavbar.scrolled {
    padding: 5px 0;
    box-shadow: var(--shadow-md);
}

.navbar-brand img {
    transition: var(--transition);
}

.navbar-nav .nav-link {
    color: var(--text-color);
    font-weight: 500;
    padding: 10px 15px;
    font-size: 0.95rem;
}

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

.btn-cta {
    font-weight: 600;
    padding: 10px 24px;
    border-radius: var(--radius-sm);
}

.dropdown-menu {
    border: none;
    box-shadow: var(--shadow-md);
    border-radius: var(--radius-sm);
    padding: 8px 0;
}

.dropdown-item {
    padding: 8px 20px;
    font-size: 0.9rem;
}

.dropdown-item:hover {
    background: var(--bg-light);
}

/* --- Language Switcher --- */
.language-switcher .dropdown-toggle {
    color: inherit;
    text-decoration: none;
    font-size: 0.85rem;
}

.language-switcher .dropdown-toggle::after {
    margin-left: 4px;
}

.flag-img {
    display: inline-block;
    width: 20px;
    height: 15px;
    object-fit: cover;
    border-radius: 2px;
    vertical-align: middle;
    border: 1px solid rgba(0,0,0,0.1);
}

/* --- Breadcrumb --- */
.breadcrumb-section {
    background: var(--bg-light);
    padding: 15px 0;
    border-bottom: 1px solid var(--border-color);
}

.breadcrumb {
    font-size: 0.85rem;
}

.breadcrumb-item a {
    color: var(--text-muted);
}

.breadcrumb-item.active {
    color: var(--primary);
}

/* --- Hero Slider --- */
.hero-slider {
    position: relative;
}

.hero-slider .slide-inner {
    height: 600px;
    background-size: cover;
    background-position: center;
    display: flex;
    align-items: center;
    position: relative;
}

.hero-slider .slide-inner::before {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(to right, rgba(0,0,0,0.7) 0%, rgba(0,0,0,0.2) 100%);
}

.hero-slider .slide-content {
    position: relative;
    z-index: 2;
    max-width: 600px;
    color: var(--white);
}

.hero-slider .slide-title {
    font-size: 3rem;
    font-weight: 700;
    margin-bottom: 15px;
    line-height: 1.2;
}

.hero-slider .slide-desc {
    font-size: 1.15rem;
    margin-bottom: 25px;
    opacity: 0.9;
}

.hero-slider .swiper-button-next,
.hero-slider .swiper-button-prev {
    color: var(--white);
}

.hero-slider .swiper-pagination-bullet-active {
    background: var(--primary);
}

@media (max-width: 768px) {
    .hero-slider .slide-inner {
        height: 400px;
    }
    .hero-slider .slide-title {
        font-size: 1.8rem;
    }
}

/* --- Stats Section --- */
.stats-section {
    background: var(--primary);
}

.stat-item {
    padding: 20px 10px;
}

.stat-number {
    font-size: 2.5rem;
    font-weight: 700;
    line-height: 1.2;
}

.stat-label {
    font-size: 0.95rem;
    opacity: 0.85;
    margin-top: 5px;
}

/* --- Section Headers --- */
.section-title {
    font-size: 2rem;
    font-weight: 700;
    color: var(--secondary);
    margin-bottom: 10px;
}

.section-subtitle {
    color: var(--text-muted);
    font-size: 1.05rem;
}

/* --- Product Cards --- */
.product-card {
    background: var(--white);
    border-radius: var(--radius-md);
    overflow: hidden;
    box-shadow: var(--shadow-sm);
    transition: var(--transition);
    height: 100%;
    display: flex;
    flex-direction: column;
}

.product-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-lg);
}

.product-card-image {
    display: block;
    overflow: hidden;
    aspect-ratio: 3/2;
}

.product-card-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s ease;
}

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

.product-card-body {
    padding: 20px;
    flex: 1;
    display: flex;
    flex-direction: column;
}

.product-card-title {
    font-size: 1.15rem;
    font-weight: 600;
    margin-bottom: 8px;
}

.product-card-title a {
    color: var(--text-color);
}

.product-card-title a:hover {
    color: var(--primary);
}

.product-card-desc {
    color: var(--text-muted);
    font-size: 0.9rem;
    flex: 1;
    margin-bottom: 15px;
}

/* --- Blog Cards --- */
.blog-card {
    background: var(--white);
    border-radius: var(--radius-md);
    overflow: hidden;
    box-shadow: var(--shadow-sm);
    transition: var(--transition);
    height: 100%;
}

.blog-card:hover {
    box-shadow: var(--shadow-md);
}

.blog-card-image {
    display: block;
    overflow: hidden;
    aspect-ratio: 3/2;
}

.blog-card-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s ease;
}

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

.blog-card-body {
    padding: 20px;
}

.blog-card-date {
    color: var(--text-muted);
    font-size: 0.8rem;
    margin-bottom: 8px;
}

.blog-card-title {
    font-size: 1.05rem;
    font-weight: 600;
    margin-bottom: 8px;
    line-height: 1.4;
}

.blog-card-title a {
    color: var(--text-color);
}

.blog-card-title a:hover {
    color: var(--primary);
}

.blog-card-desc {
    color: var(--text-muted);
    font-size: 0.88rem;
    margin-bottom: 10px;
}

.blog-card-link {
    color: var(--primary);
    font-weight: 500;
    font-size: 0.9rem;
}

/* --- CTA Section --- */
.cta-section {
    background: linear-gradient(135deg, var(--secondary) 0%, #16213e 100%);
    color: var(--white);
}

.cta-box {
    padding: 40px;
}

.cta-box h2 {
    font-size: 2rem;
    font-weight: 700;
    margin-bottom: 15px;
}

.cta-box p {
    opacity: 0.85;
    font-size: 1.1rem;
    margin-bottom: 25px;
}

/* --- References --- */
.reference-logo {
    max-height: 60px;
    filter: grayscale(100%);
    opacity: 0.6;
    transition: var(--transition);
}

.reference-logo:hover {
    filter: grayscale(0%);
    opacity: 1;
}

/* --- Mini Call Form --- */
.mini-call-section {
    background: var(--bg-light);
}

/* --- Footer --- */
.site-footer {
    background: var(--secondary);
    color: rgba(255,255,255,0.7);
}

.footer-main {
    padding: 60px 0 40px;
}

.footer-brand {
    color: var(--white);
}

.footer-logo {
    filter: brightness(0) invert(1);
}

.footer-about-text {
    font-size: 0.9rem;
    line-height: 1.6;
}

.footer-social a {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background: rgba(255,255,255,0.1);
    color: rgba(255,255,255,0.7);
    margin-right: 8px;
    transition: var(--transition);
}

.footer-social a:hover {
    background: var(--primary);
    color: var(--white);
}

.footer-widget-title {
    color: var(--white);
    font-size: 1.1rem;
    font-weight: 600;
    margin-bottom: 20px;
    position: relative;
    padding-bottom: 10px;
}

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

.footer-links {
    list-style: none;
    padding: 0;
    margin: 0;
}

.footer-links li {
    margin-bottom: 8px;
}

.footer-links a {
    color: rgba(255,255,255,0.6);
    font-size: 0.9rem;
    transition: var(--transition);
}

.footer-links a:hover {
    color: var(--white);
    padding-left: 5px;
}

.footer-contact-item p {
    margin-bottom: 8px;
    font-size: 0.9rem;
}

.footer-contact-item a {
    color: rgba(255,255,255,0.6);
}

.footer-contact-item a:hover {
    color: var(--white);
}

.footer-contact-item i {
    margin-right: 8px;
    color: var(--primary);
}

.footer-bottom {
    padding: 20px 0;
    border-top: 1px solid rgba(255,255,255,0.1);
    font-size: 0.85rem;
}

.footer-bottom-links {
    list-style: none;
    padding: 0;
    margin: 0;
    display: flex;
    gap: 20px;
    justify-content: flex-end;
}

.footer-bottom-links a {
    color: rgba(255,255,255,0.5);
}

.footer-bottom-links a:hover {
    color: var(--white);
}

/* --- Floating Actions --- */
.floating-actions {
    position: fixed;
    bottom: 20px;
    right: 20px;
    z-index: 999;
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.floating-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 50px;
    height: 50px;
    border-radius: 50%;
    border: none;
    color: var(--white);
    font-size: 1.4rem;
    cursor: pointer;
    box-shadow: var(--shadow-md);
    transition: var(--transition);
}

.floating-btn:hover {
    transform: scale(1.1);
}

.floating-whatsapp {
    background: #25d366;
}

.floating-phone {
    background: var(--primary);
}

.floating-top {
    background: var(--secondary);
}

/* --- Page Content --- */
.page-content {
    padding: 40px 0;
}

.page-content h1 {
    font-size: 2rem;
    font-weight: 700;
    margin-bottom: 20px;
}

/* --- Responsive --- */
@media (max-width: 991px) {
    .footer-bottom-links {
        justify-content: flex-start;
        margin-top: 10px;
    }
}

@media (max-width: 768px) {
    .section-title {
        font-size: 1.6rem;
    }

    .stat-number {
        font-size: 1.8rem;
    }

    .cta-box h2 {
        font-size: 1.5rem;
    }
}
