/* ==========================================================================
   RAFFIA THEME — CLEAN VERSION (Olive / Sage Palette)
   Primary: #5C6B5A
   ========================================================================== */

:root {
    /* ===== Brand Colors ===== */
    --brand-primary:          #5C6B5A;
    --brand-primary-hover:    #4E5C4D;
    --brand-primary-light:    #6B7B6A;
    --brand-black:            #1a1a1a;
    --brand-olive:            #656c5a;
    --brand-olive-dark:       #4a5348;

    /* ===== Backgrounds ===== */
    --bg-ivory:               #faf9f6;
    --bg-olive:               #e8e9e3;
    --bg-white:               #ffffff;
    --bg-soft:                rgba(92, 107, 90, 0.04);

    /* ===== Text ===== */
    --text-main:              #1a1a1a;
    --text-muted:             #707070;
    --text-light:             #9a9a9a;

    /* ===== Borders & Shadows ===== */
    --border-primary:         rgba(92, 107, 90, 0.25);
    --border-primary-strong:  rgba(92, 107, 90, 0.40);
    --border-light:           rgba(0, 0, 0, 0.06);
    --shadow-soft:            0 10px 30px rgba(0, 0, 0, 0.06);
    --shadow-medium:          0 15px 40px rgba(0, 0, 0, 0.08);

    /* ===== Sizing ===== */
    --btn-height:             45px;
    --radius-sm:              4px;
    --radius-md:              8px;
    --radius-lg:              12px;
    --transition:             all 0.3s ease;

    /* ===== Fonts ===== */
    --font-main:              'Montserrat', sans-serif;
    --font-display:           'Playfair Display', serif;
}

/* ==========================================================================
   0. BASE
   ========================================================================== */

html, body {
    width: 100% !important;
    max-width: 100% !important;
    overflow-x: hidden !important;
    position: relative;
}

body {
    background-color: var(--bg-ivory);
    color: var(--text-main);
    font-family: var(--font-main);
    margin: 0;
    padding: 0;
    -webkit-font-smoothing: antialiased;
    padding-right: 0 !important;
}

/* ==========================================================================
   TYPOGRAPHY
   ========================================================================== */

h1 {
    text-align: center !important;
    text-transform: uppercase !important;
    font-family: var(--font-main) !important;
    font-size: 22px !important;
    font-weight: 500 !important;
    letter-spacing: 2px !important;
    color: var(--text-main) !important;
    margin-top: 15px !important;
    margin-bottom: 25px !important;
    border-bottom: 1px solid var(--border-primary) !important;
    padding-bottom: 15px !important;
}

#content h2 {
    font-family: var(--font-main);
    font-size: 18px !important;
    font-weight: 500 !important;
    color: var(--text-main) !important;
    text-transform: uppercase;
    letter-spacing: 2px;
    margin-top: 40px;
    margin-bottom: 20px;
    border-bottom: 1px solid var(--border-primary);
    padding-bottom: 12px;
}

#content h2:first-of-type {
    margin-top: 0;
}

.raffia-auth-heading {
    font-family: var(--font-main);
    font-size: 14px;
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 1.5px;
    color: var(--text-main);
    margin-bottom: 1.5rem;
    text-align: center;
}

/* ==========================================================================
   LINKS
   ========================================================================== */

a {
    color: var(--brand-primary);
    text-decoration: none;
    transition: var(--transition);
}

a:hover {
    color: var(--brand-primary-hover);
}

a:focus-visible {
    outline: 1px dashed var(--brand-primary);
    outline-offset: 2px;
}

/* Очищення ефектів на кнопках-посиланнях */
a.btn:hover,
a.btn-primary:hover,
a.btn-gold:hover,
a.btn-raffia:hover,
a.btn:hover *,
a.btn-primary:hover *,
a.btn-gold:hover *,
a.btn-raffia:hover * {
    -webkit-text-stroke: 0 !important;
    text-shadow: none !important;
    color: var(--bg-ivory) !important;
}

/* ==========================================================================
   BUTTONS
   ========================================================================== */

.btn-raffia,
.btn-primary,
.btn-gold,
.btn-black,
.btn-olive,
.btn-grey {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    height: var(--btn-height);
    padding: 0 20px;
    font-size: 13px;
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 1px;
    text-decoration: none !important;
    border-radius: var(--radius-sm);
    border: 1px solid transparent;
    background: transparent;
    cursor: pointer;
    white-space: nowrap;
    transition: var(--transition);
}

/* Primary */
.btn-primary,
.btn-gold {
    border-color: var(--brand-primary);
    color: var(--brand-primary);
}

.btn-primary:hover,
.btn-primary:focus,
.btn-primary:active,
.btn-gold:hover {
    background-color: var(--brand-primary) !important;
    color: var(--bg-ivory) !important;
    border-color: var(--brand-primary) !important;
}

.btn-primary:disabled,
.btn-gold:disabled,
.btn-gold[disabled] {
    background-color: var(--brand-primary) !important;
    color: var(--bg-ivory) !important;
    opacity: 0.8;
    cursor: wait;
}

/* Black */
.btn-black {
    border-color: #000;
    color: #000;
}
.btn-black:hover {
    background: #000;
    color: var(--bg-ivory);
}

/* Olive */
.btn-olive {
    border-color: var(--brand-olive-dark);
    color: var(--brand-olive-dark);
}
.btn-olive:hover {
    background: var(--brand-olive-dark);
    color: var(--bg-ivory);
}

/* Grey */
.btn-grey {
    border-color: #ccc;
    color: #888;
}
.btn-grey:hover {
    background: #ccc;
    color: var(--bg-ivory);
}

/* Square action buttons */
.btn-square-action {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 40px !important;
    height: 40px !important;
    padding: 0 !important;
    border: none !important;
    background: transparent !important;
    box-shadow: none !important;
    font-size: 22px;
    cursor: pointer;
    transition: color 0.3s ease, transform 0.2s ease;
    text-decoration: none !important;
}

.btn-square-action:active {
    transform: scale(0.9);
}

.btn-square-cart,
.btn-square-remove,
.btn-square-edit {
    color: var(--brand-primary) !important;
}

.btn-square-cart:hover,
.btn-square-edit:hover {
    color: var(--brand-black) !important;
}

.btn-square-remove:hover {
    color: #e63946 !important;
}

/* Wishlist heart */
.btn-wishlist .heart-icon {
    fill: none;
    stroke: currentColor;
    stroke-width: 1.5;
    transition: fill 0.2s ease, transform 0.2s ease;
}

.btn-wishlist.active .heart-icon {
    fill: currentColor;
}

.btn-wishlist:hover .heart-icon {
    transform: scale(1.1);
}

/* ==========================================================================
   FORMS
   ========================================================================== */

.form-control,
.form-select,
input[type="text"],
input[type="password"],
input[type="email"],
input[type="date"],
input[type="time"],
input[type="datetime-local"],
select,
textarea {
    width: 100% !important;
    height: auto !important;
    background-color: var(--bg-soft) !important;
    border: none !important;
    border-bottom: 1px solid var(--border-primary) !important;
    border-radius: var(--radius-sm) var(--radius-sm) 0 0 !important;
    padding: 12px 15px !important;
    font-family: var(--font-main) !important;
    font-size: 14px !important;
    color: var(--text-main) !important;
    box-shadow: none !important;
    outline: none !important;
    transition: background-color 0.3s ease, border-color 0.3s ease !important;
}

.form-control:focus,
.form-select:focus,
input:focus,
select:focus,
textarea:focus {
    background-color: rgba(92, 107, 90, 0.07) !important;
    border-bottom-color: var(--brand-primary) !important;
    box-shadow: none !important;
}

::placeholder {
    color: var(--text-muted) !important;
    font-weight: 400 !important;
    opacity: 0.75 !important;
}

input:-webkit-autofill,
textarea:-webkit-autofill,
select:-webkit-autofill {
    -webkit-box-shadow: 0 0 0 50px var(--bg-ivory) inset !important;
    -webkit-text-fill-color: var(--text-main) !important;
}

.form-select,
select {
    background-position: right 15px center !important;
    padding-right: 40px !important;
}

/* Checkbox / Switch */
.form-check-input:checked {
    background-color: var(--brand-primary) !important;
    border-color: var(--brand-primary) !important;
}

.form-check-input:focus {
    border-color: var(--brand-primary) !important;
    box-shadow: 0 0 0 0.25rem rgba(92, 107, 90, 0.25) !important;
}

.form-switch .form-check-input:focus:not(:checked) {
    background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='-4 -4 8 8'%3e%3ccircle r='3' fill='%235C6B5A'/%3e%3c/svg%3e") !important;
}

.form-switch .form-check-input:checked:focus {
    background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='-4 -4 8 8'%3e%3ccircle r='3' fill='%23ffffff'/%3e%3c/svg%3e") !important;
}

/* Custom oval switch */
.raffia-switch-row {
    display: flex;
    align-items: center;
    gap: 12px;
}

.raffia-oval-switch {
    position: relative;
    width: 36px;
    height: 20px;
    appearance: none;
    background-color: rgba(26, 26, 26, 0.1);
    border: 1px solid rgba(26, 26, 26, 0.15);
    border-radius: 20px;
    cursor: pointer;
    transition: background-color 0.25s ease, border-color 0.25s ease;
}

.raffia-oval-switch::before {
    content: '';
    position: absolute;
    top: 2px;
    left: 2px;
    width: 14px;
    height: 14px;
    background-color: #fff;
    border-radius: 50%;
    transition: transform 0.25s cubic-bezier(0.25, 0.8, 0.25, 1);
}

.raffia-oval-switch:checked {
    background-color: var(--brand-primary) !important;
    border-color: var(--brand-primary) !important;
}

.raffia-oval-switch:checked::before {
    transform: translateX(16px);
}

.raffia-oval-switch:focus {
    box-shadow: 0 0 0 3px rgba(92, 107, 90, 0.15);
}

.raffia-switch-label {
    font-family: var(--font-main);
    color: var(--text-main);
    opacity: 0.85;
    font-size: 14px;
    cursor: pointer;
    user-select: none;
    margin: 0;
}

/* Date input */
input[type="date"]::-webkit-calendar-picker-indicator {
    opacity: 0;
    cursor: pointer;
    position: absolute;
    right: 12px;
    width: 24px;
    height: 24px;
}

input[type="date"] {
    position: relative;
    color: var(--text-main) !important;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='24' height='24' viewBox='0 0 24 24' fill='none' stroke='%235C6B5A' stroke-width='1.5' stroke-linecap='round' stroke-linejoin='round'%3E%3Crect x='3' y='4' width='18' height='18' rx='2' ry='2'%3E%3C/rect%3E%3Cline x1='16' y1='2' x2='16' y2='6'%3E%3C/line%3E%3Cline x1='8' y1='2' x2='8' y2='6'%3E%3C/line%3E%3Cline x1='3' y1='10' x2='21' y2='10'%3E%3C/line%3E%3C/svg%3E") !important;
    background-repeat: no-repeat !important;
    background-position: right 10px center !important;
    background-size: 18px !important;
    padding-right: 40px !important;
}

input[type="date"]::-webkit-datetime-edit-text,
input[type="date"]::-webkit-datetime-edit-day-field,
input[type="date"]::-webkit-datetime-edit-month-field,
input[type="date"]::-webkit-datetime-edit-year-field {
    color: var(--text-main) !important;
    opacity: 0.4 !important;
}

input[type="date"]:focus::-webkit-datetime-edit-text,
input[type="date"]:focus::-webkit-datetime-edit-day-field,
input[type="date"]:focus::-webkit-datetime-edit-month-field,
input[type="date"]:focus::-webkit-datetime-edit-year-field {
    opacity: 1 !important;
}

/* Number input - remove spinners */
input[type="number"]::-webkit-outer-spin-button,
input[type="number"]::-webkit-inner-spin-button {
    -webkit-appearance: none !important;
    margin: 0 !important;
}

input[type="number"] {
    -moz-appearance: textfield !important;
}

/* ==========================================================================
   HEADER
   ========================================================================== */

.raffia-header,
.raffia-menu-wrapper,
header,
#top,
.navbar {
    padding-right: 0 !important;
    border-bottom: none !important;
    box-shadow: none !important;
}

.raffia-header {
    background-color: var(--bg-ivory);
    padding: 40px 0 20px 0;
}

.raffia-header-inner {
    display: flex;
    justify-content: space-between;
    align-items: center;
    width: 100%;
    position: relative;
}

.header-center {
    position: absolute;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 10;
}

.header-center img {
    height: 65px;
    width: auto;
    display: block;
    margin: 0 auto;
}

.raffia-logo-text {
    font-family: var(--font-display);
    font-size: 32px;
    font-weight: 400;
    color: var(--brand-primary);
    text-transform: uppercase;
    letter-spacing: 6px;
    text-decoration: none;
    display: block;
}

.header-left,
.header-right {
    flex: 1;
    display: flex;
    align-items: center;
    gap: 25px;
}

.header-left { justify-content: flex-start; }
.header-right { justify-content: flex-end; }

.raffia-icon-link {
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--brand-primary) !important;
    text-decoration: none;
    transition: color 0.3s ease;
}

.raffia-icon-link svg {
    width: 22px;
    height: 22px;
    stroke-width: 1.7px !important;
}

.raffia-icon-link:hover {
    color: var(--brand-black) !important;
}

/* ==========================================================================
   SEARCH
   ========================================================================== */

.raffia-search-inline-wrapper {
    position: relative;
    display: flex;
    align-items: center;
}

.raffia-search-btn-trigger {
    position: relative;
    z-index: 1100;
    display: flex;
    align-items: center;
    justify-content: center;
    background: transparent;
    border: none;
    padding: 0;
    margin: 0;
    line-height: 0;
    cursor: pointer;
    color: var(--brand-primary);
    transition: color 0.3s ease;
}

.raffia-search-btn-trigger:hover {
    color: var(--brand-black);
}

.raffia-search-btn-trigger svg {
    width: 22px;
    height: 22px;
    stroke-width: 1.7px;
}

.raffia-search-slide-panel {
    right: 0;
    padding-right: 35px;
    width: 280px;
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
    transition: all 0.3s ease-in-out;
    z-index: 10;
}

.raffia-search-inline-wrapper:hover .raffia-search-slide-panel,
.raffia-search-slide-panel:focus-within {
    transform: translateY(-50%) translateX(-5px);
    opacity: 1;
    visibility: visible;
    pointer-events: auto;
}

.raffia-search-slide-input {
    width: 100%;
    border: none;
    border-bottom: 1.5px solid var(--brand-primary);
    background-color: var(--bg-soft) !important;
    padding: 5px 0;
    font-family: var(--font-main);
    font-size: 14px;
    color: var(--text-main);
    outline: none;
    transition: border-color 0.3s ease;
}

.raffia-search-slide-input:focus {
    background-color: rgba(92, 107, 90, 0.07) !important;
}

.raffia-search-slide-input::placeholder {
    color: var(--text-muted);
    font-weight: 300;
}

/* ==========================================================================
   DROPDOWNS
   ========================================================================== */

.header-left .dropdown-toggle::after,
.header-right .dropdown-toggle::after,
header .dropdown.d-grid > button.btn-dark.dropdown-toggle::after {
    display: none !important;
}

.header-left .dropdown,
.header-right .dropdown {
    display: flex;
    align-items: center;
    position: relative !important;
}

header .dropdown .dropdown-menu {
    z-index: 9999 !important;
}

.raffia-header .dropdown-menu {
    background-color: var(--bg-ivory) !important;
    border: none !important;
    box-shadow: var(--shadow-medium) !important;
    border-radius: var(--radius-sm) !important;
}

.raffia-header .dropdown-menu .dropdown-divider,
.raffia-header .dropdown-menu hr {
    display: none !important;
}

@keyframes fadeInDropdown {
    from { opacity: 0; transform: translateY(5px); }
    to { opacity: 1; transform: translateY(0); }
}

.header-left .dropdown-menu::before,
.header-right .dropdown-menu::before {
    content: '';
    position: absolute;
    top: -20px;
    left: 0;
    right: 0;
    height: 20px;
    background: transparent;
    z-index: 1080;
}

@media (min-width: 769px) {
    .header-left .dropdown:hover .dropdown-menu,
    .header-right .dropdown:hover .dropdown-menu,
    .header-right .dropdown:focus-within .dropdown-menu,
    #cart:hover .dropdown-menu,
    .raffia-header #cart:hover .dropdown-menu,
    header .dropdown.d-grid:hover .dropdown-menu {
        display: block !important;
        animation: fadeInDropdown 0.2s ease-in-out forwards !important;
    }
}

.header-left .dropdown-menu {
    margin-top: 10px !important;
    border-radius: 8px !important;
    min-width: 140px !important;
    padding: 15px 20px !important;
    left: 0 !important;
    right: auto !important;
    text-align: left;
}

.header-right .dropdown-menu {
    margin-top: 15px !important;
    background-color: transparent !important;
    box-shadow: none !important;
    min-width: auto;
    padding: 0;
    right: 0 !important;
    left: auto !important;
    text-align: right;
}

.header-left .dropdown-item,
.header-right .dropdown-item {
    background-color: transparent !important;
    color: var(--text-muted) !important;
    padding: 8px 0 !important;
    transition: color 0.3s ease !important;
    font-family: var(--font-main) !important;
    font-size: 13px !important;
    white-space: nowrap !important;
}

.header-left .dropdown-item:hover,
.header-right .dropdown-item:hover {
    color: var(--brand-primary) !important;
}

.raffia-active-currency {
    font-family: var(--font-main);
    font-size: 24px;
    font-weight: 400;
    line-height: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 22px;
    height: 22px;
}

/* Sort dropdown */
.raffia-sort-wrapper button {
    color: #222 !important;
    outline: none;
    box-shadow: none;
    transition: color 0.3s ease;
}

.raffia-sort-wrapper button:hover,
.raffia-sort-wrapper button:focus {
    color: var(--brand-primary) !important;
}

.raffia-sort-wrapper .dropdown-menu {
    border-radius: 8px;
    padding: 8px 0;
    min-width: 200px;
}

.raffia-sort-wrapper .dropdown-item {
    font-size: 14px;
    padding: 8px 16px;
    color: #444;
    transition: all 0.2s;
}

.raffia-sort-wrapper .dropdown-item:hover,
.raffia-sort-wrapper .dropdown-item:focus,
.raffia-sort-wrapper .dropdown-item.active,
.raffia-sort-wrapper .dropdown-item:active {
    background-color: transparent !important;
    color: var(--brand-primary) !important;
}

.raffia-sort-wrapper .dropdown-item.active {
    font-weight: 700 !important;
}

.raffia-sort-wrapper .dropdown-toggle::after {
    display: none !important;
}

/* ==========================================================================
   AUTH DROPDOWN
   ========================================================================== */

#raffia-auth-dropdown {
    background-color: var(--bg-ivory) !important;
    border: none !important;
    box-shadow: 0 15px 35px rgba(0, 0, 0, 0.08) !important;
    z-index: 9999 !important;
    min-width: 320px !important;
    padding: 20px 20px 25px !important;
    right: -48px !important;
    border-radius: 8px !important;
    margin-top: 10px !important;
}

#raffia-auth-dropdown .dropdown-item,
#raffia-auth-dropdown a:not(.btn-raffia-submit) {
    padding: 6px 0 !important;
    font-size: 14px;
    font-weight: 300;
}

#raffia-auth-dropdown h2,
#raffia-auth-dropdown #form-login p:first-of-type,
#raffia-auth-dropdown #form-forgotten h1,
#raffia-auth-dropdown #form-forgotten p {
    display: none !important;
}

#raffia-auth-dropdown .form-control {
    background-color: var(--bg-soft) !important;
    border: 1px solid var(--border-primary) !important;
    padding: 10px 15px !important;
    font-size: 0.9rem !important;
    border-radius: var(--radius-sm) !important;
    color: #333 !important;
}

#raffia-auth-dropdown .form-control:focus {
    border-color: var(--brand-primary) !important;
    background-color: rgba(92, 107, 90, 0.07) !important;
    box-shadow: none !important;
}

.desktop-forgot-link,
#raffia-auth-dropdown a[href*="forgotten"] {
    display: inline-block;
    color: var(--text-muted) !important;
    text-decoration: none !important;
    font-size: 13px !important;
    font-weight: 300 !important;
    transition: color 0.3s !important;
    margin: 5px 0 15px 0;
    border-bottom: 1px solid transparent;
}

.desktop-forgot-link:hover,
#raffia-auth-dropdown a[href*="forgotten"]:hover {
    color: var(--brand-primary) !important;
    border-bottom-color: var(--brand-primary);
}

button[type="submit"].desktop-submit-btn {
    flex: 0 0 42px !important;
    width: 42px !important;
    height: 42px !important;
    padding: 0 !important;
    border-radius: 50% !important;
    border: 1px solid var(--brand-primary) !important;
    background: transparent !important;
    color: var(--brand-primary) !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    transition: all 0.3s !important;
}

button[type="submit"].desktop-submit-btn:hover {
    background: var(--brand-primary) !important;
    color: var(--bg-ivory) !important;
}

#raffia-auth-dropdown .text-danger,
#raffia-auth-dropdown .auth-error-message,
#raffia-auth-dropdown .alert-danger {
    color: #e63946 !important;
    font-size: 13px;
    text-align: center;
    margin-bottom: 15px;
    font-weight: 500;
}

#raffia-auth-dropdown::after {
    content: '';
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    height: 300px;
    background: transparent;
    cursor: default;
}

/* ==========================================================================
   CART
   ========================================================================== */

.raffia-cart-wrapper {
    position: relative;
    display: flex;
    align-items: center;
    cursor: pointer;
}

.raffia-cart-badge {
    position: absolute;
    top: -6px;
    right: -8px;
    background-color: var(--brand-primary);
    color: var(--bg-ivory);
    font-size: 9px;
    font-weight: 600;
    font-family: var(--font-main);
    width: 16px;
    height: 16px;
    border-radius: 50%;
    display: flex;
    justify-content: center;
    align-items: center;
    line-height: 1;
    pointer-events: none;
}

header .dropdown.d-grid > button.btn-dark.dropdown-toggle {
    background-color: transparent !important;
    border: none !important;
    color: transparent !important;
    font-size: 0 !important;
    box-shadow: none !important;
    display: flex !important;
    align-items: center !important;
    padding: 0 !important;
}

header .dropdown.d-grid > button.btn-dark.dropdown-toggle > i.fa-cart-shopping {
    display: none !important;
}

header .dropdown.d-grid > button.btn-dark.dropdown-toggle::before {
    content: "" !important;
    display: inline-block !important;
    width: 24px !important;
    height: 24px !important;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%235C6B5A' stroke-width='1.25' stroke-linecap='round' stroke-linejoin='round'%3E%3Ccircle cx='9' cy='21' r='1'%3E%3C/circle%3E%3Ccircle cx='20' cy='21' r='1'%3E%3C/circle%3E%3Cpath d='M1 1h4l2.68 13.39a2 2 0 0 0 2 1.61h9.72a2 2 0 0 0 2-1.61L23 6H6'%3E%3C/path%3E%3C/svg%3E") !important;
    background-size: contain !important;
    background-repeat: no-repeat !important;
}

header .dropdown.d-grid .dropdown-menu {
    background-color: var(--bg-ivory) !important;
    border: none !important;
    box-shadow: var(--shadow-medium) !important;
    border-radius: var(--radius-sm) !important;
    margin-top: 10px !important;
    min-width: 220px !important;
}

header .dropdown.d-grid .dropdown-menu li.text-center {
    font-size: 14px !important;
    font-weight: 300 !important;
    color: #666 !important;
    padding: 20px !important;
    white-space: nowrap !important;
}

#cart .dropdown-menu {
    background-color: var(--bg-ivory) !important;
    box-shadow: 0 15px 40px rgba(0, 0, 0, 0.1) !important;
    border: 1px solid var(--border-primary) !important;
    border-radius: 8px !important;
    z-index: 3000 !important;
    padding: 20px !important;
}

@media (min-width: 768px) {
    #cart .dropdown-menu {
        width: 430px !important;
        min-width: 430px !important;
        right: 0 !important;
        left: auto !important;
        margin-top: 20px !important;
    }
}

.rf-cart-img {
    width: 100% !important;
    height: auto !important;
    display: block !important;
    border-radius: 6px !important;
    border: 1px solid rgba(0,0,0,0.05) !important;
    padding: 0 !important;
    margin: 0 !important;
}

.rf-cart-qty-input {
    -webkit-appearance: none !important;
    -moz-appearance: textfield !important;
    appearance: none !important;
    background-color: transparent !important;
    width: 45px !important;
    min-width: 45px !important;
    max-width: 45px !important;
    height: 26px !important;
    border: none !important;
    border-bottom: 1.5px solid var(--border-primary) !important;
    border-radius: 0 !important;
    padding: 0 0 0 1px !important;
    margin: 0 !important;
    text-align: center !important;
    color: var(--text-main) !important;
    font-size: 15px !important;
    font-weight: 600 !important;
    box-shadow: none !important;
    outline: none !important;
}

input[type="number"].rf-cart-qty-input::-webkit-outer-spin-button,
input[type="number"].rf-cart-qty-input::-webkit-inner-spin-button {
    -webkit-appearance: none !important;
    display: none !important;
    margin: 0 !important;
}

body.hold-cart-open #cart .dropdown-menu {
    display: block !important;
    opacity: 1 !important;
    visibility: visible !important;
    pointer-events: auto !important;
    animation: none !important;
    transition: none !important;
}

/* ==========================================================================
   MAIN MENU & MEGAMENU
   ========================================================================== */

.raffia-menu-wrapper {
    background-color: var(--bg-ivory);
    padding-bottom: 10px;
    position: relative;
}

#menu {
    background-color: transparent !important;
    background-image: none !important;
    border: none !important;
    box-shadow: none !important;
    margin-bottom: 0;
    min-height: auto;
    display: flex;
    justify-content: center;
}

#menu .navbar-nav {
    display: flex;
    justify-content: center;
    align-items: center;
    width: 100%;
    flex-direction: row;
    margin: 0;
    padding: 0;
}

#menu .navbar-nav > li {
    position: relative;
}

#menu .navbar-nav > li > a.nav-link {
    background-color: transparent !important;
    color: var(--text-main) !important;
    font-size: 12px;
    font-weight: 400;
    text-transform: uppercase;
    letter-spacing: 2.5px;
    padding: 15px 20px;
    transition: color 0.3s ease;
    display: block;
    text-align: center;
    text-decoration: none;
    position: relative;
    z-index: 1030;
}

#menu .navbar-nav > li > a.nav-link:hover,
#menu .navbar-nav > li.has-megamenu:hover > a.nav-link {
    color: var(--brand-primary) !important;
}

.megamenu-wrapper {
    position: absolute;
    top: 100%;
    left: 0;
    width: 260px;
    min-width: 240px;
    margin-left: 0;
    background-color: var(--bg-ivory);
    z-index: 1030;
    display: block !important;
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
    transform: translateY(5px);
    transition: opacity 0.3s ease, visibility 0.3s ease, transform 0.3s ease;
    border-radius: var(--radius-sm);
    box-shadow: var(--shadow-medium);
}

.megamenu-wrapper::before {
    content: '';
    position: absolute;
    top: -15px;
    left: 0;
    right: 0;
    height: 15px;
    background: transparent;
}

.megamenu-container {
    max-width: 100%;
    margin: 0 auto;
    padding: 0;
}

.megamenu-inner {
    display: flex !important;
    flex-direction: column !important;
    align-items: flex-start !important;
    text-align: left !important;
    gap: 8px !important;
    padding: 15px 20px !important;
    flex-wrap: nowrap !important;
}

.megamenu-column {
    flex: 0 0 auto;
    width: 100%;
    min-width: auto;
}

.megamenu-title {
    display: block;
    font-family: var(--font-main);
    font-weight: 600;
    font-size: 13px;
    color: var(--text-main) !important;
    margin-bottom: 8px;
    text-decoration: none;
    transition: color 0.3s ease;
}

.megamenu-title:hover {
    color: var(--brand-primary) !important;
}

.megamenu-list {
    margin: 0;
    padding: 0;
    list-style: none;
    display: block !important;
}

.megamenu-list li {
    display: block;
    width: 100%;
    margin-bottom: 4px;
}

.megamenu-list.cols-2,
.megamenu-list.cols-3 {
    column-count: 1 !important;
    min-width: auto !important;
}

.megamenu-link {
    color: var(--text-muted) !important;
    font-family: var(--font-main);
    font-size: 12px;
    font-weight: 400;
    text-decoration: none;
    display: block;
    padding: 4px 0;
    transition: color 0.3s ease, padding-left 0.3s ease;
}

.megamenu-link:hover {
    color: var(--brand-primary) !important;
    padding-left: 5px;
}

@media (min-width: 769px) {
    #menu .navbar-nav > li.has-megamenu:hover .megamenu-wrapper {
        opacity: 1;
        visibility: visible;
        pointer-events: auto;
        transform: translateY(0);
    }

    #menu .navbar-nav > li.has-megamenu:hover > a.nav-link svg {
        transform: rotate(180deg);
    }

    .d-none.d-lg-block .megamenu-wrapper,
    #menu .has-megamenu .megamenu-wrapper {
        background-color: var(--bg-ivory) !important;
        border: none !important;
        box-shadow: 0 15px 35px rgba(0, 0, 0, 0.08) !important;
        z-index: 1030 !important;
    }
}

/* ==========================================================================
   SIDEBAR CATEGORIES
   ========================================================================== */

#column-left .raffia-sidebar-menu,
#column-right .raffia-sidebar-menu {
    border-radius: 0;
    box-shadow: none;
    background: transparent;
    padding-top: 10px;
}

#column-left .list-group-item,
#column-right .list-group-item {
    border: none !important;
    background-color: transparent !important;
    padding: 12px 0 !important;
    display: block;
    transition: color 0.3s ease, opacity 0.3s ease;
}

#column-left .list-group-item.cat-level-1 {
    color: var(--text-main) !important;
    font-size: 14px;
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 1.5px;
}

#column-left .list-group-item.cat-level-1:hover,
#column-left .list-group-item.cat-level-1.active {
    color: var(--brand-primary) !important;
}

#column-left .list-group-item.cat-level-2 {
    color: var(--brand-primary) !important;
    font-size: 13px;
    font-weight: 300;
    text-transform: uppercase;
    letter-spacing: 1px;
    padding-left: 20px !important;
    opacity: 0.8;
}

#column-left .list-group-item.cat-level-2:hover,
#column-left .list-group-item.cat-level-2.active {
    opacity: 1;
    font-weight: 400;
}

#column-left .list-group-item.cat-level-3 {
    color: var(--text-muted) !important;
    font-size: 13px;
    font-weight: 300;
    text-transform: none;
    padding-left: 35px !important;
}

#column-left .list-group-item.cat-level-3:hover,
#column-left .list-group-item.cat-level-3.active {
    color: var(--brand-primary) !important;
    font-weight: 400;
}

/* ==========================================================================
   BREADCRUMBS
   ========================================================================== */

.breadcrumb {
    font-size: 11px !important;
    background: transparent !important;
    padding: 0 !important;
    margin-bottom: 25px !important;
    opacity: 0.7;
    --bs-breadcrumb-divider: '•';
    --bs-breadcrumb-divider-color: var(--brand-primary);
}

.breadcrumb a {
    color: var(--text-main) !important;
    text-decoration: none !important;
    transition: color 0.3s ease, opacity 0.3s ease;
}

.breadcrumb a:hover {
    color: var(--brand-primary) !important;
    opacity: 1;
}

.breadcrumb-item + .breadcrumb-item::before {
    color: #b0a090 !important;
}

/* ==========================================================================
   ACCOUNT
   ========================================================================== */

.raffia-account-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    gap: 20px;
    margin-bottom: 45px;
}

.raffia-account-tile {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
    background-color: var(--bg-ivory);
    border: 1px solid var(--border-primary);
    border-radius: var(--radius-md);
    padding: 30px 15px;
    text-decoration: none !important;
    transition: all 0.3s cubic-bezier(0.25, 0.8, 0.25, 1);
    box-shadow: 0 4px 15px rgba(0,0,0,0.02);
}

.raffia-account-tile:hover {
    border-color: var(--brand-primary);
    box-shadow: 0 10px 25px rgba(92, 107, 90, 0.15);
    transform: translateY(-4px);
}

.raffia-account-tile svg {
    width: 32px;
    height: 32px;
    stroke: var(--brand-primary);
    margin-bottom: 15px;
    transition: transform 0.3s ease;
}

.raffia-account-tile:hover svg {
    transform: scale(1.1);
}

.raffia-account-tile span {
    color: var(--text-main);
    font-family: var(--font-main);
    font-size: 13px;
    font-weight: 500;
    line-height: 1.4;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

#content ul.list-unstyled {
    display: none !important;
}

/* ==========================================================================
   FOOTER
   ========================================================================== */

footer {
    background-color: var(--bg-olive);
    border-top: 1px solid #dcdcd6;
    margin-bottom: 0;
}

.rf-newsletter-wrapper {
    background-color: #dfdfd9;
    border: none !important;
}

.rf-newsletter-text {
    font-family: var(--font-main);
    font-size: 14px !important;
    font-weight: 500 !important;
    color: var(--text-main) !important;
    line-height: 1.4 !important;
    margin-bottom: 0;
}

.rf-premium-form input.form-control {
    height: 45px !important;
    background-color: transparent !important;
    border: none !important;
    border-bottom: 1px solid var(--brand-olive) !important;
    border-radius: 0 !important;
    font-family: var(--font-main) !important;
    font-size: 14px !important;
    color: var(--text-main) !important;
    box-shadow: none !important;
    padding-left: 0 !important;
}

.rf-premium-form input.form-control:focus {
    border-bottom: 1px solid var(--brand-black) !important;
    background-color: transparent !important;
    box-shadow: none !important;
}

.rf-premium-form button {
    height: 45px !important;
    background-color: transparent !important;
    border: 1px solid var(--brand-olive) !important;
    color: var(--brand-olive) !important;
    border-radius: var(--radius-sm) !important;
    font-family: var(--font-main);
    font-size: 13px;
    font-weight: 500;
    text-transform: uppercase !important;
    letter-spacing: 1px;
    transition: all 0.3s ease;
    white-space: nowrap;
}

.rf-premium-form button:hover {
    background-color: var(--brand-olive) !important;
    color: var(--bg-ivory) !important;
}

.rf-brand-column {
    padding-right: 40px;
}

.rf-footer-logo-img {
    max-height: 45px !important;
    width: auto;
    display: block;
}

.rf-footer-logo-wrap {
    display: inline-block;
    text-decoration: none !important;
    margin-bottom: 15px;
}

.rf-brand-description {
    font-family: var(--font-main);
    font-size: 13px;
    line-height: 1.6;
    color: var(--text-muted);
    max-width: 320px;
}

footer h5 {
    font-family: var(--font-main);
    font-size: 14px;
    font-weight: 500;
    color: var(--text-main);
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 20px;
}

footer .list-unstyled a {
    font-family: var(--font-main);
    font-size: 13px;
    color: var(--text-muted);
    text-decoration: none;
    transition: color 0.3s ease;
    display: block;
    margin-bottom: 12px;
}

footer .list-unstyled a:hover {
    color: var(--brand-primary);
}

.rf-contact-item {
    font-family: var(--font-main);
    font-size: 13px;
    color: var(--text-muted);
    margin-bottom: 15px;
}

.rf-contact-item span {
    color: var(--text-main);
}

hr.rf-footer-divider {
    border: none;
    border-top: 1px solid rgba(101, 108, 90, 0.2);
    opacity: 1;
}

.rf-copyright-block p,
.rf-copyright-text p {
    font-family: var(--font-main);
    font-size: 13px;
    color: var(--text-muted);
    margin-bottom: 0 !important;
}

.rf-social-link {
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--text-muted);
    padding: 10px;
    margin: -10px;
}

.rf-social-link svg {
    transition: stroke 0.3s ease;
}

.rf-social-link:hover svg {
    stroke: var(--brand-black) !important;
}

/* ==========================================================================
   CONTACT PAGE
   ========================================================================== */

#information-contact {
    padding-top: 50px;
    padding-bottom: 70px;
    background-color: var(--bg-ivory);
}

#information-contact h3,
#information-contact legend {
    display: none !important;
}

/* ==========================================================================
   AUTH PAGES
   ========================================================================== */

.raffia-centered-login-col {
    width: 100% !important;
    max-width: 500px !important;
    margin: 40px auto 60px !important;
    float: none !important;
    flex: 0 0 auto !important;
    padding: 0 15px !important;
}

.raffia-centered-login-col .well,
.raffia-centered-login-col .card-body {
    background-color: var(--bg-ivory) !important;
    border: none !important;
    border-radius: var(--radius-lg) !important;
    padding: 40px 30px !important;
    box-shadow: 0 15px 50px rgba(0,0,0,0.08) !important;
}

.raffia-centered-login-col .control-label,
.raffia-centered-login-col label.col-form-label {
    display: none !important;
}

.raffia-centered-login-col input[type="submit"] {
    display: flex !important;
    width: 100% !important;
    align-items: center !important;
    justify-content: center !important;
    height: 45px !important;
    background-color: transparent !important;
    border: 1px solid var(--brand-primary) !important;
    color: var(--brand-primary) !important;
    font-family: var(--font-main) !important;
    font-size: 13px !important;
    font-weight: 500 !important;
    text-transform: uppercase !important;
    letter-spacing: 1.5px !important;
    border-radius: var(--radius-sm) !important;
    transition: all 0.3s ease !important;
    margin-top: 15px !important;
    cursor: pointer !important;
}

.raffia-centered-login-col input[type="submit"]:hover {
    background-color: var(--brand-primary) !important;
    color: #ffffff !important;
}

.raffia-centered-login-col a[href*="forgotten"] {
    display: block !important;
    text-align: right !important;
    color: var(--text-muted) !important;
    font-size: 13px !important;
    margin-top: -5px !important;
    margin-bottom: 20px !important;
    text-decoration: none !important;
}

.raffia-centered-login-col a[href*="forgotten"]:hover {
    color: var(--brand-primary) !important;
}

hr.raffia-login-divider {
    border-top: 1px dashed var(--border-primary) !important;
    margin: 25px 0 !important;
    border-bottom: none !important;
}

#account-login,
#account-register {
    padding-top: 15px !important;
    padding-bottom: 60px !important;
}

.raffia-auth-page-card {
    background-color: var(--bg-ivory) !important;
    border: 1px solid var(--border-primary) !important;
    border-radius: var(--radius-lg) !important;
    padding: 25px 30px !important;
    box-shadow: 0 15px 50px rgba(0, 0, 0, 0.05) !important;
}

.raffia-auth-tabs {
    display: flex;
    justify-content: center;
    gap: 40px;
    margin-bottom: 35px;
}

.raffia-auth-tabs .auth-tab {
    color: var(--text-main) !important;
    text-transform: uppercase;
    font-family: var(--font-main);
    font-size: 14px;
    font-weight: 500;
    text-decoration: none;
    transition: color 0.3s ease;
    padding: 5px 10px;
}

.raffia-auth-tabs .auth-tab.active {
    color: var(--brand-primary) !important;
    pointer-events: none;
}

.raffia-auth-tabs .auth-tab:hover:not(.active) {
    color: var(--brand-primary) !important;
}

.raffia-form-legend {
    font-family: var(--font-main) !important;
    font-size: 14px !important;
    font-weight: 500 !important;
    color: var(--text-main) !important;
    text-transform: uppercase !important;
    letter-spacing: 1px !important;
    border-bottom: none !important;
    margin-bottom: 15px !important;
    padding-top: 10px !important;
}

.desktop-login-btn {
    height: 45px !important;
    display: inline-flex !important;
    align-items: center;
    justify-content: center;
}

.form-check-label a.modal-link,
.form-check-label a {
    color: var(--brand-primary) !important;
    text-decoration: none !important;
}

.form-check-label a:hover {
    opacity: 0.7;
}

.form-check.form-switch {
    display: flex;
    align-items: center;
    gap: 10px;
    padding-left: 0;
}

.form-check-input[role="switch"] {
    margin-left: 0 !important;
    margin-top: 0 !important;
    cursor: pointer;
}

.password-toggle {
    position: absolute;
    right: 10px;
    top: 50%;
    transform: translateY(-50%);
    cursor: pointer;
    color: #b0a090;
    z-index: 10;
    transition: color 0.3s ease;
    font-size: 14px;
}

.password-toggle:hover {
    color: var(--brand-primary);
}

.desktop-auth-field .invalid-feedback {
    display: none !important;
}

.desktop-auth-field .form-control.is-invalid + .password-toggle {
    right: 40px !important;
}

/* ==========================================================================
   ALERTS / TOASTS
   ========================================================================== */

#alert.toast-container {
    left: 0 !important;
    right: 0 !important;
    transform: none !important;
    width: 100% !important;
    max-width: 100% !important;
    display: flex !important;
    flex-direction: column;
    align-items: center;
    padding: 15px !important;
    pointer-events: none;
    z-index: 9999;
}

#alert.toast-container .alert {
    pointer-events: auto;
    width: 100% !important;
    max-width: 480px !important;
    margin: 0 auto 10px auto !important;
    background-color: #ffffff !important;
    border-radius: 8px !important;
    font-family: var(--font-main) !important;
    font-size: 13px !important;
    color: var(--text-main) !important;
    display: block !important;
    position: relative !important;
    padding: 15px 40px 15px 50px !important;
    line-height: 1.5 !important;
    border: 1px solid transparent !important;
    text-align: left !important;
}

#alert.toast-container .alert i {
    position: absolute !important;
    left: 15px !important;
    top: 50% !important;
    transform: translateY(-50%) !important;
    font-size: 24px !important;
    margin: 0 !important;
}

#alert.toast-container .alert a {
    display: inline !important;
    font-weight: 600;
    color: var(--brand-primary) !important;
    text-decoration: none !important;
}

#alert.toast-container .alert-danger {
    border-color: rgba(230, 57, 70, 0.4) !important;
    box-shadow: 0 10px 30px rgba(230, 57, 70, 0.1) !important;
}

#alert.toast-container .alert-danger i {
    color: #e63946 !important;
}

#alert.toast-container .alert-success {
    border-color: var(--border-primary-strong) !important;
    box-shadow: 0 10px 30px rgba(92, 107, 90, 0.12) !important;
}

#alert.toast-container .alert-success i {
    color: var(--brand-primary) !important;
}

#alert.toast-container .alert .btn-close {
    position: absolute;
    right: 15px;
    top: 50%;
    transform: translateY(-50%);
    padding: 0;
    margin: 0;
    opacity: 0.4;
    background-size: 10px;
    transition: opacity 0.3s ease;
}

#alert.toast-container .alert .btn-close:hover {
    opacity: 0.9;
}

/* Переопределение стилей для alert-info под тему Raffia */
.alert-info {
    background-color: var(--bg-soft, #f4f5f3) !important;
    border-color: var(--border-primary, rgba(92, 107, 90, 0.25)) !important;
    color: var(--text-main, #1a1a1a) !important;
    border-left: 5px solid var(--brand-primary, #5C6B5A) !important;
}

/* Если внутри блока есть инлайн-стиль с бордером, можно перехватить его универсально */
div.alert-info[style*="border-left"] {
    border-left-color: var(--brand-primary, #5C6B5A) !important;
}

/* Кнопка или ссылки внутри инфо-блока */
.alert-info a, 
.alert-info .btn,
.alert-info button {
    color: var(--brand-primary, #5C6B5A) !important;
    border-color: var(--brand-primary, #5C6B5A) !important;
}

.alert-info .btn:hover,
.alert-info button:hover {
    background-color: var(--brand-primary, #5C6B5A) !important;
    color: #fff !important;
}

/* ==========================================================================
   SELECT2
   ========================================================================== */

.select2-container--bootstrap-5 .select2-selection {
    background-color: var(--bg-soft) !important;
    border: none !important;
    border-bottom: 1px solid var(--border-primary) !important;
    border-radius: var(--radius-sm) var(--radius-sm) 0 0 !important;
    min-height: 46px !important;
    padding: 0 15px !important;
    box-shadow: none !important;
    font-family: var(--font-main) !important;
    font-size: 14px !important;
    display: flex !important;
    align-items: center !important;
}

.select2-container--bootstrap-5 .select2-selection__rendered {
    color: var(--text-main) !important;
    padding: 0 !important;
    margin: 0 !important;
    line-height: 1 !important;
    width: 100%;
}

.select2-container--bootstrap-5 .select2-selection__placeholder {
    color: var(--text-muted) !important;
    opacity: 0.8 !important;
    font-weight: 300 !important;
}

.select2-container--bootstrap-5.select2-container--focus .select2-selection,
.select2-container--bootstrap-5.select2-container--open .select2-selection {
    background-color: rgba(92, 107, 90, 0.07) !important;
    border-bottom-color: var(--brand-primary) !important;
    box-shadow: none !important;
}

.select2-container--bootstrap-5 .select2-selection__arrow {
    right: 5px !important;
    top: 50% !important;
    transform: translateY(-50%) !important;
}

.select2-container--bootstrap-5 .select2-dropdown .select2-results__option--highlighted,
.select2-container--bootstrap-5 .select2-dropdown .select2-results__option--highlighted[aria-selected],
.select2-container--bootstrap-5 .select2-dropdown .select2-results__option[aria-selected="true"] {
    background-color: var(--brand-primary) !important;
    color: var(--bg-ivory) !important;
}

.select2-dropdown {
    border: none !important;
    box-shadow: var(--shadow-medium) !important;
    border-radius: 0 0 8px 8px !important;
    background-color: var(--bg-ivory) !important;
    font-family: var(--font-main) !important;
    overflow: hidden;
    z-index: 9999 !important;
}

.select2-search--dropdown {
    padding: 0 !important;
}

.select2-container--bootstrap-5 .select2-search .select2-search__field {
    background-color: transparent !important;
    border: none !important;
    border-bottom: 1px solid var(--border-primary) !important;
    border-radius: 0 !important;
    padding: 12px 20px 12px 45px !important;
    font-size: 14px !important;
    color: var(--text-main) !important;
    outline: none !important;
    box-shadow: none !important;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%235C6B5A' stroke-width='1.7' stroke-linecap='round' stroke-linejoin='round'%3E%3Ccircle cx='11' cy='11' r='8'%3E%3C/circle%3E%3Cline x1='21' y1='21' x2='16.65' y2='16.65'%3E%3C/line%3E%3C/svg%3E") !important;
    background-repeat: no-repeat !important;
    background-position: 15px center !important;
    background-size: 18px !important;
}

.select2-container--bootstrap-5 .select2-search .select2-search__field:focus {
    border-bottom-color: var(--brand-primary) !important;
    background-color: transparent !important;
    box-shadow: none !important;
}

/* ==========================================================================
   PAGINATION
   ========================================================================== */

.pagination .page-item .page-link {
    border: none !important;
    background: transparent !important;
    color: var(--text-main) !important;
    font-size: 16px;
    font-weight: 500;
    padding: 5px 12px;
    margin: 0 4px;
    transition: color 0.3s ease;
}

.pagination .page-item .page-link:hover {
    color: var(--brand-primary) !important;
    background: transparent !important;
}

.pagination .page-item.active .page-link {
    color: var(--brand-primary) !important;
    font-weight: 700;
    background: transparent !important;
    border-bottom: 2px solid var(--brand-primary) !important;
    border-radius: 0;
}

.pagination .page-link:focus {
    box-shadow: none !important;
    background: transparent !important;
}

.pagination .page-item:first-child .page-link,
.pagination .page-item:last-child .page-link {
    border-radius: 0 !important;
}

/* ==========================================================================
   PRODUCT GALLERY
   ========================================================================== */

.raffia-product-img {
    border: 1px solid var(--border-primary);
    border-radius: var(--radius-sm);
    padding: 4px;
    background-color: #fff;
    transition: border-color 0.3s ease;
}

.raffia-product-img:hover {
    border-color: var(--brand-primary);
}

.rf-main-img {
    object-fit: contain !important; /* Вместо cover, чтобы картинка не обрезалась, а вписывалась целиком */
    width: 100% !important;
    height: auto !important;
    aspect-ratio: 710/380 !important; /* Строго фиксируем пропорции под ваши фото (710х380) */
    background-color: transparent !important;
}

.rf-carousel-nav {
    background-color: var(--brand-black);
    width: 40px;
    height: 40px;
    border-radius: 50%;
    top: 50%;
    transform: translateY(-50%);
    opacity: 0;
    transition: opacity 0.3s ease;
    margin: 0 15px;
}

#rf-product-carousel:hover .rf-carousel-nav {
    opacity: 0.5;
}

.rf-carousel-nav:hover {
    opacity: 1 !important;
}

.rf-carousel-dots {
    position: absolute;
    bottom: 10px !important;
    margin-bottom: 0 !important;
    z-index: 15;
}

.rf-carousel-dots button {
    width: 8px !important;
    height: 8px !important;
    border-radius: 50%;
    background-color: var(--text-muted) !important;
    border: none !important;
    opacity: 0.3 !important;
    margin: 0 5px !important;
    transition: all 0.3s ease;
}

.rf-carousel-dots button.active {
    background-color: var(--brand-primary) !important;
    opacity: 1 !important;
    transform: scale(1.2);
}

#rf-product-carousel.carousel {
    border: none !important;
    border-radius: 0 !important;
    box-shadow: none !important;
    margin-bottom: 0 !important;
    background: transparent !important;
}

.rf-clickable-img {
    cursor: pointer;
    -webkit-tap-highlight-color: transparent;
}

/* ==========================================================================
   PRODUCT PAGE
   ========================================================================== */

.rf-product-info-pad {
    padding-top: 0;
}

.rf-product-brand a {
    font-family: var(--font-main);
    font-size: 13px;
    color: var(--brand-primary) !important;
    text-transform: uppercase;
    letter-spacing: 1px;
    text-decoration: none;
    margin-bottom: 4px;
    display: block;
}

.rf-product-title {
    font-family: var(--font-main);
    font-size: 28px;
    font-weight: 500;
    color: var(--text-main);
    line-height: 1.2;
    margin-bottom: 12px;
}

.rf-product-meta {
    font-size: 13px;
    color: var(--text-muted);
    font-family: var(--font-main);
}

.rf-product-meta span {
    color: var(--text-main);
}

.rf-product-stock {
    font-size: 14px;
    color: var(--text-main);
    font-weight: 500;
    margin-bottom: 1.5rem;
}

.rf-product-stock i {
    color: var(--brand-primary);
    margin-right: 5px;
}

.rf-purchase-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    margin-top: 0.5rem;
    margin-bottom: 1.5rem;
}

.rf-price-new,
.rf-price-special {
    font-size: 28px;
    font-weight: 500;
    color: var(--text-main);
    line-height: 1;
}

.rf-price-old {
    font-size: 14px;
    color: var(--text-muted);
    text-decoration: line-through;
    line-height: 1;
    margin-bottom: 2px;
}

.rf-controls-group {
    flex-grow: 1;
}

.rf-qty-wrapper input {
    width: 55px;
    height: 48px !important;
    border: 1px solid var(--border-primary) !important;
    background-color: transparent !important;
    color: var(--text-main) !important;
    font-weight: 500;
    font-size: 16px;
    border-radius: var(--radius-sm);
}

.rf-qty-wrapper input:focus {
    border-color: var(--brand-primary) !important;
}

.rf-controls-group .btn-gold {
    height: 48px;
    flex-grow: 1;
}

.rf-btn-wishlist {
    height: 48px;
    padding: 0 15px;
    border-color: var(--border-primary);
}

.rf-btn-wishlist i {
    font-size: 18px;
    color: var(--text-main);
}

.rf-alert-minimum {
    background-color: var(--bg-ivory);
    border-color: var(--brand-primary);
    color: var(--text-main);
    padding: 10px 15px;
}

.rf-alert-minimum i {
    color: var(--brand-primary);
}

/* Product Tabs */
.rf-product-tabs {
    border-bottom: none !important;
    display: flex !important;
    flex-wrap: nowrap !important;
    overflow-x: auto !important;
    -webkit-overflow-scrolling: touch;
    width: 100%;
    margin-bottom: 20px;
    padding-left: 0 !important;
    margin-left: 0 !important;
}

.rf-product-tabs::-webkit-scrollbar {
    display: none;
}

.rf-product-tabs .nav-item {
    flex: 0 0 auto !important;
}

.rf-product-tabs .nav-link {
    font-family: var(--font-main);
    font-size: 14px;
    font-weight: 500;
    color: var(--text-muted) !important;
    background: transparent !important;
    border: none !important;
    border-top: 1px solid transparent !important;
    border-bottom: 1px solid #e2e2dd !important;
    border-radius: 0 !important;
    padding: 12px 20px !important;
    transition: color 0.3s ease;
}

.rf-product-tabs .nav-link:hover:not(.active) {
    color: var(--text-main) !important;
}

.rf-product-tabs .nav-link.active {
    color: var(--brand-primary) !important;
    background-color: transparent !important;
    border: none !important;
    border-top: 1px solid #e2e2dd !important;
    border-bottom: 1px solid transparent !important;
}

.rf-product-tabs::after {
    content: '';
    display: block;
    flex: 1 1 auto !important;
    min-width: 15px;
    border-bottom: 1px solid #e2e2dd;
}

/* ==========================================================================
   PRODUCT CARDS / SLIDER
   ========================================================================== */

.rf-card {
    background-color: var(--bg-ivory);
    border: 1px solid var(--border-primary);
    border-radius: var(--radius-md);
    padding: 20px 25px;
    margin-bottom: 20px;
    box-shadow: 0 4px 15px rgba(0,0,0,0.02);
}

.raffia-slider-viewport {
    overflow: hidden;
    position: relative;
    width: 100%;
}

.raffia-slider-track {
    display: flex;
    flex-wrap: nowrap !important;
    align-items: stretch;
    will-change: transform;
    margin-left: -8px;
    margin-right: -8px;
}

.raffia-slider-item {
    flex: 0 0 50%;
    max-width: 50%;
    width: 50%;
    padding: 0 8px;
    box-sizing: border-box;
}

.raffia-product-slider .product-thumb {
    border: none !important;
    background: transparent !important;
    box-shadow: none !important;
    padding: 0 !important;
    margin: 0 !important;
}

.raffia-product-slider .product-thumb a,
.raffia-product-slider .product-thumb .description h4 a {
    color: #222 !important;
    text-decoration: none !important;
}

.raffia-product-slider .product-thumb .description h4 {
    margin-top: 10px !important;
    margin-bottom: 8px !important;
}

.raffia-product-slider .product-thumb .description h4 a {
    font-size: 12px !important;
    font-weight: 500 !important;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.raffia-product-slider .product-thumb .description p,
.raffia-product-slider .product-thumb .price-tax,
.raffia-product-slider .product-thumb .sku,
.raffia-product-slider .product-thumb .stat,
.raffia-product-slider .product-thumb .button-group button:not([formaction*="cart"]) {
    display: none !important;
}

.raffia-product-slider .product-thumb .price {
    font-size: 18px !important;
    font-weight: 800 !important;
    color: var(--brand-primary) !important;
    margin-bottom: 0 !important;
}

.raffia-product-slider .product-thumb .price-new {
    font-size: 18px !important;
    font-weight: 800 !important;
    color: var(--brand-primary) !important;
}

.raffia-product-slider .product-thumb .price-old {
    font-size: 14px !important;
    font-weight: 400 !important;
    color: var(--text-muted) !important;
    text-decoration: line-through !important;
    margin-right: 8px;
}

/* Subcategory pills */
.raffia-subcategory-pill {
    display: inline-block;
    padding: 8px 16px;
    background-color: transparent;
    border: 1px solid #e0e0e0;
    border-radius: var(--radius-sm);
    color: #222 !important;
    font-size: 14px;
    font-weight: 400;
    text-decoration: none !important;
    transition: all 0.3s ease;
}

.raffia-subcategory-pill:hover,
.raffia-subcategory-pill:focus {
    border-color: var(--brand-primary);
    color: var(--brand-primary) !important;
    background-color: var(--bg-soft);
}

/* Product list grid */
#product-list .product-thumb,
#product-list .custom-product-card {
    padding: 0 !important;
    margin: 0 !important;
    border: none !important;
    background: transparent !important;
    box-shadow: none !important;
}

#product-list .image,
#product-list .image a,
#product-list .image img {
    display: block;
    width: 100% !important;
    max-width: 100% !important;
    height: auto !important;
    margin: 0 !important;
    padding: 0 !important;
    border: none !important;
    outline: none !important;
    border-radius: 0 !important;
}

#product-list .custom-name,
#product-list .price-line,
#product-list .caption,
#product-list .sku-line {
    width: 100% !important;
    box-sizing: border-box !important;
    padding-left: 3px !important;
    padding-right: 3px !important;
}

#product-list .price-line {
    display: flex !important;
    justify-content: space-between !important;
    align-items: center !important;
    margin-top: 10px !important;
    margin-bottom: 15px !important;
}

#product-list form {
    display: flex !important;
    flex-direction: column !important;
    height: 100% !important;
}

#product-list .product-thumb {
    display: flex !important;
    flex-direction: column !important;
    flex-grow: 1 !important;
    height: 100% !important;
}

#product-list .content {
    display: flex !important;
    flex-direction: column !important;
    flex-grow: 1 !important;
}

#product-list .price-line {
    margin-top: auto !important;
}

/* Фикс пропорций картинок в сетке каталога под формат 710х380 */
#product-list .image img,
.raffia-product-slider .product-thumb img {
    object-fit: contain !important;
    aspect-ratio: 710/380 !important;
    width: 100% !important;
    height: auto !important;
}

/* ==========================================================================
   TABLES
   ========================================================================== */

#content .table-responsive,
.rf-card .table-responsive {
    border: none !important;
}

#content .table,
.table-responsive .table {
    width: 100%;
    margin-bottom: 2rem;
    vertical-align: middle;
    border-color: transparent !important;
}

#content .table thead th,
.table-responsive .table thead th {
    font-family: var(--font-main) !important;
    font-size: 13px !important;
    font-weight: 600 !important;
    text-transform: uppercase !important;
    letter-spacing: 1px !important;
    color: var(--text-muted) !important;
    border-bottom: 1.5px solid var(--border-primary-strong) !important;
    border-top: none !important;
    border-left: none !important;
    border-right: none !important;
    padding: 15px 20px !important;
    background-color: transparent !important;
}

#content .table tbody tr,
.table-responsive .table tbody tr {
    border-bottom: 1px solid rgba(0,0,0,0.04) !important;
    transition: background-color 0.3s ease;
}

#content .table-hover tbody tr:hover,
.table-responsive .table tbody tr:hover {
    background-color: rgba(92, 107, 90, 0.03) !important;
}

#content .table tbody td,
.table-responsive .table tbody td {
    padding: 20px !important;
    font-family: var(--font-main) !important;
    font-size: 14px !important;
    color: var(--text-main) !important;
    border: none !important;
}

#content .table tbody td a,
.table-responsive .table tbody td a {
    color: var(--text-main) !important;
    text-decoration: none !important;
    font-weight: 500 !important;
    transition: color 0.3s ease;
}

#content .table tbody td a:hover,
.table-responsive .table tbody td a:hover {
    color: var(--brand-primary) !important;
}

#content .table tbody td .btn,
.table-responsive .table tbody td .btn {
    background: transparent !important;
    border: 1px solid rgba(0,0,0,0.1) !important;
    color: var(--text-muted) !important;
    border-radius: var(--radius-sm) !important;
    padding: 8px 12px !important;
    box-shadow: none !important;
    transition: all 0.3s ease !important;
}

#content .table tbody td .btn:hover,
.table-responsive .table tbody td .btn:hover {
    border-color: var(--brand-primary) !important;
    color: var(--brand-primary) !important;
}

#content .table tbody td .btn-danger,
.table-responsive .table tbody td .btn-danger {
    border-color: transparent !important;
    color: #a0a0a0 !important;
}

#content .table tbody td .btn-danger:hover,
.table-responsive .table tbody td .btn-danger:hover {
    color: #d9534f !important;
    background: transparent !important;
}

#content .table tbody td img.img-thumbnail,
.table-responsive .table tbody td img.img-thumbnail {
    border: 1px solid rgba(0,0,0,0.05) !important;
    border-radius: 6px !important;
    padding: 2px !important;
    background: transparent !important;
}

/* ==========================================================================
   BONUS DASHBOARD
   ========================================================================== */

.rf-bonus-card {
    background-color: var(--bg-ivory);
    border: 1px solid var(--border-primary);
    border-radius: var(--radius-md);
    padding: 25px 20px;
    box-shadow: 0 4px 15px rgba(0,0,0,0.02);
    transition: all 0.3s cubic-bezier(0.25, 0.8, 0.25, 1);
}

.rf-bonus-card:hover {
    border-color: var(--brand-primary);
    box-shadow: 0 10px 25px rgba(92, 107, 90, 0.1);
    transform: translateY(-3px);
}

.rf-bonus-icon {
    font-size: 28px;
    color: var(--brand-primary);
    margin-bottom: 15px;
    line-height: 1;
}

.rf-bonus-title {
    font-family: var(--font-main);
    font-size: 14px;
    font-weight: 600;
    color: var(--text-main);
    text-transform: uppercase;
    letter-spacing: 1px;
    margin-bottom: 10px;
}

.rf-bonus-value {
    font-size: 24px;
    font-weight: 700;
    color: var(--brand-primary);
}

.rf-bonus-rules {
    list-style: none;
    padding-left: 0;
    font-family: var(--font-main);
    font-size: 13px;
    color: var(--text-muted);
    line-height: 1.5;
}

.rf-bonus-rules li {
    position: relative;
    padding-left: 18px;
    margin-bottom: 8px;
}

.rf-bonus-rules li::before {
    content: "•";
    color: var(--brand-primary);
    position: absolute;
    left: 0;
    top: 0;
    font-size: 18px;
    line-height: 1.2;
}

/* ==========================================================================
   BLOCKQUOTE
   ========================================================================== */

blockquote {
    background-color: #fcfbf9;
    border-left: 4px solid #d4c5b9;
    margin: 20px 0;
    padding: 15px 20px;
    font-style: italic;
    color: #555;
    border-radius: 0 4px 4px 0;
}

blockquote p:last-child {
    margin-bottom: 0;
}

/* ==========================================================================
   MOBILE
   ========================================================================== */

@media (max-width: 767px) {

    .raffia-header {
        padding: 15px 0 !important;
        min-height: 75px !important;
        display: flex;
        align-items: center;
        position: relative !important;
    }

    .raffia-header-inner {
        position: static !important;
        padding: 0 15px;
    }

    .header-left .language-wrapper,
    .header-left .currency-wrapper {
        display: none !important;
    }

    .header-center {
        position: absolute !important;
        left: 50% !important;
        top: 50% !important;
        transform: translate(-50%, -50%) !important;
        z-index: 10;
    }

    .header-center img {
        height: 45px;
    }

    .dropdown.d-flex.align-items-center,
    .cart-wrapper {
        position: relative;
        z-index: 1050;
    }

    /* Search takeover */
    .raffia-search-takeover {
        position: absolute !important;
        left: 55px !important;
        top: 50% !important;
        transform: translateY(-50%) !important;
        z-index: 1050;
        display: flex;
        align-items: center;
    }

    .raffia-search-takeover .raffia-search-slide-panel,
    .raffia-search-close {
        display: none !important;
    }

    .raffia-search-takeover .raffia-search-btn-trigger {
        display: flex !important;
        color: var(--brand-primary) !important;
    }

    .raffia-search-takeover.is-active ~ .dropdown,
    .raffia-search-takeover.is-active ~ .cart-wrapper {
        display: none !important;
    }

    .raffia-search-takeover.is-active {
        left: 0 !important;
        top: 0 !important;
        width: 100% !important;
        height: 100% !important;
        transform: none !important;
        background: var(--bg-ivory) !important;
        z-index: 1200 !important;
        padding: 0 15px !important;
        display: flex;
        align-items: center;
        justify-content: space-between;
    }

    .raffia-search-takeover.is-active .raffia-search-inline-wrapper {
        flex-grow: 1;
        display: flex;
        align-items: center;
        width: 100%;
    }

    .raffia-search-takeover.is-active .raffia-search-slide-panel {
        display: block !important;
        position: static !important;
        transform: none !important;
        width: 100% !important;
        padding: 0 !important;
        opacity: 1 !important;
        visibility: visible !important;
        pointer-events: auto !important;
        flex-grow: 1;
        margin-right: 15px;
    }

    .raffia-search-takeover.is-active .raffia-search-slide-input {
        width: 100% !important;
        background-color: transparent !important;
        border: none !important;
        border-bottom: 1.5px solid var(--brand-primary) !important;
        padding: 8px 5px !important;
        font-size: 16px !important;
        border-radius: 0 !important;
        box-shadow: none !important;
        color: var(--text-main) !important;
    }

    .raffia-search-takeover.is-active .raffia-search-close {
        display: flex !important;
        background: none;
        border: none;
        color: var(--brand-primary) !important;
        padding: 5px;
        margin-left: 10px;
        cursor: pointer;
    }

    .raffia-logo-text {
        font-size: 22px;
        letter-spacing: 3px;
    }

    .rf-product-title {
        font-size: 24px;
    }

    .rf-product-info-pad {
        padding-top: 15px;
    }

    .rf-carousel-nav {
        display: none !important;
    }

    .rf-controls-group {
        width: 100%;
    }

    /* Edge-to-edge gallery */
    .rf-mobile-edge {
        width: 100vw !important;
        margin-left: calc(-50vw + 50%) !important;
        position: relative;
    }

    .rf-mobile-edge .carousel-item a,
    .rf-mobile-edge .rf-main-img,
    .rf-mobile-edge .raffia-product-img {
        border: none !important;
        border-radius: 0 !important;
        background-color: transparent !important;
        box-shadow: none !important;
        padding: 0 !important;
        margin: 0 !important;
    }

    /* Product list mobile */
    #product-list.row {
        margin-top: 20px !important;
        margin-left: -15px !important;
        margin-right: -15px !important;
        width: calc(100% + 30px) !important;
        --bs-gutter-x: 0 !important;
        --bs-gutter-y: 20px !important;
    }

    #product-list > div {
        padding: 0 !important;
        border: none !important;
    }

    #product-list > div:nth-child(odd) {
        padding-right: 1px !important;
    }

    #product-list > div:nth-child(even) {
        padding-left: 1px !important;
    }

    /* Cart mobile */
    #cart .dropdown-menu {
        position: fixed !important;
        top: 22px !important;
        left: 0 !important;
        right: 0 !important;
        width: 100vw !important;
        max-width: 100vw !important;
        margin: 0 !important;
        border-radius: 0 0 16px 16px !important;
        border: none !important;
        border-top: 1px solid var(--border-primary) !important;
        box-shadow: 0 20px 40px rgba(0,0,0,0.15) !important;
        max-height: calc(100vh - 70px) !important;
        overflow-y: auto !important;
        padding: 15px 8px !important;
        background: #fff !important;
    }

    #cart .dropdown-menu .btn-close {
        top: 15px;
        right: 15px;
    }

    /* Auth pages */
    #account-login,
    #account-register {
        padding-top: 10px !important;
        padding-bottom: 30px !important;
    }

    .raffia-auth-page-card {
        padding: 25px 20px !important;
    }

    .raffia-auth-tabs {
        gap: 20px !important;
        margin-bottom: 25px !important;
    }

    /* Footer */
    .rf-brand-column {
        padding-right: 0;
        margin-bottom: 40px;
    }

    .rf-contacts-column {
        margin-left: 0 !important;
    }

    .rf-social-link {
        padding: 15px;
        margin: -15px;
    }

    .rf-social-icons {
        gap: 24px !important;
    }

    /* Success page */
    #common-success #content {
        padding-left: 15px !important;
        padding-right: 15px !important;
    }

    #common-success #content > div {
        border: none !important;
        box-shadow: none !important;
        background-color: transparent !important;
        padding: 0 !important;
    }

    #common-success #content h1 {
        margin-top: 0 !important;
    }

    .raffia-menu-wrapper {
        display: none !important;
    }

    #menu {
        display: none !important;
    }

    .hide-on-mobile {
        display: none !important;
    }
}

/* ==========================================================================
   OFFCANVAS (Mobile menu)
   ========================================================================== */

.mobile-offcanvas-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 15px 20px;
    background-color: #FAF9F6;
}

.mobile-header-side {
    display: flex;
    align-items: center;
    flex: 1;
}

.mobile-header-side.left-side {
    justify-content: flex-start;
    gap: 15px;
}

.mobile-header-side.right-side {
    justify-content: flex-end;
}

.mobile-header-center {
    display: flex;
    justify-content: center;
    flex: 1;
}

.header-icon-link {
    color: var(--brand-primary);
    display: flex;
    align-items: center;
    justify-content: center;
    text-decoration: none;
    transition: color 0.3s ease;
}

.header-icon-link:hover {
    color: var(--brand-black);
}

.mobile-lang-wrap form,
.mobile-curr-wrap form {
    margin: 0;
    display: flex;
    align-items: center;
}

.mobile-lang-wrap .dropdown-toggle,
.mobile-curr-wrap .dropdown-toggle {
    color: var(--brand-primary) !important;
    display: flex;
    align-items: center;
    justify-content: center;
    text-decoration: none;
    background: transparent;
    border: none;
    padding: 0;
}

.mobile-lang-wrap .dropdown-toggle:hover,
.mobile-curr-wrap .dropdown-toggle:hover {
    color: var(--brand-black) !important;
}

.mobile-lang-wrap .dropdown-toggle svg {
    width: 22px;
    height: 22px;
    stroke-width: 1.5px;
}

.mobile-curr-wrap .dropdown-toggle,
.mobile-curr-wrap .dropdown-toggle strong,
.mobile-curr-wrap .dropdown-toggle span {
    font-size: 24px;
    line-height: 1;
    font-family: var(--font-main);
    display: flex;
    align-items: center;
    transform: translateY(3px) !important;
}

.mobile-curr-wrap .dropdown-toggle strong,
.mobile-curr-wrap .dropdown-toggle span {
    font-weight: 400 !important;
    margin: 0 !important;
    padding: 0 !important;
}

.mobile-lang-wrap .dropdown-toggle::after,
.mobile-curr-wrap .dropdown-toggle::after {
    display: none !important;
}

.offcanvas-body .raffia-menu-wrapper,
.offcanvas-body #menu,
.offcanvas-body #menu .navbar-nav {
    display: block !important;
    visibility: visible !important;
    opacity: 1 !important;
    height: auto !important;
}

/* ==========================================================================
   DESKTOP GREETING
   ========================================================================== */

.raffia-desktop-greeting {
    position: absolute;
    top: 45px;
    right: -10px;
    background-color: var(--bg-ivory);
    color: var(--brand-primary);
    padding: 10px 20px;
    border-radius: 6px;
    font-family: var(--font-main);
    font-size: 13px;
    font-weight: 500;
    box-shadow: 0 10px 25px rgba(0,0,0,0.1);
    white-space: nowrap;
    z-index: 10000;
    pointer-events: none;
    border: 1px solid var(--border-primary);
    opacity: 0;
    transform: translateY(10px);
    transition: opacity 0.4s ease, transform 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

.raffia-desktop-greeting::after {
    content: '';
    position: absolute;
    top: -6px;
    right: 18px;
    width: 10px;
    height: 10px;
    background-color: var(--bg-ivory);
    border-top: 1px solid var(--border-primary);
    border-left: 1px solid var(--border-primary);
    transform: rotate(45deg);
}

/* ==========================================================================
   CHECKOUT & TOM SELECT (Olive / Sage Palette)
   ========================================================================== */

.checkout-section h4,
.aax-checkout-sidebar h4 {
    font-family: var(--font-main);
    font-size: 16px;
    font-weight: 600 !important;
    color: var(--text-main) !important;
}

.aax-sub-heading {
    font-family: var(--font-main);
    font-size: 14px;
    font-weight: 600;
    color: var(--text-main);
}

.aax-checkout-sidebar {
    position: sticky;
    top: 20px;
}

.aax-spinner {
    color: var(--brand-primary);
}

.desktop-auth-field {
    border: none !important;
    padding: 0 !important;
    box-shadow: none !important;
}

#aax-b2b-fields,
#aax-register-fields {
    transition: opacity 0.25s ease;
}

/* Сплошная кнопка Checkout / Confirm Order (как в модальном окне корзины) */
.btn-checkout-solid,
#button-aax-confirm,
#shopping-cart a[href*="checkout"] {
    display: flex !important;
    align-items: center;
    justify-content: center;
    width: 100%;
    height: auto !important;
    padding: 14px 24px !important;
    background-color: var(--brand-primary) !important;
    border: 1px solid var(--brand-primary) !important;
    border-radius: var(--radius-sm) !important;
    color: var(--bg-ivory) !important;
    font-family: var(--font-main) !important;
    font-size: 14px !important;
    font-weight: 600 !important;
    text-transform: uppercase !important;
    letter-spacing: 1px !important;
    cursor: pointer;
    transition: var(--transition);
}

.btn-checkout-solid:hover,
#button-aax-confirm:hover,
#shopping-cart a[href*="checkout"]:hover {
    background-color: var(--brand-primary-hover) !important;
    border-color: var(--brand-primary-hover) !important;
    color: var(--bg-ivory) !important;
    opacity: 0.95;
}

.btn-checkout-solid:disabled,
#button-aax-confirm:disabled {
    opacity: 0.75 !important;
    cursor: wait;
}

/* Tom Select под переменные темы */
.ts-wrapper {
    padding: 0 !important;
    border: none !important;
}

.ts-control {
    background-color: var(--bg-soft) !important;
    border: none !important;
    border-bottom: 1px solid var(--border-primary) !important;
    border-radius: var(--radius-sm) var(--radius-sm) 0 0 !important;
    padding: 12px 40px 12px 15px !important;
    box-shadow: none !important;
    font-family: var(--font-main) !important;
    font-size: 14px !important;
    color: var(--text-main) !important;
    min-height: 46px !important;
    display: flex !important;
    align-items: center !important;
    flex-wrap: nowrap !important;
    position: relative;
    overflow: hidden;
}

.ts-control > .item {
    white-space: normal !important;
    overflow: hidden;
    text-overflow: ellipsis;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    margin-right: 5px !important;
}

.ts-wrapper.single.has-items:not(.focus) .ts-control > input {
    width: 0 !important;
    height: 0 !important;
    padding: 0 !important;
    margin: 0 !important;
    position: absolute !important;
    opacity: 0 !important;
    pointer-events: none;
}

.ts-control.focus,
.ts-wrapper.focus .ts-control {
    background-color: rgba(92, 107, 90, 0.07) !important;
    border-bottom-color: var(--brand-primary) !important;
    box-shadow: none !important;
}

.ts-dropdown {
    background-color: var(--bg-ivory) !important;
    border: 1px solid var(--border-primary) !important;
    border-radius: 0 0 var(--radius-md) var(--radius-md) !important;
    box-shadow: var(--shadow-medium) !important;
    margin-top: 2px !important;
    z-index: 2000 !important;
}

.ts-dropdown .option {
    padding: 10px 20px;
    font-family: var(--font-main);
    font-size: 14px;
    color: var(--text-main) !important;
    transition: all 0.2s ease;
}

.ts-dropdown .option.active,
.ts-dropdown .option:hover {
    background-color: var(--bg-soft) !important;
    color: var(--brand-primary) !important;
}

/* Блок методов оплаты */
#aax-payment-methods-container .form-check {
    margin: 0 !important;
    padding: 0 !important;
}

#aax-payment-methods-container input[type="radio"] {
    display: none !important;
}

#aax-payment-methods-container label {
    font-family: var(--font-main) !important;
    font-weight: 500 !important;
    color: var(--text-main) !important;
    cursor: pointer;
    width: 100%;
    display: flex;
    align-items: center;
    margin: 0 !important;
}

/* Статусы валидации VIES */
#vies-status-icon {
    pointer-events: none;
    color: var(--brand-primary);
}

#vies-validation-msg {
    font-size: 12px;
    color: var(--brand-primary);
}