/* ==========================================================================
   ShopVista Premium Products & Category Page CSS (With Image Support)
   ========================================================================== */

.prod-wrapper {
    animation: fadeIn 0.4s ease-in-out;
}

/* টপ হেডার স্টাইল */
.prod-header {
    margin-bottom: 1.8rem;
}

.header-info h2 {
    font-size: 1.4rem;
    color: #2c3e50;
    font-weight: 700;
    margin-bottom: 4px;
}

.header-info p {
    font-size: 0.85rem;
    color: #858796;
}

/* মেইন গ্রিড লেআউট: ডেস্কটপে ফর্ম নেবে ১ ভাগ, টেবিল নেবে ২ ভাগ জায়গা */
.prod-grid {
    display: grid;
    grid-template-columns: 1fr 1.8fr;
    gap: 1.5rem;
    align-items: start;
}

/* কমন কার্ড ডিজাইন */
.prod-card {
    background: #ffffff;
    border-radius: 14px;
    padding: 1.5rem;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.02);
    border: 1px solid rgba(0, 0, 0, 0.03);
}

.prod-card h3 {
    font-size: 1.1rem;
    color: #2c3e50;
    margin-bottom: 1.2rem;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 8px;
}

.prod-card h3 i {
    color: #4e73df;
}

/* --- ফর্ম এলিমেন্ট স্টাইলিং --- */
.form-group {
    margin-bottom: 1.1rem;
}

.form-group label {
    display: block;
    font-size: 0.82rem;
    font-weight: 600;
    color: #4e73df;
    margin-bottom: 6px;
}

.form-group input, 
.form-group textarea {
    width: 100%;
    padding: 0.75rem 1rem;
    border: 1px solid #d1d3e2;
    border-radius: 8px;
    font-size: 0.9rem;
    color: #6e707e;
    background: #f8f9fc;
    transition: all 0.2s ease;
}

.form-group input:focus, 
.form-group textarea:focus {
    outline: none;
    border-color: #4e73df;
    background: #ffffff;
    box-shadow: 0 0 0 3px rgba(78, 115, 223, 0.15);
}

/* ফাইল আপলোড ইনপুটের জন্য স্পেশাল ডিজাইন */
.form-group input[type="file"] {
    padding: 0.5rem;
    cursor: pointer;
    background: #ffffff;
    border: 1px dashed #4e73df;
}

.form-group input[type="file"]::file-selector-button {
    background: #4e73df;
    color: #ffffff;
    border: none;
    padding: 0.4rem 1rem;
    border-radius: 6px;
    font-weight: 600;
    font-size: 0.8rem;
    margin-right: 10px;
    cursor: pointer;
    transition: background 0.2s ease;
}

.form-group input[type="file"]::file-selector-button:hover {
    background: #2e59d9;
}

.btn-submit {
    width: 100%;
    padding: 0.75rem;
    background: linear-gradient(135deg, #4e73df 0%, #2e59d9 100%);
    color: #ffffff;
    border: none;
    border-radius: 8px;
    font-weight: 600;
    font-size: 0.9rem;
    cursor: pointer;
    box-shadow: 0 4px 12px rgba(78, 115, 223, 0.2);
    transition: all 0.2s ease;
}

.btn-submit:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 15px rgba(78, 115, 223, 0.3);
}

/* --- টেবিল স্টাইলিং --- */
.table-responsive {
    width: 100%;
    overflow-x: auto;
}

.prod-table {
    width: 100%;
    border-collapse: collapse;
    text-align: left;
    font-size: 0.9rem;
}

.prod-table th {
    background-color: #f8f9fc;
    color: #4e73df;
    font-weight: 600;
    padding: 0.8rem 1rem;
    border-bottom: 2px solid #e3e6f0;
}

.prod-table td {
    padding: 0.9rem 1rem;
    border-bottom: 1px solid #e3e6f0;
    color: #5a5c69;
    vertical-align: middle;
}

.cat-title {
    font-weight: 600;
    color: #2c3e50;
}

.prod-table code {
    background: #f1f3f9;
    padding: 3px 6px;
    border-radius: 4px;
    font-family: monospace;
    color: #e74c3c;
    font-size: 0.85rem;
}

/* --- টেবিলে ক্যাটাগরির ছবি ডিজাইন --- */
.table-cat-img {
    width: 45px;
    height: 45px;
    object-fit: cover;
    border-radius: 8px;
    border: 1px solid #e3e6f0;
    box-shadow: 0 2px 6px rgba(0,0,0,0.06);
    display: block;
}

/* ছবি না থাকলে ডামি ব্যাকগ্রাউন্ড */
.no-image-placeholder {
    width: 45px;
    height: 45px;
    background-color: #f1f3f9;
    color: #a3b8cc;
    display: flex;
    justify-content: center;
    align-items: center;
    border-radius: 8px;
    font-size: 1.2rem;
    border: 1px solid #e3e6f0;
}

/* স্ট্যাটাস ব্যাজ */
.status-badge {
    font-size: 0.75rem;
    padding: 4px 10px;
    border-radius: 20px;
    font-weight: 600;
}

.status-badge.active {
    background-color: rgba(28, 200, 138, 0.1);
    color: #1cc88a;
}

.status-badge.inactive {
    background-color: rgba(231, 76, 60, 0.1);
    color: #e74c3c;
}

/* অ্যাকশন বাটনসমূহ */
.action-btns {
    display: flex;
    gap: 6px;
}

.btn-action {
    border: none;
    width: 32px;
    height: 32px;
    border-radius: 6px;
    display: flex;
    justify-content: center;
    align-items: center;
    cursor: pointer;
    font-size: 0.85rem;
    transition: all 0.2s;
    text-decoration: none; /* অ্যাঙ্কর ট্যাগের আন্ডারলাইন কাটবে */
}

.btn-action.edit { background: #f0f3ff; color: #4e73df; }
.btn-action.edit:hover { background: #4e73df; color: #ffffff; }

.btn-action.delete { background: #fff5f5; color: #e74c3c; }
.btn-action.delete:hover { background: #e74c3c; color: #ffffff; }

/* --- অ্যালার্ট নোটিফিকেশন সিএসএস --- */
.alert {
    padding: 0.8rem 1.2rem;
    border-radius: 8px;
    margin-bottom: 1.5rem;
    font-size: 0.9rem;
    font-weight: 500;
    animation: fadeIn 0.3s ease-in-out;
}
.alert-success {
    background-color: rgba(28, 200, 138, 0.1);
    color: #1cc88a;
    border: 1px solid rgba(28, 200, 138, 0.2);
}
.alert-danger {
    background-color: rgba(231, 76, 60, 0.1);
    color: #e74c3c;
    border: 1px solid rgba(231, 76, 60, 0.2);
}

/* পেজ ট্রানজিশন অ্যানিমেশন */
@keyframes fadeIn {
    from { opacity: 0; transform: translateY(10px); }
    to { opacity: 1; transform: translateY(0); }
}

/* ==========================================================================
   মোবাইল ও ট্যাবলেট রেসপন্সিভ ভিউ (Responsive Layout Fix)
   ========================================================================== */

@media (max-width: 992px) {
    .prod-grid {
        grid-template-columns: 1fr; /* মাঝারি বা ছোট স্ক্রিনে ফর্ম উপরে এবং টেবিল নিচে চলে যাবে */
        gap: 1.2rem;
    }
}