:root {
    --pc-brand: #40778c;
    --pc-brand-dark: #2e6174;
    --pc-teal: #009688;
    --pc-class-b: #3d6a83;
    --pc-class-b-dark: #2d5468;
    --pc-class-b-soft: #edf3f7;
    --pc-class-b-border: #c4d6e2;
    --pc-green: #0f9d58;
    --pc-orange: #ff4b1f;
    --pc-ink: #1f2a30;
    --pc-line: #e2e7ea;
}

.floating-cart-btn {
    position: fixed;
    right: 28px;
    bottom: 32px;
    z-index: 999;
    height: 62px;
    min-width: 180px;
    border: 0;
    border-radius: 999px;
    background: var(--pc-brand);
    color: #fff;
    box-shadow: 0 20px 48px rgba(31, 42, 48, .28);
    display: none;
    align-items: center;
    justify-content: center;
    gap: 10px;
    cursor: pointer;
    font-weight: 800;
    font-size: 15px;
    letter-spacing: .3px;
    font-family: Arial, Helvetica, sans-serif;
    transition: transform .2s ease, box-shadow .2s ease;
    animation: pcFloatPulse 2.4s ease-in-out infinite;
}
.floating-cart-btn.visible {
    display: flex;
}
.floating-cart-btn:hover {
    transform: translateY(-3px) scale(1.04);
    box-shadow: 0 26px 56px rgba(31, 42, 48, .35);
    animation: none;
}
@keyframes pcFloatPulse {
    0%, 100% { box-shadow: 0 20px 48px rgba(31, 42, 48, .28); }
    50% { box-shadow: 0 20px 60px rgba(64, 119, 140, .45); }
}
.floating-cart-btn .bubble {
    background: #fff;
    color: var(--pc-brand);
    min-width: 26px;
    height: 26px;
    padding: 0 6px;
    border-radius: 999px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 13px;
    font-weight: 800;
    line-height: 1;
}
@media (max-width: 620px) {
    .floating-cart-btn {
        right: 14px;
        bottom: 16px;
        min-width: 148px;
        height: 54px;
        font-size: 14px;
    }
}

.parts-cart-drawer-overlay {
    position: fixed;
    inset: 0;
    background: rgba(15, 24, 28, .36);
    z-index: 1000;
    display: none;
}
.parts-cart-drawer-overlay.open {
    display: block;
}
.parts-cart-drawer {
    position: fixed;
    top: 0;
    right: 0;
    height: 100vh;
    width: 680px;
    max-width: 96vw;
    background: #fff;
    z-index: 1001;
    box-shadow: -20px 0 50px rgba(0,0,0,.18);
    transform: translateX(105%);
    transition: .25s ease;
    display: flex;
    flex-direction: column;
    font-family: Arial, Helvetica, sans-serif;
    color: var(--pc-ink);
    font-size: 14px;
}
.parts-cart-drawer.open {
    transform: translateX(0);
}
.parts-cart-drawer .drawer-head {
    height: 66px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 22px;
    border-bottom: 1px solid var(--pc-line);
    flex-shrink: 0;
}
.parts-cart-drawer .drawer-head h2 {
    margin: 0;
    font-size: 18px;
}
.parts-cart-drawer .drawer-close {
    border: 0;
    background: transparent;
    cursor: pointer;
    font-size: 28px;
    color: #647279;
    line-height: 1;
}
.parts-cart-drawer .drawer-body {
    padding: 18px 22px;
    overflow-y: auto;
    flex: 1;
    min-height: 0;
}
.parts-cart-drawer .drawer-summary {
    border-top: 1px solid var(--pc-line);
    padding: 16px 22px 22px;
    background: #fbfcfc;
    flex-shrink: 0;
    min-height: 100px;
    box-shadow: 0 -8px 24px rgba(15, 24, 28, .06);
}
.parts-cart-drawer .drawer-empty-actions {
    margin-top: 16px;
    padding-top: 16px;
    border-top: 1px dashed #d8e0e4;
}
.parts-cart-drawer .drawer-empty-actions .pc-btn {
    margin-top: 10px;
}
.parts-cart-drawer .cart-section {
    border: 1px solid #e5eaed;
    border-radius: 12px;
    overflow: hidden;
    margin-bottom: 16px;
    background: #fff;
}
.parts-cart-drawer .cart-section-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    padding: 13px 14px;
    background: #f8fafb;
    border-bottom: 1px solid #e5eaed;
    font-weight: 800;
}
.parts-cart-drawer .cart-section-head.a {
    color: var(--pc-green);
}
.parts-cart-drawer .cart-section-head.b {
    color: var(--pc-class-b);
}
.parts-cart-drawer .drawer-item {
    display: grid;
    grid-template-columns: 66px 1fr auto;
    gap: 12px;
    padding: 14px;
    border-bottom: 1px solid #eef2f4;
    align-items: start;
}
.parts-cart-drawer .drawer-item:last-child {
    border-bottom: 0;
}
.parts-cart-drawer .drawer-thumb {
    width: 66px;
    height: 54px;
    border-radius: 8px;
    background: #f1f4f5;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    flex-shrink: 0;
}
.parts-cart-drawer .drawer-thumb img {
    width: 100%;
    height: 100%;
    object-fit: contain;
}
.parts-cart-drawer .drawer-thumb.is-placeholder::before {
    content: "";
    width: 46px;
    height: 22px;
    border-radius: 8px;
    background: linear-gradient(145deg, #171d1f, #596266 45%, #111);
    display: block;
}
.parts-cart-drawer .drawer-item-info {
    min-width: 0;
}
.parts-cart-drawer .drawer-item h3 {
    margin: 0 0 6px;
    font-size: 13px;
    line-height: 1.35;
    font-weight: 700;
    color: var(--pc-ink);
}
.parts-cart-drawer .drawer-item .item-meta {
    margin: 0;
    color: #7a878d;
    font-size: 12px;
    line-height: 1.4;
}
.parts-cart-drawer .drawer-item .price {
    margin-top: 8px;
    display: inline-block;
    font-weight: 700;
    font-size: 14px;
    color: var(--pc-orange);
}
.parts-cart-drawer .drawer-item .qty-wrap {
    margin-top: 10px;
}
.parts-cart-drawer .remove-btn {
    border: 0;
    background: transparent;
    color: #94a0a5;
    cursor: pointer;
    font-size: 18px;
    padding: 0;
    line-height: 1;
    align-self: start;
}
.parts-cart-drawer .drawer-tabs {
    display: flex;
    gap: 0;
    border-bottom: 2px solid var(--pc-line);
    margin-bottom: 12px;
    flex-shrink: 0;
}
.parts-cart-drawer .drawer-tab {
    flex: 1;
    border: 0;
    background: transparent;
    height: 40px;
    font-weight: 700;
    font-size: 13px;
    cursor: pointer;
    color: #88959d;
    position: relative;
    transition: .15s;
}
.parts-cart-drawer .drawer-tab.active {
    color: var(--pc-brand);
}
.parts-cart-drawer .drawer-tab.active::after {
    content: "";
    position: absolute;
    left: 0;
    right: 0;
    bottom: -2px;
    height: 2px;
    background: var(--pc-brand);
}
.parts-cart-drawer .drawer-tab .tab-badge {
    display: inline-block;
    min-width: 20px;
    height: 20px;
    border-radius: 999px;
    font-size: 11px;
    line-height: 20px;
    text-align: center;
    margin-left: 4px;
    font-weight: 800;
}
.parts-cart-drawer .drawer-tab.a .tab-badge {
    background: #e8f5ee;
    color: var(--pc-green);
}
.parts-cart-drawer .drawer-tab.b .tab-badge {
    background: var(--pc-class-b-soft);
    color: var(--pc-class-b);
}
.parts-cart-drawer .summary-breakdown {
    background: linear-gradient(180deg, #f8fafb 0%, #f2f6f8 100%);
    border: 1px solid #e2eaee;
    border-radius: 10px;
    padding: 4px 14px;
    margin-bottom: 12px;
}
.parts-cart-drawer .summary-line {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 10px 0;
    color: #4d5a60;
    gap: 14px;
    font-size: 13px;
}
.parts-cart-drawer .summary-breakdown .summary-line + .summary-line {
    border-top: 1px solid #e6edf0;
}
.parts-cart-drawer .summary-label {
    color: #6a7780;
    font-weight: 600;
    letter-spacing: .2px;
}
.parts-cart-drawer .summary-value {
    color: var(--pc-ink);
    font-weight: 700;
    font-size: 14px;
}
.parts-cart-drawer .summary-value.is-free {
    color: var(--pc-green);
    text-transform: uppercase;
    font-size: 12px;
    letter-spacing: .4px;
}
.parts-cart-drawer .summary-line.total {
    font-size: 16px;
    font-weight: 800;
    color: var(--pc-ink);
    padding: 12px 14px;
    margin-bottom: 4px;
    border-radius: 10px;
    background: #fff;
    border: 1px solid #dfe7eb;
    box-shadow: 0 4px 14px rgba(15, 24, 28, .04);
}
.parts-cart-drawer .summary-line.total .summary-label {
    color: var(--pc-ink);
    font-weight: 800;
    font-size: 15px;
}
.parts-cart-drawer .summary-line.total .summary-value {
    font-size: 17px;
    color: var(--pc-brand);
}
.parts-cart-drawer .freight-alert {
    border-radius: 12px;
    padding: 14px 16px;
    line-height: 1.5;
    font-size: 13px;
    background: var(--pc-class-b-soft);
    border: 1px solid var(--pc-class-b-border);
    color: var(--pc-class-b-dark);
    margin: 12px 0;
}
.parts-cart-drawer .requires-quote {
    color: var(--pc-class-b) !important;
    font-weight: 700;
    display: inline-block;
    margin-top: 6px;
    font-size: 12px;
}
.parts-cart-drawer .qty-stepper {
    display: inline-grid;
    grid-template-columns: 34px 42px 34px;
    height: 34px;
    border: 1px solid #cbd5da;
    background: #fff;
    align-items: center;
    text-align: center;
    border-radius: 0;
}
.parts-cart-drawer .qty-stepper button {
    border: 0;
    background: transparent;
    cursor: pointer;
    color: #6c7a80;
    font-size: 18px;
    height: 100%;
}
.parts-cart-drawer .qty-stepper span {
    font-size: 13px;
    color: var(--pc-ink);
}
.parts-cart-drawer .pc-btn {
    border: 0;
    background: var(--pc-brand);
    color: #fff;
    height: 42px;
    padding: 0 24px;
    border-radius: 8px;
    font-weight: 700;
    font-size: 13px;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    transition: .18s ease;
    white-space: nowrap;
    width: 100%;
    font-family: inherit;
}
.parts-cart-drawer .pc-btn:hover {
    background: var(--pc-brand-dark);
}
.parts-cart-drawer .pc-btn.ghost {
    background: #fff;
    border: 1px solid #cfd8dc;
    color: #485960;
}
.parts-cart-drawer .pc-btn.ghost:hover {
    background: #f8fafb;
}
.parts-cart-drawer .pc-btn.checkout {
    background: var(--pc-green);
}
.parts-cart-drawer .pc-btn.checkout:hover {
    background: #0b8a4c;
}
.parts-cart-drawer .pc-btn.quote {
    background: var(--pc-class-b);
}
.parts-cart-drawer .pc-btn.quote:hover {
    background: var(--pc-class-b-dark);
}
.parts-cart-drawer .pc-btn:disabled,
.parts-cart-drawer .pc-btn.is-disabled {
    opacity: .55;
    cursor: not-allowed;
}

.parts-cart-drawer .drawer-field-label {
    display: block;
    font-size: 12px;
    font-weight: 700;
    color: #5a676d;
    margin: 0 0 8px;
    text-transform: uppercase;
    letter-spacing: .4px;
}
.parts-cart-drawer .drawer-notes {
    width: 100%;
    min-height: 72px;
    border: 1px solid #cfd8dc;
    border-radius: 8px;
    padding: 10px 12px;
    font-size: 13px;
    line-height: 1.5;
    resize: vertical;
    font-family: inherit;
    color: var(--pc-ink);
    box-sizing: border-box;
    margin-bottom: 12px;
}
.parts-cart-drawer .drawer-notes:focus {
    outline: none;
    border-color: var(--pc-brand);
}
.parts-cart-drawer .drawer-address-card {
    border: 1px solid #d5dee3;
    border-radius: 10px;
    padding: 12px 14px;
    background: #fff;
    margin-bottom: 12px;
    line-height: 1.55;
    font-size: 13px;
    color: #3f4d53;
}
.parts-cart-drawer .drawer-address-card strong {
    display: block;
    color: var(--pc-ink);
    font-size: 14px;
    margin-bottom: 4px;
}
.parts-cart-drawer .drawer-address-empty {
    border: 1px dashed #cfd8dc;
    border-radius: 10px;
    padding: 14px;
    text-align: center;
    font-size: 13px;
    color: #718087;
    margin-bottom: 12px;
    line-height: 1.5;
}
.parts-cart-drawer .drawer-address-empty a {
    color: var(--pc-brand);
    font-weight: 700;
    text-decoration: none;
}
.parts-cart-drawer .drawer-address-empty a:hover {
    text-decoration: underline;
}
.parts-cart-drawer .drawer-address-edit {
    display: inline-block;
    margin-top: 8px;
    font-size: 12px;
    font-weight: 700;
    color: var(--pc-brand);
    text-decoration: none;
}
.parts-cart-drawer .drawer-address-edit:hover {
    text-decoration: underline;
}

.parts-cart-drawer .drawer-buy-now-hint {
    margin-bottom: 12px;
    padding: 10px 12px;
    border-radius: 8px;
    background: #eef6fa;
    border: 1px solid #c5dae4;
    color: #2e6174;
    font-size: 12px;
    line-height: 1.5;
    font-weight: 600;
}

.parts-cart-drawer .drawer-step-back {
    margin-bottom: 14px;
}
.parts-cart-drawer .drawer-step-back button {
    border: 0;
    background: transparent;
    color: var(--pc-brand);
    font-size: 13px;
    font-weight: 700;
    cursor: pointer;
    padding: 0;
    font-family: inherit;
}
.parts-cart-drawer .drawer-step-back button:hover {
    text-decoration: underline;
}
.parts-cart-drawer .drawer-step-title {
    font-size: 16px;
    font-weight: 800;
    color: var(--pc-ink);
    margin: 0 0 16px;
}
.parts-cart-drawer .drawer-address-form {
    display: flex;
    flex-wrap: wrap;
    gap: 12px 14px;
}
.parts-cart-drawer .drawer-form-field {
    width: 100%;
    box-sizing: border-box;
}
.parts-cart-drawer .drawer-form-field.half {
    width: calc(50% - 7px);
}
.parts-cart-drawer .drawer-form-label {
    display: block;
    font-size: 12px;
    font-weight: 600;
    color: #4d5a60;
    margin: 0 0 6px;
}
.parts-cart-drawer .drawer-input {
    width: 100%;
    height: 38px;
    border: 1px solid #cfd8dc;
    border-radius: 6px;
    padding: 0 12px;
    font-size: 13px;
    color: var(--pc-ink);
    background: #fff;
    box-sizing: border-box;
    font-family: inherit;
    transition: border-color .15s ease;
}
.parts-cart-drawer .drawer-input:focus {
    outline: none;
    border-color: var(--pc-brand);
    box-shadow: 0 0 0 2px rgba(64, 119, 140, .12);
}
.parts-cart-drawer .freight-alert.a-alert {
    background: #e8f5ee;
    border-color: #b9dfc9;
    color: #1b6b42;
}
@media (max-width: 620px) {
    .parts-cart-drawer .drawer-form-field.half {
        width: 100%;
    }
}

@media (max-width: 980px) {
    .parts-cart-drawer {
        width: 100vw;
        max-width: 100vw;
    }
}
