@import url('https://fonts.googleapis.com/css2?family=Poppins:wght@300;400;500;600;700&display=swap');

/* Base styles */
body {
    font-family: 'Poppins', sans-serif;
    -webkit-tap-highlight-color: transparent;
}

/* Search input styles */
#search {
    color: #000000;
    transition: all 0.3s ease;
    -webkit-appearance: none;
}

#search:hover {
    box-shadow: 0 0 15px rgba(59, 130, 246, 0.3);
}

#search:focus {
    box-shadow: 0 0 20px rgba(59, 130, 246, 0.4);
}

/* Medication card styles */
.medication-card {
    transition: all 0.3s ease;
    touch-action: manipulation;
}

.medication-card:hover {
    transform: translateY(-5px);
}

/* Mobile touch styles */
@media (hover: none) {
    .medication-card:hover {
        transform: none;
    }

    .medication-card:active {
        transform: scale(0.98);
    }
}

/* Comparison table responsive styles */
.comparison-table {
    margin-top: 2rem;
    width: 100%;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    scroll-behavior: smooth;
}

/* Ensure table is scrollable on mobile */
.comparison-table table {
    min-width: 640px;
    width: 100%;
    border-collapse: separate;
    border-spacing: 0;
}

.comparison-table th,
.comparison-table td {
    padding: 1rem;
    border-bottom: 1px solid #e5e7eb;
    white-space: normal;
    word-wrap: break-word;
}

/* Mobile-friendly padding */
@media (max-width: 768px) {
    .comparison-table th,
    .comparison-table td {
        padding: 0.75rem;
        font-size: 0.875rem;
    }
}

/* Added smooth transitions for chips */
.medication-chip {
    transition: all 0.2s ease;
    opacity: 1;
    transform: translateY(0);
    display: inline-flex;
    align-items: center;
    margin: 0.25rem;
    padding: 0.5rem 1rem;
    border-radius: 9999px;
    font-size: 0.875rem;
    line-height: 1.25rem;
    white-space: nowrap;
}

.medication-chip button {
    padding: 0.25rem;
    margin-left: 0.5rem;
    border-radius: 9999px;
    touch-action: manipulation;
}

.medication-chip.removing {
    opacity: 0;
    transform: translateY(-10px);
}


#searchArea {
    transition: opacity 0.3s ease;
    opacity: 1;
}

#searchArea.hidden {
    opacity: 0;
    pointer-events: none;
}