# Margin Rule

In derivatives trading, **Initial Margin** and **Maintenance Margin** define the minimum capital requirements:

* **Initial Margin**: The minimum amount required to open a position.
* **Maintenance Margin**: The minimum balance required to keep the position open.

Since traders adopt different strategies, YUBIT supports two margin modes: **Cross Margin** and **Isolated Margin**.\\

**1. Cross Margin**

* All positions in the same margin account share the available balance.
* If a position requires more margin to avoid liquidation, additional funds are automatically drawn from the account balance.

**Example:**\
A trader opens a **100 BTC/USDT long** with **517.04 USDT margin**.

* If the market falls and required margin rises to **600 USDT**, the extra **82.96 USDT** will be automatically used from the account balance.
* This helps avoid liquidation.

***

**2. Isolated Margin**

* Margin is limited to the amount allocated to a single position.
* If margin falls below the maintenance level, the position will be liquidated.
* Traders can manually adjust (add/remove) margin for the position.

**Example:**\
A trader opens a **100 BTC/USDT long** with **517.04 USDT margin**.

* In Isolated Mode, if margin requirements exceed this amount, the position is liquidated to prevent further loss.

***

**3. Margin Accounts**

Each collateral asset is managed separately. For example:

* BTC Margin Account
* USDT Margin Account

Profits and losses in one margin account do not affect others.

***

**4. Details of Margin Modes**

**4.1 Cross Margin (Default)**

* Also known as “shared margin.”
* Uses the entire account balance to prevent liquidation.
* Profitable positions can offset losing ones.
* Useful for **hedgers** and **arbitrage traders**.
* **Default mode** for all contracts.

**4.2 Isolated Margin**

* Maximum loss is limited to the allocated initial margin.
* Additional account funds are **not used** for that position.
* Useful for **speculative trades** where risk must be capped.
* High leverage = higher liquidation risk.
  * Example: A **50x leveraged position** is liquidated if price moves **2%** against you.

**4.3 Adjusting Isolated Margin**

* By default, Cross Margin is enabled.
* You can switch to Isolated Margin in the **Leverage Slider** on the trading panel.
* The chosen leverage setting is saved per contract.
* The liquidation price updates in real time as leverage is adjusted.

**4.4 Isolated Margin & Mark Price**

* During extreme volatility, market prices may deviate from the mark price.
* If you enter at a price far from the mark price, you may see **unrealized losses immediately**.
* This doesn’t necessarily mean real losses but raises the risk of quick liquidation.
* To avoid this, use moderate leverage during volatile conditions.
