/* ============================
   PLATFORMA CUSTOM FILE INPUT (Slice Stabilize-4d)
   Replaces native <input type="file"> so the "Choose file" /
   "No file chosen" labels are controlled by our resx, not the
   browser's UA locale.
   ============================ */
.platforma-file-input {
    display: flex;
    align-items: center;
    gap: var(--platforma-space-2);
    padding: 0;
    border: 1px solid var(--platforma-gray-200);
    border-radius: var(--platforma-radius-md, 8px);
    background: var(--platforma-white);
    overflow: hidden;
    transition: border-color 0.15s ease, box-shadow 0.15s ease;
}

.platforma-file-input:focus-within {
    border-color: var(--platforma-primary);
    box-shadow: 0 0 0 3px rgba(54, 153, 255, 0.15);
}

.platforma-file-input__native {
    position: absolute;
    left: -9999px;
    opacity: 0;
    width: 1px;
    height: 1px;
}

.platforma-file-input__button {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.55rem 1rem;
    background: var(--platforma-gray-50);
    color: var(--platforma-gray-700);
    font-weight: 600;
    font-size: var(--platforma-text-sm);
    border-right: 1px solid var(--platforma-gray-200);
    cursor: pointer;
    transition: background 0.15s ease;
    white-space: nowrap;
}

.platforma-file-input__button:hover {
    background: var(--platforma-gray-100);
    color: var(--platforma-gray-900);
}

.platforma-file-input__button svg {
    width: 16px;
    height: 16px;
    opacity: 0.7;
}

.platforma-file-input__label {
    flex: 1;
    padding: 0.55rem 1rem;
    color: var(--platforma-gray-500);
    font-size: var(--platforma-text-sm);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.platforma-file-input.has-file .platforma-file-input__label {
    color: var(--platforma-gray-900);
    font-weight: 500;
}
