/* Custom CSS for mcs_web_obat - Public Drug Price List */

body {
    background-color: #f7f9fc;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
    color: #333333;
    margin: 0;
    padding: 0;
}

/* Header & Search Area */
.obat-header {
    position: relative;
    background: linear-gradient(135deg, #1e3c72 0%, #2a5298 100%);
    padding: 60px 20px 40px 20px;
    text-align: center;
    color: #ffffff;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
    margin-bottom: 30px;
    border-radius: 0 0 20px 20px;
}

.header-top-bar {
    position: absolute;
    top: 25px;
    left: 30px;
}

.company-logo-top {
    height: 50px;
    width: auto;
    background-color: rgba(255, 255, 255, 0.95);
    padding: 8px 15px;
    border-radius: 8px;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.08);
    object-fit: contain;
}

.obat-header h1 {
    font-size: 2.5rem;
    font-weight: 700;
    margin-bottom: 25px;
    letter-spacing: -0.5px;
}

.search-container {
    max-width: 600px;
    margin: 0 auto;
    position: relative;
}

.search-form {
    display: flex;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.15);
    border-radius: 50px;
    overflow: hidden;
    background: #ffffff;
    border: 1px solid rgba(255, 255, 255, 0.2);
}

.search-input {
    flex-grow: 1;
    border: none;
    padding: 15px 25px;
    font-size: 1rem;
    outline: none;
    color: #333;
    border-radius: 50px 0 0 50px;
}

.search-button {
    background-color: #00c9a7;
    color: #ffffff;
    border: none;
    padding: 15px 30px;
    font-weight: 600;
    cursor: pointer;
    transition: background-color 0.2s ease;
    border-radius: 0 50px 50px 0;
    outline: none;
}

.search-button:hover {
    background-color: #00b395;
}

/* Container */
.obat-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px 60px 20px;
}

/* Card Grid */
.obat-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
    gap: 25px;
    margin-bottom: 40px;
}

/* Card Style */
.obat-card {
    background: #ffffff;
    border-radius: 16px;
    overflow: hidden;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.05);
    border: 1px solid #eef2f5;
    transition: all 0.3s cubic-bezier(0.25, 0.8, 0.25, 1);
    display: flex;
    flex-direction: column;
    height: 100%;
}

.obat-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 12px 24px rgba(0, 0, 0, 0.1);
    border-color: #dbe3eb;
}

/* Image Container */
.obat-image-container {
    position: relative;
    width: 100%;
    padding-top: 100%; /* 1:1 Aspect Ratio */
    background-color: #fbfbfb;
    border-bottom: 1px solid #f0f4f8;
    overflow: hidden;
}

.obat-image {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: contain;
    padding: 15px;
    transition: transform 0.5s ease;
}

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

/* Fallback/Placeholder Image */
.obat-image-placeholder {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #f0f4f8;
    color: #a0aec0;
}

.placeholder-icon {
    width: 48px;
    height: 48px;
    stroke-width: 1.5;
}

/* Card Body */
.obat-details {
    padding: 20px;
    display: flex;
    flex-direction: column;
    flex-grow: 1;
}

.obat-name {
    font-size: 1.05rem;
    font-weight: 600;
    line-height: 1.4;
    color: #2d3748;
    margin: 0 0 8px 0;
    min-height: 44px; /* Ensure 2 lines are consistent */
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.obat-bentuk {
    font-size: 0.85rem;
    color: #718096;
    margin: 0 0 15px 0;
    font-weight: 500;
}

.obat-price {
    font-size: 1.2rem;
    font-weight: 700;
    color: #2b6cb0;
    margin-top: auto;
}

/* No Results */
.no-results {
    text-align: center;
    padding: 60px 20px;
    color: #718096;
}

.no-results svg {
    width: 64px;
    height: 64px;
    color: #cbd5e0;
    margin-bottom: 15px;
}

.no-results h3 {
    font-size: 1.4rem;
    color: #4a5568;
    margin-bottom: 5px;
}

/* Pagination */
.obat-pagination {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 8px;
    margin-top: 30px;
    padding-top: 20px;
    border-top: 1px solid #eef2f5;
}

.page-link-custom {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 40px;
    height: 40px;
    padding: 0 10px;
    border-radius: 8px;
    border: 1px solid #e2e8f0;
    background-color: #ffffff;
    color: #4a5568;
    font-weight: 600;
    text-decoration: none;
    transition: all 0.2s ease;
}

.page-link-custom:hover {
    border-color: #cbd5e0;
    background-color: #f7fafc;
    color: #2d3748;
}

.page-link-custom.active {
    background-color: #2a5298;
    color: #ffffff;
    border-color: #2a5298;
}

.page-link-custom.disabled {
    opacity: 0.5;
    pointer-events: none;
    background-color: #edf2f7;
}

/* Responsive Grid Adjustments */
@media (max-width: 768px) {
    .obat-header {
        padding: 30px 20px;
    }
    .header-top-bar {
        position: static;
        margin-bottom: 20px;
        display: flex;
        justify-content: center;
    }
    .obat-grid {
        grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
        gap: 15px;
    }
    .obat-header h1 {
        font-size: 2rem;
    }
    .obat-details {
        padding: 12px;
    }
    .obat-name {
        font-size: 0.95rem;
        min-height: 40px;
    }
    .obat-price {
        font-size: 1.05rem;
    }
}
