.checkout-page-shell {
    padding-top: 148px;
    padding-bottom: 84px;
}

.checkout-page-container {
    display: grid;
    gap: 18px;
}

.checkout-head {
    padding: 28px 30px;
    display: grid;
    gap: 10px;
}

.checkout-head-kicker {
    margin: 0;
    font-size: 0.8rem;
    font-weight: 700;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    color: #8fc2ff;
}

.checkout-head h1 {
    margin: 0;
    color: #fff;
    font-size: clamp(1.8rem, 3vw, 2.45rem);
    line-height: 1.15;
}

.checkout-head p {
    margin: 0;
    color: var(--text-muted);
    max-width: 740px;
}

.checkout-layout {
    display: grid;
    gap: 16px;
    overflow: visible;
    position: relative;
    isolation: isolate;
}

.checkout-main {
    min-width: 0;
    display: grid;
    gap: 14px;
    position: relative;
    z-index: 1;
    overflow: visible;
    isolation: isolate;
}

.checkout-summary {
    min-width: 0;
}

.checkout-card {
    padding: 18px;
    display: grid;
    gap: 14px;
    position: relative;
    z-index: 1;
    overflow: visible;
}

.checkout-card:focus-within {
    z-index: 80;
}

.checkout-card.is-autocomplete-open {
    z-index: 1200;
}

.checkout-card h2 {
    margin: 0;
    font-size: 1.08rem;
    line-height: 1.35;
    color: #fff;
}

.checkout-card-note {
    margin: -4px 0 0;
    color: var(--text-muted);
    font-size: 0.93rem;
    line-height: 1.5;
}

.checkout-grid {
    display: grid;
    gap: 12px;
}

.checkout-grid-2 {
    grid-template-columns: repeat(2, minmax(0, 1fr));
}

.checkout-field {
    display: grid;
    gap: 6px;
}

.checkout-field-label {
    color: #dbeafe;
    font-weight: 600;
    font-size: 0.92rem;
}

.checkout-required-star {
    color: #60a5fa;
}

.checkout-input,
.checkout-select,
.checkout-textarea {
    width: 100%;
    min-width: 0;
    border: 1px solid rgba(148, 163, 184, 0.25);
    background: rgba(15, 23, 42, 0.58);
    border-radius: 14px;
    color: #fff;
    padding: 12px 14px;
    font-size: 0.96rem;
    outline: none;
    transition: border-color .2s ease, box-shadow .2s ease, background .2s ease;
}

.checkout-textarea {
    resize: vertical;
    min-height: 84px;
}

.checkout-input::placeholder,
.checkout-textarea::placeholder {
    color: rgba(203, 213, 225, 0.8);
}

.checkout-input:focus,
.checkout-select:focus,
.checkout-textarea:focus {
    border-color: rgba(96, 165, 250, 0.9);
    box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.2);
    background: rgba(15, 23, 42, 0.76);
}

.checkout-input.is-invalid,
.checkout-select.is-invalid,
.checkout-textarea.is-invalid {
    border-color: rgba(251, 113, 133, 0.92);
    box-shadow: 0 0 0 3px rgba(251, 113, 133, 0.16);
}

.checkout-error {
    color: #fda4af;
    font-size: 0.82rem;
    min-height: 1.1em;
}

.checkout-choice-grid {
    display: grid;
    gap: 10px;
}

.checkout-choice {
    border: 1px solid rgba(148, 163, 184, 0.24);
    border-radius: 16px;
    background: rgba(15, 23, 42, 0.44);
    padding: 12px 14px;
    transition: border-color .2s ease, background .2s ease, box-shadow .2s ease;
    position: relative;
}

.checkout-choice input {
    position: absolute;
    opacity: 0;
    pointer-events: none;
}

.checkout-choice-title {
    color: #fff;
    font-weight: 700;
    line-height: 1.25;
    flex: 1 1 auto;
}

.checkout-choice-head {
    display: flex;
    align-items: center;
    gap: 10px;
}

.checkout-choice-icon {
    width: 20px;
    height: 20px;
    flex: 0 0 20px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    color: #93c5fd;
}

.checkout-choice-icon svg {
    width: 100%;
    height: 100%;
    fill: currentColor;
}

.checkout-choice-logo {
    width: 20px;
    height: 20px;
    object-fit: contain;
    flex: 0 0 20px;
}

.checkout-choice-check {
    margin-left: auto;
    width: 20px;
    height: 20px;
    min-width: 20px;
    min-height: 20px;
    flex: 0 0 20px;
    aspect-ratio: 1 / 1;
    border-radius: 50%;
    border: 1px solid rgba(148, 163, 184, 0.42);
    background: rgba(2, 6, 23, 0.55);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    color: transparent;
    font-size: 12px;
    font-weight: 800;
    line-height: 1;
    transition: color .2s ease, border-color .2s ease, background .2s ease;
}

.checkout-choice.is-selected .checkout-choice-check {
    color: #22c55e;
    border-color: rgba(34, 197, 94, 0.6);
    background: rgba(15, 118, 110, 0.2);
}

.checkout-choice-copy {
    margin-top: 4px;
    color: var(--text-muted);
    font-size: 0.9rem;
    line-height: 1.45;
}

.checkout-choice.is-selected {
    border-color: rgba(96, 165, 250, 0.9);
    background: linear-gradient(160deg, rgba(29, 78, 216, 0.34), rgba(15, 23, 42, 0.68));
    box-shadow: 0 0 0 1px rgba(96, 165, 250, 0.22) inset;
}

.checkout-inline-check {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    color: #dbeafe;
    font-size: 0.92rem;
    line-height: 1.45;
}

.checkout-inline-check input {
    margin-top: 2px;
    width: 18px;
    height: 18px;
    accent-color: #3b82f6;
}

.checkout-muted-box {
    border: 1px dashed rgba(148, 163, 184, 0.32);
    border-radius: 14px;
    padding: 12px 14px;
    color: var(--text-muted);
    font-size: 0.9rem;
    line-height: 1.45;
    background: rgba(15, 23, 42, 0.35);
}

.checkout-step-note {
    margin-top: 8px;
    color: #dbeafe;
}

.checkout-step-actions {
    display: flex;
    justify-content: flex-start;
    margin-top: -2px;
}

.checkout-next-btn {
    min-width: 180px;
}

.checkout-field-hint {
    color: var(--text-muted);
    font-size: 0.86rem;
    margin-top: -2px;
}

.checkout-accent-box {
    border: 1px solid rgba(96, 165, 250, 0.5);
    border-radius: 16px;
    padding: 13px 14px;
    background: linear-gradient(160deg, rgba(30, 64, 175, 0.38), rgba(15, 23, 42, 0.68));
    color: #eaf2ff;
    font-size: 0.93rem;
    line-height: 1.45;
}

.checkout-info-box {
    border: 1px solid rgba(148, 163, 184, 0.3);
    border-left: 4px solid #60a5fa;
    border-radius: 14px;
    padding: 12px 14px;
    background: rgba(15, 23, 42, 0.5);
    color: #e2e8f0;
    line-height: 1.5;
}

.checkout-hide {
    display: none !important;
}

.checkout-actions {
    display: grid;
    gap: 10px;
}

.checkout-submit {
    width: 100%;
    min-height: 52px;
    justify-content: center;
}

.checkout-submit[disabled] {
    opacity: 0.72;
    cursor: not-allowed;
}

.checkout-status {
    min-height: 1.2em;
    font-size: 0.91rem;
    line-height: 1.45;
}

.checkout-status.is-success {
    color: #86efac;
}

.checkout-status.is-error {
    color: #fda4af;
}

.checkout-summary-card {
    padding: 18px;
    display: grid;
    gap: 12px;
}

.checkout-summary-card h2 {
    margin: 0;
    color: #fff;
    font-size: 1.1rem;
}

.checkout-summary-list {
    display: grid;
    gap: 10px;
    max-height: 470px;
    overflow: auto;
    padding-right: 2px;
}

.checkout-summary-list,
.checkout-autocomplete-list {
    scrollbar-width: thin;
    scrollbar-color: rgba(96, 165, 250, 0.9) rgba(15, 23, 42, 0.62);
}

.checkout-summary-list::-webkit-scrollbar,
.checkout-autocomplete-list::-webkit-scrollbar {
    width: 10px;
    height: 10px;
}

.checkout-summary-list::-webkit-scrollbar-track,
.checkout-autocomplete-list::-webkit-scrollbar-track {
    background: rgba(15, 23, 42, 0.62);
    border-radius: 999px;
}

.checkout-summary-list::-webkit-scrollbar-thumb,
.checkout-autocomplete-list::-webkit-scrollbar-thumb {
    background: linear-gradient(180deg, rgba(96, 165, 250, 0.96), rgba(59, 130, 246, 0.78));
    border-radius: 999px;
    border: 2px solid rgba(15, 23, 42, 0.62);
    box-shadow: 0 0 0 1px rgba(96, 165, 250, 0.12);
}

.checkout-summary-list::-webkit-scrollbar-thumb:hover,
.checkout-autocomplete-list::-webkit-scrollbar-thumb:hover {
    background: linear-gradient(180deg, rgba(147, 197, 253, 1), rgba(59, 130, 246, 0.92));
}

.checkout-item {
    border: 1px solid rgba(148, 163, 184, 0.2);
    border-radius: 14px;
    padding: 10px;
    background: rgba(15, 23, 42, 0.36);
    display: grid;
    grid-template-columns: 66px minmax(0, 1fr);
    gap: 10px;
}

.checkout-item-image {
    width: 66px;
    height: 66px;
    object-fit: contain;
    border-radius: 10px;
    background: rgba(255, 255, 255, 0.06);
    padding: 6px;
}

.checkout-item-copy {
    min-width: 0;
    display: grid;
    gap: 6px;
    grid-column: 2 / 3;
}

.checkout-item-title {
    margin: 0;
    color: #fff;
    font-size: 0.94rem;
    line-height: 1.3;
}

.checkout-item-meta {
    margin: 0;
    color: var(--text-muted);
    font-size: 0.84rem;
}

.checkout-item-options {
    margin: 0;
    padding: 0;
    list-style: none;
    display: grid;
    gap: 6px;
    grid-column: 1 / -1;
    width: 100%;
}

.checkout-item-option {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    padding: 7px 9px;
    border: 1px solid rgba(148, 163, 184, 0.2);
    border-radius: 10px;
    background: rgba(15, 23, 42, 0.52);
}

.checkout-item-option-name {
    color: #dbeafe;
    font-size: 0.84rem;
    line-height: 1.35;
}

.checkout-item-option-qty {
    color: #fff;
    font-size: 0.82rem;
    font-weight: 700;
    white-space: nowrap;
}

.checkout-item-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
    grid-column: 1 / -1;
    width: 100%;
}

.checkout-item-price {
    color: #fff;
    font-weight: 700;
    font-size: 0.92rem;
}

.checkout-qty {
    display: inline-flex;
    align-items: center;
    border: 1px solid rgba(148, 163, 184, 0.3);
    border-radius: 999px;
    overflow: hidden;
}

.checkout-qty button {
    width: 30px;
    height: 30px;
    border: 0;
    background: rgba(15, 23, 42, 0.72);
    color: #fff;
    cursor: pointer;
    transition: background .2s ease;
}

.checkout-qty button:hover {
    background: rgba(30, 41, 59, 0.95);
}

.checkout-qty input {
    width: 40px;
    border: 0;
    background: rgba(15, 23, 42, 0.55);
    color: #fff;
    text-align: center;
    font-weight: 700;
    height: 30px;
}

.checkout-remove-btn {
    border: 0;
    background: transparent;
    color: #fca5a5;
    font-size: 0.85rem;
    cursor: pointer;
    padding: 0;
}

.checkout-totals {
    border-top: 1px solid rgba(148, 163, 184, 0.24);
    padding-top: 10px;
    display: grid;
    gap: 8px;
}

.checkout-total-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    color: var(--text-muted);
}

.checkout-total-row strong {
    color: #fff;
    font-size: 1.03rem;
}

.checkout-total-row.is-grand {
    margin-top: 2px;
}

.checkout-total-row.is-grand strong {
    color: #fff;
    font-size: 1.28rem;
}

.checkout-empty {
    padding: 26px 20px;
    text-align: center;
    border: 1px dashed rgba(148, 163, 184, 0.34);
    border-radius: 16px;
    color: var(--text-muted);
}

.checkout-empty strong {
    color: #fff;
    display: block;
    margin-bottom: 8px;
}

.checkout-autocomplete {
    position: relative;
    z-index: 2;
}

.checkout-autocomplete.is-open {
    z-index: 1400;
}

.checkout-autocomplete-list {
    position: absolute;
    top: calc(100% + 6px);
    left: 0;
    right: 0;
    max-height: 250px;
    overflow: auto;
    z-index: 1410;
    border-radius: 14px;
    border: 1px solid rgba(148, 163, 184, 0.26);
    background: #050c19;
    box-shadow: 0 18px 40px rgba(2, 6, 23, 0.52);
}

.checkout-autocomplete-item {
    width: 100%;
    border: 0;
    text-align: left;
    color: #e2e8f0;
    background: #050c19;
    padding: 10px 12px;
    cursor: pointer;
}

.checkout-autocomplete-item:hover {
    background: rgba(30, 64, 175, 0.3);
}

.checkout-mobile-gap {
    padding-bottom: 88px;
}

@media (min-width: 993px) {
    .checkout-page-shell {
        padding-top: 168px;
    }

    .checkout-layout {
        grid-template-columns: minmax(0, 1fr) 360px;
        align-items: start;
        gap: 18px;
    }

    .checkout-summary {
        position: sticky;
        top: 140px;
    }

    .checkout-head,
    .checkout-card,
    .checkout-summary-card {
        border-radius: 26px;
    }

    .checkout-head {
        padding: 30px 34px;
    }
}

@media (max-width: 992px) {
    .checkout-page-shell {
        padding-top: 124px;
        padding-bottom: 110px;
    }
}

@media (max-width: 760px) {
    .checkout-grid-2 {
        grid-template-columns: 1fr;
    }

    .checkout-card,
    .checkout-summary-card {
        padding: 15px;
    }

    .checkout-head {
        padding: 18px 16px;
    }

    .checkout-choice {
        padding: 11px 12px;
    }

    .checkout-next-btn {
        width: 100%;
    }
}

/* === Checkout Cohesion Refresh === */
.checkout-page-shell {
    position: relative;
    overflow: hidden;
    padding-top: 156px;
    padding-bottom: 96px;
}

.checkout-page-shell::before {
    content: '';
    position: absolute;
    inset: 140px -180px auto auto;
    width: 380px;
    height: 380px;
    border-radius: 999px;
    background: radial-gradient(circle, rgba(59,130,246,0.22) 0%, rgba(59,130,246,0.1) 46%, rgba(59,130,246,0) 72%);
    pointer-events: none;
    z-index: 0;
}

.checkout-page-container {
    position: relative;
    z-index: 1;
    gap: 22px;
}

#checkout-app {
    display: grid;
    gap: 16px;
}

#checkout-app .checkout-head,
#checkout-app .checkout-card,
#checkout-app .checkout-summary-card,
#checkout-app .checkout-empty {
    border-radius: 24px;
    border: 1px solid rgba(148, 163, 184, 0.2);
    background:
        radial-gradient(circle at top right, rgba(59,130,246,0.09), transparent 38%),
        linear-gradient(145deg, rgba(11, 20, 38, 0.92) 0%, rgba(2, 8, 24, 0.96) 100%);
    box-shadow: 0 18px 38px rgba(2, 8, 23, 0.28);
}

#checkout-app .checkout-head {
    position: relative;
    overflow: hidden;
    padding: 30px 34px;
    gap: 12px;
}

#checkout-app .checkout-head::before {
    content: '';
    position: absolute;
    inset: auto -110px -160px auto;
    width: 280px;
    height: 280px;
    border-radius: 999px;
    background: radial-gradient(circle, rgba(59,130,246,0.22) 0%, rgba(59,130,246,0) 68%);
    pointer-events: none;
}

#checkout-app .checkout-head > * {
    position: relative;
    z-index: 1;
}

#checkout-app .checkout-head-kicker {
    color: #bfdbfe;
    letter-spacing: 0.14em;
}

#checkout-app .checkout-head h1 {
    font-size: clamp(2rem, 3vw, 2.9rem);
    line-height: 1.06;
}

#checkout-app .checkout-head p {
    max-width: 56rem;
    color: #d9e6f7;
    line-height: 1.72;
}

#checkout-app .checkout-layout {
    gap: 18px;
}

#checkout-app .checkout-main {
    gap: 16px;
}

#checkout-app .checkout-card,
#checkout-app .checkout-summary-card {
    padding: 22px;
}

#checkout-app .checkout-card h2,
#checkout-app .checkout-summary-card h2 {
    margin: 0;
    font-size: 1.28rem;
    line-height: 1.24;
}

#checkout-app .checkout-card-note {
    margin-top: -2px;
    font-size: 0.96rem;
}

#checkout-app .checkout-field-label {
    font-size: 0.95rem;
}

#checkout-app .checkout-input,
#checkout-app .checkout-select,
#checkout-app .checkout-textarea {
    min-height: 48px;
    border-radius: 14px;
    font-size: 0.97rem;
    background: rgba(15, 23, 42, 0.65);
}

#checkout-app .checkout-textarea {
    min-height: 96px;
}

#checkout-app .checkout-choice-grid {
    gap: 12px;
}

@media (min-width: 993px) {
    #checkout-app .checkout-choice-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

#checkout-app .checkout-choice {
    border-radius: 14px;
    padding: 13px 14px;
}

#checkout-app .checkout-choice-title {
    font-size: 0.98rem;
}

#checkout-app .checkout-choice-copy {
    margin-top: 6px;
    font-size: 0.9rem;
}

#checkout-app .checkout-choice.is-selected {
    border-color: rgba(96, 165, 250, 0.92);
    box-shadow: 0 0 0 1px rgba(96, 165, 250, 0.24) inset, 0 12px 24px rgba(15, 23, 42, 0.28);
}

#checkout-app .checkout-muted-box {
    border-style: solid;
    border-color: rgba(148, 163, 184, 0.26);
    border-radius: 14px;
    background: rgba(15, 23, 42, 0.52);
}

#checkout-app .checkout-info-box {
    border-radius: 14px;
    background: linear-gradient(145deg, rgba(30,64,175,0.24), rgba(15,23,42,0.66));
}

#checkout-app .checkout-submit {
    min-height: 54px;
    font-size: 15px;
}

#checkout-app .checkout-summary-list {
    gap: 12px;
}

#checkout-app .checkout-item {
    border-radius: 14px;
    padding: 11px;
}

#checkout-app .checkout-item-title {
    font-size: 0.96rem;
}

#checkout-app .checkout-total-row.is-grand strong {
    font-size: 1.34rem;
}

@media (min-width: 993px) {
    .checkout-page-shell {
        padding-top: 172px;
    }

    #checkout-app .checkout-layout {
        grid-template-columns: minmax(0, 1fr) 380px;
    }

    #checkout-app .checkout-summary {
        top: 146px;
    }
}

@media (max-width: 992px) {
    .checkout-page-shell {
        padding-top: 126px;
        padding-bottom: 114px;
    }

    #checkout-app .checkout-head {
        padding: 22px 20px;
    }

    #checkout-app .checkout-card,
    #checkout-app .checkout-summary-card {
        padding: 18px;
        border-radius: 18px;
    }

    #checkout-app .checkout-choice-grid {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 680px) {
    .checkout-page-shell {
        padding-top: 98px;
    }

    #checkout-app .checkout-head h1 {
        font-size: clamp(1.6rem, 8.1vw, 2rem);
    }

    #checkout-app .checkout-head p {
        font-size: 0.94rem;
        line-height: 1.65;
    }

    #checkout-app .checkout-card,
    #checkout-app .checkout-summary-card {
        padding: 14px;
    }
}
