/**
 * Shopify-Style One Page Checkout - Stylesheet
 *
 * Modern, clean Shopify-inspired checkout design.
 *
 * @author      ShopifyCheckout Module
 * @copyright   2026
 * @license     MIT
 */

/* ============================================
   CSS Custom Properties (Theme Colors)
   ============================================ */
.shopify-checkout {
    --sc-color-primary: #008060;
    --sc-color-primary-hover: #006e52;
    --sc-color-secondary: #f6f6f7;
    --sc-color-secondary-hover: #eaeaeb;
    --sc-color-summary-bg: #fafbfb;
    --sc-color-page-bg: #ffffff;
    --sc-color-text-primary: #202223;
    --sc-color-text-secondary: #6d7175;
    --sc-color-border: #c9cccf;
    --sc-color-error: #d82c0d;
    --sc-color-success: #008060;

    max-width: 1400px;
    margin: 0 auto;
    background: var(--sc-color-page-bg);
    color: var(--sc-color-text-primary);
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Helvetica, Arial, sans-serif;
    -webkit-font-smoothing: antialiased;
    direction: ltr;
    text-align: left;
    unicode-bidi: embed;
    min-height: 100vh;
}

/* ============================================
   Topbar (replaces navbar)
   ============================================ */
.shopify-checkout__topbar {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    height: 64px;
    background: #fff;
    border-bottom: 1px solid #e2e5e9;
    z-index: 100;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.04);
}

.shopify-checkout__topbar-inner {
    max-width: 1400px;
    margin: 0 auto;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 40px;
    gap: 24px;
}

.shopify-checkout__topbar-link {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    color: var(--sc-color-text-primary);
    text-decoration: none;
    font-size: 14px;
    font-weight: 500;
    padding: 8px 12px;
    border-radius: 4px;
    transition: all 0.2s;
    white-space: nowrap;
}

.shopify-checkout__topbar-link:hover {
    color: var(--sc-color-primary);
    background: var(--sc-color-secondary);
}

.shopify-checkout__topbar-link .material-icons {
    font-size: 20px;
}

.shopify-checkout__topbar-logo {
    display: flex;
    align-items: center;
    flex-shrink: 0;
}

.shopify-checkout__topbar-logo img {
    height: 32px;
    width: auto;
}

.shopify-checkout__topbar-logo-text {
    font-size: 20px;
    font-weight: 700;
    color: var(--sc-color-text-primary);
    text-decoration: none;
}

.shopify-checkout__topbar-link--cart {
    position: relative;
}

.shopify-checkout__cart-count {
    position: absolute;
    top: -4px;
    right: -4px;
    min-width: 18px;
    height: 18px;
    background: var(--sc-color-primary);
    color: #fff;
    font-size: 11px;
    font-weight: 600;
    border-radius: 9px;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0 4px;
}

/* Adjust main layout padding to account for fixed topbar */
.shopify-checkout__layout {
    padding-top: 64px;
}

@media (max-width: 1024px) {
    .shopify-checkout__topbar-inner {
        padding: 0 20px;
    }

    .shopify-checkout__topbar-link--back span {
        display: none;
    }

    .shopify-checkout__layout {
        padding-top: 64px;
    }
}

@media (max-width: 768px) {
    .shopify-checkout__topbar-logo img {
        height: 24px;
    }

    .shopify-checkout__topbar-logo-text {
        font-size: 16px;
    }
}

/* Force LTR/left alignment inside the checkout even where the theme or
   language (e.g. Portuguese RTL quirks) reverses shipping/payment text. */
.shopify-checkout__section,
.shopify-checkout__main,
.shopify-checkout__sidebar,
.shopify-checkout__summary,
.shopify-checkout__address-label,
.shopify-checkout__carrier-label,
.shopify-checkout__carrier-item,
.shopify-checkout__carrier-info,
.shopify-checkout__payment-label,
.shopify-checkout__payment-item,
.shopify-checkout__payment-details,
.shopify-checkout__payment-details p,
.shopify-checkout__payment-details dl,
.shopify-checkout__payment-details dt,
.shopify-checkout__payment-details dd,
.shopify-checkout__payment-details section,
.shopify-checkout__payment-details img,
.shopify-checkout__total-row,
.shopify-checkout__total,
.shopify-checkout__terms label {
    direction: ltr !important;
    text-align: left !important;
    unicode-bidi: embed !important;
}

.shopify-checkout__summary,
.shopify-checkout__submit,
.shopify-checkout__pay-button {
    margin-left: 0 !important;
    text-align: left;
}

.shopify-checkout__layout {
    display: flex;
    gap: 40px;
    min-height: 100vh;
    padding: 0 40px;
}

.shopify-checkout__main {
    flex: 1;
    max-width: 680px;
    padding: 48px 0 80px;
    margin: 0 auto;
}

.shopify-checkout__sidebar {
    flex: 0 0 380px;
    padding: 48px 0 80px;
}

@media (max-width: 1024px) {
    .shopify-checkout__layout {
        display: block;
        padding: 0 20px;
    }

    .shopify-checkout__main {
        max-width: 100%;
        padding: 24px 0 40px;
    }

    .shopify-checkout__sidebar {
        padding: 24px 0 80px;
    }
}

/* ============================================
   Header
   ============================================ */
.shopify-checkout__header {
    margin-bottom: 32px;
}

.shopify-checkout__title {
    font-size: 28px;
    font-weight: 600;
    color: var(--sc-color-text-primary);
    margin: 0 0 8px;
    line-height: 1.2;
}

.shopify-checkout__header-subtitle {
    font-size: 14px;
    color: var(--sc-color-text-secondary);
    margin: 0;
}

/* ============================================
   Sections
   ============================================ */
.shopify-checkout__section {
    padding: 24px 0;
    border-top: 1px solid var(--sc-color-border);
}

.shopify-checkout__section:first-of-type {
    border-top: none;
}

.shopify-checkout__section-header {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    margin-bottom: 16px;
    padding: 0 4px;
}

.shopify-checkout__section-title {
    font-size: 18px;
    font-weight: 600;
    color: var(--sc-color-text-primary);
    margin: 0;
}

.shopify-checkout__section-subtitle {
    font-size: 13px;
    color: var(--sc-color-text-secondary);
    margin: 0;
}

.shopify-checkout__section-content {
    padding: 0 4px;
}

.shopify-checkout__section-content--terms {
    border-top: 1px solid var(--sc-color-border);
    padding-top: 16px;
}

/* ============================================
   Form Fields - Form Floating Style
   ============================================ */
.shopify-checkout__field {
    position: relative;
    margin-bottom: 20px;
}

.shopify-checkout__field-row {
    display: flex;
    gap: 16px;
}

.shopify-checkout__field--half {
    flex: 1;
}

.shopify-checkout__field--checkbox {
    display: flex;
    align-items: flex-start;
    margin-bottom: 12px;
}

/* Form Floating Styles */
.shopify-checkout__form-floating {
    position: relative;
}

.shopify-checkout__form-floating > .shopify-checkout__input,
.shopify-checkout__form-floating > .shopify-checkout__select,
.shopify-checkout__form-floating > .form-control {
    height: 56px;
    padding: 16px 14px 8px;
    font-size: 16px;
    border: 1px solid var(--sc-color-border);
    border-radius: 4px;
    background: var(--sc-color-page-bg);
    color: var(--sc-color-text-primary);
    transition: border-color 0.2s, box-shadow 0.2s;
    box-sizing: border-box;
}

.shopify-checkout__form-floating > .shopify-checkout__input:focus,
.shopify-checkout__form-floating > .shopify-checkout__select:focus,
.shopify-checkout__form-floating > .form-control:focus {
    outline: none;
    border-color: var(--sc-color-primary);
    box-shadow: 0 0 0 3px rgba(0, 128, 96, 0.15);
}

.shopify-checkout__form-floating > .shopify-checkout__input::placeholder,
.shopify-checkout__form-floating > .form-control::placeholder {
    color: transparent;
}

.shopify-checkout__form-floating > .shopify-checkout__label,
.shopify-checkout__form-floating > label {
    position: absolute;
    top: 0;
    left: 14px;
    height: 100%;
    padding: 16px 0 8px;
    font-size: 16px;
    color: var(--sc-color-text-secondary);
    pointer-events: none;
    transform-origin: 0 0;
    transition: opacity 0.1s ease-in-out, transform 0.1s ease-in-out;
    display: flex;
    align-items: center;
}

.shopify-checkout__form-floating > .shopify-checkout__input:focus ~ .shopify-checkout__label,
.shopify-checkout__form-floating > .shopify-checkout__input:not(:placeholder-shown) ~ .shopify-checkout__label,
.shopify-checkout__form-floating > .shopify-checkout__select:focus ~ .shopify-checkout__label,
.shopify-checkout__form-floating > .shopify-checkout__select:not([value=""]) ~ .shopify-checkout__label,
.shopify-checkout__form-floating > .form-control:focus ~ label,
.shopify-checkout__form-floating > .form-control:not(:placeholder-shown) ~ label {
    opacity: 0.65;
    transform: scale(0.85) translateY(-0.5rem) translateX(0.15rem);
}

.shopify-checkout__form-floating > .shopify-checkout__input:-webkit-autofill ~ .shopify-checkout__label,
.shopify-checkout__form-floating > .form-control:-webkit-autofill ~ label {
    opacity: 0.65;
    transform: scale(0.85) translateY(-0.5rem) translateX(0.15rem);
}

.shopify-checkout__input--error {
    border-color: var(--sc-color-error) !important;
}

/* Select styling for form-floating */
.shopify-checkout__form-floating > .shopify-checkout__select {
    appearance: none;
    -webkit-appearance: none;
    background-image: url("data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12'%3E%3Cpath fill='%236d7175' d='M6 8L1.5 3h9z'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 14px center;
    cursor: pointer;
    padding-right: 40px;
}

/* Hide the placeholder-based label for selects (use JS to add .has-value class) */
.shopify-checkout__form-floating > .shopify-checkout__select.has-value ~ .shopify-checkout__label {
    opacity: 0.65;
    transform: scale(0.85) translateY(-0.5rem) translateX(0.15rem);
}

/* Special handling for state select (hidden by default) */
.shopify-checkout__label[for='opc-address-state'] {
    display: none;
}

/* ============================================
   Contact Section - Account Type Selection
   ============================================ */
.shopify-checkout__account-type {
    margin-bottom: 20px;
}

.shopify-checkout__account-type-options {
    display: flex;
    gap: 12px;
}

.shopify-checkout__account-type-option {
    flex: 1;
    display: flex;
    align-items: flex-start;
    gap: 12px;
    padding: 16px;
    border: 1px solid var(--sc-color-border);
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.2s;
}

.shopify-checkout__account-type-option:hover {
    border-color: var(--sc-color-primary);
    background: var(--sc-color-secondary);
}

.shopify-checkout__account-type-option input.shopify-checkout__radio:checked + .shopify-checkout__radio-custom {
    border-color: var(--sc-color-primary);
    background: var(--sc-color-primary);
    box-shadow: inset 0 0 0 4px #fff;
}

.shopify-checkout__account-type-option input.shopify-checkout__radio:checked ~ .shopify-checkout__account-type-info .shopify-checkout__account-type-title {
    color: var(--sc-color-primary);
}

.shopify-checkout__account-type-option input.shopify-checkout__radio {
    position: absolute;
    opacity: 0;
    width: 20px;
    height: 20px;
    margin: 0;
}

.shopify-checkout__account-type-option .shopify-checkout__radio-custom {
    position: relative;
    top: 2px;
    flex-shrink: 0;
    width: 20px;
    height: 20px;
    border: 1px solid var(--sc-color-border);
    border-radius: 50%;
    background: var(--sc-color-page-bg);
    transition: all 0.2s;
}

.shopify-checkout__account-type-info {
    flex: 1;
    min-width: 0;
}

.shopify-checkout__account-type-title {
    font-size: 15px;
    font-weight: 600;
    color: var(--sc-color-text-primary);
    margin-bottom: 2px;
}

.shopify-checkout__account-type-hint {
    font-size: 13px;
    color: var(--sc-color-text-secondary);
    line-height: 1.4;
}

.shopify-checkout__account-fields {
    margin-top: 16px;
    padding: 20px;
    background: var(--sc-color-secondary);
    border-radius: 8px;
    animation: slideDown 0.3s ease-out;
}

@keyframes slideDown {
    from {
        opacity: 0;
        transform: translateY(-10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Form Floating adjustments for account fields */
.shopify-checkout__account-fields .shopify-checkout__form-floating {
    margin-bottom: 16px;
}

.shopify-checkout__account-fields .shopify-checkout__form-floating:last-child {
    margin-bottom: 0;
}

/* Checkboxes and Radios */
.shopify-checkout__checkbox-label,
.shopify-checkout__address-label,
.shopify-checkout__carrier-label,
.shopify-checkout__payment-label {
    display: flex;
    align-items: flex-start;
    cursor: pointer;
    position: relative;
    padding-left: 32px;
}

.shopify-checkout__radio,
.shopify-checkout__checkbox {
    position: absolute;
    opacity: 0;
    width: 20px;
    height: 20px;
    margin: 0;
}

.shopify-checkout__checkbox-custom,
.shopify-checkout__radio-custom {
    position: absolute;
    top: 0;
    left: 0;
    width: 18px;
    height: 18px;
    border: 1px solid var(--sc-color-border);
    background: var(--sc-color-page-bg);
    transition: all 0.2s;
}

.shopify-checkout__checkbox-custom {
    border-radius: 2px;
}

.shopify-checkout__radio-custom {
    border-radius: 50%;
}

.shopify-checkout__radio:checked + .shopify-checkout__radio-custom {
    border-color: var(--sc-color-primary);
    background: var(--sc-color-primary);
    box-shadow: inset 0 0 0 4px #fff;
}

.shopify-checkout__checkbox:checked + .shopify-checkout__checkbox-custom {
    border-color: var(--sc-color-primary);
    background: var(--sc-color-primary);
}

.shopify-checkout__checkbox:checked + .shopify-checkout__checkbox-custom::after {
    content: '';
    position: absolute;
    top: 3px;
    left: 6px;
    width: 5px;
    height: 10px;
    border: solid #fff;
    border-width: 0 2px 2px 0;
    transform: rotate(45deg);
}

/* ============================================
   Contact Section
   ============================================ */
.shopify-checkout__contact-email {
    font-size: 14px;
    color: var(--sc-color-text-secondary);
}

.shopify-checkout__account-fields {
    margin-top: 16px;
    padding: 16px;
    background: var(--sc-color-secondary);
    border-radius: 4px;
}

/* ============================================
   Links & Buttons
   ============================================ */
.shopify-checkout__link {
    color: var(--sc-color-primary);
    text-decoration: none;
    font-size: 14px;
    transition: color 0.2s;
}

/* Reset browser/theme styling for link-style buttons
   (e.g. "Add new address") so they render as plain links. */
button.shopify-checkout__link {
    background: none;
    border: none;
    padding: 0;
    margin: 0;
    font: inherit;
    color: var(--sc-color-primary);
    cursor: pointer;
    text-align: left;
    line-height: inherit;
}

.shopify-checkout__link:hover {
    color: var(--sc-color-primary-hover);
    text-decoration: underline;
}

.shopify-checkout__link--add {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    margin-top: 12px;
}

.shopify-checkout__link--add .material-icons {
    font-size: 18px;
}

.shopify-checkout__link--return {
    display: inline-flex;
    align-items: center;
    gap: 4px;
}

.shopify-checkout__link--return .material-icons {
    font-size: 18px;
}

.shopify-checkout__button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 10px 20px;
    font-size: 15px;
    font-weight: 600;
    border-radius: 4px;
    border: none;
    cursor: pointer;
    transition: all 0.2s;
}

.shopify-checkout__button--primary {
    background: var(--sc-color-primary);
    color: #fff;
}

.shopify-checkout__button--primary:hover {
    background: var(--sc-color-primary-hover);
}

.shopify-checkout__button--secondary {
    background: var(--sc-color-secondary);
    color: var(--sc-color-text-primary);
    border: 1px solid var(--sc-color-border);
}

.shopify-checkout__button--secondary:hover {
    background: var(--sc-color-secondary-hover);
}

.shopify-checkout__button--discount {
    background: var(--sc-color-secondary);
    color: var(--sc-color-text-primary);
    border: 1px solid var(--sc-color-border);
    padding: 10px 16px;
    border-left: none;
}

.shopify-checkout__button--discount:hover {
    background: var(--sc-color-secondary-hover);
}

/* ============================================
   Address Section
   ============================================ */
.shopify-checkout__address-list {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.shopify-checkout__address-item {
    border: 1px solid var(--sc-color-border);
    border-radius: 4px;
    padding: 14px 16px;
    transition: all 0.2s;
}

.shopify-checkout__address-item--selected {
    border-color: var(--sc-color-primary);
    box-shadow: 0 0 0 1px var(--sc-color-primary);
}

.shopify-checkout__address-item .shopify-checkout__address-label {
    display: block;
    padding-left: 32px;
}

.shopify-checkout__address-info {
    font-size: 14px;
}

.shopify-checkout__address-name {
    font-weight: 600;
    font-size: 15px;
    margin-bottom: 4px;
    color: var(--sc-color-text-primary);
}

.shopify-checkout__address-details {
    color: var(--sc-color-text-secondary);
    line-height: 1.5;
}

.shopify-checkout__address-edit {
    display: inline-block;
    margin-top: 8px;
    font-size: 13px;
}

.shopify-checkout__no-addresses {
    color: var(--sc-color-text-secondary);
    font-size: 14px;
}

/* ============================================
   Shipping/Carriers
   ============================================ */
.shopify-checkout__carrier-list {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.shopify-checkout__carrier-item {
    border: 1px solid var(--sc-color-border);
    border-radius: 4px;
    padding: 14px 16px;
    transition: all 0.2s;
}

.shopify-checkout__carrier-item--selected {
    border-color: var(--sc-color-primary);
    box-shadow: 0 0 0 1px var(--sc-color-primary);
}

.shopify-checkout__carrier-label {
    display: flex;
    align-items: center;
    gap: 12px;
    padding-left: 32px;
}

.shopify-checkout__carrier-image {
    flex: 0 0 48px;
    height: 48px;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
}

.shopify-checkout__carrier-image img {
    max-width: 100%;
    max-height: 100%;
    object-fit: contain;
    width: auto;
    height: auto;
}

.shopify-checkout__carrier-image--placeholder {
    background: var(--sc-color-secondary);
    border: 1px solid var(--sc-color-border);
    border-radius: 4px;
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
}

.shopify-checkout__carrier-image--placeholder .material-icons {
    font-size: 24px;
    color: var(--sc-color-text-secondary);
}

.shopify-checkout__carrier-info {
    flex: 1;
}

.shopify-checkout__carrier-name {
    font-weight: 600;
    font-size: 14px;
    color: var(--sc-color-text-primary);
}

.shopify-checkout__carrier-delay {
    font-size: 13px;
    color: var(--sc-color-text-secondary);
    margin-top: 2px;
}

.shopify-checkout__carrier-price {
    font-weight: 600;
    font-size: 15px;
    color: var(--sc-color-text-primary);
}

.shopify-checkout__carrier-empty,
.shopify-checkout__payment-empty {
    padding: 16px;
    border: 1px dashed var(--sc-color-border);
    border-radius: 4px;
}

.shopify-checkout__carrier-empty p,
.shopify-checkout__payment-empty p {
    margin: 0;
    font-size: 14px;
    color: var(--sc-color-text-secondary);
}

/* ============================================
   Payment Section
   ============================================ */
.shopify-checkout__payment-list {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.shopify-checkout__payment-item {
    border: 1px solid var(--sc-color-border);
    border-radius: 4px;
    padding: 14px 16px;
    transition: all 0.2s;
}

.shopify-checkout__payment-item--selected {
    border-color: var(--sc-color-primary);
    box-shadow: 0 0 0 1px var(--sc-color-primary);
}

.shopify-checkout__payment-label {
    display: flex;
    align-items: center;
    gap: 12px;
    padding-left: 32px;
}

.shopify-checkout__payment-image {
    flex: 0 0 48px;
    height: 48px;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
}

.shopify-checkout__payment-image img {
    max-width: 100%;
    max-height: 100%;
    object-fit: contain;
    width: auto;
    height: auto;
}

.shopify-checkout__payment-image--placeholder {
    background: var(--sc-color-secondary);
    border: 1px solid var(--sc-color-border);
    border-radius: 4px;
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
}

.shopify-checkout__payment-image--placeholder .material-icons {
    font-size: 24px;
    color: var(--sc-color-text-secondary);
}

.shopify-checkout__payment-info {
    flex: 1;
}

.shopify-checkout__payment-name {
    font-weight: 600;
    font-size: 14px;
    color: var(--sc-color-text-primary);
}

.shopify-checkout__payment-details {
    font-size: 13px;
    color: var(--sc-color-text-secondary);
    margin-top: 2px;
}

.shopify-checkout__payment-form {
    margin-top: 16px;
    padding: 16px;
    background: var(--sc-color-secondary);
    border-radius: 4px;
}

/* ============================================
   Order Summary
   ============================================ */
.shopify-checkout__summary {
    position: sticky;
    top: 24px;
    background: var(--sc-color-summary-bg);
    border-radius: 8px;
    padding: 24px;
}

@media (max-width: 1024px) {
    .shopify-checkout__summary {
        position: static;
        margin-top: 24px;
    }
}

.shopify-checkout__summary-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 20px;
}

.shopify-checkout__summary-title {
    font-size: 16px;
    font-weight: 600;
    color: var(--sc-color-text-primary);
    margin: 0;
}

.shopify-checkout__summary-count {
    font-size: 13px;
    color: var(--sc-color-text-secondary);
}

.shopify-checkout__products {
    border-bottom: 1px solid var(--sc-color-border);
    margin-bottom: 16px;
    padding-bottom: 8px;
    max-height: 320px;
    overflow-y: auto;
}

.shopify-checkout__product {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    padding: 12px 0;
}

.shopify-checkout__product-image {
    position: relative;
    flex: 0 0 48px;
    width: 48px;
    height: 48px;
    border-radius: 4px;
    overflow: visible;
    background: var(--sc-color-page-bg);
}

.shopify-checkout__product-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    border: 1px solid var(--sc-color-border);
    border-radius: 4px;
}

.shopify-checkout__product-quantity {
    position: absolute;
    top: -6px;
    right: -6px;
    background: var(--sc-color-text-primary);
    color: #fff;
    font-size: 11px;
    font-weight: 600;
    min-width: 18px;
    height: 18px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0 4px;
    box-sizing: border-box;
}

.shopify-checkout__product-info {
    flex: 1;
    min-width: 0;
}

.shopify-checkout__product-name {
    font-size: 14px;
    font-weight: 500;
    color: var(--sc-color-text-primary);
    line-height: 1.4;
    margin-bottom: 2px;
}

.shopify-checkout__product-attributes {
    font-size: 12px;
    color: var(--sc-color-text-secondary);
}

.shopify-checkout__product-price {
    font-size: 14px;
    font-weight: 600;
    color: var(--sc-color-text-primary);
    white-space: nowrap;
}

/* Discount */
.shopify-checkout__discount {
    margin-bottom: 20px;
}

.shopify-checkout__discount-input-wrapper {
    display: flex;
    align-items: stretch;
}

.shopify-checkout__input--discount {
    border-right: none;
    border-radius: 4px 0 0 4px;
}

/* Totals */
.shopify-checkout__totals {
    margin-bottom: 8px;
}

.shopify-checkout__total-row {
    display: flex;
    justify-content: space-between;
    align-items: baseline;
    padding: 6px 0;
}

.shopify-checkout__total-label {
    font-size: 14px;
    color: var(--sc-color-text-secondary);
}

.shopify-checkout__total-value {
    font-size: 14px;
    color: var(--sc-color-text-primary);
    font-weight: 500;
}

.shopify-checkout__total-value--free {
    color: var(--sc-color-success);
    font-weight: 600;
}

.shopify-checkout__total-value--discount {
    color: var(--sc-color-success);
    font-weight: 600;
}

.shopify-checkout__total-row--discount {
    color: var(--sc-color-success);
}

.shopify-checkout__total--final {
    display: flex;
    justify-content: space-between;
    align-items: baseline;
    padding: 16px 0;
    border-top: 1px solid var(--sc-color-border);
    margin-top: 8px;
}

.shopify-checkout__total--final .shopify-checkout__total-label {
    font-size: 16px;
    font-weight: 600;
    color: var(--sc-color-text-primary);
}

.shopify-checkout__total-value--final {
    font-size: 22px;
    font-weight: 700;
    color: var(--sc-color-text-primary);
}

.shopify-checkout__total-currency {
    font-size: 14px;
    font-weight: 600;
    margin-right: 2px;
}

/* Pay Button */
.shopify-checkout__pay-button {
    width: 100%;
    margin-top: 20px;
    padding: 16px;
    font-size: 18px;
    font-weight: 600;
    color: #fff;
    background: var(--sc-color-primary);
    border: none;
    border-radius: 6px;
    cursor: pointer;
    transition: all 0.2s;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    box-shadow: rgba(0, 0, 0, 0.1) 0 1px 3px;
}

.shopify-checkout__pay-button:hover:not(:disabled) {
    background: var(--sc-color-primary-hover);
    box-shadow: rgba(0, 0, 0, 0.2) 0 2px 6px;
}

.shopify-checkout__pay-button:disabled {
    background: var(--sc-color-border);
    color: var(--sc-color-text-secondary);
    cursor: not-allowed;
}

.shopify-checkout__pay-button-amount {
    opacity: 0.85;
    font-weight: 600;
}

.shopify-checkout__submit {
    display: block;
    margin-top: 24px;
}

/* Error Banner */
.shopify-checkout__error-banner {
    margin-top: 16px;
    padding: 12px 16px;
    border: 1px solid var(--sc-color-error);
    background: #fff0e1;
    border-radius: 6px;
    color: var(--sc-color-error);
    font-size: 14px;
}

.shopify-checkout__error-banner-inner {
    display: flex;
    align-items: flex-start;
    gap: 8px;
}

.shopify-checkout__error-banner-inner .material-icons {
    font-size: 18px;
    flex: 0 0 auto;
    margin-top: 1px;
}

/* Trust badges */
.shopify-checkout__trust {
    margin-top: 16px;
    padding: 12px 0;
    border-top: 1px solid var(--sc-color-border);
}

.shopify-checkout__trust-badge {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    font-size: 13px;
    color: var(--sc-color-text-secondary);
}

.shopify-checkout__trust-badge .material-icons {
    font-size: 16px;
    color: var(--sc-color-success);
}

.shopify-checkout__return {
    text-align: center;
    margin-top: 16px;
}

/* ============================================
   Modals
   ============================================ */
.shopify-checkout__modal {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.5);
    z-index: 1000;
    display: flex;
    align-items: flex-start;
    justify-content: center;
    padding: 80px 16px;
    overflow-y: auto;
}

.shopify-checkout__modal .modal-dialog {
    background: var(--sc-color-page-bg);
    border-radius: 8px;
    max-width: 560px;
    width: 100%;
    max-height: 80vh;
    overflow-y: auto;
    position: relative;
}

.shopify-checkout__modal .modal-content {
    background: var(--sc-color-page-bg);
    padding: 24px;
}

.shopify-checkout__modal .modal-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 16px;
}

.shopify-checkout__modal .modal-title {
    font-size: 18px;
    font-weight: 600;
    color: var(--sc-color-text-primary);
    margin: 0;
}

.shopify-checkout__modal .close {
    background: none;
    border: none;
    font-size: 24px;
    color: var(--sc-color-text-secondary);
    cursor: pointer;
    line-height: 1;
    padding: 4px;
}

.shopify-checkout__modal-actions {
    display: flex;
    gap: 12px;
    margin-top: 20px;
}

.shopify-checkout__modal-title {
    font-size: 18px;
    font-weight: 600;
    color: var(--sc-color-text-primary);
    margin: 0 0 20px;
}

/* ============================================
   Loader
   ============================================ */
.shopify-checkout__loader {
    position: fixed;
    inset: 0;
    background: rgba(255, 255, 255, 0.85);
    z-index: 999;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 16px;
}

.shopify-checkout__loader-spinner {
    width: 48px;
    height: 48px;
    border: 3px solid var(--sc-color-border);
    border-top-color: var(--sc-color-primary);
    border-radius: 50%;
    animation: shopify-checkout-spin 0.8s linear infinite;
}

.shopify-checkout__loader-text {
    font-size: 14px;
    color: var(--sc-color-text-secondary);
}

@keyframes shopify-checkout-spin {
    to {
        transform: rotate(360deg);
    }
}

/* ============================================
   Error Messages
   ============================================ */
.shopify-checkout__error {
    margin: 16px 0;
}

.shopify-checkout__error-message {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 12px 16px;
    background: #fff4f4;
    border: 1px solid var(--sc-color-error);
    border-radius: 4px;
    color: var(--sc-color-error);
    font-size: 14px;
}

.shopify-checkout__error-message .material-icons {
    font-size: 20px;
}

/* ============================================
   Responsive
   ============================================ */
@media (max-width: 768px) {
    .shopify-checkout__title {
        font-size: 24px;
    }

    .shopify-checkout__field-row {
        flex-direction: column;
        gap: 0;
    }

    .shopify-checkout__section-header {
        flex-direction: column;
        gap: 4px;
    }
}