/* =========================================
   MEDICARE - Premium Medical Equipment Theme
   ========================================= */

/* --- Variables (Design System) --- */
:root {
    /* Color Palette */
    --clr-primary: #0A5C70;     /* Muted, trustworthy teal/blue */
    --clr-primary-light: #12829C;
    --clr-primary-dark: #06404F;
    --clr-accent: #028090;      /* Medical accent */
    --clr-text-main: #2C3E50;   /* Deep cool gray for text */
    --clr-text-muted: #64748B;  /* Muted text */
    --clr-surface: #FFFFFF;
    --clr-surface-alt: #F8FAFC; /* Off-white base */
    --clr-surface-dark: #F1F5F9;
    --clr-border: #E2E8F0;
    --clr-success: #10B981;
    --clr-danger: #EF4444;
    --clr-warning: #F59E0B;

    /* Typography */
    --font-primary: 'Inter', system-ui, -apple-system, sans-serif;
    --font-heading: 'Outfit', 'Inter', system-ui, sans-serif;

    /* Spacing System */
    --space-1: 0.25rem;  /* 4px */
    --space-2: 0.5rem;   /* 8px */
    --space-3: 0.75rem;  /* 12px */
    --space-4: 1rem;     /* 16px */
    --space-6: 1.5rem;   /* 24px */
    --space-8: 2rem;     /* 32px */
    --space-12: 3rem;    /* 48px */
    --space-16: 4rem;    /* 64px */
    --space-20: 5rem;    /* 80px */
    --space-24: 6rem;    /* 96px */

    /* Shadows (Premium Soft Shadows) */
    --shadow-sm: 0 2px 4px rgba(10, 92, 112, 0.04);
    --shadow-md: 0 4px 12px rgba(10, 92, 112, 0.06), 0 2px 4px rgba(10, 92, 112, 0.04);
    --shadow-lg: 0 12px 24px -4px rgba(10, 92, 112, 0.08), 0 4px 12px rgba(10, 92, 112, 0.04);
    --shadow-hover: 0 20px 32px -8px rgba(10, 92, 112, 0.12), 0 10px 16px rgba(10, 92, 112, 0.06);

    /* Radii */
    --radius-sm: 6px;
    --radius-md: 10px;
    --radius-lg: 16px;
    --radius-xl: 24px;
    --radius-full: 9999px;

    /* Transitions */
    --transition-fast: 0.15s ease-in-out;
    --transition-normal: 0.3s ease-in-out;
}

/* --- Resets & Base --- */
*, *::before, *::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

html {
    font-size: 16px;
    scroll-behavior: smooth;
}

body {
    font-family: var(--font-primary);
    color: var(--clr-text-main);
    background-color: var(--clr-surface-alt);
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
}

img, picture, video, canvas, svg {
    display: block;
    max-width: 100%;
}

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

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

h1, h2, h3, h4, h5, h6 {
    font-family: var(--font-heading);
    font-weight: 600;
    line-height: 1.2;
    color: var(--clr-text-main);
    margin-bottom: var(--space-4);
}

p {
    margin-bottom: var(--space-4);
    color: var(--clr-text-muted);
}

ul, ol {
    list-style: none;
}

/* --- Typography Utilities --- */
.text-center { text-align: center; }
.text-muted { color: var(--clr-text-muted); }
.text-primary { color: var(--clr-primary); }
.font-bold { font-weight: 700; }
.font-medium { font-weight: 500; }

.h1 { font-size: clamp(2.5rem, 5vw, 4rem); font-weight: 700; letter-spacing: -0.02em; }
.h2 { font-size: clamp(2rem, 4vw, 3rem); font-weight: 700; }
.h3 { font-size: clamp(1.5rem, 3vw, 2rem); font-weight: 600; }
.h4 { font-size: 1.25rem; }

/* --- Layout --- */
.container {
    width: 100%;
    max-width: 1280px;
    margin: 0 auto;
    padding: 0 var(--space-4);
}

.section {
    padding: var(--space-12) 0;
}

@media (min-width: 768px) {
    .section {
        padding: var(--space-24) 0;
    }
}

.section-title {
    text-align: center;
    margin-bottom: var(--space-12);
}

.section-title h2 {
    margin-bottom: var(--space-2);
}

.section-title p {
    font-size: 1.125rem;
    max-width: 600px;
    margin: 0 auto;
}

/* --- Grid System --- */
.grid {
    display: grid;
    gap: var(--space-6);
}

.grid-cols-2 { grid-template-columns: repeat(2, 1fr); }
.grid-cols-3 { grid-template-columns: repeat(3, 1fr); }
.grid-cols-4 { grid-template-columns: repeat(4, 1fr); }

@media (max-width: 1024px) {
    .grid-cols-4 { grid-template-columns: repeat(3, 1fr); }
}

@media (max-width: 768px) {
    .grid-cols-4, .grid-cols-3, .grid-cols-2 { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 480px) {
    .grid-cols-4, .grid-cols-3, .grid-cols-2 { grid-template-columns: 1fr; }
}

/* --- Components --- */
/* Buttons */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0.625rem var(--space-6);
    font-weight: 600;
    font-family: var(--font-primary);
    border-radius: var(--radius-full);
    border: 1px solid transparent;
    cursor: pointer;
    transition: all var(--transition-normal);
    text-decoration: none;
    font-size: 0.95rem;
    gap: var(--space-2);
}

.btn-primary {
    background: linear-gradient(135deg, var(--clr-primary-light), var(--clr-primary));
    color: var(--clr-surface);
    box-shadow: var(--shadow-sm);
}

.btn-primary:hover {
    background: linear-gradient(135deg, var(--clr-primary), var(--clr-primary-dark));
    color: var(--clr-surface);
    transform: translateY(-2px);
    box-shadow: var(--shadow-md);
}

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

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

.btn-block {
    display: flex;
    width: 100%;
}

/* Product Cards */
.product-card {
    position: relative;
    background-color: var(--clr-surface);
    border-radius: var(--radius-lg);
    overflow: hidden;
    box-shadow: var(--shadow-sm);
    transition: all var(--transition-normal);
    border: 1px solid var(--clr-border);
    display: flex;
    flex-direction: column;
    height: 100%;
}

.product-card:hover {
    box-shadow: var(--shadow-hover);
    transform: translateY(-4px);
    border-color: rgba(10, 92, 112, 0.15);
}

.product-card-img {
    position: relative;
    width: 100%;
    padding-top: 100%; /* 1:1 Aspect Ratio */
    background-color: var(--clr-surface-dark);
    overflow: hidden;
}

.product-card-img img {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.6s cubic-bezier(0.165, 0.84, 0.44, 1);
}

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

.product-badge {
    position: absolute;
    top: var(--space-3);
    right: var(--space-3);
    background: var(--clr-surface);
    color: var(--clr-primary-dark);
    padding: var(--space-1) var(--space-3);
    font-size: 0.75rem;
    font-weight: 600;
    border-radius: var(--radius-full);
    z-index: 10;
}

.product-card-body {
    padding: var(--space-4);
    display: flex;
    flex-direction: column;
    flex-grow: 1;
}

.product-category {
    font-size: 0.875rem;
    color: var(--clr-text-muted);
    margin-bottom: var(--space-1);
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.product-title {
    font-size: 1.125rem;
    font-weight: 600;
    margin-bottom: var(--space-2);
    color: var(--clr-text-main);
    line-height: 1.3;
}

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

.product-desc {
    font-size: 0.875rem;
    color: var(--clr-text-muted);
    margin-bottom: var(--space-4);
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.product-card-footer {
    margin-top: auto;
    padding-top: var(--space-4);
    border-top: 1px solid var(--clr-border);
}

/* Category Cards */
.category-card {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    background: var(--clr-surface);
    padding: var(--space-6);
    border-radius: var(--radius-lg);
    text-align: center;
    box-shadow: var(--shadow-sm);
    transition: all var(--transition-normal);
    border: 1px solid var(--clr-border);
    text-decoration: none;
    position: relative;
    overflow: hidden;
}

.category-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(to bottom right, rgba(10, 92, 112, 0.02), transparent);
    opacity: 0;
    transition: opacity var(--transition-normal);
}

.category-card:hover {
    box-shadow: var(--shadow-md);
    transform: translateY(-4px);
    border-color: rgba(10, 92, 112, 0.2);
}

.category-card:hover::before {
    opacity: 1;
}

.category-card-icon {
    width: 72px;
    height: 72px;
    background: rgba(10, 92, 112, 0.06);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: var(--space-4);
    color: var(--clr-primary);
    transition: all var(--transition-normal);
    position: relative;
    z-index: 1;
}

.category-card:hover .category-card-icon {
    background: var(--clr-primary);
    color: var(--clr-surface);
    transform: scale(1.05);
}

.category-card h3 {
    margin-bottom: 0;
    font-size: 1.125rem;
    position: relative;
    z-index: 1;
}

.category-card.has-bg {
    color: white;
    border: none;
    min-height: 200px;
}

.category-card.has-bg h3 {
    color: white;
    font-size: 1.5rem;
    text-shadow: 0 2px 8px rgba(0,0,0,0.5);
    z-index: 2;
}

.category-card.has-bg::before {
    display: none; /* Hide default gradient hover */
}

.category-card.has-bg::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(10, 92, 112, 0.7);
    transition: background var(--transition-normal);
    z-index: 1;
}

.category-card.has-bg:hover::after {
    background: rgba(10, 92, 112, 0.5);
}

/* Forms */
.form-group {
    margin-bottom: var(--space-4);
}

.form-label {
    display: block;
    margin-bottom: var(--space-2);
    font-weight: 500;
    color: var(--clr-text-main);
    font-size: 0.875rem;
}

.form-control {
    width: 100%;
    padding: var(--space-3) var(--space-4);
    border: 1px solid var(--clr-border);
    border-radius: var(--radius-md);
    background-color: var(--clr-surface);
    color: var(--clr-text-main);
    font-family: var(--font-primary);
    font-size: 1rem;
    transition: all var(--transition-fast);
}

.form-control:focus {
    outline: none;
    border-color: var(--clr-primary);
    box-shadow: 0 0 0 3px rgba(10, 92, 112, 0.1);
}

textarea.form-control {
    min-height: 120px;
    resize: vertical;
}

/* --- Header & Navigation --- */
.site-header {
    background-color: var(--clr-surface);
    box-shadow: var(--shadow-sm);
    position: sticky;
    top: 0;
    z-index: 1000;
}

.top-bar {
    background-color: var(--clr-primary-dark);
    color: var(--clr-surface);
    padding: var(--space-2) 0;
    font-size: 0.875rem;
}

.top-bar-inner {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.top-bar a {
    color: var(--clr-surface);
    opacity: 0.8;
}

.top-bar a:hover {
    opacity: 1;
}

.nav-container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    height: 84px;
}

.logo {
    font-family: var(--font-heading);
    font-size: 1.6rem;
    font-weight: 700;
    color: var(--clr-primary);
    display: flex;
    align-items: center;
    gap: var(--space-2);
}

.logo span {
    color: var(--clr-text-main);
}

.main-nav {
    display: flex;
    gap: var(--space-6);
    align-items: center;
}

.nav-link {
    color: var(--clr-text-main);
    font-weight: 500;
    position: relative;
    padding: var(--space-2) 0;
}

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

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

.nav-link:hover::after, .nav-link.active::after {
    width: 100%;
}

.nav-actions {
    display: flex;
    align-items: center;
    margin-left: var(--space-2);
}

.mobile-toggle {
    display: none;
    background: none;
    border: none;
    font-size: 1.5rem;
    color: var(--clr-text-main);
    cursor: pointer;
}

/* Mobile Menu */
@media (max-width: 992px) {
    .main-nav {
        display: none;
        position: absolute;
        top: 100%;
        left: 0;
        width: 100%;
        background: var(--clr-surface);
        flex-direction: column;
        padding: var(--space-4);
        box-shadow: var(--shadow-md);
        gap: var(--space-4);
    }
    
    .main-nav.active {
        display: flex;
    }
    
    .mobile-toggle {
        display: block;
    }
    
    .nav-actions .btn {
        display: none;
    }
    
    .top-bar {
        display: none;
    }
}

/* --- Hero Section --- */
.hero {
    position: relative;
    background-color: var(--clr-surface-alt);
    padding: var(--space-20) 0 var(--space-16);
    overflow: hidden;
}

.hero::before {
    content: '';
    position: absolute;
    top: -50%;
    right: -20%;
    width: 800px;
    height: 800px;
    background: radial-gradient(circle, rgba(10,92,112,0.06) 0%, rgba(255,255,255,0) 70%);
    border-radius: 50%;
    z-index: 0;
}

.hero-inner {
    display: grid;
    grid-template-columns: 1.1fr 0.9fr;
    gap: var(--space-12);
    align-items: center;
    position: relative;
    z-index: 1;
}

.hero-content h1 {
    color: var(--clr-primary-dark);
}

.hero-content p {
    font-size: 1.25rem;
    margin-bottom: var(--space-8);
}

.hero-actions {
    display: flex;
    gap: var(--space-4);
}

.hero-image {
    position: relative;
    display: flex;
    justify-content: flex-end;
}

.hero-image-card {
    background: var(--clr-surface);
    border-radius: var(--radius-xl);
    padding: var(--space-2);
    box-shadow: var(--shadow-lg);
    width: 100%;
    max-width: 500px;
    position: relative;
}

.hero-image-card::after {
    content: '';
    position: absolute;
    bottom: -20px;
    left: -20px;
    width: 120px;
    height: 120px;
    background: radial-gradient(circle, var(--clr-border) 20%, transparent 20%), radial-gradient(circle, var(--clr-border) 20%, transparent 20%);
    background-size: 16px 16px;
    background-position: 0 0, 8px 8px;
    z-index: -1;
    border-radius: var(--radius-lg);
    opacity: 0.5;
}

.hero-image img {
    border-radius: var(--radius-lg);
    width: 100%;
    display: block;
}

@media (max-width: 992px) {
    .hero {
        padding: var(--space-12) 0;
    }
    
    .hero-inner {
        grid-template-columns: 1fr;
        text-align: center;
    }
    
    .hero-actions {
        justify-content: center;
    }
    
    .hero-image {
        grid-row: 1; /* Move image to top on mobile */
    }
}

/* --- Footer --- */
.site-footer {
    background-color: var(--clr-primary-dark);
    color: rgba(255, 255, 255, 0.8);
    padding: var(--space-16) 0 var(--space-6);
}

.footer-grid {
    display: grid;
    grid-template-columns: 2fr 1fr 1fr 1.5fr;
    gap: var(--space-8);
    margin-bottom: var(--space-12);
}

.footer-col h4 {
    color: white;
    margin-bottom: var(--space-6);
}

.footer-logo {
    color: white !important;
    margin-bottom: var(--space-4);
}

.footer-links li {
    margin-bottom: var(--space-2);
}

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

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

.footer-contact li {
    display: flex;
    gap: var(--space-3);
    margin-bottom: var(--space-3);
}

.footer-bottom {
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    padding-top: var(--space-6);
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 0.875rem;
}

@media (max-width: 992px) {
    .footer-grid {
        grid-template-columns: 1fr 1fr;
    }
}

@media (max-width: 576px) {
    .footer-grid {
        grid-template-columns: 1fr;
    }
    
    .footer-bottom {
        flex-direction: column;
        gap: var(--space-4);
        text-align: center;
    }
}

/* --- Utilities --- */
.bg-white { background-color: var(--clr-surface); }
.bg-light { background-color: var(--clr-surface-alt); }
.bg-primary-light { background-color: rgba(10, 92, 112, 0.05); }
.d-flex { display: flex; }
.align-center { align-items: center; }
.justify-between { justify-content: space-between; }
.justify-center { justify-content: center; }
.gap-2 { gap: var(--space-2); }
.gap-4 { gap: var(--space-4); }

/* Decorative Elements */
.shape-blob {
    position: absolute;
    background: var(--clr-primary-light);
    border-radius: 50%;
    filter: blur(60px);
    opacity: 0.1;
    z-index: 0;
}

/* --- Floating WhatsApp --- */
.whatsapp-float {
    position: fixed;
    bottom: 30px;
    right: 30px;
    background-color: #25d366;
    color: white;
    width: 60px;
    height: 60px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 30px;
    box-shadow: var(--shadow-lg);
    z-index: 1000;
    transition: transform var(--transition-fast);
}

.whatsapp-float:hover {
    transform: scale(1.1);
    color: white;
}

/* --- Page Header --- */
.page-header {
    background-color: var(--clr-primary-dark);
    color: white;
    padding: var(--space-12) 0;
    text-align: center;
}

.page-header h1 {
    color: white;
    margin-bottom: var(--space-2);
}

.breadcrumb {
    display: flex;
    justify-content: center;
    gap: var(--space-2);
    font-size: 0.875rem;
    color: rgba(255, 255, 255, 0.7);
}

.breadcrumb a {
    color: white;
}
