/**
 * TokoPro - Modern E-Commerce Stylesheet
 * Custom UI Enhancements for Bootstrap 5.3
 */

:root {
    --primary-color: #2563eb;
    --primary-hover: #1d4ed8;
    --primary-light: #eff6ff;
    --secondary-color: #475569;
    --accent-color: #06b6d4;
    --success-color: #10b981;
    --warning-color: #f59e0b;
    --danger-color: #ef4444;
    --dark-color: #0f172a;
    --card-bg: #ffffff;
    --body-bg: #f8fafc;
    --border-color: #e2e8f0;
    --radius-sm: 8px;
    --radius-md: 12px;
    --radius-lg: 16px;
    --radius-xl: 24px;
    --shadow-sm: 0 1px 3px rgba(0,0,0,0.06), 0 1px 2px rgba(0,0,0,0.04);
    --shadow-md: 0 4px 6px -1px rgba(0,0,0,0.07), 0 2px 4px -2px rgba(0,0,0,0.05);
    --shadow-lg: 0 10px 25px -3px rgba(0,0,0,0.08), 0 4px 6px -4px rgba(0,0,0,0.04);
    --shadow-hover: 0 20px 25px -5px rgba(0,0,0,0.1), 0 8px 10px -6px rgba(0,0,0,0.06);
}

body {
    font-family: 'Plus Jakarta Sans', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
    background-color: var(--body-bg);
    color: #334155;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

main {
    flex: 1 0 auto;
}

/* Navbar Modern */
.navbar-customer {
    background-color: #ffffff;
    border-bottom: 1px solid var(--border-color);
    box-shadow: var(--shadow-sm);
    transition: all 0.3s ease;
}

.navbar-customer .nav-link {
    font-weight: 600;
    color: #475569;
    padding: 0.5rem 1rem;
    transition: color 0.2s ease;
}

.navbar-customer .nav-link:hover,
.navbar-customer .nav-link.active {
    color: var(--primary-color);
}

.search-bar-input {
    border-radius: 9999px 0 0 9999px;
    border: 1px solid var(--border-color);
    padding-left: 1.25rem;
    background: #f1f5f9;
    font-size: 0.95rem;
    transition: all 0.2s ease;
}

.search-bar-input:focus {
    background: #ffffff;
    box-shadow: none;
    border-color: var(--primary-color);
}

.search-bar-btn {
    border-radius: 0 9999px 9999px 0;
    padding-right: 1.25rem;
    padding-left: 1rem;
}

/* Category Pill Card */
.category-pill {
    background: #ffffff;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    padding: 1rem;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
    text-decoration: none;
    color: var(--dark-color);
    transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: var(--shadow-sm);
}

.category-pill:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow-md);
    border-color: var(--primary-color);
    color: var(--primary-color);
}

.category-icon-wrapper {
    width: 54px;
    height: 54px;
    border-radius: 50%;
    background: var(--primary-light);
    color: var(--primary-color);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.4rem;
    margin-bottom: 0.75rem;
    transition: all 0.25s ease;
}

.category-pill:hover .category-icon-wrapper {
    background: var(--primary-color);
    color: #ffffff;
    transform: scale(1.08);
}

/* Product Card Modern */
.product-card {
    background: #ffffff;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    overflow: hidden;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
    display: flex;
    flex-direction: column;
    height: 100%;
    box-shadow: var(--shadow-sm);
}

.product-card:hover {
    transform: translateY(-6px);
    box-shadow: var(--shadow-hover);
    border-color: #cbd5e1;
}

.product-badge-discount {
    position: absolute;
    top: 12px;
    left: 12px;
    background: linear-gradient(135deg, #ef4444, #dc2626);
    color: #ffffff;
    font-weight: 700;
    font-size: 0.75rem;
    padding: 4px 10px;
    border-radius: 9999px;
    z-index: 2;
    box-shadow: 0 4px 10px rgba(239, 68, 68, 0.3);
}

.product-wishlist-btn {
    position: absolute;
    top: 12px;
    right: 12px;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.9);
    backdrop-filter: blur(4px);
    border: 1px solid rgba(0,0,0,0.06);
    color: #64748b;
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 2;
    transition: all 0.2s ease;
    cursor: pointer;
}

.product-wishlist-btn:hover,
.product-wishlist-btn.active {
    background: #ffffff;
    color: #ef4444;
    transform: scale(1.1);
}

.product-img-wrapper {
    position: relative;
    padding-top: 85%;
    overflow: hidden;
    background: #f8fafc;
}

.product-img-wrapper img {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.4s ease;
}

.product-card:hover .product-img-wrapper img {
    transform: scale(1.05);
}

.product-card-body {
    padding: 1.1rem;
    display: flex;
    flex-direction: column;
    flex-grow: 1;
}

.product-category-text {
    font-size: 0.75rem;
    font-weight: 700;
    color: #64748b;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 0.35rem;
}

.product-title {
    font-size: 0.95rem;
    font-weight: 600;
    color: #1e293b;
    margin-bottom: 0.5rem;
    line-height: 1.4;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    height: 2.7rem;
    text-decoration: none;
}

.product-title:hover {
    color: var(--primary-color);
}

.price-current {
    font-size: 1.1rem;
    font-weight: 800;
    color: var(--primary-color);
}

.price-original {
    font-size: 0.82rem;
    color: #94a3b8;
    text-decoration: line-through;
    margin-left: 0.4rem;
}

.rating-stars {
    color: #f59e0b;
    font-size: 0.8rem;
}

/* Hero Carousel */
.hero-slider-item {
    border-radius: var(--radius-xl);
    overflow: hidden;
    padding: 60px 40px;
    color: #ffffff;
    min-height: 380px;
    display: flex;
    align-items: center;
}

/* Feature Box / Value Propositions */
.feature-box {
    background: #ffffff;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    padding: 1.5rem;
    display: flex;
    align-items: center;
    gap: 1.25rem;
    box-shadow: var(--shadow-sm);
    transition: all 0.25s ease;
}

.feature-box:hover {
    box-shadow: var(--shadow-md);
    transform: translateY(-3px);
}

.feature-box-icon {
    width: 58px;
    height: 58px;
    border-radius: 14px;
    background: var(--primary-light);
    color: var(--primary-color);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    flex-shrink: 0;
}

/* Quantity Counter Input */
.qty-counter {
    display: inline-flex;
    align-items: center;
    background: #f1f5f9;
    border-radius: var(--radius-sm);
    padding: 3px;
    border: 1px solid var(--border-color);
}

.qty-counter .btn-qty {
    width: 32px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
    border: none;
    background: #ffffff;
    border-radius: 6px;
    color: #334155;
    font-weight: 700;
    transition: all 0.2s ease;
    box-shadow: 0 1px 2px rgba(0,0,0,0.05);
}

.qty-counter .btn-qty:hover {
    background: var(--primary-color);
    color: #ffffff;
}

.qty-counter .input-qty {
    width: 44px;
    border: none;
    background: transparent;
    text-align: center;
    font-weight: 700;
    color: #1e293b;
    outline: none;
}

/* Cart Table & Summary */
.cart-card {
    background: #ffffff;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-sm);
    overflow: hidden;
}

.cart-table th {
    background: #f8fafc;
    font-weight: 700;
    color: #475569;
    font-size: 0.85rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    border-bottom: 2px solid var(--border-color);
    padding: 1rem;
}

.cart-table td {
    padding: 1.25rem 1rem;
    vertical-align: middle;
    border-bottom: 1px solid var(--border-color);
}

/* Order Status Timeline */
.timeline-steps {
    display: flex;
    justify-content: space-between;
    position: relative;
    margin: 2rem 0;
}

.timeline-steps::before {
    content: '';
    position: absolute;
    top: 20px;
    left: 40px;
    right: 40px;
    height: 3px;
    background: #e2e8f0;
    z-index: 1;
}

.timeline-step {
    position: relative;
    z-index: 2;
    text-align: center;
    flex: 1;
}

.timeline-step-icon {
    width: 42px;
    height: 42px;
    border-radius: 50%;
    background: #f1f5f9;
    color: #94a3b8;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 0.75rem auto;
    font-size: 1rem;
    border: 3px solid #ffffff;
    box-shadow: 0 2px 6px rgba(0,0,0,0.1);
    transition: all 0.3s ease;
}

.timeline-step.completed .timeline-step-icon,
.timeline-step.active .timeline-step-icon {
    background: var(--primary-color);
    color: #ffffff;
}

.timeline-step.completed .timeline-step-title {
    color: var(--primary-color);
    font-weight: 700;
}

.timeline-step-title {
    font-size: 0.8rem;
    font-weight: 600;
    color: #64748b;
}

/* Admin Sidebar Modern */
.admin-sidebar {
    width: 260px;
    background: #0f172a;
    color: #94a3b8;
    min-height: 100vh;
    transition: all 0.3s ease;
    flex-shrink: 0;
}

.admin-sidebar .sidebar-brand {
    padding: 1.5rem;
    color: #ffffff;
    font-weight: 800;
    font-size: 1.25rem;
    display: flex;
    align-items: center;
    gap: 0.75rem;
    border-bottom: 1px solid rgba(255,255,255,0.08);
}

.admin-sidebar .nav-link {
    color: #94a3b8;
    font-weight: 500;
    padding: 0.75rem 1.5rem;
    display: flex;
    align-items: center;
    gap: 0.85rem;
    border-left: 3px solid transparent;
    transition: all 0.2s ease;
}

.admin-sidebar .nav-link:hover,
.admin-sidebar .nav-link.active {
    color: #ffffff;
    background: rgba(255,255,255,0.05);
    border-left-color: var(--primary-color);
}

.admin-content {
    flex-grow: 1;
    background: #f8fafc;
    min-width: 0;
}

/* Dashboard Metric Cards */
.metric-card {
    background: #ffffff;
    border-radius: var(--radius-lg);
    border: 1px solid var(--border-color);
    padding: 1.5rem;
    box-shadow: var(--shadow-sm);
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.metric-card-icon {
    width: 56px;
    height: 56px;
    border-radius: 16px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
}

/* Print Styles */
@media print {
    body {
        background: #ffffff !important;
        color: #000000 !important;
    }
    .no-print, nav, footer, .btn, .admin-sidebar {
        display: none !important;
    }
    .invoice-card {
        border: none !important;
        box-shadow: none !important;
    }
}
