/* =====================================================================
   SMARTQRPRINT / SMARTQRPRINT - CUSTOMER MOBILE-FIRST PORTAL STYLESHEET
   ===================================================================== */

:root {
    --portal-primary: #2563eb;
    --portal-success: #10b981;
    --portal-dark: #0f172a;
    --portal-bg: #f8fafc;
}

body.portal-body {
    background-color: var(--portal-bg);
    color: #1e293b;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
    padding-bottom: calc(90px + env(safe-area-inset-bottom, 0px)); /* Space for sticky price bar on mobile */
}

/* Shop Header Card */
.portal-shop-header {
    background: #ffffff;
    border-bottom: 1px solid #e2e8f0;
    padding: 16px 0;
    position: sticky;
    top: 0;
    z-index: 1020;
    box-shadow: 0 4px 12px rgba(15, 23, 42, 0.03);
}

.shop-avatar {
    width: 48px;
    height: 48px;
    border-radius: 12px;
    background: linear-gradient(135deg, #1e3a8a, #2563eb);
    color: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.3rem;
    font-weight: 700;
}

/* Upload Dropzone */
.upload-dropzone {
    border: 2px dashed #93c5fd;
    background: #eff6ff;
    border-radius: 18px;
    padding: 32px 20px;
    text-align: center;
    cursor: pointer;
    transition: all 0.2s ease;
}

.upload-dropzone:hover, .upload-dropzone.dragover {
    border-color: var(--portal-primary);
    background: #dbeafe;
    transform: scale(0.995);
}

.upload-icon-circle {
    width: 64px;
    height: 64px;
    border-radius: 50%;
    background: #ffffff;
    color: var(--portal-primary);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 1.8rem;
    box-shadow: 0 4px 12px rgba(37, 99, 235, 0.15);
    margin-bottom: 14px;
}

/* Document Item Card */
.doc-item-card {
    background: #ffffff;
    border-radius: 16px;
    border: 1px solid #e2e8f0;
    padding: 18px;
    margin-bottom: 16px;
    box-shadow: 0 4px 10px rgba(15, 23, 42, 0.03);
    transition: all 0.2s ease;
}

.doc-item-card:hover {
    border-color: #cbd5e1;
}

/* Segmented Button Group (B&W / Color, Single / Double) */
.segmented-control {
    display: flex;
    background: #f1f5f9;
    padding: 4px;
    border-radius: 10px;
}

.segmented-control input[type="radio"] {
    display: none;
}

.segmented-control label {
    flex: 1;
    text-align: center;
    padding: 7px 10px;
    font-size: 0.84rem;
    font-weight: 600;
    color: #64748b;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.2s ease;
    margin-bottom: 0;
}

.segmented-control input[type="radio"]:checked + label {
    background: #ffffff;
    color: var(--portal-primary);
    box-shadow: 0 2px 6px rgba(15, 23, 42, 0.08);
}

/* Number Counter Input */
.counter-box {
    display: inline-flex;
    align-items: center;
    border: 1px solid #cbd5e1;
    border-radius: 10px;
    overflow: hidden;
    background: #fff;
}

.counter-btn {
    border: none;
    background: #f8fafc;
    color: #1e293b;
    width: 36px;
    height: 36px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.1rem;
    cursor: pointer;
}

.counter-btn:hover {
    background: #e2e8f0;
}

.counter-input {
    width: 48px;
    border: none;
    text-align: center;
    font-weight: 600;
    outline: none;
}

/* Mobile Sticky Checkout Bar */
.sticky-checkout-bar {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    background: #ffffff;
    border-top: 1px solid #e2e8f0;
    padding: 12px 20px calc(12px + env(safe-area-inset-bottom, 0px)) 20px;
    z-index: 1030;
    box-shadow: 0 -4px 20px rgba(15, 23, 42, 0.12);
}

@media (max-width: 576px) {
    .portal-shop-header {
        padding: 12px 0;
    }
    .shop-avatar {
        width: 42px;
        height: 42px;
        font-size: 1.15rem;
    }
    .doc-item-card {
        padding: 14px;
        border-radius: 14px;
    }
    .upload-dropzone {
        padding: 24px 14px;
        border-radius: 14px;
    }
}

/* Live Tracker Stepper */
.tracker-step {
    display: flex;
    align-items: flex-start;
    gap: 16px;
    position: relative;
    padding-bottom: 24px;
}

.tracker-step:not(:last-child)::after {
    content: '';
    position: absolute;
    left: 17px;
    top: 36px;
    bottom: 0;
    width: 2px;
    background: #e2e8f0;
}

.tracker-step.completed:not(:last-child)::after {
    background: var(--portal-success);
}

.tracker-icon {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1rem;
    background: #f1f5f9;
    color: #94a3b8;
    z-index: 1;
}

.tracker-step.completed .tracker-icon {
    background: var(--portal-success);
    color: #fff;
}

.tracker-step.active .tracker-icon {
    background: var(--portal-primary);
    color: #fff;
    box-shadow: 0 0 0 4px rgba(37, 99, 235, 0.2);
}
