:root {
    --radly-lovable-radius-sm: 10px;
    --radly-lovable-radius: 12px;
    --radly-lovable-radius-lg: 16px;
    --radly-lovable-shadow-sm: 0 8px 22px rgba(15, 23, 42, 0.08);
    --radly-lovable-shadow-md: 0 14px 32px rgba(15, 23, 42, 0.12);
    --radly-lovable-focus: rgba(18, 160, 88, 0.18);
}

body.radly-theme {
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    text-rendering: optimizeLegibility;
}

/* Keep current system visual identity, add only soft polish inspired by UI foundation */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.38rem;
    border-radius: var(--radly-lovable-radius);
    font-weight: 700;
    line-height: 1.15;
    text-align: center;
    transition: transform 0.15s ease, box-shadow 0.2s ease, filter 0.2s ease;
}

.btn:hover {
    transform: translateY(-1px);
}

.btn:focus,
.btn:focus-visible,
.form-control:focus,
.form-select:focus,
.form-check-input:focus,
.form-check-input:focus-visible,
input:focus,
select:focus,
textarea:focus {
    box-shadow: 0 0 0 0.22rem var(--radly-lovable-focus);
}

.form-control,
.form-select,
.form-check-input,
.input-group-text,
.dropdown-menu,
.modal-content,
.card,
.list-group-item,
.alert,
.toast {
    border-radius: var(--radly-lovable-radius);
}

.form-control,
.form-select,
.input-group-text {
    border-color: #dfe6f0;
}

.form-control,
.form-select {
    min-height: 42px;
}

.form-control::placeholder,
input::placeholder,
textarea::placeholder {
    color: #98a2b3;
}

.form-check-input {
    width: 1.08em;
    height: 1.08em;
    border-color: #cfd8e3;
}

.form-check-input:checked {
    border-color: var(--radly-primary, #12a058);
    background-color: var(--radly-primary, #12a058);
}

.card,
.modal-content,
.dropdown-menu,
.table-responsive,
.list-group-item {
    border-color: #e7edf5;
    box-shadow: var(--radly-lovable-shadow-sm);
}

.table {
    --bs-table-bg: transparent;
}

.table > :not(caption) > * > * {
    border-bottom-color: #e8eef5;
}

.table thead th {
    background: #f8fbff;
    color: #475467;
    font-weight: 700;
}

.badge {
    border-radius: 999px;
    font-weight: 700;
    letter-spacing: 0.1px;
}

.nav-tabs .nav-link,
.pagination .page-link,
.btn,
.dropdown-item,
.list-group-item {
    border-radius: var(--radly-lovable-radius-sm);
}

.top-navbar,
.guest-card,
.sidebar,
.legal-topbar,
.sf-header-shell,
.sf-checkout-summary-toggle,
.sf-summary-dropdown {
    backdrop-filter: saturate(1.05) blur(6px);
}

/* Storefront small polish */
.sf-product-card,
.sf-card,
.sf-summary-card,
.sf-checkout-card,
.sf-cart-card {
    border-radius: var(--radly-lovable-radius-lg);
    border: 1px solid #e7edf5;
    box-shadow: var(--radly-lovable-shadow-sm);
}

.sf-btn,
.sf-button,
.sf-checkout-submit,
.sf-add-to-cart,
button.sf-btn,
a.sf-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.38rem;
    border-radius: var(--radly-lovable-radius);
    font-weight: 700;
    line-height: 1.15;
    text-align: center;
}

.btn i,
.sf-btn i,
.sf-button i,
.sf-checkout-submit i,
.sf-add-to-cart i {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    line-height: 1;
}

@media (max-width: 991.98px) {
    .top-navbar {
        padding: 0.68rem 0.82rem;
    }

    .top-navbar .navbar-title {
        font-size: 0.94rem;
    }

    .guest-card,
    .card,
    .modal-content {
        border-radius: 14px;
    }

    .card,
    .card .card-body,
    .modal-body {
        padding: 0.9rem;
    }

    .container,
    .container-fluid,
    .uk-container,
    .uk-container-fluid {
        padding-inline: 12px;
    }

    .btn,
    .form-control,
    .form-select,
    .input-group-text {
        min-height: 44px;
        font-size: 0.95rem;
    }

    .table-responsive {
        border-radius: 12px;
        overflow: auto;
    }

    .sidebar-nav .nav-item a {
        min-height: 44px;
        padding-top: 0.78rem;
        padding-bottom: 0.78rem;
    }
}

@media (max-width: 576px) {
    .btn {
        min-height: 44px;
    }

    .guest-card-body,
    .card-body,
    .modal-body,
    .sf-section,
    .sf-panel {
        padding: 0.82rem;
    }

    .table > :not(caption) > * > * {
        padding: 0.58rem;
        font-size: 0.86rem;
    }

    .alert,
    .badge,
    .small {
        font-size: 0.82rem;
    }
}
