<?php
$page_title = 'PLM & Innovation';
require_once __DIR__ . '/../config.php';
if (session_status() === PHP_SESSION_NONE) { session_start(); }
if (!isset($_SESSION['admin_id'])) { redirect(SITE_URL . '/admin/login.php'); }
require_once __DIR__ . '/header.php';
?>

<div style="display:flex; justify-content:space-between; align-items:center; margin-bottom:24px;">
    <div>
        <h2 style="font-family:'Outfit', sans-serif; font-size:1.8rem; color:#0f172a; margin:0;">Product Lifecycle & Innovation</h2>
        <p style="color:#64748b; font-size:0.95rem; margin-top:5px;">NPD pipeline, Material BOM management, and R&D lab tracking.</p>
    </div>
    <button style="background:#2563eb; color:#fff; border:none; padding:10px 20px; border-radius:8px; font-weight:600; cursor:pointer;"><i class="fas fa-plus" style="margin-right:8px;"></i> New NPD Project</button>
</div>

<div class="grid-2">
    <!-- NPD Pipeline -->
    <div style="background:#fff; padding:20px; border-radius:12px; border:1px solid #e2e8f0;">
        <h3 style="margin:0 0 20px; font-size:1.15rem; color:#0f172a;"><i class="fas fa-rocket" style="color:#6366f1; margin-right:8px;"></i> NPD Pipeline</h3>
        
        <div style="border:1px solid #e2e8f0; border-radius:8px; padding:15px; margin-bottom:12px;">
            <div style="display:flex; justify-content:space-between; align-items:center; margin-bottom:10px;">
                <h4 style="margin:0; font-size:0.95rem;">Anti-Bacterial Nano Coating Sink</h4>
                <span style="background:#dbeafe; color:#1d4ed8; padding:3px 8px; border-radius:10px; font-size:0.7rem; font-weight:bold;">PROTOTYPE</span>
            </div>
            <div style="background:#e2e8f0; height:6px; border-radius:3px; overflow:hidden;">
                <div style="width:65%; height:100%; background:#3b82f6; border-radius:3px;"></div>
            </div>
            <div style="font-size:0.8rem; color:#64748b; margin-top:8px;">65% complete • Target launch: Q4 2026</div>
        </div>
        
        <div style="border:1px solid #e2e8f0; border-radius:8px; padding:15px; margin-bottom:12px;">
            <div style="display:flex; justify-content:space-between; align-items:center; margin-bottom:10px;">
                <h4 style="margin:0; font-size:0.95rem;">Smart IoT Faucet with Flow Sensor</h4>
                <span style="background:#fef3c7; color:#b45309; padding:3px 8px; border-radius:10px; font-size:0.7rem; font-weight:bold;">DESIGN</span>
            </div>
            <div style="background:#e2e8f0; height:6px; border-radius:3px; overflow:hidden;">
                <div style="width:30%; height:100%; background:#f59e0b; border-radius:3px;"></div>
            </div>
            <div style="font-size:0.8rem; color:#64748b; margin-top:8px;">30% complete • Engineering review pending</div>
        </div>
        
        <div style="border:1px solid #e2e8f0; border-radius:8px; padding:15px;">
            <div style="display:flex; justify-content:space-between; align-items:center; margin-bottom:10px;">
                <h4 style="margin:0; font-size:0.95rem;">Rose Gold PVD Finish Line</h4>
                <span style="background:#dcfce7; color:#166534; padding:3px 8px; border-radius:10px; font-size:0.7rem; font-weight:bold;">APPROVED</span>
            </div>
            <div style="background:#e2e8f0; height:6px; border-radius:3px; overflow:hidden;">
                <div style="width:90%; height:100%; background:#10b981; border-radius:3px;"></div>
            </div>
            <div style="font-size:0.8rem; color:#64748b; margin-top:8px;">90% complete • Production trial next week</div>
        </div>
    </div>

    <!-- R&D Lab + Patents -->
    <div style="display:flex; flex-direction:column; gap:20px;">
        <div style="background:#fff; padding:20px; border-radius:12px; border:1px solid #e2e8f0;">
            <h3 style="margin:0 0 15px; font-size:1.15rem; color:#0f172a;"><i class="fas fa-flask" style="color:#ec4899; margin-right:8px;"></i> Lab & Material Testing</h3>
            <div style="display:flex; justify-content:space-between; font-size:0.9rem; padding:10px 0; border-bottom:1px solid #f1f5f9;">
                <span>Salt spray test (SS-304 Batch #442)</span>
                <span style="color:#10b981; font-weight:bold;">PASSED ✓</span>
            </div>
            <div style="display:flex; justify-content:space-between; font-size:0.9rem; padding:10px 0; border-bottom:1px solid #f1f5f9;">
                <span>Tensile strength (New alloy sample)</span>
                <span style="color:#d97706; font-weight:bold;">IN PROGRESS</span>
            </div>
            <div style="display:flex; justify-content:space-between; font-size:0.9rem; padding:10px 0;">
                <span>PVD coating adhesion test</span>
                <span style="color:#10b981; font-weight:bold;">PASSED ✓</span>
            </div>
        </div>

        <div style="background:linear-gradient(135deg, #1e293b, #0f172a); padding:20px; border-radius:12px; color:#fff;">
            <h3 style="margin:0 0 15px; font-size:1.1rem; color:#38bdf8;"><i class="fas fa-lightbulb" style="margin-right:8px;"></i> Patent & IP Tracker</h3>
            <div style="display:flex; justify-content:space-between; font-size:0.9rem; padding:8px 0; border-bottom:1px solid rgba(255,255,255,0.1);">
                <span style="color:#cbd5e1;">Active Patents</span>
                <span style="font-weight:bold;">12</span>
            </div>
            <div style="display:flex; justify-content:space-between; font-size:0.9rem; padding:8px 0; border-bottom:1px solid rgba(255,255,255,0.1);">
                <span style="color:#cbd5e1;">Pending Applications</span>
                <span style="color:#f59e0b; font-weight:bold;">3</span>
            </div>
            <div style="display:flex; justify-content:space-between; font-size:0.9rem; padding:8px 0;">
                <span style="color:#cbd5e1;">Innovation Budget Used</span>
                <span style="font-weight:bold;">₹1.2 Cr / ₹2 Cr</span>
            </div>
        </div>
    </div>
</div>

<?php require_once __DIR__ . '/footer.php'; ?>
