/* =========================================
   CALCULATOR TAB (TACTICAL RISK ENGINE)
   ========================================= */

/* --- 1. WRAPPER (Centers the device perfectly) --- */
.calc-wrapper {
    height: 100%;
    width: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    background: radial-gradient(circle at center, #111 0%, #000 70%); /* Spotlight effect */
    position: relative;
}

/* --- 2. THE DEVICE CHASSIS --- */
.calc-device {
    width: 100%;
    max-width: 380px; /* Optimal width for focus */
    background: #080808;
    border: 1px solid #333;
    border-radius: 6px;
    box-shadow: 0 0 60px rgba(0,0,0,0.8), 0 0 0 1px #222; /* Deep shadow + Border ring */
    overflow: hidden;
    position: relative;
    display: flex;
    flex-direction: column;
}

/* --- 3. HEADER BAR --- */
.calc-header-bar {
    background: #0c0c0c;
    padding: 12px 20px;
    border-bottom: 1px solid #222;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.calc-title {
    font-family: var(--font-mono);
    font-size: 10px;
    font-weight: 700;
    color: #666;
    letter-spacing: 2px;
    text-transform: uppercase;
}

/* --- 4. THE SCREEN (Results Area) --- */
.calc-screen {
    background: linear-gradient(180deg, rgba(0, 255, 157, 0.05) 0%, rgba(0,0,0,0) 100%);
    border-bottom: 1px solid #222;
    padding: 30px 20px;
    text-align: center;
    position: relative;
}

/* The Big Lot Size Number */
.calc-lot-display {
    font-family: var(--font-mono);
    font-size: 42px; /* Massive for readability */
    font-weight: 700;
    color: var(--accent);
    text-shadow: 0 0 20px rgba(0, 255, 157, 0.4);
    line-height: 1;
    margin-bottom: 8px;
    letter-spacing: -1px;
}

.calc-lot-label {
    font-size: 9px;
    color: var(--accent);
    opacity: 0.7;
    letter-spacing: 2px;
    text-transform: uppercase;
    font-weight: 700;
}

/* Secondary Stats (Cash Risk) */
.calc-sub-screen {
    display: flex;
    justify-content: center;
    gap: 15px;
    margin-top: 15px;
}

.calc-stat-pill {
    background: #000;
    border: 1px solid #333;
    padding: 6px 12px;
    border-radius: 4px;
    font-family: var(--font-mono);
    font-size: 10px;
    color: #888;
    letter-spacing: 1px;
}

.calc-stat-pill strong {
    color: #fff;
    margin-left: 5px;
}

/* --- 5. CONTROLS BODY --- */
.calc-body {
    padding: 25px;
    display: flex;
    flex-direction: column;
    gap: 15px;
    background: #080808;
}

/* Input Grid Layout */
.calc-input-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 15px;
}

.calc-group {
    display: flex;
    flex-direction: column;
    position: relative;
}

.calc-group label {
    font-size: 9px;
    color: #555;
    font-family: var(--font-mono);
    font-weight: 700;
    margin-bottom: 6px;
    display: block;
    letter-spacing: 1px;
    text-transform: uppercase;
}

/* High-End Inputs */
.calc-input {
    width: 100%;
    background: #0b0b0b;
    border: 1px solid #2a2a2a;
    color: #fff;
    padding: 12px;
    font-family: var(--font-mono);
    font-size: 12px;
    border-radius: 4px;
    transition: all 0.2s ease;
    text-align: center; /* Center values for focus */
}

.calc-input:focus {
    border-color: var(--accent);
    background: #0f0f0f;
    box-shadow: 0 0 15px rgba(0, 255, 157, 0.05);
}

.calc-input::placeholder {
    color: #333;
    text-transform: uppercase;
}

/* Highlight Risk Input */
#re-risk {
    color: var(--accent);
    font-weight: bold;
}

/* --- 6. ACTION BUTTON --- */
.calc-action-btn {
    width: 100%;
    background: var(--accent);
    color: #000;
    border: none;
    padding: 14px;
    font-family: var(--font-mono);
    font-weight: 800;
    font-size: 11px;
    letter-spacing: 1px;
    cursor: pointer;
    margin-top: 10px;
    border-radius: 4px;
    transition: all 0.2s ease;
    text-transform: uppercase;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
}

.calc-action-btn:hover {
    box-shadow: 0 0 20px rgba(0, 255, 157, 0.4);
    transform: translateY(-1px);
    filter: brightness(1.1);
}

.calc-action-btn:active {
    transform: translateY(0);
}

/* --- 7. FOOTER --- */
.calc-footer {
    text-align: center;
    padding: 12px;
    font-size: 8px;
    color: #444;
    font-family: var(--font-mono);
    border-top: 1px solid #1a1a1a;
    background: #050505;
    letter-spacing: 1px;
}

/* --- 8. SEARCH DROPDOWN FIX --- */
/* Ensures the asset search dropdown inside calculator floats correctly */
.calc-group .search-results {
    top: 100%;
    left: 0;
    width: 100%;
    margin-top: 5px;
    background: #0a0a0a;
    border: 1px solid var(--accent);
    box-shadow: 0 10px 30px rgba(0,0,0,0.8);
    border-radius: 4px;
}