/* =========================================
   SimpleZwroty - Premium Form CSS v2.0
   ========================================= */

@import url('https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700;800&display=swap');

.sz-form-container {
    max-width: 820px !important;
    margin: 2rem auto !important;
    padding: 0 1rem !important;
    font-family: var(--sz-main-font, 'Inter'), sans-serif !important;
    color: #1a202c !important;
}

/* ---- Step Indicator ---- */
.sz-step-indicator {
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    margin-bottom: 2.5rem !important;
    gap: 0 !important;
    position: relative !important;
}

.sz-step-indicator::before {
    content: '' !important;
    position: absolute !important;
    top: 20px !important;
    left: 15% !important;
    right: 15% !important;
    height: 2px !important;
    background: #e2e8f0 !important;
    z-index: 0 !important;
}

.sz-step-dot-wrap {
    display: flex !important;
    flex-direction: column !important;
    align-items: center !important;
    gap: 8px !important;
    flex: 1 !important;
    z-index: 1 !important;
}

.sz-step-dot {
    width: 40px !important;
    height: 40px !important;
    border-radius: 50% !important;
    border: 2px solid #e2e8f0 !important;
    background: #ffffff !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    font-size: 0.85rem !important;
    font-weight: 700 !important;
    color: #94a3b8 !important;
    transition: all 0.4s cubic-bezier(0.34, 1.56, 0.64, 1) !important;
    box-shadow: 0 2px 8px rgba(0,0,0,0.06) !important;
}

.sz-step-dot.active {
    background: var(--sz-main-color) !important;
    border-color: var(--sz-main-color) !important;
    color: #ffffff !important;
    box-shadow: 0 4px 16px rgba(13, 110, 253, 0.35) !important;
    transform: scale(1.1) !important;
}

.done .sz-step-dot {
    background: #ecfdf5 !important;
    border-color: #10b981 !important;
    color: #10b981 !important;
}

.sz-step-dot.done::after {
    content: '✓' !important;
}

.sz-step-dot.done span { display: none !important; }

.sz-step-label {
    font-size: 0.72rem !important;
    font-weight: 500 !important;
    color: #94a3b8 !important;
    text-align: center !important;
    white-space: nowrap !important;
    transition: color 0.3s !important;
}

.sz-step-dot-wrap.active .sz-step-label { color: var(--sz-main-color) !important; font-weight: 600 !important; }
.sz-step-dot-wrap.done .sz-step-label { color: #10b981 !important; }

/* ---- Card ---- */
.sz-card {
    background: #ffffff !important;
    border-radius: 24px !important;
    box-shadow: 0 8px 40px rgba(0, 0, 0, 0.08), 0 1px 3px rgba(0,0,0,0.04) !important;
    border: 1px solid rgba(226, 232, 240, 0.6) !important;
    overflow: hidden !important;
    position: relative !important;
}

/* ---- Slides Container ---- */
.sz-slides-container {
    overflow: hidden !important;
    position: relative !important;
}

.sz-slide {
    display: none !important;
    padding: 2.5rem !important;
    animation-duration: 0.45s !important;
    animation-timing-function: cubic-bezier(0.4, 0, 0.2, 1) !important;
    animation-fill-mode: both !important;
}

.sz-slide.active {
    display: block !important;
}

.sz-slide.slide-in-right {
    animation-name: szSlideInRight !important;
}

.sz-slide.slide-out-left {
    animation-name: szSlideOutLeft !important;
}

.sz-slide.slide-in-left {
    animation-name: szSlideInLeft !important;
}

.sz-slide.slide-out-right {
    animation-name: szSlideOutRight !important;
}

@keyframes szSlideInRight {
    from { opacity: 0; transform: translateX(60px); }
    to   { opacity: 1; transform: translateX(0); }
}
@keyframes szSlideOutLeft {
    from { opacity: 1; transform: translateX(0); }
    to   { opacity: 0; transform: translateX(-60px); }
}
@keyframes szSlideInLeft {
    from { opacity: 0; transform: translateX(-60px); }
    to   { opacity: 1; transform: translateX(0); }
}
@keyframes szSlideOutRight {
    from { opacity: 1; transform: translateX(0); }
    to   { opacity: 0; transform: translateX(60px); }
}

/* ---- Slide Header ---- */
.sz-slide-header {
    margin-bottom: 2rem !important;
    padding-bottom: 1.25rem !important;
    border-bottom: 1px solid #f1f5f9 !important;
}

.sz-slide-header h2 {
    margin: 0 0 0.4rem 0 !important;
    font-weight: 800 !important;
    font-size: 1.45rem !important;
    color: #0f172a !important;
    letter-spacing: -0.025em !important;
}

.sz-slide-header p {
    margin: 0 !important;
    color: #64748b !important;
    font-size: 0.92rem !important;
}

/* ---- Form Controls ---- */
.sz-label {
    display: block !important;
    font-size: 0.83rem !important;
    font-weight: 600 !important;
    color: #374151 !important;
    margin-bottom: 0.4rem !important;
    letter-spacing: 0.01em !important;
}

.sz-label .sz-required-star {
    color: #ef4444 !important;
    margin-left: 3px !important;
}

.sz-form-control, .sz-form-select {
    display: block !important;
    width: 100% !important;
    border-radius: 12px !important;
    border: 1.5px solid #e2e8f0 !important;
    padding: 0.8rem 1.1rem !important;
    font-size: 0.95rem !important;
    font-family: inherit !important;
    transition: all 0.2s ease !important;
    background-color: #f8fafc !important;
    color: #334155 !important;
    outline: none !important;
    box-shadow: none !important;
}

.sz-form-control:focus, .sz-form-select:focus {
    background-color: #ffffff !important;
    border-color: var(--sz-main-color) !important;
    box-shadow: 0 0 0 3px rgba(13, 110, 253, 0.12) !important;
}

.sz-form-control::placeholder { color: #b0bac7 !important; }

textarea.sz-form-control { resize: vertical !important; min-height: 100px !important; }

/* ---- Buttons ---- */
.sz-btn-row {
    display: flex !important;
    align-items: center !important;
    gap: 12px !important;
    margin-top: 2rem !important;
}

.sz-btn {
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    gap: 8px !important;
    border-radius: 12px !important;
    padding: 0.8rem 1.8rem !important;
    font-weight: 600 !important;
    font-size: 0.95rem !important;
    font-family: inherit !important;
    cursor: pointer !important;
    transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1) !important;
    border: none !important;
    letter-spacing: 0.01em !important;
    text-decoration: none !important;
}

.sz-btn-primary {
    background-color: var(--sz-main-color) !important;
    color: #ffffff !important;
    box-shadow: 0 4px 14px rgba(13, 110, 253, 0.25) !important;
    flex: 1 !important;
}

.sz-btn-primary:hover {
    transform: translateY(-2px) !important;
    box-shadow: 0 8px 22px rgba(13, 110, 253, 0.35) !important;
    color: #ffffff !important;
    filter: brightness(1.08) !important;
}

.sz-btn-primary:disabled {
    opacity: 0.65 !important;
    cursor: not-allowed !important;
    transform: none !important;
    box-shadow: none !important;
    filter: none !important;
}

.sz-btn-primary:visited, .sz-btn-primary:focus, .sz-btn-primary:active {
    color: #ffffff !important;
}

.sz-btn-back {
    background: transparent !important;
    color: #64748b !important;
    border: 1.5px solid #e2e8f0 !important;
    padding: 0.8rem 1.2rem !important;
}

.sz-btn-back:hover {
    background: #f1f5f9 !important;
    border-color: #cbd5e1 !important;
    color: #334155 !important;
}

/* ---- Loader ---- */
.sz-loader {
    display: none !important;
    padding: 3rem !important;
    text-align: center !important;
}

.sz-spinner-ring {
    display: inline-block !important;
    width: 44px !important;
    height: 44px !important;
    border: 3px solid #f1f5f9 !important;
    border-top-color: var(--sz-main-color) !important;
    border-radius: 50% !important;
    animation: szSpin 0.8s linear infinite !important;
}

@keyframes szSpin {
    to { transform: rotate(360deg); }
}

.sz-loader p {
    margin-top: 1rem !important;
    color: #64748b !important;
    font-size: 0.9rem !important;
}

/* ---- Product List ---- */
.sz-product-list {
    display: flex !important;
    flex-direction: column !important;
    gap: 12px !important;
    margin-bottom: 1.5rem !important;
}

.sz-product-item {
    border: 1.5px solid #f1f5f9 !important;
    border-radius: 16px !important;
    padding: 1rem 1.25rem !important;
    display: flex !important;
    align-items: center !important;
    gap: 1rem !important;
    cursor: pointer !important;
    transition: all 0.2s ease !important;
    background: #fafafa !important;
    user-select: none !important;
}

.sz-product-item:hover {
    border-color: var(--sz-main-color) !important;
    background: #f8faff !important;
}

.sz-product-item.selected {
    border-color: var(--sz-main-color) !important;
    background: #f0f7ff !important;
    box-shadow: 0 0 0 1px var(--sz-main-color), 0 4px 16px rgba(13, 110, 253, 0.1) !important;
}

.sz-product-img {
    width: 64px !important;
    height: 64px !important;
    border-radius: 10px !important;
    object-fit: cover !important;
    background: #e2e8f0 !important;
    border: 1px solid #e2e8f0 !important;
    flex-shrink: 0 !important;
}

.sz-product-info { flex: 1 !important; }

.sz-product-name {
    font-weight: 700 !important;
    font-size: 0.9rem !important;
    color: #1e293b !important;
    line-height: 1.4 !important;
    margin-bottom: 2px !important;
}

.sz-product-meta {
    font-size: 0.82rem !important;
    color: #64748b !important;
    font-weight: 500 !important;
}

/* Custom checkbox */
.sz-check-wrap {
    flex-shrink: 0 !important;
}

.sz-product-checkbox {
    width: 22px !important;
    height: 22px !important;
    border-radius: 7px !important;
    border: 2px solid #cbd5e1 !important;
    appearance: none !important;
    -webkit-appearance: none !important;
    outline: none !important;
    cursor: pointer !important;
    position: relative !important;
    transition: all 0.2s ease !important;
    background: #ffffff !important;
    display: block !important;
}

.sz-product-checkbox:checked {
    background: var(--sz-main-color) !important;
    border-color: var(--sz-main-color) !important;
}

.sz-product-checkbox:checked::after {
    content: '' !important;
    position: absolute !important;
    left: 5px !important;
    top: 2px !important;
    width: 6px !important;
    height: 11px !important;
    border: solid white !important;
    border-width: 0 2px 2px 0 !important;
    transform: rotate(45deg) !important;
}

/* ---- Qty controls ---- */
.sz-qty-wrapper {
    display: flex !important;
    align-items: center !important;
    gap: 8px !important;
    margin-top: 10px !important;
    padding: 5px 10px !important;
    background: #f1f5f9 !important;
    border-radius: 8px !important;
}

.sz-qty-label {
    font-size: 0.75rem !important;
    color: #64748b !important;
    font-weight: 500 !important;
    white-space: nowrap !important;
}

.sz-qty-controls {
    display: flex !important;
    align-items: center !important;
    gap: 4px !important;
}

.sz-qty-btn {
    width: 24px !important;
    height: 24px !important;
    border-radius: 6px !important;
    border: 1px solid #cbd5e1 !important;
    background: #fff !important;
    color: #334155 !important;
    font-size: 0.95rem !important;
    cursor: pointer !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    padding: 0 !important;
    transition: all 0.15s !important;
    line-height: 1 !important;
}

.sz-qty-btn:hover {
    background: var(--sz-main-color) !important;
    color: #fff !important;
    border-color: var(--sz-main-color) !important;
}

.sz-qty-wrapper .sz-qty-input {
    width: 38px !important;
    height: 24px !important;
    text-align: center !important;
    border-radius: 6px !important;
    border: 1px solid #cbd5e1 !important;
    font-weight: 700 !important;
    font-size: 0.82rem !important;
    padding: 0 !important;
    background: #fff !important;
}

.sz-qty-max {
    font-size: 0.7rem !important;
    color: #94a3b8 !important;
}

/* Exchange size input */
.sz-exchange-size {
    margin-top: 0.6rem !important;
    font-size: 0.85rem !important;
}

/* ---- Alerts ---- */
.sz-alert {
    border-radius: 12px !important;
    padding: 0.9rem 1.1rem !important;
    margin-bottom: 1.25rem !important;
    border: none !important;
    font-size: 0.88rem !important;
    font-weight: 500 !important;
    display: none;
}

.sz-alert-danger {
    background: #fef2f2 !important;
    color: #991b1b !important;
    border-left: 4px solid #ef4444 !important;
}

.sz-alert-success {
    background: #f0fdf4 !important;
    color: #065f46 !important;
    border-left: 4px solid #10b981 !important;
}

/* ---- Success step ---- */
.sz-success-wrap {
    text-align: center !important;
    padding: 3rem 2rem !important;
}

.sz-success-icon {
    width: 72px !important;
    height: 72px !important;
    border-radius: 50% !important;
    background: linear-gradient(135deg, #10b981, #059669) !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    margin: 0 auto 1.5rem !important;
    font-size: 2rem !important;
    box-shadow: 0 8px 24px rgba(16, 185, 129, 0.35) !important;
    animation: szBounceIn 0.6s cubic-bezier(0.34, 1.56, 0.64, 1) !important;
}

@keyframes szBounceIn {
    from { transform: scale(0.3); opacity: 0; }
    to   { transform: scale(1); opacity: 1; }
}

.sz-success-wrap h3 {
    font-size: 1.4rem !important;
    font-weight: 800 !important;
    color: #0f172a !important;
    margin-bottom: 0.5rem !important;
}

.sz-success-wrap p {
    color: #64748b !important;
    max-width: 400px !important;
    margin: 0 auto !important;
}

/* ---- Omnibus badge ---- */
.sz-omnibus-badge {
    display: flex !important;
    align-items: center !important;
    gap: 10px !important;
    margin-top: 1.5rem !important;
    padding: 0.75rem 1.1rem !important;
    background: #f0f9ff !important;
    border: 1px solid #bae6fd !important;
    border-radius: 10px !important;
    font-size: 0.8rem !important;
    color: #0369a1 !important;
    font-weight: 500 !important;
}

.sz-omnibus-badge svg {
    flex-shrink: 0 !important;
}

/* ---- Bank field ---- */
.sz-bank-account-wrapper { display: none; margin-top: 0.75rem !important; }

/* ---- Responsive ---- */
@media (max-width: 600px) {
    .sz-slide { padding: 1.5rem !important; }
    .sz-step-label { display: none !important; }
    .sz-btn-row { flex-direction: column-reverse !important; }
    .sz-btn-primary, .sz-btn-back { width: 100% !important; }

    .sz-product-item {
        align-items: flex-start !important;
    }
    .sz-qty-wrapper {
        flex-direction: column !important;
        align-items: flex-start !important;
        gap: 6px !important;
    }
    .sz-qty-controls {
        width: 100% !important;
    }
}
