/* ============================================
   Morssmitt Quotation — Frontend Styles v1.2
   Compact design matching Morssmitt screenshot
   ============================================ */

/* --- Quote Icon (header) --- */

.msq-quote-icon-link {
    display: inline-flex;
    align-items: center;
    text-decoration: none;
    color: inherit;
    position: relative;
}

.msq-quote-icon {
    position: relative;
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

.msq-quote-badge {
    position: absolute;
    top: -6px;
    right: -8px;
    color: #fff;
    font-size: 10px;
    font-weight: 700;
    line-height: 1;
    min-width: 16px;
    height: 16px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0 3px;
    box-sizing: border-box;
}


/* --- Add to Quote (product page) --- */

/* Default: vertical layout (input above button) */
.msq-add-to-quote {
    display: inline-flex;
    flex-direction: column;
    gap: 8px;
    max-width: 200px;
}

/* Horizontal layout (input next to button) */
.msq-add-to-quote.msq-layout-horizontal {
    flex-direction: row;
    align-items: center;
    max-width: none;
    gap: 8px;
}

.msq-add-to-quote.msq-layout-horizontal .msq-quantity-selector {
    flex-shrink: 0;
}

.msq-add-to-quote.msq-layout-horizontal .msq-add-btn {
    flex-shrink: 0;
    white-space: nowrap;
}

/* Quantity selector: compact gray rounded container */
.msq-quantity-selector {
    display: flex;
    align-items: center;
    background: #edf0f4;
    border-radius: 8px;
    height: 38px;
    padding: 3px;
    box-sizing: border-box;
}

.msq-qty-btn {
    border: none;
    background: transparent;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    -webkit-appearance: none;
    appearance: none;
    padding: 0;
    line-height: 1;
    flex-shrink: 0;
    transition: opacity 0.15s;
}

.msq-qty-btn:hover {
    opacity: 0.7;
}

.msq-qty-minus {
    width: 36px;
    height: 32px;
    font-size: 16px;
    font-weight: 400;
    color: #b0b5bf;
}

.msq-qty-input {
    flex: 1;
    text-align: center;
    border: none;
    background: #fff;
    font-size: 14px;
    font-weight: 600;
    height: 32px;
    color: #1a1a2e;
    border-radius: 5px;
    -moz-appearance: textfield;
    -webkit-appearance: none;
    appearance: none;
    outline: none;
    min-width: 36px;
    max-width: 50px;
}

.msq-qty-input::-webkit-inner-spin-button,
.msq-qty-input::-webkit-outer-spin-button {
    -webkit-appearance: none;
    margin: 0;
}

.msq-qty-plus {
    width: 36px;
    height: 32px;
    font-size: 18px;
    font-weight: 700;
    color: #1a1a2e;
}

/* Add button: compact pill */
.msq-add-btn {
    border: none;
    border-radius: 50px;
    padding: 10px 20px;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: opacity 0.2s, transform 0.1s;
    -webkit-appearance: none;
    appearance: none;
    text-align: center;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    line-height: 1.2;
    white-space: nowrap;
}

.msq-add-btn:hover {
    opacity: 0.85;
}

.msq-add-btn:active {
    transform: scale(0.97);
}

.msq-add-btn.msq-added {
    background-color: #2e7d32 !important;
}

.msq-btn-icon {
    display: inline-flex;
    align-items: center;
    flex-shrink: 0;
}

.msq-btn-icon svg {
    display: block;
}


/* --- Quote Page --- */

.msq-quote-page {
    max-width: 800px;
}

.msq-loading {
    padding: 20px;
    color: #666;
}

.msq-quote-item {
    display: flex;
    align-items: center;
    gap: 14px;
    padding: 14px 0;
    border-bottom: 1px solid #eee;
}

.msq-quote-item:last-child {
    border-bottom: none;
}

.msq-item-thumb {
    width: 60px;
    height: 60px;
    object-fit: cover;
    border-radius: 6px;
    background: #f5f5f5;
    flex-shrink: 0;
}

.msq-item-thumb-placeholder {
    width: 60px;
    height: 60px;
    background: #f0f0f0;
    border-radius: 6px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #ccc;
    font-size: 11px;
    flex-shrink: 0;
}

.msq-item-info {
    flex: 1;
    min-width: 0;
}

.msq-item-title {
    font-weight: 600;
    font-size: 14px;
    margin: 0 0 3px;
}

.msq-item-title a {
    color: inherit;
    text-decoration: none;
}

.msq-item-title a:hover {
    text-decoration: underline;
}

.msq-item-sku {
    font-size: 12px;
    color: #888;
}

.msq-item-qty {
    display: flex;
    align-items: center;
    background: #edf0f4;
    border-radius: 6px;
    padding: 2px;
}

.msq-item-qty .msq-qty-btn {
    width: 28px;
    height: 28px;
    font-size: 14px;
    font-weight: 600;
    color: #666;
}

.msq-item-qty .msq-qty-input {
    width: 34px;
    height: 28px;
    font-size: 13px;
    border-radius: 4px;
}

.msq-item-remove {
    background: none;
    border: none;
    color: #bbb;
    cursor: pointer;
    font-size: 18px;
    padding: 2px 6px;
    transition: color 0.15s;
    -webkit-appearance: none;
    appearance: none;
}

.msq-item-remove:hover {
    color: #e30613;
}


/* --- Quote Form --- */

.msq-quote-form-wrapper {
    margin-top: 24px;
    padding-top: 18px;
    border-top: 2px solid #eee;
}

.msq-quote-form-wrapper h3 {
    margin: 0 0 14px;
    font-size: 18px;
}

.msq-form-row {
    margin-bottom: 12px;
}

.msq-form-row label {
    display: block;
    margin-bottom: 3px;
    font-weight: 600;
    font-size: 13px;
}

.msq-required {
    color: #e30613;
}

.msq-input {
    width: 100%;
    max-width: 360px;
    padding: 9px 12px;
    border: 1px solid #ddd;
    border-radius: 6px;
    font-size: 14px;
    box-sizing: border-box;
    outline: none;
    transition: border-color 0.2s;
}

.msq-input:focus {
    border-color: #333;
}

.msq-submit-btn {
    background: #e30613;
    color: #fff;
    border: none;
    border-radius: 50px;
    padding: 11px 26px;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: background 0.2s;
    -webkit-appearance: none;
    appearance: none;
    margin-top: 4px;
}

.msq-submit-btn:hover {
    background: #c50510;
}

.msq-submit-btn:disabled {
    background: #ccc;
    cursor: not-allowed;
}

.msq-form-message {
    margin-top: 10px;
    font-size: 13px;
}

.msq-form-message.msq-success {
    color: #2e7d32;
}

.msq-form-message.msq-error {
    color: #e30613;
}

.msq-empty-message {
    padding: 30px 0;
    text-align: center;
    color: #888;
    font-size: 15px;
}
