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

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', 'Roboto', 'Oxygen', 'Ubuntu', 'Cantarell', sans-serif;
    background: linear-gradient(135deg, #d4f1f4 0%, #a7e9f0 50%, #7dd3da 100%);
    min-height: 100vh;
    color: #1f2937;
}

.container {
    max-width: 1280px;
    margin: 0 auto;
    padding: 0 1rem;
}

/* Header */
.header {
    background: white;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
    position: sticky;
    top: 0;
    z-index: 1000;
    padding: 1rem 0;
}

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

.logo-section {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.logo-icon {
    background: linear-gradient(135deg, #10b981 0%, #14b8a6 100%);
    padding: 0.75rem;
    border-radius: 12px;
}

.logo-icon i {
    color: white;
    font-size: 1.75rem;
}

.logo-text h1 {
    font-size: 1.5rem;
    color: #1f2937;
    margin-bottom: 0.25rem;
}

.logo-text p {
    font-size: 0.75rem;
    color: #6b7280;
}

.btn-primary {
    background: linear-gradient(135deg, #10b981 0%, #14b8a6 100%);
    color: white;
    border: none;
    padding: 0.75rem 1.5rem;
    border-radius: 8px;
    font-weight: 600;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    transition: all 0.3s;
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 20px rgba(16, 185, 129, 0.3);
}

.btn-full {
    width: 100%;
    justify-content: center;
}

/* Dashboard */
.dashboard {
    padding: 2rem 0;
}

.metrics-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 1.5rem;
    margin-bottom: 2rem;
}

.metric-card {
    background: white;
    border-radius: 12px;
    padding: 1.5rem;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
    transition: all 0.3s;
}

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

.metric-emerald { border-left: 4px solid #10b981; }
.metric-teal { border-left: 4px solid #14b8a6; }
.metric-cyan { border-left: 4px solid #06b6d4; }
.metric-blue { border-left: 4px solid #3b82f6; }

.metric-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 0.5rem;
}

.metric-header i:first-child {
    font-size: 2rem;
}

.metric-emerald .metric-header i { color: #10b981; }
.metric-teal .metric-header i { color: #14b8a6; }
.metric-cyan .metric-header i { color: #06b6d4; }
.metric-blue .metric-header i { color: #3b82f6; }

.metric-value {
    font-size: 2rem;
    font-weight: bold;
    color: #1f2937;
    margin-bottom: 0.25rem;
}

.metric-label {
    font-size: 0.875rem;
    color: #6b7280;
}

/* Recent Connections */
.recent-connections {
    background: linear-gradient(135deg, #d1fae5 0%, #a7f3d0 100%);
    border-radius: 12px;
    padding: 1.5rem;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
}

.recent-connections h3 {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    margin-bottom: 1rem;
    color: #065f46;
}

.recent-connections h3 i {
    color: #10b981;
}

.connection-item {
    background: white;
    border-radius: 8px;
    padding: 1rem;
    margin-bottom: 0.5rem;
    animation: pulse 2s infinite;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.connection-item p {
    font-size: 0.875rem;
    color: #374151;
}

.connection-item strong {
    color: #10b981;
}

@keyframes pulse {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.8; }
}

/* Search Section */
.search-section {
    padding: 1rem 0 2rem 0;
}

.search-box {
    background: white;
    border-radius: 12px;
    padding: 1.5rem;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
}

.search-input-wrapper {
    position: relative;
    margin-bottom: 1rem;
}

.search-input-wrapper i {
    position: absolute;
    left: 1rem;
    top: 50%;
    transform: translateY(-50%);
    color: #9ca3af;
}

.search-input-wrapper input {
    width: 100%;
    padding: 0.75rem 1rem 0.75rem 3rem;
    border: 2px solid #e5e7eb;
    border-radius: 8px;
    font-size: 1rem;
    transition: all 0.3s;
}

.search-input-wrapper input:focus {
    outline: none;
    border-color: #10b981;
    box-shadow: 0 0 0 3px rgba(16, 185, 129, 0.1);
}

.filter-buttons {
    display: flex;
    gap: 0.5rem;
    flex-wrap: wrap;
}

.filter-btn {
    padding: 0.5rem 1rem;
    border: none;
    border-radius: 8px;
    background: #f3f4f6;
    color: #374151;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.3s;
}

.filter-btn:hover {
    background: #e5e7eb;
}

.filter-btn.active {
    background: linear-gradient(135deg, #10b981 0%, #14b8a6 100%);
    color: white;
    box-shadow: 0 4px 6px rgba(16, 185, 129, 0.3);
}

/* Medicine Grid */
.medicines-section {
    padding: 0 0 3rem 0;
}

.medicine-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 1.5rem;
}

.medicine-card {
    background: white;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
    transition: all 0.3s;
}

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

.medicine-header {
    background: linear-gradient(135deg, #10b981 0%, #14b8a6 100%);
    padding: 1.5rem;
}

.medicine-header h3 {
    color: white;
    font-size: 1.125rem;
    margin-bottom: 0.5rem;
}

.category-badge {
    display: inline-block;
    background: white;
    color: #059669;
    padding: 0.25rem 0.75rem;
    border-radius: 20px;
    font-size: 0.75rem;
    font-weight: 600;
}

.medicine-body {
    padding: 1.5rem;
}

.medicine-details {
    margin-bottom: 1.5rem;
}

.detail-item {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    margin-bottom: 0.75rem;
    font-size: 0.875rem;
    color: #6b7280;
}

.detail-item i {
    width: 1rem;
}

.detail-item i.fa-box { color: #10b981; }
.detail-item i.fa-calendar { color: #14b8a6; }
.detail-item i.fa-map-marker-alt { color: #06b6d4; }
.detail-item i.fa-award { color: #fbbf24; }

.detail-item strong {
    color: #1f2937;
}

.no-results {
    text-align: center;
    padding: 3rem;
    background: white;
    border-radius: 12px;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
}

.no-results i {
    font-size: 4rem;
    color: #d1d5db;
    margin-bottom: 1rem;
}

.no-results p {
    color: #6b7280;
    font-size: 1.125rem;
}

/* Modal */
.modal {
    display: none;
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.5);
    z-index: 2000;
    align-items: center;
    justify-content: center;
    padding: 1rem;
}

.modal.active {
    display: flex;
}

.modal-content {
    background: white;
    border-radius: 16px;
    max-width: 500px;
    width: 100%;
    max-height: 90vh;
    overflow-y: auto;
    box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.1);
}

.modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1.5rem;
    border-bottom: 1px solid #e5e7eb;
}

.modal-header h2 {
    font-size: 1.5rem;
    color: #1f2937;
}

.close-btn {
    background: none;
    border: none;
    font-size: 1.5rem;
    color: #6b7280;
    cursor: pointer;
    transition: color 0.3s;
}

.close-btn:hover {
    color: #1f2937;
}

.modal-body {
    padding: 1.5rem;
}

.form-group {
    margin-bottom: 1.25rem;
}

.form-group label {
    display: block;
    font-weight: 600;
    color: #374151;
    margin-bottom: 0.5rem;
    font-size: 0.875rem;
}

.form-group input,
.form-group select {
    width: 100%;
    padding: 0.75rem;
    border: 2px solid #e5e7eb;
    border-radius: 8px;
    font-size: 1rem;
    transition: all 0.3s;
}

.form-group input:focus,
.form-group select:focus {
    outline: none;
    border-color: #10b981;
    box-shadow: 0 0 0 3px rgba(16, 185, 129, 0.1);
}

.request-details {
    background: linear-gradient(135deg, #d1fae5 0%, #a7f3d0 100%);
    border-radius: 8px;
    padding: 1.5rem;
    margin-bottom: 1.5rem;
}

.request-details h3 {
    font-size: 1.125rem;
    color: #1f2937;
    margin-bottom: 1rem;
}

.request-details p {
    font-size: 0.875rem;
    color: #6b7280;
    margin-bottom: 0.5rem;
}

.verification-note {
    background: #fef3c7;
    border-left: 4px solid #fbbf24;
    padding: 1rem;
    margin-bottom: 1.5rem;
    border-radius: 4px;
    font-size: 0.875rem;
    color: #374151;
}

/* Responsive */
@media (max-width: 768px) {
    .header-content {
        flex-direction: column;
        gap: 1rem;
    }

    .metrics-grid {
        grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
    }

    .filter-buttons {
        justify-content: center;
    }

    .medicine-grid {
        grid-template-columns: 1fr;
    }
}