@import url('https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700;800;900&family=JetBrains+Mono:wght@500;700;800&display=swap');

* {
    box-sizing: border-box;
    -webkit-tap-highlight-color: transparent;
}

body {
    font-family: 'Inter', sans-serif;
    user-select: none;
    -webkit-user-select: none;
    touch-action: none;
}

.font-mono {
    font-family: 'JetBrains Mono', monospace;
}

/* Кнопки верхнього меню */
.top-icon-btn {
    width: 32px;
    height: 32px;
    border-radius: 9px;
    background: #1f2937;
    border: 1px solid #374151;
    color: #e5e7eb;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    transition: all 0.15s ease;
}
.top-icon-btn:hover {
    background: #374151;
    color: #38bdf8;
    transform: translateY(-1px);
}
.top-icon-btn:active {
    transform: translateY(0);
}

/* Кнопки HUD масштабування */
.hud-circle-btn {
    width: 28px;
    height: 28px;
    border-radius: 10px;
    background: #1f2937;
    color: #94a3b8;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    transition: all 0.15s;
}
.hud-circle-btn:hover {
    background: #374151;
    color: #38bdf8;
}

/* БОКОВІ ЯРЛИКИ (TABS) */
.side-tab-btn {
    width: 36px;
    height: 36px;
    border-radius: 10px;
    background: #192233;
    border: 1px solid #334155;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    cursor: pointer;
    transition: all 0.15s cubic-bezier(0.4, 0, 0.2, 1);
}
.side-tab-btn:hover {
    background: #223049;
    border-color: #38bdf8;
    transform: scale(1.05);
}
.side-tab-btn.active {
    background: #0f2744;
    border-color: #0284c7;
    box-shadow: 0 0 12px rgba(2, 132, 199, 0.45);
}

/* ВИСУВНІ ПАНЕЛІ (DRAWERS) */
.cad-drawer {
    position: absolute;
    right: 48px; /* поруч із рейкою шириною 48px */
    top: 0;
    bottom: 0;
    transition: transform 0.25s cubic-bezier(0.16, 1, 0.3, 1), opacity 0.2s ease;
    transform: translateX(0);
    opacity: 1;
}
.cad-drawer.drawer-closed {
    transform: translateX(110%);
    opacity: 0;
    pointer-events: none;
}

/* Кнопки вибору інструментів */
.tool-select-btn {
    background: #0f172a;
    border: 1px solid #1e293b;
    border-radius: 10px;
    padding: 8px 4px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 4px;
    color: #94a3b8;
    transition: all 0.15s;
    cursor: pointer;
}
.tool-select-btn:hover {
    background: #1e293b;
    color: #38bdf8;
}
.tool-select-btn.active {
    background: #0c4a6e;
    border-color: #0284c7;
    color: #38bdf8;
    box-shadow: 0 0 10px rgba(2, 132, 199, 0.3);
}

/* Кнопки вибору фону */
.bg-btn-choice {
    background: #1e293b;
    border: 1px solid #334155;
    border-radius: 8px;
    padding: 6px 4px;
    font-size: 10px;
    font-weight: 700;
    color: #cbd5e1;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 5px;
    transition: all 0.15s;
}
.bg-btn-choice.active {
    border-color: #0284c7;
    background: #0f2744;
    color: #38bdf8;
}

/* Слайдери */
.cad-slider {
    accent-color: #0284c7;
    height: 5px;
    border-radius: 4px;
    background: #334155;
    outline: none;
}

/* Прозорий шаховий візерунок */
.stripe-pattern {
    background: repeating-conic-gradient(#334155 0% 25%, #1e293b 0% 50%) 50% / 8px 8px;
}

/* Скролбар */
::-webkit-scrollbar {
    width: 5px;
    height: 5px;
}
::-webkit-scrollbar-track {
    background: #0b0f19;
}
::-webkit-scrollbar-thumb {
    background: #1f2937;
    border-radius: 3px;
}
::-webkit-scrollbar-thumb:hover {
    background: #374151;
}